]> 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.3.50.
4 #
5 #
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
9 #
10 #
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
90
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
96 do
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
102
103 ;;
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
109 fi
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
113 fi
114
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
126
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
132
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
149 ;;
150 esac
151 fi
152 "
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
158
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
165
166 else
167 exitcode=1; echo positional parameters were not saved.
168 fi
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
179 fi
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
186 do
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
191 /*)
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
200 fi
201 fi
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
211
212
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
222 fi
223
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
235 fi
236 exit 1
237 fi
238 fi
239 fi
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
245
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
253 {
254 { eval $1=; unset $1;}
255 }
256 as_unset=as_fn_unset
257
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
262 {
263 return $1
264 } # as_fn_set_status
265
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
270 {
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
275
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
280 {
281
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
301 q
302 }
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
305 q
306 }
307 /^X\(\/\/\)$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\).*/{
312 s//\1/
313 q
314 }
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
320
321
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
331 {
332 eval $1+=\$2
333 }'
334 else
335 as_fn_append ()
336 {
337 eval $1=\$$1\$2
338 }
339 fi # as_fn_append
340
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
348 {
349 as_val=$(( $* ))
350 }'
351 else
352 as_fn_arith ()
353 {
354 as_val=`expr "$@" || test $? -eq 1`
355 }
356 fi # as_fn_arith
357
358
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
365 {
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
370 fi
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
374
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
380 fi
381
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
386 fi
387
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
392 fi
393
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
401 q
402 }
403 /^X\/\(\/\/\)$/{
404 s//\1/
405 q
406 }
407 /^X\/\(\/\).*/{
408 s//\1/
409 q
410 }
411 s/.*/./; q'`
412
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
419
420
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
427 p
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
433 b
434 :lineno
435 N
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
443
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
450 }
451
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
461 *)
462 ECHO_N='-n';;
463 esac
464
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
471 fi
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
485 fi
486 else
487 as_ln_s='cp -p'
488 fi
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
491
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
497 fi
498
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
506 fi
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
518 '
519 fi
520 as_executable_p=$as_test_x
521
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
531
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
536
537 #
538 # Initializations.
539 #
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
548
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.3.50'
553 PACKAGE_STRING='emacs 24.3.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
556
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
593
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 ns_check_file
608 WINDOW_SYSTEM_OBJ
609 EMACS_HEAPSIZE
610 TEMACS_POST_LINK
611 ADDSECTION
612 LD_SWITCH_SYSTEM_TEMACS
613 LIBGNU_LTLIBDEPS
614 LIBGNU_LIBDEPS
615 gltests_WITNESS
616 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE
617 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE
618 gl_GNULIB_ENABLED_tempname_FALSE
619 gl_GNULIB_ENABLED_tempname_TRUE
620 gl_GNULIB_ENABLED_strtoull_FALSE
621 gl_GNULIB_ENABLED_strtoull_TRUE
622 gl_GNULIB_ENABLED_strtoll_FALSE
623 gl_GNULIB_ENABLED_strtoll_TRUE
624 gl_GNULIB_ENABLED_stat_FALSE
625 gl_GNULIB_ENABLED_stat_TRUE
626 gl_GNULIB_ENABLED_secure_getenv_FALSE
627 gl_GNULIB_ENABLED_secure_getenv_TRUE
628 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE
629 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE
630 gl_GNULIB_ENABLED_pathmax_FALSE
631 gl_GNULIB_ENABLED_pathmax_TRUE
632 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE
633 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE
634 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE
635 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE
636 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
637 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
638 gl_GNULIB_ENABLED_getgroups_FALSE
639 gl_GNULIB_ENABLED_getgroups_TRUE
640 gl_GNULIB_ENABLED_getdtablesize_FALSE
641 gl_GNULIB_ENABLED_getdtablesize_TRUE
642 gl_GNULIB_ENABLED_euidaccess_FALSE
643 gl_GNULIB_ENABLED_euidaccess_TRUE
644 gl_GNULIB_ENABLED_dosname_FALSE
645 gl_GNULIB_ENABLED_dosname_TRUE
646 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE
647 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE
648 LTLIBINTL
649 LIBINTL
650 LIB_EACCESS
651 WINDOWS_64_BIT_OFF_T
652 HAVE_UNISTD_H
653 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
654 NEXT_UNISTD_H
655 LIB_TIMER_TIME
656 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
657 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
658 TIME_H_DEFINES_STRUCT_TIMESPEC
659 NEXT_AS_FIRST_DIRECTIVE_TIME_H
660 NEXT_TIME_H
661 WINDOWS_64_BIT_ST_SIZE
662 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
663 NEXT_SYS_STAT_H
664 NEXT_AS_FIRST_DIRECTIVE_STRING_H
665 NEXT_STRING_H
666 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
667 NEXT_STDLIB_H
668 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
669 NEXT_STDIO_H
670 REPLACE_VSPRINTF
671 REPLACE_VSNPRINTF
672 REPLACE_VPRINTF
673 REPLACE_VFPRINTF
674 REPLACE_VDPRINTF
675 REPLACE_VASPRINTF
676 REPLACE_TMPFILE
677 REPLACE_STDIO_WRITE_FUNCS
678 REPLACE_STDIO_READ_FUNCS
679 REPLACE_SPRINTF
680 REPLACE_SNPRINTF
681 REPLACE_RENAMEAT
682 REPLACE_RENAME
683 REPLACE_REMOVE
684 REPLACE_PRINTF
685 REPLACE_POPEN
686 REPLACE_PERROR
687 REPLACE_OBSTACK_PRINTF
688 REPLACE_GETLINE
689 REPLACE_GETDELIM
690 REPLACE_FTELLO
691 REPLACE_FTELL
692 REPLACE_FSEEKO
693 REPLACE_FSEEK
694 REPLACE_FREOPEN
695 REPLACE_FPURGE
696 REPLACE_FPRINTF
697 REPLACE_FOPEN
698 REPLACE_FFLUSH
699 REPLACE_FDOPEN
700 REPLACE_FCLOSE
701 REPLACE_DPRINTF
702 HAVE_VDPRINTF
703 HAVE_VASPRINTF
704 HAVE_RENAMEAT
705 HAVE_POPEN
706 HAVE_PCLOSE
707 HAVE_FTELLO
708 HAVE_FSEEKO
709 HAVE_DPRINTF
710 HAVE_DECL_VSNPRINTF
711 HAVE_DECL_SNPRINTF
712 HAVE_DECL_OBSTACK_PRINTF
713 HAVE_DECL_GETLINE
714 HAVE_DECL_GETDELIM
715 HAVE_DECL_FTELLO
716 HAVE_DECL_FSEEKO
717 HAVE_DECL_FPURGE
718 GNULIB_VSPRINTF_POSIX
719 GNULIB_VSNPRINTF
720 GNULIB_VPRINTF_POSIX
721 GNULIB_VPRINTF
722 GNULIB_VFPRINTF_POSIX
723 GNULIB_VFPRINTF
724 GNULIB_VDPRINTF
725 GNULIB_VSCANF
726 GNULIB_VFSCANF
727 GNULIB_VASPRINTF
728 GNULIB_TMPFILE
729 GNULIB_STDIO_H_SIGPIPE
730 GNULIB_STDIO_H_NONBLOCKING
731 GNULIB_SPRINTF_POSIX
732 GNULIB_SNPRINTF
733 GNULIB_SCANF
734 GNULIB_RENAMEAT
735 GNULIB_RENAME
736 GNULIB_REMOVE
737 GNULIB_PUTS
738 GNULIB_PUTCHAR
739 GNULIB_PUTC
740 GNULIB_PRINTF_POSIX
741 GNULIB_PRINTF
742 GNULIB_POPEN
743 GNULIB_PERROR
744 GNULIB_PCLOSE
745 GNULIB_OBSTACK_PRINTF_POSIX
746 GNULIB_OBSTACK_PRINTF
747 GNULIB_GETLINE
748 GNULIB_GETDELIM
749 GNULIB_GETCHAR
750 GNULIB_GETC
751 GNULIB_FWRITE
752 GNULIB_FTELLO
753 GNULIB_FTELL
754 GNULIB_FSEEKO
755 GNULIB_FSEEK
756 GNULIB_FSCANF
757 GNULIB_FREOPEN
758 GNULIB_FREAD
759 GNULIB_FPUTS
760 GNULIB_FPUTC
761 GNULIB_FPURGE
762 GNULIB_FPRINTF_POSIX
763 GNULIB_FPRINTF
764 GNULIB_FOPEN
765 GNULIB_FGETS
766 GNULIB_FGETC
767 GNULIB_FFLUSH
768 GNULIB_FDOPEN
769 GNULIB_FCLOSE
770 GNULIB_DPRINTF
771 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
772 NEXT_STDDEF_H
773 GL_GENERATE_STDDEF_H_FALSE
774 GL_GENERATE_STDDEF_H_TRUE
775 STDDEF_H
776 HAVE_WCHAR_T
777 REPLACE_NULL
778 HAVE__BOOL
779 GL_GENERATE_STDBOOL_H_FALSE
780 GL_GENERATE_STDBOOL_H_TRUE
781 STDBOOL_H
782 GL_GENERATE_STDARG_H_FALSE
783 GL_GENERATE_STDARG_H_TRUE
784 STDARG_H
785 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
786 NEXT_STDARG_H
787 GL_GENERATE_STDALIGN_H_FALSE
788 GL_GENERATE_STDALIGN_H_TRUE
789 STDALIGN_H
790 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
791 NEXT_SIGNAL_H
792 USE_ACL
793 LIB_ACL
794 LIB_PTHREAD_SIGMASK
795 REPLACE_RAISE
796 REPLACE_PTHREAD_SIGMASK
797 HAVE_SIGHANDLER_T
798 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
799 HAVE_STRUCT_SIGACTION_SA_SIGACTION
800 HAVE_SIGACTION
801 HAVE_SIGINFO_T
802 HAVE_SIGSET_T
803 HAVE_RAISE
804 HAVE_PTHREAD_SIGMASK
805 HAVE_POSIX_SIGNALBLOCKING
806 GNULIB_SIGACTION
807 GNULIB_SIGPROCMASK
808 GNULIB_SIGNAL_H_SIGPIPE
809 GNULIB_RAISE
810 GNULIB_PTHREAD_SIGMASK
811 HAVE_SYS_SELECT_H
812 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
813 NEXT_SYS_SELECT_H
814 REPLACE_SELECT
815 REPLACE_PSELECT
816 HAVE_PSELECT
817 GNULIB_SELECT
818 GNULIB_PSELECT
819 REPLACE_TIMEGM
820 REPLACE_NANOSLEEP
821 REPLACE_MKTIME
822 REPLACE_LOCALTIME_R
823 HAVE_TIMEGM
824 HAVE_STRPTIME
825 HAVE_NANOSLEEP
826 HAVE_DECL_LOCALTIME_R
827 GNULIB_TIME_R
828 GNULIB_TIMEGM
829 GNULIB_STRPTIME
830 GNULIB_NANOSLEEP
831 GNULIB_MKTIME
832 UNDEFINE_STRTOK_R
833 REPLACE_STRTOK_R
834 REPLACE_STRSIGNAL
835 REPLACE_STRNLEN
836 REPLACE_STRNDUP
837 REPLACE_STRNCAT
838 REPLACE_STRERROR_R
839 REPLACE_STRERROR
840 REPLACE_STRCHRNUL
841 REPLACE_STRCASESTR
842 REPLACE_STRSTR
843 REPLACE_STRDUP
844 REPLACE_STPNCPY
845 REPLACE_MEMMEM
846 REPLACE_MEMCHR
847 HAVE_STRVERSCMP
848 HAVE_DECL_STRSIGNAL
849 HAVE_DECL_STRERROR_R
850 HAVE_DECL_STRTOK_R
851 HAVE_STRCASESTR
852 HAVE_STRSEP
853 HAVE_STRPBRK
854 HAVE_DECL_STRNLEN
855 HAVE_DECL_STRNDUP
856 HAVE_DECL_STRDUP
857 HAVE_STRCHRNUL
858 HAVE_STPNCPY
859 HAVE_STPCPY
860 HAVE_RAWMEMCHR
861 HAVE_DECL_MEMRCHR
862 HAVE_MEMPCPY
863 HAVE_DECL_MEMMEM
864 HAVE_MEMCHR
865 HAVE_FFSLL
866 HAVE_FFSL
867 HAVE_MBSLEN
868 GNULIB_STRVERSCMP
869 GNULIB_STRSIGNAL
870 GNULIB_STRERROR_R
871 GNULIB_STRERROR
872 GNULIB_MBSTOK_R
873 GNULIB_MBSSEP
874 GNULIB_MBSSPN
875 GNULIB_MBSPBRK
876 GNULIB_MBSCSPN
877 GNULIB_MBSCASESTR
878 GNULIB_MBSPCASECMP
879 GNULIB_MBSNCASECMP
880 GNULIB_MBSCASECMP
881 GNULIB_MBSSTR
882 GNULIB_MBSRCHR
883 GNULIB_MBSCHR
884 GNULIB_MBSNLEN
885 GNULIB_MBSLEN
886 GNULIB_STRTOK_R
887 GNULIB_STRCASESTR
888 GNULIB_STRSTR
889 GNULIB_STRSEP
890 GNULIB_STRPBRK
891 GNULIB_STRNLEN
892 GNULIB_STRNDUP
893 GNULIB_STRNCAT
894 GNULIB_STRDUP
895 GNULIB_STRCHRNUL
896 GNULIB_STPNCPY
897 GNULIB_STPCPY
898 GNULIB_RAWMEMCHR
899 GNULIB_MEMRCHR
900 GNULIB_MEMPCPY
901 GNULIB_MEMMEM
902 GNULIB_MEMCHR
903 GNULIB_FFSLL
904 GNULIB_FFSL
905 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
906 NEXT_INTTYPES_H
907 UINT64_MAX_EQ_ULONG_MAX
908 UINT32_MAX_LT_UINTMAX_MAX
909 PRIPTR_PREFIX
910 PRI_MACROS_BROKEN
911 INT64_MAX_EQ_LONG_MAX
912 INT32_MAX_LT_INTMAX_MAX
913 REPLACE_STRTOUMAX
914 REPLACE_STRTOIMAX
915 HAVE_DECL_STRTOUMAX
916 HAVE_DECL_STRTOIMAX
917 HAVE_DECL_IMAXDIV
918 HAVE_DECL_IMAXABS
919 GNULIB_STRTOUMAX
920 GNULIB_STRTOIMAX
921 GNULIB_IMAXDIV
922 GNULIB_IMAXABS
923 GL_GENERATE_STDINT_H_FALSE
924 GL_GENERATE_STDINT_H_TRUE
925 STDINT_H
926 WINT_T_SUFFIX
927 WCHAR_T_SUFFIX
928 SIG_ATOMIC_T_SUFFIX
929 SIZE_T_SUFFIX
930 PTRDIFF_T_SUFFIX
931 HAVE_SIGNED_WINT_T
932 HAVE_SIGNED_WCHAR_T
933 HAVE_SIGNED_SIG_ATOMIC_T
934 BITSIZEOF_WINT_T
935 BITSIZEOF_WCHAR_T
936 BITSIZEOF_SIG_ATOMIC_T
937 BITSIZEOF_SIZE_T
938 BITSIZEOF_PTRDIFF_T
939 APPLE_UNIVERSAL_BUILD
940 HAVE_SYS_BITYPES_H
941 HAVE_SYS_INTTYPES_H
942 HAVE_STDINT_H
943 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
944 NEXT_STDINT_H
945 HAVE_SYS_TYPES_H
946 HAVE_INTTYPES_H
947 HAVE_WCHAR_H
948 HAVE_UNSIGNED_LONG_LONG_INT
949 HAVE_LONG_LONG_INT
950 HAVE_WINSOCK2_H
951 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
952 NEXT_SYS_TIME_H
953 REPLACE_STRUCT_TIMEVAL
954 REPLACE_GETTIMEOFDAY
955 HAVE_SYS_TIME_H
956 HAVE_STRUCT_TIMEVAL
957 HAVE_GETTIMEOFDAY
958 GNULIB_GETTIMEOFDAY
959 GNULIB_GL_UNISTD_H_GETOPT
960 GETOPT_H
961 HAVE_GETOPT_H
962 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
963 NEXT_GETOPT_H
964 GETLOADAVG_LIBS
965 REPLACE_WCTOMB
966 REPLACE_UNSETENV
967 REPLACE_STRTOD
968 REPLACE_SETENV
969 REPLACE_REALPATH
970 REPLACE_REALLOC
971 REPLACE_RANDOM_R
972 REPLACE_PUTENV
973 REPLACE_PTSNAME_R
974 REPLACE_PTSNAME
975 REPLACE_MKSTEMP
976 REPLACE_MBTOWC
977 REPLACE_MALLOC
978 REPLACE_CANONICALIZE_FILE_NAME
979 REPLACE_CALLOC
980 HAVE_DECL_UNSETENV
981 HAVE_UNLOCKPT
982 HAVE_SYS_LOADAVG_H
983 HAVE_STRUCT_RANDOM_DATA
984 HAVE_STRTOULL
985 HAVE_STRTOLL
986 HAVE_STRTOD
987 HAVE_DECL_SETENV
988 HAVE_SETENV
989 HAVE_SECURE_GETENV
990 HAVE_RPMATCH
991 HAVE_REALPATH
992 HAVE_RANDOM_R
993 HAVE_RANDOM_H
994 HAVE_RANDOM
995 HAVE_PTSNAME_R
996 HAVE_PTSNAME
997 HAVE_POSIX_OPENPT
998 HAVE_MKSTEMPS
999 HAVE_MKSTEMP
1000 HAVE_MKOSTEMPS
1001 HAVE_MKOSTEMP
1002 HAVE_MKDTEMP
1003 HAVE_GRANTPT
1004 HAVE_GETSUBOPT
1005 HAVE_DECL_GETLOADAVG
1006 HAVE_CANONICALIZE_FILE_NAME
1007 HAVE_ATOLL
1008 HAVE__EXIT
1009 GNULIB_WCTOMB
1010 GNULIB_UNSETENV
1011 GNULIB_UNLOCKPT
1012 GNULIB_SYSTEM_POSIX
1013 GNULIB_STRTOULL
1014 GNULIB_STRTOLL
1015 GNULIB_STRTOD
1016 GNULIB_SETENV
1017 GNULIB_SECURE_GETENV
1018 GNULIB_RPMATCH
1019 GNULIB_REALPATH
1020 GNULIB_REALLOC_POSIX
1021 GNULIB_RANDOM_R
1022 GNULIB_RANDOM
1023 GNULIB_PUTENV
1024 GNULIB_PTSNAME_R
1025 GNULIB_PTSNAME
1026 GNULIB_POSIX_OPENPT
1027 GNULIB_MKSTEMPS
1028 GNULIB_MKSTEMP
1029 GNULIB_MKOSTEMPS
1030 GNULIB_MKOSTEMP
1031 GNULIB_MKDTEMP
1032 GNULIB_MBTOWC
1033 GNULIB_MALLOC_POSIX
1034 GNULIB_GRANTPT
1035 GNULIB_GETSUBOPT
1036 GNULIB_GETLOADAVG
1037 GNULIB_CANONICALIZE_FILE_NAME
1038 GNULIB_CALLOC_POSIX
1039 GNULIB_ATOLL
1040 GNULIB__EXIT
1041 REPLACE_UTIMENSAT
1042 REPLACE_STAT
1043 REPLACE_MKNOD
1044 REPLACE_MKFIFO
1045 REPLACE_MKDIR
1046 REPLACE_LSTAT
1047 REPLACE_FUTIMENS
1048 REPLACE_FSTATAT
1049 REPLACE_FSTAT
1050 HAVE_UTIMENSAT
1051 HAVE_MKNODAT
1052 HAVE_MKNOD
1053 HAVE_MKFIFOAT
1054 HAVE_MKFIFO
1055 HAVE_MKDIRAT
1056 HAVE_LSTAT
1057 HAVE_LCHMOD
1058 HAVE_FUTIMENS
1059 HAVE_FSTATAT
1060 HAVE_FCHMODAT
1061 GNULIB_UTIMENSAT
1062 GNULIB_STAT
1063 GNULIB_MKNODAT
1064 GNULIB_MKNOD
1065 GNULIB_MKFIFOAT
1066 GNULIB_MKFIFO
1067 GNULIB_MKDIRAT
1068 GNULIB_LSTAT
1069 GNULIB_LCHMOD
1070 GNULIB_FUTIMENS
1071 GNULIB_FSTATAT
1072 GNULIB_FSTAT
1073 GNULIB_FCHMODAT
1074 LIB_FDATASYNC
1075 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H
1076 NEXT_FCNTL_H
1077 REPLACE_OPENAT
1078 REPLACE_OPEN
1079 REPLACE_FCNTL
1080 HAVE_OPENAT
1081 HAVE_FCNTL
1082 GNULIB_OPENAT
1083 GNULIB_OPEN
1084 GNULIB_NONBLOCKING
1085 GNULIB_FCNTL
1086 GL_GENERATE_EXECINFO_H_FALSE
1087 GL_GENERATE_EXECINFO_H_TRUE
1088 LIB_EXECINFO
1089 EXECINFO_H
1090 EOVERFLOW_VALUE
1091 EOVERFLOW_HIDDEN
1092 ENOLINK_VALUE
1093 ENOLINK_HIDDEN
1094 EMULTIHOP_VALUE
1095 EMULTIHOP_HIDDEN
1096 GL_GENERATE_ERRNO_H_FALSE
1097 GL_GENERATE_ERRNO_H_TRUE
1098 ERRNO_H
1099 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H
1100 NEXT_ERRNO_H
1101 HAVE_DIRENT_H
1102 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H
1103 NEXT_DIRENT_H
1104 PRAGMA_COLUMNS
1105 PRAGMA_SYSTEM_HEADER
1106 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
1107 INCLUDE_NEXT
1108 REPLACE_FDOPENDIR
1109 REPLACE_DIRFD
1110 REPLACE_CLOSEDIR
1111 REPLACE_OPENDIR
1112 HAVE_ALPHASORT
1113 HAVE_SCANDIR
1114 HAVE_FDOPENDIR
1115 HAVE_DECL_FDOPENDIR
1116 HAVE_DECL_DIRFD
1117 HAVE_CLOSEDIR
1118 HAVE_REWINDDIR
1119 HAVE_READDIR
1120 HAVE_OPENDIR
1121 GNULIB_ALPHASORT
1122 GNULIB_SCANDIR
1123 GNULIB_FDOPENDIR
1124 GNULIB_DIRFD
1125 GNULIB_CLOSEDIR
1126 GNULIB_REWINDDIR
1127 GNULIB_READDIR
1128 GNULIB_OPENDIR
1129 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
1130 UNISTD_H_HAVE_WINSOCK2_H
1131 REPLACE_WRITE
1132 REPLACE_USLEEP
1133 REPLACE_UNLINKAT
1134 REPLACE_UNLINK
1135 REPLACE_TTYNAME_R
1136 REPLACE_SYMLINK
1137 REPLACE_SLEEP
1138 REPLACE_RMDIR
1139 REPLACE_READLINK
1140 REPLACE_READ
1141 REPLACE_PWRITE
1142 REPLACE_PREAD
1143 REPLACE_LSEEK
1144 REPLACE_LINKAT
1145 REPLACE_LINK
1146 REPLACE_LCHOWN
1147 REPLACE_ISATTY
1148 REPLACE_GETPAGESIZE
1149 REPLACE_GETGROUPS
1150 REPLACE_GETLOGIN_R
1151 REPLACE_GETDTABLESIZE
1152 REPLACE_GETDOMAINNAME
1153 REPLACE_GETCWD
1154 REPLACE_FTRUNCATE
1155 REPLACE_FCHOWNAT
1156 REPLACE_DUP2
1157 REPLACE_DUP
1158 REPLACE_CLOSE
1159 REPLACE_CHOWN
1160 HAVE_SYS_PARAM_H
1161 HAVE_OS_H
1162 HAVE_DECL_TTYNAME_R
1163 HAVE_DECL_SETHOSTNAME
1164 HAVE_DECL_GETUSERSHELL
1165 HAVE_DECL_GETPAGESIZE
1166 HAVE_DECL_GETLOGIN_R
1167 HAVE_DECL_GETDOMAINNAME
1168 HAVE_DECL_FDATASYNC
1169 HAVE_DECL_FCHDIR
1170 HAVE_DECL_ENVIRON
1171 HAVE_USLEEP
1172 HAVE_UNLINKAT
1173 HAVE_SYMLINKAT
1174 HAVE_SYMLINK
1175 HAVE_SLEEP
1176 HAVE_SETHOSTNAME
1177 HAVE_READLINKAT
1178 HAVE_READLINK
1179 HAVE_PWRITE
1180 HAVE_PREAD
1181 HAVE_PIPE2
1182 HAVE_PIPE
1183 HAVE_LINKAT
1184 HAVE_LINK
1185 HAVE_LCHOWN
1186 HAVE_GROUP_MEMBER
1187 HAVE_GETPAGESIZE
1188 HAVE_GETLOGIN
1189 HAVE_GETHOSTNAME
1190 HAVE_GETGROUPS
1191 HAVE_GETDTABLESIZE
1192 HAVE_FTRUNCATE
1193 HAVE_FSYNC
1194 HAVE_FDATASYNC
1195 HAVE_FCHOWNAT
1196 HAVE_FCHDIR
1197 HAVE_FACCESSAT
1198 HAVE_EUIDACCESS
1199 HAVE_DUP3
1200 HAVE_DUP2
1201 HAVE_CHOWN
1202 GNULIB_WRITE
1203 GNULIB_USLEEP
1204 GNULIB_UNLINKAT
1205 GNULIB_UNLINK
1206 GNULIB_UNISTD_H_SIGPIPE
1207 GNULIB_UNISTD_H_NONBLOCKING
1208 GNULIB_TTYNAME_R
1209 GNULIB_SYMLINKAT
1210 GNULIB_SYMLINK
1211 GNULIB_SLEEP
1212 GNULIB_SETHOSTNAME
1213 GNULIB_RMDIR
1214 GNULIB_READLINKAT
1215 GNULIB_READLINK
1216 GNULIB_READ
1217 GNULIB_PWRITE
1218 GNULIB_PREAD
1219 GNULIB_PIPE2
1220 GNULIB_PIPE
1221 GNULIB_LSEEK
1222 GNULIB_LINKAT
1223 GNULIB_LINK
1224 GNULIB_LCHOWN
1225 GNULIB_ISATTY
1226 GNULIB_GROUP_MEMBER
1227 GNULIB_GETUSERSHELL
1228 GNULIB_GETPAGESIZE
1229 GNULIB_GETLOGIN_R
1230 GNULIB_GETLOGIN
1231 GNULIB_GETHOSTNAME
1232 GNULIB_GETGROUPS
1233 GNULIB_GETDTABLESIZE
1234 GNULIB_GETDOMAINNAME
1235 GNULIB_GETCWD
1236 GNULIB_FTRUNCATE
1237 GNULIB_FSYNC
1238 GNULIB_FDATASYNC
1239 GNULIB_FCHOWNAT
1240 GNULIB_FCHDIR
1241 GNULIB_FACCESSAT
1242 GNULIB_EUIDACCESS
1243 GNULIB_ENVIRON
1244 GNULIB_DUP3
1245 GNULIB_DUP2
1246 GNULIB_DUP
1247 GNULIB_CLOSE
1248 GNULIB_CHOWN
1249 GNULIB_CHDIR
1250 LIB_CLOCK_GETTIME
1251 GL_GENERATE_BYTESWAP_H_FALSE
1252 GL_GENERATE_BYTESWAP_H_TRUE
1253 BYTESWAP_H
1254 GL_GENERATE_ALLOCA_H_FALSE
1255 GL_GENERATE_ALLOCA_H_TRUE
1256 ALLOCA_H
1257 ALLOCA
1258 GL_COND_LIBTOOL_FALSE
1259 GL_COND_LIBTOOL_TRUE
1260 POST_ALLOC_OBJ
1261 PRE_ALLOC_OBJ
1262 CYGWIN_OBJ
1263 RALLOC_OBJ
1264 OLDXMENU_DEPS
1265 LIBX_OTHER
1266 LIBXMENU
1267 OLDXMENU
1268 OLDXMENU_TARGET
1269 LIBXT_OTHER
1270 TOOLKIT_LIBW
1271 WIDGET_OBJ
1272 XOBJ
1273 XMENU_OBJ
1274 FONT_OBJ
1275 OTHER_FILES
1276 GNU_OBJC_CFLAGS
1277 ns_appsrc
1278 ns_appresdir
1279 ns_appbindir
1280 ns_appdir
1281 X_TOOLKIT_TYPE
1282 GNUSTEP_CFLAGS
1283 C_SWITCH_X_SITE
1284 LD_SWITCH_X_SITE
1285 gameuser
1286 gamedir
1287 bitmapdir
1288 etcdocdir
1289 archlibdir
1290 etcdir
1291 x_default_search_path
1292 lisppath
1293 locallisppath
1294 standardlisppath
1295 leimdir
1296 lispdir
1297 srcdir
1298 canonical
1299 configuration
1300 version
1301 copyright
1302 XGSELOBJ
1303 KRB4LIB
1304 DESLIB
1305 KRB5LIB
1306 CRYPTOLIB
1307 COM_ERRLIB
1308 LIBRESOLV
1309 LIBHESIOD
1310 TERMCAP_OBJ
1311 LIBS_TERMCAP
1312 BLESSMAIL_TARGET
1313 LIBS_MAIL
1314 liblockfile
1315 LIBXML2_LIBS
1316 LIBXML2_CFLAGS
1317 XINERAMA_LIBS
1318 XINERAMA_CFLAGS
1319 XRANDR_LIBS
1320 XRANDR_CFLAGS
1321 LIBXSM
1322 LIBGPM
1323 LIBGIF
1324 LIBTIFF
1325 LIBZ
1326 LIBPNG
1327 LIBJPEG
1328 LIBXPM
1329 M17N_FLT_LIBS
1330 M17N_FLT_CFLAGS
1331 LIBOTF_LIBS
1332 LIBOTF_CFLAGS
1333 FREETYPE_LIBS
1334 FREETYPE_CFLAGS
1335 XFT_LIBS
1336 XFT_CFLAGS
1337 FONTCONFIG_LIBS
1338 FONTCONFIG_CFLAGS
1339 LIBXMU
1340 LIBXTR6
1341 NOTIFY_OBJ
1342 GFILENOTIFY_LIBS
1343 GFILENOTIFY_CFLAGS
1344 LIBGNUTLS_LIBS
1345 LIBGNUTLS_CFLAGS
1346 LIBSELINUX_LIBS
1347 SETTINGS_LIBS
1348 SETTINGS_CFLAGS
1349 GOBJECT_LIBS
1350 GOBJECT_CFLAGS
1351 GCONF_LIBS
1352 GCONF_CFLAGS
1353 GSETTINGS_LIBS
1354 GSETTINGS_CFLAGS
1355 DBUS_OBJ
1356 DBUS_LIBS
1357 DBUS_CFLAGS
1358 GTK_OBJ
1359 GTK_LIBS
1360 GTK_CFLAGS
1361 IMAGEMAGICK_LIBS
1362 IMAGEMAGICK_CFLAGS
1363 RSVG_LIBS
1364 RSVG_CFLAGS
1365 LIB_PTHREAD
1366 VMLIMIT_OBJ
1367 GMALLOC_OBJ
1368 HAVE_XSERVER
1369 XARGS_LIMIT
1370 NTLIB
1371 LIB_WSOCK32
1372 LIBS_ECLIENT
1373 CM_OBJ
1374 NTDIR
1375 FIRSTFILE_OBJ
1376 W32_RES_LINK
1377 CLIENTW
1378 CLIENTRES
1379 UPDATE_MANIFEST
1380 EMACS_MANIFEST
1381 EMACSRES
1382 W32_LIBS
1383 W32_OBJ
1384 WINDRES
1385 NS_OBJC_OBJ
1386 NS_OBJ
1387 ns_self_contained
1388 INSTALL_ARCH_INDEP_EXTRA
1389 LIBS_GNUSTEP
1390 LD_SWITCH_X_SITE_RPATH
1391 XMKMF
1392 DEPFLAGS
1393 MKDEPDIR
1394 CFLAGS_SOUND
1395 ALSA_LIBS
1396 ALSA_CFLAGS
1397 LIBSOUND
1398 PKG_CONFIG
1399 LIB_MATH
1400 LIBS_SYSTEM
1401 C_SWITCH_SYSTEM
1402 UNEXEC_OBJ
1403 C_SWITCH_MACHINE
1404 LD_SWITCH_SYSTEM
1405 CANNOT_DUMP
1406 DOCMISC_W32
1407 INFO_OPTS
1408 INFO_EXT
1409 HAVE_MAKEINFO
1410 PAXCTL
1411 GZIP_PROG
1412 INSTALL_INFO
1413 LN_S_FILEONLY
1414 GNULIB_WARN_CFLAGS
1415 WERROR_CFLAGS
1416 WARN_CFLAGS
1417 RANLIB
1418 ARFLAGS
1419 AR
1420 EGREP
1421 GREP
1422 CPP
1423 BUILDING_FOR_WINDOWSNT_FALSE
1424 BUILDING_FOR_WINDOWSNT_TRUE
1425 am__fastdepCC_FALSE
1426 am__fastdepCC_TRUE
1427 CCDEPMODE
1428 AMDEPBACKSLASH
1429 AMDEP_FALSE
1430 AMDEP_TRUE
1431 am__quote
1432 am__include
1433 DEPDIR
1434 OBJEXT
1435 EXEEXT
1436 ac_ct_CC
1437 CPPFLAGS
1438 LDFLAGS
1439 CFLAGS
1440 CC
1441 host_os
1442 host_vendor
1443 host_cpu
1444 host
1445 build_os
1446 build_vendor
1447 build_cpu
1448 build
1449 PROFILING_CFLAGS
1450 cache_file
1451 am__untar
1452 am__tar
1453 AMTAR
1454 am__leading_dot
1455 SET_MAKE
1456 AWK
1457 mkdir_p
1458 MKDIR_P
1459 INSTALL_STRIP_PROGRAM
1460 STRIP
1461 install_sh
1462 MAKEINFO
1463 AUTOHEADER
1464 AUTOMAKE
1465 AUTOCONF
1466 ACLOCAL
1467 VERSION
1468 PACKAGE
1469 CYGPATH_W
1470 am__isrc
1471 INSTALL_DATA
1472 INSTALL_SCRIPT
1473 INSTALL_PROGRAM
1474 target_alias
1475 host_alias
1476 build_alias
1477 LIBS
1478 ECHO_T
1479 ECHO_N
1480 ECHO_C
1481 DEFS
1482 mandir
1483 localedir
1484 libdir
1485 psdir
1486 pdfdir
1487 dvidir
1488 htmldir
1489 infodir
1490 docdir
1491 oldincludedir
1492 includedir
1493 localstatedir
1494 sharedstatedir
1495 sysconfdir
1496 datadir
1497 datarootdir
1498 libexecdir
1499 sbindir
1500 bindir
1501 program_transform_name
1502 prefix
1503 exec_prefix
1504 PACKAGE_URL
1505 PACKAGE_BUGREPORT
1506 PACKAGE_STRING
1507 PACKAGE_VERSION
1508 PACKAGE_TARNAME
1509 PACKAGE_NAME
1510 PATH_SEPARATOR
1511 SHELL'
1512 ac_subst_files='deps_frag
1513 lisp_frag'
1514 ac_user_opts='
1515 enable_option_checking
1516 with_all
1517 with_pop
1518 with_kerberos
1519 with_kerberos5
1520 with_hesiod
1521 with_mmdf
1522 with_mail_unlink
1523 with_mailhost
1524 with_sound
1525 with_x_toolkit
1526 with_wide_int
1527 with_xpm
1528 with_jpeg
1529 with_tiff
1530 with_gif
1531 with_png
1532 with_rsvg
1533 with_xml2
1534 with_imagemagick
1535 with_xft
1536 with_libotf
1537 with_m17n_flt
1538 with_toolkit_scroll_bars
1539 with_xaw3d
1540 with_xim
1541 with_ns
1542 with_w32
1543 with_gpm
1544 with_dbus
1545 with_gconf
1546 with_gsettings
1547 with_selinux
1548 with_gnutls
1549 with_zlib
1550 with_file_notification
1551 with_makeinfo
1552 with_compress_install
1553 with_pkg_config_prog
1554 with_gameuser
1555 with_gnustep_conf
1556 enable_ns_self_contained
1557 enable_locallisppath
1558 enable_checking
1559 enable_check_lisp_object_type
1560 enable_profiling
1561 enable_autodepend
1562 enable_gtk_deprecation_warnings
1563 enable_dependency_tracking
1564 enable_largefile
1565 enable_gcc_warnings
1566 enable_link_time_optimization
1567 with_x
1568 enable_acl
1569 '
1570 ac_precious_vars='build_alias
1571 host_alias
1572 target_alias
1573 CC
1574 CFLAGS
1575 LDFLAGS
1576 LIBS
1577 CPPFLAGS
1578 CPP
1579 XMKMF'
1580
1581
1582 # Initialize some variables set by options.
1583 ac_init_help=
1584 ac_init_version=false
1585 ac_unrecognized_opts=
1586 ac_unrecognized_sep=
1587 # The variables have the same names as the options, with
1588 # dashes changed to underlines.
1589 cache_file=/dev/null
1590 exec_prefix=NONE
1591 no_create=
1592 no_recursion=
1593 prefix=NONE
1594 program_prefix=NONE
1595 program_suffix=NONE
1596 program_transform_name=s,x,x,
1597 silent=
1598 site=
1599 srcdir=
1600 verbose=
1601 x_includes=NONE
1602 x_libraries=NONE
1603
1604 # Installation directory options.
1605 # These are left unexpanded so users can "make install exec_prefix=/foo"
1606 # and all the variables that are supposed to be based on exec_prefix
1607 # by default will actually change.
1608 # Use braces instead of parens because sh, perl, etc. also accept them.
1609 # (The list follows the same order as the GNU Coding Standards.)
1610 bindir='${exec_prefix}/bin'
1611 sbindir='${exec_prefix}/sbin'
1612 libexecdir='${exec_prefix}/libexec'
1613 datarootdir='${prefix}/share'
1614 datadir='${datarootdir}'
1615 sysconfdir='${prefix}/etc'
1616 sharedstatedir='${prefix}/com'
1617 localstatedir='${prefix}/var'
1618 includedir='${prefix}/include'
1619 oldincludedir='/usr/include'
1620 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1621 infodir='${datarootdir}/info'
1622 htmldir='${docdir}'
1623 dvidir='${docdir}'
1624 pdfdir='${docdir}'
1625 psdir='${docdir}'
1626 libdir='${exec_prefix}/lib'
1627 localedir='${datarootdir}/locale'
1628 mandir='${datarootdir}/man'
1629
1630 ac_prev=
1631 ac_dashdash=
1632 for ac_option
1633 do
1634 # If the previous option needs an argument, assign it.
1635 if test -n "$ac_prev"; then
1636 eval $ac_prev=\$ac_option
1637 ac_prev=
1638 continue
1639 fi
1640
1641 case $ac_option in
1642 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1643 *) ac_optarg=yes ;;
1644 esac
1645
1646 # Accept the important Cygnus configure options, so we can diagnose typos.
1647
1648 case $ac_dashdash$ac_option in
1649 --)
1650 ac_dashdash=yes ;;
1651
1652 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1653 ac_prev=bindir ;;
1654 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1655 bindir=$ac_optarg ;;
1656
1657 -build | --build | --buil | --bui | --bu)
1658 ac_prev=build_alias ;;
1659 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1660 build_alias=$ac_optarg ;;
1661
1662 -cache-file | --cache-file | --cache-fil | --cache-fi \
1663 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1664 ac_prev=cache_file ;;
1665 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1666 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1667 cache_file=$ac_optarg ;;
1668
1669 --config-cache | -C)
1670 cache_file=config.cache ;;
1671
1672 -datadir | --datadir | --datadi | --datad)
1673 ac_prev=datadir ;;
1674 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1675 datadir=$ac_optarg ;;
1676
1677 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1678 | --dataroo | --dataro | --datar)
1679 ac_prev=datarootdir ;;
1680 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1681 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1682 datarootdir=$ac_optarg ;;
1683
1684 -disable-* | --disable-*)
1685 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1686 # Reject names that are not valid shell variable names.
1687 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1688 as_fn_error "invalid feature name: $ac_useropt"
1689 ac_useropt_orig=$ac_useropt
1690 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1691 case $ac_user_opts in
1692 *"
1693 "enable_$ac_useropt"
1694 "*) ;;
1695 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1696 ac_unrecognized_sep=', ';;
1697 esac
1698 eval enable_$ac_useropt=no ;;
1699
1700 -docdir | --docdir | --docdi | --doc | --do)
1701 ac_prev=docdir ;;
1702 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1703 docdir=$ac_optarg ;;
1704
1705 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1706 ac_prev=dvidir ;;
1707 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1708 dvidir=$ac_optarg ;;
1709
1710 -enable-* | --enable-*)
1711 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1712 # Reject names that are not valid shell variable names.
1713 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1714 as_fn_error "invalid feature name: $ac_useropt"
1715 ac_useropt_orig=$ac_useropt
1716 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1717 case $ac_user_opts in
1718 *"
1719 "enable_$ac_useropt"
1720 "*) ;;
1721 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1722 ac_unrecognized_sep=', ';;
1723 esac
1724 eval enable_$ac_useropt=\$ac_optarg ;;
1725
1726 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1727 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1728 | --exec | --exe | --ex)
1729 ac_prev=exec_prefix ;;
1730 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1731 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1732 | --exec=* | --exe=* | --ex=*)
1733 exec_prefix=$ac_optarg ;;
1734
1735 -gas | --gas | --ga | --g)
1736 # Obsolete; use --with-gas.
1737 with_gas=yes ;;
1738
1739 -help | --help | --hel | --he | -h)
1740 ac_init_help=long ;;
1741 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1742 ac_init_help=recursive ;;
1743 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1744 ac_init_help=short ;;
1745
1746 -host | --host | --hos | --ho)
1747 ac_prev=host_alias ;;
1748 -host=* | --host=* | --hos=* | --ho=*)
1749 host_alias=$ac_optarg ;;
1750
1751 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1752 ac_prev=htmldir ;;
1753 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1754 | --ht=*)
1755 htmldir=$ac_optarg ;;
1756
1757 -includedir | --includedir | --includedi | --included | --include \
1758 | --includ | --inclu | --incl | --inc)
1759 ac_prev=includedir ;;
1760 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1761 | --includ=* | --inclu=* | --incl=* | --inc=*)
1762 includedir=$ac_optarg ;;
1763
1764 -infodir | --infodir | --infodi | --infod | --info | --inf)
1765 ac_prev=infodir ;;
1766 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1767 infodir=$ac_optarg ;;
1768
1769 -libdir | --libdir | --libdi | --libd)
1770 ac_prev=libdir ;;
1771 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1772 libdir=$ac_optarg ;;
1773
1774 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1775 | --libexe | --libex | --libe)
1776 ac_prev=libexecdir ;;
1777 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1778 | --libexe=* | --libex=* | --libe=*)
1779 libexecdir=$ac_optarg ;;
1780
1781 -localedir | --localedir | --localedi | --localed | --locale)
1782 ac_prev=localedir ;;
1783 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1784 localedir=$ac_optarg ;;
1785
1786 -localstatedir | --localstatedir | --localstatedi | --localstated \
1787 | --localstate | --localstat | --localsta | --localst | --locals)
1788 ac_prev=localstatedir ;;
1789 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1790 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1791 localstatedir=$ac_optarg ;;
1792
1793 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1794 ac_prev=mandir ;;
1795 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1796 mandir=$ac_optarg ;;
1797
1798 -nfp | --nfp | --nf)
1799 # Obsolete; use --without-fp.
1800 with_fp=no ;;
1801
1802 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1803 | --no-cr | --no-c | -n)
1804 no_create=yes ;;
1805
1806 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1807 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1808 no_recursion=yes ;;
1809
1810 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1811 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1812 | --oldin | --oldi | --old | --ol | --o)
1813 ac_prev=oldincludedir ;;
1814 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1815 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1816 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1817 oldincludedir=$ac_optarg ;;
1818
1819 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1820 ac_prev=prefix ;;
1821 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1822 prefix=$ac_optarg ;;
1823
1824 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1825 | --program-pre | --program-pr | --program-p)
1826 ac_prev=program_prefix ;;
1827 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1828 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1829 program_prefix=$ac_optarg ;;
1830
1831 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1832 | --program-suf | --program-su | --program-s)
1833 ac_prev=program_suffix ;;
1834 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1835 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1836 program_suffix=$ac_optarg ;;
1837
1838 -program-transform-name | --program-transform-name \
1839 | --program-transform-nam | --program-transform-na \
1840 | --program-transform-n | --program-transform- \
1841 | --program-transform | --program-transfor \
1842 | --program-transfo | --program-transf \
1843 | --program-trans | --program-tran \
1844 | --progr-tra | --program-tr | --program-t)
1845 ac_prev=program_transform_name ;;
1846 -program-transform-name=* | --program-transform-name=* \
1847 | --program-transform-nam=* | --program-transform-na=* \
1848 | --program-transform-n=* | --program-transform-=* \
1849 | --program-transform=* | --program-transfor=* \
1850 | --program-transfo=* | --program-transf=* \
1851 | --program-trans=* | --program-tran=* \
1852 | --progr-tra=* | --program-tr=* | --program-t=*)
1853 program_transform_name=$ac_optarg ;;
1854
1855 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1856 ac_prev=pdfdir ;;
1857 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1858 pdfdir=$ac_optarg ;;
1859
1860 -psdir | --psdir | --psdi | --psd | --ps)
1861 ac_prev=psdir ;;
1862 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1863 psdir=$ac_optarg ;;
1864
1865 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1866 | -silent | --silent | --silen | --sile | --sil)
1867 silent=yes ;;
1868
1869 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1870 ac_prev=sbindir ;;
1871 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1872 | --sbi=* | --sb=*)
1873 sbindir=$ac_optarg ;;
1874
1875 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1876 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1877 | --sharedst | --shareds | --shared | --share | --shar \
1878 | --sha | --sh)
1879 ac_prev=sharedstatedir ;;
1880 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1881 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1882 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1883 | --sha=* | --sh=*)
1884 sharedstatedir=$ac_optarg ;;
1885
1886 -site | --site | --sit)
1887 ac_prev=site ;;
1888 -site=* | --site=* | --sit=*)
1889 site=$ac_optarg ;;
1890
1891 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1892 ac_prev=srcdir ;;
1893 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1894 srcdir=$ac_optarg ;;
1895
1896 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1897 | --syscon | --sysco | --sysc | --sys | --sy)
1898 ac_prev=sysconfdir ;;
1899 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1900 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1901 sysconfdir=$ac_optarg ;;
1902
1903 -target | --target | --targe | --targ | --tar | --ta | --t)
1904 ac_prev=target_alias ;;
1905 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1906 target_alias=$ac_optarg ;;
1907
1908 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1909 verbose=yes ;;
1910
1911 -version | --version | --versio | --versi | --vers | -V)
1912 ac_init_version=: ;;
1913
1914 -with-* | --with-*)
1915 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1916 # Reject names that are not valid shell variable names.
1917 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1918 as_fn_error "invalid package name: $ac_useropt"
1919 ac_useropt_orig=$ac_useropt
1920 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1921 case $ac_user_opts in
1922 *"
1923 "with_$ac_useropt"
1924 "*) ;;
1925 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1926 ac_unrecognized_sep=', ';;
1927 esac
1928 eval with_$ac_useropt=\$ac_optarg ;;
1929
1930 -without-* | --without-*)
1931 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1932 # Reject names that are not valid shell variable names.
1933 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1934 as_fn_error "invalid package name: $ac_useropt"
1935 ac_useropt_orig=$ac_useropt
1936 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1937 case $ac_user_opts in
1938 *"
1939 "with_$ac_useropt"
1940 "*) ;;
1941 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1942 ac_unrecognized_sep=', ';;
1943 esac
1944 eval with_$ac_useropt=no ;;
1945
1946 --x)
1947 # Obsolete; use --with-x.
1948 with_x=yes ;;
1949
1950 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1951 | --x-incl | --x-inc | --x-in | --x-i)
1952 ac_prev=x_includes ;;
1953 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1954 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1955 x_includes=$ac_optarg ;;
1956
1957 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1958 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1959 ac_prev=x_libraries ;;
1960 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1961 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1962 x_libraries=$ac_optarg ;;
1963
1964 -*) as_fn_error "unrecognized option: \`$ac_option'
1965 Try \`$0 --help' for more information."
1966 ;;
1967
1968 *=*)
1969 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1970 # Reject names that are not valid shell variable names.
1971 case $ac_envvar in #(
1972 '' | [0-9]* | *[!_$as_cr_alnum]* )
1973 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1974 esac
1975 eval $ac_envvar=\$ac_optarg
1976 export $ac_envvar ;;
1977
1978 *)
1979 # FIXME: should be removed in autoconf 3.0.
1980 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1981 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1982 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1983 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1984 ;;
1985
1986 esac
1987 done
1988
1989 if test -n "$ac_prev"; then
1990 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1991 as_fn_error "missing argument to $ac_option"
1992 fi
1993
1994 if test -n "$ac_unrecognized_opts"; then
1995 case $enable_option_checking in
1996 no) ;;
1997 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1998 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1999 esac
2000 fi
2001
2002 # Check all directory arguments for consistency.
2003 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
2004 datadir sysconfdir sharedstatedir localstatedir includedir \
2005 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
2006 libdir localedir mandir
2007 do
2008 eval ac_val=\$$ac_var
2009 # Remove trailing slashes.
2010 case $ac_val in
2011 */ )
2012 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
2013 eval $ac_var=\$ac_val;;
2014 esac
2015 # Be sure to have absolute directory names.
2016 case $ac_val in
2017 [\\/$]* | ?:[\\/]* ) continue;;
2018 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
2019 esac
2020 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
2021 done
2022
2023 # There might be people who depend on the old broken behavior: `$host'
2024 # used to hold the argument of --host etc.
2025 # FIXME: To remove some day.
2026 build=$build_alias
2027 host=$host_alias
2028 target=$target_alias
2029
2030 # FIXME: To remove some day.
2031 if test "x$host_alias" != x; then
2032 if test "x$build_alias" = x; then
2033 cross_compiling=maybe
2034 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
2035 If a cross compiler is detected then cross compile mode will be used." >&2
2036 elif test "x$build_alias" != "x$host_alias"; then
2037 cross_compiling=yes
2038 fi
2039 fi
2040
2041 ac_tool_prefix=
2042 test -n "$host_alias" && ac_tool_prefix=$host_alias-
2043
2044 test "$silent" = yes && exec 6>/dev/null
2045
2046
2047 ac_pwd=`pwd` && test -n "$ac_pwd" &&
2048 ac_ls_di=`ls -di .` &&
2049 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
2050 as_fn_error "working directory cannot be determined"
2051 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
2052 as_fn_error "pwd does not report name of working directory"
2053
2054
2055 # Find the source files, if location was not specified.
2056 if test -z "$srcdir"; then
2057 ac_srcdir_defaulted=yes
2058 # Try the directory containing this script, then the parent directory.
2059 ac_confdir=`$as_dirname -- "$as_myself" ||
2060 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
2061 X"$as_myself" : 'X\(//\)[^/]' \| \
2062 X"$as_myself" : 'X\(//\)$' \| \
2063 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
2064 $as_echo X"$as_myself" |
2065 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
2066 s//\1/
2067 q
2068 }
2069 /^X\(\/\/\)[^/].*/{
2070 s//\1/
2071 q
2072 }
2073 /^X\(\/\/\)$/{
2074 s//\1/
2075 q
2076 }
2077 /^X\(\/\).*/{
2078 s//\1/
2079 q
2080 }
2081 s/.*/./; q'`
2082 srcdir=$ac_confdir
2083 if test ! -r "$srcdir/$ac_unique_file"; then
2084 srcdir=..
2085 fi
2086 else
2087 ac_srcdir_defaulted=no
2088 fi
2089 if test ! -r "$srcdir/$ac_unique_file"; then
2090 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
2091 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
2092 fi
2093 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
2094 ac_abs_confdir=`(
2095 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
2096 pwd)`
2097 # When building in place, set srcdir=.
2098 if test "$ac_abs_confdir" = "$ac_pwd"; then
2099 srcdir=.
2100 fi
2101 # Remove unnecessary trailing slashes from srcdir.
2102 # Double slashes in file names in object file debugging info
2103 # mess up M-x gdb in Emacs.
2104 case $srcdir in
2105 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
2106 esac
2107 for ac_var in $ac_precious_vars; do
2108 eval ac_env_${ac_var}_set=\${${ac_var}+set}
2109 eval ac_env_${ac_var}_value=\$${ac_var}
2110 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
2111 eval ac_cv_env_${ac_var}_value=\$${ac_var}
2112 done
2113
2114 #
2115 # Report the --help message.
2116 #
2117 if test "$ac_init_help" = "long"; then
2118 # Omit some internal or obsolete options to make the list less imposing.
2119 # This message is too long to be a string in the A/UX 3.1 sh.
2120 cat <<_ACEOF
2121 \`configure' configures emacs 24.3.50 to adapt to many kinds of systems.
2122
2123 Usage: $0 [OPTION]... [VAR=VALUE]...
2124
2125 To assign environment variables (e.g., CC, CFLAGS...), specify them as
2126 VAR=VALUE. See below for descriptions of some of the useful variables.
2127
2128 Defaults for the options are specified in brackets.
2129
2130 Configuration:
2131 -h, --help display this help and exit
2132 --help=short display options specific to this package
2133 --help=recursive display the short help of all the included packages
2134 -V, --version display version information and exit
2135 -q, --quiet, --silent do not print \`checking...' messages
2136 --cache-file=FILE cache test results in FILE [disabled]
2137 -C, --config-cache alias for \`--cache-file=config.cache'
2138 -n, --no-create do not create output files
2139 --srcdir=DIR find the sources in DIR [configure dir or \`..']
2140
2141 Installation directories:
2142 --prefix=PREFIX install architecture-independent files in PREFIX
2143 [$ac_default_prefix]
2144 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
2145 [PREFIX]
2146
2147 By default, \`make install' will install all the files in
2148 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
2149 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
2150 for instance \`--prefix=\$HOME'.
2151
2152 For better control, use the options below.
2153
2154 Fine tuning of the installation directories:
2155 --bindir=DIR user executables [EPREFIX/bin]
2156 --sbindir=DIR system admin executables [EPREFIX/sbin]
2157 --libexecdir=DIR program executables [EPREFIX/libexec]
2158 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
2159 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
2160 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
2161 --libdir=DIR object code libraries [EPREFIX/lib]
2162 --includedir=DIR C header files [PREFIX/include]
2163 --oldincludedir=DIR C header files for non-gcc [/usr/include]
2164 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
2165 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
2166 --infodir=DIR info documentation [DATAROOTDIR/info]
2167 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
2168 --mandir=DIR man documentation [DATAROOTDIR/man]
2169 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
2170 --htmldir=DIR html documentation [DOCDIR]
2171 --dvidir=DIR dvi documentation [DOCDIR]
2172 --pdfdir=DIR pdf documentation [DOCDIR]
2173 --psdir=DIR ps documentation [DOCDIR]
2174 _ACEOF
2175
2176 cat <<\_ACEOF
2177
2178 Program names:
2179 --program-prefix=PREFIX prepend PREFIX to installed program names
2180 --program-suffix=SUFFIX append SUFFIX to installed program names
2181 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
2182
2183 X features:
2184 --x-includes=DIR X include files are in DIR
2185 --x-libraries=DIR X library files are in DIR
2186
2187 System types:
2188 --build=BUILD configure for building on BUILD [guessed]
2189 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2190 _ACEOF
2191 fi
2192
2193 if test -n "$ac_init_help"; then
2194 case $ac_init_help in
2195 short | recursive ) echo "Configuration of emacs 24.3.50:";;
2196 esac
2197 cat <<\_ACEOF
2198
2199 Optional Features:
2200 --disable-option-checking ignore unrecognized --enable/--with options
2201 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2202 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2203 --disable-ns-self-contained
2204 disable self contained build under NeXTstep
2205 --enable-locallisppath=PATH
2206 directories Emacs should search for lisp files
2207 specific to this site
2208 --enable-checking[=LIST]
2209 enable expensive run-time checks. With LIST, enable
2210 only specific categories of checks. Categories are:
2211 all,yes,no. Flags are: stringbytes, stringoverrun,
2212 stringfreelist, xmallocoverrun, conslist, glyphs
2213 --enable-check-lisp-object-type
2214 enable compile time checks for the Lisp_Object data
2215 type. This is useful for development for catching
2216 certain types of bugs.
2217 --enable-profiling build emacs with low-level, gprof profiling support.
2218 Mainly useful for debugging Emacs itself. May not
2219 work on all platforms. Stops profiler.el working.
2220 --enable-autodepend automatically generate dependencies to .h-files.
2221 Requires GNU Make and Gcc. Enabled if GNU Make and
2222 Gcc is found
2223 --enable-gtk-deprecation-warnings
2224 Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
2225 --disable-dependency-tracking speeds up one-time build
2226 --enable-dependency-tracking do not reject slow dependency extractors
2227 --disable-largefile omit support for large files
2228 --enable-gcc-warnings turn on lots of GCC warnings/errors. This is
2229 intended for developers, and may generate false
2230 alarms when used with older or non-GNU development
2231 tools.
2232 --enable-link-time-optimization
2233 build emacs with link-time optimization. This is
2234 supported only for GCC since 4.5.0.
2235 --disable-acl do not support ACLs
2236
2237 Optional Packages:
2238 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2239 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2240 --without-all omit almost all features and build small executable
2241 with minimal dependencies
2242 --without-pop don't support POP mail retrieval with movemail
2243 --with-kerberos support Kerberos-authenticated POP
2244 --with-kerberos5 support Kerberos version 5 authenticated POP
2245 --with-hesiod support Hesiod to get the POP server host
2246 --with-mmdf support MMDF mailboxes
2247 --with-mail-unlink unlink, rather than empty, mail spool after reading
2248 --with-mailhost=HOSTNAME
2249 string giving default POP mail host
2250 --with-sound=VALUE compile with sound support (VALUE one of: yes, alsa,
2251 oss, bsd-ossaudio, no; default yes). Only for
2252 GNU/Linux, FreeBSD, NetBSD, MinGW.
2253 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2254 gtk3, lucid or athena, motif, no)
2255 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2256 --without-xpm don't compile with XPM image support
2257 --without-jpeg don't compile with JPEG image support
2258 --without-tiff don't compile with TIFF image support
2259 --without-gif don't compile with GIF image support
2260 --without-png don't compile with PNG image support
2261 --without-rsvg don't compile with SVG image support
2262 --without-xml2 don't compile with XML parsing support
2263 --without-imagemagick don't compile with ImageMagick image support
2264 --without-xft don't use XFT for anti aliased fonts
2265 --without-libotf don't use libotf for OpenType font support
2266 --without-m17n-flt don't use m17n-flt for text shaping
2267 --without-toolkit-scroll-bars
2268 don't use Motif or Xaw3d scroll bars
2269 --without-xaw3d don't use Xaw3d
2270 --without-xim don't use X11 XIM
2271 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2272 --with-w32 use native MS Windows GUI in a Cygwin build
2273 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2274 console
2275 --without-dbus don't compile with D-Bus support
2276 --without-gconf don't compile with GConf support
2277 --without-gsettings don't compile with GSettings support
2278 --without-selinux don't compile with SELinux support
2279 --without-gnutls don't use -lgnutls for SSL/TLS support
2280 --without-zlib don't compile with zlib decompression support
2281 --with-file-notification=LIB
2282 use a file notification library (LIB one of: yes,
2283 gfile, inotify, w32, no)
2284 --without-makeinfo don't require makeinfo for building manuals
2285 --without-compress-install
2286 don't compress some files (.el, .info, etc.) when
2287 installing. Equivalent to: make GZIP_PROG= install
2288 --with-pkg-config-prog=FILENAME
2289 file name of pkg-config for finding GTK and librsvg
2290 --with-gameuser=USER user for shared game score files
2291 --with-gnustep-conf=FILENAME
2292 name of GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2293 or /etc/GNUstep/GNUstep.conf
2294 --with-x use the X Window System
2295
2296 Some influential environment variables:
2297 CC C compiler command
2298 CFLAGS C compiler flags
2299 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2300 nonstandard directory <lib dir>
2301 LIBS libraries to pass to the linker, e.g. -l<library>
2302 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2303 you have headers in a nonstandard directory <include dir>
2304 CPP C preprocessor
2305 XMKMF Path to xmkmf, Makefile generator for X Window System
2306
2307 Use these variables to override the choices made by `configure' or to help
2308 it to find libraries and programs with nonstandard names/locations.
2309
2310 Report bugs to the package provider.
2311 _ACEOF
2312 ac_status=$?
2313 fi
2314
2315 if test "$ac_init_help" = "recursive"; then
2316 # If there are subdirs, report their specific --help.
2317 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2318 test -d "$ac_dir" ||
2319 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2320 continue
2321 ac_builddir=.
2322
2323 case "$ac_dir" in
2324 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2325 *)
2326 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2327 # A ".." for each directory in $ac_dir_suffix.
2328 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2329 case $ac_top_builddir_sub in
2330 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2331 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2332 esac ;;
2333 esac
2334 ac_abs_top_builddir=$ac_pwd
2335 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2336 # for backward compatibility:
2337 ac_top_builddir=$ac_top_build_prefix
2338
2339 case $srcdir in
2340 .) # We are building in place.
2341 ac_srcdir=.
2342 ac_top_srcdir=$ac_top_builddir_sub
2343 ac_abs_top_srcdir=$ac_pwd ;;
2344 [\\/]* | ?:[\\/]* ) # Absolute name.
2345 ac_srcdir=$srcdir$ac_dir_suffix;
2346 ac_top_srcdir=$srcdir
2347 ac_abs_top_srcdir=$srcdir ;;
2348 *) # Relative name.
2349 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2350 ac_top_srcdir=$ac_top_build_prefix$srcdir
2351 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2352 esac
2353 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2354
2355 cd "$ac_dir" || { ac_status=$?; continue; }
2356 # Check for guested configure.
2357 if test -f "$ac_srcdir/configure.gnu"; then
2358 echo &&
2359 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2360 elif test -f "$ac_srcdir/configure"; then
2361 echo &&
2362 $SHELL "$ac_srcdir/configure" --help=recursive
2363 else
2364 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2365 fi || ac_status=$?
2366 cd "$ac_pwd" || { ac_status=$?; break; }
2367 done
2368 fi
2369
2370 test -n "$ac_init_help" && exit $ac_status
2371 if $ac_init_version; then
2372 cat <<\_ACEOF
2373 emacs configure 24.3.50
2374 generated by GNU Autoconf 2.65
2375
2376 Copyright (C) 2009 Free Software Foundation, Inc.
2377 This configure script is free software; the Free Software Foundation
2378 gives unlimited permission to copy, distribute and modify it.
2379 _ACEOF
2380 exit
2381 fi
2382
2383 ## ------------------------ ##
2384 ## Autoconf initialization. ##
2385 ## ------------------------ ##
2386
2387 # ac_fn_c_try_compile LINENO
2388 # --------------------------
2389 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2390 ac_fn_c_try_compile ()
2391 {
2392 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2393 rm -f conftest.$ac_objext
2394 if { { ac_try="$ac_compile"
2395 case "(($ac_try" in
2396 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2397 *) ac_try_echo=$ac_try;;
2398 esac
2399 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2400 $as_echo "$ac_try_echo"; } >&5
2401 (eval "$ac_compile") 2>conftest.err
2402 ac_status=$?
2403 if test -s conftest.err; then
2404 grep -v '^ *+' conftest.err >conftest.er1
2405 cat conftest.er1 >&5
2406 mv -f conftest.er1 conftest.err
2407 fi
2408 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2409 test $ac_status = 0; } && {
2410 test -z "$ac_c_werror_flag" ||
2411 test ! -s conftest.err
2412 } && test -s conftest.$ac_objext; then :
2413 ac_retval=0
2414 else
2415 $as_echo "$as_me: failed program was:" >&5
2416 sed 's/^/| /' conftest.$ac_ext >&5
2417
2418 ac_retval=1
2419 fi
2420 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2421 as_fn_set_status $ac_retval
2422
2423 } # ac_fn_c_try_compile
2424
2425 # ac_fn_c_try_cpp LINENO
2426 # ----------------------
2427 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2428 ac_fn_c_try_cpp ()
2429 {
2430 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2431 if { { ac_try="$ac_cpp conftest.$ac_ext"
2432 case "(($ac_try" in
2433 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2434 *) ac_try_echo=$ac_try;;
2435 esac
2436 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2437 $as_echo "$ac_try_echo"; } >&5
2438 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2439 ac_status=$?
2440 if test -s conftest.err; then
2441 grep -v '^ *+' conftest.err >conftest.er1
2442 cat conftest.er1 >&5
2443 mv -f conftest.er1 conftest.err
2444 fi
2445 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2446 test $ac_status = 0; } >/dev/null && {
2447 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2448 test ! -s conftest.err
2449 }; then :
2450 ac_retval=0
2451 else
2452 $as_echo "$as_me: failed program was:" >&5
2453 sed 's/^/| /' conftest.$ac_ext >&5
2454
2455 ac_retval=1
2456 fi
2457 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2458 as_fn_set_status $ac_retval
2459
2460 } # ac_fn_c_try_cpp
2461
2462 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2463 # -------------------------------------------------------
2464 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2465 # the include files in INCLUDES and setting the cache variable VAR
2466 # accordingly.
2467 ac_fn_c_check_header_mongrel ()
2468 {
2469 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2470 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2472 $as_echo_n "checking for $2... " >&6; }
2473 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2474 $as_echo_n "(cached) " >&6
2475 fi
2476 eval ac_res=\$$3
2477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2478 $as_echo "$ac_res" >&6; }
2479 else
2480 # Is the header compilable?
2481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2482 $as_echo_n "checking $2 usability... " >&6; }
2483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2484 /* end confdefs.h. */
2485 $4
2486 #include <$2>
2487 _ACEOF
2488 if ac_fn_c_try_compile "$LINENO"; then :
2489 ac_header_compiler=yes
2490 else
2491 ac_header_compiler=no
2492 fi
2493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2495 $as_echo "$ac_header_compiler" >&6; }
2496
2497 # Is the header present?
2498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2499 $as_echo_n "checking $2 presence... " >&6; }
2500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2501 /* end confdefs.h. */
2502 #include <$2>
2503 _ACEOF
2504 if ac_fn_c_try_cpp "$LINENO"; then :
2505 ac_header_preproc=yes
2506 else
2507 ac_header_preproc=no
2508 fi
2509 rm -f conftest.err conftest.$ac_ext
2510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2511 $as_echo "$ac_header_preproc" >&6; }
2512
2513 # So? What about this header?
2514 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2515 yes:no: )
2516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2517 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2518 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2519 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2520 ;;
2521 no:yes:* )
2522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2523 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2525 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2526 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2527 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2528 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2529 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2530 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2531 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2532 ;;
2533 esac
2534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2535 $as_echo_n "checking for $2... " >&6; }
2536 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2537 $as_echo_n "(cached) " >&6
2538 else
2539 eval "$3=\$ac_header_compiler"
2540 fi
2541 eval ac_res=\$$3
2542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2543 $as_echo "$ac_res" >&6; }
2544 fi
2545 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2546
2547 } # ac_fn_c_check_header_mongrel
2548
2549 # ac_fn_c_try_run LINENO
2550 # ----------------------
2551 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2552 # that executables *can* be run.
2553 ac_fn_c_try_run ()
2554 {
2555 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2556 if { { ac_try="$ac_link"
2557 case "(($ac_try" in
2558 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2559 *) ac_try_echo=$ac_try;;
2560 esac
2561 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2562 $as_echo "$ac_try_echo"; } >&5
2563 (eval "$ac_link") 2>&5
2564 ac_status=$?
2565 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2566 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2567 { { case "(($ac_try" in
2568 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2569 *) ac_try_echo=$ac_try;;
2570 esac
2571 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2572 $as_echo "$ac_try_echo"; } >&5
2573 (eval "$ac_try") 2>&5
2574 ac_status=$?
2575 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2576 test $ac_status = 0; }; }; then :
2577 ac_retval=0
2578 else
2579 $as_echo "$as_me: program exited with status $ac_status" >&5
2580 $as_echo "$as_me: failed program was:" >&5
2581 sed 's/^/| /' conftest.$ac_ext >&5
2582
2583 ac_retval=$ac_status
2584 fi
2585 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2586 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2587 as_fn_set_status $ac_retval
2588
2589 } # ac_fn_c_try_run
2590
2591 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2592 # -------------------------------------------------------
2593 # Tests whether HEADER exists and can be compiled using the include files in
2594 # INCLUDES, setting the cache variable VAR accordingly.
2595 ac_fn_c_check_header_compile ()
2596 {
2597 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2599 $as_echo_n "checking for $2... " >&6; }
2600 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2601 $as_echo_n "(cached) " >&6
2602 else
2603 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2604 /* end confdefs.h. */
2605 $4
2606 #include <$2>
2607 _ACEOF
2608 if ac_fn_c_try_compile "$LINENO"; then :
2609 eval "$3=yes"
2610 else
2611 eval "$3=no"
2612 fi
2613 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2614 fi
2615 eval ac_res=\$$3
2616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2617 $as_echo "$ac_res" >&6; }
2618 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2619
2620 } # ac_fn_c_check_header_compile
2621
2622 # ac_fn_c_try_link LINENO
2623 # -----------------------
2624 # Try to link conftest.$ac_ext, and return whether this succeeded.
2625 ac_fn_c_try_link ()
2626 {
2627 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2628 rm -f conftest.$ac_objext conftest$ac_exeext
2629 if { { ac_try="$ac_link"
2630 case "(($ac_try" in
2631 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2632 *) ac_try_echo=$ac_try;;
2633 esac
2634 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2635 $as_echo "$ac_try_echo"; } >&5
2636 (eval "$ac_link") 2>conftest.err
2637 ac_status=$?
2638 if test -s conftest.err; then
2639 grep -v '^ *+' conftest.err >conftest.er1
2640 cat conftest.er1 >&5
2641 mv -f conftest.er1 conftest.err
2642 fi
2643 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2644 test $ac_status = 0; } && {
2645 test -z "$ac_c_werror_flag" ||
2646 test ! -s conftest.err
2647 } && test -s conftest$ac_exeext && {
2648 test "$cross_compiling" = yes ||
2649 $as_test_x conftest$ac_exeext
2650 }; then :
2651 ac_retval=0
2652 else
2653 $as_echo "$as_me: failed program was:" >&5
2654 sed 's/^/| /' conftest.$ac_ext >&5
2655
2656 ac_retval=1
2657 fi
2658 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2659 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2660 # interfere with the next link command; also delete a directory that is
2661 # left behind by Apple's compiler. We do this before executing the actions.
2662 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2663 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2664 as_fn_set_status $ac_retval
2665
2666 } # ac_fn_c_try_link
2667
2668 # ac_fn_c_check_decl LINENO SYMBOL VAR
2669 # ------------------------------------
2670 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2671 ac_fn_c_check_decl ()
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 whether $2 is declared" >&5
2675 $as_echo_n "checking whether $2 is declared... " >&6; }
2676 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2677 $as_echo_n "(cached) " >&6
2678 else
2679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2680 /* end confdefs.h. */
2681 $4
2682 int
2683 main ()
2684 {
2685 #ifndef $2
2686 (void) $2;
2687 #endif
2688
2689 ;
2690 return 0;
2691 }
2692 _ACEOF
2693 if ac_fn_c_try_compile "$LINENO"; then :
2694 eval "$3=yes"
2695 else
2696 eval "$3=no"
2697 fi
2698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2699 fi
2700 eval ac_res=\$$3
2701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2702 $as_echo "$ac_res" >&6; }
2703 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2704
2705 } # ac_fn_c_check_decl
2706
2707 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2708 # ----------------------------------------------
2709 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2710 ac_fn_c_check_header_preproc ()
2711 {
2712 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2714 $as_echo_n "checking for $2... " >&6; }
2715 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2716 $as_echo_n "(cached) " >&6
2717 else
2718 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2719 /* end confdefs.h. */
2720 #include <$2>
2721 _ACEOF
2722 if ac_fn_c_try_cpp "$LINENO"; then :
2723 eval "$3=yes"
2724 else
2725 eval "$3=no"
2726 fi
2727 rm -f conftest.err conftest.$ac_ext
2728 fi
2729 eval ac_res=\$$3
2730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2731 $as_echo "$ac_res" >&6; }
2732 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2733
2734 } # ac_fn_c_check_header_preproc
2735
2736 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2737 # ----------------------------------------------------
2738 # Tries to find if the field MEMBER exists in type AGGR, after including
2739 # INCLUDES, setting cache variable VAR accordingly.
2740 ac_fn_c_check_member ()
2741 {
2742 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2744 $as_echo_n "checking for $2.$3... " >&6; }
2745 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2746 $as_echo_n "(cached) " >&6
2747 else
2748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2749 /* end confdefs.h. */
2750 $5
2751 int
2752 main ()
2753 {
2754 static $2 ac_aggr;
2755 if (ac_aggr.$3)
2756 return 0;
2757 ;
2758 return 0;
2759 }
2760 _ACEOF
2761 if ac_fn_c_try_compile "$LINENO"; then :
2762 eval "$4=yes"
2763 else
2764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2765 /* end confdefs.h. */
2766 $5
2767 int
2768 main ()
2769 {
2770 static $2 ac_aggr;
2771 if (sizeof ac_aggr.$3)
2772 return 0;
2773 ;
2774 return 0;
2775 }
2776 _ACEOF
2777 if ac_fn_c_try_compile "$LINENO"; then :
2778 eval "$4=yes"
2779 else
2780 eval "$4=no"
2781 fi
2782 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2783 fi
2784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2785 fi
2786 eval ac_res=\$$4
2787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2788 $as_echo "$ac_res" >&6; }
2789 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2790
2791 } # ac_fn_c_check_member
2792
2793 # ac_fn_c_check_func LINENO FUNC VAR
2794 # ----------------------------------
2795 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2796 ac_fn_c_check_func ()
2797 {
2798 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2800 $as_echo_n "checking for $2... " >&6; }
2801 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2802 $as_echo_n "(cached) " >&6
2803 else
2804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2805 /* end confdefs.h. */
2806 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2807 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2808 #define $2 innocuous_$2
2809
2810 /* System header to define __stub macros and hopefully few prototypes,
2811 which can conflict with char $2 (); below.
2812 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2813 <limits.h> exists even on freestanding compilers. */
2814
2815 #ifdef __STDC__
2816 # include <limits.h>
2817 #else
2818 # include <assert.h>
2819 #endif
2820
2821 #undef $2
2822
2823 /* Override any GCC internal prototype to avoid an error.
2824 Use char because int might match the return type of a GCC
2825 builtin and then its argument prototype would still apply. */
2826 #ifdef __cplusplus
2827 extern "C"
2828 #endif
2829 char $2 ();
2830 /* The GNU C library defines this for functions which it implements
2831 to always fail with ENOSYS. Some functions are actually named
2832 something starting with __ and the normal name is an alias. */
2833 #if defined __stub_$2 || defined __stub___$2
2834 choke me
2835 #endif
2836
2837 int
2838 main ()
2839 {
2840 return $2 ();
2841 ;
2842 return 0;
2843 }
2844 _ACEOF
2845 if ac_fn_c_try_link "$LINENO"; then :
2846 eval "$3=yes"
2847 else
2848 eval "$3=no"
2849 fi
2850 rm -f core conftest.err conftest.$ac_objext \
2851 conftest$ac_exeext conftest.$ac_ext
2852 fi
2853 eval ac_res=\$$3
2854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2855 $as_echo "$ac_res" >&6; }
2856 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2857
2858 } # ac_fn_c_check_func
2859
2860 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2861 # -------------------------------------------
2862 # Tests whether TYPE exists after having included INCLUDES, setting cache
2863 # variable VAR accordingly.
2864 ac_fn_c_check_type ()
2865 {
2866 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2868 $as_echo_n "checking for $2... " >&6; }
2869 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2870 $as_echo_n "(cached) " >&6
2871 else
2872 eval "$3=no"
2873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2874 /* end confdefs.h. */
2875 $4
2876 int
2877 main ()
2878 {
2879 if (sizeof ($2))
2880 return 0;
2881 ;
2882 return 0;
2883 }
2884 _ACEOF
2885 if ac_fn_c_try_compile "$LINENO"; then :
2886 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2887 /* end confdefs.h. */
2888 $4
2889 int
2890 main ()
2891 {
2892 if (sizeof (($2)))
2893 return 0;
2894 ;
2895 return 0;
2896 }
2897 _ACEOF
2898 if ac_fn_c_try_compile "$LINENO"; then :
2899
2900 else
2901 eval "$3=yes"
2902 fi
2903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2904 fi
2905 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2906 fi
2907 eval ac_res=\$$3
2908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2909 $as_echo "$ac_res" >&6; }
2910 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2911
2912 } # ac_fn_c_check_type
2913
2914 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2915 # --------------------------------------------
2916 # Tries to find the compile-time value of EXPR in a program that includes
2917 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2918 # computed
2919 ac_fn_c_compute_int ()
2920 {
2921 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2922 if test "$cross_compiling" = yes; then
2923 # Depending upon the size, compute the lo and hi bounds.
2924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2925 /* end confdefs.h. */
2926 $4
2927 int
2928 main ()
2929 {
2930 static int test_array [1 - 2 * !(($2) >= 0)];
2931 test_array [0] = 0
2932
2933 ;
2934 return 0;
2935 }
2936 _ACEOF
2937 if ac_fn_c_try_compile "$LINENO"; then :
2938 ac_lo=0 ac_mid=0
2939 while :; do
2940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2941 /* end confdefs.h. */
2942 $4
2943 int
2944 main ()
2945 {
2946 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2947 test_array [0] = 0
2948
2949 ;
2950 return 0;
2951 }
2952 _ACEOF
2953 if ac_fn_c_try_compile "$LINENO"; then :
2954 ac_hi=$ac_mid; break
2955 else
2956 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2957 if test $ac_lo -le $ac_mid; then
2958 ac_lo= ac_hi=
2959 break
2960 fi
2961 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2962 fi
2963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2964 done
2965 else
2966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2967 /* end confdefs.h. */
2968 $4
2969 int
2970 main ()
2971 {
2972 static int test_array [1 - 2 * !(($2) < 0)];
2973 test_array [0] = 0
2974
2975 ;
2976 return 0;
2977 }
2978 _ACEOF
2979 if ac_fn_c_try_compile "$LINENO"; then :
2980 ac_hi=-1 ac_mid=-1
2981 while :; do
2982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2983 /* end confdefs.h. */
2984 $4
2985 int
2986 main ()
2987 {
2988 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2989 test_array [0] = 0
2990
2991 ;
2992 return 0;
2993 }
2994 _ACEOF
2995 if ac_fn_c_try_compile "$LINENO"; then :
2996 ac_lo=$ac_mid; break
2997 else
2998 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2999 if test $ac_mid -le $ac_hi; then
3000 ac_lo= ac_hi=
3001 break
3002 fi
3003 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
3004 fi
3005 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3006 done
3007 else
3008 ac_lo= ac_hi=
3009 fi
3010 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3011 fi
3012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3013 # Binary search between lo and hi bounds.
3014 while test "x$ac_lo" != "x$ac_hi"; do
3015 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
3016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3017 /* end confdefs.h. */
3018 $4
3019 int
3020 main ()
3021 {
3022 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
3023 test_array [0] = 0
3024
3025 ;
3026 return 0;
3027 }
3028 _ACEOF
3029 if ac_fn_c_try_compile "$LINENO"; then :
3030 ac_hi=$ac_mid
3031 else
3032 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
3033 fi
3034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3035 done
3036 case $ac_lo in #((
3037 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
3038 '') ac_retval=1 ;;
3039 esac
3040 else
3041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3042 /* end confdefs.h. */
3043 $4
3044 static long int longval () { return $2; }
3045 static unsigned long int ulongval () { return $2; }
3046 #include <stdio.h>
3047 #include <stdlib.h>
3048 int
3049 main ()
3050 {
3051
3052 FILE *f = fopen ("conftest.val", "w");
3053 if (! f)
3054 return 1;
3055 if (($2) < 0)
3056 {
3057 long int i = longval ();
3058 if (i != ($2))
3059 return 1;
3060 fprintf (f, "%ld", i);
3061 }
3062 else
3063 {
3064 unsigned long int i = ulongval ();
3065 if (i != ($2))
3066 return 1;
3067 fprintf (f, "%lu", i);
3068 }
3069 /* Do not output a trailing newline, as this causes \r\n confusion
3070 on some platforms. */
3071 return ferror (f) || fclose (f) != 0;
3072
3073 ;
3074 return 0;
3075 }
3076 _ACEOF
3077 if ac_fn_c_try_run "$LINENO"; then :
3078 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
3079 else
3080 ac_retval=1
3081 fi
3082 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3083 conftest.$ac_objext conftest.beam conftest.$ac_ext
3084 rm -f conftest.val
3085
3086 fi
3087 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
3088 as_fn_set_status $ac_retval
3089
3090 } # ac_fn_c_compute_int
3091 cat >config.log <<_ACEOF
3092 This file contains any messages produced by compilers while
3093 running configure, to aid debugging if configure makes a mistake.
3094
3095 It was created by emacs $as_me 24.3.50, which was
3096 generated by GNU Autoconf 2.65. Invocation command line was
3097
3098 $ $0 $@
3099
3100 _ACEOF
3101 exec 5>>config.log
3102 {
3103 cat <<_ASUNAME
3104 ## --------- ##
3105 ## Platform. ##
3106 ## --------- ##
3107
3108 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
3109 uname -m = `(uname -m) 2>/dev/null || echo unknown`
3110 uname -r = `(uname -r) 2>/dev/null || echo unknown`
3111 uname -s = `(uname -s) 2>/dev/null || echo unknown`
3112 uname -v = `(uname -v) 2>/dev/null || echo unknown`
3113
3114 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
3115 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
3116
3117 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
3118 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
3119 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
3120 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
3121 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
3122 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
3123 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
3124
3125 _ASUNAME
3126
3127 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3128 for as_dir in $PATH
3129 do
3130 IFS=$as_save_IFS
3131 test -z "$as_dir" && as_dir=.
3132 $as_echo "PATH: $as_dir"
3133 done
3134 IFS=$as_save_IFS
3135
3136 } >&5
3137
3138 cat >&5 <<_ACEOF
3139
3140
3141 ## ----------- ##
3142 ## Core tests. ##
3143 ## ----------- ##
3144
3145 _ACEOF
3146
3147
3148 # Keep a trace of the command line.
3149 # Strip out --no-create and --no-recursion so they do not pile up.
3150 # Strip out --silent because we don't want to record it for future runs.
3151 # Also quote any args containing shell meta-characters.
3152 # Make two passes to allow for proper duplicate-argument suppression.
3153 ac_configure_args=
3154 ac_configure_args0=
3155 ac_configure_args1=
3156 ac_must_keep_next=false
3157 for ac_pass in 1 2
3158 do
3159 for ac_arg
3160 do
3161 case $ac_arg in
3162 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
3163 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
3164 | -silent | --silent | --silen | --sile | --sil)
3165 continue ;;
3166 *\'*)
3167 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
3168 esac
3169 case $ac_pass in
3170 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
3171 2)
3172 as_fn_append ac_configure_args1 " '$ac_arg'"
3173 if test $ac_must_keep_next = true; then
3174 ac_must_keep_next=false # Got value, back to normal.
3175 else
3176 case $ac_arg in
3177 *=* | --config-cache | -C | -disable-* | --disable-* \
3178 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
3179 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
3180 | -with-* | --with-* | -without-* | --without-* | --x)
3181 case "$ac_configure_args0 " in
3182 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
3183 esac
3184 ;;
3185 -* ) ac_must_keep_next=true ;;
3186 esac
3187 fi
3188 as_fn_append ac_configure_args " '$ac_arg'"
3189 ;;
3190 esac
3191 done
3192 done
3193 { ac_configure_args0=; unset ac_configure_args0;}
3194 { ac_configure_args1=; unset ac_configure_args1;}
3195
3196 # When interrupted or exit'd, cleanup temporary files, and complete
3197 # config.log. We remove comments because anyway the quotes in there
3198 # would cause problems or look ugly.
3199 # WARNING: Use '\'' to represent an apostrophe within the trap.
3200 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3201 trap 'exit_status=$?
3202 # Save into config.log some information that might help in debugging.
3203 {
3204 echo
3205
3206 cat <<\_ASBOX
3207 ## ---------------- ##
3208 ## Cache variables. ##
3209 ## ---------------- ##
3210 _ASBOX
3211 echo
3212 # The following way of writing the cache mishandles newlines in values,
3213 (
3214 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3215 eval ac_val=\$$ac_var
3216 case $ac_val in #(
3217 *${as_nl}*)
3218 case $ac_var in #(
3219 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3220 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3221 esac
3222 case $ac_var in #(
3223 _ | IFS | as_nl) ;; #(
3224 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3225 *) { eval $ac_var=; unset $ac_var;} ;;
3226 esac ;;
3227 esac
3228 done
3229 (set) 2>&1 |
3230 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3231 *${as_nl}ac_space=\ *)
3232 sed -n \
3233 "s/'\''/'\''\\\\'\'''\''/g;
3234 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3235 ;; #(
3236 *)
3237 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3238 ;;
3239 esac |
3240 sort
3241 )
3242 echo
3243
3244 cat <<\_ASBOX
3245 ## ----------------- ##
3246 ## Output variables. ##
3247 ## ----------------- ##
3248 _ASBOX
3249 echo
3250 for ac_var in $ac_subst_vars
3251 do
3252 eval ac_val=\$$ac_var
3253 case $ac_val in
3254 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3255 esac
3256 $as_echo "$ac_var='\''$ac_val'\''"
3257 done | sort
3258 echo
3259
3260 if test -n "$ac_subst_files"; then
3261 cat <<\_ASBOX
3262 ## ------------------- ##
3263 ## File substitutions. ##
3264 ## ------------------- ##
3265 _ASBOX
3266 echo
3267 for ac_var in $ac_subst_files
3268 do
3269 eval ac_val=\$$ac_var
3270 case $ac_val in
3271 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3272 esac
3273 $as_echo "$ac_var='\''$ac_val'\''"
3274 done | sort
3275 echo
3276 fi
3277
3278 if test -s confdefs.h; then
3279 cat <<\_ASBOX
3280 ## ----------- ##
3281 ## confdefs.h. ##
3282 ## ----------- ##
3283 _ASBOX
3284 echo
3285 cat confdefs.h
3286 echo
3287 fi
3288 test "$ac_signal" != 0 &&
3289 $as_echo "$as_me: caught signal $ac_signal"
3290 $as_echo "$as_me: exit $exit_status"
3291 } >&5
3292 rm -f core *.core core.conftest.* &&
3293 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3294 exit $exit_status
3295 ' 0
3296 for ac_signal in 1 2 13 15; do
3297 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3298 done
3299 ac_signal=0
3300
3301 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3302 rm -f -r conftest* confdefs.h
3303
3304 $as_echo "/* confdefs.h */" > confdefs.h
3305
3306 # Predefined preprocessor variables.
3307
3308 cat >>confdefs.h <<_ACEOF
3309 #define PACKAGE_NAME "$PACKAGE_NAME"
3310 _ACEOF
3311
3312 cat >>confdefs.h <<_ACEOF
3313 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3314 _ACEOF
3315
3316 cat >>confdefs.h <<_ACEOF
3317 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3318 _ACEOF
3319
3320 cat >>confdefs.h <<_ACEOF
3321 #define PACKAGE_STRING "$PACKAGE_STRING"
3322 _ACEOF
3323
3324 cat >>confdefs.h <<_ACEOF
3325 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3326 _ACEOF
3327
3328 cat >>confdefs.h <<_ACEOF
3329 #define PACKAGE_URL "$PACKAGE_URL"
3330 _ACEOF
3331
3332
3333 # Let the site file select an alternate cache file if it wants to.
3334 # Prefer an explicitly selected file to automatically selected ones.
3335 ac_site_file1=NONE
3336 ac_site_file2=NONE
3337 if test -n "$CONFIG_SITE"; then
3338 ac_site_file1=$CONFIG_SITE
3339 elif test "x$prefix" != xNONE; then
3340 ac_site_file1=$prefix/share/config.site
3341 ac_site_file2=$prefix/etc/config.site
3342 else
3343 ac_site_file1=$ac_default_prefix/share/config.site
3344 ac_site_file2=$ac_default_prefix/etc/config.site
3345 fi
3346 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3347 do
3348 test "x$ac_site_file" = xNONE && continue
3349 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3350 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3351 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3352 sed 's/^/| /' "$ac_site_file" >&5
3353 . "$ac_site_file"
3354 fi
3355 done
3356
3357 if test -r "$cache_file"; then
3358 # Some versions of bash will fail to source /dev/null (special files
3359 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3360 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3361 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3362 $as_echo "$as_me: loading cache $cache_file" >&6;}
3363 case $cache_file in
3364 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3365 *) . "./$cache_file";;
3366 esac
3367 fi
3368 else
3369 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3370 $as_echo "$as_me: creating cache $cache_file" >&6;}
3371 >$cache_file
3372 fi
3373
3374 as_fn_append ac_header_list " sys/systeminfo.h"
3375 as_fn_append ac_header_list " coff.h"
3376 as_fn_append ac_header_list " pty.h"
3377 as_fn_append ac_header_list " sys/resource.h"
3378 as_fn_append ac_header_list " sys/utsname.h"
3379 as_fn_append ac_header_list " pwd.h"
3380 as_fn_append ac_header_list " utmp.h"
3381 as_fn_append ac_header_list " util.h"
3382 as_fn_append ac_header_list " sys/socket.h"
3383 as_fn_append ac_header_list " stdlib.h"
3384 as_fn_append ac_header_list " unistd.h"
3385 as_fn_append ac_header_list " sys/param.h"
3386 as_fn_append ac_header_list " pthread.h"
3387 as_fn_append ac_header_list " malloc/malloc.h"
3388 as_fn_append ac_header_list " maillock.h"
3389 as_fn_append ac_header_list " sys/un.h"
3390 as_fn_append ac_func_list " tzset"
3391 as_fn_append ac_func_list " readlinkat"
3392 as_fn_append ac_header_list " dirent.h"
3393 as_fn_append ac_header_list " execinfo.h"
3394 as_fn_append ac_func_list " faccessat"
3395 as_fn_append ac_func_list " fcntl"
3396 as_fn_append ac_func_list " fdopendir"
3397 as_fn_append ac_header_list " stdio_ext.h"
3398 as_fn_append ac_func_list " fstatat"
3399 as_fn_append ac_func_list " fsync"
3400 gl_getopt_required=GNU
3401 as_fn_append ac_header_list " getopt.h"
3402 as_fn_append ac_func_list " gettimeofday"
3403 as_fn_append ac_func_list " nanotime"
3404 as_fn_append ac_header_list " sys/time.h"
3405 as_fn_append ac_header_list " wchar.h"
3406 as_fn_append ac_header_list " stdint.h"
3407 as_fn_append ac_header_list " inttypes.h"
3408 as_fn_append ac_func_list " lstat"
3409 as_fn_append ac_func_list " mkostemp"
3410 as_fn_append ac_func_list " pipe2"
3411 as_fn_append ac_header_list " sys/select.h"
3412 as_fn_append ac_func_list " pselect"
3413 as_fn_append ac_func_list " pthread_sigmask"
3414 as_fn_append ac_func_list " readlink"
3415 as_fn_append ac_func_list " strtoimax"
3416 as_fn_append ac_func_list " strtoumax"
3417 as_fn_append ac_func_list " symlink"
3418 as_fn_append ac_header_list " sys/stat.h"
3419 as_fn_append ac_func_list " localtime_r"
3420 as_fn_append ac_header_list " utime.h"
3421 as_fn_append ac_func_list " futimes"
3422 as_fn_append ac_func_list " futimesat"
3423 as_fn_append ac_func_list " futimens"
3424 as_fn_append ac_func_list " utimensat"
3425 as_fn_append ac_func_list " lutimes"
3426 as_fn_append ac_func_list " getdtablesize"
3427 as_fn_append ac_func_list " secure_getenv"
3428 # Check that the precious variables saved in the cache have kept the same
3429 # value.
3430 ac_cache_corrupted=false
3431 for ac_var in $ac_precious_vars; do
3432 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3433 eval ac_new_set=\$ac_env_${ac_var}_set
3434 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3435 eval ac_new_val=\$ac_env_${ac_var}_value
3436 case $ac_old_set,$ac_new_set in
3437 set,)
3438 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3439 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3440 ac_cache_corrupted=: ;;
3441 ,set)
3442 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3443 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3444 ac_cache_corrupted=: ;;
3445 ,);;
3446 *)
3447 if test "x$ac_old_val" != "x$ac_new_val"; then
3448 # differences in whitespace do not lead to failure.
3449 ac_old_val_w=`echo x $ac_old_val`
3450 ac_new_val_w=`echo x $ac_new_val`
3451 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3452 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3453 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3454 ac_cache_corrupted=:
3455 else
3456 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3457 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3458 eval $ac_var=\$ac_old_val
3459 fi
3460 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3461 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3462 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3463 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3464 fi;;
3465 esac
3466 # Pass precious variables to config.status.
3467 if test "$ac_new_set" = set; then
3468 case $ac_new_val in
3469 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3470 *) ac_arg=$ac_var=$ac_new_val ;;
3471 esac
3472 case " $ac_configure_args " in
3473 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3474 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3475 esac
3476 fi
3477 done
3478 if $ac_cache_corrupted; then
3479 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3480 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3481 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3482 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3483 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3484 fi
3485 ## -------------------- ##
3486 ## Main body of script. ##
3487 ## -------------------- ##
3488
3489 ac_ext=c
3490 ac_cpp='$CPP $CPPFLAGS'
3491 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3492 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3493 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3494
3495
3496
3497 emacs_config_options=
3498 optsep=
3499 for opt in ${1+"$@"} CFLAGS CPPFLAGS LDFLAGS; do
3500 case $opt in
3501 -n | --no-create | --no-recursion)
3502 continue ;;
3503 CFLAGS | CPPFLAGS | LDFLAGS)
3504 eval 'test "${'$opt'+set}" = set' || continue
3505 case " $*" in
3506 *" $opt="*) continue ;;
3507 esac
3508 eval opt=$opt=\$$opt ;;
3509 esac
3510
3511 emacs_shell_specials=$IFS\''"#$&()*;<>?[\\`{|~'
3512 case $opt in
3513 *["$emacs_shell_specials"]*)
3514 case $opt in
3515 *\'*)
3516 emacs_quote_apostrophes="s/'/'\\\\''/g"
3517 opt=`$as_echo "$opt" | sed "$emacs_quote_apostrophes"` ;;
3518 esac
3519 opt="'$opt'"
3520 case $opt in
3521 *['"\\']*)
3522 emacs_quote_for_c='s/["\\]/\\&/g; $!s/$/\\n\\/'
3523 opt=`$as_echo "$opt" | sed "$emacs_quote_for_c"` ;;
3524 esac ;;
3525 esac
3526 as_fn_append emacs_config_options "$optsep$opt"
3527 optsep=' '
3528 done
3529
3530 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3531
3532
3533 ac_aux_dir=
3534 for ac_dir in build-aux "$srcdir"/build-aux; do
3535 for ac_t in install-sh install.sh shtool; do
3536 if test -f "$ac_dir/$ac_t"; then
3537 ac_aux_dir=$ac_dir
3538 ac_install_sh="$ac_aux_dir/$ac_t -c"
3539 break 2
3540 fi
3541 done
3542 done
3543 if test -z "$ac_aux_dir"; then
3544 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3545 fi
3546
3547 # These three variables are undocumented and unsupported,
3548 # and are intended to be withdrawn in a future Autoconf release.
3549 # They can cause serious problems if a builder's source tree is in a directory
3550 # whose full name contains unusual characters.
3551 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3552 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3553 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3554
3555
3556 am__api_version='1.11'
3557
3558 # Find a good install program. We prefer a C program (faster),
3559 # so one script is as good as another. But avoid the broken or
3560 # incompatible versions:
3561 # SysV /etc/install, /usr/sbin/install
3562 # SunOS /usr/etc/install
3563 # IRIX /sbin/install
3564 # AIX /bin/install
3565 # AmigaOS /C/install, which installs bootblocks on floppy discs
3566 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3567 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3568 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3569 # OS/2's system install, which has a completely different semantic
3570 # ./install, which can be erroneously created by make from ./install.sh.
3571 # Reject install programs that cannot install multiple files.
3572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3573 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3574 if test -z "$INSTALL"; then
3575 if test "${ac_cv_path_install+set}" = set; then :
3576 $as_echo_n "(cached) " >&6
3577 else
3578 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3579 for as_dir in $PATH
3580 do
3581 IFS=$as_save_IFS
3582 test -z "$as_dir" && as_dir=.
3583 # Account for people who put trailing slashes in PATH elements.
3584 case $as_dir/ in #((
3585 ./ | .// | /[cC]/* | \
3586 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3587 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3588 /usr/ucb/* ) ;;
3589 *)
3590 # OSF1 and SCO ODT 3.0 have their own names for install.
3591 # Don't use installbsd from OSF since it installs stuff as root
3592 # by default.
3593 for ac_prog in ginstall scoinst install; do
3594 for ac_exec_ext in '' $ac_executable_extensions; do
3595 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3596 if test $ac_prog = install &&
3597 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3598 # AIX install. It has an incompatible calling convention.
3599 :
3600 elif test $ac_prog = install &&
3601 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3602 # program-specific install script used by HP pwplus--don't use.
3603 :
3604 else
3605 rm -rf conftest.one conftest.two conftest.dir
3606 echo one > conftest.one
3607 echo two > conftest.two
3608 mkdir conftest.dir
3609 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3610 test -s conftest.one && test -s conftest.two &&
3611 test -s conftest.dir/conftest.one &&
3612 test -s conftest.dir/conftest.two
3613 then
3614 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3615 break 3
3616 fi
3617 fi
3618 fi
3619 done
3620 done
3621 ;;
3622 esac
3623
3624 done
3625 IFS=$as_save_IFS
3626
3627 rm -rf conftest.one conftest.two conftest.dir
3628
3629 fi
3630 if test "${ac_cv_path_install+set}" = set; then
3631 INSTALL=$ac_cv_path_install
3632 else
3633 # As a last resort, use the slow shell script. Don't cache a
3634 # value for INSTALL within a source directory, because that will
3635 # break other packages using the cache if that directory is
3636 # removed, or if the value is a relative name.
3637 INSTALL=$ac_install_sh
3638 fi
3639 fi
3640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3641 $as_echo "$INSTALL" >&6; }
3642
3643 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3644 # It thinks the first close brace ends the variable substitution.
3645 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3646
3647 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3648
3649 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3650
3651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3652 $as_echo_n "checking whether build environment is sane... " >&6; }
3653 # Just in case
3654 sleep 1
3655 echo timestamp > conftest.file
3656 # Reject unsafe characters in $srcdir or the absolute working directory
3657 # name. Accept space and tab only in the latter.
3658 am_lf='
3659 '
3660 case `pwd` in
3661 *[\\\"\#\$\&\'\`$am_lf]*)
3662 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3663 esac
3664 case $srcdir in
3665 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3666 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3667 esac
3668
3669 # Do `set' in a subshell so we don't clobber the current shell's
3670 # arguments. Must try -L first in case configure is actually a
3671 # symlink; some systems play weird games with the mod time of symlinks
3672 # (eg FreeBSD returns the mod time of the symlink's containing
3673 # directory).
3674 if (
3675 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3676 if test "$*" = "X"; then
3677 # -L didn't work.
3678 set X `ls -t "$srcdir/configure" conftest.file`
3679 fi
3680 rm -f conftest.file
3681 if test "$*" != "X $srcdir/configure conftest.file" \
3682 && test "$*" != "X conftest.file $srcdir/configure"; then
3683
3684 # If neither matched, then we have a broken ls. This can happen
3685 # if, for instance, CONFIG_SHELL is bash and it inherits a
3686 # broken ls alias from the environment. This has actually
3687 # happened. Such a system could not be considered "sane".
3688 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3689 alias in your environment" "$LINENO" 5
3690 fi
3691
3692 test "$2" = conftest.file
3693 )
3694 then
3695 # Ok.
3696 :
3697 else
3698 as_fn_error "newly created file is older than distributed files!
3699 Check your system clock" "$LINENO" 5
3700 fi
3701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3702 $as_echo "yes" >&6; }
3703 test "$program_prefix" != NONE &&
3704 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3705 # Use a double $ so make ignores it.
3706 test "$program_suffix" != NONE &&
3707 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3708 # Double any \ or $.
3709 # By default was `s,x,x', remove it if useless.
3710 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3711 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3712
3713 # expand $ac_aux_dir to an absolute path
3714 am_aux_dir=`cd $ac_aux_dir && pwd`
3715
3716 if test x"${MISSING+set}" != xset; then
3717 case $am_aux_dir in
3718 *\ * | *\ *)
3719 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3720 *)
3721 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3722 esac
3723 fi
3724 # Use eval to expand $SHELL
3725 if eval "$MISSING --run true"; then
3726 am_missing_run="$MISSING --run "
3727 else
3728 am_missing_run=
3729 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3730 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3731 fi
3732
3733 if test x"${install_sh}" != xset; then
3734 case $am_aux_dir in
3735 *\ * | *\ *)
3736 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3737 *)
3738 install_sh="\${SHELL} $am_aux_dir/install-sh"
3739 esac
3740 fi
3741
3742 # Installed binaries are usually stripped using `strip' when the user
3743 # run `make install-strip'. However `strip' might not be the right
3744 # tool to use in cross-compilation environments, therefore Automake
3745 # will honor the `STRIP' environment variable to overrule this program.
3746 if test "$cross_compiling" != no; then
3747 if test -n "$ac_tool_prefix"; then
3748 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3749 set dummy ${ac_tool_prefix}strip; ac_word=$2
3750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3751 $as_echo_n "checking for $ac_word... " >&6; }
3752 if test "${ac_cv_prog_STRIP+set}" = set; then :
3753 $as_echo_n "(cached) " >&6
3754 else
3755 if test -n "$STRIP"; then
3756 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3757 else
3758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3759 for as_dir in $PATH
3760 do
3761 IFS=$as_save_IFS
3762 test -z "$as_dir" && as_dir=.
3763 for ac_exec_ext in '' $ac_executable_extensions; do
3764 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3765 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3766 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3767 break 2
3768 fi
3769 done
3770 done
3771 IFS=$as_save_IFS
3772
3773 fi
3774 fi
3775 STRIP=$ac_cv_prog_STRIP
3776 if test -n "$STRIP"; then
3777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3778 $as_echo "$STRIP" >&6; }
3779 else
3780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3781 $as_echo "no" >&6; }
3782 fi
3783
3784
3785 fi
3786 if test -z "$ac_cv_prog_STRIP"; then
3787 ac_ct_STRIP=$STRIP
3788 # Extract the first word of "strip", so it can be a program name with args.
3789 set dummy strip; ac_word=$2
3790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3791 $as_echo_n "checking for $ac_word... " >&6; }
3792 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3793 $as_echo_n "(cached) " >&6
3794 else
3795 if test -n "$ac_ct_STRIP"; then
3796 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3797 else
3798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3799 for as_dir in $PATH
3800 do
3801 IFS=$as_save_IFS
3802 test -z "$as_dir" && as_dir=.
3803 for ac_exec_ext in '' $ac_executable_extensions; do
3804 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3805 ac_cv_prog_ac_ct_STRIP="strip"
3806 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3807 break 2
3808 fi
3809 done
3810 done
3811 IFS=$as_save_IFS
3812
3813 fi
3814 fi
3815 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3816 if test -n "$ac_ct_STRIP"; then
3817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3818 $as_echo "$ac_ct_STRIP" >&6; }
3819 else
3820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3821 $as_echo "no" >&6; }
3822 fi
3823
3824 if test "x$ac_ct_STRIP" = x; then
3825 STRIP=":"
3826 else
3827 case $cross_compiling:$ac_tool_warned in
3828 yes:)
3829 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3830 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3831 ac_tool_warned=yes ;;
3832 esac
3833 STRIP=$ac_ct_STRIP
3834 fi
3835 else
3836 STRIP="$ac_cv_prog_STRIP"
3837 fi
3838
3839 fi
3840 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3841
3842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3843 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3844 if test -z "$MKDIR_P"; then
3845 if test "${ac_cv_path_mkdir+set}" = set; then :
3846 $as_echo_n "(cached) " >&6
3847 else
3848 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3849 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3850 do
3851 IFS=$as_save_IFS
3852 test -z "$as_dir" && as_dir=.
3853 for ac_prog in mkdir gmkdir; do
3854 for ac_exec_ext in '' $ac_executable_extensions; do
3855 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3856 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3857 'mkdir (GNU coreutils) '* | \
3858 'mkdir (coreutils) '* | \
3859 'mkdir (fileutils) '4.1*)
3860 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3861 break 3;;
3862 esac
3863 done
3864 done
3865 done
3866 IFS=$as_save_IFS
3867
3868 fi
3869
3870 test -d ./--version && rmdir ./--version
3871 if test "${ac_cv_path_mkdir+set}" = set; then
3872 MKDIR_P="$ac_cv_path_mkdir -p"
3873 else
3874 # As a last resort, use the slow shell script. Don't cache a
3875 # value for MKDIR_P within a source directory, because that will
3876 # break other packages using the cache if that directory is
3877 # removed, or if the value is a relative name.
3878 MKDIR_P="$ac_install_sh -d"
3879 fi
3880 fi
3881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3882 $as_echo "$MKDIR_P" >&6; }
3883
3884 mkdir_p="$MKDIR_P"
3885 case $mkdir_p in
3886 [\\/$]* | ?:[\\/]*) ;;
3887 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3888 esac
3889
3890 for ac_prog in gawk mawk nawk awk
3891 do
3892 # Extract the first word of "$ac_prog", so it can be a program name with args.
3893 set dummy $ac_prog; ac_word=$2
3894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3895 $as_echo_n "checking for $ac_word... " >&6; }
3896 if test "${ac_cv_prog_AWK+set}" = set; then :
3897 $as_echo_n "(cached) " >&6
3898 else
3899 if test -n "$AWK"; then
3900 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3901 else
3902 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3903 for as_dir in $PATH
3904 do
3905 IFS=$as_save_IFS
3906 test -z "$as_dir" && as_dir=.
3907 for ac_exec_ext in '' $ac_executable_extensions; do
3908 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3909 ac_cv_prog_AWK="$ac_prog"
3910 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3911 break 2
3912 fi
3913 done
3914 done
3915 IFS=$as_save_IFS
3916
3917 fi
3918 fi
3919 AWK=$ac_cv_prog_AWK
3920 if test -n "$AWK"; then
3921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3922 $as_echo "$AWK" >&6; }
3923 else
3924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3925 $as_echo "no" >&6; }
3926 fi
3927
3928
3929 test -n "$AWK" && break
3930 done
3931
3932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3933 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3934 set x ${MAKE-make}
3935 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3936 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3937 $as_echo_n "(cached) " >&6
3938 else
3939 cat >conftest.make <<\_ACEOF
3940 SHELL = /bin/sh
3941 all:
3942 @echo '@@@%%%=$(MAKE)=@@@%%%'
3943 _ACEOF
3944 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3945 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3946 *@@@%%%=?*=@@@%%%*)
3947 eval ac_cv_prog_make_${ac_make}_set=yes;;
3948 *)
3949 eval ac_cv_prog_make_${ac_make}_set=no;;
3950 esac
3951 rm -f conftest.make
3952 fi
3953 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3955 $as_echo "yes" >&6; }
3956 SET_MAKE=
3957 else
3958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3959 $as_echo "no" >&6; }
3960 SET_MAKE="MAKE=${MAKE-make}"
3961 fi
3962
3963 rm -rf .tst 2>/dev/null
3964 mkdir .tst 2>/dev/null
3965 if test -d .tst; then
3966 am__leading_dot=.
3967 else
3968 am__leading_dot=_
3969 fi
3970 rmdir .tst 2>/dev/null
3971
3972 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3973 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3974 # is not polluted with repeated "-I."
3975 am__isrc=' -I$(srcdir)'
3976 # test to see if srcdir already configured
3977 if test -f $srcdir/config.status; then
3978 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3979 fi
3980 fi
3981
3982 # test whether we have cygpath
3983 if test -z "$CYGPATH_W"; then
3984 if (cygpath --version) >/dev/null 2>/dev/null; then
3985 CYGPATH_W='cygpath -w'
3986 else
3987 CYGPATH_W=echo
3988 fi
3989 fi
3990
3991
3992 # Define the identity of the package.
3993 PACKAGE='emacs'
3994 VERSION='24.3.50'
3995
3996
3997 cat >>confdefs.h <<_ACEOF
3998 #define PACKAGE "$PACKAGE"
3999 _ACEOF
4000
4001
4002 cat >>confdefs.h <<_ACEOF
4003 #define VERSION "$VERSION"
4004 _ACEOF
4005
4006 # Some tools Automake needs.
4007
4008 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
4009
4010
4011 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
4012
4013
4014 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
4015
4016
4017 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
4018
4019
4020 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
4021
4022 # We need awk for the "check" target. The system "awk" is bad on
4023 # some platforms.
4024 # Always define AMTAR for backward compatibility.
4025
4026 AMTAR=${AMTAR-"${am_missing_run}tar"}
4027
4028 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
4029
4030
4031
4032
4033
4034
4035
4036
4037 lispdir='${datadir}/emacs/${version}/lisp'
4038 leimdir='${datadir}/emacs/${version}/leim'
4039 standardlisppath='${lispdir}:${leimdir}'
4040 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
4041 '${datadir}/emacs/site-lisp'
4042 lisppath='${locallisppath}:${standardlisppath}'
4043 etcdir='${datadir}/emacs/${version}/etc'
4044 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
4045 etcdocdir='${datadir}/emacs/${version}/etc'
4046 gamedir='${localstatedir}/games/emacs'
4047
4048
4049 # Check whether --with-all was given.
4050 if test "${with_all+set}" = set; then :
4051 withval=$with_all; with_features=$withval
4052 else
4053 with_features=yes
4054 fi
4055
4056
4057
4058
4059
4060 # Check whether --with-pop was given.
4061 if test "${with_pop+set}" = set; then :
4062 withval=$with_pop;
4063 else
4064 with_pop=$with_features
4065 fi
4066
4067 if test "$with_pop" = yes; then
4068 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
4069
4070 fi
4071
4072
4073 # Check whether --with-kerberos was given.
4074 if test "${with_kerberos+set}" = set; then :
4075 withval=$with_kerberos;
4076 else
4077 with_kerberos=no
4078 fi
4079
4080 if test "$with_kerberos" != no; then
4081 $as_echo "#define KERBEROS 1" >>confdefs.h
4082
4083 fi
4084
4085
4086 # Check whether --with-kerberos5 was given.
4087 if test "${with_kerberos5+set}" = set; then :
4088 withval=$with_kerberos5;
4089 else
4090 with_kerberos5=no
4091 fi
4092
4093 if test "${with_kerberos5}" != no; then
4094 if test "${with_kerberos}" = no; then
4095 with_kerberos=yes
4096 $as_echo "#define KERBEROS 1" >>confdefs.h
4097
4098 fi
4099
4100 $as_echo "#define KERBEROS5 1" >>confdefs.h
4101
4102 fi
4103
4104
4105 # Check whether --with-hesiod was given.
4106 if test "${with_hesiod+set}" = set; then :
4107 withval=$with_hesiod;
4108 else
4109 with_hesiod=no
4110 fi
4111
4112 if test "$with_hesiod" != no; then
4113
4114 $as_echo "#define HESIOD 1" >>confdefs.h
4115
4116 fi
4117
4118
4119 # Check whether --with-mmdf was given.
4120 if test "${with_mmdf+set}" = set; then :
4121 withval=$with_mmdf;
4122 else
4123 with_mmdf=no
4124 fi
4125
4126 if test "$with_mmdf" != no; then
4127
4128 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
4129
4130 fi
4131
4132
4133 # Check whether --with-mail-unlink was given.
4134 if test "${with_mail_unlink+set}" = set; then :
4135 withval=$with_mail_unlink;
4136 else
4137 with_mail_unlink=no
4138 fi
4139
4140 if test "$with_mail_unlink" != no; then
4141
4142 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
4143
4144 fi
4145
4146
4147 # Check whether --with-mailhost was given.
4148 if test "${with_mailhost+set}" = set; then :
4149 withval=$with_mailhost;
4150 cat >>confdefs.h <<_ACEOF
4151 #define MAILHOST "$withval"
4152 _ACEOF
4153
4154 fi
4155
4156
4157
4158 # Check whether --with-sound was given.
4159 if test "${with_sound+set}" = set; then :
4160 withval=$with_sound; case "${withval}" in
4161 yes|no|alsa|oss|bsd-ossaudio) val=$withval ;;
4162 *) as_fn_error "\`--with-sound=$withval' is invalid;
4163 this option's value should be \`yes', \`no', \`alsa', \`oss', or \`bsd-ossaudio'." "$LINENO" 5
4164 ;;
4165 esac
4166 with_sound=$val
4167
4168 else
4169 with_sound=$with_features
4170 fi
4171
4172
4173
4174 # Check whether --with-x-toolkit was given.
4175 if test "${with_x_toolkit+set}" = set; then :
4176 withval=$with_x_toolkit; case "${withval}" in
4177 y | ye | yes ) val=gtk ;;
4178 n | no ) val=no ;;
4179 l | lu | luc | luci | lucid ) val=lucid ;;
4180 a | at | ath | athe | athen | athena ) val=athena ;;
4181 m | mo | mot | moti | motif ) val=motif ;;
4182 g | gt | gtk ) val=gtk ;;
4183 gtk2 ) val=gtk2 ;;
4184 gtk3 ) val=gtk3 ;;
4185 * )
4186 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
4187 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
4188 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
4189 \`athena' and \`lucid' are synonyms." "$LINENO" 5
4190 ;;
4191 esac
4192 with_x_toolkit=$val
4193
4194 fi
4195
4196
4197
4198 # Check whether --with-wide-int was given.
4199 if test "${with_wide_int+set}" = set; then :
4200 withval=$with_wide_int;
4201 else
4202 with_wide_int=no
4203 fi
4204
4205 if test "$with_wide_int" = yes; then
4206
4207 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
4208
4209 fi
4210
4211
4212 # Check whether --with-xpm was given.
4213 if test "${with_xpm+set}" = set; then :
4214 withval=$with_xpm;
4215 else
4216 with_xpm=$with_features
4217 fi
4218
4219
4220 # Check whether --with-jpeg was given.
4221 if test "${with_jpeg+set}" = set; then :
4222 withval=$with_jpeg;
4223 else
4224 with_jpeg=$with_features
4225 fi
4226
4227
4228 # Check whether --with-tiff was given.
4229 if test "${with_tiff+set}" = set; then :
4230 withval=$with_tiff;
4231 else
4232 with_tiff=$with_features
4233 fi
4234
4235
4236 # Check whether --with-gif was given.
4237 if test "${with_gif+set}" = set; then :
4238 withval=$with_gif;
4239 else
4240 with_gif=$with_features
4241 fi
4242
4243
4244 # Check whether --with-png was given.
4245 if test "${with_png+set}" = set; then :
4246 withval=$with_png;
4247 else
4248 with_png=$with_features
4249 fi
4250
4251
4252 # Check whether --with-rsvg was given.
4253 if test "${with_rsvg+set}" = set; then :
4254 withval=$with_rsvg;
4255 else
4256 with_rsvg=$with_features
4257 fi
4258
4259
4260 # Check whether --with-xml2 was given.
4261 if test "${with_xml2+set}" = set; then :
4262 withval=$with_xml2;
4263 else
4264 with_xml2=$with_features
4265 fi
4266
4267
4268 # Check whether --with-imagemagick was given.
4269 if test "${with_imagemagick+set}" = set; then :
4270 withval=$with_imagemagick;
4271 else
4272 with_imagemagick=$with_features
4273 fi
4274
4275
4276
4277 # Check whether --with-xft was given.
4278 if test "${with_xft+set}" = set; then :
4279 withval=$with_xft;
4280 else
4281 with_xft=$with_features
4282 fi
4283
4284
4285 # Check whether --with-libotf was given.
4286 if test "${with_libotf+set}" = set; then :
4287 withval=$with_libotf;
4288 else
4289 with_libotf=$with_features
4290 fi
4291
4292
4293 # Check whether --with-m17n-flt was given.
4294 if test "${with_m17n_flt+set}" = set; then :
4295 withval=$with_m17n_flt;
4296 else
4297 with_m17n_flt=$with_features
4298 fi
4299
4300
4301
4302 # Check whether --with-toolkit-scroll-bars was given.
4303 if test "${with_toolkit_scroll_bars+set}" = set; then :
4304 withval=$with_toolkit_scroll_bars;
4305 else
4306 with_toolkit_scroll_bars=$with_features
4307 fi
4308
4309
4310 # Check whether --with-xaw3d was given.
4311 if test "${with_xaw3d+set}" = set; then :
4312 withval=$with_xaw3d;
4313 else
4314 with_xaw3d=$with_features
4315 fi
4316
4317
4318 # Check whether --with-xim was given.
4319 if test "${with_xim+set}" = set; then :
4320 withval=$with_xim;
4321 else
4322 with_xim=$with_features
4323 fi
4324
4325
4326 # Check whether --with-ns was given.
4327 if test "${with_ns+set}" = set; then :
4328 withval=$with_ns;
4329 else
4330 with_ns=no
4331 fi
4332
4333
4334 # Check whether --with-w32 was given.
4335 if test "${with_w32+set}" = set; then :
4336 withval=$with_w32;
4337 else
4338 with_w32=no
4339 fi
4340
4341
4342
4343 # Check whether --with-gpm was given.
4344 if test "${with_gpm+set}" = set; then :
4345 withval=$with_gpm;
4346 else
4347 with_gpm=$with_features
4348 fi
4349
4350
4351 # Check whether --with-dbus was given.
4352 if test "${with_dbus+set}" = set; then :
4353 withval=$with_dbus;
4354 else
4355 with_dbus=$with_features
4356 fi
4357
4358
4359 # Check whether --with-gconf was given.
4360 if test "${with_gconf+set}" = set; then :
4361 withval=$with_gconf;
4362 else
4363 with_gconf=$with_features
4364 fi
4365
4366
4367 # Check whether --with-gsettings was given.
4368 if test "${with_gsettings+set}" = set; then :
4369 withval=$with_gsettings;
4370 else
4371 with_gsettings=$with_features
4372 fi
4373
4374
4375 # Check whether --with-selinux was given.
4376 if test "${with_selinux+set}" = set; then :
4377 withval=$with_selinux;
4378 else
4379 with_selinux=$with_features
4380 fi
4381
4382
4383 # Check whether --with-gnutls was given.
4384 if test "${with_gnutls+set}" = set; then :
4385 withval=$with_gnutls;
4386 else
4387 with_gnutls=$with_features
4388 fi
4389
4390
4391 # Check whether --with-zlib was given.
4392 if test "${with_zlib+set}" = set; then :
4393 withval=$with_zlib;
4394 else
4395 with_zlib=$with_features
4396 fi
4397
4398
4399
4400 # Check whether --with-file-notification was given.
4401 if test "${with_file_notification+set}" = set; then :
4402 withval=$with_file_notification; case "${withval}" in
4403 y | ye | yes ) val=yes ;;
4404 n | no ) val=no ;;
4405 g | gf | gfi | gfil | gfile ) val=gfile ;;
4406 i | in | ino | inot | inoti | inotif | inotify ) val=inotify ;;
4407 w | w3 | w32 ) val=w32 ;;
4408 * ) as_fn_error "\`--with-file-notification=$withval' is invalid;
4409 this option's value should be \`yes', \`no', \`gfile', \`inotify' or \`w32'.
4410 \`yes' is a synonym for \`w32' on MS-Windows, for \`no' on Nextstep,
4411 otherwise for the first of \`gfile' or \`inotify' that is usable." "$LINENO" 5
4412 ;;
4413 esac
4414 with_file_notification=$val
4415
4416 else
4417 with_file_notification=$with_features
4418 fi
4419
4420
4421 ## For the times when you want to build Emacs but don't have
4422 ## a suitable makeinfo, and can live without the manuals.
4423
4424 # Check whether --with-makeinfo was given.
4425 if test "${with_makeinfo+set}" = set; then :
4426 withval=$with_makeinfo;
4427 else
4428 with_makeinfo=$with_features
4429 fi
4430
4431
4432 ## Makefile.in needs the cache file name.
4433
4434
4435 ## This is an option because I do not know if all info/man support
4436 ## compressed files, nor how to test if they do so.
4437
4438 # Check whether --with-compress-install was given.
4439 if test "${with_compress_install+set}" = set; then :
4440 withval=$with_compress_install;
4441 else
4442 with_compress_install=$with_features
4443 fi
4444
4445
4446
4447 # Check whether --with-pkg-config-prog was given.
4448 if test "${with_pkg_config_prog+set}" = set; then :
4449 withval=$with_pkg_config_prog;
4450 fi
4451
4452 if test "X${with_pkg_config_prog}" != X; then
4453 if test "${with_pkg_config_prog}" != yes; then
4454 PKG_CONFIG="${with_pkg_config_prog}"
4455 fi
4456 fi
4457
4458
4459 # Check whether --with-gameuser was given.
4460 if test "${with_gameuser+set}" = set; then :
4461 withval=$with_gameuser;
4462 fi
4463
4464 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4465 && gameuser="${with_gameuser}"
4466 test "X$gameuser" = X && gameuser=games
4467
4468
4469 # Check whether --with-gnustep-conf was given.
4470 if test "${with_gnustep_conf+set}" = set; then :
4471 withval=$with_gnustep_conf;
4472 fi
4473
4474 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4475 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4476 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4477 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4478
4479 # Check whether --enable-ns-self-contained was given.
4480 if test "${enable_ns_self_contained+set}" = set; then :
4481 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4482 else
4483 EN_NS_SELF_CONTAINED=yes
4484 fi
4485
4486
4487 # Check whether --enable-locallisppath was given.
4488 if test "${enable_locallisppath+set}" = set; then :
4489 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4490 locallisppath=
4491 elif test "${enableval}" != "yes"; then
4492 locallisppath=${enableval}
4493 fi
4494 fi
4495
4496
4497 # Check whether --enable-checking was given.
4498 if test "${enable_checking+set}" = set; then :
4499 enableval=$enable_checking; ac_checking_flags="${enableval}"
4500 fi
4501
4502 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4503 for check in $ac_checking_flags
4504 do
4505 case $check in
4506 # these set all the flags to specific states
4507 yes) ac_enable_checking=1 ;;
4508 no) ac_enable_checking= ;
4509 ac_gc_check_stringbytes= ;
4510 ac_gc_check_string_overrun= ;
4511 ac_gc_check_string_free_list= ;
4512 ac_xmalloc_overrun= ;
4513 ac_gc_check_cons_list= ;
4514 ac_glyphs_debug= ;;
4515 all) ac_enable_checking=1 ;
4516 ac_gc_check_stringbytes=1 ;
4517 ac_gc_check_string_overrun=1 ;
4518 ac_gc_check_string_free_list=1 ;
4519 ac_xmalloc_overrun=1 ;
4520 ac_gc_check_cons_list=1 ;
4521 ac_glyphs_debug=1 ;;
4522 # these enable particular checks
4523 stringbytes) ac_gc_check_stringbytes=1 ;;
4524 stringoverrun) ac_gc_check_string_overrun=1 ;;
4525 stringfreelist) ac_gc_check_string_free_list=1 ;;
4526 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4527 conslist) ac_gc_check_cons_list=1 ;;
4528 glyphs) ac_glyphs_debug=1 ;;
4529 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4530 esac
4531 done
4532 IFS="$ac_save_IFS"
4533
4534 if test x$ac_enable_checking != x ; then
4535
4536 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4537
4538 fi
4539 if test x$ac_gc_check_stringbytes != x ; then
4540
4541 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4542
4543 fi
4544 if test x$ac_gc_check_string_overrun != x ; then
4545
4546 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4547
4548 fi
4549 if test x$ac_gc_check_string_free_list != x ; then
4550
4551 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4552
4553 fi
4554 if test x$ac_xmalloc_overrun != x ; then
4555
4556 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4557
4558 fi
4559 if test x$ac_gc_check_cons_list != x ; then
4560
4561 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4562
4563 fi
4564 if test x$ac_glyphs_debug != x ; then
4565
4566 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4567
4568 fi
4569
4570 # Check whether --enable-check-lisp-object-type was given.
4571 if test "${enable_check_lisp_object_type+set}" = set; then :
4572 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4573
4574 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4575
4576 fi
4577 fi
4578
4579
4580
4581 # Check whether --enable-profiling was given.
4582 if test "${enable_profiling+set}" = set; then :
4583 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4584 fi
4585
4586 if test x$ac_enable_profiling != x ; then
4587 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4588 else
4589 PROFILING_CFLAGS=
4590 fi
4591
4592
4593 # Check whether --enable-autodepend was given.
4594 if test "${enable_autodepend+set}" = set; then :
4595 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4596 else
4597 ac_enable_autodepend=yes
4598 fi
4599
4600
4601 # Check whether --enable-gtk-deprecation-warnings was given.
4602 if test "${enable_gtk_deprecation_warnings+set}" = set; then :
4603 enableval=$enable_gtk_deprecation_warnings; ac_enable_gtk_deprecation_warnings="${enableval}"
4604 fi
4605
4606
4607 #### When building with MinGW inside the MSYS tree, 'pwd' produces
4608 #### directories relative to the root of the MSYS tree,
4609 #### e.g. '/home/user/foo' instead of '/d/MSYS/home/user/foo'. When
4610 #### such a value of srcdir is written to the top-level Makefile, it
4611 #### gets propagated to src/epaths.h, and that causes temacs to fail,
4612 #### because, being a MinGW program that knows nothing of MSYS root
4613 #### substitution, it cannot find the data directory. "pwd -W"
4614 #### produces Windows-style 'd:/foo/bar' absolute directory names, so
4615 #### we use it here to countermand that lossage.
4616 test "$MSYSTEM" = "MINGW32" && abs_srcdir=`(cd "$abs_srcdir"; pwd -W | sed -e 's,^\([A-Za-z]\):,/\1,')`
4617
4618 ### Canonicalize the configuration name.
4619
4620 # Make sure we can run config.sub.
4621 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4622 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4623
4624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4625 $as_echo_n "checking build system type... " >&6; }
4626 if test "${ac_cv_build+set}" = set; then :
4627 $as_echo_n "(cached) " >&6
4628 else
4629 ac_build_alias=$build_alias
4630 test "x$ac_build_alias" = x &&
4631 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4632 test "x$ac_build_alias" = x &&
4633 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4634 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4635 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4636
4637 fi
4638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4639 $as_echo "$ac_cv_build" >&6; }
4640 case $ac_cv_build in
4641 *-*-*) ;;
4642 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4643 esac
4644 build=$ac_cv_build
4645 ac_save_IFS=$IFS; IFS='-'
4646 set x $ac_cv_build
4647 shift
4648 build_cpu=$1
4649 build_vendor=$2
4650 shift; shift
4651 # Remember, the first character of IFS is used to create $*,
4652 # except with old shells:
4653 build_os=$*
4654 IFS=$ac_save_IFS
4655 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4656
4657
4658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4659 $as_echo_n "checking host system type... " >&6; }
4660 if test "${ac_cv_host+set}" = set; then :
4661 $as_echo_n "(cached) " >&6
4662 else
4663 if test "x$host_alias" = x; then
4664 ac_cv_host=$ac_cv_build
4665 else
4666 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4667 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4668 fi
4669
4670 fi
4671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4672 $as_echo "$ac_cv_host" >&6; }
4673 case $ac_cv_host in
4674 *-*-*) ;;
4675 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4676 esac
4677 host=$ac_cv_host
4678 ac_save_IFS=$IFS; IFS='-'
4679 set x $ac_cv_host
4680 shift
4681 host_cpu=$1
4682 host_vendor=$2
4683 shift; shift
4684 # Remember, the first character of IFS is used to create $*,
4685 # except with old shells:
4686 host_os=$*
4687 IFS=$ac_save_IFS
4688 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4689
4690
4691 canonical=$host
4692 configuration=${host_alias-${build_alias-$host}}
4693
4694
4695
4696 ### If you add support for a new configuration, add code to this
4697 ### switch statement to recognize your configuration name and select
4698 ### the appropriate operating system file.
4699
4700 ### You would hope that you could choose an s/*.h
4701 ### file based on the operating system portion. However, it turns out
4702 ### that each s/*.h file is pretty manufacturer-specific.
4703 ### So we basically have to have a special case for each
4704 ### configuration name.
4705 ###
4706 ### As far as handling version numbers on operating systems is
4707 ### concerned, make sure things will fail in a fixable way. If
4708 ### /etc/MACHINES doesn't say anything about version numbers, be
4709 ### prepared to handle anything reasonably. If version numbers
4710 ### matter, be sure /etc/MACHINES says something about it.
4711
4712 opsys='' unported=no
4713 case "${canonical}" in
4714
4715 ## GNU/Linux and similar ports
4716 *-*-linux* )
4717 opsys=gnu-linux
4718 ;;
4719
4720 ## FreeBSD ports
4721 *-*-freebsd* )
4722 opsys=freebsd
4723 ;;
4724
4725 ## DragonFly ports
4726 *-*-dragonfly* )
4727 opsys=dragonfly
4728 ;;
4729
4730 ## FreeBSD kernel + glibc based userland
4731 *-*-kfreebsd*gnu* )
4732 opsys=gnu-kfreebsd
4733 ;;
4734
4735 ## NetBSD ports
4736 *-*-netbsd* )
4737 opsys=netbsd
4738 ;;
4739
4740 ## OpenBSD ports
4741 *-*-openbsd* )
4742 opsys=openbsd
4743 ;;
4744
4745 ## Apple Darwin / Mac OS X
4746 *-apple-darwin* )
4747 case "${canonical}" in
4748 i[3456]86-* ) ;;
4749 powerpc-* ) ;;
4750 x86_64-* ) ;;
4751 * ) unported=yes ;;
4752 esac
4753 opsys=darwin
4754 ## Use fink packages if available.
4755 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4756 ## if test -d /sw/include && test -d /sw/lib; then
4757 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4758 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4759 ## fi
4760 ;;
4761
4762 ## Cygwin ports
4763 *-*-cygwin )
4764 opsys=cygwin
4765 ;;
4766
4767 ## HP 9000 series 700 and 800, running HP/UX
4768 hppa*-hp-hpux10.2* )
4769 opsys=hpux10-20
4770 ;;
4771 hppa*-hp-hpux1[1-9]* )
4772 opsys=hpux11
4773 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4774 ;;
4775
4776 ## IBM machines
4777 rs6000-ibm-aix4.[23]* )
4778 opsys=aix4-2
4779 ;;
4780 powerpc-ibm-aix4.[23]* )
4781 opsys=aix4-2
4782 ;;
4783 rs6000-ibm-aix[56]* )
4784 opsys=aix4-2
4785 ;;
4786 powerpc-ibm-aix[56]* )
4787 opsys=aix4-2
4788 ;;
4789
4790 ## Silicon Graphics machines
4791 ## Iris 4D
4792 mips-sgi-irix6.5 )
4793 opsys=irix6-5
4794 # Without defining _LANGUAGE_C, things get masked out in the headers
4795 # so that, for instance, grepping for `free' in stdlib.h fails and
4796 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4797 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4798 ;;
4799
4800 ## Suns
4801 *-sun-solaris* \
4802 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4803 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4804 case "${canonical}" in
4805 i[3456]86-*-* ) ;;
4806 amd64-*-*|x86_64-*-*) ;;
4807 sparc* ) ;;
4808 * ) unported=yes ;;
4809 esac
4810 case "${canonical}" in
4811 *-sunos5.6* | *-solaris2.6* )
4812 opsys=sol2-6
4813 RANLIB="ar -ts"
4814 ;;
4815 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4816 opsys=sol2-6
4817 emacs_check_sunpro_c=yes
4818 ;;
4819 *-sunos5* | *-solaris* )
4820 opsys=sol2-10
4821 emacs_check_sunpro_c=yes
4822 ;;
4823 esac
4824 ## Watch out for a compiler that we know will not work.
4825 case "${canonical}" in
4826 *-solaris* | *-sunos5* )
4827 if [ "x$CC" = x/usr/ucb/cc ]; then
4828 ## /usr/ucb/cc doesn't work;
4829 ## we should find some other compiler that does work.
4830 unset CC
4831 fi
4832 ;;
4833 *) ;;
4834 esac
4835 ;;
4836
4837 ## Intel 386 machines where we don't care about the manufacturer.
4838 i[3456]86-*-* )
4839 case "${canonical}" in
4840 *-darwin* ) opsys=darwin ;;
4841 *-mingw32 )
4842 opsys=mingw32
4843 # MinGW overrides and adds some system headers in nt/inc.
4844 GCC_TEST_OPTIONS="-I $srcdir/nt/inc"
4845 ;;
4846 *-sysv4.2uw* ) opsys=unixware ;;
4847 *-sysv5uw* ) opsys=unixware ;;
4848 *-sysv5OpenUNIX* ) opsys=unixware ;;
4849 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4850 esac
4851 ;;
4852
4853 * )
4854 unported=yes
4855 ;;
4856 esac
4857
4858 ### If the code above didn't choose an operating system, just choose
4859 ### an operating system based on the configuration name. You really
4860 ### only want to use this when you have no idea what the right
4861 ### operating system is; if you know what operating systems a machine
4862 ### runs, it's cleaner to make it explicit in the case statement
4863 ### above.
4864 if test x"${opsys}" = x; then
4865 case "${canonical}" in
4866 *-gnu* ) opsys=gnu ;;
4867 * )
4868 unported=yes
4869 ;;
4870 esac
4871 fi
4872
4873
4874
4875 if test $unported = yes; then
4876 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4877 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4878 fi
4879
4880
4881 #### Choose a compiler.
4882
4883 ac_ext=c
4884 ac_cpp='$CPP $CPPFLAGS'
4885 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4886 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4887 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4888 if test -n "$ac_tool_prefix"; then
4889 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4890 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4892 $as_echo_n "checking for $ac_word... " >&6; }
4893 if test "${ac_cv_prog_CC+set}" = set; then :
4894 $as_echo_n "(cached) " >&6
4895 else
4896 if test -n "$CC"; then
4897 ac_cv_prog_CC="$CC" # Let the user override the test.
4898 else
4899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4900 for as_dir in $PATH
4901 do
4902 IFS=$as_save_IFS
4903 test -z "$as_dir" && as_dir=.
4904 for ac_exec_ext in '' $ac_executable_extensions; do
4905 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4906 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4908 break 2
4909 fi
4910 done
4911 done
4912 IFS=$as_save_IFS
4913
4914 fi
4915 fi
4916 CC=$ac_cv_prog_CC
4917 if test -n "$CC"; then
4918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4919 $as_echo "$CC" >&6; }
4920 else
4921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4922 $as_echo "no" >&6; }
4923 fi
4924
4925
4926 fi
4927 if test -z "$ac_cv_prog_CC"; then
4928 ac_ct_CC=$CC
4929 # Extract the first word of "gcc", so it can be a program name with args.
4930 set dummy gcc; ac_word=$2
4931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4932 $as_echo_n "checking for $ac_word... " >&6; }
4933 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4934 $as_echo_n "(cached) " >&6
4935 else
4936 if test -n "$ac_ct_CC"; then
4937 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4938 else
4939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4940 for as_dir in $PATH
4941 do
4942 IFS=$as_save_IFS
4943 test -z "$as_dir" && as_dir=.
4944 for ac_exec_ext in '' $ac_executable_extensions; do
4945 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4946 ac_cv_prog_ac_ct_CC="gcc"
4947 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4948 break 2
4949 fi
4950 done
4951 done
4952 IFS=$as_save_IFS
4953
4954 fi
4955 fi
4956 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4957 if test -n "$ac_ct_CC"; then
4958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4959 $as_echo "$ac_ct_CC" >&6; }
4960 else
4961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4962 $as_echo "no" >&6; }
4963 fi
4964
4965 if test "x$ac_ct_CC" = x; then
4966 CC=""
4967 else
4968 case $cross_compiling:$ac_tool_warned in
4969 yes:)
4970 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4971 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4972 ac_tool_warned=yes ;;
4973 esac
4974 CC=$ac_ct_CC
4975 fi
4976 else
4977 CC="$ac_cv_prog_CC"
4978 fi
4979
4980 if test -z "$CC"; then
4981 if test -n "$ac_tool_prefix"; then
4982 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4983 set dummy ${ac_tool_prefix}cc; ac_word=$2
4984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4985 $as_echo_n "checking for $ac_word... " >&6; }
4986 if test "${ac_cv_prog_CC+set}" = set; then :
4987 $as_echo_n "(cached) " >&6
4988 else
4989 if test -n "$CC"; then
4990 ac_cv_prog_CC="$CC" # Let the user override the test.
4991 else
4992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4993 for as_dir in $PATH
4994 do
4995 IFS=$as_save_IFS
4996 test -z "$as_dir" && as_dir=.
4997 for ac_exec_ext in '' $ac_executable_extensions; do
4998 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4999 ac_cv_prog_CC="${ac_tool_prefix}cc"
5000 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5001 break 2
5002 fi
5003 done
5004 done
5005 IFS=$as_save_IFS
5006
5007 fi
5008 fi
5009 CC=$ac_cv_prog_CC
5010 if test -n "$CC"; then
5011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5012 $as_echo "$CC" >&6; }
5013 else
5014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5015 $as_echo "no" >&6; }
5016 fi
5017
5018
5019 fi
5020 fi
5021 if test -z "$CC"; then
5022 # Extract the first word of "cc", so it can be a program name with args.
5023 set dummy cc; ac_word=$2
5024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5025 $as_echo_n "checking for $ac_word... " >&6; }
5026 if test "${ac_cv_prog_CC+set}" = set; then :
5027 $as_echo_n "(cached) " >&6
5028 else
5029 if test -n "$CC"; then
5030 ac_cv_prog_CC="$CC" # Let the user override the test.
5031 else
5032 ac_prog_rejected=no
5033 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5034 for as_dir in $PATH
5035 do
5036 IFS=$as_save_IFS
5037 test -z "$as_dir" && as_dir=.
5038 for ac_exec_ext in '' $ac_executable_extensions; do
5039 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5040 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
5041 ac_prog_rejected=yes
5042 continue
5043 fi
5044 ac_cv_prog_CC="cc"
5045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5046 break 2
5047 fi
5048 done
5049 done
5050 IFS=$as_save_IFS
5051
5052 if test $ac_prog_rejected = yes; then
5053 # We found a bogon in the path, so make sure we never use it.
5054 set dummy $ac_cv_prog_CC
5055 shift
5056 if test $# != 0; then
5057 # We chose a different compiler from the bogus one.
5058 # However, it has the same basename, so the bogon will be chosen
5059 # first if we set CC to just the basename; use the full file name.
5060 shift
5061 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
5062 fi
5063 fi
5064 fi
5065 fi
5066 CC=$ac_cv_prog_CC
5067 if test -n "$CC"; then
5068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5069 $as_echo "$CC" >&6; }
5070 else
5071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5072 $as_echo "no" >&6; }
5073 fi
5074
5075
5076 fi
5077 if test -z "$CC"; then
5078 if test -n "$ac_tool_prefix"; then
5079 for ac_prog in cl.exe
5080 do
5081 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
5082 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
5083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5084 $as_echo_n "checking for $ac_word... " >&6; }
5085 if test "${ac_cv_prog_CC+set}" = set; then :
5086 $as_echo_n "(cached) " >&6
5087 else
5088 if test -n "$CC"; then
5089 ac_cv_prog_CC="$CC" # Let the user override the test.
5090 else
5091 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5092 for as_dir in $PATH
5093 do
5094 IFS=$as_save_IFS
5095 test -z "$as_dir" && as_dir=.
5096 for ac_exec_ext in '' $ac_executable_extensions; do
5097 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5098 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
5099 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5100 break 2
5101 fi
5102 done
5103 done
5104 IFS=$as_save_IFS
5105
5106 fi
5107 fi
5108 CC=$ac_cv_prog_CC
5109 if test -n "$CC"; then
5110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
5111 $as_echo "$CC" >&6; }
5112 else
5113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5114 $as_echo "no" >&6; }
5115 fi
5116
5117
5118 test -n "$CC" && break
5119 done
5120 fi
5121 if test -z "$CC"; then
5122 ac_ct_CC=$CC
5123 for ac_prog in cl.exe
5124 do
5125 # Extract the first word of "$ac_prog", so it can be a program name with args.
5126 set dummy $ac_prog; ac_word=$2
5127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5128 $as_echo_n "checking for $ac_word... " >&6; }
5129 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
5130 $as_echo_n "(cached) " >&6
5131 else
5132 if test -n "$ac_ct_CC"; then
5133 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
5134 else
5135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5136 for as_dir in $PATH
5137 do
5138 IFS=$as_save_IFS
5139 test -z "$as_dir" && as_dir=.
5140 for ac_exec_ext in '' $ac_executable_extensions; do
5141 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5142 ac_cv_prog_ac_ct_CC="$ac_prog"
5143 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5144 break 2
5145 fi
5146 done
5147 done
5148 IFS=$as_save_IFS
5149
5150 fi
5151 fi
5152 ac_ct_CC=$ac_cv_prog_ac_ct_CC
5153 if test -n "$ac_ct_CC"; then
5154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
5155 $as_echo "$ac_ct_CC" >&6; }
5156 else
5157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5158 $as_echo "no" >&6; }
5159 fi
5160
5161
5162 test -n "$ac_ct_CC" && break
5163 done
5164
5165 if test "x$ac_ct_CC" = x; then
5166 CC=""
5167 else
5168 case $cross_compiling:$ac_tool_warned in
5169 yes:)
5170 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5171 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5172 ac_tool_warned=yes ;;
5173 esac
5174 CC=$ac_ct_CC
5175 fi
5176 fi
5177
5178 fi
5179
5180
5181 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5182 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5183 as_fn_error "no acceptable C compiler found in \$PATH
5184 See \`config.log' for more details." "$LINENO" 5; }
5185
5186 # Provide some information about the compiler.
5187 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
5188 set X $ac_compile
5189 ac_compiler=$2
5190 for ac_option in --version -v -V -qversion; do
5191 { { ac_try="$ac_compiler $ac_option >&5"
5192 case "(($ac_try" in
5193 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5194 *) ac_try_echo=$ac_try;;
5195 esac
5196 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5197 $as_echo "$ac_try_echo"; } >&5
5198 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
5199 ac_status=$?
5200 if test -s conftest.err; then
5201 sed '10a\
5202 ... rest of stderr output deleted ...
5203 10q' conftest.err >conftest.er1
5204 cat conftest.er1 >&5
5205 fi
5206 rm -f conftest.er1 conftest.err
5207 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5208 test $ac_status = 0; }
5209 done
5210
5211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5212 /* end confdefs.h. */
5213
5214 int
5215 main ()
5216 {
5217
5218 ;
5219 return 0;
5220 }
5221 _ACEOF
5222 ac_clean_files_save=$ac_clean_files
5223 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
5224 # Try to create an executable without -o first, disregard a.out.
5225 # It will help us diagnose broken compilers, and finding out an intuition
5226 # of exeext.
5227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
5228 $as_echo_n "checking whether the C compiler works... " >&6; }
5229 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
5230
5231 # The possible output files:
5232 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
5233
5234 ac_rmfiles=
5235 for ac_file in $ac_files
5236 do
5237 case $ac_file in
5238 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5239 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
5240 esac
5241 done
5242 rm -f $ac_rmfiles
5243
5244 if { { ac_try="$ac_link_default"
5245 case "(($ac_try" in
5246 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5247 *) ac_try_echo=$ac_try;;
5248 esac
5249 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5250 $as_echo "$ac_try_echo"; } >&5
5251 (eval "$ac_link_default") 2>&5
5252 ac_status=$?
5253 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5254 test $ac_status = 0; }; then :
5255 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
5256 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
5257 # in a Makefile. We should not override ac_cv_exeext if it was cached,
5258 # so that the user can short-circuit this test for compilers unknown to
5259 # Autoconf.
5260 for ac_file in $ac_files ''
5261 do
5262 test -f "$ac_file" || continue
5263 case $ac_file in
5264 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5265 ;;
5266 [ab].out )
5267 # We found the default executable, but exeext='' is most
5268 # certainly right.
5269 break;;
5270 *.* )
5271 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5272 then :; else
5273 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5274 fi
5275 # We set ac_cv_exeext here because the later test for it is not
5276 # safe: cross compilers may not add the suffix if given an `-o'
5277 # argument, so we may need to know it at that point already.
5278 # Even if this section looks crufty: it has the advantage of
5279 # actually working.
5280 break;;
5281 * )
5282 break;;
5283 esac
5284 done
5285 test "$ac_cv_exeext" = no && ac_cv_exeext=
5286
5287 else
5288 ac_file=''
5289 fi
5290 if test -z "$ac_file"; then :
5291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5292 $as_echo "no" >&6; }
5293 $as_echo "$as_me: failed program was:" >&5
5294 sed 's/^/| /' conftest.$ac_ext >&5
5295
5296 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5297 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5298 { as_fn_set_status 77
5299 as_fn_error "C compiler cannot create executables
5300 See \`config.log' for more details." "$LINENO" 5; }; }
5301 else
5302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5303 $as_echo "yes" >&6; }
5304 fi
5305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5306 $as_echo_n "checking for C compiler default output file name... " >&6; }
5307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5308 $as_echo "$ac_file" >&6; }
5309 ac_exeext=$ac_cv_exeext
5310
5311 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5312 ac_clean_files=$ac_clean_files_save
5313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5314 $as_echo_n "checking for suffix of executables... " >&6; }
5315 if { { ac_try="$ac_link"
5316 case "(($ac_try" in
5317 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5318 *) ac_try_echo=$ac_try;;
5319 esac
5320 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5321 $as_echo "$ac_try_echo"; } >&5
5322 (eval "$ac_link") 2>&5
5323 ac_status=$?
5324 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5325 test $ac_status = 0; }; then :
5326 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5327 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5328 # work properly (i.e., refer to `conftest.exe'), while it won't with
5329 # `rm'.
5330 for ac_file in conftest.exe conftest conftest.*; do
5331 test -f "$ac_file" || continue
5332 case $ac_file in
5333 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5334 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5335 break;;
5336 * ) break;;
5337 esac
5338 done
5339 else
5340 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5341 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5342 as_fn_error "cannot compute suffix of executables: cannot compile and link
5343 See \`config.log' for more details." "$LINENO" 5; }
5344 fi
5345 rm -f conftest conftest$ac_cv_exeext
5346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5347 $as_echo "$ac_cv_exeext" >&6; }
5348
5349 rm -f conftest.$ac_ext
5350 EXEEXT=$ac_cv_exeext
5351 ac_exeext=$EXEEXT
5352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5353 /* end confdefs.h. */
5354 #include <stdio.h>
5355 int
5356 main ()
5357 {
5358 FILE *f = fopen ("conftest.out", "w");
5359 return ferror (f) || fclose (f) != 0;
5360
5361 ;
5362 return 0;
5363 }
5364 _ACEOF
5365 ac_clean_files="$ac_clean_files conftest.out"
5366 # Check that the compiler produces executables we can run. If not, either
5367 # the compiler is broken, or we cross compile.
5368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5369 $as_echo_n "checking whether we are cross compiling... " >&6; }
5370 if test "$cross_compiling" != yes; then
5371 { { ac_try="$ac_link"
5372 case "(($ac_try" in
5373 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5374 *) ac_try_echo=$ac_try;;
5375 esac
5376 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5377 $as_echo "$ac_try_echo"; } >&5
5378 (eval "$ac_link") 2>&5
5379 ac_status=$?
5380 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5381 test $ac_status = 0; }
5382 if { ac_try='./conftest$ac_cv_exeext'
5383 { { case "(($ac_try" in
5384 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5385 *) ac_try_echo=$ac_try;;
5386 esac
5387 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5388 $as_echo "$ac_try_echo"; } >&5
5389 (eval "$ac_try") 2>&5
5390 ac_status=$?
5391 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5392 test $ac_status = 0; }; }; then
5393 cross_compiling=no
5394 else
5395 if test "$cross_compiling" = maybe; then
5396 cross_compiling=yes
5397 else
5398 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5399 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5400 as_fn_error "cannot run C compiled programs.
5401 If you meant to cross compile, use \`--host'.
5402 See \`config.log' for more details." "$LINENO" 5; }
5403 fi
5404 fi
5405 fi
5406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5407 $as_echo "$cross_compiling" >&6; }
5408
5409 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5410 ac_clean_files=$ac_clean_files_save
5411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5412 $as_echo_n "checking for suffix of object files... " >&6; }
5413 if test "${ac_cv_objext+set}" = set; then :
5414 $as_echo_n "(cached) " >&6
5415 else
5416 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5417 /* end confdefs.h. */
5418
5419 int
5420 main ()
5421 {
5422
5423 ;
5424 return 0;
5425 }
5426 _ACEOF
5427 rm -f conftest.o conftest.obj
5428 if { { ac_try="$ac_compile"
5429 case "(($ac_try" in
5430 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5431 *) ac_try_echo=$ac_try;;
5432 esac
5433 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5434 $as_echo "$ac_try_echo"; } >&5
5435 (eval "$ac_compile") 2>&5
5436 ac_status=$?
5437 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5438 test $ac_status = 0; }; then :
5439 for ac_file in conftest.o conftest.obj conftest.*; do
5440 test -f "$ac_file" || continue;
5441 case $ac_file in
5442 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5443 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5444 break;;
5445 esac
5446 done
5447 else
5448 $as_echo "$as_me: failed program was:" >&5
5449 sed 's/^/| /' conftest.$ac_ext >&5
5450
5451 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5452 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5453 as_fn_error "cannot compute suffix of object files: cannot compile
5454 See \`config.log' for more details." "$LINENO" 5; }
5455 fi
5456 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5457 fi
5458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5459 $as_echo "$ac_cv_objext" >&6; }
5460 OBJEXT=$ac_cv_objext
5461 ac_objext=$OBJEXT
5462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5463 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5464 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5465 $as_echo_n "(cached) " >&6
5466 else
5467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5468 /* end confdefs.h. */
5469
5470 int
5471 main ()
5472 {
5473 #ifndef __GNUC__
5474 choke me
5475 #endif
5476
5477 ;
5478 return 0;
5479 }
5480 _ACEOF
5481 if ac_fn_c_try_compile "$LINENO"; then :
5482 ac_compiler_gnu=yes
5483 else
5484 ac_compiler_gnu=no
5485 fi
5486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5487 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5488
5489 fi
5490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5491 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5492 if test $ac_compiler_gnu = yes; then
5493 GCC=yes
5494 else
5495 GCC=
5496 fi
5497 ac_test_CFLAGS=${CFLAGS+set}
5498 ac_save_CFLAGS=$CFLAGS
5499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5500 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5501 if test "${ac_cv_prog_cc_g+set}" = set; then :
5502 $as_echo_n "(cached) " >&6
5503 else
5504 ac_save_c_werror_flag=$ac_c_werror_flag
5505 ac_c_werror_flag=yes
5506 ac_cv_prog_cc_g=no
5507 CFLAGS="-g"
5508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5509 /* end confdefs.h. */
5510
5511 int
5512 main ()
5513 {
5514
5515 ;
5516 return 0;
5517 }
5518 _ACEOF
5519 if ac_fn_c_try_compile "$LINENO"; then :
5520 ac_cv_prog_cc_g=yes
5521 else
5522 CFLAGS=""
5523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5524 /* end confdefs.h. */
5525
5526 int
5527 main ()
5528 {
5529
5530 ;
5531 return 0;
5532 }
5533 _ACEOF
5534 if ac_fn_c_try_compile "$LINENO"; then :
5535
5536 else
5537 ac_c_werror_flag=$ac_save_c_werror_flag
5538 CFLAGS="-g"
5539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5540 /* end confdefs.h. */
5541
5542 int
5543 main ()
5544 {
5545
5546 ;
5547 return 0;
5548 }
5549 _ACEOF
5550 if ac_fn_c_try_compile "$LINENO"; then :
5551 ac_cv_prog_cc_g=yes
5552 fi
5553 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5554 fi
5555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5556 fi
5557 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5558 ac_c_werror_flag=$ac_save_c_werror_flag
5559 fi
5560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5561 $as_echo "$ac_cv_prog_cc_g" >&6; }
5562 if test "$ac_test_CFLAGS" = set; then
5563 CFLAGS=$ac_save_CFLAGS
5564 elif test $ac_cv_prog_cc_g = yes; then
5565 if test "$GCC" = yes; then
5566 CFLAGS="-g -O2"
5567 else
5568 CFLAGS="-g"
5569 fi
5570 else
5571 if test "$GCC" = yes; then
5572 CFLAGS="-O2"
5573 else
5574 CFLAGS=
5575 fi
5576 fi
5577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5578 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5579 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5580 $as_echo_n "(cached) " >&6
5581 else
5582 ac_cv_prog_cc_c89=no
5583 ac_save_CC=$CC
5584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5585 /* end confdefs.h. */
5586 #include <stdarg.h>
5587 #include <stdio.h>
5588 #include <sys/types.h>
5589 #include <sys/stat.h>
5590 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5591 struct buf { int x; };
5592 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5593 static char *e (p, i)
5594 char **p;
5595 int i;
5596 {
5597 return p[i];
5598 }
5599 static char *f (char * (*g) (char **, int), char **p, ...)
5600 {
5601 char *s;
5602 va_list v;
5603 va_start (v,p);
5604 s = g (p, va_arg (v,int));
5605 va_end (v);
5606 return s;
5607 }
5608
5609 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5610 function prototypes and stuff, but not '\xHH' hex character constants.
5611 These don't provoke an error unfortunately, instead are silently treated
5612 as 'x'. The following induces an error, until -std is added to get
5613 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5614 array size at least. It's necessary to write '\x00'==0 to get something
5615 that's true only with -std. */
5616 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5617
5618 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5619 inside strings and character constants. */
5620 #define FOO(x) 'x'
5621 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5622
5623 int test (int i, double x);
5624 struct s1 {int (*f) (int a);};
5625 struct s2 {int (*f) (double a);};
5626 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5627 int argc;
5628 char **argv;
5629 int
5630 main ()
5631 {
5632 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5633 ;
5634 return 0;
5635 }
5636 _ACEOF
5637 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5638 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5639 do
5640 CC="$ac_save_CC $ac_arg"
5641 if ac_fn_c_try_compile "$LINENO"; then :
5642 ac_cv_prog_cc_c89=$ac_arg
5643 fi
5644 rm -f core conftest.err conftest.$ac_objext
5645 test "x$ac_cv_prog_cc_c89" != "xno" && break
5646 done
5647 rm -f conftest.$ac_ext
5648 CC=$ac_save_CC
5649
5650 fi
5651 # AC_CACHE_VAL
5652 case "x$ac_cv_prog_cc_c89" in
5653 x)
5654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5655 $as_echo "none needed" >&6; } ;;
5656 xno)
5657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5658 $as_echo "unsupported" >&6; } ;;
5659 *)
5660 CC="$CC $ac_cv_prog_cc_c89"
5661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5662 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5663 esac
5664 if test "x$ac_cv_prog_cc_c89" != xno; then :
5665
5666 fi
5667
5668 ac_ext=c
5669 ac_cpp='$CPP $CPPFLAGS'
5670 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5671 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5672 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5673 DEPDIR="${am__leading_dot}deps"
5674
5675 ac_config_commands="$ac_config_commands depfiles"
5676
5677
5678 am_make=${MAKE-make}
5679 cat > confinc << 'END'
5680 am__doit:
5681 @echo this is the am__doit target
5682 .PHONY: am__doit
5683 END
5684 # If we don't find an include directive, just comment out the code.
5685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5686 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5687 am__include="#"
5688 am__quote=
5689 _am_result=none
5690 # First try GNU make style include.
5691 echo "include confinc" > confmf
5692 # Ignore all kinds of additional output from `make'.
5693 case `$am_make -s -f confmf 2> /dev/null` in #(
5694 *the\ am__doit\ target*)
5695 am__include=include
5696 am__quote=
5697 _am_result=GNU
5698 ;;
5699 esac
5700 # Now try BSD make style include.
5701 if test "$am__include" = "#"; then
5702 echo '.include "confinc"' > confmf
5703 case `$am_make -s -f confmf 2> /dev/null` in #(
5704 *the\ am__doit\ target*)
5705 am__include=.include
5706 am__quote="\""
5707 _am_result=BSD
5708 ;;
5709 esac
5710 fi
5711
5712
5713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5714 $as_echo "$_am_result" >&6; }
5715 rm -f confinc confmf
5716
5717 # Check whether --enable-dependency-tracking was given.
5718 if test "${enable_dependency_tracking+set}" = set; then :
5719 enableval=$enable_dependency_tracking;
5720 fi
5721
5722 if test "x$enable_dependency_tracking" != xno; then
5723 am_depcomp="$ac_aux_dir/depcomp"
5724 AMDEPBACKSLASH='\'
5725 fi
5726 if test "x$enable_dependency_tracking" != xno; then
5727 AMDEP_TRUE=
5728 AMDEP_FALSE='#'
5729 else
5730 AMDEP_TRUE='#'
5731 AMDEP_FALSE=
5732 fi
5733
5734
5735
5736 depcc="$CC" am_compiler_list=
5737
5738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5739 $as_echo_n "checking dependency style of $depcc... " >&6; }
5740 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5741 $as_echo_n "(cached) " >&6
5742 else
5743 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5744 # We make a subdir and do the tests there. Otherwise we can end up
5745 # making bogus files that we don't know about and never remove. For
5746 # instance it was reported that on HP-UX the gcc test will end up
5747 # making a dummy file named `D' -- because `-MD' means `put the output
5748 # in D'.
5749 mkdir conftest.dir
5750 # Copy depcomp to subdir because otherwise we won't find it if we're
5751 # using a relative directory.
5752 cp "$am_depcomp" conftest.dir
5753 cd conftest.dir
5754 # We will build objects and dependencies in a subdirectory because
5755 # it helps to detect inapplicable dependency modes. For instance
5756 # both Tru64's cc and ICC support -MD to output dependencies as a
5757 # side effect of compilation, but ICC will put the dependencies in
5758 # the current directory while Tru64 will put them in the object
5759 # directory.
5760 mkdir sub
5761
5762 am_cv_CC_dependencies_compiler_type=none
5763 if test "$am_compiler_list" = ""; then
5764 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5765 fi
5766 am__universal=false
5767 case " $depcc " in #(
5768 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5769 esac
5770
5771 for depmode in $am_compiler_list; do
5772 # Setup a source with many dependencies, because some compilers
5773 # like to wrap large dependency lists on column 80 (with \), and
5774 # we should not choose a depcomp mode which is confused by this.
5775 #
5776 # We need to recreate these files for each test, as the compiler may
5777 # overwrite some of them when testing with obscure command lines.
5778 # This happens at least with the AIX C compiler.
5779 : > sub/conftest.c
5780 for i in 1 2 3 4 5 6; do
5781 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5782 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5783 # Solaris 8's {/usr,}/bin/sh.
5784 touch sub/conftst$i.h
5785 done
5786 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5787
5788 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5789 # mode. It turns out that the SunPro C++ compiler does not properly
5790 # handle `-M -o', and we need to detect this. Also, some Intel
5791 # versions had trouble with output in subdirs
5792 am__obj=sub/conftest.${OBJEXT-o}
5793 am__minus_obj="-o $am__obj"
5794 case $depmode in
5795 gcc)
5796 # This depmode causes a compiler race in universal mode.
5797 test "$am__universal" = false || continue
5798 ;;
5799 nosideeffect)
5800 # after this tag, mechanisms are not by side-effect, so they'll
5801 # only be used when explicitly requested
5802 if test "x$enable_dependency_tracking" = xyes; then
5803 continue
5804 else
5805 break
5806 fi
5807 ;;
5808 msvisualcpp | msvcmsys)
5809 # This compiler won't grok `-c -o', but also, the minuso test has
5810 # not run yet. These depmodes are late enough in the game, and
5811 # so weak that their functioning should not be impacted.
5812 am__obj=conftest.${OBJEXT-o}
5813 am__minus_obj=
5814 ;;
5815 none) break ;;
5816 esac
5817 if depmode=$depmode \
5818 source=sub/conftest.c object=$am__obj \
5819 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5820 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5821 >/dev/null 2>conftest.err &&
5822 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5823 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5824 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5825 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5826 # icc doesn't choke on unknown options, it will just issue warnings
5827 # or remarks (even with -Werror). So we grep stderr for any message
5828 # that says an option was ignored or not supported.
5829 # When given -MP, icc 7.0 and 7.1 complain thusly:
5830 # icc: Command line warning: ignoring option '-M'; no argument required
5831 # The diagnosis changed in icc 8.0:
5832 # icc: Command line remark: option '-MP' not supported
5833 if (grep 'ignoring option' conftest.err ||
5834 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5835 am_cv_CC_dependencies_compiler_type=$depmode
5836 break
5837 fi
5838 fi
5839 done
5840
5841 cd ..
5842 rm -rf conftest.dir
5843 else
5844 am_cv_CC_dependencies_compiler_type=none
5845 fi
5846
5847 fi
5848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5849 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5850 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5851
5852 if
5853 test "x$enable_dependency_tracking" != xno \
5854 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5855 am__fastdepCC_TRUE=
5856 am__fastdepCC_FALSE='#'
5857 else
5858 am__fastdepCC_TRUE='#'
5859 am__fastdepCC_FALSE=
5860 fi
5861
5862
5863 if test "x$CC" != xcc; then
5864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5865 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5866 else
5867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5868 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5869 fi
5870 set dummy $CC; ac_cc=`$as_echo "$2" |
5871 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5872 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5873 $as_echo_n "(cached) " >&6
5874 else
5875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5876 /* end confdefs.h. */
5877
5878 int
5879 main ()
5880 {
5881
5882 ;
5883 return 0;
5884 }
5885 _ACEOF
5886 # Make sure it works both with $CC and with simple cc.
5887 # We do the test twice because some compilers refuse to overwrite an
5888 # existing .o file with -o, though they will create one.
5889 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5890 rm -f conftest2.*
5891 if { { case "(($ac_try" in
5892 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5893 *) ac_try_echo=$ac_try;;
5894 esac
5895 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5896 $as_echo "$ac_try_echo"; } >&5
5897 (eval "$ac_try") 2>&5
5898 ac_status=$?
5899 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5900 test $ac_status = 0; } &&
5901 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5902 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5903 *) ac_try_echo=$ac_try;;
5904 esac
5905 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5906 $as_echo "$ac_try_echo"; } >&5
5907 (eval "$ac_try") 2>&5
5908 ac_status=$?
5909 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5910 test $ac_status = 0; };
5911 then
5912 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5913 if test "x$CC" != xcc; then
5914 # Test first that cc exists at all.
5915 if { ac_try='cc -c conftest.$ac_ext >&5'
5916 { { case "(($ac_try" in
5917 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5918 *) ac_try_echo=$ac_try;;
5919 esac
5920 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5921 $as_echo "$ac_try_echo"; } >&5
5922 (eval "$ac_try") 2>&5
5923 ac_status=$?
5924 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5925 test $ac_status = 0; }; }; then
5926 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5927 rm -f conftest2.*
5928 if { { case "(($ac_try" in
5929 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5930 *) ac_try_echo=$ac_try;;
5931 esac
5932 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5933 $as_echo "$ac_try_echo"; } >&5
5934 (eval "$ac_try") 2>&5
5935 ac_status=$?
5936 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5937 test $ac_status = 0; } &&
5938 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5939 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5940 *) ac_try_echo=$ac_try;;
5941 esac
5942 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5943 $as_echo "$ac_try_echo"; } >&5
5944 (eval "$ac_try") 2>&5
5945 ac_status=$?
5946 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5947 test $ac_status = 0; };
5948 then
5949 # cc works too.
5950 :
5951 else
5952 # cc exists but doesn't like -o.
5953 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5954 fi
5955 fi
5956 fi
5957 else
5958 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5959 fi
5960 rm -f core conftest*
5961
5962 fi
5963 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5965 $as_echo "yes" >&6; }
5966 else
5967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5968 $as_echo "no" >&6; }
5969
5970 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5971
5972 fi
5973
5974 # FIXME: we rely on the cache variable name because
5975 # there is no other way.
5976 set dummy $CC
5977 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5978 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5979 if test "$am_t" != yes; then
5980 # Losing compiler, so override with the script.
5981 # FIXME: It is wrong to rewrite CC.
5982 # But if we don't then we get into trouble of one sort or another.
5983 # A longer-term fix would be to have automake use am__CC in this case,
5984 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5985 CC="$am_aux_dir/compile $CC"
5986 fi
5987
5988
5989
5990 if test x$GCC = xyes; then
5991 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5992 else
5993 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5994 fi
5995
5996 if test "x$opsys" = "xmingw32"; then
5997 BUILDING_FOR_WINDOWSNT_TRUE=
5998 BUILDING_FOR_WINDOWSNT_FALSE='#'
5999 else
6000 BUILDING_FOR_WINDOWSNT_TRUE='#'
6001 BUILDING_FOR_WINDOWSNT_FALSE=
6002 fi
6003
6004
6005 # Avoid gnulib's tests for HAVE_WORKING_O_NOATIME and HAVE_WORKING_O_NOFOLLOW,
6006 # as we don't use them.
6007
6008 # Avoid gnulib's threadlib module, as we do threads our own way.
6009
6010
6011 # Initialize gnulib right after choosing the compiler.
6012
6013 ac_ext=c
6014 ac_cpp='$CPP $CPPFLAGS'
6015 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6016 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6017 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6019 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6020 # On Suns, sometimes $CPP names a directory.
6021 if test -n "$CPP" && test -d "$CPP"; then
6022 CPP=
6023 fi
6024 if test -z "$CPP"; then
6025 if test "${ac_cv_prog_CPP+set}" = set; then :
6026 $as_echo_n "(cached) " >&6
6027 else
6028 # Double quotes because CPP needs to be expanded
6029 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6030 do
6031 ac_preproc_ok=false
6032 for ac_c_preproc_warn_flag in '' yes
6033 do
6034 # Use a header file that comes with gcc, so configuring glibc
6035 # with a fresh cross-compiler works.
6036 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6037 # <limits.h> exists even on freestanding compilers.
6038 # On the NeXT, cc -E runs the code through the compiler's parser,
6039 # not just through cpp. "Syntax error" is here to catch this case.
6040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6041 /* end confdefs.h. */
6042 #ifdef __STDC__
6043 # include <limits.h>
6044 #else
6045 # include <assert.h>
6046 #endif
6047 Syntax error
6048 _ACEOF
6049 if ac_fn_c_try_cpp "$LINENO"; then :
6050
6051 else
6052 # Broken: fails on valid input.
6053 continue
6054 fi
6055 rm -f conftest.err conftest.$ac_ext
6056
6057 # OK, works on sane cases. Now check whether nonexistent headers
6058 # can be detected and how.
6059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h. */
6061 #include <ac_nonexistent.h>
6062 _ACEOF
6063 if ac_fn_c_try_cpp "$LINENO"; then :
6064 # Broken: success on invalid input.
6065 continue
6066 else
6067 # Passes both tests.
6068 ac_preproc_ok=:
6069 break
6070 fi
6071 rm -f conftest.err conftest.$ac_ext
6072
6073 done
6074 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6075 rm -f conftest.err conftest.$ac_ext
6076 if $ac_preproc_ok; then :
6077 break
6078 fi
6079
6080 done
6081 ac_cv_prog_CPP=$CPP
6082
6083 fi
6084 CPP=$ac_cv_prog_CPP
6085 else
6086 ac_cv_prog_CPP=$CPP
6087 fi
6088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6089 $as_echo "$CPP" >&6; }
6090 ac_preproc_ok=false
6091 for ac_c_preproc_warn_flag in '' yes
6092 do
6093 # Use a header file that comes with gcc, so configuring glibc
6094 # with a fresh cross-compiler works.
6095 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6096 # <limits.h> exists even on freestanding compilers.
6097 # On the NeXT, cc -E runs the code through the compiler's parser,
6098 # not just through cpp. "Syntax error" is here to catch this case.
6099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6100 /* end confdefs.h. */
6101 #ifdef __STDC__
6102 # include <limits.h>
6103 #else
6104 # include <assert.h>
6105 #endif
6106 Syntax error
6107 _ACEOF
6108 if ac_fn_c_try_cpp "$LINENO"; then :
6109
6110 else
6111 # Broken: fails on valid input.
6112 continue
6113 fi
6114 rm -f conftest.err conftest.$ac_ext
6115
6116 # OK, works on sane cases. Now check whether nonexistent headers
6117 # can be detected and how.
6118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6119 /* end confdefs.h. */
6120 #include <ac_nonexistent.h>
6121 _ACEOF
6122 if ac_fn_c_try_cpp "$LINENO"; then :
6123 # Broken: success on invalid input.
6124 continue
6125 else
6126 # Passes both tests.
6127 ac_preproc_ok=:
6128 break
6129 fi
6130 rm -f conftest.err conftest.$ac_ext
6131
6132 done
6133 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6134 rm -f conftest.err conftest.$ac_ext
6135 if $ac_preproc_ok; then :
6136
6137 else
6138 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6139 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6140 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6141 See \`config.log' for more details." "$LINENO" 5; }
6142 fi
6143
6144 ac_ext=c
6145 ac_cpp='$CPP $CPPFLAGS'
6146 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6147 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6148 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6149
6150
6151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
6152 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
6153 if test "${ac_cv_path_GREP+set}" = set; then :
6154 $as_echo_n "(cached) " >&6
6155 else
6156 if test -z "$GREP"; then
6157 ac_path_GREP_found=false
6158 # Loop through the user's path and test for each of PROGNAME-LIST
6159 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6160 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6161 do
6162 IFS=$as_save_IFS
6163 test -z "$as_dir" && as_dir=.
6164 for ac_prog in grep ggrep; do
6165 for ac_exec_ext in '' $ac_executable_extensions; do
6166 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
6167 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
6168 # Check for GNU ac_path_GREP and select it if it is found.
6169 # Check for GNU $ac_path_GREP
6170 case `"$ac_path_GREP" --version 2>&1` in
6171 *GNU*)
6172 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
6173 *)
6174 ac_count=0
6175 $as_echo_n 0123456789 >"conftest.in"
6176 while :
6177 do
6178 cat "conftest.in" "conftest.in" >"conftest.tmp"
6179 mv "conftest.tmp" "conftest.in"
6180 cp "conftest.in" "conftest.nl"
6181 $as_echo 'GREP' >> "conftest.nl"
6182 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6183 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6184 as_fn_arith $ac_count + 1 && ac_count=$as_val
6185 if test $ac_count -gt ${ac_path_GREP_max-0}; then
6186 # Best one so far, save it but keep looking for a better one
6187 ac_cv_path_GREP="$ac_path_GREP"
6188 ac_path_GREP_max=$ac_count
6189 fi
6190 # 10*(2^10) chars as input seems more than enough
6191 test $ac_count -gt 10 && break
6192 done
6193 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6194 esac
6195
6196 $ac_path_GREP_found && break 3
6197 done
6198 done
6199 done
6200 IFS=$as_save_IFS
6201 if test -z "$ac_cv_path_GREP"; then
6202 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6203 fi
6204 else
6205 ac_cv_path_GREP=$GREP
6206 fi
6207
6208 fi
6209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
6210 $as_echo "$ac_cv_path_GREP" >&6; }
6211 GREP="$ac_cv_path_GREP"
6212
6213
6214 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
6215 $as_echo_n "checking for egrep... " >&6; }
6216 if test "${ac_cv_path_EGREP+set}" = set; then :
6217 $as_echo_n "(cached) " >&6
6218 else
6219 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
6220 then ac_cv_path_EGREP="$GREP -E"
6221 else
6222 if test -z "$EGREP"; then
6223 ac_path_EGREP_found=false
6224 # Loop through the user's path and test for each of PROGNAME-LIST
6225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6226 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6227 do
6228 IFS=$as_save_IFS
6229 test -z "$as_dir" && as_dir=.
6230 for ac_prog in egrep; do
6231 for ac_exec_ext in '' $ac_executable_extensions; do
6232 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6233 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6234 # Check for GNU ac_path_EGREP and select it if it is found.
6235 # Check for GNU $ac_path_EGREP
6236 case `"$ac_path_EGREP" --version 2>&1` in
6237 *GNU*)
6238 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6239 *)
6240 ac_count=0
6241 $as_echo_n 0123456789 >"conftest.in"
6242 while :
6243 do
6244 cat "conftest.in" "conftest.in" >"conftest.tmp"
6245 mv "conftest.tmp" "conftest.in"
6246 cp "conftest.in" "conftest.nl"
6247 $as_echo 'EGREP' >> "conftest.nl"
6248 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6249 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6250 as_fn_arith $ac_count + 1 && ac_count=$as_val
6251 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6252 # Best one so far, save it but keep looking for a better one
6253 ac_cv_path_EGREP="$ac_path_EGREP"
6254 ac_path_EGREP_max=$ac_count
6255 fi
6256 # 10*(2^10) chars as input seems more than enough
6257 test $ac_count -gt 10 && break
6258 done
6259 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6260 esac
6261
6262 $ac_path_EGREP_found && break 3
6263 done
6264 done
6265 done
6266 IFS=$as_save_IFS
6267 if test -z "$ac_cv_path_EGREP"; then
6268 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6269 fi
6270 else
6271 ac_cv_path_EGREP=$EGREP
6272 fi
6273
6274 fi
6275 fi
6276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6277 $as_echo "$ac_cv_path_EGREP" >&6; }
6278 EGREP="$ac_cv_path_EGREP"
6279
6280
6281
6282
6283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
6284 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6285 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6286 $as_echo_n "(cached) " >&6
6287 else
6288
6289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6290 /* end confdefs.h. */
6291
6292 #ifdef __ACK__
6293 Amsterdam
6294 #endif
6295
6296 _ACEOF
6297 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6298 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6299 gl_cv_c_amsterdam_compiler=yes
6300 else
6301 gl_cv_c_amsterdam_compiler=no
6302 fi
6303 rm -f conftest*
6304
6305
6306 fi
6307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6308 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6309 if test -z "$AR"; then
6310 if test $gl_cv_c_amsterdam_compiler = yes; then
6311 AR='cc -c.a'
6312 if test -z "$ARFLAGS"; then
6313 ARFLAGS='-o'
6314 fi
6315 else
6316 if test -n "$ac_tool_prefix"; then
6317 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6318 set dummy ${ac_tool_prefix}ar; ac_word=$2
6319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6320 $as_echo_n "checking for $ac_word... " >&6; }
6321 if test "${ac_cv_prog_AR+set}" = set; then :
6322 $as_echo_n "(cached) " >&6
6323 else
6324 if test -n "$AR"; then
6325 ac_cv_prog_AR="$AR" # Let the user override the test.
6326 else
6327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6328 for as_dir in $PATH
6329 do
6330 IFS=$as_save_IFS
6331 test -z "$as_dir" && as_dir=.
6332 for ac_exec_ext in '' $ac_executable_extensions; do
6333 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6334 ac_cv_prog_AR="${ac_tool_prefix}ar"
6335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6336 break 2
6337 fi
6338 done
6339 done
6340 IFS=$as_save_IFS
6341
6342 fi
6343 fi
6344 AR=$ac_cv_prog_AR
6345 if test -n "$AR"; then
6346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6347 $as_echo "$AR" >&6; }
6348 else
6349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6350 $as_echo "no" >&6; }
6351 fi
6352
6353
6354 fi
6355 if test -z "$ac_cv_prog_AR"; then
6356 ac_ct_AR=$AR
6357 # Extract the first word of "ar", so it can be a program name with args.
6358 set dummy ar; ac_word=$2
6359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6360 $as_echo_n "checking for $ac_word... " >&6; }
6361 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6362 $as_echo_n "(cached) " >&6
6363 else
6364 if test -n "$ac_ct_AR"; then
6365 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6366 else
6367 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6368 for as_dir in $PATH
6369 do
6370 IFS=$as_save_IFS
6371 test -z "$as_dir" && as_dir=.
6372 for ac_exec_ext in '' $ac_executable_extensions; do
6373 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6374 ac_cv_prog_ac_ct_AR="ar"
6375 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6376 break 2
6377 fi
6378 done
6379 done
6380 IFS=$as_save_IFS
6381
6382 fi
6383 fi
6384 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6385 if test -n "$ac_ct_AR"; then
6386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6387 $as_echo "$ac_ct_AR" >&6; }
6388 else
6389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6390 $as_echo "no" >&6; }
6391 fi
6392
6393 if test "x$ac_ct_AR" = x; then
6394 AR="ar"
6395 else
6396 case $cross_compiling:$ac_tool_warned in
6397 yes:)
6398 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6399 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6400 ac_tool_warned=yes ;;
6401 esac
6402 AR=$ac_ct_AR
6403 fi
6404 else
6405 AR="$ac_cv_prog_AR"
6406 fi
6407
6408 if test -z "$ARFLAGS"; then
6409 ARFLAGS='cru'
6410 fi
6411 fi
6412 else
6413 if test -z "$ARFLAGS"; then
6414 ARFLAGS='cru'
6415 fi
6416 fi
6417
6418
6419 if test -z "$RANLIB"; then
6420 if test $gl_cv_c_amsterdam_compiler = yes; then
6421 RANLIB=':'
6422 else
6423 if test -n "$ac_tool_prefix"; then
6424 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6425 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6427 $as_echo_n "checking for $ac_word... " >&6; }
6428 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6429 $as_echo_n "(cached) " >&6
6430 else
6431 if test -n "$RANLIB"; then
6432 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6433 else
6434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6435 for as_dir in $PATH
6436 do
6437 IFS=$as_save_IFS
6438 test -z "$as_dir" && as_dir=.
6439 for ac_exec_ext in '' $ac_executable_extensions; do
6440 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6441 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6443 break 2
6444 fi
6445 done
6446 done
6447 IFS=$as_save_IFS
6448
6449 fi
6450 fi
6451 RANLIB=$ac_cv_prog_RANLIB
6452 if test -n "$RANLIB"; then
6453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6454 $as_echo "$RANLIB" >&6; }
6455 else
6456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6457 $as_echo "no" >&6; }
6458 fi
6459
6460
6461 fi
6462 if test -z "$ac_cv_prog_RANLIB"; then
6463 ac_ct_RANLIB=$RANLIB
6464 # Extract the first word of "ranlib", so it can be a program name with args.
6465 set dummy ranlib; ac_word=$2
6466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6467 $as_echo_n "checking for $ac_word... " >&6; }
6468 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6469 $as_echo_n "(cached) " >&6
6470 else
6471 if test -n "$ac_ct_RANLIB"; then
6472 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6473 else
6474 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6475 for as_dir in $PATH
6476 do
6477 IFS=$as_save_IFS
6478 test -z "$as_dir" && as_dir=.
6479 for ac_exec_ext in '' $ac_executable_extensions; do
6480 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6481 ac_cv_prog_ac_ct_RANLIB="ranlib"
6482 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6483 break 2
6484 fi
6485 done
6486 done
6487 IFS=$as_save_IFS
6488
6489 fi
6490 fi
6491 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6492 if test -n "$ac_ct_RANLIB"; then
6493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6494 $as_echo "$ac_ct_RANLIB" >&6; }
6495 else
6496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6497 $as_echo "no" >&6; }
6498 fi
6499
6500 if test "x$ac_ct_RANLIB" = x; then
6501 RANLIB=":"
6502 else
6503 case $cross_compiling:$ac_tool_warned in
6504 yes:)
6505 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6506 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6507 ac_tool_warned=yes ;;
6508 esac
6509 RANLIB=$ac_ct_RANLIB
6510 fi
6511 else
6512 RANLIB="$ac_cv_prog_RANLIB"
6513 fi
6514
6515 fi
6516 fi
6517
6518
6519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6520 $as_echo_n "checking for ANSI C header files... " >&6; }
6521 if test "${ac_cv_header_stdc+set}" = set; then :
6522 $as_echo_n "(cached) " >&6
6523 else
6524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6525 /* end confdefs.h. */
6526 #include <stdlib.h>
6527 #include <stdarg.h>
6528 #include <string.h>
6529 #include <float.h>
6530
6531 int
6532 main ()
6533 {
6534
6535 ;
6536 return 0;
6537 }
6538 _ACEOF
6539 if ac_fn_c_try_compile "$LINENO"; then :
6540 ac_cv_header_stdc=yes
6541 else
6542 ac_cv_header_stdc=no
6543 fi
6544 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6545
6546 if test $ac_cv_header_stdc = yes; then
6547 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6548 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6549 /* end confdefs.h. */
6550 #include <string.h>
6551
6552 _ACEOF
6553 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6554 $EGREP "memchr" >/dev/null 2>&1; then :
6555
6556 else
6557 ac_cv_header_stdc=no
6558 fi
6559 rm -f conftest*
6560
6561 fi
6562
6563 if test $ac_cv_header_stdc = yes; then
6564 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6566 /* end confdefs.h. */
6567 #include <stdlib.h>
6568
6569 _ACEOF
6570 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6571 $EGREP "free" >/dev/null 2>&1; then :
6572
6573 else
6574 ac_cv_header_stdc=no
6575 fi
6576 rm -f conftest*
6577
6578 fi
6579
6580 if test $ac_cv_header_stdc = yes; then
6581 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6582 if test "$cross_compiling" = yes; then :
6583 :
6584 else
6585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6586 /* end confdefs.h. */
6587 #include <ctype.h>
6588 #include <stdlib.h>
6589 #if ((' ' & 0x0FF) == 0x020)
6590 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6591 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6592 #else
6593 # define ISLOWER(c) \
6594 (('a' <= (c) && (c) <= 'i') \
6595 || ('j' <= (c) && (c) <= 'r') \
6596 || ('s' <= (c) && (c) <= 'z'))
6597 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6598 #endif
6599
6600 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6601 int
6602 main ()
6603 {
6604 int i;
6605 for (i = 0; i < 256; i++)
6606 if (XOR (islower (i), ISLOWER (i))
6607 || toupper (i) != TOUPPER (i))
6608 return 2;
6609 return 0;
6610 }
6611 _ACEOF
6612 if ac_fn_c_try_run "$LINENO"; then :
6613
6614 else
6615 ac_cv_header_stdc=no
6616 fi
6617 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6618 conftest.$ac_objext conftest.beam conftest.$ac_ext
6619 fi
6620
6621 fi
6622 fi
6623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6624 $as_echo "$ac_cv_header_stdc" >&6; }
6625 if test $ac_cv_header_stdc = yes; then
6626
6627 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6628
6629 fi
6630
6631 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6632 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6633 inttypes.h stdint.h unistd.h
6634 do :
6635 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6636 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6637 "
6638 eval as_val=\$$as_ac_Header
6639 if test "x$as_val" = x""yes; then :
6640 cat >>confdefs.h <<_ACEOF
6641 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6642 _ACEOF
6643
6644 fi
6645
6646 done
6647
6648
6649
6650 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6651 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6652 MINIX=yes
6653 else
6654 MINIX=
6655 fi
6656
6657
6658 if test "$MINIX" = yes; then
6659
6660 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6661
6662
6663 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6664
6665
6666 $as_echo "#define _MINIX 1" >>confdefs.h
6667
6668
6669 $as_echo "#define _NETBSD_SOURCE 1" >>confdefs.h
6670
6671 fi
6672
6673
6674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6675 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6676 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6677 $as_echo_n "(cached) " >&6
6678 else
6679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6680 /* end confdefs.h. */
6681
6682 # define __EXTENSIONS__ 1
6683 $ac_includes_default
6684 int
6685 main ()
6686 {
6687
6688 ;
6689 return 0;
6690 }
6691 _ACEOF
6692 if ac_fn_c_try_compile "$LINENO"; then :
6693 ac_cv_safe_to_define___extensions__=yes
6694 else
6695 ac_cv_safe_to_define___extensions__=no
6696 fi
6697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6698 fi
6699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6700 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6701 test $ac_cv_safe_to_define___extensions__ = yes &&
6702 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6703
6704 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6705
6706 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6707
6708 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6709
6710 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6711
6712 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6713
6714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
6715 $as_echo_n "checking whether _XOPEN_SOURCE should be defined... " >&6; }
6716 if test "${ac_cv_should_define__xopen_source+set}" = set; then :
6717 $as_echo_n "(cached) " >&6
6718 else
6719 ac_cv_should_define__xopen_source=no
6720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6721 /* end confdefs.h. */
6722
6723 #include <wchar.h>
6724 mbstate_t x;
6725 int
6726 main ()
6727 {
6728
6729 ;
6730 return 0;
6731 }
6732 _ACEOF
6733 if ac_fn_c_try_compile "$LINENO"; then :
6734
6735 else
6736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6737 /* end confdefs.h. */
6738
6739 #define _XOPEN_SOURCE 500
6740 #include <wchar.h>
6741 mbstate_t x;
6742 int
6743 main ()
6744 {
6745
6746 ;
6747 return 0;
6748 }
6749 _ACEOF
6750 if ac_fn_c_try_compile "$LINENO"; then :
6751 ac_cv_should_define__xopen_source=yes
6752 fi
6753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6754 fi
6755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6756 fi
6757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
6758 $as_echo "$ac_cv_should_define__xopen_source" >&6; }
6759 test $ac_cv_should_define__xopen_source = yes &&
6760 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6761
6762
6763
6764
6765
6766
6767
6768
6769 # Check whether --enable-largefile was given.
6770 if test "${enable_largefile+set}" = set; then :
6771 enableval=$enable_largefile;
6772 fi
6773
6774 if test "$enable_largefile" != no; then
6775
6776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6777 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6778 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6779 $as_echo_n "(cached) " >&6
6780 else
6781 ac_cv_sys_largefile_CC=no
6782 if test "$GCC" != yes; then
6783 ac_save_CC=$CC
6784 while :; do
6785 # IRIX 6.2 and later do not support large files by default,
6786 # so use the C compiler's -n32 option if that helps.
6787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6788 /* end confdefs.h. */
6789 #include <sys/types.h>
6790 /* Check that off_t can represent 2**63 - 1 correctly.
6791 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6792 since some C++ compilers masquerading as C compilers
6793 incorrectly reject 9223372036854775807. */
6794 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6795 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6796 && LARGE_OFF_T % 2147483647 == 1)
6797 ? 1 : -1];
6798 int
6799 main ()
6800 {
6801
6802 ;
6803 return 0;
6804 }
6805 _ACEOF
6806 if ac_fn_c_try_compile "$LINENO"; then :
6807 break
6808 fi
6809 rm -f core conftest.err conftest.$ac_objext
6810 CC="$CC -n32"
6811 if ac_fn_c_try_compile "$LINENO"; then :
6812 ac_cv_sys_largefile_CC=' -n32'; break
6813 fi
6814 rm -f core conftest.err conftest.$ac_objext
6815 break
6816 done
6817 CC=$ac_save_CC
6818 rm -f conftest.$ac_ext
6819 fi
6820 fi
6821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6822 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6823 if test "$ac_cv_sys_largefile_CC" != no; then
6824 CC=$CC$ac_cv_sys_largefile_CC
6825 fi
6826
6827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6828 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6829 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6830 $as_echo_n "(cached) " >&6
6831 else
6832 while :; do
6833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6834 /* end confdefs.h. */
6835 #include <sys/types.h>
6836 /* Check that off_t can represent 2**63 - 1 correctly.
6837 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6838 since some C++ compilers masquerading as C compilers
6839 incorrectly reject 9223372036854775807. */
6840 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6841 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6842 && LARGE_OFF_T % 2147483647 == 1)
6843 ? 1 : -1];
6844 int
6845 main ()
6846 {
6847
6848 ;
6849 return 0;
6850 }
6851 _ACEOF
6852 if ac_fn_c_try_compile "$LINENO"; then :
6853 ac_cv_sys_file_offset_bits=no; break
6854 fi
6855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6857 /* end confdefs.h. */
6858 #define _FILE_OFFSET_BITS 64
6859 #include <sys/types.h>
6860 /* Check that off_t can represent 2**63 - 1 correctly.
6861 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6862 since some C++ compilers masquerading as C compilers
6863 incorrectly reject 9223372036854775807. */
6864 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6865 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6866 && LARGE_OFF_T % 2147483647 == 1)
6867 ? 1 : -1];
6868 int
6869 main ()
6870 {
6871
6872 ;
6873 return 0;
6874 }
6875 _ACEOF
6876 if ac_fn_c_try_compile "$LINENO"; then :
6877 ac_cv_sys_file_offset_bits=64; break
6878 fi
6879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6880 ac_cv_sys_file_offset_bits=unknown
6881 break
6882 done
6883 fi
6884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6885 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6886 case $ac_cv_sys_file_offset_bits in #(
6887 no | unknown) ;;
6888 *)
6889 cat >>confdefs.h <<_ACEOF
6890 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6891 _ACEOF
6892 ;;
6893 esac
6894 rm -rf conftest*
6895 if test $ac_cv_sys_file_offset_bits = unknown; then
6896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6897 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6898 if test "${ac_cv_sys_large_files+set}" = set; then :
6899 $as_echo_n "(cached) " >&6
6900 else
6901 while :; do
6902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6903 /* end confdefs.h. */
6904 #include <sys/types.h>
6905 /* Check that off_t can represent 2**63 - 1 correctly.
6906 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6907 since some C++ compilers masquerading as C compilers
6908 incorrectly reject 9223372036854775807. */
6909 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6910 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6911 && LARGE_OFF_T % 2147483647 == 1)
6912 ? 1 : -1];
6913 int
6914 main ()
6915 {
6916
6917 ;
6918 return 0;
6919 }
6920 _ACEOF
6921 if ac_fn_c_try_compile "$LINENO"; then :
6922 ac_cv_sys_large_files=no; break
6923 fi
6924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6926 /* end confdefs.h. */
6927 #define _LARGE_FILES 1
6928 #include <sys/types.h>
6929 /* Check that off_t can represent 2**63 - 1 correctly.
6930 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6931 since some C++ compilers masquerading as C compilers
6932 incorrectly reject 9223372036854775807. */
6933 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6934 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6935 && LARGE_OFF_T % 2147483647 == 1)
6936 ? 1 : -1];
6937 int
6938 main ()
6939 {
6940
6941 ;
6942 return 0;
6943 }
6944 _ACEOF
6945 if ac_fn_c_try_compile "$LINENO"; then :
6946 ac_cv_sys_large_files=1; break
6947 fi
6948 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6949 ac_cv_sys_large_files=unknown
6950 break
6951 done
6952 fi
6953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6954 $as_echo "$ac_cv_sys_large_files" >&6; }
6955 case $ac_cv_sys_large_files in #(
6956 no | unknown) ;;
6957 *)
6958 cat >>confdefs.h <<_ACEOF
6959 #define _LARGE_FILES $ac_cv_sys_large_files
6960 _ACEOF
6961 ;;
6962 esac
6963 rm -rf conftest*
6964 fi
6965
6966
6967 $as_echo "#define _DARWIN_USE_64_BIT_INODE 1" >>confdefs.h
6968
6969 fi
6970
6971 case $ac_cv_prog_cc_stdc in #(
6972 no) :
6973 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6974 *) :
6975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6976 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6977 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6978 $as_echo_n "(cached) " >&6
6979 else
6980 ac_cv_prog_cc_c99=no
6981 ac_save_CC=$CC
6982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6983 /* end confdefs.h. */
6984 #include <stdarg.h>
6985 #include <stdbool.h>
6986 #include <stdlib.h>
6987 #include <wchar.h>
6988 #include <stdio.h>
6989
6990 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6991 #define debug(...) fprintf (stderr, __VA_ARGS__)
6992 #define showlist(...) puts (#__VA_ARGS__)
6993 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6994 static void
6995 test_varargs_macros (void)
6996 {
6997 int x = 1234;
6998 int y = 5678;
6999 debug ("Flag");
7000 debug ("X = %d\n", x);
7001 showlist (The first, second, and third items.);
7002 report (x>y, "x is %d but y is %d", x, y);
7003 }
7004
7005 // Check long long types.
7006 #define BIG64 18446744073709551615ull
7007 #define BIG32 4294967295ul
7008 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
7009 #if !BIG_OK
7010 your preprocessor is broken;
7011 #endif
7012 #if BIG_OK
7013 #else
7014 your preprocessor is broken;
7015 #endif
7016 static long long int bignum = -9223372036854775807LL;
7017 static unsigned long long int ubignum = BIG64;
7018
7019 struct incomplete_array
7020 {
7021 int datasize;
7022 double data[];
7023 };
7024
7025 struct named_init {
7026 int number;
7027 const wchar_t *name;
7028 double average;
7029 };
7030
7031 typedef const char *ccp;
7032
7033 static inline int
7034 test_restrict (ccp restrict text)
7035 {
7036 // See if C++-style comments work.
7037 // Iterate through items via the restricted pointer.
7038 // Also check for declarations in for loops.
7039 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
7040 continue;
7041 return 0;
7042 }
7043
7044 // Check varargs and va_copy.
7045 static void
7046 test_varargs (const char *format, ...)
7047 {
7048 va_list args;
7049 va_start (args, format);
7050 va_list args_copy;
7051 va_copy (args_copy, args);
7052
7053 const char *str;
7054 int number;
7055 float fnumber;
7056
7057 while (*format)
7058 {
7059 switch (*format++)
7060 {
7061 case 's': // string
7062 str = va_arg (args_copy, const char *);
7063 break;
7064 case 'd': // int
7065 number = va_arg (args_copy, int);
7066 break;
7067 case 'f': // float
7068 fnumber = va_arg (args_copy, double);
7069 break;
7070 default:
7071 break;
7072 }
7073 }
7074 va_end (args_copy);
7075 va_end (args);
7076 }
7077
7078 int
7079 main ()
7080 {
7081
7082 // Check bool.
7083 _Bool success = false;
7084
7085 // Check restrict.
7086 if (test_restrict ("String literal") == 0)
7087 success = true;
7088 char *restrict newvar = "Another string";
7089
7090 // Check varargs.
7091 test_varargs ("s, d' f .", "string", 65, 34.234);
7092 test_varargs_macros ();
7093
7094 // Check flexible array members.
7095 struct incomplete_array *ia =
7096 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
7097 ia->datasize = 10;
7098 for (int i = 0; i < ia->datasize; ++i)
7099 ia->data[i] = i * 1.234;
7100
7101 // Check named initializers.
7102 struct named_init ni = {
7103 .number = 34,
7104 .name = L"Test wide string",
7105 .average = 543.34343,
7106 };
7107
7108 ni.number = 58;
7109
7110 int dynamic_array[ni.number];
7111 dynamic_array[ni.number - 1] = 543;
7112
7113 // work around unused variable warnings
7114 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
7115 || dynamic_array[ni.number - 1] != 543);
7116
7117 ;
7118 return 0;
7119 }
7120 _ACEOF
7121 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
7122 do
7123 CC="$ac_save_CC $ac_arg"
7124 if ac_fn_c_try_compile "$LINENO"; then :
7125 ac_cv_prog_cc_c99=$ac_arg
7126 fi
7127 rm -f core conftest.err conftest.$ac_objext
7128 test "x$ac_cv_prog_cc_c99" != "xno" && break
7129 done
7130 rm -f conftest.$ac_ext
7131 CC=$ac_save_CC
7132
7133 fi
7134 # AC_CACHE_VAL
7135 case "x$ac_cv_prog_cc_c99" in
7136 x)
7137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7138 $as_echo "none needed" >&6; } ;;
7139 xno)
7140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7141 $as_echo "unsupported" >&6; } ;;
7142 *)
7143 CC="$CC $ac_cv_prog_cc_c99"
7144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
7145 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
7146 esac
7147 if test "x$ac_cv_prog_cc_c99" != xno; then :
7148 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
7149 else
7150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
7151 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
7152 if test "${ac_cv_prog_cc_c89+set}" = set; then :
7153 $as_echo_n "(cached) " >&6
7154 else
7155 ac_cv_prog_cc_c89=no
7156 ac_save_CC=$CC
7157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7158 /* end confdefs.h. */
7159 #include <stdarg.h>
7160 #include <stdio.h>
7161 #include <sys/types.h>
7162 #include <sys/stat.h>
7163 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
7164 struct buf { int x; };
7165 FILE * (*rcsopen) (struct buf *, struct stat *, int);
7166 static char *e (p, i)
7167 char **p;
7168 int i;
7169 {
7170 return p[i];
7171 }
7172 static char *f (char * (*g) (char **, int), char **p, ...)
7173 {
7174 char *s;
7175 va_list v;
7176 va_start (v,p);
7177 s = g (p, va_arg (v,int));
7178 va_end (v);
7179 return s;
7180 }
7181
7182 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
7183 function prototypes and stuff, but not '\xHH' hex character constants.
7184 These don't provoke an error unfortunately, instead are silently treated
7185 as 'x'. The following induces an error, until -std is added to get
7186 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
7187 array size at least. It's necessary to write '\x00'==0 to get something
7188 that's true only with -std. */
7189 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
7190
7191 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
7192 inside strings and character constants. */
7193 #define FOO(x) 'x'
7194 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
7195
7196 int test (int i, double x);
7197 struct s1 {int (*f) (int a);};
7198 struct s2 {int (*f) (double a);};
7199 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
7200 int argc;
7201 char **argv;
7202 int
7203 main ()
7204 {
7205 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
7206 ;
7207 return 0;
7208 }
7209 _ACEOF
7210 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
7211 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
7212 do
7213 CC="$ac_save_CC $ac_arg"
7214 if ac_fn_c_try_compile "$LINENO"; then :
7215 ac_cv_prog_cc_c89=$ac_arg
7216 fi
7217 rm -f core conftest.err conftest.$ac_objext
7218 test "x$ac_cv_prog_cc_c89" != "xno" && break
7219 done
7220 rm -f conftest.$ac_ext
7221 CC=$ac_save_CC
7222
7223 fi
7224 # AC_CACHE_VAL
7225 case "x$ac_cv_prog_cc_c89" in
7226 x)
7227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7228 $as_echo "none needed" >&6; } ;;
7229 xno)
7230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7231 $as_echo "unsupported" >&6; } ;;
7232 *)
7233 CC="$CC $ac_cv_prog_cc_c89"
7234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
7235 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
7236 esac
7237 if test "x$ac_cv_prog_cc_c89" != xno; then :
7238 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
7239 else
7240 ac_cv_prog_cc_stdc=no
7241 fi
7242
7243 fi
7244 ;;
7245 esac
7246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
7247 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
7248 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
7249 $as_echo_n "(cached) " >&6
7250 fi
7251
7252 case $ac_cv_prog_cc_stdc in #(
7253 no) :
7254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
7255 $as_echo "unsupported" >&6; } ;; #(
7256 '') :
7257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
7258 $as_echo "none needed" >&6; } ;; #(
7259 *) :
7260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
7261 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
7262 esac
7263
7264
7265
7266 # Code from module alloca-opt:
7267 # Code from module allocator:
7268 # Code from module at-internal:
7269 # Code from module binary-io:
7270 # Code from module byteswap:
7271 # Code from module c-ctype:
7272 # Code from module c-strcase:
7273 # Code from module careadlinkat:
7274 # Code from module clock-time:
7275 # Code from module close-stream:
7276 # Code from module count-one-bits:
7277 # Code from module count-trailing-zeros:
7278 # Code from module crypto/md5:
7279 # Code from module crypto/sha1:
7280 # Code from module crypto/sha256:
7281 # Code from module crypto/sha512:
7282 # Code from module dirent:
7283 # Code from module dosname:
7284 # Code from module dtoastr:
7285 # Code from module dtotimespec:
7286 # Code from module dup2:
7287 # Code from module environ:
7288 # Code from module errno:
7289 # Code from module euidaccess:
7290 # Code from module execinfo:
7291 # Code from module extensions:
7292
7293 # Code from module extern-inline:
7294 # Code from module faccessat:
7295 # Code from module fcntl:
7296 # Code from module fcntl-h:
7297 # Code from module fdatasync:
7298 # Code from module fdopendir:
7299 # Code from module filemode:
7300 # Code from module fpending:
7301 # Code from module fstatat:
7302 # Code from module fsync:
7303 # Code from module getdtablesize:
7304 # Code from module getgroups:
7305 # Code from module getloadavg:
7306 # Code from module getopt-gnu:
7307 # Code from module getopt-posix:
7308 # Code from module gettext-h:
7309 # Code from module gettime:
7310 # Code from module gettimeofday:
7311 # Code from module group-member:
7312 # Code from module include_next:
7313 # Code from module intprops:
7314 # Code from module inttypes-incomplete:
7315 # Code from module largefile:
7316
7317 # Code from module lstat:
7318 # Code from module manywarnings:
7319 # Code from module memrchr:
7320 # Code from module mkostemp:
7321 # Code from module mktime:
7322 # Code from module multiarch:
7323 # Code from module nocrash:
7324 # Code from module openat-h:
7325 # Code from module pathmax:
7326 # Code from module pipe2:
7327 # Code from module pselect:
7328 # Code from module pthread_sigmask:
7329 # Code from module putenv:
7330 # Code from module qacl:
7331 # Code from module readlink:
7332 # Code from module readlinkat:
7333 # Code from module root-uid:
7334 # Code from module secure_getenv:
7335 # Code from module sig2str:
7336 # Code from module signal-h:
7337 # Code from module snippet/_Noreturn:
7338 # Code from module snippet/arg-nonnull:
7339 # Code from module snippet/c++defs:
7340 # Code from module snippet/warn-on-use:
7341 # Code from module socklen:
7342 # Code from module ssize_t:
7343 # Code from module stat:
7344 # Code from module stat-time:
7345 # Code from module stdalign:
7346 # Code from module stdarg:
7347
7348
7349
7350 # Code from module stdbool:
7351 # Code from module stddef:
7352 # Code from module stdint:
7353 # Code from module stdio:
7354 # Code from module stdlib:
7355 # Code from module strftime:
7356 # Code from module string:
7357 # Code from module strtoimax:
7358 # Code from module strtoll:
7359 # Code from module strtoull:
7360 # Code from module strtoumax:
7361 # Code from module symlink:
7362 # Code from module sys_select:
7363 # Code from module sys_stat:
7364 # Code from module sys_time:
7365 # Code from module tempname:
7366 # Code from module time:
7367 # Code from module time_r:
7368 # Code from module timer-time:
7369 # Code from module timespec:
7370 # Code from module timespec-add:
7371 # Code from module timespec-sub:
7372 # Code from module u64:
7373 # Code from module unistd:
7374 # Code from module unsetenv:
7375 # Code from module utimens:
7376 # Code from module verify:
7377 # Code from module warnings:
7378 # Code from module xalloc-oversized:
7379
7380
7381 if test "$ac_test_CFLAGS" != set; then
7382 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7383 # if -g3 works and the user does not specify CFLAGS.
7384 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7385 case $CFLAGS in
7386 '-g')
7387 emacs_g3_CFLAGS='-g3';;
7388 '-g -O2')
7389 emacs_g3_CFLAGS='-g3 -O2';;
7390 *)
7391 emacs_g3_CFLAGS='';;
7392 esac
7393 if test -n "$emacs_g3_CFLAGS"; then
7394 emacs_save_CFLAGS=$CFLAGS
7395 CFLAGS=$emacs_g3_CFLAGS
7396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7397 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7398 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7399 $as_echo_n "(cached) " >&6
7400 else
7401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7402 /* end confdefs.h. */
7403
7404 int
7405 main ()
7406 {
7407
7408 ;
7409 return 0;
7410 }
7411 _ACEOF
7412 if ac_fn_c_try_link "$LINENO"; then :
7413 emacs_cv_prog_cc_g3=yes
7414 else
7415 emacs_cv_prog_cc_g3=no
7416 fi
7417 rm -f core conftest.err conftest.$ac_objext \
7418 conftest$ac_exeext conftest.$ac_ext
7419 fi
7420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7421 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7422 if test $emacs_cv_prog_cc_g3 != yes; then
7423 CFLAGS=$emacs_save_CFLAGS
7424 fi
7425 if test $opsys = mingw32; then
7426 CFLAGS="$CFLAGS -gdwarf-2"
7427 fi
7428 fi
7429
7430 case $CFLAGS in
7431 *-O*) ;;
7432 *)
7433 # No optimization flag was inferred for this non-GCC compiler.
7434 # Try -O. This is needed for xlc on AIX; see Bug#14258.
7435 emacs_save_CFLAGS=$CFLAGS
7436 test -z "$CFLAGS" || CFLAGS="$CFLAGS "
7437 CFLAGS=${CFLAGS}-O
7438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -O" >&5
7439 $as_echo_n "checking whether $CC accepts -O... " >&6; }
7440 if test "${emacs_cv_prog_cc_o+set}" = set; then :
7441 $as_echo_n "(cached) " >&6
7442 else
7443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7444 /* end confdefs.h. */
7445
7446 int
7447 main ()
7448 {
7449
7450 ;
7451 return 0;
7452 }
7453 _ACEOF
7454 if ac_fn_c_try_link "$LINENO"; then :
7455 emacs_cv_prog_cc_o=yes
7456 else
7457 emacs_cv_prog_cc_o=no
7458 fi
7459 rm -f core conftest.err conftest.$ac_objext \
7460 conftest$ac_exeext conftest.$ac_ext
7461 fi
7462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_o" >&5
7463 $as_echo "$emacs_cv_prog_cc_o" >&6; }
7464 if test $emacs_cv_prog_cc_o != yes; then
7465 CFLAGS=$emacs_save_CFLAGS
7466 fi ;;
7467 esac
7468 fi
7469
7470 # Check whether --enable-gcc-warnings was given.
7471 if test "${enable_gcc_warnings+set}" = set; then :
7472 enableval=$enable_gcc_warnings; case $enableval in
7473 yes|no) ;;
7474 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7475 esac
7476 gl_gcc_warnings=$enableval
7477 else
7478 gl_gcc_warnings=no
7479
7480 fi
7481
7482
7483 # Check whether --enable-link-time-optimization was given.
7484 if test "${enable_link_time_optimization+set}" = set; then :
7485 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7487 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7488 ac_lto_supported=no
7489 if test x$GCC = xyes; then
7490 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7491 if test x$CPUS != x; then
7492 LTO="-flto=$CPUS"
7493 else
7494 LTO="-flto"
7495 fi
7496 old_CFLAGS=$CFLAGS
7497 CFLAGS="$CFLAGS $LTO"
7498 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7499 /* end confdefs.h. */
7500
7501 int
7502 main ()
7503 {
7504
7505 ;
7506 return 0;
7507 }
7508 _ACEOF
7509 if ac_fn_c_try_compile "$LINENO"; then :
7510 ac_lto_supported=yes
7511 else
7512 ac_lto_supported=no
7513 fi
7514 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7515 CFLAGS="$old_CFLAGS"
7516 fi
7517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7518 $as_echo "$ac_lto_supported" >&6; }
7519 if test "$ac_lto_supported" = "yes"; then
7520 CFLAGS="$CFLAGS $LTO"
7521 fi
7522 fi
7523 fi
7524
7525
7526 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7527 # ------------------------------------------------
7528 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7529 # Otherwise, run RUN-IF-NOT-FOUND.
7530
7531
7532 # clang is unduly picky about some things.
7533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the compiler is clang" >&5
7534 $as_echo_n "checking whether the compiler is clang... " >&6; }
7535 if test "${emacs_cv_clang+set}" = set; then :
7536 $as_echo_n "(cached) " >&6
7537 else
7538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7539 /* end confdefs.h. */
7540
7541 #ifndef __clang__
7542 #error "not clang"
7543 #endif
7544
7545 int
7546 main ()
7547 {
7548
7549 ;
7550 return 0;
7551 }
7552 _ACEOF
7553 if ac_fn_c_try_compile "$LINENO"; then :
7554 emacs_cv_clang=yes
7555 else
7556 emacs_cv_clang=no
7557 fi
7558 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7559 fi
7560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_clang" >&5
7561 $as_echo "$emacs_cv_clang" >&6; }
7562
7563 # When compiling with GCC, prefer -isystem to -I when including system
7564 # include files, to avoid generating useless diagnostics for the files.
7565 if test "$gl_gcc_warnings" != yes; then
7566 isystem='-I'
7567 if test "$emacs_cv_clang" = yes
7568 then
7569 # Turn off some warnings if supported.
7570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror -Wunknown-warning-option" >&5
7571 $as_echo_n "checking whether C compiler handles -Werror -Wunknown-warning-option... " >&6; }
7572 if test "${gl_cv_warn_c__Werror__Wunknown_warning_option+set}" = set; then :
7573 $as_echo_n "(cached) " >&6
7574 else
7575
7576 gl_save_compiler_FLAGS="$CFLAGS"
7577 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror -Wunknown-warning-option"
7578 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7579 /* end confdefs.h. */
7580
7581 int
7582 main ()
7583 {
7584
7585 ;
7586 return 0;
7587 }
7588 _ACEOF
7589 if ac_fn_c_try_link "$LINENO"; then :
7590 gl_cv_warn_c__Werror__Wunknown_warning_option=yes
7591 else
7592 gl_cv_warn_c__Werror__Wunknown_warning_option=no
7593 fi
7594 rm -f core conftest.err conftest.$ac_objext \
7595 conftest$ac_exeext conftest.$ac_ext
7596 CFLAGS="$gl_save_compiler_FLAGS"
7597
7598 fi
7599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror__Wunknown_warning_option" >&5
7600 $as_echo "$gl_cv_warn_c__Werror__Wunknown_warning_option" >&6; }
7601 if test "x$gl_cv_warn_c__Werror__Wunknown_warning_option" = x""yes; then :
7602 gl_unknown_warnings_are_errors='-Wunknown-warning-option -Werror'
7603 else
7604 gl_unknown_warnings_are_errors=
7605 fi
7606
7607
7608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7609 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7610 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7611 $as_echo_n "(cached) " >&6
7612 else
7613
7614 gl_save_compiler_FLAGS="$CFLAGS"
7615 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
7616 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7617 /* end confdefs.h. */
7618
7619 int
7620 main ()
7621 {
7622
7623 ;
7624 return 0;
7625 }
7626 _ACEOF
7627 if ac_fn_c_try_link "$LINENO"; then :
7628 gl_cv_warn_c__Wno_switch=yes
7629 else
7630 gl_cv_warn_c__Wno_switch=no
7631 fi
7632 rm -f core conftest.err conftest.$ac_objext \
7633 conftest$ac_exeext conftest.$ac_ext
7634 CFLAGS="$gl_save_compiler_FLAGS"
7635
7636 fi
7637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7638 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7639 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7640 as_fn_append WARN_CFLAGS " -Wno-switch"
7641 fi
7642
7643
7644
7645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
7646 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
7647 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
7648 $as_echo_n "(cached) " >&6
7649 else
7650
7651 gl_save_compiler_FLAGS="$CFLAGS"
7652 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
7653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7654 /* end confdefs.h. */
7655
7656 int
7657 main ()
7658 {
7659
7660 ;
7661 return 0;
7662 }
7663 _ACEOF
7664 if ac_fn_c_try_link "$LINENO"; then :
7665 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
7666 else
7667 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
7668 fi
7669 rm -f core conftest.err conftest.$ac_objext \
7670 conftest$ac_exeext conftest.$ac_ext
7671 CFLAGS="$gl_save_compiler_FLAGS"
7672
7673 fi
7674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
7675 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
7676 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
7677 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
7678 fi
7679
7680
7681
7682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-pointer-sign" >&5
7683 $as_echo_n "checking whether C compiler handles -Wno-pointer-sign... " >&6; }
7684 if test "${gl_cv_warn_c__Wno_pointer_sign+set}" = set; then :
7685 $as_echo_n "(cached) " >&6
7686 else
7687
7688 gl_save_compiler_FLAGS="$CFLAGS"
7689 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wpointer-sign"
7690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7691 /* end confdefs.h. */
7692
7693 int
7694 main ()
7695 {
7696
7697 ;
7698 return 0;
7699 }
7700 _ACEOF
7701 if ac_fn_c_try_link "$LINENO"; then :
7702 gl_cv_warn_c__Wno_pointer_sign=yes
7703 else
7704 gl_cv_warn_c__Wno_pointer_sign=no
7705 fi
7706 rm -f core conftest.err conftest.$ac_objext \
7707 conftest$ac_exeext conftest.$ac_ext
7708 CFLAGS="$gl_save_compiler_FLAGS"
7709
7710 fi
7711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_pointer_sign" >&5
7712 $as_echo "$gl_cv_warn_c__Wno_pointer_sign" >&6; }
7713 if test "x$gl_cv_warn_c__Wno_pointer_sign" = x""yes; then :
7714 as_fn_append WARN_CFLAGS " -Wno-pointer-sign"
7715 fi
7716
7717
7718 fi
7719 else
7720 isystem='-isystem '
7721
7722 # This, $nw, is the list of warnings we disable.
7723 nw=
7724
7725 case $with_x_toolkit in
7726 lucid | athena | motif)
7727 # Old toolkits mishandle 'const'.
7728 nw="$nw -Wwrite-strings"
7729 ;;
7730 *)
7731
7732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7733 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7734 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7735 $as_echo_n "(cached) " >&6
7736 else
7737
7738 gl_save_compiler_FLAGS="$CFLAGS"
7739 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Werror"
7740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7741 /* end confdefs.h. */
7742
7743 int
7744 main ()
7745 {
7746
7747 ;
7748 return 0;
7749 }
7750 _ACEOF
7751 if ac_fn_c_try_link "$LINENO"; then :
7752 gl_cv_warn_c__Werror=yes
7753 else
7754 gl_cv_warn_c__Werror=no
7755 fi
7756 rm -f core conftest.err conftest.$ac_objext \
7757 conftest$ac_exeext conftest.$ac_ext
7758 CFLAGS="$gl_save_compiler_FLAGS"
7759
7760 fi
7761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7762 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7763 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7764 as_fn_append WERROR_CFLAGS " -Werror"
7765 fi
7766
7767
7768 ;;
7769 esac
7770
7771
7772 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7773 nw="$nw -Woverlength-strings" # Not a problem these days
7774 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7775 nw="$nw -Wformat-nonliteral" # we do this a lot
7776 nw="$nw -Wvla" # warnings in gettext.h
7777 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7778 nw="$nw -Wswitch-default" # Too many warnings for now
7779 nw="$nw -Winline" # OK to ignore 'inline'
7780 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7781 nw="$nw -Wstrict-overflow" # OK to optimize assuming that
7782 # signed overflow has undefined behavior
7783 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7784 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7785 nw="$nw -Wbad-function-cast" # These casts are no worse than others.
7786
7787 # Emacs doesn't care about shadowing; see
7788 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7789 nw="$nw -Wshadow"
7790
7791 # Emacs's use of alloca inhibits protecting the stack.
7792 nw="$nw -Wstack-protector"
7793
7794 # The following line should be removable at some point.
7795 nw="$nw -Wsuggest-attribute=pure"
7796
7797 # This part is merely for shortening the command line,
7798 # since -Wno-FOO needs to be added below regardless.
7799 nw="$nw -Wmissing-field-initializers"
7800 nw="$nw -Wswitch"
7801 nw="$nw -Wtype-limits"
7802 nw="$nw -Wunused-parameter"
7803
7804 if test $emacs_cv_clang = yes; then
7805 nw="$nw -Wcast-align"
7806 fi
7807
7808
7809
7810 if test -n "$GCC"; then
7811
7812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7813 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7814 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7815 $as_echo_n "(cached) " >&6
7816 else
7817
7818 gl_save_CFLAGS="$CFLAGS"
7819 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7821 /* end confdefs.h. */
7822
7823 int
7824 main ()
7825 {
7826
7827 ;
7828 return 0;
7829 }
7830 _ACEOF
7831 if ac_fn_c_try_compile "$LINENO"; then :
7832 gl_cv_cc_nomfi_supported=yes
7833 else
7834 gl_cv_cc_nomfi_supported=no
7835 fi
7836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7837 CFLAGS="$gl_save_CFLAGS"
7838 fi
7839
7840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7841 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7842
7843 if test "$gl_cv_cc_nomfi_supported" = yes; then
7844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7845 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7846 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7847 $as_echo_n "(cached) " >&6
7848 else
7849
7850 gl_save_CFLAGS="$CFLAGS"
7851 CFLAGS="$CFLAGS -W -Werror"
7852 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7853 /* end confdefs.h. */
7854 void f (void)
7855 {
7856 typedef struct { int a; int b; } s_t;
7857 s_t s1 = { 0, };
7858 }
7859
7860 int
7861 main ()
7862 {
7863
7864 ;
7865 return 0;
7866 }
7867 _ACEOF
7868 if ac_fn_c_try_compile "$LINENO"; then :
7869 gl_cv_cc_nomfi_needed=no
7870 else
7871 gl_cv_cc_nomfi_needed=yes
7872 fi
7873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7874 CFLAGS="$gl_save_CFLAGS"
7875
7876 fi
7877
7878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7879 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7880 fi
7881
7882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wuninitialized is supported" >&5
7883 $as_echo_n "checking whether -Wuninitialized is supported... " >&6; }
7884 if test "${gl_cv_cc_uninitialized_supported+set}" = set; then :
7885 $as_echo_n "(cached) " >&6
7886 else
7887
7888 gl_save_CFLAGS="$CFLAGS"
7889 CFLAGS="$CFLAGS -Werror -Wuninitialized"
7890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7891 /* end confdefs.h. */
7892
7893 int
7894 main ()
7895 {
7896
7897 ;
7898 return 0;
7899 }
7900 _ACEOF
7901 if ac_fn_c_try_compile "$LINENO"; then :
7902 gl_cv_cc_uninitialized_supported=yes
7903 else
7904 gl_cv_cc_uninitialized_supported=no
7905 fi
7906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7907 CFLAGS="$gl_save_CFLAGS"
7908 fi
7909
7910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_uninitialized_supported" >&5
7911 $as_echo "$gl_cv_cc_uninitialized_supported" >&6; }
7912
7913 fi
7914
7915 # List all gcc warning categories.
7916 gl_manywarn_set=
7917 for gl_manywarn_item in \
7918 -W \
7919 -Wabi \
7920 -Waddress \
7921 -Waggressive-loop-optimizations \
7922 -Wall \
7923 -Warray-bounds \
7924 -Wattributes \
7925 -Wbad-function-cast \
7926 -Wbuiltin-macro-redefined \
7927 -Wcast-align \
7928 -Wchar-subscripts \
7929 -Wclobbered \
7930 -Wcomment \
7931 -Wcomments \
7932 -Wcoverage-mismatch \
7933 -Wcpp \
7934 -Wdeprecated \
7935 -Wdeprecated-declarations \
7936 -Wdisabled-optimization \
7937 -Wdiv-by-zero \
7938 -Wdouble-promotion \
7939 -Wempty-body \
7940 -Wendif-labels \
7941 -Wenum-compare \
7942 -Wextra \
7943 -Wformat-contains-nul \
7944 -Wformat-extra-args \
7945 -Wformat-nonliteral \
7946 -Wformat-security \
7947 -Wformat-y2k \
7948 -Wformat-zero-length \
7949 -Wfree-nonheap-object \
7950 -Wignored-qualifiers \
7951 -Wimplicit \
7952 -Wimplicit-function-declaration \
7953 -Wimplicit-int \
7954 -Winit-self \
7955 -Winline \
7956 -Wint-to-pointer-cast \
7957 -Winvalid-memory-model \
7958 -Winvalid-pch \
7959 -Wjump-misses-init \
7960 -Wlogical-op \
7961 -Wmain \
7962 -Wmaybe-uninitialized \
7963 -Wmissing-braces \
7964 -Wmissing-declarations \
7965 -Wmissing-field-initializers \
7966 -Wmissing-include-dirs \
7967 -Wmissing-parameter-type \
7968 -Wmissing-prototypes \
7969 -Wmudflap \
7970 -Wmultichar \
7971 -Wnarrowing \
7972 -Wnested-externs \
7973 -Wnonnull \
7974 -Wnormalized=nfc \
7975 -Wold-style-declaration \
7976 -Wold-style-definition \
7977 -Woverflow \
7978 -Woverlength-strings \
7979 -Woverride-init \
7980 -Wpacked \
7981 -Wpacked-bitfield-compat \
7982 -Wparentheses \
7983 -Wpointer-arith \
7984 -Wpointer-sign \
7985 -Wpointer-to-int-cast \
7986 -Wpragmas \
7987 -Wreturn-local-addr \
7988 -Wreturn-type \
7989 -Wsequence-point \
7990 -Wshadow \
7991 -Wsizeof-pointer-memaccess \
7992 -Wstack-protector \
7993 -Wstrict-aliasing \
7994 -Wstrict-overflow \
7995 -Wstrict-prototypes \
7996 -Wsuggest-attribute=const \
7997 -Wsuggest-attribute=format \
7998 -Wsuggest-attribute=noreturn \
7999 -Wsuggest-attribute=pure \
8000 -Wswitch \
8001 -Wswitch-default \
8002 -Wsync-nand \
8003 -Wsystem-headers \
8004 -Wtrampolines \
8005 -Wtrigraphs \
8006 -Wtype-limits \
8007 -Wuninitialized \
8008 -Wunknown-pragmas \
8009 -Wunsafe-loop-optimizations \
8010 -Wunused \
8011 -Wunused-but-set-parameter \
8012 -Wunused-but-set-variable \
8013 -Wunused-function \
8014 -Wunused-label \
8015 -Wunused-local-typedefs \
8016 -Wunused-macros \
8017 -Wunused-parameter \
8018 -Wunused-result \
8019 -Wunused-value \
8020 -Wunused-variable \
8021 -Wvarargs \
8022 -Wvariadic-macros \
8023 -Wvector-operation-performance \
8024 -Wvla \
8025 -Wvolatile-register-var \
8026 -Wwrite-strings \
8027 -fdiagnostics-show-option \
8028 -funit-at-a-time \
8029 \
8030 ; do
8031 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
8032 done
8033
8034 # Disable specific options as needed.
8035 if test "$gl_cv_cc_nomfi_needed" = yes; then
8036 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
8037 fi
8038
8039 if test "$gl_cv_cc_uninitialized_supported" = no; then
8040 gl_manywarn_set="$gl_manywarn_set -Wno-uninitialized"
8041 fi
8042
8043 ws=$gl_manywarn_set
8044
8045
8046 gl_warn_set=
8047 set x $ws; shift
8048 for gl_warn_item
8049 do
8050 case " $nw " in
8051 *" $gl_warn_item "*)
8052 ;;
8053 *)
8054 gl_warn_set="$gl_warn_set $gl_warn_item"
8055 ;;
8056 esac
8057 done
8058 ws=$gl_warn_set
8059
8060 for w in $ws; do
8061
8062 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
8063 gl_positive="$w"
8064 case $gl_positive in
8065 -Wno-*) gl_positive=-W`expr "X$gl_positive" : 'X-Wno-\(.*\)'` ;;
8066 esac
8067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
8068 $as_echo_n "checking whether C compiler handles $w... " >&6; }
8069 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
8070 $as_echo_n "(cached) " >&6
8071 else
8072
8073 gl_save_compiler_FLAGS="$CFLAGS"
8074 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors $gl_positive"
8075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8076 /* end confdefs.h. */
8077
8078 int
8079 main ()
8080 {
8081
8082 ;
8083 return 0;
8084 }
8085 _ACEOF
8086 if ac_fn_c_try_link "$LINENO"; then :
8087 eval "$as_gl_Warn=yes"
8088 else
8089 eval "$as_gl_Warn=no"
8090 fi
8091 rm -f core conftest.err conftest.$ac_objext \
8092 conftest$ac_exeext conftest.$ac_ext
8093 CFLAGS="$gl_save_compiler_FLAGS"
8094
8095 fi
8096 eval ac_res=\$$as_gl_Warn
8097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
8098 $as_echo "$ac_res" >&6; }
8099 eval as_val=\$$as_gl_Warn
8100 if test "x$as_val" = x""yes; then :
8101 as_fn_append WARN_CFLAGS " $w"
8102 fi
8103
8104
8105 done
8106
8107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
8108 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
8109 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
8110 $as_echo_n "(cached) " >&6
8111 else
8112
8113 gl_save_compiler_FLAGS="$CFLAGS"
8114 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wmissing-field-initializers"
8115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8116 /* end confdefs.h. */
8117
8118 int
8119 main ()
8120 {
8121
8122 ;
8123 return 0;
8124 }
8125 _ACEOF
8126 if ac_fn_c_try_link "$LINENO"; then :
8127 gl_cv_warn_c__Wno_missing_field_initializers=yes
8128 else
8129 gl_cv_warn_c__Wno_missing_field_initializers=no
8130 fi
8131 rm -f core conftest.err conftest.$ac_objext \
8132 conftest$ac_exeext conftest.$ac_ext
8133 CFLAGS="$gl_save_compiler_FLAGS"
8134
8135 fi
8136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
8137 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
8138 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
8139 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
8140 fi
8141
8142 # We need this one
8143
8144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
8145 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
8146 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
8147 $as_echo_n "(cached) " >&6
8148 else
8149
8150 gl_save_compiler_FLAGS="$CFLAGS"
8151 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wsign-compare"
8152 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8153 /* end confdefs.h. */
8154
8155 int
8156 main ()
8157 {
8158
8159 ;
8160 return 0;
8161 }
8162 _ACEOF
8163 if ac_fn_c_try_link "$LINENO"; then :
8164 gl_cv_warn_c__Wno_sign_compare=yes
8165 else
8166 gl_cv_warn_c__Wno_sign_compare=no
8167 fi
8168 rm -f core conftest.err conftest.$ac_objext \
8169 conftest$ac_exeext conftest.$ac_ext
8170 CFLAGS="$gl_save_compiler_FLAGS"
8171
8172 fi
8173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
8174 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
8175 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
8176 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
8177 fi
8178
8179 # Too many warnings for now
8180
8181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
8182 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
8183 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
8184 $as_echo_n "(cached) " >&6
8185 else
8186
8187 gl_save_compiler_FLAGS="$CFLAGS"
8188 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtype-limits"
8189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8190 /* end confdefs.h. */
8191
8192 int
8193 main ()
8194 {
8195
8196 ;
8197 return 0;
8198 }
8199 _ACEOF
8200 if ac_fn_c_try_link "$LINENO"; then :
8201 gl_cv_warn_c__Wno_type_limits=yes
8202 else
8203 gl_cv_warn_c__Wno_type_limits=no
8204 fi
8205 rm -f core conftest.err conftest.$ac_objext \
8206 conftest$ac_exeext conftest.$ac_ext
8207 CFLAGS="$gl_save_compiler_FLAGS"
8208
8209 fi
8210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
8211 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
8212 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
8213 as_fn_append WARN_CFLAGS " -Wno-type-limits"
8214 fi
8215
8216 # Too many warnings for now
8217
8218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
8219 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
8220 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
8221 $as_echo_n "(cached) " >&6
8222 else
8223
8224 gl_save_compiler_FLAGS="$CFLAGS"
8225 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wswitch"
8226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8227 /* end confdefs.h. */
8228
8229 int
8230 main ()
8231 {
8232
8233 ;
8234 return 0;
8235 }
8236 _ACEOF
8237 if ac_fn_c_try_link "$LINENO"; then :
8238 gl_cv_warn_c__Wno_switch=yes
8239 else
8240 gl_cv_warn_c__Wno_switch=no
8241 fi
8242 rm -f core conftest.err conftest.$ac_objext \
8243 conftest$ac_exeext conftest.$ac_ext
8244 CFLAGS="$gl_save_compiler_FLAGS"
8245
8246 fi
8247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
8248 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
8249 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
8250 as_fn_append WARN_CFLAGS " -Wno-switch"
8251 fi
8252
8253 # Too many warnings for now
8254
8255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
8256 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
8257 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
8258 $as_echo_n "(cached) " >&6
8259 else
8260
8261 gl_save_compiler_FLAGS="$CFLAGS"
8262 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-parameter"
8263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8264 /* end confdefs.h. */
8265
8266 int
8267 main ()
8268 {
8269
8270 ;
8271 return 0;
8272 }
8273 _ACEOF
8274 if ac_fn_c_try_link "$LINENO"; then :
8275 gl_cv_warn_c__Wno_unused_parameter=yes
8276 else
8277 gl_cv_warn_c__Wno_unused_parameter=no
8278 fi
8279 rm -f core conftest.err conftest.$ac_objext \
8280 conftest$ac_exeext conftest.$ac_ext
8281 CFLAGS="$gl_save_compiler_FLAGS"
8282
8283 fi
8284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
8285 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
8286 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
8287 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
8288 fi
8289
8290 # Too many warnings for now
8291
8292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
8293 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
8294 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
8295 $as_echo_n "(cached) " >&6
8296 else
8297
8298 gl_save_compiler_FLAGS="$CFLAGS"
8299 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-nonliteral"
8300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8301 /* end confdefs.h. */
8302
8303 int
8304 main ()
8305 {
8306
8307 ;
8308 return 0;
8309 }
8310 _ACEOF
8311 if ac_fn_c_try_link "$LINENO"; then :
8312 gl_cv_warn_c__Wno_format_nonliteral=yes
8313 else
8314 gl_cv_warn_c__Wno_format_nonliteral=no
8315 fi
8316 rm -f core conftest.err conftest.$ac_objext \
8317 conftest$ac_exeext conftest.$ac_ext
8318 CFLAGS="$gl_save_compiler_FLAGS"
8319
8320 fi
8321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
8322 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
8323 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
8324 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
8325 fi
8326
8327
8328
8329 # In spite of excluding -Wlogical-op above, it is enabled, as of
8330 # gcc 4.5.0 20090517.
8331
8332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
8333 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
8334 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
8335 $as_echo_n "(cached) " >&6
8336 else
8337
8338 gl_save_compiler_FLAGS="$CFLAGS"
8339 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wlogical-op"
8340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8341 /* end confdefs.h. */
8342
8343 int
8344 main ()
8345 {
8346
8347 ;
8348 return 0;
8349 }
8350 _ACEOF
8351 if ac_fn_c_try_link "$LINENO"; then :
8352 gl_cv_warn_c__Wno_logical_op=yes
8353 else
8354 gl_cv_warn_c__Wno_logical_op=no
8355 fi
8356 rm -f core conftest.err conftest.$ac_objext \
8357 conftest$ac_exeext conftest.$ac_ext
8358 CFLAGS="$gl_save_compiler_FLAGS"
8359
8360 fi
8361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
8362 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
8363 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
8364 as_fn_append WARN_CFLAGS " -Wno-logical-op"
8365 fi
8366
8367
8368
8369 # More things that clang is unduly picky about.
8370 if test $emacs_cv_clang = yes; then
8371
8372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-extra-args" >&5
8373 $as_echo_n "checking whether C compiler handles -Wno-format-extra-args... " >&6; }
8374 if test "${gl_cv_warn_c__Wno_format_extra_args+set}" = set; then :
8375 $as_echo_n "(cached) " >&6
8376 else
8377
8378 gl_save_compiler_FLAGS="$CFLAGS"
8379 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wformat-extra-args"
8380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8381 /* end confdefs.h. */
8382
8383 int
8384 main ()
8385 {
8386
8387 ;
8388 return 0;
8389 }
8390 _ACEOF
8391 if ac_fn_c_try_link "$LINENO"; then :
8392 gl_cv_warn_c__Wno_format_extra_args=yes
8393 else
8394 gl_cv_warn_c__Wno_format_extra_args=no
8395 fi
8396 rm -f core conftest.err conftest.$ac_objext \
8397 conftest$ac_exeext conftest.$ac_ext
8398 CFLAGS="$gl_save_compiler_FLAGS"
8399
8400 fi
8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_extra_args" >&5
8402 $as_echo "$gl_cv_warn_c__Wno_format_extra_args" >&6; }
8403 if test "x$gl_cv_warn_c__Wno_format_extra_args" = x""yes; then :
8404 as_fn_append WARN_CFLAGS " -Wno-format-extra-args"
8405 fi
8406
8407
8408
8409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare" >&5
8410 $as_echo_n "checking whether C compiler handles -Wno-tautological-constant-out-of-range-compare... " >&6; }
8411 if test "${gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare+set}" = set; then :
8412 $as_echo_n "(cached) " >&6
8413 else
8414
8415 gl_save_compiler_FLAGS="$CFLAGS"
8416 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wtautological-constant-out-of-range-compare"
8417 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8418 /* end confdefs.h. */
8419
8420 int
8421 main ()
8422 {
8423
8424 ;
8425 return 0;
8426 }
8427 _ACEOF
8428 if ac_fn_c_try_link "$LINENO"; then :
8429 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=yes
8430 else
8431 gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare=no
8432 fi
8433 rm -f core conftest.err conftest.$ac_objext \
8434 conftest$ac_exeext conftest.$ac_ext
8435 CFLAGS="$gl_save_compiler_FLAGS"
8436
8437 fi
8438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&5
8439 $as_echo "$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" >&6; }
8440 if test "x$gl_cv_warn_c__Wno_tautological_constant_out_of_range_compare" = x""yes; then :
8441 as_fn_append WARN_CFLAGS " -Wno-tautological-constant-out-of-range-compare"
8442 fi
8443
8444
8445
8446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-command-line-argument" >&5
8447 $as_echo_n "checking whether C compiler handles -Wno-unused-command-line-argument... " >&6; }
8448 if test "${gl_cv_warn_c__Wno_unused_command_line_argument+set}" = set; then :
8449 $as_echo_n "(cached) " >&6
8450 else
8451
8452 gl_save_compiler_FLAGS="$CFLAGS"
8453 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-command-line-argument"
8454 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8455 /* end confdefs.h. */
8456
8457 int
8458 main ()
8459 {
8460
8461 ;
8462 return 0;
8463 }
8464 _ACEOF
8465 if ac_fn_c_try_link "$LINENO"; then :
8466 gl_cv_warn_c__Wno_unused_command_line_argument=yes
8467 else
8468 gl_cv_warn_c__Wno_unused_command_line_argument=no
8469 fi
8470 rm -f core conftest.err conftest.$ac_objext \
8471 conftest$ac_exeext conftest.$ac_ext
8472 CFLAGS="$gl_save_compiler_FLAGS"
8473
8474 fi
8475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_command_line_argument" >&5
8476 $as_echo "$gl_cv_warn_c__Wno_unused_command_line_argument" >&6; }
8477 if test "x$gl_cv_warn_c__Wno_unused_command_line_argument" = x""yes; then :
8478 as_fn_append WARN_CFLAGS " -Wno-unused-command-line-argument"
8479 fi
8480
8481
8482
8483 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-value" >&5
8484 $as_echo_n "checking whether C compiler handles -Wno-unused-value... " >&6; }
8485 if test "${gl_cv_warn_c__Wno_unused_value+set}" = set; then :
8486 $as_echo_n "(cached) " >&6
8487 else
8488
8489 gl_save_compiler_FLAGS="$CFLAGS"
8490 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-value"
8491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8492 /* end confdefs.h. */
8493
8494 int
8495 main ()
8496 {
8497
8498 ;
8499 return 0;
8500 }
8501 _ACEOF
8502 if ac_fn_c_try_link "$LINENO"; then :
8503 gl_cv_warn_c__Wno_unused_value=yes
8504 else
8505 gl_cv_warn_c__Wno_unused_value=no
8506 fi
8507 rm -f core conftest.err conftest.$ac_objext \
8508 conftest$ac_exeext conftest.$ac_ext
8509 CFLAGS="$gl_save_compiler_FLAGS"
8510
8511 fi
8512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_value" >&5
8513 $as_echo "$gl_cv_warn_c__Wno_unused_value" >&6; }
8514 if test "x$gl_cv_warn_c__Wno_unused_value" = x""yes; then :
8515 as_fn_append WARN_CFLAGS " -Wno-unused-value"
8516 fi
8517
8518
8519 fi
8520
8521
8522 $as_echo "#define lint 1" >>confdefs.h
8523
8524
8525
8526 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
8527
8528
8529 # We use a slightly smaller set of warning options for lib/.
8530 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
8531 nw=
8532 nw="$nw -Wunused-macros"
8533
8534
8535 gl_warn_set=
8536 set x $WARN_CFLAGS; shift
8537 for gl_warn_item
8538 do
8539 case " $nw " in
8540 *" $gl_warn_item "*)
8541 ;;
8542 *)
8543 gl_warn_set="$gl_warn_set $gl_warn_item"
8544 ;;
8545 esac
8546 done
8547 GNULIB_WARN_CFLAGS=$gl_warn_set
8548
8549
8550 fi
8551
8552
8553
8554
8555
8556
8557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works for files in the same directory" >&5
8558 $as_echo_n "checking whether ln -s works for files in the same directory... " >&6; }
8559 rm -f conf$$ conf$$.file
8560
8561 LN_S_FILEONLY='cp -p'
8562
8563 if (echo >conf$$.file) 2>/dev/null; then
8564 if ln -s conf$$.file conf$$ 2>/dev/null; then
8565 LN_S_FILEONLY='ln -s'
8566 elif ln conf$$.file conf$$ 2>/dev/null; then
8567 LN_S_FILEONLY=ln
8568 fi
8569 fi
8570
8571 rm -f conf$$ conf$$.file
8572
8573 if test "$LN_S_FILEONLY" = "ln -s"; then
8574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8575 $as_echo "yes" >&6; }
8576 else
8577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S_FILEONLY" >&5
8578 $as_echo "no, using $LN_S_FILEONLY" >&6; }
8579 fi
8580
8581
8582
8583
8584 if test "$opsys" = "mingw32"; then
8585 LN_S="ln"
8586 fi
8587
8588 # Extract the first word of "install-info", so it can be a program name with args.
8589 set dummy install-info; ac_word=$2
8590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8591 $as_echo_n "checking for $ac_word... " >&6; }
8592 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
8593 $as_echo_n "(cached) " >&6
8594 else
8595 case $INSTALL_INFO in
8596 [\\/]* | ?:[\\/]*)
8597 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
8598 ;;
8599 *)
8600 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8601 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
8602 do
8603 IFS=$as_save_IFS
8604 test -z "$as_dir" && as_dir=.
8605 for ac_exec_ext in '' $ac_executable_extensions; do
8606 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8607 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
8608 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8609 break 2
8610 fi
8611 done
8612 done
8613 IFS=$as_save_IFS
8614
8615 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
8616 ;;
8617 esac
8618 fi
8619 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
8620 if test -n "$INSTALL_INFO"; then
8621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
8622 $as_echo "$INSTALL_INFO" >&6; }
8623 else
8624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8625 $as_echo "no" >&6; }
8626 fi
8627
8628
8629 # Extract the first word of "gzip", so it can be a program name with args.
8630 set dummy gzip; ac_word=$2
8631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8632 $as_echo_n "checking for $ac_word... " >&6; }
8633 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
8634 $as_echo_n "(cached) " >&6
8635 else
8636 case $GZIP_PROG in
8637 [\\/]* | ?:[\\/]*)
8638 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
8639 ;;
8640 *)
8641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8642 for as_dir in $PATH
8643 do
8644 IFS=$as_save_IFS
8645 test -z "$as_dir" && as_dir=.
8646 for ac_exec_ext in '' $ac_executable_extensions; do
8647 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8648 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
8649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8650 break 2
8651 fi
8652 done
8653 done
8654 IFS=$as_save_IFS
8655
8656 ;;
8657 esac
8658 fi
8659 GZIP_PROG=$ac_cv_path_GZIP_PROG
8660 if test -n "$GZIP_PROG"; then
8661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
8662 $as_echo "$GZIP_PROG" >&6; }
8663 else
8664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8665 $as_echo "no" >&6; }
8666 fi
8667
8668
8669
8670 test $with_compress_install != yes && test -n "$GZIP_PROG" && \
8671 GZIP_PROG=" # $GZIP_PROG # (disabled by configure --without-compress-install)"
8672
8673 if test $opsys = gnu-linux; then
8674 # Extract the first word of "paxctl", so it can be a program name with args.
8675 set dummy paxctl; ac_word=$2
8676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8677 $as_echo_n "checking for $ac_word... " >&6; }
8678 if test "${ac_cv_path_PAXCTL+set}" = set; then :
8679 $as_echo_n "(cached) " >&6
8680 else
8681 case $PAXCTL in
8682 [\\/]* | ?:[\\/]*)
8683 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
8684 ;;
8685 *)
8686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8687 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
8688 do
8689 IFS=$as_save_IFS
8690 test -z "$as_dir" && as_dir=.
8691 for ac_exec_ext in '' $ac_executable_extensions; do
8692 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8693 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
8694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8695 break 2
8696 fi
8697 done
8698 done
8699 IFS=$as_save_IFS
8700
8701 ;;
8702 esac
8703 fi
8704 PAXCTL=$ac_cv_path_PAXCTL
8705 if test -n "$PAXCTL"; then
8706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
8707 $as_echo "$PAXCTL" >&6; }
8708 else
8709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8710 $as_echo "no" >&6; }
8711 fi
8712
8713
8714 if test "X$PAXCTL" != X; then
8715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
8716 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
8717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8718 /* end confdefs.h. */
8719
8720 int
8721 main ()
8722 {
8723
8724 ;
8725 return 0;
8726 }
8727 _ACEOF
8728 if ac_fn_c_try_link "$LINENO"; then :
8729 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8730 $as_echo "yes" >&6; }
8731 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8732 $as_echo "no" >&6; }; PAXCTL=""; fi
8733 fi
8734 rm -f core conftest.err conftest.$ac_objext \
8735 conftest$ac_exeext conftest.$ac_ext
8736 fi
8737 fi
8738
8739 ## Need makeinfo >= 4.7 (?) to build the manuals.
8740 # Extract the first word of "makeinfo", so it can be a program name with args.
8741 set dummy makeinfo; ac_word=$2
8742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8743 $as_echo_n "checking for $ac_word... " >&6; }
8744 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
8745 $as_echo_n "(cached) " >&6
8746 else
8747 case $MAKEINFO in
8748 [\\/]* | ?:[\\/]*)
8749 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
8750 ;;
8751 *)
8752 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8753 for as_dir in $PATH
8754 do
8755 IFS=$as_save_IFS
8756 test -z "$as_dir" && as_dir=.
8757 for ac_exec_ext in '' $ac_executable_extensions; do
8758 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8759 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8760 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8761 break 2
8762 fi
8763 done
8764 done
8765 IFS=$as_save_IFS
8766
8767 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8768 ;;
8769 esac
8770 fi
8771 MAKEINFO=$ac_cv_path_MAKEINFO
8772 if test -n "$MAKEINFO"; then
8773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8774 $as_echo "$MAKEINFO" >&6; }
8775 else
8776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8777 $as_echo "no" >&6; }
8778 fi
8779
8780
8781 if test "$MAKEINFO" != "no"; then
8782 case `
8783 $MAKEINFO --version 2> /dev/null |
8784 $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'
8785 ` in
8786 '') MAKEINFO=no;;
8787 esac
8788 fi
8789
8790 ## Makeinfo is unusual. For a released Emacs, the manuals are
8791 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8792 ## therefore in the category of "special tools" not normally required, which
8793 ## configure does not have to check for (eg autoconf itself).
8794 ## In a Bazaar checkout on the other hand, the manuals are not included.
8795 ## So makeinfo is a requirement to build from Bazaar, and configure
8796 ## should test for it as it does for any other build requirement.
8797 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8798 ## with pre-built manuals, from a Bazaar checkout.
8799 HAVE_MAKEINFO=yes
8800
8801 if test "$MAKEINFO" = "no"; then
8802 MAKEINFO=makeinfo
8803 if test "x${with_makeinfo}" = "xno"; then
8804 HAVE_MAKEINFO=no
8805 elif test ! -e "$srcdir/info/emacs" && test ! -e "$srcdir/info/emacs.info"; then
8806 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8807 source tree does not seem to have pre-built manuals in the \`info' directory.
8808 Either install a suitable version of makeinfo, or re-run configure
8809 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8810 fi
8811 fi
8812
8813
8814 INFO_EXT=.info
8815 INFO_OPTS=--no-split
8816
8817
8818
8819 if test $opsys = mingw32; then
8820 DOCMISC_W32=efaq-w32
8821 else
8822 DOCMISC_W32=
8823 fi
8824
8825
8826
8827 if test x$GCC = xyes; then
8828 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8829 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8830 else
8831 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8832 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8833 fi
8834
8835
8836 late_LDFLAGS="$LDFLAGS"
8837 if test x$GCC = xyes; then
8838 LDFLAGS_NOCOMBRELOC="-Wl,-znocombreloc"
8839 else
8840 LDFLAGS_NOCOMBRELOC="-znocombreloc"
8841 fi
8842
8843 LDFLAGS="$LDFLAGS $LDFLAGS_NOCOMBRELOC"
8844
8845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8846 $as_echo_n "checking for -znocombreloc... " >&6; }
8847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8848 /* end confdefs.h. */
8849
8850 int
8851 main ()
8852 {
8853
8854 ;
8855 return 0;
8856 }
8857 _ACEOF
8858 if ac_fn_c_try_link "$LINENO"; then :
8859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8860 $as_echo "yes" >&6; }
8861 else
8862 LDFLAGS_NOCOMBRELOC=
8863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8864 $as_echo "no" >&6; }
8865 fi
8866 rm -f core conftest.err conftest.$ac_objext \
8867 conftest$ac_exeext conftest.$ac_ext
8868
8869 LDFLAGS="$late_LDFLAGS"
8870
8871 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8872 case "$opsys" in
8873 your-opsys-here) CANNOT_DUMP=yes ;;
8874 esac
8875
8876 test "$CANNOT_DUMP" = "yes" && \
8877
8878 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8879
8880
8881
8882
8883
8884 UNEXEC_OBJ=unexelf.o
8885 case "$opsys" in
8886 # MSDOS uses unexcoff.o
8887 aix4-2)
8888 UNEXEC_OBJ=unexaix.o
8889 ;;
8890 cygwin)
8891 UNEXEC_OBJ=unexcw.o
8892 ;;
8893 darwin)
8894 UNEXEC_OBJ=unexmacosx.o
8895 ;;
8896 hpux10-20 | hpux11)
8897 UNEXEC_OBJ=unexhp9k800.o
8898 ;;
8899 mingw32)
8900 UNEXEC_OBJ=unexw32.o
8901 ;;
8902 sol2-10)
8903 # Use the Solaris dldump() function, called from unexsol.c, to dump
8904 # emacs, instead of the generic ELF dump code found in unexelf.c.
8905 # The resulting binary has a complete symbol table, and is better
8906 # for debugging and other observability tools (debuggers, pstack, etc).
8907 #
8908 # If you encounter a problem using dldump(), please consider sending
8909 # a message to the OpenSolaris tools-linking mailing list:
8910 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8911 #
8912 # It is likely that dldump() works with older Solaris too, but this has
8913 # not been tested, so for now this change is for Solaris 10 or newer.
8914 UNEXEC_OBJ=unexsol.o
8915 ;;
8916 esac
8917
8918 LD_SWITCH_SYSTEM=
8919 case "$opsys" in
8920 freebsd|dragonfly)
8921 ## Let `ld' find image libs and similar things in /usr/local/lib.
8922 ## The system compiler, GCC, has apparently been modified to not
8923 ## look there, contrary to what a stock GCC would do.
8924 ### It's not our place to do this. See bug#10313#17.
8925 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8926 :
8927 ;;
8928
8929 gnu-linux)
8930 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8931 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8932 ;;
8933
8934 netbsd)
8935 ### It's not our place to do this. See bug#10313#17.
8936 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8937 :
8938 ;;
8939
8940 openbsd)
8941 ## Han Boetes <han@boetes.org> says this is necessary,
8942 ## otherwise Emacs dumps core on elf systems.
8943 LD_SWITCH_SYSTEM="-Z"
8944 ;;
8945 esac
8946
8947
8948 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8949
8950 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8951 ## which has not been defined yet. When this was handled with cpp,
8952 ## it was expanded to null when configure sourced the s/*.h file.
8953 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8954 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8955 ## (or somesuch), but because it is supposed to go at the _front_
8956 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8957 ## Compare with the gnu-linux case below, which added to the end
8958 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8959 ## LD_SWITCH_SYSTEM_TEMACS.
8960 case "$opsys" in
8961 netbsd|openbsd)
8962 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8963 esac
8964
8965
8966 C_SWITCH_MACHINE=
8967 case $canonical in
8968 alpha*)
8969 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8970 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8971
8972 fi
8973
8974 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8975 ## With ELF, make sure that all common symbols get allocated to in the
8976 ## data section. Otherwise, the dump of temacs may miss variables in
8977 ## the shared library that have been initialized. For example, with
8978 ## GNU libc, __malloc_initialized would normally be resolved to the
8979 ## shared library's .bss section, which is fatal.
8980 if test "x$GCC" = "xyes"; then
8981 C_SWITCH_MACHINE="-fno-common"
8982 else
8983 as_fn_error "Non-GCC compilers are not supported." "$LINENO" 5
8984 fi
8985 else
8986 as_fn_error "Non-ELF systems are not supported since Emacs 24.1." "$LINENO" 5
8987 fi
8988 ;;
8989 esac
8990
8991
8992
8993
8994 C_SWITCH_SYSTEM=
8995 ## Some programs in src produce warnings saying certain subprograms
8996 ## are too complex and need a MAXMEM value greater than 2000 for
8997 ## additional optimization. --nils@exp-math.uni-essen.de
8998 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8999 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
9000 test "$opsys" = "mingw32" && C_SWITCH_SYSTEM="-mtune=pentium4"
9001 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
9002 ## It is redundant in glibc2, since we define _GNU_SOURCE.
9003
9004
9005
9006 LIBS_SYSTEM=
9007 case "$opsys" in
9008 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
9009 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
9010
9011 freebsd|dragonfly) LIBS_SYSTEM="-lutil" ;;
9012
9013 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
9014
9015 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
9016
9017 ## Motif needs -lgen.
9018 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
9019 esac
9020
9021
9022
9023 ### Make sure subsequent tests use flags consistent with the build flags.
9024
9025 if test x"${OVERRIDE_CPPFLAGS}" != x; then
9026 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
9027 else
9028 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
9029 fi
9030
9031 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
9032
9033 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
9034
9035
9036
9037 LIB_MATH=-lm
9038 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
9039
9040 case $opsys in
9041 cygwin )
9042 LIB_MATH=
9043 ;;
9044 darwin )
9045 ## Adding -lm confuses the dynamic linker, so omit it.
9046 LIB_MATH=
9047 ;;
9048 freebsd | dragonfly )
9049 SYSTEM_TYPE=berkeley-unix
9050 ;;
9051 gnu-linux | gnu-kfreebsd )
9052 ;;
9053 hpux10-20 | hpux11 )
9054 ;;
9055 mingw32 )
9056 LIB_MATH=
9057 SYSTEM_TYPE=windows-nt
9058 ;;
9059 netbsd | openbsd )
9060 SYSTEM_TYPE=berkeley-unix
9061 ;;
9062
9063 sol2* | unixware )
9064 SYSTEM_TYPE=usg-unix-v
9065 ;;
9066
9067 esac
9068
9069
9070
9071 cat >>confdefs.h <<_ACEOF
9072 #define SYSTEM_TYPE "$SYSTEM_TYPE"
9073 _ACEOF
9074
9075
9076
9077 pre_PKG_CONFIG_CFLAGS=$CFLAGS
9078 pre_PKG_CONFIG_LIBS=$LIBS
9079
9080 # Extract the first word of "pkg-config", so it can be a program name with args.
9081 set dummy pkg-config; ac_word=$2
9082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9083 $as_echo_n "checking for $ac_word... " >&6; }
9084 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
9085 $as_echo_n "(cached) " >&6
9086 else
9087 case $PKG_CONFIG in
9088 [\\/]* | ?:[\\/]*)
9089 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
9090 ;;
9091 *)
9092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9093 for as_dir in $PATH
9094 do
9095 IFS=$as_save_IFS
9096 test -z "$as_dir" && as_dir=.
9097 for ac_exec_ext in '' $ac_executable_extensions; do
9098 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9099 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
9100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9101 break 2
9102 fi
9103 done
9104 done
9105 IFS=$as_save_IFS
9106
9107 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
9108 ;;
9109 esac
9110 fi
9111 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
9112 if test -n "$PKG_CONFIG"; then
9113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
9114 $as_echo "$PKG_CONFIG" >&6; }
9115 else
9116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9117 $as_echo "no" >&6; }
9118 fi
9119
9120
9121
9122
9123
9124 HAVE_SOUND=no
9125 if test "${with_sound}" != "no"; then
9126 # Sound support for GNU/Linux, the free BSDs, and MinGW.
9127 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
9128 do :
9129 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9130 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "
9131 #ifdef __MINGW32__
9132 #define WIN32_LEAN_AND_MEAN
9133 #include <windows.h>
9134 #endif
9135
9136 "
9137 eval as_val=\$$as_ac_Header
9138 if test "x$as_val" = x""yes; then :
9139 cat >>confdefs.h <<_ACEOF
9140 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9141 _ACEOF
9142 have_sound_header=yes
9143 fi
9144
9145 done
9146
9147 test "${with_sound}" = "oss" && test "${have_sound_header}" != "yes" && \
9148 as_fn_error "OSS sound support requested but not found." "$LINENO" 5
9149
9150 if test "${with_sound}" = "bsd-ossaudio" || test "${with_sound}" = "yes"; then
9151 # Emulation library used on NetBSD.
9152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
9153 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
9154 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
9155 $as_echo_n "(cached) " >&6
9156 else
9157 ac_check_lib_save_LIBS=$LIBS
9158 LIBS="-lossaudio $LIBS"
9159 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9160 /* end confdefs.h. */
9161
9162 /* Override any GCC internal prototype to avoid an error.
9163 Use char because int might match the return type of a GCC
9164 builtin and then its argument prototype would still apply. */
9165 #ifdef __cplusplus
9166 extern "C"
9167 #endif
9168 char _oss_ioctl ();
9169 int
9170 main ()
9171 {
9172 return _oss_ioctl ();
9173 ;
9174 return 0;
9175 }
9176 _ACEOF
9177 if ac_fn_c_try_link "$LINENO"; then :
9178 ac_cv_lib_ossaudio__oss_ioctl=yes
9179 else
9180 ac_cv_lib_ossaudio__oss_ioctl=no
9181 fi
9182 rm -f core conftest.err conftest.$ac_objext \
9183 conftest$ac_exeext conftest.$ac_ext
9184 LIBS=$ac_check_lib_save_LIBS
9185 fi
9186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
9187 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
9188 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
9189 LIBSOUND=-lossaudio
9190 else
9191 LIBSOUND=
9192 fi
9193
9194 test "${with_sound}" = "bsd-ossaudio" && test -z "$LIBSOUND" && \
9195 as_fn_error "bsd-ossaudio sound support requested but not found." "$LINENO" 5
9196 fi
9197
9198
9199 if test "${with_sound}" = "alsa" || test "${with_sound}" = "yes"; then
9200 ALSA_REQUIRED=1.0.0
9201 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
9202
9203 succeeded=no
9204
9205 if test "$PKG_CONFIG" = "no" ; then
9206 HAVE_ALSA=no
9207 else
9208 PKG_CONFIG_MIN_VERSION=0.9.0
9209 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
9210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
9211 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
9212
9213 if "$PKG_CONFIG" --exists "$ALSA_MODULES" 2>&5 &&
9214 ALSA_CFLAGS=`"$PKG_CONFIG" --cflags "$ALSA_MODULES" 2>&5` &&
9215 ALSA_LIBS=`"$PKG_CONFIG" --libs "$ALSA_MODULES" 2>&5`; then
9216 edit_cflags="
9217 s,///*,/,g
9218 s/^/ /
9219 s/ -I/ $isystem/g
9220 s/^ //
9221 "
9222 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
9223 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
9224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
9225 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
9226 succeeded=yes
9227 else
9228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9229 $as_echo "no" >&6; }
9230 ALSA_CFLAGS=""
9231 ALSA_LIBS=""
9232 ## If we have a custom action on failure, don't print errors, but
9233 ## do set a variable so people can do so. Do it in a subshell
9234 ## to capture any diagnostics in invoking pkg-config.
9235 ALSA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$ALSA_MODULES") 2>&1`
9236
9237 fi
9238
9239
9240
9241 else
9242 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
9243 echo "*** See http://www.freedesktop.org/software/pkgconfig"
9244 fi
9245 fi
9246
9247 if test $succeeded = yes; then
9248 HAVE_ALSA=yes
9249 else
9250 HAVE_ALSA=no
9251 fi
9252
9253 if test $HAVE_ALSA = yes; then
9254 SAVE_CFLAGS="$CFLAGS"
9255 SAVE_LIBS="$LIBS"
9256 CFLAGS="$ALSA_CFLAGS $CFLAGS"
9257 LIBS="$ALSA_LIBS $LIBS"
9258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9259 /* end confdefs.h. */
9260 #include <asoundlib.h>
9261 int
9262 main ()
9263 {
9264 snd_lib_error_set_handler (0);
9265 ;
9266 return 0;
9267 }
9268 _ACEOF
9269 if ac_fn_c_try_compile "$LINENO"; then :
9270 emacs_alsa_normal=yes
9271 else
9272 emacs_alsa_normal=no
9273 fi
9274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9275 if test "$emacs_alsa_normal" != yes; then
9276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9277 /* end confdefs.h. */
9278 #include <alsa/asoundlib.h>
9279 int
9280 main ()
9281 {
9282 snd_lib_error_set_handler (0);
9283 ;
9284 return 0;
9285 }
9286 _ACEOF
9287 if ac_fn_c_try_compile "$LINENO"; then :
9288 emacs_alsa_subdir=yes
9289 else
9290 emacs_alsa_subdir=no
9291 fi
9292 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9293 if test "$emacs_alsa_subdir" != yes; then
9294 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
9295 fi
9296 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
9297 fi
9298
9299 CFLAGS="$SAVE_CFLAGS"
9300 LIBS="$SAVE_LIBS"
9301 LIBSOUND="$LIBSOUND $ALSA_LIBS"
9302 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
9303
9304 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
9305
9306 elif test "${with_sound}" = "alsa"; then
9307 as_fn_error "ALSA sound support requested but not found." "$LINENO" 5
9308 fi
9309 fi
9310 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
9311 case "$opsys" in
9312 gnu-linux|freebsd|netbsd|mingw32)
9313
9314 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
9315
9316 HAVE_SOUND=yes
9317 ;;
9318 esac
9319 fi
9320
9321
9322 fi
9323
9324
9325
9326
9327 for ac_header in $ac_header_list
9328 do :
9329 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9330 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9331 "
9332 eval as_val=\$$as_ac_Header
9333 if test "x$as_val" = x""yes; then :
9334 cat >>confdefs.h <<_ACEOF
9335 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9336 _ACEOF
9337
9338 fi
9339
9340 done
9341
9342
9343
9344
9345
9346
9347
9348
9349
9350
9351
9352
9353
9354
9355
9356
9357
9358
9359
9360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
9361 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
9362 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9363 /* end confdefs.h. */
9364 #include <sys/personality.h>
9365 int
9366 main ()
9367 {
9368 personality (PER_LINUX32)
9369 ;
9370 return 0;
9371 }
9372 _ACEOF
9373 if ac_fn_c_try_compile "$LINENO"; then :
9374 emacs_cv_personality_linux32=yes
9375 else
9376 emacs_cv_personality_linux32=no
9377 fi
9378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
9380 $as_echo "$emacs_cv_personality_linux32" >&6; }
9381
9382 if test $emacs_cv_personality_linux32 = yes; then
9383
9384 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
9385
9386 fi
9387
9388 for ac_header in term.h
9389 do :
9390 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
9391 if test "x$ac_cv_header_term_h" = x""yes; then :
9392 cat >>confdefs.h <<_ACEOF
9393 #define HAVE_TERM_H 1
9394 _ACEOF
9395
9396 fi
9397
9398 done
9399
9400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
9401 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
9402 if test "${ac_cv_header_time+set}" = set; then :
9403 $as_echo_n "(cached) " >&6
9404 else
9405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9406 /* end confdefs.h. */
9407 #include <sys/types.h>
9408 #include <sys/time.h>
9409 #include <time.h>
9410
9411 int
9412 main ()
9413 {
9414 if ((struct tm *) 0)
9415 return 0;
9416 ;
9417 return 0;
9418 }
9419 _ACEOF
9420 if ac_fn_c_try_compile "$LINENO"; then :
9421 ac_cv_header_time=yes
9422 else
9423 ac_cv_header_time=no
9424 fi
9425 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9426 fi
9427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
9428 $as_echo "$ac_cv_header_time" >&6; }
9429 if test $ac_cv_header_time = yes; then
9430
9431 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
9432
9433 fi
9434
9435 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
9436
9437 "
9438 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
9439 ac_have_decl=1
9440 else
9441 ac_have_decl=0
9442 fi
9443
9444 cat >>confdefs.h <<_ACEOF
9445 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
9446 _ACEOF
9447
9448 if test $ac_cv_have_decl_sys_siglist != yes; then
9449 # For Tru64, at least:
9450 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "#include <signal.h>
9451
9452 "
9453 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
9454 ac_have_decl=1
9455 else
9456 ac_have_decl=0
9457 fi
9458
9459 cat >>confdefs.h <<_ACEOF
9460 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
9461 _ACEOF
9462
9463 fi
9464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
9465 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
9466 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
9467 $as_echo_n "(cached) " >&6
9468 else
9469 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9470 /* end confdefs.h. */
9471 #include <sys/types.h>
9472 #include <sys/wait.h>
9473 #ifndef WEXITSTATUS
9474 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
9475 #endif
9476 #ifndef WIFEXITED
9477 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
9478 #endif
9479
9480 int
9481 main ()
9482 {
9483 int s;
9484 wait (&s);
9485 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
9486 ;
9487 return 0;
9488 }
9489 _ACEOF
9490 if ac_fn_c_try_compile "$LINENO"; then :
9491 ac_cv_header_sys_wait_h=yes
9492 else
9493 ac_cv_header_sys_wait_h=no
9494 fi
9495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9496 fi
9497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
9498 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
9499 if test $ac_cv_header_sys_wait_h = yes; then
9500
9501 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
9502
9503 fi
9504
9505
9506
9507
9508
9509 for ac_header in net/if.h
9510 do :
9511 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
9512 #if HAVE_SYS_SOCKET_H
9513 #include <sys/socket.h>
9514 #endif
9515 "
9516 if test "x$ac_cv_header_net_if_h" = x""yes; then :
9517 cat >>confdefs.h <<_ACEOF
9518 #define HAVE_NET_IF_H 1
9519 _ACEOF
9520
9521 fi
9522
9523 done
9524
9525 for ac_header in ifaddrs.h
9526 do :
9527 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
9528 #if HAVE_SYS_SOCKET_H
9529 #include <sys/socket.h>
9530 #endif
9531 "
9532 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
9533 cat >>confdefs.h <<_ACEOF
9534 #define HAVE_IFADDRS_H 1
9535 _ACEOF
9536
9537 fi
9538
9539 done
9540
9541 for ac_header in net/if_dl.h
9542 do :
9543 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
9544 #if HAVE_SYS_SOCKET_H
9545 #include <sys/socket.h>
9546 #endif
9547 "
9548 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
9549 cat >>confdefs.h <<_ACEOF
9550 #define HAVE_NET_IF_DL_H 1
9551 _ACEOF
9552
9553 fi
9554
9555 done
9556
9557
9558 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
9559 #if HAVE_SYS_SOCKET_H
9560 #include <sys/socket.h>
9561 #endif
9562 #if HAVE_NET_IF_H
9563 #include <net/if.h>
9564 #endif
9565 "
9566 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
9567
9568 cat >>confdefs.h <<_ACEOF
9569 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
9570 _ACEOF
9571
9572
9573 fi
9574 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
9575 #if HAVE_SYS_SOCKET_H
9576 #include <sys/socket.h>
9577 #endif
9578 #if HAVE_NET_IF_H
9579 #include <net/if.h>
9580 #endif
9581 "
9582 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
9583
9584 cat >>confdefs.h <<_ACEOF
9585 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
9586 _ACEOF
9587
9588
9589 fi
9590 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
9591 #if HAVE_SYS_SOCKET_H
9592 #include <sys/socket.h>
9593 #endif
9594 #if HAVE_NET_IF_H
9595 #include <net/if.h>
9596 #endif
9597 "
9598 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
9599
9600 cat >>confdefs.h <<_ACEOF
9601 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
9602 _ACEOF
9603
9604
9605 fi
9606 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
9607 #if HAVE_SYS_SOCKET_H
9608 #include <sys/socket.h>
9609 #endif
9610 #if HAVE_NET_IF_H
9611 #include <net/if.h>
9612 #endif
9613 "
9614 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
9615
9616 cat >>confdefs.h <<_ACEOF
9617 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
9618 _ACEOF
9619
9620
9621 fi
9622 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
9623 #if HAVE_SYS_SOCKET_H
9624 #include <sys/socket.h>
9625 #endif
9626 #if HAVE_NET_IF_H
9627 #include <net/if.h>
9628 #endif
9629 "
9630 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9631
9632 cat >>confdefs.h <<_ACEOF
9633 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9634 _ACEOF
9635
9636
9637 fi
9638 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9639 #if HAVE_SYS_SOCKET_H
9640 #include <sys/socket.h>
9641 #endif
9642 #if HAVE_NET_IF_H
9643 #include <net/if.h>
9644 #endif
9645 "
9646 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9647
9648 cat >>confdefs.h <<_ACEOF
9649 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9650 _ACEOF
9651
9652
9653 fi
9654
9655
9656
9657
9658 DEPFLAGS=
9659 MKDEPDIR=":"
9660 deps_frag=deps.mk
9661 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9663 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9664 HAVE_GNU_MAKE=no
9665 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9666 if test "x$testval" != x; then
9667 HAVE_GNU_MAKE=yes
9668 else
9669 ac_enable_autodepend=no
9670 fi
9671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9672 $as_echo "$HAVE_GNU_MAKE" >&6; }
9673 if test $HAVE_GNU_MAKE = yes; then
9674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9675 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9676 SAVE_CFLAGS="$CFLAGS"
9677 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9679 /* end confdefs.h. */
9680
9681 int
9682 main ()
9683 {
9684
9685 ;
9686 return 0;
9687 }
9688 _ACEOF
9689 if ac_fn_c_try_compile "$LINENO"; then :
9690
9691 else
9692 ac_enable_autodepend=no
9693 fi
9694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9695 CFLAGS="$SAVE_CFLAGS"
9696 test -f deps.d || ac_enable_autodepend=no
9697 rm -rf deps.d
9698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9699 $as_echo "$ac_enable_autodepend" >&6; }
9700 fi
9701 if test $ac_enable_autodepend = yes; then
9702 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9703 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9704 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9705 deps_frag=autodeps.mk
9706 fi
9707 fi
9708 deps_frag=$srcdir/src/$deps_frag
9709
9710
9711
9712
9713
9714 lisp_frag=$srcdir/src/lisp.mk
9715
9716
9717
9718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9719 $as_echo_n "checking for long file names... " >&6; }
9720 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9721 $as_echo_n "(cached) " >&6
9722 else
9723 ac_cv_sys_long_file_names=yes
9724 # Test for long file names in all the places we know might matter:
9725 # . the current directory, where building will happen
9726 # $prefix/lib where we will be installing things
9727 # $exec_prefix/lib likewise
9728 # $TMPDIR if set, where it might want to write temporary files
9729 # /tmp where it might want to write temporary files
9730 # /var/tmp likewise
9731 # /usr/tmp likewise
9732 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9733 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9734 # in the usual case where exec_prefix is '${prefix}'.
9735 case $ac_dir in #(
9736 . | /* | ?:[\\/]*) ;; #(
9737 *) continue;;
9738 esac
9739 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9740 ac_xdir=$ac_dir/cf$$
9741 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9742 ac_tf1=$ac_xdir/conftest9012345
9743 ac_tf2=$ac_xdir/conftest9012346
9744 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9745 ac_cv_sys_long_file_names=no
9746 rm -f -r "$ac_xdir" 2>/dev/null
9747 test $ac_cv_sys_long_file_names = no && break
9748 done
9749 fi
9750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9751 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9752 if test $ac_cv_sys_long_file_names = yes; then
9753
9754 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9755
9756 fi
9757
9758
9759 #### Choose a window system.
9760
9761 ## We leave window_system equal to none if
9762 ## we end up building without one. Any new window system should
9763 ## set window_system to an appropriate value and add objects to
9764 ## window-system-specific substs.
9765
9766 window_system=none
9767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9768 $as_echo_n "checking for X... " >&6; }
9769
9770
9771 # Check whether --with-x was given.
9772 if test "${with_x+set}" = set; then :
9773 withval=$with_x;
9774 fi
9775
9776 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9777 if test "x$with_x" = xno; then
9778 # The user explicitly disabled X.
9779 have_x=disabled
9780 else
9781 case $x_includes,$x_libraries in #(
9782 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9783 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9784 $as_echo_n "(cached) " >&6
9785 else
9786 # One or both of the vars are not set, and there is no cached value.
9787 ac_x_includes=no ac_x_libraries=no
9788 rm -f -r conftest.dir
9789 if mkdir conftest.dir; then
9790 cd conftest.dir
9791 cat >Imakefile <<'_ACEOF'
9792 incroot:
9793 @echo incroot='${INCROOT}'
9794 usrlibdir:
9795 @echo usrlibdir='${USRLIBDIR}'
9796 libdir:
9797 @echo libdir='${LIBDIR}'
9798 _ACEOF
9799 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9800 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9801 for ac_var in incroot usrlibdir libdir; do
9802 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9803 done
9804 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9805 for ac_extension in a so sl dylib la dll; do
9806 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9807 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9808 ac_im_usrlibdir=$ac_im_libdir; break
9809 fi
9810 done
9811 # Screen out bogus values from the imake configuration. They are
9812 # bogus both because they are the default anyway, and because
9813 # using them would break gcc on systems where it needs fixed includes.
9814 case $ac_im_incroot in
9815 /usr/include) ac_x_includes= ;;
9816 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9817 esac
9818 case $ac_im_usrlibdir in
9819 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9820 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9821 esac
9822 fi
9823 cd ..
9824 rm -f -r conftest.dir
9825 fi
9826
9827 # Standard set of common directories for X headers.
9828 # Check X11 before X11Rn because it is often a symlink to the current release.
9829 ac_x_header_dirs='
9830 /usr/X11/include
9831 /usr/X11R7/include
9832 /usr/X11R6/include
9833 /usr/X11R5/include
9834 /usr/X11R4/include
9835
9836 /usr/include/X11
9837 /usr/include/X11R7
9838 /usr/include/X11R6
9839 /usr/include/X11R5
9840 /usr/include/X11R4
9841
9842 /usr/local/X11/include
9843 /usr/local/X11R7/include
9844 /usr/local/X11R6/include
9845 /usr/local/X11R5/include
9846 /usr/local/X11R4/include
9847
9848 /usr/local/include/X11
9849 /usr/local/include/X11R7
9850 /usr/local/include/X11R6
9851 /usr/local/include/X11R5
9852 /usr/local/include/X11R4
9853
9854 /usr/X386/include
9855 /usr/x386/include
9856 /usr/XFree86/include/X11
9857
9858 /usr/include
9859 /usr/local/include
9860 /usr/unsupported/include
9861 /usr/athena/include
9862 /usr/local/x11r5/include
9863 /usr/lpp/Xamples/include
9864
9865 /usr/openwin/include
9866 /usr/openwin/share/include'
9867
9868 if test "$ac_x_includes" = no; then
9869 # Guess where to find include files, by looking for Xlib.h.
9870 # First, try using that file with no special directory specified.
9871 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9872 /* end confdefs.h. */
9873 #include <X11/Xlib.h>
9874 _ACEOF
9875 if ac_fn_c_try_cpp "$LINENO"; then :
9876 # We can compile using X headers with no special include directory.
9877 ac_x_includes=
9878 else
9879 for ac_dir in $ac_x_header_dirs; do
9880 if test -r "$ac_dir/X11/Xlib.h"; then
9881 ac_x_includes=$ac_dir
9882 break
9883 fi
9884 done
9885 fi
9886 rm -f conftest.err conftest.$ac_ext
9887 fi # $ac_x_includes = no
9888
9889 if test "$ac_x_libraries" = no; then
9890 # Check for the libraries.
9891 # See if we find them without any special options.
9892 # Don't add to $LIBS permanently.
9893 ac_save_LIBS=$LIBS
9894 LIBS="-lX11 $LIBS"
9895 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9896 /* end confdefs.h. */
9897 #include <X11/Xlib.h>
9898 int
9899 main ()
9900 {
9901 XrmInitialize ()
9902 ;
9903 return 0;
9904 }
9905 _ACEOF
9906 if ac_fn_c_try_link "$LINENO"; then :
9907 LIBS=$ac_save_LIBS
9908 # We can link X programs with no special library path.
9909 ac_x_libraries=
9910 else
9911 LIBS=$ac_save_LIBS
9912 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9913 do
9914 # Don't even attempt the hair of trying to link an X program!
9915 for ac_extension in a so sl dylib la dll; do
9916 if test -r "$ac_dir/libX11.$ac_extension"; then
9917 ac_x_libraries=$ac_dir
9918 break 2
9919 fi
9920 done
9921 done
9922 fi
9923 rm -f core conftest.err conftest.$ac_objext \
9924 conftest$ac_exeext conftest.$ac_ext
9925 fi # $ac_x_libraries = no
9926
9927 case $ac_x_includes,$ac_x_libraries in #(
9928 no,* | *,no | *\'*)
9929 # Didn't find X, or a directory has "'" in its name.
9930 ac_cv_have_x="have_x=no";; #(
9931 *)
9932 # Record where we found X for the cache.
9933 ac_cv_have_x="have_x=yes\
9934 ac_x_includes='$ac_x_includes'\
9935 ac_x_libraries='$ac_x_libraries'"
9936 esac
9937 fi
9938 ;; #(
9939 *) have_x=yes;;
9940 esac
9941 eval "$ac_cv_have_x"
9942 fi # $with_x != no
9943
9944 if test "$have_x" != yes; then
9945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9946 $as_echo "$have_x" >&6; }
9947 no_x=yes
9948 else
9949 # If each of the values was on the command line, it overrides each guess.
9950 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9951 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9952 # Update the cache value to reflect the command line values.
9953 ac_cv_have_x="have_x=yes\
9954 ac_x_includes='$x_includes'\
9955 ac_x_libraries='$x_libraries'"
9956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9957 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9958 fi
9959
9960 if test "$no_x" != yes; then
9961 window_system=x11
9962 fi
9963
9964 LD_SWITCH_X_SITE_RPATH=
9965 if test "${x_libraries}" != NONE; then
9966 if test -n "${x_libraries}"; then
9967 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9968 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9969 fi
9970 x_default_search_path=""
9971 x_search_path=${x_libraries}
9972 if test -z "${x_search_path}"; then
9973 x_search_path=/usr/lib
9974 fi
9975 for x_library in `echo ${x_search_path}: | \
9976 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9977 x_search_path="\
9978 ${x_library}/X11/%L/%T/%N%C%S:\
9979 ${x_library}/X11/%l/%T/%N%C%S:\
9980 ${x_library}/X11/%T/%N%C%S:\
9981 ${x_library}/X11/%L/%T/%N%S:\
9982 ${x_library}/X11/%l/%T/%N%S:\
9983 ${x_library}/X11/%T/%N%S"
9984 if test x"${x_default_search_path}" = x; then
9985 x_default_search_path=${x_search_path}
9986 else
9987 x_default_search_path="${x_search_path}:${x_default_search_path}"
9988 fi
9989 done
9990 fi
9991
9992
9993 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9994 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9995 fi
9996
9997 if test x"${x_includes}" = x; then
9998 bitmapdir=/usr/include/X11/bitmaps
9999 else
10000 # accumulate include directories that have X11 bitmap subdirectories
10001 bmd_acc="dummyval"
10002 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
10003 if test -d "${bmd}/X11/bitmaps"; then
10004 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
10005 fi
10006 if test -d "${bmd}/bitmaps"; then
10007 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
10008 fi
10009 done
10010 if test ${bmd_acc} != "dummyval"; then
10011 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
10012 fi
10013 fi
10014
10015 HAVE_NS=no
10016 NS_IMPL_COCOA=no
10017 NS_IMPL_GNUSTEP=no
10018 tmp_CPPFLAGS="$CPPFLAGS"
10019 tmp_CFLAGS="$CFLAGS"
10020 CPPFLAGS="$CPPFLAGS -x objective-c"
10021 CFLAGS="$CFLAGS -x objective-c"
10022 GNU_OBJC_CFLAGS=
10023 LIBS_GNUSTEP=
10024 if test "${with_ns}" != no; then
10025 if test "${opsys}" = darwin; then
10026 NS_IMPL_COCOA=yes
10027 ns_appdir=`pwd`/nextstep/Emacs.app
10028 ns_appbindir=${ns_appdir}/Contents/MacOS
10029 ns_appresdir=${ns_appdir}/Contents/Resources
10030 ns_appsrc=Cocoa/Emacs.base
10031 elif test -f $GNUSTEP_CONFIG_FILE; then
10032 NS_IMPL_GNUSTEP=yes
10033 ns_appdir=`pwd`/nextstep/Emacs.app
10034 ns_appbindir=${ns_appdir}
10035 ns_appresdir=${ns_appdir}/Resources
10036 ns_appsrc=GNUstep/Emacs.base
10037 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
10038 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
10039 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
10040 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
10041 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
10042 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
10043 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
10044 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
10045 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10046 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
10047 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
10048 LIBS_GNUSTEP="-lgnustep-gui -lgnustep-base -lobjc -lpthread"
10049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
10050 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
10051 if test "${emacs_cv_objc_exceptions+set}" = set; then :
10052 $as_echo_n "(cached) " >&6
10053 else
10054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10055 /* end confdefs.h. */
10056 #include <GNUstepBase/GSConfig.h>
10057 int
10058 main ()
10059 {
10060 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
10061 1;
10062 #else
10063 fail;
10064 #endif
10065 ;
10066 return 0;
10067 }
10068 _ACEOF
10069 if ac_fn_c_try_compile "$LINENO"; then :
10070 emacs_cv_objc_exceptions=yes
10071 else
10072 emacs_cv_objc_exceptions=no
10073 fi
10074 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10075 fi
10076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
10077 $as_echo "$emacs_cv_objc_exceptions" >&6; }
10078 if test $emacs_cv_objc_exceptions = yes; then
10079
10080 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
10081
10082 GNU_OBJC_CFLAGS="-fobjc-exceptions"
10083 fi
10084 fi
10085
10086 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
10087
10088 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
10089 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
10090 HAVE_NS=yes
10091 else
10092 as_fn_error "\`--with-ns' was specified, but the include
10093 files are missing or cannot be compiled." "$LINENO" 5
10094 fi
10095
10096
10097
10098 macfont_file=""
10099 if test "${NS_IMPL_COCOA}" = "yes"; then
10100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.4 or newer" >&5
10101 $as_echo_n "checking for OSX 10.4 or newer... " >&6; }
10102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10103 /* end confdefs.h. */
10104 #include <AppKit/AppKit.h>
10105 int
10106 main ()
10107 {
10108
10109 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10110 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
10111 ; /* OK */
10112 #else
10113 #error "OSX 10.4 or newer required"
10114 #endif
10115 #endif
10116
10117 ;
10118 return 0;
10119 }
10120 _ACEOF
10121 if ac_fn_c_try_compile "$LINENO"; then :
10122 ns_osx_have_104=yes
10123 else
10124 ns_osx_have_104=no
10125 fi
10126 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_104" >&5
10128 $as_echo "$ns_osx_have_104" >&6; }
10129
10130 if test $ns_osx_have_104 = no; then
10131 as_fn_error "\`OSX 10.4 or newer is required'" "$LINENO" 5;
10132 fi
10133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OSX 10.5 or newer" >&5
10134 $as_echo_n "checking for OSX 10.5 or newer... " >&6; }
10135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10136 /* end confdefs.h. */
10137 #include <AppKit/AppKit.h>
10138 int
10139 main ()
10140 {
10141
10142 #ifdef MAC_OS_X_VERSION_MAX_ALLOWED
10143 #if MAC_OS_X_VERSION_MAX_ALLOWED >= 1050
10144 ; /* OK */
10145 #else
10146 #error "OSX 10.5 not found"
10147 #endif
10148 #endif
10149
10150 ;
10151 return 0;
10152 }
10153 _ACEOF
10154 if ac_fn_c_try_compile "$LINENO"; then :
10155 ns_osx_have_105=yes
10156 else
10157 ns_osx_have_105=no
10158 fi
10159 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ns_osx_have_105" >&5
10161 $as_echo "$ns_osx_have_105" >&6; }
10162 if test $ns_osx_have_105 = yes; then
10163 macfont_file="macfont.o"
10164 fi
10165 fi
10166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10167 /* end confdefs.h. */
10168 #include <Foundation/NSObjCRuntime.h>
10169 int
10170 main ()
10171 {
10172 NSInteger i;
10173 ;
10174 return 0;
10175 }
10176 _ACEOF
10177 if ac_fn_c_try_compile "$LINENO"; then :
10178 ns_have_nsinteger=yes
10179 else
10180 ns_have_nsinteger=no
10181 fi
10182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10183 if test $ns_have_nsinteger = yes; then
10184
10185 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
10186
10187 fi
10188 fi
10189
10190
10191
10192 INSTALL_ARCH_INDEP_EXTRA=install-etc
10193 ns_self_contained=no
10194 NS_OBJ=
10195 NS_OBJC_OBJ=
10196 if test "${HAVE_NS}" = yes; then
10197 if test "$with_toolkit_scroll_bars" = "no"; then
10198 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
10199 fi
10200
10201 window_system=nextstep
10202 # set up packaging dirs
10203 if test "${EN_NS_SELF_CONTAINED}" = yes; then
10204 ns_self_contained=yes
10205 prefix=${ns_appresdir}
10206 exec_prefix=${ns_appbindir}
10207 libexecdir="\${ns_appbindir}/libexec"
10208 archlibdir="\${ns_appbindir}/libexec"
10209 etcdocdir="\${ns_appresdir}/etc"
10210 etcdir="\${ns_appresdir}/etc"
10211 infodir="\${ns_appresdir}/info"
10212 mandir="\${ns_appresdir}/man"
10213 lispdir="\${ns_appresdir}/lisp"
10214 leimdir="\${ns_appresdir}/leim"
10215 INSTALL_ARCH_INDEP_EXTRA=
10216 fi
10217
10218 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o $macfont_file"
10219 fi
10220 CFLAGS="$tmp_CFLAGS"
10221 CPPFLAGS="$tmp_CPPFLAGS"
10222
10223
10224
10225
10226
10227 HAVE_W32=no
10228 W32_OBJ=
10229 W32_LIBS=
10230 EMACSRES=
10231 CLIENTRES=
10232 CLIENTW=
10233 W32_RES_LINK=
10234 EMACS_MANIFEST=
10235 UPDATE_MANIFEST=
10236 if test "${with_w32}" != no; then
10237 case "${opsys}" in
10238 cygwin)
10239 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
10240 if test "x$ac_cv_header_windows_h" = x""yes; then :
10241 HAVE_W32=yes
10242 else
10243 as_fn_error "\`--with-w32' was specified, but windows.h
10244 cannot be found." "$LINENO" 5
10245 fi
10246
10247
10248 ;;
10249 mingw32)
10250 ## Using --with-w32 with MinGW is a no-op, but we allow it.
10251 ;;
10252 *)
10253 as_fn_error "Using w32 with an autotools build is only supported for Cygwin and MinGW32." "$LINENO" 5
10254 ;;
10255 esac
10256 fi
10257
10258 if test "${opsys}" = "mingw32"; then
10259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether Windows API headers are recent enough" >&5
10260 $as_echo_n "checking whether Windows API headers are recent enough... " >&6; }
10261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10262 /* end confdefs.h. */
10263
10264 #include <windows.h>
10265 #include <usp10.h>
10266 int
10267 main ()
10268 {
10269 PIMAGE_NT_HEADERS pHeader;
10270 PIMAGE_SECTION_HEADER pSection = IMAGE_FIRST_SECTION(pHeader)
10271 ;
10272 return 0;
10273 }
10274 _ACEOF
10275 if ac_fn_c_try_compile "$LINENO"; then :
10276 emacs_cv_w32api=yes
10277 HAVE_W32=yes
10278 else
10279 emacs_cv_w32api=no
10280 fi
10281 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_w32api" >&5
10283 $as_echo "$emacs_cv_w32api" >&6; }
10284 if test "${emacs_cv_w32api}" = "no"; then
10285 as_fn_error "the Windows API headers are too old to support this build." "$LINENO" 5
10286 fi
10287 fi
10288
10289 FIRSTFILE_OBJ=
10290 NTDIR=
10291 LIBS_ECLIENT=
10292 LIB_WSOCK32=
10293 NTLIB=
10294 CM_OBJ="cm.o"
10295 XARGS_LIMIT=
10296 if test "${HAVE_W32}" = "yes"; then
10297
10298 $as_echo "#define HAVE_NTGUI 1" >>confdefs.h
10299
10300 if test -n "$ac_tool_prefix"; then
10301 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
10302 set dummy ${ac_tool_prefix}windres; ac_word=$2
10303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10304 $as_echo_n "checking for $ac_word... " >&6; }
10305 if test "${ac_cv_prog_WINDRES+set}" = set; then :
10306 $as_echo_n "(cached) " >&6
10307 else
10308 if test -n "$WINDRES"; then
10309 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
10310 else
10311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10312 for as_dir in $PATH
10313 do
10314 IFS=$as_save_IFS
10315 test -z "$as_dir" && as_dir=.
10316 for ac_exec_ext in '' $ac_executable_extensions; do
10317 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10318 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
10319 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10320 break 2
10321 fi
10322 done
10323 done
10324 IFS=$as_save_IFS
10325
10326 fi
10327 fi
10328 WINDRES=$ac_cv_prog_WINDRES
10329 if test -n "$WINDRES"; then
10330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
10331 $as_echo "$WINDRES" >&6; }
10332 else
10333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10334 $as_echo "no" >&6; }
10335 fi
10336
10337
10338 fi
10339 if test -z "$ac_cv_prog_WINDRES"; then
10340 ac_ct_WINDRES=$WINDRES
10341 # Extract the first word of "windres", so it can be a program name with args.
10342 set dummy windres; ac_word=$2
10343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10344 $as_echo_n "checking for $ac_word... " >&6; }
10345 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then :
10346 $as_echo_n "(cached) " >&6
10347 else
10348 if test -n "$ac_ct_WINDRES"; then
10349 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
10350 else
10351 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10352 for as_dir in $PATH
10353 do
10354 IFS=$as_save_IFS
10355 test -z "$as_dir" && as_dir=.
10356 for ac_exec_ext in '' $ac_executable_extensions; do
10357 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10358 ac_cv_prog_ac_ct_WINDRES="windres"
10359 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10360 break 2
10361 fi
10362 done
10363 done
10364 IFS=$as_save_IFS
10365
10366 fi
10367 fi
10368 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
10369 if test -n "$ac_ct_WINDRES"; then
10370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
10371 $as_echo "$ac_ct_WINDRES" >&6; }
10372 else
10373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10374 $as_echo "no" >&6; }
10375 fi
10376
10377 if test "x$ac_ct_WINDRES" = x; then
10378 WINDRES="as_fn_error "No resource compiler found." "$LINENO" 5"
10379 else
10380 case $cross_compiling:$ac_tool_warned in
10381 yes:)
10382 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10383 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10384 ac_tool_warned=yes ;;
10385 esac
10386 WINDRES=$ac_ct_WINDRES
10387 fi
10388 else
10389 WINDRES="$ac_cv_prog_WINDRES"
10390 fi
10391
10392 W32_OBJ="w32fns.o w32menu.o w32reg.o w32font.o w32term.o"
10393 W32_OBJ="$W32_OBJ w32xfns.o w32select.o w32uniscribe.o"
10394 EMACSRES="emacs.res"
10395 case "$canonical" in
10396 x86_64-*-*) EMACS_MANIFEST="emacs-x64.manifest" ;;
10397 *) EMACS_MANIFEST="emacs-x86.manifest" ;;
10398 esac
10399 UPDATE_MANIFEST=update-game-score.exe.manifest
10400 if test "${opsys}" = "cygwin"; then
10401 W32_LIBS="$W32_LIBS -lkernel32 -luser32 -lgdi32 -lole32 -lcomdlg32"
10402 W32_LIBS="$W32_LIBS -lusp10 -lcomctl32 -lwinspool"
10403 # Tell the linker that emacs.res is an object (which we compile from
10404 # the rc file), not a linker script.
10405 W32_RES_LINK="-Wl,emacs.res"
10406 else
10407 W32_OBJ="$W32_OBJ w32.o w32console.o w32heap.o w32inevt.o w32proc.o"
10408 W32_LIBS="$W32_LIBS -lwinmm -lgdi32 -lcomdlg32"
10409 W32_LIBS="$W32_LIBS -lmpr -lwinspool -lole32 -lcomctl32 -lusp10"
10410 W32_RES_LINK="\$(EMACSRES)"
10411 CLIENTRES="emacsclient.res"
10412 CLIENTW="emacsclientw\$(EXEEXT)"
10413 FIRSTFILE_OBJ=firstfile.o
10414 NTDIR=nt
10415 CM_OBJ=
10416 LIBS_ECLIENT="-lcomctl32"
10417 LIB_WSOCK32="-lwsock32"
10418 NTLIB="ntlib.$ac_objext"
10419 XARGS_LIMIT="-s 10000"
10420 fi
10421 fi
10422
10423
10424
10425
10426
10427
10428
10429
10430
10431
10432
10433
10434
10435
10436
10437
10438 if test "${HAVE_W32}" = "yes"; then
10439 window_system=w32
10440 with_xft=no
10441 fi
10442
10443 ## $window_system is now set to the window system we will
10444 ## ultimately use.
10445
10446 if test "$window_system" = none && test "$gl_gcc_warnings" = yes; then
10447 # Too many warnings for now.
10448 nw=
10449 nw="$nw -Wsuggest-attribute=const"
10450 nw="$nw -Wsuggest-attribute=noreturn"
10451
10452 gl_warn_set=
10453 set x $WARN_CFLAGS; shift
10454 for gl_warn_item
10455 do
10456 case " $nw " in
10457 *" $gl_warn_item "*)
10458 ;;
10459 *)
10460 gl_warn_set="$gl_warn_set $gl_warn_item"
10461 ;;
10462 esac
10463 done
10464 WARN_CFLAGS=$gl_warn_set
10465
10466
10467
10468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-variable" >&5
10469 $as_echo_n "checking whether C compiler handles -Wno-unused-variable... " >&6; }
10470 if test "${gl_cv_warn_c__Wno_unused_variable+set}" = set; then :
10471 $as_echo_n "(cached) " >&6
10472 else
10473
10474 gl_save_compiler_FLAGS="$CFLAGS"
10475 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-variable"
10476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10477 /* end confdefs.h. */
10478
10479 int
10480 main ()
10481 {
10482
10483 ;
10484 return 0;
10485 }
10486 _ACEOF
10487 if ac_fn_c_try_link "$LINENO"; then :
10488 gl_cv_warn_c__Wno_unused_variable=yes
10489 else
10490 gl_cv_warn_c__Wno_unused_variable=no
10491 fi
10492 rm -f core conftest.err conftest.$ac_objext \
10493 conftest$ac_exeext conftest.$ac_ext
10494 CFLAGS="$gl_save_compiler_FLAGS"
10495
10496 fi
10497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_variable" >&5
10498 $as_echo "$gl_cv_warn_c__Wno_unused_variable" >&6; }
10499 if test "x$gl_cv_warn_c__Wno_unused_variable" = x""yes; then :
10500 as_fn_append WARN_CFLAGS " -Wno-unused-variable"
10501 fi
10502
10503
10504
10505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-variable" >&5
10506 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-variable... " >&6; }
10507 if test "${gl_cv_warn_c__Wno_unused_but_set_variable+set}" = set; then :
10508 $as_echo_n "(cached) " >&6
10509 else
10510
10511 gl_save_compiler_FLAGS="$CFLAGS"
10512 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-variable"
10513 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10514 /* end confdefs.h. */
10515
10516 int
10517 main ()
10518 {
10519
10520 ;
10521 return 0;
10522 }
10523 _ACEOF
10524 if ac_fn_c_try_link "$LINENO"; then :
10525 gl_cv_warn_c__Wno_unused_but_set_variable=yes
10526 else
10527 gl_cv_warn_c__Wno_unused_but_set_variable=no
10528 fi
10529 rm -f core conftest.err conftest.$ac_objext \
10530 conftest$ac_exeext conftest.$ac_ext
10531 CFLAGS="$gl_save_compiler_FLAGS"
10532
10533 fi
10534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_variable" >&5
10535 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_variable" >&6; }
10536 if test "x$gl_cv_warn_c__Wno_unused_but_set_variable" = x""yes; then :
10537 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-variable"
10538 fi
10539
10540
10541
10542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-but-set-parameter" >&5
10543 $as_echo_n "checking whether C compiler handles -Wno-unused-but-set-parameter... " >&6; }
10544 if test "${gl_cv_warn_c__Wno_unused_but_set_parameter+set}" = set; then :
10545 $as_echo_n "(cached) " >&6
10546 else
10547
10548 gl_save_compiler_FLAGS="$CFLAGS"
10549 as_fn_append CFLAGS " $gl_unknown_warnings_are_errors -Wunused-but-set-parameter"
10550 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10551 /* end confdefs.h. */
10552
10553 int
10554 main ()
10555 {
10556
10557 ;
10558 return 0;
10559 }
10560 _ACEOF
10561 if ac_fn_c_try_link "$LINENO"; then :
10562 gl_cv_warn_c__Wno_unused_but_set_parameter=yes
10563 else
10564 gl_cv_warn_c__Wno_unused_but_set_parameter=no
10565 fi
10566 rm -f core conftest.err conftest.$ac_objext \
10567 conftest$ac_exeext conftest.$ac_ext
10568 CFLAGS="$gl_save_compiler_FLAGS"
10569
10570 fi
10571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_but_set_parameter" >&5
10572 $as_echo "$gl_cv_warn_c__Wno_unused_but_set_parameter" >&6; }
10573 if test "x$gl_cv_warn_c__Wno_unused_but_set_parameter" = x""yes; then :
10574 as_fn_append WARN_CFLAGS " -Wno-unused-but-set-parameter"
10575 fi
10576
10577
10578 fi
10579
10580 term_header=
10581 HAVE_X_WINDOWS=no
10582 HAVE_X11=no
10583 USE_X_TOOLKIT=none
10584
10585 case "${window_system}" in
10586 x11 )
10587 HAVE_X_WINDOWS=yes
10588 HAVE_X11=yes
10589 term_header=xterm.h
10590 case "${with_x_toolkit}" in
10591 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
10592 motif ) USE_X_TOOLKIT=MOTIF ;;
10593 gtk ) with_gtk=yes
10594 term_header=gtkutil.h
10595 USE_X_TOOLKIT=none ;;
10596 gtk2 ) with_gtk2=yes
10597 term_header=gtkutil.h
10598 USE_X_TOOLKIT=none ;;
10599 gtk3 ) with_gtk3=yes
10600 term_header=gtkutil.h
10601 USE_X_TOOLKIT=none ;;
10602 no ) USE_X_TOOLKIT=none ;;
10603 * ) USE_X_TOOLKIT=maybe ;;
10604 esac
10605 ;;
10606 nextstep )
10607 term_header=nsterm.h
10608 ;;
10609 w32 )
10610 term_header=w32term.h
10611 ;;
10612 esac
10613
10614 if test "$window_system" = none && test "X$with_x" != "Xno"; then
10615 # Extract the first word of "X", so it can be a program name with args.
10616 set dummy X; ac_word=$2
10617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10618 $as_echo_n "checking for $ac_word... " >&6; }
10619 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
10620 $as_echo_n "(cached) " >&6
10621 else
10622 if test -n "$HAVE_XSERVER"; then
10623 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
10624 else
10625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10626 for as_dir in $PATH
10627 do
10628 IFS=$as_save_IFS
10629 test -z "$as_dir" && as_dir=.
10630 for ac_exec_ext in '' $ac_executable_extensions; do
10631 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10632 ac_cv_prog_HAVE_XSERVER="true"
10633 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10634 break 2
10635 fi
10636 done
10637 done
10638 IFS=$as_save_IFS
10639
10640 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
10641 fi
10642 fi
10643 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
10644 if test -n "$HAVE_XSERVER"; then
10645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
10646 $as_echo "$HAVE_XSERVER" >&6; }
10647 else
10648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10649 $as_echo "no" >&6; }
10650 fi
10651
10652
10653 if test "$HAVE_XSERVER" = true ||
10654 test -n "$DISPLAY" ||
10655 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
10656 as_fn_error "You seem to be running X, but no X development libraries
10657 were found. You should install the relevant development files for X
10658 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
10659 sure you have development files for image handling, i.e.
10660 tiff, gif, jpeg, png and xpm.
10661 If you are sure you want Emacs compiled without X window support, pass
10662 --without-x
10663 to configure." "$LINENO" 5
10664 fi
10665 fi
10666
10667 ### We always support menus.
10668 HAVE_MENUS=yes
10669
10670 # Does the opsystem file prohibit the use of the GNU malloc?
10671 # Assume not, until told otherwise.
10672 GNU_MALLOC=yes
10673
10674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
10675 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
10676 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
10677 $as_echo_n "(cached) " >&6
10678 else
10679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10680 /* end confdefs.h. */
10681 #include <malloc.h>
10682 static void hook (void) {}
10683 int
10684 main ()
10685 {
10686 malloc_set_state (malloc_get_state ());
10687 __after_morecore_hook = hook;
10688 __malloc_initialize_hook = hook;
10689 ;
10690 return 0;
10691 }
10692 _ACEOF
10693 if ac_fn_c_try_link "$LINENO"; then :
10694 emacs_cv_var_doug_lea_malloc=yes
10695 else
10696 emacs_cv_var_doug_lea_malloc=no
10697 fi
10698 rm -f core conftest.err conftest.$ac_objext \
10699 conftest$ac_exeext conftest.$ac_ext
10700 fi
10701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
10702 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
10703 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
10704
10705
10706 system_malloc=no
10707 case "$opsys" in
10708 ## darwin ld insists on the use of malloc routines in the System framework.
10709 darwin|sol2-10) system_malloc=yes ;;
10710 esac
10711
10712 if test "${system_malloc}" = "yes"; then
10713
10714 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
10715
10716 GNU_MALLOC=no
10717 GNU_MALLOC_reason="
10718 (The GNU allocators don't work with this system configuration.)"
10719 GMALLOC_OBJ=
10720 VMLIMIT_OBJ=
10721 else
10722 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10723 VMLIMIT_OBJ=vm-limit.o
10724
10725 for ac_header in sys/vlimit.h
10726 do :
10727 ac_fn_c_check_header_mongrel "$LINENO" "sys/vlimit.h" "ac_cv_header_sys_vlimit_h" "$ac_includes_default"
10728 if test "x$ac_cv_header_sys_vlimit_h" = x""yes; then :
10729 cat >>confdefs.h <<_ACEOF
10730 #define HAVE_SYS_VLIMIT_H 1
10731 _ACEOF
10732
10733 fi
10734
10735 done
10736
10737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for data_start" >&5
10738 $as_echo_n "checking for data_start... " >&6; }
10739 if test "${emacs_cv_data_start+set}" = set; then :
10740 $as_echo_n "(cached) " >&6
10741 else
10742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10743 /* end confdefs.h. */
10744 extern char data_start[]; char ch;
10745 int
10746 main ()
10747 {
10748 return data_start < &ch;
10749 ;
10750 return 0;
10751 }
10752 _ACEOF
10753 if ac_fn_c_try_link "$LINENO"; then :
10754 emacs_cv_data_start=yes
10755 else
10756 emacs_cv_data_start=no
10757 fi
10758 rm -f core conftest.err conftest.$ac_objext \
10759 conftest$ac_exeext conftest.$ac_ext
10760 fi
10761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_data_start" >&5
10762 $as_echo "$emacs_cv_data_start" >&6; }
10763 if test $emacs_cv_data_start = yes; then
10764
10765 $as_echo "#define HAVE_DATA_START 1" >>confdefs.h
10766
10767 fi
10768 fi
10769
10770
10771
10772 if test "$doug_lea_malloc" = "yes" ; then
10773 if test "$GNU_MALLOC" = yes ; then
10774 GNU_MALLOC_reason="
10775 (Using Doug Lea's new malloc from the GNU C Library.)"
10776 fi
10777
10778 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10779
10780
10781 ## Use mmap directly for allocating larger buffers.
10782 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10783 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10784 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10785 case "$opsys" in
10786 gnu*) REL_ALLOC=no ;;
10787 esac
10788 fi
10789
10790 if test x"${REL_ALLOC}" = x; then
10791 REL_ALLOC=${GNU_MALLOC}
10792 fi
10793
10794 use_mmap_for_buffers=no
10795 case "$opsys" in
10796 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10797 esac
10798
10799
10800
10801
10802
10803
10804
10805
10806 for ac_func in getpagesize
10807 do :
10808 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10809 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10810 cat >>confdefs.h <<_ACEOF
10811 #define HAVE_GETPAGESIZE 1
10812 _ACEOF
10813
10814 fi
10815 done
10816
10817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10818 $as_echo_n "checking for working mmap... " >&6; }
10819 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10820 $as_echo_n "(cached) " >&6
10821 else
10822 if test "$cross_compiling" = yes; then :
10823 ac_cv_func_mmap_fixed_mapped=no
10824 else
10825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10826 /* end confdefs.h. */
10827 $ac_includes_default
10828 /* malloc might have been renamed as rpl_malloc. */
10829 #undef malloc
10830
10831 /* Thanks to Mike Haertel and Jim Avera for this test.
10832 Here is a matrix of mmap possibilities:
10833 mmap private not fixed
10834 mmap private fixed at somewhere currently unmapped
10835 mmap private fixed at somewhere already mapped
10836 mmap shared not fixed
10837 mmap shared fixed at somewhere currently unmapped
10838 mmap shared fixed at somewhere already mapped
10839 For private mappings, we should verify that changes cannot be read()
10840 back from the file, nor mmap's back from the file at a different
10841 address. (There have been systems where private was not correctly
10842 implemented like the infamous i386 svr4.0, and systems where the
10843 VM page cache was not coherent with the file system buffer cache
10844 like early versions of FreeBSD and possibly contemporary NetBSD.)
10845 For shared mappings, we should conversely verify that changes get
10846 propagated back to all the places they're supposed to be.
10847
10848 Grep wants private fixed already mapped.
10849 The main things grep needs to know about mmap are:
10850 * does it exist and is it safe to write into the mmap'd area
10851 * how to use it (BSD variants) */
10852
10853 #include <fcntl.h>
10854 #include <sys/mman.h>
10855
10856 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10857 char *malloc ();
10858 #endif
10859
10860 /* This mess was copied from the GNU getpagesize.h. */
10861 #ifndef HAVE_GETPAGESIZE
10862 # ifdef _SC_PAGESIZE
10863 # define getpagesize() sysconf(_SC_PAGESIZE)
10864 # else /* no _SC_PAGESIZE */
10865 # ifdef HAVE_SYS_PARAM_H
10866 # include <sys/param.h>
10867 # ifdef EXEC_PAGESIZE
10868 # define getpagesize() EXEC_PAGESIZE
10869 # else /* no EXEC_PAGESIZE */
10870 # ifdef NBPG
10871 # define getpagesize() NBPG * CLSIZE
10872 # ifndef CLSIZE
10873 # define CLSIZE 1
10874 # endif /* no CLSIZE */
10875 # else /* no NBPG */
10876 # ifdef NBPC
10877 # define getpagesize() NBPC
10878 # else /* no NBPC */
10879 # ifdef PAGESIZE
10880 # define getpagesize() PAGESIZE
10881 # endif /* PAGESIZE */
10882 # endif /* no NBPC */
10883 # endif /* no NBPG */
10884 # endif /* no EXEC_PAGESIZE */
10885 # else /* no HAVE_SYS_PARAM_H */
10886 # define getpagesize() 8192 /* punt totally */
10887 # endif /* no HAVE_SYS_PARAM_H */
10888 # endif /* no _SC_PAGESIZE */
10889
10890 #endif /* no HAVE_GETPAGESIZE */
10891
10892 int
10893 main ()
10894 {
10895 char *data, *data2, *data3;
10896 const char *cdata2;
10897 int i, pagesize;
10898 int fd, fd2;
10899
10900 pagesize = getpagesize ();
10901
10902 /* First, make a file with some known garbage in it. */
10903 data = (char *) malloc (pagesize);
10904 if (!data)
10905 return 1;
10906 for (i = 0; i < pagesize; ++i)
10907 *(data + i) = rand ();
10908 umask (0);
10909 fd = creat ("conftest.mmap", 0600);
10910 if (fd < 0)
10911 return 2;
10912 if (write (fd, data, pagesize) != pagesize)
10913 return 3;
10914 close (fd);
10915
10916 /* Next, check that the tail of a page is zero-filled. File must have
10917 non-zero length, otherwise we risk SIGBUS for entire page. */
10918 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10919 if (fd2 < 0)
10920 return 4;
10921 cdata2 = "";
10922 if (write (fd2, cdata2, 1) != 1)
10923 return 5;
10924 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10925 if (data2 == MAP_FAILED)
10926 return 6;
10927 for (i = 0; i < pagesize; ++i)
10928 if (*(data2 + i))
10929 return 7;
10930 close (fd2);
10931 if (munmap (data2, pagesize))
10932 return 8;
10933
10934 /* Next, try to mmap the file at a fixed address which already has
10935 something else allocated at it. If we can, also make sure that
10936 we see the same garbage. */
10937 fd = open ("conftest.mmap", O_RDWR);
10938 if (fd < 0)
10939 return 9;
10940 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10941 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10942 return 10;
10943 for (i = 0; i < pagesize; ++i)
10944 if (*(data + i) != *(data2 + i))
10945 return 11;
10946
10947 /* Finally, make sure that changes to the mapped area do not
10948 percolate back to the file as seen by read(). (This is a bug on
10949 some variants of i386 svr4.0.) */
10950 for (i = 0; i < pagesize; ++i)
10951 *(data2 + i) = *(data2 + i) + 1;
10952 data3 = (char *) malloc (pagesize);
10953 if (!data3)
10954 return 12;
10955 if (read (fd, data3, pagesize) != pagesize)
10956 return 13;
10957 for (i = 0; i < pagesize; ++i)
10958 if (*(data + i) != *(data3 + i))
10959 return 14;
10960 close (fd);
10961 return 0;
10962 }
10963 _ACEOF
10964 if ac_fn_c_try_run "$LINENO"; then :
10965 ac_cv_func_mmap_fixed_mapped=yes
10966 else
10967 ac_cv_func_mmap_fixed_mapped=no
10968 fi
10969 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10970 conftest.$ac_objext conftest.beam conftest.$ac_ext
10971 fi
10972
10973 fi
10974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10975 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10976 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10977
10978 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10979
10980 fi
10981 rm -f conftest.mmap conftest.txt
10982
10983 if test $use_mmap_for_buffers = yes; then
10984
10985 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10986
10987 REL_ALLOC=no
10988 fi
10989
10990 LIBS="$LIBS_SYSTEM $LIBS"
10991
10992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10993 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10994 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10995 $as_echo_n "(cached) " >&6
10996 else
10997 ac_check_lib_save_LIBS=$LIBS
10998 LIBS="-ldnet $LIBS"
10999 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11000 /* end confdefs.h. */
11001
11002 /* Override any GCC internal prototype to avoid an error.
11003 Use char because int might match the return type of a GCC
11004 builtin and then its argument prototype would still apply. */
11005 #ifdef __cplusplus
11006 extern "C"
11007 #endif
11008 char dnet_ntoa ();
11009 int
11010 main ()
11011 {
11012 return dnet_ntoa ();
11013 ;
11014 return 0;
11015 }
11016 _ACEOF
11017 if ac_fn_c_try_link "$LINENO"; then :
11018 ac_cv_lib_dnet_dnet_ntoa=yes
11019 else
11020 ac_cv_lib_dnet_dnet_ntoa=no
11021 fi
11022 rm -f core conftest.err conftest.$ac_objext \
11023 conftest$ac_exeext conftest.$ac_ext
11024 LIBS=$ac_check_lib_save_LIBS
11025 fi
11026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
11027 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
11028 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
11029 cat >>confdefs.h <<_ACEOF
11030 #define HAVE_LIBDNET 1
11031 _ACEOF
11032
11033 LIBS="-ldnet $LIBS"
11034
11035 fi
11036
11037
11038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
11039 $as_echo_n "checking for main in -lXbsd... " >&6; }
11040 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
11041 $as_echo_n "(cached) " >&6
11042 else
11043 ac_check_lib_save_LIBS=$LIBS
11044 LIBS="-lXbsd $LIBS"
11045 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11046 /* end confdefs.h. */
11047
11048
11049 int
11050 main ()
11051 {
11052 return main ();
11053 ;
11054 return 0;
11055 }
11056 _ACEOF
11057 if ac_fn_c_try_link "$LINENO"; then :
11058 ac_cv_lib_Xbsd_main=yes
11059 else
11060 ac_cv_lib_Xbsd_main=no
11061 fi
11062 rm -f core conftest.err conftest.$ac_objext \
11063 conftest$ac_exeext conftest.$ac_ext
11064 LIBS=$ac_check_lib_save_LIBS
11065 fi
11066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
11067 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
11068 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
11069 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
11070 fi
11071
11072
11073 LIB_PTHREAD=
11074
11075
11076
11077 if test "$ac_cv_header_pthread_h"; then
11078 if test "$GMALLOC_OBJ" = gmalloc.o; then
11079 emacs_pthread_function=pthread_atfork
11080 else
11081 emacs_pthread_function=pthread_self
11082 fi
11083 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
11084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
11085 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
11086 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
11087 $as_echo_n "(cached) " >&6
11088 else
11089 ac_check_lib_save_LIBS=$LIBS
11090 LIBS="-lpthread $LIBS"
11091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11092 /* end confdefs.h. */
11093
11094 /* Override any GCC internal prototype to avoid an error.
11095 Use char because int might match the return type of a GCC
11096 builtin and then its argument prototype would still apply. */
11097 #ifdef __cplusplus
11098 extern "C"
11099 #endif
11100 char $emacs_pthread_function ();
11101 int
11102 main ()
11103 {
11104 return $emacs_pthread_function ();
11105 ;
11106 return 0;
11107 }
11108 _ACEOF
11109 if ac_fn_c_try_link "$LINENO"; then :
11110 eval "$as_ac_Lib=yes"
11111 else
11112 eval "$as_ac_Lib=no"
11113 fi
11114 rm -f core conftest.err conftest.$ac_objext \
11115 conftest$ac_exeext conftest.$ac_ext
11116 LIBS=$ac_check_lib_save_LIBS
11117 fi
11118 eval ac_res=\$$as_ac_Lib
11119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
11120 $as_echo "$ac_res" >&6; }
11121 eval as_val=\$$as_ac_Lib
11122 if test "x$as_val" = x""yes; then :
11123 HAVE_PTHREAD=yes
11124 fi
11125
11126 fi
11127 if test "$HAVE_PTHREAD" = yes; then
11128 case "${canonical}" in
11129 *-hpux*) ;;
11130 *) LIB_PTHREAD="-lpthread"
11131 LIBS="$LIB_PTHREAD $LIBS" ;;
11132 esac
11133
11134 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
11135
11136 fi
11137
11138
11139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
11140 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
11141 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
11142 $as_echo_n "(cached) " >&6
11143 else
11144 ac_check_lib_save_LIBS=$LIBS
11145 LIBS="-lpthreads $LIBS"
11146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11147 /* end confdefs.h. */
11148
11149 /* Override any GCC internal prototype to avoid an error.
11150 Use char because int might match the return type of a GCC
11151 builtin and then its argument prototype would still apply. */
11152 #ifdef __cplusplus
11153 extern "C"
11154 #endif
11155 char cma_open ();
11156 int
11157 main ()
11158 {
11159 return cma_open ();
11160 ;
11161 return 0;
11162 }
11163 _ACEOF
11164 if ac_fn_c_try_link "$LINENO"; then :
11165 ac_cv_lib_pthreads_cma_open=yes
11166 else
11167 ac_cv_lib_pthreads_cma_open=no
11168 fi
11169 rm -f core conftest.err conftest.$ac_objext \
11170 conftest$ac_exeext conftest.$ac_ext
11171 LIBS=$ac_check_lib_save_LIBS
11172 fi
11173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
11174 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
11175 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
11176 cat >>confdefs.h <<_ACEOF
11177 #define HAVE_LIBPTHREADS 1
11178 _ACEOF
11179
11180 LIBS="-lpthreads $LIBS"
11181
11182 fi
11183
11184
11185 ## Note: when using cpp in s/aix4.2.h, this definition depended on
11186 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
11187 ## the system file was sourced. Hence the value of LIBS_SYSTEM
11188 ## added to LIBS in configure would never contain the pthreads part,
11189 ## but the value used in Makefiles might. FIXME?
11190 ##
11191 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
11192 ## be harmless on older versions of X where it happens to exist.
11193 test "$opsys" = "aix4-2" && \
11194 test $ac_cv_lib_pthreads_cma_open = yes && \
11195 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
11196
11197
11198 case ${host_os} in
11199 aix*)
11200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
11201 $as_echo_n "checking for -bbigtoc option... " >&6; }
11202 if test "${gdb_cv_bigtoc+set}" = set; then :
11203 $as_echo_n "(cached) " >&6
11204 else
11205
11206 case $GCC in
11207 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
11208 *) gdb_cv_bigtoc=-bbigtoc ;;
11209 esac
11210
11211 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
11212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11213 /* end confdefs.h. */
11214
11215 int
11216 main ()
11217 {
11218 int i;
11219 ;
11220 return 0;
11221 }
11222 _ACEOF
11223 if ac_fn_c_try_link "$LINENO"; then :
11224
11225 else
11226 gdb_cv_bigtoc=
11227 fi
11228 rm -f core conftest.err conftest.$ac_objext \
11229 conftest$ac_exeext conftest.$ac_ext
11230
11231 fi
11232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
11233 $as_echo "$gdb_cv_bigtoc" >&6; }
11234 ;;
11235 esac
11236
11237 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
11238 # used for the tests that follow. We set them back to REAL_CFLAGS and
11239 # REAL_CPPFLAGS later on.
11240
11241 REAL_CFLAGS="$CFLAGS"
11242 REAL_CPPFLAGS="$CPPFLAGS"
11243
11244 if test "${HAVE_X11}" = "yes"; then
11245 DEFS="$C_SWITCH_X_SITE $DEFS"
11246 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
11247 LIBS="-lX11 $LIBS"
11248 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
11249 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
11250
11251 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
11252 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
11253 # but it's more convenient here to set LD_RUN_PATH since this
11254 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
11255 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
11256 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
11257 export LD_RUN_PATH
11258 fi
11259
11260 if test "${opsys}" = "gnu-linux"; then
11261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
11262 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
11263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11264 /* end confdefs.h. */
11265
11266 int
11267 main ()
11268 {
11269 XOpenDisplay ("foo");
11270 ;
11271 return 0;
11272 }
11273 _ACEOF
11274 if ac_fn_c_try_link "$LINENO"; then :
11275 xgnu_linux_first_failure=no
11276 else
11277 xgnu_linux_first_failure=yes
11278 fi
11279 rm -f core conftest.err conftest.$ac_objext \
11280 conftest$ac_exeext conftest.$ac_ext
11281 if test "${xgnu_linux_first_failure}" = "yes"; then
11282 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
11283 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
11284 OLD_CPPFLAGS="$CPPFLAGS"
11285 OLD_LIBS="$LIBS"
11286 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
11287 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
11288 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
11289 LIBS="$LIBS -b i486-linuxaout"
11290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11291 /* end confdefs.h. */
11292
11293 int
11294 main ()
11295 {
11296 XOpenDisplay ("foo");
11297 ;
11298 return 0;
11299 }
11300 _ACEOF
11301 if ac_fn_c_try_link "$LINENO"; then :
11302 xgnu_linux_second_failure=no
11303 else
11304 xgnu_linux_second_failure=yes
11305 fi
11306 rm -f core conftest.err conftest.$ac_objext \
11307 conftest$ac_exeext conftest.$ac_ext
11308 if test "${xgnu_linux_second_failure}" = "yes"; then
11309 # If we get the same failure with -b, there is no use adding -b.
11310 # So take it out. This plays safe.
11311 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
11312 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
11313 CPPFLAGS="$OLD_CPPFLAGS"
11314 LIBS="$OLD_LIBS"
11315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11316 $as_echo "no" >&6; }
11317 else
11318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11319 $as_echo "yes" >&6; }
11320 fi
11321 else
11322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11323 $as_echo "no" >&6; }
11324 fi
11325 fi
11326
11327 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
11328 # header files included from there.
11329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
11330 $as_echo_n "checking for Xkb... " >&6; }
11331 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11332 /* end confdefs.h. */
11333 #include <X11/Xlib.h>
11334 #include <X11/XKBlib.h>
11335 int
11336 main ()
11337 {
11338 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
11339 ;
11340 return 0;
11341 }
11342 _ACEOF
11343 if ac_fn_c_try_link "$LINENO"; then :
11344 emacs_xkb=yes
11345 else
11346 emacs_xkb=no
11347 fi
11348 rm -f core conftest.err conftest.$ac_objext \
11349 conftest$ac_exeext conftest.$ac_ext
11350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
11351 $as_echo "$emacs_xkb" >&6; }
11352 if test $emacs_xkb = yes; then
11353
11354 $as_echo "#define HAVE_XKB 1" >>confdefs.h
11355
11356 fi
11357
11358 for ac_func in XrmSetDatabase XScreenResourceString \
11359 XScreenNumberOfScreen
11360 do :
11361 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11362 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11363 eval as_val=\$$as_ac_var
11364 if test "x$as_val" = x""yes; then :
11365 cat >>confdefs.h <<_ACEOF
11366 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11367 _ACEOF
11368
11369 fi
11370 done
11371
11372 fi
11373
11374 if test "${window_system}" = "x11"; then
11375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
11376 $as_echo_n "checking X11 version 6... " >&6; }
11377 if test "${emacs_cv_x11_version_6+set}" = set; then :
11378 $as_echo_n "(cached) " >&6
11379 else
11380 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11381 /* end confdefs.h. */
11382 #include <X11/Xlib.h>
11383 int
11384 main ()
11385 {
11386 #if XlibSpecificationRelease < 6
11387 fail;
11388 #endif
11389
11390 ;
11391 return 0;
11392 }
11393 _ACEOF
11394 if ac_fn_c_try_link "$LINENO"; then :
11395 emacs_cv_x11_version_6=yes
11396 else
11397 emacs_cv_x11_version_6=no
11398 fi
11399 rm -f core conftest.err conftest.$ac_objext \
11400 conftest$ac_exeext conftest.$ac_ext
11401 fi
11402
11403 if test $emacs_cv_x11_version_6 = yes; then
11404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11405 $as_echo "6 or newer" >&6; }
11406
11407 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
11408
11409
11410 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
11411
11412 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
11413 ## XIM support.
11414 case "$opsys" in
11415 sol2-*) : ;;
11416 *)
11417 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
11418
11419 ;;
11420 esac
11421 else
11422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11423 $as_echo "before 6" >&6; }
11424 fi
11425 fi
11426
11427
11428 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
11429 HAVE_RSVG=no
11430 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes" || test "${opsys}" = "mingw32"; then
11431 if test "${with_rsvg}" != "no"; then
11432 RSVG_REQUIRED=2.11.0
11433 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
11434
11435
11436 succeeded=no
11437
11438 if test "$PKG_CONFIG" = "no" ; then
11439 :
11440 else
11441 PKG_CONFIG_MIN_VERSION=0.9.0
11442 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
11444 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
11445
11446 if "$PKG_CONFIG" --exists "$RSVG_MODULE" 2>&5 &&
11447 RSVG_CFLAGS=`"$PKG_CONFIG" --cflags "$RSVG_MODULE" 2>&5` &&
11448 RSVG_LIBS=`"$PKG_CONFIG" --libs "$RSVG_MODULE" 2>&5`; then
11449 edit_cflags="
11450 s,///*,/,g
11451 s/^/ /
11452 s/ -I/ $isystem/g
11453 s/^ //
11454 "
11455 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
11456 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
11458 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
11459 succeeded=yes
11460 else
11461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11462 $as_echo "no" >&6; }
11463 RSVG_CFLAGS=""
11464 RSVG_LIBS=""
11465 ## If we have a custom action on failure, don't print errors, but
11466 ## do set a variable so people can do so. Do it in a subshell
11467 ## to capture any diagnostics in invoking pkg-config.
11468 RSVG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$RSVG_MODULE") 2>&1`
11469
11470 fi
11471
11472
11473
11474 else
11475 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11476 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11477 fi
11478 fi
11479
11480 if test $succeeded = yes; then
11481 HAVE_RSVG=yes
11482 else
11483 :
11484 fi
11485
11486
11487
11488
11489 if test $HAVE_RSVG = yes; then
11490
11491 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
11492
11493 CFLAGS="$CFLAGS $RSVG_CFLAGS"
11494 LIBS="$RSVG_LIBS $LIBS"
11495 fi
11496 fi
11497 fi
11498
11499 HAVE_IMAGEMAGICK=no
11500 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
11501 if test "${with_imagemagick}" != "no"; then
11502 ## 6.2.8 is the earliest version known to work, but earlier versions
11503 ## might work - let us know if you find one.
11504 ## 6.0.7 does not work. See bug#7955.
11505 ## 6.8.2 makes Emacs crash; see Bug#13867.
11506 IMAGEMAGICK_MODULE="Wand >= 6.2.8 Wand != 6.8.2"
11507
11508 succeeded=no
11509
11510 if test "$PKG_CONFIG" = "no" ; then
11511 :
11512 else
11513 PKG_CONFIG_MIN_VERSION=0.9.0
11514 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
11516 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
11517
11518 if "$PKG_CONFIG" --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
11519 IMAGEMAGICK_CFLAGS=`"$PKG_CONFIG" --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
11520 IMAGEMAGICK_LIBS=`"$PKG_CONFIG" --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
11521 edit_cflags="
11522 s,///*,/,g
11523 s/^/ /
11524 s/ -I/ $isystem/g
11525 s/^ //
11526 "
11527 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
11528 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
11529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
11530 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
11531 succeeded=yes
11532 else
11533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11534 $as_echo "no" >&6; }
11535 IMAGEMAGICK_CFLAGS=""
11536 IMAGEMAGICK_LIBS=""
11537 ## If we have a custom action on failure, don't print errors, but
11538 ## do set a variable so people can do so. Do it in a subshell
11539 ## to capture any diagnostics in invoking pkg-config.
11540 IMAGEMAGICK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
11541
11542 fi
11543
11544
11545
11546 else
11547 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11548 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11549 fi
11550 fi
11551
11552 if test $succeeded = yes; then
11553 HAVE_IMAGEMAGICK=yes
11554 else
11555 :
11556 fi
11557
11558
11559
11560
11561 if test $HAVE_IMAGEMAGICK = yes; then
11562
11563 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
11564
11565 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
11566 LIBS="$IMAGEMAGICK_LIBS $LIBS"
11567 for ac_func in MagickExportImagePixels MagickMergeImageLayers
11568 do :
11569 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11570 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11571 eval as_val=\$$as_ac_var
11572 if test "x$as_val" = x""yes; then :
11573 cat >>confdefs.h <<_ACEOF
11574 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11575 _ACEOF
11576
11577 fi
11578 done
11579
11580 fi
11581 fi
11582 fi
11583
11584
11585 HAVE_GTK=no
11586 GTK_OBJ=
11587 gtk_term_header=$term_header
11588 check_gtk2=no
11589 gtk3_pkg_errors=
11590 if test "${opsys}" != "mingw32"; then
11591 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11592 GLIB_REQUIRED=2.28
11593 GTK_REQUIRED=3.0
11594 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11595
11596
11597 succeeded=no
11598
11599 if test "$PKG_CONFIG" = "no" ; then
11600 pkg_check_gtk=no
11601 else
11602 PKG_CONFIG_MIN_VERSION=0.9.0
11603 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11605 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11606
11607 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11608 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11609 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11610 edit_cflags="
11611 s,///*,/,g
11612 s/^/ /
11613 s/ -I/ $isystem/g
11614 s/^ //
11615 "
11616 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11617 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11619 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11620 succeeded=yes
11621 else
11622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11623 $as_echo "no" >&6; }
11624 GTK_CFLAGS=""
11625 GTK_LIBS=""
11626 ## If we have a custom action on failure, don't print errors, but
11627 ## do set a variable so people can do so. Do it in a subshell
11628 ## to capture any diagnostics in invoking pkg-config.
11629 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11630
11631 fi
11632
11633
11634
11635 else
11636 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11637 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11638 fi
11639 fi
11640
11641 if test $succeeded = yes; then
11642 pkg_check_gtk=yes
11643 else
11644 pkg_check_gtk=no
11645 fi
11646
11647 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
11648 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11649 fi
11650 if test "$pkg_check_gtk" = "yes"; then
11651
11652 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11653
11654 GTK_OBJ=emacsgtkfixed.o
11655 gtk_term_header=gtkutil.h
11656 USE_GTK_TOOLKIT="GTK3"
11657 if test "x$ac_enable_gtk_deprecation_warnings" = x; then
11658 GTK_CFLAGS="$GTK_CFLAGS -DGDK_DISABLE_DEPRECATION_WARNINGS"
11659 GTK_CFLAGS="$GTK_CFLAGS -DGLIB_DISABLE_DEPRECATION_WARNINGS"
11660 fi
11661 else
11662 check_gtk2=yes
11663 gtk3_pkg_errors="$GTK_PKG_ERRORS "
11664 fi
11665 fi
11666
11667 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
11668 GLIB_REQUIRED=2.10
11669 GTK_REQUIRED=2.10
11670 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11671
11672
11673 succeeded=no
11674
11675 if test "$PKG_CONFIG" = "no" ; then
11676 pkg_check_gtk=no
11677 else
11678 PKG_CONFIG_MIN_VERSION=0.9.0
11679 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11681 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11682
11683 if "$PKG_CONFIG" --exists "$GTK_MODULES" 2>&5 &&
11684 GTK_CFLAGS=`"$PKG_CONFIG" --cflags "$GTK_MODULES" 2>&5` &&
11685 GTK_LIBS=`"$PKG_CONFIG" --libs "$GTK_MODULES" 2>&5`; then
11686 edit_cflags="
11687 s,///*,/,g
11688 s/^/ /
11689 s/ -I/ $isystem/g
11690 s/^ //
11691 "
11692 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
11693 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11695 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11696 succeeded=yes
11697 else
11698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11699 $as_echo "no" >&6; }
11700 GTK_CFLAGS=""
11701 GTK_LIBS=""
11702 ## If we have a custom action on failure, don't print errors, but
11703 ## do set a variable so people can do so. Do it in a subshell
11704 ## to capture any diagnostics in invoking pkg-config.
11705 GTK_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$GTK_MODULES") 2>&1`
11706
11707 fi
11708
11709
11710
11711 else
11712 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11713 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11714 fi
11715 fi
11716
11717 if test $succeeded = yes; then
11718 pkg_check_gtk=yes
11719 else
11720 pkg_check_gtk=no
11721 fi
11722
11723 if test "$pkg_check_gtk" = "no" &&
11724 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
11725 then
11726 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
11727 fi
11728 test "$pkg_check_gtk" = "yes" && USE_GTK_TOOLKIT="GTK2"
11729 fi
11730 fi
11731
11732 if test x"$pkg_check_gtk" = xyes; then
11733
11734
11735
11736 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11737 CFLAGS="$CFLAGS $GTK_CFLAGS"
11738 LIBS="$GTK_LIBS $LIBS"
11739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GTK compiles" >&5
11740 $as_echo_n "checking whether GTK compiles... " >&6; }
11741 GTK_COMPILES=no
11742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11743 /* end confdefs.h. */
11744 /* Check the Gtk and Glib APIs. */
11745 #include <gtk/gtk.h>
11746 #include <glib-object.h>
11747 static void
11748 callback (GObject *go, GParamSpec *spec, gpointer user_data)
11749 {}
11750
11751 int
11752 main ()
11753 {
11754
11755 GtkSettings *gs = 0;
11756 /* Use G_CALLBACK to make sure function pointers can be cast to void *;
11757 strict C prohibits this. Use gtk_main_iteration to test that the
11758 libraries are there. */
11759 if (g_signal_handler_find (G_OBJECT (gs), G_SIGNAL_MATCH_FUNC,
11760 0, 0, 0, G_CALLBACK (callback), 0))
11761 gtk_main_iteration ();
11762
11763 ;
11764 return 0;
11765 }
11766 _ACEOF
11767 if ac_fn_c_try_link "$LINENO"; then :
11768 GTK_COMPILES=yes
11769 fi
11770 rm -f core conftest.err conftest.$ac_objext \
11771 conftest$ac_exeext conftest.$ac_ext
11772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_COMPILES" >&5
11773 $as_echo "$GTK_COMPILES" >&6; }
11774 if test "${GTK_COMPILES}" != "yes"; then
11775 GTK_OBJ=
11776 if test "$USE_X_TOOLKIT" != "maybe"; then
11777 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11778 fi
11779 else
11780 HAVE_GTK=yes
11781
11782 $as_echo "#define USE_GTK 1" >>confdefs.h
11783
11784 GTK_OBJ="gtkutil.o $GTK_OBJ"
11785 term_header=$gtk_term_header
11786 USE_X_TOOLKIT=none
11787 if "$PKG_CONFIG" --atleast-version=2.10 gtk+-2.0; then
11788 :
11789 else
11790 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11791 closing open displays. This is no problem if you just use
11792 one display, but if you use more than one and close one of them
11793 Emacs may crash." >&5
11794 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11795 closing open displays. This is no problem if you just use
11796 one display, but if you use more than one and close one of them
11797 Emacs may crash." >&2;}
11798 sleep 3
11799 fi
11800 fi
11801
11802 fi
11803
11804
11805
11806 if test "${HAVE_GTK}" = "yes"; then
11807
11808 if test "$with_toolkit_scroll_bars" != no; then
11809 with_toolkit_scroll_bars=yes
11810 fi
11811
11812 HAVE_GTK_FILE_SELECTION=no
11813 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11814 #include <gtk/gtk.h>
11815 "
11816 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11817 HAVE_GTK_FILE_SELECTION=yes
11818 else
11819 HAVE_GTK_FILE_SELECTION=no
11820 fi
11821
11822 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11823 for ac_func in gtk_file_selection_new
11824 do :
11825 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11826 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11827 cat >>confdefs.h <<_ACEOF
11828 #define HAVE_GTK_FILE_SELECTION_NEW 1
11829 _ACEOF
11830
11831 fi
11832 done
11833
11834 fi
11835
11836 HAVE_GTK_HANDLE_BOX=no
11837 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_HANDLE_BOX" "ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" "$ac_includes_default
11838 #include <gtk/gtk.h>
11839 "
11840 if test "x$ac_cv_have_decl_GTK_TYPE_HANDLE_BOX" = x""yes; then :
11841 HAVE_GTK_HANDLE_BOX=yes
11842 else
11843 HAVE_GTK_HANDLE_BOX=no
11844 fi
11845
11846 if test "$HAVE_GTK_HANDLE_BOX" = yes; then
11847 for ac_func in gtk_handle_box_new
11848 do :
11849 ac_fn_c_check_func "$LINENO" "gtk_handle_box_new" "ac_cv_func_gtk_handle_box_new"
11850 if test "x$ac_cv_func_gtk_handle_box_new" = x""yes; then :
11851 cat >>confdefs.h <<_ACEOF
11852 #define HAVE_GTK_HANDLE_BOX_NEW 1
11853 _ACEOF
11854
11855 fi
11856 done
11857
11858 fi
11859
11860 HAVE_GTK_TEAROFF_MENU_ITEM=no
11861 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_TEAROFF_MENU_ITEM" "ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" "$ac_includes_default
11862 #include <gtk/gtk.h>
11863 "
11864 if test "x$ac_cv_have_decl_GTK_TYPE_TEAROFF_MENU_ITEM" = x""yes; then :
11865 HAVE_GTK_TEAROFF_MENU_ITEM=yes
11866 else
11867 HAVE_GTK_TEAROFF_MENU_ITEM=no
11868 fi
11869
11870 if test "$HAVE_GTK_TEAROFF_MENU_ITEM" = yes; then
11871 for ac_func in gtk_tearoff_menu_item_new
11872 do :
11873 ac_fn_c_check_func "$LINENO" "gtk_tearoff_menu_item_new" "ac_cv_func_gtk_tearoff_menu_item_new"
11874 if test "x$ac_cv_func_gtk_tearoff_menu_item_new" = x""yes; then :
11875 cat >>confdefs.h <<_ACEOF
11876 #define HAVE_GTK_TEAROFF_MENU_ITEM_NEW 1
11877 _ACEOF
11878
11879 fi
11880 done
11881
11882 fi
11883
11884 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11885 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11886 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11887 gtk_orientable_set_orientation \
11888 gtk_window_set_has_resize_grip
11889 do :
11890 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11891 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11892 eval as_val=\$$as_ac_var
11893 if test "x$as_val" = x""yes; then :
11894 cat >>confdefs.h <<_ACEOF
11895 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11896 _ACEOF
11897
11898 fi
11899 done
11900
11901
11902 term_header=gtkutil.h
11903 fi
11904
11905 HAVE_DBUS=no
11906 DBUS_OBJ=
11907 if test "${with_dbus}" = "yes"; then
11908
11909 succeeded=no
11910
11911 if test "$PKG_CONFIG" = "no" ; then
11912 HAVE_DBUS=no
11913 else
11914 PKG_CONFIG_MIN_VERSION=0.9.0
11915 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11917 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11918
11919 if "$PKG_CONFIG" --exists "dbus-1 >= 1.0" 2>&5 &&
11920 DBUS_CFLAGS=`"$PKG_CONFIG" --cflags "dbus-1 >= 1.0" 2>&5` &&
11921 DBUS_LIBS=`"$PKG_CONFIG" --libs "dbus-1 >= 1.0" 2>&5`; then
11922 edit_cflags="
11923 s,///*,/,g
11924 s/^/ /
11925 s/ -I/ $isystem/g
11926 s/^ //
11927 "
11928 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
11929 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11931 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11932 succeeded=yes
11933 else
11934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11935 $as_echo "no" >&6; }
11936 DBUS_CFLAGS=""
11937 DBUS_LIBS=""
11938 ## If we have a custom action on failure, don't print errors, but
11939 ## do set a variable so people can do so. Do it in a subshell
11940 ## to capture any diagnostics in invoking pkg-config.
11941 DBUS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "dbus-1 >= 1.0") 2>&1`
11942
11943 fi
11944
11945
11946
11947 else
11948 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11949 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11950 fi
11951 fi
11952
11953 if test $succeeded = yes; then
11954 HAVE_DBUS=yes
11955 else
11956 HAVE_DBUS=no
11957 fi
11958
11959 if test "$HAVE_DBUS" = yes; then
11960 LIBS="$LIBS $DBUS_LIBS"
11961
11962 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11963
11964 for ac_func in dbus_watch_get_unix_fd \
11965 dbus_type_is_valid \
11966 dbus_validate_bus_name \
11967 dbus_validate_path \
11968 dbus_validate_interface \
11969 dbus_validate_member
11970 do :
11971 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11972 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11973 eval as_val=\$$as_ac_var
11974 if test "x$as_val" = x""yes; then :
11975 cat >>confdefs.h <<_ACEOF
11976 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11977 _ACEOF
11978
11979 fi
11980 done
11981
11982 DBUS_OBJ=dbusbind.o
11983 fi
11984 fi
11985
11986
11987 HAVE_GSETTINGS=no
11988 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11989
11990 succeeded=no
11991
11992 if test "$PKG_CONFIG" = "no" ; then
11993 HAVE_GSETTINGS=no
11994 else
11995 PKG_CONFIG_MIN_VERSION=0.9.0
11996 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11998 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11999
12000 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.26" 2>&5 &&
12001 GSETTINGS_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.26" 2>&5` &&
12002 GSETTINGS_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.26" 2>&5`; then
12003 edit_cflags="
12004 s,///*,/,g
12005 s/^/ /
12006 s/ -I/ $isystem/g
12007 s/^ //
12008 "
12009 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
12010 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
12011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
12012 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
12013 succeeded=yes
12014 else
12015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12016 $as_echo "no" >&6; }
12017 GSETTINGS_CFLAGS=""
12018 GSETTINGS_LIBS=""
12019 ## If we have a custom action on failure, don't print errors, but
12020 ## do set a variable so people can do so. Do it in a subshell
12021 ## to capture any diagnostics in invoking pkg-config.
12022 GSETTINGS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.26") 2>&1`
12023
12024 fi
12025
12026
12027
12028 else
12029 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12030 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12031 fi
12032 fi
12033
12034 if test $succeeded = yes; then
12035 HAVE_GSETTINGS=yes
12036 else
12037 HAVE_GSETTINGS=no
12038 fi
12039
12040 if test "$HAVE_GSETTINGS" = "yes"; then
12041
12042 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
12043
12044 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
12045 SETTINGS_LIBS="$GSETTINGS_LIBS"
12046 fi
12047 fi
12048
12049 HAVE_GCONF=no
12050 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
12051
12052 succeeded=no
12053
12054 if test "$PKG_CONFIG" = "no" ; then
12055 HAVE_GCONF=no
12056 else
12057 PKG_CONFIG_MIN_VERSION=0.9.0
12058 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
12060 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
12061
12062 if "$PKG_CONFIG" --exists "gconf-2.0 >= 2.13" 2>&5 &&
12063 GCONF_CFLAGS=`"$PKG_CONFIG" --cflags "gconf-2.0 >= 2.13" 2>&5` &&
12064 GCONF_LIBS=`"$PKG_CONFIG" --libs "gconf-2.0 >= 2.13" 2>&5`; then
12065 edit_cflags="
12066 s,///*,/,g
12067 s/^/ /
12068 s/ -I/ $isystem/g
12069 s/^ //
12070 "
12071 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
12072 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
12073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
12074 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
12075 succeeded=yes
12076 else
12077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12078 $as_echo "no" >&6; }
12079 GCONF_CFLAGS=""
12080 GCONF_LIBS=""
12081 ## If we have a custom action on failure, don't print errors, but
12082 ## do set a variable so people can do so. Do it in a subshell
12083 ## to capture any diagnostics in invoking pkg-config.
12084 GCONF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gconf-2.0 >= 2.13") 2>&1`
12085
12086 fi
12087
12088
12089
12090 else
12091 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12092 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12093 fi
12094 fi
12095
12096 if test $succeeded = yes; then
12097 HAVE_GCONF=yes
12098 else
12099 HAVE_GCONF=no
12100 fi
12101
12102 if test "$HAVE_GCONF" = yes; then
12103
12104 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
12105
12106 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
12107 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
12108 fi
12109 fi
12110
12111 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
12112
12113 succeeded=no
12114
12115 if test "$PKG_CONFIG" = "no" ; then
12116 HAVE_GOBJECT=no
12117 else
12118 PKG_CONFIG_MIN_VERSION=0.9.0
12119 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
12121 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
12122
12123 if "$PKG_CONFIG" --exists "gobject-2.0 >= 2.0" 2>&5 &&
12124 GOBJECT_CFLAGS=`"$PKG_CONFIG" --cflags "gobject-2.0 >= 2.0" 2>&5` &&
12125 GOBJECT_LIBS=`"$PKG_CONFIG" --libs "gobject-2.0 >= 2.0" 2>&5`; then
12126 edit_cflags="
12127 s,///*,/,g
12128 s/^/ /
12129 s/ -I/ $isystem/g
12130 s/^ //
12131 "
12132 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
12133 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
12134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
12135 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
12136 succeeded=yes
12137 else
12138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12139 $as_echo "no" >&6; }
12140 GOBJECT_CFLAGS=""
12141 GOBJECT_LIBS=""
12142 ## If we have a custom action on failure, don't print errors, but
12143 ## do set a variable so people can do so. Do it in a subshell
12144 ## to capture any diagnostics in invoking pkg-config.
12145 GOBJECT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gobject-2.0 >= 2.0") 2>&1`
12146
12147 fi
12148
12149
12150
12151 else
12152 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12153 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12154 fi
12155 fi
12156
12157 if test $succeeded = yes; then
12158 HAVE_GOBJECT=yes
12159 else
12160 HAVE_GOBJECT=no
12161 fi
12162
12163 if test "$HAVE_GOBJECT" = "yes"; then
12164 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
12165 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
12166 fi
12167 SAVE_CFLAGS="$CFLAGS"
12168 SAVE_LIBS="$LIBS"
12169 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
12170 LIBS="$SETTINGS_LIBS $LIBS"
12171 CFLAGS="$SAVE_CFLAGS"
12172 LIBS="$SAVE_LIBS"
12173 fi
12174
12175
12176
12177
12178 HAVE_LIBSELINUX=no
12179 LIBSELINUX_LIBS=
12180 if test "${with_selinux}" = "yes"; then
12181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
12182 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
12183 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
12184 $as_echo_n "(cached) " >&6
12185 else
12186 ac_check_lib_save_LIBS=$LIBS
12187 LIBS="-lselinux $LIBS"
12188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12189 /* end confdefs.h. */
12190
12191 /* Override any GCC internal prototype to avoid an error.
12192 Use char because int might match the return type of a GCC
12193 builtin and then its argument prototype would still apply. */
12194 #ifdef __cplusplus
12195 extern "C"
12196 #endif
12197 char lgetfilecon ();
12198 int
12199 main ()
12200 {
12201 return lgetfilecon ();
12202 ;
12203 return 0;
12204 }
12205 _ACEOF
12206 if ac_fn_c_try_link "$LINENO"; then :
12207 ac_cv_lib_selinux_lgetfilecon=yes
12208 else
12209 ac_cv_lib_selinux_lgetfilecon=no
12210 fi
12211 rm -f core conftest.err conftest.$ac_objext \
12212 conftest$ac_exeext conftest.$ac_ext
12213 LIBS=$ac_check_lib_save_LIBS
12214 fi
12215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
12216 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
12217 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
12218 HAVE_LIBSELINUX=yes
12219 else
12220 HAVE_LIBSELINUX=no
12221 fi
12222
12223 if test "$HAVE_LIBSELINUX" = yes; then
12224
12225 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
12226
12227 LIBSELINUX_LIBS=-lselinux
12228 fi
12229 fi
12230
12231
12232 HAVE_GNUTLS=no
12233 HAVE_GNUTLS3=no
12234 if test "${with_gnutls}" = "yes" ; then
12235
12236 succeeded=no
12237
12238 if test "$PKG_CONFIG" = "no" ; then
12239 HAVE_GNUTLS3=no
12240 else
12241 PKG_CONFIG_MIN_VERSION=0.9.0
12242 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 3.0.0" >&5
12244 $as_echo_n "checking for gnutls >= 3.0.0... " >&6; }
12245
12246 if "$PKG_CONFIG" --exists "gnutls >= 3.0.0" 2>&5 &&
12247 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 3.0.0" 2>&5` &&
12248 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 3.0.0" 2>&5`; then
12249 edit_cflags="
12250 s,///*,/,g
12251 s/^/ /
12252 s/ -I/ $isystem/g
12253 s/^ //
12254 "
12255 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
12256 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
12257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
12258 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
12259 succeeded=yes
12260 else
12261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12262 $as_echo "no" >&6; }
12263 LIBGNUTLS_CFLAGS=""
12264 LIBGNUTLS_LIBS=""
12265 ## If we have a custom action on failure, don't print errors, but
12266 ## do set a variable so people can do so. Do it in a subshell
12267 ## to capture any diagnostics in invoking pkg-config.
12268 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 3.0.0") 2>&1`
12269
12270 fi
12271
12272
12273
12274 else
12275 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12276 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12277 fi
12278 fi
12279
12280 if test $succeeded = yes; then
12281 HAVE_GNUTLS3=yes
12282 else
12283 HAVE_GNUTLS3=no
12284 fi
12285
12286 if test "${HAVE_GNUTLS3}" = "yes"; then
12287
12288 $as_echo "#define HAVE_GNUTLS3 1" >>confdefs.h
12289
12290 HAVE_GNUTLS="yes"
12291 else
12292
12293 succeeded=no
12294
12295 if test "$PKG_CONFIG" = "no" ; then
12296 HAVE_GNUTLS=no
12297 else
12298 PKG_CONFIG_MIN_VERSION=0.9.0
12299 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
12301 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
12302
12303 if "$PKG_CONFIG" --exists "gnutls >= 2.6.6" 2>&5 &&
12304 LIBGNUTLS_CFLAGS=`"$PKG_CONFIG" --cflags "gnutls >= 2.6.6" 2>&5` &&
12305 LIBGNUTLS_LIBS=`"$PKG_CONFIG" --libs "gnutls >= 2.6.6" 2>&5`; then
12306 edit_cflags="
12307 s,///*,/,g
12308 s/^/ /
12309 s/ -I/ $isystem/g
12310 s/^ //
12311 "
12312 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
12313 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
12314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
12315 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
12316 succeeded=yes
12317 else
12318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12319 $as_echo "no" >&6; }
12320 LIBGNUTLS_CFLAGS=""
12321 LIBGNUTLS_LIBS=""
12322 ## If we have a custom action on failure, don't print errors, but
12323 ## do set a variable so people can do so. Do it in a subshell
12324 ## to capture any diagnostics in invoking pkg-config.
12325 LIBGNUTLS_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gnutls >= 2.6.6") 2>&1`
12326
12327 fi
12328
12329
12330
12331 else
12332 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12333 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12334 fi
12335 fi
12336
12337 if test $succeeded = yes; then
12338 HAVE_GNUTLS=yes
12339 else
12340 HAVE_GNUTLS=no
12341 fi
12342
12343 fi
12344 if test "${HAVE_GNUTLS}" = "yes"; then
12345
12346 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
12347
12348 fi
12349
12350 # Windows loads GnuTLS dynamically
12351 if test "${opsys}" = "mingw32"; then
12352 LIBGNUTLS_LIBS=
12353 else
12354 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
12355 LIBS="$LIBGNUTLS_LIBS $LIBS"
12356 fi
12357 fi
12358
12359
12360
12361
12362 NOTIFY_OBJ=
12363 NOTIFY_SUMMARY=no
12364
12365 if test "${with_ns}" = yes && test ${with_file_notification} = yes; then
12366 with_file_notification=no
12367 fi
12368
12369 case $with_file_notification,$opsys in
12370 w32,* | yes,mingw32)
12371 ac_fn_c_check_header_mongrel "$LINENO" "windows.h" "ac_cv_header_windows_h" "$ac_includes_default"
12372 if test "x$ac_cv_header_windows_h" = x""yes; then :
12373
12374 fi
12375
12376
12377 if test "$ac_cv_header_windows_h" = yes ; then
12378
12379 $as_echo "#define HAVE_W32NOTIFY 1" >>confdefs.h
12380
12381 NOTIFY_OBJ=w32notify.o
12382 NOTIFY_SUMMARY="yes (w32)"
12383 fi ;;
12384 esac
12385
12386 case $with_file_notification,$NOTIFY_OBJ in
12387 gfile, | yes,)
12388
12389 succeeded=no
12390
12391 if test "$PKG_CONFIG" = "no" ; then
12392 HAVE_GFILENOTIFY=no
12393 else
12394 PKG_CONFIG_MIN_VERSION=0.9.0
12395 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.24" >&5
12397 $as_echo_n "checking for gio-2.0 >= 2.24... " >&6; }
12398
12399 if "$PKG_CONFIG" --exists "gio-2.0 >= 2.24" 2>&5 &&
12400 GFILENOTIFY_CFLAGS=`"$PKG_CONFIG" --cflags "gio-2.0 >= 2.24" 2>&5` &&
12401 GFILENOTIFY_LIBS=`"$PKG_CONFIG" --libs "gio-2.0 >= 2.24" 2>&5`; then
12402 edit_cflags="
12403 s,///*,/,g
12404 s/^/ /
12405 s/ -I/ $isystem/g
12406 s/^ //
12407 "
12408 GFILENOTIFY_CFLAGS=`$as_echo "$GFILENOTIFY_CFLAGS" | sed -e "$edit_cflags"`
12409 GFILENOTIFY_LIBS=`$as_echo "$GFILENOTIFY_LIBS" | sed -e 's,///*,/,g'`
12410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&5
12411 $as_echo "yes CFLAGS='$GFILENOTIFY_CFLAGS' LIBS='$GFILENOTIFY_LIBS'" >&6; }
12412 succeeded=yes
12413 else
12414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12415 $as_echo "no" >&6; }
12416 GFILENOTIFY_CFLAGS=""
12417 GFILENOTIFY_LIBS=""
12418 ## If we have a custom action on failure, don't print errors, but
12419 ## do set a variable so people can do so. Do it in a subshell
12420 ## to capture any diagnostics in invoking pkg-config.
12421 GFILENOTIFY_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "gio-2.0 >= 2.24") 2>&1`
12422
12423 fi
12424
12425
12426
12427 else
12428 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12429 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12430 fi
12431 fi
12432
12433 if test $succeeded = yes; then
12434 HAVE_GFILENOTIFY=yes
12435 else
12436 HAVE_GFILENOTIFY=no
12437 fi
12438
12439 if test "$HAVE_GFILENOTIFY" = "yes"; then
12440
12441 $as_echo "#define HAVE_GFILENOTIFY 1" >>confdefs.h
12442
12443 NOTIFY_OBJ=gfilenotify.o
12444 NOTIFY_SUMMARY="yes -lgio (gfile)"
12445 fi ;;
12446 esac
12447
12448 case $with_file_notification,$NOTIFY_OBJ in
12449 inotify, | yes,)
12450 ac_fn_c_check_header_mongrel "$LINENO" "sys/inotify.h" "ac_cv_header_sys_inotify_h" "$ac_includes_default"
12451 if test "x$ac_cv_header_sys_inotify_h" = x""yes; then :
12452
12453 fi
12454
12455
12456 if test "$ac_cv_header_sys_inotify_h" = yes ; then
12457 ac_fn_c_check_func "$LINENO" "inotify_init1" "ac_cv_func_inotify_init1"
12458 if test "x$ac_cv_func_inotify_init1" = x""yes; then :
12459
12460 fi
12461
12462 if test "$ac_cv_func_inotify_init1" = yes; then
12463
12464 $as_echo "#define HAVE_INOTIFY 1" >>confdefs.h
12465
12466 NOTIFY_OBJ=inotify.o
12467 NOTIFY_SUMMARY="yes -lglibc (inotify)"
12468 fi
12469 fi ;;
12470 esac
12471
12472 case $with_file_notification,$NOTIFY_OBJ in
12473 yes,* | no,* | *,?*) ;;
12474 *) as_fn_error "File notification \`$with_file_notification' requested but requirements not found." "$LINENO" 5 ;;
12475 esac
12476
12477 if test -n "$NOTIFY_OBJ"; then
12478
12479 $as_echo "#define USE_FILE_NOTIFY 1" >>confdefs.h
12480
12481 fi
12482
12483
12484
12485
12486 HAVE_XAW3D=no
12487 LUCID_LIBW=
12488 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
12489 if test "$with_xaw3d" != no; then
12490 if test "${emacs_cv_xaw3d+set}" = set; then :
12491 $as_echo_n "(cached) " >&6
12492 else
12493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12494 /* end confdefs.h. */
12495
12496 #include <X11/Intrinsic.h>
12497 #include <X11/Xaw3d/Simple.h>
12498 int
12499 main ()
12500 {
12501
12502 ;
12503 return 0;
12504 }
12505 _ACEOF
12506 if ac_fn_c_try_link "$LINENO"; then :
12507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
12508 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
12509 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
12510 $as_echo_n "(cached) " >&6
12511 else
12512 ac_check_lib_save_LIBS=$LIBS
12513 LIBS="-lXaw3d $LIBS"
12514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12515 /* end confdefs.h. */
12516
12517 /* Override any GCC internal prototype to avoid an error.
12518 Use char because int might match the return type of a GCC
12519 builtin and then its argument prototype would still apply. */
12520 #ifdef __cplusplus
12521 extern "C"
12522 #endif
12523 char XawScrollbarSetThumb ();
12524 int
12525 main ()
12526 {
12527 return XawScrollbarSetThumb ();
12528 ;
12529 return 0;
12530 }
12531 _ACEOF
12532 if ac_fn_c_try_link "$LINENO"; then :
12533 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
12534 else
12535 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
12536 fi
12537 rm -f core conftest.err conftest.$ac_objext \
12538 conftest$ac_exeext conftest.$ac_ext
12539 LIBS=$ac_check_lib_save_LIBS
12540 fi
12541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
12542 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
12543 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
12544 emacs_cv_xaw3d=yes
12545 else
12546 emacs_cv_xaw3d=no
12547 fi
12548
12549 else
12550 emacs_cv_xaw3d=no
12551 fi
12552 rm -f core conftest.err conftest.$ac_objext \
12553 conftest$ac_exeext conftest.$ac_ext
12554 fi
12555
12556 else
12557 emacs_cv_xaw3d=no
12558 fi
12559 if test $emacs_cv_xaw3d = yes; then
12560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12561 $as_echo_n "checking for xaw3d... " >&6; }
12562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12563 $as_echo "yes; using Lucid toolkit" >&6; }
12564 USE_X_TOOLKIT=LUCID
12565 HAVE_XAW3D=yes
12566 LUCID_LIBW=-lXaw3d
12567
12568 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
12569
12570 else
12571 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
12572 $as_echo_n "checking for xaw3d... " >&6; }
12573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12574 $as_echo "no" >&6; }
12575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
12576 $as_echo_n "checking for libXaw... " >&6; }
12577 if test "${emacs_cv_xaw+set}" = set; then :
12578 $as_echo_n "(cached) " >&6
12579 else
12580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12581 /* end confdefs.h. */
12582
12583 #include <X11/Intrinsic.h>
12584 #include <X11/Xaw/Simple.h>
12585 int
12586 main ()
12587 {
12588
12589 ;
12590 return 0;
12591 }
12592 _ACEOF
12593 if ac_fn_c_try_link "$LINENO"; then :
12594 emacs_cv_xaw=yes
12595 else
12596 emacs_cv_xaw=no
12597 fi
12598 rm -f core conftest.err conftest.$ac_objext \
12599 conftest$ac_exeext conftest.$ac_ext
12600 fi
12601
12602 if test $emacs_cv_xaw = yes; then
12603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
12604 $as_echo "yes; using Lucid toolkit" >&6; }
12605 USE_X_TOOLKIT=LUCID
12606 LUCID_LIBW=-lXaw
12607 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
12608 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
12609 else
12610 as_fn_error "No X toolkit could be found.
12611 If you are sure you want Emacs compiled without an X toolkit, pass
12612 --with-x-toolkit=no
12613 to configure. Otherwise, install the development libraries for the toolkit
12614 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
12615 fi
12616 fi
12617 fi
12618
12619 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
12620
12621 LIBXTR6=
12622 if test "${USE_X_TOOLKIT}" != "none"; then
12623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
12624 $as_echo_n "checking X11 toolkit version... " >&6; }
12625 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
12626 $as_echo_n "(cached) " >&6
12627 else
12628 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12629 /* end confdefs.h. */
12630 #include <X11/Intrinsic.h>
12631 int
12632 main ()
12633 {
12634 #if XtSpecificationRelease < 6
12635 fail;
12636 #endif
12637
12638 ;
12639 return 0;
12640 }
12641 _ACEOF
12642 if ac_fn_c_try_link "$LINENO"; then :
12643 emacs_cv_x11_toolkit_version_6=yes
12644 else
12645 emacs_cv_x11_toolkit_version_6=no
12646 fi
12647 rm -f core conftest.err conftest.$ac_objext \
12648 conftest$ac_exeext conftest.$ac_ext
12649 fi
12650
12651 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
12652 if test $emacs_cv_x11_toolkit_version_6 = yes; then
12653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
12654 $as_echo "6 or newer" >&6; }
12655
12656 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
12657
12658 LIBXTR6="-lSM -lICE"
12659 case "$opsys" in
12660 ## Use libw.a along with X11R6 Xt.
12661 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
12662 esac
12663 else
12664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
12665 $as_echo "before 6" >&6; }
12666 fi
12667
12668 OLDLIBS="$LIBS"
12669 if test x$HAVE_X11XTR6 = xyes; then
12670 LIBS="-lXt -lSM -lICE $LIBS"
12671 else
12672 LIBS="-lXt $LIBS"
12673 fi
12674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
12675 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
12676 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
12677 $as_echo_n "(cached) " >&6
12678 else
12679 ac_check_lib_save_LIBS=$LIBS
12680 LIBS="-lXmu $LIBS"
12681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12682 /* end confdefs.h. */
12683
12684 /* Override any GCC internal prototype to avoid an error.
12685 Use char because int might match the return type of a GCC
12686 builtin and then its argument prototype would still apply. */
12687 #ifdef __cplusplus
12688 extern "C"
12689 #endif
12690 char XmuConvertStandardSelection ();
12691 int
12692 main ()
12693 {
12694 return XmuConvertStandardSelection ();
12695 ;
12696 return 0;
12697 }
12698 _ACEOF
12699 if ac_fn_c_try_link "$LINENO"; then :
12700 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
12701 else
12702 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
12703 fi
12704 rm -f core conftest.err conftest.$ac_objext \
12705 conftest$ac_exeext conftest.$ac_ext
12706 LIBS=$ac_check_lib_save_LIBS
12707 fi
12708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
12709 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
12710 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
12711 cat >>confdefs.h <<_ACEOF
12712 #define HAVE_LIBXMU 1
12713 _ACEOF
12714
12715 LIBS="-lXmu $LIBS"
12716
12717 fi
12718
12719 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
12720 fi
12721
12722
12723 LIBXMU=-lXmu
12724 case $opsys in
12725 ## These systems don't supply Xmu.
12726 hpux* | aix4-2 )
12727 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
12728 ;;
12729 mingw32 )
12730 LIBXMU=
12731 ;;
12732 esac
12733
12734
12735 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
12736 if test "${HAVE_X11}" = "yes"; then
12737 if test "${USE_X_TOOLKIT}" != "none"; then
12738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
12739 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
12740 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
12741 $as_echo_n "(cached) " >&6
12742 else
12743 ac_check_lib_save_LIBS=$LIBS
12744 LIBS="-lXext $LIBS"
12745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12746 /* end confdefs.h. */
12747
12748 /* Override any GCC internal prototype to avoid an error.
12749 Use char because int might match the return type of a GCC
12750 builtin and then its argument prototype would still apply. */
12751 #ifdef __cplusplus
12752 extern "C"
12753 #endif
12754 char XShapeQueryExtension ();
12755 int
12756 main ()
12757 {
12758 return XShapeQueryExtension ();
12759 ;
12760 return 0;
12761 }
12762 _ACEOF
12763 if ac_fn_c_try_link "$LINENO"; then :
12764 ac_cv_lib_Xext_XShapeQueryExtension=yes
12765 else
12766 ac_cv_lib_Xext_XShapeQueryExtension=no
12767 fi
12768 rm -f core conftest.err conftest.$ac_objext \
12769 conftest$ac_exeext conftest.$ac_ext
12770 LIBS=$ac_check_lib_save_LIBS
12771 fi
12772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12773 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12774 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12775 cat >>confdefs.h <<_ACEOF
12776 #define HAVE_LIBXEXT 1
12777 _ACEOF
12778
12779 LIBS="-lXext $LIBS"
12780
12781 fi
12782
12783 fi
12784 fi
12785
12786 LIBXP=
12787 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12788 # OpenMotif may be installed in such a way on some GNU/Linux systems.
12789 if test -d /usr/include/openmotif; then
12790 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
12791 emacs_cv_openmotif=yes
12792 case "$canonical" in
12793 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
12794 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
12795 ;;
12796 *)
12797 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
12798 esac
12799 else
12800 emacs_cv_openmotif=no
12801 fi
12802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
12803 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
12804 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12805 $as_echo_n "(cached) " >&6
12806 else
12807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12808 /* end confdefs.h. */
12809 #include <Xm/Xm.h>
12810 int
12811 main ()
12812 {
12813 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12814 int x = 5;
12815 #else
12816 Motif version prior to 2.1.
12817 #endif
12818 ;
12819 return 0;
12820 }
12821 _ACEOF
12822 if ac_fn_c_try_compile "$LINENO"; then :
12823 emacs_cv_motif_version_2_1=yes
12824 else
12825 emacs_cv_motif_version_2_1=no
12826 fi
12827 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12828 fi
12829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12830 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12831 if test $emacs_cv_motif_version_2_1 = yes; then
12832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12833 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12834 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12835 $as_echo_n "(cached) " >&6
12836 else
12837 ac_check_lib_save_LIBS=$LIBS
12838 LIBS="-lXp $LIBS"
12839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12840 /* end confdefs.h. */
12841
12842 /* Override any GCC internal prototype to avoid an error.
12843 Use char because int might match the return type of a GCC
12844 builtin and then its argument prototype would still apply. */
12845 #ifdef __cplusplus
12846 extern "C"
12847 #endif
12848 char XpCreateContext ();
12849 int
12850 main ()
12851 {
12852 return XpCreateContext ();
12853 ;
12854 return 0;
12855 }
12856 _ACEOF
12857 if ac_fn_c_try_link "$LINENO"; then :
12858 ac_cv_lib_Xp_XpCreateContext=yes
12859 else
12860 ac_cv_lib_Xp_XpCreateContext=no
12861 fi
12862 rm -f core conftest.err conftest.$ac_objext \
12863 conftest$ac_exeext conftest.$ac_ext
12864 LIBS=$ac_check_lib_save_LIBS
12865 fi
12866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12867 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12868 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12869 LIBXP=-lXp
12870 fi
12871
12872 if test x$emacs_cv_openmotif = xyes; then
12873 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
12874 fi
12875 else
12876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12877 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12878 if test "${emacs_cv_lesstif+set}" = set; then :
12879 $as_echo_n "(cached) " >&6
12880 else
12881 # We put this in CFLAGS temporarily to precede other -I options
12882 # that might be in CFLAGS temporarily.
12883 # We put this in CPPFLAGS where it precedes the other -I options.
12884 OLD_CPPFLAGS=$CPPFLAGS
12885 OLD_CFLAGS=$CFLAGS
12886 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12887 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12889 /* end confdefs.h. */
12890 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12891 int
12892 main ()
12893 {
12894 int x = 5;
12895 ;
12896 return 0;
12897 }
12898 _ACEOF
12899 if ac_fn_c_try_compile "$LINENO"; then :
12900 emacs_cv_lesstif=yes
12901 else
12902 emacs_cv_lesstif=no
12903 fi
12904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12905 fi
12906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12907 $as_echo "$emacs_cv_lesstif" >&6; }
12908 if test $emacs_cv_lesstif = yes; then
12909 # Make sure this -I option remains in CPPFLAGS after it is set
12910 # back to REAL_CPPFLAGS.
12911 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12912 # have those other -I options anyway. Ultimately, having this
12913 # directory ultimately in CPPFLAGS will be enough.
12914 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12915 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12916 else
12917 CFLAGS=$OLD_CFLAGS
12918 CPPFLAGS=$OLD_CPPFLAGS
12919 fi
12920 fi
12921 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12922 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12923
12924 else
12925 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12926 fi
12927
12928
12929 fi
12930
12931
12932 USE_TOOLKIT_SCROLL_BARS=no
12933 if test "${with_toolkit_scroll_bars}" != "no"; then
12934 if test "${USE_X_TOOLKIT}" != "none"; then
12935 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12936 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12937
12938 HAVE_XAW3D=no
12939 USE_TOOLKIT_SCROLL_BARS=yes
12940 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12941 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12942
12943 USE_TOOLKIT_SCROLL_BARS=yes
12944 fi
12945 elif test "${HAVE_GTK}" = "yes"; then
12946 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12947
12948 USE_TOOLKIT_SCROLL_BARS=yes
12949 elif test "${HAVE_NS}" = "yes"; then
12950 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12951
12952 USE_TOOLKIT_SCROLL_BARS=yes
12953 elif test "${HAVE_W32}" = "yes"; then
12954 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12955
12956 USE_TOOLKIT_SCROLL_BARS=yes
12957 fi
12958 fi
12959
12960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12961 /* end confdefs.h. */
12962
12963 #include <X11/Xlib.h>
12964 #include <X11/Xresource.h>
12965 int
12966 main ()
12967 {
12968 XIMProc callback;
12969 ;
12970 return 0;
12971 }
12972 _ACEOF
12973 if ac_fn_c_try_compile "$LINENO"; then :
12974 HAVE_XIM=yes
12975
12976 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12977
12978 else
12979 HAVE_XIM=no
12980 fi
12981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12982
12983
12984 if test "${with_xim}" != "no"; then
12985
12986 $as_echo "#define USE_XIM 1" >>confdefs.h
12987
12988 fi
12989
12990
12991 if test "${HAVE_XIM}" != "no"; then
12992 late_CFLAGS=$CFLAGS
12993 if test "$GCC" = yes; then
12994 CFLAGS="$CFLAGS --pedantic-errors"
12995 fi
12996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12997 /* end confdefs.h. */
12998
12999 #include <X11/Xlib.h>
13000 #include <X11/Xresource.h>
13001 int
13002 main ()
13003 {
13004 Display *display;
13005 XrmDatabase db;
13006 char *res_name;
13007 char *res_class;
13008 XIMProc callback;
13009 XPointer *client_data;
13010 #ifndef __GNUC__
13011 /* If we're not using GCC, it's probably not XFree86, and this is
13012 probably right, but we can't use something like --pedantic-errors. */
13013 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
13014 char*, XIMProc, XPointer*);
13015 #endif
13016 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
13017 client_data);
13018 ;
13019 return 0;
13020 }
13021 _ACEOF
13022 if ac_fn_c_try_compile "$LINENO"; then :
13023 emacs_cv_arg6_star=yes
13024 fi
13025 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13026 if test "$emacs_cv_arg6_star" = yes; then
13027 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
13028
13029 else
13030 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
13031
13032 fi
13033 CFLAGS=$late_CFLAGS
13034 fi
13035
13036 ### Start of font-backend (under any platform) section.
13037 # (nothing here yet -- this is a placeholder)
13038 ### End of font-backend (under any platform) section.
13039
13040 ### Start of font-backend (under X11) section.
13041 if test "${HAVE_X11}" = "yes"; then
13042
13043 succeeded=no
13044
13045 if test "$PKG_CONFIG" = "no" ; then
13046 HAVE_FC=no
13047 else
13048 PKG_CONFIG_MIN_VERSION=0.9.0
13049 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
13051 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
13052
13053 if "$PKG_CONFIG" --exists "fontconfig >= 2.2.0" 2>&5 &&
13054 FONTCONFIG_CFLAGS=`"$PKG_CONFIG" --cflags "fontconfig >= 2.2.0" 2>&5` &&
13055 FONTCONFIG_LIBS=`"$PKG_CONFIG" --libs "fontconfig >= 2.2.0" 2>&5`; then
13056 edit_cflags="
13057 s,///*,/,g
13058 s/^/ /
13059 s/ -I/ $isystem/g
13060 s/^ //
13061 "
13062 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
13063 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
13064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
13065 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
13066 succeeded=yes
13067 else
13068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13069 $as_echo "no" >&6; }
13070 FONTCONFIG_CFLAGS=""
13071 FONTCONFIG_LIBS=""
13072 ## If we have a custom action on failure, don't print errors, but
13073 ## do set a variable so people can do so. Do it in a subshell
13074 ## to capture any diagnostics in invoking pkg-config.
13075 FONTCONFIG_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "fontconfig >= 2.2.0") 2>&1`
13076
13077 fi
13078
13079
13080
13081 else
13082 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13083 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13084 fi
13085 fi
13086
13087 if test $succeeded = yes; then
13088 HAVE_FC=yes
13089 else
13090 HAVE_FC=no
13091 fi
13092
13093
13094 ## Use -lXft if available, unless `--with-xft=no'.
13095 HAVE_XFT=maybe
13096 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
13097 with_xft="no";
13098 fi
13099 if test "x${with_xft}" != "xno"; then
13100
13101
13102 succeeded=no
13103
13104 if test "$PKG_CONFIG" = "no" ; then
13105 HAVE_XFT=no
13106 else
13107 PKG_CONFIG_MIN_VERSION=0.9.0
13108 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
13110 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
13111
13112 if "$PKG_CONFIG" --exists "xft >= 0.13.0" 2>&5 &&
13113 XFT_CFLAGS=`"$PKG_CONFIG" --cflags "xft >= 0.13.0" 2>&5` &&
13114 XFT_LIBS=`"$PKG_CONFIG" --libs "xft >= 0.13.0" 2>&5`; then
13115 edit_cflags="
13116 s,///*,/,g
13117 s/^/ /
13118 s/ -I/ $isystem/g
13119 s/^ //
13120 "
13121 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
13122 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
13123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
13124 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
13125 succeeded=yes
13126 else
13127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13128 $as_echo "no" >&6; }
13129 XFT_CFLAGS=""
13130 XFT_LIBS=""
13131 ## If we have a custom action on failure, don't print errors, but
13132 ## do set a variable so people can do so. Do it in a subshell
13133 ## to capture any diagnostics in invoking pkg-config.
13134 XFT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "xft >= 0.13.0") 2>&1`
13135
13136 fi
13137
13138
13139
13140 else
13141 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13142 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13143 fi
13144 fi
13145
13146 if test $succeeded = yes; then
13147 :
13148 else
13149 HAVE_XFT=no
13150 fi
13151
13152 ## Because xftfont.c uses XRenderQueryExtension, we also
13153 ## need to link to -lXrender.
13154 HAVE_XRENDER=no
13155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
13156 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
13157 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
13158 $as_echo_n "(cached) " >&6
13159 else
13160 ac_check_lib_save_LIBS=$LIBS
13161 LIBS="-lXrender $LIBS"
13162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13163 /* end confdefs.h. */
13164
13165 /* Override any GCC internal prototype to avoid an error.
13166 Use char because int might match the return type of a GCC
13167 builtin and then its argument prototype would still apply. */
13168 #ifdef __cplusplus
13169 extern "C"
13170 #endif
13171 char XRenderQueryExtension ();
13172 int
13173 main ()
13174 {
13175 return XRenderQueryExtension ();
13176 ;
13177 return 0;
13178 }
13179 _ACEOF
13180 if ac_fn_c_try_link "$LINENO"; then :
13181 ac_cv_lib_Xrender_XRenderQueryExtension=yes
13182 else
13183 ac_cv_lib_Xrender_XRenderQueryExtension=no
13184 fi
13185 rm -f core conftest.err conftest.$ac_objext \
13186 conftest$ac_exeext conftest.$ac_ext
13187 LIBS=$ac_check_lib_save_LIBS
13188 fi
13189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
13190 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
13191 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
13192 HAVE_XRENDER=yes
13193 fi
13194
13195 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
13196 OLD_CPPFLAGS="$CPPFLAGS"
13197 OLD_CFLAGS="$CFLAGS"
13198 OLD_LIBS="$LIBS"
13199 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
13200 CFLAGS="$CFLAGS $XFT_CFLAGS"
13201 XFT_LIBS="-lXrender $XFT_LIBS"
13202 LIBS="$XFT_LIBS $LIBS"
13203 ac_fn_c_check_header_compile "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "#include <X11/X.h>
13204 "
13205 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
13206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
13207 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
13208 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
13209 $as_echo_n "(cached) " >&6
13210 else
13211 ac_check_lib_save_LIBS=$LIBS
13212 LIBS="-lXft $XFT_LIBS $LIBS"
13213 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13214 /* end confdefs.h. */
13215
13216 /* Override any GCC internal prototype to avoid an error.
13217 Use char because int might match the return type of a GCC
13218 builtin and then its argument prototype would still apply. */
13219 #ifdef __cplusplus
13220 extern "C"
13221 #endif
13222 char XftFontOpen ();
13223 int
13224 main ()
13225 {
13226 return XftFontOpen ();
13227 ;
13228 return 0;
13229 }
13230 _ACEOF
13231 if ac_fn_c_try_link "$LINENO"; then :
13232 ac_cv_lib_Xft_XftFontOpen=yes
13233 else
13234 ac_cv_lib_Xft_XftFontOpen=no
13235 fi
13236 rm -f core conftest.err conftest.$ac_objext \
13237 conftest$ac_exeext conftest.$ac_ext
13238 LIBS=$ac_check_lib_save_LIBS
13239 fi
13240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
13241 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
13242 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
13243 HAVE_XFT=yes
13244 fi
13245
13246 fi
13247
13248
13249
13250 if test "${HAVE_XFT}" = "yes"; then
13251
13252 $as_echo "#define HAVE_XFT 1" >>confdefs.h
13253
13254
13255 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
13256 else
13257 CPPFLAGS="$OLD_CPPFLAGS"
13258 CFLAGS="$OLD_CFLAGS"
13259 LIBS="$OLD_LIBS"
13260 fi # "${HAVE_XFT}" = "yes"
13261 fi # "$HAVE_XFT" != no
13262 fi # "x${with_xft}" != "xno"
13263
13264 ## We used to allow building with FreeType and without Xft.
13265 ## However, the ftx font backend driver is not in good shape.
13266 if test "$HAVE_XFT" != "yes"; then
13267 HAVE_XFT=no
13268 HAVE_FREETYPE=no
13269 else
13270
13271 succeeded=no
13272
13273 if test "$PKG_CONFIG" = "no" ; then
13274 HAVE_FREETYPE=no
13275 else
13276 PKG_CONFIG_MIN_VERSION=0.9.0
13277 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
13279 $as_echo_n "checking for freetype2... " >&6; }
13280
13281 if "$PKG_CONFIG" --exists "freetype2" 2>&5 &&
13282 FREETYPE_CFLAGS=`"$PKG_CONFIG" --cflags "freetype2" 2>&5` &&
13283 FREETYPE_LIBS=`"$PKG_CONFIG" --libs "freetype2" 2>&5`; then
13284 edit_cflags="
13285 s,///*,/,g
13286 s/^/ /
13287 s/ -I/ $isystem/g
13288 s/^ //
13289 "
13290 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
13291 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
13292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
13293 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
13294 succeeded=yes
13295 else
13296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13297 $as_echo "no" >&6; }
13298 FREETYPE_CFLAGS=""
13299 FREETYPE_LIBS=""
13300 ## If we have a custom action on failure, don't print errors, but
13301 ## do set a variable so people can do so. Do it in a subshell
13302 ## to capture any diagnostics in invoking pkg-config.
13303 FREETYPE_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "freetype2") 2>&1`
13304
13305 fi
13306
13307
13308
13309 else
13310 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13311 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13312 fi
13313 fi
13314
13315 if test $succeeded = yes; then
13316 HAVE_FREETYPE=yes
13317 else
13318 HAVE_FREETYPE=no
13319 fi
13320
13321
13322 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
13323 fi
13324
13325 HAVE_LIBOTF=no
13326 if test "${HAVE_FREETYPE}" = "yes"; then
13327
13328 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
13329
13330 if test "${with_libotf}" != "no"; then
13331
13332 succeeded=no
13333
13334 if test "$PKG_CONFIG" = "no" ; then
13335 HAVE_LIBOTF=no
13336 else
13337 PKG_CONFIG_MIN_VERSION=0.9.0
13338 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
13340 $as_echo_n "checking for libotf... " >&6; }
13341
13342 if "$PKG_CONFIG" --exists "libotf" 2>&5 &&
13343 LIBOTF_CFLAGS=`"$PKG_CONFIG" --cflags "libotf" 2>&5` &&
13344 LIBOTF_LIBS=`"$PKG_CONFIG" --libs "libotf" 2>&5`; then
13345 edit_cflags="
13346 s,///*,/,g
13347 s/^/ /
13348 s/ -I/ $isystem/g
13349 s/^ //
13350 "
13351 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
13352 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
13353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
13354 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
13355 succeeded=yes
13356 else
13357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13358 $as_echo "no" >&6; }
13359 LIBOTF_CFLAGS=""
13360 LIBOTF_LIBS=""
13361 ## If we have a custom action on failure, don't print errors, but
13362 ## do set a variable so people can do so. Do it in a subshell
13363 ## to capture any diagnostics in invoking pkg-config.
13364 LIBOTF_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libotf") 2>&1`
13365
13366 fi
13367
13368
13369
13370 else
13371 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13372 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13373 fi
13374 fi
13375
13376 if test $succeeded = yes; then
13377 HAVE_LIBOTF=yes
13378 else
13379 HAVE_LIBOTF=no
13380 fi
13381
13382 if test "$HAVE_LIBOTF" = "yes"; then
13383
13384 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
13385
13386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
13387 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
13388 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
13389 $as_echo_n "(cached) " >&6
13390 else
13391 ac_check_lib_save_LIBS=$LIBS
13392 LIBS="-lotf $LIBS"
13393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13394 /* end confdefs.h. */
13395
13396 /* Override any GCC internal prototype to avoid an error.
13397 Use char because int might match the return type of a GCC
13398 builtin and then its argument prototype would still apply. */
13399 #ifdef __cplusplus
13400 extern "C"
13401 #endif
13402 char OTF_get_variation_glyphs ();
13403 int
13404 main ()
13405 {
13406 return OTF_get_variation_glyphs ();
13407 ;
13408 return 0;
13409 }
13410 _ACEOF
13411 if ac_fn_c_try_link "$LINENO"; then :
13412 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
13413 else
13414 ac_cv_lib_otf_OTF_get_variation_glyphs=no
13415 fi
13416 rm -f core conftest.err conftest.$ac_objext \
13417 conftest$ac_exeext conftest.$ac_ext
13418 LIBS=$ac_check_lib_save_LIBS
13419 fi
13420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
13421 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
13422 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
13423 HAVE_OTF_GET_VARIATION_GLYPHS=yes
13424 else
13425 HAVE_OTF_GET_VARIATION_GLYPHS=no
13426 fi
13427
13428 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
13429
13430 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
13431
13432 fi
13433 fi
13434 fi
13435 fi
13436
13437 HAVE_M17N_FLT=no
13438 if test "${HAVE_LIBOTF}" = yes; then
13439 if test "${with_m17n_flt}" != "no"; then
13440
13441 succeeded=no
13442
13443 if test "$PKG_CONFIG" = "no" ; then
13444 HAVE_M17N_FLT=no
13445 else
13446 PKG_CONFIG_MIN_VERSION=0.9.0
13447 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
13449 $as_echo_n "checking for m17n-flt... " >&6; }
13450
13451 if "$PKG_CONFIG" --exists "m17n-flt" 2>&5 &&
13452 M17N_FLT_CFLAGS=`"$PKG_CONFIG" --cflags "m17n-flt" 2>&5` &&
13453 M17N_FLT_LIBS=`"$PKG_CONFIG" --libs "m17n-flt" 2>&5`; then
13454 edit_cflags="
13455 s,///*,/,g
13456 s/^/ /
13457 s/ -I/ $isystem/g
13458 s/^ //
13459 "
13460 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
13461 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
13462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
13463 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
13464 succeeded=yes
13465 else
13466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13467 $as_echo "no" >&6; }
13468 M17N_FLT_CFLAGS=""
13469 M17N_FLT_LIBS=""
13470 ## If we have a custom action on failure, don't print errors, but
13471 ## do set a variable so people can do so. Do it in a subshell
13472 ## to capture any diagnostics in invoking pkg-config.
13473 M17N_FLT_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "m17n-flt") 2>&1`
13474
13475 fi
13476
13477
13478
13479 else
13480 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13481 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13482 fi
13483 fi
13484
13485 if test $succeeded = yes; then
13486 HAVE_M17N_FLT=yes
13487 else
13488 HAVE_M17N_FLT=no
13489 fi
13490
13491 if test "$HAVE_M17N_FLT" = "yes"; then
13492
13493 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
13494
13495 fi
13496 fi
13497 fi
13498 else
13499 HAVE_XFT=no
13500 HAVE_FREETYPE=no
13501 HAVE_LIBOTF=no
13502 HAVE_M17N_FLT=no
13503 fi
13504
13505 ### End of font-backend (under X11) section.
13506
13507
13508
13509
13510
13511
13512
13513
13514
13515
13516 ### Use -lXpm if available, unless `--with-xpm=no'.
13517 ### mingw32 doesn't use -lXpm, since it loads the library dynamically.
13518 HAVE_XPM=no
13519 LIBXPM=
13520 if test "${HAVE_W32}" = "yes" && test "${opsys}" = "cygwin"; then
13521 if test "${with_xpm}" != "no"; then
13522 SAVE_CPPFLAGS="$CPPFLAGS"
13523 SAVE_LDFLAGS="$LDFLAGS"
13524 CPPFLAGS="$CPPFLAGS -I/usr/include/noX"
13525 LDFLAGS="$LDFLAGS -L/usr/lib/noX"
13526 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13527 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToImage in -lXpm" >&5
13529 $as_echo_n "checking for XpmReadFileToImage in -lXpm... " >&6; }
13530 if test "${ac_cv_lib_Xpm_XpmReadFileToImage+set}" = set; then :
13531 $as_echo_n "(cached) " >&6
13532 else
13533 ac_check_lib_save_LIBS=$LIBS
13534 LIBS="-lXpm $LIBS"
13535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13536 /* end confdefs.h. */
13537
13538 /* Override any GCC internal prototype to avoid an error.
13539 Use char because int might match the return type of a GCC
13540 builtin and then its argument prototype would still apply. */
13541 #ifdef __cplusplus
13542 extern "C"
13543 #endif
13544 char XpmReadFileToImage ();
13545 int
13546 main ()
13547 {
13548 return XpmReadFileToImage ();
13549 ;
13550 return 0;
13551 }
13552 _ACEOF
13553 if ac_fn_c_try_link "$LINENO"; then :
13554 ac_cv_lib_Xpm_XpmReadFileToImage=yes
13555 else
13556 ac_cv_lib_Xpm_XpmReadFileToImage=no
13557 fi
13558 rm -f core conftest.err conftest.$ac_objext \
13559 conftest$ac_exeext conftest.$ac_ext
13560 LIBS=$ac_check_lib_save_LIBS
13561 fi
13562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToImage" >&5
13563 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToImage" >&6; }
13564 if test "x$ac_cv_lib_Xpm_XpmReadFileToImage" = x""yes; then :
13565 HAVE_XPM=yes
13566 fi
13567
13568 fi
13569
13570
13571 if test "${HAVE_XPM}" = "yes"; then
13572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13573 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13575 /* end confdefs.h. */
13576 #include "X11/xpm.h"
13577 #ifndef XpmReturnAllocPixels
13578 no_return_alloc_pixels
13579 #endif
13580
13581 _ACEOF
13582 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13583 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13584 HAVE_XPM=no
13585 else
13586 HAVE_XPM=yes
13587 fi
13588 rm -f conftest*
13589
13590
13591 if test "${HAVE_XPM}" = "yes"; then
13592 REAL_CPPFLAGS="$REAL_CPPFLAGS -I/usr/include/noX"
13593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13594 $as_echo "yes" >&6; }
13595 else
13596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13597 $as_echo "no" >&6; }
13598 CPPFLAGS="$SAVE_CPPFLAGS"
13599 LDFLAGS="$SAVE_LDFLAGS"
13600 fi
13601 fi
13602 fi
13603
13604 if test "${HAVE_XPM}" = "yes"; then
13605
13606 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13607
13608 LIBXPM=-lXpm
13609 fi
13610 fi
13611
13612 if test "${HAVE_X11}" = "yes"; then
13613 if test "${with_xpm}" != "no"; then
13614 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
13615 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13616 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
13617 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
13618 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
13619 $as_echo_n "(cached) " >&6
13620 else
13621 ac_check_lib_save_LIBS=$LIBS
13622 LIBS="-lXpm -lX11 $LIBS"
13623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13624 /* end confdefs.h. */
13625
13626 /* Override any GCC internal prototype to avoid an error.
13627 Use char because int might match the return type of a GCC
13628 builtin and then its argument prototype would still apply. */
13629 #ifdef __cplusplus
13630 extern "C"
13631 #endif
13632 char XpmReadFileToPixmap ();
13633 int
13634 main ()
13635 {
13636 return XpmReadFileToPixmap ();
13637 ;
13638 return 0;
13639 }
13640 _ACEOF
13641 if ac_fn_c_try_link "$LINENO"; then :
13642 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
13643 else
13644 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
13645 fi
13646 rm -f core conftest.err conftest.$ac_objext \
13647 conftest$ac_exeext conftest.$ac_ext
13648 LIBS=$ac_check_lib_save_LIBS
13649 fi
13650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
13651 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
13652 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
13653 HAVE_XPM=yes
13654 fi
13655
13656 fi
13657
13658
13659 if test "${HAVE_XPM}" = "yes"; then
13660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
13661 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
13662 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13663 /* end confdefs.h. */
13664 #include "X11/xpm.h"
13665 #ifndef XpmReturnAllocPixels
13666 no_return_alloc_pixels
13667 #endif
13668
13669 _ACEOF
13670 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13671 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
13672 HAVE_XPM=no
13673 else
13674 HAVE_XPM=yes
13675 fi
13676 rm -f conftest*
13677
13678
13679 if test "${HAVE_XPM}" = "yes"; then
13680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13681 $as_echo "yes" >&6; }
13682 else
13683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13684 $as_echo "no" >&6; }
13685 fi
13686 fi
13687 fi
13688
13689 if test "${HAVE_XPM}" = "yes"; then
13690
13691 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13692
13693 LIBXPM=-lXpm
13694 fi
13695 fi
13696
13697 ### FIXME: Perhaps regroup to minimize code duplication due to MinGW's
13698 ### slightly different requirements wrt image libraries (it doesn't
13699 ### use -lXpm because it loads the xpm shared library dynamically at
13700 ### run time).
13701 if test "${opsys}" = "mingw32"; then
13702 if test "${with_xpm}" != "no"; then
13703 ac_fn_c_check_header_compile "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "
13704 #define FOR_MSW 1
13705 "
13706 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
13707 HAVE_XPM=yes
13708 else
13709 HAVE_XPM=no
13710 fi
13711
13712
13713 fi
13714
13715 if test "${HAVE_XPM}" = "yes"; then
13716
13717 $as_echo "#define HAVE_XPM 1" >>confdefs.h
13718
13719 fi
13720 fi
13721
13722
13723
13724 ### Use -ljpeg if available, unless `--with-jpeg=no'.
13725 ### mingw32 doesn't use -ljpeg, since it loads the library dynamically.
13726 HAVE_JPEG=no
13727 LIBJPEG=
13728 if test "${opsys}" = "mingw32"; then
13729 if test "${with_jpeg}" != "no"; then
13730 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13731 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13732 HAVE_JPEG=yes
13733 else
13734 HAVE_JPEG=no
13735 fi
13736
13737
13738 fi
13739 if test "${HAVE_JPEG}" = "yes"; then
13740 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13741
13742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13743 /* end confdefs.h. */
13744 #include <jpeglib.h>
13745 version=JPEG_LIB_VERSION
13746
13747 _ACEOF
13748 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13749 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13750 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13751
13752 else
13753 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13754 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13755 HAVE_JPEG=no
13756 fi
13757 rm -f conftest*
13758
13759 fi
13760 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13761 if test "${with_jpeg}" != "no"; then
13762 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13763 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13765 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13766 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13767 $as_echo_n "(cached) " >&6
13768 else
13769 ac_check_lib_save_LIBS=$LIBS
13770 LIBS="-ljpeg $LIBS"
13771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13772 /* end confdefs.h. */
13773
13774 /* Override any GCC internal prototype to avoid an error.
13775 Use char because int might match the return type of a GCC
13776 builtin and then its argument prototype would still apply. */
13777 #ifdef __cplusplus
13778 extern "C"
13779 #endif
13780 char jpeg_destroy_compress ();
13781 int
13782 main ()
13783 {
13784 return jpeg_destroy_compress ();
13785 ;
13786 return 0;
13787 }
13788 _ACEOF
13789 if ac_fn_c_try_link "$LINENO"; then :
13790 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13791 else
13792 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13793 fi
13794 rm -f core conftest.err conftest.$ac_objext \
13795 conftest$ac_exeext conftest.$ac_ext
13796 LIBS=$ac_check_lib_save_LIBS
13797 fi
13798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13799 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13800 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13801 HAVE_JPEG=yes
13802 fi
13803
13804 fi
13805
13806
13807 fi
13808
13809 if test "${HAVE_JPEG}" = "yes"; then
13810 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13811
13812 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13813 /* end confdefs.h. */
13814 #include <jpeglib.h>
13815 version=JPEG_LIB_VERSION
13816
13817 _ACEOF
13818 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13819 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13820 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13821
13822 else
13823 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13824 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13825 HAVE_JPEG=no
13826 fi
13827 rm -f conftest*
13828
13829 fi
13830 if test "${HAVE_JPEG}" = "yes"; then
13831 LIBJPEG=-ljpeg
13832 fi
13833 fi
13834
13835
13836 ### Use -lpng if available, unless `--with-png=no'.
13837 ### mingw32 doesn't use -lpng, since it loads the library dynamically.
13838 HAVE_PNG=no
13839 LIBPNG=
13840 if test "${opsys}" = "mingw32"; then
13841 if test "${with_png}" != "no"; then
13842 ac_fn_c_check_header_mongrel "$LINENO" "png.h" "ac_cv_header_png_h" "$ac_includes_default"
13843 if test "x$ac_cv_header_png_h" = x""yes; then :
13844 HAVE_PNG=yes
13845 else
13846 HAVE_PNG=no
13847 fi
13848
13849
13850 fi
13851 if test "${HAVE_PNG}" = "yes"; then
13852
13853 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13854
13855
13856 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13857 # include <libpng/png.h>
13858 #else
13859 # include <png.h>
13860 #endif
13861
13862 "
13863 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13864
13865 else
13866
13867 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13868
13869 fi
13870
13871 fi
13872 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
13873 if test "${with_png}" != "no"; then
13874 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13875 # in /usr/include/libpng.
13876 for ac_header in png.h libpng/png.h
13877 do :
13878 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13879 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13880 eval as_val=\$$as_ac_Header
13881 if test "x$as_val" = x""yes; then :
13882 cat >>confdefs.h <<_ACEOF
13883 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13884 _ACEOF
13885 break
13886 fi
13887
13888 done
13889
13890 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13892 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13893 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13894 $as_echo_n "(cached) " >&6
13895 else
13896 ac_check_lib_save_LIBS=$LIBS
13897 LIBS="-lpng -lz -lm $LIBS"
13898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13899 /* end confdefs.h. */
13900
13901 /* Override any GCC internal prototype to avoid an error.
13902 Use char because int might match the return type of a GCC
13903 builtin and then its argument prototype would still apply. */
13904 #ifdef __cplusplus
13905 extern "C"
13906 #endif
13907 char png_get_channels ();
13908 int
13909 main ()
13910 {
13911 return png_get_channels ();
13912 ;
13913 return 0;
13914 }
13915 _ACEOF
13916 if ac_fn_c_try_link "$LINENO"; then :
13917 ac_cv_lib_png_png_get_channels=yes
13918 else
13919 ac_cv_lib_png_png_get_channels=no
13920 fi
13921 rm -f core conftest.err conftest.$ac_objext \
13922 conftest$ac_exeext conftest.$ac_ext
13923 LIBS=$ac_check_lib_save_LIBS
13924 fi
13925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13926 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13927 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13928 HAVE_PNG=yes
13929 fi
13930
13931 fi
13932 fi
13933
13934 if test "${HAVE_PNG}" = "yes"; then
13935
13936 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13937
13938 LIBPNG="-lpng -lz -lm"
13939
13940 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
13941 # include <libpng/png.h>
13942 #else
13943 # include <png.h>
13944 #endif
13945
13946 "
13947 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
13948
13949 else
13950
13951 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
13952
13953 fi
13954
13955 fi
13956 fi
13957
13958
13959 HAVE_ZLIB=no
13960 LIBZ=
13961 if test "${with_zlib}" != "no"; then
13962 OLIBS=$LIBS
13963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing inflateEnd" >&5
13964 $as_echo_n "checking for library containing inflateEnd... " >&6; }
13965 if test "${ac_cv_search_inflateEnd+set}" = set; then :
13966 $as_echo_n "(cached) " >&6
13967 else
13968 ac_func_search_save_LIBS=$LIBS
13969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13970 /* end confdefs.h. */
13971
13972 /* Override any GCC internal prototype to avoid an error.
13973 Use char because int might match the return type of a GCC
13974 builtin and then its argument prototype would still apply. */
13975 #ifdef __cplusplus
13976 extern "C"
13977 #endif
13978 char inflateEnd ();
13979 int
13980 main ()
13981 {
13982 return inflateEnd ();
13983 ;
13984 return 0;
13985 }
13986 _ACEOF
13987 for ac_lib in '' z; do
13988 if test -z "$ac_lib"; then
13989 ac_res="none required"
13990 else
13991 ac_res=-l$ac_lib
13992 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
13993 fi
13994 if ac_fn_c_try_link "$LINENO"; then :
13995 ac_cv_search_inflateEnd=$ac_res
13996 fi
13997 rm -f core conftest.err conftest.$ac_objext \
13998 conftest$ac_exeext
13999 if test "${ac_cv_search_inflateEnd+set}" = set; then :
14000 break
14001 fi
14002 done
14003 if test "${ac_cv_search_inflateEnd+set}" = set; then :
14004
14005 else
14006 ac_cv_search_inflateEnd=no
14007 fi
14008 rm conftest.$ac_ext
14009 LIBS=$ac_func_search_save_LIBS
14010 fi
14011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_inflateEnd" >&5
14012 $as_echo "$ac_cv_search_inflateEnd" >&6; }
14013 ac_res=$ac_cv_search_inflateEnd
14014 if test "$ac_res" != no; then :
14015 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14016 HAVE_ZLIB=yes
14017 fi
14018
14019 LIBS=$OLIBS
14020 case $ac_cv_search_inflateEnd in
14021 -*) LIBZ=$ac_cv_search_inflateEnd ;;
14022 esac
14023 fi
14024 if test "${HAVE_ZLIB}" = "yes"; then
14025
14026 $as_echo "#define HAVE_ZLIB 1" >>confdefs.h
14027
14028 ### mingw32 doesn't use -lz, since it loads the library dynamically.
14029 if test "${opsys}" = "mingw32"; then
14030 LIBZ=
14031 fi
14032 fi
14033
14034
14035
14036 ### Use -ltiff if available, unless `--with-tiff=no'.
14037 ### mingw32 doesn't use -ltiff, since it loads the library dynamically.
14038 HAVE_TIFF=no
14039 LIBTIFF=
14040 if test "${opsys}" = "mingw32"; then
14041 if test "${with_tiff}" != "no"; then
14042 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
14043 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
14044 HAVE_TIFF=yes
14045 else
14046 HAVE_TIFF=no
14047 fi
14048
14049
14050 fi
14051 if test "${HAVE_TIFF}" = "yes"; then
14052
14053 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
14054
14055 fi
14056 elif test "${HAVE_X11}" = "yes" || test "${HAVE_W32}" = "yes"; then
14057 if test "${with_tiff}" != "no"; then
14058 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
14059 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
14060 tifflibs="-lz -lm"
14061 # At least one tiff package requires the jpeg library.
14062 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
14063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
14064 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
14065 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
14066 $as_echo_n "(cached) " >&6
14067 else
14068 ac_check_lib_save_LIBS=$LIBS
14069 LIBS="-ltiff $tifflibs $LIBS"
14070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14071 /* end confdefs.h. */
14072
14073 /* Override any GCC internal prototype to avoid an error.
14074 Use char because int might match the return type of a GCC
14075 builtin and then its argument prototype would still apply. */
14076 #ifdef __cplusplus
14077 extern "C"
14078 #endif
14079 char TIFFGetVersion ();
14080 int
14081 main ()
14082 {
14083 return TIFFGetVersion ();
14084 ;
14085 return 0;
14086 }
14087 _ACEOF
14088 if ac_fn_c_try_link "$LINENO"; then :
14089 ac_cv_lib_tiff_TIFFGetVersion=yes
14090 else
14091 ac_cv_lib_tiff_TIFFGetVersion=no
14092 fi
14093 rm -f core conftest.err conftest.$ac_objext \
14094 conftest$ac_exeext conftest.$ac_ext
14095 LIBS=$ac_check_lib_save_LIBS
14096 fi
14097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
14098 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
14099 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
14100 HAVE_TIFF=yes
14101 fi
14102
14103 fi
14104
14105
14106 fi
14107
14108 if test "${HAVE_TIFF}" = "yes"; then
14109
14110 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
14111
14112 LIBTIFF=-ltiff
14113 fi
14114 fi
14115
14116
14117 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
14118 ### mingw32 doesn't use -lgif/-lungif, since it loads the library dynamically.
14119 HAVE_GIF=no
14120 LIBGIF=
14121 if test "${opsys}" = "mingw32"; then
14122 if test "${with_gif}" != "no"; then
14123 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14124 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14125 HAVE_GIF=yes
14126 else
14127 HAVE_GIF=no
14128 fi
14129
14130
14131 fi
14132 if test "${HAVE_GIF}" = "yes"; then
14133
14134 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14135
14136 fi
14137 elif test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no" \
14138 || test "${HAVE_W32}" = "yes"; then
14139 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
14140 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
14141 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
14142 # Earlier versions can crash Emacs, but version 5.0 removes EGifPutExtensionLast.
14143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GifMakeMapObject in -lgif" >&5
14144 $as_echo_n "checking for GifMakeMapObject in -lgif... " >&6; }
14145 if test "${ac_cv_lib_gif_GifMakeMapObject+set}" = set; then :
14146 $as_echo_n "(cached) " >&6
14147 else
14148 ac_check_lib_save_LIBS=$LIBS
14149 LIBS="-lgif $LIBS"
14150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14151 /* end confdefs.h. */
14152
14153 /* Override any GCC internal prototype to avoid an error.
14154 Use char because int might match the return type of a GCC
14155 builtin and then its argument prototype would still apply. */
14156 #ifdef __cplusplus
14157 extern "C"
14158 #endif
14159 char GifMakeMapObject ();
14160 int
14161 main ()
14162 {
14163 return GifMakeMapObject ();
14164 ;
14165 return 0;
14166 }
14167 _ACEOF
14168 if ac_fn_c_try_link "$LINENO"; then :
14169 ac_cv_lib_gif_GifMakeMapObject=yes
14170 else
14171 ac_cv_lib_gif_GifMakeMapObject=no
14172 fi
14173 rm -f core conftest.err conftest.$ac_objext \
14174 conftest$ac_exeext conftest.$ac_ext
14175 LIBS=$ac_check_lib_save_LIBS
14176 fi
14177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_GifMakeMapObject" >&5
14178 $as_echo "$ac_cv_lib_gif_GifMakeMapObject" >&6; }
14179 if test "x$ac_cv_lib_gif_GifMakeMapObject" = x""yes; then :
14180 HAVE_GIF=yes
14181 else
14182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
14183 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
14184 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
14185 $as_echo_n "(cached) " >&6
14186 else
14187 ac_check_lib_save_LIBS=$LIBS
14188 LIBS="-lgif $LIBS"
14189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14190 /* end confdefs.h. */
14191
14192 /* Override any GCC internal prototype to avoid an error.
14193 Use char because int might match the return type of a GCC
14194 builtin and then its argument prototype would still apply. */
14195 #ifdef __cplusplus
14196 extern "C"
14197 #endif
14198 char EGifPutExtensionLast ();
14199 int
14200 main ()
14201 {
14202 return EGifPutExtensionLast ();
14203 ;
14204 return 0;
14205 }
14206 _ACEOF
14207 if ac_fn_c_try_link "$LINENO"; then :
14208 ac_cv_lib_gif_EGifPutExtensionLast=yes
14209 else
14210 ac_cv_lib_gif_EGifPutExtensionLast=no
14211 fi
14212 rm -f core conftest.err conftest.$ac_objext \
14213 conftest$ac_exeext conftest.$ac_ext
14214 LIBS=$ac_check_lib_save_LIBS
14215 fi
14216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
14217 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
14218 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
14219 HAVE_GIF=yes
14220 else
14221 HAVE_GIF=maybe
14222 fi
14223
14224 fi
14225
14226 fi
14227
14228
14229
14230 if test "$HAVE_GIF" = yes; then
14231 LIBGIF=-lgif
14232 elif test "$HAVE_GIF" = maybe; then
14233 # If gif_lib.h but no libgif, try libungif.
14234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
14235 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
14236 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
14237 $as_echo_n "(cached) " >&6
14238 else
14239 ac_check_lib_save_LIBS=$LIBS
14240 LIBS="-lungif $LIBS"
14241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14242 /* end confdefs.h. */
14243
14244 /* Override any GCC internal prototype to avoid an error.
14245 Use char because int might match the return type of a GCC
14246 builtin and then its argument prototype would still apply. */
14247 #ifdef __cplusplus
14248 extern "C"
14249 #endif
14250 char EGifPutExtensionLast ();
14251 int
14252 main ()
14253 {
14254 return EGifPutExtensionLast ();
14255 ;
14256 return 0;
14257 }
14258 _ACEOF
14259 if ac_fn_c_try_link "$LINENO"; then :
14260 ac_cv_lib_ungif_EGifPutExtensionLast=yes
14261 else
14262 ac_cv_lib_ungif_EGifPutExtensionLast=no
14263 fi
14264 rm -f core conftest.err conftest.$ac_objext \
14265 conftest$ac_exeext conftest.$ac_ext
14266 LIBS=$ac_check_lib_save_LIBS
14267 fi
14268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
14269 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
14270 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
14271 HAVE_GIF=yes
14272 else
14273 HAVE_GIF=no
14274 fi
14275
14276 test "$HAVE_GIF" = yes && LIBGIF=-lungif
14277 fi
14278
14279 if test "${HAVE_GIF}" = "yes"; then
14280
14281 $as_echo "#define HAVE_GIF 1" >>confdefs.h
14282
14283 fi
14284 fi
14285
14286
14287 if test "${HAVE_X11}" = "yes"; then
14288 MISSING=""
14289 WITH_NO=""
14290 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
14291 MISSING="libXpm" && WITH_NO="--with-xpm=no"
14292 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
14293 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
14294 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
14295 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
14296 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
14297 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
14298 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
14299 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
14300
14301 if test "X${MISSING}" != X; then
14302 as_fn_error "The following required libraries were not found:
14303 $MISSING
14304 Maybe some development libraries/packages are missing?
14305 If you don't want to link with them give
14306 $WITH_NO
14307 as options to configure" "$LINENO" 5
14308 fi
14309 fi
14310
14311 ### Use -lgpm if available, unless `--with-gpm=no'.
14312 HAVE_GPM=no
14313 LIBGPM=
14314 if test "${with_gpm}" != "no"; then
14315 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
14316 if test "x$ac_cv_header_gpm_h" = x""yes; then :
14317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
14318 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
14319 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
14320 $as_echo_n "(cached) " >&6
14321 else
14322 ac_check_lib_save_LIBS=$LIBS
14323 LIBS="-lgpm $LIBS"
14324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14325 /* end confdefs.h. */
14326
14327 /* Override any GCC internal prototype to avoid an error.
14328 Use char because int might match the return type of a GCC
14329 builtin and then its argument prototype would still apply. */
14330 #ifdef __cplusplus
14331 extern "C"
14332 #endif
14333 char Gpm_Open ();
14334 int
14335 main ()
14336 {
14337 return Gpm_Open ();
14338 ;
14339 return 0;
14340 }
14341 _ACEOF
14342 if ac_fn_c_try_link "$LINENO"; then :
14343 ac_cv_lib_gpm_Gpm_Open=yes
14344 else
14345 ac_cv_lib_gpm_Gpm_Open=no
14346 fi
14347 rm -f core conftest.err conftest.$ac_objext \
14348 conftest$ac_exeext conftest.$ac_ext
14349 LIBS=$ac_check_lib_save_LIBS
14350 fi
14351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
14352 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
14353 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
14354 HAVE_GPM=yes
14355 fi
14356
14357 fi
14358
14359
14360
14361 if test "${HAVE_GPM}" = "yes"; then
14362
14363 $as_echo "#define HAVE_GPM 1" >>confdefs.h
14364
14365 LIBGPM=-lgpm
14366 fi
14367 fi
14368
14369
14370
14371
14372
14373
14374 GNUSTEP_CFLAGS=
14375 ### Use NeXTstep API to implement GUI.
14376 if test "${HAVE_NS}" = "yes"; then
14377
14378 $as_echo "#define HAVE_NS 1" >>confdefs.h
14379
14380 if test "${NS_IMPL_COCOA}" = "yes"; then
14381
14382 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
14383
14384 fi
14385 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
14386
14387 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
14388
14389 # See also .m.o rule in Makefile.in */
14390 # FIXME: are all these flags really needed? Document here why. */
14391 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
14392 ## Extra CFLAGS applied to src/*.m files.
14393 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"
14394 fi
14395 OTHER_FILES=ns-app
14396 fi
14397
14398 ### Use session management (-lSM -lICE) if available
14399 HAVE_X_SM=no
14400 LIBXSM=
14401 if test "${HAVE_X11}" = "yes"; then
14402 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
14403 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
14404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
14405 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
14406 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
14407 $as_echo_n "(cached) " >&6
14408 else
14409 ac_check_lib_save_LIBS=$LIBS
14410 LIBS="-lSM -lICE $LIBS"
14411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14412 /* end confdefs.h. */
14413
14414 /* Override any GCC internal prototype to avoid an error.
14415 Use char because int might match the return type of a GCC
14416 builtin and then its argument prototype would still apply. */
14417 #ifdef __cplusplus
14418 extern "C"
14419 #endif
14420 char SmcOpenConnection ();
14421 int
14422 main ()
14423 {
14424 return SmcOpenConnection ();
14425 ;
14426 return 0;
14427 }
14428 _ACEOF
14429 if ac_fn_c_try_link "$LINENO"; then :
14430 ac_cv_lib_SM_SmcOpenConnection=yes
14431 else
14432 ac_cv_lib_SM_SmcOpenConnection=no
14433 fi
14434 rm -f core conftest.err conftest.$ac_objext \
14435 conftest$ac_exeext conftest.$ac_ext
14436 LIBS=$ac_check_lib_save_LIBS
14437 fi
14438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
14439 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
14440 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
14441 HAVE_X_SM=yes
14442 fi
14443
14444 fi
14445
14446
14447
14448 if test "${HAVE_X_SM}" = "yes"; then
14449
14450 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
14451
14452 LIBXSM="-lSM -lICE"
14453 case "$LIBS" in
14454 *-lSM*) ;;
14455 *) LIBS="$LIBXSM $LIBS" ;;
14456 esac
14457 fi
14458 fi
14459
14460
14461 ### Use XRandr (-lXrandr) if available
14462 HAVE_XRANDR=no
14463 if test "${HAVE_X11}" = "yes"; then
14464 XRANDR_REQUIRED=1.2.2
14465 XRANDR_MODULES="xrandr >= $XRANDR_REQUIRED"
14466
14467 succeeded=no
14468
14469 if test "$PKG_CONFIG" = "no" ; then
14470 HAVE_XRANDR=no
14471 else
14472 PKG_CONFIG_MIN_VERSION=0.9.0
14473 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XRANDR_MODULES" >&5
14475 $as_echo_n "checking for $XRANDR_MODULES... " >&6; }
14476
14477 if "$PKG_CONFIG" --exists "$XRANDR_MODULES" 2>&5 &&
14478 XRANDR_CFLAGS=`"$PKG_CONFIG" --cflags "$XRANDR_MODULES" 2>&5` &&
14479 XRANDR_LIBS=`"$PKG_CONFIG" --libs "$XRANDR_MODULES" 2>&5`; then
14480 edit_cflags="
14481 s,///*,/,g
14482 s/^/ /
14483 s/ -I/ $isystem/g
14484 s/^ //
14485 "
14486 XRANDR_CFLAGS=`$as_echo "$XRANDR_CFLAGS" | sed -e "$edit_cflags"`
14487 XRANDR_LIBS=`$as_echo "$XRANDR_LIBS" | sed -e 's,///*,/,g'`
14488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&5
14489 $as_echo "yes CFLAGS='$XRANDR_CFLAGS' LIBS='$XRANDR_LIBS'" >&6; }
14490 succeeded=yes
14491 else
14492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14493 $as_echo "no" >&6; }
14494 XRANDR_CFLAGS=""
14495 XRANDR_LIBS=""
14496 ## If we have a custom action on failure, don't print errors, but
14497 ## do set a variable so people can do so. Do it in a subshell
14498 ## to capture any diagnostics in invoking pkg-config.
14499 XRANDR_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XRANDR_MODULES") 2>&1`
14500
14501 fi
14502
14503
14504
14505 else
14506 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14507 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14508 fi
14509 fi
14510
14511 if test $succeeded = yes; then
14512 HAVE_XRANDR=yes
14513 else
14514 HAVE_XRANDR=no
14515 fi
14516
14517 if test $HAVE_XRANDR = no; then
14518 # Test old way in case pkg-config doesn't have it (older machines).
14519 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xrandr.h" "ac_cv_header_X11_extensions_Xrandr_h" "$ac_includes_default"
14520 if test "x$ac_cv_header_X11_extensions_Xrandr_h" = x""yes; then :
14521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRRGetScreenResources in -lXrandr" >&5
14522 $as_echo_n "checking for XRRGetScreenResources in -lXrandr... " >&6; }
14523 if test "${ac_cv_lib_Xrandr_XRRGetScreenResources+set}" = set; then :
14524 $as_echo_n "(cached) " >&6
14525 else
14526 ac_check_lib_save_LIBS=$LIBS
14527 LIBS="-lXrandr $LIBS"
14528 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14529 /* end confdefs.h. */
14530
14531 /* Override any GCC internal prototype to avoid an error.
14532 Use char because int might match the return type of a GCC
14533 builtin and then its argument prototype would still apply. */
14534 #ifdef __cplusplus
14535 extern "C"
14536 #endif
14537 char XRRGetScreenResources ();
14538 int
14539 main ()
14540 {
14541 return XRRGetScreenResources ();
14542 ;
14543 return 0;
14544 }
14545 _ACEOF
14546 if ac_fn_c_try_link "$LINENO"; then :
14547 ac_cv_lib_Xrandr_XRRGetScreenResources=yes
14548 else
14549 ac_cv_lib_Xrandr_XRRGetScreenResources=no
14550 fi
14551 rm -f core conftest.err conftest.$ac_objext \
14552 conftest$ac_exeext conftest.$ac_ext
14553 LIBS=$ac_check_lib_save_LIBS
14554 fi
14555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrandr_XRRGetScreenResources" >&5
14556 $as_echo "$ac_cv_lib_Xrandr_XRRGetScreenResources" >&6; }
14557 if test "x$ac_cv_lib_Xrandr_XRRGetScreenResources" = x""yes; then :
14558 HAVE_XRANDR=yes
14559 fi
14560
14561 fi
14562
14563
14564 if test $HAVE_XRANDR = yes; then
14565 XRANDR_LIBS=-lXrandr
14566
14567 fi
14568 fi
14569 if test $HAVE_XRANDR = yes; then
14570 SAVE_CFLAGS="$CFLAGS"
14571 SAVE_LIBS="$LIBS"
14572 CFLAGS="$XRANDR_CFLAGS $CFLAGS"
14573 LIBS="$XRANDR_LIBS $LIBS"
14574 for ac_func in XRRGetOutputPrimary XRRGetScreenResourcesCurrent
14575 do :
14576 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14577 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14578 eval as_val=\$$as_ac_var
14579 if test "x$as_val" = x""yes; then :
14580 cat >>confdefs.h <<_ACEOF
14581 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14582 _ACEOF
14583
14584 fi
14585 done
14586
14587 CFLAGS="$SAVE_CFLAGS"
14588 LIBS="$SAVE_LIBS"
14589
14590
14591 $as_echo "#define HAVE_XRANDR 1" >>confdefs.h
14592
14593 fi
14594 fi
14595
14596 ### Use Xinerama (-lXinerama) if available
14597 HAVE_XINERAMA=no
14598 if test "${HAVE_X11}" = "yes"; then
14599 XINERAMA_REQUIRED=1.0.2
14600 XINERAMA_MODULES="xinerama >= $XINERAMA_REQUIRED"
14601
14602 succeeded=no
14603
14604 if test "$PKG_CONFIG" = "no" ; then
14605 HAVE_XINERAMA=no
14606 else
14607 PKG_CONFIG_MIN_VERSION=0.9.0
14608 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $XINERAMA_MODULES" >&5
14610 $as_echo_n "checking for $XINERAMA_MODULES... " >&6; }
14611
14612 if "$PKG_CONFIG" --exists "$XINERAMA_MODULES" 2>&5 &&
14613 XINERAMA_CFLAGS=`"$PKG_CONFIG" --cflags "$XINERAMA_MODULES" 2>&5` &&
14614 XINERAMA_LIBS=`"$PKG_CONFIG" --libs "$XINERAMA_MODULES" 2>&5`; then
14615 edit_cflags="
14616 s,///*,/,g
14617 s/^/ /
14618 s/ -I/ $isystem/g
14619 s/^ //
14620 "
14621 XINERAMA_CFLAGS=`$as_echo "$XINERAMA_CFLAGS" | sed -e "$edit_cflags"`
14622 XINERAMA_LIBS=`$as_echo "$XINERAMA_LIBS" | sed -e 's,///*,/,g'`
14623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&5
14624 $as_echo "yes CFLAGS='$XINERAMA_CFLAGS' LIBS='$XINERAMA_LIBS'" >&6; }
14625 succeeded=yes
14626 else
14627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14628 $as_echo "no" >&6; }
14629 XINERAMA_CFLAGS=""
14630 XINERAMA_LIBS=""
14631 ## If we have a custom action on failure, don't print errors, but
14632 ## do set a variable so people can do so. Do it in a subshell
14633 ## to capture any diagnostics in invoking pkg-config.
14634 XINERAMA_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "$XINERAMA_MODULES") 2>&1`
14635
14636 fi
14637
14638
14639
14640 else
14641 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14642 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14643 fi
14644 fi
14645
14646 if test $succeeded = yes; then
14647 HAVE_XINERAMA=yes
14648 else
14649 HAVE_XINERAMA=no
14650 fi
14651
14652 if test $HAVE_XINERAMA = no; then
14653 # Test old way in case pkg-config doesn't have it (older machines).
14654 ac_fn_c_check_header_mongrel "$LINENO" "X11/extensions/Xinerama.h" "ac_cv_header_X11_extensions_Xinerama_h" "$ac_includes_default"
14655 if test "x$ac_cv_header_X11_extensions_Xinerama_h" = x""yes; then :
14656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XineramaQueryExtension in -lXinerama" >&5
14657 $as_echo_n "checking for XineramaQueryExtension in -lXinerama... " >&6; }
14658 if test "${ac_cv_lib_Xinerama_XineramaQueryExtension+set}" = set; then :
14659 $as_echo_n "(cached) " >&6
14660 else
14661 ac_check_lib_save_LIBS=$LIBS
14662 LIBS="-lXinerama $LIBS"
14663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14664 /* end confdefs.h. */
14665
14666 /* Override any GCC internal prototype to avoid an error.
14667 Use char because int might match the return type of a GCC
14668 builtin and then its argument prototype would still apply. */
14669 #ifdef __cplusplus
14670 extern "C"
14671 #endif
14672 char XineramaQueryExtension ();
14673 int
14674 main ()
14675 {
14676 return XineramaQueryExtension ();
14677 ;
14678 return 0;
14679 }
14680 _ACEOF
14681 if ac_fn_c_try_link "$LINENO"; then :
14682 ac_cv_lib_Xinerama_XineramaQueryExtension=yes
14683 else
14684 ac_cv_lib_Xinerama_XineramaQueryExtension=no
14685 fi
14686 rm -f core conftest.err conftest.$ac_objext \
14687 conftest$ac_exeext conftest.$ac_ext
14688 LIBS=$ac_check_lib_save_LIBS
14689 fi
14690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xinerama_XineramaQueryExtension" >&5
14691 $as_echo "$ac_cv_lib_Xinerama_XineramaQueryExtension" >&6; }
14692 if test "x$ac_cv_lib_Xinerama_XineramaQueryExtension" = x""yes; then :
14693 HAVE_XINERAMA=yes
14694 fi
14695
14696 fi
14697
14698
14699 if test $HAVE_XINERAMA = yes; then
14700 XINERAMA_LIBS=-lXinerama
14701
14702 fi
14703 fi
14704 if test $HAVE_XINERAMA = yes; then
14705
14706 $as_echo "#define HAVE_XINERAMA 1" >>confdefs.h
14707
14708 fi
14709 fi
14710
14711
14712 ### Use libxml (-lxml2) if available
14713 ### mingw32 doesn't use -lxml2, since it loads the library dynamically.
14714 HAVE_LIBXML2=no
14715 if test "${with_xml2}" != "no"; then
14716 ### I'm not sure what the version number should be, so I just guessed.
14717
14718 succeeded=no
14719
14720 if test "$PKG_CONFIG" = "no" ; then
14721 HAVE_LIBXML2=no
14722 else
14723 PKG_CONFIG_MIN_VERSION=0.9.0
14724 if "$PKG_CONFIG" --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
14725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
14726 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
14727
14728 if "$PKG_CONFIG" --exists "libxml-2.0 > 2.6.17" 2>&5 &&
14729 LIBXML2_CFLAGS=`"$PKG_CONFIG" --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
14730 LIBXML2_LIBS=`"$PKG_CONFIG" --libs "libxml-2.0 > 2.6.17" 2>&5`; then
14731 edit_cflags="
14732 s,///*,/,g
14733 s/^/ /
14734 s/ -I/ $isystem/g
14735 s/^ //
14736 "
14737 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
14738 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
14739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
14740 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
14741 succeeded=yes
14742 else
14743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14744 $as_echo "no" >&6; }
14745 LIBXML2_CFLAGS=""
14746 LIBXML2_LIBS=""
14747 ## If we have a custom action on failure, don't print errors, but
14748 ## do set a variable so people can do so. Do it in a subshell
14749 ## to capture any diagnostics in invoking pkg-config.
14750 LIBXML2_PKG_ERRORS=`("$PKG_CONFIG" --print-errors "libxml-2.0 > 2.6.17") 2>&1`
14751
14752 fi
14753
14754
14755
14756 else
14757 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
14758 echo "*** See http://www.freedesktop.org/software/pkgconfig"
14759 fi
14760 fi
14761
14762 if test $succeeded = yes; then
14763 HAVE_LIBXML2=yes
14764 else
14765 HAVE_LIBXML2=no
14766 fi
14767
14768 # Built-in libxml2 on OS X 10.8 lacks libxml-2.0.pc.
14769 if test "${HAVE_LIBXML2}" != "yes" -a "$opsys" = "darwin"; then
14770 SAVE_CPPFLAGS="$CPPFLAGS"
14771 CPPFLAGS="$CPPFLAGS -I/usr/include/libxml2"
14772 ac_fn_c_check_header_mongrel "$LINENO" "libxml/HTMLparser.h" "ac_cv_header_libxml_HTMLparser_h" "$ac_includes_default"
14773 if test "x$ac_cv_header_libxml_HTMLparser_h" = x""yes; then :
14774 ac_fn_c_check_decl "$LINENO" "HTML_PARSE_RECOVER" "ac_cv_have_decl_HTML_PARSE_RECOVER" "#include <libxml/HTMLparser.h>
14775 "
14776 if test "x$ac_cv_have_decl_HTML_PARSE_RECOVER" = x""yes; then :
14777 HAVE_LIBXML2=yes
14778 fi
14779
14780 fi
14781
14782
14783 CPPFLAGS="$SAVE_CPPFLAGS"
14784 if test "${HAVE_LIBXML2}" = "yes"; then
14785 LIBXML2_LIBS="-lxml2"
14786 LIBXML2_CFLAGS="-I/usr/include/libxml2"
14787 fi
14788 fi
14789 if test "${HAVE_LIBXML2}" = "yes"; then
14790 if test "${opsys}" != "mingw32"; then
14791 LIBS="$LIBXML2_LIBS $LIBS"
14792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
14793 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
14794 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
14795 $as_echo_n "(cached) " >&6
14796 else
14797 ac_check_lib_save_LIBS=$LIBS
14798 LIBS="-lxml2 $LIBS"
14799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14800 /* end confdefs.h. */
14801
14802 /* Override any GCC internal prototype to avoid an error.
14803 Use char because int might match the return type of a GCC
14804 builtin and then its argument prototype would still apply. */
14805 #ifdef __cplusplus
14806 extern "C"
14807 #endif
14808 char htmlReadMemory ();
14809 int
14810 main ()
14811 {
14812 return htmlReadMemory ();
14813 ;
14814 return 0;
14815 }
14816 _ACEOF
14817 if ac_fn_c_try_link "$LINENO"; then :
14818 ac_cv_lib_xml2_htmlReadMemory=yes
14819 else
14820 ac_cv_lib_xml2_htmlReadMemory=no
14821 fi
14822 rm -f core conftest.err conftest.$ac_objext \
14823 conftest$ac_exeext conftest.$ac_ext
14824 LIBS=$ac_check_lib_save_LIBS
14825 fi
14826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
14827 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
14828 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
14829 HAVE_LIBXML2=yes
14830 else
14831 HAVE_LIBXML2=no
14832 fi
14833
14834 else
14835 LIBXML2_LIBS=""
14836 fi
14837 if test "${HAVE_LIBXML2}" = "yes"; then
14838
14839 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
14840
14841 else
14842 LIBXML2_LIBS=""
14843 LIBXML2_CFLAGS=""
14844 fi
14845 fi
14846 fi
14847
14848
14849
14850 # If netdb.h doesn't declare h_errno, we must declare it by hand.
14851 # On MinGW, that is provided by nt/inc/sys/socket.h and w32.c.
14852 if test "${opsys}" = "mingw32"; then
14853 emacs_cv_netdb_declares_h_errno=yes
14854 fi
14855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
14856 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
14857 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
14858 $as_echo_n "(cached) " >&6
14859 else
14860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14861 /* end confdefs.h. */
14862 #include <netdb.h>
14863 int
14864 main ()
14865 {
14866 return h_errno;
14867 ;
14868 return 0;
14869 }
14870 _ACEOF
14871 if ac_fn_c_try_link "$LINENO"; then :
14872 emacs_cv_netdb_declares_h_errno=yes
14873 else
14874 emacs_cv_netdb_declares_h_errno=no
14875 fi
14876 rm -f core conftest.err conftest.$ac_objext \
14877 conftest$ac_exeext conftest.$ac_ext
14878 fi
14879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
14880 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
14881 if test $emacs_cv_netdb_declares_h_errno = yes; then
14882
14883 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
14884
14885 fi
14886
14887 # sqrt and other floating-point functions such as fmod and frexp
14888 # are found in -lm on most systems, but mingw32 doesn't use -lm.
14889 if test "${opsys}" != "mingw32"; then
14890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
14891 $as_echo_n "checking for sqrt in -lm... " >&6; }
14892 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
14893 $as_echo_n "(cached) " >&6
14894 else
14895 ac_check_lib_save_LIBS=$LIBS
14896 LIBS="-lm $LIBS"
14897 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14898 /* end confdefs.h. */
14899
14900 /* Override any GCC internal prototype to avoid an error.
14901 Use char because int might match the return type of a GCC
14902 builtin and then its argument prototype would still apply. */
14903 #ifdef __cplusplus
14904 extern "C"
14905 #endif
14906 char sqrt ();
14907 int
14908 main ()
14909 {
14910 return sqrt ();
14911 ;
14912 return 0;
14913 }
14914 _ACEOF
14915 if ac_fn_c_try_link "$LINENO"; then :
14916 ac_cv_lib_m_sqrt=yes
14917 else
14918 ac_cv_lib_m_sqrt=no
14919 fi
14920 rm -f core conftest.err conftest.$ac_objext \
14921 conftest$ac_exeext conftest.$ac_ext
14922 LIBS=$ac_check_lib_save_LIBS
14923 fi
14924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
14925 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
14926 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
14927 cat >>confdefs.h <<_ACEOF
14928 #define HAVE_LIBM 1
14929 _ACEOF
14930
14931 LIBS="-lm $LIBS"
14932
14933 fi
14934
14935 fi
14936
14937 # Check for mail-locking functions in a "mail" library. Probably this should
14938 # have the same check as for liblockfile below.
14939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
14940 $as_echo_n "checking for maillock in -lmail... " >&6; }
14941 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
14942 $as_echo_n "(cached) " >&6
14943 else
14944 ac_check_lib_save_LIBS=$LIBS
14945 LIBS="-lmail $LIBS"
14946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14947 /* end confdefs.h. */
14948
14949 /* Override any GCC internal prototype to avoid an error.
14950 Use char because int might match the return type of a GCC
14951 builtin and then its argument prototype would still apply. */
14952 #ifdef __cplusplus
14953 extern "C"
14954 #endif
14955 char maillock ();
14956 int
14957 main ()
14958 {
14959 return maillock ();
14960 ;
14961 return 0;
14962 }
14963 _ACEOF
14964 if ac_fn_c_try_link "$LINENO"; then :
14965 ac_cv_lib_mail_maillock=yes
14966 else
14967 ac_cv_lib_mail_maillock=no
14968 fi
14969 rm -f core conftest.err conftest.$ac_objext \
14970 conftest$ac_exeext conftest.$ac_ext
14971 LIBS=$ac_check_lib_save_LIBS
14972 fi
14973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
14974 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
14975 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
14976 have_mail=yes
14977 else
14978 have_mail=no
14979 fi
14980
14981 if test $have_mail = yes; then
14982 LIBS_MAIL=-lmail
14983 LIBS="$LIBS_MAIL $LIBS"
14984
14985 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
14986
14987 else
14988 LIBS_MAIL=
14989 fi
14990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
14991 $as_echo_n "checking for maillock in -llockfile... " >&6; }
14992 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
14993 $as_echo_n "(cached) " >&6
14994 else
14995 ac_check_lib_save_LIBS=$LIBS
14996 LIBS="-llockfile $LIBS"
14997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14998 /* end confdefs.h. */
14999
15000 /* Override any GCC internal prototype to avoid an error.
15001 Use char because int might match the return type of a GCC
15002 builtin and then its argument prototype would still apply. */
15003 #ifdef __cplusplus
15004 extern "C"
15005 #endif
15006 char maillock ();
15007 int
15008 main ()
15009 {
15010 return maillock ();
15011 ;
15012 return 0;
15013 }
15014 _ACEOF
15015 if ac_fn_c_try_link "$LINENO"; then :
15016 ac_cv_lib_lockfile_maillock=yes
15017 else
15018 ac_cv_lib_lockfile_maillock=no
15019 fi
15020 rm -f core conftest.err conftest.$ac_objext \
15021 conftest$ac_exeext conftest.$ac_ext
15022 LIBS=$ac_check_lib_save_LIBS
15023 fi
15024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
15025 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
15026 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
15027 have_lockfile=yes
15028 else
15029 have_lockfile=no
15030 fi
15031
15032 if test $have_lockfile = yes; then
15033 LIBS_MAIL=-llockfile
15034 LIBS="$LIBS_MAIL $LIBS"
15035
15036 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
15037
15038 else
15039 # If we have the shared liblockfile, assume we must use it for mail
15040 # locking (e.g. Debian). If we couldn't link against liblockfile
15041 # (no liblockfile.a installed), ensure that we don't need to.
15042 # Extract the first word of "liblockfile.so", so it can be a program name with args.
15043 set dummy liblockfile.so; ac_word=$2
15044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15045 $as_echo_n "checking for $ac_word... " >&6; }
15046 if test "${ac_cv_prog_liblockfile+set}" = set; then :
15047 $as_echo_n "(cached) " >&6
15048 else
15049 if test -n "$liblockfile"; then
15050 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
15051 else
15052 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15053 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
15054 for as_dir in $as_dummy
15055 do
15056 IFS=$as_save_IFS
15057 test -z "$as_dir" && as_dir=.
15058 for ac_exec_ext in '' $ac_executable_extensions; do
15059 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15060 ac_cv_prog_liblockfile="yes"
15061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15062 break 2
15063 fi
15064 done
15065 done
15066 IFS=$as_save_IFS
15067
15068 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
15069 fi
15070 fi
15071 liblockfile=$ac_cv_prog_liblockfile
15072 if test -n "$liblockfile"; then
15073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
15074 $as_echo "$liblockfile" >&6; }
15075 else
15076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15077 $as_echo "no" >&6; }
15078 fi
15079
15080
15081 if test $ac_cv_prog_liblockfile = yes; then
15082 as_fn_error "Shared liblockfile found but can't link against it.
15083 This probably means that movemail could lose mail.
15084 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
15085 fi
15086 fi
15087
15088
15089
15090
15091
15092 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
15093 ## interlock access to the mail spool. The alternative is a lock file named
15094 ## /usr/spool/mail/$USER.lock.
15095 mail_lock=no
15096 case "$opsys" in
15097 aix4-2) mail_lock="lockf" ;;
15098
15099 gnu|freebsd|dragonfly|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
15100
15101 ## On GNU/Linux systems, both methods are used by various mail programs.
15102 ## I assume most people are using newer mailers that have heard of flock.
15103 ## Change this if you need to.
15104 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
15105 ## configure gets the right answers, and that means *NOT* using flock.
15106 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
15107 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
15108 ## Debian maintainer hasn't provided a clean fix for Emacs.
15109 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
15110 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
15111 ## correct logic. -- fx
15112 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
15113 ## liblockfile is a Free Software replacement for libmail, used on
15114 ## Debian systems and elsewhere. -rfr.
15115 gnu-*)
15116 mail_lock="flock"
15117 if test $have_mail = yes || test $have_lockfile = yes; then
15118 test $ac_cv_header_maillock_h = yes && mail_lock=no
15119 fi
15120 ;;
15121
15122 mingw32)
15123 mail_lock="none-needed" ;;
15124 esac
15125
15126 BLESSMAIL_TARGET=
15127 case "$mail_lock" in
15128 flock)
15129 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
15130 ;;
15131
15132 lockf)
15133 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
15134 ;;
15135
15136 none-needed) ;;
15137
15138 *) BLESSMAIL_TARGET="need-blessmail" ;;
15139 esac
15140
15141
15142
15143 for ac_func in accept4 gethostname \
15144 getrusage get_current_dir_name \
15145 lrand48 \
15146 select getpagesize setlocale \
15147 getrlimit setrlimit shutdown getaddrinfo \
15148 strsignal setitimer \
15149 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
15150 gai_strerror getline getdelim sync \
15151 difftime posix_memalign \
15152 getpwent endpwent getgrent endgrent \
15153 touchlock \
15154 cfmakeraw cfsetspeed copysign __executable_start log2
15155 do :
15156 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15157 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15158 eval as_val=\$$as_ac_var
15159 if test "x$as_val" = x""yes; then :
15160 cat >>confdefs.h <<_ACEOF
15161 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15162 _ACEOF
15163
15164 fi
15165 done
15166
15167
15168 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
15169 ## has a broken `rint' in some library versions including math library
15170 ## version number A.09.05.
15171 ## You can fix the math library by installing patch number PHSS_4630.
15172 ## But we can fix it more reliably for Emacs by just not using rint.
15173 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
15174 case $opsys in
15175 hpux*) : ;;
15176 *) for ac_func in random rint
15177 do :
15178 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15179 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15180 eval as_val=\$$as_ac_var
15181 if test "x$as_val" = x""yes; then :
15182 cat >>confdefs.h <<_ACEOF
15183 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15184 _ACEOF
15185
15186 fi
15187 done
15188 ;;
15189 esac
15190
15191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
15192 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
15193 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
15194 $as_echo_n "(cached) " >&6
15195 else
15196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15197 /* end confdefs.h. */
15198
15199 int
15200 main ()
15201 {
15202 __builtin_unwind_init ();
15203 ;
15204 return 0;
15205 }
15206 _ACEOF
15207 if ac_fn_c_try_link "$LINENO"; then :
15208 emacs_cv_func___builtin_unwind_init=yes
15209 else
15210 emacs_cv_func___builtin_unwind_init=no
15211 fi
15212 rm -f core conftest.err conftest.$ac_objext \
15213 conftest$ac_exeext conftest.$ac_ext
15214 fi
15215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
15216 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
15217 if test $emacs_cv_func___builtin_unwind_init = yes; then
15218
15219 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
15220
15221 fi
15222
15223
15224
15225
15226
15227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
15228 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
15229 if test "${ac_cv_sys_largefile_source+set}" = set; then :
15230 $as_echo_n "(cached) " >&6
15231 else
15232 while :; do
15233 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15234 /* end confdefs.h. */
15235 #include <sys/types.h> /* for off_t */
15236 #include <stdio.h>
15237 int
15238 main ()
15239 {
15240 int (*fp) (FILE *, off_t, int) = fseeko;
15241 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15242 ;
15243 return 0;
15244 }
15245 _ACEOF
15246 if ac_fn_c_try_link "$LINENO"; then :
15247 ac_cv_sys_largefile_source=no; break
15248 fi
15249 rm -f core conftest.err conftest.$ac_objext \
15250 conftest$ac_exeext conftest.$ac_ext
15251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15252 /* end confdefs.h. */
15253 #define _LARGEFILE_SOURCE 1
15254 #include <sys/types.h> /* for off_t */
15255 #include <stdio.h>
15256 int
15257 main ()
15258 {
15259 int (*fp) (FILE *, off_t, int) = fseeko;
15260 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
15261 ;
15262 return 0;
15263 }
15264 _ACEOF
15265 if ac_fn_c_try_link "$LINENO"; then :
15266 ac_cv_sys_largefile_source=1; break
15267 fi
15268 rm -f core conftest.err conftest.$ac_objext \
15269 conftest$ac_exeext conftest.$ac_ext
15270 ac_cv_sys_largefile_source=unknown
15271 break
15272 done
15273 fi
15274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
15275 $as_echo "$ac_cv_sys_largefile_source" >&6; }
15276 case $ac_cv_sys_largefile_source in #(
15277 no | unknown) ;;
15278 *)
15279 cat >>confdefs.h <<_ACEOF
15280 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
15281 _ACEOF
15282 ;;
15283 esac
15284 rm -rf conftest*
15285
15286 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
15287 # in glibc 2.1.3, but that breaks too many other things.
15288 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
15289 if test $ac_cv_sys_largefile_source != unknown; then
15290
15291 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
15292
15293 fi
15294
15295
15296 # UNIX98 PTYs.
15297 for ac_func in grantpt
15298 do :
15299 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
15300 if test "x$ac_cv_func_grantpt" = x""yes; then :
15301 cat >>confdefs.h <<_ACEOF
15302 #define HAVE_GRANTPT 1
15303 _ACEOF
15304
15305 fi
15306 done
15307
15308
15309 # PTY-related GNU extensions.
15310 for ac_func in getpt posix_openpt
15311 do :
15312 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15313 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15314 eval as_val=\$$as_ac_var
15315 if test "x$as_val" = x""yes; then :
15316 cat >>confdefs.h <<_ACEOF
15317 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15318 _ACEOF
15319
15320 fi
15321 done
15322
15323
15324 # Check this now, so that we will NOT find the above functions in ncurses.
15325 # That is because we have not set up to link ncurses in lib-src.
15326 # It's better to believe a function is not available
15327 # than to expect to find it in ncurses.
15328 # Also we need tputs and friends to be able to build at all.
15329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
15330 $as_echo_n "checking for library containing tputs... " >&6; }
15331 # Run a test program that contains a call to tputs, a call that is
15332 # never executed. This tests whether a pre-'main' dynamic linker
15333 # works with the library. It's too much trouble to actually call
15334 # tputs in the test program, due to portability hassles. When
15335 # cross-compiling, assume the test program will run if it links.
15336
15337 if test "${opsys}" = "mingw32"; then
15338 msg='none required'
15339 else
15340 # Maybe curses should be tried earlier?
15341 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
15342 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
15343 OLIBS=$LIBS
15344 if test -z "$tputs_library"; then
15345 LIBS_TERMCAP=
15346 msg='none required'
15347 else
15348 LIBS_TERMCAP=-l$tputs_library
15349 msg=$LIBS_TERMCAP
15350 LIBS="$LIBS_TERMCAP $LIBS"
15351 fi
15352 if test "$cross_compiling" = yes; then :
15353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15354 /* end confdefs.h. */
15355
15356 extern void tputs (const char *, int, int (*)(int));
15357 int main (int argc, char **argv)
15358 {
15359 if (argc == 10000)
15360 tputs (argv[0], 0, 0);
15361 return 0;
15362 }
15363
15364 _ACEOF
15365 if ac_fn_c_try_link "$LINENO"; then :
15366
15367 else
15368 msg=no
15369 fi
15370 rm -f core conftest.err conftest.$ac_objext \
15371 conftest$ac_exeext conftest.$ac_ext
15372 else
15373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15374 /* end confdefs.h. */
15375
15376 extern void tputs (const char *, int, int (*)(int));
15377 int main (int argc, char **argv)
15378 {
15379 if (argc == 10000)
15380 tputs (argv[0], 0, 0);
15381 return 0;
15382 }
15383
15384 _ACEOF
15385 if ac_fn_c_try_run "$LINENO"; then :
15386
15387 else
15388 msg=no
15389 fi
15390 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15391 conftest.$ac_objext conftest.beam conftest.$ac_ext
15392 fi
15393
15394 LIBS=$OLIBS
15395 if test "X$msg" != Xno; then
15396 break
15397 fi
15398 done
15399 fi
15400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
15401 $as_echo "$msg" >&6; }
15402 if test "X$msg" = Xno; then
15403 as_fn_error "The required function \`tputs' was not found in any library.
15404 The following libraries were tried (in order):
15405 libtinfo, libncurses, libterminfo, libtermcap, libcurses
15406 Please try installing whichever of these libraries is most appropriate
15407 for your system, together with its header files.
15408 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
15409 fi
15410
15411 ## Use termcap instead of terminfo?
15412 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
15413 TERMINFO=yes
15414 ## FIXME? In the cases below where we unconditionally set
15415 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
15416 ## if that was found above to have tputs.
15417 ## Should we use the gnu* logic everywhere?
15418 case "$opsys" in
15419 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
15420 ## The ncurses library has been moved out of the System framework in
15421 ## Mac OS X 10.2. So if configure detects it, set the command-line
15422 ## option to use it.
15423 darwin) LIBS_TERMCAP="-lncurses" ;;
15424
15425 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
15426
15427 freebsd)
15428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
15429 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
15430 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
15431 $as_echo_n "(cached) " >&6
15432 else
15433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15434 /* end confdefs.h. */
15435 #include <osreldate.h>
15436 int
15437 main ()
15438 {
15439 #if __FreeBSD_version < 400000
15440 fail;
15441 #endif
15442
15443 ;
15444 return 0;
15445 }
15446 _ACEOF
15447 if ac_fn_c_try_link "$LINENO"; then :
15448 emacs_cv_freebsd_terminfo=yes
15449 else
15450 emacs_cv_freebsd_terminfo=no
15451 fi
15452 rm -f core conftest.err conftest.$ac_objext \
15453 conftest$ac_exeext conftest.$ac_ext
15454 fi
15455
15456
15457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
15458 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
15459
15460 if test $emacs_cv_freebsd_terminfo = yes; then
15461 LIBS_TERMCAP="-lncurses"
15462 else
15463 TERMINFO=no
15464 LIBS_TERMCAP="-ltermcap"
15465 fi
15466 ;;
15467
15468 mingw32)
15469 TERMINFO=no
15470 LIBS_TERMCAP=
15471 ;;
15472
15473 netbsd)
15474 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
15475 TERMINFO=no
15476 LIBS_TERMCAP="-ltermcap"
15477 fi
15478 ;;
15479
15480 openbsd | dragonfly) LIBS_TERMCAP="-lncurses" ;;
15481
15482 ## hpux: Make sure we get select from libc rather than from libcurses
15483 ## because libcurses on HPUX 10.10 has a broken version of select.
15484 ## We used to use -lc -lcurses, but this may be cleaner.
15485 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
15486 # set that way, now it uses the default). Isn't this a contradiction?
15487 hpux*) LIBS_TERMCAP="-ltermcap" ;;
15488
15489 esac
15490
15491 TERMCAP_OBJ=tparam.o
15492 if test $TERMINFO = yes; then
15493
15494 $as_echo "#define TERMINFO 1" >>confdefs.h
15495
15496 TERMCAP_OBJ=terminfo.o
15497 fi
15498 if test "X$LIBS_TERMCAP" = "X-lncurses"; then
15499
15500 $as_echo "#define USE_NCURSES 1" >>confdefs.h
15501
15502 fi
15503
15504
15505
15506
15507 # Do we have res_init, for detecting changes in /etc/resolv.conf?
15508 # On Darwin, res_init appears not to be useful: see bug#562 and
15509 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
15510 resolv=no
15511
15512 if test $opsys != darwin; then
15513
15514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15515 /* end confdefs.h. */
15516 #include <netinet/in.h>
15517 #include <arpa/nameser.h>
15518 #include <resolv.h>
15519 int
15520 main ()
15521 {
15522 return res_init();
15523 ;
15524 return 0;
15525 }
15526 _ACEOF
15527 if ac_fn_c_try_link "$LINENO"; then :
15528 have_res_init=yes
15529 else
15530 have_res_init=no
15531 fi
15532 rm -f core conftest.err conftest.$ac_objext \
15533 conftest$ac_exeext conftest.$ac_ext
15534 if test "$have_res_init" = no; then
15535 OLIBS="$LIBS"
15536 LIBS="$LIBS -lresolv"
15537 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
15538 $as_echo_n "checking for res_init with -lresolv... " >&6; }
15539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15540 /* end confdefs.h. */
15541 #include <netinet/in.h>
15542 #include <arpa/nameser.h>
15543 #include <resolv.h>
15544 int
15545 main ()
15546 {
15547 return res_init();
15548 ;
15549 return 0;
15550 }
15551 _ACEOF
15552 if ac_fn_c_try_link "$LINENO"; then :
15553 have_res_init=yes
15554 else
15555 have_res_init=no
15556 fi
15557 rm -f core conftest.err conftest.$ac_objext \
15558 conftest$ac_exeext conftest.$ac_ext
15559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
15560 $as_echo "$have_res_init" >&6; }
15561 if test "$have_res_init" = yes ; then
15562 resolv=yes
15563 fi
15564 LIBS="$OLIBS"
15565 fi
15566
15567 if test "$have_res_init" = yes; then
15568
15569 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
15570
15571 fi
15572 fi
15573 # Do we need the Hesiod library to provide the support routines?
15574 LIBHESIOD=
15575 if test "$with_hesiod" != no ; then
15576 # Don't set $LIBS here -- see comments above. FIXME which comments?
15577 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
15578 if test "x$ac_cv_func_res_send" = x""yes; then :
15579
15580 else
15581 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
15582 if test "x$ac_cv_func___res_send" = x""yes; then :
15583
15584 else
15585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
15586 $as_echo_n "checking for res_send in -lresolv... " >&6; }
15587 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
15588 $as_echo_n "(cached) " >&6
15589 else
15590 ac_check_lib_save_LIBS=$LIBS
15591 LIBS="-lresolv $LIBS"
15592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15593 /* end confdefs.h. */
15594
15595 /* Override any GCC internal prototype to avoid an error.
15596 Use char because int might match the return type of a GCC
15597 builtin and then its argument prototype would still apply. */
15598 #ifdef __cplusplus
15599 extern "C"
15600 #endif
15601 char res_send ();
15602 int
15603 main ()
15604 {
15605 return res_send ();
15606 ;
15607 return 0;
15608 }
15609 _ACEOF
15610 if ac_fn_c_try_link "$LINENO"; then :
15611 ac_cv_lib_resolv_res_send=yes
15612 else
15613 ac_cv_lib_resolv_res_send=no
15614 fi
15615 rm -f core conftest.err conftest.$ac_objext \
15616 conftest$ac_exeext conftest.$ac_ext
15617 LIBS=$ac_check_lib_save_LIBS
15618 fi
15619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
15620 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
15621 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
15622 resolv=yes
15623 else
15624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
15625 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
15626 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
15627 $as_echo_n "(cached) " >&6
15628 else
15629 ac_check_lib_save_LIBS=$LIBS
15630 LIBS="-lresolv $LIBS"
15631 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15632 /* end confdefs.h. */
15633
15634 /* Override any GCC internal prototype to avoid an error.
15635 Use char because int might match the return type of a GCC
15636 builtin and then its argument prototype would still apply. */
15637 #ifdef __cplusplus
15638 extern "C"
15639 #endif
15640 char __res_send ();
15641 int
15642 main ()
15643 {
15644 return __res_send ();
15645 ;
15646 return 0;
15647 }
15648 _ACEOF
15649 if ac_fn_c_try_link "$LINENO"; then :
15650 ac_cv_lib_resolv___res_send=yes
15651 else
15652 ac_cv_lib_resolv___res_send=no
15653 fi
15654 rm -f core conftest.err conftest.$ac_objext \
15655 conftest$ac_exeext conftest.$ac_ext
15656 LIBS=$ac_check_lib_save_LIBS
15657 fi
15658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
15659 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
15660 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
15661 resolv=yes
15662 fi
15663
15664 fi
15665
15666 fi
15667
15668 fi
15669
15670 if test "$resolv" = yes ; then
15671 RESOLVLIB=-lresolv
15672 else
15673 RESOLVLIB=
15674 fi
15675 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
15676 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
15677
15678 else
15679 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
15680 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
15681 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
15682 $as_echo_n "(cached) " >&6
15683 else
15684 ac_check_lib_save_LIBS=$LIBS
15685 LIBS="-lhesiod $RESOLVLIB $LIBS"
15686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15687 /* end confdefs.h. */
15688
15689 /* Override any GCC internal prototype to avoid an error.
15690 Use char because int might match the return type of a GCC
15691 builtin and then its argument prototype would still apply. */
15692 #ifdef __cplusplus
15693 extern "C"
15694 #endif
15695 char hes_getmailhost ();
15696 int
15697 main ()
15698 {
15699 return hes_getmailhost ();
15700 ;
15701 return 0;
15702 }
15703 _ACEOF
15704 if ac_fn_c_try_link "$LINENO"; then :
15705 ac_cv_lib_hesiod_hes_getmailhost=yes
15706 else
15707 ac_cv_lib_hesiod_hes_getmailhost=no
15708 fi
15709 rm -f core conftest.err conftest.$ac_objext \
15710 conftest$ac_exeext conftest.$ac_ext
15711 LIBS=$ac_check_lib_save_LIBS
15712 fi
15713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
15714 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
15715 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
15716 hesiod=yes
15717 else
15718 :
15719 fi
15720
15721 fi
15722
15723
15724 if test x"$hesiod" = xyes; then
15725 LIBHESIOD=-lhesiod
15726 fi
15727 fi
15728
15729
15730 # Do we need libresolv (due to res_init or Hesiod)?
15731 if test "$resolv" = yes && test $opsys != darwin; then
15732 LIBRESOLV=-lresolv
15733 else
15734 LIBRESOLV=
15735 fi
15736
15737
15738 # These tell us which Kerberos-related libraries to use.
15739 COM_ERRLIB=
15740 CRYPTOLIB=
15741 KRB5LIB=
15742 DESLIB=
15743 KRB4LIB=
15744
15745 if test "${with_kerberos}" != no; then
15746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
15747 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
15748 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
15749 $as_echo_n "(cached) " >&6
15750 else
15751 ac_check_lib_save_LIBS=$LIBS
15752 LIBS="-lcom_err $LIBS"
15753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15754 /* end confdefs.h. */
15755
15756 /* Override any GCC internal prototype to avoid an error.
15757 Use char because int might match the return type of a GCC
15758 builtin and then its argument prototype would still apply. */
15759 #ifdef __cplusplus
15760 extern "C"
15761 #endif
15762 char com_err ();
15763 int
15764 main ()
15765 {
15766 return com_err ();
15767 ;
15768 return 0;
15769 }
15770 _ACEOF
15771 if ac_fn_c_try_link "$LINENO"; then :
15772 ac_cv_lib_com_err_com_err=yes
15773 else
15774 ac_cv_lib_com_err_com_err=no
15775 fi
15776 rm -f core conftest.err conftest.$ac_objext \
15777 conftest$ac_exeext conftest.$ac_ext
15778 LIBS=$ac_check_lib_save_LIBS
15779 fi
15780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
15781 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
15782 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
15783 have_com_err=yes
15784 else
15785 have_com_err=no
15786 fi
15787
15788 if test $have_com_err = yes; then
15789 COM_ERRLIB=-lcom_err
15790 LIBS="$COM_ERRLIB $LIBS"
15791 fi
15792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
15793 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
15794 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
15795 $as_echo_n "(cached) " >&6
15796 else
15797 ac_check_lib_save_LIBS=$LIBS
15798 LIBS="-lcrypto $LIBS"
15799 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15800 /* end confdefs.h. */
15801
15802 /* Override any GCC internal prototype to avoid an error.
15803 Use char because int might match the return type of a GCC
15804 builtin and then its argument prototype would still apply. */
15805 #ifdef __cplusplus
15806 extern "C"
15807 #endif
15808 char mit_des_cbc_encrypt ();
15809 int
15810 main ()
15811 {
15812 return mit_des_cbc_encrypt ();
15813 ;
15814 return 0;
15815 }
15816 _ACEOF
15817 if ac_fn_c_try_link "$LINENO"; then :
15818 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
15819 else
15820 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
15821 fi
15822 rm -f core conftest.err conftest.$ac_objext \
15823 conftest$ac_exeext conftest.$ac_ext
15824 LIBS=$ac_check_lib_save_LIBS
15825 fi
15826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
15827 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
15828 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
15829 have_crypto=yes
15830 else
15831 have_crypto=no
15832 fi
15833
15834 if test $have_crypto = yes; then
15835 CRYPTOLIB=-lcrypto
15836 LIBS="$CRYPTOLIB $LIBS"
15837 fi
15838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
15839 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
15840 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
15841 $as_echo_n "(cached) " >&6
15842 else
15843 ac_check_lib_save_LIBS=$LIBS
15844 LIBS="-lk5crypto $LIBS"
15845 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15846 /* end confdefs.h. */
15847
15848 /* Override any GCC internal prototype to avoid an error.
15849 Use char because int might match the return type of a GCC
15850 builtin and then its argument prototype would still apply. */
15851 #ifdef __cplusplus
15852 extern "C"
15853 #endif
15854 char mit_des_cbc_encrypt ();
15855 int
15856 main ()
15857 {
15858 return mit_des_cbc_encrypt ();
15859 ;
15860 return 0;
15861 }
15862 _ACEOF
15863 if ac_fn_c_try_link "$LINENO"; then :
15864 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
15865 else
15866 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
15867 fi
15868 rm -f core conftest.err conftest.$ac_objext \
15869 conftest$ac_exeext conftest.$ac_ext
15870 LIBS=$ac_check_lib_save_LIBS
15871 fi
15872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
15873 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
15874 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
15875 have_k5crypto=yes
15876 else
15877 have_k5crypto=no
15878 fi
15879
15880 if test $have_k5crypto = yes; then
15881 CRYPTOLIB=-lk5crypto
15882 LIBS="$CRYPTOLIB $LIBS"
15883 fi
15884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
15885 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
15886 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
15887 $as_echo_n "(cached) " >&6
15888 else
15889 ac_check_lib_save_LIBS=$LIBS
15890 LIBS="-lkrb5 $LIBS"
15891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15892 /* end confdefs.h. */
15893
15894 /* Override any GCC internal prototype to avoid an error.
15895 Use char because int might match the return type of a GCC
15896 builtin and then its argument prototype would still apply. */
15897 #ifdef __cplusplus
15898 extern "C"
15899 #endif
15900 char krb5_init_context ();
15901 int
15902 main ()
15903 {
15904 return krb5_init_context ();
15905 ;
15906 return 0;
15907 }
15908 _ACEOF
15909 if ac_fn_c_try_link "$LINENO"; then :
15910 ac_cv_lib_krb5_krb5_init_context=yes
15911 else
15912 ac_cv_lib_krb5_krb5_init_context=no
15913 fi
15914 rm -f core conftest.err conftest.$ac_objext \
15915 conftest$ac_exeext conftest.$ac_ext
15916 LIBS=$ac_check_lib_save_LIBS
15917 fi
15918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
15919 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
15920 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
15921 have_krb5=yes
15922 else
15923 have_krb5=no
15924 fi
15925
15926 if test $have_krb5=yes; then
15927 KRB5LIB=-lkrb5
15928 LIBS="$KRB5LIB $LIBS"
15929 fi
15930 if test "${with_kerberos5}" = no; then
15931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
15932 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
15933 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
15934 $as_echo_n "(cached) " >&6
15935 else
15936 ac_check_lib_save_LIBS=$LIBS
15937 LIBS="-ldes425 $LIBS"
15938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15939 /* end confdefs.h. */
15940
15941 /* Override any GCC internal prototype to avoid an error.
15942 Use char because int might match the return type of a GCC
15943 builtin and then its argument prototype would still apply. */
15944 #ifdef __cplusplus
15945 extern "C"
15946 #endif
15947 char des_cbc_encrypt ();
15948 int
15949 main ()
15950 {
15951 return des_cbc_encrypt ();
15952 ;
15953 return 0;
15954 }
15955 _ACEOF
15956 if ac_fn_c_try_link "$LINENO"; then :
15957 ac_cv_lib_des425_des_cbc_encrypt=yes
15958 else
15959 ac_cv_lib_des425_des_cbc_encrypt=no
15960 fi
15961 rm -f core conftest.err conftest.$ac_objext \
15962 conftest$ac_exeext conftest.$ac_ext
15963 LIBS=$ac_check_lib_save_LIBS
15964 fi
15965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
15966 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
15967 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
15968 have_des425=yes
15969 else
15970 have_des425=no
15971 fi
15972
15973 if test $have_des425 = yes; then
15974 DESLIB=-ldes425
15975 LIBS="$DESLIB $LIBS"
15976 else
15977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
15978 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
15979 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
15980 $as_echo_n "(cached) " >&6
15981 else
15982 ac_check_lib_save_LIBS=$LIBS
15983 LIBS="-ldes $LIBS"
15984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15985 /* end confdefs.h. */
15986
15987 /* Override any GCC internal prototype to avoid an error.
15988 Use char because int might match the return type of a GCC
15989 builtin and then its argument prototype would still apply. */
15990 #ifdef __cplusplus
15991 extern "C"
15992 #endif
15993 char des_cbc_encrypt ();
15994 int
15995 main ()
15996 {
15997 return des_cbc_encrypt ();
15998 ;
15999 return 0;
16000 }
16001 _ACEOF
16002 if ac_fn_c_try_link "$LINENO"; then :
16003 ac_cv_lib_des_des_cbc_encrypt=yes
16004 else
16005 ac_cv_lib_des_des_cbc_encrypt=no
16006 fi
16007 rm -f core conftest.err conftest.$ac_objext \
16008 conftest$ac_exeext conftest.$ac_ext
16009 LIBS=$ac_check_lib_save_LIBS
16010 fi
16011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
16012 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
16013 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
16014 have_des=yes
16015 else
16016 have_des=no
16017 fi
16018
16019 if test $have_des = yes; then
16020 DESLIB=-ldes
16021 LIBS="$DESLIB $LIBS"
16022 fi
16023 fi
16024 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
16025 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
16026 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
16027 $as_echo_n "(cached) " >&6
16028 else
16029 ac_check_lib_save_LIBS=$LIBS
16030 LIBS="-lkrb4 $LIBS"
16031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16032 /* end confdefs.h. */
16033
16034 /* Override any GCC internal prototype to avoid an error.
16035 Use char because int might match the return type of a GCC
16036 builtin and then its argument prototype would still apply. */
16037 #ifdef __cplusplus
16038 extern "C"
16039 #endif
16040 char krb_get_cred ();
16041 int
16042 main ()
16043 {
16044 return krb_get_cred ();
16045 ;
16046 return 0;
16047 }
16048 _ACEOF
16049 if ac_fn_c_try_link "$LINENO"; then :
16050 ac_cv_lib_krb4_krb_get_cred=yes
16051 else
16052 ac_cv_lib_krb4_krb_get_cred=no
16053 fi
16054 rm -f core conftest.err conftest.$ac_objext \
16055 conftest$ac_exeext conftest.$ac_ext
16056 LIBS=$ac_check_lib_save_LIBS
16057 fi
16058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
16059 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
16060 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
16061 have_krb4=yes
16062 else
16063 have_krb4=no
16064 fi
16065
16066 if test $have_krb4 = yes; then
16067 KRB4LIB=-lkrb4
16068 LIBS="$KRB4LIB $LIBS"
16069 else
16070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
16071 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
16072 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
16073 $as_echo_n "(cached) " >&6
16074 else
16075 ac_check_lib_save_LIBS=$LIBS
16076 LIBS="-lkrb $LIBS"
16077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16078 /* end confdefs.h. */
16079
16080 /* Override any GCC internal prototype to avoid an error.
16081 Use char because int might match the return type of a GCC
16082 builtin and then its argument prototype would still apply. */
16083 #ifdef __cplusplus
16084 extern "C"
16085 #endif
16086 char krb_get_cred ();
16087 int
16088 main ()
16089 {
16090 return krb_get_cred ();
16091 ;
16092 return 0;
16093 }
16094 _ACEOF
16095 if ac_fn_c_try_link "$LINENO"; then :
16096 ac_cv_lib_krb_krb_get_cred=yes
16097 else
16098 ac_cv_lib_krb_krb_get_cred=no
16099 fi
16100 rm -f core conftest.err conftest.$ac_objext \
16101 conftest$ac_exeext conftest.$ac_ext
16102 LIBS=$ac_check_lib_save_LIBS
16103 fi
16104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
16105 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
16106 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
16107 have_krb=yes
16108 else
16109 have_krb=no
16110 fi
16111
16112 if test $have_krb = yes; then
16113 KRB4LIB=-lkrb
16114 LIBS="$KRB4LIB $LIBS"
16115 fi
16116 fi
16117 fi
16118
16119 if test "${with_kerberos5}" != no; then
16120 for ac_header in krb5.h
16121 do :
16122 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
16123 if test "x$ac_cv_header_krb5_h" = x""yes; then :
16124 cat >>confdefs.h <<_ACEOF
16125 #define HAVE_KRB5_H 1
16126 _ACEOF
16127 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
16128 "
16129 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
16130
16131 cat >>confdefs.h <<_ACEOF
16132 #define HAVE_KRB5_ERROR_TEXT 1
16133 _ACEOF
16134
16135
16136 fi
16137 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
16138 "
16139 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
16140
16141 cat >>confdefs.h <<_ACEOF
16142 #define HAVE_KRB5_ERROR_E_TEXT 1
16143 _ACEOF
16144
16145
16146 fi
16147
16148 fi
16149
16150 done
16151
16152 else
16153 for ac_header in krb.h
16154 do :
16155 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
16156 if test "x$ac_cv_header_krb_h" = x""yes; then :
16157 cat >>confdefs.h <<_ACEOF
16158 #define HAVE_KRB_H 1
16159 _ACEOF
16160
16161 else
16162 for ac_header in kerberosIV/krb.h
16163 do :
16164 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
16165 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
16166 cat >>confdefs.h <<_ACEOF
16167 #define HAVE_KERBEROSIV_KRB_H 1
16168 _ACEOF
16169
16170 else
16171 for ac_header in kerberos/krb.h
16172 do :
16173 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
16174 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
16175 cat >>confdefs.h <<_ACEOF
16176 #define HAVE_KERBEROS_KRB_H 1
16177 _ACEOF
16178
16179 fi
16180
16181 done
16182
16183 fi
16184
16185 done
16186
16187 fi
16188
16189 done
16190
16191 fi
16192 for ac_header in com_err.h
16193 do :
16194 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
16195 if test "x$ac_cv_header_com_err_h" = x""yes; then :
16196 cat >>confdefs.h <<_ACEOF
16197 #define HAVE_COM_ERR_H 1
16198 _ACEOF
16199
16200 fi
16201
16202 done
16203
16204 fi
16205
16206
16207
16208
16209
16210
16211
16212 for ac_header in valgrind/valgrind.h
16213 do :
16214 ac_fn_c_check_header_mongrel "$LINENO" "valgrind/valgrind.h" "ac_cv_header_valgrind_valgrind_h" "$ac_includes_default"
16215 if test "x$ac_cv_header_valgrind_valgrind_h" = x""yes; then :
16216 cat >>confdefs.h <<_ACEOF
16217 #define HAVE_VALGRIND_VALGRIND_H 1
16218 _ACEOF
16219
16220 fi
16221
16222 done
16223
16224
16225
16226
16227
16228 for ac_func in $ac_func_list
16229 do :
16230 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16231 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16232 eval as_val=\$$as_ac_var
16233 if test "x$as_val" = x""yes; then :
16234 cat >>confdefs.h <<_ACEOF
16235 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16236 _ACEOF
16237
16238 fi
16239 done
16240
16241
16242
16243
16244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
16245 $as_echo_n "checking whether localtime caches TZ... " >&6; }
16246 if test "${emacs_cv_localtime_cache+set}" = set; then :
16247 $as_echo_n "(cached) " >&6
16248 else
16249 if test x$ac_cv_func_tzset = xyes; then
16250 if test "$cross_compiling" = yes; then :
16251 # If we have tzset, assume the worst when cross-compiling.
16252 emacs_cv_localtime_cache=yes
16253 else
16254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16255 /* end confdefs.h. */
16256 #include <time.h>
16257 char TZ_GMT0[] = "TZ=GMT0";
16258 char TZ_PST8[] = "TZ=PST8";
16259 main()
16260 {
16261 time_t now = time ((time_t *) 0);
16262 int hour_GMT0, hour_unset;
16263 if (putenv (TZ_GMT0) != 0)
16264 exit (1);
16265 hour_GMT0 = localtime (&now)->tm_hour;
16266 unsetenv("TZ");
16267 hour_unset = localtime (&now)->tm_hour;
16268 if (putenv (TZ_PST8) != 0)
16269 exit (1);
16270 if (localtime (&now)->tm_hour == hour_GMT0)
16271 exit (1);
16272 unsetenv("TZ");
16273 if (localtime (&now)->tm_hour != hour_unset)
16274 exit (1);
16275 exit (0);
16276 }
16277 _ACEOF
16278 if ac_fn_c_try_run "$LINENO"; then :
16279 emacs_cv_localtime_cache=no
16280 else
16281 emacs_cv_localtime_cache=yes
16282 fi
16283 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16284 conftest.$ac_objext conftest.beam conftest.$ac_ext
16285 fi
16286
16287 else
16288 # If we lack tzset, report that localtime does not cache TZ,
16289 # since we can't invalidate the cache if we don't have tzset.
16290 emacs_cv_localtime_cache=no
16291 fi
16292 fi
16293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
16294 $as_echo "$emacs_cv_localtime_cache" >&6; }
16295 if test $emacs_cv_localtime_cache = yes; then
16296
16297 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
16298
16299 fi
16300
16301 ok_so_far=yes
16302 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
16303 if test "x$ac_cv_func_socket" = x""yes; then :
16304
16305 else
16306 ok_so_far=no
16307 fi
16308
16309 if test $ok_so_far = yes; then
16310 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
16311 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
16312
16313 else
16314 ok_so_far=no
16315 fi
16316
16317
16318 fi
16319 if test $ok_so_far = yes; then
16320 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
16321 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
16322
16323 else
16324 ok_so_far=no
16325 fi
16326
16327
16328 fi
16329 if test $ok_so_far = yes; then
16330
16331 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
16332
16333 fi
16334
16335 case $canonical in
16336 *-solaris2.4 | *-solaris2.4.*)
16337 : ${ac_cv_func_vfork_works=no};;
16338 esac
16339
16340 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
16341 if test "x$ac_cv_type_pid_t" = x""yes; then :
16342
16343 else
16344
16345 cat >>confdefs.h <<_ACEOF
16346 #define pid_t int
16347 _ACEOF
16348
16349 fi
16350
16351 for ac_header in vfork.h
16352 do :
16353 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
16354 if test "x$ac_cv_header_vfork_h" = x""yes; then :
16355 cat >>confdefs.h <<_ACEOF
16356 #define HAVE_VFORK_H 1
16357 _ACEOF
16358
16359 fi
16360
16361 done
16362
16363 for ac_func in fork vfork
16364 do :
16365 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16366 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16367 eval as_val=\$$as_ac_var
16368 if test "x$as_val" = x""yes; then :
16369 cat >>confdefs.h <<_ACEOF
16370 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16371 _ACEOF
16372
16373 fi
16374 done
16375
16376 if test "x$ac_cv_func_fork" = xyes; then
16377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
16378 $as_echo_n "checking for working fork... " >&6; }
16379 if test "${ac_cv_func_fork_works+set}" = set; then :
16380 $as_echo_n "(cached) " >&6
16381 else
16382 if test "$cross_compiling" = yes; then :
16383 ac_cv_func_fork_works=cross
16384 else
16385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16386 /* end confdefs.h. */
16387 $ac_includes_default
16388 int
16389 main ()
16390 {
16391
16392 /* By Ruediger Kuhlmann. */
16393 return fork () < 0;
16394
16395 ;
16396 return 0;
16397 }
16398 _ACEOF
16399 if ac_fn_c_try_run "$LINENO"; then :
16400 ac_cv_func_fork_works=yes
16401 else
16402 ac_cv_func_fork_works=no
16403 fi
16404 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16405 conftest.$ac_objext conftest.beam conftest.$ac_ext
16406 fi
16407
16408 fi
16409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
16410 $as_echo "$ac_cv_func_fork_works" >&6; }
16411
16412 else
16413 ac_cv_func_fork_works=$ac_cv_func_fork
16414 fi
16415 if test "x$ac_cv_func_fork_works" = xcross; then
16416 case $host in
16417 *-*-amigaos* | *-*-msdosdjgpp*)
16418 # Override, as these systems have only a dummy fork() stub
16419 ac_cv_func_fork_works=no
16420 ;;
16421 *)
16422 ac_cv_func_fork_works=yes
16423 ;;
16424 esac
16425 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
16426 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
16427 fi
16428 ac_cv_func_vfork_works=$ac_cv_func_vfork
16429 if test "x$ac_cv_func_vfork" = xyes; then
16430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
16431 $as_echo_n "checking for working vfork... " >&6; }
16432 if test "${ac_cv_func_vfork_works+set}" = set; then :
16433 $as_echo_n "(cached) " >&6
16434 else
16435 if test "$cross_compiling" = yes; then :
16436 ac_cv_func_vfork_works=cross
16437 else
16438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16439 /* end confdefs.h. */
16440 /* Thanks to Paul Eggert for this test. */
16441 $ac_includes_default
16442 #include <sys/wait.h>
16443 #ifdef HAVE_VFORK_H
16444 # include <vfork.h>
16445 #endif
16446 /* On some sparc systems, changes by the child to local and incoming
16447 argument registers are propagated back to the parent. The compiler
16448 is told about this with #include <vfork.h>, but some compilers
16449 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
16450 static variable whose address is put into a register that is
16451 clobbered by the vfork. */
16452 static void
16453 #ifdef __cplusplus
16454 sparc_address_test (int arg)
16455 # else
16456 sparc_address_test (arg) int arg;
16457 #endif
16458 {
16459 static pid_t child;
16460 if (!child) {
16461 child = vfork ();
16462 if (child < 0) {
16463 perror ("vfork");
16464 _exit(2);
16465 }
16466 if (!child) {
16467 arg = getpid();
16468 write(-1, "", 0);
16469 _exit (arg);
16470 }
16471 }
16472 }
16473
16474 int
16475 main ()
16476 {
16477 pid_t parent = getpid ();
16478 pid_t child;
16479
16480 sparc_address_test (0);
16481
16482 child = vfork ();
16483
16484 if (child == 0) {
16485 /* Here is another test for sparc vfork register problems. This
16486 test uses lots of local variables, at least as many local
16487 variables as main has allocated so far including compiler
16488 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
16489 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
16490 reuse the register of parent for one of the local variables,
16491 since it will think that parent can't possibly be used any more
16492 in this routine. Assigning to the local variable will thus
16493 munge parent in the parent process. */
16494 pid_t
16495 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
16496 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
16497 /* Convince the compiler that p..p7 are live; otherwise, it might
16498 use the same hardware register for all 8 local variables. */
16499 if (p != p1 || p != p2 || p != p3 || p != p4
16500 || p != p5 || p != p6 || p != p7)
16501 _exit(1);
16502
16503 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
16504 from child file descriptors. If the child closes a descriptor
16505 before it execs or exits, this munges the parent's descriptor
16506 as well. Test for this by closing stdout in the child. */
16507 _exit(close(fileno(stdout)) != 0);
16508 } else {
16509 int status;
16510 struct stat st;
16511
16512 while (wait(&status) != child)
16513 ;
16514 return (
16515 /* Was there some problem with vforking? */
16516 child < 0
16517
16518 /* Did the child fail? (This shouldn't happen.) */
16519 || status
16520
16521 /* Did the vfork/compiler bug occur? */
16522 || parent != getpid()
16523
16524 /* Did the file descriptor bug occur? */
16525 || fstat(fileno(stdout), &st) != 0
16526 );
16527 }
16528 }
16529 _ACEOF
16530 if ac_fn_c_try_run "$LINENO"; then :
16531 ac_cv_func_vfork_works=yes
16532 else
16533 ac_cv_func_vfork_works=no
16534 fi
16535 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16536 conftest.$ac_objext conftest.beam conftest.$ac_ext
16537 fi
16538
16539 fi
16540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
16541 $as_echo "$ac_cv_func_vfork_works" >&6; }
16542
16543 fi;
16544 if test "x$ac_cv_func_fork_works" = xcross; then
16545 ac_cv_func_vfork_works=$ac_cv_func_vfork
16546 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
16547 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
16548 fi
16549
16550 if test "x$ac_cv_func_vfork_works" = xyes; then
16551
16552 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
16553
16554 else
16555
16556 $as_echo "#define vfork fork" >>confdefs.h
16557
16558 fi
16559 if test "x$ac_cv_func_fork_works" = xyes; then
16560
16561 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
16562
16563 fi
16564
16565
16566 for ac_func in snprintf
16567 do :
16568 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
16569 if test "x$ac_cv_func_snprintf" = x""yes; then :
16570 cat >>confdefs.h <<_ACEOF
16571 #define HAVE_SNPRINTF 1
16572 _ACEOF
16573
16574 fi
16575 done
16576
16577
16578 XGSELOBJ=
16579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether GLib is linked in" >&5
16580 $as_echo_n "checking whether GLib is linked in... " >&6; }
16581 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16582 /* end confdefs.h. */
16583 #include <glib.h>
16584
16585 int
16586 main ()
16587 {
16588 g_print ("Hello world");
16589 ;
16590 return 0;
16591 }
16592 _ACEOF
16593 if ac_fn_c_try_link "$LINENO"; then :
16594 links_glib=yes
16595 else
16596 links_glib=no
16597 fi
16598 rm -f core conftest.err conftest.$ac_objext \
16599 conftest$ac_exeext conftest.$ac_ext
16600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $links_glib" >&5
16601 $as_echo "$links_glib" >&6; }
16602 if test "${links_glib}" = "yes"; then
16603
16604 $as_echo "#define HAVE_GLIB 1" >>confdefs.h
16605
16606 if test "$HAVE_NS" = no;then
16607 XGSELOBJ=xgselect.o
16608 fi
16609 fi
16610
16611
16612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
16613 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
16614 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
16615 $as_echo_n "(cached) " >&6
16616 else
16617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16618 /* end confdefs.h. */
16619 #include <langinfo.h>
16620 int
16621 main ()
16622 {
16623 char* cs = nl_langinfo(CODESET);
16624 ;
16625 return 0;
16626 }
16627 _ACEOF
16628 if ac_fn_c_try_link "$LINENO"; then :
16629 emacs_cv_langinfo_codeset=yes
16630 else
16631 emacs_cv_langinfo_codeset=no
16632 fi
16633 rm -f core conftest.err conftest.$ac_objext \
16634 conftest$ac_exeext conftest.$ac_ext
16635
16636 fi
16637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
16638 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
16639 if test $emacs_cv_langinfo_codeset = yes; then
16640
16641 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
16642
16643 fi
16644
16645 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
16646 $as_echo_n "checking for mbstate_t... " >&6; }
16647 if test "${ac_cv_type_mbstate_t+set}" = set; then :
16648 $as_echo_n "(cached) " >&6
16649 else
16650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16651 /* end confdefs.h. */
16652 $ac_includes_default
16653 # include <wchar.h>
16654 int
16655 main ()
16656 {
16657 mbstate_t x; return sizeof x;
16658 ;
16659 return 0;
16660 }
16661 _ACEOF
16662 if ac_fn_c_try_compile "$LINENO"; then :
16663 ac_cv_type_mbstate_t=yes
16664 else
16665 ac_cv_type_mbstate_t=no
16666 fi
16667 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16668 fi
16669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
16670 $as_echo "$ac_cv_type_mbstate_t" >&6; }
16671 if test $ac_cv_type_mbstate_t = yes; then
16672
16673 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
16674
16675 else
16676
16677 $as_echo "#define mbstate_t int" >>confdefs.h
16678
16679 fi
16680
16681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
16682 $as_echo_n "checking for C restricted array declarations... " >&6; }
16683 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
16684 $as_echo_n "(cached) " >&6
16685 else
16686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16687 /* end confdefs.h. */
16688 void fred (int x[__restrict]);
16689 int
16690 main ()
16691 {
16692
16693 ;
16694 return 0;
16695 }
16696 _ACEOF
16697 if ac_fn_c_try_compile "$LINENO"; then :
16698 emacs_cv_c_restrict_arr=yes
16699 else
16700 emacs_cv_c_restrict_arr=no
16701 fi
16702 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16703 fi
16704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
16705 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
16706 if test "$emacs_cv_c_restrict_arr" = yes; then
16707
16708 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
16709
16710 fi
16711
16712
16713 if test "${opsys}" != "mingw32"; then
16714
16715 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
16716
16717 fi
16718
16719
16720 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
16721
16722
16723 ## Note: PTYs are broken on darwin <6. Use at your own risk.
16724 if test "${opsys}" != "mingw32"; then
16725
16726 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
16727
16728 fi
16729
16730
16731 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
16732
16733
16734
16735
16736
16737 if test "${opsys}" = "mingw32"; then
16738 $as_echo "#define NULL_DEVICE \"NUL:\"" >>confdefs.h
16739
16740 else
16741 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
16742
16743 fi
16744
16745
16746 if test "${opsys}" = "mingw32"; then
16747 $as_echo "#define SEPCHAR ';'" >>confdefs.h
16748
16749 else
16750 $as_echo "#define SEPCHAR ':'" >>confdefs.h
16751
16752 fi
16753
16754
16755 $as_echo "#define subprocesses 1" >>confdefs.h
16756
16757
16758
16759 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
16760
16761
16762
16763
16764 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
16765
16766
16767 if test "${opsys}" = "mingw32"; then
16768
16769 $as_echo "#define IS_DEVICE_SEP(_c_) ((_c_) == ':')" >>confdefs.h
16770
16771
16772
16773 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == '/' || (_c_) == '\\\\')" >>confdefs.h
16774
16775
16776
16777 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_) || IS_DEVICE_SEP(_c_))" >>confdefs.h
16778
16779 else
16780
16781 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
16782
16783
16784
16785 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
16786
16787
16788
16789 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
16790
16791 fi
16792
16793
16794
16795 case $opsys in
16796 aix4-2)
16797 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
16798 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16799
16800 fi
16801 ;;
16802
16803 hpux*)
16804 $as_echo "#define NO_EDITRES 1" >>confdefs.h
16805
16806 ;;
16807 esac
16808
16809
16810 case $opsys in
16811 irix6-5 | sol2* | unixware )
16812
16813 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
16814
16815 ;;
16816 esac
16817
16818 emacs_broken_SIGIO=no
16819
16820 case $opsys in
16821 hpux* | irix6-5 | openbsd | sol2* | unixware )
16822 emacs_broken_SIGIO=yes
16823 ;;
16824
16825 aix4-2)
16826
16827 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
16828
16829 ;;
16830
16831 freebsd)
16832
16833 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
16834
16835 ;;
16836 esac
16837
16838 case $opsys in
16839 gnu-* | sol2-10 )
16840
16841 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
16842
16843 ;;
16844 esac
16845
16846 case $opsys in
16847 darwin | dragonfly | freebsd | netbsd | openbsd )
16848
16849 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
16850
16851 ;;
16852 esac
16853
16854 case $opsys in
16855 netbsd | openbsd) sound_device="/dev/audio" ;;
16856 *) sound_device="/dev/dsp" ;;
16857 esac
16858
16859
16860 cat >>confdefs.h <<_ACEOF
16861 #define DEFAULT_SOUND_DEVICE "$sound_device"
16862 _ACEOF
16863
16864
16865
16866 case $opsys in
16867 darwin | gnu-linux | gnu-kfreebsd )
16868
16869 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
16870
16871 ;;
16872 esac
16873
16874
16875 case $opsys in
16876 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
16877
16878 $as_echo "#define NARROWPROTO 1" >>confdefs.h
16879
16880 ;;
16881 esac
16882
16883
16884
16885
16886
16887
16888
16889
16890 case $opsys in
16891 aix4-2 )
16892 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
16893
16894 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
16895
16896 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
16897
16898 ;;
16899
16900 cygwin )
16901 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16902
16903 $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
16904
16905 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16906
16907 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16908
16909 ;;
16910
16911 darwin )
16912 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16913
16914 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16915
16916 $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
16917
16918 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16919
16920 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16921
16922 ;;
16923
16924 gnu | openbsd )
16925 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16926
16927 ;;
16928
16929 gnu-linux | gnu-kfreebsd | dragonfly | freebsd | netbsd )
16930 if test "x$ac_cv_func_grantpt" = xyes; then
16931
16932 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
16933
16934 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
16935
16936 $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) { emacs_close (fd); return -1; } snprintf (pty_name, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16937
16938 if test "x$ac_cv_func_posix_openpt" = xyes; then
16939 $as_echo "#define PTY_OPEN do { fd = posix_openpt (O_RDWR | O_CLOEXEC | O_NOCTTY); if (fd < 0 && errno == EINVAL) fd = posix_openpt (O_RDWR | O_NOCTTY); } while (0)" >>confdefs.h
16940
16941 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16942
16943 elif test "x$ac_cv_func_getpt" = xyes; then
16944 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
16945
16946 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16947
16948 else
16949 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16950
16951 fi
16952 else
16953 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16954
16955 fi
16956 ;;
16957
16958 hpux*)
16959 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
16960
16961 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
16962
16963 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
16964
16965 ;;
16966
16967 irix6-5 )
16968 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
16969
16970 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
16971
16972 $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(SIGCHLD, &cstat, &ocstat); name = _getpty (&fd, O_RDWR | O_NDELAY, 0600, 0); sigaction(SIGCHLD, &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
16973
16974 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
16975
16976 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
16977
16978 ;;
16979
16980 sol2* )
16981 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); 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, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16982
16983 ;;
16984
16985 unixware )
16986 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); 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, PTY_NAME_SIZE, \"%s\", ptyname); }" >>confdefs.h
16987
16988 ;;
16989 esac
16990
16991
16992 case $opsys in
16993 sol2* | unixware )
16994 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
16995
16996 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
16997
16998
16999 $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
17000
17001 ;;
17002 esac
17003
17004
17005
17006
17007 case $opsys in
17008 aix4-2 | cygwin | gnu | irix6-5 | dragonfly | freebsd | netbsd | openbsd | darwin )
17009 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
17010
17011 ;;
17012
17013 gnu-linux | gnu-kfreebsd )
17014
17015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
17016 $as_echo_n "checking for signals via characters... " >&6; }
17017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17018 /* end confdefs.h. */
17019
17020 #include <linux/version.h>
17021 #if LINUX_VERSION_CODE < 0x20400
17022 # error "Linux version too old"
17023 #endif
17024
17025 int
17026 main ()
17027 {
17028
17029 ;
17030 return 0;
17031 }
17032 _ACEOF
17033 if ac_fn_c_try_cpp "$LINENO"; then :
17034 emacs_signals_via_chars=yes
17035 else
17036 emacs_signals_via_chars=no
17037 fi
17038 rm -f conftest.err conftest.$ac_ext
17039
17040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
17041 $as_echo "$emacs_signals_via_chars" >&6; }
17042 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
17043
17044 ;;
17045 esac
17046
17047
17048
17049
17050 case $opsys in
17051 aix*)
17052 $as_echo "#define DATA_SEG_BITS 0x20000000" >>confdefs.h
17053
17054 ;;
17055 hpux*)
17056 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
17057
17058 ;;
17059 irix6-5)
17060 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
17061
17062 ;;
17063 esac
17064
17065
17066
17067
17068 case $opsys in
17069 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
17070 ;;
17071
17072 gnu | dragonfly | freebsd | netbsd | openbsd )
17073
17074 $as_echo "#define TABDLY OXTABS" >>confdefs.h
17075
17076 $as_echo "#define TAB3 OXTABS" >>confdefs.h
17077
17078 ;;
17079
17080 gnu-linux | gnu-kfreebsd )
17081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17082 /* end confdefs.h. */
17083
17084 #ifndef __ia64__
17085 # error "not ia64"
17086 #endif
17087
17088 int
17089 main ()
17090 {
17091
17092 ;
17093 return 0;
17094 }
17095 _ACEOF
17096 if ac_fn_c_try_cpp "$LINENO"; then :
17097
17098 $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
17099
17100 fi
17101 rm -f conftest.err conftest.$ac_ext
17102 ;;
17103
17104 hpux*)
17105
17106 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
17107
17108 ;;
17109 esac
17110
17111
17112
17113
17114
17115 case $opsys in
17116 gnu-linux | gnu-kfreebsd )
17117 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17118 /* end confdefs.h. */
17119
17120 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
17121 || defined __alpha__ || defined __mips__ || defined __s390__ \
17122 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
17123 || defined __ia64__ || defined __sh__
17124 /* ok */
17125 #else
17126 # error "setjmp not known to work on this arch"
17127 #endif
17128
17129 int
17130 main ()
17131 {
17132
17133 ;
17134 return 0;
17135 }
17136 _ACEOF
17137 if ac_fn_c_try_cpp "$LINENO"; then :
17138 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17139
17140 fi
17141 rm -f conftest.err conftest.$ac_ext
17142 ;;
17143 esac
17144
17145
17146 if test x$GCC = xyes; then
17147 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17148
17149 else
17150 case $opsys in
17151 dragonfly | freebsd | netbsd | openbsd | irix6-5 | sol2* )
17152 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
17153
17154 ;;
17155 esac
17156 fi
17157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
17158 $as_echo_n "checking for _setjmp... " >&6; }
17159 if test "${emacs_cv_func__setjmp+set}" = set; then :
17160 $as_echo_n "(cached) " >&6
17161 else
17162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17163 /* end confdefs.h. */
17164 #include <setjmp.h>
17165 #ifdef __MINGW32__
17166 # define _longjmp longjmp
17167 #endif
17168
17169 int
17170 main ()
17171 {
17172 jmp_buf j;
17173 if (! _setjmp (j))
17174 _longjmp (j, 1);
17175 ;
17176 return 0;
17177 }
17178 _ACEOF
17179 if ac_fn_c_try_link "$LINENO"; then :
17180 emacs_cv_func__setjmp=yes
17181 else
17182 emacs_cv_func__setjmp=no
17183 fi
17184 rm -f core conftest.err conftest.$ac_objext \
17185 conftest$ac_exeext conftest.$ac_ext
17186 fi
17187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
17188 $as_echo "$emacs_cv_func__setjmp" >&6; }
17189 if test $emacs_cv_func__setjmp = yes; then
17190
17191 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
17192
17193 else
17194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
17195 $as_echo_n "checking for sigsetjmp... " >&6; }
17196 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
17197 $as_echo_n "(cached) " >&6
17198 else
17199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17200 /* end confdefs.h. */
17201 #include <setjmp.h>
17202
17203 int
17204 main ()
17205 {
17206 sigjmp_buf j;
17207 if (! sigsetjmp (j, 1))
17208 siglongjmp (j, 1);
17209 ;
17210 return 0;
17211 }
17212 _ACEOF
17213 if ac_fn_c_try_link "$LINENO"; then :
17214 emacs_cv_func_sigsetjmp=yes
17215 else
17216 emacs_cv_func_sigsetjmp=no
17217 fi
17218 rm -f core conftest.err conftest.$ac_objext \
17219 conftest$ac_exeext conftest.$ac_ext
17220 fi
17221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
17222 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
17223 if test $emacs_cv_func_sigsetjmp = yes; then
17224
17225 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
17226
17227 fi
17228 fi
17229
17230 case $opsys in
17231 sol2* | unixware )
17232
17233 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
17234
17235 ;;
17236 esac
17237
17238
17239 case $opsys in
17240 hpux* | sol2* )
17241
17242 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
17243
17244 ;;
17245 esac
17246
17247
17248
17249
17250
17251
17252
17253 case $opsys in
17254 aix4-2)
17255 $as_echo "#define USG /**/" >>confdefs.h
17256
17257 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17258 /* end confdefs.h. */
17259
17260 #ifndef _AIX
17261 # error "_AIX not defined"
17262 #endif
17263
17264 int
17265 main ()
17266 {
17267
17268 ;
17269 return 0;
17270 }
17271 _ACEOF
17272 if ac_fn_c_try_cpp "$LINENO"; then :
17273
17274 else
17275
17276 $as_echo "#define _AIX /**/" >>confdefs.h
17277
17278 fi
17279 rm -f conftest.err conftest.$ac_ext
17280 ;;
17281
17282 cygwin)
17283
17284 $as_echo "#define CYGWIN 1" >>confdefs.h
17285
17286 ;;
17287
17288 darwin)
17289
17290 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
17291
17292 ;;
17293
17294 gnu-linux | gnu-kfreebsd )
17295 $as_echo "#define USG /**/" >>confdefs.h
17296
17297
17298 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
17299
17300 ;;
17301
17302 hpux*)
17303 $as_echo "#define USG /**/" >>confdefs.h
17304
17305
17306 $as_echo "#define HPUX /**/" >>confdefs.h
17307
17308 ;;
17309
17310 irix6-5)
17311 $as_echo "#define USG /**/" >>confdefs.h
17312
17313 $as_echo "#define USG5_4 /**/" >>confdefs.h
17314
17315
17316 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
17317
17318 ;;
17319
17320 mingw32)
17321 $as_echo "#define DOS_NT /**/" >>confdefs.h
17322
17323
17324 $as_echo "#define WINDOWSNT 1" >>confdefs.h
17325
17326 if test "x$ac_enable_checking" != "x" ; then
17327
17328 $as_echo "#define EMACSDEBUG 1" >>confdefs.h
17329
17330 fi
17331 ;;
17332
17333 sol2*)
17334 $as_echo "#define USG /**/" >>confdefs.h
17335
17336 $as_echo "#define USG5_4 /**/" >>confdefs.h
17337
17338
17339 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
17340
17341 ;;
17342
17343 unixware)
17344 $as_echo "#define USG /**/" >>confdefs.h
17345
17346 $as_echo "#define USG5_4 /**/" >>confdefs.h
17347
17348 ;;
17349 esac
17350
17351 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
17352 $as_echo_n "checking for usable FIONREAD... " >&6; }
17353 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
17354 $as_echo_n "(cached) " >&6
17355 else
17356 case $opsys in
17357 aix4-2)
17358 emacs_cv_usable_FIONREAD=no
17359 ;;
17360
17361 mingw32)
17362 emacs_cv_usable_FIONREAD=yes
17363 ;;
17364
17365 *)
17366 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17367 /* end confdefs.h. */
17368 #include <sys/types.h>
17369 #include <sys/ioctl.h>
17370 #ifdef USG5_4
17371 # include <sys/filio.h>
17372 #endif
17373
17374 int
17375 main ()
17376 {
17377 int foo = ioctl (0, FIONREAD, &foo);
17378 ;
17379 return 0;
17380 }
17381 _ACEOF
17382 if ac_fn_c_try_compile "$LINENO"; then :
17383 emacs_cv_usable_FIONREAD=yes
17384 else
17385 emacs_cv_usable_FIONREAD=no
17386 fi
17387 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17388 ;;
17389 esac
17390 fi
17391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
17392 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
17393 if test $emacs_cv_usable_FIONREAD = yes; then
17394
17395 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
17396
17397
17398 if test $emacs_broken_SIGIO = no; then
17399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
17400 $as_echo_n "checking for usable SIGIO... " >&6; }
17401 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
17402 $as_echo_n "(cached) " >&6
17403 else
17404 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17405 /* end confdefs.h. */
17406 #include <fcntl.h>
17407 #include <signal.h>
17408
17409 int
17410 main ()
17411 {
17412 int foo = SIGIO | F_SETFL | FASYNC;
17413 ;
17414 return 0;
17415 }
17416 _ACEOF
17417 if ac_fn_c_try_compile "$LINENO"; then :
17418 emacs_cv_usable_SIGIO=yes
17419 else
17420 emacs_cv_usable_SIGIO=no
17421 fi
17422 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17423 fi
17424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
17425 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
17426 if test $emacs_cv_usable_SIGIO = yes; then
17427
17428 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
17429
17430 fi
17431 fi
17432 fi
17433
17434
17435 case $opsys in
17436 cygwin)
17437
17438 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
17439
17440 ;;
17441
17442 hpux11)
17443
17444 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
17445
17446 ;;
17447
17448 irix6-5)
17449
17450 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
17451
17452 ;;
17453
17454 sol2-10)
17455
17456 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
17457
17458 ;;
17459 esac
17460
17461 # Set up the CFLAGS for real compilation, so we can substitute it.
17462 CFLAGS="$REAL_CFLAGS"
17463 CPPFLAGS="$REAL_CPPFLAGS"
17464
17465 ## Hack to detect a buggy GCC version.
17466 if test "x$GCC" = xyes \
17467 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
17468 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
17469 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
17470 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
17471 fi
17472
17473 version=$PACKAGE_VERSION
17474
17475 copyright="Copyright (C) 2013 Free Software Foundation, Inc."
17476
17477 cat >>confdefs.h <<_ACEOF
17478 #define COPYRIGHT "$copyright"
17479 _ACEOF
17480
17481
17482
17483 ### Specify what sort of things we'll be editing into Makefile and config.h.
17484 ### Use configuration here uncanonicalized to avoid exceeding size limits.
17485
17486
17487 ## Unused?
17488
17489
17490
17491
17492
17493
17494
17495
17496
17497
17498
17499
17500
17501
17502
17503
17504
17505
17506
17507
17508
17509
17510 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
17511 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
17512 ## end of LIBX_BASE, but nothing ever set it.
17513
17514
17515
17516
17517 ## Used in lwlib/Makefile.in.
17518
17519
17520
17521
17522
17523
17524
17525
17526 if test -n "${term_header}"; then
17527
17528 cat >>confdefs.h <<_ACEOF
17529 #define TERM_HEADER "${term_header}"
17530 _ACEOF
17531
17532 fi
17533
17534
17535 cat >>confdefs.h <<_ACEOF
17536 #define EMACS_CONFIGURATION "${canonical}"
17537 _ACEOF
17538
17539
17540 cat >>confdefs.h <<_ACEOF
17541 #define EMACS_CONFIG_OPTIONS "${emacs_config_options}"
17542 _ACEOF
17543
17544
17545
17546 case $opsys in
17547 mingw32)
17548 $as_echo "#define config_opsysfile <ms-w32.h>" >>confdefs.h
17549
17550 ;;
17551 esac
17552
17553 XMENU_OBJ=
17554 XOBJ=
17555 FONT_OBJ=
17556 if test "${HAVE_X_WINDOWS}" = "yes" ; then
17557
17558 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
17559
17560 XMENU_OBJ=xmenu.o
17561 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o"
17562 FONT_OBJ=xfont.o
17563 if test "$HAVE_XFT" = "yes"; then
17564 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
17565 elif test "$HAVE_FREETYPE" = "yes"; then
17566 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
17567 fi
17568
17569 fi
17570
17571
17572
17573
17574 WIDGET_OBJ=
17575 MOTIF_LIBW=
17576 if test "${USE_X_TOOLKIT}" != "none" ; then
17577 WIDGET_OBJ=widget.o
17578
17579 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
17580
17581 if test "${USE_X_TOOLKIT}" = "LUCID"; then
17582
17583 $as_echo "#define USE_LUCID 1" >>confdefs.h
17584
17585 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
17586
17587 $as_echo "#define USE_MOTIF 1" >>confdefs.h
17588
17589 MOTIF_LIBW=-lXm
17590 case "$opsys" in
17591 gnu-linux)
17592 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
17593 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
17594 ;;
17595
17596 unixware)
17597 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
17598 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
17599 MOTIF_LIBW="MOTIF_LIBW -lXimp"
17600 ;;
17601
17602 aix4-2)
17603 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
17604 MOTIF_LIBW="$MOTIF_LIBW -li18n"
17605 ;;
17606 esac
17607 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
17608 fi
17609 fi
17610
17611
17612 TOOLKIT_LIBW=
17613 case "$USE_X_TOOLKIT" in
17614 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
17615 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
17616 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
17617 esac
17618
17619
17620 if test "${opsys}" != "mingw32"; then
17621 if test "$USE_X_TOOLKIT" = "none"; then
17622 LIBXT_OTHER="\$(LIBXSM)"
17623 OLDXMENU_TARGET="really-oldXMenu"
17624 else
17625 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
17626 OLDXMENU_TARGET="really-lwlib"
17627 fi
17628 fi
17629
17630
17631 ## The X Menu stuff is present in the X10 distribution, but missing
17632 ## from X11. If we have X10, just use the installed library;
17633 ## otherwise, use our own copy.
17634 if test "${HAVE_X11}" = "yes" ; then
17635
17636 $as_echo "#define HAVE_X11 1" >>confdefs.h
17637
17638
17639 if test "$USE_X_TOOLKIT" = "none"; then
17640 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
17641 else
17642 OLDXMENU="\${lwlibdir}/liblw.a"
17643 fi
17644 LIBXMENU="\$(OLDXMENU)"
17645 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
17646 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
17647 else
17648 ## For a syntactically valid Makefile; not actually used for anything.
17649 ## See comments in src/Makefile.in.
17650 OLDXMENU=nothing
17651 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
17652 if test "${HAVE_X_WINDOWS}" = "yes"; then
17653 LIBXMENU="-lXMenu"
17654 else
17655 LIBXMENU=
17656 fi
17657 LIBX_OTHER=
17658 OLDXMENU_DEPS=
17659 fi
17660
17661 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
17662 OLDXMENU_TARGET=
17663 OLDXMENU=nothing
17664 LIBXMENU=
17665 OLDXMENU_DEPS=
17666 fi
17667
17668
17669
17670
17671
17672
17673
17674 if test "${HAVE_MENUS}" = "yes" ; then
17675
17676 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
17677
17678 fi
17679
17680 if test "${GNU_MALLOC}" = "yes" ; then
17681
17682 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
17683
17684 fi
17685
17686 RALLOC_OBJ=
17687 if test "${REL_ALLOC}" = "yes" ; then
17688
17689 $as_echo "#define REL_ALLOC 1" >>confdefs.h
17690
17691
17692 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
17693 fi
17694
17695
17696 if test "$opsys" = "cygwin"; then
17697 CYGWIN_OBJ="sheap.o cygw32.o"
17698 ## Cygwin differs because of its unexec().
17699 PRE_ALLOC_OBJ=
17700 POST_ALLOC_OBJ=lastfile.o
17701 elif test "$opsys" = "mingw32"; then
17702 CYGWIN_OBJ=
17703 PRE_ALLOC_OBJ=
17704 POST_ALLOC_OBJ=lastfile.o
17705 else
17706 CYGWIN_OBJ=
17707 PRE_ALLOC_OBJ=lastfile.o
17708 POST_ALLOC_OBJ=
17709 fi
17710
17711
17712
17713
17714
17715
17716 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
17717 # it temporarily reverts them to their pre-pkg-config values,
17718 # because gnulib needs to work with both src (which uses the
17719 # pkg-config stuff) and lib-src (which does not). For example, gnulib
17720 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
17721 # and it therefore needs to run in an environment where LIBS does not
17722 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
17723 # for some package unrelated to lib-src.
17724 SAVE_CFLAGS=$CFLAGS
17725 SAVE_LIBS=$LIBS
17726 CFLAGS=$pre_PKG_CONFIG_CFLAGS
17727 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
17728
17729
17730
17731
17732
17733
17734
17735
17736
17737
17738
17739 LIBC_FATAL_STDERR_=1
17740 export LIBC_FATAL_STDERR_
17741
17742 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
17743 # for constant arguments. Useless!
17744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
17745 $as_echo_n "checking for working alloca.h... " >&6; }
17746 if test "${ac_cv_working_alloca_h+set}" = set; then :
17747 $as_echo_n "(cached) " >&6
17748 else
17749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17750 /* end confdefs.h. */
17751 #include <alloca.h>
17752 int
17753 main ()
17754 {
17755 char *p = (char *) alloca (2 * sizeof (int));
17756 if (p) return 0;
17757 ;
17758 return 0;
17759 }
17760 _ACEOF
17761 if ac_fn_c_try_link "$LINENO"; then :
17762 ac_cv_working_alloca_h=yes
17763 else
17764 ac_cv_working_alloca_h=no
17765 fi
17766 rm -f core conftest.err conftest.$ac_objext \
17767 conftest$ac_exeext conftest.$ac_ext
17768 fi
17769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
17770 $as_echo "$ac_cv_working_alloca_h" >&6; }
17771 if test $ac_cv_working_alloca_h = yes; then
17772
17773 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
17774
17775 fi
17776
17777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
17778 $as_echo_n "checking for alloca... " >&6; }
17779 if test "${ac_cv_func_alloca_works+set}" = set; then :
17780 $as_echo_n "(cached) " >&6
17781 else
17782 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17783 /* end confdefs.h. */
17784 #ifdef __GNUC__
17785 # define alloca __builtin_alloca
17786 #else
17787 # ifdef _MSC_VER
17788 # include <malloc.h>
17789 # define alloca _alloca
17790 # else
17791 # ifdef HAVE_ALLOCA_H
17792 # include <alloca.h>
17793 # else
17794 # ifdef _AIX
17795 #pragma alloca
17796 # else
17797 # ifndef alloca /* predefined by HP cc +Olibcalls */
17798 char *alloca ();
17799 # endif
17800 # endif
17801 # endif
17802 # endif
17803 #endif
17804
17805 int
17806 main ()
17807 {
17808 char *p = (char *) alloca (1);
17809 if (p) return 0;
17810 ;
17811 return 0;
17812 }
17813 _ACEOF
17814 if ac_fn_c_try_link "$LINENO"; then :
17815 ac_cv_func_alloca_works=yes
17816 else
17817 ac_cv_func_alloca_works=no
17818 fi
17819 rm -f core conftest.err conftest.$ac_objext \
17820 conftest$ac_exeext conftest.$ac_ext
17821 fi
17822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
17823 $as_echo "$ac_cv_func_alloca_works" >&6; }
17824
17825 if test $ac_cv_func_alloca_works = yes; then
17826
17827 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
17828
17829 else
17830 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
17831 # that cause trouble. Some versions do not even contain alloca or
17832 # contain a buggy version. If you still want to use their alloca,
17833 # use ar to extract alloca.o from them instead of compiling alloca.c.
17834
17835
17836
17837
17838
17839 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
17840
17841 $as_echo "#define C_ALLOCA 1" >>confdefs.h
17842
17843
17844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
17845 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
17846 if test "${ac_cv_os_cray+set}" = set; then :
17847 $as_echo_n "(cached) " >&6
17848 else
17849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17850 /* end confdefs.h. */
17851 #if defined CRAY && ! defined CRAY2
17852 webecray
17853 #else
17854 wenotbecray
17855 #endif
17856
17857 _ACEOF
17858 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
17859 $EGREP "webecray" >/dev/null 2>&1; then :
17860 ac_cv_os_cray=yes
17861 else
17862 ac_cv_os_cray=no
17863 fi
17864 rm -f conftest*
17865
17866 fi
17867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
17868 $as_echo "$ac_cv_os_cray" >&6; }
17869 if test $ac_cv_os_cray = yes; then
17870 for ac_func in _getb67 GETB67 getb67; do
17871 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
17872 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
17873 eval as_val=\$$as_ac_var
17874 if test "x$as_val" = x""yes; then :
17875
17876 cat >>confdefs.h <<_ACEOF
17877 #define CRAY_STACKSEG_END $ac_func
17878 _ACEOF
17879
17880 break
17881 fi
17882
17883 done
17884 fi
17885
17886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
17887 $as_echo_n "checking stack direction for C alloca... " >&6; }
17888 if test "${ac_cv_c_stack_direction+set}" = set; then :
17889 $as_echo_n "(cached) " >&6
17890 else
17891 if test "$cross_compiling" = yes; then :
17892 ac_cv_c_stack_direction=0
17893 else
17894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17895 /* end confdefs.h. */
17896 $ac_includes_default
17897 int
17898 find_stack_direction (int *addr, int depth)
17899 {
17900 int dir, dummy = 0;
17901 if (! addr)
17902 addr = &dummy;
17903 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
17904 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
17905 return dir + dummy;
17906 }
17907
17908 int
17909 main (int argc, char **argv)
17910 {
17911 return find_stack_direction (0, argc + !argv + 20) < 0;
17912 }
17913 _ACEOF
17914 if ac_fn_c_try_run "$LINENO"; then :
17915 ac_cv_c_stack_direction=1
17916 else
17917 ac_cv_c_stack_direction=-1
17918 fi
17919 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17920 conftest.$ac_objext conftest.beam conftest.$ac_ext
17921 fi
17922
17923 fi
17924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
17925 $as_echo "$ac_cv_c_stack_direction" >&6; }
17926 cat >>confdefs.h <<_ACEOF
17927 #define STACK_DIRECTION $ac_cv_c_stack_direction
17928 _ACEOF
17929
17930
17931 fi
17932
17933
17934
17935
17936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17937 $as_echo_n "checking for unsigned long long int... " >&6; }
17938 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17939 $as_echo_n "(cached) " >&6
17940 else
17941 ac_cv_type_unsigned_long_long_int=yes
17942 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17943 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17944 /* end confdefs.h. */
17945
17946 /* For now, do not test the preprocessor; as of 2007 there are too many
17947 implementations with broken preprocessors. Perhaps this can
17948 be revisited in 2012. In the meantime, code should not expect
17949 #if to work with literals wider than 32 bits. */
17950 /* Test literals. */
17951 long long int ll = 9223372036854775807ll;
17952 long long int nll = -9223372036854775807LL;
17953 unsigned long long int ull = 18446744073709551615ULL;
17954 /* Test constant expressions. */
17955 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17956 ? 1 : -1)];
17957 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17958 ? 1 : -1)];
17959 int i = 63;
17960 int
17961 main ()
17962 {
17963 /* Test availability of runtime routines for shift and division. */
17964 long long int llmax = 9223372036854775807ll;
17965 unsigned long long int ullmax = 18446744073709551615ull;
17966 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17967 | (llmax / ll) | (llmax % ll)
17968 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17969 | (ullmax / ull) | (ullmax % ull));
17970 ;
17971 return 0;
17972 }
17973
17974 _ACEOF
17975 if ac_fn_c_try_link "$LINENO"; then :
17976
17977 else
17978 ac_cv_type_unsigned_long_long_int=no
17979 fi
17980 rm -f core conftest.err conftest.$ac_objext \
17981 conftest$ac_exeext conftest.$ac_ext
17982 fi
17983 fi
17984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17985 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17986 if test $ac_cv_type_unsigned_long_long_int = yes; then
17987
17988 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17989
17990 fi
17991
17992
17993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
17994 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
17995 if test "${ac_cv_c_bigendian+set}" = set; then :
17996 $as_echo_n "(cached) " >&6
17997 else
17998 ac_cv_c_bigendian=unknown
17999 # See if we're dealing with a universal compiler.
18000 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18001 /* end confdefs.h. */
18002 #ifndef __APPLE_CC__
18003 not a universal capable compiler
18004 #endif
18005 typedef int dummy;
18006
18007 _ACEOF
18008 if ac_fn_c_try_compile "$LINENO"; then :
18009
18010 # Check for potential -arch flags. It is not universal unless
18011 # there are at least two -arch flags with different values.
18012 ac_arch=
18013 ac_prev=
18014 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
18015 if test -n "$ac_prev"; then
18016 case $ac_word in
18017 i?86 | x86_64 | ppc | ppc64)
18018 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
18019 ac_arch=$ac_word
18020 else
18021 ac_cv_c_bigendian=universal
18022 break
18023 fi
18024 ;;
18025 esac
18026 ac_prev=
18027 elif test "x$ac_word" = "x-arch"; then
18028 ac_prev=arch
18029 fi
18030 done
18031 fi
18032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18033 if test $ac_cv_c_bigendian = unknown; then
18034 # See if sys/param.h defines the BYTE_ORDER macro.
18035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18036 /* end confdefs.h. */
18037 #include <sys/types.h>
18038 #include <sys/param.h>
18039
18040 int
18041 main ()
18042 {
18043 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
18044 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
18045 && LITTLE_ENDIAN)
18046 bogus endian macros
18047 #endif
18048
18049 ;
18050 return 0;
18051 }
18052 _ACEOF
18053 if ac_fn_c_try_compile "$LINENO"; then :
18054 # It does; now see whether it defined to BIG_ENDIAN or not.
18055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18056 /* end confdefs.h. */
18057 #include <sys/types.h>
18058 #include <sys/param.h>
18059
18060 int
18061 main ()
18062 {
18063 #if BYTE_ORDER != BIG_ENDIAN
18064 not big endian
18065 #endif
18066
18067 ;
18068 return 0;
18069 }
18070 _ACEOF
18071 if ac_fn_c_try_compile "$LINENO"; then :
18072 ac_cv_c_bigendian=yes
18073 else
18074 ac_cv_c_bigendian=no
18075 fi
18076 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18077 fi
18078 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18079 fi
18080 if test $ac_cv_c_bigendian = unknown; then
18081 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
18082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18083 /* end confdefs.h. */
18084 #include <limits.h>
18085
18086 int
18087 main ()
18088 {
18089 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
18090 bogus endian macros
18091 #endif
18092
18093 ;
18094 return 0;
18095 }
18096 _ACEOF
18097 if ac_fn_c_try_compile "$LINENO"; then :
18098 # It does; now see whether it defined to _BIG_ENDIAN or not.
18099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18100 /* end confdefs.h. */
18101 #include <limits.h>
18102
18103 int
18104 main ()
18105 {
18106 #ifndef _BIG_ENDIAN
18107 not big endian
18108 #endif
18109
18110 ;
18111 return 0;
18112 }
18113 _ACEOF
18114 if ac_fn_c_try_compile "$LINENO"; then :
18115 ac_cv_c_bigendian=yes
18116 else
18117 ac_cv_c_bigendian=no
18118 fi
18119 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18120 fi
18121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18122 fi
18123 if test $ac_cv_c_bigendian = unknown; then
18124 # Compile a test program.
18125 if test "$cross_compiling" = yes; then :
18126 # Try to guess by grepping values from an object file.
18127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18128 /* end confdefs.h. */
18129 short int ascii_mm[] =
18130 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
18131 short int ascii_ii[] =
18132 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
18133 int use_ascii (int i) {
18134 return ascii_mm[i] + ascii_ii[i];
18135 }
18136 short int ebcdic_ii[] =
18137 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
18138 short int ebcdic_mm[] =
18139 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
18140 int use_ebcdic (int i) {
18141 return ebcdic_mm[i] + ebcdic_ii[i];
18142 }
18143 extern int foo;
18144
18145 int
18146 main ()
18147 {
18148 return use_ascii (foo) == use_ebcdic (foo);
18149 ;
18150 return 0;
18151 }
18152 _ACEOF
18153 if ac_fn_c_try_compile "$LINENO"; then :
18154 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
18155 ac_cv_c_bigendian=yes
18156 fi
18157 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
18158 if test "$ac_cv_c_bigendian" = unknown; then
18159 ac_cv_c_bigendian=no
18160 else
18161 # finding both strings is unlikely to happen, but who knows?
18162 ac_cv_c_bigendian=unknown
18163 fi
18164 fi
18165 fi
18166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18167 else
18168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18169 /* end confdefs.h. */
18170 $ac_includes_default
18171 int
18172 main ()
18173 {
18174
18175 /* Are we little or big endian? From Harbison&Steele. */
18176 union
18177 {
18178 long int l;
18179 char c[sizeof (long int)];
18180 } u;
18181 u.l = 1;
18182 return u.c[sizeof (long int) - 1] == 1;
18183
18184 ;
18185 return 0;
18186 }
18187 _ACEOF
18188 if ac_fn_c_try_run "$LINENO"; then :
18189 ac_cv_c_bigendian=no
18190 else
18191 ac_cv_c_bigendian=yes
18192 fi
18193 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18194 conftest.$ac_objext conftest.beam conftest.$ac_ext
18195 fi
18196
18197 fi
18198 fi
18199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
18200 $as_echo "$ac_cv_c_bigendian" >&6; }
18201 case $ac_cv_c_bigendian in #(
18202 yes)
18203 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
18204 ;; #(
18205 no)
18206 ;; #(
18207 universal)
18208
18209 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
18210
18211 ;; #(
18212 *)
18213 as_fn_error "unknown endianness
18214 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
18215 esac
18216
18217
18218
18219 GNULIB_CHDIR=0;
18220 GNULIB_CHOWN=0;
18221 GNULIB_CLOSE=0;
18222 GNULIB_DUP=0;
18223 GNULIB_DUP2=0;
18224 GNULIB_DUP3=0;
18225 GNULIB_ENVIRON=0;
18226 GNULIB_EUIDACCESS=0;
18227 GNULIB_FACCESSAT=0;
18228 GNULIB_FCHDIR=0;
18229 GNULIB_FCHOWNAT=0;
18230 GNULIB_FDATASYNC=0;
18231 GNULIB_FSYNC=0;
18232 GNULIB_FTRUNCATE=0;
18233 GNULIB_GETCWD=0;
18234 GNULIB_GETDOMAINNAME=0;
18235 GNULIB_GETDTABLESIZE=0;
18236 GNULIB_GETGROUPS=0;
18237 GNULIB_GETHOSTNAME=0;
18238 GNULIB_GETLOGIN=0;
18239 GNULIB_GETLOGIN_R=0;
18240 GNULIB_GETPAGESIZE=0;
18241 GNULIB_GETUSERSHELL=0;
18242 GNULIB_GROUP_MEMBER=0;
18243 GNULIB_ISATTY=0;
18244 GNULIB_LCHOWN=0;
18245 GNULIB_LINK=0;
18246 GNULIB_LINKAT=0;
18247 GNULIB_LSEEK=0;
18248 GNULIB_PIPE=0;
18249 GNULIB_PIPE2=0;
18250 GNULIB_PREAD=0;
18251 GNULIB_PWRITE=0;
18252 GNULIB_READ=0;
18253 GNULIB_READLINK=0;
18254 GNULIB_READLINKAT=0;
18255 GNULIB_RMDIR=0;
18256 GNULIB_SETHOSTNAME=0;
18257 GNULIB_SLEEP=0;
18258 GNULIB_SYMLINK=0;
18259 GNULIB_SYMLINKAT=0;
18260 GNULIB_TTYNAME_R=0;
18261 GNULIB_UNISTD_H_NONBLOCKING=0;
18262 GNULIB_UNISTD_H_SIGPIPE=0;
18263 GNULIB_UNLINK=0;
18264 GNULIB_UNLINKAT=0;
18265 GNULIB_USLEEP=0;
18266 GNULIB_WRITE=0;
18267 HAVE_CHOWN=1;
18268 HAVE_DUP2=1;
18269 HAVE_DUP3=1;
18270 HAVE_EUIDACCESS=1;
18271 HAVE_FACCESSAT=1;
18272 HAVE_FCHDIR=1;
18273 HAVE_FCHOWNAT=1;
18274 HAVE_FDATASYNC=1;
18275 HAVE_FSYNC=1;
18276 HAVE_FTRUNCATE=1;
18277 HAVE_GETDTABLESIZE=1;
18278 HAVE_GETGROUPS=1;
18279 HAVE_GETHOSTNAME=1;
18280 HAVE_GETLOGIN=1;
18281 HAVE_GETPAGESIZE=1;
18282 HAVE_GROUP_MEMBER=1;
18283 HAVE_LCHOWN=1;
18284 HAVE_LINK=1;
18285 HAVE_LINKAT=1;
18286 HAVE_PIPE=1;
18287 HAVE_PIPE2=1;
18288 HAVE_PREAD=1;
18289 HAVE_PWRITE=1;
18290 HAVE_READLINK=1;
18291 HAVE_READLINKAT=1;
18292 HAVE_SETHOSTNAME=1;
18293 HAVE_SLEEP=1;
18294 HAVE_SYMLINK=1;
18295 HAVE_SYMLINKAT=1;
18296 HAVE_UNLINKAT=1;
18297 HAVE_USLEEP=1;
18298 HAVE_DECL_ENVIRON=1;
18299 HAVE_DECL_FCHDIR=1;
18300 HAVE_DECL_FDATASYNC=1;
18301 HAVE_DECL_GETDOMAINNAME=1;
18302 HAVE_DECL_GETLOGIN_R=1;
18303 HAVE_DECL_GETPAGESIZE=1;
18304 HAVE_DECL_GETUSERSHELL=1;
18305 HAVE_DECL_SETHOSTNAME=1;
18306 HAVE_DECL_TTYNAME_R=1;
18307 HAVE_OS_H=0;
18308 HAVE_SYS_PARAM_H=0;
18309 REPLACE_CHOWN=0;
18310 REPLACE_CLOSE=0;
18311 REPLACE_DUP=0;
18312 REPLACE_DUP2=0;
18313 REPLACE_FCHOWNAT=0;
18314 REPLACE_FTRUNCATE=0;
18315 REPLACE_GETCWD=0;
18316 REPLACE_GETDOMAINNAME=0;
18317 REPLACE_GETDTABLESIZE=0;
18318 REPLACE_GETLOGIN_R=0;
18319 REPLACE_GETGROUPS=0;
18320 REPLACE_GETPAGESIZE=0;
18321 REPLACE_ISATTY=0;
18322 REPLACE_LCHOWN=0;
18323 REPLACE_LINK=0;
18324 REPLACE_LINKAT=0;
18325 REPLACE_LSEEK=0;
18326 REPLACE_PREAD=0;
18327 REPLACE_PWRITE=0;
18328 REPLACE_READ=0;
18329 REPLACE_READLINK=0;
18330 REPLACE_RMDIR=0;
18331 REPLACE_SLEEP=0;
18332 REPLACE_SYMLINK=0;
18333 REPLACE_TTYNAME_R=0;
18334 REPLACE_UNLINK=0;
18335 REPLACE_UNLINKAT=0;
18336 REPLACE_USLEEP=0;
18337 REPLACE_WRITE=0;
18338 UNISTD_H_HAVE_WINSOCK2_H=0;
18339 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
18340
18341
18342
18343 GNULIB_OPENDIR=0;
18344 GNULIB_READDIR=0;
18345 GNULIB_REWINDDIR=0;
18346 GNULIB_CLOSEDIR=0;
18347 GNULIB_DIRFD=0;
18348 GNULIB_FDOPENDIR=0;
18349 GNULIB_SCANDIR=0;
18350 GNULIB_ALPHASORT=0;
18351 HAVE_OPENDIR=1;
18352 HAVE_READDIR=1;
18353 HAVE_REWINDDIR=1;
18354 HAVE_CLOSEDIR=1;
18355 HAVE_DECL_DIRFD=1;
18356 HAVE_DECL_FDOPENDIR=1;
18357 HAVE_FDOPENDIR=1;
18358 HAVE_SCANDIR=1;
18359 HAVE_ALPHASORT=1;
18360 REPLACE_OPENDIR=0;
18361 REPLACE_CLOSEDIR=0;
18362 REPLACE_DIRFD=0;
18363 REPLACE_FDOPENDIR=0;
18364
18365
18366
18367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
18368 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
18369 if test "${gl_cv_have_include_next+set}" = set; then :
18370 $as_echo_n "(cached) " >&6
18371 else
18372 rm -rf conftestd1a conftestd1b conftestd2
18373 mkdir conftestd1a conftestd1b conftestd2
18374 cat <<EOF > conftestd1a/conftest.h
18375 #define DEFINED_IN_CONFTESTD1
18376 #include_next <conftest.h>
18377 #ifdef DEFINED_IN_CONFTESTD2
18378 int foo;
18379 #else
18380 #error "include_next doesn't work"
18381 #endif
18382 EOF
18383 cat <<EOF > conftestd1b/conftest.h
18384 #define DEFINED_IN_CONFTESTD1
18385 #include <stdio.h>
18386 #include_next <conftest.h>
18387 #ifdef DEFINED_IN_CONFTESTD2
18388 int foo;
18389 #else
18390 #error "include_next doesn't work"
18391 #endif
18392 EOF
18393 cat <<EOF > conftestd2/conftest.h
18394 #ifndef DEFINED_IN_CONFTESTD1
18395 #error "include_next test doesn't work"
18396 #endif
18397 #define DEFINED_IN_CONFTESTD2
18398 EOF
18399 gl_save_CPPFLAGS="$CPPFLAGS"
18400 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
18401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18402 /* end confdefs.h. */
18403 #include <conftest.h>
18404 _ACEOF
18405 if ac_fn_c_try_compile "$LINENO"; then :
18406 gl_cv_have_include_next=yes
18407 else
18408 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
18409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18410 /* end confdefs.h. */
18411 #include <conftest.h>
18412 _ACEOF
18413 if ac_fn_c_try_compile "$LINENO"; then :
18414 gl_cv_have_include_next=buggy
18415 else
18416 gl_cv_have_include_next=no
18417 fi
18418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18419
18420 fi
18421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18422 CPPFLAGS="$gl_save_CPPFLAGS"
18423 rm -rf conftestd1a conftestd1b conftestd2
18424
18425 fi
18426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
18427 $as_echo "$gl_cv_have_include_next" >&6; }
18428 PRAGMA_SYSTEM_HEADER=
18429 if test $gl_cv_have_include_next = yes; then
18430 INCLUDE_NEXT=include_next
18431 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18432 if test -n "$GCC"; then
18433 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
18434 fi
18435 else
18436 if test $gl_cv_have_include_next = buggy; then
18437 INCLUDE_NEXT=include
18438 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
18439 else
18440 INCLUDE_NEXT=include
18441 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
18442 fi
18443 fi
18444
18445
18446
18447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
18448 $as_echo_n "checking whether system header files limit the line length... " >&6; }
18449 if test "${gl_cv_pragma_columns+set}" = set; then :
18450 $as_echo_n "(cached) " >&6
18451 else
18452 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18453 /* end confdefs.h. */
18454
18455 #ifdef __TANDEM
18456 choke me
18457 #endif
18458
18459 _ACEOF
18460 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18461 $EGREP "choke me" >/dev/null 2>&1; then :
18462 gl_cv_pragma_columns=yes
18463 else
18464 gl_cv_pragma_columns=no
18465 fi
18466 rm -f conftest*
18467
18468
18469 fi
18470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
18471 $as_echo "$gl_cv_pragma_columns" >&6; }
18472 if test $gl_cv_pragma_columns = yes; then
18473 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
18474 else
18475 PRAGMA_COLUMNS=
18476 fi
18477
18478
18479
18480
18481
18482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
18483 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
18484 if test "${gl_cv_func_c99_strtold+set}" = set; then :
18485 $as_echo_n "(cached) " >&6
18486 else
18487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18488 /* end confdefs.h. */
18489 /* On HP-UX before 11.23, strtold returns a struct instead of
18490 long double. Reject implementations like that, by requiring
18491 compatibility with the C99 prototype. */
18492 #include <stdlib.h>
18493 static long double (*p) (char const *, char **) = strtold;
18494 static long double
18495 test (char const *nptr, char **endptr)
18496 {
18497 long double r;
18498 r = strtold (nptr, endptr);
18499 return r;
18500 }
18501 int
18502 main ()
18503 {
18504 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
18505 ;
18506 return 0;
18507 }
18508 _ACEOF
18509 if ac_fn_c_try_link "$LINENO"; then :
18510 gl_cv_func_c99_strtold=yes
18511 else
18512 gl_cv_func_c99_strtold=no
18513 fi
18514 rm -f core conftest.err conftest.$ac_objext \
18515 conftest$ac_exeext conftest.$ac_ext
18516 fi
18517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
18518 $as_echo "$gl_cv_func_c99_strtold" >&6; }
18519 if test $gl_cv_func_c99_strtold = yes; then
18520
18521 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
18522
18523 fi
18524
18525
18526
18527
18528
18529
18530
18531
18532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
18533 $as_echo_n "checking if environ is properly declared... " >&6; }
18534 if test "${gt_cv_var_environ_declaration+set}" = set; then :
18535 $as_echo_n "(cached) " >&6
18536 else
18537
18538 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18539 /* end confdefs.h. */
18540 #if HAVE_UNISTD_H
18541 #include <unistd.h>
18542 #endif
18543 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
18544 #include <stdlib.h>
18545
18546 extern struct { int foo; } environ;
18547 int
18548 main ()
18549 {
18550 environ.foo = 1;
18551 ;
18552 return 0;
18553 }
18554 _ACEOF
18555 if ac_fn_c_try_compile "$LINENO"; then :
18556 gt_cv_var_environ_declaration=no
18557 else
18558 gt_cv_var_environ_declaration=yes
18559 fi
18560 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18561 fi
18562
18563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
18564 $as_echo "$gt_cv_var_environ_declaration" >&6; }
18565 if test $gt_cv_var_environ_declaration = yes; then
18566
18567 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
18568
18569 fi
18570
18571
18572 if test $gt_cv_var_environ_declaration != yes; then
18573 HAVE_DECL_ENVIRON=0
18574 fi
18575
18576
18577
18578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for complete errno.h" >&5
18579 $as_echo_n "checking for complete errno.h... " >&6; }
18580 if test "${gl_cv_header_errno_h_complete+set}" = set; then :
18581 $as_echo_n "(cached) " >&6
18582 else
18583
18584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18585 /* end confdefs.h. */
18586
18587 #include <errno.h>
18588 #if !defined ETXTBSY
18589 booboo
18590 #endif
18591 #if !defined ENOMSG
18592 booboo
18593 #endif
18594 #if !defined EIDRM
18595 booboo
18596 #endif
18597 #if !defined ENOLINK
18598 booboo
18599 #endif
18600 #if !defined EPROTO
18601 booboo
18602 #endif
18603 #if !defined EMULTIHOP
18604 booboo
18605 #endif
18606 #if !defined EBADMSG
18607 booboo
18608 #endif
18609 #if !defined EOVERFLOW
18610 booboo
18611 #endif
18612 #if !defined ENOTSUP
18613 booboo
18614 #endif
18615 #if !defined ENETRESET
18616 booboo
18617 #endif
18618 #if !defined ECONNABORTED
18619 booboo
18620 #endif
18621 #if !defined ESTALE
18622 booboo
18623 #endif
18624 #if !defined EDQUOT
18625 booboo
18626 #endif
18627 #if !defined ECANCELED
18628 booboo
18629 #endif
18630 #if !defined EOWNERDEAD
18631 booboo
18632 #endif
18633 #if !defined ENOTRECOVERABLE
18634 booboo
18635 #endif
18636 #if !defined EILSEQ
18637 booboo
18638 #endif
18639
18640 _ACEOF
18641 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18642 $EGREP "booboo" >/dev/null 2>&1; then :
18643 gl_cv_header_errno_h_complete=no
18644 else
18645 gl_cv_header_errno_h_complete=yes
18646 fi
18647 rm -f conftest*
18648
18649
18650 fi
18651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_complete" >&5
18652 $as_echo "$gl_cv_header_errno_h_complete" >&6; }
18653 if test $gl_cv_header_errno_h_complete = yes; then
18654 ERRNO_H=''
18655 else
18656
18657
18658
18659
18660
18661
18662
18663
18664 if test $gl_cv_have_include_next = yes; then
18665 gl_cv_next_errno_h='<'errno.h'>'
18666 else
18667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <errno.h>" >&5
18668 $as_echo_n "checking absolute name of <errno.h>... " >&6; }
18669 if test "${gl_cv_next_errno_h+set}" = set; then :
18670 $as_echo_n "(cached) " >&6
18671 else
18672
18673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18674 /* end confdefs.h. */
18675 #include <errno.h>
18676
18677 _ACEOF
18678 case "$host_os" in
18679 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18680 *) gl_absname_cpp="$ac_cpp" ;;
18681 esac
18682
18683 case "$host_os" in
18684 mingw*)
18685 gl_dirsep_regex='[/\\]'
18686 ;;
18687 *)
18688 gl_dirsep_regex='\/'
18689 ;;
18690 esac
18691 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18692
18693 gl_header_literal_regex=`echo 'errno.h' \
18694 | sed -e "$gl_make_literal_regex_sed"`
18695 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18696 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18697 s|^/[^/]|//&|
18698 p
18699 q
18700 }'
18701 gl_cv_next_errno_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18702 sed -n "$gl_absolute_header_sed"`'"'
18703
18704
18705 fi
18706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_errno_h" >&5
18707 $as_echo "$gl_cv_next_errno_h" >&6; }
18708 fi
18709 NEXT_ERRNO_H=$gl_cv_next_errno_h
18710
18711 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18712 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18713 gl_next_as_first_directive='<'errno.h'>'
18714 else
18715 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18716 gl_next_as_first_directive=$gl_cv_next_errno_h
18717 fi
18718 NEXT_AS_FIRST_DIRECTIVE_ERRNO_H=$gl_next_as_first_directive
18719
18720
18721
18722
18723 ERRNO_H='errno.h'
18724 fi
18725
18726 if test -n "$ERRNO_H"; then
18727 GL_GENERATE_ERRNO_H_TRUE=
18728 GL_GENERATE_ERRNO_H_FALSE='#'
18729 else
18730 GL_GENERATE_ERRNO_H_TRUE='#'
18731 GL_GENERATE_ERRNO_H_FALSE=
18732 fi
18733
18734
18735 if test -n "$ERRNO_H"; then
18736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EMULTIHOP value" >&5
18737 $as_echo_n "checking for EMULTIHOP value... " >&6; }
18738 if test "${gl_cv_header_errno_h_EMULTIHOP+set}" = set; then :
18739 $as_echo_n "(cached) " >&6
18740 else
18741
18742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18743 /* end confdefs.h. */
18744
18745 #include <errno.h>
18746 #ifdef EMULTIHOP
18747 yes
18748 #endif
18749
18750 _ACEOF
18751 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18752 $EGREP "yes" >/dev/null 2>&1; then :
18753 gl_cv_header_errno_h_EMULTIHOP=yes
18754 else
18755 gl_cv_header_errno_h_EMULTIHOP=no
18756 fi
18757 rm -f conftest*
18758
18759 if test $gl_cv_header_errno_h_EMULTIHOP = no; then
18760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18761 /* end confdefs.h. */
18762
18763 #define _XOPEN_SOURCE_EXTENDED 1
18764 #include <errno.h>
18765 #ifdef EMULTIHOP
18766 yes
18767 #endif
18768
18769 _ACEOF
18770 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18771 $EGREP "yes" >/dev/null 2>&1; then :
18772 gl_cv_header_errno_h_EMULTIHOP=hidden
18773 fi
18774 rm -f conftest*
18775
18776 if test $gl_cv_header_errno_h_EMULTIHOP = hidden; then
18777 if ac_fn_c_compute_int "$LINENO" "EMULTIHOP" "gl_cv_header_errno_h_EMULTIHOP" "
18778 #define _XOPEN_SOURCE_EXTENDED 1
18779 #include <errno.h>
18780 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18781 #include <stdio.h>
18782 #include <stdlib.h>
18783 "; then :
18784
18785 fi
18786
18787 fi
18788 fi
18789
18790 fi
18791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EMULTIHOP" >&5
18792 $as_echo "$gl_cv_header_errno_h_EMULTIHOP" >&6; }
18793 case $gl_cv_header_errno_h_EMULTIHOP in
18794 yes | no)
18795 EMULTIHOP_HIDDEN=0; EMULTIHOP_VALUE=
18796 ;;
18797 *)
18798 EMULTIHOP_HIDDEN=1; EMULTIHOP_VALUE="$gl_cv_header_errno_h_EMULTIHOP"
18799 ;;
18800 esac
18801
18802
18803 fi
18804
18805
18806 if test -n "$ERRNO_H"; then
18807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ENOLINK value" >&5
18808 $as_echo_n "checking for ENOLINK value... " >&6; }
18809 if test "${gl_cv_header_errno_h_ENOLINK+set}" = set; then :
18810 $as_echo_n "(cached) " >&6
18811 else
18812
18813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18814 /* end confdefs.h. */
18815
18816 #include <errno.h>
18817 #ifdef ENOLINK
18818 yes
18819 #endif
18820
18821 _ACEOF
18822 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18823 $EGREP "yes" >/dev/null 2>&1; then :
18824 gl_cv_header_errno_h_ENOLINK=yes
18825 else
18826 gl_cv_header_errno_h_ENOLINK=no
18827 fi
18828 rm -f conftest*
18829
18830 if test $gl_cv_header_errno_h_ENOLINK = no; then
18831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18832 /* end confdefs.h. */
18833
18834 #define _XOPEN_SOURCE_EXTENDED 1
18835 #include <errno.h>
18836 #ifdef ENOLINK
18837 yes
18838 #endif
18839
18840 _ACEOF
18841 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18842 $EGREP "yes" >/dev/null 2>&1; then :
18843 gl_cv_header_errno_h_ENOLINK=hidden
18844 fi
18845 rm -f conftest*
18846
18847 if test $gl_cv_header_errno_h_ENOLINK = hidden; then
18848 if ac_fn_c_compute_int "$LINENO" "ENOLINK" "gl_cv_header_errno_h_ENOLINK" "
18849 #define _XOPEN_SOURCE_EXTENDED 1
18850 #include <errno.h>
18851 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18852 #include <stdio.h>
18853 #include <stdlib.h>
18854 "; then :
18855
18856 fi
18857
18858 fi
18859 fi
18860
18861 fi
18862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_ENOLINK" >&5
18863 $as_echo "$gl_cv_header_errno_h_ENOLINK" >&6; }
18864 case $gl_cv_header_errno_h_ENOLINK in
18865 yes | no)
18866 ENOLINK_HIDDEN=0; ENOLINK_VALUE=
18867 ;;
18868 *)
18869 ENOLINK_HIDDEN=1; ENOLINK_VALUE="$gl_cv_header_errno_h_ENOLINK"
18870 ;;
18871 esac
18872
18873
18874 fi
18875
18876
18877 if test -n "$ERRNO_H"; then
18878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EOVERFLOW value" >&5
18879 $as_echo_n "checking for EOVERFLOW value... " >&6; }
18880 if test "${gl_cv_header_errno_h_EOVERFLOW+set}" = set; then :
18881 $as_echo_n "(cached) " >&6
18882 else
18883
18884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18885 /* end confdefs.h. */
18886
18887 #include <errno.h>
18888 #ifdef EOVERFLOW
18889 yes
18890 #endif
18891
18892 _ACEOF
18893 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18894 $EGREP "yes" >/dev/null 2>&1; then :
18895 gl_cv_header_errno_h_EOVERFLOW=yes
18896 else
18897 gl_cv_header_errno_h_EOVERFLOW=no
18898 fi
18899 rm -f conftest*
18900
18901 if test $gl_cv_header_errno_h_EOVERFLOW = no; then
18902 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18903 /* end confdefs.h. */
18904
18905 #define _XOPEN_SOURCE_EXTENDED 1
18906 #include <errno.h>
18907 #ifdef EOVERFLOW
18908 yes
18909 #endif
18910
18911 _ACEOF
18912 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18913 $EGREP "yes" >/dev/null 2>&1; then :
18914 gl_cv_header_errno_h_EOVERFLOW=hidden
18915 fi
18916 rm -f conftest*
18917
18918 if test $gl_cv_header_errno_h_EOVERFLOW = hidden; then
18919 if ac_fn_c_compute_int "$LINENO" "EOVERFLOW" "gl_cv_header_errno_h_EOVERFLOW" "
18920 #define _XOPEN_SOURCE_EXTENDED 1
18921 #include <errno.h>
18922 /* The following two lines are a workaround against an autoconf-2.52 bug. */
18923 #include <stdio.h>
18924 #include <stdlib.h>
18925 "; then :
18926
18927 fi
18928
18929 fi
18930 fi
18931
18932 fi
18933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_errno_h_EOVERFLOW" >&5
18934 $as_echo "$gl_cv_header_errno_h_EOVERFLOW" >&6; }
18935 case $gl_cv_header_errno_h_EOVERFLOW in
18936 yes | no)
18937 EOVERFLOW_HIDDEN=0; EOVERFLOW_VALUE=
18938 ;;
18939 *)
18940 EOVERFLOW_HIDDEN=1; EOVERFLOW_VALUE="$gl_cv_header_errno_h_EOVERFLOW"
18941 ;;
18942 esac
18943
18944
18945 fi
18946
18947
18948
18949
18950
18951
18952
18953
18954
18955
18956 GNULIB_FCNTL=0;
18957 GNULIB_NONBLOCKING=0;
18958 GNULIB_OPEN=0;
18959 GNULIB_OPENAT=0;
18960 HAVE_FCNTL=1;
18961 HAVE_OPENAT=1;
18962 REPLACE_FCNTL=0;
18963 REPLACE_OPEN=0;
18964 REPLACE_OPENAT=0;
18965
18966
18967
18968
18969 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18970 if test "x$ac_cv_type_mode_t" = x""yes; then :
18971
18972 else
18973
18974 cat >>confdefs.h <<_ACEOF
18975 #define mode_t int
18976 _ACEOF
18977
18978 fi
18979
18980 ac_fn_c_check_decl "$LINENO" "fdatasync" "ac_cv_have_decl_fdatasync" "$ac_includes_default"
18981 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then :
18982 ac_have_decl=1
18983 else
18984 ac_have_decl=0
18985 fi
18986
18987 cat >>confdefs.h <<_ACEOF
18988 #define HAVE_DECL_FDATASYNC $ac_have_decl
18989 _ACEOF
18990
18991
18992
18993 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
18994 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
18995 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
18996 $as_echo_n "(cached) " >&6
18997 else
18998 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18999 /* end confdefs.h. */
19000
19001 #include <sys/types.h>
19002 #include <sys/stat.h>
19003 int
19004 main ()
19005 {
19006 struct stat s; s.st_dm_mode;
19007 ;
19008 return 0;
19009 }
19010 _ACEOF
19011 if ac_fn_c_try_compile "$LINENO"; then :
19012 ac_cv_struct_st_dm_mode=yes
19013 else
19014 ac_cv_struct_st_dm_mode=no
19015 fi
19016 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19017 fi
19018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
19019 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
19020
19021 if test $ac_cv_struct_st_dm_mode = yes; then
19022
19023 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
19024
19025 fi
19026
19027
19028 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
19029 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
19030 ac_have_decl=1
19031 else
19032 ac_have_decl=0
19033 fi
19034
19035 cat >>confdefs.h <<_ACEOF
19036 #define HAVE_DECL_STRMODE $ac_have_decl
19037 _ACEOF
19038
19039
19040
19041
19042 GNULIB_FCHMODAT=0;
19043 GNULIB_FSTAT=0;
19044 GNULIB_FSTATAT=0;
19045 GNULIB_FUTIMENS=0;
19046 GNULIB_LCHMOD=0;
19047 GNULIB_LSTAT=0;
19048 GNULIB_MKDIRAT=0;
19049 GNULIB_MKFIFO=0;
19050 GNULIB_MKFIFOAT=0;
19051 GNULIB_MKNOD=0;
19052 GNULIB_MKNODAT=0;
19053 GNULIB_STAT=0;
19054 GNULIB_UTIMENSAT=0;
19055 HAVE_FCHMODAT=1;
19056 HAVE_FSTATAT=1;
19057 HAVE_FUTIMENS=1;
19058 HAVE_LCHMOD=1;
19059 HAVE_LSTAT=1;
19060 HAVE_MKDIRAT=1;
19061 HAVE_MKFIFO=1;
19062 HAVE_MKFIFOAT=1;
19063 HAVE_MKNOD=1;
19064 HAVE_MKNODAT=1;
19065 HAVE_UTIMENSAT=1;
19066 REPLACE_FSTAT=0;
19067 REPLACE_FSTATAT=0;
19068 REPLACE_FUTIMENS=0;
19069 REPLACE_LSTAT=0;
19070 REPLACE_MKDIR=0;
19071 REPLACE_MKFIFO=0;
19072 REPLACE_MKNOD=0;
19073 REPLACE_STAT=0;
19074 REPLACE_UTIMENSAT=0;
19075
19076
19077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
19078 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
19079 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
19080 $as_echo_n "(cached) " >&6
19081 else
19082 rm -f conftest.sym conftest.file
19083 echo >conftest.file
19084 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
19085 if test "$cross_compiling" = yes; then :
19086 case "$host_os" in
19087 # Guess yes on glibc systems.
19088 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
19089 # If we don't know, assume the worst.
19090 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
19091 esac
19092
19093 else
19094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19095 /* end confdefs.h. */
19096 $ac_includes_default
19097 int
19098 main ()
19099 {
19100 struct stat sbuf;
19101 /* Linux will dereference the symlink and fail, as required by
19102 POSIX. That is better in the sense that it means we will not
19103 have to compile and use the lstat wrapper. */
19104 return lstat ("conftest.sym/", &sbuf) == 0;
19105
19106 ;
19107 return 0;
19108 }
19109 _ACEOF
19110 if ac_fn_c_try_run "$LINENO"; then :
19111 gl_cv_func_lstat_dereferences_slashed_symlink=yes
19112 else
19113 gl_cv_func_lstat_dereferences_slashed_symlink=no
19114 fi
19115 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19116 conftest.$ac_objext conftest.beam conftest.$ac_ext
19117 fi
19118
19119 else
19120 # If the 'ln -s' command failed, then we probably don't even
19121 # have an lstat function.
19122 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
19123 fi
19124 rm -f conftest.sym conftest.file
19125
19126 fi
19127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
19128 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
19129 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
19130 *yes)
19131
19132 cat >>confdefs.h <<_ACEOF
19133 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
19134 _ACEOF
19135
19136 ;;
19137 esac
19138
19139
19140
19141
19142
19143
19144 GNULIB__EXIT=0;
19145 GNULIB_ATOLL=0;
19146 GNULIB_CALLOC_POSIX=0;
19147 GNULIB_CANONICALIZE_FILE_NAME=0;
19148 GNULIB_GETLOADAVG=0;
19149 GNULIB_GETSUBOPT=0;
19150 GNULIB_GRANTPT=0;
19151 GNULIB_MALLOC_POSIX=0;
19152 GNULIB_MBTOWC=0;
19153 GNULIB_MKDTEMP=0;
19154 GNULIB_MKOSTEMP=0;
19155 GNULIB_MKOSTEMPS=0;
19156 GNULIB_MKSTEMP=0;
19157 GNULIB_MKSTEMPS=0;
19158 GNULIB_POSIX_OPENPT=0;
19159 GNULIB_PTSNAME=0;
19160 GNULIB_PTSNAME_R=0;
19161 GNULIB_PUTENV=0;
19162 GNULIB_RANDOM=0;
19163 GNULIB_RANDOM_R=0;
19164 GNULIB_REALLOC_POSIX=0;
19165 GNULIB_REALPATH=0;
19166 GNULIB_RPMATCH=0;
19167 GNULIB_SECURE_GETENV=0;
19168 GNULIB_SETENV=0;
19169 GNULIB_STRTOD=0;
19170 GNULIB_STRTOLL=0;
19171 GNULIB_STRTOULL=0;
19172 GNULIB_SYSTEM_POSIX=0;
19173 GNULIB_UNLOCKPT=0;
19174 GNULIB_UNSETENV=0;
19175 GNULIB_WCTOMB=0;
19176 HAVE__EXIT=1;
19177 HAVE_ATOLL=1;
19178 HAVE_CANONICALIZE_FILE_NAME=1;
19179 HAVE_DECL_GETLOADAVG=1;
19180 HAVE_GETSUBOPT=1;
19181 HAVE_GRANTPT=1;
19182 HAVE_MKDTEMP=1;
19183 HAVE_MKOSTEMP=1;
19184 HAVE_MKOSTEMPS=1;
19185 HAVE_MKSTEMP=1;
19186 HAVE_MKSTEMPS=1;
19187 HAVE_POSIX_OPENPT=1;
19188 HAVE_PTSNAME=1;
19189 HAVE_PTSNAME_R=1;
19190 HAVE_RANDOM=1;
19191 HAVE_RANDOM_H=1;
19192 HAVE_RANDOM_R=1;
19193 HAVE_REALPATH=1;
19194 HAVE_RPMATCH=1;
19195 HAVE_SECURE_GETENV=1;
19196 HAVE_SETENV=1;
19197 HAVE_DECL_SETENV=1;
19198 HAVE_STRTOD=1;
19199 HAVE_STRTOLL=1;
19200 HAVE_STRTOULL=1;
19201 HAVE_STRUCT_RANDOM_DATA=1;
19202 HAVE_SYS_LOADAVG_H=0;
19203 HAVE_UNLOCKPT=1;
19204 HAVE_DECL_UNSETENV=1;
19205 REPLACE_CALLOC=0;
19206 REPLACE_CANONICALIZE_FILE_NAME=0;
19207 REPLACE_MALLOC=0;
19208 REPLACE_MBTOWC=0;
19209 REPLACE_MKSTEMP=0;
19210 REPLACE_PTSNAME=0;
19211 REPLACE_PTSNAME_R=0;
19212 REPLACE_PUTENV=0;
19213 REPLACE_RANDOM_R=0;
19214 REPLACE_REALLOC=0;
19215 REPLACE_REALPATH=0;
19216 REPLACE_SETENV=0;
19217 REPLACE_STRTOD=0;
19218 REPLACE_UNSETENV=0;
19219 REPLACE_WCTOMB=0;
19220
19221
19222
19223
19224
19225
19226
19227
19228
19229
19230
19231
19232
19233
19234
19235
19236 if test $gl_cv_have_include_next = yes; then
19237 gl_cv_next_getopt_h='<'getopt.h'>'
19238 else
19239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
19240 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
19241 if test "${gl_cv_next_getopt_h+set}" = set; then :
19242 $as_echo_n "(cached) " >&6
19243 else
19244
19245 if test $ac_cv_header_getopt_h = yes; then
19246
19247
19248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19249 /* end confdefs.h. */
19250 #include <getopt.h>
19251
19252 _ACEOF
19253 case "$host_os" in
19254 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19255 *) gl_absname_cpp="$ac_cpp" ;;
19256 esac
19257
19258 case "$host_os" in
19259 mingw*)
19260 gl_dirsep_regex='[/\\]'
19261 ;;
19262 *)
19263 gl_dirsep_regex='\/'
19264 ;;
19265 esac
19266 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19267
19268 gl_header_literal_regex=`echo 'getopt.h' \
19269 | sed -e "$gl_make_literal_regex_sed"`
19270 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19271 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19272 s|^/[^/]|//&|
19273 p
19274 q
19275 }'
19276 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19277 sed -n "$gl_absolute_header_sed"`'"'
19278 else
19279 gl_cv_next_getopt_h='<'getopt.h'>'
19280 fi
19281
19282
19283 fi
19284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
19285 $as_echo "$gl_cv_next_getopt_h" >&6; }
19286 fi
19287 NEXT_GETOPT_H=$gl_cv_next_getopt_h
19288
19289 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19290 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19291 gl_next_as_first_directive='<'getopt.h'>'
19292 else
19293 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19294 gl_next_as_first_directive=$gl_cv_next_getopt_h
19295 fi
19296 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
19297
19298
19299
19300
19301 if test $ac_cv_header_getopt_h = yes; then
19302 HAVE_GETOPT_H=1
19303 else
19304 HAVE_GETOPT_H=0
19305 fi
19306
19307
19308 gl_replace_getopt=
19309
19310 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19311 for ac_header in getopt.h
19312 do :
19313 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
19314 if test "x$ac_cv_header_getopt_h" = x""yes; then :
19315 cat >>confdefs.h <<_ACEOF
19316 #define HAVE_GETOPT_H 1
19317 _ACEOF
19318
19319 else
19320 gl_replace_getopt=yes
19321 fi
19322
19323 done
19324
19325 fi
19326
19327 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19328 for ac_func in getopt_long_only
19329 do :
19330 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
19331 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
19332 cat >>confdefs.h <<_ACEOF
19333 #define HAVE_GETOPT_LONG_ONLY 1
19334 _ACEOF
19335
19336 else
19337 gl_replace_getopt=yes
19338 fi
19339 done
19340
19341 fi
19342
19343 if test -z "$gl_replace_getopt"; then
19344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
19345 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
19346 if test "${gl_cv_func_getopt_posix+set}" = set; then :
19347 $as_echo_n "(cached) " >&6
19348 else
19349
19350 if test $cross_compiling = no; then
19351 if test "$cross_compiling" = yes; then :
19352 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19353 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19354 as_fn_error "cannot run test program while cross compiling
19355 See \`config.log' for more details." "$LINENO" 5; }
19356 else
19357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19358 /* end confdefs.h. */
19359
19360 #include <unistd.h>
19361 #include <stdlib.h>
19362 #include <string.h>
19363
19364 int
19365 main ()
19366 {
19367 static char program[] = "program";
19368 static char a[] = "-a";
19369 static char foo[] = "foo";
19370 static char bar[] = "bar";
19371 char *argv[] = { program, a, foo, bar, NULL };
19372 int c;
19373
19374 c = getopt (4, argv, "ab");
19375 if (!(c == 'a'))
19376 return 1;
19377 c = getopt (4, argv, "ab");
19378 if (!(c == -1))
19379 return 2;
19380 if (!(optind == 2))
19381 return 3;
19382 return 0;
19383 }
19384
19385 _ACEOF
19386 if ac_fn_c_try_run "$LINENO"; then :
19387 gl_cv_func_getopt_posix=maybe
19388 else
19389 gl_cv_func_getopt_posix=no
19390 fi
19391 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19392 conftest.$ac_objext conftest.beam conftest.$ac_ext
19393 fi
19394
19395 if test $gl_cv_func_getopt_posix = maybe; then
19396 if test "$cross_compiling" = yes; then :
19397 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19398 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19399 as_fn_error "cannot run test program while cross compiling
19400 See \`config.log' for more details." "$LINENO" 5; }
19401 else
19402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19403 /* end confdefs.h. */
19404
19405 #include <unistd.h>
19406 #include <stdlib.h>
19407 #include <string.h>
19408
19409 int
19410 main ()
19411 {
19412 static char program[] = "program";
19413 static char donald[] = "donald";
19414 static char p[] = "-p";
19415 static char billy[] = "billy";
19416 static char duck[] = "duck";
19417 static char a[] = "-a";
19418 static char bar[] = "bar";
19419 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
19420 int c;
19421
19422 c = getopt (7, argv, "+abp:q:");
19423 if (!(c == -1))
19424 return 4;
19425 if (!(strcmp (argv[0], "program") == 0))
19426 return 5;
19427 if (!(strcmp (argv[1], "donald") == 0))
19428 return 6;
19429 if (!(strcmp (argv[2], "-p") == 0))
19430 return 7;
19431 if (!(strcmp (argv[3], "billy") == 0))
19432 return 8;
19433 if (!(strcmp (argv[4], "duck") == 0))
19434 return 9;
19435 if (!(strcmp (argv[5], "-a") == 0))
19436 return 10;
19437 if (!(strcmp (argv[6], "bar") == 0))
19438 return 11;
19439 if (!(optind == 1))
19440 return 12;
19441 return 0;
19442 }
19443
19444 _ACEOF
19445 if ac_fn_c_try_run "$LINENO"; then :
19446 gl_cv_func_getopt_posix=maybe
19447 else
19448 gl_cv_func_getopt_posix=no
19449 fi
19450 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19451 conftest.$ac_objext conftest.beam conftest.$ac_ext
19452 fi
19453
19454 fi
19455 if test $gl_cv_func_getopt_posix = maybe; then
19456 if test "$cross_compiling" = yes; then :
19457 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
19458 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
19459 as_fn_error "cannot run test program while cross compiling
19460 See \`config.log' for more details." "$LINENO" 5; }
19461 else
19462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19463 /* end confdefs.h. */
19464
19465 #include <unistd.h>
19466 #include <stdlib.h>
19467 #include <string.h>
19468
19469 int
19470 main ()
19471 {
19472 static char program[] = "program";
19473 static char ab[] = "-ab";
19474 char *argv[3] = { program, ab, NULL };
19475 if (getopt (2, argv, "ab:") != 'a')
19476 return 13;
19477 if (getopt (2, argv, "ab:") != '?')
19478 return 14;
19479 if (optopt != 'b')
19480 return 15;
19481 if (optind != 2)
19482 return 16;
19483 return 0;
19484 }
19485
19486 _ACEOF
19487 if ac_fn_c_try_run "$LINENO"; then :
19488 gl_cv_func_getopt_posix=yes
19489 else
19490 gl_cv_func_getopt_posix=no
19491 fi
19492 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19493 conftest.$ac_objext conftest.beam conftest.$ac_ext
19494 fi
19495
19496 fi
19497 else
19498 case "$host_os" in
19499 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
19500 *) gl_cv_func_getopt_posix="guessing yes";;
19501 esac
19502 fi
19503
19504 fi
19505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
19506 $as_echo "$gl_cv_func_getopt_posix" >&6; }
19507 case "$gl_cv_func_getopt_posix" in
19508 *no) gl_replace_getopt=yes ;;
19509 esac
19510 fi
19511
19512 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
19513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
19514 $as_echo_n "checking for working GNU getopt function... " >&6; }
19515 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
19516 $as_echo_n "(cached) " >&6
19517 else
19518 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
19519 # optstring is necessary for programs like m4 that have POSIX-mandated
19520 # semantics for supporting options interspersed with files.
19521 # Also, since getopt_long is a GNU extension, we require optind=0.
19522 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
19523 # so take care to revert to the correct (non-)export state.
19524 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
19525 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
19526 xx) gl_had_POSIXLY_CORRECT=exported ;;
19527 x) gl_had_POSIXLY_CORRECT=yes ;;
19528 *) gl_had_POSIXLY_CORRECT= ;;
19529 esac
19530 POSIXLY_CORRECT=1
19531 export POSIXLY_CORRECT
19532 if test "$cross_compiling" = yes; then :
19533 gl_cv_func_getopt_gnu="guessing no"
19534
19535 else
19536 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19537 /* end confdefs.h. */
19538 #include <getopt.h>
19539 #include <stddef.h>
19540 #include <string.h>
19541
19542 #include <stdlib.h>
19543 #if defined __MACH__ && defined __APPLE__
19544 /* Avoid a crash on Mac OS X. */
19545 #include <mach/mach.h>
19546 #include <mach/mach_error.h>
19547 #include <mach/thread_status.h>
19548 #include <mach/exception.h>
19549 #include <mach/task.h>
19550 #include <pthread.h>
19551 /* The exception port on which our thread listens. */
19552 static mach_port_t our_exception_port;
19553 /* The main function of the thread listening for exceptions of type
19554 EXC_BAD_ACCESS. */
19555 static void *
19556 mach_exception_thread (void *arg)
19557 {
19558 /* Buffer for a message to be received. */
19559 struct {
19560 mach_msg_header_t head;
19561 mach_msg_body_t msgh_body;
19562 char data[1024];
19563 } msg;
19564 mach_msg_return_t retval;
19565 /* Wait for a message on the exception port. */
19566 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
19567 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
19568 if (retval != MACH_MSG_SUCCESS)
19569 abort ();
19570 exit (1);
19571 }
19572 static void
19573 nocrash_init (void)
19574 {
19575 mach_port_t self = mach_task_self ();
19576 /* Allocate a port on which the thread shall listen for exceptions. */
19577 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
19578 == KERN_SUCCESS) {
19579 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
19580 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
19581 MACH_MSG_TYPE_MAKE_SEND)
19582 == KERN_SUCCESS) {
19583 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
19584 for us. */
19585 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
19586 /* Create the thread listening on the exception port. */
19587 pthread_attr_t attr;
19588 pthread_t thread;
19589 if (pthread_attr_init (&attr) == 0
19590 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
19591 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
19592 pthread_attr_destroy (&attr);
19593 /* Replace the exception port info for these exceptions with our own.
19594 Note that we replace the exception port for the entire task, not only
19595 for a particular thread. This has the effect that when our exception
19596 port gets the message, the thread specific exception port has already
19597 been asked, and we don't need to bother about it.
19598 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
19599 task_set_exception_ports (self, mask, our_exception_port,
19600 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
19601 }
19602 }
19603 }
19604 }
19605 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
19606 /* Avoid a crash on native Windows. */
19607 #define WIN32_LEAN_AND_MEAN
19608 #include <windows.h>
19609 #include <winerror.h>
19610 static LONG WINAPI
19611 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
19612 {
19613 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
19614 {
19615 case EXCEPTION_ACCESS_VIOLATION:
19616 case EXCEPTION_IN_PAGE_ERROR:
19617 case EXCEPTION_STACK_OVERFLOW:
19618 case EXCEPTION_GUARD_PAGE:
19619 case EXCEPTION_PRIV_INSTRUCTION:
19620 case EXCEPTION_ILLEGAL_INSTRUCTION:
19621 case EXCEPTION_DATATYPE_MISALIGNMENT:
19622 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
19623 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
19624 exit (1);
19625 }
19626 return EXCEPTION_CONTINUE_SEARCH;
19627 }
19628 static void
19629 nocrash_init (void)
19630 {
19631 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
19632 }
19633 #else
19634 /* Avoid a crash on POSIX systems. */
19635 #include <signal.h>
19636 /* A POSIX signal handler. */
19637 static void
19638 exception_handler (int sig)
19639 {
19640 exit (1);
19641 }
19642 static void
19643 nocrash_init (void)
19644 {
19645 #ifdef SIGSEGV
19646 signal (SIGSEGV, exception_handler);
19647 #endif
19648 #ifdef SIGBUS
19649 signal (SIGBUS, exception_handler);
19650 #endif
19651 }
19652 #endif
19653
19654
19655 int
19656 main ()
19657 {
19658
19659 int result = 0;
19660
19661 nocrash_init();
19662
19663 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
19664 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
19665 OSF/1 5.1, Solaris 10. */
19666 {
19667 static char conftest[] = "conftest";
19668 static char plus[] = "-+";
19669 char *argv[3] = { conftest, plus, NULL };
19670 opterr = 0;
19671 if (getopt (2, argv, "+a") != '?')
19672 result |= 1;
19673 }
19674 /* This code succeeds on glibc 2.8, mingw,
19675 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
19676 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
19677 {
19678 static char program[] = "program";
19679 static char p[] = "-p";
19680 static char foo[] = "foo";
19681 static char bar[] = "bar";
19682 char *argv[] = { program, p, foo, bar, NULL };
19683
19684 optind = 1;
19685 if (getopt (4, argv, "p::") != 'p')
19686 result |= 2;
19687 else if (optarg != NULL)
19688 result |= 4;
19689 else if (getopt (4, argv, "p::") != -1)
19690 result |= 6;
19691 else if (optind != 2)
19692 result |= 8;
19693 }
19694 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
19695 {
19696 static char program[] = "program";
19697 static char foo[] = "foo";
19698 static char p[] = "-p";
19699 char *argv[] = { program, foo, p, NULL };
19700 optind = 0;
19701 if (getopt (3, argv, "-p") != 1)
19702 result |= 16;
19703 else if (getopt (3, argv, "-p") != 'p')
19704 result |= 16;
19705 }
19706 /* This code fails on glibc 2.11. */
19707 {
19708 static char program[] = "program";
19709 static char b[] = "-b";
19710 static char a[] = "-a";
19711 char *argv[] = { program, b, a, NULL };
19712 optind = opterr = 0;
19713 if (getopt (3, argv, "+:a:b") != 'b')
19714 result |= 32;
19715 else if (getopt (3, argv, "+:a:b") != ':')
19716 result |= 32;
19717 }
19718 /* This code dumps core on glibc 2.14. */
19719 {
19720 static char program[] = "program";
19721 static char w[] = "-W";
19722 static char dummy[] = "dummy";
19723 char *argv[] = { program, w, dummy, NULL };
19724 optind = opterr = 1;
19725 if (getopt (3, argv, "W;") != 'W')
19726 result |= 64;
19727 }
19728 return result;
19729
19730 ;
19731 return 0;
19732 }
19733 _ACEOF
19734 if ac_fn_c_try_run "$LINENO"; then :
19735 gl_cv_func_getopt_gnu=yes
19736 else
19737 gl_cv_func_getopt_gnu=no
19738 fi
19739 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19740 conftest.$ac_objext conftest.beam conftest.$ac_ext
19741 fi
19742
19743 case $gl_had_POSIXLY_CORRECT in
19744 exported) ;;
19745 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
19746 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
19747 esac
19748
19749 fi
19750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
19751 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
19752 if test "$gl_cv_func_getopt_gnu" != yes; then
19753 gl_replace_getopt=yes
19754 else
19755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
19756 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
19757 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
19758 $as_echo_n "(cached) " >&6
19759 else
19760 if test "$cross_compiling" = yes; then :
19761 case "$host_os" in
19762 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
19763 *) gl_cv_func_getopt_long_gnu="guessing yes";;
19764 esac
19765
19766 else
19767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19768 /* end confdefs.h. */
19769 #include <getopt.h>
19770 #include <stddef.h>
19771 #include <string.h>
19772
19773 int
19774 main ()
19775 {
19776 static const struct option long_options[] =
19777 {
19778 { "xtremely-",no_argument, NULL, 1003 },
19779 { "xtra", no_argument, NULL, 1001 },
19780 { "xtreme", no_argument, NULL, 1002 },
19781 { "xtremely", no_argument, NULL, 1003 },
19782 { NULL, 0, NULL, 0 }
19783 };
19784 /* This code fails on OpenBSD 5.0. */
19785 {
19786 static char program[] = "program";
19787 static char xtremel[] = "--xtremel";
19788 char *argv[] = { program, xtremel, NULL };
19789 int option_index;
19790 optind = 1; opterr = 0;
19791 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
19792 return 1;
19793 }
19794 return 0;
19795
19796 ;
19797 return 0;
19798 }
19799 _ACEOF
19800 if ac_fn_c_try_run "$LINENO"; then :
19801 gl_cv_func_getopt_long_gnu=yes
19802 else
19803 gl_cv_func_getopt_long_gnu=no
19804 fi
19805 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19806 conftest.$ac_objext conftest.beam conftest.$ac_ext
19807 fi
19808
19809
19810 fi
19811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
19812 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
19813 case "$gl_cv_func_getopt_long_gnu" in
19814 *yes) ;;
19815 *) gl_replace_getopt=yes ;;
19816 esac
19817 fi
19818 fi
19819
19820
19821
19822
19823
19824
19825 REPLACE_GETOPT=0
19826 if test -n "$gl_replace_getopt"; then
19827 REPLACE_GETOPT=1
19828 fi
19829
19830 if test $REPLACE_GETOPT = 1; then
19831
19832 GETOPT_H=getopt.h
19833
19834 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19835
19836
19837
19838 fi
19839
19840 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
19841 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
19842 ac_have_decl=1
19843 else
19844 ac_have_decl=0
19845 fi
19846
19847 cat >>confdefs.h <<_ACEOF
19848 #define HAVE_DECL_GETENV $ac_have_decl
19849 _ACEOF
19850
19851 :
19852
19853
19854
19855
19856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
19857 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
19858 if test "${ac_cv_c_restrict+set}" = set; then :
19859 $as_echo_n "(cached) " >&6
19860 else
19861 ac_cv_c_restrict=no
19862 # The order here caters to the fact that C++ does not require restrict.
19863 for ac_kw in __restrict __restrict__ _Restrict restrict; do
19864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19865 /* end confdefs.h. */
19866 typedef int * int_ptr;
19867 int foo (int_ptr $ac_kw ip) {
19868 return ip[0];
19869 }
19870 int
19871 main ()
19872 {
19873 int s[1];
19874 int * $ac_kw t = s;
19875 t[0] = 0;
19876 return foo(t)
19877 ;
19878 return 0;
19879 }
19880 _ACEOF
19881 if ac_fn_c_try_compile "$LINENO"; then :
19882 ac_cv_c_restrict=$ac_kw
19883 fi
19884 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19885 test "$ac_cv_c_restrict" != no && break
19886 done
19887
19888 fi
19889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
19890 $as_echo "$ac_cv_c_restrict" >&6; }
19891
19892 case $ac_cv_c_restrict in
19893 restrict) ;;
19894 no) $as_echo "#define restrict /**/" >>confdefs.h
19895 ;;
19896 *) cat >>confdefs.h <<_ACEOF
19897 #define restrict $ac_cv_c_restrict
19898 _ACEOF
19899 ;;
19900 esac
19901
19902
19903 GNULIB_GETTIMEOFDAY=0;
19904 HAVE_GETTIMEOFDAY=1;
19905 HAVE_STRUCT_TIMEVAL=1;
19906 HAVE_SYS_TIME_H=1;
19907 REPLACE_GETTIMEOFDAY=0;
19908 REPLACE_STRUCT_TIMEVAL=0;
19909
19910
19911
19912
19913
19914
19915
19916
19917
19918
19919
19920
19921
19922
19923
19924
19925 if test $gl_cv_have_include_next = yes; then
19926 gl_cv_next_sys_time_h='<'sys/time.h'>'
19927 else
19928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
19929 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
19930 if test "${gl_cv_next_sys_time_h+set}" = set; then :
19931 $as_echo_n "(cached) " >&6
19932 else
19933
19934 if test $ac_cv_header_sys_time_h = yes; then
19935
19936
19937 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19938 /* end confdefs.h. */
19939 #include <sys/time.h>
19940
19941 _ACEOF
19942 case "$host_os" in
19943 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19944 *) gl_absname_cpp="$ac_cpp" ;;
19945 esac
19946
19947 case "$host_os" in
19948 mingw*)
19949 gl_dirsep_regex='[/\\]'
19950 ;;
19951 *)
19952 gl_dirsep_regex='\/'
19953 ;;
19954 esac
19955 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19956
19957 gl_header_literal_regex=`echo 'sys/time.h' \
19958 | sed -e "$gl_make_literal_regex_sed"`
19959 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19960 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19961 s|^/[^/]|//&|
19962 p
19963 q
19964 }'
19965 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19966 sed -n "$gl_absolute_header_sed"`'"'
19967 else
19968 gl_cv_next_sys_time_h='<'sys/time.h'>'
19969 fi
19970
19971
19972 fi
19973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
19974 $as_echo "$gl_cv_next_sys_time_h" >&6; }
19975 fi
19976 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
19977
19978 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19979 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19980 gl_next_as_first_directive='<'sys/time.h'>'
19981 else
19982 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19983 gl_next_as_first_directive=$gl_cv_next_sys_time_h
19984 fi
19985 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
19986
19987
19988
19989
19990
19991 if test $ac_cv_header_sys_time_h != yes; then
19992 HAVE_SYS_TIME_H=0
19993 fi
19994
19995
19996
19997
19998
19999 if test $ac_cv_header_sys_socket_h != yes; then
20000 for ac_header in winsock2.h
20001 do :
20002 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
20003 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
20004 cat >>confdefs.h <<_ACEOF
20005 #define HAVE_WINSOCK2_H 1
20006 _ACEOF
20007
20008 fi
20009
20010 done
20011
20012 fi
20013 if test "$ac_cv_header_winsock2_h" = yes; then
20014 HAVE_WINSOCK2_H=1
20015 UNISTD_H_HAVE_WINSOCK2_H=1
20016 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
20017 else
20018 HAVE_WINSOCK2_H=0
20019 fi
20020
20021
20022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
20023 $as_echo_n "checking for struct timeval... " >&6; }
20024 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
20025 $as_echo_n "(cached) " >&6
20026 else
20027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20028 /* end confdefs.h. */
20029 #if HAVE_SYS_TIME_H
20030 #include <sys/time.h>
20031 #endif
20032 #include <time.h>
20033 #if HAVE_WINSOCK2_H
20034 # include <winsock2.h>
20035 #endif
20036
20037 int
20038 main ()
20039 {
20040 static struct timeval x; x.tv_sec = x.tv_usec;
20041 ;
20042 return 0;
20043 }
20044 _ACEOF
20045 if ac_fn_c_try_compile "$LINENO"; then :
20046 gl_cv_sys_struct_timeval=yes
20047 else
20048 gl_cv_sys_struct_timeval=no
20049 fi
20050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20051
20052 fi
20053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
20054 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
20055 if test $gl_cv_sys_struct_timeval != yes; then
20056 HAVE_STRUCT_TIMEVAL=0
20057 else
20058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
20059 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
20060 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
20061 $as_echo_n "(cached) " >&6
20062 else
20063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20064 /* end confdefs.h. */
20065 #if HAVE_SYS_TIME_H
20066 #include <sys/time.h>
20067 #endif
20068 #include <time.h>
20069 #if HAVE_WINSOCK2_H
20070 # include <winsock2.h>
20071 #endif
20072
20073 int
20074 main ()
20075 {
20076 static struct timeval x;
20077 typedef int verify_tv_sec_type[
20078 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
20079 ];
20080
20081 ;
20082 return 0;
20083 }
20084 _ACEOF
20085 if ac_fn_c_try_compile "$LINENO"; then :
20086 gl_cv_sys_struct_timeval_tv_sec=yes
20087 else
20088 gl_cv_sys_struct_timeval_tv_sec=no
20089 fi
20090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20091
20092 fi
20093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
20094 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
20095 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
20096 REPLACE_STRUCT_TIMEVAL=1
20097 fi
20098 fi
20099
20100
20101
20102
20103
20104
20105
20106
20107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
20108 $as_echo_n "checking for long long int... " >&6; }
20109 if test "${ac_cv_type_long_long_int+set}" = set; then :
20110 $as_echo_n "(cached) " >&6
20111 else
20112 ac_cv_type_long_long_int=yes
20113 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
20114 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
20115 if test $ac_cv_type_long_long_int = yes; then
20116 if test "$cross_compiling" = yes; then :
20117 :
20118 else
20119 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20120 /* end confdefs.h. */
20121 #include <limits.h>
20122 #ifndef LLONG_MAX
20123 # define HALF \
20124 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
20125 # define LLONG_MAX (HALF - 1 + HALF)
20126 #endif
20127 int
20128 main ()
20129 {
20130 long long int n = 1;
20131 int i;
20132 for (i = 0; ; i++)
20133 {
20134 long long int m = n << i;
20135 if (m >> i != n)
20136 return 1;
20137 if (LLONG_MAX / 2 < m)
20138 break;
20139 }
20140 return 0;
20141 ;
20142 return 0;
20143 }
20144 _ACEOF
20145 if ac_fn_c_try_run "$LINENO"; then :
20146
20147 else
20148 ac_cv_type_long_long_int=no
20149 fi
20150 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20151 conftest.$ac_objext conftest.beam conftest.$ac_ext
20152 fi
20153
20154 fi
20155 fi
20156 fi
20157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
20158 $as_echo "$ac_cv_type_long_long_int" >&6; }
20159 if test $ac_cv_type_long_long_int = yes; then
20160
20161 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
20162
20163 fi
20164
20165
20166
20167
20168
20169
20170 gl_cv_c_multiarch=no
20171 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20172 /* end confdefs.h. */
20173 #ifndef __APPLE_CC__
20174 not a universal capable compiler
20175 #endif
20176 typedef int dummy;
20177
20178 _ACEOF
20179 if ac_fn_c_try_compile "$LINENO"; then :
20180
20181 arch=
20182 prev=
20183 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
20184 if test -n "$prev"; then
20185 case $word in
20186 i?86 | x86_64 | ppc | ppc64)
20187 if test -z "$arch" || test "$arch" = "$word"; then
20188 arch="$word"
20189 else
20190 gl_cv_c_multiarch=yes
20191 fi
20192 ;;
20193 esac
20194 prev=
20195 else
20196 if test "x$word" = "x-arch"; then
20197 prev=arch
20198 fi
20199 fi
20200 done
20201
20202 fi
20203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20204 if test $gl_cv_c_multiarch = yes; then
20205 APPLE_UNIVERSAL_BUILD=1
20206 else
20207 APPLE_UNIVERSAL_BUILD=0
20208 fi
20209
20210
20211
20212
20213
20214 if test $ac_cv_type_long_long_int = yes; then
20215 HAVE_LONG_LONG_INT=1
20216 else
20217 HAVE_LONG_LONG_INT=0
20218 fi
20219
20220
20221 if test $ac_cv_type_unsigned_long_long_int = yes; then
20222 HAVE_UNSIGNED_LONG_LONG_INT=1
20223 else
20224 HAVE_UNSIGNED_LONG_LONG_INT=0
20225 fi
20226
20227
20228
20229 if test $ac_cv_header_wchar_h = yes; then
20230 HAVE_WCHAR_H=1
20231 else
20232 HAVE_WCHAR_H=0
20233 fi
20234
20235
20236 if test $ac_cv_header_inttypes_h = yes; then
20237 HAVE_INTTYPES_H=1
20238 else
20239 HAVE_INTTYPES_H=0
20240 fi
20241
20242
20243 if test $ac_cv_header_sys_types_h = yes; then
20244 HAVE_SYS_TYPES_H=1
20245 else
20246 HAVE_SYS_TYPES_H=0
20247 fi
20248
20249
20250
20251
20252
20253
20254
20255
20256
20257
20258
20259 if test $gl_cv_have_include_next = yes; then
20260 gl_cv_next_stdint_h='<'stdint.h'>'
20261 else
20262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
20263 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
20264 if test "${gl_cv_next_stdint_h+set}" = set; then :
20265 $as_echo_n "(cached) " >&6
20266 else
20267
20268 if test $ac_cv_header_stdint_h = yes; then
20269
20270
20271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20272 /* end confdefs.h. */
20273 #include <stdint.h>
20274
20275 _ACEOF
20276 case "$host_os" in
20277 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20278 *) gl_absname_cpp="$ac_cpp" ;;
20279 esac
20280
20281 case "$host_os" in
20282 mingw*)
20283 gl_dirsep_regex='[/\\]'
20284 ;;
20285 *)
20286 gl_dirsep_regex='\/'
20287 ;;
20288 esac
20289 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
20290
20291 gl_header_literal_regex=`echo 'stdint.h' \
20292 | sed -e "$gl_make_literal_regex_sed"`
20293 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
20294 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
20295 s|^/[^/]|//&|
20296 p
20297 q
20298 }'
20299 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20300 sed -n "$gl_absolute_header_sed"`'"'
20301 else
20302 gl_cv_next_stdint_h='<'stdint.h'>'
20303 fi
20304
20305
20306 fi
20307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
20308 $as_echo "$gl_cv_next_stdint_h" >&6; }
20309 fi
20310 NEXT_STDINT_H=$gl_cv_next_stdint_h
20311
20312 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20313 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20314 gl_next_as_first_directive='<'stdint.h'>'
20315 else
20316 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20317 gl_next_as_first_directive=$gl_cv_next_stdint_h
20318 fi
20319 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
20320
20321
20322
20323
20324 if test $ac_cv_header_stdint_h = yes; then
20325 HAVE_STDINT_H=1
20326 else
20327 HAVE_STDINT_H=0
20328 fi
20329
20330
20331 if test $ac_cv_header_stdint_h = yes; then
20332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
20333 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
20334 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
20335 $as_echo_n "(cached) " >&6
20336 else
20337 gl_cv_header_working_stdint_h=no
20338 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20339 /* end confdefs.h. */
20340
20341
20342 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20343 #include <stdint.h>
20344 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
20345 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
20346 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
20347 #endif
20348
20349
20350 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20351 included before <wchar.h>. */
20352 #include <stddef.h>
20353 #include <signal.h>
20354 #if HAVE_WCHAR_H
20355 # include <stdio.h>
20356 # include <time.h>
20357 # include <wchar.h>
20358 #endif
20359
20360
20361 #ifdef INT8_MAX
20362 int8_t a1 = INT8_MAX;
20363 int8_t a1min = INT8_MIN;
20364 #endif
20365 #ifdef INT16_MAX
20366 int16_t a2 = INT16_MAX;
20367 int16_t a2min = INT16_MIN;
20368 #endif
20369 #ifdef INT32_MAX
20370 int32_t a3 = INT32_MAX;
20371 int32_t a3min = INT32_MIN;
20372 #endif
20373 #ifdef INT64_MAX
20374 int64_t a4 = INT64_MAX;
20375 int64_t a4min = INT64_MIN;
20376 #endif
20377 #ifdef UINT8_MAX
20378 uint8_t b1 = UINT8_MAX;
20379 #else
20380 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
20381 #endif
20382 #ifdef UINT16_MAX
20383 uint16_t b2 = UINT16_MAX;
20384 #endif
20385 #ifdef UINT32_MAX
20386 uint32_t b3 = UINT32_MAX;
20387 #endif
20388 #ifdef UINT64_MAX
20389 uint64_t b4 = UINT64_MAX;
20390 #endif
20391 int_least8_t c1 = INT8_C (0x7f);
20392 int_least8_t c1max = INT_LEAST8_MAX;
20393 int_least8_t c1min = INT_LEAST8_MIN;
20394 int_least16_t c2 = INT16_C (0x7fff);
20395 int_least16_t c2max = INT_LEAST16_MAX;
20396 int_least16_t c2min = INT_LEAST16_MIN;
20397 int_least32_t c3 = INT32_C (0x7fffffff);
20398 int_least32_t c3max = INT_LEAST32_MAX;
20399 int_least32_t c3min = INT_LEAST32_MIN;
20400 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
20401 int_least64_t c4max = INT_LEAST64_MAX;
20402 int_least64_t c4min = INT_LEAST64_MIN;
20403 uint_least8_t d1 = UINT8_C (0xff);
20404 uint_least8_t d1max = UINT_LEAST8_MAX;
20405 uint_least16_t d2 = UINT16_C (0xffff);
20406 uint_least16_t d2max = UINT_LEAST16_MAX;
20407 uint_least32_t d3 = UINT32_C (0xffffffff);
20408 uint_least32_t d3max = UINT_LEAST32_MAX;
20409 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
20410 uint_least64_t d4max = UINT_LEAST64_MAX;
20411 int_fast8_t e1 = INT_FAST8_MAX;
20412 int_fast8_t e1min = INT_FAST8_MIN;
20413 int_fast16_t e2 = INT_FAST16_MAX;
20414 int_fast16_t e2min = INT_FAST16_MIN;
20415 int_fast32_t e3 = INT_FAST32_MAX;
20416 int_fast32_t e3min = INT_FAST32_MIN;
20417 int_fast64_t e4 = INT_FAST64_MAX;
20418 int_fast64_t e4min = INT_FAST64_MIN;
20419 uint_fast8_t f1 = UINT_FAST8_MAX;
20420 uint_fast16_t f2 = UINT_FAST16_MAX;
20421 uint_fast32_t f3 = UINT_FAST32_MAX;
20422 uint_fast64_t f4 = UINT_FAST64_MAX;
20423 #ifdef INTPTR_MAX
20424 intptr_t g = INTPTR_MAX;
20425 intptr_t gmin = INTPTR_MIN;
20426 #endif
20427 #ifdef UINTPTR_MAX
20428 uintptr_t h = UINTPTR_MAX;
20429 #endif
20430 intmax_t i = INTMAX_MAX;
20431 uintmax_t j = UINTMAX_MAX;
20432
20433 #include <limits.h> /* for CHAR_BIT */
20434 #define TYPE_MINIMUM(t) \
20435 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
20436 #define TYPE_MAXIMUM(t) \
20437 ((t) ((t) 0 < (t) -1 \
20438 ? (t) -1 \
20439 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
20440 struct s {
20441 int check_PTRDIFF:
20442 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
20443 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
20444 ? 1 : -1;
20445 /* Detect bug in FreeBSD 6.0 / ia64. */
20446 int check_SIG_ATOMIC:
20447 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
20448 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
20449 ? 1 : -1;
20450 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
20451 int check_WCHAR:
20452 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
20453 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
20454 ? 1 : -1;
20455 /* Detect bug in mingw. */
20456 int check_WINT:
20457 WINT_MIN == TYPE_MINIMUM (wint_t)
20458 && WINT_MAX == TYPE_MAXIMUM (wint_t)
20459 ? 1 : -1;
20460
20461 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
20462 int check_UINT8_C:
20463 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
20464 int check_UINT16_C:
20465 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
20466
20467 /* Detect bugs in OpenBSD 3.9 stdint.h. */
20468 #ifdef UINT8_MAX
20469 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
20470 #endif
20471 #ifdef UINT16_MAX
20472 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
20473 #endif
20474 #ifdef UINT32_MAX
20475 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
20476 #endif
20477 #ifdef UINT64_MAX
20478 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
20479 #endif
20480 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
20481 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
20482 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
20483 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
20484 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
20485 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
20486 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
20487 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
20488 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
20489 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
20490 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
20491 };
20492
20493 int
20494 main ()
20495 {
20496
20497 ;
20498 return 0;
20499 }
20500 _ACEOF
20501 if ac_fn_c_try_compile "$LINENO"; then :
20502 if test "$cross_compiling" = yes; then :
20503 gl_cv_header_working_stdint_h=yes
20504
20505 else
20506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20507 /* end confdefs.h. */
20508
20509
20510 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
20511 #include <stdint.h>
20512
20513
20514 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20515 included before <wchar.h>. */
20516 #include <stddef.h>
20517 #include <signal.h>
20518 #if HAVE_WCHAR_H
20519 # include <stdio.h>
20520 # include <time.h>
20521 # include <wchar.h>
20522 #endif
20523
20524
20525 #include <stdio.h>
20526 #include <string.h>
20527 #define MVAL(macro) MVAL1(macro)
20528 #define MVAL1(expression) #expression
20529 static const char *macro_values[] =
20530 {
20531 #ifdef INT8_MAX
20532 MVAL (INT8_MAX),
20533 #endif
20534 #ifdef INT16_MAX
20535 MVAL (INT16_MAX),
20536 #endif
20537 #ifdef INT32_MAX
20538 MVAL (INT32_MAX),
20539 #endif
20540 #ifdef INT64_MAX
20541 MVAL (INT64_MAX),
20542 #endif
20543 #ifdef UINT8_MAX
20544 MVAL (UINT8_MAX),
20545 #endif
20546 #ifdef UINT16_MAX
20547 MVAL (UINT16_MAX),
20548 #endif
20549 #ifdef UINT32_MAX
20550 MVAL (UINT32_MAX),
20551 #endif
20552 #ifdef UINT64_MAX
20553 MVAL (UINT64_MAX),
20554 #endif
20555 NULL
20556 };
20557
20558 int
20559 main ()
20560 {
20561
20562 const char **mv;
20563 for (mv = macro_values; *mv != NULL; mv++)
20564 {
20565 const char *value = *mv;
20566 /* Test whether it looks like a cast expression. */
20567 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
20568 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
20569 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
20570 || strncmp (value, "((int)"/*)*/, 6) == 0
20571 || strncmp (value, "((signed short)"/*)*/, 15) == 0
20572 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
20573 return mv - macro_values + 1;
20574 }
20575 return 0;
20576
20577 ;
20578 return 0;
20579 }
20580 _ACEOF
20581 if ac_fn_c_try_run "$LINENO"; then :
20582 gl_cv_header_working_stdint_h=yes
20583 fi
20584 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20585 conftest.$ac_objext conftest.beam conftest.$ac_ext
20586 fi
20587
20588
20589 fi
20590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20591
20592 fi
20593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
20594 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
20595 fi
20596 if test "$gl_cv_header_working_stdint_h" = yes; then
20597 STDINT_H=
20598 else
20599 for ac_header in sys/inttypes.h sys/bitypes.h
20600 do :
20601 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
20602 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
20603 eval as_val=\$$as_ac_Header
20604 if test "x$as_val" = x""yes; then :
20605 cat >>confdefs.h <<_ACEOF
20606 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
20607 _ACEOF
20608
20609 fi
20610
20611 done
20612
20613 if test $ac_cv_header_sys_inttypes_h = yes; then
20614 HAVE_SYS_INTTYPES_H=1
20615 else
20616 HAVE_SYS_INTTYPES_H=0
20617 fi
20618
20619 if test $ac_cv_header_sys_bitypes_h = yes; then
20620 HAVE_SYS_BITYPES_H=1
20621 else
20622 HAVE_SYS_BITYPES_H=0
20623 fi
20624
20625
20626
20627
20628 if test $APPLE_UNIVERSAL_BUILD = 0; then
20629
20630
20631 for gltype in ptrdiff_t size_t ; do
20632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20633 $as_echo_n "checking for bit size of $gltype... " >&6; }
20634 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20635 $as_echo_n "(cached) " >&6
20636 else
20637 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20638 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20639 included before <wchar.h>. */
20640 #include <stddef.h>
20641 #include <signal.h>
20642 #if HAVE_WCHAR_H
20643 # include <stdio.h>
20644 # include <time.h>
20645 # include <wchar.h>
20646 #endif
20647
20648 #include <limits.h>"; then :
20649
20650 else
20651 result=unknown
20652 fi
20653
20654 eval gl_cv_bitsizeof_${gltype}=\$result
20655
20656 fi
20657 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20659 $as_echo "$ac_res" >&6; }
20660 eval result=\$gl_cv_bitsizeof_${gltype}
20661 if test $result = unknown; then
20662 result=0
20663 fi
20664 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20665 cat >>confdefs.h <<_ACEOF
20666 #define BITSIZEOF_${GLTYPE} $result
20667 _ACEOF
20668
20669 eval BITSIZEOF_${GLTYPE}=\$result
20670 done
20671
20672
20673 fi
20674
20675
20676 for gltype in sig_atomic_t wchar_t wint_t ; do
20677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
20678 $as_echo_n "checking for bit size of $gltype... " >&6; }
20679 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
20680 $as_echo_n "(cached) " >&6
20681 else
20682 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
20683 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20684 included before <wchar.h>. */
20685 #include <stddef.h>
20686 #include <signal.h>
20687 #if HAVE_WCHAR_H
20688 # include <stdio.h>
20689 # include <time.h>
20690 # include <wchar.h>
20691 #endif
20692
20693 #include <limits.h>"; then :
20694
20695 else
20696 result=unknown
20697 fi
20698
20699 eval gl_cv_bitsizeof_${gltype}=\$result
20700
20701 fi
20702 eval ac_res=\$gl_cv_bitsizeof_${gltype}
20703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20704 $as_echo "$ac_res" >&6; }
20705 eval result=\$gl_cv_bitsizeof_${gltype}
20706 if test $result = unknown; then
20707 result=0
20708 fi
20709 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20710 cat >>confdefs.h <<_ACEOF
20711 #define BITSIZEOF_${GLTYPE} $result
20712 _ACEOF
20713
20714 eval BITSIZEOF_${GLTYPE}=\$result
20715 done
20716
20717
20718
20719
20720 for gltype in sig_atomic_t wchar_t wint_t ; do
20721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
20722 $as_echo_n "checking whether $gltype is signed... " >&6; }
20723 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
20724 $as_echo_n "(cached) " >&6
20725 else
20726 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20727 /* end confdefs.h. */
20728
20729 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20730 included before <wchar.h>. */
20731 #include <stddef.h>
20732 #include <signal.h>
20733 #if HAVE_WCHAR_H
20734 # include <stdio.h>
20735 # include <time.h>
20736 # include <wchar.h>
20737 #endif
20738
20739 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
20740 int
20741 main ()
20742 {
20743
20744 ;
20745 return 0;
20746 }
20747 _ACEOF
20748 if ac_fn_c_try_compile "$LINENO"; then :
20749 result=yes
20750 else
20751 result=no
20752 fi
20753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20754 eval gl_cv_type_${gltype}_signed=\$result
20755
20756 fi
20757 eval ac_res=\$gl_cv_type_${gltype}_signed
20758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20759 $as_echo "$ac_res" >&6; }
20760 eval result=\$gl_cv_type_${gltype}_signed
20761 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20762 if test "$result" = yes; then
20763 cat >>confdefs.h <<_ACEOF
20764 #define HAVE_SIGNED_${GLTYPE} 1
20765 _ACEOF
20766
20767 eval HAVE_SIGNED_${GLTYPE}=1
20768 else
20769 eval HAVE_SIGNED_${GLTYPE}=0
20770 fi
20771 done
20772
20773
20774 gl_cv_type_ptrdiff_t_signed=yes
20775 gl_cv_type_size_t_signed=no
20776 if test $APPLE_UNIVERSAL_BUILD = 0; then
20777
20778
20779 for gltype in ptrdiff_t size_t ; do
20780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20781 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20782 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20783 $as_echo_n "(cached) " >&6
20784 else
20785 eval gl_cv_type_${gltype}_suffix=no
20786 eval result=\$gl_cv_type_${gltype}_signed
20787 if test "$result" = yes; then
20788 glsufu=
20789 else
20790 glsufu=u
20791 fi
20792 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20793 case $glsuf in
20794 '') gltype1='int';;
20795 l) gltype1='long int';;
20796 ll) gltype1='long long int';;
20797 i64) gltype1='__int64';;
20798 u) gltype1='unsigned int';;
20799 ul) gltype1='unsigned long int';;
20800 ull) gltype1='unsigned long long int';;
20801 ui64)gltype1='unsigned __int64';;
20802 esac
20803 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20804 /* end confdefs.h. */
20805
20806 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20807 included before <wchar.h>. */
20808 #include <stddef.h>
20809 #include <signal.h>
20810 #if HAVE_WCHAR_H
20811 # include <stdio.h>
20812 # include <time.h>
20813 # include <wchar.h>
20814 #endif
20815
20816 extern $gltype foo;
20817 extern $gltype1 foo;
20818 int
20819 main ()
20820 {
20821
20822 ;
20823 return 0;
20824 }
20825 _ACEOF
20826 if ac_fn_c_try_compile "$LINENO"; then :
20827 eval gl_cv_type_${gltype}_suffix=\$glsuf
20828 fi
20829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20830 eval result=\$gl_cv_type_${gltype}_suffix
20831 test "$result" != no && break
20832 done
20833 fi
20834 eval ac_res=\$gl_cv_type_${gltype}_suffix
20835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20836 $as_echo "$ac_res" >&6; }
20837 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20838 eval result=\$gl_cv_type_${gltype}_suffix
20839 test "$result" = no && result=
20840 eval ${GLTYPE}_SUFFIX=\$result
20841 cat >>confdefs.h <<_ACEOF
20842 #define ${GLTYPE}_SUFFIX $result
20843 _ACEOF
20844
20845 done
20846
20847
20848 fi
20849
20850
20851 for gltype in sig_atomic_t wchar_t wint_t ; do
20852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
20853 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
20854 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
20855 $as_echo_n "(cached) " >&6
20856 else
20857 eval gl_cv_type_${gltype}_suffix=no
20858 eval result=\$gl_cv_type_${gltype}_signed
20859 if test "$result" = yes; then
20860 glsufu=
20861 else
20862 glsufu=u
20863 fi
20864 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
20865 case $glsuf in
20866 '') gltype1='int';;
20867 l) gltype1='long int';;
20868 ll) gltype1='long long int';;
20869 i64) gltype1='__int64';;
20870 u) gltype1='unsigned int';;
20871 ul) gltype1='unsigned long int';;
20872 ull) gltype1='unsigned long long int';;
20873 ui64)gltype1='unsigned __int64';;
20874 esac
20875 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20876 /* end confdefs.h. */
20877
20878 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
20879 included before <wchar.h>. */
20880 #include <stddef.h>
20881 #include <signal.h>
20882 #if HAVE_WCHAR_H
20883 # include <stdio.h>
20884 # include <time.h>
20885 # include <wchar.h>
20886 #endif
20887
20888 extern $gltype foo;
20889 extern $gltype1 foo;
20890 int
20891 main ()
20892 {
20893
20894 ;
20895 return 0;
20896 }
20897 _ACEOF
20898 if ac_fn_c_try_compile "$LINENO"; then :
20899 eval gl_cv_type_${gltype}_suffix=\$glsuf
20900 fi
20901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20902 eval result=\$gl_cv_type_${gltype}_suffix
20903 test "$result" != no && break
20904 done
20905 fi
20906 eval ac_res=\$gl_cv_type_${gltype}_suffix
20907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
20908 $as_echo "$ac_res" >&6; }
20909 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
20910 eval result=\$gl_cv_type_${gltype}_suffix
20911 test "$result" = no && result=
20912 eval ${GLTYPE}_SUFFIX=\$result
20913 cat >>confdefs.h <<_ACEOF
20914 #define ${GLTYPE}_SUFFIX $result
20915 _ACEOF
20916
20917 done
20918
20919
20920
20921 if test $BITSIZEOF_WINT_T -lt 32; then
20922 BITSIZEOF_WINT_T=32
20923 fi
20924
20925 STDINT_H=stdint.h
20926 fi
20927
20928 if test -n "$STDINT_H"; then
20929 GL_GENERATE_STDINT_H_TRUE=
20930 GL_GENERATE_STDINT_H_FALSE='#'
20931 else
20932 GL_GENERATE_STDINT_H_TRUE='#'
20933 GL_GENERATE_STDINT_H_FALSE=
20934 fi
20935
20936
20937
20938
20939
20940 GNULIB_IMAXABS=0;
20941 GNULIB_IMAXDIV=0;
20942 GNULIB_STRTOIMAX=0;
20943 GNULIB_STRTOUMAX=0;
20944 HAVE_DECL_IMAXABS=1;
20945 HAVE_DECL_IMAXDIV=1;
20946 HAVE_DECL_STRTOIMAX=1;
20947 HAVE_DECL_STRTOUMAX=1;
20948 REPLACE_STRTOIMAX=0;
20949 REPLACE_STRTOUMAX=0;
20950 INT32_MAX_LT_INTMAX_MAX=1;
20951 INT64_MAX_EQ_LONG_MAX='defined _LP64';
20952 PRI_MACROS_BROKEN=0;
20953 PRIPTR_PREFIX=__PRIPTR_PREFIX;
20954 UINT32_MAX_LT_UINTMAX_MAX=1;
20955 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
20956
20957
20958
20959
20960
20961
20962
20963
20964
20965
20966
20967
20968
20969
20970
20971 if test $gl_cv_have_include_next = yes; then
20972 gl_cv_next_inttypes_h='<'inttypes.h'>'
20973 else
20974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
20975 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
20976 if test "${gl_cv_next_inttypes_h+set}" = set; then :
20977 $as_echo_n "(cached) " >&6
20978 else
20979
20980 if test $ac_cv_header_inttypes_h = yes; then
20981
20982
20983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20984 /* end confdefs.h. */
20985 #include <inttypes.h>
20986
20987 _ACEOF
20988 case "$host_os" in
20989 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20990 *) gl_absname_cpp="$ac_cpp" ;;
20991 esac
20992
20993 case "$host_os" in
20994 mingw*)
20995 gl_dirsep_regex='[/\\]'
20996 ;;
20997 *)
20998 gl_dirsep_regex='\/'
20999 ;;
21000 esac
21001 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21002
21003 gl_header_literal_regex=`echo 'inttypes.h' \
21004 | sed -e "$gl_make_literal_regex_sed"`
21005 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21006 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21007 s|^/[^/]|//&|
21008 p
21009 q
21010 }'
21011 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21012 sed -n "$gl_absolute_header_sed"`'"'
21013 else
21014 gl_cv_next_inttypes_h='<'inttypes.h'>'
21015 fi
21016
21017
21018 fi
21019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
21020 $as_echo "$gl_cv_next_inttypes_h" >&6; }
21021 fi
21022 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
21023
21024 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21025 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21026 gl_next_as_first_directive='<'inttypes.h'>'
21027 else
21028 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21029 gl_next_as_first_directive=$gl_cv_next_inttypes_h
21030 fi
21031 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
21032
21033
21034
21035
21036
21037
21038
21039
21040
21041
21042
21043 case "$host_os" in
21044 mingw*)
21045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
21046 $as_echo_n "checking for 64-bit off_t... " >&6; }
21047 if test "${gl_cv_type_off_t_64+set}" = set; then :
21048 $as_echo_n "(cached) " >&6
21049 else
21050 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21051 /* end confdefs.h. */
21052 #include <sys/types.h>
21053 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
21054
21055 int
21056 main ()
21057 {
21058
21059 ;
21060 return 0;
21061 }
21062 _ACEOF
21063 if ac_fn_c_try_compile "$LINENO"; then :
21064 gl_cv_type_off_t_64=yes
21065 else
21066 gl_cv_type_off_t_64=no
21067 fi
21068 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21069
21070 fi
21071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
21072 $as_echo "$gl_cv_type_off_t_64" >&6; }
21073 if test $gl_cv_type_off_t_64 = no; then
21074 WINDOWS_64_BIT_OFF_T=1
21075 else
21076 WINDOWS_64_BIT_OFF_T=0
21077 fi
21078 WINDOWS_64_BIT_ST_SIZE=1
21079 ;;
21080 *)
21081 WINDOWS_64_BIT_OFF_T=0
21082 WINDOWS_64_BIT_ST_SIZE=0
21083 ;;
21084 esac
21085
21086
21087
21088
21089 GNULIB_FFSL=0;
21090 GNULIB_FFSLL=0;
21091 GNULIB_MEMCHR=0;
21092 GNULIB_MEMMEM=0;
21093 GNULIB_MEMPCPY=0;
21094 GNULIB_MEMRCHR=0;
21095 GNULIB_RAWMEMCHR=0;
21096 GNULIB_STPCPY=0;
21097 GNULIB_STPNCPY=0;
21098 GNULIB_STRCHRNUL=0;
21099 GNULIB_STRDUP=0;
21100 GNULIB_STRNCAT=0;
21101 GNULIB_STRNDUP=0;
21102 GNULIB_STRNLEN=0;
21103 GNULIB_STRPBRK=0;
21104 GNULIB_STRSEP=0;
21105 GNULIB_STRSTR=0;
21106 GNULIB_STRCASESTR=0;
21107 GNULIB_STRTOK_R=0;
21108 GNULIB_MBSLEN=0;
21109 GNULIB_MBSNLEN=0;
21110 GNULIB_MBSCHR=0;
21111 GNULIB_MBSRCHR=0;
21112 GNULIB_MBSSTR=0;
21113 GNULIB_MBSCASECMP=0;
21114 GNULIB_MBSNCASECMP=0;
21115 GNULIB_MBSPCASECMP=0;
21116 GNULIB_MBSCASESTR=0;
21117 GNULIB_MBSCSPN=0;
21118 GNULIB_MBSPBRK=0;
21119 GNULIB_MBSSPN=0;
21120 GNULIB_MBSSEP=0;
21121 GNULIB_MBSTOK_R=0;
21122 GNULIB_STRERROR=0;
21123 GNULIB_STRERROR_R=0;
21124 GNULIB_STRSIGNAL=0;
21125 GNULIB_STRVERSCMP=0;
21126 HAVE_MBSLEN=0;
21127 HAVE_FFSL=1;
21128 HAVE_FFSLL=1;
21129 HAVE_MEMCHR=1;
21130 HAVE_DECL_MEMMEM=1;
21131 HAVE_MEMPCPY=1;
21132 HAVE_DECL_MEMRCHR=1;
21133 HAVE_RAWMEMCHR=1;
21134 HAVE_STPCPY=1;
21135 HAVE_STPNCPY=1;
21136 HAVE_STRCHRNUL=1;
21137 HAVE_DECL_STRDUP=1;
21138 HAVE_DECL_STRNDUP=1;
21139 HAVE_DECL_STRNLEN=1;
21140 HAVE_STRPBRK=1;
21141 HAVE_STRSEP=1;
21142 HAVE_STRCASESTR=1;
21143 HAVE_DECL_STRTOK_R=1;
21144 HAVE_DECL_STRERROR_R=1;
21145 HAVE_DECL_STRSIGNAL=1;
21146 HAVE_STRVERSCMP=1;
21147 REPLACE_MEMCHR=0;
21148 REPLACE_MEMMEM=0;
21149 REPLACE_STPNCPY=0;
21150 REPLACE_STRDUP=0;
21151 REPLACE_STRSTR=0;
21152 REPLACE_STRCASESTR=0;
21153 REPLACE_STRCHRNUL=0;
21154 REPLACE_STRERROR=0;
21155 REPLACE_STRERROR_R=0;
21156 REPLACE_STRNCAT=0;
21157 REPLACE_STRNDUP=0;
21158 REPLACE_STRNLEN=0;
21159 REPLACE_STRSIGNAL=0;
21160 REPLACE_STRTOK_R=0;
21161 UNDEFINE_STRTOK_R=0;
21162
21163 ac_fn_c_check_decl "$LINENO" "memrchr" "ac_cv_have_decl_memrchr" "$ac_includes_default"
21164 if test "x$ac_cv_have_decl_memrchr" = x""yes; then :
21165 ac_have_decl=1
21166 else
21167 ac_have_decl=0
21168 fi
21169
21170 cat >>confdefs.h <<_ACEOF
21171 #define HAVE_DECL_MEMRCHR $ac_have_decl
21172 _ACEOF
21173
21174
21175
21176
21177 GNULIB_MKTIME=0;
21178 GNULIB_NANOSLEEP=0;
21179 GNULIB_STRPTIME=0;
21180 GNULIB_TIMEGM=0;
21181 GNULIB_TIME_R=0;
21182 HAVE_DECL_LOCALTIME_R=1;
21183 HAVE_NANOSLEEP=1;
21184 HAVE_STRPTIME=1;
21185 HAVE_TIMEGM=1;
21186 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
21187 REPLACE_MKTIME=GNULIB_PORTCHECK;
21188 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
21189 REPLACE_TIMEGM=GNULIB_PORTCHECK;
21190
21191 ac_fn_c_check_decl "$LINENO" "alarm" "ac_cv_have_decl_alarm" "$ac_includes_default"
21192 if test "x$ac_cv_have_decl_alarm" = x""yes; then :
21193 ac_have_decl=1
21194 else
21195 ac_have_decl=0
21196 fi
21197
21198 cat >>confdefs.h <<_ACEOF
21199 #define HAVE_DECL_ALARM $ac_have_decl
21200 _ACEOF
21201
21202
21203
21204
21205 GNULIB_PSELECT=0;
21206 GNULIB_SELECT=0;
21207 HAVE_PSELECT=1;
21208 REPLACE_PSELECT=0;
21209 REPLACE_SELECT=0;
21210
21211
21212
21213
21214
21215
21216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
21217 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
21218 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
21219 $as_echo_n "(cached) " >&6
21220 else
21221
21222 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21223 /* end confdefs.h. */
21224 #include <sys/select.h>
21225 int
21226 main ()
21227 {
21228 struct timeval b;
21229 ;
21230 return 0;
21231 }
21232 _ACEOF
21233 if ac_fn_c_try_compile "$LINENO"; then :
21234 gl_cv_header_sys_select_h_selfcontained=yes
21235 else
21236 gl_cv_header_sys_select_h_selfcontained=no
21237 fi
21238 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21239 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
21240 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21241 /* end confdefs.h. */
21242 #include <sys/select.h>
21243 int
21244 main ()
21245 {
21246 int memset; int bzero;
21247 ;
21248 return 0;
21249 }
21250
21251 _ACEOF
21252 if ac_fn_c_try_compile "$LINENO"; then :
21253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21254 /* end confdefs.h. */
21255 #include <sys/select.h>
21256 int
21257 main ()
21258 {
21259
21260 #undef memset
21261 #define memset nonexistent_memset
21262 extern
21263 #ifdef __cplusplus
21264 "C"
21265 #endif
21266 void *memset (void *, int, unsigned long);
21267 #undef bzero
21268 #define bzero nonexistent_bzero
21269 extern
21270 #ifdef __cplusplus
21271 "C"
21272 #endif
21273 void bzero (void *, unsigned long);
21274 fd_set fds;
21275 FD_ZERO (&fds);
21276
21277 ;
21278 return 0;
21279 }
21280
21281 _ACEOF
21282 if ac_fn_c_try_link "$LINENO"; then :
21283
21284 else
21285 gl_cv_header_sys_select_h_selfcontained=no
21286 fi
21287 rm -f core conftest.err conftest.$ac_objext \
21288 conftest$ac_exeext conftest.$ac_ext
21289
21290 fi
21291 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21292 fi
21293
21294 fi
21295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
21296 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
21297
21298
21299
21300
21301
21302
21303
21304
21305
21306 if test $gl_cv_have_include_next = yes; then
21307 gl_cv_next_sys_select_h='<'sys/select.h'>'
21308 else
21309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
21310 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
21311 if test "${gl_cv_next_sys_select_h+set}" = set; then :
21312 $as_echo_n "(cached) " >&6
21313 else
21314
21315 if test $ac_cv_header_sys_select_h = yes; then
21316
21317
21318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21319 /* end confdefs.h. */
21320 #include <sys/select.h>
21321
21322 _ACEOF
21323 case "$host_os" in
21324 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21325 *) gl_absname_cpp="$ac_cpp" ;;
21326 esac
21327
21328 case "$host_os" in
21329 mingw*)
21330 gl_dirsep_regex='[/\\]'
21331 ;;
21332 *)
21333 gl_dirsep_regex='\/'
21334 ;;
21335 esac
21336 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21337
21338 gl_header_literal_regex=`echo 'sys/select.h' \
21339 | sed -e "$gl_make_literal_regex_sed"`
21340 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21341 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21342 s|^/[^/]|//&|
21343 p
21344 q
21345 }'
21346 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21347 sed -n "$gl_absolute_header_sed"`'"'
21348 else
21349 gl_cv_next_sys_select_h='<'sys/select.h'>'
21350 fi
21351
21352
21353 fi
21354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
21355 $as_echo "$gl_cv_next_sys_select_h" >&6; }
21356 fi
21357 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
21358
21359 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21360 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21361 gl_next_as_first_directive='<'sys/select.h'>'
21362 else
21363 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21364 gl_next_as_first_directive=$gl_cv_next_sys_select_h
21365 fi
21366 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
21367
21368
21369
21370
21371 if test $ac_cv_header_sys_select_h = yes; then
21372 HAVE_SYS_SELECT_H=1
21373 else
21374 HAVE_SYS_SELECT_H=0
21375 fi
21376
21377
21378
21379
21380
21381 if test $ac_cv_header_sys_socket_h != yes; then
21382 for ac_header in winsock2.h
21383 do :
21384 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
21385 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
21386 cat >>confdefs.h <<_ACEOF
21387 #define HAVE_WINSOCK2_H 1
21388 _ACEOF
21389
21390 fi
21391
21392 done
21393
21394 fi
21395 if test "$ac_cv_header_winsock2_h" = yes; then
21396 HAVE_WINSOCK2_H=1
21397 UNISTD_H_HAVE_WINSOCK2_H=1
21398 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
21399 else
21400 HAVE_WINSOCK2_H=0
21401 fi
21402
21403
21404
21405
21406
21407
21408
21409
21410 GNULIB_PTHREAD_SIGMASK=0;
21411 GNULIB_RAISE=0;
21412 GNULIB_SIGNAL_H_SIGPIPE=0;
21413 GNULIB_SIGPROCMASK=0;
21414 GNULIB_SIGACTION=0;
21415 HAVE_POSIX_SIGNALBLOCKING=1;
21416 HAVE_PTHREAD_SIGMASK=1;
21417 HAVE_RAISE=1;
21418 HAVE_SIGSET_T=1;
21419 HAVE_SIGINFO_T=1;
21420 HAVE_SIGACTION=1;
21421 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
21422
21423 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
21424
21425 HAVE_SIGHANDLER_T=1;
21426 REPLACE_PTHREAD_SIGMASK=0;
21427 REPLACE_RAISE=0;
21428
21429
21430
21431
21432
21433
21434
21435 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
21436 #include <signal.h>
21437 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
21438 #include <sys/types.h>
21439
21440 "
21441 if test "x$ac_cv_type_sigset_t" = x""yes; then :
21442
21443 cat >>confdefs.h <<_ACEOF
21444 #define HAVE_SIGSET_T 1
21445 _ACEOF
21446
21447 gl_cv_type_sigset_t=yes
21448 else
21449 gl_cv_type_sigset_t=no
21450 fi
21451
21452 if test $gl_cv_type_sigset_t != yes; then
21453 HAVE_SIGSET_T=0
21454 fi
21455
21456
21457
21458 if test $ac_cv_header_sys_socket_h = no; then
21459 for ac_header in ws2tcpip.h
21460 do :
21461 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
21462 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
21463 cat >>confdefs.h <<_ACEOF
21464 #define HAVE_WS2TCPIP_H 1
21465 _ACEOF
21466
21467 fi
21468
21469 done
21470
21471 fi
21472
21473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
21474 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
21475 if test "${ac_cv_header_stdbool_h+set}" = set; then :
21476 $as_echo_n "(cached) " >&6
21477 else
21478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21479 /* end confdefs.h. */
21480
21481 #include <stdbool.h>
21482 #ifndef bool
21483 "error: bool is not defined"
21484 #endif
21485 #ifndef false
21486 "error: false is not defined"
21487 #endif
21488 #if false
21489 "error: false is not 0"
21490 #endif
21491 #ifndef true
21492 "error: true is not defined"
21493 #endif
21494 #if true != 1
21495 "error: true is not 1"
21496 #endif
21497 #ifndef __bool_true_false_are_defined
21498 "error: __bool_true_false_are_defined is not defined"
21499 #endif
21500
21501 struct s { _Bool s: 1; _Bool t; } s;
21502
21503 char a[true == 1 ? 1 : -1];
21504 char b[false == 0 ? 1 : -1];
21505 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
21506 char d[(bool) 0.5 == true ? 1 : -1];
21507 /* See body of main program for 'e'. */
21508 char f[(_Bool) 0.0 == false ? 1 : -1];
21509 char g[true];
21510 char h[sizeof (_Bool)];
21511 char i[sizeof s.t];
21512 enum { j = false, k = true, l = false * true, m = true * 256 };
21513 /* The following fails for
21514 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
21515 _Bool n[m];
21516 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
21517 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
21518 /* Catch a bug in an HP-UX C compiler. See
21519 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
21520 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
21521 */
21522 _Bool q = true;
21523 _Bool *pq = &q;
21524
21525 int
21526 main ()
21527 {
21528
21529 bool e = &s;
21530 *pq |= q;
21531 *pq |= ! q;
21532 /* Refer to every declared value, to avoid compiler optimizations. */
21533 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
21534 + !m + !n + !o + !p + !q + !pq);
21535
21536 ;
21537 return 0;
21538 }
21539 _ACEOF
21540 if ac_fn_c_try_compile "$LINENO"; then :
21541 ac_cv_header_stdbool_h=yes
21542 else
21543 ac_cv_header_stdbool_h=no
21544 fi
21545 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21546 fi
21547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
21548 $as_echo "$ac_cv_header_stdbool_h" >&6; }
21549 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
21550 if test "x$ac_cv_type__Bool" = x""yes; then :
21551
21552 cat >>confdefs.h <<_ACEOF
21553 #define HAVE__BOOL 1
21554 _ACEOF
21555
21556
21557 fi
21558
21559
21560
21561 REPLACE_NULL=0;
21562 HAVE_WCHAR_T=1;
21563
21564
21565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
21566 $as_echo_n "checking for wchar_t... " >&6; }
21567 if test "${gt_cv_c_wchar_t+set}" = set; then :
21568 $as_echo_n "(cached) " >&6
21569 else
21570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21571 /* end confdefs.h. */
21572 #include <stddef.h>
21573 wchar_t foo = (wchar_t)'\0';
21574 int
21575 main ()
21576 {
21577
21578 ;
21579 return 0;
21580 }
21581 _ACEOF
21582 if ac_fn_c_try_compile "$LINENO"; then :
21583 gt_cv_c_wchar_t=yes
21584 else
21585 gt_cv_c_wchar_t=no
21586 fi
21587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21588 fi
21589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
21590 $as_echo "$gt_cv_c_wchar_t" >&6; }
21591 if test $gt_cv_c_wchar_t = yes; then
21592
21593 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
21594
21595 fi
21596
21597
21598 GNULIB_DPRINTF=0;
21599 GNULIB_FCLOSE=0;
21600 GNULIB_FDOPEN=0;
21601 GNULIB_FFLUSH=0;
21602 GNULIB_FGETC=0;
21603 GNULIB_FGETS=0;
21604 GNULIB_FOPEN=0;
21605 GNULIB_FPRINTF=0;
21606 GNULIB_FPRINTF_POSIX=0;
21607 GNULIB_FPURGE=0;
21608 GNULIB_FPUTC=0;
21609 GNULIB_FPUTS=0;
21610 GNULIB_FREAD=0;
21611 GNULIB_FREOPEN=0;
21612 GNULIB_FSCANF=0;
21613 GNULIB_FSEEK=0;
21614 GNULIB_FSEEKO=0;
21615 GNULIB_FTELL=0;
21616 GNULIB_FTELLO=0;
21617 GNULIB_FWRITE=0;
21618 GNULIB_GETC=0;
21619 GNULIB_GETCHAR=0;
21620 GNULIB_GETDELIM=0;
21621 GNULIB_GETLINE=0;
21622 GNULIB_OBSTACK_PRINTF=0;
21623 GNULIB_OBSTACK_PRINTF_POSIX=0;
21624 GNULIB_PCLOSE=0;
21625 GNULIB_PERROR=0;
21626 GNULIB_POPEN=0;
21627 GNULIB_PRINTF=0;
21628 GNULIB_PRINTF_POSIX=0;
21629 GNULIB_PUTC=0;
21630 GNULIB_PUTCHAR=0;
21631 GNULIB_PUTS=0;
21632 GNULIB_REMOVE=0;
21633 GNULIB_RENAME=0;
21634 GNULIB_RENAMEAT=0;
21635 GNULIB_SCANF=0;
21636 GNULIB_SNPRINTF=0;
21637 GNULIB_SPRINTF_POSIX=0;
21638 GNULIB_STDIO_H_NONBLOCKING=0;
21639 GNULIB_STDIO_H_SIGPIPE=0;
21640 GNULIB_TMPFILE=0;
21641 GNULIB_VASPRINTF=0;
21642 GNULIB_VFSCANF=0;
21643 GNULIB_VSCANF=0;
21644 GNULIB_VDPRINTF=0;
21645 GNULIB_VFPRINTF=0;
21646 GNULIB_VFPRINTF_POSIX=0;
21647 GNULIB_VPRINTF=0;
21648 GNULIB_VPRINTF_POSIX=0;
21649 GNULIB_VSNPRINTF=0;
21650 GNULIB_VSPRINTF_POSIX=0;
21651 HAVE_DECL_FPURGE=1;
21652 HAVE_DECL_FSEEKO=1;
21653 HAVE_DECL_FTELLO=1;
21654 HAVE_DECL_GETDELIM=1;
21655 HAVE_DECL_GETLINE=1;
21656 HAVE_DECL_OBSTACK_PRINTF=1;
21657 HAVE_DECL_SNPRINTF=1;
21658 HAVE_DECL_VSNPRINTF=1;
21659 HAVE_DPRINTF=1;
21660 HAVE_FSEEKO=1;
21661 HAVE_FTELLO=1;
21662 HAVE_PCLOSE=1;
21663 HAVE_POPEN=1;
21664 HAVE_RENAMEAT=1;
21665 HAVE_VASPRINTF=1;
21666 HAVE_VDPRINTF=1;
21667 REPLACE_DPRINTF=0;
21668 REPLACE_FCLOSE=0;
21669 REPLACE_FDOPEN=0;
21670 REPLACE_FFLUSH=0;
21671 REPLACE_FOPEN=0;
21672 REPLACE_FPRINTF=0;
21673 REPLACE_FPURGE=0;
21674 REPLACE_FREOPEN=0;
21675 REPLACE_FSEEK=0;
21676 REPLACE_FSEEKO=0;
21677 REPLACE_FTELL=0;
21678 REPLACE_FTELLO=0;
21679 REPLACE_GETDELIM=0;
21680 REPLACE_GETLINE=0;
21681 REPLACE_OBSTACK_PRINTF=0;
21682 REPLACE_PERROR=0;
21683 REPLACE_POPEN=0;
21684 REPLACE_PRINTF=0;
21685 REPLACE_REMOVE=0;
21686 REPLACE_RENAME=0;
21687 REPLACE_RENAMEAT=0;
21688 REPLACE_SNPRINTF=0;
21689 REPLACE_SPRINTF=0;
21690 REPLACE_STDIO_READ_FUNCS=0;
21691 REPLACE_STDIO_WRITE_FUNCS=0;
21692 REPLACE_TMPFILE=0;
21693 REPLACE_VASPRINTF=0;
21694 REPLACE_VDPRINTF=0;
21695 REPLACE_VFPRINTF=0;
21696 REPLACE_VPRINTF=0;
21697 REPLACE_VSNPRINTF=0;
21698 REPLACE_VSPRINTF=0;
21699
21700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
21701 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
21702 if test "${ac_cv_struct_tm+set}" = set; then :
21703 $as_echo_n "(cached) " >&6
21704 else
21705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21706 /* end confdefs.h. */
21707 #include <sys/types.h>
21708 #include <time.h>
21709
21710 int
21711 main ()
21712 {
21713 struct tm tm;
21714 int *p = &tm.tm_sec;
21715 return !p;
21716 ;
21717 return 0;
21718 }
21719 _ACEOF
21720 if ac_fn_c_try_compile "$LINENO"; then :
21721 ac_cv_struct_tm=time.h
21722 else
21723 ac_cv_struct_tm=sys/time.h
21724 fi
21725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21726 fi
21727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
21728 $as_echo "$ac_cv_struct_tm" >&6; }
21729 if test $ac_cv_struct_tm = sys/time.h; then
21730
21731 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
21732
21733 fi
21734
21735 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
21736 #include <$ac_cv_struct_tm>
21737
21738 "
21739 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
21740
21741 cat >>confdefs.h <<_ACEOF
21742 #define HAVE_STRUCT_TM_TM_ZONE 1
21743 _ACEOF
21744
21745
21746 fi
21747
21748 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
21749
21750 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
21751
21752 else
21753 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
21754 "
21755 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
21756 ac_have_decl=1
21757 else
21758 ac_have_decl=0
21759 fi
21760
21761 cat >>confdefs.h <<_ACEOF
21762 #define HAVE_DECL_TZNAME $ac_have_decl
21763 _ACEOF
21764
21765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
21766 $as_echo_n "checking for tzname... " >&6; }
21767 if test "${ac_cv_var_tzname+set}" = set; then :
21768 $as_echo_n "(cached) " >&6
21769 else
21770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21771 /* end confdefs.h. */
21772 #include <time.h>
21773 #if !HAVE_DECL_TZNAME
21774 extern char *tzname[];
21775 #endif
21776
21777 int
21778 main ()
21779 {
21780 return tzname[0][0];
21781 ;
21782 return 0;
21783 }
21784 _ACEOF
21785 if ac_fn_c_try_link "$LINENO"; then :
21786 ac_cv_var_tzname=yes
21787 else
21788 ac_cv_var_tzname=no
21789 fi
21790 rm -f core conftest.err conftest.$ac_objext \
21791 conftest$ac_exeext conftest.$ac_ext
21792 fi
21793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
21794 $as_echo "$ac_cv_var_tzname" >&6; }
21795 if test $ac_cv_var_tzname = yes; then
21796
21797 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
21798
21799 fi
21800 fi
21801
21802
21803 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
21804 "
21805 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
21806
21807 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
21808
21809 fi
21810
21811
21812
21813
21814
21815
21816
21817
21818
21819
21820
21821
21822
21823 if test $gl_cv_have_include_next = yes; then
21824 gl_cv_next_string_h='<'string.h'>'
21825 else
21826 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <string.h>" >&5
21827 $as_echo_n "checking absolute name of <string.h>... " >&6; }
21828 if test "${gl_cv_next_string_h+set}" = set; then :
21829 $as_echo_n "(cached) " >&6
21830 else
21831
21832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21833 /* end confdefs.h. */
21834 #include <string.h>
21835
21836 _ACEOF
21837 case "$host_os" in
21838 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21839 *) gl_absname_cpp="$ac_cpp" ;;
21840 esac
21841
21842 case "$host_os" in
21843 mingw*)
21844 gl_dirsep_regex='[/\\]'
21845 ;;
21846 *)
21847 gl_dirsep_regex='\/'
21848 ;;
21849 esac
21850 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
21851
21852 gl_header_literal_regex=`echo 'string.h' \
21853 | sed -e "$gl_make_literal_regex_sed"`
21854 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
21855 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
21856 s|^/[^/]|//&|
21857 p
21858 q
21859 }'
21860 gl_cv_next_string_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21861 sed -n "$gl_absolute_header_sed"`'"'
21862
21863
21864 fi
21865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_string_h" >&5
21866 $as_echo "$gl_cv_next_string_h" >&6; }
21867 fi
21868 NEXT_STRING_H=$gl_cv_next_string_h
21869
21870 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21871 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21872 gl_next_as_first_directive='<'string.h'>'
21873 else
21874 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21875 gl_next_as_first_directive=$gl_cv_next_string_h
21876 fi
21877 NEXT_AS_FIRST_DIRECTIVE_STRING_H=$gl_next_as_first_directive
21878
21879
21880
21881
21882
21883
21884
21885
21886
21887 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
21888 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
21889 ac_have_decl=1
21890 else
21891 ac_have_decl=0
21892 fi
21893
21894 cat >>confdefs.h <<_ACEOF
21895 #define HAVE_DECL_STRTOIMAX $ac_have_decl
21896 _ACEOF
21897
21898
21899
21900 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
21901 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
21902 ac_have_decl=1
21903 else
21904 ac_have_decl=0
21905 fi
21906
21907 cat >>confdefs.h <<_ACEOF
21908 #define HAVE_DECL_STRTOUMAX $ac_have_decl
21909 _ACEOF
21910
21911
21912
21913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
21914 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
21915 if test "${ac_cv_header_stat_broken+set}" = set; then :
21916 $as_echo_n "(cached) " >&6
21917 else
21918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21919 /* end confdefs.h. */
21920 #include <sys/types.h>
21921 #include <sys/stat.h>
21922
21923 #if defined S_ISBLK && defined S_IFDIR
21924 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
21925 #endif
21926
21927 #if defined S_ISBLK && defined S_IFCHR
21928 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
21929 #endif
21930
21931 #if defined S_ISLNK && defined S_IFREG
21932 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
21933 #endif
21934
21935 #if defined S_ISSOCK && defined S_IFREG
21936 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
21937 #endif
21938
21939 _ACEOF
21940 if ac_fn_c_try_compile "$LINENO"; then :
21941 ac_cv_header_stat_broken=no
21942 else
21943 ac_cv_header_stat_broken=yes
21944 fi
21945 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21946 fi
21947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
21948 $as_echo "$ac_cv_header_stat_broken" >&6; }
21949 if test $ac_cv_header_stat_broken = yes; then
21950
21951 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
21952
21953 fi
21954
21955
21956
21957
21958
21959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
21960 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
21961 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
21962 $as_echo_n "(cached) " >&6
21963 else
21964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21965 /* end confdefs.h. */
21966 #include <time.h>
21967
21968 int
21969 main ()
21970 {
21971 static struct timespec x; x.tv_sec = x.tv_nsec;
21972 ;
21973 return 0;
21974 }
21975 _ACEOF
21976 if ac_fn_c_try_compile "$LINENO"; then :
21977 gl_cv_sys_struct_timespec_in_time_h=yes
21978 else
21979 gl_cv_sys_struct_timespec_in_time_h=no
21980 fi
21981 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21982 fi
21983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
21984 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
21985
21986 TIME_H_DEFINES_STRUCT_TIMESPEC=0
21987 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
21988 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
21989 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
21990 TIME_H_DEFINES_STRUCT_TIMESPEC=1
21991 else
21992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
21993 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
21994 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
21995 $as_echo_n "(cached) " >&6
21996 else
21997 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21998 /* end confdefs.h. */
21999 #include <sys/time.h>
22000
22001 int
22002 main ()
22003 {
22004 static struct timespec x; x.tv_sec = x.tv_nsec;
22005 ;
22006 return 0;
22007 }
22008 _ACEOF
22009 if ac_fn_c_try_compile "$LINENO"; then :
22010 gl_cv_sys_struct_timespec_in_sys_time_h=yes
22011 else
22012 gl_cv_sys_struct_timespec_in_sys_time_h=no
22013 fi
22014 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22015 fi
22016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
22017 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
22018 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
22019 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
22020 else
22021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
22022 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
22023 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
22024 $as_echo_n "(cached) " >&6
22025 else
22026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22027 /* end confdefs.h. */
22028 #include <pthread.h>
22029
22030 int
22031 main ()
22032 {
22033 static struct timespec x; x.tv_sec = x.tv_nsec;
22034 ;
22035 return 0;
22036 }
22037 _ACEOF
22038 if ac_fn_c_try_compile "$LINENO"; then :
22039 gl_cv_sys_struct_timespec_in_pthread_h=yes
22040 else
22041 gl_cv_sys_struct_timespec_in_pthread_h=no
22042 fi
22043 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22044 fi
22045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
22046 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
22047 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
22048 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
22049 fi
22050 fi
22051 fi
22052
22053
22054
22055
22056
22057
22058
22059
22060
22061
22062
22063
22064
22065
22066
22067 if test $gl_cv_have_include_next = yes; then
22068 gl_cv_next_time_h='<'time.h'>'
22069 else
22070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
22071 $as_echo_n "checking absolute name of <time.h>... " >&6; }
22072 if test "${gl_cv_next_time_h+set}" = set; then :
22073 $as_echo_n "(cached) " >&6
22074 else
22075
22076 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22077 /* end confdefs.h. */
22078 #include <time.h>
22079
22080 _ACEOF
22081 case "$host_os" in
22082 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22083 *) gl_absname_cpp="$ac_cpp" ;;
22084 esac
22085
22086 case "$host_os" in
22087 mingw*)
22088 gl_dirsep_regex='[/\\]'
22089 ;;
22090 *)
22091 gl_dirsep_regex='\/'
22092 ;;
22093 esac
22094 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22095
22096 gl_header_literal_regex=`echo 'time.h' \
22097 | sed -e "$gl_make_literal_regex_sed"`
22098 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22099 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22100 s|^/[^/]|//&|
22101 p
22102 q
22103 }'
22104 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22105 sed -n "$gl_absolute_header_sed"`'"'
22106
22107
22108 fi
22109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
22110 $as_echo "$gl_cv_next_time_h" >&6; }
22111 fi
22112 NEXT_TIME_H=$gl_cv_next_time_h
22113
22114 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22115 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22116 gl_next_as_first_directive='<'time.h'>'
22117 else
22118 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22119 gl_next_as_first_directive=$gl_cv_next_time_h
22120 fi
22121 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
22122
22123
22124
22125
22126
22127
22128
22129
22130
22131
22132
22133
22134
22135
22136 ac_fn_c_check_decl "$LINENO" "unsetenv" "ac_cv_have_decl_unsetenv" "$ac_includes_default"
22137 if test "x$ac_cv_have_decl_unsetenv" = x""yes; then :
22138 ac_have_decl=1
22139 else
22140 ac_have_decl=0
22141 fi
22142
22143 cat >>confdefs.h <<_ACEOF
22144 #define HAVE_DECL_UNSETENV $ac_have_decl
22145 _ACEOF
22146
22147
22148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
22149 $as_echo_n "checking whether the utimes function works... " >&6; }
22150 if test "${gl_cv_func_working_utimes+set}" = set; then :
22151 $as_echo_n "(cached) " >&6
22152 else
22153
22154 if test "$cross_compiling" = yes; then :
22155 gl_cv_func_working_utimes=no
22156 else
22157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22158 /* end confdefs.h. */
22159
22160 #include <sys/types.h>
22161 #include <sys/stat.h>
22162 #include <fcntl.h>
22163 #include <sys/time.h>
22164 #include <time.h>
22165 #include <unistd.h>
22166 #include <stdlib.h>
22167 #include <stdio.h>
22168 #include <utime.h>
22169
22170 static int
22171 inorder (time_t a, time_t b, time_t c)
22172 {
22173 return a <= b && b <= c;
22174 }
22175
22176 int
22177 main ()
22178 {
22179 int result = 0;
22180 char const *file = "conftest.utimes";
22181 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
22182
22183 /* Test whether utimes() essentially works. */
22184 {
22185 struct stat sbuf;
22186 FILE *f = fopen (file, "w");
22187 if (f == NULL)
22188 result |= 1;
22189 else if (fclose (f) != 0)
22190 result |= 1;
22191 else if (utimes (file, timeval) != 0)
22192 result |= 2;
22193 else if (lstat (file, &sbuf) != 0)
22194 result |= 1;
22195 else if (!(sbuf.st_atime == timeval[0].tv_sec
22196 && sbuf.st_mtime == timeval[1].tv_sec))
22197 result |= 4;
22198 if (unlink (file) != 0)
22199 result |= 1;
22200 }
22201
22202 /* Test whether utimes() with a NULL argument sets the file's timestamp
22203 to the current time. Use 'fstat' as well as 'time' to
22204 determine the "current" time, to accommodate NFS file systems
22205 if there is a time skew between the host and the NFS server. */
22206 {
22207 int fd = open (file, O_WRONLY|O_CREAT, 0644);
22208 if (fd < 0)
22209 result |= 1;
22210 else
22211 {
22212 time_t t0, t2;
22213 struct stat st0, st1, st2;
22214 if (time (&t0) == (time_t) -1)
22215 result |= 1;
22216 else if (fstat (fd, &st0) != 0)
22217 result |= 1;
22218 else if (utimes (file, timeval) != 0)
22219 result |= 2;
22220 else if (utimes (file, NULL) != 0)
22221 result |= 8;
22222 else if (fstat (fd, &st1) != 0)
22223 result |= 1;
22224 else if (write (fd, "\n", 1) != 1)
22225 result |= 1;
22226 else if (fstat (fd, &st2) != 0)
22227 result |= 1;
22228 else if (time (&t2) == (time_t) -1)
22229 result |= 1;
22230 else
22231 {
22232 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
22233 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
22234 if (! (st1.st_atime == st1.st_mtime))
22235 result |= 16;
22236 if (! (m_ok_POSIX || m_ok_NFS))
22237 result |= 32;
22238 }
22239 if (close (fd) != 0)
22240 result |= 1;
22241 }
22242 if (unlink (file) != 0)
22243 result |= 1;
22244 }
22245
22246 /* Test whether utimes() with a NULL argument works on read-only files. */
22247 {
22248 int fd = open (file, O_WRONLY|O_CREAT, 0444);
22249 if (fd < 0)
22250 result |= 1;
22251 else if (close (fd) != 0)
22252 result |= 1;
22253 else if (utimes (file, NULL) != 0)
22254 result |= 64;
22255 if (unlink (file) != 0)
22256 result |= 1;
22257 }
22258
22259 return result;
22260 }
22261
22262 _ACEOF
22263 if ac_fn_c_try_run "$LINENO"; then :
22264 gl_cv_func_working_utimes=yes
22265 else
22266 gl_cv_func_working_utimes=no
22267 fi
22268 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22269 conftest.$ac_objext conftest.beam conftest.$ac_ext
22270 fi
22271
22272 fi
22273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
22274 $as_echo "$gl_cv_func_working_utimes" >&6; }
22275
22276 if test $gl_cv_func_working_utimes = yes; then
22277
22278 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
22279
22280 fi
22281
22282
22283
22284
22285
22286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
22287 $as_echo_n "checking for struct utimbuf... " >&6; }
22288 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
22289 $as_echo_n "(cached) " >&6
22290 else
22291 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22292 /* end confdefs.h. */
22293 #if HAVE_SYS_TIME_H
22294 #include <sys/time.h>
22295 #endif
22296 #include <time.h>
22297 #ifdef HAVE_UTIME_H
22298 #include <utime.h>
22299 #endif
22300
22301 int
22302 main ()
22303 {
22304 static struct utimbuf x; x.actime = x.modtime;
22305 ;
22306 return 0;
22307 }
22308 _ACEOF
22309 if ac_fn_c_try_compile "$LINENO"; then :
22310 gl_cv_sys_struct_utimbuf=yes
22311 else
22312 gl_cv_sys_struct_utimbuf=no
22313 fi
22314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22315 fi
22316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
22317 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
22318
22319 if test $gl_cv_sys_struct_utimbuf = yes; then
22320
22321 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
22322
22323 fi
22324
22325
22326
22327
22328
22329
22330
22331
22332
22333
22334
22335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
22336 $as_echo_n "checking type of array argument to getgroups... " >&6; }
22337 if test "${ac_cv_type_getgroups+set}" = set; then :
22338 $as_echo_n "(cached) " >&6
22339 else
22340 if test "$cross_compiling" = yes; then :
22341 ac_cv_type_getgroups=cross
22342 else
22343 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22344 /* end confdefs.h. */
22345 /* Thanks to Mike Rendell for this test. */
22346 $ac_includes_default
22347 #define NGID 256
22348 #undef MAX
22349 #define MAX(x, y) ((x) > (y) ? (x) : (y))
22350
22351 int
22352 main ()
22353 {
22354 gid_t gidset[NGID];
22355 int i, n;
22356 union { gid_t gval; long int lval; } val;
22357
22358 val.lval = -1;
22359 for (i = 0; i < NGID; i++)
22360 gidset[i] = val.gval;
22361 n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1,
22362 gidset);
22363 /* Exit non-zero if getgroups seems to require an array of ints. This
22364 happens when gid_t is short int but getgroups modifies an array
22365 of ints. */
22366 return n > 0 && gidset[n] != val.gval;
22367 }
22368 _ACEOF
22369 if ac_fn_c_try_run "$LINENO"; then :
22370 ac_cv_type_getgroups=gid_t
22371 else
22372 ac_cv_type_getgroups=int
22373 fi
22374 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22375 conftest.$ac_objext conftest.beam conftest.$ac_ext
22376 fi
22377
22378 if test $ac_cv_type_getgroups = cross; then
22379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22380 /* end confdefs.h. */
22381 #include <unistd.h>
22382
22383 _ACEOF
22384 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22385 $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then :
22386 ac_cv_type_getgroups=gid_t
22387 else
22388 ac_cv_type_getgroups=int
22389 fi
22390 rm -f conftest*
22391
22392 fi
22393 fi
22394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
22395 $as_echo "$ac_cv_type_getgroups" >&6; }
22396
22397 cat >>confdefs.h <<_ACEOF
22398 #define GETGROUPS_T $ac_cv_type_getgroups
22399 _ACEOF
22400
22401
22402
22403
22404
22405
22406
22407
22408 if false; then
22409 GL_COND_LIBTOOL_TRUE=
22410 GL_COND_LIBTOOL_FALSE='#'
22411 else
22412 GL_COND_LIBTOOL_TRUE='#'
22413 GL_COND_LIBTOOL_FALSE=
22414 fi
22415
22416 gl_cond_libtool=false
22417 gl_libdeps=
22418 gl_ltlibdeps=
22419 gl_m4_base='m4'
22420
22421
22422
22423
22424
22425
22426
22427
22428
22429 gl_source_base='lib'
22430
22431
22432 if test $ac_cv_func_alloca_works = no; then
22433 :
22434 fi
22435
22436 # Define an additional variable used in the Makefile substitution.
22437 if test $ac_cv_working_alloca_h = yes; then
22438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
22439 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
22440 if test "${gl_cv_rpl_alloca+set}" = set; then :
22441 $as_echo_n "(cached) " >&6
22442 else
22443
22444 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22445 /* end confdefs.h. */
22446
22447 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
22448 Need own alloca
22449 #endif
22450
22451 _ACEOF
22452 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22453 $EGREP "Need own alloca" >/dev/null 2>&1; then :
22454 gl_cv_rpl_alloca=yes
22455 else
22456 gl_cv_rpl_alloca=no
22457 fi
22458 rm -f conftest*
22459
22460
22461 fi
22462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
22463 $as_echo "$gl_cv_rpl_alloca" >&6; }
22464 if test $gl_cv_rpl_alloca = yes; then
22465
22466 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
22467
22468 ALLOCA_H=alloca.h
22469 else
22470 ALLOCA_H=
22471 fi
22472 else
22473 ALLOCA_H=alloca.h
22474 fi
22475
22476 if test -n "$ALLOCA_H"; then
22477 GL_GENERATE_ALLOCA_H_TRUE=
22478 GL_GENERATE_ALLOCA_H_FALSE='#'
22479 else
22480 GL_GENERATE_ALLOCA_H_TRUE='#'
22481 GL_GENERATE_ALLOCA_H_FALSE=
22482 fi
22483
22484
22485
22486 for ac_header in byteswap.h
22487 do :
22488 ac_fn_c_check_header_mongrel "$LINENO" "byteswap.h" "ac_cv_header_byteswap_h" "$ac_includes_default"
22489 if test "x$ac_cv_header_byteswap_h" = x""yes; then :
22490 cat >>confdefs.h <<_ACEOF
22491 #define HAVE_BYTESWAP_H 1
22492 _ACEOF
22493
22494 BYTESWAP_H=''
22495
22496 else
22497
22498 BYTESWAP_H='byteswap.h'
22499
22500 fi
22501
22502 done
22503
22504
22505 if test -n "$BYTESWAP_H"; then
22506 GL_GENERATE_BYTESWAP_H_TRUE=
22507 GL_GENERATE_BYTESWAP_H_FALSE='#'
22508 else
22509 GL_GENERATE_BYTESWAP_H_TRUE='#'
22510 GL_GENERATE_BYTESWAP_H_FALSE=
22511 fi
22512
22513
22514
22515
22516
22517
22518 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
22519 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
22520
22521 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
22522 # programs in the package would end up linked with that potentially-shared
22523 # library, inducing unnecessary run-time overhead.
22524 LIB_CLOCK_GETTIME=
22525
22526 gl_saved_libs=$LIBS
22527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
22528 $as_echo_n "checking for library containing clock_gettime... " >&6; }
22529 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22530 $as_echo_n "(cached) " >&6
22531 else
22532 ac_func_search_save_LIBS=$LIBS
22533 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22534 /* end confdefs.h. */
22535
22536 /* Override any GCC internal prototype to avoid an error.
22537 Use char because int might match the return type of a GCC
22538 builtin and then its argument prototype would still apply. */
22539 #ifdef __cplusplus
22540 extern "C"
22541 #endif
22542 char clock_gettime ();
22543 int
22544 main ()
22545 {
22546 return clock_gettime ();
22547 ;
22548 return 0;
22549 }
22550 _ACEOF
22551 for ac_lib in '' rt posix4; do
22552 if test -z "$ac_lib"; then
22553 ac_res="none required"
22554 else
22555 ac_res=-l$ac_lib
22556 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22557 fi
22558 if ac_fn_c_try_link "$LINENO"; then :
22559 ac_cv_search_clock_gettime=$ac_res
22560 fi
22561 rm -f core conftest.err conftest.$ac_objext \
22562 conftest$ac_exeext
22563 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22564 break
22565 fi
22566 done
22567 if test "${ac_cv_search_clock_gettime+set}" = set; then :
22568
22569 else
22570 ac_cv_search_clock_gettime=no
22571 fi
22572 rm conftest.$ac_ext
22573 LIBS=$ac_func_search_save_LIBS
22574 fi
22575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
22576 $as_echo "$ac_cv_search_clock_gettime" >&6; }
22577 ac_res=$ac_cv_search_clock_gettime
22578 if test "$ac_res" != no; then :
22579 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22580 test "$ac_cv_search_clock_gettime" = "none required" ||
22581 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
22582 fi
22583
22584 for ac_func in clock_gettime clock_settime
22585 do :
22586 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22587 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
22588 eval as_val=\$$as_ac_var
22589 if test "x$as_val" = x""yes; then :
22590 cat >>confdefs.h <<_ACEOF
22591 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22592 _ACEOF
22593
22594 fi
22595 done
22596
22597 LIBS=$gl_saved_libs
22598
22599
22600 :
22601
22602
22603
22604 cat >>confdefs.h <<_ACEOF
22605 #define GNULIB_CLOSE_STREAM 1
22606 _ACEOF
22607
22608
22609
22610
22611
22612
22613
22614
22615
22616
22617 :
22618
22619
22620
22621 :
22622
22623
22624
22625 :
22626
22627
22628
22629 :
22630
22631
22632
22633
22634
22635
22636
22637
22638
22639
22640
22641
22642
22643 if test $gl_cv_have_include_next = yes; then
22644 gl_cv_next_dirent_h='<'dirent.h'>'
22645 else
22646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <dirent.h>" >&5
22647 $as_echo_n "checking absolute name of <dirent.h>... " >&6; }
22648 if test "${gl_cv_next_dirent_h+set}" = set; then :
22649 $as_echo_n "(cached) " >&6
22650 else
22651
22652 if test $ac_cv_header_dirent_h = yes; then
22653
22654
22655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22656 /* end confdefs.h. */
22657 #include <dirent.h>
22658
22659 _ACEOF
22660 case "$host_os" in
22661 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22662 *) gl_absname_cpp="$ac_cpp" ;;
22663 esac
22664
22665 case "$host_os" in
22666 mingw*)
22667 gl_dirsep_regex='[/\\]'
22668 ;;
22669 *)
22670 gl_dirsep_regex='\/'
22671 ;;
22672 esac
22673 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22674
22675 gl_header_literal_regex=`echo 'dirent.h' \
22676 | sed -e "$gl_make_literal_regex_sed"`
22677 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22678 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22679 s|^/[^/]|//&|
22680 p
22681 q
22682 }'
22683 gl_cv_next_dirent_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22684 sed -n "$gl_absolute_header_sed"`'"'
22685 else
22686 gl_cv_next_dirent_h='<'dirent.h'>'
22687 fi
22688
22689
22690 fi
22691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_dirent_h" >&5
22692 $as_echo "$gl_cv_next_dirent_h" >&6; }
22693 fi
22694 NEXT_DIRENT_H=$gl_cv_next_dirent_h
22695
22696 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22697 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22698 gl_next_as_first_directive='<'dirent.h'>'
22699 else
22700 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22701 gl_next_as_first_directive=$gl_cv_next_dirent_h
22702 fi
22703 NEXT_AS_FIRST_DIRECTIVE_DIRENT_H=$gl_next_as_first_directive
22704
22705
22706
22707
22708 if test $ac_cv_header_dirent_h = yes; then
22709 HAVE_DIRENT_H=1
22710 else
22711 HAVE_DIRENT_H=0
22712 fi
22713
22714
22715
22716
22717
22718
22719
22720
22721
22722
22723 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
22724
22725
22726 if test $HAVE_DUP2 = 1; then
22727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
22728 $as_echo_n "checking whether dup2 works... " >&6; }
22729 if test "${gl_cv_func_dup2_works+set}" = set; then :
22730 $as_echo_n "(cached) " >&6
22731 else
22732 if test "$cross_compiling" = yes; then :
22733 case "$host_os" in
22734 mingw*) # on this platform, dup2 always returns 0 for success
22735 gl_cv_func_dup2_works="guessing no" ;;
22736 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
22737 gl_cv_func_dup2_works="guessing no" ;;
22738 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
22739 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
22740 gl_cv_func_dup2_works="guessing no" ;;
22741 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
22742 gl_cv_func_dup2_works="guessing no" ;;
22743 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
22744 gl_cv_func_dup2_works="guessing no" ;;
22745 *) gl_cv_func_dup2_works="guessing yes" ;;
22746 esac
22747 else
22748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22749 /* end confdefs.h. */
22750
22751 #include <unistd.h>
22752 #include <fcntl.h>
22753 #include <errno.h>
22754 int
22755 main ()
22756 {
22757 int result = 0;
22758 #ifdef FD_CLOEXEC
22759 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
22760 result |= 1;
22761 #endif
22762 if (dup2 (1, 1) == 0)
22763 result |= 2;
22764 #ifdef FD_CLOEXEC
22765 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
22766 result |= 4;
22767 #endif
22768 close (0);
22769 if (dup2 (0, 0) != -1)
22770 result |= 8;
22771 /* Many gnulib modules require POSIX conformance of EBADF. */
22772 if (dup2 (2, 1000000) == -1 && errno != EBADF)
22773 result |= 16;
22774 /* Flush out some cygwin core dumps. */
22775 if (dup2 (2, -1) != -1 || errno != EBADF)
22776 result |= 32;
22777 dup2 (2, 255);
22778 dup2 (2, 256);
22779 return result;
22780
22781 ;
22782 return 0;
22783 }
22784
22785 _ACEOF
22786 if ac_fn_c_try_run "$LINENO"; then :
22787 gl_cv_func_dup2_works=yes
22788 else
22789 gl_cv_func_dup2_works=no
22790 fi
22791 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22792 conftest.$ac_objext conftest.beam conftest.$ac_ext
22793 fi
22794
22795
22796 fi
22797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
22798 $as_echo "$gl_cv_func_dup2_works" >&6; }
22799 case "$gl_cv_func_dup2_works" in
22800 *yes) ;;
22801 *)
22802 REPLACE_DUP2=1
22803 for ac_func in setdtablesize
22804 do :
22805 ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
22806 if test "x$ac_cv_func_setdtablesize" = x""yes; then :
22807 cat >>confdefs.h <<_ACEOF
22808 #define HAVE_SETDTABLESIZE 1
22809 _ACEOF
22810
22811 fi
22812 done
22813
22814 ;;
22815 esac
22816 fi
22817
22818
22819 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
22820
22821
22822
22823
22824
22825
22826
22827
22828 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
22829
22830
22831 fi
22832
22833
22834
22835
22836
22837 GNULIB_DUP2=1
22838
22839
22840
22841
22842
22843
22844
22845
22846
22847
22848
22849 GNULIB_ENVIRON=1
22850
22851
22852
22853
22854
22855
22856
22857
22858
22859 LIB_EXECINFO=''
22860 EXECINFO_H='execinfo.h'
22861
22862 if test $ac_cv_header_execinfo_h = yes; then
22863 gl_saved_libs=$LIBS
22864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
22865 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
22866 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22867 $as_echo_n "(cached) " >&6
22868 else
22869 ac_func_search_save_LIBS=$LIBS
22870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22871 /* end confdefs.h. */
22872
22873 /* Override any GCC internal prototype to avoid an error.
22874 Use char because int might match the return type of a GCC
22875 builtin and then its argument prototype would still apply. */
22876 #ifdef __cplusplus
22877 extern "C"
22878 #endif
22879 char backtrace_symbols_fd ();
22880 int
22881 main ()
22882 {
22883 return backtrace_symbols_fd ();
22884 ;
22885 return 0;
22886 }
22887 _ACEOF
22888 for ac_lib in '' execinfo; do
22889 if test -z "$ac_lib"; then
22890 ac_res="none required"
22891 else
22892 ac_res=-l$ac_lib
22893 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
22894 fi
22895 if ac_fn_c_try_link "$LINENO"; then :
22896 ac_cv_search_backtrace_symbols_fd=$ac_res
22897 fi
22898 rm -f core conftest.err conftest.$ac_objext \
22899 conftest$ac_exeext
22900 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22901 break
22902 fi
22903 done
22904 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
22905
22906 else
22907 ac_cv_search_backtrace_symbols_fd=no
22908 fi
22909 rm conftest.$ac_ext
22910 LIBS=$ac_func_search_save_LIBS
22911 fi
22912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
22913 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
22914 ac_res=$ac_cv_search_backtrace_symbols_fd
22915 if test "$ac_res" != no; then :
22916 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
22917 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
22918 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
22919 fi
22920
22921 LIBS=$gl_saved_libs
22922 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
22923 fi
22924
22925 if test -n "$EXECINFO_H"; then
22926
22927
22928
22929
22930
22931
22932
22933
22934 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
22935
22936 fi
22937
22938
22939
22940 if test -n "$EXECINFO_H"; then
22941 GL_GENERATE_EXECINFO_H_TRUE=
22942 GL_GENERATE_EXECINFO_H_FALSE='#'
22943 else
22944 GL_GENERATE_EXECINFO_H_TRUE='#'
22945 GL_GENERATE_EXECINFO_H_FALSE=
22946 fi
22947
22948
22949
22950
22951
22952
22953
22954
22955
22956 if test $ac_cv_func_faccessat = no; then
22957 HAVE_FACCESSAT=0
22958 fi
22959
22960 if test $HAVE_FACCESSAT = 0; then
22961
22962
22963
22964
22965
22966
22967
22968
22969 gl_LIBOBJS="$gl_LIBOBJS faccessat.$ac_objext"
22970
22971
22972 for ac_func in access
22973 do :
22974 ac_fn_c_check_func "$LINENO" "access" "ac_cv_func_access"
22975 if test "x$ac_cv_func_access" = x""yes; then :
22976 cat >>confdefs.h <<_ACEOF
22977 #define HAVE_ACCESS 1
22978 _ACEOF
22979
22980 fi
22981 done
22982
22983
22984 fi
22985
22986
22987 cat >>confdefs.h <<_ACEOF
22988 #define GNULIB_FACCESSAT 1
22989 _ACEOF
22990
22991
22992
22993
22994
22995
22996
22997 GNULIB_FACCESSAT=1
22998
22999
23000
23001
23002
23003
23004
23005
23006
23007
23008 if test $ac_cv_func_fcntl = no; then
23009
23010
23011
23012 if test $ac_cv_func_fcntl = no; then
23013 HAVE_FCNTL=0
23014 else
23015 REPLACE_FCNTL=1
23016 fi
23017
23018 else
23019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl handles F_DUPFD correctly" >&5
23020 $as_echo_n "checking whether fcntl handles F_DUPFD correctly... " >&6; }
23021 if test "${gl_cv_func_fcntl_f_dupfd_works+set}" = set; then :
23022 $as_echo_n "(cached) " >&6
23023 else
23024 if test "$cross_compiling" = yes; then :
23025 # Guess that it works on glibc systems
23026 case $host_os in #((
23027 *-gnu*) gl_cv_func_fcntl_f_dupfd_works="guessing yes";;
23028 *) gl_cv_func_fcntl_f_dupfd_works="guessing no";;
23029 esac
23030 else
23031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23032 /* end confdefs.h. */
23033
23034 #include <fcntl.h>
23035 #include <errno.h>
23036
23037 int
23038 main ()
23039 {
23040 int result = 0;
23041 if (fcntl (0, F_DUPFD, -1) != -1) result |= 1;
23042 if (errno != EINVAL) result |= 2;
23043 return result;
23044
23045 ;
23046 return 0;
23047 }
23048 _ACEOF
23049 if ac_fn_c_try_run "$LINENO"; then :
23050 gl_cv_func_fcntl_f_dupfd_works=yes
23051 else
23052 gl_cv_func_fcntl_f_dupfd_works=no
23053 fi
23054 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23055 conftest.$ac_objext conftest.beam conftest.$ac_ext
23056 fi
23057
23058 fi
23059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_works" >&5
23060 $as_echo "$gl_cv_func_fcntl_f_dupfd_works" >&6; }
23061 case $gl_cv_func_fcntl_f_dupfd_works in
23062 *yes) ;;
23063 *)
23064
23065
23066 if test $ac_cv_func_fcntl = no; then
23067 HAVE_FCNTL=0
23068 else
23069 REPLACE_FCNTL=1
23070 fi
23071
23072
23073 $as_echo "#define FCNTL_DUPFD_BUGGY 1" >>confdefs.h
23074 ;;
23075 esac
23076
23077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fcntl understands F_DUPFD_CLOEXEC" >&5
23078 $as_echo_n "checking whether fcntl understands F_DUPFD_CLOEXEC... " >&6; }
23079 if test "${gl_cv_func_fcntl_f_dupfd_cloexec+set}" = set; then :
23080 $as_echo_n "(cached) " >&6
23081 else
23082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23083 /* end confdefs.h. */
23084
23085 #include <fcntl.h>
23086 #ifndef F_DUPFD_CLOEXEC
23087 choke me
23088 #endif
23089
23090 int
23091 main ()
23092 {
23093
23094 ;
23095 return 0;
23096 }
23097 _ACEOF
23098 if ac_fn_c_try_compile "$LINENO"; then :
23099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23100 /* end confdefs.h. */
23101
23102 #ifdef __linux__
23103 /* The Linux kernel only added F_DUPFD_CLOEXEC in 2.6.24, so we always replace
23104 it to support the semantics on older kernels that failed with EINVAL. */
23105 choke me
23106 #endif
23107
23108 int
23109 main ()
23110 {
23111
23112 ;
23113 return 0;
23114 }
23115 _ACEOF
23116 if ac_fn_c_try_compile "$LINENO"; then :
23117 gl_cv_func_fcntl_f_dupfd_cloexec=yes
23118 else
23119 gl_cv_func_fcntl_f_dupfd_cloexec="needs runtime check"
23120 fi
23121 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23122 else
23123 gl_cv_func_fcntl_f_dupfd_cloexec=no
23124 fi
23125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23126 fi
23127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fcntl_f_dupfd_cloexec" >&5
23128 $as_echo "$gl_cv_func_fcntl_f_dupfd_cloexec" >&6; }
23129 if test "$gl_cv_func_fcntl_f_dupfd_cloexec" != yes; then
23130
23131
23132
23133 if test $ac_cv_func_fcntl = no; then
23134 HAVE_FCNTL=0
23135 else
23136 REPLACE_FCNTL=1
23137 fi
23138
23139 fi
23140 fi
23141
23142
23143 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
23144
23145
23146
23147
23148
23149
23150
23151
23152 gl_LIBOBJS="$gl_LIBOBJS fcntl.$ac_objext"
23153
23154 fi
23155
23156
23157
23158
23159
23160 GNULIB_FCNTL=1
23161
23162
23163
23164
23165
23166
23167
23168
23169
23170
23171
23172
23173
23174
23175
23176
23177 if test $gl_cv_have_include_next = yes; then
23178 gl_cv_next_fcntl_h='<'fcntl.h'>'
23179 else
23180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <fcntl.h>" >&5
23181 $as_echo_n "checking absolute name of <fcntl.h>... " >&6; }
23182 if test "${gl_cv_next_fcntl_h+set}" = set; then :
23183 $as_echo_n "(cached) " >&6
23184 else
23185
23186 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23187 /* end confdefs.h. */
23188 #include <fcntl.h>
23189
23190 _ACEOF
23191 case "$host_os" in
23192 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23193 *) gl_absname_cpp="$ac_cpp" ;;
23194 esac
23195
23196 case "$host_os" in
23197 mingw*)
23198 gl_dirsep_regex='[/\\]'
23199 ;;
23200 *)
23201 gl_dirsep_regex='\/'
23202 ;;
23203 esac
23204 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23205
23206 gl_header_literal_regex=`echo 'fcntl.h' \
23207 | sed -e "$gl_make_literal_regex_sed"`
23208 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23209 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23210 s|^/[^/]|//&|
23211 p
23212 q
23213 }'
23214 gl_cv_next_fcntl_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23215 sed -n "$gl_absolute_header_sed"`'"'
23216
23217
23218 fi
23219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_fcntl_h" >&5
23220 $as_echo "$gl_cv_next_fcntl_h" >&6; }
23221 fi
23222 NEXT_FCNTL_H=$gl_cv_next_fcntl_h
23223
23224 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23225 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23226 gl_next_as_first_directive='<'fcntl.h'>'
23227 else
23228 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23229 gl_next_as_first_directive=$gl_cv_next_fcntl_h
23230 fi
23231 NEXT_AS_FIRST_DIRECTIVE_FCNTL_H=$gl_next_as_first_directive
23232
23233
23234
23235
23236
23237
23238
23239
23240
23241
23242
23243
23244
23245
23246
23247 LIB_FDATASYNC=
23248
23249
23250 if test $ac_cv_have_decl_fdatasync = no; then
23251 HAVE_DECL_FDATASYNC=0
23252 for ac_func in fdatasync
23253 do :
23254 ac_fn_c_check_func "$LINENO" "fdatasync" "ac_cv_func_fdatasync"
23255 if test "x$ac_cv_func_fdatasync" = x""yes; then :
23256 cat >>confdefs.h <<_ACEOF
23257 #define HAVE_FDATASYNC 1
23258 _ACEOF
23259
23260 fi
23261 done
23262
23263 if test $ac_cv_func_fdatasync = no; then
23264 HAVE_FDATASYNC=0
23265 fi
23266 else
23267 gl_saved_libs=$LIBS
23268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing fdatasync" >&5
23269 $as_echo_n "checking for library containing fdatasync... " >&6; }
23270 if test "${ac_cv_search_fdatasync+set}" = set; then :
23271 $as_echo_n "(cached) " >&6
23272 else
23273 ac_func_search_save_LIBS=$LIBS
23274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23275 /* end confdefs.h. */
23276
23277 /* Override any GCC internal prototype to avoid an error.
23278 Use char because int might match the return type of a GCC
23279 builtin and then its argument prototype would still apply. */
23280 #ifdef __cplusplus
23281 extern "C"
23282 #endif
23283 char fdatasync ();
23284 int
23285 main ()
23286 {
23287 return fdatasync ();
23288 ;
23289 return 0;
23290 }
23291 _ACEOF
23292 for ac_lib in '' rt posix4; do
23293 if test -z "$ac_lib"; then
23294 ac_res="none required"
23295 else
23296 ac_res=-l$ac_lib
23297 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
23298 fi
23299 if ac_fn_c_try_link "$LINENO"; then :
23300 ac_cv_search_fdatasync=$ac_res
23301 fi
23302 rm -f core conftest.err conftest.$ac_objext \
23303 conftest$ac_exeext
23304 if test "${ac_cv_search_fdatasync+set}" = set; then :
23305 break
23306 fi
23307 done
23308 if test "${ac_cv_search_fdatasync+set}" = set; then :
23309
23310 else
23311 ac_cv_search_fdatasync=no
23312 fi
23313 rm conftest.$ac_ext
23314 LIBS=$ac_func_search_save_LIBS
23315 fi
23316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_fdatasync" >&5
23317 $as_echo "$ac_cv_search_fdatasync" >&6; }
23318 ac_res=$ac_cv_search_fdatasync
23319 if test "$ac_res" != no; then :
23320 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
23321 test "$ac_cv_search_fdatasync" = "none required" ||
23322 LIB_FDATASYNC=$ac_cv_search_fdatasync
23323 fi
23324
23325 LIBS=$gl_saved_libs
23326 fi
23327
23328 if test $HAVE_FDATASYNC = 0; then
23329
23330
23331
23332
23333
23334
23335
23336
23337 gl_LIBOBJS="$gl_LIBOBJS fdatasync.$ac_objext"
23338
23339 fi
23340
23341
23342
23343
23344
23345 GNULIB_FDATASYNC=1
23346
23347
23348
23349
23350
23351
23352
23353
23354
23355
23356 ac_fn_c_check_decl "$LINENO" "fdopendir" "ac_cv_have_decl_fdopendir" "
23357 #include <dirent.h>
23358
23359 "
23360 if test "x$ac_cv_have_decl_fdopendir" = x""yes; then :
23361 ac_have_decl=1
23362 else
23363 ac_have_decl=0
23364 fi
23365
23366 cat >>confdefs.h <<_ACEOF
23367 #define HAVE_DECL_FDOPENDIR $ac_have_decl
23368 _ACEOF
23369 if test $ac_have_decl = 1; then :
23370
23371 else
23372 HAVE_DECL_FDOPENDIR=0
23373 fi
23374
23375
23376 if test $ac_cv_func_fdopendir = no; then
23377 HAVE_FDOPENDIR=0
23378 else
23379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fdopendir works" >&5
23380 $as_echo_n "checking whether fdopendir works... " >&6; }
23381 if test "${gl_cv_func_fdopendir_works+set}" = set; then :
23382 $as_echo_n "(cached) " >&6
23383 else
23384 if test "$cross_compiling" = yes; then :
23385 case "$host_os" in
23386 # Guess yes on glibc systems.
23387 *-gnu*) gl_cv_func_fdopendir_works="guessing yes" ;;
23388 # If we don't know, assume the worst.
23389 *) gl_cv_func_fdopendir_works="guessing no" ;;
23390 esac
23391
23392 else
23393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23394 /* end confdefs.h. */
23395
23396 #include <dirent.h>
23397 #include <fcntl.h>
23398 #include <unistd.h>
23399 #if !HAVE_DECL_FDOPENDIR
23400 extern
23401 # ifdef __cplusplus
23402 "C"
23403 # endif
23404 DIR *fdopendir (int);
23405 #endif
23406
23407 int
23408 main ()
23409 {
23410 int result = 0;
23411 int fd = open ("conftest.c", O_RDONLY);
23412 if (fd < 0) result |= 1;
23413 if (fdopendir (fd)) result |= 2;
23414 if (close (fd)) result |= 4;
23415 return result;
23416 ;
23417 return 0;
23418 }
23419 _ACEOF
23420 if ac_fn_c_try_run "$LINENO"; then :
23421 gl_cv_func_fdopendir_works=yes
23422 else
23423 gl_cv_func_fdopendir_works=no
23424 fi
23425 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23426 conftest.$ac_objext conftest.beam conftest.$ac_ext
23427 fi
23428
23429 fi
23430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fdopendir_works" >&5
23431 $as_echo "$gl_cv_func_fdopendir_works" >&6; }
23432 case "$gl_cv_func_fdopendir_works" in
23433 *yes) ;;
23434 *)
23435 REPLACE_FDOPENDIR=1
23436 ;;
23437 esac
23438 fi
23439
23440 if test $HAVE_FDOPENDIR = 0 || test $REPLACE_FDOPENDIR = 1; then
23441
23442
23443
23444
23445
23446
23447
23448
23449 gl_LIBOBJS="$gl_LIBOBJS fdopendir.$ac_objext"
23450
23451 fi
23452
23453
23454
23455
23456
23457 GNULIB_FDOPENDIR=1
23458
23459
23460
23461
23462
23463
23464
23465 cat >>confdefs.h <<_ACEOF
23466 #define GNULIB_FDOPENDIR 1
23467 _ACEOF
23468
23469
23470
23471
23472
23473
23474
23475
23476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __fpending" >&5
23477 $as_echo_n "checking for __fpending... " >&6; }
23478 if test "${gl_cv_func___fpending+set}" = set; then :
23479 $as_echo_n "(cached) " >&6
23480 else
23481
23482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23483 /* end confdefs.h. */
23484 #include <stdio.h>
23485 #if HAVE_STDIO_EXT_H
23486 # include <stdio_ext.h>
23487 #endif
23488
23489 int
23490 main ()
23491 {
23492 return ! __fpending (stdin);
23493 ;
23494 return 0;
23495 }
23496 _ACEOF
23497 if ac_fn_c_try_link "$LINENO"; then :
23498 gl_cv_func___fpending=yes
23499 else
23500 gl_cv_func___fpending=no
23501 fi
23502 rm -f core conftest.err conftest.$ac_objext \
23503 conftest$ac_exeext conftest.$ac_ext
23504
23505 fi
23506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func___fpending" >&5
23507 $as_echo "$gl_cv_func___fpending" >&6; }
23508
23509 if test $gl_cv_func___fpending = no; then
23510
23511
23512
23513
23514
23515
23516
23517
23518 gl_LIBOBJS="$gl_LIBOBJS fpending.$ac_objext"
23519
23520
23521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to determine the number of pending output bytes on a stream" >&5
23522 $as_echo_n "checking how to determine the number of pending output bytes on a stream... " >&6; }
23523 if test "${ac_cv_sys_pending_output_n_bytes+set}" = set; then :
23524 $as_echo_n "(cached) " >&6
23525 else
23526
23527 for ac_expr in \
23528 \
23529 '# glibc2' \
23530 'fp->_IO_write_ptr - fp->_IO_write_base' \
23531 \
23532 '# traditional Unix' \
23533 'fp->_ptr - fp->_base' \
23534 \
23535 '# BSD' \
23536 'fp->_p - fp->_bf._base' \
23537 \
23538 '# SCO, Unixware' \
23539 '(fp->__ptr ? fp->__ptr - fp->__base : 0)' \
23540 \
23541 '# QNX' \
23542 '(fp->_Mode & 0x2000 /*_MWRITE*/ ? fp->_Next - fp->_Buf : 0)' \
23543 \
23544 '# old glibc?' \
23545 'fp->__bufp - fp->__buffer' \
23546 \
23547 '# old glibc iostream?' \
23548 'fp->_pptr - fp->_pbase' \
23549 \
23550 '# emx+gcc' \
23551 'fp->_ptr - fp->_buffer' \
23552 \
23553 '# Minix' \
23554 'fp->_ptr - fp->_buf' \
23555 \
23556 '# Plan9' \
23557 'fp->wp - fp->buf' \
23558 \
23559 '# VMS' \
23560 '(*fp)->_ptr - (*fp)->_base' \
23561 \
23562 '# e.g., DGUX R4.11; the info is not available' \
23563 1 \
23564 ; do
23565
23566 # Skip each embedded comment.
23567 case "$ac_expr" in '#'*) continue;; esac
23568
23569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23570 /* end confdefs.h. */
23571 #include <stdio.h>
23572 int
23573 main ()
23574 {
23575 FILE *fp = stdin; (void) ($ac_expr);
23576 ;
23577 return 0;
23578 }
23579 _ACEOF
23580 if ac_fn_c_try_compile "$LINENO"; then :
23581 fp_done=yes
23582
23583 fi
23584 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23585 test "$fp_done" = yes && break
23586 done
23587
23588 ac_cv_sys_pending_output_n_bytes=$ac_expr
23589
23590
23591 fi
23592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_pending_output_n_bytes" >&5
23593 $as_echo "$ac_cv_sys_pending_output_n_bytes" >&6; }
23594
23595 cat >>confdefs.h <<_ACEOF
23596 #define PENDING_OUTPUT_N_BYTES $ac_cv_sys_pending_output_n_bytes
23597 _ACEOF
23598
23599
23600 fi
23601
23602
23603
23604
23605
23606
23607 if test $ac_cv_func_fstatat = no; then
23608 HAVE_FSTATAT=0
23609 else
23610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether fstatat (..., 0) works" >&5
23611 $as_echo_n "checking whether fstatat (..., 0) works... " >&6; }
23612 if test "${gl_cv_func_fstatat_zero_flag+set}" = set; then :
23613 $as_echo_n "(cached) " >&6
23614 else
23615 if test "$cross_compiling" = yes; then :
23616 case "$host_os" in
23617 aix*) gl_cv_func_fstatat_zero_flag="guessing no";;
23618 *) gl_cv_func_fstatat_zero_flag="guessing yes";;
23619 esac
23620
23621 else
23622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23623 /* end confdefs.h. */
23624
23625 #include <fcntl.h>
23626 #include <sys/stat.h>
23627 int
23628 main (void)
23629 {
23630 struct stat a;
23631 return fstatat (AT_FDCWD, ".", &a, 0) != 0;
23632 }
23633
23634 _ACEOF
23635 if ac_fn_c_try_run "$LINENO"; then :
23636 gl_cv_func_fstatat_zero_flag=yes
23637 else
23638 gl_cv_func_fstatat_zero_flag=no
23639 fi
23640 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23641 conftest.$ac_objext conftest.beam conftest.$ac_ext
23642 fi
23643
23644
23645 fi
23646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_fstatat_zero_flag" >&5
23647 $as_echo "$gl_cv_func_fstatat_zero_flag" >&6; }
23648
23649 case $gl_cv_func_fstatat_zero_flag+$gl_cv_func_lstat_dereferences_slashed_symlink in
23650 *yes+*yes) ;;
23651 *) REPLACE_FSTATAT=1
23652 case $gl_cv_func_fstatat_zero_flag in
23653 *yes)
23654
23655 $as_echo "#define HAVE_WORKING_FSTATAT_ZERO_FLAG 1" >>confdefs.h
23656
23657 ;;
23658 esac
23659 ;;
23660 esac
23661 fi
23662
23663 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
23664
23665
23666
23667
23668
23669
23670
23671
23672 gl_LIBOBJS="$gl_LIBOBJS fstatat.$ac_objext"
23673
23674 fi
23675
23676
23677
23678
23679
23680 GNULIB_FSTATAT=1
23681
23682
23683
23684
23685
23686
23687
23688
23689 if test $ac_cv_func_fsync = no; then
23690 HAVE_FSYNC=0
23691 fi
23692
23693 if test $HAVE_FSYNC = 0; then
23694
23695
23696
23697
23698
23699
23700
23701
23702 gl_LIBOBJS="$gl_LIBOBJS fsync.$ac_objext"
23703
23704 :
23705 fi
23706
23707
23708
23709
23710
23711 GNULIB_FSYNC=1
23712
23713
23714
23715
23716
23717
23718
23719 # Persuade glibc <stdlib.h> to declare getloadavg().
23720
23721
23722 gl_save_LIBS=$LIBS
23723
23724 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
23725 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
23726 HAVE_GETLOADAVG=1
23727 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
23728 if test "x$ac_cv_func_getloadavg" = x""yes; then :
23729
23730 else
23731 gl_func_getloadavg_done=no
23732
23733 # Some systems with -lutil have (and need) -lkvm as well, some do not.
23734 # On Solaris, -lkvm requires nlist from -lelf, so check that first
23735 # to get the right answer into the cache.
23736 # For kstat on solaris, we need to test for libelf and libkvm to force the
23737 # definition of SVR4 below.
23738 if test $gl_func_getloadavg_done = no; then
23739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
23740 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
23741 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
23742 $as_echo_n "(cached) " >&6
23743 else
23744 ac_check_lib_save_LIBS=$LIBS
23745 LIBS="-lelf $LIBS"
23746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23747 /* end confdefs.h. */
23748
23749 /* Override any GCC internal prototype to avoid an error.
23750 Use char because int might match the return type of a GCC
23751 builtin and then its argument prototype would still apply. */
23752 #ifdef __cplusplus
23753 extern "C"
23754 #endif
23755 char elf_begin ();
23756 int
23757 main ()
23758 {
23759 return elf_begin ();
23760 ;
23761 return 0;
23762 }
23763 _ACEOF
23764 if ac_fn_c_try_link "$LINENO"; then :
23765 ac_cv_lib_elf_elf_begin=yes
23766 else
23767 ac_cv_lib_elf_elf_begin=no
23768 fi
23769 rm -f core conftest.err conftest.$ac_objext \
23770 conftest$ac_exeext conftest.$ac_ext
23771 LIBS=$ac_check_lib_save_LIBS
23772 fi
23773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
23774 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
23775 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
23776 LIBS="-lelf $LIBS"
23777 fi
23778
23779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
23780 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
23781 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
23782 $as_echo_n "(cached) " >&6
23783 else
23784 ac_check_lib_save_LIBS=$LIBS
23785 LIBS="-lkvm $LIBS"
23786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23787 /* end confdefs.h. */
23788
23789 /* Override any GCC internal prototype to avoid an error.
23790 Use char because int might match the return type of a GCC
23791 builtin and then its argument prototype would still apply. */
23792 #ifdef __cplusplus
23793 extern "C"
23794 #endif
23795 char kvm_open ();
23796 int
23797 main ()
23798 {
23799 return kvm_open ();
23800 ;
23801 return 0;
23802 }
23803 _ACEOF
23804 if ac_fn_c_try_link "$LINENO"; then :
23805 ac_cv_lib_kvm_kvm_open=yes
23806 else
23807 ac_cv_lib_kvm_kvm_open=no
23808 fi
23809 rm -f core conftest.err conftest.$ac_objext \
23810 conftest$ac_exeext conftest.$ac_ext
23811 LIBS=$ac_check_lib_save_LIBS
23812 fi
23813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
23814 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
23815 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
23816 LIBS="-lkvm $LIBS"
23817 fi
23818
23819 # Check for the 4.4BSD definition of getloadavg.
23820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
23821 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
23822 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
23823 $as_echo_n "(cached) " >&6
23824 else
23825 ac_check_lib_save_LIBS=$LIBS
23826 LIBS="-lutil $LIBS"
23827 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23828 /* end confdefs.h. */
23829
23830 /* Override any GCC internal prototype to avoid an error.
23831 Use char because int might match the return type of a GCC
23832 builtin and then its argument prototype would still apply. */
23833 #ifdef __cplusplus
23834 extern "C"
23835 #endif
23836 char getloadavg ();
23837 int
23838 main ()
23839 {
23840 return getloadavg ();
23841 ;
23842 return 0;
23843 }
23844 _ACEOF
23845 if ac_fn_c_try_link "$LINENO"; then :
23846 ac_cv_lib_util_getloadavg=yes
23847 else
23848 ac_cv_lib_util_getloadavg=no
23849 fi
23850 rm -f core conftest.err conftest.$ac_objext \
23851 conftest$ac_exeext conftest.$ac_ext
23852 LIBS=$ac_check_lib_save_LIBS
23853 fi
23854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
23855 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
23856 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
23857 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
23858 fi
23859
23860 fi
23861
23862 if test $gl_func_getloadavg_done = no; then
23863 # There is a commonly available library for RS/6000 AIX.
23864 # Since it is not a standard part of AIX, it might be installed locally.
23865 gl_getloadavg_LIBS=$LIBS
23866 LIBS="-L/usr/local/lib $LIBS"
23867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
23868 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
23869 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
23870 $as_echo_n "(cached) " >&6
23871 else
23872 ac_check_lib_save_LIBS=$LIBS
23873 LIBS="-lgetloadavg $LIBS"
23874 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23875 /* end confdefs.h. */
23876
23877 /* Override any GCC internal prototype to avoid an error.
23878 Use char because int might match the return type of a GCC
23879 builtin and then its argument prototype would still apply. */
23880 #ifdef __cplusplus
23881 extern "C"
23882 #endif
23883 char getloadavg ();
23884 int
23885 main ()
23886 {
23887 return getloadavg ();
23888 ;
23889 return 0;
23890 }
23891 _ACEOF
23892 if ac_fn_c_try_link "$LINENO"; then :
23893 ac_cv_lib_getloadavg_getloadavg=yes
23894 else
23895 ac_cv_lib_getloadavg_getloadavg=no
23896 fi
23897 rm -f core conftest.err conftest.$ac_objext \
23898 conftest$ac_exeext conftest.$ac_ext
23899 LIBS=$ac_check_lib_save_LIBS
23900 fi
23901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
23902 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
23903 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
23904 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
23905 else
23906 LIBS=$gl_getloadavg_LIBS
23907 fi
23908
23909 fi
23910
23911 # Set up the replacement function if necessary.
23912 if test $gl_func_getloadavg_done = no; then
23913 HAVE_GETLOADAVG=0
23914
23915 # Solaris has libkstat which does not require root.
23916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
23917 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
23918 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
23919 $as_echo_n "(cached) " >&6
23920 else
23921 ac_check_lib_save_LIBS=$LIBS
23922 LIBS="-lkstat $LIBS"
23923 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23924 /* end confdefs.h. */
23925
23926 /* Override any GCC internal prototype to avoid an error.
23927 Use char because int might match the return type of a GCC
23928 builtin and then its argument prototype would still apply. */
23929 #ifdef __cplusplus
23930 extern "C"
23931 #endif
23932 char kstat_open ();
23933 int
23934 main ()
23935 {
23936 return kstat_open ();
23937 ;
23938 return 0;
23939 }
23940 _ACEOF
23941 if ac_fn_c_try_link "$LINENO"; then :
23942 ac_cv_lib_kstat_kstat_open=yes
23943 else
23944 ac_cv_lib_kstat_kstat_open=no
23945 fi
23946 rm -f core conftest.err conftest.$ac_objext \
23947 conftest$ac_exeext conftest.$ac_ext
23948 LIBS=$ac_check_lib_save_LIBS
23949 fi
23950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
23951 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
23952 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
23953 cat >>confdefs.h <<_ACEOF
23954 #define HAVE_LIBKSTAT 1
23955 _ACEOF
23956
23957 LIBS="-lkstat $LIBS"
23958
23959 fi
23960
23961 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
23962
23963 # AIX has libperfstat which does not require root
23964 if test $gl_func_getloadavg_done = no; then
23965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
23966 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
23967 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
23968 $as_echo_n "(cached) " >&6
23969 else
23970 ac_check_lib_save_LIBS=$LIBS
23971 LIBS="-lperfstat $LIBS"
23972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23973 /* end confdefs.h. */
23974
23975 /* Override any GCC internal prototype to avoid an error.
23976 Use char because int might match the return type of a GCC
23977 builtin and then its argument prototype would still apply. */
23978 #ifdef __cplusplus
23979 extern "C"
23980 #endif
23981 char perfstat_cpu_total ();
23982 int
23983 main ()
23984 {
23985 return perfstat_cpu_total ();
23986 ;
23987 return 0;
23988 }
23989 _ACEOF
23990 if ac_fn_c_try_link "$LINENO"; then :
23991 ac_cv_lib_perfstat_perfstat_cpu_total=yes
23992 else
23993 ac_cv_lib_perfstat_perfstat_cpu_total=no
23994 fi
23995 rm -f core conftest.err conftest.$ac_objext \
23996 conftest$ac_exeext conftest.$ac_ext
23997 LIBS=$ac_check_lib_save_LIBS
23998 fi
23999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
24000 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
24001 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
24002 cat >>confdefs.h <<_ACEOF
24003 #define HAVE_LIBPERFSTAT 1
24004 _ACEOF
24005
24006 LIBS="-lperfstat $LIBS"
24007
24008 fi
24009
24010 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
24011 fi
24012
24013 if test $gl_func_getloadavg_done = no; then
24014 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
24015 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
24016 gl_func_getloadavg_done=yes
24017
24018 $as_echo "#define DGUX 1" >>confdefs.h
24019
24020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
24021 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
24022 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
24023 $as_echo_n "(cached) " >&6
24024 else
24025 ac_check_lib_save_LIBS=$LIBS
24026 LIBS="-ldgc $LIBS"
24027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24028 /* end confdefs.h. */
24029
24030 /* Override any GCC internal prototype to avoid an error.
24031 Use char because int might match the return type of a GCC
24032 builtin and then its argument prototype would still apply. */
24033 #ifdef __cplusplus
24034 extern "C"
24035 #endif
24036 char dg_sys_info ();
24037 int
24038 main ()
24039 {
24040 return dg_sys_info ();
24041 ;
24042 return 0;
24043 }
24044 _ACEOF
24045 if ac_fn_c_try_link "$LINENO"; then :
24046 ac_cv_lib_dgc_dg_sys_info=yes
24047 else
24048 ac_cv_lib_dgc_dg_sys_info=no
24049 fi
24050 rm -f core conftest.err conftest.$ac_objext \
24051 conftest$ac_exeext conftest.$ac_ext
24052 LIBS=$ac_check_lib_save_LIBS
24053 fi
24054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
24055 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
24056 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
24057 cat >>confdefs.h <<_ACEOF
24058 #define HAVE_LIBDGC 1
24059 _ACEOF
24060
24061 LIBS="-ldgc $LIBS"
24062
24063 fi
24064
24065 fi
24066
24067
24068 fi
24069 fi
24070 fi
24071
24072
24073 if test "x$gl_save_LIBS" = x; then
24074 GETLOADAVG_LIBS=$LIBS
24075 else
24076 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
24077 fi
24078 LIBS=$gl_save_LIBS
24079
24080
24081 # Test whether the system declares getloadavg. Solaris has the function
24082 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
24083 for ac_header in sys/loadavg.h
24084 do :
24085 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
24086 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
24087 cat >>confdefs.h <<_ACEOF
24088 #define HAVE_SYS_LOADAVG_H 1
24089 _ACEOF
24090
24091 fi
24092
24093 done
24094
24095 if test $ac_cv_header_sys_loadavg_h = yes; then
24096 HAVE_SYS_LOADAVG_H=1
24097 else
24098 HAVE_SYS_LOADAVG_H=0
24099 fi
24100 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
24101 # include <sys/loadavg.h>
24102 #endif
24103 #include <stdlib.h>
24104 "
24105 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
24106
24107 else
24108 HAVE_DECL_GETLOADAVG=0
24109 fi
24110
24111
24112 if test $HAVE_GETLOADAVG = 0; then
24113
24114
24115
24116
24117
24118
24119
24120
24121 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
24122
24123
24124 # Figure out what our getloadavg.c needs.
24125
24126
24127
24128 # On HPUX9, an unprivileged user can get load averages this way.
24129 if test $gl_func_getloadavg_done = no; then
24130 for ac_func in pstat_getdynamic
24131 do :
24132 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
24133 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
24134 cat >>confdefs.h <<_ACEOF
24135 #define HAVE_PSTAT_GETDYNAMIC 1
24136 _ACEOF
24137 gl_func_getloadavg_done=yes
24138 fi
24139 done
24140
24141 fi
24142
24143 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
24144 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
24145 # Irix 4.0.5F has the header but not the library.
24146 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
24147 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
24148 gl_func_getloadavg_done=yes
24149
24150 $as_echo "#define SVR4 1" >>confdefs.h
24151
24152 fi
24153
24154 if test $gl_func_getloadavg_done = no; then
24155 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
24156 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
24157 gl_func_getloadavg_done=yes
24158
24159 $as_echo "#define UMAX 1" >>confdefs.h
24160
24161
24162 $as_echo "#define UMAX4_3 1" >>confdefs.h
24163
24164 fi
24165
24166
24167 fi
24168
24169 if test $gl_func_getloadavg_done = no; then
24170 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
24171 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
24172 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
24173
24174 fi
24175
24176
24177 fi
24178
24179 if test $gl_func_getloadavg_done = no; then
24180 for ac_header in mach/mach.h
24181 do :
24182 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
24183 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
24184 cat >>confdefs.h <<_ACEOF
24185 #define HAVE_MACH_MACH_H 1
24186 _ACEOF
24187
24188 fi
24189
24190 done
24191
24192 fi
24193
24194 for ac_header in nlist.h
24195 do :
24196 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
24197 if test "x$ac_cv_header_nlist_h" = x""yes; then :
24198 cat >>confdefs.h <<_ACEOF
24199 #define HAVE_NLIST_H 1
24200 _ACEOF
24201 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
24202 "
24203 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
24204
24205 cat >>confdefs.h <<_ACEOF
24206 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
24207 _ACEOF
24208
24209
24210 fi
24211
24212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24213 /* end confdefs.h. */
24214 #include <nlist.h>
24215 int
24216 main ()
24217 {
24218 struct nlist x;
24219 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
24220 x.n_un.n_name = "";
24221 #else
24222 x.n_name = "";
24223 #endif
24224 ;
24225 return 0;
24226 }
24227 _ACEOF
24228 if ac_fn_c_try_link "$LINENO"; then :
24229
24230 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
24231
24232 fi
24233 rm -f core conftest.err conftest.$ac_objext \
24234 conftest$ac_exeext conftest.$ac_ext
24235
24236 fi
24237
24238 done
24239
24240 fi
24241
24242
24243
24244
24245
24246 GNULIB_GETLOADAVG=1
24247
24248
24249
24250
24251
24252
24253
24254
24255
24256
24257 if test $REPLACE_GETOPT = 1; then
24258
24259
24260
24261
24262
24263
24264
24265
24266 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24267
24268
24269
24270
24271
24272
24273
24274
24275
24276 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24277
24278
24279
24280
24281 GNULIB_GL_UNISTD_H_GETOPT=1
24282 fi
24283
24284
24285
24286
24287
24288
24289
24290 REPLACE_GETOPT=0
24291 if test -n "$gl_replace_getopt"; then
24292 REPLACE_GETOPT=1
24293 fi
24294
24295 if test $REPLACE_GETOPT = 1; then
24296
24297 GETOPT_H=getopt.h
24298
24299 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
24300
24301
24302
24303 fi
24304
24305 if test $REPLACE_GETOPT = 1; then
24306
24307
24308
24309
24310
24311
24312
24313
24314 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
24315
24316
24317
24318
24319
24320
24321
24322
24323
24324 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
24325
24326
24327
24328
24329 GNULIB_GL_UNISTD_H_GETOPT=1
24330 fi
24331
24332
24333
24334
24335
24336
24337
24338
24339
24340
24341
24342
24343 gl_gettimeofday_timezone=void
24344 if test $ac_cv_func_gettimeofday != yes; then
24345 HAVE_GETTIMEOFDAY=0
24346 else
24347
24348
24349
24350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
24351 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
24352 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
24353 $as_echo_n "(cached) " >&6
24354 else
24355 if test "$cross_compiling" = yes; then :
24356 # When cross-compiling:
24357 case "$host_os" in
24358 # Guess all is fine on glibc systems.
24359 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
24360 # If we don't know, assume the worst.
24361 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
24362 esac
24363
24364 else
24365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24366 /* end confdefs.h. */
24367 #include <string.h>
24368 #include <sys/time.h>
24369 #include <time.h>
24370 #include <stdlib.h>
24371
24372 int
24373 main ()
24374 {
24375
24376 time_t t = 0;
24377 struct tm *lt;
24378 struct tm saved_lt;
24379 struct timeval tv;
24380 lt = localtime (&t);
24381 saved_lt = *lt;
24382 gettimeofday (&tv, NULL);
24383 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
24384
24385 ;
24386 return 0;
24387 }
24388 _ACEOF
24389 if ac_fn_c_try_run "$LINENO"; then :
24390 gl_cv_func_gettimeofday_clobber=no
24391 else
24392 gl_cv_func_gettimeofday_clobber=yes
24393 fi
24394 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24395 conftest.$ac_objext conftest.beam conftest.$ac_ext
24396 fi
24397
24398 fi
24399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
24400 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
24401
24402 case "$gl_cv_func_gettimeofday_clobber" in
24403 *yes)
24404 REPLACE_GETTIMEOFDAY=1
24405
24406
24407 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
24408
24409
24410 $as_echo "#define localtime rpl_localtime" >>confdefs.h
24411
24412
24413
24414 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
24415
24416 ;;
24417 esac
24418
24419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
24420 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
24421 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
24422 $as_echo_n "(cached) " >&6
24423 else
24424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24425 /* end confdefs.h. */
24426 #include <sys/time.h>
24427 struct timeval c;
24428 int gettimeofday (struct timeval *restrict, void *restrict);
24429
24430 int
24431 main ()
24432 {
24433 /* glibc uses struct timezone * rather than the POSIX void *
24434 if _GNU_SOURCE is defined. However, since the only portable
24435 use of gettimeofday uses NULL as the second parameter, and
24436 since the glibc definition is actually more typesafe, it is
24437 not worth wrapping this to get a compliant signature. */
24438 int (*f) (struct timeval *restrict, void *restrict)
24439 = gettimeofday;
24440 int x = f (&c, 0);
24441 return !(x | c.tv_sec | c.tv_usec);
24442
24443 ;
24444 return 0;
24445 }
24446 _ACEOF
24447 if ac_fn_c_try_compile "$LINENO"; then :
24448 gl_cv_func_gettimeofday_posix_signature=yes
24449 else
24450 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24451 /* end confdefs.h. */
24452 #include <sys/time.h>
24453 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
24454
24455 int
24456 main ()
24457 {
24458
24459 ;
24460 return 0;
24461 }
24462 _ACEOF
24463 if ac_fn_c_try_compile "$LINENO"; then :
24464 gl_cv_func_gettimeofday_posix_signature=almost
24465 else
24466 gl_cv_func_gettimeofday_posix_signature=no
24467 fi
24468 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24469 fi
24470 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24471 fi
24472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
24473 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
24474 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
24475 gl_gettimeofday_timezone='struct timezone'
24476 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
24477 REPLACE_GETTIMEOFDAY=1
24478 fi
24479 if test $REPLACE_STRUCT_TIMEVAL = 1; then
24480 REPLACE_GETTIMEOFDAY=1
24481 fi
24482
24483 fi
24484
24485 cat >>confdefs.h <<_ACEOF
24486 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
24487 _ACEOF
24488
24489
24490 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
24491
24492
24493
24494
24495
24496
24497
24498
24499 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
24500
24501
24502 for ac_header in sys/timeb.h
24503 do :
24504 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
24505 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
24506 cat >>confdefs.h <<_ACEOF
24507 #define HAVE_SYS_TIMEB_H 1
24508 _ACEOF
24509
24510 fi
24511
24512 done
24513
24514 for ac_func in _ftime
24515 do :
24516 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
24517 if test "x$ac_cv_func__ftime" = x""yes; then :
24518 cat >>confdefs.h <<_ACEOF
24519 #define HAVE__FTIME 1
24520 _ACEOF
24521
24522 fi
24523 done
24524
24525
24526 fi
24527
24528
24529
24530
24531
24532 GNULIB_GETTIMEOFDAY=1
24533
24534
24535
24536
24537
24538
24539
24540
24541
24542
24543 if test $ac_cv_func_lstat = yes; then
24544
24545 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
24546 *no)
24547 REPLACE_LSTAT=1
24548 ;;
24549 esac
24550 else
24551 HAVE_LSTAT=0
24552 fi
24553
24554 if test $REPLACE_LSTAT = 1; then
24555
24556
24557
24558
24559
24560
24561
24562
24563 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
24564
24565 :
24566 fi
24567
24568
24569
24570
24571
24572 GNULIB_LSTAT=1
24573
24574
24575
24576
24577
24578
24579
24580
24581
24582
24583 if test $ac_cv_have_decl_memrchr = no; then
24584 HAVE_DECL_MEMRCHR=0
24585 fi
24586
24587 for ac_func in memrchr
24588 do :
24589 ac_fn_c_check_func "$LINENO" "memrchr" "ac_cv_func_memrchr"
24590 if test "x$ac_cv_func_memrchr" = x""yes; then :
24591 cat >>confdefs.h <<_ACEOF
24592 #define HAVE_MEMRCHR 1
24593 _ACEOF
24594
24595 fi
24596 done
24597
24598
24599 if test $ac_cv_func_memrchr = no; then
24600
24601
24602
24603
24604
24605
24606
24607
24608 gl_LIBOBJS="$gl_LIBOBJS memrchr.$ac_objext"
24609
24610 :
24611 fi
24612
24613
24614
24615
24616
24617 GNULIB_MEMRCHR=1
24618
24619
24620
24621
24622
24623
24624
24625
24626
24627
24628
24629 if test $ac_cv_func_mkostemp != yes; then
24630 HAVE_MKOSTEMP=0
24631 fi
24632
24633 if test $HAVE_MKOSTEMP = 0; then
24634
24635
24636
24637
24638
24639
24640
24641
24642 gl_LIBOBJS="$gl_LIBOBJS mkostemp.$ac_objext"
24643
24644
24645
24646 fi
24647
24648
24649 cat >>confdefs.h <<_ACEOF
24650 #define GNULIB_MKOSTEMP 1
24651 _ACEOF
24652
24653
24654
24655
24656
24657
24658
24659 GNULIB_MKOSTEMP=1
24660
24661
24662
24663
24664
24665
24666
24667
24668
24669
24670
24671 if test $APPLE_UNIVERSAL_BUILD = 1; then
24672 # A universal build on Apple Mac OS X platforms.
24673 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
24674 # But we need a configuration result that is valid in both modes.
24675 gl_cv_func_working_mktime=no
24676 fi
24677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
24678 $as_echo_n "checking for working mktime... " >&6; }
24679 if test "${gl_cv_func_working_mktime+set}" = set; then :
24680 $as_echo_n "(cached) " >&6
24681 else
24682 if test "$cross_compiling" = yes; then :
24683 gl_cv_func_working_mktime=no
24684 else
24685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24686 /* end confdefs.h. */
24687 /* Test program from Paul Eggert and Tony Leneis. */
24688 #include <limits.h>
24689 #include <stdlib.h>
24690 #include <time.h>
24691
24692 #ifdef HAVE_UNISTD_H
24693 # include <unistd.h>
24694 #endif
24695
24696 #if HAVE_DECL_ALARM
24697 # include <signal.h>
24698 #endif
24699
24700 /* Work around redefinition to rpl_putenv by other config tests. */
24701 #undef putenv
24702
24703 static time_t time_t_max;
24704 static time_t time_t_min;
24705
24706 /* Values we'll use to set the TZ environment variable. */
24707 static char *tz_strings[] = {
24708 (char *) 0, "TZ=GMT0", "TZ=JST-9",
24709 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
24710 };
24711 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
24712
24713 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
24714 Based on a problem report from Andreas Jaeger. */
24715 static int
24716 spring_forward_gap ()
24717 {
24718 /* glibc (up to about 1998-10-07) failed this test. */
24719 struct tm tm;
24720
24721 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24722 instead of "TZ=America/Vancouver" in order to detect the bug even
24723 on systems that don't support the Olson extension, or don't have the
24724 full zoneinfo tables installed. */
24725 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24726
24727 tm.tm_year = 98;
24728 tm.tm_mon = 3;
24729 tm.tm_mday = 5;
24730 tm.tm_hour = 2;
24731 tm.tm_min = 0;
24732 tm.tm_sec = 0;
24733 tm.tm_isdst = -1;
24734 return mktime (&tm) != (time_t) -1;
24735 }
24736
24737 static int
24738 mktime_test1 (time_t now)
24739 {
24740 struct tm *lt;
24741 return ! (lt = localtime (&now)) || mktime (lt) == now;
24742 }
24743
24744 static int
24745 mktime_test (time_t now)
24746 {
24747 return (mktime_test1 (now)
24748 && mktime_test1 ((time_t) (time_t_max - now))
24749 && mktime_test1 ((time_t) (time_t_min + now)));
24750 }
24751
24752 static int
24753 irix_6_4_bug ()
24754 {
24755 /* Based on code from Ariel Faigon. */
24756 struct tm tm;
24757 tm.tm_year = 96;
24758 tm.tm_mon = 3;
24759 tm.tm_mday = 0;
24760 tm.tm_hour = 0;
24761 tm.tm_min = 0;
24762 tm.tm_sec = 0;
24763 tm.tm_isdst = -1;
24764 mktime (&tm);
24765 return tm.tm_mon == 2 && tm.tm_mday == 31;
24766 }
24767
24768 static int
24769 bigtime_test (int j)
24770 {
24771 struct tm tm;
24772 time_t now;
24773 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
24774 now = mktime (&tm);
24775 if (now != (time_t) -1)
24776 {
24777 struct tm *lt = localtime (&now);
24778 if (! (lt
24779 && lt->tm_year == tm.tm_year
24780 && lt->tm_mon == tm.tm_mon
24781 && lt->tm_mday == tm.tm_mday
24782 && lt->tm_hour == tm.tm_hour
24783 && lt->tm_min == tm.tm_min
24784 && lt->tm_sec == tm.tm_sec
24785 && lt->tm_yday == tm.tm_yday
24786 && lt->tm_wday == tm.tm_wday
24787 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
24788 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
24789 return 0;
24790 }
24791 return 1;
24792 }
24793
24794 static int
24795 year_2050_test ()
24796 {
24797 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
24798 ignoring leap seconds. */
24799 unsigned long int answer = 2527315200UL;
24800
24801 struct tm tm;
24802 time_t t;
24803 tm.tm_year = 2050 - 1900;
24804 tm.tm_mon = 2 - 1;
24805 tm.tm_mday = 1;
24806 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
24807 tm.tm_isdst = -1;
24808
24809 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
24810 instead of "TZ=America/Vancouver" in order to detect the bug even
24811 on systems that don't support the Olson extension, or don't have the
24812 full zoneinfo tables installed. */
24813 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
24814
24815 t = mktime (&tm);
24816
24817 /* Check that the result is either a failure, or close enough
24818 to the correct answer that we can assume the discrepancy is
24819 due to leap seconds. */
24820 return (t == (time_t) -1
24821 || (0 < t && answer - 120 <= t && t <= answer + 120));
24822 }
24823
24824 int
24825 main ()
24826 {
24827 int result = 0;
24828 time_t t, delta;
24829 int i, j;
24830 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
24831 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
24832
24833 #if HAVE_DECL_ALARM
24834 /* This test makes some buggy mktime implementations loop.
24835 Give up after 60 seconds; a mktime slower than that
24836 isn't worth using anyway. */
24837 signal (SIGALRM, SIG_DFL);
24838 alarm (60);
24839 #endif
24840
24841 time_t_max = (! time_t_signed
24842 ? (time_t) -1
24843 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
24844 * 2 + 1));
24845 time_t_min = (! time_t_signed
24846 ? (time_t) 0
24847 : time_t_signed_magnitude
24848 ? ~ (time_t) 0
24849 : ~ time_t_max);
24850
24851 delta = time_t_max / 997; /* a suitable prime number */
24852 for (i = 0; i < N_STRINGS; i++)
24853 {
24854 if (tz_strings[i])
24855 putenv (tz_strings[i]);
24856
24857 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
24858 if (! mktime_test (t))
24859 result |= 1;
24860 if ((result & 2) == 0
24861 && ! (mktime_test ((time_t) 1)
24862 && mktime_test ((time_t) (60 * 60))
24863 && mktime_test ((time_t) (60 * 60 * 24))))
24864 result |= 2;
24865
24866 for (j = 1; (result & 4) == 0; j <<= 1)
24867 {
24868 if (! bigtime_test (j))
24869 result |= 4;
24870 if (INT_MAX / 2 < j)
24871 break;
24872 }
24873 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
24874 result |= 8;
24875 }
24876 if (! irix_6_4_bug ())
24877 result |= 16;
24878 if (! spring_forward_gap ())
24879 result |= 32;
24880 if (! year_2050_test ())
24881 result |= 64;
24882 return result;
24883 }
24884 _ACEOF
24885 if ac_fn_c_try_run "$LINENO"; then :
24886 gl_cv_func_working_mktime=yes
24887 else
24888 gl_cv_func_working_mktime=no
24889 fi
24890 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
24891 conftest.$ac_objext conftest.beam conftest.$ac_ext
24892 fi
24893
24894
24895 fi
24896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
24897 $as_echo "$gl_cv_func_working_mktime" >&6; }
24898
24899 if test $gl_cv_func_working_mktime = no; then
24900 REPLACE_MKTIME=1
24901 else
24902 REPLACE_MKTIME=0
24903 fi
24904
24905 if test $REPLACE_MKTIME = 1; then
24906
24907
24908
24909
24910
24911
24912
24913
24914 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
24915
24916 :
24917 fi
24918
24919
24920
24921
24922
24923 GNULIB_MKTIME=1
24924
24925
24926
24927
24928
24929
24930
24931
24932
24933
24934
24935
24936 if test $ac_cv_func_pipe2 != yes; then
24937 HAVE_PIPE2=0
24938 fi
24939
24940
24941
24942
24943
24944
24945 GNULIB_PIPE2=1
24946
24947
24948
24949
24950
24951
24952
24953
24954
24955
24956 if test $ac_cv_func_pselect = yes; then
24957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
24958 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
24959 if test "${gl_cv_sig_pselect+set}" = set; then :
24960 $as_echo_n "(cached) " >&6
24961 else
24962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
24963 /* end confdefs.h. */
24964 #include <sys/select.h>
24965
24966 int
24967 main ()
24968 {
24969 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
24970 struct timespec const *restrict,
24971 sigset_t const *restrict) = pselect;
24972 return !p;
24973 ;
24974 return 0;
24975 }
24976 _ACEOF
24977 if ac_fn_c_try_link "$LINENO"; then :
24978 gl_cv_sig_pselect=yes
24979 else
24980 gl_cv_sig_pselect=no
24981 fi
24982 rm -f core conftest.err conftest.$ac_objext \
24983 conftest$ac_exeext conftest.$ac_ext
24984 fi
24985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
24986 $as_echo "$gl_cv_sig_pselect" >&6; }
24987
24988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pselect detects invalid fds" >&5
24989 $as_echo_n "checking whether pselect detects invalid fds... " >&6; }
24990 if test "${gl_cv_func_pselect_detects_ebadf+set}" = set; then :
24991 $as_echo_n "(cached) " >&6
24992 else
24993
24994 if test "$cross_compiling" = yes; then :
24995
24996 case "$host_os" in
24997 # Guess yes on glibc systems.
24998 *-gnu*) gl_cv_func_pselect_detects_ebadf="guessing yes" ;;
24999 # If we don't know, assume the worst.
25000 *) gl_cv_func_pselect_detects_ebadf="guessing no" ;;
25001 esac
25002
25003 else
25004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25005 /* end confdefs.h. */
25006
25007 #include <sys/types.h>
25008 #include <sys/time.h>
25009 #if HAVE_SYS_SELECT_H
25010 # include <sys/select.h>
25011 #endif
25012 #include <unistd.h>
25013 #include <errno.h>
25014
25015 int
25016 main ()
25017 {
25018
25019 fd_set set;
25020 dup2(0, 16);
25021 FD_ZERO(&set);
25022 FD_SET(16, &set);
25023 close(16);
25024 struct timespec timeout;
25025 timeout.tv_sec = 0;
25026 timeout.tv_nsec = 5000;
25027 return pselect (17, &set, NULL, NULL, &timeout, NULL) != -1 || errno != EBADF;
25028
25029 ;
25030 return 0;
25031 }
25032 _ACEOF
25033 if ac_fn_c_try_run "$LINENO"; then :
25034 gl_cv_func_pselect_detects_ebadf=yes
25035 else
25036 gl_cv_func_pselect_detects_ebadf=no
25037 fi
25038 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25039 conftest.$ac_objext conftest.beam conftest.$ac_ext
25040 fi
25041
25042
25043 fi
25044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pselect_detects_ebadf" >&5
25045 $as_echo "$gl_cv_func_pselect_detects_ebadf" >&6; }
25046 case $gl_cv_func_pselect_detects_ebadf in
25047 *yes) ;;
25048 *) REPLACE_PSELECT=1 ;;
25049 esac
25050 fi
25051
25052 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
25053 REPLACE_PSELECT=1
25054 fi
25055
25056 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
25057
25058
25059
25060
25061
25062
25063
25064
25065 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
25066
25067 fi
25068
25069
25070
25071
25072
25073 GNULIB_PSELECT=1
25074
25075
25076
25077
25078
25079
25080
25081
25082
25083 LIB_PTHREAD_SIGMASK=
25084
25085
25086
25087
25088 if test "$gl_threads_api" = posix; then
25089 if test $ac_cv_func_pthread_sigmask = yes; then
25090 :
25091 else
25092 if test -n "$LIBMULTITHREAD"; then
25093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_sigmask in $LIBMULTITHREAD" >&5
25094 $as_echo_n "checking for pthread_sigmask in $LIBMULTITHREAD... " >&6; }
25095 if test "${gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD+set}" = set; then :
25096 $as_echo_n "(cached) " >&6
25097 else
25098 gl_save_LIBS="$LIBS"
25099 LIBS="$LIBS $LIBMULTITHREAD"
25100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25101 /* end confdefs.h. */
25102 #include <pthread.h>
25103 #include <signal.h>
25104
25105 int
25106 main ()
25107 {
25108 return pthread_sigmask (0, (sigset_t *) 0, (sigset_t *) 0);
25109 ;
25110 return 0;
25111 }
25112
25113 _ACEOF
25114 if ac_fn_c_try_link "$LINENO"; then :
25115 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=yes
25116 else
25117 gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD=no
25118 fi
25119 rm -f core conftest.err conftest.$ac_objext \
25120 conftest$ac_exeext conftest.$ac_ext
25121 LIBS="$gl_save_LIBS"
25122
25123 fi
25124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&5
25125 $as_echo "$gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD" >&6; }
25126 if test $gl_cv_func_pthread_sigmask_in_LIBMULTITHREAD = yes; then
25127 LIB_PTHREAD_SIGMASK="$LIBMULTITHREAD"
25128 else
25129 HAVE_PTHREAD_SIGMASK=0
25130 fi
25131 else
25132 HAVE_PTHREAD_SIGMASK=0
25133 fi
25134 fi
25135 else
25136 if test $ac_cv_func_pthread_sigmask = yes; then
25137 REPLACE_PTHREAD_SIGMASK=1
25138 else
25139 HAVE_PTHREAD_SIGMASK=0
25140 fi
25141 fi
25142
25143
25144
25145
25146 if test $HAVE_PTHREAD_SIGMASK = 1; then
25147
25148
25149 if test -z "$LIB_PTHREAD_SIGMASK"; then
25150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
25151 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
25152 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
25153 $as_echo_n "(cached) " >&6
25154 else
25155
25156 if test "$cross_compiling" = yes; then :
25157
25158 case "$host_os" in
25159 freebsd* | hpux* | solaris | solaris2.[2-9]*)
25160 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
25161 *)
25162 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
25163 esac
25164
25165 else
25166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25167 /* end confdefs.h. */
25168
25169 #include <pthread.h>
25170 #include <signal.h>
25171 #include <stddef.h>
25172 int main ()
25173 {
25174 sigset_t set;
25175 sigemptyset (&set);
25176 return pthread_sigmask (1729, &set, NULL) != 0;
25177 }
25178 _ACEOF
25179 if ac_fn_c_try_run "$LINENO"; then :
25180 gl_cv_func_pthread_sigmask_in_libc_works=no
25181 else
25182 gl_cv_func_pthread_sigmask_in_libc_works=yes
25183 fi
25184 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25185 conftest.$ac_objext conftest.beam conftest.$ac_ext
25186 fi
25187
25188
25189 fi
25190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
25191 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
25192 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
25193 *no)
25194 REPLACE_PTHREAD_SIGMASK=1
25195
25196 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
25197
25198 ;;
25199 esac
25200 fi
25201
25202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
25203 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
25204 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
25205 $as_echo_n "(cached) " >&6
25206 else
25207
25208 gl_save_LIBS="$LIBS"
25209 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
25210 if test "$cross_compiling" = yes; then :
25211 case "$host_os" in
25212 cygwin*)
25213 gl_cv_func_pthread_sigmask_return_works="guessing no";;
25214 *)
25215 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
25216 esac
25217
25218 else
25219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25220 /* end confdefs.h. */
25221
25222 #include <pthread.h>
25223 #include <signal.h>
25224 #include <stddef.h>
25225 int main ()
25226 {
25227 sigset_t set;
25228 sigemptyset (&set);
25229 if (pthread_sigmask (1729, &set, NULL) == -1)
25230 return 1;
25231 return 0;
25232 }
25233 _ACEOF
25234 if ac_fn_c_try_run "$LINENO"; then :
25235 gl_cv_func_pthread_sigmask_return_works=yes
25236 else
25237 gl_cv_func_pthread_sigmask_return_works=no
25238 fi
25239 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25240 conftest.$ac_objext conftest.beam conftest.$ac_ext
25241 fi
25242
25243 LIBS="$gl_save_LIBS"
25244
25245 fi
25246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
25247 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
25248 case "$gl_cv_func_pthread_sigmask_return_works" in
25249 *no)
25250 REPLACE_PTHREAD_SIGMASK=1
25251
25252 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
25253
25254 ;;
25255 esac
25256
25257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
25258 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
25259 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
25260 $as_echo_n "(cached) " >&6
25261 else
25262
25263 case "$host_os" in
25264 irix*)
25265 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
25266 *)
25267 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
25268 esac
25269 gl_save_LIBS="$LIBS"
25270 LIBS="$LIBS $LIBMULTITHREAD"
25271 if test "$cross_compiling" = yes; then :
25272 :
25273 else
25274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25275 /* end confdefs.h. */
25276
25277 #include <pthread.h>
25278 #include <signal.h>
25279 #include <stdio.h>
25280 #include <stdlib.h>
25281 #include <unistd.h>
25282 static volatile int sigint_occurred;
25283 static void
25284 sigint_handler (int sig)
25285 {
25286 sigint_occurred++;
25287 }
25288 int main ()
25289 {
25290 sigset_t set;
25291 int pid = getpid ();
25292 char command[80];
25293 signal (SIGINT, sigint_handler);
25294 sigemptyset (&set);
25295 sigaddset (&set, SIGINT);
25296 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
25297 return 1;
25298 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
25299 if (!(system (command) == 0))
25300 return 2;
25301 sleep (2);
25302 if (!(sigint_occurred == 0))
25303 return 3;
25304 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
25305 return 4;
25306 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
25307 return 5;
25308 return 0;
25309 }
25310 _ACEOF
25311 if ac_fn_c_try_run "$LINENO"; then :
25312 :
25313 else
25314 gl_cv_func_pthread_sigmask_unblock_works=no
25315 fi
25316 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25317 conftest.$ac_objext conftest.beam conftest.$ac_ext
25318 fi
25319
25320 LIBS="$gl_save_LIBS"
25321
25322 fi
25323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
25324 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
25325 case "$gl_cv_func_pthread_sigmask_unblock_works" in
25326 *no)
25327 REPLACE_PTHREAD_SIGMASK=1
25328
25329 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
25330
25331 ;;
25332 esac
25333 fi
25334
25335 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
25336
25337
25338
25339
25340
25341
25342
25343
25344 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
25345
25346
25347 if test $HAVE_PTHREAD_SIGMASK = 1; then
25348
25349 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
25350
25351 fi
25352
25353 fi
25354
25355
25356
25357
25358
25359 GNULIB_PTHREAD_SIGMASK=1
25360
25361
25362
25363
25364
25365
25366
25367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for putenv compatible with GNU and SVID" >&5
25368 $as_echo_n "checking for putenv compatible with GNU and SVID... " >&6; }
25369 if test "${gl_cv_func_svid_putenv+set}" = set; then :
25370 $as_echo_n "(cached) " >&6
25371 else
25372 if test "$cross_compiling" = yes; then :
25373 case "$host_os" in
25374 # Guess yes on glibc systems.
25375 *-gnu*) gl_cv_func_svid_putenv="guessing yes" ;;
25376 # If we don't know, assume the worst.
25377 *) gl_cv_func_svid_putenv="guessing no" ;;
25378 esac
25379
25380 else
25381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25382 /* end confdefs.h. */
25383 $ac_includes_default
25384 int
25385 main ()
25386 {
25387
25388 /* Put it in env. */
25389 if (putenv ("CONFTEST_putenv=val"))
25390 return 1;
25391
25392 /* Try to remove it. */
25393 if (putenv ("CONFTEST_putenv"))
25394 return 2;
25395
25396 /* Make sure it was deleted. */
25397 if (getenv ("CONFTEST_putenv") != 0)
25398 return 3;
25399
25400 return 0;
25401
25402 ;
25403 return 0;
25404 }
25405 _ACEOF
25406 if ac_fn_c_try_run "$LINENO"; then :
25407 gl_cv_func_svid_putenv=yes
25408 else
25409 gl_cv_func_svid_putenv=no
25410 fi
25411 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25412 conftest.$ac_objext conftest.beam conftest.$ac_ext
25413 fi
25414
25415
25416 fi
25417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_svid_putenv" >&5
25418 $as_echo "$gl_cv_func_svid_putenv" >&6; }
25419 case "$gl_cv_func_svid_putenv" in
25420 *yes) ;;
25421 *)
25422 REPLACE_PUTENV=1
25423 ;;
25424 esac
25425
25426 if test $REPLACE_PUTENV = 1; then
25427
25428
25429
25430
25431
25432
25433
25434
25435 gl_LIBOBJS="$gl_LIBOBJS putenv.$ac_objext"
25436
25437
25438 ac_fn_c_check_decl "$LINENO" "_putenv" "ac_cv_have_decl__putenv" "$ac_includes_default"
25439 if test "x$ac_cv_have_decl__putenv" = x""yes; then :
25440 ac_have_decl=1
25441 else
25442 ac_have_decl=0
25443 fi
25444
25445 cat >>confdefs.h <<_ACEOF
25446 #define HAVE_DECL__PUTENV $ac_have_decl
25447 _ACEOF
25448
25449
25450 fi
25451
25452
25453
25454
25455
25456 GNULIB_PUTENV=1
25457
25458
25459
25460
25461
25462
25463 # Check whether --enable-acl was given.
25464 if test "${enable_acl+set}" = set; then :
25465 enableval=$enable_acl;
25466 else
25467 enable_acl=auto
25468 fi
25469
25470
25471 LIB_ACL=
25472 use_acl=0
25473 if test "x$enable_acl" != "xno"; then
25474 for ac_header in sys/acl.h
25475 do :
25476 ac_fn_c_check_header_mongrel "$LINENO" "sys/acl.h" "ac_cv_header_sys_acl_h" "$ac_includes_default"
25477 if test "x$ac_cv_header_sys_acl_h" = x""yes; then :
25478 cat >>confdefs.h <<_ACEOF
25479 #define HAVE_SYS_ACL_H 1
25480 _ACEOF
25481
25482 fi
25483
25484 done
25485
25486 if test $ac_cv_header_sys_acl_h = yes; then
25487 ac_save_LIBS=$LIBS
25488
25489 if test $use_acl = 0; then
25490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_get_file" >&5
25491 $as_echo_n "checking for library containing acl_get_file... " >&6; }
25492 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25493 $as_echo_n "(cached) " >&6
25494 else
25495 ac_func_search_save_LIBS=$LIBS
25496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25497 /* end confdefs.h. */
25498
25499 /* Override any GCC internal prototype to avoid an error.
25500 Use char because int might match the return type of a GCC
25501 builtin and then its argument prototype would still apply. */
25502 #ifdef __cplusplus
25503 extern "C"
25504 #endif
25505 char acl_get_file ();
25506 int
25507 main ()
25508 {
25509 return acl_get_file ();
25510 ;
25511 return 0;
25512 }
25513 _ACEOF
25514 for ac_lib in '' acl pacl; do
25515 if test -z "$ac_lib"; then
25516 ac_res="none required"
25517 else
25518 ac_res=-l$ac_lib
25519 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25520 fi
25521 if ac_fn_c_try_link "$LINENO"; then :
25522 ac_cv_search_acl_get_file=$ac_res
25523 fi
25524 rm -f core conftest.err conftest.$ac_objext \
25525 conftest$ac_exeext
25526 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25527 break
25528 fi
25529 done
25530 if test "${ac_cv_search_acl_get_file+set}" = set; then :
25531
25532 else
25533 ac_cv_search_acl_get_file=no
25534 fi
25535 rm conftest.$ac_ext
25536 LIBS=$ac_func_search_save_LIBS
25537 fi
25538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_get_file" >&5
25539 $as_echo "$ac_cv_search_acl_get_file" >&6; }
25540 ac_res=$ac_cv_search_acl_get_file
25541 if test "$ac_res" != no; then :
25542 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25543 if test "$ac_cv_search_acl_get_file" != "none required"; then
25544 LIB_ACL=$ac_cv_search_acl_get_file
25545 fi
25546 for ac_func in acl_get_file acl_get_fd acl_set_file acl_set_fd \
25547 acl_free acl_from_mode acl_from_text \
25548 acl_delete_def_file acl_extended_file \
25549 acl_delete_fd_np acl_delete_file_np \
25550 acl_copy_ext_native acl_create_entry_np \
25551 acl_to_short_text acl_free_text
25552 do :
25553 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
25554 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
25555 eval as_val=\$$as_ac_var
25556 if test "x$as_val" = x""yes; then :
25557 cat >>confdefs.h <<_ACEOF
25558 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
25559 _ACEOF
25560
25561 fi
25562 done
25563
25564 # If the acl_get_file bug is detected, don't enable the ACL support.
25565
25566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working acl_get_file" >&5
25567 $as_echo_n "checking for working acl_get_file... " >&6; }
25568 if test "${gl_cv_func_working_acl_get_file+set}" = set; then :
25569 $as_echo_n "(cached) " >&6
25570 else
25571 gl_cv_func_working_acl_get_file=no
25572 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25573 /* end confdefs.h. */
25574 #include <sys/types.h>
25575 #include <sys/acl.h>
25576 #include <errno.h>
25577
25578 int
25579 main ()
25580 {
25581 if (!acl_get_file (".", ACL_TYPE_ACCESS) && errno == ENOENT)
25582 return 1;
25583 return 0;
25584
25585 ;
25586 return 0;
25587 }
25588 _ACEOF
25589 if ac_fn_c_try_link "$LINENO"; then :
25590 if test $cross_compiling = yes; then
25591 gl_cv_func_working_acl_get_file="guessing yes"
25592 elif ./conftest$ac_exeext; then
25593 gl_cv_func_working_acl_get_file=yes
25594 fi
25595 fi
25596 rm -f core conftest.err conftest.$ac_objext \
25597 conftest$ac_exeext conftest.$ac_ext
25598 fi
25599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_acl_get_file" >&5
25600 $as_echo "$gl_cv_func_working_acl_get_file" >&6; }
25601 if test "$gl_cv_func_working_acl_get_file" != no; then :
25602 use_acl=1
25603 fi
25604
25605 if test $use_acl = 1; then
25606 for ac_header in acl/libacl.h
25607 do :
25608 ac_fn_c_check_header_mongrel "$LINENO" "acl/libacl.h" "ac_cv_header_acl_libacl_h" "$ac_includes_default"
25609 if test "x$ac_cv_header_acl_libacl_h" = x""yes; then :
25610 cat >>confdefs.h <<_ACEOF
25611 #define HAVE_ACL_LIBACL_H 1
25612 _ACEOF
25613
25614 fi
25615
25616 done
25617
25618
25619
25620
25621
25622
25623
25624
25625
25626 for ac_func in acl_entries
25627 do :
25628 ac_fn_c_check_func "$LINENO" "acl_entries" "ac_cv_func_acl_entries"
25629 if test "x$ac_cv_func_acl_entries" = x""yes; then :
25630 cat >>confdefs.h <<_ACEOF
25631 #define HAVE_ACL_ENTRIES 1
25632 _ACEOF
25633
25634 else
25635
25636 gl_LIBOBJS="$gl_LIBOBJS $ac_func.$ac_objext"
25637
25638 fi
25639 done
25640
25641
25642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_FIRST_ENTRY" >&5
25643 $as_echo_n "checking for ACL_FIRST_ENTRY... " >&6; }
25644 if test "${gl_cv_acl_ACL_FIRST_ENTRY+set}" = set; then :
25645 $as_echo_n "(cached) " >&6
25646 else
25647 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25648 /* end confdefs.h. */
25649 #include <sys/types.h>
25650 #include <sys/acl.h>
25651 int type = ACL_FIRST_ENTRY;
25652 int
25653 main ()
25654 {
25655
25656 ;
25657 return 0;
25658 }
25659 _ACEOF
25660 if ac_fn_c_try_compile "$LINENO"; then :
25661 gl_cv_acl_ACL_FIRST_ENTRY=yes
25662 else
25663 gl_cv_acl_ACL_FIRST_ENTRY=no
25664 fi
25665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25666 fi
25667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_FIRST_ENTRY" >&5
25668 $as_echo "$gl_cv_acl_ACL_FIRST_ENTRY" >&6; }
25669 if test $gl_cv_acl_ACL_FIRST_ENTRY = yes; then
25670
25671 $as_echo "#define HAVE_ACL_FIRST_ENTRY 1" >>confdefs.h
25672
25673 fi
25674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ACL_TYPE_EXTENDED" >&5
25675 $as_echo_n "checking for ACL_TYPE_EXTENDED... " >&6; }
25676 if test "${gl_cv_acl_ACL_TYPE_EXTENDED+set}" = set; then :
25677 $as_echo_n "(cached) " >&6
25678 else
25679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25680 /* end confdefs.h. */
25681 #include <sys/types.h>
25682 #include <sys/acl.h>
25683 int type = ACL_TYPE_EXTENDED;
25684 int
25685 main ()
25686 {
25687
25688 ;
25689 return 0;
25690 }
25691 _ACEOF
25692 if ac_fn_c_try_compile "$LINENO"; then :
25693 gl_cv_acl_ACL_TYPE_EXTENDED=yes
25694 else
25695 gl_cv_acl_ACL_TYPE_EXTENDED=no
25696 fi
25697 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25698 fi
25699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_acl_ACL_TYPE_EXTENDED" >&5
25700 $as_echo "$gl_cv_acl_ACL_TYPE_EXTENDED" >&6; }
25701 if test $gl_cv_acl_ACL_TYPE_EXTENDED = yes; then
25702
25703 $as_echo "#define HAVE_ACL_TYPE_EXTENDED 1" >>confdefs.h
25704
25705 fi
25706 else
25707 LIB_ACL=
25708 fi
25709
25710 fi
25711
25712 fi
25713
25714 if test $use_acl = 0; then
25715 for ac_func in facl
25716 do :
25717 ac_fn_c_check_func "$LINENO" "facl" "ac_cv_func_facl"
25718 if test "x$ac_cv_func_facl" = x""yes; then :
25719 cat >>confdefs.h <<_ACEOF
25720 #define HAVE_FACL 1
25721 _ACEOF
25722
25723 fi
25724 done
25725
25726 if test $ac_cv_func_facl = yes; then
25727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing acl_trivial" >&5
25728 $as_echo_n "checking for library containing acl_trivial... " >&6; }
25729 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25730 $as_echo_n "(cached) " >&6
25731 else
25732 ac_func_search_save_LIBS=$LIBS
25733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25734 /* end confdefs.h. */
25735
25736 /* Override any GCC internal prototype to avoid an error.
25737 Use char because int might match the return type of a GCC
25738 builtin and then its argument prototype would still apply. */
25739 #ifdef __cplusplus
25740 extern "C"
25741 #endif
25742 char acl_trivial ();
25743 int
25744 main ()
25745 {
25746 return acl_trivial ();
25747 ;
25748 return 0;
25749 }
25750 _ACEOF
25751 for ac_lib in '' sec; do
25752 if test -z "$ac_lib"; then
25753 ac_res="none required"
25754 else
25755 ac_res=-l$ac_lib
25756 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
25757 fi
25758 if ac_fn_c_try_link "$LINENO"; then :
25759 ac_cv_search_acl_trivial=$ac_res
25760 fi
25761 rm -f core conftest.err conftest.$ac_objext \
25762 conftest$ac_exeext
25763 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25764 break
25765 fi
25766 done
25767 if test "${ac_cv_search_acl_trivial+set}" = set; then :
25768
25769 else
25770 ac_cv_search_acl_trivial=no
25771 fi
25772 rm conftest.$ac_ext
25773 LIBS=$ac_func_search_save_LIBS
25774 fi
25775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_acl_trivial" >&5
25776 $as_echo "$ac_cv_search_acl_trivial" >&6; }
25777 ac_res=$ac_cv_search_acl_trivial
25778 if test "$ac_res" != no; then :
25779 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
25780 if test "$ac_cv_search_acl_trivial" != "none required"; then
25781 LIB_ACL=$ac_cv_search_acl_trivial
25782 fi
25783
25784 fi
25785
25786 for ac_func in acl_trivial
25787 do :
25788 ac_fn_c_check_func "$LINENO" "acl_trivial" "ac_cv_func_acl_trivial"
25789 if test "x$ac_cv_func_acl_trivial" = x""yes; then :
25790 cat >>confdefs.h <<_ACEOF
25791 #define HAVE_ACL_TRIVIAL 1
25792 _ACEOF
25793
25794 fi
25795 done
25796
25797 use_acl=1
25798 fi
25799 fi
25800
25801 if test $use_acl = 0; then
25802 for ac_func in getacl
25803 do :
25804 ac_fn_c_check_func "$LINENO" "getacl" "ac_cv_func_getacl"
25805 if test "x$ac_cv_func_getacl" = x""yes; then :
25806 cat >>confdefs.h <<_ACEOF
25807 #define HAVE_GETACL 1
25808 _ACEOF
25809
25810 fi
25811 done
25812
25813 if test $ac_cv_func_getacl = yes; then
25814 use_acl=1
25815 fi
25816 for ac_header in aclv.h
25817 do :
25818 ac_fn_c_check_header_compile "$LINENO" "aclv.h" "ac_cv_header_aclv_h" "#include <sys/types.h>
25819 "
25820 if test "x$ac_cv_header_aclv_h" = x""yes; then :
25821 cat >>confdefs.h <<_ACEOF
25822 #define HAVE_ACLV_H 1
25823 _ACEOF
25824
25825 fi
25826
25827 done
25828
25829 fi
25830
25831 if test $use_acl = 0; then
25832 for ac_func in aclx_get
25833 do :
25834 ac_fn_c_check_func "$LINENO" "aclx_get" "ac_cv_func_aclx_get"
25835 if test "x$ac_cv_func_aclx_get" = x""yes; then :
25836 cat >>confdefs.h <<_ACEOF
25837 #define HAVE_ACLX_GET 1
25838 _ACEOF
25839
25840 fi
25841 done
25842
25843 if test $ac_cv_func_aclx_get = yes; then
25844 use_acl=1
25845 fi
25846 fi
25847
25848 if test $use_acl = 0 || test "$ac_cv_func_aclx_get" = yes; then
25849 for ac_func in statacl
25850 do :
25851 ac_fn_c_check_func "$LINENO" "statacl" "ac_cv_func_statacl"
25852 if test "x$ac_cv_func_statacl" = x""yes; then :
25853 cat >>confdefs.h <<_ACEOF
25854 #define HAVE_STATACL 1
25855 _ACEOF
25856
25857 fi
25858 done
25859
25860 if test $ac_cv_func_statacl = yes; then
25861 use_acl=1
25862 fi
25863 fi
25864
25865 if test $use_acl = 0; then
25866 for ac_func in aclsort
25867 do :
25868 ac_fn_c_check_func "$LINENO" "aclsort" "ac_cv_func_aclsort"
25869 if test "x$ac_cv_func_aclsort" = x""yes; then :
25870 cat >>confdefs.h <<_ACEOF
25871 #define HAVE_ACLSORT 1
25872 _ACEOF
25873
25874 fi
25875 done
25876
25877 if test $ac_cv_func_aclsort = yes; then
25878 use_acl=1
25879 fi
25880 fi
25881
25882 LIBS=$ac_save_LIBS
25883 fi
25884 if test "x$enable_acl$use_acl" = "xyes0"; then
25885 as_fn_error "ACLs enabled but support not detected" "$LINENO" 5
25886 elif test "x$enable_acl$use_acl" = "xauto0"; then
25887 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libacl development library was not found or not usable." >&5
25888 $as_echo "$as_me: WARNING: libacl development library was not found or not usable." >&2;}
25889 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: emacs will be built without ACL support." >&5
25890 $as_echo "$as_me: WARNING: emacs will be built without ACL support." >&2;}
25891 fi
25892 fi
25893
25894
25895 cat >>confdefs.h <<_ACEOF
25896 #define USE_ACL $use_acl
25897 _ACEOF
25898
25899 USE_ACL=$use_acl
25900
25901
25902
25903
25904
25905 if test $ac_cv_func_readlink = no; then
25906 HAVE_READLINK=0
25907 else
25908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
25909 $as_echo_n "checking whether readlink signature is correct... " >&6; }
25910 if test "${gl_cv_decl_readlink_works+set}" = set; then :
25911 $as_echo_n "(cached) " >&6
25912 else
25913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25914 /* end confdefs.h. */
25915 #include <unistd.h>
25916 /* Cause compilation failure if original declaration has wrong type. */
25917 ssize_t readlink (const char *, char *, size_t);
25918 int
25919 main ()
25920 {
25921
25922 ;
25923 return 0;
25924 }
25925 _ACEOF
25926 if ac_fn_c_try_compile "$LINENO"; then :
25927 gl_cv_decl_readlink_works=yes
25928 else
25929 gl_cv_decl_readlink_works=no
25930 fi
25931 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25932 fi
25933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
25934 $as_echo "$gl_cv_decl_readlink_works" >&6; }
25935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
25936 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
25937 if test "${gl_cv_func_readlink_works+set}" = set; then :
25938 $as_echo_n "(cached) " >&6
25939 else
25940 # We have readlink, so assume ln -s works.
25941 ln -s conftest.no-such conftest.link
25942 ln -s conftest.link conftest.lnk2
25943 if test "$cross_compiling" = yes; then :
25944 case "$host_os" in
25945 # Guess yes on glibc systems.
25946 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
25947 # If we don't know, assume the worst.
25948 *) gl_cv_func_readlink_works="guessing no" ;;
25949 esac
25950
25951 else
25952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
25953 /* end confdefs.h. */
25954 #include <unistd.h>
25955
25956 int
25957 main ()
25958 {
25959 char buf[20];
25960 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
25961 ;
25962 return 0;
25963 }
25964 _ACEOF
25965 if ac_fn_c_try_run "$LINENO"; then :
25966 gl_cv_func_readlink_works=yes
25967 else
25968 gl_cv_func_readlink_works=no
25969 fi
25970 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
25971 conftest.$ac_objext conftest.beam conftest.$ac_ext
25972 fi
25973
25974 rm -f conftest.link conftest.lnk2
25975 fi
25976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
25977 $as_echo "$gl_cv_func_readlink_works" >&6; }
25978 case "$gl_cv_func_readlink_works" in
25979 *yes)
25980 if test "$gl_cv_decl_readlink_works" != yes; then
25981 REPLACE_READLINK=1
25982 fi
25983 ;;
25984 *)
25985
25986 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
25987
25988 REPLACE_READLINK=1
25989 ;;
25990 esac
25991 fi
25992
25993 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
25994
25995
25996
25997
25998
25999
26000
26001
26002 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
26003
26004
26005 :
26006
26007 fi
26008
26009
26010
26011
26012
26013 GNULIB_READLINK=1
26014
26015
26016
26017
26018
26019
26020
26021
26022
26023 if test $ac_cv_func_readlinkat = no; then
26024 HAVE_READLINKAT=0
26025 fi
26026
26027 if test $HAVE_READLINKAT = 0; then
26028
26029
26030
26031
26032
26033
26034
26035
26036 gl_LIBOBJS="$gl_LIBOBJS readlinkat.$ac_objext"
26037
26038 fi
26039
26040
26041
26042
26043
26044 GNULIB_READLINKAT=1
26045
26046
26047
26048
26049
26050
26051 for ac_func in sig2str
26052 do :
26053 ac_fn_c_check_func "$LINENO" "sig2str" "ac_cv_func_sig2str"
26054 if test "x$ac_cv_func_sig2str" = x""yes; then :
26055 cat >>confdefs.h <<_ACEOF
26056 #define HAVE_SIG2STR 1
26057 _ACEOF
26058
26059 fi
26060 done
26061
26062
26063 if test $ac_cv_func_sig2str = no; then
26064
26065
26066
26067
26068
26069
26070
26071
26072 gl_LIBOBJS="$gl_LIBOBJS sig2str.$ac_objext"
26073
26074
26075 :
26076
26077 fi
26078
26079
26080
26081
26082
26083
26084
26085
26086
26087
26088
26089 if test $gl_cv_have_include_next = yes; then
26090 gl_cv_next_signal_h='<'signal.h'>'
26091 else
26092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
26093 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
26094 if test "${gl_cv_next_signal_h+set}" = set; then :
26095 $as_echo_n "(cached) " >&6
26096 else
26097
26098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26099 /* end confdefs.h. */
26100 #include <signal.h>
26101
26102 _ACEOF
26103 case "$host_os" in
26104 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26105 *) gl_absname_cpp="$ac_cpp" ;;
26106 esac
26107
26108 case "$host_os" in
26109 mingw*)
26110 gl_dirsep_regex='[/\\]'
26111 ;;
26112 *)
26113 gl_dirsep_regex='\/'
26114 ;;
26115 esac
26116 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26117
26118 gl_header_literal_regex=`echo 'signal.h' \
26119 | sed -e "$gl_make_literal_regex_sed"`
26120 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26121 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26122 s|^/[^/]|//&|
26123 p
26124 q
26125 }'
26126 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26127 sed -n "$gl_absolute_header_sed"`'"'
26128
26129
26130 fi
26131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
26132 $as_echo "$gl_cv_next_signal_h" >&6; }
26133 fi
26134 NEXT_SIGNAL_H=$gl_cv_next_signal_h
26135
26136 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26137 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26138 gl_next_as_first_directive='<'signal.h'>'
26139 else
26140 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26141 gl_next_as_first_directive=$gl_cv_next_signal_h
26142 fi
26143 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
26144
26145
26146
26147
26148
26149 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
26150 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
26151 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
26152 #include <signal.h>
26153
26154 "
26155 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
26156
26157 else
26158 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
26159 fi
26160
26161
26162
26163
26164
26165
26166
26167 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
26168 #include <signal.h>
26169
26170 "
26171 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
26172
26173 else
26174 HAVE_SIGHANDLER_T=0
26175 fi
26176
26177
26178
26179
26180 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
26181 /* <sys/types.h> is not needed according to POSIX, but the
26182 <sys/socket.h> in i386-unknown-freebsd4.10 and
26183 powerpc-apple-darwin5.5 required it. */
26184 #include <sys/types.h>
26185 #if HAVE_SYS_SOCKET_H
26186 # include <sys/socket.h>
26187 #elif HAVE_WS2TCPIP_H
26188 # include <ws2tcpip.h>
26189 #endif
26190
26191 "
26192 if test "x$ac_cv_type_socklen_t" = x""yes; then :
26193
26194 else
26195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
26196 $as_echo_n "checking for socklen_t equivalent... " >&6; }
26197 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
26198 $as_echo_n "(cached) " >&6
26199 else
26200 # Systems have either "struct sockaddr *" or
26201 # "void *" as the second argument to getpeername
26202 gl_cv_socklen_t_equiv=
26203 for arg2 in "struct sockaddr" void; do
26204 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
26205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26206 /* end confdefs.h. */
26207 #include <sys/types.h>
26208 #include <sys/socket.h>
26209
26210 int getpeername (int, $arg2 *, $t *);
26211 int
26212 main ()
26213 {
26214 $t len;
26215 getpeername (0, 0, &len);
26216 ;
26217 return 0;
26218 }
26219 _ACEOF
26220 if ac_fn_c_try_compile "$LINENO"; then :
26221 gl_cv_socklen_t_equiv="$t"
26222 fi
26223 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26224 test "$gl_cv_socklen_t_equiv" != "" && break
26225 done
26226 test "$gl_cv_socklen_t_equiv" != "" && break
26227 done
26228
26229 fi
26230
26231 if test "$gl_cv_socklen_t_equiv" = ""; then
26232 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
26233 fi
26234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
26235 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
26236
26237 cat >>confdefs.h <<_ACEOF
26238 #define socklen_t $gl_cv_socklen_t_equiv
26239 _ACEOF
26240
26241 fi
26242
26243
26244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
26245 $as_echo_n "checking for ssize_t... " >&6; }
26246 if test "${gt_cv_ssize_t+set}" = set; then :
26247 $as_echo_n "(cached) " >&6
26248 else
26249 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26250 /* end confdefs.h. */
26251 #include <sys/types.h>
26252 int
26253 main ()
26254 {
26255 int x = sizeof (ssize_t *) + sizeof (ssize_t);
26256 return !x;
26257 ;
26258 return 0;
26259 }
26260 _ACEOF
26261 if ac_fn_c_try_compile "$LINENO"; then :
26262 gt_cv_ssize_t=yes
26263 else
26264 gt_cv_ssize_t=no
26265 fi
26266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26267 fi
26268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
26269 $as_echo "$gt_cv_ssize_t" >&6; }
26270 if test $gt_cv_ssize_t = no; then
26271
26272 $as_echo "#define ssize_t int" >>confdefs.h
26273
26274 fi
26275
26276
26277
26278
26279
26280 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>
26281 #include <sys/stat.h>
26282 "
26283 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
26284
26285 cat >>confdefs.h <<_ACEOF
26286 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
26287 _ACEOF
26288
26289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
26290 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
26291 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
26292 $as_echo_n "(cached) " >&6
26293 else
26294 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26295 /* end confdefs.h. */
26296
26297 #include <sys/types.h>
26298 #include <sys/stat.h>
26299 #if HAVE_SYS_TIME_H
26300 # include <sys/time.h>
26301 #endif
26302 #include <time.h>
26303 struct timespec ts;
26304 struct stat st;
26305
26306 int
26307 main ()
26308 {
26309
26310 st.st_atim = ts;
26311
26312 ;
26313 return 0;
26314 }
26315 _ACEOF
26316 if ac_fn_c_try_compile "$LINENO"; then :
26317 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
26318 else
26319 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
26320 fi
26321 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26322 fi
26323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
26324 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
26325 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
26326
26327 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
26328
26329 fi
26330 else
26331 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>
26332 #include <sys/stat.h>
26333 "
26334 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
26335
26336 cat >>confdefs.h <<_ACEOF
26337 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
26338 _ACEOF
26339
26340
26341 else
26342 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
26343 #include <sys/stat.h>
26344 "
26345 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
26346
26347 cat >>confdefs.h <<_ACEOF
26348 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
26349 _ACEOF
26350
26351
26352 else
26353 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>
26354 #include <sys/stat.h>
26355 "
26356 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
26357
26358 cat >>confdefs.h <<_ACEOF
26359 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
26360 _ACEOF
26361
26362
26363 fi
26364
26365 fi
26366
26367 fi
26368
26369 fi
26370
26371
26372
26373
26374
26375 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>
26376 #include <sys/stat.h>
26377 "
26378 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
26379
26380 cat >>confdefs.h <<_ACEOF
26381 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
26382 _ACEOF
26383
26384
26385 else
26386 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
26387 #include <sys/stat.h>
26388 "
26389 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
26390
26391 cat >>confdefs.h <<_ACEOF
26392 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
26393 _ACEOF
26394
26395
26396 else
26397 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>
26398 #include <sys/stat.h>
26399 "
26400 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
26401
26402 cat >>confdefs.h <<_ACEOF
26403 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
26404 _ACEOF
26405
26406
26407 fi
26408
26409 fi
26410
26411 fi
26412
26413
26414
26415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
26416 $as_echo_n "checking for working stdalign.h... " >&6; }
26417 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
26418 $as_echo_n "(cached) " >&6
26419 else
26420 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26421 /* end confdefs.h. */
26422 #include <stdalign.h>
26423 #include <stddef.h>
26424
26425 /* Test that alignof yields a result consistent with offsetof.
26426 This catches GCC bug 52023
26427 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
26428 #ifdef __cplusplus
26429 template <class t> struct alignof_helper { char a; t b; };
26430 # define ao(type) offsetof (alignof_helper<type>, b)
26431 #else
26432 # define ao(type) offsetof (struct { char a; type b; }, b)
26433 #endif
26434 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
26435 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
26436 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
26437
26438 /* Test _Alignas only on platforms where gnulib can help. */
26439 #if \
26440 ((defined __cplusplus && 201103 <= __cplusplus) \
26441 || __GNUC__ || __IBMC__ || __IBMCPP__ || __ICC \
26442 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
26443 struct alignas_test { char c; char alignas (8) alignas_8; };
26444 char test_alignas[offsetof (struct alignas_test, alignas_8) == 8
26445 ? 1 : -1];
26446 #endif
26447
26448 int
26449 main ()
26450 {
26451
26452 ;
26453 return 0;
26454 }
26455 _ACEOF
26456 if ac_fn_c_try_compile "$LINENO"; then :
26457 gl_cv_header_working_stdalign_h=yes
26458 else
26459 gl_cv_header_working_stdalign_h=no
26460 fi
26461 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26462 fi
26463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
26464 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
26465
26466 if test $gl_cv_header_working_stdalign_h = yes; then
26467 STDALIGN_H=''
26468 else
26469 STDALIGN_H='stdalign.h'
26470 fi
26471
26472
26473 if test -n "$STDALIGN_H"; then
26474 GL_GENERATE_STDALIGN_H_TRUE=
26475 GL_GENERATE_STDALIGN_H_FALSE='#'
26476 else
26477 GL_GENERATE_STDALIGN_H_TRUE='#'
26478 GL_GENERATE_STDALIGN_H_FALSE=
26479 fi
26480
26481
26482
26483 STDARG_H=''
26484 NEXT_STDARG_H='<stdarg.h>'
26485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
26486 $as_echo_n "checking for va_copy... " >&6; }
26487 if test "${gl_cv_func_va_copy+set}" = set; then :
26488 $as_echo_n "(cached) " >&6
26489 else
26490
26491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26492 /* end confdefs.h. */
26493 #include <stdarg.h>
26494 int
26495 main ()
26496 {
26497
26498 #ifndef va_copy
26499 void (*func) (va_list, va_list) = va_copy;
26500 #endif
26501
26502 ;
26503 return 0;
26504 }
26505 _ACEOF
26506 if ac_fn_c_try_compile "$LINENO"; then :
26507 gl_cv_func_va_copy=yes
26508 else
26509 gl_cv_func_va_copy=no
26510 fi
26511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26512 fi
26513
26514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
26515 $as_echo "$gl_cv_func_va_copy" >&6; }
26516 if test $gl_cv_func_va_copy = no; then
26517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26518 /* end confdefs.h. */
26519 #if defined _AIX && !defined __GNUC__
26520 AIX vaccine
26521 #endif
26522
26523 _ACEOF
26524 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
26525 $EGREP "vaccine" >/dev/null 2>&1; then :
26526 gl_aixcc=yes
26527 else
26528 gl_aixcc=no
26529 fi
26530 rm -f conftest*
26531
26532 if test $gl_aixcc = yes; then
26533 STDARG_H=stdarg.h
26534
26535
26536
26537
26538
26539
26540
26541
26542 if test $gl_cv_have_include_next = yes; then
26543 gl_cv_next_stdarg_h='<'stdarg.h'>'
26544 else
26545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
26546 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
26547 if test "${gl_cv_next_stdarg_h+set}" = set; then :
26548 $as_echo_n "(cached) " >&6
26549 else
26550
26551 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26552 /* end confdefs.h. */
26553 #include <stdarg.h>
26554
26555 _ACEOF
26556 case "$host_os" in
26557 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26558 *) gl_absname_cpp="$ac_cpp" ;;
26559 esac
26560
26561 case "$host_os" in
26562 mingw*)
26563 gl_dirsep_regex='[/\\]'
26564 ;;
26565 *)
26566 gl_dirsep_regex='\/'
26567 ;;
26568 esac
26569 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26570
26571 gl_header_literal_regex=`echo 'stdarg.h' \
26572 | sed -e "$gl_make_literal_regex_sed"`
26573 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26574 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26575 s|^/[^/]|//&|
26576 p
26577 q
26578 }'
26579 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26580 sed -n "$gl_absolute_header_sed"`'"'
26581
26582
26583 fi
26584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
26585 $as_echo "$gl_cv_next_stdarg_h" >&6; }
26586 fi
26587 NEXT_STDARG_H=$gl_cv_next_stdarg_h
26588
26589 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26590 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26591 gl_next_as_first_directive='<'stdarg.h'>'
26592 else
26593 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26594 gl_next_as_first_directive=$gl_cv_next_stdarg_h
26595 fi
26596 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
26597
26598
26599
26600
26601 if test "$gl_cv_next_stdarg_h" = '""'; then
26602 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
26603 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
26604 fi
26605 else
26606
26607 saved_as_echo_n="$as_echo_n"
26608 as_echo_n=':'
26609 if test "${gl_cv_func___va_copy+set}" = set; then :
26610 $as_echo_n "(cached) " >&6
26611 else
26612
26613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26614 /* end confdefs.h. */
26615 #include <stdarg.h>
26616 int
26617 main ()
26618 {
26619
26620 #ifndef __va_copy
26621 error, bail out
26622 #endif
26623
26624 ;
26625 return 0;
26626 }
26627 _ACEOF
26628 if ac_fn_c_try_compile "$LINENO"; then :
26629 gl_cv_func___va_copy=yes
26630 else
26631 gl_cv_func___va_copy=no
26632 fi
26633 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26634 fi
26635
26636 as_echo_n="$saved_as_echo_n"
26637
26638 if test $gl_cv_func___va_copy = yes; then
26639
26640 $as_echo "#define va_copy __va_copy" >>confdefs.h
26641
26642 else
26643
26644
26645 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
26646
26647 fi
26648 fi
26649 fi
26650
26651 if test -n "$STDARG_H"; then
26652 GL_GENERATE_STDARG_H_TRUE=
26653 GL_GENERATE_STDARG_H_FALSE='#'
26654 else
26655 GL_GENERATE_STDARG_H_TRUE='#'
26656 GL_GENERATE_STDARG_H_FALSE=
26657 fi
26658
26659
26660
26661
26662
26663
26664 # Define two additional variables used in the Makefile substitution.
26665
26666 if test "$ac_cv_header_stdbool_h" = yes; then
26667 STDBOOL_H=''
26668 else
26669 STDBOOL_H='stdbool.h'
26670 fi
26671
26672 if test -n "$STDBOOL_H"; then
26673 GL_GENERATE_STDBOOL_H_TRUE=
26674 GL_GENERATE_STDBOOL_H_FALSE='#'
26675 else
26676 GL_GENERATE_STDBOOL_H_TRUE='#'
26677 GL_GENERATE_STDBOOL_H_FALSE=
26678 fi
26679
26680
26681 if test "$ac_cv_type__Bool" = yes; then
26682 HAVE__BOOL=1
26683 else
26684 HAVE__BOOL=0
26685 fi
26686
26687
26688
26689
26690
26691 STDDEF_H=
26692 if test $gt_cv_c_wchar_t = no; then
26693 HAVE_WCHAR_T=0
26694 STDDEF_H=stddef.h
26695 fi
26696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
26697 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
26698 if test "${gl_cv_decl_null_works+set}" = set; then :
26699 $as_echo_n "(cached) " >&6
26700 else
26701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26702 /* end confdefs.h. */
26703 #include <stddef.h>
26704 int test[2 * (sizeof NULL == sizeof (void *)) -1];
26705
26706 int
26707 main ()
26708 {
26709
26710 ;
26711 return 0;
26712 }
26713 _ACEOF
26714 if ac_fn_c_try_compile "$LINENO"; then :
26715 gl_cv_decl_null_works=yes
26716 else
26717 gl_cv_decl_null_works=no
26718 fi
26719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26720 fi
26721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
26722 $as_echo "$gl_cv_decl_null_works" >&6; }
26723 if test $gl_cv_decl_null_works = no; then
26724 REPLACE_NULL=1
26725 STDDEF_H=stddef.h
26726 fi
26727
26728 if test -n "$STDDEF_H"; then
26729 GL_GENERATE_STDDEF_H_TRUE=
26730 GL_GENERATE_STDDEF_H_FALSE='#'
26731 else
26732 GL_GENERATE_STDDEF_H_TRUE='#'
26733 GL_GENERATE_STDDEF_H_FALSE=
26734 fi
26735
26736 if test -n "$STDDEF_H"; then
26737
26738
26739
26740
26741
26742
26743
26744
26745 if test $gl_cv_have_include_next = yes; then
26746 gl_cv_next_stddef_h='<'stddef.h'>'
26747 else
26748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
26749 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
26750 if test "${gl_cv_next_stddef_h+set}" = set; then :
26751 $as_echo_n "(cached) " >&6
26752 else
26753
26754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26755 /* end confdefs.h. */
26756 #include <stddef.h>
26757
26758 _ACEOF
26759 case "$host_os" in
26760 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26761 *) gl_absname_cpp="$ac_cpp" ;;
26762 esac
26763
26764 case "$host_os" in
26765 mingw*)
26766 gl_dirsep_regex='[/\\]'
26767 ;;
26768 *)
26769 gl_dirsep_regex='\/'
26770 ;;
26771 esac
26772 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26773
26774 gl_header_literal_regex=`echo 'stddef.h' \
26775 | sed -e "$gl_make_literal_regex_sed"`
26776 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26777 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26778 s|^/[^/]|//&|
26779 p
26780 q
26781 }'
26782 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26783 sed -n "$gl_absolute_header_sed"`'"'
26784
26785
26786 fi
26787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
26788 $as_echo "$gl_cv_next_stddef_h" >&6; }
26789 fi
26790 NEXT_STDDEF_H=$gl_cv_next_stddef_h
26791
26792 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26793 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26794 gl_next_as_first_directive='<'stddef.h'>'
26795 else
26796 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26797 gl_next_as_first_directive=$gl_cv_next_stddef_h
26798 fi
26799 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
26800
26801
26802
26803
26804 fi
26805
26806
26807
26808
26809
26810
26811
26812
26813
26814
26815
26816
26817 if test $gl_cv_have_include_next = yes; then
26818 gl_cv_next_stdio_h='<'stdio.h'>'
26819 else
26820 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
26821 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
26822 if test "${gl_cv_next_stdio_h+set}" = set; then :
26823 $as_echo_n "(cached) " >&6
26824 else
26825
26826 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26827 /* end confdefs.h. */
26828 #include <stdio.h>
26829
26830 _ACEOF
26831 case "$host_os" in
26832 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26833 *) gl_absname_cpp="$ac_cpp" ;;
26834 esac
26835
26836 case "$host_os" in
26837 mingw*)
26838 gl_dirsep_regex='[/\\]'
26839 ;;
26840 *)
26841 gl_dirsep_regex='\/'
26842 ;;
26843 esac
26844 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26845
26846 gl_header_literal_regex=`echo 'stdio.h' \
26847 | sed -e "$gl_make_literal_regex_sed"`
26848 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26849 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26850 s|^/[^/]|//&|
26851 p
26852 q
26853 }'
26854 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26855 sed -n "$gl_absolute_header_sed"`'"'
26856
26857
26858 fi
26859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
26860 $as_echo "$gl_cv_next_stdio_h" >&6; }
26861 fi
26862 NEXT_STDIO_H=$gl_cv_next_stdio_h
26863
26864 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26865 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26866 gl_next_as_first_directive='<'stdio.h'>'
26867 else
26868 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26869 gl_next_as_first_directive=$gl_cv_next_stdio_h
26870 fi
26871 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
26872
26873
26874
26875
26876
26877 GNULIB_FSCANF=1
26878
26879
26880 cat >>confdefs.h <<_ACEOF
26881 #define GNULIB_FSCANF 1
26882 _ACEOF
26883
26884
26885 GNULIB_SCANF=1
26886
26887
26888 cat >>confdefs.h <<_ACEOF
26889 #define GNULIB_SCANF 1
26890 _ACEOF
26891
26892
26893 GNULIB_FGETC=1
26894 GNULIB_GETC=1
26895 GNULIB_GETCHAR=1
26896 GNULIB_FGETS=1
26897 GNULIB_FREAD=1
26898
26899
26900 GNULIB_FPRINTF=1
26901 GNULIB_PRINTF=1
26902 GNULIB_VFPRINTF=1
26903 GNULIB_VPRINTF=1
26904 GNULIB_FPUTC=1
26905 GNULIB_PUTC=1
26906 GNULIB_PUTCHAR=1
26907 GNULIB_FPUTS=1
26908 GNULIB_PUTS=1
26909 GNULIB_FWRITE=1
26910
26911
26912
26913
26914
26915
26916
26917
26918
26919
26920
26921
26922
26923
26924
26925 if test $gl_cv_have_include_next = yes; then
26926 gl_cv_next_stdlib_h='<'stdlib.h'>'
26927 else
26928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
26929 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
26930 if test "${gl_cv_next_stdlib_h+set}" = set; then :
26931 $as_echo_n "(cached) " >&6
26932 else
26933
26934 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
26935 /* end confdefs.h. */
26936 #include <stdlib.h>
26937
26938 _ACEOF
26939 case "$host_os" in
26940 aix*) gl_absname_cpp="$ac_cpp -C" ;;
26941 *) gl_absname_cpp="$ac_cpp" ;;
26942 esac
26943
26944 case "$host_os" in
26945 mingw*)
26946 gl_dirsep_regex='[/\\]'
26947 ;;
26948 *)
26949 gl_dirsep_regex='\/'
26950 ;;
26951 esac
26952 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
26953
26954 gl_header_literal_regex=`echo 'stdlib.h' \
26955 | sed -e "$gl_make_literal_regex_sed"`
26956 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
26957 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
26958 s|^/[^/]|//&|
26959 p
26960 q
26961 }'
26962 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
26963 sed -n "$gl_absolute_header_sed"`'"'
26964
26965
26966 fi
26967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
26968 $as_echo "$gl_cv_next_stdlib_h" >&6; }
26969 fi
26970 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
26971
26972 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
26973 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
26974 gl_next_as_first_directive='<'stdlib.h'>'
26975 else
26976 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
26977 gl_next_as_first_directive=$gl_cv_next_stdlib_h
26978 fi
26979 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
26980
26981
26982
26983
26984
26985
26986
26987
26988
26989 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
26990
26991
26992
26993
26994
26995
26996
26997 $as_echo "#define my_strftime nstrftime" >>confdefs.h
26998
26999
27000
27001
27002
27003
27004
27005
27006
27007
27008
27009 if test "$ac_cv_have_decl_strtoimax" != yes; then
27010 HAVE_DECL_STRTOIMAX=0
27011 fi
27012
27013 if test "$ac_cv_func_strtoimax" = yes; then
27014 HAVE_STRTOIMAX=1
27015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
27016 $as_echo_n "checking whether strtoimax works... " >&6; }
27017 if test "${gl_cv_func_strtoimax+set}" = set; then :
27018 $as_echo_n "(cached) " >&6
27019 else
27020 if test "$cross_compiling" = yes; then :
27021 case "$host_os" in
27022 # Guess no on AIX 5.
27023 aix5*) gl_cv_func_strtoimax="guessing no" ;;
27024 # Guess yes otherwise.
27025 *) gl_cv_func_strtoimax="guessing yes" ;;
27026 esac
27027
27028 else
27029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27030 /* end confdefs.h. */
27031
27032 #include <errno.h>
27033 #include <string.h>
27034 #include <inttypes.h>
27035 int main ()
27036 {
27037 if (sizeof (intmax_t) > sizeof (int))
27038 {
27039 const char *s = "4294967295";
27040 char *p;
27041 intmax_t res;
27042 errno = 0;
27043 res = strtoimax (s, &p, 10);
27044 if (p != s + strlen (s))
27045 return 1;
27046 if (errno != 0)
27047 return 2;
27048 if (res != (intmax_t) 65535 * (intmax_t) 65537)
27049 return 3;
27050 }
27051 else
27052 {
27053 const char *s = "2147483647";
27054 char *p;
27055 intmax_t res;
27056 errno = 0;
27057 res = strtoimax (s, &p, 10);
27058 if (p != s + strlen (s))
27059 return 1;
27060 if (errno != 0)
27061 return 2;
27062 if (res != 2147483647)
27063 return 3;
27064 }
27065 return 0;
27066 }
27067
27068 _ACEOF
27069 if ac_fn_c_try_run "$LINENO"; then :
27070 gl_cv_func_strtoimax=yes
27071 else
27072 gl_cv_func_strtoimax=no
27073 fi
27074 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27075 conftest.$ac_objext conftest.beam conftest.$ac_ext
27076 fi
27077
27078
27079 fi
27080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
27081 $as_echo "$gl_cv_func_strtoimax" >&6; }
27082 case "$gl_cv_func_strtoimax" in
27083 *no) REPLACE_STRTOIMAX=1 ;;
27084 esac
27085 else
27086 if test "$ac_cv_have_decl_strtoimax" = yes; then
27087 # HP-UX 11.11 has "#define strtoimax(...) ..." but no function.
27088 REPLACE_STRTOIMAX=1
27089 fi
27090 HAVE_STRTOIMAX=0
27091 fi
27092
27093 if test $HAVE_DECL_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
27094
27095
27096
27097
27098
27099
27100
27101
27102 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
27103
27104
27105 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
27106 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
27107 ac_have_decl=1
27108 else
27109 ac_have_decl=0
27110 fi
27111
27112 cat >>confdefs.h <<_ACEOF
27113 #define HAVE_DECL_STRTOLL $ac_have_decl
27114 _ACEOF
27115
27116
27117
27118 fi
27119
27120
27121
27122
27123
27124 GNULIB_STRTOIMAX=1
27125
27126
27127
27128
27129
27130
27131
27132
27133
27134 if test "$ac_cv_have_decl_strtoumax" = yes; then
27135 if test "$ac_cv_func_strtoumax" != yes; then
27136 # HP-UX 11.11 has "#define strtoimax(...) ..." but no function.
27137 REPLACE_STRTOUMAX=1
27138 fi
27139 else
27140 HAVE_DECL_STRTOUMAX=0
27141 fi
27142
27143 if test $HAVE_DECL_STRTOUMAX = 0 || test $REPLACE_STRTOUMAX = 1; then
27144
27145
27146
27147
27148
27149
27150
27151
27152 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
27153
27154
27155 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
27156 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
27157 ac_have_decl=1
27158 else
27159 ac_have_decl=0
27160 fi
27161
27162 cat >>confdefs.h <<_ACEOF
27163 #define HAVE_DECL_STRTOULL $ac_have_decl
27164 _ACEOF
27165
27166
27167
27168 fi
27169
27170
27171
27172
27173
27174 GNULIB_STRTOUMAX=1
27175
27176
27177
27178
27179
27180
27181
27182 if test $ac_cv_func_symlink = no; then
27183 HAVE_SYMLINK=0
27184 else
27185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
27186 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
27187 if test "${gl_cv_func_symlink_works+set}" = set; then :
27188 $as_echo_n "(cached) " >&6
27189 else
27190 if test "$cross_compiling" = yes; then :
27191 case "$host_os" in
27192 # Guess yes on glibc systems.
27193 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
27194 # If we don't know, assume the worst.
27195 *) gl_cv_func_symlink_works="guessing no" ;;
27196 esac
27197
27198 else
27199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27200 /* end confdefs.h. */
27201 #include <unistd.h>
27202
27203 int
27204 main ()
27205 {
27206 int result = 0;
27207 if (!symlink ("a", "conftest.link/"))
27208 result |= 1;
27209 if (symlink ("conftest.f", "conftest.lnk2"))
27210 result |= 2;
27211 else if (!symlink ("a", "conftest.lnk2/"))
27212 result |= 4;
27213 return result;
27214
27215 ;
27216 return 0;
27217 }
27218 _ACEOF
27219 if ac_fn_c_try_run "$LINENO"; then :
27220 gl_cv_func_symlink_works=yes
27221 else
27222 gl_cv_func_symlink_works=no
27223 fi
27224 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27225 conftest.$ac_objext conftest.beam conftest.$ac_ext
27226 fi
27227
27228 rm -f conftest.f conftest.link conftest.lnk2
27229 fi
27230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
27231 $as_echo "$gl_cv_func_symlink_works" >&6; }
27232 case "$gl_cv_func_symlink_works" in
27233 *yes) ;;
27234 *)
27235 REPLACE_SYMLINK=1
27236 ;;
27237 esac
27238 fi
27239
27240 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
27241
27242
27243
27244
27245
27246
27247
27248
27249 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
27250
27251 fi
27252
27253
27254
27255
27256
27257 GNULIB_SYMLINK=1
27258
27259
27260
27261
27262
27263
27264
27265
27266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
27267 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
27268 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
27269 $as_echo_n "(cached) " >&6
27270 else
27271
27272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27273 /* end confdefs.h. */
27274 #include <sys/select.h>
27275 int
27276 main ()
27277 {
27278 struct timeval b;
27279 ;
27280 return 0;
27281 }
27282 _ACEOF
27283 if ac_fn_c_try_compile "$LINENO"; then :
27284 gl_cv_header_sys_select_h_selfcontained=yes
27285 else
27286 gl_cv_header_sys_select_h_selfcontained=no
27287 fi
27288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27289 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
27290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27291 /* end confdefs.h. */
27292 #include <sys/select.h>
27293 int
27294 main ()
27295 {
27296 int memset; int bzero;
27297 ;
27298 return 0;
27299 }
27300
27301 _ACEOF
27302 if ac_fn_c_try_compile "$LINENO"; then :
27303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27304 /* end confdefs.h. */
27305 #include <sys/select.h>
27306 int
27307 main ()
27308 {
27309
27310 #undef memset
27311 #define memset nonexistent_memset
27312 extern
27313 #ifdef __cplusplus
27314 "C"
27315 #endif
27316 void *memset (void *, int, unsigned long);
27317 #undef bzero
27318 #define bzero nonexistent_bzero
27319 extern
27320 #ifdef __cplusplus
27321 "C"
27322 #endif
27323 void bzero (void *, unsigned long);
27324 fd_set fds;
27325 FD_ZERO (&fds);
27326
27327 ;
27328 return 0;
27329 }
27330
27331 _ACEOF
27332 if ac_fn_c_try_link "$LINENO"; then :
27333
27334 else
27335 gl_cv_header_sys_select_h_selfcontained=no
27336 fi
27337 rm -f core conftest.err conftest.$ac_objext \
27338 conftest$ac_exeext conftest.$ac_ext
27339
27340 fi
27341 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27342 fi
27343
27344 fi
27345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
27346 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
27347
27348
27349
27350
27351
27352
27353
27354
27355
27356 if test $gl_cv_have_include_next = yes; then
27357 gl_cv_next_sys_select_h='<'sys/select.h'>'
27358 else
27359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
27360 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
27361 if test "${gl_cv_next_sys_select_h+set}" = set; then :
27362 $as_echo_n "(cached) " >&6
27363 else
27364
27365 if test $ac_cv_header_sys_select_h = yes; then
27366
27367
27368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27369 /* end confdefs.h. */
27370 #include <sys/select.h>
27371
27372 _ACEOF
27373 case "$host_os" in
27374 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27375 *) gl_absname_cpp="$ac_cpp" ;;
27376 esac
27377
27378 case "$host_os" in
27379 mingw*)
27380 gl_dirsep_regex='[/\\]'
27381 ;;
27382 *)
27383 gl_dirsep_regex='\/'
27384 ;;
27385 esac
27386 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27387
27388 gl_header_literal_regex=`echo 'sys/select.h' \
27389 | sed -e "$gl_make_literal_regex_sed"`
27390 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27391 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27392 s|^/[^/]|//&|
27393 p
27394 q
27395 }'
27396 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27397 sed -n "$gl_absolute_header_sed"`'"'
27398 else
27399 gl_cv_next_sys_select_h='<'sys/select.h'>'
27400 fi
27401
27402
27403 fi
27404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
27405 $as_echo "$gl_cv_next_sys_select_h" >&6; }
27406 fi
27407 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
27408
27409 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27410 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27411 gl_next_as_first_directive='<'sys/select.h'>'
27412 else
27413 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27414 gl_next_as_first_directive=$gl_cv_next_sys_select_h
27415 fi
27416 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
27417
27418
27419
27420
27421 if test $ac_cv_header_sys_select_h = yes; then
27422 HAVE_SYS_SELECT_H=1
27423 else
27424 HAVE_SYS_SELECT_H=0
27425 fi
27426
27427
27428
27429
27430
27431 if test $ac_cv_header_sys_socket_h != yes; then
27432 for ac_header in winsock2.h
27433 do :
27434 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
27435 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
27436 cat >>confdefs.h <<_ACEOF
27437 #define HAVE_WINSOCK2_H 1
27438 _ACEOF
27439
27440 fi
27441
27442 done
27443
27444 fi
27445 if test "$ac_cv_header_winsock2_h" = yes; then
27446 HAVE_WINSOCK2_H=1
27447 UNISTD_H_HAVE_WINSOCK2_H=1
27448 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
27449 else
27450 HAVE_WINSOCK2_H=0
27451 fi
27452
27453
27454
27455
27456
27457
27458
27459
27460
27461
27462
27463
27464
27465
27466
27467
27468
27469
27470
27471
27472 if test $gl_cv_have_include_next = yes; then
27473 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27474 else
27475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
27476 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
27477 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
27478 $as_echo_n "(cached) " >&6
27479 else
27480
27481 if test $ac_cv_header_sys_stat_h = yes; then
27482
27483
27484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27485 /* end confdefs.h. */
27486 #include <sys/stat.h>
27487
27488 _ACEOF
27489 case "$host_os" in
27490 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27491 *) gl_absname_cpp="$ac_cpp" ;;
27492 esac
27493
27494 case "$host_os" in
27495 mingw*)
27496 gl_dirsep_regex='[/\\]'
27497 ;;
27498 *)
27499 gl_dirsep_regex='\/'
27500 ;;
27501 esac
27502 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27503
27504 gl_header_literal_regex=`echo 'sys/stat.h' \
27505 | sed -e "$gl_make_literal_regex_sed"`
27506 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27507 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27508 s|^/[^/]|//&|
27509 p
27510 q
27511 }'
27512 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27513 sed -n "$gl_absolute_header_sed"`'"'
27514 else
27515 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
27516 fi
27517
27518
27519 fi
27520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
27521 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
27522 fi
27523 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
27524
27525 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27526 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27527 gl_next_as_first_directive='<'sys/stat.h'>'
27528 else
27529 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27530 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
27531 fi
27532 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
27533
27534
27535
27536
27537
27538
27539
27540
27541
27542
27543
27544 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
27545
27546 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
27547
27548 fi
27549
27550 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
27551 #include <sys/stat.h>
27552 "
27553 if test "x$ac_cv_type_nlink_t" = x""yes; then :
27554
27555 else
27556
27557 $as_echo "#define nlink_t int" >>confdefs.h
27558
27559 fi
27560
27561
27562
27563
27564
27565
27566
27567
27568
27569
27570
27571
27572
27573
27574
27575
27576
27577
27578 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
27579 "
27580 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
27581 ac_have_decl=1
27582 else
27583 ac_have_decl=0
27584 fi
27585
27586 cat >>confdefs.h <<_ACEOF
27587 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
27588 _ACEOF
27589
27590 if test $ac_cv_have_decl_localtime_r = no; then
27591 HAVE_DECL_LOCALTIME_R=0
27592 fi
27593
27594
27595 if test $ac_cv_func_localtime_r = yes; then
27596 HAVE_LOCALTIME_R=1
27597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
27598 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
27599 if test "${gl_cv_time_r_posix+set}" = set; then :
27600 $as_echo_n "(cached) " >&6
27601 else
27602 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27603 /* end confdefs.h. */
27604 #include <time.h>
27605 int
27606 main ()
27607 {
27608 /* We don't need to append 'restrict's to the argument types,
27609 even though the POSIX signature has the 'restrict's,
27610 since C99 says they can't affect type compatibility. */
27611 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
27612 if (ptr) return 0;
27613 /* Check the return type is a pointer.
27614 On HP-UX 10 it is 'int'. */
27615 *localtime_r (0, 0);
27616 ;
27617 return 0;
27618 }
27619
27620 _ACEOF
27621 if ac_fn_c_try_compile "$LINENO"; then :
27622 gl_cv_time_r_posix=yes
27623 else
27624 gl_cv_time_r_posix=no
27625 fi
27626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27627
27628 fi
27629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
27630 $as_echo "$gl_cv_time_r_posix" >&6; }
27631 if test $gl_cv_time_r_posix = yes; then
27632 REPLACE_LOCALTIME_R=0
27633 else
27634 REPLACE_LOCALTIME_R=1
27635 fi
27636 else
27637 HAVE_LOCALTIME_R=0
27638 fi
27639
27640 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
27641
27642
27643
27644
27645
27646
27647
27648
27649 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
27650
27651
27652 :
27653
27654 fi
27655
27656
27657
27658
27659
27660 GNULIB_TIME_R=1
27661
27662
27663
27664
27665
27666
27667
27668
27669
27670
27671 LIB_TIMER_TIME=
27672
27673 gl_saved_libs=$LIBS
27674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing timer_settime" >&5
27675 $as_echo_n "checking for library containing timer_settime... " >&6; }
27676 if test "${ac_cv_search_timer_settime+set}" = set; then :
27677 $as_echo_n "(cached) " >&6
27678 else
27679 ac_func_search_save_LIBS=$LIBS
27680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27681 /* end confdefs.h. */
27682
27683 /* Override any GCC internal prototype to avoid an error.
27684 Use char because int might match the return type of a GCC
27685 builtin and then its argument prototype would still apply. */
27686 #ifdef __cplusplus
27687 extern "C"
27688 #endif
27689 char timer_settime ();
27690 int
27691 main ()
27692 {
27693 return timer_settime ();
27694 ;
27695 return 0;
27696 }
27697 _ACEOF
27698 for ac_lib in '' rt posix4; do
27699 if test -z "$ac_lib"; then
27700 ac_res="none required"
27701 else
27702 ac_res=-l$ac_lib
27703 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
27704 fi
27705 if ac_fn_c_try_link "$LINENO"; then :
27706 ac_cv_search_timer_settime=$ac_res
27707 fi
27708 rm -f core conftest.err conftest.$ac_objext \
27709 conftest$ac_exeext
27710 if test "${ac_cv_search_timer_settime+set}" = set; then :
27711 break
27712 fi
27713 done
27714 if test "${ac_cv_search_timer_settime+set}" = set; then :
27715
27716 else
27717 ac_cv_search_timer_settime=no
27718 fi
27719 rm conftest.$ac_ext
27720 LIBS=$ac_func_search_save_LIBS
27721 fi
27722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_timer_settime" >&5
27723 $as_echo "$ac_cv_search_timer_settime" >&6; }
27724 ac_res=$ac_cv_search_timer_settime
27725 if test "$ac_res" != no; then :
27726 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
27727 test "$ac_cv_search_timer_settime" = "none required" ||
27728 LIB_TIMER_TIME=$ac_cv_search_timer_settime
27729 fi
27730
27731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27732 /* end confdefs.h. */
27733
27734 #include <features.h>
27735 #ifdef __GNU_LIBRARY__
27736 #if ((__GLIBC__ == 2 && __GLIBC_MINOR__ >= 2) || (__GLIBC__ > 2)) \
27737 && !defined __UCLIBC__
27738 Thread emulation available
27739 #endif
27740 #endif
27741
27742 _ACEOF
27743 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
27744 $EGREP "Thread" >/dev/null 2>&1; then :
27745 LIB_TIMER_TIME="$LIB_TIMER_TIME $LIBMULTITHREAD"
27746 fi
27747 rm -f conftest*
27748
27749 for ac_func in timer_settime
27750 do :
27751 ac_fn_c_check_func "$LINENO" "timer_settime" "ac_cv_func_timer_settime"
27752 if test "x$ac_cv_func_timer_settime" = x""yes; then :
27753 cat >>confdefs.h <<_ACEOF
27754 #define HAVE_TIMER_SETTIME 1
27755 _ACEOF
27756
27757 fi
27758 done
27759
27760 LIBS=$gl_saved_libs
27761
27762 :
27763
27764
27765
27766
27767
27768
27769
27770
27771
27772
27773
27774
27775 if test $gl_cv_have_include_next = yes; then
27776 gl_cv_next_unistd_h='<'unistd.h'>'
27777 else
27778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
27779 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
27780 if test "${gl_cv_next_unistd_h+set}" = set; then :
27781 $as_echo_n "(cached) " >&6
27782 else
27783
27784 if test $ac_cv_header_unistd_h = yes; then
27785
27786
27787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27788 /* end confdefs.h. */
27789 #include <unistd.h>
27790
27791 _ACEOF
27792 case "$host_os" in
27793 aix*) gl_absname_cpp="$ac_cpp -C" ;;
27794 *) gl_absname_cpp="$ac_cpp" ;;
27795 esac
27796
27797 case "$host_os" in
27798 mingw*)
27799 gl_dirsep_regex='[/\\]'
27800 ;;
27801 *)
27802 gl_dirsep_regex='\/'
27803 ;;
27804 esac
27805 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
27806
27807 gl_header_literal_regex=`echo 'unistd.h' \
27808 | sed -e "$gl_make_literal_regex_sed"`
27809 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
27810 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
27811 s|^/[^/]|//&|
27812 p
27813 q
27814 }'
27815 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
27816 sed -n "$gl_absolute_header_sed"`'"'
27817 else
27818 gl_cv_next_unistd_h='<'unistd.h'>'
27819 fi
27820
27821
27822 fi
27823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
27824 $as_echo "$gl_cv_next_unistd_h" >&6; }
27825 fi
27826 NEXT_UNISTD_H=$gl_cv_next_unistd_h
27827
27828 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
27829 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
27830 gl_next_as_first_directive='<'unistd.h'>'
27831 else
27832 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
27833 gl_next_as_first_directive=$gl_cv_next_unistd_h
27834 fi
27835 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
27836
27837
27838
27839
27840 if test $ac_cv_header_unistd_h = yes; then
27841 HAVE_UNISTD_H=1
27842 else
27843 HAVE_UNISTD_H=0
27844 fi
27845
27846
27847
27848
27849
27850
27851
27852
27853
27854
27855
27856 if test $ac_cv_have_decl_unsetenv = no; then
27857 HAVE_DECL_UNSETENV=0
27858 fi
27859 for ac_func in unsetenv
27860 do :
27861 ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
27862 if test "x$ac_cv_func_unsetenv" = x""yes; then :
27863 cat >>confdefs.h <<_ACEOF
27864 #define HAVE_UNSETENV 1
27865 _ACEOF
27866
27867 fi
27868 done
27869
27870 if test $ac_cv_func_unsetenv = no; then
27871 HAVE_UNSETENV=0
27872 else
27873 HAVE_UNSETENV=1
27874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsetenv() return type" >&5
27875 $as_echo_n "checking for unsetenv() return type... " >&6; }
27876 if test "${gt_cv_func_unsetenv_ret+set}" = set; then :
27877 $as_echo_n "(cached) " >&6
27878 else
27879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27880 /* end confdefs.h. */
27881
27882 #undef _BSD
27883 #define _BSD 1 /* unhide unsetenv declaration in OSF/1 5.1 <stdlib.h> */
27884 #include <stdlib.h>
27885 extern
27886 #ifdef __cplusplus
27887 "C"
27888 #endif
27889 int unsetenv (const char *name);
27890
27891 int
27892 main ()
27893 {
27894
27895 ;
27896 return 0;
27897 }
27898 _ACEOF
27899 if ac_fn_c_try_compile "$LINENO"; then :
27900 gt_cv_func_unsetenv_ret='int'
27901 else
27902 gt_cv_func_unsetenv_ret='void'
27903 fi
27904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27905 fi
27906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_unsetenv_ret" >&5
27907 $as_echo "$gt_cv_func_unsetenv_ret" >&6; }
27908 if test $gt_cv_func_unsetenv_ret = 'void'; then
27909
27910 $as_echo "#define VOID_UNSETENV 1" >>confdefs.h
27911
27912 REPLACE_UNSETENV=1
27913 fi
27914
27915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether unsetenv obeys POSIX" >&5
27916 $as_echo_n "checking whether unsetenv obeys POSIX... " >&6; }
27917 if test "${gl_cv_func_unsetenv_works+set}" = set; then :
27918 $as_echo_n "(cached) " >&6
27919 else
27920 if test "$cross_compiling" = yes; then :
27921 case "$host_os" in
27922 # Guess yes on glibc systems.
27923 *-gnu*) gl_cv_func_unsetenv_works="guessing yes" ;;
27924 # If we don't know, assume the worst.
27925 *) gl_cv_func_unsetenv_works="guessing no" ;;
27926 esac
27927
27928 else
27929 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
27930 /* end confdefs.h. */
27931
27932 #include <stdlib.h>
27933 #include <errno.h>
27934 extern char **environ;
27935
27936 int
27937 main ()
27938 {
27939
27940 char entry1[] = "a=1";
27941 char entry2[] = "b=2";
27942 char *env[] = { entry1, entry2, NULL };
27943 if (putenv ((char *) "a=1")) return 1;
27944 if (putenv (entry2)) return 2;
27945 entry2[0] = 'a';
27946 unsetenv ("a");
27947 if (getenv ("a")) return 3;
27948 if (!unsetenv ("") || errno != EINVAL) return 4;
27949 entry2[0] = 'b';
27950 environ = env;
27951 if (!getenv ("a")) return 5;
27952 entry2[0] = 'a';
27953 unsetenv ("a");
27954 if (getenv ("a")) return 6;
27955
27956 ;
27957 return 0;
27958 }
27959 _ACEOF
27960 if ac_fn_c_try_run "$LINENO"; then :
27961 gl_cv_func_unsetenv_works=yes
27962 else
27963 gl_cv_func_unsetenv_works=no
27964 fi
27965 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
27966 conftest.$ac_objext conftest.beam conftest.$ac_ext
27967 fi
27968
27969 fi
27970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_unsetenv_works" >&5
27971 $as_echo "$gl_cv_func_unsetenv_works" >&6; }
27972 case "$gl_cv_func_unsetenv_works" in
27973 *yes) ;;
27974 *)
27975 REPLACE_UNSETENV=1
27976 ;;
27977 esac
27978 fi
27979
27980 if test $HAVE_UNSETENV = 0 || test $REPLACE_UNSETENV = 1; then
27981
27982
27983
27984
27985
27986
27987
27988
27989 gl_LIBOBJS="$gl_LIBOBJS unsetenv.$ac_objext"
27990
27991
27992
27993
27994
27995 fi
27996
27997
27998
27999
28000
28001 GNULIB_UNSETENV=1
28002
28003
28004
28005
28006
28007
28008
28009
28010
28011
28012
28013 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
28014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
28015 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
28016 if test "${gl_cv_func_futimesat_works+set}" = set; then :
28017 $as_echo_n "(cached) " >&6
28018 else
28019 touch conftest.file
28020 if test "$cross_compiling" = yes; then :
28021 case "$host_os" in
28022 # Guess yes on glibc systems.
28023 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
28024 # If we don't know, assume the worst.
28025 *) gl_cv_func_futimesat_works="guessing no" ;;
28026 esac
28027
28028 else
28029 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28030 /* end confdefs.h. */
28031
28032 #include <stddef.h>
28033 #include <sys/times.h>
28034 #include <fcntl.h>
28035
28036 int
28037 main ()
28038 {
28039 int fd = open ("conftest.file", O_RDWR);
28040 if (fd < 0) return 1;
28041 if (futimesat (fd, NULL, NULL)) return 2;
28042
28043 ;
28044 return 0;
28045 }
28046 _ACEOF
28047 if ac_fn_c_try_run "$LINENO"; then :
28048 gl_cv_func_futimesat_works=yes
28049 else
28050 gl_cv_func_futimesat_works=no
28051 fi
28052 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28053 conftest.$ac_objext conftest.beam conftest.$ac_ext
28054 fi
28055
28056 rm -f conftest.file
28057 fi
28058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
28059 $as_echo "$gl_cv_func_futimesat_works" >&6; }
28060 case "$gl_cv_func_futimesat_works" in
28061 *yes) ;;
28062 *)
28063
28064 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
28065
28066 ;;
28067 esac
28068 fi
28069
28070 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=false
28071 gl_gnulib_enabled_dosname=false
28072 gl_gnulib_enabled_euidaccess=false
28073 gl_gnulib_enabled_getdtablesize=false
28074 gl_gnulib_enabled_getgroups=false
28075 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
28076 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=false
28077 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=false
28078 gl_gnulib_enabled_pathmax=false
28079 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=false
28080 gl_gnulib_enabled_secure_getenv=false
28081 gl_gnulib_enabled_stat=false
28082 gl_gnulib_enabled_strtoll=false
28083 gl_gnulib_enabled_strtoull=false
28084 gl_gnulib_enabled_tempname=false
28085 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=false
28086 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b ()
28087 {
28088 if ! $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
28089
28090
28091
28092
28093
28094
28095
28096
28097 gl_LIBOBJS="$gl_LIBOBJS openat-proc.$ac_objext"
28098
28099 gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b=true
28100 fi
28101 }
28102 func_gl_gnulib_m4code_dosname ()
28103 {
28104 if ! $gl_gnulib_enabled_dosname; then
28105 gl_gnulib_enabled_dosname=true
28106 fi
28107 }
28108 func_gl_gnulib_m4code_euidaccess ()
28109 {
28110 if ! $gl_gnulib_enabled_euidaccess; then
28111
28112
28113
28114
28115
28116 for ac_func in euidaccess
28117 do :
28118 ac_fn_c_check_func "$LINENO" "euidaccess" "ac_cv_func_euidaccess"
28119 if test "x$ac_cv_func_euidaccess" = x""yes; then :
28120 cat >>confdefs.h <<_ACEOF
28121 #define HAVE_EUIDACCESS 1
28122 _ACEOF
28123
28124 fi
28125 done
28126
28127 if test $ac_cv_func_euidaccess = no; then
28128 HAVE_EUIDACCESS=0
28129 fi
28130
28131 if test $HAVE_EUIDACCESS = 0; then
28132
28133
28134
28135
28136
28137
28138
28139
28140 gl_LIBOBJS="$gl_LIBOBJS euidaccess.$ac_objext"
28141
28142
28143
28144 for ac_header in libgen.h
28145 do :
28146 ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
28147 if test "x$ac_cv_header_libgen_h" = x""yes; then :
28148 cat >>confdefs.h <<_ACEOF
28149 #define HAVE_LIBGEN_H 1
28150 _ACEOF
28151
28152 fi
28153
28154 done
28155
28156
28157 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28158 if test "x$ac_cv_func_getgroups" = x""yes; then :
28159
28160 fi
28161
28162
28163 # If we don't yet have getgroups, see if it's in -lbsd.
28164 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28165 ac_save_LIBS=$LIBS
28166 if test $ac_cv_func_getgroups = no; then
28167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28168 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28169 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28170 $as_echo_n "(cached) " >&6
28171 else
28172 ac_check_lib_save_LIBS=$LIBS
28173 LIBS="-lbsd $LIBS"
28174 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28175 /* end confdefs.h. */
28176
28177 /* Override any GCC internal prototype to avoid an error.
28178 Use char because int might match the return type of a GCC
28179 builtin and then its argument prototype would still apply. */
28180 #ifdef __cplusplus
28181 extern "C"
28182 #endif
28183 char getgroups ();
28184 int
28185 main ()
28186 {
28187 return getgroups ();
28188 ;
28189 return 0;
28190 }
28191 _ACEOF
28192 if ac_fn_c_try_link "$LINENO"; then :
28193 ac_cv_lib_bsd_getgroups=yes
28194 else
28195 ac_cv_lib_bsd_getgroups=no
28196 fi
28197 rm -f core conftest.err conftest.$ac_objext \
28198 conftest$ac_exeext conftest.$ac_ext
28199 LIBS=$ac_check_lib_save_LIBS
28200 fi
28201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28202 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28203 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28204 GETGROUPS_LIB=-lbsd
28205 fi
28206
28207 fi
28208
28209 # Run the program to test the functionality of the system-supplied
28210 # getgroups function only if there is such a function.
28211 if test $ac_cv_func_getgroups = yes; then
28212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28213 $as_echo_n "checking for working getgroups... " >&6; }
28214 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28215 $as_echo_n "(cached) " >&6
28216 else
28217 if test "$cross_compiling" = yes; then :
28218 case "$host_os" in # ((
28219 # Guess yes on glibc systems.
28220 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28221 # If we don't know, assume the worst.
28222 *) ac_cv_func_getgroups_works="guessing no" ;;
28223 esac
28224
28225 else
28226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28227 /* end confdefs.h. */
28228 $ac_includes_default
28229 int
28230 main ()
28231 {
28232 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28233 return getgroups (0, 0) == -1;
28234 ;
28235 return 0;
28236 }
28237
28238 _ACEOF
28239 if ac_fn_c_try_run "$LINENO"; then :
28240 ac_cv_func_getgroups_works=yes
28241 else
28242 ac_cv_func_getgroups_works=no
28243 fi
28244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28245 conftest.$ac_objext conftest.beam conftest.$ac_ext
28246 fi
28247
28248
28249 fi
28250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28251 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28252 else
28253 ac_cv_func_getgroups_works=no
28254 fi
28255 case "$ac_cv_func_getgroups_works" in
28256 *yes)
28257
28258 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28259
28260 ;;
28261 esac
28262 LIBS=$ac_save_LIBS
28263
28264
28265 # Solaris 9 and 10 need -lgen to get the eaccess function.
28266 # Save and restore LIBS so -lgen isn't added to it. Otherwise, *all*
28267 # programs in the package would end up linked with that potentially-shared
28268 # library, inducing unnecessary run-time overhead.
28269 LIB_EACCESS=
28270
28271 gl_saved_libs=$LIBS
28272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing eaccess" >&5
28273 $as_echo_n "checking for library containing eaccess... " >&6; }
28274 if test "${ac_cv_search_eaccess+set}" = set; then :
28275 $as_echo_n "(cached) " >&6
28276 else
28277 ac_func_search_save_LIBS=$LIBS
28278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28279 /* end confdefs.h. */
28280
28281 /* Override any GCC internal prototype to avoid an error.
28282 Use char because int might match the return type of a GCC
28283 builtin and then its argument prototype would still apply. */
28284 #ifdef __cplusplus
28285 extern "C"
28286 #endif
28287 char eaccess ();
28288 int
28289 main ()
28290 {
28291 return eaccess ();
28292 ;
28293 return 0;
28294 }
28295 _ACEOF
28296 for ac_lib in '' gen; do
28297 if test -z "$ac_lib"; then
28298 ac_res="none required"
28299 else
28300 ac_res=-l$ac_lib
28301 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
28302 fi
28303 if ac_fn_c_try_link "$LINENO"; then :
28304 ac_cv_search_eaccess=$ac_res
28305 fi
28306 rm -f core conftest.err conftest.$ac_objext \
28307 conftest$ac_exeext
28308 if test "${ac_cv_search_eaccess+set}" = set; then :
28309 break
28310 fi
28311 done
28312 if test "${ac_cv_search_eaccess+set}" = set; then :
28313
28314 else
28315 ac_cv_search_eaccess=no
28316 fi
28317 rm conftest.$ac_ext
28318 LIBS=$ac_func_search_save_LIBS
28319 fi
28320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_eaccess" >&5
28321 $as_echo "$ac_cv_search_eaccess" >&6; }
28322 ac_res=$ac_cv_search_eaccess
28323 if test "$ac_res" != no; then :
28324 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28325 test "$ac_cv_search_eaccess" = "none required" ||
28326 LIB_EACCESS=$ac_cv_search_eaccess
28327 fi
28328
28329 for ac_func in eaccess
28330 do :
28331 ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
28332 if test "x$ac_cv_func_eaccess" = x""yes; then :
28333 cat >>confdefs.h <<_ACEOF
28334 #define HAVE_EACCESS 1
28335 _ACEOF
28336
28337 fi
28338 done
28339
28340 LIBS=$gl_saved_libs
28341
28342 fi
28343
28344
28345
28346
28347
28348 GNULIB_EUIDACCESS=1
28349
28350
28351
28352
28353
28354 gl_gnulib_enabled_euidaccess=true
28355 if test $HAVE_EUIDACCESS = 0; then
28356 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1
28357 fi
28358 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c
28359 if test $HAVE_EUIDACCESS = 0; then
28360 func_gl_gnulib_m4code_stat
28361 fi
28362 fi
28363 }
28364 func_gl_gnulib_m4code_getdtablesize ()
28365 {
28366 if ! $gl_gnulib_enabled_getdtablesize; then
28367
28368
28369
28370
28371 if test $ac_cv_func_getdtablesize = yes; then
28372 # Cygwin 1.7.25 automatically increases the RLIMIT_NOFILE soft limit
28373 # up to an unchangeable hard limit; all other platforms correctly
28374 # require setrlimit before getdtablesize() can report a larger value.
28375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getdtablesize works" >&5
28376 $as_echo_n "checking whether getdtablesize works... " >&6; }
28377 if test "${gl_cv_func_getdtablesize_works+set}" = set; then :
28378 $as_echo_n "(cached) " >&6
28379 else
28380 if test "$cross_compiling" = yes; then :
28381 case "$host_os" in
28382 cygwin*) # on cygwin 1.5.25, getdtablesize() automatically grows
28383 gl_cv_func_getdtablesize_works="guessing no" ;;
28384 *) gl_cv_func_getdtablesize_works="guessing yes" ;;
28385 esac
28386 else
28387 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28388 /* end confdefs.h. */
28389
28390 #include <unistd.h>
28391 int
28392 main ()
28393 {
28394 int size = getdtablesize();
28395 if (dup2 (0, getdtablesize()) != -1)
28396 return 1;
28397 if (size != getdtablesize())
28398 return 2;
28399
28400 ;
28401 return 0;
28402 }
28403 _ACEOF
28404 if ac_fn_c_try_run "$LINENO"; then :
28405 gl_cv_func_getdtablesize_works=yes
28406 else
28407 gl_cv_func_getdtablesize_works=no
28408 fi
28409 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28410 conftest.$ac_objext conftest.beam conftest.$ac_ext
28411 fi
28412
28413
28414 fi
28415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getdtablesize_works" >&5
28416 $as_echo "$gl_cv_func_getdtablesize_works" >&6; }
28417 case "$gl_cv_func_getdtablesize_works" in
28418 *yes) ;;
28419 *) REPLACE_GETDTABLESIZE=1 ;;
28420 esac
28421 else
28422 HAVE_GETDTABLESIZE=0
28423 fi
28424
28425 if test $HAVE_GETDTABLESIZE = 0 || test $REPLACE_GETDTABLESIZE = 1; then
28426
28427
28428
28429
28430
28431
28432
28433
28434 gl_LIBOBJS="$gl_LIBOBJS getdtablesize.$ac_objext"
28435
28436 :
28437 fi
28438
28439
28440
28441
28442
28443 GNULIB_GETDTABLESIZE=1
28444
28445
28446
28447
28448
28449 gl_gnulib_enabled_getdtablesize=true
28450 fi
28451 }
28452 func_gl_gnulib_m4code_getgroups ()
28453 {
28454 if ! $gl_gnulib_enabled_getgroups; then
28455
28456
28457
28458
28459
28460 ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
28461 if test "x$ac_cv_func_getgroups" = x""yes; then :
28462
28463 fi
28464
28465
28466 # If we don't yet have getgroups, see if it's in -lbsd.
28467 # This is reported to be necessary on an ITOS 3000WS running SEIUX 3.1.
28468 ac_save_LIBS=$LIBS
28469 if test $ac_cv_func_getgroups = no; then
28470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getgroups in -lbsd" >&5
28471 $as_echo_n "checking for getgroups in -lbsd... " >&6; }
28472 if test "${ac_cv_lib_bsd_getgroups+set}" = set; then :
28473 $as_echo_n "(cached) " >&6
28474 else
28475 ac_check_lib_save_LIBS=$LIBS
28476 LIBS="-lbsd $LIBS"
28477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28478 /* end confdefs.h. */
28479
28480 /* Override any GCC internal prototype to avoid an error.
28481 Use char because int might match the return type of a GCC
28482 builtin and then its argument prototype would still apply. */
28483 #ifdef __cplusplus
28484 extern "C"
28485 #endif
28486 char getgroups ();
28487 int
28488 main ()
28489 {
28490 return getgroups ();
28491 ;
28492 return 0;
28493 }
28494 _ACEOF
28495 if ac_fn_c_try_link "$LINENO"; then :
28496 ac_cv_lib_bsd_getgroups=yes
28497 else
28498 ac_cv_lib_bsd_getgroups=no
28499 fi
28500 rm -f core conftest.err conftest.$ac_objext \
28501 conftest$ac_exeext conftest.$ac_ext
28502 LIBS=$ac_check_lib_save_LIBS
28503 fi
28504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_getgroups" >&5
28505 $as_echo "$ac_cv_lib_bsd_getgroups" >&6; }
28506 if test "x$ac_cv_lib_bsd_getgroups" = x""yes; then :
28507 GETGROUPS_LIB=-lbsd
28508 fi
28509
28510 fi
28511
28512 # Run the program to test the functionality of the system-supplied
28513 # getgroups function only if there is such a function.
28514 if test $ac_cv_func_getgroups = yes; then
28515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working getgroups" >&5
28516 $as_echo_n "checking for working getgroups... " >&6; }
28517 if test "${ac_cv_func_getgroups_works+set}" = set; then :
28518 $as_echo_n "(cached) " >&6
28519 else
28520 if test "$cross_compiling" = yes; then :
28521 case "$host_os" in # ((
28522 # Guess yes on glibc systems.
28523 *-gnu*) ac_cv_func_getgroups_works="guessing yes" ;;
28524 # If we don't know, assume the worst.
28525 *) ac_cv_func_getgroups_works="guessing no" ;;
28526 esac
28527
28528 else
28529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28530 /* end confdefs.h. */
28531 $ac_includes_default
28532 int
28533 main ()
28534 {
28535 /* On Ultrix 4.3, getgroups (0, 0) always fails. */
28536 return getgroups (0, 0) == -1;
28537 ;
28538 return 0;
28539 }
28540
28541 _ACEOF
28542 if ac_fn_c_try_run "$LINENO"; then :
28543 ac_cv_func_getgroups_works=yes
28544 else
28545 ac_cv_func_getgroups_works=no
28546 fi
28547 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28548 conftest.$ac_objext conftest.beam conftest.$ac_ext
28549 fi
28550
28551
28552 fi
28553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getgroups_works" >&5
28554 $as_echo "$ac_cv_func_getgroups_works" >&6; }
28555 else
28556 ac_cv_func_getgroups_works=no
28557 fi
28558 case "$ac_cv_func_getgroups_works" in
28559 *yes)
28560
28561 $as_echo "#define HAVE_GETGROUPS 1" >>confdefs.h
28562
28563 ;;
28564 esac
28565 LIBS=$ac_save_LIBS
28566
28567 if test $ac_cv_func_getgroups != yes; then
28568 HAVE_GETGROUPS=0
28569 else
28570 if test "$ac_cv_type_getgroups" != gid_t \
28571 || { case "$ac_cv_func_getgroups_works" in
28572 *yes) false;;
28573 *) true;;
28574 esac
28575 }; then
28576 REPLACE_GETGROUPS=1
28577
28578 $as_echo "#define GETGROUPS_ZERO_BUG 1" >>confdefs.h
28579
28580 else
28581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getgroups handles negative values" >&5
28582 $as_echo_n "checking whether getgroups handles negative values... " >&6; }
28583 if test "${gl_cv_func_getgroups_works+set}" = set; then :
28584 $as_echo_n "(cached) " >&6
28585 else
28586 if test "$cross_compiling" = yes; then :
28587 case "$host_os" in
28588 # Guess yes on glibc systems.
28589 *-gnu*) gl_cv_func_getgroups_works="guessing yes" ;;
28590 # If we don't know, assume the worst.
28591 *) gl_cv_func_getgroups_works="guessing no" ;;
28592 esac
28593
28594 else
28595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28596 /* end confdefs.h. */
28597 $ac_includes_default
28598 int
28599 main ()
28600 {
28601 int size = getgroups (0, 0);
28602 gid_t *list = malloc (size * sizeof *list);
28603 return getgroups (-1, list) != -1;
28604 ;
28605 return 0;
28606 }
28607 _ACEOF
28608 if ac_fn_c_try_run "$LINENO"; then :
28609 gl_cv_func_getgroups_works=yes
28610 else
28611 gl_cv_func_getgroups_works=no
28612 fi
28613 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28614 conftest.$ac_objext conftest.beam conftest.$ac_ext
28615 fi
28616
28617 fi
28618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getgroups_works" >&5
28619 $as_echo "$gl_cv_func_getgroups_works" >&6; }
28620 case "$gl_cv_func_getgroups_works" in
28621 *yes) ;;
28622 *) REPLACE_GETGROUPS=1 ;;
28623 esac
28624 fi
28625 fi
28626 test -n "$GETGROUPS_LIB" && LIBS="$GETGROUPS_LIB $LIBS"
28627
28628 if test $HAVE_GETGROUPS = 0 || test $REPLACE_GETGROUPS = 1; then
28629
28630
28631
28632
28633
28634
28635
28636
28637 gl_LIBOBJS="$gl_LIBOBJS getgroups.$ac_objext"
28638
28639 fi
28640
28641
28642
28643
28644
28645 GNULIB_GETGROUPS=1
28646
28647
28648
28649
28650
28651 gl_gnulib_enabled_getgroups=true
28652 fi
28653 }
28654 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
28655 {
28656 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
28657
28658
28659 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
28660 fi
28661 }
28662 func_gl_gnulib_m4code_a9786850e999ae65a836a6041e8e5ed1 ()
28663 {
28664 if ! $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
28665
28666
28667
28668
28669
28670 ac_fn_c_check_func "$LINENO" "group_member" "ac_cv_func_group_member"
28671 if test "x$ac_cv_func_group_member" = x""yes; then :
28672
28673 else
28674
28675 HAVE_GROUP_MEMBER=0
28676
28677 fi
28678
28679
28680 if test $HAVE_GROUP_MEMBER = 0; then
28681
28682
28683
28684
28685
28686
28687
28688
28689 gl_LIBOBJS="$gl_LIBOBJS group-member.$ac_objext"
28690
28691
28692
28693
28694 fi
28695
28696
28697
28698
28699
28700 GNULIB_GROUP_MEMBER=1
28701
28702
28703
28704
28705
28706 gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1=true
28707 if test $HAVE_GROUP_MEMBER = 0; then
28708 func_gl_gnulib_m4code_getgroups
28709 fi
28710 if test $HAVE_GROUP_MEMBER = 0; then
28711 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec
28712 fi
28713 fi
28714 }
28715 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7 ()
28716 {
28717 if ! $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
28718 gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7=true
28719 fi
28720 }
28721 func_gl_gnulib_m4code_pathmax ()
28722 {
28723 if ! $gl_gnulib_enabled_pathmax; then
28724
28725
28726
28727 gl_gnulib_enabled_pathmax=true
28728 fi
28729 }
28730 func_gl_gnulib_m4code_6099e9737f757db36c47fa9d9f02e88c ()
28731 {
28732 if ! $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
28733 gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c=true
28734 fi
28735 }
28736 func_gl_gnulib_m4code_secure_getenv ()
28737 {
28738 if ! $gl_gnulib_enabled_secure_getenv; then
28739
28740
28741
28742
28743
28744 if test $ac_cv_func_secure_getenv = no; then
28745 HAVE_SECURE_GETENV=0
28746 fi
28747
28748 if test $HAVE_SECURE_GETENV = 0; then
28749
28750
28751
28752
28753
28754
28755
28756
28757 gl_LIBOBJS="$gl_LIBOBJS secure_getenv.$ac_objext"
28758
28759
28760 for ac_func in __secure_getenv
28761 do :
28762 ac_fn_c_check_func "$LINENO" "__secure_getenv" "ac_cv_func___secure_getenv"
28763 if test "x$ac_cv_func___secure_getenv" = x""yes; then :
28764 cat >>confdefs.h <<_ACEOF
28765 #define HAVE___SECURE_GETENV 1
28766 _ACEOF
28767
28768 fi
28769 done
28770
28771 if test $ac_cv_func___secure_getenv = no; then
28772 for ac_func in issetugid
28773 do :
28774 ac_fn_c_check_func "$LINENO" "issetugid" "ac_cv_func_issetugid"
28775 if test "x$ac_cv_func_issetugid" = x""yes; then :
28776 cat >>confdefs.h <<_ACEOF
28777 #define HAVE_ISSETUGID 1
28778 _ACEOF
28779
28780 fi
28781 done
28782
28783 fi
28784
28785 fi
28786
28787
28788
28789
28790
28791 GNULIB_SECURE_GETENV=1
28792
28793
28794
28795
28796
28797 gl_gnulib_enabled_secure_getenv=true
28798 fi
28799 }
28800 func_gl_gnulib_m4code_stat ()
28801 {
28802 if ! $gl_gnulib_enabled_stat; then
28803
28804
28805
28806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
28807 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
28808 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
28809 $as_echo_n "(cached) " >&6
28810 else
28811 if test "$cross_compiling" = yes; then :
28812 case $host_os in
28813 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
28814 *) gl_cv_func_stat_dir_slash="guessing yes";;
28815 esac
28816 else
28817 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28818 /* end confdefs.h. */
28819 #include <sys/stat.h>
28820
28821 int
28822 main ()
28823 {
28824 struct stat st; return stat (".", &st) != stat ("./", &st);
28825 ;
28826 return 0;
28827 }
28828 _ACEOF
28829 if ac_fn_c_try_run "$LINENO"; then :
28830 gl_cv_func_stat_dir_slash=yes
28831 else
28832 gl_cv_func_stat_dir_slash=no
28833 fi
28834 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28835 conftest.$ac_objext conftest.beam conftest.$ac_ext
28836 fi
28837
28838 fi
28839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
28840 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
28841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
28842 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
28843 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
28844 $as_echo_n "(cached) " >&6
28845 else
28846 touch conftest.tmp
28847 # Assume that if we have lstat, we can also check symlinks.
28848 if test $ac_cv_func_lstat = yes; then
28849 ln -s conftest.tmp conftest.lnk
28850 fi
28851 if test "$cross_compiling" = yes; then :
28852 case "$host_os" in
28853 # Guess yes on glibc systems.
28854 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
28855 # If we don't know, assume the worst.
28856 *) gl_cv_func_stat_file_slash="guessing no" ;;
28857 esac
28858
28859 else
28860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
28861 /* end confdefs.h. */
28862 #include <sys/stat.h>
28863
28864 int
28865 main ()
28866 {
28867 int result = 0;
28868 struct stat st;
28869 if (!stat ("conftest.tmp/", &st))
28870 result |= 1;
28871 #if HAVE_LSTAT
28872 if (!stat ("conftest.lnk/", &st))
28873 result |= 2;
28874 #endif
28875 return result;
28876
28877 ;
28878 return 0;
28879 }
28880 _ACEOF
28881 if ac_fn_c_try_run "$LINENO"; then :
28882 gl_cv_func_stat_file_slash=yes
28883 else
28884 gl_cv_func_stat_file_slash=no
28885 fi
28886 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
28887 conftest.$ac_objext conftest.beam conftest.$ac_ext
28888 fi
28889
28890 rm -f conftest.tmp conftest.lnk
28891 fi
28892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
28893 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
28894 case $gl_cv_func_stat_dir_slash in
28895 *no) REPLACE_STAT=1
28896
28897 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
28898 ;;
28899 esac
28900 case $gl_cv_func_stat_file_slash in
28901 *no) REPLACE_STAT=1
28902
28903 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
28904 ;;
28905 esac
28906
28907 if test $REPLACE_STAT = 1; then
28908
28909
28910
28911
28912
28913
28914
28915
28916 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
28917
28918 :
28919 fi
28920
28921
28922
28923
28924
28925 GNULIB_STAT=1
28926
28927
28928
28929
28930
28931 gl_gnulib_enabled_stat=true
28932 if test $REPLACE_STAT = 1; then
28933 func_gl_gnulib_m4code_dosname
28934 fi
28935 if test $REPLACE_STAT = 1; then
28936 func_gl_gnulib_m4code_pathmax
28937 fi
28938 fi
28939 }
28940 func_gl_gnulib_m4code_strtoll ()
28941 {
28942 if ! $gl_gnulib_enabled_strtoll; then
28943
28944
28945
28946 if test "$ac_cv_type_long_long_int" = yes; then
28947 for ac_func in strtoll
28948 do :
28949 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
28950 if test "x$ac_cv_func_strtoll" = x""yes; then :
28951 cat >>confdefs.h <<_ACEOF
28952 #define HAVE_STRTOLL 1
28953 _ACEOF
28954
28955 fi
28956 done
28957
28958 if test $ac_cv_func_strtoll = no; then
28959 HAVE_STRTOLL=0
28960 fi
28961 fi
28962
28963 if test $HAVE_STRTOLL = 0; then
28964
28965
28966
28967
28968
28969
28970
28971
28972 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
28973
28974
28975 :
28976
28977 fi
28978
28979
28980
28981
28982
28983 GNULIB_STRTOLL=1
28984
28985
28986
28987
28988
28989 gl_gnulib_enabled_strtoll=true
28990 fi
28991 }
28992 func_gl_gnulib_m4code_strtoull ()
28993 {
28994 if ! $gl_gnulib_enabled_strtoull; then
28995
28996
28997
28998 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
28999 for ac_func in strtoull
29000 do :
29001 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
29002 if test "x$ac_cv_func_strtoull" = x""yes; then :
29003 cat >>confdefs.h <<_ACEOF
29004 #define HAVE_STRTOULL 1
29005 _ACEOF
29006
29007 fi
29008 done
29009
29010 if test $ac_cv_func_strtoull = no; then
29011 HAVE_STRTOULL=0
29012 fi
29013 fi
29014
29015 if test $HAVE_STRTOULL = 0; then
29016
29017
29018
29019
29020
29021
29022
29023
29024 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
29025
29026
29027 :
29028
29029 fi
29030
29031
29032
29033
29034
29035 GNULIB_STRTOULL=1
29036
29037
29038
29039
29040
29041 gl_gnulib_enabled_strtoull=true
29042 fi
29043 }
29044 func_gl_gnulib_m4code_tempname ()
29045 {
29046 if ! $gl_gnulib_enabled_tempname; then
29047
29048
29049 :
29050
29051
29052 gl_gnulib_enabled_tempname=true
29053 func_gl_gnulib_m4code_secure_getenv
29054 fi
29055 }
29056 func_gl_gnulib_m4code_682e609604ccaac6be382e4ee3a4eaec ()
29057 {
29058 if ! $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
29059 gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec=true
29060 fi
29061 }
29062 if test $HAVE_FACCESSAT = 0; then
29063 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
29064 fi
29065 if test $HAVE_FACCESSAT = 0; then
29066 func_gl_gnulib_m4code_dosname
29067 fi
29068 if test $HAVE_FACCESSAT = 0; then
29069 func_gl_gnulib_m4code_euidaccess
29070 fi
29071 if test $HAVE_FACCESSAT = 0; then
29072 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
29073 fi
29074 if test $HAVE_FCNTL = 0 || test $REPLACE_FCNTL = 1; then
29075 func_gl_gnulib_m4code_getdtablesize
29076 fi
29077 if test $HAVE_FDOPENDIR = 0; then
29078 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
29079 fi
29080 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
29081 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
29082 fi
29083 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
29084 func_gl_gnulib_m4code_dosname
29085 fi
29086 if test $HAVE_FSTATAT = 0 || test $REPLACE_FSTATAT = 1; then
29087 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
29088 fi
29089 if test $REPLACE_GETOPT = 1; then
29090 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
29091 fi
29092 if test $REPLACE_LSTAT = 1; then
29093 func_gl_gnulib_m4code_dosname
29094 fi
29095 if test $REPLACE_LSTAT = 1; then
29096 func_gl_gnulib_m4code_stat
29097 fi
29098 if test $HAVE_MKOSTEMP = 0; then
29099 func_gl_gnulib_m4code_tempname
29100 fi
29101 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
29102 func_gl_gnulib_m4code_stat
29103 fi
29104 if test $HAVE_READLINKAT = 0; then
29105 func_gl_gnulib_m4code_260941c0e5dc67ec9e87d1fb321c300b
29106 fi
29107 if test $HAVE_READLINKAT = 0; then
29108 func_gl_gnulib_m4code_dosname
29109 fi
29110 if test $HAVE_READLINKAT = 0; then
29111 func_gl_gnulib_m4code_03e0aaad4cb89ca757653bd367a6ccb7
29112 fi
29113 if { test $HAVE_DECL_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
29114 func_gl_gnulib_m4code_strtoll
29115 fi
29116 if { test $HAVE_DECL_STRTOUMAX = 0 || test $REPLACE_STRTOUMAX = 1; } && test $ac_cv_type_unsigned_long_long_int = yes; then
29117 func_gl_gnulib_m4code_strtoull
29118 fi
29119
29120 if $gl_gnulib_enabled_260941c0e5dc67ec9e87d1fb321c300b; then
29121 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE=
29122 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE='#'
29123 else
29124 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE='#'
29125 gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE=
29126 fi
29127
29128 if $gl_gnulib_enabled_dosname; then
29129 gl_GNULIB_ENABLED_dosname_TRUE=
29130 gl_GNULIB_ENABLED_dosname_FALSE='#'
29131 else
29132 gl_GNULIB_ENABLED_dosname_TRUE='#'
29133 gl_GNULIB_ENABLED_dosname_FALSE=
29134 fi
29135
29136 if $gl_gnulib_enabled_euidaccess; then
29137 gl_GNULIB_ENABLED_euidaccess_TRUE=
29138 gl_GNULIB_ENABLED_euidaccess_FALSE='#'
29139 else
29140 gl_GNULIB_ENABLED_euidaccess_TRUE='#'
29141 gl_GNULIB_ENABLED_euidaccess_FALSE=
29142 fi
29143
29144 if $gl_gnulib_enabled_getdtablesize; then
29145 gl_GNULIB_ENABLED_getdtablesize_TRUE=
29146 gl_GNULIB_ENABLED_getdtablesize_FALSE='#'
29147 else
29148 gl_GNULIB_ENABLED_getdtablesize_TRUE='#'
29149 gl_GNULIB_ENABLED_getdtablesize_FALSE=
29150 fi
29151
29152 if $gl_gnulib_enabled_getgroups; then
29153 gl_GNULIB_ENABLED_getgroups_TRUE=
29154 gl_GNULIB_ENABLED_getgroups_FALSE='#'
29155 else
29156 gl_GNULIB_ENABLED_getgroups_TRUE='#'
29157 gl_GNULIB_ENABLED_getgroups_FALSE=
29158 fi
29159
29160 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
29161 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
29162 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
29163 else
29164 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
29165 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
29166 fi
29167
29168 if $gl_gnulib_enabled_a9786850e999ae65a836a6041e8e5ed1; then
29169 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE=
29170 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE='#'
29171 else
29172 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE='#'
29173 gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE=
29174 fi
29175
29176 if $gl_gnulib_enabled_03e0aaad4cb89ca757653bd367a6ccb7; then
29177 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE=
29178 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE='#'
29179 else
29180 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE='#'
29181 gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE=
29182 fi
29183
29184 if $gl_gnulib_enabled_pathmax; then
29185 gl_GNULIB_ENABLED_pathmax_TRUE=
29186 gl_GNULIB_ENABLED_pathmax_FALSE='#'
29187 else
29188 gl_GNULIB_ENABLED_pathmax_TRUE='#'
29189 gl_GNULIB_ENABLED_pathmax_FALSE=
29190 fi
29191
29192 if $gl_gnulib_enabled_6099e9737f757db36c47fa9d9f02e88c; then
29193 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE=
29194 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE='#'
29195 else
29196 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE='#'
29197 gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE=
29198 fi
29199
29200 if $gl_gnulib_enabled_secure_getenv; then
29201 gl_GNULIB_ENABLED_secure_getenv_TRUE=
29202 gl_GNULIB_ENABLED_secure_getenv_FALSE='#'
29203 else
29204 gl_GNULIB_ENABLED_secure_getenv_TRUE='#'
29205 gl_GNULIB_ENABLED_secure_getenv_FALSE=
29206 fi
29207
29208 if $gl_gnulib_enabled_stat; then
29209 gl_GNULIB_ENABLED_stat_TRUE=
29210 gl_GNULIB_ENABLED_stat_FALSE='#'
29211 else
29212 gl_GNULIB_ENABLED_stat_TRUE='#'
29213 gl_GNULIB_ENABLED_stat_FALSE=
29214 fi
29215
29216 if $gl_gnulib_enabled_strtoll; then
29217 gl_GNULIB_ENABLED_strtoll_TRUE=
29218 gl_GNULIB_ENABLED_strtoll_FALSE='#'
29219 else
29220 gl_GNULIB_ENABLED_strtoll_TRUE='#'
29221 gl_GNULIB_ENABLED_strtoll_FALSE=
29222 fi
29223
29224 if $gl_gnulib_enabled_strtoull; then
29225 gl_GNULIB_ENABLED_strtoull_TRUE=
29226 gl_GNULIB_ENABLED_strtoull_FALSE='#'
29227 else
29228 gl_GNULIB_ENABLED_strtoull_TRUE='#'
29229 gl_GNULIB_ENABLED_strtoull_FALSE=
29230 fi
29231
29232 if $gl_gnulib_enabled_tempname; then
29233 gl_GNULIB_ENABLED_tempname_TRUE=
29234 gl_GNULIB_ENABLED_tempname_FALSE='#'
29235 else
29236 gl_GNULIB_ENABLED_tempname_TRUE='#'
29237 gl_GNULIB_ENABLED_tempname_FALSE=
29238 fi
29239
29240 if $gl_gnulib_enabled_682e609604ccaac6be382e4ee3a4eaec; then
29241 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE=
29242 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE='#'
29243 else
29244 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE='#'
29245 gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE=
29246 fi
29247
29248 # End of code from modules
29249
29250
29251
29252
29253
29254
29255
29256
29257
29258 gltests_libdeps=
29259 gltests_ltlibdeps=
29260
29261
29262
29263
29264
29265
29266
29267
29268
29269 gl_source_base='tests'
29270 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
29271
29272 gl_module_indicator_condition=$gltests_WITNESS
29273
29274
29275
29276
29277
29278
29279
29280
29281
29282
29283 LIBGNU_LIBDEPS="$gl_libdeps"
29284
29285 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
29286
29287
29288 CFLAGS=$SAVE_CFLAGS
29289 LIBS=$SAVE_LIBS
29290
29291 if test "${opsys}" = "mingw32"; then
29292 CPPFLAGS="$CPPFLAGS -DUSE_CRT_DLL=1 -I $srcdir/nt/inc"
29293 # Remove unneeded switches from the value of CC that goes to Makefiles
29294 CC=`echo $CC | sed -e "s,$GCC_TEST_OPTIONS,,"`
29295 fi
29296
29297 case "$opsys" in
29298 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
29299
29300 darwin)
29301 ## The -headerpad option tells ld (see man page) to leave room at the
29302 ## end of the header for adding load commands. Needed for dumping.
29303 ## 0x690 is the total size of 30 segment load commands (at 56
29304 ## each); under Cocoa 31 commands are required.
29305 if test "$HAVE_NS" = "yes"; then
29306 libs_nsgui="-framework AppKit"
29307 if test "$NS_IMPL_COCOA" = "yes"; then
29308 libs_nsgui="$libs_nsgui -framework IOKit"
29309 fi
29310 headerpad_extra=6C8
29311 else
29312 libs_nsgui=
29313 headerpad_extra=690
29314 fi
29315 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
29316
29317 ## This is here because src/Makefile.in did some extra fiddling around
29318 ## with LD_SWITCH_SYSTEM. It seems cleaner to put this in
29319 ## LD_SWITCH_SYSTEM_TEMACS instead,
29320 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
29321 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
29322 ;;
29323
29324 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
29325 ## find X at run-time.
29326 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
29327 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
29328 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
29329 ## had different values in configure (in ac_link) and src/Makefile.in.
29330 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
29331 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
29332
29333 mingw32)
29334 ## MinGW64 does not prepend an underscore to symbols, so we must
29335 ## pass a different -entry switch to linker. FIXME: It is better
29336 ## to make the entry points the same by changing unexw32.c.
29337 case "$canonical" in
29338 x86_64-*-*) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,_start -Wl,-Map,./temacs.map" ;;
29339 *) LD_SWITCH_SYSTEM_TEMACS="-Wl,-stack,0x00800000 -Wl,-heap,0x00100000 -Wl,-image-base,0x01000000 -Wl,-entry,__start -Wl,-Map,./temacs.map" ;;
29340 esac
29341 ;;
29342
29343 openbsd) LD_SWITCH_SYSTEM_TEMACS='-nopie' ;;
29344
29345 *) LD_SWITCH_SYSTEM_TEMACS= ;;
29346 esac
29347
29348 if test x$ac_enable_profiling != x ; then
29349 case $opsys in
29350 *freebsd | gnu-linux) ;;
29351 *) LD_SWITCH_SYSTEM_TEMACS="$LD_SWITCH_SYSTEM_TEMACS -pg" ;;
29352 esac
29353 fi
29354
29355 LD_SWITCH_SYSTEM_TEMACS="$LDFLAGS_NOCOMBRELOC $LD_SWITCH_SYSTEM_TEMACS"
29356
29357
29358
29359 ## MinGW-specific post-link processing of temacs.
29360 TEMACS_POST_LINK=":"
29361 ADDSECTION=
29362 EMACS_HEAPSIZE=
29363 if test "${opsys}" = "mingw32"; then
29364 TEMACS_POST_LINK="\$(MINGW_TEMACS_POST_LINK)"
29365 ADDSECTION="../nt/addsection\$(EXEEXT)"
29366 ## Preload heap size of temacs.exe in MB.
29367 case "$canonical" in
29368 x86_64-*-*) EMACS_HEAPSIZE=42 ;;
29369 *) EMACS_HEAPSIZE=27 ;;
29370 esac
29371 fi
29372
29373
29374
29375
29376
29377 ## Common for all window systems
29378 if test "$window_system" != "none"; then
29379
29380 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
29381
29382 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
29383 fi
29384
29385
29386
29387
29388
29389 #### Report on what we decided to do.
29390 #### Report GTK as a toolkit, even if it doesn't use Xt.
29391 #### It makes printing result more understandable as using GTK sets
29392 #### toolkit_scroll_bars to yes by default.
29393 if test "${HAVE_GTK}" = "yes"; then
29394 USE_X_TOOLKIT="$USE_GTK_TOOLKIT"
29395 fi
29396
29397 if test $USE_ACL -ne 0; then
29398 acl_summary="yes $LIB_ACL"
29399 else
29400 acl_summary=no
29401 fi
29402
29403 echo "
29404 Configured for \`${canonical}'.
29405
29406 Where should the build process find the source code? ${srcdir}
29407 What compiler should emacs be built with? ${CC} ${CFLAGS}
29408 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
29409 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
29410 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
29411 What window system should Emacs use? ${window_system}
29412 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
29413
29414 if test -n "${x_includes}"; then
29415 echo " Where do we find X Windows header files? ${x_includes}"
29416 else
29417 echo " Where do we find X Windows header files? Standard dirs"
29418 fi
29419 if test -n "${x_libraries}"; then
29420 echo " Where do we find X Windows libraries? ${x_libraries}"
29421 else
29422 echo " Where do we find X Windows libraries? Standard dirs"
29423 fi
29424
29425 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
29426 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
29427 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
29428 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
29429 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
29430 echo " Does Emacs use -lpng? ${HAVE_PNG}"
29431 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
29432 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
29433
29434 echo " Does Emacs support sound? ${HAVE_SOUND}"
29435
29436 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
29437 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
29438 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
29439 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
29440 echo " Does Emacs use a file notification library? ${NOTIFY_SUMMARY}"
29441 echo " Does Emacs use access control lists? ${acl_summary}"
29442 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
29443 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
29444 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
29445
29446 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
29447 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
29448 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
29449 echo " Does Emacs use -lxft? ${HAVE_XFT}"
29450 echo " Does Emacs directly use zlib? ${HAVE_ZLIB}"
29451
29452 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
29453 echo
29454
29455 if test -n "${EMACSDATA}"; then
29456 echo " Environment variable EMACSDATA set to: $EMACSDATA"
29457 fi
29458 if test -n "${EMACSDOC}"; then
29459 echo " Environment variable EMACSDOC set to: $EMACSDOC"
29460 fi
29461
29462 echo
29463
29464 if test "$HAVE_NS" = "yes"; then
29465 echo
29466 echo "You must run \"${MAKE-make} install\" in order to test the built application.
29467 The installed application will go to nextstep/Emacs.app and can be
29468 run or moved from there."
29469 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
29470 echo "The application will be fully self-contained."
29471 else
29472 echo "The lisp resources for the application will be installed under ${prefix}.
29473 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
29474 to run if these resources are not installed."
29475 fi
29476 echo
29477 fi
29478
29479 if test "${opsys}" = "cygwin"; then
29480 case `uname -r` in
29481 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
29482 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
29483 echo
29484 ;;
29485 esac
29486 fi
29487
29488 # Remove any trailing slashes in these variables.
29489 test "${prefix}" != NONE &&
29490 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
29491 test "${exec_prefix}" != NONE &&
29492 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
29493
29494 if test "$HAVE_NS" = "yes"; then
29495 if test "$NS_IMPL_GNUSTEP" = yes; then
29496 ac_config_files="$ac_config_files nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in"
29497
29498 ns_check_file=Resources/Info-gnustep.plist
29499 else
29500 ac_config_files="$ac_config_files nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in"
29501
29502 ns_check_file=Contents/Info.plist
29503 fi
29504
29505 fi
29506
29507 SUBDIR_MAKEFILES="lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile nt/Makefile"
29508
29509 ac_config_files="$ac_config_files Makefile lib/Makefile lib-src/Makefile oldXMenu/Makefile doc/emacs/Makefile doc/misc/Makefile doc/lispintro/Makefile doc/lispref/Makefile src/Makefile lwlib/Makefile lisp/Makefile leim/Makefile nextstep/Makefile nt/Makefile"
29510
29511
29512 opt_makefile=test/automated/Makefile
29513
29514 if test -f "$srcdir/$opt_makefile.in"; then
29515 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29516 ac_config_files="$ac_config_files test/automated/Makefile"
29517
29518 fi
29519
29520
29521 opt_makefile=admin/unidata/Makefile
29522
29523 if test -f "$srcdir/$opt_makefile.in"; then
29524 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
29525 ac_config_files="$ac_config_files admin/unidata/Makefile"
29526
29527 fi
29528
29529
29530 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
29531
29532
29533
29534 ac_config_commands="$ac_config_commands src/epaths.h"
29535
29536
29537 ac_config_commands="$ac_config_commands src/.gdbinit"
29538
29539
29540 cat >confcache <<\_ACEOF
29541 # This file is a shell script that caches the results of configure
29542 # tests run on this system so they can be shared between configure
29543 # scripts and configure runs, see configure's option --config-cache.
29544 # It is not useful on other systems. If it contains results you don't
29545 # want to keep, you may remove or edit it.
29546 #
29547 # config.status only pays attention to the cache file if you give it
29548 # the --recheck option to rerun configure.
29549 #
29550 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29551 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29552 # following values.
29553
29554 _ACEOF
29555
29556 # The following way of writing the cache mishandles newlines in values,
29557 # but we know of no workaround that is simple, portable, and efficient.
29558 # So, we kill variables containing newlines.
29559 # Ultrix sh set writes to stderr and can't be redirected directly,
29560 # and sets the high bit in the cache file unless we assign to the vars.
29561 (
29562 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29563 eval ac_val=\$$ac_var
29564 case $ac_val in #(
29565 *${as_nl}*)
29566 case $ac_var in #(
29567 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
29568 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29569 esac
29570 case $ac_var in #(
29571 _ | IFS | as_nl) ;; #(
29572 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29573 *) { eval $ac_var=; unset $ac_var;} ;;
29574 esac ;;
29575 esac
29576 done
29577
29578 (set) 2>&1 |
29579 case $as_nl`(ac_space=' '; set) 2>&1` in #(
29580 *${as_nl}ac_space=\ *)
29581 # `set' does not quote correctly, so add quotes: double-quote
29582 # substitution turns \\\\ into \\, and sed turns \\ into \.
29583 sed -n \
29584 "s/'/'\\\\''/g;
29585 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29586 ;; #(
29587 *)
29588 # `set' quotes correctly as required by POSIX, so do not add quotes.
29589 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29590 ;;
29591 esac |
29592 sort
29593 ) |
29594 sed '
29595 /^ac_cv_env_/b end
29596 t clear
29597 :clear
29598 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29599 t end
29600 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29601 :end' >>confcache
29602 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29603 if test -w "$cache_file"; then
29604 test "x$cache_file" != "x/dev/null" &&
29605 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
29606 $as_echo "$as_me: updating cache $cache_file" >&6;}
29607 cat confcache >$cache_file
29608 else
29609 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
29610 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29611 fi
29612 fi
29613 rm -f confcache
29614
29615 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29616 # Let make expand exec_prefix.
29617 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29618
29619 DEFS=-DHAVE_CONFIG_H
29620
29621 ac_libobjs=
29622 ac_ltlibobjs=
29623 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29624 # 1. Remove the extension, and $U if already installed.
29625 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29626 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29627 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
29628 # will be set to the directory where LIBOBJS objects are built.
29629 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29630 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
29631 done
29632 LIBOBJS=$ac_libobjs
29633
29634 LTLIBOBJS=$ac_ltlibobjs
29635
29636
29637 if test -n "$EXEEXT"; then
29638 am__EXEEXT_TRUE=
29639 am__EXEEXT_FALSE='#'
29640 else
29641 am__EXEEXT_TRUE='#'
29642 am__EXEEXT_FALSE=
29643 fi
29644
29645 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
29646 as_fn_error "conditional \"AMDEP\" was never defined.
29647 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29648 fi
29649 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
29650 as_fn_error "conditional \"am__fastdepCC\" was never defined.
29651 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29652 fi
29653 if test -z "${BUILDING_FOR_WINDOWSNT_TRUE}" && test -z "${BUILDING_FOR_WINDOWSNT_FALSE}"; then
29654 as_fn_error "conditional \"BUILDING_FOR_WINDOWSNT\" was never defined.
29655 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29656 fi
29657 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
29658 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
29659 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29660 fi
29661 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
29662 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
29663 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29664 fi
29665 if test -z "${GL_GENERATE_BYTESWAP_H_TRUE}" && test -z "${GL_GENERATE_BYTESWAP_H_FALSE}"; then
29666 as_fn_error "conditional \"GL_GENERATE_BYTESWAP_H\" was never defined.
29667 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29668 fi
29669
29670 if test -z "${GL_GENERATE_ERRNO_H_TRUE}" && test -z "${GL_GENERATE_ERRNO_H_FALSE}"; then
29671 as_fn_error "conditional \"GL_GENERATE_ERRNO_H\" was never defined.
29672 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29673 fi
29674 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
29675 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
29676 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29677 fi
29678 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
29679 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
29680 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29681 fi
29682 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
29683 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
29684 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29685 fi
29686 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
29687 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
29688 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29689 fi
29690 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
29691 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
29692 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29693 fi
29694 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
29695 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
29696 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29697 fi
29698 if test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_TRUE}" && test -z "${gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b_FALSE}"; then
29699 as_fn_error "conditional \"gl_GNULIB_ENABLED_260941c0e5dc67ec9e87d1fb321c300b\" was never defined.
29700 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29701 fi
29702 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
29703 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
29704 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29705 fi
29706 if test -z "${gl_GNULIB_ENABLED_euidaccess_TRUE}" && test -z "${gl_GNULIB_ENABLED_euidaccess_FALSE}"; then
29707 as_fn_error "conditional \"gl_GNULIB_ENABLED_euidaccess\" was never defined.
29708 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29709 fi
29710 if test -z "${gl_GNULIB_ENABLED_getdtablesize_TRUE}" && test -z "${gl_GNULIB_ENABLED_getdtablesize_FALSE}"; then
29711 as_fn_error "conditional \"gl_GNULIB_ENABLED_getdtablesize\" was never defined.
29712 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29713 fi
29714 if test -z "${gl_GNULIB_ENABLED_getgroups_TRUE}" && test -z "${gl_GNULIB_ENABLED_getgroups_FALSE}"; then
29715 as_fn_error "conditional \"gl_GNULIB_ENABLED_getgroups\" was never defined.
29716 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29717 fi
29718 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
29719 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
29720 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29721 fi
29722 if test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_TRUE}" && test -z "${gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1_FALSE}"; then
29723 as_fn_error "conditional \"gl_GNULIB_ENABLED_a9786850e999ae65a836a6041e8e5ed1\" was never defined.
29724 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29725 fi
29726 if test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_TRUE}" && test -z "${gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7_FALSE}"; then
29727 as_fn_error "conditional \"gl_GNULIB_ENABLED_03e0aaad4cb89ca757653bd367a6ccb7\" was never defined.
29728 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29729 fi
29730 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
29731 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
29732 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29733 fi
29734 if test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_TRUE}" && test -z "${gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c_FALSE}"; then
29735 as_fn_error "conditional \"gl_GNULIB_ENABLED_6099e9737f757db36c47fa9d9f02e88c\" was never defined.
29736 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29737 fi
29738 if test -z "${gl_GNULIB_ENABLED_secure_getenv_TRUE}" && test -z "${gl_GNULIB_ENABLED_secure_getenv_FALSE}"; then
29739 as_fn_error "conditional \"gl_GNULIB_ENABLED_secure_getenv\" was never defined.
29740 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29741 fi
29742 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
29743 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
29744 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29745 fi
29746 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
29747 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
29748 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29749 fi
29750 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
29751 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
29752 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29753 fi
29754 if test -z "${gl_GNULIB_ENABLED_tempname_TRUE}" && test -z "${gl_GNULIB_ENABLED_tempname_FALSE}"; then
29755 as_fn_error "conditional \"gl_GNULIB_ENABLED_tempname\" was never defined.
29756 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29757 fi
29758 if test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_TRUE}" && test -z "${gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec_FALSE}"; then
29759 as_fn_error "conditional \"gl_GNULIB_ENABLED_682e609604ccaac6be382e4ee3a4eaec\" was never defined.
29760 Usually this means the macro was only invoked conditionally." "$LINENO" 5
29761 fi
29762
29763 gl_libobjs=
29764 gl_ltlibobjs=
29765 if test -n "$gl_LIBOBJS"; then
29766 # Remove the extension.
29767 sed_drop_objext='s/\.o$//;s/\.obj$//'
29768 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29769 gl_libobjs="$gl_libobjs $i.$ac_objext"
29770 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
29771 done
29772 fi
29773 gl_LIBOBJS=$gl_libobjs
29774
29775 gl_LTLIBOBJS=$gl_ltlibobjs
29776
29777
29778
29779 gltests_libobjs=
29780 gltests_ltlibobjs=
29781 if test -n "$gltests_LIBOBJS"; then
29782 # Remove the extension.
29783 sed_drop_objext='s/\.o$//;s/\.obj$//'
29784 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
29785 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
29786 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
29787 done
29788 fi
29789 gltests_LIBOBJS=$gltests_libobjs
29790
29791 gltests_LTLIBOBJS=$gltests_ltlibobjs
29792
29793
29794
29795 : ${CONFIG_STATUS=./config.status}
29796 ac_write_fail=0
29797 ac_clean_files_save=$ac_clean_files
29798 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29799 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
29800 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29801 as_write_fail=0
29802 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
29803 #! $SHELL
29804 # Generated by $as_me.
29805 # Run this file to recreate the current configuration.
29806 # Compiler output produced by configure, useful for debugging
29807 # configure, is in config.log if it exists.
29808
29809 debug=false
29810 ac_cs_recheck=false
29811 ac_cs_silent=false
29812
29813 SHELL=\${CONFIG_SHELL-$SHELL}
29814 export SHELL
29815 _ASEOF
29816 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
29817 ## -------------------- ##
29818 ## M4sh Initialization. ##
29819 ## -------------------- ##
29820
29821 # Be more Bourne compatible
29822 DUALCASE=1; export DUALCASE # for MKS sh
29823 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
29824 emulate sh
29825 NULLCMD=:
29826 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29827 # is contrary to our usage. Disable this feature.
29828 alias -g '${1+"$@"}'='"$@"'
29829 setopt NO_GLOB_SUBST
29830 else
29831 case `(set -o) 2>/dev/null` in #(
29832 *posix*) :
29833 set -o posix ;; #(
29834 *) :
29835 ;;
29836 esac
29837 fi
29838
29839
29840 as_nl='
29841 '
29842 export as_nl
29843 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29844 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29845 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29846 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29847 # Prefer a ksh shell builtin over an external printf program on Solaris,
29848 # but without wasting forks for bash or zsh.
29849 if test -z "$BASH_VERSION$ZSH_VERSION" \
29850 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
29851 as_echo='print -r --'
29852 as_echo_n='print -rn --'
29853 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29854 as_echo='printf %s\n'
29855 as_echo_n='printf %s'
29856 else
29857 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29858 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29859 as_echo_n='/usr/ucb/echo -n'
29860 else
29861 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29862 as_echo_n_body='eval
29863 arg=$1;
29864 case $arg in #(
29865 *"$as_nl"*)
29866 expr "X$arg" : "X\\(.*\\)$as_nl";
29867 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29868 esac;
29869 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29870 '
29871 export as_echo_n_body
29872 as_echo_n='sh -c $as_echo_n_body as_echo'
29873 fi
29874 export as_echo_body
29875 as_echo='sh -c $as_echo_body as_echo'
29876 fi
29877
29878 # The user is always right.
29879 if test "${PATH_SEPARATOR+set}" != set; then
29880 PATH_SEPARATOR=:
29881 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29882 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29883 PATH_SEPARATOR=';'
29884 }
29885 fi
29886
29887
29888 # IFS
29889 # We need space, tab and new line, in precisely that order. Quoting is
29890 # there to prevent editors from complaining about space-tab.
29891 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29892 # splitting by setting IFS to empty value.)
29893 IFS=" "" $as_nl"
29894
29895 # Find who we are. Look in the path if we contain no directory separator.
29896 case $0 in #((
29897 *[\\/]* ) as_myself=$0 ;;
29898 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29899 for as_dir in $PATH
29900 do
29901 IFS=$as_save_IFS
29902 test -z "$as_dir" && as_dir=.
29903 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29904 done
29905 IFS=$as_save_IFS
29906
29907 ;;
29908 esac
29909 # We did not find ourselves, most probably we were run as `sh COMMAND'
29910 # in which case we are not to be found in the path.
29911 if test "x$as_myself" = x; then
29912 as_myself=$0
29913 fi
29914 if test ! -f "$as_myself"; then
29915 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29916 exit 1
29917 fi
29918
29919 # Unset variables that we do not need and which cause bugs (e.g. in
29920 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
29921 # suppresses any "Segmentation fault" message there. '((' could
29922 # trigger a bug in pdksh 5.2.14.
29923 for as_var in BASH_ENV ENV MAIL MAILPATH
29924 do eval test x\${$as_var+set} = xset \
29925 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
29926 done
29927 PS1='$ '
29928 PS2='> '
29929 PS4='+ '
29930
29931 # NLS nuisances.
29932 LC_ALL=C
29933 export LC_ALL
29934 LANGUAGE=C
29935 export LANGUAGE
29936
29937 # CDPATH.
29938 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
29939
29940
29941 # as_fn_error ERROR [LINENO LOG_FD]
29942 # ---------------------------------
29943 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
29944 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
29945 # script with status $?, using 1 if that was 0.
29946 as_fn_error ()
29947 {
29948 as_status=$?; test $as_status -eq 0 && as_status=1
29949 if test "$3"; then
29950 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
29951 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
29952 fi
29953 $as_echo "$as_me: error: $1" >&2
29954 as_fn_exit $as_status
29955 } # as_fn_error
29956
29957
29958 # as_fn_set_status STATUS
29959 # -----------------------
29960 # Set $? to STATUS, without forking.
29961 as_fn_set_status ()
29962 {
29963 return $1
29964 } # as_fn_set_status
29965
29966 # as_fn_exit STATUS
29967 # -----------------
29968 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
29969 as_fn_exit ()
29970 {
29971 set +e
29972 as_fn_set_status $1
29973 exit $1
29974 } # as_fn_exit
29975
29976 # as_fn_unset VAR
29977 # ---------------
29978 # Portably unset VAR.
29979 as_fn_unset ()
29980 {
29981 { eval $1=; unset $1;}
29982 }
29983 as_unset=as_fn_unset
29984 # as_fn_append VAR VALUE
29985 # ----------------------
29986 # Append the text in VALUE to the end of the definition contained in VAR. Take
29987 # advantage of any shell optimizations that allow amortized linear growth over
29988 # repeated appends, instead of the typical quadratic growth present in naive
29989 # implementations.
29990 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
29991 eval 'as_fn_append ()
29992 {
29993 eval $1+=\$2
29994 }'
29995 else
29996 as_fn_append ()
29997 {
29998 eval $1=\$$1\$2
29999 }
30000 fi # as_fn_append
30001
30002 # as_fn_arith ARG...
30003 # ------------------
30004 # Perform arithmetic evaluation on the ARGs, and store the result in the
30005 # global $as_val. Take advantage of shells that can avoid forks. The arguments
30006 # must be portable across $(()) and expr.
30007 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
30008 eval 'as_fn_arith ()
30009 {
30010 as_val=$(( $* ))
30011 }'
30012 else
30013 as_fn_arith ()
30014 {
30015 as_val=`expr "$@" || test $? -eq 1`
30016 }
30017 fi # as_fn_arith
30018
30019
30020 if expr a : '\(a\)' >/dev/null 2>&1 &&
30021 test "X`expr 00001 : '.*\(...\)'`" = X001; then
30022 as_expr=expr
30023 else
30024 as_expr=false
30025 fi
30026
30027 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
30028 as_basename=basename
30029 else
30030 as_basename=false
30031 fi
30032
30033 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
30034 as_dirname=dirname
30035 else
30036 as_dirname=false
30037 fi
30038
30039 as_me=`$as_basename -- "$0" ||
30040 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
30041 X"$0" : 'X\(//\)$' \| \
30042 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
30043 $as_echo X/"$0" |
30044 sed '/^.*\/\([^/][^/]*\)\/*$/{
30045 s//\1/
30046 q
30047 }
30048 /^X\/\(\/\/\)$/{
30049 s//\1/
30050 q
30051 }
30052 /^X\/\(\/\).*/{
30053 s//\1/
30054 q
30055 }
30056 s/.*/./; q'`
30057
30058 # Avoid depending upon Character Ranges.
30059 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
30060 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
30061 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
30062 as_cr_digits='0123456789'
30063 as_cr_alnum=$as_cr_Letters$as_cr_digits
30064
30065 ECHO_C= ECHO_N= ECHO_T=
30066 case `echo -n x` in #(((((
30067 -n*)
30068 case `echo 'xy\c'` in
30069 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
30070 xy) ECHO_C='\c';;
30071 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
30072 ECHO_T=' ';;
30073 esac;;
30074 *)
30075 ECHO_N='-n';;
30076 esac
30077
30078 rm -f conf$$ conf$$.exe conf$$.file
30079 if test -d conf$$.dir; then
30080 rm -f conf$$.dir/conf$$.file
30081 else
30082 rm -f conf$$.dir
30083 mkdir conf$$.dir 2>/dev/null
30084 fi
30085 if (echo >conf$$.file) 2>/dev/null; then
30086 if ln -s conf$$.file conf$$ 2>/dev/null; then
30087 as_ln_s='ln -s'
30088 # ... but there are two gotchas:
30089 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
30090 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
30091 # In both cases, we have to default to `cp -p'.
30092 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
30093 as_ln_s='cp -p'
30094 elif ln conf$$.file conf$$ 2>/dev/null; then
30095 as_ln_s=ln
30096 else
30097 as_ln_s='cp -p'
30098 fi
30099 else
30100 as_ln_s='cp -p'
30101 fi
30102 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
30103 rmdir conf$$.dir 2>/dev/null
30104
30105
30106 # as_fn_mkdir_p
30107 # -------------
30108 # Create "$as_dir" as a directory, including parents if necessary.
30109 as_fn_mkdir_p ()
30110 {
30111
30112 case $as_dir in #(
30113 -*) as_dir=./$as_dir;;
30114 esac
30115 test -d "$as_dir" || eval $as_mkdir_p || {
30116 as_dirs=
30117 while :; do
30118 case $as_dir in #(
30119 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30120 *) as_qdir=$as_dir;;
30121 esac
30122 as_dirs="'$as_qdir' $as_dirs"
30123 as_dir=`$as_dirname -- "$as_dir" ||
30124 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30125 X"$as_dir" : 'X\(//\)[^/]' \| \
30126 X"$as_dir" : 'X\(//\)$' \| \
30127 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30128 $as_echo X"$as_dir" |
30129 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30130 s//\1/
30131 q
30132 }
30133 /^X\(\/\/\)[^/].*/{
30134 s//\1/
30135 q
30136 }
30137 /^X\(\/\/\)$/{
30138 s//\1/
30139 q
30140 }
30141 /^X\(\/\).*/{
30142 s//\1/
30143 q
30144 }
30145 s/.*/./; q'`
30146 test -d "$as_dir" && break
30147 done
30148 test -z "$as_dirs" || eval "mkdir $as_dirs"
30149 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
30150
30151
30152 } # as_fn_mkdir_p
30153 if mkdir -p . 2>/dev/null; then
30154 as_mkdir_p='mkdir -p "$as_dir"'
30155 else
30156 test -d ./-p && rmdir ./-p
30157 as_mkdir_p=false
30158 fi
30159
30160 if test -x / >/dev/null 2>&1; then
30161 as_test_x='test -x'
30162 else
30163 if ls -dL / >/dev/null 2>&1; then
30164 as_ls_L_option=L
30165 else
30166 as_ls_L_option=
30167 fi
30168 as_test_x='
30169 eval sh -c '\''
30170 if test -d "$1"; then
30171 test -d "$1/.";
30172 else
30173 case $1 in #(
30174 -*)set "./$1";;
30175 esac;
30176 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
30177 ???[sx]*):;;*)false;;esac;fi
30178 '\'' sh
30179 '
30180 fi
30181 as_executable_p=$as_test_x
30182
30183 # Sed expression to map a string onto a valid CPP name.
30184 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
30185
30186 # Sed expression to map a string onto a valid variable name.
30187 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
30188
30189
30190 exec 6>&1
30191 ## ----------------------------------- ##
30192 ## Main body of $CONFIG_STATUS script. ##
30193 ## ----------------------------------- ##
30194 _ASEOF
30195 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
30196
30197 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30198 # Save the log message, to keep $0 and so on meaningful, and to
30199 # report actual input values of CONFIG_FILES etc. instead of their
30200 # values after options handling.
30201 ac_log="
30202 This file was extended by emacs $as_me 24.3.50, which was
30203 generated by GNU Autoconf 2.65. Invocation command line was
30204
30205 CONFIG_FILES = $CONFIG_FILES
30206 CONFIG_HEADERS = $CONFIG_HEADERS
30207 CONFIG_LINKS = $CONFIG_LINKS
30208 CONFIG_COMMANDS = $CONFIG_COMMANDS
30209 $ $0 $@
30210
30211 on `(hostname || uname -n) 2>/dev/null | sed 1q`
30212 "
30213
30214 _ACEOF
30215
30216 case $ac_config_files in *"
30217 "*) set x $ac_config_files; shift; ac_config_files=$*;;
30218 esac
30219
30220 case $ac_config_headers in *"
30221 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
30222 esac
30223
30224
30225 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30226 # Files that config.status was made for.
30227 config_files="$ac_config_files"
30228 config_headers="$ac_config_headers"
30229 config_commands="$ac_config_commands"
30230
30231 _ACEOF
30232
30233 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30234 ac_cs_usage="\
30235 \`$as_me' instantiates files and other configuration actions
30236 from templates according to the current configuration. Unless the files
30237 and actions are specified as TAGs, all are instantiated by default.
30238
30239 Usage: $0 [OPTION]... [TAG]...
30240
30241 -h, --help print this help, then exit
30242 -V, --version print version number and configuration settings, then exit
30243 --config print configuration, then exit
30244 -q, --quiet, --silent
30245 do not print progress messages
30246 -d, --debug don't remove temporary files
30247 --recheck update $as_me by reconfiguring in the same conditions
30248 --file=FILE[:TEMPLATE]
30249 instantiate the configuration file FILE
30250 --header=FILE[:TEMPLATE]
30251 instantiate the configuration header FILE
30252
30253 Configuration files:
30254 $config_files
30255
30256 Configuration headers:
30257 $config_headers
30258
30259 Configuration commands:
30260 $config_commands
30261
30262 Report bugs to the package provider."
30263
30264 _ACEOF
30265 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30266 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
30267 ac_cs_version="\\
30268 emacs config.status 24.3.50
30269 configured by $0, generated by GNU Autoconf 2.65,
30270 with options \\"\$ac_cs_config\\"
30271
30272 Copyright (C) 2009 Free Software Foundation, Inc.
30273 This config.status script is free software; the Free Software Foundation
30274 gives unlimited permission to copy, distribute and modify it."
30275
30276 ac_pwd='$ac_pwd'
30277 srcdir='$srcdir'
30278 INSTALL='$INSTALL'
30279 MKDIR_P='$MKDIR_P'
30280 AWK='$AWK'
30281 test -n "\$AWK" || AWK=awk
30282 _ACEOF
30283
30284 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30285 # The default lists apply if the user does not specify any file.
30286 ac_need_defaults=:
30287 while test $# != 0
30288 do
30289 case $1 in
30290 --*=*)
30291 ac_option=`expr "X$1" : 'X\([^=]*\)='`
30292 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
30293 ac_shift=:
30294 ;;
30295 *)
30296 ac_option=$1
30297 ac_optarg=$2
30298 ac_shift=shift
30299 ;;
30300 esac
30301
30302 case $ac_option in
30303 # Handling of the options.
30304 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
30305 ac_cs_recheck=: ;;
30306 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
30307 $as_echo "$ac_cs_version"; exit ;;
30308 --config | --confi | --conf | --con | --co | --c )
30309 $as_echo "$ac_cs_config"; exit ;;
30310 --debug | --debu | --deb | --de | --d | -d )
30311 debug=: ;;
30312 --file | --fil | --fi | --f )
30313 $ac_shift
30314 case $ac_optarg in
30315 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30316 esac
30317 as_fn_append CONFIG_FILES " '$ac_optarg'"
30318 ac_need_defaults=false;;
30319 --header | --heade | --head | --hea )
30320 $ac_shift
30321 case $ac_optarg in
30322 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
30323 esac
30324 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
30325 ac_need_defaults=false;;
30326 --he | --h)
30327 # Conflict between --help and --header
30328 as_fn_error "ambiguous option: \`$1'
30329 Try \`$0 --help' for more information.";;
30330 --help | --hel | -h )
30331 $as_echo "$ac_cs_usage"; exit ;;
30332 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30333 | -silent | --silent | --silen | --sile | --sil | --si | --s)
30334 ac_cs_silent=: ;;
30335
30336 # This is an error.
30337 -*) as_fn_error "unrecognized option: \`$1'
30338 Try \`$0 --help' for more information." ;;
30339
30340 *) as_fn_append ac_config_targets " $1"
30341 ac_need_defaults=false ;;
30342
30343 esac
30344 shift
30345 done
30346
30347 ac_configure_extra_args=
30348
30349 if $ac_cs_silent; then
30350 exec 6>/dev/null
30351 ac_configure_extra_args="$ac_configure_extra_args --silent"
30352 fi
30353
30354 _ACEOF
30355 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30356 if \$ac_cs_recheck; then
30357 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30358 shift
30359 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30360 CONFIG_SHELL='$SHELL'
30361 export CONFIG_SHELL
30362 exec "\$@"
30363 fi
30364
30365 _ACEOF
30366 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30367 exec 5>>config.log
30368 {
30369 echo
30370 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30371 ## Running $as_me. ##
30372 _ASBOX
30373 $as_echo "$ac_log"
30374 } >&5
30375
30376 _ACEOF
30377 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30378 #
30379 # INIT-COMMANDS
30380 #
30381 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
30382 GCC="$GCC" CPPFLAGS="$CPPFLAGS" opsys="$opsys"
30383
30384 _ACEOF
30385
30386 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30387
30388 # Handling of arguments.
30389 for ac_config_target in $ac_config_targets
30390 do
30391 case $ac_config_target in
30392 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
30393 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
30394 "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist:nextstep/templates/Info-gnustep.plist.in" ;;
30395 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
30396 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
30397 "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings:nextstep/templates/InfoPlist.strings.in" ;;
30398 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
30399 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
30400 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
30401 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
30402 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
30403 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
30404 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
30405 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
30406 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
30407 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
30408 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
30409 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
30410 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
30411 "nt/Makefile") CONFIG_FILES="$CONFIG_FILES nt/Makefile" ;;
30412 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
30413 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
30414 "src/epaths.h") CONFIG_COMMANDS="$CONFIG_COMMANDS src/epaths.h" ;;
30415 "src/.gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS src/.gdbinit" ;;
30416
30417 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
30418 esac
30419 done
30420
30421
30422 # If the user did not use the arguments to specify the items to instantiate,
30423 # then the envvar interface is used. Set only those that are not.
30424 # We use the long form for the default assignment because of an extremely
30425 # bizarre bug on SunOS 4.1.3.
30426 if $ac_need_defaults; then
30427 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30428 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30429 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30430 fi
30431
30432 # Have a temporary directory for convenience. Make it in the build tree
30433 # simply because there is no reason against having it here, and in addition,
30434 # creating and moving files from /tmp can sometimes cause problems.
30435 # Hook for its removal unless debugging.
30436 # Note that there is a small window in which the directory will not be cleaned:
30437 # after its creation but before its name has been assigned to `$tmp'.
30438 $debug ||
30439 {
30440 tmp=
30441 trap 'exit_status=$?
30442 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30443 ' 0
30444 trap 'as_fn_exit 1' 1 2 13 15
30445 }
30446 # Create a (secure) tmp directory for tmp files.
30447
30448 {
30449 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30450 test -n "$tmp" && test -d "$tmp"
30451 } ||
30452 {
30453 tmp=./conf$$-$RANDOM
30454 (umask 077 && mkdir "$tmp")
30455 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
30456
30457 # Set up the scripts for CONFIG_FILES section.
30458 # No need to generate them if there are no CONFIG_FILES.
30459 # This happens for instance with `./config.status config.h'.
30460 if test -n "$CONFIG_FILES"; then
30461
30462 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
30463 ac_cs_awk_getline=:
30464 ac_cs_awk_pipe_init=
30465 ac_cs_awk_read_file='
30466 while ((getline aline < (F[key])) > 0)
30467 print(aline)
30468 close(F[key])'
30469 ac_cs_awk_pipe_fini=
30470 else
30471 ac_cs_awk_getline=false
30472 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
30473 ac_cs_awk_read_file='
30474 print "|#_!!_#|"
30475 print "cat " F[key] " &&"
30476 '$ac_cs_awk_pipe_init
30477 # The final `:' finishes the AND list.
30478 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
30479 fi
30480 ac_cr=`echo X | tr X '\015'`
30481 # On cygwin, bash can eat \r inside `` if the user requested igncr.
30482 # But we know of no other shell where ac_cr would be empty at this
30483 # point, so we can use a bashism as a fallback.
30484 if test "x$ac_cr" = x; then
30485 eval ac_cr=\$\'\\r\'
30486 fi
30487 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30488 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30489 ac_cs_awk_cr='\r'
30490 else
30491 ac_cs_awk_cr=$ac_cr
30492 fi
30493
30494 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30495 _ACEOF
30496
30497 # Create commands to substitute file output variables.
30498 {
30499 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
30500 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
30501 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
30502 echo "_ACAWK" &&
30503 echo "_ACEOF"
30504 } >conf$$files.sh &&
30505 . ./conf$$files.sh ||
30506 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30507 rm -f conf$$files.sh
30508
30509 {
30510 echo "cat >conf$$subs.awk <<_ACEOF" &&
30511 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30512 echo "_ACEOF"
30513 } >conf$$subs.sh ||
30514 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30515 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30516 ac_delim='%!_!# '
30517 for ac_last_try in false false false false false :; do
30518 . ./conf$$subs.sh ||
30519 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30520
30521 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30522 if test $ac_delim_n = $ac_delim_num; then
30523 break
30524 elif $ac_last_try; then
30525 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
30526 else
30527 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30528 fi
30529 done
30530 rm -f conf$$subs.sh
30531
30532 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30533 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30534 _ACEOF
30535 sed -n '
30536 h
30537 s/^/S["/; s/!.*/"]=/
30538 p
30539 g
30540 s/^[^!]*!//
30541 :repl
30542 t repl
30543 s/'"$ac_delim"'$//
30544 t delim
30545 :nl
30546 h
30547 s/\(.\{148\}\)..*/\1/
30548 t more1
30549 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30550 p
30551 n
30552 b repl
30553 :more1
30554 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30555 p
30556 g
30557 s/.\{148\}//
30558 t nl
30559 :delim
30560 h
30561 s/\(.\{148\}\)..*/\1/
30562 t more2
30563 s/["\\]/\\&/g; s/^/"/; s/$/"/
30564 p
30565 b
30566 :more2
30567 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30568 p
30569 g
30570 s/.\{148\}//
30571 t delim
30572 ' <conf$$subs.awk | sed '
30573 /^[^""]/{
30574 N
30575 s/\n//
30576 }
30577 ' >>$CONFIG_STATUS || ac_write_fail=1
30578 rm -f conf$$subs.awk
30579 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30580 _ACAWK
30581 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30582 for (key in S) S_is_set[key] = 1
30583 FS = "\a"
30584 \$ac_cs_awk_pipe_init
30585 }
30586 {
30587 line = $ 0
30588 nfields = split(line, field, "@")
30589 substed = 0
30590 len = length(field[1])
30591 for (i = 2; i < nfields; i++) {
30592 key = field[i]
30593 keylen = length(key)
30594 if (S_is_set[key]) {
30595 value = S[key]
30596 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30597 len += length(value) + length(field[++i])
30598 substed = 1
30599 } else
30600 len += 1 + keylen
30601 }
30602 if (nfields == 3 && !substed) {
30603 key = field[2]
30604 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
30605 \$ac_cs_awk_read_file
30606 next
30607 }
30608 }
30609 print line
30610 }
30611 \$ac_cs_awk_pipe_fini
30612 _ACAWK
30613 _ACEOF
30614 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30615 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30616 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30617 else
30618 cat
30619 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30620 || as_fn_error "could not setup config files machinery" "$LINENO" 5
30621 _ACEOF
30622
30623 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30624 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30625 # trailing colons and then remove the whole line if VPATH becomes empty
30626 # (actually we leave an empty line to preserve line numbers).
30627 if test "x$srcdir" = x.; then
30628 ac_vpsub='/^[ ]*VPATH[ ]*=/{
30629 s/:*\$(srcdir):*/:/
30630 s/:*\${srcdir}:*/:/
30631 s/:*@srcdir@:*/:/
30632 s/^\([^=]*=[ ]*\):*/\1/
30633 s/:*$//
30634 s/^[^=]*=[ ]*$//
30635 }'
30636 fi
30637
30638 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30639 fi # test -n "$CONFIG_FILES"
30640
30641 # Set up the scripts for CONFIG_HEADERS section.
30642 # No need to generate them if there are no CONFIG_HEADERS.
30643 # This happens for instance with `./config.status Makefile'.
30644 if test -n "$CONFIG_HEADERS"; then
30645 cat >"$tmp/defines.awk" <<\_ACAWK ||
30646 BEGIN {
30647 _ACEOF
30648
30649 # Transform confdefs.h into an awk script `defines.awk', embedded as
30650 # here-document in config.status, that substitutes the proper values into
30651 # config.h.in to produce config.h.
30652
30653 # Create a delimiter string that does not exist in confdefs.h, to ease
30654 # handling of long lines.
30655 ac_delim='%!_!# '
30656 for ac_last_try in false false :; do
30657 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30658 if test -z "$ac_t"; then
30659 break
30660 elif $ac_last_try; then
30661 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
30662 else
30663 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30664 fi
30665 done
30666
30667 # For the awk script, D is an array of macro values keyed by name,
30668 # likewise P contains macro parameters if any. Preserve backslash
30669 # newline sequences.
30670
30671 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30672 sed -n '
30673 s/.\{148\}/&'"$ac_delim"'/g
30674 t rset
30675 :rset
30676 s/^[ ]*#[ ]*define[ ][ ]*/ /
30677 t def
30678 d
30679 :def
30680 s/\\$//
30681 t bsnl
30682 s/["\\]/\\&/g
30683 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30684 D["\1"]=" \3"/p
30685 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
30686 d
30687 :bsnl
30688 s/["\\]/\\&/g
30689 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
30690 D["\1"]=" \3\\\\\\n"\\/p
30691 t cont
30692 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30693 t cont
30694 d
30695 :cont
30696 n
30697 s/.\{148\}/&'"$ac_delim"'/g
30698 t clear
30699 :clear
30700 s/\\$//
30701 t bsnlc
30702 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30703 d
30704 :bsnlc
30705 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30706 b cont
30707 ' <confdefs.h | sed '
30708 s/'"$ac_delim"'/"\\\
30709 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30710
30711 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30712 for (key in D) D_is_set[key] = 1
30713 FS = "\a"
30714 }
30715 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30716 line = \$ 0
30717 split(line, arg, " ")
30718 if (arg[1] == "#") {
30719 defundef = arg[2]
30720 mac1 = arg[3]
30721 } else {
30722 defundef = substr(arg[1], 2)
30723 mac1 = arg[2]
30724 }
30725 split(mac1, mac2, "(") #)
30726 macro = mac2[1]
30727 prefix = substr(line, 1, index(line, defundef) - 1)
30728 if (D_is_set[macro]) {
30729 # Preserve the white space surrounding the "#".
30730 print prefix "define", macro P[macro] D[macro]
30731 next
30732 } else {
30733 # Replace #undef with comments. This is necessary, for example,
30734 # in the case of _POSIX_SOURCE, which is predefined and required
30735 # on some systems where configure will not decide to define it.
30736 if (defundef == "undef") {
30737 print "/*", prefix defundef, macro, "*/"
30738 next
30739 }
30740 }
30741 }
30742 { print }
30743 _ACAWK
30744 _ACEOF
30745 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30746 as_fn_error "could not setup config headers machinery" "$LINENO" 5
30747 fi # test -n "$CONFIG_HEADERS"
30748
30749
30750 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
30751 shift
30752 for ac_tag
30753 do
30754 case $ac_tag in
30755 :[FHLC]) ac_mode=$ac_tag; continue;;
30756 esac
30757 case $ac_mode$ac_tag in
30758 :[FHL]*:*);;
30759 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
30760 :[FH]-) ac_tag=-:-;;
30761 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30762 esac
30763 ac_save_IFS=$IFS
30764 IFS=:
30765 set x $ac_tag
30766 IFS=$ac_save_IFS
30767 shift
30768 ac_file=$1
30769 shift
30770
30771 case $ac_mode in
30772 :L) ac_source=$1;;
30773 :[FH])
30774 ac_file_inputs=
30775 for ac_f
30776 do
30777 case $ac_f in
30778 -) ac_f="$tmp/stdin";;
30779 *) # Look for the file first in the build tree, then in the source tree
30780 # (if the path is not absolute). The absolute path cannot be DOS-style,
30781 # because $ac_f cannot contain `:'.
30782 test -f "$ac_f" ||
30783 case $ac_f in
30784 [\\/$]*) false;;
30785 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30786 esac ||
30787 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
30788 esac
30789 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30790 as_fn_append ac_file_inputs " '$ac_f'"
30791 done
30792
30793 # Let's still pretend it is `configure' which instantiates (i.e., don't
30794 # use $as_me), people would be surprised to read:
30795 # /* config.h. Generated by config.status. */
30796 configure_input='Generated from '`
30797 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30798 `' by configure.'
30799 if test x"$ac_file" != x-; then
30800 configure_input="$ac_file. $configure_input"
30801 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
30802 $as_echo "$as_me: creating $ac_file" >&6;}
30803 fi
30804 # Neutralize special characters interpreted by sed in replacement strings.
30805 case $configure_input in #(
30806 *\&* | *\|* | *\\* )
30807 ac_sed_conf_input=`$as_echo "$configure_input" |
30808 sed 's/[\\\\&|]/\\\\&/g'`;; #(
30809 *) ac_sed_conf_input=$configure_input;;
30810 esac
30811
30812 case $ac_tag in
30813 *:-:* | *:-) cat >"$tmp/stdin" \
30814 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
30815 esac
30816 ;;
30817 esac
30818
30819 ac_dir=`$as_dirname -- "$ac_file" ||
30820 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30821 X"$ac_file" : 'X\(//\)[^/]' \| \
30822 X"$ac_file" : 'X\(//\)$' \| \
30823 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30824 $as_echo X"$ac_file" |
30825 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30826 s//\1/
30827 q
30828 }
30829 /^X\(\/\/\)[^/].*/{
30830 s//\1/
30831 q
30832 }
30833 /^X\(\/\/\)$/{
30834 s//\1/
30835 q
30836 }
30837 /^X\(\/\).*/{
30838 s//\1/
30839 q
30840 }
30841 s/.*/./; q'`
30842 as_dir="$ac_dir"; as_fn_mkdir_p
30843 ac_builddir=.
30844
30845 case "$ac_dir" in
30846 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30847 *)
30848 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30849 # A ".." for each directory in $ac_dir_suffix.
30850 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30851 case $ac_top_builddir_sub in
30852 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30853 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30854 esac ;;
30855 esac
30856 ac_abs_top_builddir=$ac_pwd
30857 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30858 # for backward compatibility:
30859 ac_top_builddir=$ac_top_build_prefix
30860
30861 case $srcdir in
30862 .) # We are building in place.
30863 ac_srcdir=.
30864 ac_top_srcdir=$ac_top_builddir_sub
30865 ac_abs_top_srcdir=$ac_pwd ;;
30866 [\\/]* | ?:[\\/]* ) # Absolute name.
30867 ac_srcdir=$srcdir$ac_dir_suffix;
30868 ac_top_srcdir=$srcdir
30869 ac_abs_top_srcdir=$srcdir ;;
30870 *) # Relative name.
30871 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30872 ac_top_srcdir=$ac_top_build_prefix$srcdir
30873 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30874 esac
30875 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30876
30877
30878 case $ac_mode in
30879 :F)
30880 #
30881 # CONFIG_FILE
30882 #
30883
30884 case $INSTALL in
30885 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
30886 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
30887 esac
30888 ac_MKDIR_P=$MKDIR_P
30889 case $MKDIR_P in
30890 [\\/$]* | ?:[\\/]* ) ;;
30891 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30892 esac
30893 _ACEOF
30894
30895 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30896 # If the template does not know about datarootdir, expand it.
30897 # FIXME: This hack should be removed a few years after 2.60.
30898 ac_datarootdir_hack=; ac_datarootdir_seen=
30899 ac_sed_dataroot='
30900 /datarootdir/ {
30901 p
30902 q
30903 }
30904 /@datadir@/p
30905 /@docdir@/p
30906 /@infodir@/p
30907 /@localedir@/p
30908 /@mandir@/p'
30909 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30910 *datarootdir*) ac_datarootdir_seen=yes;;
30911 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30912 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30913 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30914 _ACEOF
30915 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30916 ac_datarootdir_hack='
30917 s&@datadir@&$datadir&g
30918 s&@docdir@&$docdir&g
30919 s&@infodir@&$infodir&g
30920 s&@localedir@&$localedir&g
30921 s&@mandir@&$mandir&g
30922 s&\\\${datarootdir}&$datarootdir&g' ;;
30923 esac
30924 _ACEOF
30925
30926 # Neutralize VPATH when `$srcdir' = `.'.
30927 # Shell code in configure.ac might set extrasub.
30928 # FIXME: do we really want to maintain this feature?
30929 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30930 ac_sed_extra="$ac_vpsub
30931 $extrasub
30932 _ACEOF
30933 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30934 :t
30935 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30936 s|@configure_input@|$ac_sed_conf_input|;t t
30937 s&@top_builddir@&$ac_top_builddir_sub&;t t
30938 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30939 s&@srcdir@&$ac_srcdir&;t t
30940 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30941 s&@top_srcdir@&$ac_top_srcdir&;t t
30942 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30943 s&@builddir@&$ac_builddir&;t t
30944 s&@abs_builddir@&$ac_abs_builddir&;t t
30945 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30946 s&@INSTALL@&$ac_INSTALL&;t t
30947 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30948 $ac_datarootdir_hack
30949 "
30950 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
30951 if $ac_cs_awk_getline; then
30952 $AWK -f "$tmp/subs.awk"
30953 else
30954 $AWK -f "$tmp/subs.awk" | $SHELL
30955 fi >$tmp/out \
30956 || as_fn_error "could not create $ac_file" "$LINENO" 5
30957
30958 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30959 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30960 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30961 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30962 which seems to be undefined. Please make sure it is defined." >&5
30963 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30964 which seems to be undefined. Please make sure it is defined." >&2;}
30965
30966 rm -f "$tmp/stdin"
30967 case $ac_file in
30968 -) cat "$tmp/out" && rm -f "$tmp/out";;
30969 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30970 esac \
30971 || as_fn_error "could not create $ac_file" "$LINENO" 5
30972 ;;
30973 :H)
30974 #
30975 # CONFIG_HEADER
30976 #
30977 if test x"$ac_file" != x-; then
30978 {
30979 $as_echo "/* $configure_input */" \
30980 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30981 } >"$tmp/config.h" \
30982 || as_fn_error "could not create $ac_file" "$LINENO" 5
30983 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30984 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
30985 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30986 else
30987 rm -f "$ac_file"
30988 mv "$tmp/config.h" "$ac_file" \
30989 || as_fn_error "could not create $ac_file" "$LINENO" 5
30990 fi
30991 else
30992 $as_echo "/* $configure_input */" \
30993 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30994 || as_fn_error "could not create -" "$LINENO" 5
30995 fi
30996 # Compute "$ac_file"'s index in $config_headers.
30997 _am_arg="$ac_file"
30998 _am_stamp_count=1
30999 for _am_header in $config_headers :; do
31000 case $_am_header in
31001 $_am_arg | $_am_arg:* )
31002 break ;;
31003 * )
31004 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
31005 esac
31006 done
31007 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
31008 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31009 X"$_am_arg" : 'X\(//\)[^/]' \| \
31010 X"$_am_arg" : 'X\(//\)$' \| \
31011 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
31012 $as_echo X"$_am_arg" |
31013 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31014 s//\1/
31015 q
31016 }
31017 /^X\(\/\/\)[^/].*/{
31018 s//\1/
31019 q
31020 }
31021 /^X\(\/\/\)$/{
31022 s//\1/
31023 q
31024 }
31025 /^X\(\/\).*/{
31026 s//\1/
31027 q
31028 }
31029 s/.*/./; q'`/stamp-h$_am_stamp_count
31030 ;;
31031
31032 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
31033 $as_echo "$as_me: executing $ac_file commands" >&6;}
31034 ;;
31035 esac
31036
31037
31038 case $ac_file$ac_mode in
31039 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
31040 # Autoconf 2.62 quotes --file arguments for eval, but not when files
31041 # are listed without --file. Let's play safe and only enable the eval
31042 # if we detect the quoting.
31043 case $CONFIG_FILES in
31044 *\'*) eval set x "$CONFIG_FILES" ;;
31045 *) set x $CONFIG_FILES ;;
31046 esac
31047 shift
31048 for mf
31049 do
31050 # Strip MF so we end up with the name of the file.
31051 mf=`echo "$mf" | sed -e 's/:.*$//'`
31052 # Check whether this is an Automake generated Makefile or not.
31053 # We used to match only the files named `Makefile.in', but
31054 # some people rename them; so instead we look at the file content.
31055 # Grep'ing the first line is not enough: some people post-process
31056 # each Makefile.in and add a new line on top of each file to say so.
31057 # Grep'ing the whole file is not good either: AIX grep has a line
31058 # limit of 2048, but all sed's we know have understand at least 4000.
31059 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
31060 dirpart=`$as_dirname -- "$mf" ||
31061 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31062 X"$mf" : 'X\(//\)[^/]' \| \
31063 X"$mf" : 'X\(//\)$' \| \
31064 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
31065 $as_echo X"$mf" |
31066 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31067 s//\1/
31068 q
31069 }
31070 /^X\(\/\/\)[^/].*/{
31071 s//\1/
31072 q
31073 }
31074 /^X\(\/\/\)$/{
31075 s//\1/
31076 q
31077 }
31078 /^X\(\/\).*/{
31079 s//\1/
31080 q
31081 }
31082 s/.*/./; q'`
31083 else
31084 continue
31085 fi
31086 # Extract the definition of DEPDIR, am__include, and am__quote
31087 # from the Makefile without running `make'.
31088 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
31089 test -z "$DEPDIR" && continue
31090 am__include=`sed -n 's/^am__include = //p' < "$mf"`
31091 test -z "am__include" && continue
31092 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
31093 # When using ansi2knr, U may be empty or an underscore; expand it
31094 U=`sed -n 's/^U = //p' < "$mf"`
31095 # Find all dependency output files, they are included files with
31096 # $(DEPDIR) in their names. We invoke sed twice because it is the
31097 # simplest approach to changing $(DEPDIR) to its actual value in the
31098 # expansion.
31099 for file in `sed -n "
31100 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
31101 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
31102 # Make sure the directory exists.
31103 test -f "$dirpart/$file" && continue
31104 fdir=`$as_dirname -- "$file" ||
31105 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
31106 X"$file" : 'X\(//\)[^/]' \| \
31107 X"$file" : 'X\(//\)$' \| \
31108 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
31109 $as_echo X"$file" |
31110 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
31111 s//\1/
31112 q
31113 }
31114 /^X\(\/\/\)[^/].*/{
31115 s//\1/
31116 q
31117 }
31118 /^X\(\/\/\)$/{
31119 s//\1/
31120 q
31121 }
31122 /^X\(\/\).*/{
31123 s//\1/
31124 q
31125 }
31126 s/.*/./; q'`
31127 as_dir=$dirpart/$fdir; as_fn_mkdir_p
31128 # echo "creating $dirpart/$file"
31129 echo '# dummy' > "$dirpart/$file"
31130 done
31131 done
31132 }
31133 ;;
31134 "src/epaths.h":C)
31135 if test "${opsys}" = "mingw32"; then
31136 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force-w32
31137 else
31138 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
31139 fi
31140 ;;
31141 "src/.gdbinit":C)
31142 if test ! -f src/.gdbinit && test -f "$srcdir/src/.gdbinit"; then
31143 echo "source $srcdir/src/.gdbinit" > src/.gdbinit
31144 fi
31145 ;;
31146
31147 esac
31148 done # for ac_tag
31149
31150
31151 as_fn_exit 0
31152 _ACEOF
31153 ac_clean_files=$ac_clean_files_save
31154
31155 test $ac_write_fail = 0 ||
31156 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
31157
31158
31159 # configure is writing to config.log, and then calls config.status.
31160 # config.status does its own redirection, appending to config.log.
31161 # Unfortunately, on DOS this fails, as config.log is still kept open
31162 # by configure, so config.status won't be able to write to it; its
31163 # output is simply discarded. So we exec the FD to /dev/null,
31164 # effectively closing config.log, so it can be properly (re)opened and
31165 # appended to by config.status. When coming back to configure, we
31166 # need to make the FD available again.
31167 if test "$no_create" != yes; then
31168 ac_cs_success=:
31169 ac_config_status_args=
31170 test "$silent" = yes &&
31171 ac_config_status_args="$ac_config_status_args --quiet"
31172 exec 5>/dev/null
31173 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
31174 exec 5>>config.log
31175 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
31176 # would make configure fail if this is the last instruction.
31177 $ac_cs_success || as_fn_exit $?
31178 fi
31179 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
31180 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
31181 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
31182 fi
31183