Auto-commit of generated files.
[bpt/emacs.git] / autogen / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.2.50.
4 #
5 #
6 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
7 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software Foundation,
8 # Inc.
9 #
10 #
11 # This configure script is free software; the Free Software Foundation
12 # gives unlimited permission to copy, distribute and modify it.
13 ## -------------------- ##
14 ## M4sh Initialization. ##
15 ## -------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
20 emulate sh
21 NULLCMD=:
22 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23 # is contrary to our usage. Disable this feature.
24 alias -g '${1+"$@"}'='"$@"'
25 setopt NO_GLOB_SUBST
26 else
27 case `(set -o) 2>/dev/null` in #(
28 *posix*) :
29 set -o posix ;; #(
30 *) :
31 ;;
32 esac
33 fi
34
35
36 as_nl='
37 '
38 export as_nl
39 # Printing a long string crashes Solaris 7 /usr/bin/printf.
40 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
41 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
42 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
43 # Prefer a ksh shell builtin over an external printf program on Solaris,
44 # but without wasting forks for bash or zsh.
45 if test -z "$BASH_VERSION$ZSH_VERSION" \
46 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
47 as_echo='print -r --'
48 as_echo_n='print -rn --'
49 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
50 as_echo='printf %s\n'
51 as_echo_n='printf %s'
52 else
53 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
54 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
55 as_echo_n='/usr/ucb/echo -n'
56 else
57 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
58 as_echo_n_body='eval
59 arg=$1;
60 case $arg in #(
61 *"$as_nl"*)
62 expr "X$arg" : "X\\(.*\\)$as_nl";
63 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
64 esac;
65 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
66 '
67 export as_echo_n_body
68 as_echo_n='sh -c $as_echo_n_body as_echo'
69 fi
70 export as_echo_body
71 as_echo='sh -c $as_echo_body as_echo'
72 fi
73
74 # The user is always right.
75 if test "${PATH_SEPARATOR+set}" != set; then
76 PATH_SEPARATOR=:
77 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
78 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
79 PATH_SEPARATOR=';'
80 }
81 fi
82
83
84 # IFS
85 # We need space, tab and new line, in precisely that order. Quoting is
86 # there to prevent editors from complaining about space-tab.
87 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
88 # splitting by setting IFS to empty value.)
89 IFS=" "" $as_nl"
90
91 # Find who we are. Look in the path if we contain no directory separator.
92 case $0 in #((
93 *[\\/]* ) as_myself=$0 ;;
94 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
95 for as_dir in $PATH
96 do
97 IFS=$as_save_IFS
98 test -z "$as_dir" && as_dir=.
99 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
100 done
101 IFS=$as_save_IFS
102
103 ;;
104 esac
105 # We did not find ourselves, most probably we were run as `sh COMMAND'
106 # in which case we are not to be found in the path.
107 if test "x$as_myself" = x; then
108 as_myself=$0
109 fi
110 if test ! -f "$as_myself"; then
111 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
112 exit 1
113 fi
114
115 # Unset variables that we do not need and which cause bugs (e.g. in
116 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
117 # suppresses any "Segmentation fault" message there. '((' could
118 # trigger a bug in pdksh 5.2.14.
119 for as_var in BASH_ENV ENV MAIL MAILPATH
120 do eval test x\${$as_var+set} = xset \
121 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
122 done
123 PS1='$ '
124 PS2='> '
125 PS4='+ '
126
127 # NLS nuisances.
128 LC_ALL=C
129 export LC_ALL
130 LANGUAGE=C
131 export LANGUAGE
132
133 # CDPATH.
134 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
135
136 if test "x$CONFIG_SHELL" = x; then
137 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
138 emulate sh
139 NULLCMD=:
140 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
141 # is contrary to our usage. Disable this feature.
142 alias -g '\${1+\"\$@\"}'='\"\$@\"'
143 setopt NO_GLOB_SUBST
144 else
145 case \`(set -o) 2>/dev/null\` in #(
146 *posix*) :
147 set -o posix ;; #(
148 *) :
149 ;;
150 esac
151 fi
152 "
153 as_required="as_fn_return () { (exit \$1); }
154 as_fn_success () { as_fn_return 0; }
155 as_fn_failure () { as_fn_return 1; }
156 as_fn_ret_success () { return 0; }
157 as_fn_ret_failure () { return 1; }
158
159 exitcode=0
160 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
161 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
162 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
163 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
164 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
165
166 else
167 exitcode=1; echo positional parameters were not saved.
168 fi
169 test x\$exitcode = x0 || exit 1"
170 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
171 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
172 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
173 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
174 test \$(( 1 + 1 )) = 2 || exit 1"
175 if (eval "$as_required") 2>/dev/null; then :
176 as_have_required=yes
177 else
178 as_have_required=no
179 fi
180 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
181
182 else
183 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
184 as_found=false
185 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
186 do
187 IFS=$as_save_IFS
188 test -z "$as_dir" && as_dir=.
189 as_found=:
190 case $as_dir in #(
191 /*)
192 for as_base in sh bash ksh sh5; do
193 # Try only shells that exist, to save several forks.
194 as_shell=$as_dir/$as_base
195 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
196 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
197 CONFIG_SHELL=$as_shell as_have_required=yes
198 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
199 break 2
200 fi
201 fi
202 done;;
203 esac
204 as_found=false
205 done
206 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
207 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
208 CONFIG_SHELL=$SHELL as_have_required=yes
209 fi; }
210 IFS=$as_save_IFS
211
212
213 if test "x$CONFIG_SHELL" != x; then :
214 # We cannot yet assume a decent shell, so we have to provide a
215 # neutralization value for shells without unset; and this also
216 # works around shells that cannot unset nonexistent variables.
217 BASH_ENV=/dev/null
218 ENV=/dev/null
219 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
220 export CONFIG_SHELL
221 exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
222 fi
223
224 if test x$as_have_required = xno; then :
225 $as_echo "$0: This script requires a shell more modern than all"
226 $as_echo "$0: the shells that I found on your system."
227 if test x${ZSH_VERSION+set} = xset ; then
228 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
229 $as_echo "$0: be upgraded to zsh 4.3.4 or later."
230 else
231 $as_echo "$0: Please tell bug-autoconf@gnu.org about your system,
232 $0: including any error possibly output before this
233 $0: message. Then install a modern shell, or manually run
234 $0: the script under such a shell if you do have one."
235 fi
236 exit 1
237 fi
238 fi
239 fi
240 SHELL=${CONFIG_SHELL-/bin/sh}
241 export SHELL
242 # Unset more variables known to interfere with behavior of common tools.
243 CLICOLOR_FORCE= GREP_OPTIONS=
244 unset CLICOLOR_FORCE GREP_OPTIONS
245
246 ## --------------------- ##
247 ## M4sh Shell Functions. ##
248 ## --------------------- ##
249 # as_fn_unset VAR
250 # ---------------
251 # Portably unset VAR.
252 as_fn_unset ()
253 {
254 { eval $1=; unset $1;}
255 }
256 as_unset=as_fn_unset
257
258 # as_fn_set_status STATUS
259 # -----------------------
260 # Set $? to STATUS, without forking.
261 as_fn_set_status ()
262 {
263 return $1
264 } # as_fn_set_status
265
266 # as_fn_exit STATUS
267 # -----------------
268 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
269 as_fn_exit ()
270 {
271 set +e
272 as_fn_set_status $1
273 exit $1
274 } # as_fn_exit
275
276 # as_fn_mkdir_p
277 # -------------
278 # Create "$as_dir" as a directory, including parents if necessary.
279 as_fn_mkdir_p ()
280 {
281
282 case $as_dir in #(
283 -*) as_dir=./$as_dir;;
284 esac
285 test -d "$as_dir" || eval $as_mkdir_p || {
286 as_dirs=
287 while :; do
288 case $as_dir in #(
289 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
290 *) as_qdir=$as_dir;;
291 esac
292 as_dirs="'$as_qdir' $as_dirs"
293 as_dir=`$as_dirname -- "$as_dir" ||
294 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
295 X"$as_dir" : 'X\(//\)[^/]' \| \
296 X"$as_dir" : 'X\(//\)$' \| \
297 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
298 $as_echo X"$as_dir" |
299 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
300 s//\1/
301 q
302 }
303 /^X\(\/\/\)[^/].*/{
304 s//\1/
305 q
306 }
307 /^X\(\/\/\)$/{
308 s//\1/
309 q
310 }
311 /^X\(\/\).*/{
312 s//\1/
313 q
314 }
315 s/.*/./; q'`
316 test -d "$as_dir" && break
317 done
318 test -z "$as_dirs" || eval "mkdir $as_dirs"
319 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
320
321
322 } # as_fn_mkdir_p
323 # as_fn_append VAR VALUE
324 # ----------------------
325 # Append the text in VALUE to the end of the definition contained in VAR. Take
326 # advantage of any shell optimizations that allow amortized linear growth over
327 # repeated appends, instead of the typical quadratic growth present in naive
328 # implementations.
329 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
330 eval 'as_fn_append ()
331 {
332 eval $1+=\$2
333 }'
334 else
335 as_fn_append ()
336 {
337 eval $1=\$$1\$2
338 }
339 fi # as_fn_append
340
341 # as_fn_arith ARG...
342 # ------------------
343 # Perform arithmetic evaluation on the ARGs, and store the result in the
344 # global $as_val. Take advantage of shells that can avoid forks. The arguments
345 # must be portable across $(()) and expr.
346 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
347 eval 'as_fn_arith ()
348 {
349 as_val=$(( $* ))
350 }'
351 else
352 as_fn_arith ()
353 {
354 as_val=`expr "$@" || test $? -eq 1`
355 }
356 fi # as_fn_arith
357
358
359 # as_fn_error ERROR [LINENO LOG_FD]
360 # ---------------------------------
361 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
362 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
363 # script with status $?, using 1 if that was 0.
364 as_fn_error ()
365 {
366 as_status=$?; test $as_status -eq 0 && as_status=1
367 if test "$3"; then
368 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
369 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
370 fi
371 $as_echo "$as_me: error: $1" >&2
372 as_fn_exit $as_status
373 } # as_fn_error
374
375 if expr a : '\(a\)' >/dev/null 2>&1 &&
376 test "X`expr 00001 : '.*\(...\)'`" = X001; then
377 as_expr=expr
378 else
379 as_expr=false
380 fi
381
382 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
383 as_basename=basename
384 else
385 as_basename=false
386 fi
387
388 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
389 as_dirname=dirname
390 else
391 as_dirname=false
392 fi
393
394 as_me=`$as_basename -- "$0" ||
395 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
396 X"$0" : 'X\(//\)$' \| \
397 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
398 $as_echo X/"$0" |
399 sed '/^.*\/\([^/][^/]*\)\/*$/{
400 s//\1/
401 q
402 }
403 /^X\/\(\/\/\)$/{
404 s//\1/
405 q
406 }
407 /^X\/\(\/\).*/{
408 s//\1/
409 q
410 }
411 s/.*/./; q'`
412
413 # Avoid depending upon Character Ranges.
414 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
415 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
416 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
417 as_cr_digits='0123456789'
418 as_cr_alnum=$as_cr_Letters$as_cr_digits
419
420
421 as_lineno_1=$LINENO as_lineno_1a=$LINENO
422 as_lineno_2=$LINENO as_lineno_2a=$LINENO
423 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
424 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
425 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
426 sed -n '
427 p
428 /[$]LINENO/=
429 ' <$as_myself |
430 sed '
431 s/[$]LINENO.*/&-/
432 t lineno
433 b
434 :lineno
435 N
436 :loop
437 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
438 t loop
439 s/-\n.*//
440 ' >$as_me.lineno &&
441 chmod +x "$as_me.lineno" ||
442 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
443
444 # Don't try to exec as it changes $[0], causing all sort of problems
445 # (the dirname of $[0] is not the place where we might find the
446 # original and so on. Autoconf is especially sensitive to this).
447 . "./$as_me.lineno"
448 # Exit status is that of the last command.
449 exit
450 }
451
452 ECHO_C= ECHO_N= ECHO_T=
453 case `echo -n x` in #(((((
454 -n*)
455 case `echo 'xy\c'` in
456 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
457 xy) ECHO_C='\c';;
458 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
459 ECHO_T=' ';;
460 esac;;
461 *)
462 ECHO_N='-n';;
463 esac
464
465 rm -f conf$$ conf$$.exe conf$$.file
466 if test -d conf$$.dir; then
467 rm -f conf$$.dir/conf$$.file
468 else
469 rm -f conf$$.dir
470 mkdir conf$$.dir 2>/dev/null
471 fi
472 if (echo >conf$$.file) 2>/dev/null; then
473 if ln -s conf$$.file conf$$ 2>/dev/null; then
474 as_ln_s='ln -s'
475 # ... but there are two gotchas:
476 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
477 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
478 # In both cases, we have to default to `cp -p'.
479 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
480 as_ln_s='cp -p'
481 elif ln conf$$.file conf$$ 2>/dev/null; then
482 as_ln_s=ln
483 else
484 as_ln_s='cp -p'
485 fi
486 else
487 as_ln_s='cp -p'
488 fi
489 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
490 rmdir conf$$.dir 2>/dev/null
491
492 if mkdir -p . 2>/dev/null; then
493 as_mkdir_p='mkdir -p "$as_dir"'
494 else
495 test -d ./-p && rmdir ./-p
496 as_mkdir_p=false
497 fi
498
499 if test -x / >/dev/null 2>&1; then
500 as_test_x='test -x'
501 else
502 if ls -dL / >/dev/null 2>&1; then
503 as_ls_L_option=L
504 else
505 as_ls_L_option=
506 fi
507 as_test_x='
508 eval sh -c '\''
509 if test -d "$1"; then
510 test -d "$1/.";
511 else
512 case $1 in #(
513 -*)set "./$1";;
514 esac;
515 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
516 ???[sx]*):;;*)false;;esac;fi
517 '\'' sh
518 '
519 fi
520 as_executable_p=$as_test_x
521
522 # Sed expression to map a string onto a valid CPP name.
523 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
524
525 # Sed expression to map a string onto a valid variable name.
526 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
527
528
529 test -n "$DJDIR" || exec 7<&0 </dev/null
530 exec 6>&1
531
532 # Name of the host.
533 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
534 # so uname gets run too.
535 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
536
537 #
538 # Initializations.
539 #
540 ac_default_prefix=/usr/local
541 ac_clean_files=
542 ac_config_libobj_dir=.
543 LIBOBJS=
544 cross_compiling=no
545 subdirs=
546 MFLAGS=
547 MAKEFLAGS=
548
549 # Identity of this package.
550 PACKAGE_NAME='emacs'
551 PACKAGE_TARNAME='emacs'
552 PACKAGE_VERSION='24.2.50'
553 PACKAGE_STRING='emacs 24.2.50'
554 PACKAGE_BUGREPORT=''
555 PACKAGE_URL=''
556
557 ac_unique_file="src/lisp.h"
558 # Factoring default headers for most tests.
559 ac_includes_default="\
560 #include <stdio.h>
561 #ifdef HAVE_SYS_TYPES_H
562 # include <sys/types.h>
563 #endif
564 #ifdef HAVE_SYS_STAT_H
565 # include <sys/stat.h>
566 #endif
567 #ifdef STDC_HEADERS
568 # include <stdlib.h>
569 # include <stddef.h>
570 #else
571 # ifdef HAVE_STDLIB_H
572 # include <stdlib.h>
573 # endif
574 #endif
575 #ifdef HAVE_STRING_H
576 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
577 # include <memory.h>
578 # endif
579 # include <string.h>
580 #endif
581 #ifdef HAVE_STRINGS_H
582 # include <strings.h>
583 #endif
584 #ifdef HAVE_INTTYPES_H
585 # include <inttypes.h>
586 #endif
587 #ifdef HAVE_STDINT_H
588 # include <stdint.h>
589 #endif
590 #ifdef HAVE_UNISTD_H
591 # include <unistd.h>
592 #endif"
593
594 ac_header_list=
595 ac_func_list=
596 gl_getopt_required=POSIX
597 gl_getopt_required=POSIX
598 ac_subst_vars='gltests_LTLIBOBJS
599 gltests_LIBOBJS
600 gl_LTLIBOBJS
601 gl_LIBOBJS
602 am__EXEEXT_FALSE
603 am__EXEEXT_TRUE
604 LTLIBOBJS
605 LIBOBJS
606 SUBDIR_MAKEFILES_IN
607 WINDOW_SYSTEM_OBJ
608 LIB_GCC
609 LD_FIRSTFLAG
610 LD_SWITCH_SYSTEM_TEMACS
611 LIBGNU_LTLIBDEPS
612 LIBGNU_LIBDEPS
613 gltests_WITNESS
614 gl_GNULIB_ENABLED_verify_FALSE
615 gl_GNULIB_ENABLED_verify_TRUE
616 gl_GNULIB_ENABLED_strtoull_FALSE
617 gl_GNULIB_ENABLED_strtoull_TRUE
618 gl_GNULIB_ENABLED_strtoll_FALSE
619 gl_GNULIB_ENABLED_strtoll_TRUE
620 gl_GNULIB_ENABLED_stat_FALSE
621 gl_GNULIB_ENABLED_stat_TRUE
622 gl_GNULIB_ENABLED_pathmax_FALSE
623 gl_GNULIB_ENABLED_pathmax_TRUE
624 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
625 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
626 gl_GNULIB_ENABLED_dosname_FALSE
627 gl_GNULIB_ENABLED_dosname_TRUE
628 LTLIBINTL
629 LIBINTL
630 WINDOWS_64_BIT_OFF_T
631 HAVE_UNISTD_H
632 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
633 NEXT_UNISTD_H
634 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
635 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
636 TIME_H_DEFINES_STRUCT_TIMESPEC
637 NEXT_AS_FIRST_DIRECTIVE_TIME_H
638 NEXT_TIME_H
639 WINDOWS_64_BIT_ST_SIZE
640 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
641 NEXT_SYS_STAT_H
642 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
643 NEXT_STDLIB_H
644 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
645 NEXT_STDIO_H
646 REPLACE_VSPRINTF
647 REPLACE_VSNPRINTF
648 REPLACE_VPRINTF
649 REPLACE_VFPRINTF
650 REPLACE_VDPRINTF
651 REPLACE_VASPRINTF
652 REPLACE_TMPFILE
653 REPLACE_STDIO_WRITE_FUNCS
654 REPLACE_STDIO_READ_FUNCS
655 REPLACE_SPRINTF
656 REPLACE_SNPRINTF
657 REPLACE_RENAMEAT
658 REPLACE_RENAME
659 REPLACE_REMOVE
660 REPLACE_PRINTF
661 REPLACE_POPEN
662 REPLACE_PERROR
663 REPLACE_OBSTACK_PRINTF
664 REPLACE_GETLINE
665 REPLACE_GETDELIM
666 REPLACE_FTELLO
667 REPLACE_FTELL
668 REPLACE_FSEEKO
669 REPLACE_FSEEK
670 REPLACE_FREOPEN
671 REPLACE_FPURGE
672 REPLACE_FPRINTF
673 REPLACE_FOPEN
674 REPLACE_FFLUSH
675 REPLACE_FDOPEN
676 REPLACE_FCLOSE
677 REPLACE_DPRINTF
678 HAVE_VDPRINTF
679 HAVE_VASPRINTF
680 HAVE_RENAMEAT
681 HAVE_POPEN
682 HAVE_PCLOSE
683 HAVE_FTELLO
684 HAVE_FSEEKO
685 HAVE_DPRINTF
686 HAVE_DECL_VSNPRINTF
687 HAVE_DECL_SNPRINTF
688 HAVE_DECL_OBSTACK_PRINTF
689 HAVE_DECL_GETLINE
690 HAVE_DECL_GETDELIM
691 HAVE_DECL_FTELLO
692 HAVE_DECL_FSEEKO
693 HAVE_DECL_FPURGE
694 GNULIB_VSPRINTF_POSIX
695 GNULIB_VSNPRINTF
696 GNULIB_VPRINTF_POSIX
697 GNULIB_VPRINTF
698 GNULIB_VFPRINTF_POSIX
699 GNULIB_VFPRINTF
700 GNULIB_VDPRINTF
701 GNULIB_VSCANF
702 GNULIB_VFSCANF
703 GNULIB_VASPRINTF
704 GNULIB_TMPFILE
705 GNULIB_STDIO_H_SIGPIPE
706 GNULIB_STDIO_H_NONBLOCKING
707 GNULIB_SPRINTF_POSIX
708 GNULIB_SNPRINTF
709 GNULIB_SCANF
710 GNULIB_RENAMEAT
711 GNULIB_RENAME
712 GNULIB_REMOVE
713 GNULIB_PUTS
714 GNULIB_PUTCHAR
715 GNULIB_PUTC
716 GNULIB_PRINTF_POSIX
717 GNULIB_PRINTF
718 GNULIB_POPEN
719 GNULIB_PERROR
720 GNULIB_PCLOSE
721 GNULIB_OBSTACK_PRINTF_POSIX
722 GNULIB_OBSTACK_PRINTF
723 GNULIB_GETLINE
724 GNULIB_GETDELIM
725 GNULIB_GETCHAR
726 GNULIB_GETC
727 GNULIB_FWRITE
728 GNULIB_FTELLO
729 GNULIB_FTELL
730 GNULIB_FSEEKO
731 GNULIB_FSEEK
732 GNULIB_FSCANF
733 GNULIB_FREOPEN
734 GNULIB_FREAD
735 GNULIB_FPUTS
736 GNULIB_FPUTC
737 GNULIB_FPURGE
738 GNULIB_FPRINTF_POSIX
739 GNULIB_FPRINTF
740 GNULIB_FOPEN
741 GNULIB_FGETS
742 GNULIB_FGETC
743 GNULIB_FFLUSH
744 GNULIB_FDOPEN
745 GNULIB_FCLOSE
746 GNULIB_DPRINTF
747 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
748 NEXT_STDDEF_H
749 GL_GENERATE_STDDEF_H_FALSE
750 GL_GENERATE_STDDEF_H_TRUE
751 STDDEF_H
752 HAVE_WCHAR_T
753 REPLACE_NULL
754 HAVE__BOOL
755 GL_GENERATE_STDBOOL_H_FALSE
756 GL_GENERATE_STDBOOL_H_TRUE
757 STDBOOL_H
758 GL_GENERATE_STDARG_H_FALSE
759 GL_GENERATE_STDARG_H_TRUE
760 STDARG_H
761 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
762 NEXT_STDARG_H
763 GL_GENERATE_STDALIGN_H_FALSE
764 GL_GENERATE_STDALIGN_H_TRUE
765 STDALIGN_H
766 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
767 NEXT_SIGNAL_H
768 LIB_PTHREAD_SIGMASK
769 REPLACE_RAISE
770 REPLACE_PTHREAD_SIGMASK
771 HAVE_SIGHANDLER_T
772 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
773 HAVE_STRUCT_SIGACTION_SA_SIGACTION
774 HAVE_SIGACTION
775 HAVE_SIGINFO_T
776 HAVE_SIGSET_T
777 HAVE_RAISE
778 HAVE_PTHREAD_SIGMASK
779 HAVE_POSIX_SIGNALBLOCKING
780 GNULIB_SIGACTION
781 GNULIB_SIGPROCMASK
782 GNULIB_SIGNAL_H_SIGPIPE
783 GNULIB_RAISE
784 GNULIB_PTHREAD_SIGMASK
785 HAVE_SYS_SELECT_H
786 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H
787 NEXT_SYS_SELECT_H
788 REPLACE_SELECT
789 REPLACE_PSELECT
790 HAVE_PSELECT
791 GNULIB_SELECT
792 GNULIB_PSELECT
793 REPLACE_TIMEGM
794 REPLACE_NANOSLEEP
795 REPLACE_MKTIME
796 REPLACE_LOCALTIME_R
797 HAVE_TIMEGM
798 HAVE_STRPTIME
799 HAVE_NANOSLEEP
800 HAVE_DECL_LOCALTIME_R
801 GNULIB_TIME_R
802 GNULIB_TIMEGM
803 GNULIB_STRPTIME
804 GNULIB_NANOSLEEP
805 GNULIB_MKTIME
806 REPLACE_UTIMENSAT
807 REPLACE_STAT
808 REPLACE_MKNOD
809 REPLACE_MKFIFO
810 REPLACE_MKDIR
811 REPLACE_LSTAT
812 REPLACE_FUTIMENS
813 REPLACE_FSTATAT
814 REPLACE_FSTAT
815 HAVE_UTIMENSAT
816 HAVE_MKNODAT
817 HAVE_MKNOD
818 HAVE_MKFIFOAT
819 HAVE_MKFIFO
820 HAVE_MKDIRAT
821 HAVE_LSTAT
822 HAVE_LCHMOD
823 HAVE_FUTIMENS
824 HAVE_FSTATAT
825 HAVE_FCHMODAT
826 GNULIB_UTIMENSAT
827 GNULIB_STAT
828 GNULIB_MKNODAT
829 GNULIB_MKNOD
830 GNULIB_MKFIFOAT
831 GNULIB_MKFIFO
832 GNULIB_MKDIRAT
833 GNULIB_LSTAT
834 GNULIB_LCHMOD
835 GNULIB_FUTIMENS
836 GNULIB_FSTATAT
837 GNULIB_FSTAT
838 GNULIB_FCHMODAT
839 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
840 NEXT_INTTYPES_H
841 UINT64_MAX_EQ_ULONG_MAX
842 UINT32_MAX_LT_UINTMAX_MAX
843 PRIPTR_PREFIX
844 PRI_MACROS_BROKEN
845 INT64_MAX_EQ_LONG_MAX
846 INT32_MAX_LT_INTMAX_MAX
847 REPLACE_STRTOIMAX
848 HAVE_DECL_STRTOUMAX
849 HAVE_DECL_STRTOIMAX
850 HAVE_DECL_IMAXDIV
851 HAVE_DECL_IMAXABS
852 GNULIB_STRTOUMAX
853 GNULIB_STRTOIMAX
854 GNULIB_IMAXDIV
855 GNULIB_IMAXABS
856 GL_GENERATE_STDINT_H_FALSE
857 GL_GENERATE_STDINT_H_TRUE
858 STDINT_H
859 WINT_T_SUFFIX
860 WCHAR_T_SUFFIX
861 SIG_ATOMIC_T_SUFFIX
862 SIZE_T_SUFFIX
863 PTRDIFF_T_SUFFIX
864 HAVE_SIGNED_WINT_T
865 HAVE_SIGNED_WCHAR_T
866 HAVE_SIGNED_SIG_ATOMIC_T
867 BITSIZEOF_WINT_T
868 BITSIZEOF_WCHAR_T
869 BITSIZEOF_SIG_ATOMIC_T
870 BITSIZEOF_SIZE_T
871 BITSIZEOF_PTRDIFF_T
872 APPLE_UNIVERSAL_BUILD
873 HAVE_SYS_BITYPES_H
874 HAVE_SYS_INTTYPES_H
875 HAVE_STDINT_H
876 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
877 NEXT_STDINT_H
878 HAVE_SYS_TYPES_H
879 HAVE_INTTYPES_H
880 HAVE_WCHAR_H
881 HAVE_UNSIGNED_LONG_LONG_INT
882 HAVE_LONG_LONG_INT
883 HAVE_WINSOCK2_H
884 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H
885 NEXT_SYS_TIME_H
886 REPLACE_STRUCT_TIMEVAL
887 REPLACE_GETTIMEOFDAY
888 HAVE_SYS_TIME_H
889 HAVE_STRUCT_TIMEVAL
890 HAVE_GETTIMEOFDAY
891 GNULIB_GETTIMEOFDAY
892 GNULIB_GL_UNISTD_H_GETOPT
893 GETOPT_H
894 HAVE_GETOPT_H
895 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
896 NEXT_GETOPT_H
897 PRAGMA_COLUMNS
898 PRAGMA_SYSTEM_HEADER
899 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
900 INCLUDE_NEXT
901 GETLOADAVG_LIBS
902 REPLACE_WCTOMB
903 REPLACE_UNSETENV
904 REPLACE_STRTOD
905 REPLACE_SETENV
906 REPLACE_REALPATH
907 REPLACE_REALLOC
908 REPLACE_RANDOM_R
909 REPLACE_PUTENV
910 REPLACE_PTSNAME_R
911 REPLACE_MKSTEMP
912 REPLACE_MBTOWC
913 REPLACE_MALLOC
914 REPLACE_CANONICALIZE_FILE_NAME
915 REPLACE_CALLOC
916 HAVE_DECL_UNSETENV
917 HAVE_UNLOCKPT
918 HAVE_SYS_LOADAVG_H
919 HAVE_STRUCT_RANDOM_DATA
920 HAVE_STRTOULL
921 HAVE_STRTOLL
922 HAVE_STRTOD
923 HAVE_DECL_SETENV
924 HAVE_SETENV
925 HAVE_RPMATCH
926 HAVE_REALPATH
927 HAVE_RANDOM_R
928 HAVE_RANDOM_H
929 HAVE_RANDOM
930 HAVE_PTSNAME_R
931 HAVE_PTSNAME
932 HAVE_POSIX_OPENPT
933 HAVE_MKSTEMPS
934 HAVE_MKSTEMP
935 HAVE_MKOSTEMPS
936 HAVE_MKOSTEMP
937 HAVE_MKDTEMP
938 HAVE_GRANTPT
939 HAVE_GETSUBOPT
940 HAVE_DECL_GETLOADAVG
941 HAVE_CANONICALIZE_FILE_NAME
942 HAVE_ATOLL
943 HAVE__EXIT
944 GNULIB_WCTOMB
945 GNULIB_UNSETENV
946 GNULIB_UNLOCKPT
947 GNULIB_SYSTEM_POSIX
948 GNULIB_STRTOULL
949 GNULIB_STRTOLL
950 GNULIB_STRTOD
951 GNULIB_SETENV
952 GNULIB_RPMATCH
953 GNULIB_REALPATH
954 GNULIB_REALLOC_POSIX
955 GNULIB_RANDOM_R
956 GNULIB_RANDOM
957 GNULIB_PUTENV
958 GNULIB_PTSNAME_R
959 GNULIB_PTSNAME
960 GNULIB_POSIX_OPENPT
961 GNULIB_MKSTEMPS
962 GNULIB_MKSTEMP
963 GNULIB_MKOSTEMPS
964 GNULIB_MKOSTEMP
965 GNULIB_MKDTEMP
966 GNULIB_MBTOWC
967 GNULIB_MALLOC_POSIX
968 GNULIB_GRANTPT
969 GNULIB_GETSUBOPT
970 GNULIB_GETLOADAVG
971 GNULIB_CANONICALIZE_FILE_NAME
972 GNULIB_CALLOC_POSIX
973 GNULIB_ATOLL
974 GNULIB__EXIT
975 GL_GENERATE_EXECINFO_H_FALSE
976 GL_GENERATE_EXECINFO_H_TRUE
977 LIB_EXECINFO
978 EXECINFO_H
979 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
980 UNISTD_H_HAVE_WINSOCK2_H
981 REPLACE_WRITE
982 REPLACE_USLEEP
983 REPLACE_UNLINKAT
984 REPLACE_UNLINK
985 REPLACE_TTYNAME_R
986 REPLACE_SYMLINK
987 REPLACE_SLEEP
988 REPLACE_RMDIR
989 REPLACE_READLINK
990 REPLACE_READ
991 REPLACE_PWRITE
992 REPLACE_PREAD
993 REPLACE_LSEEK
994 REPLACE_LINKAT
995 REPLACE_LINK
996 REPLACE_LCHOWN
997 REPLACE_ISATTY
998 REPLACE_GETPAGESIZE
999 REPLACE_GETGROUPS
1000 REPLACE_GETLOGIN_R
1001 REPLACE_GETDOMAINNAME
1002 REPLACE_GETCWD
1003 REPLACE_FTRUNCATE
1004 REPLACE_FCHOWNAT
1005 REPLACE_DUP2
1006 REPLACE_DUP
1007 REPLACE_CLOSE
1008 REPLACE_CHOWN
1009 HAVE_SYS_PARAM_H
1010 HAVE_OS_H
1011 HAVE_DECL_TTYNAME_R
1012 HAVE_DECL_SETHOSTNAME
1013 HAVE_DECL_GETUSERSHELL
1014 HAVE_DECL_GETPAGESIZE
1015 HAVE_DECL_GETLOGIN_R
1016 HAVE_DECL_GETDOMAINNAME
1017 HAVE_DECL_FDATASYNC
1018 HAVE_DECL_FCHDIR
1019 HAVE_DECL_ENVIRON
1020 HAVE_USLEEP
1021 HAVE_UNLINKAT
1022 HAVE_SYMLINKAT
1023 HAVE_SYMLINK
1024 HAVE_SLEEP
1025 HAVE_SETHOSTNAME
1026 HAVE_READLINKAT
1027 HAVE_READLINK
1028 HAVE_PWRITE
1029 HAVE_PREAD
1030 HAVE_PIPE2
1031 HAVE_PIPE
1032 HAVE_LINKAT
1033 HAVE_LINK
1034 HAVE_LCHOWN
1035 HAVE_GROUP_MEMBER
1036 HAVE_GETPAGESIZE
1037 HAVE_GETLOGIN
1038 HAVE_GETHOSTNAME
1039 HAVE_GETGROUPS
1040 HAVE_GETDTABLESIZE
1041 HAVE_FTRUNCATE
1042 HAVE_FSYNC
1043 HAVE_FDATASYNC
1044 HAVE_FCHOWNAT
1045 HAVE_FCHDIR
1046 HAVE_FACCESSAT
1047 HAVE_EUIDACCESS
1048 HAVE_DUP3
1049 HAVE_DUP2
1050 HAVE_CHOWN
1051 GNULIB_WRITE
1052 GNULIB_USLEEP
1053 GNULIB_UNLINKAT
1054 GNULIB_UNLINK
1055 GNULIB_UNISTD_H_SIGPIPE
1056 GNULIB_UNISTD_H_NONBLOCKING
1057 GNULIB_TTYNAME_R
1058 GNULIB_SYMLINKAT
1059 GNULIB_SYMLINK
1060 GNULIB_SLEEP
1061 GNULIB_SETHOSTNAME
1062 GNULIB_RMDIR
1063 GNULIB_READLINKAT
1064 GNULIB_READLINK
1065 GNULIB_READ
1066 GNULIB_PWRITE
1067 GNULIB_PREAD
1068 GNULIB_PIPE2
1069 GNULIB_PIPE
1070 GNULIB_LSEEK
1071 GNULIB_LINKAT
1072 GNULIB_LINK
1073 GNULIB_LCHOWN
1074 GNULIB_ISATTY
1075 GNULIB_GROUP_MEMBER
1076 GNULIB_GETUSERSHELL
1077 GNULIB_GETPAGESIZE
1078 GNULIB_GETLOGIN_R
1079 GNULIB_GETLOGIN
1080 GNULIB_GETHOSTNAME
1081 GNULIB_GETGROUPS
1082 GNULIB_GETDTABLESIZE
1083 GNULIB_GETDOMAINNAME
1084 GNULIB_GETCWD
1085 GNULIB_FTRUNCATE
1086 GNULIB_FSYNC
1087 GNULIB_FDATASYNC
1088 GNULIB_FCHOWNAT
1089 GNULIB_FCHDIR
1090 GNULIB_FACCESSAT
1091 GNULIB_EUIDACCESS
1092 GNULIB_ENVIRON
1093 GNULIB_DUP3
1094 GNULIB_DUP2
1095 GNULIB_DUP
1096 GNULIB_CLOSE
1097 GNULIB_CHOWN
1098 GNULIB_CHDIR
1099 LIB_CLOCK_GETTIME
1100 GL_GENERATE_ALLOCA_H_FALSE
1101 GL_GENERATE_ALLOCA_H_TRUE
1102 ALLOCA_H
1103 ALLOCA
1104 GL_COND_LIBTOOL_FALSE
1105 GL_COND_LIBTOOL_TRUE
1106 POST_ALLOC_OBJ
1107 PRE_ALLOC_OBJ
1108 CYGWIN_OBJ
1109 RALLOC_OBJ
1110 OLDXMENU_DEPS
1111 LIBX_OTHER
1112 LIBXMENU
1113 OLDXMENU
1114 OLDXMENU_TARGET
1115 LIBXT_OTHER
1116 TOOLKIT_LIBW
1117 WIDGET_OBJ
1118 XOBJ
1119 XMENU_OBJ
1120 FONT_OBJ
1121 OTHER_FILES
1122 GNU_OBJC_CFLAGS
1123 ns_appsrc
1124 ns_appresdir
1125 ns_appbindir
1126 ns_appdir
1127 X_TOOLKIT_TYPE
1128 GNUSTEP_CFLAGS
1129 C_SWITCH_X_SITE
1130 LD_SWITCH_X_SITE
1131 gameuser
1132 gamedir
1133 bitmapdir
1134 archlibdir
1135 etcdir
1136 x_default_search_path
1137 lisppath
1138 locallisppath
1139 standardlisppath
1140 leimdir
1141 lispdir
1142 srcdir
1143 canonical
1144 configuration
1145 version
1146 copyright
1147 KRB4LIB
1148 DESLIB
1149 KRB5LIB
1150 CRYPTOLIB
1151 COM_ERRLIB
1152 LIBRESOLV
1153 LIBHESIOD
1154 TERMCAP_OBJ
1155 LIBS_TERMCAP
1156 BLESSMAIL_TARGET
1157 LIBS_MAIL
1158 liblockfile
1159 LIBXML2_LIBS
1160 LIBXML2_CFLAGS
1161 LIBXSM
1162 LIBGPM
1163 LIBGIF
1164 LIBTIFF
1165 LIBPNG
1166 LIBJPEG
1167 LIBXPM
1168 M17N_FLT_LIBS
1169 M17N_FLT_CFLAGS
1170 LIBOTF_LIBS
1171 LIBOTF_CFLAGS
1172 FREETYPE_LIBS
1173 FREETYPE_CFLAGS
1174 XFT_LIBS
1175 XFT_CFLAGS
1176 FONTCONFIG_LIBS
1177 FONTCONFIG_CFLAGS
1178 LIBXMU
1179 LIBXTR6
1180 LIBGNUTLS_LIBS
1181 LIBGNUTLS_CFLAGS
1182 LIBSELINUX_LIBS
1183 SETTINGS_LIBS
1184 SETTINGS_CFLAGS
1185 GOBJECT_LIBS
1186 GOBJECT_CFLAGS
1187 GCONF_LIBS
1188 GCONF_CFLAGS
1189 GSETTINGS_LIBS
1190 GSETTINGS_CFLAGS
1191 DBUS_OBJ
1192 DBUS_LIBS
1193 DBUS_CFLAGS
1194 GTK_OBJ
1195 GTK_LIBS
1196 GTK_CFLAGS
1197 IMAGEMAGICK_LIBS
1198 IMAGEMAGICK_CFLAGS
1199 RSVG_LIBS
1200 RSVG_CFLAGS
1201 LIB_PTHREAD
1202 VMLIMIT_OBJ
1203 GMALLOC_OBJ
1204 HAVE_XSERVER
1205 LIB_STANDARD
1206 NS_OBJC_OBJ
1207 NS_OBJ
1208 ns_self_contained
1209 INSTALL_ARCH_INDEP_EXTRA
1210 TEMACS_LDFLAGS2
1211 LD_SWITCH_X_SITE_RPATH
1212 XMKMF
1213 DEPFLAGS
1214 MKDEPDIR
1215 CFLAGS_SOUND
1216 ALSA_LIBS
1217 ALSA_CFLAGS
1218 LIBSOUND
1219 PKG_CONFIG
1220 CRT_DIR
1221 START_FILES
1222 LIB_MATH
1223 LIBS_SYSTEM
1224 C_SWITCH_SYSTEM
1225 UNEXEC_OBJ
1226 C_SWITCH_MACHINE
1227 LD_SWITCH_SYSTEM
1228 CANNOT_DUMP
1229 INFO_OPTS
1230 INFO_EXT
1231 HAVE_MAKEINFO
1232 PAXCTL
1233 GZIP_PROG
1234 INSTALL_INFO
1235 LN_S
1236 GNULIB_WARN_CFLAGS
1237 WARN_CFLAGS
1238 WERROR_CFLAGS
1239 RANLIB
1240 ARFLAGS
1241 AR
1242 EGREP
1243 GREP
1244 CPP
1245 am__fastdepCC_FALSE
1246 am__fastdepCC_TRUE
1247 CCDEPMODE
1248 AMDEPBACKSLASH
1249 AMDEP_FALSE
1250 AMDEP_TRUE
1251 am__quote
1252 am__include
1253 DEPDIR
1254 OBJEXT
1255 EXEEXT
1256 ac_ct_CC
1257 CPPFLAGS
1258 LDFLAGS
1259 CFLAGS
1260 CC
1261 host_os
1262 host_vendor
1263 host_cpu
1264 host
1265 build_os
1266 build_vendor
1267 build_cpu
1268 build
1269 PROFILING_CFLAGS
1270 GZIP_INFO
1271 cache_file
1272 am__untar
1273 am__tar
1274 AMTAR
1275 am__leading_dot
1276 SET_MAKE
1277 AWK
1278 mkdir_p
1279 MKDIR_P
1280 INSTALL_STRIP_PROGRAM
1281 STRIP
1282 install_sh
1283 MAKEINFO
1284 AUTOHEADER
1285 AUTOMAKE
1286 AUTOCONF
1287 ACLOCAL
1288 VERSION
1289 PACKAGE
1290 CYGPATH_W
1291 am__isrc
1292 INSTALL_DATA
1293 INSTALL_SCRIPT
1294 INSTALL_PROGRAM
1295 target_alias
1296 host_alias
1297 build_alias
1298 LIBS
1299 ECHO_T
1300 ECHO_N
1301 ECHO_C
1302 DEFS
1303 mandir
1304 localedir
1305 libdir
1306 psdir
1307 pdfdir
1308 dvidir
1309 htmldir
1310 infodir
1311 docdir
1312 oldincludedir
1313 includedir
1314 localstatedir
1315 sharedstatedir
1316 sysconfdir
1317 datadir
1318 datarootdir
1319 libexecdir
1320 sbindir
1321 bindir
1322 program_transform_name
1323 prefix
1324 exec_prefix
1325 PACKAGE_URL
1326 PACKAGE_BUGREPORT
1327 PACKAGE_STRING
1328 PACKAGE_VERSION
1329 PACKAGE_TARNAME
1330 PACKAGE_NAME
1331 PATH_SEPARATOR
1332 SHELL'
1333 ac_subst_files='deps_frag
1334 lisp_frag'
1335 ac_user_opts='
1336 enable_option_checking
1337 with_all
1338 with_pop
1339 with_kerberos
1340 with_kerberos5
1341 with_hesiod
1342 with_mmdf
1343 with_mail_unlink
1344 with_mailhost
1345 with_sound
1346 with_x_toolkit
1347 with_wide_int
1348 with_xpm
1349 with_jpeg
1350 with_tiff
1351 with_gif
1352 with_png
1353 with_rsvg
1354 with_xml2
1355 with_imagemagick
1356 with_xft
1357 with_libotf
1358 with_m17n_flt
1359 with_toolkit_scroll_bars
1360 with_xaw3d
1361 with_xim
1362 with_ns
1363 with_gpm
1364 with_dbus
1365 with_gconf
1366 with_gsettings
1367 with_selinux
1368 with_gnutls
1369 with_makeinfo
1370 with_compress_info
1371 with_pkg_config_prog
1372 with_crt_dir
1373 with_gameuser
1374 with_gnustep_conf
1375 enable_ns_self_contained
1376 enable_locallisppath
1377 enable_checking
1378 enable_check_lisp_object_type
1379 enable_profiling
1380 enable_autodepend
1381 enable_dependency_tracking
1382 enable_largefile
1383 enable_gcc_warnings
1384 enable_link_time_optimization
1385 with_x
1386 '
1387 ac_precious_vars='build_alias
1388 host_alias
1389 target_alias
1390 CC
1391 CFLAGS
1392 LDFLAGS
1393 LIBS
1394 CPPFLAGS
1395 CPP
1396 XMKMF'
1397
1398
1399 # Initialize some variables set by options.
1400 ac_init_help=
1401 ac_init_version=false
1402 ac_unrecognized_opts=
1403 ac_unrecognized_sep=
1404 # The variables have the same names as the options, with
1405 # dashes changed to underlines.
1406 cache_file=/dev/null
1407 exec_prefix=NONE
1408 no_create=
1409 no_recursion=
1410 prefix=NONE
1411 program_prefix=NONE
1412 program_suffix=NONE
1413 program_transform_name=s,x,x,
1414 silent=
1415 site=
1416 srcdir=
1417 verbose=
1418 x_includes=NONE
1419 x_libraries=NONE
1420
1421 # Installation directory options.
1422 # These are left unexpanded so users can "make install exec_prefix=/foo"
1423 # and all the variables that are supposed to be based on exec_prefix
1424 # by default will actually change.
1425 # Use braces instead of parens because sh, perl, etc. also accept them.
1426 # (The list follows the same order as the GNU Coding Standards.)
1427 bindir='${exec_prefix}/bin'
1428 sbindir='${exec_prefix}/sbin'
1429 libexecdir='${exec_prefix}/libexec'
1430 datarootdir='${prefix}/share'
1431 datadir='${datarootdir}'
1432 sysconfdir='${prefix}/etc'
1433 sharedstatedir='${prefix}/com'
1434 localstatedir='${prefix}/var'
1435 includedir='${prefix}/include'
1436 oldincludedir='/usr/include'
1437 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1438 infodir='${datarootdir}/info'
1439 htmldir='${docdir}'
1440 dvidir='${docdir}'
1441 pdfdir='${docdir}'
1442 psdir='${docdir}'
1443 libdir='${exec_prefix}/lib'
1444 localedir='${datarootdir}/locale'
1445 mandir='${datarootdir}/man'
1446
1447 ac_prev=
1448 ac_dashdash=
1449 for ac_option
1450 do
1451 # If the previous option needs an argument, assign it.
1452 if test -n "$ac_prev"; then
1453 eval $ac_prev=\$ac_option
1454 ac_prev=
1455 continue
1456 fi
1457
1458 case $ac_option in
1459 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1460 *) ac_optarg=yes ;;
1461 esac
1462
1463 # Accept the important Cygnus configure options, so we can diagnose typos.
1464
1465 case $ac_dashdash$ac_option in
1466 --)
1467 ac_dashdash=yes ;;
1468
1469 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1470 ac_prev=bindir ;;
1471 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1472 bindir=$ac_optarg ;;
1473
1474 -build | --build | --buil | --bui | --bu)
1475 ac_prev=build_alias ;;
1476 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1477 build_alias=$ac_optarg ;;
1478
1479 -cache-file | --cache-file | --cache-fil | --cache-fi \
1480 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1481 ac_prev=cache_file ;;
1482 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1483 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1484 cache_file=$ac_optarg ;;
1485
1486 --config-cache | -C)
1487 cache_file=config.cache ;;
1488
1489 -datadir | --datadir | --datadi | --datad)
1490 ac_prev=datadir ;;
1491 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1492 datadir=$ac_optarg ;;
1493
1494 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1495 | --dataroo | --dataro | --datar)
1496 ac_prev=datarootdir ;;
1497 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1498 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1499 datarootdir=$ac_optarg ;;
1500
1501 -disable-* | --disable-*)
1502 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1503 # Reject names that are not valid shell variable names.
1504 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1505 as_fn_error "invalid feature name: $ac_useropt"
1506 ac_useropt_orig=$ac_useropt
1507 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1508 case $ac_user_opts in
1509 *"
1510 "enable_$ac_useropt"
1511 "*) ;;
1512 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1513 ac_unrecognized_sep=', ';;
1514 esac
1515 eval enable_$ac_useropt=no ;;
1516
1517 -docdir | --docdir | --docdi | --doc | --do)
1518 ac_prev=docdir ;;
1519 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1520 docdir=$ac_optarg ;;
1521
1522 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1523 ac_prev=dvidir ;;
1524 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1525 dvidir=$ac_optarg ;;
1526
1527 -enable-* | --enable-*)
1528 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1529 # Reject names that are not valid shell variable names.
1530 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1531 as_fn_error "invalid feature name: $ac_useropt"
1532 ac_useropt_orig=$ac_useropt
1533 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1534 case $ac_user_opts in
1535 *"
1536 "enable_$ac_useropt"
1537 "*) ;;
1538 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1539 ac_unrecognized_sep=', ';;
1540 esac
1541 eval enable_$ac_useropt=\$ac_optarg ;;
1542
1543 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1544 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1545 | --exec | --exe | --ex)
1546 ac_prev=exec_prefix ;;
1547 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1548 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1549 | --exec=* | --exe=* | --ex=*)
1550 exec_prefix=$ac_optarg ;;
1551
1552 -gas | --gas | --ga | --g)
1553 # Obsolete; use --with-gas.
1554 with_gas=yes ;;
1555
1556 -help | --help | --hel | --he | -h)
1557 ac_init_help=long ;;
1558 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1559 ac_init_help=recursive ;;
1560 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1561 ac_init_help=short ;;
1562
1563 -host | --host | --hos | --ho)
1564 ac_prev=host_alias ;;
1565 -host=* | --host=* | --hos=* | --ho=*)
1566 host_alias=$ac_optarg ;;
1567
1568 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1569 ac_prev=htmldir ;;
1570 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1571 | --ht=*)
1572 htmldir=$ac_optarg ;;
1573
1574 -includedir | --includedir | --includedi | --included | --include \
1575 | --includ | --inclu | --incl | --inc)
1576 ac_prev=includedir ;;
1577 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1578 | --includ=* | --inclu=* | --incl=* | --inc=*)
1579 includedir=$ac_optarg ;;
1580
1581 -infodir | --infodir | --infodi | --infod | --info | --inf)
1582 ac_prev=infodir ;;
1583 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1584 infodir=$ac_optarg ;;
1585
1586 -libdir | --libdir | --libdi | --libd)
1587 ac_prev=libdir ;;
1588 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1589 libdir=$ac_optarg ;;
1590
1591 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1592 | --libexe | --libex | --libe)
1593 ac_prev=libexecdir ;;
1594 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1595 | --libexe=* | --libex=* | --libe=*)
1596 libexecdir=$ac_optarg ;;
1597
1598 -localedir | --localedir | --localedi | --localed | --locale)
1599 ac_prev=localedir ;;
1600 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1601 localedir=$ac_optarg ;;
1602
1603 -localstatedir | --localstatedir | --localstatedi | --localstated \
1604 | --localstate | --localstat | --localsta | --localst | --locals)
1605 ac_prev=localstatedir ;;
1606 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1607 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1608 localstatedir=$ac_optarg ;;
1609
1610 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1611 ac_prev=mandir ;;
1612 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1613 mandir=$ac_optarg ;;
1614
1615 -nfp | --nfp | --nf)
1616 # Obsolete; use --without-fp.
1617 with_fp=no ;;
1618
1619 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1620 | --no-cr | --no-c | -n)
1621 no_create=yes ;;
1622
1623 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1624 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1625 no_recursion=yes ;;
1626
1627 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1628 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1629 | --oldin | --oldi | --old | --ol | --o)
1630 ac_prev=oldincludedir ;;
1631 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1632 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1633 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1634 oldincludedir=$ac_optarg ;;
1635
1636 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1637 ac_prev=prefix ;;
1638 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1639 prefix=$ac_optarg ;;
1640
1641 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1642 | --program-pre | --program-pr | --program-p)
1643 ac_prev=program_prefix ;;
1644 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1645 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1646 program_prefix=$ac_optarg ;;
1647
1648 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1649 | --program-suf | --program-su | --program-s)
1650 ac_prev=program_suffix ;;
1651 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1652 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1653 program_suffix=$ac_optarg ;;
1654
1655 -program-transform-name | --program-transform-name \
1656 | --program-transform-nam | --program-transform-na \
1657 | --program-transform-n | --program-transform- \
1658 | --program-transform | --program-transfor \
1659 | --program-transfo | --program-transf \
1660 | --program-trans | --program-tran \
1661 | --progr-tra | --program-tr | --program-t)
1662 ac_prev=program_transform_name ;;
1663 -program-transform-name=* | --program-transform-name=* \
1664 | --program-transform-nam=* | --program-transform-na=* \
1665 | --program-transform-n=* | --program-transform-=* \
1666 | --program-transform=* | --program-transfor=* \
1667 | --program-transfo=* | --program-transf=* \
1668 | --program-trans=* | --program-tran=* \
1669 | --progr-tra=* | --program-tr=* | --program-t=*)
1670 program_transform_name=$ac_optarg ;;
1671
1672 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1673 ac_prev=pdfdir ;;
1674 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1675 pdfdir=$ac_optarg ;;
1676
1677 -psdir | --psdir | --psdi | --psd | --ps)
1678 ac_prev=psdir ;;
1679 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1680 psdir=$ac_optarg ;;
1681
1682 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1683 | -silent | --silent | --silen | --sile | --sil)
1684 silent=yes ;;
1685
1686 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1687 ac_prev=sbindir ;;
1688 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1689 | --sbi=* | --sb=*)
1690 sbindir=$ac_optarg ;;
1691
1692 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1693 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1694 | --sharedst | --shareds | --shared | --share | --shar \
1695 | --sha | --sh)
1696 ac_prev=sharedstatedir ;;
1697 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1698 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1699 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1700 | --sha=* | --sh=*)
1701 sharedstatedir=$ac_optarg ;;
1702
1703 -site | --site | --sit)
1704 ac_prev=site ;;
1705 -site=* | --site=* | --sit=*)
1706 site=$ac_optarg ;;
1707
1708 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1709 ac_prev=srcdir ;;
1710 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1711 srcdir=$ac_optarg ;;
1712
1713 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1714 | --syscon | --sysco | --sysc | --sys | --sy)
1715 ac_prev=sysconfdir ;;
1716 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1717 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1718 sysconfdir=$ac_optarg ;;
1719
1720 -target | --target | --targe | --targ | --tar | --ta | --t)
1721 ac_prev=target_alias ;;
1722 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1723 target_alias=$ac_optarg ;;
1724
1725 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1726 verbose=yes ;;
1727
1728 -version | --version | --versio | --versi | --vers | -V)
1729 ac_init_version=: ;;
1730
1731 -with-* | --with-*)
1732 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1733 # Reject names that are not valid shell variable names.
1734 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1735 as_fn_error "invalid package name: $ac_useropt"
1736 ac_useropt_orig=$ac_useropt
1737 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1738 case $ac_user_opts in
1739 *"
1740 "with_$ac_useropt"
1741 "*) ;;
1742 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1743 ac_unrecognized_sep=', ';;
1744 esac
1745 eval with_$ac_useropt=\$ac_optarg ;;
1746
1747 -without-* | --without-*)
1748 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1749 # Reject names that are not valid shell variable names.
1750 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1751 as_fn_error "invalid package name: $ac_useropt"
1752 ac_useropt_orig=$ac_useropt
1753 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1754 case $ac_user_opts in
1755 *"
1756 "with_$ac_useropt"
1757 "*) ;;
1758 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1759 ac_unrecognized_sep=', ';;
1760 esac
1761 eval with_$ac_useropt=no ;;
1762
1763 --x)
1764 # Obsolete; use --with-x.
1765 with_x=yes ;;
1766
1767 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1768 | --x-incl | --x-inc | --x-in | --x-i)
1769 ac_prev=x_includes ;;
1770 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1771 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1772 x_includes=$ac_optarg ;;
1773
1774 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1775 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1776 ac_prev=x_libraries ;;
1777 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1778 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1779 x_libraries=$ac_optarg ;;
1780
1781 -*) as_fn_error "unrecognized option: \`$ac_option'
1782 Try \`$0 --help' for more information."
1783 ;;
1784
1785 *=*)
1786 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1787 # Reject names that are not valid shell variable names.
1788 case $ac_envvar in #(
1789 '' | [0-9]* | *[!_$as_cr_alnum]* )
1790 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1791 esac
1792 eval $ac_envvar=\$ac_optarg
1793 export $ac_envvar ;;
1794
1795 *)
1796 # FIXME: should be removed in autoconf 3.0.
1797 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1798 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1799 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1800 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1801 ;;
1802
1803 esac
1804 done
1805
1806 if test -n "$ac_prev"; then
1807 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1808 as_fn_error "missing argument to $ac_option"
1809 fi
1810
1811 if test -n "$ac_unrecognized_opts"; then
1812 case $enable_option_checking in
1813 no) ;;
1814 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1815 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1816 esac
1817 fi
1818
1819 # Check all directory arguments for consistency.
1820 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1821 datadir sysconfdir sharedstatedir localstatedir includedir \
1822 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1823 libdir localedir mandir
1824 do
1825 eval ac_val=\$$ac_var
1826 # Remove trailing slashes.
1827 case $ac_val in
1828 */ )
1829 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1830 eval $ac_var=\$ac_val;;
1831 esac
1832 # Be sure to have absolute directory names.
1833 case $ac_val in
1834 [\\/$]* | ?:[\\/]* ) continue;;
1835 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1836 esac
1837 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1838 done
1839
1840 # There might be people who depend on the old broken behavior: `$host'
1841 # used to hold the argument of --host etc.
1842 # FIXME: To remove some day.
1843 build=$build_alias
1844 host=$host_alias
1845 target=$target_alias
1846
1847 # FIXME: To remove some day.
1848 if test "x$host_alias" != x; then
1849 if test "x$build_alias" = x; then
1850 cross_compiling=maybe
1851 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1852 If a cross compiler is detected then cross compile mode will be used." >&2
1853 elif test "x$build_alias" != "x$host_alias"; then
1854 cross_compiling=yes
1855 fi
1856 fi
1857
1858 ac_tool_prefix=
1859 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1860
1861 test "$silent" = yes && exec 6>/dev/null
1862
1863
1864 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1865 ac_ls_di=`ls -di .` &&
1866 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1867 as_fn_error "working directory cannot be determined"
1868 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1869 as_fn_error "pwd does not report name of working directory"
1870
1871
1872 # Find the source files, if location was not specified.
1873 if test -z "$srcdir"; then
1874 ac_srcdir_defaulted=yes
1875 # Try the directory containing this script, then the parent directory.
1876 ac_confdir=`$as_dirname -- "$as_myself" ||
1877 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1878 X"$as_myself" : 'X\(//\)[^/]' \| \
1879 X"$as_myself" : 'X\(//\)$' \| \
1880 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1881 $as_echo X"$as_myself" |
1882 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1883 s//\1/
1884 q
1885 }
1886 /^X\(\/\/\)[^/].*/{
1887 s//\1/
1888 q
1889 }
1890 /^X\(\/\/\)$/{
1891 s//\1/
1892 q
1893 }
1894 /^X\(\/\).*/{
1895 s//\1/
1896 q
1897 }
1898 s/.*/./; q'`
1899 srcdir=$ac_confdir
1900 if test ! -r "$srcdir/$ac_unique_file"; then
1901 srcdir=..
1902 fi
1903 else
1904 ac_srcdir_defaulted=no
1905 fi
1906 if test ! -r "$srcdir/$ac_unique_file"; then
1907 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1908 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1909 fi
1910 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1911 ac_abs_confdir=`(
1912 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1913 pwd)`
1914 # When building in place, set srcdir=.
1915 if test "$ac_abs_confdir" = "$ac_pwd"; then
1916 srcdir=.
1917 fi
1918 # Remove unnecessary trailing slashes from srcdir.
1919 # Double slashes in file names in object file debugging info
1920 # mess up M-x gdb in Emacs.
1921 case $srcdir in
1922 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1923 esac
1924 for ac_var in $ac_precious_vars; do
1925 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1926 eval ac_env_${ac_var}_value=\$${ac_var}
1927 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1928 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1929 done
1930
1931 #
1932 # Report the --help message.
1933 #
1934 if test "$ac_init_help" = "long"; then
1935 # Omit some internal or obsolete options to make the list less imposing.
1936 # This message is too long to be a string in the A/UX 3.1 sh.
1937 cat <<_ACEOF
1938 \`configure' configures emacs 24.2.50 to adapt to many kinds of systems.
1939
1940 Usage: $0 [OPTION]... [VAR=VALUE]...
1941
1942 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1943 VAR=VALUE. See below for descriptions of some of the useful variables.
1944
1945 Defaults for the options are specified in brackets.
1946
1947 Configuration:
1948 -h, --help display this help and exit
1949 --help=short display options specific to this package
1950 --help=recursive display the short help of all the included packages
1951 -V, --version display version information and exit
1952 -q, --quiet, --silent do not print \`checking...' messages
1953 --cache-file=FILE cache test results in FILE [disabled]
1954 -C, --config-cache alias for \`--cache-file=config.cache'
1955 -n, --no-create do not create output files
1956 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1957
1958 Installation directories:
1959 --prefix=PREFIX install architecture-independent files in PREFIX
1960 [$ac_default_prefix]
1961 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1962 [PREFIX]
1963
1964 By default, \`make install' will install all the files in
1965 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1966 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1967 for instance \`--prefix=\$HOME'.
1968
1969 For better control, use the options below.
1970
1971 Fine tuning of the installation directories:
1972 --bindir=DIR user executables [EPREFIX/bin]
1973 --sbindir=DIR system admin executables [EPREFIX/sbin]
1974 --libexecdir=DIR program executables [EPREFIX/libexec]
1975 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1976 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1977 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1978 --libdir=DIR object code libraries [EPREFIX/lib]
1979 --includedir=DIR C header files [PREFIX/include]
1980 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1981 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1982 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1983 --infodir=DIR info documentation [DATAROOTDIR/info]
1984 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1985 --mandir=DIR man documentation [DATAROOTDIR/man]
1986 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1987 --htmldir=DIR html documentation [DOCDIR]
1988 --dvidir=DIR dvi documentation [DOCDIR]
1989 --pdfdir=DIR pdf documentation [DOCDIR]
1990 --psdir=DIR ps documentation [DOCDIR]
1991 _ACEOF
1992
1993 cat <<\_ACEOF
1994
1995 Program names:
1996 --program-prefix=PREFIX prepend PREFIX to installed program names
1997 --program-suffix=SUFFIX append SUFFIX to installed program names
1998 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1999
2000 X features:
2001 --x-includes=DIR X include files are in DIR
2002 --x-libraries=DIR X library files are in DIR
2003
2004 System types:
2005 --build=BUILD configure for building on BUILD [guessed]
2006 --host=HOST cross-compile to build programs to run on HOST [BUILD]
2007 _ACEOF
2008 fi
2009
2010 if test -n "$ac_init_help"; then
2011 case $ac_init_help in
2012 short | recursive ) echo "Configuration of emacs 24.2.50:";;
2013 esac
2014 cat <<\_ACEOF
2015
2016 Optional Features:
2017 --disable-option-checking ignore unrecognized --enable/--with options
2018 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
2019 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
2020 --disable-ns-self-contained
2021 disable self contained build under NeXTstep
2022 --enable-locallisppath=PATH
2023 directories Emacs should search for lisp files
2024 specific to this site
2025 --enable-checking[=LIST]
2026 enable expensive run-time checks. With LIST, enable
2027 only specific categories of checks. Categories are:
2028 all,yes,no. Flags are: stringbytes, stringoverrun,
2029 stringfreelist, xmallocoverrun, conslist, glyphs
2030 --enable-check-lisp-object-type
2031 enable compile time checks for the Lisp_Object data
2032 type. This is useful for development for catching
2033 certain types of bugs.
2034 --enable-profiling build emacs with profiling support. This might not
2035 work on all platforms
2036 --enable-autodepend automatically generate dependencies to .h-files.
2037 Requires GNU Make and Gcc. Enabled if GNU Make and
2038 Gcc is found
2039 --disable-dependency-tracking speeds up one-time build
2040 --enable-dependency-tracking do not reject slow dependency extractors
2041 --disable-largefile omit support for large files
2042 --enable-gcc-warnings turn on lots of GCC warnings. This is intended for
2043 developers, and may generate false alarms when used
2044 with older or non-GNU development tools.
2045 --enable-link-time-optimization
2046 build emacs with link-time optimization. This is
2047 supported only for GCC since 4.5.0.
2048
2049 Optional Packages:
2050 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2051 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2052 --without-all omit almost all features and build small executable
2053 with minimal dependencies
2054 --without-pop don't support POP mail retrieval with movemail
2055 --with-kerberos support Kerberos-authenticated POP
2056 --with-kerberos5 support Kerberos version 5 authenticated POP
2057 --with-hesiod support Hesiod to get the POP server host
2058 --with-mmdf support MMDF mailboxes
2059 --with-mail-unlink unlink, rather than empty, mail spool after reading
2060 --with-mailhost=HOSTNAME
2061 string giving default POP mail host
2062 --without-sound don't compile with sound support
2063 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
2064 gtk3, lucid or athena, motif, no)
2065 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2066 --without-xpm don't compile with XPM image support
2067 --without-jpeg don't compile with JPEG image support
2068 --without-tiff don't compile with TIFF image support
2069 --without-gif don't compile with GIF image support
2070 --without-png don't compile with PNG image support
2071 --without-rsvg don't compile with SVG image support
2072 --without-xml2 don't compile with XML parsing support
2073 --without-imagemagick don't compile with ImageMagick image support
2074 --without-xft don't use XFT for anti aliased fonts
2075 --without-libotf don't use libotf for OpenType font support
2076 --without-m17n-flt don't use m17n-flt for text shaping
2077 --without-toolkit-scroll-bars
2078 don't use Motif or Xaw3d scroll bars
2079 --without-xaw3d don't use Xaw3d
2080 --without-xim don't use X11 XIM
2081 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2082 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2083 console
2084 --without-dbus don't compile with D-Bus support
2085 --without-gconf don't compile with GConf support
2086 --without-gsettings don't compile with GSettings support
2087 --without-selinux don't compile with SELinux support
2088 --without-gnutls don't use -lgnutls for SSL/TLS support
2089 --without-makeinfo don't require makeinfo for building manuals
2090 --without-compress-info don't compress the installed Info pages
2091 --with-pkg-config-prog=PATH
2092 path to pkg-config for finding GTK and librsvg
2093 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2094 /usr/lib, or /usr/lib64 on some platforms.
2095 --with-gameuser=USER user for shared game score files
2096 --with-gnustep-conf=PATH
2097 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2098 or /etc/GNUstep/GNUstep.conf
2099 --with-x use the X Window System
2100
2101 Some influential environment variables:
2102 CC C compiler command
2103 CFLAGS C compiler flags
2104 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2105 nonstandard directory <lib dir>
2106 LIBS libraries to pass to the linker, e.g. -l<library>
2107 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2108 you have headers in a nonstandard directory <include dir>
2109 CPP C preprocessor
2110 XMKMF Path to xmkmf, Makefile generator for X Window System
2111
2112 Use these variables to override the choices made by `configure' or to help
2113 it to find libraries and programs with nonstandard names/locations.
2114
2115 Report bugs to the package provider.
2116 _ACEOF
2117 ac_status=$?
2118 fi
2119
2120 if test "$ac_init_help" = "recursive"; then
2121 # If there are subdirs, report their specific --help.
2122 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2123 test -d "$ac_dir" ||
2124 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2125 continue
2126 ac_builddir=.
2127
2128 case "$ac_dir" in
2129 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2130 *)
2131 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2132 # A ".." for each directory in $ac_dir_suffix.
2133 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2134 case $ac_top_builddir_sub in
2135 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2136 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2137 esac ;;
2138 esac
2139 ac_abs_top_builddir=$ac_pwd
2140 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2141 # for backward compatibility:
2142 ac_top_builddir=$ac_top_build_prefix
2143
2144 case $srcdir in
2145 .) # We are building in place.
2146 ac_srcdir=.
2147 ac_top_srcdir=$ac_top_builddir_sub
2148 ac_abs_top_srcdir=$ac_pwd ;;
2149 [\\/]* | ?:[\\/]* ) # Absolute name.
2150 ac_srcdir=$srcdir$ac_dir_suffix;
2151 ac_top_srcdir=$srcdir
2152 ac_abs_top_srcdir=$srcdir ;;
2153 *) # Relative name.
2154 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2155 ac_top_srcdir=$ac_top_build_prefix$srcdir
2156 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2157 esac
2158 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2159
2160 cd "$ac_dir" || { ac_status=$?; continue; }
2161 # Check for guested configure.
2162 if test -f "$ac_srcdir/configure.gnu"; then
2163 echo &&
2164 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2165 elif test -f "$ac_srcdir/configure"; then
2166 echo &&
2167 $SHELL "$ac_srcdir/configure" --help=recursive
2168 else
2169 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2170 fi || ac_status=$?
2171 cd "$ac_pwd" || { ac_status=$?; break; }
2172 done
2173 fi
2174
2175 test -n "$ac_init_help" && exit $ac_status
2176 if $ac_init_version; then
2177 cat <<\_ACEOF
2178 emacs configure 24.2.50
2179 generated by GNU Autoconf 2.65
2180
2181 Copyright (C) 2009 Free Software Foundation, Inc.
2182 This configure script is free software; the Free Software Foundation
2183 gives unlimited permission to copy, distribute and modify it.
2184 _ACEOF
2185 exit
2186 fi
2187
2188 ## ------------------------ ##
2189 ## Autoconf initialization. ##
2190 ## ------------------------ ##
2191
2192 # ac_fn_c_try_compile LINENO
2193 # --------------------------
2194 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2195 ac_fn_c_try_compile ()
2196 {
2197 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2198 rm -f conftest.$ac_objext
2199 if { { ac_try="$ac_compile"
2200 case "(($ac_try" in
2201 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2202 *) ac_try_echo=$ac_try;;
2203 esac
2204 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2205 $as_echo "$ac_try_echo"; } >&5
2206 (eval "$ac_compile") 2>conftest.err
2207 ac_status=$?
2208 if test -s conftest.err; then
2209 grep -v '^ *+' conftest.err >conftest.er1
2210 cat conftest.er1 >&5
2211 mv -f conftest.er1 conftest.err
2212 fi
2213 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2214 test $ac_status = 0; } && {
2215 test -z "$ac_c_werror_flag" ||
2216 test ! -s conftest.err
2217 } && test -s conftest.$ac_objext; then :
2218 ac_retval=0
2219 else
2220 $as_echo "$as_me: failed program was:" >&5
2221 sed 's/^/| /' conftest.$ac_ext >&5
2222
2223 ac_retval=1
2224 fi
2225 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2226 as_fn_set_status $ac_retval
2227
2228 } # ac_fn_c_try_compile
2229
2230 # ac_fn_c_try_cpp LINENO
2231 # ----------------------
2232 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2233 ac_fn_c_try_cpp ()
2234 {
2235 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2236 if { { ac_try="$ac_cpp conftest.$ac_ext"
2237 case "(($ac_try" in
2238 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2239 *) ac_try_echo=$ac_try;;
2240 esac
2241 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2242 $as_echo "$ac_try_echo"; } >&5
2243 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2244 ac_status=$?
2245 if test -s conftest.err; then
2246 grep -v '^ *+' conftest.err >conftest.er1
2247 cat conftest.er1 >&5
2248 mv -f conftest.er1 conftest.err
2249 fi
2250 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2251 test $ac_status = 0; } >/dev/null && {
2252 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2253 test ! -s conftest.err
2254 }; then :
2255 ac_retval=0
2256 else
2257 $as_echo "$as_me: failed program was:" >&5
2258 sed 's/^/| /' conftest.$ac_ext >&5
2259
2260 ac_retval=1
2261 fi
2262 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2263 as_fn_set_status $ac_retval
2264
2265 } # ac_fn_c_try_cpp
2266
2267 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2268 # -------------------------------------------------------
2269 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2270 # the include files in INCLUDES and setting the cache variable VAR
2271 # accordingly.
2272 ac_fn_c_check_header_mongrel ()
2273 {
2274 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2275 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2277 $as_echo_n "checking for $2... " >&6; }
2278 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2279 $as_echo_n "(cached) " >&6
2280 fi
2281 eval ac_res=\$$3
2282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2283 $as_echo "$ac_res" >&6; }
2284 else
2285 # Is the header compilable?
2286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2287 $as_echo_n "checking $2 usability... " >&6; }
2288 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2289 /* end confdefs.h. */
2290 $4
2291 #include <$2>
2292 _ACEOF
2293 if ac_fn_c_try_compile "$LINENO"; then :
2294 ac_header_compiler=yes
2295 else
2296 ac_header_compiler=no
2297 fi
2298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2300 $as_echo "$ac_header_compiler" >&6; }
2301
2302 # Is the header present?
2303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2304 $as_echo_n "checking $2 presence... " >&6; }
2305 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2306 /* end confdefs.h. */
2307 #include <$2>
2308 _ACEOF
2309 if ac_fn_c_try_cpp "$LINENO"; then :
2310 ac_header_preproc=yes
2311 else
2312 ac_header_preproc=no
2313 fi
2314 rm -f conftest.err conftest.$ac_ext
2315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2316 $as_echo "$ac_header_preproc" >&6; }
2317
2318 # So? What about this header?
2319 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2320 yes:no: )
2321 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2322 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2323 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2324 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2325 ;;
2326 no:yes:* )
2327 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2328 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2329 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2330 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2331 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2332 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2333 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2334 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2335 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2336 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2337 ;;
2338 esac
2339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2340 $as_echo_n "checking for $2... " >&6; }
2341 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2342 $as_echo_n "(cached) " >&6
2343 else
2344 eval "$3=\$ac_header_compiler"
2345 fi
2346 eval ac_res=\$$3
2347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2348 $as_echo "$ac_res" >&6; }
2349 fi
2350 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2351
2352 } # ac_fn_c_check_header_mongrel
2353
2354 # ac_fn_c_try_run LINENO
2355 # ----------------------
2356 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2357 # that executables *can* be run.
2358 ac_fn_c_try_run ()
2359 {
2360 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2361 if { { ac_try="$ac_link"
2362 case "(($ac_try" in
2363 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2364 *) ac_try_echo=$ac_try;;
2365 esac
2366 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2367 $as_echo "$ac_try_echo"; } >&5
2368 (eval "$ac_link") 2>&5
2369 ac_status=$?
2370 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2371 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2372 { { case "(($ac_try" in
2373 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2374 *) ac_try_echo=$ac_try;;
2375 esac
2376 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2377 $as_echo "$ac_try_echo"; } >&5
2378 (eval "$ac_try") 2>&5
2379 ac_status=$?
2380 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2381 test $ac_status = 0; }; }; then :
2382 ac_retval=0
2383 else
2384 $as_echo "$as_me: program exited with status $ac_status" >&5
2385 $as_echo "$as_me: failed program was:" >&5
2386 sed 's/^/| /' conftest.$ac_ext >&5
2387
2388 ac_retval=$ac_status
2389 fi
2390 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2391 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2392 as_fn_set_status $ac_retval
2393
2394 } # ac_fn_c_try_run
2395
2396 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2397 # -------------------------------------------------------
2398 # Tests whether HEADER exists and can be compiled using the include files in
2399 # INCLUDES, setting the cache variable VAR accordingly.
2400 ac_fn_c_check_header_compile ()
2401 {
2402 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2404 $as_echo_n "checking for $2... " >&6; }
2405 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2406 $as_echo_n "(cached) " >&6
2407 else
2408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2409 /* end confdefs.h. */
2410 $4
2411 #include <$2>
2412 _ACEOF
2413 if ac_fn_c_try_compile "$LINENO"; then :
2414 eval "$3=yes"
2415 else
2416 eval "$3=no"
2417 fi
2418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2419 fi
2420 eval ac_res=\$$3
2421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2422 $as_echo "$ac_res" >&6; }
2423 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2424
2425 } # ac_fn_c_check_header_compile
2426
2427 # ac_fn_c_try_link LINENO
2428 # -----------------------
2429 # Try to link conftest.$ac_ext, and return whether this succeeded.
2430 ac_fn_c_try_link ()
2431 {
2432 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2433 rm -f conftest.$ac_objext conftest$ac_exeext
2434 if { { ac_try="$ac_link"
2435 case "(($ac_try" in
2436 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2437 *) ac_try_echo=$ac_try;;
2438 esac
2439 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2440 $as_echo "$ac_try_echo"; } >&5
2441 (eval "$ac_link") 2>conftest.err
2442 ac_status=$?
2443 if test -s conftest.err; then
2444 grep -v '^ *+' conftest.err >conftest.er1
2445 cat conftest.er1 >&5
2446 mv -f conftest.er1 conftest.err
2447 fi
2448 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2449 test $ac_status = 0; } && {
2450 test -z "$ac_c_werror_flag" ||
2451 test ! -s conftest.err
2452 } && test -s conftest$ac_exeext && {
2453 test "$cross_compiling" = yes ||
2454 $as_test_x conftest$ac_exeext
2455 }; then :
2456 ac_retval=0
2457 else
2458 $as_echo "$as_me: failed program was:" >&5
2459 sed 's/^/| /' conftest.$ac_ext >&5
2460
2461 ac_retval=1
2462 fi
2463 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2464 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2465 # interfere with the next link command; also delete a directory that is
2466 # left behind by Apple's compiler. We do this before executing the actions.
2467 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2468 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2469 as_fn_set_status $ac_retval
2470
2471 } # ac_fn_c_try_link
2472
2473 # ac_fn_c_check_decl LINENO SYMBOL VAR
2474 # ------------------------------------
2475 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2476 ac_fn_c_check_decl ()
2477 {
2478 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2480 $as_echo_n "checking whether $2 is declared... " >&6; }
2481 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2482 $as_echo_n "(cached) " >&6
2483 else
2484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2485 /* end confdefs.h. */
2486 $4
2487 int
2488 main ()
2489 {
2490 #ifndef $2
2491 (void) $2;
2492 #endif
2493
2494 ;
2495 return 0;
2496 }
2497 _ACEOF
2498 if ac_fn_c_try_compile "$LINENO"; then :
2499 eval "$3=yes"
2500 else
2501 eval "$3=no"
2502 fi
2503 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2504 fi
2505 eval ac_res=\$$3
2506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2507 $as_echo "$ac_res" >&6; }
2508 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2509
2510 } # ac_fn_c_check_decl
2511
2512 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2513 # ----------------------------------------------
2514 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2515 ac_fn_c_check_header_preproc ()
2516 {
2517 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2519 $as_echo_n "checking for $2... " >&6; }
2520 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2521 $as_echo_n "(cached) " >&6
2522 else
2523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2524 /* end confdefs.h. */
2525 #include <$2>
2526 _ACEOF
2527 if ac_fn_c_try_cpp "$LINENO"; then :
2528 eval "$3=yes"
2529 else
2530 eval "$3=no"
2531 fi
2532 rm -f conftest.err conftest.$ac_ext
2533 fi
2534 eval ac_res=\$$3
2535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2536 $as_echo "$ac_res" >&6; }
2537 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2538
2539 } # ac_fn_c_check_header_preproc
2540
2541 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2542 # ----------------------------------------------------
2543 # Tries to find if the field MEMBER exists in type AGGR, after including
2544 # INCLUDES, setting cache variable VAR accordingly.
2545 ac_fn_c_check_member ()
2546 {
2547 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2549 $as_echo_n "checking for $2.$3... " >&6; }
2550 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2551 $as_echo_n "(cached) " >&6
2552 else
2553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2554 /* end confdefs.h. */
2555 $5
2556 int
2557 main ()
2558 {
2559 static $2 ac_aggr;
2560 if (ac_aggr.$3)
2561 return 0;
2562 ;
2563 return 0;
2564 }
2565 _ACEOF
2566 if ac_fn_c_try_compile "$LINENO"; then :
2567 eval "$4=yes"
2568 else
2569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2570 /* end confdefs.h. */
2571 $5
2572 int
2573 main ()
2574 {
2575 static $2 ac_aggr;
2576 if (sizeof ac_aggr.$3)
2577 return 0;
2578 ;
2579 return 0;
2580 }
2581 _ACEOF
2582 if ac_fn_c_try_compile "$LINENO"; then :
2583 eval "$4=yes"
2584 else
2585 eval "$4=no"
2586 fi
2587 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2588 fi
2589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2590 fi
2591 eval ac_res=\$$4
2592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2593 $as_echo "$ac_res" >&6; }
2594 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2595
2596 } # ac_fn_c_check_member
2597
2598 # ac_fn_c_check_func LINENO FUNC VAR
2599 # ----------------------------------
2600 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2601 ac_fn_c_check_func ()
2602 {
2603 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2605 $as_echo_n "checking for $2... " >&6; }
2606 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2607 $as_echo_n "(cached) " >&6
2608 else
2609 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2610 /* end confdefs.h. */
2611 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2612 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2613 #define $2 innocuous_$2
2614
2615 /* System header to define __stub macros and hopefully few prototypes,
2616 which can conflict with char $2 (); below.
2617 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2618 <limits.h> exists even on freestanding compilers. */
2619
2620 #ifdef __STDC__
2621 # include <limits.h>
2622 #else
2623 # include <assert.h>
2624 #endif
2625
2626 #undef $2
2627
2628 /* Override any GCC internal prototype to avoid an error.
2629 Use char because int might match the return type of a GCC
2630 builtin and then its argument prototype would still apply. */
2631 #ifdef __cplusplus
2632 extern "C"
2633 #endif
2634 char $2 ();
2635 /* The GNU C library defines this for functions which it implements
2636 to always fail with ENOSYS. Some functions are actually named
2637 something starting with __ and the normal name is an alias. */
2638 #if defined __stub_$2 || defined __stub___$2
2639 choke me
2640 #endif
2641
2642 int
2643 main ()
2644 {
2645 return $2 ();
2646 ;
2647 return 0;
2648 }
2649 _ACEOF
2650 if ac_fn_c_try_link "$LINENO"; then :
2651 eval "$3=yes"
2652 else
2653 eval "$3=no"
2654 fi
2655 rm -f core conftest.err conftest.$ac_objext \
2656 conftest$ac_exeext conftest.$ac_ext
2657 fi
2658 eval ac_res=\$$3
2659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2660 $as_echo "$ac_res" >&6; }
2661 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2662
2663 } # ac_fn_c_check_func
2664
2665 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2666 # -------------------------------------------
2667 # Tests whether TYPE exists after having included INCLUDES, setting cache
2668 # variable VAR accordingly.
2669 ac_fn_c_check_type ()
2670 {
2671 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2673 $as_echo_n "checking for $2... " >&6; }
2674 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2675 $as_echo_n "(cached) " >&6
2676 else
2677 eval "$3=no"
2678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2679 /* end confdefs.h. */
2680 $4
2681 int
2682 main ()
2683 {
2684 if (sizeof ($2))
2685 return 0;
2686 ;
2687 return 0;
2688 }
2689 _ACEOF
2690 if ac_fn_c_try_compile "$LINENO"; then :
2691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2692 /* end confdefs.h. */
2693 $4
2694 int
2695 main ()
2696 {
2697 if (sizeof (($2)))
2698 return 0;
2699 ;
2700 return 0;
2701 }
2702 _ACEOF
2703 if ac_fn_c_try_compile "$LINENO"; then :
2704
2705 else
2706 eval "$3=yes"
2707 fi
2708 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2709 fi
2710 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2711 fi
2712 eval ac_res=\$$3
2713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2714 $as_echo "$ac_res" >&6; }
2715 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2716
2717 } # ac_fn_c_check_type
2718
2719 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2720 # --------------------------------------------
2721 # Tries to find the compile-time value of EXPR in a program that includes
2722 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2723 # computed
2724 ac_fn_c_compute_int ()
2725 {
2726 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2727 if test "$cross_compiling" = yes; then
2728 # Depending upon the size, compute the lo and hi bounds.
2729 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2730 /* end confdefs.h. */
2731 $4
2732 int
2733 main ()
2734 {
2735 static int test_array [1 - 2 * !(($2) >= 0)];
2736 test_array [0] = 0
2737
2738 ;
2739 return 0;
2740 }
2741 _ACEOF
2742 if ac_fn_c_try_compile "$LINENO"; then :
2743 ac_lo=0 ac_mid=0
2744 while :; do
2745 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2746 /* end confdefs.h. */
2747 $4
2748 int
2749 main ()
2750 {
2751 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2752 test_array [0] = 0
2753
2754 ;
2755 return 0;
2756 }
2757 _ACEOF
2758 if ac_fn_c_try_compile "$LINENO"; then :
2759 ac_hi=$ac_mid; break
2760 else
2761 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2762 if test $ac_lo -le $ac_mid; then
2763 ac_lo= ac_hi=
2764 break
2765 fi
2766 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2767 fi
2768 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2769 done
2770 else
2771 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2772 /* end confdefs.h. */
2773 $4
2774 int
2775 main ()
2776 {
2777 static int test_array [1 - 2 * !(($2) < 0)];
2778 test_array [0] = 0
2779
2780 ;
2781 return 0;
2782 }
2783 _ACEOF
2784 if ac_fn_c_try_compile "$LINENO"; then :
2785 ac_hi=-1 ac_mid=-1
2786 while :; do
2787 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2788 /* end confdefs.h. */
2789 $4
2790 int
2791 main ()
2792 {
2793 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2794 test_array [0] = 0
2795
2796 ;
2797 return 0;
2798 }
2799 _ACEOF
2800 if ac_fn_c_try_compile "$LINENO"; then :
2801 ac_lo=$ac_mid; break
2802 else
2803 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2804 if test $ac_mid -le $ac_hi; then
2805 ac_lo= ac_hi=
2806 break
2807 fi
2808 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2809 fi
2810 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2811 done
2812 else
2813 ac_lo= ac_hi=
2814 fi
2815 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2816 fi
2817 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2818 # Binary search between lo and hi bounds.
2819 while test "x$ac_lo" != "x$ac_hi"; do
2820 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2822 /* end confdefs.h. */
2823 $4
2824 int
2825 main ()
2826 {
2827 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2828 test_array [0] = 0
2829
2830 ;
2831 return 0;
2832 }
2833 _ACEOF
2834 if ac_fn_c_try_compile "$LINENO"; then :
2835 ac_hi=$ac_mid
2836 else
2837 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2838 fi
2839 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2840 done
2841 case $ac_lo in #((
2842 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2843 '') ac_retval=1 ;;
2844 esac
2845 else
2846 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2847 /* end confdefs.h. */
2848 $4
2849 static long int longval () { return $2; }
2850 static unsigned long int ulongval () { return $2; }
2851 #include <stdio.h>
2852 #include <stdlib.h>
2853 int
2854 main ()
2855 {
2856
2857 FILE *f = fopen ("conftest.val", "w");
2858 if (! f)
2859 return 1;
2860 if (($2) < 0)
2861 {
2862 long int i = longval ();
2863 if (i != ($2))
2864 return 1;
2865 fprintf (f, "%ld", i);
2866 }
2867 else
2868 {
2869 unsigned long int i = ulongval ();
2870 if (i != ($2))
2871 return 1;
2872 fprintf (f, "%lu", i);
2873 }
2874 /* Do not output a trailing newline, as this causes \r\n confusion
2875 on some platforms. */
2876 return ferror (f) || fclose (f) != 0;
2877
2878 ;
2879 return 0;
2880 }
2881 _ACEOF
2882 if ac_fn_c_try_run "$LINENO"; then :
2883 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2884 else
2885 ac_retval=1
2886 fi
2887 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2888 conftest.$ac_objext conftest.beam conftest.$ac_ext
2889 rm -f conftest.val
2890
2891 fi
2892 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2893 as_fn_set_status $ac_retval
2894
2895 } # ac_fn_c_compute_int
2896 cat >config.log <<_ACEOF
2897 This file contains any messages produced by compilers while
2898 running configure, to aid debugging if configure makes a mistake.
2899
2900 It was created by emacs $as_me 24.2.50, which was
2901 generated by GNU Autoconf 2.65. Invocation command line was
2902
2903 $ $0 $@
2904
2905 _ACEOF
2906 exec 5>>config.log
2907 {
2908 cat <<_ASUNAME
2909 ## --------- ##
2910 ## Platform. ##
2911 ## --------- ##
2912
2913 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2914 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2915 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2916 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2917 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2918
2919 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2920 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2921
2922 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2923 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2924 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2925 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2926 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2927 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2928 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2929
2930 _ASUNAME
2931
2932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2933 for as_dir in $PATH
2934 do
2935 IFS=$as_save_IFS
2936 test -z "$as_dir" && as_dir=.
2937 $as_echo "PATH: $as_dir"
2938 done
2939 IFS=$as_save_IFS
2940
2941 } >&5
2942
2943 cat >&5 <<_ACEOF
2944
2945
2946 ## ----------- ##
2947 ## Core tests. ##
2948 ## ----------- ##
2949
2950 _ACEOF
2951
2952
2953 # Keep a trace of the command line.
2954 # Strip out --no-create and --no-recursion so they do not pile up.
2955 # Strip out --silent because we don't want to record it for future runs.
2956 # Also quote any args containing shell meta-characters.
2957 # Make two passes to allow for proper duplicate-argument suppression.
2958 ac_configure_args=
2959 ac_configure_args0=
2960 ac_configure_args1=
2961 ac_must_keep_next=false
2962 for ac_pass in 1 2
2963 do
2964 for ac_arg
2965 do
2966 case $ac_arg in
2967 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2968 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2969 | -silent | --silent | --silen | --sile | --sil)
2970 continue ;;
2971 *\'*)
2972 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2973 esac
2974 case $ac_pass in
2975 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2976 2)
2977 as_fn_append ac_configure_args1 " '$ac_arg'"
2978 if test $ac_must_keep_next = true; then
2979 ac_must_keep_next=false # Got value, back to normal.
2980 else
2981 case $ac_arg in
2982 *=* | --config-cache | -C | -disable-* | --disable-* \
2983 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2984 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2985 | -with-* | --with-* | -without-* | --without-* | --x)
2986 case "$ac_configure_args0 " in
2987 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2988 esac
2989 ;;
2990 -* ) ac_must_keep_next=true ;;
2991 esac
2992 fi
2993 as_fn_append ac_configure_args " '$ac_arg'"
2994 ;;
2995 esac
2996 done
2997 done
2998 { ac_configure_args0=; unset ac_configure_args0;}
2999 { ac_configure_args1=; unset ac_configure_args1;}
3000
3001 # When interrupted or exit'd, cleanup temporary files, and complete
3002 # config.log. We remove comments because anyway the quotes in there
3003 # would cause problems or look ugly.
3004 # WARNING: Use '\'' to represent an apostrophe within the trap.
3005 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
3006 trap 'exit_status=$?
3007 # Save into config.log some information that might help in debugging.
3008 {
3009 echo
3010
3011 cat <<\_ASBOX
3012 ## ---------------- ##
3013 ## Cache variables. ##
3014 ## ---------------- ##
3015 _ASBOX
3016 echo
3017 # The following way of writing the cache mishandles newlines in values,
3018 (
3019 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
3020 eval ac_val=\$$ac_var
3021 case $ac_val in #(
3022 *${as_nl}*)
3023 case $ac_var in #(
3024 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
3025 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
3026 esac
3027 case $ac_var in #(
3028 _ | IFS | as_nl) ;; #(
3029 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
3030 *) { eval $ac_var=; unset $ac_var;} ;;
3031 esac ;;
3032 esac
3033 done
3034 (set) 2>&1 |
3035 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
3036 *${as_nl}ac_space=\ *)
3037 sed -n \
3038 "s/'\''/'\''\\\\'\'''\''/g;
3039 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
3040 ;; #(
3041 *)
3042 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
3043 ;;
3044 esac |
3045 sort
3046 )
3047 echo
3048
3049 cat <<\_ASBOX
3050 ## ----------------- ##
3051 ## Output variables. ##
3052 ## ----------------- ##
3053 _ASBOX
3054 echo
3055 for ac_var in $ac_subst_vars
3056 do
3057 eval ac_val=\$$ac_var
3058 case $ac_val in
3059 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3060 esac
3061 $as_echo "$ac_var='\''$ac_val'\''"
3062 done | sort
3063 echo
3064
3065 if test -n "$ac_subst_files"; then
3066 cat <<\_ASBOX
3067 ## ------------------- ##
3068 ## File substitutions. ##
3069 ## ------------------- ##
3070 _ASBOX
3071 echo
3072 for ac_var in $ac_subst_files
3073 do
3074 eval ac_val=\$$ac_var
3075 case $ac_val in
3076 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3077 esac
3078 $as_echo "$ac_var='\''$ac_val'\''"
3079 done | sort
3080 echo
3081 fi
3082
3083 if test -s confdefs.h; then
3084 cat <<\_ASBOX
3085 ## ----------- ##
3086 ## confdefs.h. ##
3087 ## ----------- ##
3088 _ASBOX
3089 echo
3090 cat confdefs.h
3091 echo
3092 fi
3093 test "$ac_signal" != 0 &&
3094 $as_echo "$as_me: caught signal $ac_signal"
3095 $as_echo "$as_me: exit $exit_status"
3096 } >&5
3097 rm -f core *.core core.conftest.* &&
3098 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3099 exit $exit_status
3100 ' 0
3101 for ac_signal in 1 2 13 15; do
3102 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3103 done
3104 ac_signal=0
3105
3106 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3107 rm -f -r conftest* confdefs.h
3108
3109 $as_echo "/* confdefs.h */" > confdefs.h
3110
3111 # Predefined preprocessor variables.
3112
3113 cat >>confdefs.h <<_ACEOF
3114 #define PACKAGE_NAME "$PACKAGE_NAME"
3115 _ACEOF
3116
3117 cat >>confdefs.h <<_ACEOF
3118 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3119 _ACEOF
3120
3121 cat >>confdefs.h <<_ACEOF
3122 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3123 _ACEOF
3124
3125 cat >>confdefs.h <<_ACEOF
3126 #define PACKAGE_STRING "$PACKAGE_STRING"
3127 _ACEOF
3128
3129 cat >>confdefs.h <<_ACEOF
3130 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3131 _ACEOF
3132
3133 cat >>confdefs.h <<_ACEOF
3134 #define PACKAGE_URL "$PACKAGE_URL"
3135 _ACEOF
3136
3137
3138 # Let the site file select an alternate cache file if it wants to.
3139 # Prefer an explicitly selected file to automatically selected ones.
3140 ac_site_file1=NONE
3141 ac_site_file2=NONE
3142 if test -n "$CONFIG_SITE"; then
3143 ac_site_file1=$CONFIG_SITE
3144 elif test "x$prefix" != xNONE; then
3145 ac_site_file1=$prefix/share/config.site
3146 ac_site_file2=$prefix/etc/config.site
3147 else
3148 ac_site_file1=$ac_default_prefix/share/config.site
3149 ac_site_file2=$ac_default_prefix/etc/config.site
3150 fi
3151 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3152 do
3153 test "x$ac_site_file" = xNONE && continue
3154 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3155 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3156 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3157 sed 's/^/| /' "$ac_site_file" >&5
3158 . "$ac_site_file"
3159 fi
3160 done
3161
3162 if test -r "$cache_file"; then
3163 # Some versions of bash will fail to source /dev/null (special files
3164 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3165 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3166 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3167 $as_echo "$as_me: loading cache $cache_file" >&6;}
3168 case $cache_file in
3169 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3170 *) . "./$cache_file";;
3171 esac
3172 fi
3173 else
3174 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3175 $as_echo "$as_me: creating cache $cache_file" >&6;}
3176 >$cache_file
3177 fi
3178
3179 as_fn_append ac_header_list " linux/version.h"
3180 as_fn_append ac_header_list " sys/systeminfo.h"
3181 as_fn_append ac_header_list " stdio_ext.h"
3182 as_fn_append ac_header_list " fcntl.h"
3183 as_fn_append ac_header_list " coff.h"
3184 as_fn_append ac_header_list " pty.h"
3185 as_fn_append ac_header_list " sys/vlimit.h"
3186 as_fn_append ac_header_list " sys/resource.h"
3187 as_fn_append ac_header_list " sys/utsname.h"
3188 as_fn_append ac_header_list " pwd.h"
3189 as_fn_append ac_header_list " utmp.h"
3190 as_fn_append ac_header_list " dirent.h"
3191 as_fn_append ac_header_list " util.h"
3192 as_fn_append ac_header_list " sys/socket.h"
3193 as_fn_append ac_header_list " stdlib.h"
3194 as_fn_append ac_header_list " unistd.h"
3195 as_fn_append ac_header_list " sys/param.h"
3196 as_fn_append ac_header_list " pthread.h"
3197 as_fn_append ac_header_list " malloc/malloc.h"
3198 as_fn_append ac_header_list " maillock.h"
3199 as_fn_append ac_header_list " sys/un.h"
3200 as_fn_append ac_func_list " tzset"
3201 as_fn_append ac_func_list " readlinkat"
3202 as_fn_append ac_header_list " execinfo.h"
3203 gl_getopt_required=GNU
3204 as_fn_append ac_header_list " getopt.h"
3205 as_fn_append ac_func_list " gettimeofday"
3206 as_fn_append ac_func_list " nanotime"
3207 as_fn_append ac_header_list " sys/time.h"
3208 as_fn_append ac_header_list " wchar.h"
3209 as_fn_append ac_header_list " stdint.h"
3210 as_fn_append ac_header_list " inttypes.h"
3211 as_fn_append ac_func_list " lstat"
3212 as_fn_append ac_func_list " alarm"
3213 as_fn_append ac_header_list " sys/select.h"
3214 as_fn_append ac_func_list " pselect"
3215 as_fn_append ac_func_list " pthread_sigmask"
3216 as_fn_append ac_func_list " readlink"
3217 as_fn_append ac_func_list " strtoimax"
3218 as_fn_append ac_func_list " strtoumax"
3219 as_fn_append ac_func_list " symlink"
3220 as_fn_append ac_header_list " sys/stat.h"
3221 as_fn_append ac_func_list " localtime_r"
3222 as_fn_append ac_header_list " utime.h"
3223 as_fn_append ac_func_list " futimes"
3224 as_fn_append ac_func_list " futimesat"
3225 as_fn_append ac_func_list " futimens"
3226 as_fn_append ac_func_list " utimensat"
3227 as_fn_append ac_func_list " lutimes"
3228 # Check that the precious variables saved in the cache have kept the same
3229 # value.
3230 ac_cache_corrupted=false
3231 for ac_var in $ac_precious_vars; do
3232 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3233 eval ac_new_set=\$ac_env_${ac_var}_set
3234 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3235 eval ac_new_val=\$ac_env_${ac_var}_value
3236 case $ac_old_set,$ac_new_set in
3237 set,)
3238 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3239 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3240 ac_cache_corrupted=: ;;
3241 ,set)
3242 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3243 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3244 ac_cache_corrupted=: ;;
3245 ,);;
3246 *)
3247 if test "x$ac_old_val" != "x$ac_new_val"; then
3248 # differences in whitespace do not lead to failure.
3249 ac_old_val_w=`echo x $ac_old_val`
3250 ac_new_val_w=`echo x $ac_new_val`
3251 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3252 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3253 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3254 ac_cache_corrupted=:
3255 else
3256 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3257 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3258 eval $ac_var=\$ac_old_val
3259 fi
3260 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3261 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3262 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3263 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3264 fi;;
3265 esac
3266 # Pass precious variables to config.status.
3267 if test "$ac_new_set" = set; then
3268 case $ac_new_val in
3269 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3270 *) ac_arg=$ac_var=$ac_new_val ;;
3271 esac
3272 case " $ac_configure_args " in
3273 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3274 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3275 esac
3276 fi
3277 done
3278 if $ac_cache_corrupted; then
3279 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3280 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3281 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3282 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3283 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3284 fi
3285 ## -------------------- ##
3286 ## Main body of script. ##
3287 ## -------------------- ##
3288
3289 ac_ext=c
3290 ac_cpp='$CPP $CPPFLAGS'
3291 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3292 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3293 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3294
3295
3296 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3297
3298
3299 ac_aux_dir=
3300 for ac_dir in build-aux "$srcdir"/build-aux; do
3301 for ac_t in install-sh install.sh shtool; do
3302 if test -f "$ac_dir/$ac_t"; then
3303 ac_aux_dir=$ac_dir
3304 ac_install_sh="$ac_aux_dir/$ac_t -c"
3305 break 2
3306 fi
3307 done
3308 done
3309 if test -z "$ac_aux_dir"; then
3310 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3311 fi
3312
3313 # These three variables are undocumented and unsupported,
3314 # and are intended to be withdrawn in a future Autoconf release.
3315 # They can cause serious problems if a builder's source tree is in a directory
3316 # whose full name contains unusual characters.
3317 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3318 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3319 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3320
3321
3322 am__api_version='1.11'
3323
3324 # Find a good install program. We prefer a C program (faster),
3325 # so one script is as good as another. But avoid the broken or
3326 # incompatible versions:
3327 # SysV /etc/install, /usr/sbin/install
3328 # SunOS /usr/etc/install
3329 # IRIX /sbin/install
3330 # AIX /bin/install
3331 # AmigaOS /C/install, which installs bootblocks on floppy discs
3332 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3333 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3334 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3335 # OS/2's system install, which has a completely different semantic
3336 # ./install, which can be erroneously created by make from ./install.sh.
3337 # Reject install programs that cannot install multiple files.
3338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3339 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3340 if test -z "$INSTALL"; then
3341 if test "${ac_cv_path_install+set}" = set; then :
3342 $as_echo_n "(cached) " >&6
3343 else
3344 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3345 for as_dir in $PATH
3346 do
3347 IFS=$as_save_IFS
3348 test -z "$as_dir" && as_dir=.
3349 # Account for people who put trailing slashes in PATH elements.
3350 case $as_dir/ in #((
3351 ./ | .// | /[cC]/* | \
3352 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3353 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3354 /usr/ucb/* ) ;;
3355 *)
3356 # OSF1 and SCO ODT 3.0 have their own names for install.
3357 # Don't use installbsd from OSF since it installs stuff as root
3358 # by default.
3359 for ac_prog in ginstall scoinst install; do
3360 for ac_exec_ext in '' $ac_executable_extensions; do
3361 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3362 if test $ac_prog = install &&
3363 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3364 # AIX install. It has an incompatible calling convention.
3365 :
3366 elif test $ac_prog = install &&
3367 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3368 # program-specific install script used by HP pwplus--don't use.
3369 :
3370 else
3371 rm -rf conftest.one conftest.two conftest.dir
3372 echo one > conftest.one
3373 echo two > conftest.two
3374 mkdir conftest.dir
3375 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3376 test -s conftest.one && test -s conftest.two &&
3377 test -s conftest.dir/conftest.one &&
3378 test -s conftest.dir/conftest.two
3379 then
3380 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3381 break 3
3382 fi
3383 fi
3384 fi
3385 done
3386 done
3387 ;;
3388 esac
3389
3390 done
3391 IFS=$as_save_IFS
3392
3393 rm -rf conftest.one conftest.two conftest.dir
3394
3395 fi
3396 if test "${ac_cv_path_install+set}" = set; then
3397 INSTALL=$ac_cv_path_install
3398 else
3399 # As a last resort, use the slow shell script. Don't cache a
3400 # value for INSTALL within a source directory, because that will
3401 # break other packages using the cache if that directory is
3402 # removed, or if the value is a relative name.
3403 INSTALL=$ac_install_sh
3404 fi
3405 fi
3406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3407 $as_echo "$INSTALL" >&6; }
3408
3409 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3410 # It thinks the first close brace ends the variable substitution.
3411 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3412
3413 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3414
3415 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3416
3417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3418 $as_echo_n "checking whether build environment is sane... " >&6; }
3419 # Just in case
3420 sleep 1
3421 echo timestamp > conftest.file
3422 # Reject unsafe characters in $srcdir or the absolute working directory
3423 # name. Accept space and tab only in the latter.
3424 am_lf='
3425 '
3426 case `pwd` in
3427 *[\\\"\#\$\&\'\`$am_lf]*)
3428 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3429 esac
3430 case $srcdir in
3431 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3432 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3433 esac
3434
3435 # Do `set' in a subshell so we don't clobber the current shell's
3436 # arguments. Must try -L first in case configure is actually a
3437 # symlink; some systems play weird games with the mod time of symlinks
3438 # (eg FreeBSD returns the mod time of the symlink's containing
3439 # directory).
3440 if (
3441 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3442 if test "$*" = "X"; then
3443 # -L didn't work.
3444 set X `ls -t "$srcdir/configure" conftest.file`
3445 fi
3446 rm -f conftest.file
3447 if test "$*" != "X $srcdir/configure conftest.file" \
3448 && test "$*" != "X conftest.file $srcdir/configure"; then
3449
3450 # If neither matched, then we have a broken ls. This can happen
3451 # if, for instance, CONFIG_SHELL is bash and it inherits a
3452 # broken ls alias from the environment. This has actually
3453 # happened. Such a system could not be considered "sane".
3454 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3455 alias in your environment" "$LINENO" 5
3456 fi
3457
3458 test "$2" = conftest.file
3459 )
3460 then
3461 # Ok.
3462 :
3463 else
3464 as_fn_error "newly created file is older than distributed files!
3465 Check your system clock" "$LINENO" 5
3466 fi
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3468 $as_echo "yes" >&6; }
3469 test "$program_prefix" != NONE &&
3470 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3471 # Use a double $ so make ignores it.
3472 test "$program_suffix" != NONE &&
3473 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3474 # Double any \ or $.
3475 # By default was `s,x,x', remove it if useless.
3476 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3477 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3478
3479 # expand $ac_aux_dir to an absolute path
3480 am_aux_dir=`cd $ac_aux_dir && pwd`
3481
3482 if test x"${MISSING+set}" != xset; then
3483 case $am_aux_dir in
3484 *\ * | *\ *)
3485 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3486 *)
3487 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3488 esac
3489 fi
3490 # Use eval to expand $SHELL
3491 if eval "$MISSING --run true"; then
3492 am_missing_run="$MISSING --run "
3493 else
3494 am_missing_run=
3495 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3496 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3497 fi
3498
3499 if test x"${install_sh}" != xset; then
3500 case $am_aux_dir in
3501 *\ * | *\ *)
3502 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3503 *)
3504 install_sh="\${SHELL} $am_aux_dir/install-sh"
3505 esac
3506 fi
3507
3508 # Installed binaries are usually stripped using `strip' when the user
3509 # run `make install-strip'. However `strip' might not be the right
3510 # tool to use in cross-compilation environments, therefore Automake
3511 # will honor the `STRIP' environment variable to overrule this program.
3512 if test "$cross_compiling" != no; then
3513 if test -n "$ac_tool_prefix"; then
3514 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3515 set dummy ${ac_tool_prefix}strip; ac_word=$2
3516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3517 $as_echo_n "checking for $ac_word... " >&6; }
3518 if test "${ac_cv_prog_STRIP+set}" = set; then :
3519 $as_echo_n "(cached) " >&6
3520 else
3521 if test -n "$STRIP"; then
3522 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3523 else
3524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3525 for as_dir in $PATH
3526 do
3527 IFS=$as_save_IFS
3528 test -z "$as_dir" && as_dir=.
3529 for ac_exec_ext in '' $ac_executable_extensions; do
3530 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3531 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3533 break 2
3534 fi
3535 done
3536 done
3537 IFS=$as_save_IFS
3538
3539 fi
3540 fi
3541 STRIP=$ac_cv_prog_STRIP
3542 if test -n "$STRIP"; then
3543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3544 $as_echo "$STRIP" >&6; }
3545 else
3546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3547 $as_echo "no" >&6; }
3548 fi
3549
3550
3551 fi
3552 if test -z "$ac_cv_prog_STRIP"; then
3553 ac_ct_STRIP=$STRIP
3554 # Extract the first word of "strip", so it can be a program name with args.
3555 set dummy strip; ac_word=$2
3556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3557 $as_echo_n "checking for $ac_word... " >&6; }
3558 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3559 $as_echo_n "(cached) " >&6
3560 else
3561 if test -n "$ac_ct_STRIP"; then
3562 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3563 else
3564 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3565 for as_dir in $PATH
3566 do
3567 IFS=$as_save_IFS
3568 test -z "$as_dir" && as_dir=.
3569 for ac_exec_ext in '' $ac_executable_extensions; do
3570 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3571 ac_cv_prog_ac_ct_STRIP="strip"
3572 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3573 break 2
3574 fi
3575 done
3576 done
3577 IFS=$as_save_IFS
3578
3579 fi
3580 fi
3581 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3582 if test -n "$ac_ct_STRIP"; then
3583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3584 $as_echo "$ac_ct_STRIP" >&6; }
3585 else
3586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3587 $as_echo "no" >&6; }
3588 fi
3589
3590 if test "x$ac_ct_STRIP" = x; then
3591 STRIP=":"
3592 else
3593 case $cross_compiling:$ac_tool_warned in
3594 yes:)
3595 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3596 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3597 ac_tool_warned=yes ;;
3598 esac
3599 STRIP=$ac_ct_STRIP
3600 fi
3601 else
3602 STRIP="$ac_cv_prog_STRIP"
3603 fi
3604
3605 fi
3606 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3607
3608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3609 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3610 if test -z "$MKDIR_P"; then
3611 if test "${ac_cv_path_mkdir+set}" = set; then :
3612 $as_echo_n "(cached) " >&6
3613 else
3614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3615 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3616 do
3617 IFS=$as_save_IFS
3618 test -z "$as_dir" && as_dir=.
3619 for ac_prog in mkdir gmkdir; do
3620 for ac_exec_ext in '' $ac_executable_extensions; do
3621 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3622 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3623 'mkdir (GNU coreutils) '* | \
3624 'mkdir (coreutils) '* | \
3625 'mkdir (fileutils) '4.1*)
3626 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3627 break 3;;
3628 esac
3629 done
3630 done
3631 done
3632 IFS=$as_save_IFS
3633
3634 fi
3635
3636 test -d ./--version && rmdir ./--version
3637 if test "${ac_cv_path_mkdir+set}" = set; then
3638 MKDIR_P="$ac_cv_path_mkdir -p"
3639 else
3640 # As a last resort, use the slow shell script. Don't cache a
3641 # value for MKDIR_P within a source directory, because that will
3642 # break other packages using the cache if that directory is
3643 # removed, or if the value is a relative name.
3644 MKDIR_P="$ac_install_sh -d"
3645 fi
3646 fi
3647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3648 $as_echo "$MKDIR_P" >&6; }
3649
3650
3651 mkdir_p="$MKDIR_P"
3652 case $mkdir_p in
3653 [\\/$]* | ?:[\\/]*) ;;
3654 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3655 esac
3656
3657 for ac_prog in gawk mawk nawk awk
3658 do
3659 # Extract the first word of "$ac_prog", so it can be a program name with args.
3660 set dummy $ac_prog; ac_word=$2
3661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3662 $as_echo_n "checking for $ac_word... " >&6; }
3663 if test "${ac_cv_prog_AWK+set}" = set; then :
3664 $as_echo_n "(cached) " >&6
3665 else
3666 if test -n "$AWK"; then
3667 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3668 else
3669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3670 for as_dir in $PATH
3671 do
3672 IFS=$as_save_IFS
3673 test -z "$as_dir" && as_dir=.
3674 for ac_exec_ext in '' $ac_executable_extensions; do
3675 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3676 ac_cv_prog_AWK="$ac_prog"
3677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3678 break 2
3679 fi
3680 done
3681 done
3682 IFS=$as_save_IFS
3683
3684 fi
3685 fi
3686 AWK=$ac_cv_prog_AWK
3687 if test -n "$AWK"; then
3688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3689 $as_echo "$AWK" >&6; }
3690 else
3691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3692 $as_echo "no" >&6; }
3693 fi
3694
3695
3696 test -n "$AWK" && break
3697 done
3698
3699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3700 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3701 set x ${MAKE-make}
3702 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3703 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3704 $as_echo_n "(cached) " >&6
3705 else
3706 cat >conftest.make <<\_ACEOF
3707 SHELL = /bin/sh
3708 all:
3709 @echo '@@@%%%=$(MAKE)=@@@%%%'
3710 _ACEOF
3711 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3712 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3713 *@@@%%%=?*=@@@%%%*)
3714 eval ac_cv_prog_make_${ac_make}_set=yes;;
3715 *)
3716 eval ac_cv_prog_make_${ac_make}_set=no;;
3717 esac
3718 rm -f conftest.make
3719 fi
3720 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3722 $as_echo "yes" >&6; }
3723 SET_MAKE=
3724 else
3725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3726 $as_echo "no" >&6; }
3727 SET_MAKE="MAKE=${MAKE-make}"
3728 fi
3729
3730 rm -rf .tst 2>/dev/null
3731 mkdir .tst 2>/dev/null
3732 if test -d .tst; then
3733 am__leading_dot=.
3734 else
3735 am__leading_dot=_
3736 fi
3737 rmdir .tst 2>/dev/null
3738
3739 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3740 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3741 # is not polluted with repeated "-I."
3742 am__isrc=' -I$(srcdir)'
3743 # test to see if srcdir already configured
3744 if test -f $srcdir/config.status; then
3745 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3746 fi
3747 fi
3748
3749 # test whether we have cygpath
3750 if test -z "$CYGPATH_W"; then
3751 if (cygpath --version) >/dev/null 2>/dev/null; then
3752 CYGPATH_W='cygpath -w'
3753 else
3754 CYGPATH_W=echo
3755 fi
3756 fi
3757
3758
3759 # Define the identity of the package.
3760 PACKAGE='emacs'
3761 VERSION='24.2.50'
3762
3763
3764 cat >>confdefs.h <<_ACEOF
3765 #define PACKAGE "$PACKAGE"
3766 _ACEOF
3767
3768
3769 cat >>confdefs.h <<_ACEOF
3770 #define VERSION "$VERSION"
3771 _ACEOF
3772
3773 # Some tools Automake needs.
3774
3775 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3776
3777
3778 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3779
3780
3781 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3782
3783
3784 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3785
3786
3787 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3788
3789 # We need awk for the "check" target. The system "awk" is bad on
3790 # some platforms.
3791 # Always define AMTAR for backward compatibility.
3792
3793 AMTAR=${AMTAR-"${am_missing_run}tar"}
3794
3795 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3796
3797
3798
3799
3800
3801
3802
3803
3804 lispdir='${datadir}/emacs/${version}/lisp'
3805 leimdir='${datadir}/emacs/${version}/leim'
3806 standardlisppath='${lispdir}:${leimdir}'
3807 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3808 '${datadir}/emacs/site-lisp'
3809 lisppath='${locallisppath}:${standardlisppath}'
3810 etcdir='${datadir}/emacs/${version}/etc'
3811 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3812 docdir='${datadir}/emacs/${version}/etc'
3813 gamedir='${localstatedir}/games/emacs'
3814
3815
3816 # Check whether --with-all was given.
3817 if test "${with_all+set}" = set; then :
3818 withval=$with_all; with_features=$withval
3819 else
3820 with_features=yes
3821 fi
3822
3823
3824
3825
3826
3827 # Check whether --with-pop was given.
3828 if test "${with_pop+set}" = set; then :
3829 withval=$with_pop;
3830 else
3831 with_pop=$with_features
3832 fi
3833
3834 if test "$with_pop" = yes; then
3835 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3836
3837 fi
3838
3839
3840 # Check whether --with-kerberos was given.
3841 if test "${with_kerberos+set}" = set; then :
3842 withval=$with_kerberos;
3843 else
3844 with_kerberos=no
3845 fi
3846
3847 if test "$with_kerberos" != no; then
3848 $as_echo "#define KERBEROS 1" >>confdefs.h
3849
3850 fi
3851
3852
3853 # Check whether --with-kerberos5 was given.
3854 if test "${with_kerberos5+set}" = set; then :
3855 withval=$with_kerberos5;
3856 else
3857 with_kerberos5=no
3858 fi
3859
3860 if test "${with_kerberos5}" != no; then
3861 if test "${with_kerberos}" = no; then
3862 with_kerberos=yes
3863 $as_echo "#define KERBEROS 1" >>confdefs.h
3864
3865 fi
3866
3867 $as_echo "#define KERBEROS5 1" >>confdefs.h
3868
3869 fi
3870
3871
3872 # Check whether --with-hesiod was given.
3873 if test "${with_hesiod+set}" = set; then :
3874 withval=$with_hesiod;
3875 else
3876 with_hesiod=no
3877 fi
3878
3879 if test "$with_hesiod" != no; then
3880
3881 $as_echo "#define HESIOD 1" >>confdefs.h
3882
3883 fi
3884
3885
3886 # Check whether --with-mmdf was given.
3887 if test "${with_mmdf+set}" = set; then :
3888 withval=$with_mmdf;
3889 else
3890 with_mmdf=no
3891 fi
3892
3893 if test "$with_mmdf" != no; then
3894
3895 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3896
3897 fi
3898
3899
3900 # Check whether --with-mail-unlink was given.
3901 if test "${with_mail_unlink+set}" = set; then :
3902 withval=$with_mail_unlink;
3903 else
3904 with_mail_unlink=no
3905 fi
3906
3907 if test "$with_mail_unlink" != no; then
3908
3909 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3910
3911 fi
3912
3913
3914 # Check whether --with-mailhost was given.
3915 if test "${with_mailhost+set}" = set; then :
3916 withval=$with_mailhost;
3917 cat >>confdefs.h <<_ACEOF
3918 #define MAILHOST "$withval"
3919 _ACEOF
3920
3921 fi
3922
3923
3924
3925 # Check whether --with-sound was given.
3926 if test "${with_sound+set}" = set; then :
3927 withval=$with_sound;
3928 else
3929 with_sound=$with_features
3930 fi
3931
3932
3933
3934 # Check whether --with-x-toolkit was given.
3935 if test "${with_x_toolkit+set}" = set; then :
3936 withval=$with_x_toolkit; case "${withval}" in
3937 y | ye | yes ) val=gtk ;;
3938 n | no ) val=no ;;
3939 l | lu | luc | luci | lucid ) val=lucid ;;
3940 a | at | ath | athe | athen | athena ) val=athena ;;
3941 m | mo | mot | moti | motif ) val=motif ;;
3942 g | gt | gtk ) val=gtk ;;
3943 gtk2 ) val=gtk2 ;;
3944 gtk3 ) val=gtk3 ;;
3945 * )
3946 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3947 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk',
3948 \`gtk2' or \`gtk3'. \`yes' and \`gtk' are synonyms.
3949 \`athena' and \`lucid' are synonyms." "$LINENO" 5
3950 ;;
3951 esac
3952 with_x_toolkit=$val
3953
3954 fi
3955
3956
3957
3958 # Check whether --with-wide-int was given.
3959 if test "${with_wide_int+set}" = set; then :
3960 withval=$with_wide_int;
3961 else
3962 with_wide_int=no
3963 fi
3964
3965 if test "$with_wide_int" = yes; then
3966
3967 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3968
3969 fi
3970
3971
3972 # Check whether --with-xpm was given.
3973 if test "${with_xpm+set}" = set; then :
3974 withval=$with_xpm;
3975 else
3976 with_xpm=$with_features
3977 fi
3978
3979
3980 # Check whether --with-jpeg was given.
3981 if test "${with_jpeg+set}" = set; then :
3982 withval=$with_jpeg;
3983 else
3984 with_jpeg=$with_features
3985 fi
3986
3987
3988 # Check whether --with-tiff was given.
3989 if test "${with_tiff+set}" = set; then :
3990 withval=$with_tiff;
3991 else
3992 with_tiff=$with_features
3993 fi
3994
3995
3996 # Check whether --with-gif was given.
3997 if test "${with_gif+set}" = set; then :
3998 withval=$with_gif;
3999 else
4000 with_gif=$with_features
4001 fi
4002
4003
4004 # Check whether --with-png was given.
4005 if test "${with_png+set}" = set; then :
4006 withval=$with_png;
4007 else
4008 with_png=$with_features
4009 fi
4010
4011
4012 # Check whether --with-rsvg was given.
4013 if test "${with_rsvg+set}" = set; then :
4014 withval=$with_rsvg;
4015 else
4016 with_rsvg=$with_features
4017 fi
4018
4019
4020 # Check whether --with-xml2 was given.
4021 if test "${with_xml2+set}" = set; then :
4022 withval=$with_xml2;
4023 else
4024 with_xml2=$with_features
4025 fi
4026
4027
4028 # Check whether --with-imagemagick was given.
4029 if test "${with_imagemagick+set}" = set; then :
4030 withval=$with_imagemagick;
4031 else
4032 with_imagemagick=$with_features
4033 fi
4034
4035
4036
4037 # Check whether --with-xft was given.
4038 if test "${with_xft+set}" = set; then :
4039 withval=$with_xft;
4040 else
4041 with_xft=$with_features
4042 fi
4043
4044
4045 # Check whether --with-libotf was given.
4046 if test "${with_libotf+set}" = set; then :
4047 withval=$with_libotf;
4048 else
4049 with_libotf=$with_features
4050 fi
4051
4052
4053 # Check whether --with-m17n-flt was given.
4054 if test "${with_m17n_flt+set}" = set; then :
4055 withval=$with_m17n_flt;
4056 else
4057 with_m17n_flt=$with_features
4058 fi
4059
4060
4061
4062 # Check whether --with-toolkit-scroll-bars was given.
4063 if test "${with_toolkit_scroll_bars+set}" = set; then :
4064 withval=$with_toolkit_scroll_bars;
4065 else
4066 with_toolkit_scroll_bars=$with_features
4067 fi
4068
4069
4070 # Check whether --with-xaw3d was given.
4071 if test "${with_xaw3d+set}" = set; then :
4072 withval=$with_xaw3d;
4073 else
4074 with_xaw3d=$with_features
4075 fi
4076
4077
4078 # Check whether --with-xim was given.
4079 if test "${with_xim+set}" = set; then :
4080 withval=$with_xim;
4081 else
4082 with_xim=$with_features
4083 fi
4084
4085
4086 # Check whether --with-ns was given.
4087 if test "${with_ns+set}" = set; then :
4088 withval=$with_ns;
4089 else
4090 with_ns=no
4091 fi
4092
4093
4094
4095 # Check whether --with-gpm was given.
4096 if test "${with_gpm+set}" = set; then :
4097 withval=$with_gpm;
4098 else
4099 with_gpm=$with_features
4100 fi
4101
4102
4103 # Check whether --with-dbus was given.
4104 if test "${with_dbus+set}" = set; then :
4105 withval=$with_dbus;
4106 else
4107 with_dbus=$with_features
4108 fi
4109
4110
4111 # Check whether --with-gconf was given.
4112 if test "${with_gconf+set}" = set; then :
4113 withval=$with_gconf;
4114 else
4115 with_gconf=$with_features
4116 fi
4117
4118
4119 # Check whether --with-gsettings was given.
4120 if test "${with_gsettings+set}" = set; then :
4121 withval=$with_gsettings;
4122 else
4123 with_gsettings=$with_features
4124 fi
4125
4126
4127 # Check whether --with-selinux was given.
4128 if test "${with_selinux+set}" = set; then :
4129 withval=$with_selinux;
4130 else
4131 with_selinux=$with_features
4132 fi
4133
4134
4135 # Check whether --with-gnutls was given.
4136 if test "${with_gnutls+set}" = set; then :
4137 withval=$with_gnutls;
4138 else
4139 with_gnutls=$with_features
4140 fi
4141
4142
4143 ## For the times when you want to build Emacs but don't have
4144 ## a suitable makeinfo, and can live without the manuals.
4145
4146 # Check whether --with-makeinfo was given.
4147 if test "${with_makeinfo+set}" = set; then :
4148 withval=$with_makeinfo;
4149 else
4150 with_makeinfo=$with_features
4151 fi
4152
4153
4154 ## Makefile.in needs the cache file name.
4155
4156
4157 ## This is an option because I do not know if all info/man support
4158 ## compressed files, nor how to test if they do so.
4159
4160 # Check whether --with-compress-info was given.
4161 if test "${with_compress_info+set}" = set; then :
4162 withval=$with_compress_info;
4163 else
4164 with_compress_info=$with_features
4165 fi
4166
4167 if test $with_compress_info = yes; then
4168 GZIP_INFO=yes
4169 else
4170 GZIP_INFO=
4171 fi
4172
4173
4174
4175 # Check whether --with-pkg-config-prog was given.
4176 if test "${with_pkg_config_prog+set}" = set; then :
4177 withval=$with_pkg_config_prog;
4178 fi
4179
4180 if test "X${with_pkg_config_prog}" != X; then
4181 if test "${with_pkg_config_prog}" != yes; then
4182 PKG_CONFIG="${with_pkg_config_prog}"
4183 fi
4184 fi
4185
4186 CRT_DIR=
4187
4188 # Check whether --with-crt-dir was given.
4189 if test "${with_crt_dir+set}" = set; then :
4190 withval=$with_crt_dir;
4191 fi
4192
4193 CRT_DIR="${with_crt_dir}"
4194
4195
4196 # Check whether --with-gameuser was given.
4197 if test "${with_gameuser+set}" = set; then :
4198 withval=$with_gameuser;
4199 fi
4200
4201 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4202 && gameuser="${with_gameuser}"
4203 test "X$gameuser" = X && gameuser=games
4204
4205
4206 # Check whether --with-gnustep-conf was given.
4207 if test "${with_gnustep_conf+set}" = set; then :
4208 withval=$with_gnustep_conf;
4209 fi
4210
4211 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4212 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4213 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4214 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4215
4216 # Check whether --enable-ns-self-contained was given.
4217 if test "${enable_ns_self_contained+set}" = set; then :
4218 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4219 else
4220 EN_NS_SELF_CONTAINED=yes
4221 fi
4222
4223
4224 # Check whether --enable-locallisppath was given.
4225 if test "${enable_locallisppath+set}" = set; then :
4226 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4227 locallisppath=
4228 elif test "${enableval}" != "yes"; then
4229 locallisppath=${enableval}
4230 fi
4231 fi
4232
4233
4234 # Check whether --enable-checking was given.
4235 if test "${enable_checking+set}" = set; then :
4236 enableval=$enable_checking; ac_checking_flags="${enableval}"
4237 fi
4238
4239 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4240 for check in $ac_checking_flags
4241 do
4242 case $check in
4243 # these set all the flags to specific states
4244 yes) ac_enable_checking=1 ;;
4245 no) ac_enable_checking= ;
4246 ac_gc_check_stringbytes= ;
4247 ac_gc_check_string_overrun= ;
4248 ac_gc_check_string_free_list= ;
4249 ac_xmalloc_overrun= ;
4250 ac_gc_check_cons_list= ;
4251 ac_glyphs_debug= ;;
4252 all) ac_enable_checking=1 ;
4253 ac_gc_check_stringbytes=1 ;
4254 ac_gc_check_string_overrun=1 ;
4255 ac_gc_check_string_free_list=1 ;
4256 ac_xmalloc_overrun=1 ;
4257 ac_gc_check_cons_list=1 ;
4258 ac_glyphs_debug=1 ;;
4259 # these enable particular checks
4260 stringbytes) ac_gc_check_stringbytes=1 ;;
4261 stringoverrun) ac_gc_check_string_overrun=1 ;;
4262 stringfreelist) ac_gc_check_string_free_list=1 ;;
4263 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4264 conslist) ac_gc_check_cons_list=1 ;;
4265 glyphs) ac_glyphs_debug=1 ;;
4266 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4267 esac
4268 done
4269 IFS="$ac_save_IFS"
4270
4271 if test x$ac_enable_checking != x ; then
4272
4273 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4274
4275 fi
4276 if test x$ac_gc_check_stringbytes != x ; then
4277
4278 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4279
4280 fi
4281 if test x$ac_gc_check_string_overrun != x ; then
4282
4283 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4284
4285 fi
4286 if test x$ac_gc_check_string_free_list != x ; then
4287
4288 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4289
4290 fi
4291 if test x$ac_xmalloc_overrun != x ; then
4292
4293 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4294
4295 fi
4296 if test x$ac_gc_check_cons_list != x ; then
4297
4298 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4299
4300 fi
4301 if test x$ac_glyphs_debug != x ; then
4302
4303 $as_echo "#define GLYPH_DEBUG 1" >>confdefs.h
4304
4305 fi
4306
4307 # Check whether --enable-check-lisp-object-type was given.
4308 if test "${enable_check_lisp_object_type+set}" = set; then :
4309 enableval=$enable_check_lisp_object_type; if test "${enableval}" != "no"; then
4310
4311 $as_echo "#define CHECK_LISP_OBJECT_TYPE 1" >>confdefs.h
4312
4313 fi
4314 fi
4315
4316
4317
4318 # Check whether --enable-profiling was given.
4319 if test "${enable_profiling+set}" = set; then :
4320 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4321 fi
4322
4323 if test x$ac_enable_profiling != x ; then
4324 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4325 else
4326 PROFILING_CFLAGS=
4327 fi
4328
4329
4330 # Check whether --enable-autodepend was given.
4331 if test "${enable_autodepend+set}" = set; then :
4332 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4333 else
4334 ac_enable_autodepend=yes
4335 fi
4336
4337
4338 #### Make srcdir absolute, if it isn't already. It's important to
4339 #### avoid running the path through pwd unnecessarily, since pwd can
4340 #### give you automounter prefixes, which can go away. We do all this
4341 #### so Emacs can find its files when run uninstalled.
4342 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4343 unset CDPATH
4344 case "${srcdir}" in
4345 /* ) ;;
4346 . )
4347 ## We may be able to use the $PWD environment variable to make this
4348 ## absolute. But sometimes PWD is inaccurate.
4349 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4350 ## but that tested only for a well-formed and valid PWD,
4351 ## it did not object when PWD was well-formed and valid but just wrong.
4352 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4353 then
4354 srcdir="$PWD"
4355 else
4356 srcdir="`(cd ${srcdir}; pwd)`"
4357 fi
4358 ;;
4359 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4360 esac
4361
4362 ### Canonicalize the configuration name.
4363
4364 # Make sure we can run config.sub.
4365 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4366 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4367
4368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4369 $as_echo_n "checking build system type... " >&6; }
4370 if test "${ac_cv_build+set}" = set; then :
4371 $as_echo_n "(cached) " >&6
4372 else
4373 ac_build_alias=$build_alias
4374 test "x$ac_build_alias" = x &&
4375 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4376 test "x$ac_build_alias" = x &&
4377 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4378 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4379 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4380
4381 fi
4382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4383 $as_echo "$ac_cv_build" >&6; }
4384 case $ac_cv_build in
4385 *-*-*) ;;
4386 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4387 esac
4388 build=$ac_cv_build
4389 ac_save_IFS=$IFS; IFS='-'
4390 set x $ac_cv_build
4391 shift
4392 build_cpu=$1
4393 build_vendor=$2
4394 shift; shift
4395 # Remember, the first character of IFS is used to create $*,
4396 # except with old shells:
4397 build_os=$*
4398 IFS=$ac_save_IFS
4399 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4400
4401
4402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4403 $as_echo_n "checking host system type... " >&6; }
4404 if test "${ac_cv_host+set}" = set; then :
4405 $as_echo_n "(cached) " >&6
4406 else
4407 if test "x$host_alias" = x; then
4408 ac_cv_host=$ac_cv_build
4409 else
4410 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4411 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4412 fi
4413
4414 fi
4415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4416 $as_echo "$ac_cv_host" >&6; }
4417 case $ac_cv_host in
4418 *-*-*) ;;
4419 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4420 esac
4421 host=$ac_cv_host
4422 ac_save_IFS=$IFS; IFS='-'
4423 set x $ac_cv_host
4424 shift
4425 host_cpu=$1
4426 host_vendor=$2
4427 shift; shift
4428 # Remember, the first character of IFS is used to create $*,
4429 # except with old shells:
4430 host_os=$*
4431 IFS=$ac_save_IFS
4432 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4433
4434
4435 canonical=$host
4436 configuration=${host_alias-${build_alias-$host}}
4437
4438
4439
4440 ### If you add support for a new configuration, add code to this
4441 ### switch statement to recognize your configuration name and select
4442 ### the appropriate operating system file.
4443
4444 ### You would hope that you could choose an s/*.h
4445 ### file based on the operating system portion. However, it turns out
4446 ### that each s/*.h file is pretty manufacturer-specific.
4447 ### So we basically have to have a special case for each
4448 ### configuration name.
4449 ###
4450 ### As far as handling version numbers on operating systems is
4451 ### concerned, make sure things will fail in a fixable way. If
4452 ### /etc/MACHINES doesn't say anything about version numbers, be
4453 ### prepared to handle anything reasonably. If version numbers
4454 ### matter, be sure /etc/MACHINES says something about it.
4455
4456 opsys='' unported=no
4457 case "${canonical}" in
4458
4459 ## GNU/Linux and similar ports
4460 *-*-linux* )
4461 opsys=gnu-linux
4462 ;;
4463
4464 ## FreeBSD ports
4465 *-*-freebsd* )
4466 opsys=freebsd
4467 ;;
4468
4469 ## FreeBSD kernel + glibc based userland
4470 *-*-kfreebsd*gnu* )
4471 opsys=gnu-kfreebsd
4472 ;;
4473
4474 ## NetBSD ports
4475 *-*-netbsd* )
4476 opsys=netbsd
4477 ;;
4478
4479 ## OpenBSD ports
4480 *-*-openbsd* )
4481 opsys=openbsd
4482 ;;
4483
4484 ## Apple Darwin / Mac OS X
4485 *-apple-darwin* )
4486 case "${canonical}" in
4487 i[3456]86-* ) ;;
4488 powerpc-* ) ;;
4489 x86_64-* ) ;;
4490 * ) unported=yes ;;
4491 esac
4492 opsys=darwin
4493 ## Use fink packages if available.
4494 ## FIXME find a better way to do this: http://debbugs.gnu.org/11507
4495 ## if test -d /sw/include && test -d /sw/lib; then
4496 ## GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4497 ## NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4498 ## fi
4499 ;;
4500
4501 ## HP 9000 series 700 and 800, running HP/UX
4502 hppa*-hp-hpux10.2* )
4503 opsys=hpux10-20
4504 ;;
4505 hppa*-hp-hpux1[1-9]* )
4506 opsys=hpux11
4507 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4508 ;;
4509
4510 ## IBM machines
4511 rs6000-ibm-aix4.[23]* )
4512 opsys=aix4-2
4513 ;;
4514 powerpc-ibm-aix4.[23]* )
4515 opsys=aix4-2
4516 ;;
4517 rs6000-ibm-aix[56]* )
4518 opsys=aix4-2
4519 ;;
4520 powerpc-ibm-aix[56]* )
4521 opsys=aix4-2
4522 ;;
4523
4524 ## Silicon Graphics machines
4525 ## Iris 4D
4526 mips-sgi-irix6.5 )
4527 opsys=irix6-5
4528 # Without defining _LANGUAGE_C, things get masked out in the headers
4529 # so that, for instance, grepping for `free' in stdlib.h fails and
4530 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4531 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4532 ;;
4533
4534 ## Suns
4535 *-sun-solaris* \
4536 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4537 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4538 case "${canonical}" in
4539 i[3456]86-*-* ) ;;
4540 amd64-*-*|x86_64-*-*) ;;
4541 sparc* ) ;;
4542 * ) unported=yes ;;
4543 esac
4544 case "${canonical}" in
4545 *-sunos5.6* | *-solaris2.6* )
4546 opsys=sol2-6
4547 RANLIB="ar -ts"
4548 ;;
4549 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4550 opsys=sol2-6
4551 emacs_check_sunpro_c=yes
4552 ;;
4553 *-sunos5* | *-solaris* )
4554 opsys=sol2-10
4555 emacs_check_sunpro_c=yes
4556 ;;
4557 esac
4558 ## Watch out for a compiler that we know will not work.
4559 case "${canonical}" in
4560 *-solaris* | *-sunos5* )
4561 if [ "x$CC" = x/usr/ucb/cc ]; then
4562 ## /usr/ucb/cc doesn't work;
4563 ## we should find some other compiler that does work.
4564 unset CC
4565 fi
4566 ;;
4567 *) ;;
4568 esac
4569 ;;
4570
4571 ## Intel 386 machines where we don't care about the manufacturer.
4572 i[3456]86-*-* )
4573 case "${canonical}" in
4574 *-cygwin ) opsys=cygwin ;;
4575 *-darwin* ) opsys=darwin ;;
4576 *-sysv4.2uw* ) opsys=unixware ;;
4577 *-sysv5uw* ) opsys=unixware ;;
4578 *-sysv5OpenUNIX* ) opsys=unixware ;;
4579 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4580 esac
4581 ;;
4582
4583 * )
4584 unported=yes
4585 ;;
4586 esac
4587
4588 ### If the code above didn't choose an operating system, just choose
4589 ### an operating system based on the configuration name. You really
4590 ### only want to use this when you have no idea what the right
4591 ### operating system is; if you know what operating systems a machine
4592 ### runs, it's cleaner to make it explicit in the case statement
4593 ### above.
4594 if test x"${opsys}" = x; then
4595 case "${canonical}" in
4596 *-gnu* ) opsys=gnu ;;
4597 * )
4598 unported=yes
4599 ;;
4600 esac
4601 fi
4602
4603
4604
4605 if test $unported = yes; then
4606 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4607 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4608 fi
4609
4610
4611 #### Choose a compiler.
4612
4613 ac_ext=c
4614 ac_cpp='$CPP $CPPFLAGS'
4615 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4616 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4617 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4618 if test -n "$ac_tool_prefix"; then
4619 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4620 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4622 $as_echo_n "checking for $ac_word... " >&6; }
4623 if test "${ac_cv_prog_CC+set}" = set; then :
4624 $as_echo_n "(cached) " >&6
4625 else
4626 if test -n "$CC"; then
4627 ac_cv_prog_CC="$CC" # Let the user override the test.
4628 else
4629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4630 for as_dir in $PATH
4631 do
4632 IFS=$as_save_IFS
4633 test -z "$as_dir" && as_dir=.
4634 for ac_exec_ext in '' $ac_executable_extensions; do
4635 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4636 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4638 break 2
4639 fi
4640 done
4641 done
4642 IFS=$as_save_IFS
4643
4644 fi
4645 fi
4646 CC=$ac_cv_prog_CC
4647 if test -n "$CC"; then
4648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4649 $as_echo "$CC" >&6; }
4650 else
4651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4652 $as_echo "no" >&6; }
4653 fi
4654
4655
4656 fi
4657 if test -z "$ac_cv_prog_CC"; then
4658 ac_ct_CC=$CC
4659 # Extract the first word of "gcc", so it can be a program name with args.
4660 set dummy gcc; ac_word=$2
4661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4662 $as_echo_n "checking for $ac_word... " >&6; }
4663 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4664 $as_echo_n "(cached) " >&6
4665 else
4666 if test -n "$ac_ct_CC"; then
4667 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4668 else
4669 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4670 for as_dir in $PATH
4671 do
4672 IFS=$as_save_IFS
4673 test -z "$as_dir" && as_dir=.
4674 for ac_exec_ext in '' $ac_executable_extensions; do
4675 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4676 ac_cv_prog_ac_ct_CC="gcc"
4677 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4678 break 2
4679 fi
4680 done
4681 done
4682 IFS=$as_save_IFS
4683
4684 fi
4685 fi
4686 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4687 if test -n "$ac_ct_CC"; then
4688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4689 $as_echo "$ac_ct_CC" >&6; }
4690 else
4691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4692 $as_echo "no" >&6; }
4693 fi
4694
4695 if test "x$ac_ct_CC" = x; then
4696 CC=""
4697 else
4698 case $cross_compiling:$ac_tool_warned in
4699 yes:)
4700 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4701 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4702 ac_tool_warned=yes ;;
4703 esac
4704 CC=$ac_ct_CC
4705 fi
4706 else
4707 CC="$ac_cv_prog_CC"
4708 fi
4709
4710 if test -z "$CC"; then
4711 if test -n "$ac_tool_prefix"; then
4712 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4713 set dummy ${ac_tool_prefix}cc; ac_word=$2
4714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4715 $as_echo_n "checking for $ac_word... " >&6; }
4716 if test "${ac_cv_prog_CC+set}" = set; then :
4717 $as_echo_n "(cached) " >&6
4718 else
4719 if test -n "$CC"; then
4720 ac_cv_prog_CC="$CC" # Let the user override the test.
4721 else
4722 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4723 for as_dir in $PATH
4724 do
4725 IFS=$as_save_IFS
4726 test -z "$as_dir" && as_dir=.
4727 for ac_exec_ext in '' $ac_executable_extensions; do
4728 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4729 ac_cv_prog_CC="${ac_tool_prefix}cc"
4730 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4731 break 2
4732 fi
4733 done
4734 done
4735 IFS=$as_save_IFS
4736
4737 fi
4738 fi
4739 CC=$ac_cv_prog_CC
4740 if test -n "$CC"; then
4741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4742 $as_echo "$CC" >&6; }
4743 else
4744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4745 $as_echo "no" >&6; }
4746 fi
4747
4748
4749 fi
4750 fi
4751 if test -z "$CC"; then
4752 # Extract the first word of "cc", so it can be a program name with args.
4753 set dummy cc; ac_word=$2
4754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4755 $as_echo_n "checking for $ac_word... " >&6; }
4756 if test "${ac_cv_prog_CC+set}" = set; then :
4757 $as_echo_n "(cached) " >&6
4758 else
4759 if test -n "$CC"; then
4760 ac_cv_prog_CC="$CC" # Let the user override the test.
4761 else
4762 ac_prog_rejected=no
4763 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4764 for as_dir in $PATH
4765 do
4766 IFS=$as_save_IFS
4767 test -z "$as_dir" && as_dir=.
4768 for ac_exec_ext in '' $ac_executable_extensions; do
4769 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4770 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4771 ac_prog_rejected=yes
4772 continue
4773 fi
4774 ac_cv_prog_CC="cc"
4775 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4776 break 2
4777 fi
4778 done
4779 done
4780 IFS=$as_save_IFS
4781
4782 if test $ac_prog_rejected = yes; then
4783 # We found a bogon in the path, so make sure we never use it.
4784 set dummy $ac_cv_prog_CC
4785 shift
4786 if test $# != 0; then
4787 # We chose a different compiler from the bogus one.
4788 # However, it has the same basename, so the bogon will be chosen
4789 # first if we set CC to just the basename; use the full file name.
4790 shift
4791 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4792 fi
4793 fi
4794 fi
4795 fi
4796 CC=$ac_cv_prog_CC
4797 if test -n "$CC"; then
4798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4799 $as_echo "$CC" >&6; }
4800 else
4801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4802 $as_echo "no" >&6; }
4803 fi
4804
4805
4806 fi
4807 if test -z "$CC"; then
4808 if test -n "$ac_tool_prefix"; then
4809 for ac_prog in cl.exe
4810 do
4811 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4812 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4814 $as_echo_n "checking for $ac_word... " >&6; }
4815 if test "${ac_cv_prog_CC+set}" = set; then :
4816 $as_echo_n "(cached) " >&6
4817 else
4818 if test -n "$CC"; then
4819 ac_cv_prog_CC="$CC" # Let the user override the test.
4820 else
4821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4822 for as_dir in $PATH
4823 do
4824 IFS=$as_save_IFS
4825 test -z "$as_dir" && as_dir=.
4826 for ac_exec_ext in '' $ac_executable_extensions; do
4827 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4828 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4830 break 2
4831 fi
4832 done
4833 done
4834 IFS=$as_save_IFS
4835
4836 fi
4837 fi
4838 CC=$ac_cv_prog_CC
4839 if test -n "$CC"; then
4840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4841 $as_echo "$CC" >&6; }
4842 else
4843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4844 $as_echo "no" >&6; }
4845 fi
4846
4847
4848 test -n "$CC" && break
4849 done
4850 fi
4851 if test -z "$CC"; then
4852 ac_ct_CC=$CC
4853 for ac_prog in cl.exe
4854 do
4855 # Extract the first word of "$ac_prog", so it can be a program name with args.
4856 set dummy $ac_prog; ac_word=$2
4857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4858 $as_echo_n "checking for $ac_word... " >&6; }
4859 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4860 $as_echo_n "(cached) " >&6
4861 else
4862 if test -n "$ac_ct_CC"; then
4863 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4864 else
4865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4866 for as_dir in $PATH
4867 do
4868 IFS=$as_save_IFS
4869 test -z "$as_dir" && as_dir=.
4870 for ac_exec_ext in '' $ac_executable_extensions; do
4871 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4872 ac_cv_prog_ac_ct_CC="$ac_prog"
4873 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4874 break 2
4875 fi
4876 done
4877 done
4878 IFS=$as_save_IFS
4879
4880 fi
4881 fi
4882 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4883 if test -n "$ac_ct_CC"; then
4884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4885 $as_echo "$ac_ct_CC" >&6; }
4886 else
4887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4888 $as_echo "no" >&6; }
4889 fi
4890
4891
4892 test -n "$ac_ct_CC" && break
4893 done
4894
4895 if test "x$ac_ct_CC" = x; then
4896 CC=""
4897 else
4898 case $cross_compiling:$ac_tool_warned in
4899 yes:)
4900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4901 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4902 ac_tool_warned=yes ;;
4903 esac
4904 CC=$ac_ct_CC
4905 fi
4906 fi
4907
4908 fi
4909
4910
4911 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4912 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4913 as_fn_error "no acceptable C compiler found in \$PATH
4914 See \`config.log' for more details." "$LINENO" 5; }
4915
4916 # Provide some information about the compiler.
4917 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4918 set X $ac_compile
4919 ac_compiler=$2
4920 for ac_option in --version -v -V -qversion; do
4921 { { ac_try="$ac_compiler $ac_option >&5"
4922 case "(($ac_try" in
4923 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4924 *) ac_try_echo=$ac_try;;
4925 esac
4926 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4927 $as_echo "$ac_try_echo"; } >&5
4928 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4929 ac_status=$?
4930 if test -s conftest.err; then
4931 sed '10a\
4932 ... rest of stderr output deleted ...
4933 10q' conftest.err >conftest.er1
4934 cat conftest.er1 >&5
4935 fi
4936 rm -f conftest.er1 conftest.err
4937 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4938 test $ac_status = 0; }
4939 done
4940
4941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4942 /* end confdefs.h. */
4943
4944 int
4945 main ()
4946 {
4947
4948 ;
4949 return 0;
4950 }
4951 _ACEOF
4952 ac_clean_files_save=$ac_clean_files
4953 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4954 # Try to create an executable without -o first, disregard a.out.
4955 # It will help us diagnose broken compilers, and finding out an intuition
4956 # of exeext.
4957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4958 $as_echo_n "checking whether the C compiler works... " >&6; }
4959 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4960
4961 # The possible output files:
4962 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4963
4964 ac_rmfiles=
4965 for ac_file in $ac_files
4966 do
4967 case $ac_file in
4968 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4969 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4970 esac
4971 done
4972 rm -f $ac_rmfiles
4973
4974 if { { ac_try="$ac_link_default"
4975 case "(($ac_try" in
4976 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4977 *) ac_try_echo=$ac_try;;
4978 esac
4979 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4980 $as_echo "$ac_try_echo"; } >&5
4981 (eval "$ac_link_default") 2>&5
4982 ac_status=$?
4983 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4984 test $ac_status = 0; }; then :
4985 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4986 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4987 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4988 # so that the user can short-circuit this test for compilers unknown to
4989 # Autoconf.
4990 for ac_file in $ac_files ''
4991 do
4992 test -f "$ac_file" || continue
4993 case $ac_file in
4994 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4995 ;;
4996 [ab].out )
4997 # We found the default executable, but exeext='' is most
4998 # certainly right.
4999 break;;
5000 *.* )
5001 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5002 then :; else
5003 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5004 fi
5005 # We set ac_cv_exeext here because the later test for it is not
5006 # safe: cross compilers may not add the suffix if given an `-o'
5007 # argument, so we may need to know it at that point already.
5008 # Even if this section looks crufty: it has the advantage of
5009 # actually working.
5010 break;;
5011 * )
5012 break;;
5013 esac
5014 done
5015 test "$ac_cv_exeext" = no && ac_cv_exeext=
5016
5017 else
5018 ac_file=''
5019 fi
5020 if test -z "$ac_file"; then :
5021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5022 $as_echo "no" >&6; }
5023 $as_echo "$as_me: failed program was:" >&5
5024 sed 's/^/| /' conftest.$ac_ext >&5
5025
5026 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5027 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5028 { as_fn_set_status 77
5029 as_fn_error "C compiler cannot create executables
5030 See \`config.log' for more details." "$LINENO" 5; }; }
5031 else
5032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5033 $as_echo "yes" >&6; }
5034 fi
5035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5036 $as_echo_n "checking for C compiler default output file name... " >&6; }
5037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5038 $as_echo "$ac_file" >&6; }
5039 ac_exeext=$ac_cv_exeext
5040
5041 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5042 ac_clean_files=$ac_clean_files_save
5043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5044 $as_echo_n "checking for suffix of executables... " >&6; }
5045 if { { ac_try="$ac_link"
5046 case "(($ac_try" in
5047 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5048 *) ac_try_echo=$ac_try;;
5049 esac
5050 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5051 $as_echo "$ac_try_echo"; } >&5
5052 (eval "$ac_link") 2>&5
5053 ac_status=$?
5054 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5055 test $ac_status = 0; }; then :
5056 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5057 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5058 # work properly (i.e., refer to `conftest.exe'), while it won't with
5059 # `rm'.
5060 for ac_file in conftest.exe conftest conftest.*; do
5061 test -f "$ac_file" || continue
5062 case $ac_file in
5063 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5064 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5065 break;;
5066 * ) break;;
5067 esac
5068 done
5069 else
5070 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5071 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5072 as_fn_error "cannot compute suffix of executables: cannot compile and link
5073 See \`config.log' for more details." "$LINENO" 5; }
5074 fi
5075 rm -f conftest conftest$ac_cv_exeext
5076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5077 $as_echo "$ac_cv_exeext" >&6; }
5078
5079 rm -f conftest.$ac_ext
5080 EXEEXT=$ac_cv_exeext
5081 ac_exeext=$EXEEXT
5082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5083 /* end confdefs.h. */
5084 #include <stdio.h>
5085 int
5086 main ()
5087 {
5088 FILE *f = fopen ("conftest.out", "w");
5089 return ferror (f) || fclose (f) != 0;
5090
5091 ;
5092 return 0;
5093 }
5094 _ACEOF
5095 ac_clean_files="$ac_clean_files conftest.out"
5096 # Check that the compiler produces executables we can run. If not, either
5097 # the compiler is broken, or we cross compile.
5098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5099 $as_echo_n "checking whether we are cross compiling... " >&6; }
5100 if test "$cross_compiling" != yes; then
5101 { { ac_try="$ac_link"
5102 case "(($ac_try" in
5103 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5104 *) ac_try_echo=$ac_try;;
5105 esac
5106 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5107 $as_echo "$ac_try_echo"; } >&5
5108 (eval "$ac_link") 2>&5
5109 ac_status=$?
5110 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5111 test $ac_status = 0; }
5112 if { ac_try='./conftest$ac_cv_exeext'
5113 { { case "(($ac_try" in
5114 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5115 *) ac_try_echo=$ac_try;;
5116 esac
5117 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5118 $as_echo "$ac_try_echo"; } >&5
5119 (eval "$ac_try") 2>&5
5120 ac_status=$?
5121 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5122 test $ac_status = 0; }; }; then
5123 cross_compiling=no
5124 else
5125 if test "$cross_compiling" = maybe; then
5126 cross_compiling=yes
5127 else
5128 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5129 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5130 as_fn_error "cannot run C compiled programs.
5131 If you meant to cross compile, use \`--host'.
5132 See \`config.log' for more details." "$LINENO" 5; }
5133 fi
5134 fi
5135 fi
5136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5137 $as_echo "$cross_compiling" >&6; }
5138
5139 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5140 ac_clean_files=$ac_clean_files_save
5141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5142 $as_echo_n "checking for suffix of object files... " >&6; }
5143 if test "${ac_cv_objext+set}" = set; then :
5144 $as_echo_n "(cached) " >&6
5145 else
5146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5147 /* end confdefs.h. */
5148
5149 int
5150 main ()
5151 {
5152
5153 ;
5154 return 0;
5155 }
5156 _ACEOF
5157 rm -f conftest.o conftest.obj
5158 if { { ac_try="$ac_compile"
5159 case "(($ac_try" in
5160 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5161 *) ac_try_echo=$ac_try;;
5162 esac
5163 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5164 $as_echo "$ac_try_echo"; } >&5
5165 (eval "$ac_compile") 2>&5
5166 ac_status=$?
5167 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5168 test $ac_status = 0; }; then :
5169 for ac_file in conftest.o conftest.obj conftest.*; do
5170 test -f "$ac_file" || continue;
5171 case $ac_file in
5172 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5173 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5174 break;;
5175 esac
5176 done
5177 else
5178 $as_echo "$as_me: failed program was:" >&5
5179 sed 's/^/| /' conftest.$ac_ext >&5
5180
5181 { { $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 "cannot compute suffix of object files: cannot compile
5184 See \`config.log' for more details." "$LINENO" 5; }
5185 fi
5186 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5187 fi
5188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5189 $as_echo "$ac_cv_objext" >&6; }
5190 OBJEXT=$ac_cv_objext
5191 ac_objext=$OBJEXT
5192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5193 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5194 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5195 $as_echo_n "(cached) " >&6
5196 else
5197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5198 /* end confdefs.h. */
5199
5200 int
5201 main ()
5202 {
5203 #ifndef __GNUC__
5204 choke me
5205 #endif
5206
5207 ;
5208 return 0;
5209 }
5210 _ACEOF
5211 if ac_fn_c_try_compile "$LINENO"; then :
5212 ac_compiler_gnu=yes
5213 else
5214 ac_compiler_gnu=no
5215 fi
5216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5217 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5218
5219 fi
5220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5221 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5222 if test $ac_compiler_gnu = yes; then
5223 GCC=yes
5224 else
5225 GCC=
5226 fi
5227 ac_test_CFLAGS=${CFLAGS+set}
5228 ac_save_CFLAGS=$CFLAGS
5229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5230 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5231 if test "${ac_cv_prog_cc_g+set}" = set; then :
5232 $as_echo_n "(cached) " >&6
5233 else
5234 ac_save_c_werror_flag=$ac_c_werror_flag
5235 ac_c_werror_flag=yes
5236 ac_cv_prog_cc_g=no
5237 CFLAGS="-g"
5238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5239 /* end confdefs.h. */
5240
5241 int
5242 main ()
5243 {
5244
5245 ;
5246 return 0;
5247 }
5248 _ACEOF
5249 if ac_fn_c_try_compile "$LINENO"; then :
5250 ac_cv_prog_cc_g=yes
5251 else
5252 CFLAGS=""
5253 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5254 /* end confdefs.h. */
5255
5256 int
5257 main ()
5258 {
5259
5260 ;
5261 return 0;
5262 }
5263 _ACEOF
5264 if ac_fn_c_try_compile "$LINENO"; then :
5265
5266 else
5267 ac_c_werror_flag=$ac_save_c_werror_flag
5268 CFLAGS="-g"
5269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5270 /* end confdefs.h. */
5271
5272 int
5273 main ()
5274 {
5275
5276 ;
5277 return 0;
5278 }
5279 _ACEOF
5280 if ac_fn_c_try_compile "$LINENO"; then :
5281 ac_cv_prog_cc_g=yes
5282 fi
5283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5284 fi
5285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5286 fi
5287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5288 ac_c_werror_flag=$ac_save_c_werror_flag
5289 fi
5290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5291 $as_echo "$ac_cv_prog_cc_g" >&6; }
5292 if test "$ac_test_CFLAGS" = set; then
5293 CFLAGS=$ac_save_CFLAGS
5294 elif test $ac_cv_prog_cc_g = yes; then
5295 if test "$GCC" = yes; then
5296 CFLAGS="-g -O2"
5297 else
5298 CFLAGS="-g"
5299 fi
5300 else
5301 if test "$GCC" = yes; then
5302 CFLAGS="-O2"
5303 else
5304 CFLAGS=
5305 fi
5306 fi
5307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5308 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5309 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5310 $as_echo_n "(cached) " >&6
5311 else
5312 ac_cv_prog_cc_c89=no
5313 ac_save_CC=$CC
5314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5315 /* end confdefs.h. */
5316 #include <stdarg.h>
5317 #include <stdio.h>
5318 #include <sys/types.h>
5319 #include <sys/stat.h>
5320 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5321 struct buf { int x; };
5322 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5323 static char *e (p, i)
5324 char **p;
5325 int i;
5326 {
5327 return p[i];
5328 }
5329 static char *f (char * (*g) (char **, int), char **p, ...)
5330 {
5331 char *s;
5332 va_list v;
5333 va_start (v,p);
5334 s = g (p, va_arg (v,int));
5335 va_end (v);
5336 return s;
5337 }
5338
5339 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5340 function prototypes and stuff, but not '\xHH' hex character constants.
5341 These don't provoke an error unfortunately, instead are silently treated
5342 as 'x'. The following induces an error, until -std is added to get
5343 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5344 array size at least. It's necessary to write '\x00'==0 to get something
5345 that's true only with -std. */
5346 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5347
5348 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5349 inside strings and character constants. */
5350 #define FOO(x) 'x'
5351 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5352
5353 int test (int i, double x);
5354 struct s1 {int (*f) (int a);};
5355 struct s2 {int (*f) (double a);};
5356 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5357 int argc;
5358 char **argv;
5359 int
5360 main ()
5361 {
5362 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5363 ;
5364 return 0;
5365 }
5366 _ACEOF
5367 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5368 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5369 do
5370 CC="$ac_save_CC $ac_arg"
5371 if ac_fn_c_try_compile "$LINENO"; then :
5372 ac_cv_prog_cc_c89=$ac_arg
5373 fi
5374 rm -f core conftest.err conftest.$ac_objext
5375 test "x$ac_cv_prog_cc_c89" != "xno" && break
5376 done
5377 rm -f conftest.$ac_ext
5378 CC=$ac_save_CC
5379
5380 fi
5381 # AC_CACHE_VAL
5382 case "x$ac_cv_prog_cc_c89" in
5383 x)
5384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5385 $as_echo "none needed" >&6; } ;;
5386 xno)
5387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5388 $as_echo "unsupported" >&6; } ;;
5389 *)
5390 CC="$CC $ac_cv_prog_cc_c89"
5391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5392 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5393 esac
5394 if test "x$ac_cv_prog_cc_c89" != xno; then :
5395
5396 fi
5397
5398 ac_ext=c
5399 ac_cpp='$CPP $CPPFLAGS'
5400 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5401 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5402 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5403 DEPDIR="${am__leading_dot}deps"
5404
5405 ac_config_commands="$ac_config_commands depfiles"
5406
5407
5408 am_make=${MAKE-make}
5409 cat > confinc << 'END'
5410 am__doit:
5411 @echo this is the am__doit target
5412 .PHONY: am__doit
5413 END
5414 # If we don't find an include directive, just comment out the code.
5415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5416 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5417 am__include="#"
5418 am__quote=
5419 _am_result=none
5420 # First try GNU make style include.
5421 echo "include confinc" > confmf
5422 # Ignore all kinds of additional output from `make'.
5423 case `$am_make -s -f confmf 2> /dev/null` in #(
5424 *the\ am__doit\ target*)
5425 am__include=include
5426 am__quote=
5427 _am_result=GNU
5428 ;;
5429 esac
5430 # Now try BSD make style include.
5431 if test "$am__include" = "#"; then
5432 echo '.include "confinc"' > confmf
5433 case `$am_make -s -f confmf 2> /dev/null` in #(
5434 *the\ am__doit\ target*)
5435 am__include=.include
5436 am__quote="\""
5437 _am_result=BSD
5438 ;;
5439 esac
5440 fi
5441
5442
5443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5444 $as_echo "$_am_result" >&6; }
5445 rm -f confinc confmf
5446
5447 # Check whether --enable-dependency-tracking was given.
5448 if test "${enable_dependency_tracking+set}" = set; then :
5449 enableval=$enable_dependency_tracking;
5450 fi
5451
5452 if test "x$enable_dependency_tracking" != xno; then
5453 am_depcomp="$ac_aux_dir/depcomp"
5454 AMDEPBACKSLASH='\'
5455 fi
5456 if test "x$enable_dependency_tracking" != xno; then
5457 AMDEP_TRUE=
5458 AMDEP_FALSE='#'
5459 else
5460 AMDEP_TRUE='#'
5461 AMDEP_FALSE=
5462 fi
5463
5464
5465
5466 depcc="$CC" am_compiler_list=
5467
5468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5469 $as_echo_n "checking dependency style of $depcc... " >&6; }
5470 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5471 $as_echo_n "(cached) " >&6
5472 else
5473 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5474 # We make a subdir and do the tests there. Otherwise we can end up
5475 # making bogus files that we don't know about and never remove. For
5476 # instance it was reported that on HP-UX the gcc test will end up
5477 # making a dummy file named `D' -- because `-MD' means `put the output
5478 # in D'.
5479 mkdir conftest.dir
5480 # Copy depcomp to subdir because otherwise we won't find it if we're
5481 # using a relative directory.
5482 cp "$am_depcomp" conftest.dir
5483 cd conftest.dir
5484 # We will build objects and dependencies in a subdirectory because
5485 # it helps to detect inapplicable dependency modes. For instance
5486 # both Tru64's cc and ICC support -MD to output dependencies as a
5487 # side effect of compilation, but ICC will put the dependencies in
5488 # the current directory while Tru64 will put them in the object
5489 # directory.
5490 mkdir sub
5491
5492 am_cv_CC_dependencies_compiler_type=none
5493 if test "$am_compiler_list" = ""; then
5494 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5495 fi
5496 am__universal=false
5497 case " $depcc " in #(
5498 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5499 esac
5500
5501 for depmode in $am_compiler_list; do
5502 # Setup a source with many dependencies, because some compilers
5503 # like to wrap large dependency lists on column 80 (with \), and
5504 # we should not choose a depcomp mode which is confused by this.
5505 #
5506 # We need to recreate these files for each test, as the compiler may
5507 # overwrite some of them when testing with obscure command lines.
5508 # This happens at least with the AIX C compiler.
5509 : > sub/conftest.c
5510 for i in 1 2 3 4 5 6; do
5511 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5512 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5513 # Solaris 8's {/usr,}/bin/sh.
5514 touch sub/conftst$i.h
5515 done
5516 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5517
5518 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5519 # mode. It turns out that the SunPro C++ compiler does not properly
5520 # handle `-M -o', and we need to detect this. Also, some Intel
5521 # versions had trouble with output in subdirs
5522 am__obj=sub/conftest.${OBJEXT-o}
5523 am__minus_obj="-o $am__obj"
5524 case $depmode in
5525 gcc)
5526 # This depmode causes a compiler race in universal mode.
5527 test "$am__universal" = false || continue
5528 ;;
5529 nosideeffect)
5530 # after this tag, mechanisms are not by side-effect, so they'll
5531 # only be used when explicitly requested
5532 if test "x$enable_dependency_tracking" = xyes; then
5533 continue
5534 else
5535 break
5536 fi
5537 ;;
5538 msvisualcpp | msvcmsys)
5539 # This compiler won't grok `-c -o', but also, the minuso test has
5540 # not run yet. These depmodes are late enough in the game, and
5541 # so weak that their functioning should not be impacted.
5542 am__obj=conftest.${OBJEXT-o}
5543 am__minus_obj=
5544 ;;
5545 none) break ;;
5546 esac
5547 if depmode=$depmode \
5548 source=sub/conftest.c object=$am__obj \
5549 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5550 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5551 >/dev/null 2>conftest.err &&
5552 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5553 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5554 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5555 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5556 # icc doesn't choke on unknown options, it will just issue warnings
5557 # or remarks (even with -Werror). So we grep stderr for any message
5558 # that says an option was ignored or not supported.
5559 # When given -MP, icc 7.0 and 7.1 complain thusly:
5560 # icc: Command line warning: ignoring option '-M'; no argument required
5561 # The diagnosis changed in icc 8.0:
5562 # icc: Command line remark: option '-MP' not supported
5563 if (grep 'ignoring option' conftest.err ||
5564 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5565 am_cv_CC_dependencies_compiler_type=$depmode
5566 break
5567 fi
5568 fi
5569 done
5570
5571 cd ..
5572 rm -rf conftest.dir
5573 else
5574 am_cv_CC_dependencies_compiler_type=none
5575 fi
5576
5577 fi
5578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5579 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5580 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5581
5582 if
5583 test "x$enable_dependency_tracking" != xno \
5584 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5585 am__fastdepCC_TRUE=
5586 am__fastdepCC_FALSE='#'
5587 else
5588 am__fastdepCC_TRUE='#'
5589 am__fastdepCC_FALSE=
5590 fi
5591
5592
5593 if test "x$CC" != xcc; then
5594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5595 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5596 else
5597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5598 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5599 fi
5600 set dummy $CC; ac_cc=`$as_echo "$2" |
5601 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5602 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5603 $as_echo_n "(cached) " >&6
5604 else
5605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5606 /* end confdefs.h. */
5607
5608 int
5609 main ()
5610 {
5611
5612 ;
5613 return 0;
5614 }
5615 _ACEOF
5616 # Make sure it works both with $CC and with simple cc.
5617 # We do the test twice because some compilers refuse to overwrite an
5618 # existing .o file with -o, though they will create one.
5619 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5620 rm -f conftest2.*
5621 if { { case "(($ac_try" in
5622 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5623 *) ac_try_echo=$ac_try;;
5624 esac
5625 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5626 $as_echo "$ac_try_echo"; } >&5
5627 (eval "$ac_try") 2>&5
5628 ac_status=$?
5629 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5630 test $ac_status = 0; } &&
5631 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5632 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5633 *) ac_try_echo=$ac_try;;
5634 esac
5635 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5636 $as_echo "$ac_try_echo"; } >&5
5637 (eval "$ac_try") 2>&5
5638 ac_status=$?
5639 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5640 test $ac_status = 0; };
5641 then
5642 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5643 if test "x$CC" != xcc; then
5644 # Test first that cc exists at all.
5645 if { ac_try='cc -c conftest.$ac_ext >&5'
5646 { { case "(($ac_try" in
5647 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5648 *) ac_try_echo=$ac_try;;
5649 esac
5650 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5651 $as_echo "$ac_try_echo"; } >&5
5652 (eval "$ac_try") 2>&5
5653 ac_status=$?
5654 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5655 test $ac_status = 0; }; }; then
5656 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5657 rm -f conftest2.*
5658 if { { case "(($ac_try" in
5659 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5660 *) ac_try_echo=$ac_try;;
5661 esac
5662 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5663 $as_echo "$ac_try_echo"; } >&5
5664 (eval "$ac_try") 2>&5
5665 ac_status=$?
5666 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5667 test $ac_status = 0; } &&
5668 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5669 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5670 *) ac_try_echo=$ac_try;;
5671 esac
5672 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5673 $as_echo "$ac_try_echo"; } >&5
5674 (eval "$ac_try") 2>&5
5675 ac_status=$?
5676 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5677 test $ac_status = 0; };
5678 then
5679 # cc works too.
5680 :
5681 else
5682 # cc exists but doesn't like -o.
5683 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5684 fi
5685 fi
5686 fi
5687 else
5688 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5689 fi
5690 rm -f core conftest*
5691
5692 fi
5693 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5695 $as_echo "yes" >&6; }
5696 else
5697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5698 $as_echo "no" >&6; }
5699
5700 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5701
5702 fi
5703
5704 # FIXME: we rely on the cache variable name because
5705 # there is no other way.
5706 set dummy $CC
5707 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5708 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5709 if test "$am_t" != yes; then
5710 # Losing compiler, so override with the script.
5711 # FIXME: It is wrong to rewrite CC.
5712 # But if we don't then we get into trouble of one sort or another.
5713 # A longer-term fix would be to have automake use am__CC in this case,
5714 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5715 CC="$am_aux_dir/compile $CC"
5716 fi
5717
5718
5719
5720 if test x$GCC = xyes; then
5721 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
5722 else
5723 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
5724 fi
5725
5726 # Initialize gnulib right after choosing the compiler.
5727
5728 ac_ext=c
5729 ac_cpp='$CPP $CPPFLAGS'
5730 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5731 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5732 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5734 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5735 # On Suns, sometimes $CPP names a directory.
5736 if test -n "$CPP" && test -d "$CPP"; then
5737 CPP=
5738 fi
5739 if test -z "$CPP"; then
5740 if test "${ac_cv_prog_CPP+set}" = set; then :
5741 $as_echo_n "(cached) " >&6
5742 else
5743 # Double quotes because CPP needs to be expanded
5744 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5745 do
5746 ac_preproc_ok=false
5747 for ac_c_preproc_warn_flag in '' yes
5748 do
5749 # Use a header file that comes with gcc, so configuring glibc
5750 # with a fresh cross-compiler works.
5751 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5752 # <limits.h> exists even on freestanding compilers.
5753 # On the NeXT, cc -E runs the code through the compiler's parser,
5754 # not just through cpp. "Syntax error" is here to catch this case.
5755 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5756 /* end confdefs.h. */
5757 #ifdef __STDC__
5758 # include <limits.h>
5759 #else
5760 # include <assert.h>
5761 #endif
5762 Syntax error
5763 _ACEOF
5764 if ac_fn_c_try_cpp "$LINENO"; then :
5765
5766 else
5767 # Broken: fails on valid input.
5768 continue
5769 fi
5770 rm -f conftest.err conftest.$ac_ext
5771
5772 # OK, works on sane cases. Now check whether nonexistent headers
5773 # can be detected and how.
5774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5775 /* end confdefs.h. */
5776 #include <ac_nonexistent.h>
5777 _ACEOF
5778 if ac_fn_c_try_cpp "$LINENO"; then :
5779 # Broken: success on invalid input.
5780 continue
5781 else
5782 # Passes both tests.
5783 ac_preproc_ok=:
5784 break
5785 fi
5786 rm -f conftest.err conftest.$ac_ext
5787
5788 done
5789 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5790 rm -f conftest.err conftest.$ac_ext
5791 if $ac_preproc_ok; then :
5792 break
5793 fi
5794
5795 done
5796 ac_cv_prog_CPP=$CPP
5797
5798 fi
5799 CPP=$ac_cv_prog_CPP
5800 else
5801 ac_cv_prog_CPP=$CPP
5802 fi
5803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5804 $as_echo "$CPP" >&6; }
5805 ac_preproc_ok=false
5806 for ac_c_preproc_warn_flag in '' yes
5807 do
5808 # Use a header file that comes with gcc, so configuring glibc
5809 # with a fresh cross-compiler works.
5810 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5811 # <limits.h> exists even on freestanding compilers.
5812 # On the NeXT, cc -E runs the code through the compiler's parser,
5813 # not just through cpp. "Syntax error" is here to catch this case.
5814 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5815 /* end confdefs.h. */
5816 #ifdef __STDC__
5817 # include <limits.h>
5818 #else
5819 # include <assert.h>
5820 #endif
5821 Syntax error
5822 _ACEOF
5823 if ac_fn_c_try_cpp "$LINENO"; then :
5824
5825 else
5826 # Broken: fails on valid input.
5827 continue
5828 fi
5829 rm -f conftest.err conftest.$ac_ext
5830
5831 # OK, works on sane cases. Now check whether nonexistent headers
5832 # can be detected and how.
5833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5834 /* end confdefs.h. */
5835 #include <ac_nonexistent.h>
5836 _ACEOF
5837 if ac_fn_c_try_cpp "$LINENO"; then :
5838 # Broken: success on invalid input.
5839 continue
5840 else
5841 # Passes both tests.
5842 ac_preproc_ok=:
5843 break
5844 fi
5845 rm -f conftest.err conftest.$ac_ext
5846
5847 done
5848 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5849 rm -f conftest.err conftest.$ac_ext
5850 if $ac_preproc_ok; then :
5851
5852 else
5853 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5854 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5855 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5856 See \`config.log' for more details." "$LINENO" 5; }
5857 fi
5858
5859 ac_ext=c
5860 ac_cpp='$CPP $CPPFLAGS'
5861 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5862 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5863 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5864
5865
5866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5867 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5868 if test "${ac_cv_path_GREP+set}" = set; then :
5869 $as_echo_n "(cached) " >&6
5870 else
5871 if test -z "$GREP"; then
5872 ac_path_GREP_found=false
5873 # Loop through the user's path and test for each of PROGNAME-LIST
5874 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5875 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5876 do
5877 IFS=$as_save_IFS
5878 test -z "$as_dir" && as_dir=.
5879 for ac_prog in grep ggrep; do
5880 for ac_exec_ext in '' $ac_executable_extensions; do
5881 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5882 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5883 # Check for GNU ac_path_GREP and select it if it is found.
5884 # Check for GNU $ac_path_GREP
5885 case `"$ac_path_GREP" --version 2>&1` in
5886 *GNU*)
5887 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5888 *)
5889 ac_count=0
5890 $as_echo_n 0123456789 >"conftest.in"
5891 while :
5892 do
5893 cat "conftest.in" "conftest.in" >"conftest.tmp"
5894 mv "conftest.tmp" "conftest.in"
5895 cp "conftest.in" "conftest.nl"
5896 $as_echo 'GREP' >> "conftest.nl"
5897 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5898 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5899 as_fn_arith $ac_count + 1 && ac_count=$as_val
5900 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5901 # Best one so far, save it but keep looking for a better one
5902 ac_cv_path_GREP="$ac_path_GREP"
5903 ac_path_GREP_max=$ac_count
5904 fi
5905 # 10*(2^10) chars as input seems more than enough
5906 test $ac_count -gt 10 && break
5907 done
5908 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5909 esac
5910
5911 $ac_path_GREP_found && break 3
5912 done
5913 done
5914 done
5915 IFS=$as_save_IFS
5916 if test -z "$ac_cv_path_GREP"; then
5917 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5918 fi
5919 else
5920 ac_cv_path_GREP=$GREP
5921 fi
5922
5923 fi
5924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5925 $as_echo "$ac_cv_path_GREP" >&6; }
5926 GREP="$ac_cv_path_GREP"
5927
5928
5929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5930 $as_echo_n "checking for egrep... " >&6; }
5931 if test "${ac_cv_path_EGREP+set}" = set; then :
5932 $as_echo_n "(cached) " >&6
5933 else
5934 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5935 then ac_cv_path_EGREP="$GREP -E"
5936 else
5937 if test -z "$EGREP"; then
5938 ac_path_EGREP_found=false
5939 # Loop through the user's path and test for each of PROGNAME-LIST
5940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5941 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5942 do
5943 IFS=$as_save_IFS
5944 test -z "$as_dir" && as_dir=.
5945 for ac_prog in egrep; do
5946 for ac_exec_ext in '' $ac_executable_extensions; do
5947 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5948 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5949 # Check for GNU ac_path_EGREP and select it if it is found.
5950 # Check for GNU $ac_path_EGREP
5951 case `"$ac_path_EGREP" --version 2>&1` in
5952 *GNU*)
5953 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5954 *)
5955 ac_count=0
5956 $as_echo_n 0123456789 >"conftest.in"
5957 while :
5958 do
5959 cat "conftest.in" "conftest.in" >"conftest.tmp"
5960 mv "conftest.tmp" "conftest.in"
5961 cp "conftest.in" "conftest.nl"
5962 $as_echo 'EGREP' >> "conftest.nl"
5963 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5964 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5965 as_fn_arith $ac_count + 1 && ac_count=$as_val
5966 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5967 # Best one so far, save it but keep looking for a better one
5968 ac_cv_path_EGREP="$ac_path_EGREP"
5969 ac_path_EGREP_max=$ac_count
5970 fi
5971 # 10*(2^10) chars as input seems more than enough
5972 test $ac_count -gt 10 && break
5973 done
5974 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5975 esac
5976
5977 $ac_path_EGREP_found && break 3
5978 done
5979 done
5980 done
5981 IFS=$as_save_IFS
5982 if test -z "$ac_cv_path_EGREP"; then
5983 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5984 fi
5985 else
5986 ac_cv_path_EGREP=$EGREP
5987 fi
5988
5989 fi
5990 fi
5991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5992 $as_echo "$ac_cv_path_EGREP" >&6; }
5993 EGREP="$ac_cv_path_EGREP"
5994
5995
5996
5997
5998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5999 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
6000 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6001 $as_echo_n "(cached) " >&6
6002 else
6003
6004 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6005 /* end confdefs.h. */
6006
6007 #ifdef __ACK__
6008 Amsterdam
6009 #endif
6010
6011 _ACEOF
6012 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6013 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6014 gl_cv_c_amsterdam_compiler=yes
6015 else
6016 gl_cv_c_amsterdam_compiler=no
6017 fi
6018 rm -f conftest*
6019
6020
6021 fi
6022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6023 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6024 if test -z "$AR"; then
6025 if test $gl_cv_c_amsterdam_compiler = yes; then
6026 AR='cc -c.a'
6027 if test -z "$ARFLAGS"; then
6028 ARFLAGS='-o'
6029 fi
6030 else
6031 if test -n "$ac_tool_prefix"; then
6032 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6033 set dummy ${ac_tool_prefix}ar; ac_word=$2
6034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6035 $as_echo_n "checking for $ac_word... " >&6; }
6036 if test "${ac_cv_prog_AR+set}" = set; then :
6037 $as_echo_n "(cached) " >&6
6038 else
6039 if test -n "$AR"; then
6040 ac_cv_prog_AR="$AR" # Let the user override the test.
6041 else
6042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6043 for as_dir in $PATH
6044 do
6045 IFS=$as_save_IFS
6046 test -z "$as_dir" && as_dir=.
6047 for ac_exec_ext in '' $ac_executable_extensions; do
6048 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6049 ac_cv_prog_AR="${ac_tool_prefix}ar"
6050 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6051 break 2
6052 fi
6053 done
6054 done
6055 IFS=$as_save_IFS
6056
6057 fi
6058 fi
6059 AR=$ac_cv_prog_AR
6060 if test -n "$AR"; then
6061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6062 $as_echo "$AR" >&6; }
6063 else
6064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6065 $as_echo "no" >&6; }
6066 fi
6067
6068
6069 fi
6070 if test -z "$ac_cv_prog_AR"; then
6071 ac_ct_AR=$AR
6072 # Extract the first word of "ar", so it can be a program name with args.
6073 set dummy ar; ac_word=$2
6074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6075 $as_echo_n "checking for $ac_word... " >&6; }
6076 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6077 $as_echo_n "(cached) " >&6
6078 else
6079 if test -n "$ac_ct_AR"; then
6080 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6081 else
6082 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6083 for as_dir in $PATH
6084 do
6085 IFS=$as_save_IFS
6086 test -z "$as_dir" && as_dir=.
6087 for ac_exec_ext in '' $ac_executable_extensions; do
6088 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6089 ac_cv_prog_ac_ct_AR="ar"
6090 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6091 break 2
6092 fi
6093 done
6094 done
6095 IFS=$as_save_IFS
6096
6097 fi
6098 fi
6099 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6100 if test -n "$ac_ct_AR"; then
6101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6102 $as_echo "$ac_ct_AR" >&6; }
6103 else
6104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6105 $as_echo "no" >&6; }
6106 fi
6107
6108 if test "x$ac_ct_AR" = x; then
6109 AR="ar"
6110 else
6111 case $cross_compiling:$ac_tool_warned in
6112 yes:)
6113 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6114 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6115 ac_tool_warned=yes ;;
6116 esac
6117 AR=$ac_ct_AR
6118 fi
6119 else
6120 AR="$ac_cv_prog_AR"
6121 fi
6122
6123 if test -z "$ARFLAGS"; then
6124 ARFLAGS='cru'
6125 fi
6126 fi
6127 else
6128 if test -z "$ARFLAGS"; then
6129 ARFLAGS='cru'
6130 fi
6131 fi
6132
6133
6134 if test -z "$RANLIB"; then
6135 if test $gl_cv_c_amsterdam_compiler = yes; then
6136 RANLIB=':'
6137 else
6138 if test -n "$ac_tool_prefix"; then
6139 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6140 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6142 $as_echo_n "checking for $ac_word... " >&6; }
6143 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6144 $as_echo_n "(cached) " >&6
6145 else
6146 if test -n "$RANLIB"; then
6147 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6148 else
6149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6150 for as_dir in $PATH
6151 do
6152 IFS=$as_save_IFS
6153 test -z "$as_dir" && as_dir=.
6154 for ac_exec_ext in '' $ac_executable_extensions; do
6155 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6156 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6157 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6158 break 2
6159 fi
6160 done
6161 done
6162 IFS=$as_save_IFS
6163
6164 fi
6165 fi
6166 RANLIB=$ac_cv_prog_RANLIB
6167 if test -n "$RANLIB"; then
6168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6169 $as_echo "$RANLIB" >&6; }
6170 else
6171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6172 $as_echo "no" >&6; }
6173 fi
6174
6175
6176 fi
6177 if test -z "$ac_cv_prog_RANLIB"; then
6178 ac_ct_RANLIB=$RANLIB
6179 # Extract the first word of "ranlib", so it can be a program name with args.
6180 set dummy ranlib; ac_word=$2
6181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6182 $as_echo_n "checking for $ac_word... " >&6; }
6183 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6184 $as_echo_n "(cached) " >&6
6185 else
6186 if test -n "$ac_ct_RANLIB"; then
6187 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6188 else
6189 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6190 for as_dir in $PATH
6191 do
6192 IFS=$as_save_IFS
6193 test -z "$as_dir" && as_dir=.
6194 for ac_exec_ext in '' $ac_executable_extensions; do
6195 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6196 ac_cv_prog_ac_ct_RANLIB="ranlib"
6197 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6198 break 2
6199 fi
6200 done
6201 done
6202 IFS=$as_save_IFS
6203
6204 fi
6205 fi
6206 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6207 if test -n "$ac_ct_RANLIB"; then
6208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6209 $as_echo "$ac_ct_RANLIB" >&6; }
6210 else
6211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6212 $as_echo "no" >&6; }
6213 fi
6214
6215 if test "x$ac_ct_RANLIB" = x; then
6216 RANLIB=":"
6217 else
6218 case $cross_compiling:$ac_tool_warned in
6219 yes:)
6220 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6221 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6222 ac_tool_warned=yes ;;
6223 esac
6224 RANLIB=$ac_ct_RANLIB
6225 fi
6226 else
6227 RANLIB="$ac_cv_prog_RANLIB"
6228 fi
6229
6230 fi
6231 fi
6232
6233
6234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6235 $as_echo_n "checking for ANSI C header files... " >&6; }
6236 if test "${ac_cv_header_stdc+set}" = set; then :
6237 $as_echo_n "(cached) " >&6
6238 else
6239 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6240 /* end confdefs.h. */
6241 #include <stdlib.h>
6242 #include <stdarg.h>
6243 #include <string.h>
6244 #include <float.h>
6245
6246 int
6247 main ()
6248 {
6249
6250 ;
6251 return 0;
6252 }
6253 _ACEOF
6254 if ac_fn_c_try_compile "$LINENO"; then :
6255 ac_cv_header_stdc=yes
6256 else
6257 ac_cv_header_stdc=no
6258 fi
6259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6260
6261 if test $ac_cv_header_stdc = yes; then
6262 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6263 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6264 /* end confdefs.h. */
6265 #include <string.h>
6266
6267 _ACEOF
6268 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6269 $EGREP "memchr" >/dev/null 2>&1; then :
6270
6271 else
6272 ac_cv_header_stdc=no
6273 fi
6274 rm -f conftest*
6275
6276 fi
6277
6278 if test $ac_cv_header_stdc = yes; then
6279 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6281 /* end confdefs.h. */
6282 #include <stdlib.h>
6283
6284 _ACEOF
6285 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6286 $EGREP "free" >/dev/null 2>&1; then :
6287
6288 else
6289 ac_cv_header_stdc=no
6290 fi
6291 rm -f conftest*
6292
6293 fi
6294
6295 if test $ac_cv_header_stdc = yes; then
6296 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6297 if test "$cross_compiling" = yes; then :
6298 :
6299 else
6300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6301 /* end confdefs.h. */
6302 #include <ctype.h>
6303 #include <stdlib.h>
6304 #if ((' ' & 0x0FF) == 0x020)
6305 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6306 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6307 #else
6308 # define ISLOWER(c) \
6309 (('a' <= (c) && (c) <= 'i') \
6310 || ('j' <= (c) && (c) <= 'r') \
6311 || ('s' <= (c) && (c) <= 'z'))
6312 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6313 #endif
6314
6315 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6316 int
6317 main ()
6318 {
6319 int i;
6320 for (i = 0; i < 256; i++)
6321 if (XOR (islower (i), ISLOWER (i))
6322 || toupper (i) != TOUPPER (i))
6323 return 2;
6324 return 0;
6325 }
6326 _ACEOF
6327 if ac_fn_c_try_run "$LINENO"; then :
6328
6329 else
6330 ac_cv_header_stdc=no
6331 fi
6332 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6333 conftest.$ac_objext conftest.beam conftest.$ac_ext
6334 fi
6335
6336 fi
6337 fi
6338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6339 $as_echo "$ac_cv_header_stdc" >&6; }
6340 if test $ac_cv_header_stdc = yes; then
6341
6342 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6343
6344 fi
6345
6346 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6347 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6348 inttypes.h stdint.h unistd.h
6349 do :
6350 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6351 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6352 "
6353 eval as_val=\$$as_ac_Header
6354 if test "x$as_val" = x""yes; then :
6355 cat >>confdefs.h <<_ACEOF
6356 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6357 _ACEOF
6358
6359 fi
6360
6361 done
6362
6363
6364
6365
6366
6367 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6368 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6369 MINIX=yes
6370 else
6371 MINIX=
6372 fi
6373
6374
6375 if test "$MINIX" = yes; then
6376
6377 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6378
6379
6380 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6381
6382
6383 $as_echo "#define _MINIX 1" >>confdefs.h
6384
6385 fi
6386
6387 case "$host_os" in
6388 hpux*)
6389
6390 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6391
6392 ;;
6393 esac
6394
6395
6396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6397 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6398 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6399 $as_echo_n "(cached) " >&6
6400 else
6401 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6402 /* end confdefs.h. */
6403
6404 # define __EXTENSIONS__ 1
6405 $ac_includes_default
6406 int
6407 main ()
6408 {
6409
6410 ;
6411 return 0;
6412 }
6413 _ACEOF
6414 if ac_fn_c_try_compile "$LINENO"; then :
6415 ac_cv_safe_to_define___extensions__=yes
6416 else
6417 ac_cv_safe_to_define___extensions__=no
6418 fi
6419 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6420 fi
6421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6422 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6423 test $ac_cv_safe_to_define___extensions__ = yes &&
6424 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6425
6426 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6427
6428 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6429
6430 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6431
6432 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6433
6434 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6435
6436
6437
6438
6439
6440
6441
6442
6443 # Check whether --enable-largefile was given.
6444 if test "${enable_largefile+set}" = set; then :
6445 enableval=$enable_largefile;
6446 fi
6447
6448 if test "$enable_largefile" != no; then
6449
6450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6451 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6452 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6453 $as_echo_n "(cached) " >&6
6454 else
6455 ac_cv_sys_largefile_CC=no
6456 if test "$GCC" != yes; then
6457 ac_save_CC=$CC
6458 while :; do
6459 # IRIX 6.2 and later do not support large files by default,
6460 # so use the C compiler's -n32 option if that helps.
6461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6462 /* end confdefs.h. */
6463 #include <sys/types.h>
6464 /* Check that off_t can represent 2**63 - 1 correctly.
6465 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6466 since some C++ compilers masquerading as C compilers
6467 incorrectly reject 9223372036854775807. */
6468 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6469 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6470 && LARGE_OFF_T % 2147483647 == 1)
6471 ? 1 : -1];
6472 int
6473 main ()
6474 {
6475
6476 ;
6477 return 0;
6478 }
6479 _ACEOF
6480 if ac_fn_c_try_compile "$LINENO"; then :
6481 break
6482 fi
6483 rm -f core conftest.err conftest.$ac_objext
6484 CC="$CC -n32"
6485 if ac_fn_c_try_compile "$LINENO"; then :
6486 ac_cv_sys_largefile_CC=' -n32'; break
6487 fi
6488 rm -f core conftest.err conftest.$ac_objext
6489 break
6490 done
6491 CC=$ac_save_CC
6492 rm -f conftest.$ac_ext
6493 fi
6494 fi
6495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6496 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6497 if test "$ac_cv_sys_largefile_CC" != no; then
6498 CC=$CC$ac_cv_sys_largefile_CC
6499 fi
6500
6501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6502 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6503 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6504 $as_echo_n "(cached) " >&6
6505 else
6506 while :; do
6507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6508 /* end confdefs.h. */
6509 #include <sys/types.h>
6510 /* Check that off_t can represent 2**63 - 1 correctly.
6511 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6512 since some C++ compilers masquerading as C compilers
6513 incorrectly reject 9223372036854775807. */
6514 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6515 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6516 && LARGE_OFF_T % 2147483647 == 1)
6517 ? 1 : -1];
6518 int
6519 main ()
6520 {
6521
6522 ;
6523 return 0;
6524 }
6525 _ACEOF
6526 if ac_fn_c_try_compile "$LINENO"; then :
6527 ac_cv_sys_file_offset_bits=no; break
6528 fi
6529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6531 /* end confdefs.h. */
6532 #define _FILE_OFFSET_BITS 64
6533 #include <sys/types.h>
6534 /* Check that off_t can represent 2**63 - 1 correctly.
6535 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6536 since some C++ compilers masquerading as C compilers
6537 incorrectly reject 9223372036854775807. */
6538 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6539 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6540 && LARGE_OFF_T % 2147483647 == 1)
6541 ? 1 : -1];
6542 int
6543 main ()
6544 {
6545
6546 ;
6547 return 0;
6548 }
6549 _ACEOF
6550 if ac_fn_c_try_compile "$LINENO"; then :
6551 ac_cv_sys_file_offset_bits=64; break
6552 fi
6553 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6554 ac_cv_sys_file_offset_bits=unknown
6555 break
6556 done
6557 fi
6558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6559 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6560 case $ac_cv_sys_file_offset_bits in #(
6561 no | unknown) ;;
6562 *)
6563 cat >>confdefs.h <<_ACEOF
6564 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6565 _ACEOF
6566 ;;
6567 esac
6568 rm -rf conftest*
6569 if test $ac_cv_sys_file_offset_bits = unknown; then
6570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6571 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6572 if test "${ac_cv_sys_large_files+set}" = set; then :
6573 $as_echo_n "(cached) " >&6
6574 else
6575 while :; do
6576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6577 /* end confdefs.h. */
6578 #include <sys/types.h>
6579 /* Check that off_t can represent 2**63 - 1 correctly.
6580 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6581 since some C++ compilers masquerading as C compilers
6582 incorrectly reject 9223372036854775807. */
6583 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6584 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6585 && LARGE_OFF_T % 2147483647 == 1)
6586 ? 1 : -1];
6587 int
6588 main ()
6589 {
6590
6591 ;
6592 return 0;
6593 }
6594 _ACEOF
6595 if ac_fn_c_try_compile "$LINENO"; then :
6596 ac_cv_sys_large_files=no; break
6597 fi
6598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6599 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6600 /* end confdefs.h. */
6601 #define _LARGE_FILES 1
6602 #include <sys/types.h>
6603 /* Check that off_t can represent 2**63 - 1 correctly.
6604 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6605 since some C++ compilers masquerading as C compilers
6606 incorrectly reject 9223372036854775807. */
6607 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6608 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6609 && LARGE_OFF_T % 2147483647 == 1)
6610 ? 1 : -1];
6611 int
6612 main ()
6613 {
6614
6615 ;
6616 return 0;
6617 }
6618 _ACEOF
6619 if ac_fn_c_try_compile "$LINENO"; then :
6620 ac_cv_sys_large_files=1; break
6621 fi
6622 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6623 ac_cv_sys_large_files=unknown
6624 break
6625 done
6626 fi
6627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6628 $as_echo "$ac_cv_sys_large_files" >&6; }
6629 case $ac_cv_sys_large_files in #(
6630 no | unknown) ;;
6631 *)
6632 cat >>confdefs.h <<_ACEOF
6633 #define _LARGE_FILES $ac_cv_sys_large_files
6634 _ACEOF
6635 ;;
6636 esac
6637 rm -rf conftest*
6638 fi
6639
6640
6641 fi
6642
6643 case $ac_cv_prog_cc_stdc in #(
6644 no) :
6645 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6646 *) :
6647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6648 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6649 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6650 $as_echo_n "(cached) " >&6
6651 else
6652 ac_cv_prog_cc_c99=no
6653 ac_save_CC=$CC
6654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6655 /* end confdefs.h. */
6656 #include <stdarg.h>
6657 #include <stdbool.h>
6658 #include <stdlib.h>
6659 #include <wchar.h>
6660 #include <stdio.h>
6661
6662 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6663 #define debug(...) fprintf (stderr, __VA_ARGS__)
6664 #define showlist(...) puts (#__VA_ARGS__)
6665 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6666 static void
6667 test_varargs_macros (void)
6668 {
6669 int x = 1234;
6670 int y = 5678;
6671 debug ("Flag");
6672 debug ("X = %d\n", x);
6673 showlist (The first, second, and third items.);
6674 report (x>y, "x is %d but y is %d", x, y);
6675 }
6676
6677 // Check long long types.
6678 #define BIG64 18446744073709551615ull
6679 #define BIG32 4294967295ul
6680 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6681 #if !BIG_OK
6682 your preprocessor is broken;
6683 #endif
6684 #if BIG_OK
6685 #else
6686 your preprocessor is broken;
6687 #endif
6688 static long long int bignum = -9223372036854775807LL;
6689 static unsigned long long int ubignum = BIG64;
6690
6691 struct incomplete_array
6692 {
6693 int datasize;
6694 double data[];
6695 };
6696
6697 struct named_init {
6698 int number;
6699 const wchar_t *name;
6700 double average;
6701 };
6702
6703 typedef const char *ccp;
6704
6705 static inline int
6706 test_restrict (ccp restrict text)
6707 {
6708 // See if C++-style comments work.
6709 // Iterate through items via the restricted pointer.
6710 // Also check for declarations in for loops.
6711 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6712 continue;
6713 return 0;
6714 }
6715
6716 // Check varargs and va_copy.
6717 static void
6718 test_varargs (const char *format, ...)
6719 {
6720 va_list args;
6721 va_start (args, format);
6722 va_list args_copy;
6723 va_copy (args_copy, args);
6724
6725 const char *str;
6726 int number;
6727 float fnumber;
6728
6729 while (*format)
6730 {
6731 switch (*format++)
6732 {
6733 case 's': // string
6734 str = va_arg (args_copy, const char *);
6735 break;
6736 case 'd': // int
6737 number = va_arg (args_copy, int);
6738 break;
6739 case 'f': // float
6740 fnumber = va_arg (args_copy, double);
6741 break;
6742 default:
6743 break;
6744 }
6745 }
6746 va_end (args_copy);
6747 va_end (args);
6748 }
6749
6750 int
6751 main ()
6752 {
6753
6754 // Check bool.
6755 _Bool success = false;
6756
6757 // Check restrict.
6758 if (test_restrict ("String literal") == 0)
6759 success = true;
6760 char *restrict newvar = "Another string";
6761
6762 // Check varargs.
6763 test_varargs ("s, d' f .", "string", 65, 34.234);
6764 test_varargs_macros ();
6765
6766 // Check flexible array members.
6767 struct incomplete_array *ia =
6768 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6769 ia->datasize = 10;
6770 for (int i = 0; i < ia->datasize; ++i)
6771 ia->data[i] = i * 1.234;
6772
6773 // Check named initializers.
6774 struct named_init ni = {
6775 .number = 34,
6776 .name = L"Test wide string",
6777 .average = 543.34343,
6778 };
6779
6780 ni.number = 58;
6781
6782 int dynamic_array[ni.number];
6783 dynamic_array[ni.number - 1] = 543;
6784
6785 // work around unused variable warnings
6786 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6787 || dynamic_array[ni.number - 1] != 543);
6788
6789 ;
6790 return 0;
6791 }
6792 _ACEOF
6793 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6794 do
6795 CC="$ac_save_CC $ac_arg"
6796 if ac_fn_c_try_compile "$LINENO"; then :
6797 ac_cv_prog_cc_c99=$ac_arg
6798 fi
6799 rm -f core conftest.err conftest.$ac_objext
6800 test "x$ac_cv_prog_cc_c99" != "xno" && break
6801 done
6802 rm -f conftest.$ac_ext
6803 CC=$ac_save_CC
6804
6805 fi
6806 # AC_CACHE_VAL
6807 case "x$ac_cv_prog_cc_c99" in
6808 x)
6809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6810 $as_echo "none needed" >&6; } ;;
6811 xno)
6812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6813 $as_echo "unsupported" >&6; } ;;
6814 *)
6815 CC="$CC $ac_cv_prog_cc_c99"
6816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6817 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6818 esac
6819 if test "x$ac_cv_prog_cc_c99" != xno; then :
6820 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6821 else
6822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6823 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6824 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6825 $as_echo_n "(cached) " >&6
6826 else
6827 ac_cv_prog_cc_c89=no
6828 ac_save_CC=$CC
6829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6830 /* end confdefs.h. */
6831 #include <stdarg.h>
6832 #include <stdio.h>
6833 #include <sys/types.h>
6834 #include <sys/stat.h>
6835 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6836 struct buf { int x; };
6837 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6838 static char *e (p, i)
6839 char **p;
6840 int i;
6841 {
6842 return p[i];
6843 }
6844 static char *f (char * (*g) (char **, int), char **p, ...)
6845 {
6846 char *s;
6847 va_list v;
6848 va_start (v,p);
6849 s = g (p, va_arg (v,int));
6850 va_end (v);
6851 return s;
6852 }
6853
6854 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6855 function prototypes and stuff, but not '\xHH' hex character constants.
6856 These don't provoke an error unfortunately, instead are silently treated
6857 as 'x'. The following induces an error, until -std is added to get
6858 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6859 array size at least. It's necessary to write '\x00'==0 to get something
6860 that's true only with -std. */
6861 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6862
6863 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6864 inside strings and character constants. */
6865 #define FOO(x) 'x'
6866 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6867
6868 int test (int i, double x);
6869 struct s1 {int (*f) (int a);};
6870 struct s2 {int (*f) (double a);};
6871 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6872 int argc;
6873 char **argv;
6874 int
6875 main ()
6876 {
6877 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6878 ;
6879 return 0;
6880 }
6881 _ACEOF
6882 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6883 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6884 do
6885 CC="$ac_save_CC $ac_arg"
6886 if ac_fn_c_try_compile "$LINENO"; then :
6887 ac_cv_prog_cc_c89=$ac_arg
6888 fi
6889 rm -f core conftest.err conftest.$ac_objext
6890 test "x$ac_cv_prog_cc_c89" != "xno" && break
6891 done
6892 rm -f conftest.$ac_ext
6893 CC=$ac_save_CC
6894
6895 fi
6896 # AC_CACHE_VAL
6897 case "x$ac_cv_prog_cc_c89" in
6898 x)
6899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6900 $as_echo "none needed" >&6; } ;;
6901 xno)
6902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6903 $as_echo "unsupported" >&6; } ;;
6904 *)
6905 CC="$CC $ac_cv_prog_cc_c89"
6906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6907 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6908 esac
6909 if test "x$ac_cv_prog_cc_c89" != xno; then :
6910 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6911 else
6912 ac_cv_prog_cc_stdc=no
6913 fi
6914
6915 fi
6916 ;;
6917 esac
6918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6919 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6920 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6921 $as_echo_n "(cached) " >&6
6922 fi
6923
6924 case $ac_cv_prog_cc_stdc in #(
6925 no) :
6926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6927 $as_echo "unsupported" >&6; } ;; #(
6928 '') :
6929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6930 $as_echo "none needed" >&6; } ;; #(
6931 *) :
6932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6933 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6934 esac
6935
6936
6937
6938 # Code from module alloca-opt:
6939 # Code from module allocator:
6940 # Code from module c-ctype:
6941 # Code from module c-strcase:
6942 # Code from module careadlinkat:
6943 # Code from module clock-time:
6944 # Code from module crypto/md5:
6945 # Code from module crypto/sha1:
6946 # Code from module crypto/sha256:
6947 # Code from module crypto/sha512:
6948 # Code from module dosname:
6949 # Code from module dtoastr:
6950 # Code from module dtotimespec:
6951 # Code from module dup2:
6952 # Code from module environ:
6953 # Code from module execinfo:
6954 # Code from module extensions:
6955
6956 # Code from module extern-inline:
6957 # Code from module filemode:
6958 # Code from module getloadavg:
6959 # Code from module getopt-gnu:
6960 # Code from module getopt-posix:
6961 # Code from module gettext-h:
6962 # Code from module gettime:
6963 # Code from module gettimeofday:
6964 # Code from module ignore-value:
6965 # Code from module include_next:
6966 # Code from module intprops:
6967 # Code from module inttypes-incomplete:
6968 # Code from module largefile:
6969
6970 # Code from module lstat:
6971 # Code from module manywarnings:
6972 # Code from module mktime:
6973 # Code from module multiarch:
6974 # Code from module nocrash:
6975 # Code from module pathmax:
6976 # Code from module pselect:
6977 # Code from module pthread_sigmask:
6978 # Code from module readlink:
6979 # Code from module signal-h:
6980 # Code from module snippet/_Noreturn:
6981 # Code from module snippet/arg-nonnull:
6982 # Code from module snippet/c++defs:
6983 # Code from module snippet/warn-on-use:
6984 # Code from module socklen:
6985 # Code from module ssize_t:
6986 # Code from module stat:
6987 # Code from module stat-time:
6988 # Code from module stdalign:
6989 # Code from module stdarg:
6990
6991
6992
6993 # Code from module stdbool:
6994 # Code from module stddef:
6995 # Code from module stdint:
6996 # Code from module stdio:
6997 # Code from module stdlib:
6998 # Code from module strftime:
6999 # Code from module strtoimax:
7000 # Code from module strtoll:
7001 # Code from module strtoull:
7002 # Code from module strtoumax:
7003 # Code from module symlink:
7004 # Code from module sys_select:
7005 # Code from module sys_stat:
7006 # Code from module sys_time:
7007 # Code from module time:
7008 # Code from module time_r:
7009 # Code from module timespec:
7010 # Code from module timespec-add:
7011 # Code from module timespec-sub:
7012 # Code from module u64:
7013 # Code from module unistd:
7014 # Code from module utimens:
7015 # Code from module verify:
7016 # Code from module warnings:
7017
7018
7019 # It's helpful to have C macros available to GDB, so prefer -g3 to -g
7020 # if -g3 works and the user does not specify CFLAGS.
7021 # This test must follow gl_EARLY; otherwise AC_LINK_IFELSE complains.
7022 if test "$ac_test_CFLAGS" != set; then
7023 case $CFLAGS in
7024 '-g')
7025 emacs_g3_CFLAGS='-g3';;
7026 '-g -O2')
7027 emacs_g3_CFLAGS='-g3 -O2';;
7028 *)
7029 emacs_g3_CFLAGS='';;
7030 esac
7031 if test -n "$emacs_g3_CFLAGS"; then
7032 emacs_save_CFLAGS=$CFLAGS
7033 CFLAGS=$emacs_g3_CFLAGS
7034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts $emacs_g3_CFLAGS" >&5
7035 $as_echo_n "checking whether $CC accepts $emacs_g3_CFLAGS... " >&6; }
7036 if test "${emacs_cv_prog_cc_g3+set}" = set; then :
7037 $as_echo_n "(cached) " >&6
7038 else
7039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7040 /* end confdefs.h. */
7041
7042 int
7043 main ()
7044 {
7045
7046 ;
7047 return 0;
7048 }
7049 _ACEOF
7050 if ac_fn_c_try_link "$LINENO"; then :
7051 emacs_cv_prog_cc_g3=yes
7052 else
7053 emacs_cv_prog_cc_g3=no
7054 fi
7055 rm -f core conftest.err conftest.$ac_objext \
7056 conftest$ac_exeext conftest.$ac_ext
7057 fi
7058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_prog_cc_g3" >&5
7059 $as_echo "$emacs_cv_prog_cc_g3" >&6; }
7060 if test $emacs_cv_prog_cc_g3 = yes; then
7061 CFLAGS=$emacs_g3_CFLAGS
7062 else
7063 CFLAGS=$emacs_save_CFLAGS
7064 fi
7065 fi
7066 fi
7067
7068 # Check whether --enable-gcc-warnings was given.
7069 if test "${enable_gcc_warnings+set}" = set; then :
7070 enableval=$enable_gcc_warnings; case $enableval in
7071 yes|no) ;;
7072 *) as_fn_error "bad value $enableval for gcc-warnings option" "$LINENO" 5 ;;
7073 esac
7074 gl_gcc_warnings=$enableval
7075 else
7076 gl_gcc_warnings=no
7077
7078 fi
7079
7080
7081 # Check whether --enable-link-time-optimization was given.
7082 if test "${enable_link_time_optimization+set}" = set; then :
7083 enableval=$enable_link_time_optimization; if test "${enableval}" != "no"; then
7084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether link-time optimization is supported" >&5
7085 $as_echo_n "checking whether link-time optimization is supported... " >&6; }
7086 ac_lto_supported=no
7087 if test x$GCC = xyes; then
7088 CPUS=`getconf _NPROCESSORS_ONLN 2>/dev/null`
7089 if test x$CPUS != x; then
7090 LTO="-flto=$CPUS"
7091 else
7092 LTO="-flto"
7093 fi
7094 old_CFLAGS=$CFLAGS
7095 CFLAGS="$CFLAGS $LTO"
7096 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7097 /* end confdefs.h. */
7098
7099 int
7100 main ()
7101 {
7102
7103 ;
7104 return 0;
7105 }
7106 _ACEOF
7107 if ac_fn_c_try_compile "$LINENO"; then :
7108 ac_lto_supported=yes
7109 else
7110 ac_lto_supported=no
7111 fi
7112 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7113 CFLAGS="$old_CFLAGS"
7114 fi
7115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_lto_supported" >&5
7116 $as_echo "$ac_lto_supported" >&6; }
7117 if test "$ac_lto_supported" = "yes"; then
7118 CFLAGS="$CFLAGS $LTO"
7119 fi
7120 fi
7121 fi
7122
7123
7124 # gl_GCC_VERSION_IFELSE([major], [minor], [run-if-found], [run-if-not-found])
7125 # ------------------------------------------------
7126 # If $CPP is gcc-MAJOR.MINOR or newer, then run RUN-IF-FOUND.
7127 # Otherwise, run RUN-IF-NOT-FOUND.
7128
7129
7130 # When compiling with GCC, prefer -isystem to -I when including system
7131 # include files, to avoid generating useless diagnostics for the files.
7132 if test "$gl_gcc_warnings" != yes; then
7133 isystem='-I'
7134 else
7135 isystem='-isystem '
7136
7137 # This, $nw, is the list of warnings we disable.
7138 nw=
7139
7140 case $with_x_toolkit in
7141 lucid | athena | motif)
7142 # Old toolkits mishandle 'const'.
7143 nw="$nw -Wwrite-strings"
7144 ;;
7145 *)
7146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Werror" >&5
7147 $as_echo_n "checking whether C compiler handles -Werror... " >&6; }
7148 if test "${gl_cv_warn_c__Werror+set}" = set; then :
7149 $as_echo_n "(cached) " >&6
7150 else
7151
7152 gl_save_compiler_FLAGS="$CFLAGS"
7153 as_fn_append CFLAGS " -Werror"
7154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7155 /* end confdefs.h. */
7156
7157 int
7158 main ()
7159 {
7160
7161 ;
7162 return 0;
7163 }
7164 _ACEOF
7165 if ac_fn_c_try_compile "$LINENO"; then :
7166 gl_cv_warn_c__Werror=yes
7167 else
7168 gl_cv_warn_c__Werror=no
7169 fi
7170 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7171 CFLAGS="$gl_save_compiler_FLAGS"
7172
7173 fi
7174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Werror" >&5
7175 $as_echo "$gl_cv_warn_c__Werror" >&6; }
7176 if test "x$gl_cv_warn_c__Werror" = x""yes; then :
7177 as_fn_append WERROR_CFLAGS " -Werror"
7178 fi
7179
7180
7181 ;;
7182 esac
7183
7184
7185 nw="$nw -Waggregate-return" # anachronistic
7186 nw="$nw -Wlong-long" # C90 is anachronistic
7187 nw="$nw -Wc++-compat" # We don't care about C++ compilers
7188 nw="$nw -Wundef" # Warns on '#if GNULIB_FOO' etc in gnulib
7189 nw="$nw -Wtraditional" # Warns on #elif which we use often
7190 nw="$nw -Wcast-qual" # Too many warnings for now
7191 nw="$nw -Wconversion" # Too many warnings for now
7192 nw="$nw -Wsystem-headers" # Don't let system headers trigger warnings
7193 nw="$nw -Wsign-conversion" # Too many warnings for now
7194 nw="$nw -Woverlength-strings" # Not a problem these days
7195 nw="$nw -Wtraditional-conversion" # Too many warnings for now
7196 nw="$nw -Wunreachable-code" # so buggy that it's now silently ignored
7197 nw="$nw -Wpadded" # Our structs are not padded
7198 nw="$nw -Wredundant-decls" # we regularly (re)declare functions
7199 nw="$nw -Wlogical-op" # any use of fwrite provokes this
7200 nw="$nw -Wformat-nonliteral" # we do this a lot
7201 nw="$nw -Wvla" # warnings in gettext.h
7202 nw="$nw -Wnested-externs" # use of XARGMATCH/verify_function__
7203 nw="$nw -Wswitch-enum" # Too many warnings for now
7204 nw="$nw -Wswitch-default" # Too many warnings for now
7205 nw="$nw -Wfloat-equal" # warns about high-quality code
7206 nw="$nw -Winline" # OK to ignore 'inline'
7207 nw="$nw -Wjump-misses-init" # We sometimes safely jump over init.
7208 nw="$nw -Wsync-nand" # irrelevant here, and provokes ObjC warning
7209 nw="$nw -Wunsafe-loop-optimizations" # OK to suppress unsafe optimizations
7210
7211 # Emacs doesn't care about shadowing; see
7212 # <http://lists.gnu.org/archive/html/emacs-diffs/2011-11/msg00265.html>.
7213 nw="$nw -Wshadow"
7214
7215 # The following lines should be removable at some point.
7216 nw="$nw -Wstack-protector"
7217 nw="$nw -Wstrict-overflow"
7218 nw="$nw -Wsuggest-attribute=pure"
7219
7220
7221
7222 if test -n "$GCC"; then
7223
7224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is supported" >&5
7225 $as_echo_n "checking whether -Wno-missing-field-initializers is supported... " >&6; }
7226 if test "${gl_cv_cc_nomfi_supported+set}" = set; then :
7227 $as_echo_n "(cached) " >&6
7228 else
7229
7230 gl_save_CFLAGS="$CFLAGS"
7231 CFLAGS="$CFLAGS -W -Werror -Wno-missing-field-initializers"
7232 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7233 /* end confdefs.h. */
7234
7235 int
7236 main ()
7237 {
7238
7239 ;
7240 return 0;
7241 }
7242 _ACEOF
7243 if ac_fn_c_try_compile "$LINENO"; then :
7244 gl_cv_cc_nomfi_supported=yes
7245 else
7246 gl_cv_cc_nomfi_supported=no
7247 fi
7248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7249 CFLAGS="$gl_save_CFLAGS"
7250 fi
7251
7252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_supported" >&5
7253 $as_echo "$gl_cv_cc_nomfi_supported" >&6; }
7254
7255 if test "$gl_cv_cc_nomfi_supported" = yes; then
7256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -Wno-missing-field-initializers is needed" >&5
7257 $as_echo_n "checking whether -Wno-missing-field-initializers is needed... " >&6; }
7258 if test "${gl_cv_cc_nomfi_needed+set}" = set; then :
7259 $as_echo_n "(cached) " >&6
7260 else
7261
7262 gl_save_CFLAGS="$CFLAGS"
7263 CFLAGS="$CFLAGS -W -Werror"
7264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7265 /* end confdefs.h. */
7266 void f (void)
7267 {
7268 typedef struct { int a; int b; } s_t;
7269 s_t s1 = { 0, };
7270 }
7271
7272 int
7273 main ()
7274 {
7275
7276 ;
7277 return 0;
7278 }
7279 _ACEOF
7280 if ac_fn_c_try_compile "$LINENO"; then :
7281 gl_cv_cc_nomfi_needed=no
7282 else
7283 gl_cv_cc_nomfi_needed=yes
7284 fi
7285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7286 CFLAGS="$gl_save_CFLAGS"
7287
7288 fi
7289
7290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_nomfi_needed" >&5
7291 $as_echo "$gl_cv_cc_nomfi_needed" >&6; }
7292 fi
7293 fi
7294
7295 gl_manywarn_set=
7296 for gl_manywarn_item in \
7297 -W \
7298 -Wabi \
7299 -Waddress \
7300 -Wall \
7301 -Warray-bounds \
7302 -Wattributes \
7303 -Wbad-function-cast \
7304 -Wbuiltin-macro-redefined \
7305 -Wcast-align \
7306 -Wchar-subscripts \
7307 -Wclobbered \
7308 -Wcomment \
7309 -Wcomments \
7310 -Wcoverage-mismatch \
7311 -Wcpp \
7312 -Wdeprecated \
7313 -Wdeprecated-declarations \
7314 -Wdisabled-optimization \
7315 -Wdiv-by-zero \
7316 -Wdouble-promotion \
7317 -Wempty-body \
7318 -Wendif-labels \
7319 -Wenum-compare \
7320 -Wextra \
7321 -Wformat-contains-nul \
7322 -Wformat-extra-args \
7323 -Wformat-nonliteral \
7324 -Wformat-security \
7325 -Wformat-y2k \
7326 -Wformat-zero-length \
7327 -Wformat=2 \
7328 -Wfree-nonheap-object \
7329 -Wignored-qualifiers \
7330 -Wimplicit \
7331 -Wimplicit-function-declaration \
7332 -Wimplicit-int \
7333 -Winit-self \
7334 -Winline \
7335 -Wint-to-pointer-cast \
7336 -Winvalid-memory-model \
7337 -Winvalid-pch \
7338 -Wjump-misses-init \
7339 -Wlogical-op \
7340 -Wmain \
7341 -Wmaybe-uninitialized \
7342 -Wmissing-braces \
7343 -Wmissing-declarations \
7344 -Wmissing-field-initializers \
7345 -Wmissing-format-attribute \
7346 -Wmissing-include-dirs \
7347 -Wmissing-noreturn \
7348 -Wmissing-parameter-type \
7349 -Wmissing-prototypes \
7350 -Wmudflap \
7351 -Wmultichar \
7352 -Wnarrowing \
7353 -Wnested-externs \
7354 -Wnonnull \
7355 -Wnormalized=nfc \
7356 -Wold-style-declaration \
7357 -Wold-style-definition \
7358 -Woverflow \
7359 -Woverlength-strings \
7360 -Woverride-init \
7361 -Wpacked \
7362 -Wpacked-bitfield-compat \
7363 -Wparentheses \
7364 -Wpointer-arith \
7365 -Wpointer-sign \
7366 -Wpointer-to-int-cast \
7367 -Wpragmas \
7368 -Wreturn-type \
7369 -Wsequence-point \
7370 -Wshadow \
7371 -Wsizeof-pointer-memaccess \
7372 -Wstack-protector \
7373 -Wstrict-aliasing \
7374 -Wstrict-overflow \
7375 -Wstrict-prototypes \
7376 -Wsuggest-attribute=const \
7377 -Wsuggest-attribute=format \
7378 -Wsuggest-attribute=noreturn \
7379 -Wsuggest-attribute=pure \
7380 -Wswitch \
7381 -Wswitch-default \
7382 -Wsync-nand \
7383 -Wsystem-headers \
7384 -Wtrampolines \
7385 -Wtrigraphs \
7386 -Wtype-limits \
7387 -Wuninitialized \
7388 -Wunknown-pragmas \
7389 -Wunreachable-code \
7390 -Wunsafe-loop-optimizations \
7391 -Wunused \
7392 -Wunused-but-set-parameter \
7393 -Wunused-but-set-variable \
7394 -Wunused-function \
7395 -Wunused-label \
7396 -Wunused-local-typedefs \
7397 -Wunused-macros \
7398 -Wunused-parameter \
7399 -Wunused-result \
7400 -Wunused-value \
7401 -Wunused-variable \
7402 -Wvarargs \
7403 -Wvariadic-macros \
7404 -Wvector-operation-performance \
7405 -Wvla \
7406 -Wvolatile-register-var \
7407 -Wwrite-strings \
7408 \
7409 ; do
7410 gl_manywarn_set="$gl_manywarn_set $gl_manywarn_item"
7411 done
7412
7413 # Disable the missing-field-initializers warning if needed
7414 if test "$gl_cv_cc_nomfi_needed" = yes; then
7415 gl_manywarn_set="$gl_manywarn_set -Wno-missing-field-initializers"
7416 fi
7417
7418 ws=$gl_manywarn_set
7419
7420
7421 gl_warn_set=
7422 set x $ws; shift
7423 for gl_warn_item
7424 do
7425 case " $nw " in
7426 *" $gl_warn_item "*)
7427 ;;
7428 *)
7429 gl_warn_set="$gl_warn_set $gl_warn_item"
7430 ;;
7431 esac
7432 done
7433 ws=$gl_warn_set
7434
7435 for w in $ws; do
7436 as_gl_Warn=`$as_echo "gl_cv_warn_c_$w" | $as_tr_sh`
7437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles $w" >&5
7438 $as_echo_n "checking whether C compiler handles $w... " >&6; }
7439 if { as_var=$as_gl_Warn; eval "test \"\${$as_var+set}\" = set"; }; then :
7440 $as_echo_n "(cached) " >&6
7441 else
7442
7443 gl_save_compiler_FLAGS="$CFLAGS"
7444 as_fn_append CFLAGS " $w"
7445 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7446 /* end confdefs.h. */
7447
7448 int
7449 main ()
7450 {
7451
7452 ;
7453 return 0;
7454 }
7455 _ACEOF
7456 if ac_fn_c_try_compile "$LINENO"; then :
7457 eval "$as_gl_Warn=yes"
7458 else
7459 eval "$as_gl_Warn=no"
7460 fi
7461 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7462 CFLAGS="$gl_save_compiler_FLAGS"
7463
7464 fi
7465 eval ac_res=\$$as_gl_Warn
7466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
7467 $as_echo "$ac_res" >&6; }
7468 eval as_val=\$$as_gl_Warn
7469 if test "x$as_val" = x""yes; then :
7470 as_fn_append WARN_CFLAGS " $w"
7471 fi
7472
7473
7474 done
7475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-missing-field-initializers" >&5
7476 $as_echo_n "checking whether C compiler handles -Wno-missing-field-initializers... " >&6; }
7477 if test "${gl_cv_warn_c__Wno_missing_field_initializers+set}" = set; then :
7478 $as_echo_n "(cached) " >&6
7479 else
7480
7481 gl_save_compiler_FLAGS="$CFLAGS"
7482 as_fn_append CFLAGS " -Wno-missing-field-initializers"
7483 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7484 /* end confdefs.h. */
7485
7486 int
7487 main ()
7488 {
7489
7490 ;
7491 return 0;
7492 }
7493 _ACEOF
7494 if ac_fn_c_try_compile "$LINENO"; then :
7495 gl_cv_warn_c__Wno_missing_field_initializers=yes
7496 else
7497 gl_cv_warn_c__Wno_missing_field_initializers=no
7498 fi
7499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7500 CFLAGS="$gl_save_compiler_FLAGS"
7501
7502 fi
7503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_missing_field_initializers" >&5
7504 $as_echo "$gl_cv_warn_c__Wno_missing_field_initializers" >&6; }
7505 if test "x$gl_cv_warn_c__Wno_missing_field_initializers" = x""yes; then :
7506 as_fn_append WARN_CFLAGS " -Wno-missing-field-initializers"
7507 fi
7508
7509 # We need this one
7510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-sign-compare" >&5
7511 $as_echo_n "checking whether C compiler handles -Wno-sign-compare... " >&6; }
7512 if test "${gl_cv_warn_c__Wno_sign_compare+set}" = set; then :
7513 $as_echo_n "(cached) " >&6
7514 else
7515
7516 gl_save_compiler_FLAGS="$CFLAGS"
7517 as_fn_append CFLAGS " -Wno-sign-compare"
7518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7519 /* end confdefs.h. */
7520
7521 int
7522 main ()
7523 {
7524
7525 ;
7526 return 0;
7527 }
7528 _ACEOF
7529 if ac_fn_c_try_compile "$LINENO"; then :
7530 gl_cv_warn_c__Wno_sign_compare=yes
7531 else
7532 gl_cv_warn_c__Wno_sign_compare=no
7533 fi
7534 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7535 CFLAGS="$gl_save_compiler_FLAGS"
7536
7537 fi
7538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_sign_compare" >&5
7539 $as_echo "$gl_cv_warn_c__Wno_sign_compare" >&6; }
7540 if test "x$gl_cv_warn_c__Wno_sign_compare" = x""yes; then :
7541 as_fn_append WARN_CFLAGS " -Wno-sign-compare"
7542 fi
7543
7544 # Too many warnings for now
7545 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-type-limits" >&5
7546 $as_echo_n "checking whether C compiler handles -Wno-type-limits... " >&6; }
7547 if test "${gl_cv_warn_c__Wno_type_limits+set}" = set; then :
7548 $as_echo_n "(cached) " >&6
7549 else
7550
7551 gl_save_compiler_FLAGS="$CFLAGS"
7552 as_fn_append CFLAGS " -Wno-type-limits"
7553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7554 /* end confdefs.h. */
7555
7556 int
7557 main ()
7558 {
7559
7560 ;
7561 return 0;
7562 }
7563 _ACEOF
7564 if ac_fn_c_try_compile "$LINENO"; then :
7565 gl_cv_warn_c__Wno_type_limits=yes
7566 else
7567 gl_cv_warn_c__Wno_type_limits=no
7568 fi
7569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7570 CFLAGS="$gl_save_compiler_FLAGS"
7571
7572 fi
7573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_type_limits" >&5
7574 $as_echo "$gl_cv_warn_c__Wno_type_limits" >&6; }
7575 if test "x$gl_cv_warn_c__Wno_type_limits" = x""yes; then :
7576 as_fn_append WARN_CFLAGS " -Wno-type-limits"
7577 fi
7578
7579 # Too many warnings for now
7580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-switch" >&5
7581 $as_echo_n "checking whether C compiler handles -Wno-switch... " >&6; }
7582 if test "${gl_cv_warn_c__Wno_switch+set}" = set; then :
7583 $as_echo_n "(cached) " >&6
7584 else
7585
7586 gl_save_compiler_FLAGS="$CFLAGS"
7587 as_fn_append CFLAGS " -Wno-switch"
7588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7589 /* end confdefs.h. */
7590
7591 int
7592 main ()
7593 {
7594
7595 ;
7596 return 0;
7597 }
7598 _ACEOF
7599 if ac_fn_c_try_compile "$LINENO"; then :
7600 gl_cv_warn_c__Wno_switch=yes
7601 else
7602 gl_cv_warn_c__Wno_switch=no
7603 fi
7604 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7605 CFLAGS="$gl_save_compiler_FLAGS"
7606
7607 fi
7608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_switch" >&5
7609 $as_echo "$gl_cv_warn_c__Wno_switch" >&6; }
7610 if test "x$gl_cv_warn_c__Wno_switch" = x""yes; then :
7611 as_fn_append WARN_CFLAGS " -Wno-switch"
7612 fi
7613
7614 # Too many warnings for now
7615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-unused-parameter" >&5
7616 $as_echo_n "checking whether C compiler handles -Wno-unused-parameter... " >&6; }
7617 if test "${gl_cv_warn_c__Wno_unused_parameter+set}" = set; then :
7618 $as_echo_n "(cached) " >&6
7619 else
7620
7621 gl_save_compiler_FLAGS="$CFLAGS"
7622 as_fn_append CFLAGS " -Wno-unused-parameter"
7623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7624 /* end confdefs.h. */
7625
7626 int
7627 main ()
7628 {
7629
7630 ;
7631 return 0;
7632 }
7633 _ACEOF
7634 if ac_fn_c_try_compile "$LINENO"; then :
7635 gl_cv_warn_c__Wno_unused_parameter=yes
7636 else
7637 gl_cv_warn_c__Wno_unused_parameter=no
7638 fi
7639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7640 CFLAGS="$gl_save_compiler_FLAGS"
7641
7642 fi
7643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_unused_parameter" >&5
7644 $as_echo "$gl_cv_warn_c__Wno_unused_parameter" >&6; }
7645 if test "x$gl_cv_warn_c__Wno_unused_parameter" = x""yes; then :
7646 as_fn_append WARN_CFLAGS " -Wno-unused-parameter"
7647 fi
7648
7649 # Too many warnings for now
7650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-format-nonliteral" >&5
7651 $as_echo_n "checking whether C compiler handles -Wno-format-nonliteral... " >&6; }
7652 if test "${gl_cv_warn_c__Wno_format_nonliteral+set}" = set; then :
7653 $as_echo_n "(cached) " >&6
7654 else
7655
7656 gl_save_compiler_FLAGS="$CFLAGS"
7657 as_fn_append CFLAGS " -Wno-format-nonliteral"
7658 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7659 /* end confdefs.h. */
7660
7661 int
7662 main ()
7663 {
7664
7665 ;
7666 return 0;
7667 }
7668 _ACEOF
7669 if ac_fn_c_try_compile "$LINENO"; then :
7670 gl_cv_warn_c__Wno_format_nonliteral=yes
7671 else
7672 gl_cv_warn_c__Wno_format_nonliteral=no
7673 fi
7674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7675 CFLAGS="$gl_save_compiler_FLAGS"
7676
7677 fi
7678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_format_nonliteral" >&5
7679 $as_echo "$gl_cv_warn_c__Wno_format_nonliteral" >&6; }
7680 if test "x$gl_cv_warn_c__Wno_format_nonliteral" = x""yes; then :
7681 as_fn_append WARN_CFLAGS " -Wno-format-nonliteral"
7682 fi
7683
7684
7685
7686 # In spite of excluding -Wlogical-op above, it is enabled, as of
7687 # gcc 4.5.0 20090517.
7688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -Wno-logical-op" >&5
7689 $as_echo_n "checking whether C compiler handles -Wno-logical-op... " >&6; }
7690 if test "${gl_cv_warn_c__Wno_logical_op+set}" = set; then :
7691 $as_echo_n "(cached) " >&6
7692 else
7693
7694 gl_save_compiler_FLAGS="$CFLAGS"
7695 as_fn_append CFLAGS " -Wno-logical-op"
7696 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7697 /* end confdefs.h. */
7698
7699 int
7700 main ()
7701 {
7702
7703 ;
7704 return 0;
7705 }
7706 _ACEOF
7707 if ac_fn_c_try_compile "$LINENO"; then :
7708 gl_cv_warn_c__Wno_logical_op=yes
7709 else
7710 gl_cv_warn_c__Wno_logical_op=no
7711 fi
7712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7713 CFLAGS="$gl_save_compiler_FLAGS"
7714
7715 fi
7716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__Wno_logical_op" >&5
7717 $as_echo "$gl_cv_warn_c__Wno_logical_op" >&6; }
7718 if test "x$gl_cv_warn_c__Wno_logical_op" = x""yes; then :
7719 as_fn_append WARN_CFLAGS " -Wno-logical-op"
7720 fi
7721
7722
7723
7724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -fdiagnostics-show-option" >&5
7725 $as_echo_n "checking whether C compiler handles -fdiagnostics-show-option... " >&6; }
7726 if test "${gl_cv_warn_c__fdiagnostics_show_option+set}" = set; then :
7727 $as_echo_n "(cached) " >&6
7728 else
7729
7730 gl_save_compiler_FLAGS="$CFLAGS"
7731 as_fn_append CFLAGS " -fdiagnostics-show-option"
7732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7733 /* end confdefs.h. */
7734
7735 int
7736 main ()
7737 {
7738
7739 ;
7740 return 0;
7741 }
7742 _ACEOF
7743 if ac_fn_c_try_compile "$LINENO"; then :
7744 gl_cv_warn_c__fdiagnostics_show_option=yes
7745 else
7746 gl_cv_warn_c__fdiagnostics_show_option=no
7747 fi
7748 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7749 CFLAGS="$gl_save_compiler_FLAGS"
7750
7751 fi
7752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__fdiagnostics_show_option" >&5
7753 $as_echo "$gl_cv_warn_c__fdiagnostics_show_option" >&6; }
7754 if test "x$gl_cv_warn_c__fdiagnostics_show_option" = x""yes; then :
7755 as_fn_append WARN_CFLAGS " -fdiagnostics-show-option"
7756 fi
7757
7758
7759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether C compiler handles -funit-at-a-time" >&5
7760 $as_echo_n "checking whether C compiler handles -funit-at-a-time... " >&6; }
7761 if test "${gl_cv_warn_c__funit_at_a_time+set}" = set; then :
7762 $as_echo_n "(cached) " >&6
7763 else
7764
7765 gl_save_compiler_FLAGS="$CFLAGS"
7766 as_fn_append CFLAGS " -funit-at-a-time"
7767 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7768 /* end confdefs.h. */
7769
7770 int
7771 main ()
7772 {
7773
7774 ;
7775 return 0;
7776 }
7777 _ACEOF
7778 if ac_fn_c_try_compile "$LINENO"; then :
7779 gl_cv_warn_c__funit_at_a_time=yes
7780 else
7781 gl_cv_warn_c__funit_at_a_time=no
7782 fi
7783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7784 CFLAGS="$gl_save_compiler_FLAGS"
7785
7786 fi
7787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_warn_c__funit_at_a_time" >&5
7788 $as_echo "$gl_cv_warn_c__funit_at_a_time" >&6; }
7789 if test "x$gl_cv_warn_c__funit_at_a_time" = x""yes; then :
7790 as_fn_append WARN_CFLAGS " -funit-at-a-time"
7791 fi
7792
7793
7794
7795
7796 $as_echo "#define lint 1" >>confdefs.h
7797
7798
7799
7800 $as_echo "#define GNULIB_PORTCHECK 1" >>confdefs.h
7801
7802
7803 # We use a slightly smaller set of warning options for lib/.
7804 # Remove the following and save the result in GNULIB_WARN_CFLAGS.
7805 nw=
7806 nw="$nw -Wunused-macros"
7807
7808
7809 gl_warn_set=
7810 set x $WARN_CFLAGS; shift
7811 for gl_warn_item
7812 do
7813 case " $nw " in
7814 *" $gl_warn_item "*)
7815 ;;
7816 *)
7817 gl_warn_set="$gl_warn_set $gl_warn_item"
7818 ;;
7819 esac
7820 done
7821 GNULIB_WARN_CFLAGS=$gl_warn_set
7822
7823
7824 fi
7825
7826
7827
7828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5
7829 $as_echo_n "checking whether ln -s works... " >&6; }
7830 LN_S=$as_ln_s
7831 if test "$LN_S" = "ln -s"; then
7832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7833 $as_echo "yes" >&6; }
7834 else
7835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5
7836 $as_echo "no, using $LN_S" >&6; }
7837 fi
7838
7839
7840 # Extract the first word of "install-info", so it can be a program name with args.
7841 set dummy install-info; ac_word=$2
7842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7843 $as_echo_n "checking for $ac_word... " >&6; }
7844 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7845 $as_echo_n "(cached) " >&6
7846 else
7847 case $INSTALL_INFO in
7848 [\\/]* | ?:[\\/]*)
7849 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7850 ;;
7851 *)
7852 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7853 for as_dir in $PATH$PATH_SEPARATOR/usr/sbin$PATH_SEPARATOR/sbin
7854 do
7855 IFS=$as_save_IFS
7856 test -z "$as_dir" && as_dir=.
7857 for ac_exec_ext in '' $ac_executable_extensions; do
7858 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7859 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7860 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7861 break 2
7862 fi
7863 done
7864 done
7865 IFS=$as_save_IFS
7866
7867 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7868 ;;
7869 esac
7870 fi
7871 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7872 if test -n "$INSTALL_INFO"; then
7873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7874 $as_echo "$INSTALL_INFO" >&6; }
7875 else
7876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7877 $as_echo "no" >&6; }
7878 fi
7879
7880
7881 # Extract the first word of "gzip", so it can be a program name with args.
7882 set dummy gzip; ac_word=$2
7883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7884 $as_echo_n "checking for $ac_word... " >&6; }
7885 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7886 $as_echo_n "(cached) " >&6
7887 else
7888 case $GZIP_PROG in
7889 [\\/]* | ?:[\\/]*)
7890 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7891 ;;
7892 *)
7893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7894 for as_dir in $PATH
7895 do
7896 IFS=$as_save_IFS
7897 test -z "$as_dir" && as_dir=.
7898 for ac_exec_ext in '' $ac_executable_extensions; do
7899 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7900 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7902 break 2
7903 fi
7904 done
7905 done
7906 IFS=$as_save_IFS
7907
7908 ;;
7909 esac
7910 fi
7911 GZIP_PROG=$ac_cv_path_GZIP_PROG
7912 if test -n "$GZIP_PROG"; then
7913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7914 $as_echo "$GZIP_PROG" >&6; }
7915 else
7916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7917 $as_echo "no" >&6; }
7918 fi
7919
7920
7921
7922 if test $opsys = gnu-linux; then
7923 # Extract the first word of "paxctl", so it can be a program name with args.
7924 set dummy paxctl; ac_word=$2
7925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7926 $as_echo_n "checking for $ac_word... " >&6; }
7927 if test "${ac_cv_path_PAXCTL+set}" = set; then :
7928 $as_echo_n "(cached) " >&6
7929 else
7930 case $PAXCTL in
7931 [\\/]* | ?:[\\/]*)
7932 ac_cv_path_PAXCTL="$PAXCTL" # Let the user override the test with a path.
7933 ;;
7934 *)
7935 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7936 for as_dir in $PATH$PATH_SEPARATOR/sbin$PATH_SEPARATOR/usr/sbin
7937 do
7938 IFS=$as_save_IFS
7939 test -z "$as_dir" && as_dir=.
7940 for ac_exec_ext in '' $ac_executable_extensions; do
7941 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7942 ac_cv_path_PAXCTL="$as_dir/$ac_word$ac_exec_ext"
7943 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7944 break 2
7945 fi
7946 done
7947 done
7948 IFS=$as_save_IFS
7949
7950 ;;
7951 esac
7952 fi
7953 PAXCTL=$ac_cv_path_PAXCTL
7954 if test -n "$PAXCTL"; then
7955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PAXCTL" >&5
7956 $as_echo "$PAXCTL" >&6; }
7957 else
7958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7959 $as_echo "no" >&6; }
7960 fi
7961
7962
7963 if test "X$PAXCTL" != X; then
7964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether binaries have a PT_PAX_FLAGS header" >&5
7965 $as_echo_n "checking whether binaries have a PT_PAX_FLAGS header... " >&6; }
7966 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7967 /* end confdefs.h. */
7968
7969 int
7970 main ()
7971 {
7972
7973 ;
7974 return 0;
7975 }
7976 _ACEOF
7977 if ac_fn_c_try_link "$LINENO"; then :
7978 if $PAXCTL -v conftest$EXEEXT >/dev/null 2>&1; then { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7979 $as_echo "yes" >&6; }
7980 else { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7981 $as_echo "no" >&6; }; PAXCTL=""; fi
7982 fi
7983 rm -f core conftest.err conftest.$ac_objext \
7984 conftest$ac_exeext conftest.$ac_ext
7985 fi
7986 fi
7987
7988 ## Need makeinfo >= 4.7 (?) to build the manuals.
7989 # Extract the first word of "makeinfo", so it can be a program name with args.
7990 set dummy makeinfo; ac_word=$2
7991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7992 $as_echo_n "checking for $ac_word... " >&6; }
7993 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
7994 $as_echo_n "(cached) " >&6
7995 else
7996 case $MAKEINFO in
7997 [\\/]* | ?:[\\/]*)
7998 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7999 ;;
8000 *)
8001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8002 for as_dir in $PATH
8003 do
8004 IFS=$as_save_IFS
8005 test -z "$as_dir" && as_dir=.
8006 for ac_exec_ext in '' $ac_executable_extensions; do
8007 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8008 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
8009 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8010 break 2
8011 fi
8012 done
8013 done
8014 IFS=$as_save_IFS
8015
8016 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
8017 ;;
8018 esac
8019 fi
8020 MAKEINFO=$ac_cv_path_MAKEINFO
8021 if test -n "$MAKEINFO"; then
8022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
8023 $as_echo "$MAKEINFO" >&6; }
8024 else
8025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8026 $as_echo "no" >&6; }
8027 fi
8028
8029
8030 if test "$MAKEINFO" != "no" && \
8031 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'`" = x; then
8032 MAKEINFO=no
8033 fi
8034
8035 ## Makeinfo is unusual. For a released Emacs, the manuals are
8036 ## pre-built, and not deleted by the normal clean rules. makeinfo is
8037 ## therefore in the category of "special tools" not normally required, which
8038 ## configure does not have to check for (eg autoconf itself).
8039 ## In a Bazaar checkout on the other hand, the manuals are not included.
8040 ## So makeinfo is a requirement to build from Bazaar, and configure
8041 ## should test for it as it does for any other build requirement.
8042 ## We use the presence of $srcdir/info/emacs to distinguish a release,
8043 ## with pre-built manuals, from a Bazaar checkout.
8044 HAVE_MAKEINFO=yes
8045
8046 if test "$MAKEINFO" = "no"; then
8047 MAKEINFO=makeinfo
8048 if test "x${with_makeinfo}" = "xno"; then
8049 HAVE_MAKEINFO=no
8050 elif test ! -e $srcdir/info/emacs; then
8051 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
8052 source tree does not seem to have pre-built manuals in the \`info' directory.
8053 Either install a suitable version of makeinfo, or re-run configure
8054 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
8055 fi
8056 fi
8057
8058
8059 INFO_EXT=.info
8060 INFO_OPTS=--no-split
8061
8062
8063
8064
8065 if test x$GCC = xyes; then
8066 test "x$GCC_LINK_TEST_OPTIONS" != x && \
8067 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
8068 else
8069 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
8070 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
8071 fi
8072
8073
8074 late_LDFLAGS=$LDFLAGS
8075 if test x$GCC = xyes; then
8076 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
8077 else
8078 LDFLAGS="$LDFLAGS -znocombreloc"
8079 fi
8080
8081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
8082 $as_echo_n "checking for -znocombreloc... " >&6; }
8083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8084 /* end confdefs.h. */
8085
8086 int
8087 main ()
8088 {
8089
8090 ;
8091 return 0;
8092 }
8093 _ACEOF
8094 if ac_fn_c_try_link "$LINENO"; then :
8095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8096 $as_echo "yes" >&6; }
8097 else
8098 LDFLAGS=$late_LDFLAGS
8099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8100 $as_echo "no" >&6; }
8101 fi
8102 rm -f core conftest.err conftest.$ac_objext \
8103 conftest$ac_exeext conftest.$ac_ext
8104
8105
8106 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
8107 case "$opsys" in
8108 your-opsys-here) CANNOT_DUMP=yes ;;
8109 esac
8110
8111 test "$CANNOT_DUMP" = "yes" && \
8112
8113 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
8114
8115
8116
8117
8118
8119 UNEXEC_OBJ=unexelf.o
8120 case "$opsys" in
8121 # MSDOS uses unexcoff.o
8122 # MSWindows uses unexw32.o
8123 aix4-2)
8124 UNEXEC_OBJ=unexaix.o
8125 ;;
8126 cygwin)
8127 UNEXEC_OBJ=unexcw.o
8128 ;;
8129 darwin)
8130 UNEXEC_OBJ=unexmacosx.o
8131 ;;
8132 hpux10-20 | hpux11)
8133 UNEXEC_OBJ=unexhp9k800.o
8134 ;;
8135 sol2-10)
8136 # Use the Solaris dldump() function, called from unexsol.c, to dump
8137 # emacs, instead of the generic ELF dump code found in unexelf.c.
8138 # The resulting binary has a complete symbol table, and is better
8139 # for debugging and other observability tools (debuggers, pstack, etc).
8140 #
8141 # If you encounter a problem using dldump(), please consider sending
8142 # a message to the OpenSolaris tools-linking mailing list:
8143 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
8144 #
8145 # It is likely that dldump() works with older Solaris too, but this has
8146 # not been tested, so for now this change is for Solaris 10 or newer.
8147 UNEXEC_OBJ=unexsol.o
8148 ;;
8149 esac
8150
8151 LD_SWITCH_SYSTEM=
8152 case "$opsys" in
8153 freebsd)
8154 ## Let `ld' find image libs and similar things in /usr/local/lib.
8155 ## The system compiler, GCC, has apparently been modified to not
8156 ## look there, contrary to what a stock GCC would do.
8157 ### It's not our place to do this. See bug#10313#17.
8158 ### LD_SWITCH_SYSTEM=-L/usr/local/lib
8159 :
8160 ;;
8161
8162 gnu-linux)
8163 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
8164 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
8165 ;;
8166
8167 netbsd)
8168 ### It's not our place to do this. See bug#10313#17.
8169 ### LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
8170 :
8171 ;;
8172
8173 openbsd)
8174 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
8175 ## otherwise Emacs dumps core on elf systems.
8176 LD_SWITCH_SYSTEM="-Z"
8177 ;;
8178 esac
8179
8180
8181 ac_link="$ac_link $LD_SWITCH_SYSTEM"
8182
8183 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_RPATH,
8184 ## which has not been defined yet. When this was handled with cpp,
8185 ## it was expanded to null when configure sourced the s/*.h file.
8186 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
8187 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
8188 ## (or somesuch), but because it is supposed to go at the _front_
8189 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
8190 ## Compare with the gnu-linux case below, which added to the end
8191 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
8192 ## LD_SWITCH_SYSTEM_TEMACS.
8193 case "$opsys" in
8194 netbsd|openbsd)
8195 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_RPATH) $LD_SWITCH_SYSTEM" ;;
8196 esac
8197
8198
8199 C_SWITCH_MACHINE=
8200 case $canonical in
8201 alpha*)
8202 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
8203 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
8204
8205 fi
8206
8207 if test "$ac_cv_have_decl___ELF__" = "yes"; then
8208 ## With ELF, make sure that all common symbols get allocated to in the
8209 ## data section. Otherwise, the dump of temacs may miss variables in
8210 ## the shared library that have been initialized. For example, with
8211 ## GNU libc, __malloc_initialized would normally be resolved to the
8212 ## shared library's .bss section, which is fatal.
8213 if test "x$GCC" = "xyes"; then
8214 C_SWITCH_MACHINE="-fno-common"
8215 else
8216 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
8217 fi
8218 else
8219 UNEXEC_OBJ=unexalpha.o
8220 fi
8221 ;;
8222 esac
8223
8224
8225
8226
8227 C_SWITCH_SYSTEM=
8228 ## Some programs in src produce warnings saying certain subprograms
8229 ## are too complex and need a MAXMEM value greater than 2000 for
8230 ## additional optimization. --nils@exp-math.uni-essen.de
8231 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
8232 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
8233 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
8234 ## It is redundant in glibc2, since we define _GNU_SOURCE.
8235
8236
8237
8238 LIBS_SYSTEM=
8239 case "$opsys" in
8240 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
8241 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
8242
8243 freebsd) LIBS_SYSTEM="-lutil" ;;
8244
8245 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
8246
8247 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
8248
8249 ## Motif needs -lgen.
8250 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
8251 esac
8252
8253
8254
8255 ### Make sure subsequent tests use flags consistent with the build flags.
8256
8257 if test x"${OVERRIDE_CPPFLAGS}" != x; then
8258 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
8259 else
8260 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
8261 fi
8262
8263 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
8264
8265 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
8266
8267
8268
8269 LIB_MATH=-lm
8270 LIB_STANDARD=
8271 START_FILES=
8272 SYSTEM_TYPE=`echo $opsys | sed -e 's/[0-9].*//' -e 's|-|/|'`
8273
8274 case $opsys in
8275 cygwin )
8276 LIB_MATH=
8277 START_FILES='pre-crt0.o'
8278 ;;
8279 darwin )
8280 ## Adding -lm confuses the dynamic linker, so omit it.
8281 LIB_MATH=
8282 START_FILES='pre-crt0.o'
8283 ;;
8284 freebsd )
8285 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8286 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8287 SYSTEM_TYPE=berkeley-unix
8288 ;;
8289 gnu-linux | gnu-kfreebsd )
8290 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8291 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8292 ;;
8293 hpux10-20 | hpux11 )
8294 LIB_STANDARD=-lc
8295 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8296 ;;
8297 netbsd | openbsd )
8298 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8299 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8300 SYSTEM_TYPE=berkeley-unix
8301 ;;
8302
8303 sol2* | unixware )
8304 SYSTEM_TYPE=usg-unix-v
8305 ;;
8306
8307 esac
8308
8309
8310
8311
8312 cat >>confdefs.h <<_ACEOF
8313 #define SYSTEM_TYPE "$SYSTEM_TYPE"
8314 _ACEOF
8315
8316
8317 crt_files=
8318
8319 for file in x $LIB_STANDARD $START_FILES; do
8320 case "$file" in
8321 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8322 esac
8323 done
8324
8325 if test "x$crt_files" != x; then
8326
8327 ## If user specified a crt-dir, use that unconditionally.
8328 crt_gcc=no
8329
8330 if test "X$CRT_DIR" = "X"; then
8331
8332 CRT_DIR=/usr/lib # default
8333
8334 case "$canonical" in
8335 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8336 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8337 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8338 ## For anything else (eg /usr/lib32), it is up the user to specify
8339 ## the location (bug#5655).
8340 ## Test for crtn.o, not just the directory, because sometimes the
8341 ## directory exists but does not have the relevant files (bug#1287).
8342 ## FIXME better to test for binary compatibility somehow.
8343 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8344 ;;
8345
8346 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8347 esac
8348
8349 case "$opsys" in
8350 hpux10-20) CRT_DIR=/lib ;;
8351 esac
8352
8353 test "x${GCC}" = xyes && crt_gcc=yes
8354
8355 fi # CRT_DIR = ""
8356
8357 crt_missing=
8358
8359 for file in $crt_files; do
8360
8361 ## If we're using gcc, try to determine it automatically by asking
8362 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8363 ## system-dependent default from above.]
8364 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8365
8366 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8367 case "$crt_file" in
8368 */*)
8369 CRT_DIR=`$as_dirname -- "$crt_file" ||
8370 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8371 X"$crt_file" : 'X\(//\)[^/]' \| \
8372 X"$crt_file" : 'X\(//\)$' \| \
8373 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8374 $as_echo X"$crt_file" |
8375 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8376 s//\1/
8377 q
8378 }
8379 /^X\(\/\/\)[^/].*/{
8380 s//\1/
8381 q
8382 }
8383 /^X\(\/\/\)$/{
8384 s//\1/
8385 q
8386 }
8387 /^X\(\/\).*/{
8388 s//\1/
8389 q
8390 }
8391 s/.*/./; q'`
8392 ;;
8393 esac
8394 fi
8395
8396 crt_gcc=no
8397
8398 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8399 done # $crt_files
8400
8401 test "x$crt_missing" = x || \
8402 as_fn_error "Required file(s) not found:$crt_missing
8403 Try using the --with-crt-dir option." "$LINENO" 5
8404
8405 fi # crt_files != ""
8406
8407
8408
8409 case $opsys in
8410 netbsd | openbsd )
8411 if test -f $CRT_DIR/crti.o; then
8412
8413 test -f $CRT_DIR/crtn.o || \
8414 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8415
8416 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8417 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8418 fi
8419 ;;
8420 esac
8421
8422
8423 pre_PKG_CONFIG_CFLAGS=$CFLAGS
8424 pre_PKG_CONFIG_LIBS=$LIBS
8425
8426 # Extract the first word of "pkg-config", so it can be a program name with args.
8427 set dummy pkg-config; ac_word=$2
8428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8429 $as_echo_n "checking for $ac_word... " >&6; }
8430 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8431 $as_echo_n "(cached) " >&6
8432 else
8433 case $PKG_CONFIG in
8434 [\\/]* | ?:[\\/]*)
8435 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8436 ;;
8437 *)
8438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8439 for as_dir in $PATH
8440 do
8441 IFS=$as_save_IFS
8442 test -z "$as_dir" && as_dir=.
8443 for ac_exec_ext in '' $ac_executable_extensions; do
8444 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8445 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8447 break 2
8448 fi
8449 done
8450 done
8451 IFS=$as_save_IFS
8452
8453 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8454 ;;
8455 esac
8456 fi
8457 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8458 if test -n "$PKG_CONFIG"; then
8459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8460 $as_echo "$PKG_CONFIG" >&6; }
8461 else
8462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8463 $as_echo "no" >&6; }
8464 fi
8465
8466
8467
8468
8469
8470
8471 if test "${with_sound}" != "no"; then
8472 # Sound support for GNU/Linux and the free BSDs.
8473 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8474 do :
8475 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8476 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8477 eval as_val=\$$as_ac_Header
8478 if test "x$as_val" = x""yes; then :
8479 cat >>confdefs.h <<_ACEOF
8480 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8481 _ACEOF
8482 have_sound_header=yes
8483 fi
8484
8485 done
8486
8487 # Emulation library used on NetBSD.
8488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8489 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8490 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8491 $as_echo_n "(cached) " >&6
8492 else
8493 ac_check_lib_save_LIBS=$LIBS
8494 LIBS="-lossaudio $LIBS"
8495 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8496 /* end confdefs.h. */
8497
8498 /* Override any GCC internal prototype to avoid an error.
8499 Use char because int might match the return type of a GCC
8500 builtin and then its argument prototype would still apply. */
8501 #ifdef __cplusplus
8502 extern "C"
8503 #endif
8504 char _oss_ioctl ();
8505 int
8506 main ()
8507 {
8508 return _oss_ioctl ();
8509 ;
8510 return 0;
8511 }
8512 _ACEOF
8513 if ac_fn_c_try_link "$LINENO"; then :
8514 ac_cv_lib_ossaudio__oss_ioctl=yes
8515 else
8516 ac_cv_lib_ossaudio__oss_ioctl=no
8517 fi
8518 rm -f core conftest.err conftest.$ac_objext \
8519 conftest$ac_exeext conftest.$ac_ext
8520 LIBS=$ac_check_lib_save_LIBS
8521 fi
8522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8523 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8524 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8525 LIBSOUND=-lossaudio
8526 else
8527 LIBSOUND=
8528 fi
8529
8530
8531
8532 ALSA_REQUIRED=1.0.0
8533 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8534
8535 succeeded=no
8536
8537 if test "$PKG_CONFIG" = "no" ; then
8538 HAVE_ALSA=no
8539 else
8540 PKG_CONFIG_MIN_VERSION=0.9.0
8541 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8543 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8544
8545 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8546 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8547 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8548 edit_cflags="
8549 s,///*,/,g
8550 s/^/ /
8551 s/ -I/ $isystem/g
8552 s/^ //
8553 "
8554 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e "$edit_cflags"`
8555 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8557 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8558 succeeded=yes
8559 else
8560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8561 $as_echo "no" >&6; }
8562 ALSA_CFLAGS=""
8563 ALSA_LIBS=""
8564 ## If we have a custom action on failure, don't print errors, but
8565 ## do set a variable so people can do so. Do it in a subshell
8566 ## to capture any diagnostics in invoking pkg-config.
8567 ALSA_PKG_ERRORS=`($PKG_CONFIG --print-errors "$ALSA_MODULES") 2>&1`
8568
8569 fi
8570
8571
8572
8573 else
8574 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8575 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8576 fi
8577 fi
8578
8579 if test $succeeded = yes; then
8580 HAVE_ALSA=yes
8581 else
8582 HAVE_ALSA=no
8583 fi
8584
8585 if test $HAVE_ALSA = yes; then
8586 SAVE_CFLAGS="$CFLAGS"
8587 SAVE_LIBS="$LIBS"
8588 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8589 LIBS="$ALSA_LIBS $LIBS"
8590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8591 /* end confdefs.h. */
8592 #include <asoundlib.h>
8593 int
8594 main ()
8595 {
8596 snd_lib_error_set_handler (0);
8597 ;
8598 return 0;
8599 }
8600 _ACEOF
8601 if ac_fn_c_try_compile "$LINENO"; then :
8602 emacs_alsa_normal=yes
8603 else
8604 emacs_alsa_normal=no
8605 fi
8606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8607 if test "$emacs_alsa_normal" != yes; then
8608 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8609 /* end confdefs.h. */
8610 #include <alsa/asoundlib.h>
8611 int
8612 main ()
8613 {
8614 snd_lib_error_set_handler (0);
8615 ;
8616 return 0;
8617 }
8618 _ACEOF
8619 if ac_fn_c_try_compile "$LINENO"; then :
8620 emacs_alsa_subdir=yes
8621 else
8622 emacs_alsa_subdir=no
8623 fi
8624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8625 if test "$emacs_alsa_subdir" != yes; then
8626 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8627 fi
8628 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8629 fi
8630
8631 CFLAGS="$SAVE_CFLAGS"
8632 LIBS="$SAVE_LIBS"
8633 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8634 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8635
8636 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8637
8638 fi
8639
8640 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8641 case "$opsys" in
8642 gnu-linux|freebsd|netbsd)
8643
8644 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8645
8646 ;;
8647 esac
8648 fi
8649
8650
8651 fi
8652
8653
8654
8655
8656 for ac_header in $ac_header_list
8657 do :
8658 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8659 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
8660 "
8661 eval as_val=\$$as_ac_Header
8662 if test "x$as_val" = x""yes; then :
8663 cat >>confdefs.h <<_ACEOF
8664 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8665 _ACEOF
8666
8667 fi
8668
8669 done
8670
8671
8672
8673
8674
8675
8676
8677
8678
8679
8680
8681
8682
8683
8684
8685
8686
8687
8688
8689
8690
8691
8692
8693
8694
8695
8696
8697
8698
8699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8700 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8702 /* end confdefs.h. */
8703 #include <sys/personality.h>
8704 int
8705 main ()
8706 {
8707 personality (PER_LINUX32)
8708 ;
8709 return 0;
8710 }
8711 _ACEOF
8712 if ac_fn_c_try_compile "$LINENO"; then :
8713 emacs_cv_personality_linux32=yes
8714 else
8715 emacs_cv_personality_linux32=no
8716 fi
8717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8719 $as_echo "$emacs_cv_personality_linux32" >&6; }
8720
8721 if test $emacs_cv_personality_linux32 = yes; then
8722
8723 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8724
8725 fi
8726
8727 for ac_header in term.h
8728 do :
8729 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8730 if test "x$ac_cv_header_term_h" = x""yes; then :
8731 cat >>confdefs.h <<_ACEOF
8732 #define HAVE_TERM_H 1
8733 _ACEOF
8734
8735 fi
8736
8737 done
8738
8739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8740 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8741 if test "${ac_cv_header_time+set}" = set; then :
8742 $as_echo_n "(cached) " >&6
8743 else
8744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8745 /* end confdefs.h. */
8746 #include <sys/types.h>
8747 #include <sys/time.h>
8748 #include <time.h>
8749
8750 int
8751 main ()
8752 {
8753 if ((struct tm *) 0)
8754 return 0;
8755 ;
8756 return 0;
8757 }
8758 _ACEOF
8759 if ac_fn_c_try_compile "$LINENO"; then :
8760 ac_cv_header_time=yes
8761 else
8762 ac_cv_header_time=no
8763 fi
8764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8765 fi
8766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8767 $as_echo "$ac_cv_header_time" >&6; }
8768 if test $ac_cv_header_time = yes; then
8769
8770 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8771
8772 fi
8773
8774 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8775 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8776 ac_have_decl=1
8777 else
8778 ac_have_decl=0
8779 fi
8780
8781 cat >>confdefs.h <<_ACEOF
8782 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8783 _ACEOF
8784
8785 if test $ac_cv_have_decl_sys_siglist != yes; then
8786 # For Tru64, at least:
8787 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8788 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8789 ac_have_decl=1
8790 else
8791 ac_have_decl=0
8792 fi
8793
8794 cat >>confdefs.h <<_ACEOF
8795 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8796 _ACEOF
8797
8798 if test $ac_cv_have_decl___sys_siglist = yes; then
8799
8800 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8801
8802 fi
8803 fi
8804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8805 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8806 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8807 $as_echo_n "(cached) " >&6
8808 else
8809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8810 /* end confdefs.h. */
8811 #include <sys/types.h>
8812 #include <sys/wait.h>
8813 #ifndef WEXITSTATUS
8814 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8815 #endif
8816 #ifndef WIFEXITED
8817 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8818 #endif
8819
8820 int
8821 main ()
8822 {
8823 int s;
8824 wait (&s);
8825 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8826 ;
8827 return 0;
8828 }
8829 _ACEOF
8830 if ac_fn_c_try_compile "$LINENO"; then :
8831 ac_cv_header_sys_wait_h=yes
8832 else
8833 ac_cv_header_sys_wait_h=no
8834 fi
8835 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8836 fi
8837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8838 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8839 if test $ac_cv_header_sys_wait_h = yes; then
8840
8841 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8842
8843 fi
8844
8845
8846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8847 $as_echo_n "checking for speed_t... " >&6; }
8848 if test "${emacs_cv_speed_t+set}" = set; then :
8849 $as_echo_n "(cached) " >&6
8850 else
8851 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8852 /* end confdefs.h. */
8853 #include <termios.h>
8854 int
8855 main ()
8856 {
8857 speed_t x = 1;
8858 ;
8859 return 0;
8860 }
8861 _ACEOF
8862 if ac_fn_c_try_compile "$LINENO"; then :
8863 emacs_cv_speed_t=yes
8864 else
8865 emacs_cv_speed_t=no
8866 fi
8867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8868 fi
8869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8870 $as_echo "$emacs_cv_speed_t" >&6; }
8871 if test $emacs_cv_speed_t = yes; then
8872
8873 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8874
8875 fi
8876
8877
8878
8879
8880 for ac_header in net/if.h
8881 do :
8882 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8883 #if HAVE_SYS_SOCKET_H
8884 #include <sys/socket.h>
8885 #endif
8886 "
8887 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8888 cat >>confdefs.h <<_ACEOF
8889 #define HAVE_NET_IF_H 1
8890 _ACEOF
8891
8892 fi
8893
8894 done
8895
8896 for ac_header in ifaddrs.h
8897 do :
8898 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8899 #if HAVE_SYS_SOCKET_H
8900 #include <sys/socket.h>
8901 #endif
8902 "
8903 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8904 cat >>confdefs.h <<_ACEOF
8905 #define HAVE_IFADDRS_H 1
8906 _ACEOF
8907
8908 fi
8909
8910 done
8911
8912 for ac_header in net/if_dl.h
8913 do :
8914 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8915 #if HAVE_SYS_SOCKET_H
8916 #include <sys/socket.h>
8917 #endif
8918 "
8919 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8920 cat >>confdefs.h <<_ACEOF
8921 #define HAVE_NET_IF_DL_H 1
8922 _ACEOF
8923
8924 fi
8925
8926 done
8927
8928
8929 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8930 #if HAVE_SYS_SOCKET_H
8931 #include <sys/socket.h>
8932 #endif
8933 #if HAVE_NET_IF_H
8934 #include <net/if.h>
8935 #endif
8936 "
8937 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8938
8939 cat >>confdefs.h <<_ACEOF
8940 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8941 _ACEOF
8942
8943
8944 fi
8945 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8946 #if HAVE_SYS_SOCKET_H
8947 #include <sys/socket.h>
8948 #endif
8949 #if HAVE_NET_IF_H
8950 #include <net/if.h>
8951 #endif
8952 "
8953 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8954
8955 cat >>confdefs.h <<_ACEOF
8956 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8957 _ACEOF
8958
8959
8960 fi
8961 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8962 #if HAVE_SYS_SOCKET_H
8963 #include <sys/socket.h>
8964 #endif
8965 #if HAVE_NET_IF_H
8966 #include <net/if.h>
8967 #endif
8968 "
8969 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
8970
8971 cat >>confdefs.h <<_ACEOF
8972 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8973 _ACEOF
8974
8975
8976 fi
8977 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8978 #if HAVE_SYS_SOCKET_H
8979 #include <sys/socket.h>
8980 #endif
8981 #if HAVE_NET_IF_H
8982 #include <net/if.h>
8983 #endif
8984 "
8985 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
8986
8987 cat >>confdefs.h <<_ACEOF
8988 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8989 _ACEOF
8990
8991
8992 fi
8993 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8994 #if HAVE_SYS_SOCKET_H
8995 #include <sys/socket.h>
8996 #endif
8997 #if HAVE_NET_IF_H
8998 #include <net/if.h>
8999 #endif
9000 "
9001 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
9002
9003 cat >>confdefs.h <<_ACEOF
9004 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
9005 _ACEOF
9006
9007
9008 fi
9009 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
9010 #if HAVE_SYS_SOCKET_H
9011 #include <sys/socket.h>
9012 #endif
9013 #if HAVE_NET_IF_H
9014 #include <net/if.h>
9015 #endif
9016 "
9017 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
9018
9019 cat >>confdefs.h <<_ACEOF
9020 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
9021 _ACEOF
9022
9023
9024 fi
9025
9026
9027
9028
9029 DEPFLAGS=
9030 MKDEPDIR=":"
9031 deps_frag=deps.mk
9032 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9034 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9035 HAVE_GNU_MAKE=no
9036 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9037 if test "x$testval" != x; then
9038 HAVE_GNU_MAKE=yes
9039 else
9040 ac_enable_autodepend=no
9041 fi
9042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9043 $as_echo "$HAVE_GNU_MAKE" >&6; }
9044 if test $HAVE_GNU_MAKE = yes; then
9045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9046 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9047 SAVE_CFLAGS="$CFLAGS"
9048 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9050 /* end confdefs.h. */
9051
9052 int
9053 main ()
9054 {
9055
9056 ;
9057 return 0;
9058 }
9059 _ACEOF
9060 if ac_fn_c_try_compile "$LINENO"; then :
9061
9062 else
9063 ac_enable_autodepend=no
9064 fi
9065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9066 CFLAGS="$SAVE_CFLAGS"
9067 test -f deps.d || ac_enable_autodepend=no
9068 rm -rf deps.d
9069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9070 $as_echo "$ac_enable_autodepend" >&6; }
9071 fi
9072 if test $ac_enable_autodepend = yes; then
9073 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9074 ## MKDIR_P is documented (see AC_PROG_MKDIR_P) to be parallel-safe.
9075 MKDEPDIR='${MKDIR_P} ${DEPDIR}'
9076 deps_frag=autodeps.mk
9077 fi
9078 fi
9079 deps_frag=$srcdir/src/$deps_frag
9080
9081
9082
9083
9084
9085 lisp_frag=$srcdir/src/lisp.mk
9086
9087
9088
9089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9090 $as_echo_n "checking for long file names... " >&6; }
9091 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9092 $as_echo_n "(cached) " >&6
9093 else
9094 ac_cv_sys_long_file_names=yes
9095 # Test for long file names in all the places we know might matter:
9096 # . the current directory, where building will happen
9097 # $prefix/lib where we will be installing things
9098 # $exec_prefix/lib likewise
9099 # $TMPDIR if set, where it might want to write temporary files
9100 # /tmp where it might want to write temporary files
9101 # /var/tmp likewise
9102 # /usr/tmp likewise
9103 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9104 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9105 # in the usual case where exec_prefix is '${prefix}'.
9106 case $ac_dir in #(
9107 . | /* | ?:[\\/]*) ;; #(
9108 *) continue;;
9109 esac
9110 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9111 ac_xdir=$ac_dir/cf$$
9112 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9113 ac_tf1=$ac_xdir/conftest9012345
9114 ac_tf2=$ac_xdir/conftest9012346
9115 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9116 ac_cv_sys_long_file_names=no
9117 rm -f -r "$ac_xdir" 2>/dev/null
9118 test $ac_cv_sys_long_file_names = no && break
9119 done
9120 fi
9121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9122 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9123 if test $ac_cv_sys_long_file_names = yes; then
9124
9125 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9126
9127 fi
9128
9129
9130 #### Choose a window system.
9131
9132 ## We leave window_system equal to none if
9133 ## we end up building without one. Any new window system should
9134 ## set window_system to an appropriate value and add objects to
9135 ## window-system-specific substs.
9136
9137 window_system=none
9138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9139 $as_echo_n "checking for X... " >&6; }
9140
9141
9142 # Check whether --with-x was given.
9143 if test "${with_x+set}" = set; then :
9144 withval=$with_x;
9145 fi
9146
9147 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9148 if test "x$with_x" = xno; then
9149 # The user explicitly disabled X.
9150 have_x=disabled
9151 else
9152 case $x_includes,$x_libraries in #(
9153 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9154 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9155 $as_echo_n "(cached) " >&6
9156 else
9157 # One or both of the vars are not set, and there is no cached value.
9158 ac_x_includes=no ac_x_libraries=no
9159 rm -f -r conftest.dir
9160 if mkdir conftest.dir; then
9161 cd conftest.dir
9162 cat >Imakefile <<'_ACEOF'
9163 incroot:
9164 @echo incroot='${INCROOT}'
9165 usrlibdir:
9166 @echo usrlibdir='${USRLIBDIR}'
9167 libdir:
9168 @echo libdir='${LIBDIR}'
9169 _ACEOF
9170 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9171 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9172 for ac_var in incroot usrlibdir libdir; do
9173 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9174 done
9175 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9176 for ac_extension in a so sl dylib la dll; do
9177 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9178 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9179 ac_im_usrlibdir=$ac_im_libdir; break
9180 fi
9181 done
9182 # Screen out bogus values from the imake configuration. They are
9183 # bogus both because they are the default anyway, and because
9184 # using them would break gcc on systems where it needs fixed includes.
9185 case $ac_im_incroot in
9186 /usr/include) ac_x_includes= ;;
9187 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9188 esac
9189 case $ac_im_usrlibdir in
9190 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9191 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9192 esac
9193 fi
9194 cd ..
9195 rm -f -r conftest.dir
9196 fi
9197
9198 # Standard set of common directories for X headers.
9199 # Check X11 before X11Rn because it is often a symlink to the current release.
9200 ac_x_header_dirs='
9201 /usr/X11/include
9202 /usr/X11R7/include
9203 /usr/X11R6/include
9204 /usr/X11R5/include
9205 /usr/X11R4/include
9206
9207 /usr/include/X11
9208 /usr/include/X11R7
9209 /usr/include/X11R6
9210 /usr/include/X11R5
9211 /usr/include/X11R4
9212
9213 /usr/local/X11/include
9214 /usr/local/X11R7/include
9215 /usr/local/X11R6/include
9216 /usr/local/X11R5/include
9217 /usr/local/X11R4/include
9218
9219 /usr/local/include/X11
9220 /usr/local/include/X11R7
9221 /usr/local/include/X11R6
9222 /usr/local/include/X11R5
9223 /usr/local/include/X11R4
9224
9225 /usr/X386/include
9226 /usr/x386/include
9227 /usr/XFree86/include/X11
9228
9229 /usr/include
9230 /usr/local/include
9231 /usr/unsupported/include
9232 /usr/athena/include
9233 /usr/local/x11r5/include
9234 /usr/lpp/Xamples/include
9235
9236 /usr/openwin/include
9237 /usr/openwin/share/include'
9238
9239 if test "$ac_x_includes" = no; then
9240 # Guess where to find include files, by looking for Xlib.h.
9241 # First, try using that file with no special directory specified.
9242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9243 /* end confdefs.h. */
9244 #include <X11/Xlib.h>
9245 _ACEOF
9246 if ac_fn_c_try_cpp "$LINENO"; then :
9247 # We can compile using X headers with no special include directory.
9248 ac_x_includes=
9249 else
9250 for ac_dir in $ac_x_header_dirs; do
9251 if test -r "$ac_dir/X11/Xlib.h"; then
9252 ac_x_includes=$ac_dir
9253 break
9254 fi
9255 done
9256 fi
9257 rm -f conftest.err conftest.$ac_ext
9258 fi # $ac_x_includes = no
9259
9260 if test "$ac_x_libraries" = no; then
9261 # Check for the libraries.
9262 # See if we find them without any special options.
9263 # Don't add to $LIBS permanently.
9264 ac_save_LIBS=$LIBS
9265 LIBS="-lX11 $LIBS"
9266 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9267 /* end confdefs.h. */
9268 #include <X11/Xlib.h>
9269 int
9270 main ()
9271 {
9272 XrmInitialize ()
9273 ;
9274 return 0;
9275 }
9276 _ACEOF
9277 if ac_fn_c_try_link "$LINENO"; then :
9278 LIBS=$ac_save_LIBS
9279 # We can link X programs with no special library path.
9280 ac_x_libraries=
9281 else
9282 LIBS=$ac_save_LIBS
9283 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9284 do
9285 # Don't even attempt the hair of trying to link an X program!
9286 for ac_extension in a so sl dylib la dll; do
9287 if test -r "$ac_dir/libX11.$ac_extension"; then
9288 ac_x_libraries=$ac_dir
9289 break 2
9290 fi
9291 done
9292 done
9293 fi
9294 rm -f core conftest.err conftest.$ac_objext \
9295 conftest$ac_exeext conftest.$ac_ext
9296 fi # $ac_x_libraries = no
9297
9298 case $ac_x_includes,$ac_x_libraries in #(
9299 no,* | *,no | *\'*)
9300 # Didn't find X, or a directory has "'" in its name.
9301 ac_cv_have_x="have_x=no";; #(
9302 *)
9303 # Record where we found X for the cache.
9304 ac_cv_have_x="have_x=yes\
9305 ac_x_includes='$ac_x_includes'\
9306 ac_x_libraries='$ac_x_libraries'"
9307 esac
9308 fi
9309 ;; #(
9310 *) have_x=yes;;
9311 esac
9312 eval "$ac_cv_have_x"
9313 fi # $with_x != no
9314
9315 if test "$have_x" != yes; then
9316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9317 $as_echo "$have_x" >&6; }
9318 no_x=yes
9319 else
9320 # If each of the values was on the command line, it overrides each guess.
9321 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9322 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9323 # Update the cache value to reflect the command line values.
9324 ac_cv_have_x="have_x=yes\
9325 ac_x_includes='$x_includes'\
9326 ac_x_libraries='$x_libraries'"
9327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9328 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9329 fi
9330
9331 if test "$no_x" != yes; then
9332 window_system=x11
9333 fi
9334
9335 LD_SWITCH_X_SITE_RPATH=
9336 if test "${x_libraries}" != NONE; then
9337 if test -n "${x_libraries}"; then
9338 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9339 LD_SWITCH_X_SITE_RPATH=-Wl,-rpath,`echo ${x_libraries} | sed -e "s/:/ -Wl,-rpath,/g"`
9340 fi
9341 x_default_search_path=""
9342 x_search_path=${x_libraries}
9343 if test -z "${x_search_path}"; then
9344 x_search_path=/usr/lib
9345 fi
9346 for x_library in `echo ${x_search_path}: | \
9347 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9348 x_search_path="\
9349 ${x_library}/X11/%L/%T/%N%C%S:\
9350 ${x_library}/X11/%l/%T/%N%C%S:\
9351 ${x_library}/X11/%T/%N%C%S:\
9352 ${x_library}/X11/%L/%T/%N%S:\
9353 ${x_library}/X11/%l/%T/%N%S:\
9354 ${x_library}/X11/%T/%N%S"
9355 if test x"${x_default_search_path}" = x; then
9356 x_default_search_path=${x_search_path}
9357 else
9358 x_default_search_path="${x_search_path}:${x_default_search_path}"
9359 fi
9360 done
9361 fi
9362
9363
9364 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9365 C_SWITCH_X_SITE="$isystem"`echo ${x_includes} | sed -e "s/:/ $isystem/g"`
9366 fi
9367
9368 if test x"${x_includes}" = x; then
9369 bitmapdir=/usr/include/X11/bitmaps
9370 else
9371 # accumulate include directories that have X11 bitmap subdirectories
9372 bmd_acc="dummyval"
9373 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9374 if test -d "${bmd}/X11/bitmaps"; then
9375 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9376 fi
9377 if test -d "${bmd}/bitmaps"; then
9378 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9379 fi
9380 done
9381 if test ${bmd_acc} != "dummyval"; then
9382 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9383 fi
9384 fi
9385
9386 HAVE_NS=no
9387 NS_IMPL_COCOA=no
9388 NS_IMPL_GNUSTEP=no
9389 tmp_CPPFLAGS="$CPPFLAGS"
9390 tmp_CFLAGS="$CFLAGS"
9391 CPPFLAGS="$CPPFLAGS -x objective-c"
9392 CFLAGS="$CFLAGS -x objective-c"
9393 TEMACS_LDFLAGS2="\${LDFLAGS}"
9394 GNU_OBJC_CFLAGS=
9395 if test "${with_ns}" != no; then
9396 if test "${opsys}" = darwin; then
9397 NS_IMPL_COCOA=yes
9398 ns_appdir=`pwd`/nextstep/Emacs.app
9399 ns_appbindir=${ns_appdir}/Contents/MacOS
9400 ns_appresdir=${ns_appdir}/Contents/Resources
9401 ns_appsrc=Cocoa/Emacs.base
9402 elif test -f $GNUSTEP_CONFIG_FILE; then
9403 NS_IMPL_GNUSTEP=yes
9404 ns_appdir=`pwd`/nextstep/Emacs.app
9405 ns_appbindir=${ns_appdir}
9406 ns_appresdir=${ns_appdir}/Resources
9407 ns_appsrc=GNUstep/Emacs.base
9408 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9409 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9410 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9411 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9412 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9413 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9414 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9415 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9416 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9417 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9418 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9419 LIB_STANDARD=
9420 START_FILES=
9421 TEMACS_LDFLAGS2=
9422 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9423 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9424 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9425 $as_echo_n "(cached) " >&6
9426 else
9427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9428 /* end confdefs.h. */
9429 #include <GNUstepBase/GSConfig.h>
9430 int
9431 main ()
9432 {
9433 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9434 1;
9435 #else
9436 fail;
9437 #endif
9438 ;
9439 return 0;
9440 }
9441 _ACEOF
9442 if ac_fn_c_try_compile "$LINENO"; then :
9443 emacs_cv_objc_exceptions=yes
9444 else
9445 emacs_cv_objc_exceptions=no
9446 fi
9447 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9448 fi
9449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9450 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9451 if test $emacs_cv_objc_exceptions = yes; then
9452
9453 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9454
9455 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9456 fi
9457 fi
9458
9459 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9460
9461 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9462 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9463 HAVE_NS=yes
9464 else
9465 as_fn_error "\`--with-ns' was specified, but the include
9466 files are missing or cannot be compiled." "$LINENO" 5
9467 fi
9468
9469
9470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9471 /* end confdefs.h. */
9472 #include <Foundation/NSObjCRuntime.h>
9473 int
9474 main ()
9475 {
9476 NSInteger i;
9477 ;
9478 return 0;
9479 }
9480 _ACEOF
9481 if ac_fn_c_try_compile "$LINENO"; then :
9482 ns_have_nsinteger=yes
9483 else
9484 ns_have_nsinteger=no
9485 fi
9486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9487 if test $ns_have_nsinteger = yes; then
9488
9489 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
9490
9491 fi
9492 fi
9493
9494
9495 INSTALL_ARCH_INDEP_EXTRA=install-etc
9496 ns_self_contained=no
9497 NS_OBJ=
9498 NS_OBJC_OBJ=
9499 if test "${HAVE_NS}" = yes; then
9500 if test "$with_toolkit_scroll_bars" = "no"; then
9501 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9502 fi
9503
9504 window_system=nextstep
9505 # set up packaging dirs
9506 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9507 ns_self_contained=yes
9508 prefix=${ns_appresdir}
9509 exec_prefix=${ns_appbindir}
9510 libexecdir="\${ns_appbindir}/libexec"
9511 archlibdir="\${ns_appbindir}/libexec"
9512 docdir="\${ns_appresdir}/etc"
9513 etcdir="\${ns_appresdir}/etc"
9514 infodir="\${ns_appresdir}/info"
9515 mandir="\${ns_appresdir}/man"
9516 lispdir="\${ns_appresdir}/lisp"
9517 leimdir="\${ns_appresdir}/leim"
9518 INSTALL_ARCH_INDEP_EXTRA=
9519 fi
9520 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9521 fi
9522 CFLAGS="$tmp_CFLAGS"
9523 CPPFLAGS="$tmp_CPPFLAGS"
9524
9525
9526
9527
9528
9529
9530 ## $window_system is now set to the window system we will
9531 ## ultimately use.
9532
9533 term_header=
9534 HAVE_X_WINDOWS=no
9535 HAVE_X11=no
9536 USE_X_TOOLKIT=none
9537
9538 case "${window_system}" in
9539 x11 )
9540 HAVE_X_WINDOWS=yes
9541 HAVE_X11=yes
9542 term_header=xterm.h
9543 case "${with_x_toolkit}" in
9544 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9545 motif ) USE_X_TOOLKIT=MOTIF ;;
9546 gtk ) with_gtk=yes
9547 term_header=gtkutil.h
9548 USE_X_TOOLKIT=none ;;
9549 gtk2 ) with_gtk2=yes
9550 term_header=gtkutil.h
9551 USE_X_TOOLKIT=none ;;
9552 gtk3 ) with_gtk3=yes
9553 term_header=gtkutil.h
9554 USE_X_TOOLKIT=none ;;
9555 no ) USE_X_TOOLKIT=none ;;
9556 * ) USE_X_TOOLKIT=maybe ;;
9557 esac
9558 ;;
9559 nextstep )
9560 term_header=nsterm.h
9561 ;;
9562 esac
9563
9564 if test -n "${term_header}"; then
9565
9566 cat >>confdefs.h <<_ACEOF
9567 #define TERM_HEADER "${term_header}"
9568 _ACEOF
9569
9570 fi
9571
9572 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9573 # Extract the first word of "X", so it can be a program name with args.
9574 set dummy X; ac_word=$2
9575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9576 $as_echo_n "checking for $ac_word... " >&6; }
9577 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9578 $as_echo_n "(cached) " >&6
9579 else
9580 if test -n "$HAVE_XSERVER"; then
9581 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9582 else
9583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9584 for as_dir in $PATH
9585 do
9586 IFS=$as_save_IFS
9587 test -z "$as_dir" && as_dir=.
9588 for ac_exec_ext in '' $ac_executable_extensions; do
9589 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9590 ac_cv_prog_HAVE_XSERVER="true"
9591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9592 break 2
9593 fi
9594 done
9595 done
9596 IFS=$as_save_IFS
9597
9598 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9599 fi
9600 fi
9601 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9602 if test -n "$HAVE_XSERVER"; then
9603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9604 $as_echo "$HAVE_XSERVER" >&6; }
9605 else
9606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9607 $as_echo "no" >&6; }
9608 fi
9609
9610
9611 if test "$HAVE_XSERVER" = true ||
9612 test -n "$DISPLAY" ||
9613 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9614 as_fn_error "You seem to be running X, but no X development libraries
9615 were found. You should install the relevant development files for X
9616 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9617 sure you have development files for image handling, i.e.
9618 tiff, gif, jpeg, png and xpm.
9619 If you are sure you want Emacs compiled without X window support, pass
9620 --without-x
9621 to configure." "$LINENO" 5
9622 fi
9623 fi
9624
9625 ### If we're using X11, we should use the X menu package.
9626 HAVE_MENUS=no
9627 case ${HAVE_X11} in
9628 yes ) HAVE_MENUS=yes ;;
9629 esac
9630
9631 # Does the opsystem file prohibit the use of the GNU malloc?
9632 # Assume not, until told otherwise.
9633 GNU_MALLOC=yes
9634
9635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether malloc is Doug Lea style" >&5
9636 $as_echo_n "checking whether malloc is Doug Lea style... " >&6; }
9637 if test "${emacs_cv_var_doug_lea_malloc+set}" = set; then :
9638 $as_echo_n "(cached) " >&6
9639 else
9640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9641 /* end confdefs.h. */
9642 #include <malloc.h>
9643 static void hook (void) {}
9644 int
9645 main ()
9646 {
9647 malloc_set_state (malloc_get_state ());
9648 __after_morecore_hook = hook;
9649 __malloc_initialize_hook = hook;
9650 ;
9651 return 0;
9652 }
9653 _ACEOF
9654 if ac_fn_c_try_link "$LINENO"; then :
9655 emacs_cv_var_doug_lea_malloc=yes
9656 else
9657 emacs_cv_var_doug_lea_malloc=no
9658 fi
9659 rm -f core conftest.err conftest.$ac_objext \
9660 conftest$ac_exeext conftest.$ac_ext
9661 fi
9662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var_doug_lea_malloc" >&5
9663 $as_echo "$emacs_cv_var_doug_lea_malloc" >&6; }
9664 doug_lea_malloc=$emacs_cv_var_doug_lea_malloc
9665
9666
9667 system_malloc=no
9668 case "$opsys" in
9669 ## darwin ld insists on the use of malloc routines in the System framework.
9670 darwin|sol2-10) system_malloc=yes ;;
9671 esac
9672
9673 if test "${system_malloc}" = "yes"; then
9674
9675 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9676
9677 GNU_MALLOC=no
9678 GNU_MALLOC_reason="
9679 (The GNU allocators don't work with this system configuration.)"
9680 GMALLOC_OBJ=
9681 VMLIMIT_OBJ=
9682 else
9683 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9684 VMLIMIT_OBJ=vm-limit.o
9685 fi
9686
9687
9688
9689 if test "$doug_lea_malloc" = "yes" ; then
9690 if test "$GNU_MALLOC" = yes ; then
9691 GNU_MALLOC_reason="
9692 (Using Doug Lea's new malloc from the GNU C Library.)"
9693 fi
9694
9695 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9696
9697
9698 ## Use mmap directly for allocating larger buffers.
9699 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9700 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9701 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
9702 case "$opsys" in
9703 gnu*) REL_ALLOC=no ;;
9704 esac
9705 fi
9706
9707 if test x"${REL_ALLOC}" = x; then
9708 REL_ALLOC=${GNU_MALLOC}
9709 fi
9710
9711 use_mmap_for_buffers=no
9712 case "$opsys" in
9713 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9714 esac
9715
9716
9717
9718
9719
9720
9721
9722
9723 for ac_func in getpagesize
9724 do :
9725 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9726 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9727 cat >>confdefs.h <<_ACEOF
9728 #define HAVE_GETPAGESIZE 1
9729 _ACEOF
9730
9731 fi
9732 done
9733
9734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9735 $as_echo_n "checking for working mmap... " >&6; }
9736 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9737 $as_echo_n "(cached) " >&6
9738 else
9739 if test "$cross_compiling" = yes; then :
9740 ac_cv_func_mmap_fixed_mapped=no
9741 else
9742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9743 /* end confdefs.h. */
9744 $ac_includes_default
9745 /* malloc might have been renamed as rpl_malloc. */
9746 #undef malloc
9747
9748 /* Thanks to Mike Haertel and Jim Avera for this test.
9749 Here is a matrix of mmap possibilities:
9750 mmap private not fixed
9751 mmap private fixed at somewhere currently unmapped
9752 mmap private fixed at somewhere already mapped
9753 mmap shared not fixed
9754 mmap shared fixed at somewhere currently unmapped
9755 mmap shared fixed at somewhere already mapped
9756 For private mappings, we should verify that changes cannot be read()
9757 back from the file, nor mmap's back from the file at a different
9758 address. (There have been systems where private was not correctly
9759 implemented like the infamous i386 svr4.0, and systems where the
9760 VM page cache was not coherent with the file system buffer cache
9761 like early versions of FreeBSD and possibly contemporary NetBSD.)
9762 For shared mappings, we should conversely verify that changes get
9763 propagated back to all the places they're supposed to be.
9764
9765 Grep wants private fixed already mapped.
9766 The main things grep needs to know about mmap are:
9767 * does it exist and is it safe to write into the mmap'd area
9768 * how to use it (BSD variants) */
9769
9770 #include <fcntl.h>
9771 #include <sys/mman.h>
9772
9773 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9774 char *malloc ();
9775 #endif
9776
9777 /* This mess was copied from the GNU getpagesize.h. */
9778 #ifndef HAVE_GETPAGESIZE
9779 # ifdef _SC_PAGESIZE
9780 # define getpagesize() sysconf(_SC_PAGESIZE)
9781 # else /* no _SC_PAGESIZE */
9782 # ifdef HAVE_SYS_PARAM_H
9783 # include <sys/param.h>
9784 # ifdef EXEC_PAGESIZE
9785 # define getpagesize() EXEC_PAGESIZE
9786 # else /* no EXEC_PAGESIZE */
9787 # ifdef NBPG
9788 # define getpagesize() NBPG * CLSIZE
9789 # ifndef CLSIZE
9790 # define CLSIZE 1
9791 # endif /* no CLSIZE */
9792 # else /* no NBPG */
9793 # ifdef NBPC
9794 # define getpagesize() NBPC
9795 # else /* no NBPC */
9796 # ifdef PAGESIZE
9797 # define getpagesize() PAGESIZE
9798 # endif /* PAGESIZE */
9799 # endif /* no NBPC */
9800 # endif /* no NBPG */
9801 # endif /* no EXEC_PAGESIZE */
9802 # else /* no HAVE_SYS_PARAM_H */
9803 # define getpagesize() 8192 /* punt totally */
9804 # endif /* no HAVE_SYS_PARAM_H */
9805 # endif /* no _SC_PAGESIZE */
9806
9807 #endif /* no HAVE_GETPAGESIZE */
9808
9809 int
9810 main ()
9811 {
9812 char *data, *data2, *data3;
9813 const char *cdata2;
9814 int i, pagesize;
9815 int fd, fd2;
9816
9817 pagesize = getpagesize ();
9818
9819 /* First, make a file with some known garbage in it. */
9820 data = (char *) malloc (pagesize);
9821 if (!data)
9822 return 1;
9823 for (i = 0; i < pagesize; ++i)
9824 *(data + i) = rand ();
9825 umask (0);
9826 fd = creat ("conftest.mmap", 0600);
9827 if (fd < 0)
9828 return 2;
9829 if (write (fd, data, pagesize) != pagesize)
9830 return 3;
9831 close (fd);
9832
9833 /* Next, check that the tail of a page is zero-filled. File must have
9834 non-zero length, otherwise we risk SIGBUS for entire page. */
9835 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9836 if (fd2 < 0)
9837 return 4;
9838 cdata2 = "";
9839 if (write (fd2, cdata2, 1) != 1)
9840 return 5;
9841 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9842 if (data2 == MAP_FAILED)
9843 return 6;
9844 for (i = 0; i < pagesize; ++i)
9845 if (*(data2 + i))
9846 return 7;
9847 close (fd2);
9848 if (munmap (data2, pagesize))
9849 return 8;
9850
9851 /* Next, try to mmap the file at a fixed address which already has
9852 something else allocated at it. If we can, also make sure that
9853 we see the same garbage. */
9854 fd = open ("conftest.mmap", O_RDWR);
9855 if (fd < 0)
9856 return 9;
9857 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9858 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9859 return 10;
9860 for (i = 0; i < pagesize; ++i)
9861 if (*(data + i) != *(data2 + i))
9862 return 11;
9863
9864 /* Finally, make sure that changes to the mapped area do not
9865 percolate back to the file as seen by read(). (This is a bug on
9866 some variants of i386 svr4.0.) */
9867 for (i = 0; i < pagesize; ++i)
9868 *(data2 + i) = *(data2 + i) + 1;
9869 data3 = (char *) malloc (pagesize);
9870 if (!data3)
9871 return 12;
9872 if (read (fd, data3, pagesize) != pagesize)
9873 return 13;
9874 for (i = 0; i < pagesize; ++i)
9875 if (*(data + i) != *(data3 + i))
9876 return 14;
9877 close (fd);
9878 return 0;
9879 }
9880 _ACEOF
9881 if ac_fn_c_try_run "$LINENO"; then :
9882 ac_cv_func_mmap_fixed_mapped=yes
9883 else
9884 ac_cv_func_mmap_fixed_mapped=no
9885 fi
9886 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9887 conftest.$ac_objext conftest.beam conftest.$ac_ext
9888 fi
9889
9890 fi
9891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9892 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9893 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9894
9895 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9896
9897 fi
9898 rm -f conftest.mmap conftest.txt
9899
9900 if test $use_mmap_for_buffers = yes; then
9901
9902 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9903
9904 REL_ALLOC=no
9905 fi
9906
9907 LIBS="$LIBS_SYSTEM $LIBS"
9908
9909 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9910 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
9911 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
9912 $as_echo_n "(cached) " >&6
9913 else
9914 ac_check_lib_save_LIBS=$LIBS
9915 LIBS="-ldnet $LIBS"
9916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9917 /* end confdefs.h. */
9918
9919 /* Override any GCC internal prototype to avoid an error.
9920 Use char because int might match the return type of a GCC
9921 builtin and then its argument prototype would still apply. */
9922 #ifdef __cplusplus
9923 extern "C"
9924 #endif
9925 char dnet_ntoa ();
9926 int
9927 main ()
9928 {
9929 return dnet_ntoa ();
9930 ;
9931 return 0;
9932 }
9933 _ACEOF
9934 if ac_fn_c_try_link "$LINENO"; then :
9935 ac_cv_lib_dnet_dnet_ntoa=yes
9936 else
9937 ac_cv_lib_dnet_dnet_ntoa=no
9938 fi
9939 rm -f core conftest.err conftest.$ac_objext \
9940 conftest$ac_exeext conftest.$ac_ext
9941 LIBS=$ac_check_lib_save_LIBS
9942 fi
9943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9944 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
9945 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
9946 cat >>confdefs.h <<_ACEOF
9947 #define HAVE_LIBDNET 1
9948 _ACEOF
9949
9950 LIBS="-ldnet $LIBS"
9951
9952 fi
9953
9954
9955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
9956 $as_echo_n "checking for main in -lXbsd... " >&6; }
9957 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
9958 $as_echo_n "(cached) " >&6
9959 else
9960 ac_check_lib_save_LIBS=$LIBS
9961 LIBS="-lXbsd $LIBS"
9962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9963 /* end confdefs.h. */
9964
9965
9966 int
9967 main ()
9968 {
9969 return main ();
9970 ;
9971 return 0;
9972 }
9973 _ACEOF
9974 if ac_fn_c_try_link "$LINENO"; then :
9975 ac_cv_lib_Xbsd_main=yes
9976 else
9977 ac_cv_lib_Xbsd_main=no
9978 fi
9979 rm -f core conftest.err conftest.$ac_objext \
9980 conftest$ac_exeext conftest.$ac_ext
9981 LIBS=$ac_check_lib_save_LIBS
9982 fi
9983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
9984 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
9985 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
9986 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
9987 fi
9988
9989
9990 LIB_PTHREAD=
9991
9992
9993
9994 if test "$ac_cv_header_pthread_h"; then
9995 if test "$GMALLOC_OBJ" = gmalloc.o; then
9996 emacs_pthread_function=pthread_atfork
9997 else
9998 emacs_pthread_function=pthread_self
9999 fi
10000 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10002 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10003 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10004 $as_echo_n "(cached) " >&6
10005 else
10006 ac_check_lib_save_LIBS=$LIBS
10007 LIBS="-lpthread $LIBS"
10008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10009 /* end confdefs.h. */
10010
10011 /* Override any GCC internal prototype to avoid an error.
10012 Use char because int might match the return type of a GCC
10013 builtin and then its argument prototype would still apply. */
10014 #ifdef __cplusplus
10015 extern "C"
10016 #endif
10017 char $emacs_pthread_function ();
10018 int
10019 main ()
10020 {
10021 return $emacs_pthread_function ();
10022 ;
10023 return 0;
10024 }
10025 _ACEOF
10026 if ac_fn_c_try_link "$LINENO"; then :
10027 eval "$as_ac_Lib=yes"
10028 else
10029 eval "$as_ac_Lib=no"
10030 fi
10031 rm -f core conftest.err conftest.$ac_objext \
10032 conftest$ac_exeext conftest.$ac_ext
10033 LIBS=$ac_check_lib_save_LIBS
10034 fi
10035 eval ac_res=\$$as_ac_Lib
10036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10037 $as_echo "$ac_res" >&6; }
10038 eval as_val=\$$as_ac_Lib
10039 if test "x$as_val" = x""yes; then :
10040 HAVE_PTHREAD=yes
10041 fi
10042
10043 fi
10044 if test "$HAVE_PTHREAD" = yes; then
10045 case "${canonical}" in
10046 *-hpux*) ;;
10047 *) LIB_PTHREAD="-lpthread"
10048 LIBS="$LIB_PTHREAD $LIBS" ;;
10049 esac
10050
10051 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10052
10053 fi
10054
10055
10056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10057 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10058 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10059 $as_echo_n "(cached) " >&6
10060 else
10061 ac_check_lib_save_LIBS=$LIBS
10062 LIBS="-lpthreads $LIBS"
10063 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10064 /* end confdefs.h. */
10065
10066 /* Override any GCC internal prototype to avoid an error.
10067 Use char because int might match the return type of a GCC
10068 builtin and then its argument prototype would still apply. */
10069 #ifdef __cplusplus
10070 extern "C"
10071 #endif
10072 char cma_open ();
10073 int
10074 main ()
10075 {
10076 return cma_open ();
10077 ;
10078 return 0;
10079 }
10080 _ACEOF
10081 if ac_fn_c_try_link "$LINENO"; then :
10082 ac_cv_lib_pthreads_cma_open=yes
10083 else
10084 ac_cv_lib_pthreads_cma_open=no
10085 fi
10086 rm -f core conftest.err conftest.$ac_objext \
10087 conftest$ac_exeext conftest.$ac_ext
10088 LIBS=$ac_check_lib_save_LIBS
10089 fi
10090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10091 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10092 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10093 cat >>confdefs.h <<_ACEOF
10094 #define HAVE_LIBPTHREADS 1
10095 _ACEOF
10096
10097 LIBS="-lpthreads $LIBS"
10098
10099 fi
10100
10101
10102 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10103 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10104 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10105 ## added to LIBS in configure would never contain the pthreads part,
10106 ## but the value used in Makefiles might. FIXME?
10107 ##
10108 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10109 ## be harmless on older versions of X where it happens to exist.
10110 test "$opsys" = "aix4-2" && \
10111 test $ac_cv_lib_pthreads_cma_open = yes && \
10112 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10113
10114
10115 case ${host_os} in
10116 aix*)
10117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10118 $as_echo_n "checking for -bbigtoc option... " >&6; }
10119 if test "${gdb_cv_bigtoc+set}" = set; then :
10120 $as_echo_n "(cached) " >&6
10121 else
10122
10123 case $GCC in
10124 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10125 *) gdb_cv_bigtoc=-bbigtoc ;;
10126 esac
10127
10128 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10130 /* end confdefs.h. */
10131
10132 int
10133 main ()
10134 {
10135 int i;
10136 ;
10137 return 0;
10138 }
10139 _ACEOF
10140 if ac_fn_c_try_link "$LINENO"; then :
10141
10142 else
10143 gdb_cv_bigtoc=
10144 fi
10145 rm -f core conftest.err conftest.$ac_objext \
10146 conftest$ac_exeext conftest.$ac_ext
10147
10148 fi
10149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10150 $as_echo "$gdb_cv_bigtoc" >&6; }
10151 ;;
10152 esac
10153
10154 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10155 # used for the tests that follow. We set them back to REAL_CFLAGS and
10156 # REAL_CPPFLAGS later on.
10157
10158 REAL_CFLAGS="$CFLAGS"
10159 REAL_CPPFLAGS="$CPPFLAGS"
10160
10161 if test "${HAVE_X11}" = "yes"; then
10162 DEFS="$C_SWITCH_X_SITE $DEFS"
10163 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10164 LIBS="-lX11 $LIBS"
10165 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10166 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10167
10168 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10169 # This is handled by LD_SWITCH_X_SITE_RPATH during the real build,
10170 # but it's more convenient here to set LD_RUN_PATH since this
10171 # also works on hosts that don't understand LD_SWITCH_X_SITE_RPATH.
10172 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10173 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10174 export LD_RUN_PATH
10175 fi
10176
10177 if test "${opsys}" = "gnu-linux"; then
10178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10179 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10180 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10181 /* end confdefs.h. */
10182
10183 int
10184 main ()
10185 {
10186 XOpenDisplay ("foo");
10187 ;
10188 return 0;
10189 }
10190 _ACEOF
10191 if ac_fn_c_try_link "$LINENO"; then :
10192 xgnu_linux_first_failure=no
10193 else
10194 xgnu_linux_first_failure=yes
10195 fi
10196 rm -f core conftest.err conftest.$ac_objext \
10197 conftest$ac_exeext conftest.$ac_ext
10198 if test "${xgnu_linux_first_failure}" = "yes"; then
10199 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10200 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10201 OLD_CPPFLAGS="$CPPFLAGS"
10202 OLD_LIBS="$LIBS"
10203 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10204 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10205 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10206 LIBS="$LIBS -b i486-linuxaout"
10207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10208 /* end confdefs.h. */
10209
10210 int
10211 main ()
10212 {
10213 XOpenDisplay ("foo");
10214 ;
10215 return 0;
10216 }
10217 _ACEOF
10218 if ac_fn_c_try_link "$LINENO"; then :
10219 xgnu_linux_second_failure=no
10220 else
10221 xgnu_linux_second_failure=yes
10222 fi
10223 rm -f core conftest.err conftest.$ac_objext \
10224 conftest$ac_exeext conftest.$ac_ext
10225 if test "${xgnu_linux_second_failure}" = "yes"; then
10226 # If we get the same failure with -b, there is no use adding -b.
10227 # So take it out. This plays safe.
10228 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10229 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10230 CPPFLAGS="$OLD_CPPFLAGS"
10231 LIBS="$OLD_LIBS"
10232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10233 $as_echo "no" >&6; }
10234 else
10235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10236 $as_echo "yes" >&6; }
10237 fi
10238 else
10239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10240 $as_echo "no" >&6; }
10241 fi
10242 fi
10243
10244 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10245 # header files included from there.
10246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10247 $as_echo_n "checking for Xkb... " >&6; }
10248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10249 /* end confdefs.h. */
10250 #include <X11/Xlib.h>
10251 #include <X11/XKBlib.h>
10252 int
10253 main ()
10254 {
10255 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10256 ;
10257 return 0;
10258 }
10259 _ACEOF
10260 if ac_fn_c_try_link "$LINENO"; then :
10261 emacs_xkb=yes
10262 else
10263 emacs_xkb=no
10264 fi
10265 rm -f core conftest.err conftest.$ac_objext \
10266 conftest$ac_exeext conftest.$ac_ext
10267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10268 $as_echo "$emacs_xkb" >&6; }
10269 if test $emacs_xkb = yes; then
10270
10271 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10272
10273 fi
10274
10275 for ac_func in XrmSetDatabase XScreenResourceString \
10276 XScreenNumberOfScreen
10277 do :
10278 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10279 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10280 eval as_val=\$$as_ac_var
10281 if test "x$as_val" = x""yes; then :
10282 cat >>confdefs.h <<_ACEOF
10283 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10284 _ACEOF
10285
10286 fi
10287 done
10288
10289 fi
10290
10291 if test "${window_system}" = "x11"; then
10292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10293 $as_echo_n "checking X11 version 6... " >&6; }
10294 if test "${emacs_cv_x11_version_6+set}" = set; then :
10295 $as_echo_n "(cached) " >&6
10296 else
10297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10298 /* end confdefs.h. */
10299 #include <X11/Xlib.h>
10300 int
10301 main ()
10302 {
10303 #if XlibSpecificationRelease < 6
10304 fail;
10305 #endif
10306
10307 ;
10308 return 0;
10309 }
10310 _ACEOF
10311 if ac_fn_c_try_link "$LINENO"; then :
10312 emacs_cv_x11_version_6=yes
10313 else
10314 emacs_cv_x11_version_6=no
10315 fi
10316 rm -f core conftest.err conftest.$ac_objext \
10317 conftest$ac_exeext conftest.$ac_ext
10318 fi
10319
10320 if test $emacs_cv_x11_version_6 = yes; then
10321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10322 $as_echo "6 or newer" >&6; }
10323
10324 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10325
10326
10327 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10328
10329 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10330 ## XIM support.
10331 case "$opsys" in
10332 sol2-*) : ;;
10333 *)
10334 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10335
10336 ;;
10337 esac
10338 else
10339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10340 $as_echo "before 6" >&6; }
10341 fi
10342 fi
10343
10344
10345 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10346 HAVE_RSVG=no
10347 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10348 if test "${with_rsvg}" != "no"; then
10349 RSVG_REQUIRED=2.11.0
10350 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10351
10352
10353 succeeded=no
10354
10355 if test "$PKG_CONFIG" = "no" ; then
10356 :
10357 else
10358 PKG_CONFIG_MIN_VERSION=0.9.0
10359 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10361 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10362
10363 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10364 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10365 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10366 edit_cflags="
10367 s,///*,/,g
10368 s/^/ /
10369 s/ -I/ $isystem/g
10370 s/^ //
10371 "
10372 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e "$edit_cflags"`
10373 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10375 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10376 succeeded=yes
10377 else
10378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10379 $as_echo "no" >&6; }
10380 RSVG_CFLAGS=""
10381 RSVG_LIBS=""
10382 ## If we have a custom action on failure, don't print errors, but
10383 ## do set a variable so people can do so. Do it in a subshell
10384 ## to capture any diagnostics in invoking pkg-config.
10385 RSVG_PKG_ERRORS=`($PKG_CONFIG --print-errors "$RSVG_MODULE") 2>&1`
10386
10387 fi
10388
10389
10390
10391 else
10392 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10393 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10394 fi
10395 fi
10396
10397 if test $succeeded = yes; then
10398 HAVE_RSVG=yes
10399 else
10400 :
10401 fi
10402
10403
10404
10405
10406 if test $HAVE_RSVG = yes; then
10407
10408 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10409
10410 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10411 LIBS="$RSVG_LIBS $LIBS"
10412 fi
10413 fi
10414 fi
10415
10416 HAVE_IMAGEMAGICK=no
10417 if test "${HAVE_X11}" = "yes"; then
10418 if test "${with_imagemagick}" != "no"; then
10419 ## 6.2.8 is the earliest version known to work, but earlier versions
10420 ## might work - let us know if you find one.
10421 ## 6.0.7 does not work. See bug#7955.
10422 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10423
10424 succeeded=no
10425
10426 if test "$PKG_CONFIG" = "no" ; then
10427 :
10428 else
10429 PKG_CONFIG_MIN_VERSION=0.9.0
10430 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10432 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10433
10434 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10435 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10436 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10437 edit_cflags="
10438 s,///*,/,g
10439 s/^/ /
10440 s/ -I/ $isystem/g
10441 s/^ //
10442 "
10443 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e "$edit_cflags"`
10444 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10446 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10447 succeeded=yes
10448 else
10449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10450 $as_echo "no" >&6; }
10451 IMAGEMAGICK_CFLAGS=""
10452 IMAGEMAGICK_LIBS=""
10453 ## If we have a custom action on failure, don't print errors, but
10454 ## do set a variable so people can do so. Do it in a subshell
10455 ## to capture any diagnostics in invoking pkg-config.
10456 IMAGEMAGICK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$IMAGEMAGICK_MODULE") 2>&1`
10457
10458 fi
10459
10460
10461
10462 else
10463 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10464 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10465 fi
10466 fi
10467
10468 if test $succeeded = yes; then
10469 HAVE_IMAGEMAGICK=yes
10470 else
10471 :
10472 fi
10473
10474
10475
10476
10477 if test $HAVE_IMAGEMAGICK = yes; then
10478
10479 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10480
10481 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10482 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10483 for ac_func in MagickExportImagePixels MagickMergeImageLayers
10484 do :
10485 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10486 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10487 eval as_val=\$$as_ac_var
10488 if test "x$as_val" = x""yes; then :
10489 cat >>confdefs.h <<_ACEOF
10490 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10491 _ACEOF
10492
10493 fi
10494 done
10495
10496 fi
10497 fi
10498 fi
10499
10500
10501 HAVE_GTK=no
10502 GTK_OBJ=
10503 check_gtk2=no
10504 gtk3_pkg_errors=
10505 if test "${with_gtk3}" = "yes" || test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10506 GLIB_REQUIRED=2.28
10507 GTK_REQUIRED=3.0
10508 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10509
10510
10511 succeeded=no
10512
10513 if test "$PKG_CONFIG" = "no" ; then
10514 pkg_check_gtk=no
10515 else
10516 PKG_CONFIG_MIN_VERSION=0.9.0
10517 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10519 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10520
10521 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10522 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10523 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10524 edit_cflags="
10525 s,///*,/,g
10526 s/^/ /
10527 s/ -I/ $isystem/g
10528 s/^ //
10529 "
10530 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10531 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10533 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10534 succeeded=yes
10535 else
10536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10537 $as_echo "no" >&6; }
10538 GTK_CFLAGS=""
10539 GTK_LIBS=""
10540 ## If we have a custom action on failure, don't print errors, but
10541 ## do set a variable so people can do so. Do it in a subshell
10542 ## to capture any diagnostics in invoking pkg-config.
10543 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10544
10545 fi
10546
10547
10548
10549 else
10550 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10551 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10552 fi
10553 fi
10554
10555 if test $succeeded = yes; then
10556 pkg_check_gtk=yes
10557 else
10558 pkg_check_gtk=no
10559 fi
10560
10561 if test "$pkg_check_gtk" = "no" && test "$with_gtk3" = "yes"; then
10562 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10563 fi
10564 if test "$pkg_check_gtk" = "yes"; then
10565
10566 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10567
10568 GTK_OBJ=emacsgtkfixed.o
10569 term_header=gtkutil.h
10570 else
10571 check_gtk2=yes
10572 gtk3_pkg_errors="$GTK_PKG_ERRORS "
10573 fi
10574 fi
10575
10576 if test "${with_gtk2}" = "yes" || test "$check_gtk2" = "yes"; then
10577 GLIB_REQUIRED=2.10
10578 GTK_REQUIRED=2.10
10579 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10580
10581
10582 succeeded=no
10583
10584 if test "$PKG_CONFIG" = "no" ; then
10585 pkg_check_gtk=no
10586 else
10587 PKG_CONFIG_MIN_VERSION=0.9.0
10588 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10590 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10591
10592 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10593 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10594 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10595 edit_cflags="
10596 s,///*,/,g
10597 s/^/ /
10598 s/ -I/ $isystem/g
10599 s/^ //
10600 "
10601 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e "$edit_cflags"`
10602 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10604 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10605 succeeded=yes
10606 else
10607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10608 $as_echo "no" >&6; }
10609 GTK_CFLAGS=""
10610 GTK_LIBS=""
10611 ## If we have a custom action on failure, don't print errors, but
10612 ## do set a variable so people can do so. Do it in a subshell
10613 ## to capture any diagnostics in invoking pkg-config.
10614 GTK_PKG_ERRORS=`($PKG_CONFIG --print-errors "$GTK_MODULES") 2>&1`
10615
10616 fi
10617
10618
10619
10620 else
10621 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10622 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10623 fi
10624 fi
10625
10626 if test $succeeded = yes; then
10627 pkg_check_gtk=yes
10628 else
10629 pkg_check_gtk=no
10630 fi
10631
10632 if test "$pkg_check_gtk" = "no" &&
10633 { test "$with_gtk" = yes || test "$with_gtk2" = "yes"; }
10634 then
10635 as_fn_error "$gtk3_pkg_errors$GTK_PKG_ERRORS" "$LINENO" 5
10636 fi
10637 fi
10638
10639 if test x"$pkg_check_gtk" = xyes; then
10640
10641
10642
10643 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10644 CFLAGS="$CFLAGS $GTK_CFLAGS"
10645 LIBS="$GTK_LIBS $LIBS"
10646 GTK_COMPILES=no
10647 for ac_func in gtk_main
10648 do :
10649 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10650 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10651 cat >>confdefs.h <<_ACEOF
10652 #define HAVE_GTK_MAIN 1
10653 _ACEOF
10654 GTK_COMPILES=yes
10655 fi
10656 done
10657
10658 if test "${GTK_COMPILES}" != "yes"; then
10659 if test "$USE_X_TOOLKIT" != "maybe"; then
10660 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10661 fi
10662 else
10663 HAVE_GTK=yes
10664
10665 $as_echo "#define USE_GTK 1" >>confdefs.h
10666
10667 GTK_OBJ="gtkutil.o $GTK_OBJ"
10668 USE_X_TOOLKIT=none
10669 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10670 :
10671 else
10672 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10673 closing open displays. This is no problem if you just use
10674 one display, but if you use more than one and close one of them
10675 Emacs may crash." >&5
10676 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10677 closing open displays. This is no problem if you just use
10678 one display, but if you use more than one and close one of them
10679 Emacs may crash." >&2;}
10680 sleep 3
10681 fi
10682 fi
10683
10684 fi
10685
10686
10687
10688 if test "${HAVE_GTK}" = "yes"; then
10689
10690 if test "$with_toolkit_scroll_bars" != no; then
10691 with_toolkit_scroll_bars=yes
10692 fi
10693
10694 HAVE_GTK_FILE_SELECTION=no
10695 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10696 #include <gtk/gtk.h>
10697 "
10698 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10699 HAVE_GTK_FILE_SELECTION=yes
10700 else
10701 HAVE_GTK_FILE_SELECTION=no
10702 fi
10703
10704 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10705 for ac_func in gtk_file_selection_new
10706 do :
10707 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10708 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10709 cat >>confdefs.h <<_ACEOF
10710 #define HAVE_GTK_FILE_SELECTION_NEW 1
10711 _ACEOF
10712
10713 fi
10714 done
10715
10716 fi
10717
10718
10719 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10720 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10721 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10722 gtk_orientable_set_orientation \
10723 gtk_window_set_has_resize_grip
10724 do :
10725 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10726 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10727 eval as_val=\$$as_ac_var
10728 if test "x$as_val" = x""yes; then :
10729 cat >>confdefs.h <<_ACEOF
10730 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10731 _ACEOF
10732
10733 fi
10734 done
10735
10736
10737 term_header=gtkutil.h
10738 fi
10739
10740 HAVE_DBUS=no
10741 DBUS_OBJ=
10742 if test "${with_dbus}" = "yes"; then
10743
10744 succeeded=no
10745
10746 if test "$PKG_CONFIG" = "no" ; then
10747 HAVE_DBUS=no
10748 else
10749 PKG_CONFIG_MIN_VERSION=0.9.0
10750 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10752 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
10753
10754 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
10755 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
10756 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
10757 edit_cflags="
10758 s,///*,/,g
10759 s/^/ /
10760 s/ -I/ $isystem/g
10761 s/^ //
10762 "
10763 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e "$edit_cflags"`
10764 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
10765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
10766 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
10767 succeeded=yes
10768 else
10769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10770 $as_echo "no" >&6; }
10771 DBUS_CFLAGS=""
10772 DBUS_LIBS=""
10773 ## If we have a custom action on failure, don't print errors, but
10774 ## do set a variable so people can do so. Do it in a subshell
10775 ## to capture any diagnostics in invoking pkg-config.
10776 DBUS_PKG_ERRORS=`($PKG_CONFIG --print-errors "dbus-1 >= 1.0") 2>&1`
10777
10778 fi
10779
10780
10781
10782 else
10783 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10784 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10785 fi
10786 fi
10787
10788 if test $succeeded = yes; then
10789 HAVE_DBUS=yes
10790 else
10791 HAVE_DBUS=no
10792 fi
10793
10794 if test "$HAVE_DBUS" = yes; then
10795 LIBS="$LIBS $DBUS_LIBS"
10796
10797 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
10798
10799 for ac_func in dbus_watch_get_unix_fd \
10800 dbus_type_is_valid \
10801 dbus_validate_bus_name \
10802 dbus_validate_path \
10803 dbus_validate_interface \
10804 dbus_validate_member
10805 do :
10806 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10807 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10808 eval as_val=\$$as_ac_var
10809 if test "x$as_val" = x""yes; then :
10810 cat >>confdefs.h <<_ACEOF
10811 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10812 _ACEOF
10813
10814 fi
10815 done
10816
10817 DBUS_OBJ=dbusbind.o
10818 fi
10819 fi
10820
10821
10822 HAVE_GSETTINGS=no
10823 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
10824
10825 succeeded=no
10826
10827 if test "$PKG_CONFIG" = "no" ; then
10828 HAVE_GSETTINGS=no
10829 else
10830 PKG_CONFIG_MIN_VERSION=0.9.0
10831 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
10833 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
10834
10835 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
10836 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
10837 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
10838 edit_cflags="
10839 s,///*,/,g
10840 s/^/ /
10841 s/ -I/ $isystem/g
10842 s/^ //
10843 "
10844 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e "$edit_cflags"`
10845 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
10846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
10847 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
10848 succeeded=yes
10849 else
10850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10851 $as_echo "no" >&6; }
10852 GSETTINGS_CFLAGS=""
10853 GSETTINGS_LIBS=""
10854 ## If we have a custom action on failure, don't print errors, but
10855 ## do set a variable so people can do so. Do it in a subshell
10856 ## to capture any diagnostics in invoking pkg-config.
10857 GSETTINGS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gio-2.0 >= 2.26") 2>&1`
10858
10859 fi
10860
10861
10862
10863 else
10864 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10865 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10866 fi
10867 fi
10868
10869 if test $succeeded = yes; then
10870 HAVE_GSETTINGS=yes
10871 else
10872 HAVE_GSETTINGS=no
10873 fi
10874
10875 if test "$HAVE_GSETTINGS" = "yes"; then
10876
10877 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
10878
10879 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
10880 SETTINGS_LIBS="$GSETTINGS_LIBS"
10881 fi
10882 fi
10883
10884 HAVE_GCONF=no
10885 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
10886
10887 succeeded=no
10888
10889 if test "$PKG_CONFIG" = "no" ; then
10890 HAVE_GCONF=no
10891 else
10892 PKG_CONFIG_MIN_VERSION=0.9.0
10893 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
10895 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
10896
10897 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
10898 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
10899 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
10900 edit_cflags="
10901 s,///*,/,g
10902 s/^/ /
10903 s/ -I/ $isystem/g
10904 s/^ //
10905 "
10906 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e "$edit_cflags"`
10907 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
10908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
10909 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
10910 succeeded=yes
10911 else
10912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10913 $as_echo "no" >&6; }
10914 GCONF_CFLAGS=""
10915 GCONF_LIBS=""
10916 ## If we have a custom action on failure, don't print errors, but
10917 ## do set a variable so people can do so. Do it in a subshell
10918 ## to capture any diagnostics in invoking pkg-config.
10919 GCONF_PKG_ERRORS=`($PKG_CONFIG --print-errors "gconf-2.0 >= 2.13") 2>&1`
10920
10921 fi
10922
10923
10924
10925 else
10926 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10927 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10928 fi
10929 fi
10930
10931 if test $succeeded = yes; then
10932 HAVE_GCONF=yes
10933 else
10934 HAVE_GCONF=no
10935 fi
10936
10937 if test "$HAVE_GCONF" = yes; then
10938
10939 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
10940
10941 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
10942 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
10943 fi
10944 fi
10945
10946 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
10947
10948 succeeded=no
10949
10950 if test "$PKG_CONFIG" = "no" ; then
10951 HAVE_GOBJECT=no
10952 else
10953 PKG_CONFIG_MIN_VERSION=0.9.0
10954 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gobject-2.0 >= 2.0" >&5
10956 $as_echo_n "checking for gobject-2.0 >= 2.0... " >&6; }
10957
10958 if $PKG_CONFIG --exists "gobject-2.0 >= 2.0" 2>&5 &&
10959 GOBJECT_CFLAGS=`$PKG_CONFIG --cflags "gobject-2.0 >= 2.0" 2>&5` &&
10960 GOBJECT_LIBS=`$PKG_CONFIG --libs "gobject-2.0 >= 2.0" 2>&5`; then
10961 edit_cflags="
10962 s,///*,/,g
10963 s/^/ /
10964 s/ -I/ $isystem/g
10965 s/^ //
10966 "
10967 GOBJECT_CFLAGS=`$as_echo "$GOBJECT_CFLAGS" | sed -e "$edit_cflags"`
10968 GOBJECT_LIBS=`$as_echo "$GOBJECT_LIBS" | sed -e 's,///*,/,g'`
10969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&5
10970 $as_echo "yes CFLAGS='$GOBJECT_CFLAGS' LIBS='$GOBJECT_LIBS'" >&6; }
10971 succeeded=yes
10972 else
10973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10974 $as_echo "no" >&6; }
10975 GOBJECT_CFLAGS=""
10976 GOBJECT_LIBS=""
10977 ## If we have a custom action on failure, don't print errors, but
10978 ## do set a variable so people can do so. Do it in a subshell
10979 ## to capture any diagnostics in invoking pkg-config.
10980 GOBJECT_PKG_ERRORS=`($PKG_CONFIG --print-errors "gobject-2.0 >= 2.0") 2>&1`
10981
10982 fi
10983
10984
10985
10986 else
10987 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10988 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10989 fi
10990 fi
10991
10992 if test $succeeded = yes; then
10993 HAVE_GOBJECT=yes
10994 else
10995 HAVE_GOBJECT=no
10996 fi
10997
10998 if test "$HAVE_GOBJECT" = "yes"; then
10999 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GOBJECT_CFLAGS"
11000 SETTINGS_LIBS="$SETTINGS_LIBS $GOBJECT_LIBS"
11001 fi
11002 SAVE_CFLAGS="$CFLAGS"
11003 SAVE_LIBS="$LIBS"
11004 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11005 LIBS="$SETTINGS_LIBS $LIBS"
11006 for ac_func in g_type_init
11007 do :
11008 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11009 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11010 cat >>confdefs.h <<_ACEOF
11011 #define HAVE_G_TYPE_INIT 1
11012 _ACEOF
11013
11014 fi
11015 done
11016
11017 CFLAGS="$SAVE_CFLAGS"
11018 LIBS="$SAVE_LIBS"
11019 fi
11020
11021
11022
11023
11024 HAVE_LIBSELINUX=no
11025 LIBSELINUX_LIBS=
11026 if test "${with_selinux}" = "yes"; then
11027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11028 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11029 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11030 $as_echo_n "(cached) " >&6
11031 else
11032 ac_check_lib_save_LIBS=$LIBS
11033 LIBS="-lselinux $LIBS"
11034 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11035 /* end confdefs.h. */
11036
11037 /* Override any GCC internal prototype to avoid an error.
11038 Use char because int might match the return type of a GCC
11039 builtin and then its argument prototype would still apply. */
11040 #ifdef __cplusplus
11041 extern "C"
11042 #endif
11043 char lgetfilecon ();
11044 int
11045 main ()
11046 {
11047 return lgetfilecon ();
11048 ;
11049 return 0;
11050 }
11051 _ACEOF
11052 if ac_fn_c_try_link "$LINENO"; then :
11053 ac_cv_lib_selinux_lgetfilecon=yes
11054 else
11055 ac_cv_lib_selinux_lgetfilecon=no
11056 fi
11057 rm -f core conftest.err conftest.$ac_objext \
11058 conftest$ac_exeext conftest.$ac_ext
11059 LIBS=$ac_check_lib_save_LIBS
11060 fi
11061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11062 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11063 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11064 HAVE_LIBSELINUX=yes
11065 else
11066 HAVE_LIBSELINUX=no
11067 fi
11068
11069 if test "$HAVE_LIBSELINUX" = yes; then
11070
11071 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11072
11073 LIBSELINUX_LIBS=-lselinux
11074 fi
11075 fi
11076
11077
11078 HAVE_GNUTLS=no
11079 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11080 if test "${with_gnutls}" = "yes" ; then
11081
11082 succeeded=no
11083
11084 if test "$PKG_CONFIG" = "no" ; then
11085 HAVE_GNUTLS=no
11086 else
11087 PKG_CONFIG_MIN_VERSION=0.9.0
11088 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11090 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11091
11092 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11093 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11094 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11095 edit_cflags="
11096 s,///*,/,g
11097 s/^/ /
11098 s/ -I/ $isystem/g
11099 s/^ //
11100 "
11101 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e "$edit_cflags"`
11102 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11104 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11105 succeeded=yes
11106 else
11107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11108 $as_echo "no" >&6; }
11109 LIBGNUTLS_CFLAGS=""
11110 LIBGNUTLS_LIBS=""
11111 ## If we have a custom action on failure, don't print errors, but
11112 ## do set a variable so people can do so. Do it in a subshell
11113 ## to capture any diagnostics in invoking pkg-config.
11114 LIBGNUTLS_PKG_ERRORS=`($PKG_CONFIG --print-errors "gnutls >= 2.6.6") 2>&1`
11115
11116 fi
11117
11118
11119
11120 else
11121 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11122 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11123 fi
11124 fi
11125
11126 if test $succeeded = yes; then
11127 HAVE_GNUTLS=yes
11128 else
11129 HAVE_GNUTLS=no
11130 fi
11131
11132 if test "${HAVE_GNUTLS}" = "yes"; then
11133
11134 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11135
11136 fi
11137
11138 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11139 LIBS="$LIBGNUTLS_LIBS $LIBS"
11140 for ac_func in gnutls_certificate_set_verify_function
11141 do :
11142 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11143 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11144 cat >>confdefs.h <<_ACEOF
11145 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11146 _ACEOF
11147 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11148 fi
11149 done
11150
11151
11152 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11153
11154 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11155
11156 fi
11157 fi
11158
11159
11160
11161
11162 HAVE_XAW3D=no
11163 LUCID_LIBW=
11164 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11165 if test "$with_xaw3d" != no; then
11166 if test "${emacs_cv_xaw3d+set}" = set; then :
11167 $as_echo_n "(cached) " >&6
11168 else
11169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11170 /* end confdefs.h. */
11171
11172 #include <X11/Intrinsic.h>
11173 #include <X11/Xaw3d/Simple.h>
11174 int
11175 main ()
11176 {
11177
11178 ;
11179 return 0;
11180 }
11181 _ACEOF
11182 if ac_fn_c_try_link "$LINENO"; then :
11183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11184 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11185 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11186 $as_echo_n "(cached) " >&6
11187 else
11188 ac_check_lib_save_LIBS=$LIBS
11189 LIBS="-lXaw3d $LIBS"
11190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11191 /* end confdefs.h. */
11192
11193 /* Override any GCC internal prototype to avoid an error.
11194 Use char because int might match the return type of a GCC
11195 builtin and then its argument prototype would still apply. */
11196 #ifdef __cplusplus
11197 extern "C"
11198 #endif
11199 char XawScrollbarSetThumb ();
11200 int
11201 main ()
11202 {
11203 return XawScrollbarSetThumb ();
11204 ;
11205 return 0;
11206 }
11207 _ACEOF
11208 if ac_fn_c_try_link "$LINENO"; then :
11209 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11210 else
11211 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11212 fi
11213 rm -f core conftest.err conftest.$ac_objext \
11214 conftest$ac_exeext conftest.$ac_ext
11215 LIBS=$ac_check_lib_save_LIBS
11216 fi
11217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11218 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11219 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11220 emacs_cv_xaw3d=yes
11221 else
11222 emacs_cv_xaw3d=no
11223 fi
11224
11225 else
11226 emacs_cv_xaw3d=no
11227 fi
11228 rm -f core conftest.err conftest.$ac_objext \
11229 conftest$ac_exeext conftest.$ac_ext
11230 fi
11231
11232 else
11233 emacs_cv_xaw3d=no
11234 fi
11235 if test $emacs_cv_xaw3d = yes; then
11236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11237 $as_echo_n "checking for xaw3d... " >&6; }
11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11239 $as_echo "yes; using Lucid toolkit" >&6; }
11240 USE_X_TOOLKIT=LUCID
11241 HAVE_XAW3D=yes
11242 LUCID_LIBW=-lXaw3d
11243
11244 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11245
11246 else
11247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11248 $as_echo_n "checking for xaw3d... " >&6; }
11249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11250 $as_echo "no" >&6; }
11251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11252 $as_echo_n "checking for libXaw... " >&6; }
11253 if test "${emacs_cv_xaw+set}" = set; then :
11254 $as_echo_n "(cached) " >&6
11255 else
11256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11257 /* end confdefs.h. */
11258
11259 #include <X11/Intrinsic.h>
11260 #include <X11/Xaw/Simple.h>
11261 int
11262 main ()
11263 {
11264
11265 ;
11266 return 0;
11267 }
11268 _ACEOF
11269 if ac_fn_c_try_link "$LINENO"; then :
11270 emacs_cv_xaw=yes
11271 else
11272 emacs_cv_xaw=no
11273 fi
11274 rm -f core conftest.err conftest.$ac_objext \
11275 conftest$ac_exeext conftest.$ac_ext
11276 fi
11277
11278 if test $emacs_cv_xaw = yes; then
11279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11280 $as_echo "yes; using Lucid toolkit" >&6; }
11281 USE_X_TOOLKIT=LUCID
11282 LUCID_LIBW=-lXaw
11283 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11284 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11285 else
11286 as_fn_error "No X toolkit could be found.
11287 If you are sure you want Emacs compiled without an X toolkit, pass
11288 --with-x-toolkit=no
11289 to configure. Otherwise, install the development libraries for the toolkit
11290 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11291 fi
11292 fi
11293 fi
11294
11295 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11296
11297 LIBXTR6=
11298 if test "${USE_X_TOOLKIT}" != "none"; then
11299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11300 $as_echo_n "checking X11 toolkit version... " >&6; }
11301 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11302 $as_echo_n "(cached) " >&6
11303 else
11304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11305 /* end confdefs.h. */
11306 #include <X11/Intrinsic.h>
11307 int
11308 main ()
11309 {
11310 #if XtSpecificationRelease < 6
11311 fail;
11312 #endif
11313
11314 ;
11315 return 0;
11316 }
11317 _ACEOF
11318 if ac_fn_c_try_link "$LINENO"; then :
11319 emacs_cv_x11_toolkit_version_6=yes
11320 else
11321 emacs_cv_x11_toolkit_version_6=no
11322 fi
11323 rm -f core conftest.err conftest.$ac_objext \
11324 conftest$ac_exeext conftest.$ac_ext
11325 fi
11326
11327 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11328 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11329 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11330 $as_echo "6 or newer" >&6; }
11331
11332 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11333
11334 LIBXTR6="-lSM -lICE"
11335 case "$opsys" in
11336 ## Use libw.a along with X11R6 Xt.
11337 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11338 esac
11339 else
11340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11341 $as_echo "before 6" >&6; }
11342 fi
11343
11344 OLDLIBS="$LIBS"
11345 if test x$HAVE_X11XTR6 = xyes; then
11346 LIBS="-lXt -lSM -lICE $LIBS"
11347 else
11348 LIBS="-lXt $LIBS"
11349 fi
11350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11351 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11352 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11353 $as_echo_n "(cached) " >&6
11354 else
11355 ac_check_lib_save_LIBS=$LIBS
11356 LIBS="-lXmu $LIBS"
11357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11358 /* end confdefs.h. */
11359
11360 /* Override any GCC internal prototype to avoid an error.
11361 Use char because int might match the return type of a GCC
11362 builtin and then its argument prototype would still apply. */
11363 #ifdef __cplusplus
11364 extern "C"
11365 #endif
11366 char XmuConvertStandardSelection ();
11367 int
11368 main ()
11369 {
11370 return XmuConvertStandardSelection ();
11371 ;
11372 return 0;
11373 }
11374 _ACEOF
11375 if ac_fn_c_try_link "$LINENO"; then :
11376 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11377 else
11378 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11379 fi
11380 rm -f core conftest.err conftest.$ac_objext \
11381 conftest$ac_exeext conftest.$ac_ext
11382 LIBS=$ac_check_lib_save_LIBS
11383 fi
11384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11385 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11386 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11387 cat >>confdefs.h <<_ACEOF
11388 #define HAVE_LIBXMU 1
11389 _ACEOF
11390
11391 LIBS="-lXmu $LIBS"
11392
11393 fi
11394
11395 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11396 fi
11397
11398
11399 LIBXMU=-lXmu
11400 case $opsys in
11401 ## These systems don't supply Xmu.
11402 hpux* | aix4-2 )
11403 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11404 ;;
11405 esac
11406
11407
11408 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11409 if test "${HAVE_X11}" = "yes"; then
11410 if test "${USE_X_TOOLKIT}" != "none"; then
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11412 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11413 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11414 $as_echo_n "(cached) " >&6
11415 else
11416 ac_check_lib_save_LIBS=$LIBS
11417 LIBS="-lXext $LIBS"
11418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11419 /* end confdefs.h. */
11420
11421 /* Override any GCC internal prototype to avoid an error.
11422 Use char because int might match the return type of a GCC
11423 builtin and then its argument prototype would still apply. */
11424 #ifdef __cplusplus
11425 extern "C"
11426 #endif
11427 char XShapeQueryExtension ();
11428 int
11429 main ()
11430 {
11431 return XShapeQueryExtension ();
11432 ;
11433 return 0;
11434 }
11435 _ACEOF
11436 if ac_fn_c_try_link "$LINENO"; then :
11437 ac_cv_lib_Xext_XShapeQueryExtension=yes
11438 else
11439 ac_cv_lib_Xext_XShapeQueryExtension=no
11440 fi
11441 rm -f core conftest.err conftest.$ac_objext \
11442 conftest$ac_exeext conftest.$ac_ext
11443 LIBS=$ac_check_lib_save_LIBS
11444 fi
11445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11446 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11447 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11448 cat >>confdefs.h <<_ACEOF
11449 #define HAVE_LIBXEXT 1
11450 _ACEOF
11451
11452 LIBS="-lXext $LIBS"
11453
11454 fi
11455
11456 fi
11457 fi
11458
11459 LIBXP=
11460 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11461 # OpenMotif may be installed in such a way on some GNU/Linux systems.
11462 if test -d /usr/include/openmotif; then
11463 CPPFLAGS="-I/usr/include/openmotif $CPPFLAGS"
11464 emacs_cv_openmotif=yes
11465 case "$canonical" in
11466 x86_64-*-linux-gnu* | powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*)
11467 test -d /usr/lib64/openmotif && LDFLAGS="-L/usr/lib64/openmotif $LDFLAGS"
11468 ;;
11469 *)
11470 test -d /usr/lib/openmotif && LDFLAGS="-L/usr/lib/openmotif $LDFLAGS"
11471 esac
11472 else
11473 emacs_cv_openmotif=no
11474 fi
11475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (Open)Motif version 2.1" >&5
11476 $as_echo_n "checking for (Open)Motif version 2.1... " >&6; }
11477 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11478 $as_echo_n "(cached) " >&6
11479 else
11480 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11481 /* end confdefs.h. */
11482 #include <Xm/Xm.h>
11483 int
11484 main ()
11485 {
11486 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11487 int x = 5;
11488 #else
11489 Motif version prior to 2.1.
11490 #endif
11491 ;
11492 return 0;
11493 }
11494 _ACEOF
11495 if ac_fn_c_try_compile "$LINENO"; then :
11496 emacs_cv_motif_version_2_1=yes
11497 else
11498 emacs_cv_motif_version_2_1=no
11499 fi
11500 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11501 fi
11502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11503 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11504 if test $emacs_cv_motif_version_2_1 = yes; then
11505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11506 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11507 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11508 $as_echo_n "(cached) " >&6
11509 else
11510 ac_check_lib_save_LIBS=$LIBS
11511 LIBS="-lXp $LIBS"
11512 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11513 /* end confdefs.h. */
11514
11515 /* Override any GCC internal prototype to avoid an error.
11516 Use char because int might match the return type of a GCC
11517 builtin and then its argument prototype would still apply. */
11518 #ifdef __cplusplus
11519 extern "C"
11520 #endif
11521 char XpCreateContext ();
11522 int
11523 main ()
11524 {
11525 return XpCreateContext ();
11526 ;
11527 return 0;
11528 }
11529 _ACEOF
11530 if ac_fn_c_try_link "$LINENO"; then :
11531 ac_cv_lib_Xp_XpCreateContext=yes
11532 else
11533 ac_cv_lib_Xp_XpCreateContext=no
11534 fi
11535 rm -f core conftest.err conftest.$ac_objext \
11536 conftest$ac_exeext conftest.$ac_ext
11537 LIBS=$ac_check_lib_save_LIBS
11538 fi
11539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11540 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11541 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11542 LIBXP=-lXp
11543 fi
11544
11545 if test x$emacs_cv_openmotif = xyes; then
11546 REAL_CPPFLAGS="-I/usr/include/openmotif $REAL_CPPFLAGS"
11547 fi
11548 else
11549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11550 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11551 if test "${emacs_cv_lesstif+set}" = set; then :
11552 $as_echo_n "(cached) " >&6
11553 else
11554 # We put this in CFLAGS temporarily to precede other -I options
11555 # that might be in CFLAGS temporarily.
11556 # We put this in CPPFLAGS where it precedes the other -I options.
11557 OLD_CPPFLAGS=$CPPFLAGS
11558 OLD_CFLAGS=$CFLAGS
11559 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11560 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11561 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11562 /* end confdefs.h. */
11563 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11564 int
11565 main ()
11566 {
11567 int x = 5;
11568 ;
11569 return 0;
11570 }
11571 _ACEOF
11572 if ac_fn_c_try_compile "$LINENO"; then :
11573 emacs_cv_lesstif=yes
11574 else
11575 emacs_cv_lesstif=no
11576 fi
11577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11578 fi
11579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11580 $as_echo "$emacs_cv_lesstif" >&6; }
11581 if test $emacs_cv_lesstif = yes; then
11582 # Make sure this -I option remains in CPPFLAGS after it is set
11583 # back to REAL_CPPFLAGS.
11584 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11585 # have those other -I options anyway. Ultimately, having this
11586 # directory ultimately in CPPFLAGS will be enough.
11587 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11588 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11589 else
11590 CFLAGS=$OLD_CFLAGS
11591 CPPFLAGS=$OLD_CPPFLAGS
11592 fi
11593 fi
11594 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
11595 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
11596
11597 else
11598 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
11599 fi
11600
11601
11602 fi
11603
11604
11605 USE_TOOLKIT_SCROLL_BARS=no
11606 if test "${with_toolkit_scroll_bars}" != "no"; then
11607 if test "${USE_X_TOOLKIT}" != "none"; then
11608 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11609 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11610
11611 HAVE_XAW3D=no
11612 USE_TOOLKIT_SCROLL_BARS=yes
11613 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
11614 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11615
11616 USE_TOOLKIT_SCROLL_BARS=yes
11617 fi
11618 elif test "${HAVE_GTK}" = "yes"; then
11619 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11620
11621 USE_TOOLKIT_SCROLL_BARS=yes
11622 elif test "${HAVE_NS}" = "yes"; then
11623 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11624
11625 USE_TOOLKIT_SCROLL_BARS=yes
11626 fi
11627 fi
11628
11629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11630 /* end confdefs.h. */
11631
11632 #include <X11/Xlib.h>
11633 #include <X11/Xresource.h>
11634 int
11635 main ()
11636 {
11637 XIMProc callback;
11638 ;
11639 return 0;
11640 }
11641 _ACEOF
11642 if ac_fn_c_try_compile "$LINENO"; then :
11643 HAVE_XIM=yes
11644
11645 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11646
11647 else
11648 HAVE_XIM=no
11649 fi
11650 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11651
11652
11653 if test "${with_xim}" != "no"; then
11654
11655 $as_echo "#define USE_XIM 1" >>confdefs.h
11656
11657 fi
11658
11659
11660 if test "${HAVE_XIM}" != "no"; then
11661 late_CFLAGS=$CFLAGS
11662 if test "$GCC" = yes; then
11663 CFLAGS="$CFLAGS --pedantic-errors"
11664 fi
11665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11666 /* end confdefs.h. */
11667
11668 #include <X11/Xlib.h>
11669 #include <X11/Xresource.h>
11670 int
11671 main ()
11672 {
11673 Display *display;
11674 XrmDatabase db;
11675 char *res_name;
11676 char *res_class;
11677 XIMProc callback;
11678 XPointer *client_data;
11679 #ifndef __GNUC__
11680 /* If we're not using GCC, it's probably not XFree86, and this is
11681 probably right, but we can't use something like --pedantic-errors. */
11682 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11683 char*, XIMProc, XPointer*);
11684 #endif
11685 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11686 client_data);
11687 ;
11688 return 0;
11689 }
11690 _ACEOF
11691 if ac_fn_c_try_compile "$LINENO"; then :
11692 emacs_cv_arg6_star=yes
11693 fi
11694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11695 if test "$emacs_cv_arg6_star" = yes; then
11696 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11697
11698 else
11699 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11700
11701 fi
11702 CFLAGS=$late_CFLAGS
11703 fi
11704
11705 ### Start of font-backend (under any platform) section.
11706 # (nothing here yet -- this is a placeholder)
11707 ### End of font-backend (under any platform) section.
11708
11709 ### Start of font-backend (under X11) section.
11710 if test "${HAVE_X11}" = "yes"; then
11711
11712 succeeded=no
11713
11714 if test "$PKG_CONFIG" = "no" ; then
11715 HAVE_FC=no
11716 else
11717 PKG_CONFIG_MIN_VERSION=0.9.0
11718 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
11720 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
11721
11722 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
11723 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
11724 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
11725 edit_cflags="
11726 s,///*,/,g
11727 s/^/ /
11728 s/ -I/ $isystem/g
11729 s/^ //
11730 "
11731 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e "$edit_cflags"`
11732 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
11733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
11734 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
11735 succeeded=yes
11736 else
11737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11738 $as_echo "no" >&6; }
11739 FONTCONFIG_CFLAGS=""
11740 FONTCONFIG_LIBS=""
11741 ## If we have a custom action on failure, don't print errors, but
11742 ## do set a variable so people can do so. Do it in a subshell
11743 ## to capture any diagnostics in invoking pkg-config.
11744 FONTCONFIG_PKG_ERRORS=`($PKG_CONFIG --print-errors "fontconfig >= 2.2.0") 2>&1`
11745
11746 fi
11747
11748
11749
11750 else
11751 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11752 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11753 fi
11754 fi
11755
11756 if test $succeeded = yes; then
11757 HAVE_FC=yes
11758 else
11759 HAVE_FC=no
11760 fi
11761
11762
11763 ## Use -lXft if available, unless `--with-xft=no'.
11764 HAVE_XFT=maybe
11765 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
11766 with_xft="no";
11767 fi
11768 if test "x${with_xft}" != "xno"; then
11769
11770
11771 succeeded=no
11772
11773 if test "$PKG_CONFIG" = "no" ; then
11774 HAVE_XFT=no
11775 else
11776 PKG_CONFIG_MIN_VERSION=0.9.0
11777 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
11779 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
11780
11781 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
11782 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
11783 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
11784 edit_cflags="
11785 s,///*,/,g
11786 s/^/ /
11787 s/ -I/ $isystem/g
11788 s/^ //
11789 "
11790 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e "$edit_cflags"`
11791 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
11792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
11793 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
11794 succeeded=yes
11795 else
11796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11797 $as_echo "no" >&6; }
11798 XFT_CFLAGS=""
11799 XFT_LIBS=""
11800 ## If we have a custom action on failure, don't print errors, but
11801 ## do set a variable so people can do so. Do it in a subshell
11802 ## to capture any diagnostics in invoking pkg-config.
11803 XFT_PKG_ERRORS=`($PKG_CONFIG --print-errors "xft >= 0.13.0") 2>&1`
11804
11805 fi
11806
11807
11808
11809 else
11810 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11811 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11812 fi
11813 fi
11814
11815 if test $succeeded = yes; then
11816 :
11817 else
11818 HAVE_XFT=no
11819 fi
11820
11821 ## Because xftfont.c uses XRenderQueryExtension, we also
11822 ## need to link to -lXrender.
11823 HAVE_XRENDER=no
11824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
11825 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
11826 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
11827 $as_echo_n "(cached) " >&6
11828 else
11829 ac_check_lib_save_LIBS=$LIBS
11830 LIBS="-lXrender $LIBS"
11831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11832 /* end confdefs.h. */
11833
11834 /* Override any GCC internal prototype to avoid an error.
11835 Use char because int might match the return type of a GCC
11836 builtin and then its argument prototype would still apply. */
11837 #ifdef __cplusplus
11838 extern "C"
11839 #endif
11840 char XRenderQueryExtension ();
11841 int
11842 main ()
11843 {
11844 return XRenderQueryExtension ();
11845 ;
11846 return 0;
11847 }
11848 _ACEOF
11849 if ac_fn_c_try_link "$LINENO"; then :
11850 ac_cv_lib_Xrender_XRenderQueryExtension=yes
11851 else
11852 ac_cv_lib_Xrender_XRenderQueryExtension=no
11853 fi
11854 rm -f core conftest.err conftest.$ac_objext \
11855 conftest$ac_exeext conftest.$ac_ext
11856 LIBS=$ac_check_lib_save_LIBS
11857 fi
11858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
11859 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
11860 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
11861 HAVE_XRENDER=yes
11862 fi
11863
11864 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
11865 OLD_CPPFLAGS="$CPPFLAGS"
11866 OLD_CFLAGS="$CFLAGS"
11867 OLD_LIBS="$LIBS"
11868 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
11869 CFLAGS="$CFLAGS $XFT_CFLAGS"
11870 XFT_LIBS="-lXrender $XFT_LIBS"
11871 LIBS="$XFT_LIBS $LIBS"
11872 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
11873 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
11874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
11875 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
11876 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
11877 $as_echo_n "(cached) " >&6
11878 else
11879 ac_check_lib_save_LIBS=$LIBS
11880 LIBS="-lXft $XFT_LIBS $LIBS"
11881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11882 /* end confdefs.h. */
11883
11884 /* Override any GCC internal prototype to avoid an error.
11885 Use char because int might match the return type of a GCC
11886 builtin and then its argument prototype would still apply. */
11887 #ifdef __cplusplus
11888 extern "C"
11889 #endif
11890 char XftFontOpen ();
11891 int
11892 main ()
11893 {
11894 return XftFontOpen ();
11895 ;
11896 return 0;
11897 }
11898 _ACEOF
11899 if ac_fn_c_try_link "$LINENO"; then :
11900 ac_cv_lib_Xft_XftFontOpen=yes
11901 else
11902 ac_cv_lib_Xft_XftFontOpen=no
11903 fi
11904 rm -f core conftest.err conftest.$ac_objext \
11905 conftest$ac_exeext conftest.$ac_ext
11906 LIBS=$ac_check_lib_save_LIBS
11907 fi
11908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
11909 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
11910 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
11911 HAVE_XFT=yes
11912 fi
11913
11914 fi
11915
11916
11917
11918 if test "${HAVE_XFT}" = "yes"; then
11919
11920 $as_echo "#define HAVE_XFT 1" >>confdefs.h
11921
11922
11923 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
11924 else
11925 CPPFLAGS="$OLD_CPPFLAGS"
11926 CFLAGS="$OLD_CFLAGS"
11927 LIBS="$OLD_LIBS"
11928 fi # "${HAVE_XFT}" = "yes"
11929 fi # "$HAVE_XFT" != no
11930 fi # "x${with_xft}" != "xno"
11931
11932 ## We used to allow building with FreeType and without Xft.
11933 ## However, the ftx font backend driver is not in good shape.
11934 if test "$HAVE_XFT" != "yes"; then
11935 HAVE_XFT=no
11936 HAVE_FREETYPE=no
11937 else
11938
11939 succeeded=no
11940
11941 if test "$PKG_CONFIG" = "no" ; then
11942 HAVE_FREETYPE=no
11943 else
11944 PKG_CONFIG_MIN_VERSION=0.9.0
11945 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
11947 $as_echo_n "checking for freetype2... " >&6; }
11948
11949 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
11950 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
11951 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
11952 edit_cflags="
11953 s,///*,/,g
11954 s/^/ /
11955 s/ -I/ $isystem/g
11956 s/^ //
11957 "
11958 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e "$edit_cflags"`
11959 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
11960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
11961 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
11962 succeeded=yes
11963 else
11964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11965 $as_echo "no" >&6; }
11966 FREETYPE_CFLAGS=""
11967 FREETYPE_LIBS=""
11968 ## If we have a custom action on failure, don't print errors, but
11969 ## do set a variable so people can do so. Do it in a subshell
11970 ## to capture any diagnostics in invoking pkg-config.
11971 FREETYPE_PKG_ERRORS=`($PKG_CONFIG --print-errors "freetype2") 2>&1`
11972
11973 fi
11974
11975
11976
11977 else
11978 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11979 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11980 fi
11981 fi
11982
11983 if test $succeeded = yes; then
11984 HAVE_FREETYPE=yes
11985 else
11986 HAVE_FREETYPE=no
11987 fi
11988
11989
11990 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
11991 fi
11992
11993 HAVE_LIBOTF=no
11994 if test "${HAVE_FREETYPE}" = "yes"; then
11995
11996 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
11997
11998 if test "${with_libotf}" != "no"; then
11999
12000 succeeded=no
12001
12002 if test "$PKG_CONFIG" = "no" ; then
12003 HAVE_LIBOTF=no
12004 else
12005 PKG_CONFIG_MIN_VERSION=0.9.0
12006 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12008 $as_echo_n "checking for libotf... " >&6; }
12009
12010 if $PKG_CONFIG --exists "libotf" 2>&5 &&
12011 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
12012 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
12013 edit_cflags="
12014 s,///*,/,g
12015 s/^/ /
12016 s/ -I/ $isystem/g
12017 s/^ //
12018 "
12019 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e "$edit_cflags"`
12020 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12022 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12023 succeeded=yes
12024 else
12025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12026 $as_echo "no" >&6; }
12027 LIBOTF_CFLAGS=""
12028 LIBOTF_LIBS=""
12029 ## If we have a custom action on failure, don't print errors, but
12030 ## do set a variable so people can do so. Do it in a subshell
12031 ## to capture any diagnostics in invoking pkg-config.
12032 LIBOTF_PKG_ERRORS=`($PKG_CONFIG --print-errors "libotf") 2>&1`
12033
12034 fi
12035
12036
12037
12038 else
12039 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12040 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12041 fi
12042 fi
12043
12044 if test $succeeded = yes; then
12045 HAVE_LIBOTF=yes
12046 else
12047 HAVE_LIBOTF=no
12048 fi
12049
12050 if test "$HAVE_LIBOTF" = "yes"; then
12051
12052 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12053
12054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12055 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12056 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12057 $as_echo_n "(cached) " >&6
12058 else
12059 ac_check_lib_save_LIBS=$LIBS
12060 LIBS="-lotf $LIBS"
12061 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12062 /* end confdefs.h. */
12063
12064 /* Override any GCC internal prototype to avoid an error.
12065 Use char because int might match the return type of a GCC
12066 builtin and then its argument prototype would still apply. */
12067 #ifdef __cplusplus
12068 extern "C"
12069 #endif
12070 char OTF_get_variation_glyphs ();
12071 int
12072 main ()
12073 {
12074 return OTF_get_variation_glyphs ();
12075 ;
12076 return 0;
12077 }
12078 _ACEOF
12079 if ac_fn_c_try_link "$LINENO"; then :
12080 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12081 else
12082 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12083 fi
12084 rm -f core conftest.err conftest.$ac_objext \
12085 conftest$ac_exeext conftest.$ac_ext
12086 LIBS=$ac_check_lib_save_LIBS
12087 fi
12088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12089 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12090 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12091 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12092 else
12093 HAVE_OTF_GET_VARIATION_GLYPHS=no
12094 fi
12095
12096 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12097
12098 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12099
12100 fi
12101 fi
12102 fi
12103 fi
12104
12105 HAVE_M17N_FLT=no
12106 if test "${HAVE_LIBOTF}" = yes; then
12107 if test "${with_m17n_flt}" != "no"; then
12108
12109 succeeded=no
12110
12111 if test "$PKG_CONFIG" = "no" ; then
12112 HAVE_M17N_FLT=no
12113 else
12114 PKG_CONFIG_MIN_VERSION=0.9.0
12115 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12117 $as_echo_n "checking for m17n-flt... " >&6; }
12118
12119 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12120 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12121 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12122 edit_cflags="
12123 s,///*,/,g
12124 s/^/ /
12125 s/ -I/ $isystem/g
12126 s/^ //
12127 "
12128 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e "$edit_cflags"`
12129 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12131 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12132 succeeded=yes
12133 else
12134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12135 $as_echo "no" >&6; }
12136 M17N_FLT_CFLAGS=""
12137 M17N_FLT_LIBS=""
12138 ## If we have a custom action on failure, don't print errors, but
12139 ## do set a variable so people can do so. Do it in a subshell
12140 ## to capture any diagnostics in invoking pkg-config.
12141 M17N_FLT_PKG_ERRORS=`($PKG_CONFIG --print-errors "m17n-flt") 2>&1`
12142
12143 fi
12144
12145
12146
12147 else
12148 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12149 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12150 fi
12151 fi
12152
12153 if test $succeeded = yes; then
12154 HAVE_M17N_FLT=yes
12155 else
12156 HAVE_M17N_FLT=no
12157 fi
12158
12159 if test "$HAVE_M17N_FLT" = "yes"; then
12160
12161 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12162
12163 fi
12164 fi
12165 fi
12166 else
12167 HAVE_XFT=no
12168 HAVE_FREETYPE=no
12169 HAVE_LIBOTF=no
12170 HAVE_M17N_FLT=no
12171 fi
12172
12173 ### End of font-backend (under X11) section.
12174
12175
12176
12177
12178
12179
12180
12181
12182
12183
12184 ### Use -lXpm if available, unless `--with-xpm=no'.
12185 HAVE_XPM=no
12186 LIBXPM=
12187 if test "${HAVE_X11}" = "yes"; then
12188 if test "${with_xpm}" != "no"; then
12189 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12190 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12192 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12193 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12194 $as_echo_n "(cached) " >&6
12195 else
12196 ac_check_lib_save_LIBS=$LIBS
12197 LIBS="-lXpm -lX11 $LIBS"
12198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12199 /* end confdefs.h. */
12200
12201 /* Override any GCC internal prototype to avoid an error.
12202 Use char because int might match the return type of a GCC
12203 builtin and then its argument prototype would still apply. */
12204 #ifdef __cplusplus
12205 extern "C"
12206 #endif
12207 char XpmReadFileToPixmap ();
12208 int
12209 main ()
12210 {
12211 return XpmReadFileToPixmap ();
12212 ;
12213 return 0;
12214 }
12215 _ACEOF
12216 if ac_fn_c_try_link "$LINENO"; then :
12217 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12218 else
12219 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12220 fi
12221 rm -f core conftest.err conftest.$ac_objext \
12222 conftest$ac_exeext conftest.$ac_ext
12223 LIBS=$ac_check_lib_save_LIBS
12224 fi
12225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12226 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12227 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12228 HAVE_XPM=yes
12229 fi
12230
12231 fi
12232
12233
12234 if test "${HAVE_XPM}" = "yes"; then
12235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12236 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12238 /* end confdefs.h. */
12239 #include "X11/xpm.h"
12240 #ifndef XpmReturnAllocPixels
12241 no_return_alloc_pixels
12242 #endif
12243
12244 _ACEOF
12245 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12246 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12247 HAVE_XPM=no
12248 else
12249 HAVE_XPM=yes
12250 fi
12251 rm -f conftest*
12252
12253
12254 if test "${HAVE_XPM}" = "yes"; then
12255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12256 $as_echo "yes" >&6; }
12257 else
12258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12259 $as_echo "no" >&6; }
12260 fi
12261 fi
12262 fi
12263
12264 if test "${HAVE_XPM}" = "yes"; then
12265
12266 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12267
12268 LIBXPM=-lXpm
12269 fi
12270 fi
12271
12272
12273 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12274 HAVE_JPEG=no
12275 LIBJPEG=
12276 if test "${HAVE_X11}" = "yes"; then
12277 if test "${with_jpeg}" != "no"; then
12278 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12279 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12281 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12282 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12283 $as_echo_n "(cached) " >&6
12284 else
12285 ac_check_lib_save_LIBS=$LIBS
12286 LIBS="-ljpeg $LIBS"
12287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12288 /* end confdefs.h. */
12289
12290 /* Override any GCC internal prototype to avoid an error.
12291 Use char because int might match the return type of a GCC
12292 builtin and then its argument prototype would still apply. */
12293 #ifdef __cplusplus
12294 extern "C"
12295 #endif
12296 char jpeg_destroy_compress ();
12297 int
12298 main ()
12299 {
12300 return jpeg_destroy_compress ();
12301 ;
12302 return 0;
12303 }
12304 _ACEOF
12305 if ac_fn_c_try_link "$LINENO"; then :
12306 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12307 else
12308 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12309 fi
12310 rm -f core conftest.err conftest.$ac_objext \
12311 conftest$ac_exeext conftest.$ac_ext
12312 LIBS=$ac_check_lib_save_LIBS
12313 fi
12314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12315 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12316 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12317 HAVE_JPEG=yes
12318 fi
12319
12320 fi
12321
12322
12323 fi
12324
12325 if test "${HAVE_JPEG}" = "yes"; then
12326 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12327
12328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12329 /* end confdefs.h. */
12330 #include <jpeglib.h>
12331 version=JPEG_LIB_VERSION
12332
12333 _ACEOF
12334 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12335 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12336 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12337
12338 else
12339 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12340 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12341 HAVE_JPEG=no
12342 fi
12343 rm -f conftest*
12344
12345 fi
12346 if test "${HAVE_JPEG}" = "yes"; then
12347 LIBJPEG=-ljpeg
12348 fi
12349 fi
12350
12351
12352 ### Use -lpng if available, unless `--with-png=no'.
12353 HAVE_PNG=no
12354 LIBPNG=
12355 if test "${HAVE_X11}" = "yes"; then
12356 if test "${with_png}" != "no"; then
12357 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12358 # in /usr/include/libpng.
12359 for ac_header in png.h libpng/png.h
12360 do :
12361 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12362 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12363 eval as_val=\$$as_ac_Header
12364 if test "x$as_val" = x""yes; then :
12365 cat >>confdefs.h <<_ACEOF
12366 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12367 _ACEOF
12368 break
12369 fi
12370
12371 done
12372
12373 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12375 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12376 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12377 $as_echo_n "(cached) " >&6
12378 else
12379 ac_check_lib_save_LIBS=$LIBS
12380 LIBS="-lpng -lz -lm $LIBS"
12381 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12382 /* end confdefs.h. */
12383
12384 /* Override any GCC internal prototype to avoid an error.
12385 Use char because int might match the return type of a GCC
12386 builtin and then its argument prototype would still apply. */
12387 #ifdef __cplusplus
12388 extern "C"
12389 #endif
12390 char png_get_channels ();
12391 int
12392 main ()
12393 {
12394 return png_get_channels ();
12395 ;
12396 return 0;
12397 }
12398 _ACEOF
12399 if ac_fn_c_try_link "$LINENO"; then :
12400 ac_cv_lib_png_png_get_channels=yes
12401 else
12402 ac_cv_lib_png_png_get_channels=no
12403 fi
12404 rm -f core conftest.err conftest.$ac_objext \
12405 conftest$ac_exeext conftest.$ac_ext
12406 LIBS=$ac_check_lib_save_LIBS
12407 fi
12408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12409 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12410 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12411 HAVE_PNG=yes
12412 fi
12413
12414 fi
12415 fi
12416
12417 if test "${HAVE_PNG}" = "yes"; then
12418
12419 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12420
12421 LIBPNG="-lpng -lz -lm"
12422
12423 ac_fn_c_check_decl "$LINENO" "png_longjmp" "ac_cv_have_decl_png_longjmp" "#ifdef HAVE_LIBPNG_PNG_H
12424 # include <libpng/png.h>
12425 #else
12426 # include <png.h>
12427 #endif
12428
12429 "
12430 if test "x$ac_cv_have_decl_png_longjmp" = x""yes; then :
12431
12432 else
12433
12434 $as_echo "#define PNG_DEPSTRUCT /**/" >>confdefs.h
12435
12436 fi
12437
12438 fi
12439 fi
12440
12441
12442 ### Use -ltiff if available, unless `--with-tiff=no'.
12443 HAVE_TIFF=no
12444 LIBTIFF=
12445 if test "${HAVE_X11}" = "yes"; then
12446 if test "${with_tiff}" != "no"; then
12447 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12448 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12449 tifflibs="-lz -lm"
12450 # At least one tiff package requires the jpeg library.
12451 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12453 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12454 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12455 $as_echo_n "(cached) " >&6
12456 else
12457 ac_check_lib_save_LIBS=$LIBS
12458 LIBS="-ltiff $tifflibs $LIBS"
12459 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12460 /* end confdefs.h. */
12461
12462 /* Override any GCC internal prototype to avoid an error.
12463 Use char because int might match the return type of a GCC
12464 builtin and then its argument prototype would still apply. */
12465 #ifdef __cplusplus
12466 extern "C"
12467 #endif
12468 char TIFFGetVersion ();
12469 int
12470 main ()
12471 {
12472 return TIFFGetVersion ();
12473 ;
12474 return 0;
12475 }
12476 _ACEOF
12477 if ac_fn_c_try_link "$LINENO"; then :
12478 ac_cv_lib_tiff_TIFFGetVersion=yes
12479 else
12480 ac_cv_lib_tiff_TIFFGetVersion=no
12481 fi
12482 rm -f core conftest.err conftest.$ac_objext \
12483 conftest$ac_exeext conftest.$ac_ext
12484 LIBS=$ac_check_lib_save_LIBS
12485 fi
12486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12487 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12488 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12489 HAVE_TIFF=yes
12490 fi
12491
12492 fi
12493
12494
12495 fi
12496
12497 if test "${HAVE_TIFF}" = "yes"; then
12498
12499 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12500
12501 LIBTIFF=-ltiff
12502 fi
12503 fi
12504
12505
12506 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12507 HAVE_GIF=no
12508 LIBGIF=
12509 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12510 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12511 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12512 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
12513 # Earlier versions can crash Emacs.
12514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
12515 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
12516 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
12517 $as_echo_n "(cached) " >&6
12518 else
12519 ac_check_lib_save_LIBS=$LIBS
12520 LIBS="-lgif $LIBS"
12521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12522 /* end confdefs.h. */
12523
12524 /* Override any GCC internal prototype to avoid an error.
12525 Use char because int might match the return type of a GCC
12526 builtin and then its argument prototype would still apply. */
12527 #ifdef __cplusplus
12528 extern "C"
12529 #endif
12530 char EGifPutExtensionLast ();
12531 int
12532 main ()
12533 {
12534 return EGifPutExtensionLast ();
12535 ;
12536 return 0;
12537 }
12538 _ACEOF
12539 if ac_fn_c_try_link "$LINENO"; then :
12540 ac_cv_lib_gif_EGifPutExtensionLast=yes
12541 else
12542 ac_cv_lib_gif_EGifPutExtensionLast=no
12543 fi
12544 rm -f core conftest.err conftest.$ac_objext \
12545 conftest$ac_exeext conftest.$ac_ext
12546 LIBS=$ac_check_lib_save_LIBS
12547 fi
12548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
12549 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
12550 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
12551 HAVE_GIF=yes
12552 else
12553 HAVE_GIF=maybe
12554 fi
12555
12556 fi
12557
12558
12559
12560 if test "$HAVE_GIF" = yes; then
12561 LIBGIF=-lgif
12562 elif test "$HAVE_GIF" = maybe; then
12563 # If gif_lib.h but no libgif, try libungif.
12564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
12565 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
12566 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
12567 $as_echo_n "(cached) " >&6
12568 else
12569 ac_check_lib_save_LIBS=$LIBS
12570 LIBS="-lungif $LIBS"
12571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12572 /* end confdefs.h. */
12573
12574 /* Override any GCC internal prototype to avoid an error.
12575 Use char because int might match the return type of a GCC
12576 builtin and then its argument prototype would still apply. */
12577 #ifdef __cplusplus
12578 extern "C"
12579 #endif
12580 char EGifPutExtensionLast ();
12581 int
12582 main ()
12583 {
12584 return EGifPutExtensionLast ();
12585 ;
12586 return 0;
12587 }
12588 _ACEOF
12589 if ac_fn_c_try_link "$LINENO"; then :
12590 ac_cv_lib_ungif_EGifPutExtensionLast=yes
12591 else
12592 ac_cv_lib_ungif_EGifPutExtensionLast=no
12593 fi
12594 rm -f core conftest.err conftest.$ac_objext \
12595 conftest$ac_exeext conftest.$ac_ext
12596 LIBS=$ac_check_lib_save_LIBS
12597 fi
12598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
12599 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
12600 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
12601 HAVE_GIF=yes
12602 else
12603 HAVE_GIF=no
12604 fi
12605
12606 test "$HAVE_GIF" = yes && LIBGIF=-lungif
12607 fi
12608
12609 if test "${HAVE_GIF}" = "yes"; then
12610
12611 $as_echo "#define HAVE_GIF 1" >>confdefs.h
12612
12613 fi
12614 fi
12615
12616
12617 if test "${HAVE_X11}" = "yes"; then
12618 MISSING=""
12619 WITH_NO=""
12620 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
12621 MISSING="libXpm" && WITH_NO="--with-xpm=no"
12622 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
12623 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
12624 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
12625 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
12626 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
12627 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
12628 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
12629 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
12630
12631 if test "X${MISSING}" != X; then
12632 as_fn_error "The following required libraries were not found:
12633 $MISSING
12634 Maybe some development libraries/packages are missing?
12635 If you don't want to link with them give
12636 $WITH_NO
12637 as options to configure" "$LINENO" 5
12638 fi
12639 fi
12640
12641 ### Use -lgpm if available, unless `--with-gpm=no'.
12642 HAVE_GPM=no
12643 LIBGPM=
12644 if test "${with_gpm}" != "no"; then
12645 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
12646 if test "x$ac_cv_header_gpm_h" = x""yes; then :
12647 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
12648 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
12649 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
12650 $as_echo_n "(cached) " >&6
12651 else
12652 ac_check_lib_save_LIBS=$LIBS
12653 LIBS="-lgpm $LIBS"
12654 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12655 /* end confdefs.h. */
12656
12657 /* Override any GCC internal prototype to avoid an error.
12658 Use char because int might match the return type of a GCC
12659 builtin and then its argument prototype would still apply. */
12660 #ifdef __cplusplus
12661 extern "C"
12662 #endif
12663 char Gpm_Open ();
12664 int
12665 main ()
12666 {
12667 return Gpm_Open ();
12668 ;
12669 return 0;
12670 }
12671 _ACEOF
12672 if ac_fn_c_try_link "$LINENO"; then :
12673 ac_cv_lib_gpm_Gpm_Open=yes
12674 else
12675 ac_cv_lib_gpm_Gpm_Open=no
12676 fi
12677 rm -f core conftest.err conftest.$ac_objext \
12678 conftest$ac_exeext conftest.$ac_ext
12679 LIBS=$ac_check_lib_save_LIBS
12680 fi
12681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
12682 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
12683 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
12684 HAVE_GPM=yes
12685 fi
12686
12687 fi
12688
12689
12690
12691 if test "${HAVE_GPM}" = "yes"; then
12692
12693 $as_echo "#define HAVE_GPM 1" >>confdefs.h
12694
12695 LIBGPM=-lgpm
12696 fi
12697 fi
12698
12699
12700
12701
12702
12703
12704 GNUSTEP_CFLAGS=
12705 ### Use NeXTstep API to implement GUI.
12706 if test "${HAVE_NS}" = "yes"; then
12707
12708 $as_echo "#define HAVE_NS 1" >>confdefs.h
12709
12710 if test "${NS_IMPL_COCOA}" = "yes"; then
12711
12712 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
12713
12714 fi
12715 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
12716
12717 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
12718
12719 # See also .m.o rule in Makefile.in */
12720 # FIXME: are all these flags really needed? Document here why. */
12721 GNUSTEP_CFLAGS="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
12722 ## Extra CFLAGS applied to src/*.m files.
12723 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"
12724 fi
12725 # We also have mouse menus.
12726 HAVE_MENUS=yes
12727 OTHER_FILES=ns-app
12728 fi
12729
12730
12731 ### Use session management (-lSM -lICE) if available
12732 HAVE_X_SM=no
12733 LIBXSM=
12734 if test "${HAVE_X11}" = "yes"; then
12735 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
12736 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
12737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
12738 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
12739 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
12740 $as_echo_n "(cached) " >&6
12741 else
12742 ac_check_lib_save_LIBS=$LIBS
12743 LIBS="-lSM -lICE $LIBS"
12744 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12745 /* end confdefs.h. */
12746
12747 /* Override any GCC internal prototype to avoid an error.
12748 Use char because int might match the return type of a GCC
12749 builtin and then its argument prototype would still apply. */
12750 #ifdef __cplusplus
12751 extern "C"
12752 #endif
12753 char SmcOpenConnection ();
12754 int
12755 main ()
12756 {
12757 return SmcOpenConnection ();
12758 ;
12759 return 0;
12760 }
12761 _ACEOF
12762 if ac_fn_c_try_link "$LINENO"; then :
12763 ac_cv_lib_SM_SmcOpenConnection=yes
12764 else
12765 ac_cv_lib_SM_SmcOpenConnection=no
12766 fi
12767 rm -f core conftest.err conftest.$ac_objext \
12768 conftest$ac_exeext conftest.$ac_ext
12769 LIBS=$ac_check_lib_save_LIBS
12770 fi
12771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
12772 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
12773 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
12774 HAVE_X_SM=yes
12775 fi
12776
12777 fi
12778
12779
12780
12781 if test "${HAVE_X_SM}" = "yes"; then
12782
12783 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
12784
12785 LIBXSM="-lSM -lICE"
12786 case "$LIBS" in
12787 *-lSM*) ;;
12788 *) LIBS="$LIBXSM $LIBS" ;;
12789 esac
12790 fi
12791 fi
12792
12793
12794 ### Use libxml (-lxml2) if available
12795 HAVE_LIBXML2=no
12796 if test "${with_xml2}" != "no"; then
12797 ### I'm not sure what the version number should be, so I just guessed.
12798
12799 succeeded=no
12800
12801 if test "$PKG_CONFIG" = "no" ; then
12802 HAVE_LIBXML2=no
12803 else
12804 PKG_CONFIG_MIN_VERSION=0.9.0
12805 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
12807 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
12808
12809 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
12810 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
12811 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
12812 edit_cflags="
12813 s,///*,/,g
12814 s/^/ /
12815 s/ -I/ $isystem/g
12816 s/^ //
12817 "
12818 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e "$edit_cflags"`
12819 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
12820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
12821 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
12822 succeeded=yes
12823 else
12824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12825 $as_echo "no" >&6; }
12826 LIBXML2_CFLAGS=""
12827 LIBXML2_LIBS=""
12828 ## If we have a custom action on failure, don't print errors, but
12829 ## do set a variable so people can do so. Do it in a subshell
12830 ## to capture any diagnostics in invoking pkg-config.
12831 LIBXML2_PKG_ERRORS=`($PKG_CONFIG --print-errors "libxml-2.0 > 2.6.17") 2>&1`
12832
12833 fi
12834
12835
12836
12837 else
12838 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12839 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12840 fi
12841 fi
12842
12843 if test $succeeded = yes; then
12844 HAVE_LIBXML2=yes
12845 else
12846 HAVE_LIBXML2=no
12847 fi
12848
12849 if test "${HAVE_LIBXML2}" = "yes"; then
12850 LIBS="$LIBXML2_LIBS $LIBS"
12851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
12852 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
12853 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
12854 $as_echo_n "(cached) " >&6
12855 else
12856 ac_check_lib_save_LIBS=$LIBS
12857 LIBS="-lxml2 $LIBS"
12858 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12859 /* end confdefs.h. */
12860
12861 /* Override any GCC internal prototype to avoid an error.
12862 Use char because int might match the return type of a GCC
12863 builtin and then its argument prototype would still apply. */
12864 #ifdef __cplusplus
12865 extern "C"
12866 #endif
12867 char htmlReadMemory ();
12868 int
12869 main ()
12870 {
12871 return htmlReadMemory ();
12872 ;
12873 return 0;
12874 }
12875 _ACEOF
12876 if ac_fn_c_try_link "$LINENO"; then :
12877 ac_cv_lib_xml2_htmlReadMemory=yes
12878 else
12879 ac_cv_lib_xml2_htmlReadMemory=no
12880 fi
12881 rm -f core conftest.err conftest.$ac_objext \
12882 conftest$ac_exeext conftest.$ac_ext
12883 LIBS=$ac_check_lib_save_LIBS
12884 fi
12885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
12886 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
12887 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
12888 HAVE_LIBXML2=yes
12889 else
12890 HAVE_LIBXML2=no
12891 fi
12892
12893 if test "${HAVE_LIBXML2}" = "yes"; then
12894
12895 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
12896
12897 else
12898 LIBXML2_LIBS=""
12899 LIBXML2_CFLAGS=""
12900 fi
12901 fi
12902 fi
12903
12904
12905
12906 # If netdb.h doesn't declare h_errno, we must declare it by hand.
12907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
12908 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
12909 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
12910 $as_echo_n "(cached) " >&6
12911 else
12912 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12913 /* end confdefs.h. */
12914 #include <netdb.h>
12915 int
12916 main ()
12917 {
12918 return h_errno;
12919 ;
12920 return 0;
12921 }
12922 _ACEOF
12923 if ac_fn_c_try_link "$LINENO"; then :
12924 emacs_cv_netdb_declares_h_errno=yes
12925 else
12926 emacs_cv_netdb_declares_h_errno=no
12927 fi
12928 rm -f core conftest.err conftest.$ac_objext \
12929 conftest$ac_exeext conftest.$ac_ext
12930 fi
12931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
12932 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
12933 if test $emacs_cv_netdb_declares_h_errno = yes; then
12934
12935 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
12936
12937 fi
12938
12939 # sqrt and other floating-point functions such as fmod and frexp
12940 # are found in -lm on most systems.
12941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
12942 $as_echo_n "checking for sqrt in -lm... " >&6; }
12943 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
12944 $as_echo_n "(cached) " >&6
12945 else
12946 ac_check_lib_save_LIBS=$LIBS
12947 LIBS="-lm $LIBS"
12948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12949 /* end confdefs.h. */
12950
12951 /* Override any GCC internal prototype to avoid an error.
12952 Use char because int might match the return type of a GCC
12953 builtin and then its argument prototype would still apply. */
12954 #ifdef __cplusplus
12955 extern "C"
12956 #endif
12957 char sqrt ();
12958 int
12959 main ()
12960 {
12961 return sqrt ();
12962 ;
12963 return 0;
12964 }
12965 _ACEOF
12966 if ac_fn_c_try_link "$LINENO"; then :
12967 ac_cv_lib_m_sqrt=yes
12968 else
12969 ac_cv_lib_m_sqrt=no
12970 fi
12971 rm -f core conftest.err conftest.$ac_objext \
12972 conftest$ac_exeext conftest.$ac_ext
12973 LIBS=$ac_check_lib_save_LIBS
12974 fi
12975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
12976 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
12977 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
12978 cat >>confdefs.h <<_ACEOF
12979 #define HAVE_LIBM 1
12980 _ACEOF
12981
12982 LIBS="-lm $LIBS"
12983
12984 fi
12985
12986
12987 # Check for mail-locking functions in a "mail" library. Probably this should
12988 # have the same check as for liblockfile below.
12989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
12990 $as_echo_n "checking for maillock in -lmail... " >&6; }
12991 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
12992 $as_echo_n "(cached) " >&6
12993 else
12994 ac_check_lib_save_LIBS=$LIBS
12995 LIBS="-lmail $LIBS"
12996 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12997 /* end confdefs.h. */
12998
12999 /* Override any GCC internal prototype to avoid an error.
13000 Use char because int might match the return type of a GCC
13001 builtin and then its argument prototype would still apply. */
13002 #ifdef __cplusplus
13003 extern "C"
13004 #endif
13005 char maillock ();
13006 int
13007 main ()
13008 {
13009 return maillock ();
13010 ;
13011 return 0;
13012 }
13013 _ACEOF
13014 if ac_fn_c_try_link "$LINENO"; then :
13015 ac_cv_lib_mail_maillock=yes
13016 else
13017 ac_cv_lib_mail_maillock=no
13018 fi
13019 rm -f core conftest.err conftest.$ac_objext \
13020 conftest$ac_exeext conftest.$ac_ext
13021 LIBS=$ac_check_lib_save_LIBS
13022 fi
13023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13024 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13025 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13026 have_mail=yes
13027 else
13028 have_mail=no
13029 fi
13030
13031 if test $have_mail = yes; then
13032 LIBS_MAIL=-lmail
13033 LIBS="$LIBS_MAIL $LIBS"
13034
13035 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13036
13037 else
13038 LIBS_MAIL=
13039 fi
13040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13041 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13042 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13043 $as_echo_n "(cached) " >&6
13044 else
13045 ac_check_lib_save_LIBS=$LIBS
13046 LIBS="-llockfile $LIBS"
13047 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13048 /* end confdefs.h. */
13049
13050 /* Override any GCC internal prototype to avoid an error.
13051 Use char because int might match the return type of a GCC
13052 builtin and then its argument prototype would still apply. */
13053 #ifdef __cplusplus
13054 extern "C"
13055 #endif
13056 char maillock ();
13057 int
13058 main ()
13059 {
13060 return maillock ();
13061 ;
13062 return 0;
13063 }
13064 _ACEOF
13065 if ac_fn_c_try_link "$LINENO"; then :
13066 ac_cv_lib_lockfile_maillock=yes
13067 else
13068 ac_cv_lib_lockfile_maillock=no
13069 fi
13070 rm -f core conftest.err conftest.$ac_objext \
13071 conftest$ac_exeext conftest.$ac_ext
13072 LIBS=$ac_check_lib_save_LIBS
13073 fi
13074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13075 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13076 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13077 have_lockfile=yes
13078 else
13079 have_lockfile=no
13080 fi
13081
13082 if test $have_lockfile = yes; then
13083 LIBS_MAIL=-llockfile
13084 LIBS="$LIBS_MAIL $LIBS"
13085
13086 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13087
13088 else
13089 # If we have the shared liblockfile, assume we must use it for mail
13090 # locking (e.g. Debian). If we couldn't link against liblockfile
13091 # (no liblockfile.a installed), ensure that we don't need to.
13092 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13093 set dummy liblockfile.so; ac_word=$2
13094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13095 $as_echo_n "checking for $ac_word... " >&6; }
13096 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13097 $as_echo_n "(cached) " >&6
13098 else
13099 if test -n "$liblockfile"; then
13100 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13101 else
13102 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13103 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13104 for as_dir in $as_dummy
13105 do
13106 IFS=$as_save_IFS
13107 test -z "$as_dir" && as_dir=.
13108 for ac_exec_ext in '' $ac_executable_extensions; do
13109 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13110 ac_cv_prog_liblockfile="yes"
13111 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13112 break 2
13113 fi
13114 done
13115 done
13116 IFS=$as_save_IFS
13117
13118 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13119 fi
13120 fi
13121 liblockfile=$ac_cv_prog_liblockfile
13122 if test -n "$liblockfile"; then
13123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13124 $as_echo "$liblockfile" >&6; }
13125 else
13126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13127 $as_echo "no" >&6; }
13128 fi
13129
13130
13131 if test $ac_cv_prog_liblockfile = yes; then
13132 as_fn_error "Shared liblockfile found but can't link against it.
13133 This probably means that movemail could lose mail.
13134 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13135 fi
13136 fi
13137
13138
13139
13140
13141
13142 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13143 ## interlock access to the mail spool. The alternative is a lock file named
13144 ## /usr/spool/mail/$USER.lock.
13145 mail_lock=no
13146 case "$opsys" in
13147 aix4-2) mail_lock="lockf" ;;
13148
13149 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13150
13151 ## On GNU/Linux systems, both methods are used by various mail programs.
13152 ## I assume most people are using newer mailers that have heard of flock.
13153 ## Change this if you need to.
13154 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13155 ## configure gets the right answers, and that means *NOT* using flock.
13156 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13157 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13158 ## Debian maintainer hasn't provided a clean fix for Emacs.
13159 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13160 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13161 ## correct logic. -- fx
13162 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13163 ## liblockfile is a Free Software replacement for libmail, used on
13164 ## Debian systems and elsewhere. -rfr.
13165 gnu-*)
13166 mail_lock="flock"
13167 if test $have_mail = yes || test $have_lockfile = yes; then
13168 test $ac_cv_header_maillock_h = yes && mail_lock=no
13169 fi
13170 ;;
13171 esac
13172
13173 BLESSMAIL_TARGET=
13174 case "$mail_lock" in
13175 flock)
13176 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13177 ;;
13178
13179 lockf)
13180 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13181 ;;
13182
13183 *) BLESSMAIL_TARGET="need-blessmail" ;;
13184 esac
13185
13186
13187
13188 for ac_func in gethostname \
13189 closedir getrusage get_current_dir_name \
13190 lrand48 setsid \
13191 fpathconf select euidaccess getpagesize setlocale \
13192 utimes getrlimit setrlimit setpgid getcwd shutdown getaddrinfo \
13193 __fpending strsignal setitimer \
13194 sendto recvfrom getsockname getpeername getifaddrs freeifaddrs \
13195 gai_strerror mkstemp getline getdelim fsync sync \
13196 difftime posix_memalign \
13197 getpwent endpwent getgrent endgrent \
13198 touchlock \
13199 cfmakeraw cfsetspeed copysign __executable_start
13200 do :
13201 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13202 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13203 eval as_val=\$$as_ac_var
13204 if test "x$as_val" = x""yes; then :
13205 cat >>confdefs.h <<_ACEOF
13206 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13207 _ACEOF
13208
13209 fi
13210 done
13211
13212
13213 if test $opsys = unixware; then
13214
13215 $as_echo "#define BROKEN_GETWD 1" >>confdefs.h
13216
13217 else
13218 for ac_func in getwd
13219 do :
13220 ac_fn_c_check_func "$LINENO" "getwd" "ac_cv_func_getwd"
13221 if test "x$ac_cv_func_getwd" = x""yes; then :
13222 cat >>confdefs.h <<_ACEOF
13223 #define HAVE_GETWD 1
13224 _ACEOF
13225
13226 fi
13227 done
13228
13229 fi
13230
13231 ## Eric Backus <ericb@lsid.hp.com> says, HP-UX 9.x on HP 700 machines
13232 ## has a broken `rint' in some library versions including math library
13233 ## version number A.09.05.
13234 ## You can fix the math library by installing patch number PHSS_4630.
13235 ## But we can fix it more reliably for Emacs by just not using rint.
13236 ## We also skip HAVE_RANDOM - see comments in src/conf_post.h.
13237 case $opsys in
13238 hpux*) : ;;
13239 *) for ac_func in random rint
13240 do :
13241 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13242 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13243 eval as_val=\$$as_ac_var
13244 if test "x$as_val" = x""yes; then :
13245 cat >>confdefs.h <<_ACEOF
13246 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13247 _ACEOF
13248
13249 fi
13250 done
13251 ;;
13252 esac
13253
13254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13255 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13256 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13257 $as_echo_n "(cached) " >&6
13258 else
13259 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13260 /* end confdefs.h. */
13261
13262 int
13263 main ()
13264 {
13265 __builtin_unwind_init ();
13266 ;
13267 return 0;
13268 }
13269 _ACEOF
13270 if ac_fn_c_try_link "$LINENO"; then :
13271 emacs_cv_func___builtin_unwind_init=yes
13272 else
13273 emacs_cv_func___builtin_unwind_init=no
13274 fi
13275 rm -f core conftest.err conftest.$ac_objext \
13276 conftest$ac_exeext conftest.$ac_ext
13277 fi
13278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13279 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13280 if test $emacs_cv_func___builtin_unwind_init = yes; then
13281
13282 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13283
13284 fi
13285
13286
13287
13288
13289
13290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13291 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13292 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13293 $as_echo_n "(cached) " >&6
13294 else
13295 while :; do
13296 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13297 /* end confdefs.h. */
13298 #include <sys/types.h> /* for off_t */
13299 #include <stdio.h>
13300 int
13301 main ()
13302 {
13303 int (*fp) (FILE *, off_t, int) = fseeko;
13304 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13305 ;
13306 return 0;
13307 }
13308 _ACEOF
13309 if ac_fn_c_try_link "$LINENO"; then :
13310 ac_cv_sys_largefile_source=no; break
13311 fi
13312 rm -f core conftest.err conftest.$ac_objext \
13313 conftest$ac_exeext conftest.$ac_ext
13314 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13315 /* end confdefs.h. */
13316 #define _LARGEFILE_SOURCE 1
13317 #include <sys/types.h> /* for off_t */
13318 #include <stdio.h>
13319 int
13320 main ()
13321 {
13322 int (*fp) (FILE *, off_t, int) = fseeko;
13323 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13324 ;
13325 return 0;
13326 }
13327 _ACEOF
13328 if ac_fn_c_try_link "$LINENO"; then :
13329 ac_cv_sys_largefile_source=1; break
13330 fi
13331 rm -f core conftest.err conftest.$ac_objext \
13332 conftest$ac_exeext conftest.$ac_ext
13333 ac_cv_sys_largefile_source=unknown
13334 break
13335 done
13336 fi
13337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13338 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13339 case $ac_cv_sys_largefile_source in #(
13340 no | unknown) ;;
13341 *)
13342 cat >>confdefs.h <<_ACEOF
13343 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13344 _ACEOF
13345 ;;
13346 esac
13347 rm -rf conftest*
13348
13349 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13350 # in glibc 2.1.3, but that breaks too many other things.
13351 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13352 if test $ac_cv_sys_largefile_source != unknown; then
13353
13354 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13355
13356 fi
13357
13358
13359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13360 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13361 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13362 $as_echo_n "(cached) " >&6
13363 else
13364 # Use it with a single arg.
13365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13366 /* end confdefs.h. */
13367 $ac_includes_default
13368 int
13369 main ()
13370 {
13371 getpgrp (0);
13372 ;
13373 return 0;
13374 }
13375 _ACEOF
13376 if ac_fn_c_try_compile "$LINENO"; then :
13377 ac_cv_func_getpgrp_void=no
13378 else
13379 ac_cv_func_getpgrp_void=yes
13380 fi
13381 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13382
13383 fi
13384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13385 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13386 if test $ac_cv_func_getpgrp_void = yes; then
13387
13388 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13389
13390 fi
13391
13392
13393 # UNIX98 PTYs.
13394 for ac_func in grantpt
13395 do :
13396 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
13397 if test "x$ac_cv_func_grantpt" = x""yes; then :
13398 cat >>confdefs.h <<_ACEOF
13399 #define HAVE_GRANTPT 1
13400 _ACEOF
13401
13402 fi
13403 done
13404
13405
13406 # PTY-related GNU extensions.
13407 for ac_func in getpt posix_openpt
13408 do :
13409 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13410 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13411 eval as_val=\$$as_ac_var
13412 if test "x$as_val" = x""yes; then :
13413 cat >>confdefs.h <<_ACEOF
13414 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13415 _ACEOF
13416
13417 fi
13418 done
13419
13420
13421 # Check this now, so that we will NOT find the above functions in ncurses.
13422 # That is because we have not set up to link ncurses in lib-src.
13423 # It's better to believe a function is not available
13424 # than to expect to find it in ncurses.
13425 # Also we need tputs and friends to be able to build at all.
13426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
13427 $as_echo_n "checking for library containing tputs... " >&6; }
13428 # Run a test program that contains a call to tputs, a call that is
13429 # never executed. This tests whether a pre-'main' dynamic linker
13430 # works with the library. It's too much trouble to actually call
13431 # tputs in the test program, due to portability hassles. When
13432 # cross-compiling, assume the test program will run if it links.
13433
13434 # Maybe curses should be tried earlier?
13435 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
13436 for tputs_library in '' tinfo ncurses terminfo termcap curses; do
13437 OLIBS=$LIBS
13438 if test -z "$tputs_library"; then
13439 LIBS_TERMCAP=
13440 msg='none required'
13441 else
13442 LIBS_TERMCAP=-l$tputs_library
13443 msg=$LIBS_TERMCAP
13444 LIBS="$LIBS_TERMCAP $LIBS"
13445 fi
13446 if test "$cross_compiling" = yes; then :
13447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13448 /* end confdefs.h. */
13449
13450 extern void tputs (const char *, int, int (*)(int));
13451 int main (int argc, char **argv)
13452 {
13453 if (argc == 10000)
13454 tputs (argv[0], 0, 0);
13455 return 0;
13456 }
13457
13458 _ACEOF
13459 if ac_fn_c_try_link "$LINENO"; then :
13460
13461 else
13462 msg=no
13463 fi
13464 rm -f core conftest.err conftest.$ac_objext \
13465 conftest$ac_exeext conftest.$ac_ext
13466 else
13467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13468 /* end confdefs.h. */
13469
13470 extern void tputs (const char *, int, int (*)(int));
13471 int main (int argc, char **argv)
13472 {
13473 if (argc == 10000)
13474 tputs (argv[0], 0, 0);
13475 return 0;
13476 }
13477
13478 _ACEOF
13479 if ac_fn_c_try_run "$LINENO"; then :
13480
13481 else
13482 msg=no
13483 fi
13484 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13485 conftest.$ac_objext conftest.beam conftest.$ac_ext
13486 fi
13487
13488 LIBS=$OLIBS
13489 if test "X$msg" != Xno; then
13490 break
13491 fi
13492 done
13493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
13494 $as_echo "$msg" >&6; }
13495 if test "X$msg" = Xno; then
13496 as_fn_error "The required function \`tputs' was not found in any library.
13497 The following libraries were tried (in order):
13498 libtinfo, libncurses, libterminfo, libtermcap, libcurses
13499 Please try installing whichever of these libraries is most appropriate
13500 for your system, together with its header files.
13501 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
13502 fi
13503
13504 ## Use termcap instead of terminfo?
13505 ## Only true for: freebsd < 40000, ms-w32, msdos, netbsd < 599002500.
13506 TERMINFO=yes
13507 ## FIXME? In the cases below where we unconditionally set
13508 ## LIBS_TERMCAP="-lncurses", this overrides LIBS_TERMCAP = -ltinfo,
13509 ## if that was found above to have tputs.
13510 ## Should we use the gnu* logic everywhere?
13511 case "$opsys" in
13512 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
13513 ## The ncurses library has been moved out of the System framework in
13514 ## Mac OS X 10.2. So if configure detects it, set the command-line
13515 ## option to use it.
13516 darwin) LIBS_TERMCAP="-lncurses" ;;
13517
13518 gnu*) test -z "$LIBS_TERMCAP" && LIBS_TERMCAP="-lncurses" ;;
13519
13520 freebsd)
13521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
13522 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
13523 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
13524 $as_echo_n "(cached) " >&6
13525 else
13526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13527 /* end confdefs.h. */
13528 #include <osreldate.h>
13529 int
13530 main ()
13531 {
13532 #if __FreeBSD_version < 400000
13533 fail;
13534 #endif
13535
13536 ;
13537 return 0;
13538 }
13539 _ACEOF
13540 if ac_fn_c_try_link "$LINENO"; then :
13541 emacs_cv_freebsd_terminfo=yes
13542 else
13543 emacs_cv_freebsd_terminfo=no
13544 fi
13545 rm -f core conftest.err conftest.$ac_objext \
13546 conftest$ac_exeext conftest.$ac_ext
13547 fi
13548
13549
13550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
13551 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
13552
13553 if test $emacs_cv_freebsd_terminfo = yes; then
13554 LIBS_TERMCAP="-lncurses"
13555 else
13556 TERMINFO=no
13557 LIBS_TERMCAP="-ltermcap"
13558 fi
13559 ;;
13560
13561 netbsd)
13562 if test "x$LIBS_TERMCAP" != "x-lterminfo"; then
13563 TERMINFO=no
13564 LIBS_TERMCAP="-ltermcap"
13565 fi
13566 ;;
13567
13568 openbsd) LIBS_TERMCAP="-lncurses" ;;
13569
13570 ## hpux: Make sure we get select from libc rather than from libcurses
13571 ## because libcurses on HPUX 10.10 has a broken version of select.
13572 ## We used to use -lc -lcurses, but this may be cleaner.
13573 ## FIXME? But TERMINFO = yes on hpux (it used to be explicitly
13574 # set that way, now it uses the default). Isn't this a contradiction?
13575 hpux*) LIBS_TERMCAP="-ltermcap" ;;
13576
13577 esac
13578
13579 TERMCAP_OBJ=tparam.o
13580 if test $TERMINFO = yes; then
13581
13582 $as_echo "#define TERMINFO 1" >>confdefs.h
13583
13584 TERMCAP_OBJ=terminfo.o
13585 fi
13586
13587
13588
13589
13590 # Do we have res_init, for detecting changes in /etc/resolv.conf?
13591 # On Darwin, res_init appears not to be useful: see bug#562 and
13592 # http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01467.html
13593 resolv=no
13594
13595 if test $opsys != darwin; then
13596
13597 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13598 /* end confdefs.h. */
13599 #include <netinet/in.h>
13600 #include <arpa/nameser.h>
13601 #include <resolv.h>
13602 int
13603 main ()
13604 {
13605 return res_init();
13606 ;
13607 return 0;
13608 }
13609 _ACEOF
13610 if ac_fn_c_try_link "$LINENO"; then :
13611 have_res_init=yes
13612 else
13613 have_res_init=no
13614 fi
13615 rm -f core conftest.err conftest.$ac_objext \
13616 conftest$ac_exeext conftest.$ac_ext
13617 if test "$have_res_init" = no; then
13618 OLIBS="$LIBS"
13619 LIBS="$LIBS -lresolv"
13620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
13621 $as_echo_n "checking for res_init with -lresolv... " >&6; }
13622 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13623 /* end confdefs.h. */
13624 #include <netinet/in.h>
13625 #include <arpa/nameser.h>
13626 #include <resolv.h>
13627 int
13628 main ()
13629 {
13630 return res_init();
13631 ;
13632 return 0;
13633 }
13634 _ACEOF
13635 if ac_fn_c_try_link "$LINENO"; then :
13636 have_res_init=yes
13637 else
13638 have_res_init=no
13639 fi
13640 rm -f core conftest.err conftest.$ac_objext \
13641 conftest$ac_exeext conftest.$ac_ext
13642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
13643 $as_echo "$have_res_init" >&6; }
13644 if test "$have_res_init" = yes ; then
13645 resolv=yes
13646 fi
13647 LIBS="$OLIBS"
13648 fi
13649
13650 if test "$have_res_init" = yes; then
13651
13652 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
13653
13654 fi
13655 fi
13656 # Do we need the Hesiod library to provide the support routines?
13657 LIBHESIOD=
13658 if test "$with_hesiod" != no ; then
13659 # Don't set $LIBS here -- see comments above. FIXME which comments?
13660 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
13661 if test "x$ac_cv_func_res_send" = x""yes; then :
13662
13663 else
13664 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
13665 if test "x$ac_cv_func___res_send" = x""yes; then :
13666
13667 else
13668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
13669 $as_echo_n "checking for res_send in -lresolv... " >&6; }
13670 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
13671 $as_echo_n "(cached) " >&6
13672 else
13673 ac_check_lib_save_LIBS=$LIBS
13674 LIBS="-lresolv $LIBS"
13675 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13676 /* end confdefs.h. */
13677
13678 /* Override any GCC internal prototype to avoid an error.
13679 Use char because int might match the return type of a GCC
13680 builtin and then its argument prototype would still apply. */
13681 #ifdef __cplusplus
13682 extern "C"
13683 #endif
13684 char res_send ();
13685 int
13686 main ()
13687 {
13688 return res_send ();
13689 ;
13690 return 0;
13691 }
13692 _ACEOF
13693 if ac_fn_c_try_link "$LINENO"; then :
13694 ac_cv_lib_resolv_res_send=yes
13695 else
13696 ac_cv_lib_resolv_res_send=no
13697 fi
13698 rm -f core conftest.err conftest.$ac_objext \
13699 conftest$ac_exeext conftest.$ac_ext
13700 LIBS=$ac_check_lib_save_LIBS
13701 fi
13702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
13703 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
13704 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
13705 resolv=yes
13706 else
13707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
13708 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
13709 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
13710 $as_echo_n "(cached) " >&6
13711 else
13712 ac_check_lib_save_LIBS=$LIBS
13713 LIBS="-lresolv $LIBS"
13714 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13715 /* end confdefs.h. */
13716
13717 /* Override any GCC internal prototype to avoid an error.
13718 Use char because int might match the return type of a GCC
13719 builtin and then its argument prototype would still apply. */
13720 #ifdef __cplusplus
13721 extern "C"
13722 #endif
13723 char __res_send ();
13724 int
13725 main ()
13726 {
13727 return __res_send ();
13728 ;
13729 return 0;
13730 }
13731 _ACEOF
13732 if ac_fn_c_try_link "$LINENO"; then :
13733 ac_cv_lib_resolv___res_send=yes
13734 else
13735 ac_cv_lib_resolv___res_send=no
13736 fi
13737 rm -f core conftest.err conftest.$ac_objext \
13738 conftest$ac_exeext conftest.$ac_ext
13739 LIBS=$ac_check_lib_save_LIBS
13740 fi
13741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
13742 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
13743 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
13744 resolv=yes
13745 fi
13746
13747 fi
13748
13749 fi
13750
13751 fi
13752
13753 if test "$resolv" = yes ; then
13754 RESOLVLIB=-lresolv
13755 else
13756 RESOLVLIB=
13757 fi
13758 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
13759 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
13760
13761 else
13762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
13763 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
13764 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
13765 $as_echo_n "(cached) " >&6
13766 else
13767 ac_check_lib_save_LIBS=$LIBS
13768 LIBS="-lhesiod $RESOLVLIB $LIBS"
13769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13770 /* end confdefs.h. */
13771
13772 /* Override any GCC internal prototype to avoid an error.
13773 Use char because int might match the return type of a GCC
13774 builtin and then its argument prototype would still apply. */
13775 #ifdef __cplusplus
13776 extern "C"
13777 #endif
13778 char hes_getmailhost ();
13779 int
13780 main ()
13781 {
13782 return hes_getmailhost ();
13783 ;
13784 return 0;
13785 }
13786 _ACEOF
13787 if ac_fn_c_try_link "$LINENO"; then :
13788 ac_cv_lib_hesiod_hes_getmailhost=yes
13789 else
13790 ac_cv_lib_hesiod_hes_getmailhost=no
13791 fi
13792 rm -f core conftest.err conftest.$ac_objext \
13793 conftest$ac_exeext conftest.$ac_ext
13794 LIBS=$ac_check_lib_save_LIBS
13795 fi
13796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
13797 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
13798 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
13799 hesiod=yes
13800 else
13801 :
13802 fi
13803
13804 fi
13805
13806
13807 if test x"$hesiod" = xyes; then
13808
13809 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
13810
13811 LIBHESIOD=-lhesiod
13812 fi
13813 fi
13814
13815
13816 # Do we need libresolv (due to res_init or Hesiod)?
13817 if test "$resolv" = yes && test $opsys != darwin; then
13818
13819 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
13820
13821 LIBRESOLV=-lresolv
13822 else
13823 LIBRESOLV=
13824 fi
13825
13826
13827 # These tell us which Kerberos-related libraries to use.
13828 COM_ERRLIB=
13829 CRYPTOLIB=
13830 KRB5LIB=
13831 DESLIB=
13832 KRB4LIB=
13833
13834 if test "${with_kerberos}" != no; then
13835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
13836 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
13837 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
13838 $as_echo_n "(cached) " >&6
13839 else
13840 ac_check_lib_save_LIBS=$LIBS
13841 LIBS="-lcom_err $LIBS"
13842 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13843 /* end confdefs.h. */
13844
13845 /* Override any GCC internal prototype to avoid an error.
13846 Use char because int might match the return type of a GCC
13847 builtin and then its argument prototype would still apply. */
13848 #ifdef __cplusplus
13849 extern "C"
13850 #endif
13851 char com_err ();
13852 int
13853 main ()
13854 {
13855 return com_err ();
13856 ;
13857 return 0;
13858 }
13859 _ACEOF
13860 if ac_fn_c_try_link "$LINENO"; then :
13861 ac_cv_lib_com_err_com_err=yes
13862 else
13863 ac_cv_lib_com_err_com_err=no
13864 fi
13865 rm -f core conftest.err conftest.$ac_objext \
13866 conftest$ac_exeext conftest.$ac_ext
13867 LIBS=$ac_check_lib_save_LIBS
13868 fi
13869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
13870 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
13871 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
13872 have_com_err=yes
13873 else
13874 have_com_err=no
13875 fi
13876
13877 if test $have_com_err = yes; then
13878 COM_ERRLIB=-lcom_err
13879 LIBS="$COM_ERRLIB $LIBS"
13880
13881 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
13882
13883 fi
13884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
13885 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
13886 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
13887 $as_echo_n "(cached) " >&6
13888 else
13889 ac_check_lib_save_LIBS=$LIBS
13890 LIBS="-lcrypto $LIBS"
13891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13892 /* end confdefs.h. */
13893
13894 /* Override any GCC internal prototype to avoid an error.
13895 Use char because int might match the return type of a GCC
13896 builtin and then its argument prototype would still apply. */
13897 #ifdef __cplusplus
13898 extern "C"
13899 #endif
13900 char mit_des_cbc_encrypt ();
13901 int
13902 main ()
13903 {
13904 return mit_des_cbc_encrypt ();
13905 ;
13906 return 0;
13907 }
13908 _ACEOF
13909 if ac_fn_c_try_link "$LINENO"; then :
13910 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
13911 else
13912 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
13913 fi
13914 rm -f core conftest.err conftest.$ac_objext \
13915 conftest$ac_exeext conftest.$ac_ext
13916 LIBS=$ac_check_lib_save_LIBS
13917 fi
13918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
13919 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
13920 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
13921 have_crypto=yes
13922 else
13923 have_crypto=no
13924 fi
13925
13926 if test $have_crypto = yes; then
13927 CRYPTOLIB=-lcrypto
13928 LIBS="$CRYPTOLIB $LIBS"
13929
13930 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
13931
13932 fi
13933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
13934 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
13935 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
13936 $as_echo_n "(cached) " >&6
13937 else
13938 ac_check_lib_save_LIBS=$LIBS
13939 LIBS="-lk5crypto $LIBS"
13940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13941 /* end confdefs.h. */
13942
13943 /* Override any GCC internal prototype to avoid an error.
13944 Use char because int might match the return type of a GCC
13945 builtin and then its argument prototype would still apply. */
13946 #ifdef __cplusplus
13947 extern "C"
13948 #endif
13949 char mit_des_cbc_encrypt ();
13950 int
13951 main ()
13952 {
13953 return mit_des_cbc_encrypt ();
13954 ;
13955 return 0;
13956 }
13957 _ACEOF
13958 if ac_fn_c_try_link "$LINENO"; then :
13959 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
13960 else
13961 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
13962 fi
13963 rm -f core conftest.err conftest.$ac_objext \
13964 conftest$ac_exeext conftest.$ac_ext
13965 LIBS=$ac_check_lib_save_LIBS
13966 fi
13967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
13968 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
13969 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
13970 have_k5crypto=yes
13971 else
13972 have_k5crypto=no
13973 fi
13974
13975 if test $have_k5crypto = yes; then
13976 CRYPTOLIB=-lk5crypto
13977 LIBS="$CRYPTOLIB $LIBS"
13978
13979 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
13980
13981 fi
13982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
13983 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
13984 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
13985 $as_echo_n "(cached) " >&6
13986 else
13987 ac_check_lib_save_LIBS=$LIBS
13988 LIBS="-lkrb5 $LIBS"
13989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13990 /* end confdefs.h. */
13991
13992 /* Override any GCC internal prototype to avoid an error.
13993 Use char because int might match the return type of a GCC
13994 builtin and then its argument prototype would still apply. */
13995 #ifdef __cplusplus
13996 extern "C"
13997 #endif
13998 char krb5_init_context ();
13999 int
14000 main ()
14001 {
14002 return krb5_init_context ();
14003 ;
14004 return 0;
14005 }
14006 _ACEOF
14007 if ac_fn_c_try_link "$LINENO"; then :
14008 ac_cv_lib_krb5_krb5_init_context=yes
14009 else
14010 ac_cv_lib_krb5_krb5_init_context=no
14011 fi
14012 rm -f core conftest.err conftest.$ac_objext \
14013 conftest$ac_exeext conftest.$ac_ext
14014 LIBS=$ac_check_lib_save_LIBS
14015 fi
14016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14017 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14018 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14019 have_krb5=yes
14020 else
14021 have_krb5=no
14022 fi
14023
14024 if test $have_krb5=yes; then
14025 KRB5LIB=-lkrb5
14026 LIBS="$KRB5LIB $LIBS"
14027
14028 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14029
14030 fi
14031 if test "${with_kerberos5}" = no; then
14032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14033 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14034 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14035 $as_echo_n "(cached) " >&6
14036 else
14037 ac_check_lib_save_LIBS=$LIBS
14038 LIBS="-ldes425 $LIBS"
14039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14040 /* end confdefs.h. */
14041
14042 /* Override any GCC internal prototype to avoid an error.
14043 Use char because int might match the return type of a GCC
14044 builtin and then its argument prototype would still apply. */
14045 #ifdef __cplusplus
14046 extern "C"
14047 #endif
14048 char des_cbc_encrypt ();
14049 int
14050 main ()
14051 {
14052 return des_cbc_encrypt ();
14053 ;
14054 return 0;
14055 }
14056 _ACEOF
14057 if ac_fn_c_try_link "$LINENO"; then :
14058 ac_cv_lib_des425_des_cbc_encrypt=yes
14059 else
14060 ac_cv_lib_des425_des_cbc_encrypt=no
14061 fi
14062 rm -f core conftest.err conftest.$ac_objext \
14063 conftest$ac_exeext conftest.$ac_ext
14064 LIBS=$ac_check_lib_save_LIBS
14065 fi
14066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14067 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14068 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14069 have_des425=yes
14070 else
14071 have_des425=no
14072 fi
14073
14074 if test $have_des425 = yes; then
14075 DESLIB=-ldes425
14076 LIBS="$DESLIB $LIBS"
14077
14078 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14079
14080 else
14081 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14082 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14083 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14084 $as_echo_n "(cached) " >&6
14085 else
14086 ac_check_lib_save_LIBS=$LIBS
14087 LIBS="-ldes $LIBS"
14088 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14089 /* end confdefs.h. */
14090
14091 /* Override any GCC internal prototype to avoid an error.
14092 Use char because int might match the return type of a GCC
14093 builtin and then its argument prototype would still apply. */
14094 #ifdef __cplusplus
14095 extern "C"
14096 #endif
14097 char des_cbc_encrypt ();
14098 int
14099 main ()
14100 {
14101 return des_cbc_encrypt ();
14102 ;
14103 return 0;
14104 }
14105 _ACEOF
14106 if ac_fn_c_try_link "$LINENO"; then :
14107 ac_cv_lib_des_des_cbc_encrypt=yes
14108 else
14109 ac_cv_lib_des_des_cbc_encrypt=no
14110 fi
14111 rm -f core conftest.err conftest.$ac_objext \
14112 conftest$ac_exeext conftest.$ac_ext
14113 LIBS=$ac_check_lib_save_LIBS
14114 fi
14115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14116 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14117 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14118 have_des=yes
14119 else
14120 have_des=no
14121 fi
14122
14123 if test $have_des = yes; then
14124 DESLIB=-ldes
14125 LIBS="$DESLIB $LIBS"
14126
14127 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14128
14129 fi
14130 fi
14131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14132 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14133 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14134 $as_echo_n "(cached) " >&6
14135 else
14136 ac_check_lib_save_LIBS=$LIBS
14137 LIBS="-lkrb4 $LIBS"
14138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14139 /* end confdefs.h. */
14140
14141 /* Override any GCC internal prototype to avoid an error.
14142 Use char because int might match the return type of a GCC
14143 builtin and then its argument prototype would still apply. */
14144 #ifdef __cplusplus
14145 extern "C"
14146 #endif
14147 char krb_get_cred ();
14148 int
14149 main ()
14150 {
14151 return krb_get_cred ();
14152 ;
14153 return 0;
14154 }
14155 _ACEOF
14156 if ac_fn_c_try_link "$LINENO"; then :
14157 ac_cv_lib_krb4_krb_get_cred=yes
14158 else
14159 ac_cv_lib_krb4_krb_get_cred=no
14160 fi
14161 rm -f core conftest.err conftest.$ac_objext \
14162 conftest$ac_exeext conftest.$ac_ext
14163 LIBS=$ac_check_lib_save_LIBS
14164 fi
14165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14166 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14167 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14168 have_krb4=yes
14169 else
14170 have_krb4=no
14171 fi
14172
14173 if test $have_krb4 = yes; then
14174 KRB4LIB=-lkrb4
14175 LIBS="$KRB4LIB $LIBS"
14176
14177 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14178
14179 else
14180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14181 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14182 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14183 $as_echo_n "(cached) " >&6
14184 else
14185 ac_check_lib_save_LIBS=$LIBS
14186 LIBS="-lkrb $LIBS"
14187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14188 /* end confdefs.h. */
14189
14190 /* Override any GCC internal prototype to avoid an error.
14191 Use char because int might match the return type of a GCC
14192 builtin and then its argument prototype would still apply. */
14193 #ifdef __cplusplus
14194 extern "C"
14195 #endif
14196 char krb_get_cred ();
14197 int
14198 main ()
14199 {
14200 return krb_get_cred ();
14201 ;
14202 return 0;
14203 }
14204 _ACEOF
14205 if ac_fn_c_try_link "$LINENO"; then :
14206 ac_cv_lib_krb_krb_get_cred=yes
14207 else
14208 ac_cv_lib_krb_krb_get_cred=no
14209 fi
14210 rm -f core conftest.err conftest.$ac_objext \
14211 conftest$ac_exeext conftest.$ac_ext
14212 LIBS=$ac_check_lib_save_LIBS
14213 fi
14214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14215 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14216 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14217 have_krb=yes
14218 else
14219 have_krb=no
14220 fi
14221
14222 if test $have_krb = yes; then
14223 KRB4LIB=-lkrb
14224 LIBS="$KRB4LIB $LIBS"
14225
14226 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14227
14228 fi
14229 fi
14230 fi
14231
14232 if test "${with_kerberos5}" != no; then
14233 for ac_header in krb5.h
14234 do :
14235 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14236 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14237 cat >>confdefs.h <<_ACEOF
14238 #define HAVE_KRB5_H 1
14239 _ACEOF
14240 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14241 "
14242 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14243
14244 cat >>confdefs.h <<_ACEOF
14245 #define HAVE_KRB5_ERROR_TEXT 1
14246 _ACEOF
14247
14248
14249 fi
14250 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
14251 "
14252 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
14253
14254 cat >>confdefs.h <<_ACEOF
14255 #define HAVE_KRB5_ERROR_E_TEXT 1
14256 _ACEOF
14257
14258
14259 fi
14260
14261 fi
14262
14263 done
14264
14265 else
14266 for ac_header in des.h
14267 do :
14268 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
14269 if test "x$ac_cv_header_des_h" = x""yes; then :
14270 cat >>confdefs.h <<_ACEOF
14271 #define HAVE_DES_H 1
14272 _ACEOF
14273
14274 else
14275 for ac_header in kerberosIV/des.h
14276 do :
14277 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
14278 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
14279 cat >>confdefs.h <<_ACEOF
14280 #define HAVE_KERBEROSIV_DES_H 1
14281 _ACEOF
14282
14283 else
14284 for ac_header in kerberos/des.h
14285 do :
14286 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
14287 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
14288 cat >>confdefs.h <<_ACEOF
14289 #define HAVE_KERBEROS_DES_H 1
14290 _ACEOF
14291
14292 fi
14293
14294 done
14295
14296 fi
14297
14298 done
14299
14300 fi
14301
14302 done
14303
14304 for ac_header in krb.h
14305 do :
14306 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
14307 if test "x$ac_cv_header_krb_h" = x""yes; then :
14308 cat >>confdefs.h <<_ACEOF
14309 #define HAVE_KRB_H 1
14310 _ACEOF
14311
14312 else
14313 for ac_header in kerberosIV/krb.h
14314 do :
14315 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
14316 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
14317 cat >>confdefs.h <<_ACEOF
14318 #define HAVE_KERBEROSIV_KRB_H 1
14319 _ACEOF
14320
14321 else
14322 for ac_header in kerberos/krb.h
14323 do :
14324 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
14325 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
14326 cat >>confdefs.h <<_ACEOF
14327 #define HAVE_KERBEROS_KRB_H 1
14328 _ACEOF
14329
14330 fi
14331
14332 done
14333
14334 fi
14335
14336 done
14337
14338 fi
14339
14340 done
14341
14342 fi
14343 for ac_header in com_err.h
14344 do :
14345 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
14346 if test "x$ac_cv_header_com_err_h" = x""yes; then :
14347 cat >>confdefs.h <<_ACEOF
14348 #define HAVE_COM_ERR_H 1
14349 _ACEOF
14350
14351 fi
14352
14353 done
14354
14355 fi
14356
14357
14358
14359
14360
14361
14362
14363
14364
14365
14366 for ac_func in $ac_func_list
14367 do :
14368 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14369 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14370 eval as_val=\$$as_ac_var
14371 if test "x$as_val" = x""yes; then :
14372 cat >>confdefs.h <<_ACEOF
14373 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14374 _ACEOF
14375
14376 fi
14377 done
14378
14379
14380
14381
14382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
14383 $as_echo_n "checking whether localtime caches TZ... " >&6; }
14384 if test "${emacs_cv_localtime_cache+set}" = set; then :
14385 $as_echo_n "(cached) " >&6
14386 else
14387 if test x$ac_cv_func_tzset = xyes; then
14388 if test "$cross_compiling" = yes; then :
14389 # If we have tzset, assume the worst when cross-compiling.
14390 emacs_cv_localtime_cache=yes
14391 else
14392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14393 /* end confdefs.h. */
14394 #include <time.h>
14395 char TZ_GMT0[] = "TZ=GMT0";
14396 char TZ_PST8[] = "TZ=PST8";
14397 main()
14398 {
14399 time_t now = time ((time_t *) 0);
14400 int hour_GMT0, hour_unset;
14401 if (putenv (TZ_GMT0) != 0)
14402 exit (1);
14403 hour_GMT0 = localtime (&now)->tm_hour;
14404 unsetenv("TZ");
14405 hour_unset = localtime (&now)->tm_hour;
14406 if (putenv (TZ_PST8) != 0)
14407 exit (1);
14408 if (localtime (&now)->tm_hour == hour_GMT0)
14409 exit (1);
14410 unsetenv("TZ");
14411 if (localtime (&now)->tm_hour != hour_unset)
14412 exit (1);
14413 exit (0);
14414 }
14415 _ACEOF
14416 if ac_fn_c_try_run "$LINENO"; then :
14417 emacs_cv_localtime_cache=no
14418 else
14419 emacs_cv_localtime_cache=yes
14420 fi
14421 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14422 conftest.$ac_objext conftest.beam conftest.$ac_ext
14423 fi
14424
14425 else
14426 # If we lack tzset, report that localtime does not cache TZ,
14427 # since we can't invalidate the cache if we don't have tzset.
14428 emacs_cv_localtime_cache=no
14429 fi
14430 fi
14431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
14432 $as_echo "$emacs_cv_localtime_cache" >&6; }
14433 if test $emacs_cv_localtime_cache = yes; then
14434
14435 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
14436
14437 fi
14438
14439 ok_so_far=yes
14440 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
14441 if test "x$ac_cv_func_socket" = x""yes; then :
14442
14443 else
14444 ok_so_far=no
14445 fi
14446
14447 if test $ok_so_far = yes; then
14448 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
14449 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
14450
14451 else
14452 ok_so_far=no
14453 fi
14454
14455
14456 fi
14457 if test $ok_so_far = yes; then
14458 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
14459 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
14460
14461 else
14462 ok_so_far=no
14463 fi
14464
14465
14466 fi
14467 if test $ok_so_far = yes; then
14468
14469 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
14470
14471 fi
14472
14473 if test -f /usr/lpp/X11/bin/smt.exp; then
14474
14475 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
14476
14477 fi
14478
14479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
14480 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
14481 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
14482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14483 $as_echo "yes" >&6; }
14484
14485 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
14486
14487 else
14488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14489 $as_echo "no" >&6; }
14490 fi
14491
14492 case $canonical in
14493 *-solaris2.4 | *-solaris2.4.*)
14494 : ${ac_cv_func_vfork_works=no};;
14495 esac
14496
14497 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
14498 if test "x$ac_cv_type_pid_t" = x""yes; then :
14499
14500 else
14501
14502 cat >>confdefs.h <<_ACEOF
14503 #define pid_t int
14504 _ACEOF
14505
14506 fi
14507
14508 for ac_header in vfork.h
14509 do :
14510 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
14511 if test "x$ac_cv_header_vfork_h" = x""yes; then :
14512 cat >>confdefs.h <<_ACEOF
14513 #define HAVE_VFORK_H 1
14514 _ACEOF
14515
14516 fi
14517
14518 done
14519
14520 for ac_func in fork vfork
14521 do :
14522 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14523 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14524 eval as_val=\$$as_ac_var
14525 if test "x$as_val" = x""yes; then :
14526 cat >>confdefs.h <<_ACEOF
14527 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14528 _ACEOF
14529
14530 fi
14531 done
14532
14533 if test "x$ac_cv_func_fork" = xyes; then
14534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
14535 $as_echo_n "checking for working fork... " >&6; }
14536 if test "${ac_cv_func_fork_works+set}" = set; then :
14537 $as_echo_n "(cached) " >&6
14538 else
14539 if test "$cross_compiling" = yes; then :
14540 ac_cv_func_fork_works=cross
14541 else
14542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14543 /* end confdefs.h. */
14544 $ac_includes_default
14545 int
14546 main ()
14547 {
14548
14549 /* By Ruediger Kuhlmann. */
14550 return fork () < 0;
14551
14552 ;
14553 return 0;
14554 }
14555 _ACEOF
14556 if ac_fn_c_try_run "$LINENO"; then :
14557 ac_cv_func_fork_works=yes
14558 else
14559 ac_cv_func_fork_works=no
14560 fi
14561 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14562 conftest.$ac_objext conftest.beam conftest.$ac_ext
14563 fi
14564
14565 fi
14566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
14567 $as_echo "$ac_cv_func_fork_works" >&6; }
14568
14569 else
14570 ac_cv_func_fork_works=$ac_cv_func_fork
14571 fi
14572 if test "x$ac_cv_func_fork_works" = xcross; then
14573 case $host in
14574 *-*-amigaos* | *-*-msdosdjgpp*)
14575 # Override, as these systems have only a dummy fork() stub
14576 ac_cv_func_fork_works=no
14577 ;;
14578 *)
14579 ac_cv_func_fork_works=yes
14580 ;;
14581 esac
14582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
14583 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
14584 fi
14585 ac_cv_func_vfork_works=$ac_cv_func_vfork
14586 if test "x$ac_cv_func_vfork" = xyes; then
14587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
14588 $as_echo_n "checking for working vfork... " >&6; }
14589 if test "${ac_cv_func_vfork_works+set}" = set; then :
14590 $as_echo_n "(cached) " >&6
14591 else
14592 if test "$cross_compiling" = yes; then :
14593 ac_cv_func_vfork_works=cross
14594 else
14595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14596 /* end confdefs.h. */
14597 /* Thanks to Paul Eggert for this test. */
14598 $ac_includes_default
14599 #include <sys/wait.h>
14600 #ifdef HAVE_VFORK_H
14601 # include <vfork.h>
14602 #endif
14603 /* On some sparc systems, changes by the child to local and incoming
14604 argument registers are propagated back to the parent. The compiler
14605 is told about this with #include <vfork.h>, but some compilers
14606 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
14607 static variable whose address is put into a register that is
14608 clobbered by the vfork. */
14609 static void
14610 #ifdef __cplusplus
14611 sparc_address_test (int arg)
14612 # else
14613 sparc_address_test (arg) int arg;
14614 #endif
14615 {
14616 static pid_t child;
14617 if (!child) {
14618 child = vfork ();
14619 if (child < 0) {
14620 perror ("vfork");
14621 _exit(2);
14622 }
14623 if (!child) {
14624 arg = getpid();
14625 write(-1, "", 0);
14626 _exit (arg);
14627 }
14628 }
14629 }
14630
14631 int
14632 main ()
14633 {
14634 pid_t parent = getpid ();
14635 pid_t child;
14636
14637 sparc_address_test (0);
14638
14639 child = vfork ();
14640
14641 if (child == 0) {
14642 /* Here is another test for sparc vfork register problems. This
14643 test uses lots of local variables, at least as many local
14644 variables as main has allocated so far including compiler
14645 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
14646 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
14647 reuse the register of parent for one of the local variables,
14648 since it will think that parent can't possibly be used any more
14649 in this routine. Assigning to the local variable will thus
14650 munge parent in the parent process. */
14651 pid_t
14652 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
14653 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
14654 /* Convince the compiler that p..p7 are live; otherwise, it might
14655 use the same hardware register for all 8 local variables. */
14656 if (p != p1 || p != p2 || p != p3 || p != p4
14657 || p != p5 || p != p6 || p != p7)
14658 _exit(1);
14659
14660 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
14661 from child file descriptors. If the child closes a descriptor
14662 before it execs or exits, this munges the parent's descriptor
14663 as well. Test for this by closing stdout in the child. */
14664 _exit(close(fileno(stdout)) != 0);
14665 } else {
14666 int status;
14667 struct stat st;
14668
14669 while (wait(&status) != child)
14670 ;
14671 return (
14672 /* Was there some problem with vforking? */
14673 child < 0
14674
14675 /* Did the child fail? (This shouldn't happen.) */
14676 || status
14677
14678 /* Did the vfork/compiler bug occur? */
14679 || parent != getpid()
14680
14681 /* Did the file descriptor bug occur? */
14682 || fstat(fileno(stdout), &st) != 0
14683 );
14684 }
14685 }
14686 _ACEOF
14687 if ac_fn_c_try_run "$LINENO"; then :
14688 ac_cv_func_vfork_works=yes
14689 else
14690 ac_cv_func_vfork_works=no
14691 fi
14692 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14693 conftest.$ac_objext conftest.beam conftest.$ac_ext
14694 fi
14695
14696 fi
14697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
14698 $as_echo "$ac_cv_func_vfork_works" >&6; }
14699
14700 fi;
14701 if test "x$ac_cv_func_fork_works" = xcross; then
14702 ac_cv_func_vfork_works=$ac_cv_func_vfork
14703 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
14704 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
14705 fi
14706
14707 if test "x$ac_cv_func_vfork_works" = xyes; then
14708
14709 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
14710
14711 else
14712
14713 $as_echo "#define vfork fork" >>confdefs.h
14714
14715 fi
14716 if test "x$ac_cv_func_fork_works" = xyes; then
14717
14718 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
14719
14720 fi
14721
14722
14723 for ac_func in snprintf
14724 do :
14725 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
14726 if test "x$ac_cv_func_snprintf" = x""yes; then :
14727 cat >>confdefs.h <<_ACEOF
14728 #define HAVE_SNPRINTF 1
14729 _ACEOF
14730
14731 fi
14732 done
14733
14734
14735 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
14736 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
14737 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
14738 $as_echo_n "(cached) " >&6
14739 else
14740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14741 /* end confdefs.h. */
14742 #include <langinfo.h>
14743 int
14744 main ()
14745 {
14746 char* cs = nl_langinfo(CODESET);
14747 ;
14748 return 0;
14749 }
14750 _ACEOF
14751 if ac_fn_c_try_link "$LINENO"; then :
14752 emacs_cv_langinfo_codeset=yes
14753 else
14754 emacs_cv_langinfo_codeset=no
14755 fi
14756 rm -f core conftest.err conftest.$ac_objext \
14757 conftest$ac_exeext conftest.$ac_ext
14758
14759 fi
14760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
14761 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
14762 if test $emacs_cv_langinfo_codeset = yes; then
14763
14764 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
14765
14766 fi
14767
14768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
14769 $as_echo_n "checking for mbstate_t... " >&6; }
14770 if test "${ac_cv_type_mbstate_t+set}" = set; then :
14771 $as_echo_n "(cached) " >&6
14772 else
14773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14774 /* end confdefs.h. */
14775 $ac_includes_default
14776 # include <wchar.h>
14777 int
14778 main ()
14779 {
14780 mbstate_t x; return sizeof x;
14781 ;
14782 return 0;
14783 }
14784 _ACEOF
14785 if ac_fn_c_try_compile "$LINENO"; then :
14786 ac_cv_type_mbstate_t=yes
14787 else
14788 ac_cv_type_mbstate_t=no
14789 fi
14790 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14791 fi
14792 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
14793 $as_echo "$ac_cv_type_mbstate_t" >&6; }
14794 if test $ac_cv_type_mbstate_t = yes; then
14795
14796 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
14797
14798 else
14799
14800 $as_echo "#define mbstate_t int" >>confdefs.h
14801
14802 fi
14803
14804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
14805 $as_echo_n "checking for C restricted array declarations... " >&6; }
14806 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
14807 $as_echo_n "(cached) " >&6
14808 else
14809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14810 /* end confdefs.h. */
14811 void fred (int x[__restrict]);
14812 int
14813 main ()
14814 {
14815
14816 ;
14817 return 0;
14818 }
14819 _ACEOF
14820 if ac_fn_c_try_compile "$LINENO"; then :
14821 emacs_cv_c_restrict_arr=yes
14822 else
14823 emacs_cv_c_restrict_arr=no
14824 fi
14825 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14826 fi
14827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
14828 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
14829 if test "$emacs_cv_c_restrict_arr" = yes; then
14830
14831 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
14832
14833 fi
14834
14835
14836
14837 $as_echo "#define AMPERSAND_FULL_NAME 1" >>confdefs.h
14838
14839
14840
14841 $as_echo "#define CLASH_DETECTION 1" >>confdefs.h
14842
14843
14844 ## Note: PTYs are broken on darwin <6. Use at your own risk.
14845
14846 $as_echo "#define HAVE_PTYS 1" >>confdefs.h
14847
14848
14849
14850 $as_echo "#define HAVE_SOCKETS 1" >>confdefs.h
14851
14852
14853
14854
14855
14856 $as_echo "#define NULL_DEVICE \"/dev/null\"" >>confdefs.h
14857
14858
14859
14860 $as_echo "#define SEPCHAR ':'" >>confdefs.h
14861
14862
14863
14864 $as_echo "#define subprocesses 1" >>confdefs.h
14865
14866
14867
14868 $as_echo "#define USER_FULL_NAME pw->pw_gecos" >>confdefs.h
14869
14870
14871
14872
14873 $as_echo "#define DIRECTORY_SEP '/'" >>confdefs.h
14874
14875
14876
14877
14878
14879 $as_echo "#define IS_DEVICE_SEP(_c_) 0" >>confdefs.h
14880
14881
14882
14883 $as_echo "#define IS_DIRECTORY_SEP(_c_) ((_c_) == DIRECTORY_SEP)" >>confdefs.h
14884
14885
14886
14887 $as_echo "#define IS_ANY_SEP(_c_) (IS_DIRECTORY_SEP (_c_))" >>confdefs.h
14888
14889
14890
14891
14892
14893 case $opsys in
14894 aix4-2)
14895 if test x$ac_cv_lib_Xmu_XmuConvertStandardSelection != xyes; then
14896 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14897
14898 fi
14899 ;;
14900
14901 hpux*)
14902 $as_echo "#define NO_EDITRES 1" >>confdefs.h
14903
14904 ;;
14905 esac
14906
14907
14908 case $opsys in
14909 irix6-5 | sol2* | unixware )
14910
14911 $as_echo "#define NSIG_MINIMUM 32" >>confdefs.h
14912
14913 ;;
14914 esac
14915
14916 emacs_broken_SIGIO=no
14917
14918 case $opsys in
14919 hpux* | irix6-5 | openbsd | sol2* | unixware )
14920 emacs_broken_SIGIO=yes
14921 ;;
14922
14923 aix4-2)
14924
14925 $as_echo "#define BROKEN_GET_CURRENT_DIR_NAME 1" >>confdefs.h
14926
14927 ;;
14928
14929 freebsd)
14930
14931 $as_echo "#define BROKEN_PTY_READ_AFTER_EAGAIN 1" >>confdefs.h
14932
14933 ;;
14934 esac
14935
14936 case $opsys in
14937 gnu-* | sol2-10 )
14938
14939 $as_echo "#define HAVE_PROCFS 1" >>confdefs.h
14940
14941 ;;
14942 esac
14943
14944 case $opsys in
14945 darwin | freebsd | netbsd | openbsd )
14946
14947 $as_echo "#define DONT_REOPEN_PTY 1" >>confdefs.h
14948
14949 ;;
14950 esac
14951
14952 case $opsys in
14953 netbsd | openbsd) sound_device="/dev/audio" ;;
14954 *) sound_device="/dev/dsp" ;;
14955 esac
14956
14957
14958 cat >>confdefs.h <<_ACEOF
14959 #define DEFAULT_SOUND_DEVICE "$sound_device"
14960 _ACEOF
14961
14962
14963
14964 case $opsys in
14965 darwin | gnu-linux | gnu-kfreebsd )
14966
14967 $as_echo "#define INTERRUPT_INPUT 1" >>confdefs.h
14968
14969 ;;
14970 esac
14971
14972
14973 case $opsys in
14974 cygwin|gnu|gnu-linux|gnu-kfreebsd|irix6-5|freebsd|netbsd|openbsd)
14975
14976 $as_echo "#define NARROWPROTO 1" >>confdefs.h
14977
14978 ;;
14979 esac
14980
14981
14982
14983
14984
14985
14986
14987
14988 case $opsys in
14989 aix4-2 )
14990 $as_echo "#define PTY_ITERATION int c; for (c = 0; !c ; c++)" >>confdefs.h
14991
14992 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptc\");" >>confdefs.h
14993
14994 $as_echo "#define PTY_TTY_NAME_SPRINTF strcpy (pty_name, ttyname (fd));" >>confdefs.h
14995
14996 ;;
14997
14998 cygwin )
14999 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15000
15001 $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
15002
15003 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15004
15005 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15006
15007 ;;
15008
15009 darwin )
15010 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15011
15012 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15013
15014 $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
15015
15016 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15017
15018 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15019
15020 ;;
15021
15022 gnu | openbsd )
15023 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15024
15025 ;;
15026
15027 gnu-linux | gnu-kfreebsd | freebsd | netbsd )
15028 if test "x$ac_cv_func_grantpt" = xyes; then
15029
15030 $as_echo "#define UNIX98_PTYS 1" >>confdefs.h
15031
15032 $as_echo "#define PTY_ITERATION int i; for (i = 0; i < 1; i++)" >>confdefs.h
15033
15034 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptyname = 0; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCHLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); if (grantpt (fd) != -1 && unlockpt (fd) != -1) ptyname = ptsname(fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (!ptyname) { close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15035
15036 if test "x$ac_cv_func_posix_openpt" = xyes; then
15037 $as_echo "#define PTY_OPEN fd = posix_openpt (O_RDWR | O_NOCTTY)" >>confdefs.h
15038
15039 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15040
15041 elif test "x$ac_cv_func_getpt" = xyes; then
15042 $as_echo "#define PTY_OPEN fd = getpt ()" >>confdefs.h
15043
15044 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15045
15046 else
15047 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15048
15049 fi
15050 else
15051 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15052
15053 fi
15054 ;;
15055
15056 hpux*)
15057 $as_echo "#define FIRST_PTY_LETTER 'p'" >>confdefs.h
15058
15059 $as_echo "#define PTY_NAME_SPRINTF sprintf (pty_name, \"/dev/ptym/pty%c%x\", c, i);" >>confdefs.h
15060
15061 $as_echo "#define PTY_TTY_NAME_SPRINTF sprintf (pty_name, \"/dev/pty/tty%c%x\", c, i);" >>confdefs.h
15062
15063 ;;
15064
15065 irix6-5 )
15066 $as_echo "#define PTY_ITERATION /**/" >>confdefs.h
15067
15068 $as_echo "#define FIRST_PTY_LETTER 'q'" >>confdefs.h
15069
15070 $as_echo "#define PTY_OPEN { struct sigaction ocstat, cstat; struct stat stb; char * name; sigemptyset(&cstat.sa_mask); cstat.sa_handler = SIG_DFL; cstat.sa_flags = 0; sigaction(SIGCLD, &cstat, &ocstat); name = _getpty (&fd, O_RDWR | O_NDELAY, 0600, 0); sigaction(SIGCLD, &ocstat, (struct sigaction *)0); if (name == 0) return -1; if (fd < 0) return -1; if (fstat (fd, &stb) < 0) return -1; strcpy (pty_name, name); }" >>confdefs.h
15071
15072 $as_echo "#define PTY_NAME_SPRINTF /**/" >>confdefs.h
15073
15074 $as_echo "#define PTY_TTY_NAME_SPRINTF /**/" >>confdefs.h
15075
15076 ;;
15077
15078 sol2* )
15079 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1 || unlockpt (fd) == -1 || !(ptyname = ptsname (fd))) { emacs_close (fd); return -1; } snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15080
15081 ;;
15082
15083 unixware )
15084 $as_echo "#define PTY_TTY_NAME_SPRINTF { char *ptsname (int), *ptyname; int grantpt_result; sigset_t blocked; sigemptyset (&blocked); sigaddset (&blocked, SIGCLD); pthread_sigmask (SIG_BLOCK, &blocked, 0); grantpt_result = grantpt (fd); pthread_sigmask (SIG_UNBLOCK, &blocked, 0); if (grantpt_result == -1) fatal(\"could not grant slave pty\"); if (unlockpt(fd) == -1) fatal(\"could not unlock slave pty\"); if (!(ptyname = ptsname(fd))) fatal (\"could not enable slave pty\"); snprintf (pty_name, sizeof pty_name, \"%s\", ptyname); }" >>confdefs.h
15085
15086 ;;
15087 esac
15088
15089
15090 case $opsys in
15091 sol2* | unixware )
15092 $as_echo "#define FIRST_PTY_LETTER 'z'" >>confdefs.h
15093
15094 $as_echo "#define PTY_NAME_SPRINTF strcpy (pty_name, \"/dev/ptmx\");" >>confdefs.h
15095
15096
15097 $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
15098
15099 ;;
15100 esac
15101
15102
15103
15104
15105 case $opsys in
15106 aix4-2 | cygwin | gnu | irix6-5 | freebsd | netbsd | openbsd )
15107 $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15108
15109 ;;
15110
15111 gnu-linux | gnu-kfreebsd )
15112
15113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for signals via characters" >&5
15114 $as_echo_n "checking for signals via characters... " >&6; }
15115 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15116 /* end confdefs.h. */
15117
15118 #include <linux/version.h>
15119 #if LINUX_VERSION_CODE < 0x20400
15120 # error "Linux version too old"
15121 #endif
15122
15123 int
15124 main ()
15125 {
15126
15127 ;
15128 return 0;
15129 }
15130 _ACEOF
15131 if ac_fn_c_try_cpp "$LINENO"; then :
15132 emacs_signals_via_chars=yes
15133 else
15134 emacs_signals_via_chars=no
15135 fi
15136 rm -f conftest.err conftest.$ac_ext
15137
15138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_signals_via_chars" >&5
15139 $as_echo "$emacs_signals_via_chars" >&6; }
15140 test $emacs_signals_via_chars = yes && $as_echo "#define SIGNALS_VIA_CHARACTERS 1" >>confdefs.h
15141
15142 ;;
15143 esac
15144
15145
15146
15147
15148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C library" >&5
15149 $as_echo_n "checking whether we are using the GNU C library... " >&6; }
15150 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15151 /* end confdefs.h. */
15152
15153 #include <features.h>
15154 #ifndef __GNU_LIBRARY__
15155 # error "this is not the GNU C library"
15156 #endif
15157
15158 int
15159 main ()
15160 {
15161
15162 ;
15163 return 0;
15164 }
15165 _ACEOF
15166 if ac_fn_c_try_cpp "$LINENO"; then :
15167 emacs_glibc=yes
15168 else
15169 emacs_glibc=no
15170 fi
15171 rm -f conftest.err conftest.$ac_ext
15172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_glibc" >&5
15173 $as_echo "$emacs_glibc" >&6; }
15174
15175 if test $emacs_glibc = yes; then
15176
15177 emacs_pending_output=unknown
15178
15179 case $opsys in
15180 gnu | gnu-linux | gnu-kfreebsd )
15181 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of pending output formalism" >&5
15182 $as_echo_n "checking for style of pending output formalism... " >&6; }
15183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15184 /* end confdefs.h. */
15185
15186 #include <stdio.h>
15187 #if !defined (_IO_STDIO_H) && !defined (_STDIO_USES_IOSTREAM)
15188 # error "stdio definitions not found"
15189 #endif
15190
15191 int
15192 main ()
15193 {
15194
15195 ;
15196 return 0;
15197 }
15198 _ACEOF
15199 if ac_fn_c_try_cpp "$LINENO"; then :
15200 emacs_pending_output=new
15201 fi
15202 rm -f conftest.err conftest.$ac_ext
15203
15204 if test $emacs_pending_output = unknown; then
15205 case $opsys in
15206 gnu-linux | gnu-kfreebsd)
15207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15208 /* end confdefs.h. */
15209
15210 #include <stdio.h>
15211 #ifndef __UCLIBC__
15212 # error "not using uclibc"
15213 #endif
15214
15215 int
15216 main ()
15217 {
15218
15219 ;
15220 return 0;
15221 }
15222 _ACEOF
15223 if ac_fn_c_try_cpp "$LINENO"; then :
15224 emacs_pending_output=uclibc
15225 else
15226 emacs_pending_output=old
15227 fi
15228 rm -f conftest.err conftest.$ac_ext
15229 ;;
15230 esac
15231 fi
15232
15233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_pending_output" >&5
15234 $as_echo "$emacs_pending_output" >&6; }
15235
15236 case $emacs_pending_output in
15237 new)
15238 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_IO_write_ptr - (FILE)->_IO_write_base)" >>confdefs.h
15239
15240 ;;
15241 uclibc)
15242 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufpos - (FILE)->__bufstart)" >>confdefs.h
15243
15244 ;;
15245 old)
15246 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_pptr - (FILE)->_pbase)" >>confdefs.h
15247
15248 ;;
15249 esac
15250 ;;
15251 esac
15252 if test $emacs_pending_output = unknown; then
15253 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__bufp - (FILE)->__buffer)" >>confdefs.h
15254
15255 fi
15256
15257 else
15258 case $opsys in
15259 cygwin | darwin | freebsd | netbsd | openbsd )
15260 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_p - (FILE)->_bf._base)" >>confdefs.h
15261
15262 ;;
15263
15264 unixware)
15265 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->__ptr - (FILE)->__base)" >>confdefs.h
15266
15267 ;;
15268
15269 *)
15270 if test x$ac_cv_header_stdio_ext_h = xyes && \
15271 test x$ac_cv_func___fpending = xyes; then
15272 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) __fpending (FILE)" >>confdefs.h
15273
15274
15275 $as_echo "#define DISPNEW_NEEDS_STDIO_EXT 1" >>confdefs.h
15276
15277 else
15278 $as_echo "#define PENDING_OUTPUT_COUNT(FILE) ((FILE)->_ptr - (FILE)->_base)" >>confdefs.h
15279
15280 fi
15281 ;;
15282 esac
15283 fi
15284
15285
15286
15287
15288 case $opsys in
15289 gnu)
15290 $as_echo "#define DATA_START ({ extern int data_start; (char *) &data_start; })" >>confdefs.h
15291
15292 ;;
15293
15294 hpux*)
15295 $as_echo "#define DATA_START 0x40000000" >>confdefs.h
15296
15297 $as_echo "#define DATA_SEG_BITS 0x40000000" >>confdefs.h
15298
15299 ;;
15300 irix6-5)
15301 $as_echo "#define DATA_START 0x10000000" >>confdefs.h
15302
15303 $as_echo "#define DATA_SEG_BITS 0x10000000" >>confdefs.h
15304
15305 ;;
15306 esac
15307
15308
15309
15310
15311
15312 case $opsys in
15313 darwin) $as_echo "#define TAB3 OXTABS" >>confdefs.h
15314 ;;
15315
15316 gnu | freebsd | netbsd | openbsd )
15317
15318 $as_echo "#define TABDLY OXTABS" >>confdefs.h
15319
15320 $as_echo "#define TAB3 OXTABS" >>confdefs.h
15321
15322 ;;
15323
15324 gnu-linux | gnu-kfreebsd )
15325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15326 /* end confdefs.h. */
15327
15328 #ifndef __i386__
15329 # error "not i386"
15330 #endif
15331
15332 int
15333 main ()
15334 {
15335
15336 ;
15337 return 0;
15338 }
15339 _ACEOF
15340 if ac_fn_c_try_cpp "$LINENO"; then :
15341 $as_echo "#define ULIMIT_BREAK_VALUE (32*1024*1024)" >>confdefs.h
15342
15343 fi
15344 rm -f conftest.err conftest.$ac_ext
15345
15346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15347 /* end confdefs.h. */
15348
15349 #ifndef __ia64__
15350 # error "not ia64"
15351 #endif
15352
15353 int
15354 main ()
15355 {
15356
15357 ;
15358 return 0;
15359 }
15360 _ACEOF
15361 if ac_fn_c_try_cpp "$LINENO"; then :
15362
15363 $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
15364
15365 fi
15366 rm -f conftest.err conftest.$ac_ext
15367 ;;
15368
15369 hpux*)
15370
15371 $as_echo "#define RUN_TIME_REMAP 1" >>confdefs.h
15372
15373 ;;
15374
15375 irix6-5)
15376 $as_echo "#define ULIMIT_BREAK_VALUE 0x14000000" >>confdefs.h
15377
15378 ;;
15379 esac
15380
15381
15382
15383
15384
15385
15386
15387 case $opsys in
15388 aix4-2 | hpux* | unixware)
15389 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15390
15391 ;;
15392
15393 gnu-linux | gnu-kfreebsd )
15394 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15395 /* end confdefs.h. */
15396
15397 #if defined __i386__ || defined __sparc__ || defined __mc68000__ \
15398 || defined __alpha__ || defined __mips__ || defined __s390__ \
15399 || defined __arm__ || defined __powerpc__ || defined __amd64__ \
15400 || defined __ia64__ || defined __sh__
15401 /* ok */
15402 #else
15403 # error "setjmp not known to work on this arch"
15404 #endif
15405
15406 int
15407 main ()
15408 {
15409
15410 ;
15411 return 0;
15412 }
15413 _ACEOF
15414 if ac_fn_c_try_cpp "$LINENO"; then :
15415 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15416
15417 else
15418 $as_echo "#define GC_MARK_STACK GC_USE_GCPROS_AS_BEFORE" >>confdefs.h
15419
15420 fi
15421 rm -f conftest.err conftest.$ac_ext
15422 ;;
15423 esac
15424
15425
15426 if test x$GCC = xyes; then
15427 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15428
15429 else
15430 case $opsys in
15431 freebsd | netbsd | openbsd | irix6-5 | sol2* )
15432 $as_echo "#define GC_SETJMP_WORKS 1" >>confdefs.h
15433
15434 ;;
15435 esac
15436 fi
15437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _setjmp" >&5
15438 $as_echo_n "checking for _setjmp... " >&6; }
15439 if test "${emacs_cv_func__setjmp+set}" = set; then :
15440 $as_echo_n "(cached) " >&6
15441 else
15442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15443 /* end confdefs.h. */
15444 #include <setjmp.h>
15445
15446 int
15447 main ()
15448 {
15449 jmp_buf j;
15450 if (! _setjmp (j))
15451 _longjmp (j, 1);
15452 ;
15453 return 0;
15454 }
15455 _ACEOF
15456 if ac_fn_c_try_link "$LINENO"; then :
15457 emacs_cv_func__setjmp=yes
15458 else
15459 emacs_cv_func__setjmp=no
15460 fi
15461 rm -f core conftest.err conftest.$ac_objext \
15462 conftest$ac_exeext conftest.$ac_ext
15463 fi
15464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func__setjmp" >&5
15465 $as_echo "$emacs_cv_func__setjmp" >&6; }
15466 if test $emacs_cv_func__setjmp = yes; then
15467
15468 $as_echo "#define HAVE__SETJMP 1" >>confdefs.h
15469
15470 else
15471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigsetjmp" >&5
15472 $as_echo_n "checking for sigsetjmp... " >&6; }
15473 if test "${emacs_cv_func_sigsetjmp+set}" = set; then :
15474 $as_echo_n "(cached) " >&6
15475 else
15476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15477 /* end confdefs.h. */
15478 #include <setjmp.h>
15479
15480 int
15481 main ()
15482 {
15483 sigjmp_buf j;
15484 if (! sigsetjmp (j, 1))
15485 siglongjmp (j, 1);
15486 ;
15487 return 0;
15488 }
15489 _ACEOF
15490 if ac_fn_c_try_link "$LINENO"; then :
15491 emacs_cv_func_sigsetjmp=yes
15492 else
15493 emacs_cv_func_sigsetjmp=no
15494 fi
15495 rm -f core conftest.err conftest.$ac_objext \
15496 conftest$ac_exeext conftest.$ac_ext
15497 fi
15498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func_sigsetjmp" >&5
15499 $as_echo "$emacs_cv_func_sigsetjmp" >&6; }
15500 if test $emacs_cv_func_sigsetjmp = yes; then
15501
15502 $as_echo "#define HAVE_SIGSETJMP 1" >>confdefs.h
15503
15504 fi
15505 fi
15506
15507 case $opsys in
15508 sol2* | unixware )
15509
15510 $as_echo "#define TIOCSIGSEND TIOCSIGNAL" >>confdefs.h
15511
15512 ;;
15513 esac
15514
15515
15516 case $opsys in
15517 hpux* | sol2* )
15518
15519 $as_echo "#define XOS_NEEDS_TIME_H 1" >>confdefs.h
15520
15521 ;;
15522 esac
15523
15524
15525
15526
15527
15528
15529
15530
15531
15532
15533 case $opsys in
15534 aix4-2)
15535 $as_echo "#define USG /**/" >>confdefs.h
15536
15537 $as_echo "#define USG5 /**/" >>confdefs.h
15538
15539 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15540 /* end confdefs.h. */
15541
15542 #ifndef _AIX
15543 # error "_AIX not defined"
15544 #endif
15545
15546 int
15547 main ()
15548 {
15549
15550 ;
15551 return 0;
15552 }
15553 _ACEOF
15554 if ac_fn_c_try_cpp "$LINENO"; then :
15555
15556 else
15557
15558 $as_echo "#define _AIX /**/" >>confdefs.h
15559
15560 fi
15561 rm -f conftest.err conftest.$ac_ext
15562 ;;
15563
15564 cygwin)
15565
15566 $as_echo "#define CYGWIN 1" >>confdefs.h
15567
15568 ;;
15569
15570 darwin)
15571 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15572
15573 $as_echo "#define BSD_SYSTEM /**/" >>confdefs.h
15574
15575
15576 $as_echo "#define DARWIN_OS /**/" >>confdefs.h
15577
15578 ;;
15579
15580 freebsd)
15581 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15582
15583
15584 $as_echo "#define BSD_SYSTEM_AHB 1" >>confdefs.h
15585
15586 ;;
15587
15588 gnu | netbsd | openbsd )
15589 $as_echo "#define BSD4_2 /**/" >>confdefs.h
15590
15591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15592 /* end confdefs.h. */
15593
15594 #ifndef BSD_SYSTEM
15595 # error "BSD_SYSTEM not defined"
15596 #endif
15597
15598 int
15599 main ()
15600 {
15601
15602 ;
15603 return 0;
15604 }
15605 _ACEOF
15606 if ac_fn_c_try_cpp "$LINENO"; then :
15607
15608 else
15609 $as_echo "#define BSD_SYSTEM 43" >>confdefs.h
15610
15611 fi
15612 rm -f conftest.err conftest.$ac_ext
15613 ;;
15614
15615 gnu-linux | gnu-kfreebsd )
15616 $as_echo "#define USG /**/" >>confdefs.h
15617
15618
15619 $as_echo "#define GNU_LINUX /**/" >>confdefs.h
15620
15621 ;;
15622
15623 hpux*)
15624 $as_echo "#define USG /**/" >>confdefs.h
15625
15626 $as_echo "#define USG5 /**/" >>confdefs.h
15627
15628
15629 $as_echo "#define HPUX /**/" >>confdefs.h
15630
15631 ;;
15632
15633 irix6-5)
15634 $as_echo "#define USG /**/" >>confdefs.h
15635
15636 $as_echo "#define USG5 /**/" >>confdefs.h
15637
15638 $as_echo "#define USG5_4 /**/" >>confdefs.h
15639
15640
15641 $as_echo "#define IRIX6_5 /**/" >>confdefs.h
15642
15643 ;;
15644
15645 sol2*)
15646 $as_echo "#define USG /**/" >>confdefs.h
15647
15648 $as_echo "#define USG5 /**/" >>confdefs.h
15649
15650 $as_echo "#define USG5_4 /**/" >>confdefs.h
15651
15652
15653 $as_echo "#define SOLARIS2 /**/" >>confdefs.h
15654
15655 ;;
15656
15657 unixware)
15658 $as_echo "#define USG /**/" >>confdefs.h
15659
15660 $as_echo "#define USG5 /**/" >>confdefs.h
15661
15662 $as_echo "#define USG5_4 /**/" >>confdefs.h
15663
15664 ;;
15665 esac
15666
15667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable FIONREAD" >&5
15668 $as_echo_n "checking for usable FIONREAD... " >&6; }
15669 if test "${emacs_cv_usable_FIONREAD+set}" = set; then :
15670 $as_echo_n "(cached) " >&6
15671 else
15672 case $opsys in
15673 aix4-2)
15674 emacs_cv_usable_FIONREAD=no
15675 ;;
15676
15677 *)
15678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15679 /* end confdefs.h. */
15680 #include <sys/types.h>
15681 #include <sys/ioctl.h>
15682 #ifdef USG5_4
15683 # include <sys/filio.h>
15684 #endif
15685
15686 int
15687 main ()
15688 {
15689 int foo = ioctl (0, FIONREAD, &foo);
15690 ;
15691 return 0;
15692 }
15693 _ACEOF
15694 if ac_fn_c_try_compile "$LINENO"; then :
15695 emacs_cv_usable_FIONREAD=yes
15696 else
15697 emacs_cv_usable_FIONREAD=no
15698 fi
15699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15700 ;;
15701 esac
15702 fi
15703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_FIONREAD" >&5
15704 $as_echo "$emacs_cv_usable_FIONREAD" >&6; }
15705 if test $emacs_cv_usable_FIONREAD = yes; then
15706
15707 $as_echo "#define USABLE_FIONREAD 1" >>confdefs.h
15708
15709
15710 if test $emacs_broken_SIGIO = no; then
15711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for usable SIGIO" >&5
15712 $as_echo_n "checking for usable SIGIO... " >&6; }
15713 if test "${emacs_cv_usable_SIGIO+set}" = set; then :
15714 $as_echo_n "(cached) " >&6
15715 else
15716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15717 /* end confdefs.h. */
15718 #include <fcntl.h>
15719 #include <signal.h>
15720
15721 int
15722 main ()
15723 {
15724 int foo = SIGIO | F_SETFL | FASYNC;
15725 ;
15726 return 0;
15727 }
15728 _ACEOF
15729 if ac_fn_c_try_compile "$LINENO"; then :
15730 emacs_cv_usable_SIGIO=yes
15731 else
15732 emacs_cv_usable_SIGIO=no
15733 fi
15734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15735 fi
15736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_usable_SIGIO" >&5
15737 $as_echo "$emacs_cv_usable_SIGIO" >&6; }
15738 if test $emacs_cv_usable_SIGIO = yes; then
15739
15740 $as_echo "#define USABLE_SIGIO 1" >>confdefs.h
15741
15742 fi
15743 fi
15744 fi
15745
15746
15747 case $opsys in
15748 cygwin)
15749
15750 $as_echo "#define G_SLICE_ALWAYS_MALLOC 1" >>confdefs.h
15751
15752 ;;
15753
15754 hpux11)
15755
15756 $as_echo "#define USG_SUBTTY_WORKS 1" >>confdefs.h
15757
15758 ;;
15759
15760 irix6-5)
15761
15762 $as_echo "#define PREFER_VSUSP 1" >>confdefs.h
15763
15764
15765 $as_echo "#define SETPGRP_RELEASES_CTTY 1" >>confdefs.h
15766
15767 ;;
15768
15769 sol2-10)
15770
15771 $as_echo "#define _STRUCTURED_PROC 1" >>confdefs.h
15772
15773 ;;
15774 esac
15775
15776 # Set up the CFLAGS for real compilation, so we can substitute it.
15777 CFLAGS="$REAL_CFLAGS"
15778 CPPFLAGS="$REAL_CPPFLAGS"
15779
15780 ## Hack to detect a buggy GCC version.
15781 if test "x$GCC" = xyes \
15782 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15783 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15784 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15785 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15786 fi
15787
15788 version=$PACKAGE_VERSION
15789
15790 copyright="Copyright (C) 2012 Free Software Foundation, Inc."
15791
15792 cat >>confdefs.h <<_ACEOF
15793 #define COPYRIGHT "$copyright"
15794 _ACEOF
15795
15796
15797
15798 ### Specify what sort of things we'll be editing into Makefile and config.h.
15799 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15800
15801
15802 ## Unused?
15803
15804
15805
15806
15807
15808
15809
15810
15811
15812
15813
15814
15815
15816
15817
15818
15819
15820
15821
15822
15823
15824
15825 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15826 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15827 ## end of LIBX_BASE, but nothing ever set it.
15828
15829
15830
15831
15832 ## Used in lwlib/Makefile.in.
15833
15834
15835
15836
15837
15838
15839
15840
15841 if test -n "${term_header}"; then
15842
15843 cat >>confdefs.h <<_ACEOF
15844 #define TERM_HEADER "${term_header}"
15845 _ACEOF
15846
15847 fi
15848
15849
15850 cat >>confdefs.h <<_ACEOF
15851 #define EMACS_CONFIGURATION "${canonical}"
15852 _ACEOF
15853
15854
15855 cat >>confdefs.h <<_ACEOF
15856 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15857 _ACEOF
15858
15859
15860
15861 XMENU_OBJ=
15862 XOBJ=
15863 FONT_OBJ=
15864 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15865
15866 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15867
15868 XMENU_OBJ=xmenu.o
15869 XOBJ="xterm.o xfns.o xselect.o xrdb.o xsmfns.o xsettings.o xgselect.o"
15870 FONT_OBJ=xfont.o
15871 if test "$HAVE_XFT" = "yes"; then
15872 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15873 elif test "$HAVE_FREETYPE" = "yes"; then
15874 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15875 fi
15876
15877 fi
15878
15879
15880
15881
15882 WIDGET_OBJ=
15883 MOTIF_LIBW=
15884 if test "${USE_X_TOOLKIT}" != "none" ; then
15885 WIDGET_OBJ=widget.o
15886
15887 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15888
15889 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15890
15891 $as_echo "#define USE_LUCID 1" >>confdefs.h
15892
15893 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15894
15895 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15896
15897 MOTIF_LIBW=-lXm
15898 case "$opsys" in
15899 gnu-linux)
15900 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15901 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15902 ;;
15903
15904 unixware)
15905 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15906 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15907 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15908 ;;
15909
15910 aix4-2)
15911 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15912 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15913 ;;
15914 esac
15915 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15916 fi
15917 fi
15918
15919
15920 TOOLKIT_LIBW=
15921 case "$USE_X_TOOLKIT" in
15922 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15923 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15924 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15925 esac
15926
15927
15928 if test "$USE_X_TOOLKIT" = "none"; then
15929 LIBXT_OTHER="\$(LIBXSM)"
15930 OLDXMENU_TARGET="really-oldXMenu"
15931 else
15932 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15933 OLDXMENU_TARGET="really-lwlib"
15934 fi
15935
15936
15937 ## The X Menu stuff is present in the X10 distribution, but missing
15938 ## from X11. If we have X10, just use the installed library;
15939 ## otherwise, use our own copy.
15940 if test "${HAVE_X11}" = "yes" ; then
15941
15942 $as_echo "#define HAVE_X11 1" >>confdefs.h
15943
15944
15945 if test "$USE_X_TOOLKIT" = "none"; then
15946 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15947 else
15948 OLDXMENU="\${lwlibdir}/liblw.a"
15949 fi
15950 LIBXMENU="\$(OLDXMENU)"
15951 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15952 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
15953 else
15954 ## For a syntactically valid Makefile; not actually used for anything.
15955 ## See comments in src/Makefile.in.
15956 OLDXMENU=nothing
15957 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15958 if test "${HAVE_X_WINDOWS}" = "yes"; then
15959 LIBXMENU="-lXMenu"
15960 else
15961 LIBXMENU=
15962 fi
15963 LIBX_OTHER=
15964 OLDXMENU_DEPS=
15965 fi
15966
15967 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15968 OLDXMENU_TARGET=
15969 OLDXMENU=nothing
15970 LIBXMENU=
15971 OLDXMENU_DEPS=
15972 fi
15973
15974
15975
15976
15977
15978
15979
15980 if test "${HAVE_MENUS}" = "yes" ; then
15981
15982 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
15983
15984 fi
15985
15986 if test "${GNU_MALLOC}" = "yes" ; then
15987
15988 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
15989
15990 fi
15991
15992 RALLOC_OBJ=
15993 if test "${REL_ALLOC}" = "yes" ; then
15994
15995 $as_echo "#define REL_ALLOC 1" >>confdefs.h
15996
15997
15998 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
15999 fi
16000
16001
16002 if test "$opsys" = "cygwin"; then
16003 CYGWIN_OBJ="sheap.o"
16004 ## Cygwin differs because of its unexec().
16005 PRE_ALLOC_OBJ=
16006 POST_ALLOC_OBJ=lastfile.o
16007 else
16008 CYGWIN_OBJ=
16009 PRE_ALLOC_OBJ=lastfile.o
16010 POST_ALLOC_OBJ=
16011 fi
16012
16013
16014
16015
16016 # Configure gnulib. Although this does not affect CFLAGS or LIBS permanently.
16017 # it temporarily reverts them to their pre-pkg-config values,
16018 # because gnulib needs to work with both src (which uses the
16019 # pkg-config stuff) and lib-src (which does not). For example, gnulib
16020 # may need to determine whether LIB_CLOCK_GETTIME should contain -lrt,
16021 # and it therefore needs to run in an environment where LIBS does not
16022 # already contain -lrt merely because 'pkg-config --libs' printed '-lrt'
16023 # for some package unrelated to lib-src.
16024 SAVE_CFLAGS=$CFLAGS
16025 SAVE_LIBS=$LIBS
16026 CFLAGS=$pre_PKG_CONFIG_CFLAGS
16027 LIBS="$LIB_PTHREAD $pre_PKG_CONFIG_LIBS"
16028
16029
16030
16031
16032
16033
16034
16035
16036
16037
16038
16039 LIBC_FATAL_STDERR_=1
16040 export LIBC_FATAL_STDERR_
16041
16042 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
16043 # for constant arguments. Useless!
16044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
16045 $as_echo_n "checking for working alloca.h... " >&6; }
16046 if test "${ac_cv_working_alloca_h+set}" = set; then :
16047 $as_echo_n "(cached) " >&6
16048 else
16049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16050 /* end confdefs.h. */
16051 #include <alloca.h>
16052 int
16053 main ()
16054 {
16055 char *p = (char *) alloca (2 * sizeof (int));
16056 if (p) return 0;
16057 ;
16058 return 0;
16059 }
16060 _ACEOF
16061 if ac_fn_c_try_link "$LINENO"; then :
16062 ac_cv_working_alloca_h=yes
16063 else
16064 ac_cv_working_alloca_h=no
16065 fi
16066 rm -f core conftest.err conftest.$ac_objext \
16067 conftest$ac_exeext conftest.$ac_ext
16068 fi
16069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
16070 $as_echo "$ac_cv_working_alloca_h" >&6; }
16071 if test $ac_cv_working_alloca_h = yes; then
16072
16073 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
16074
16075 fi
16076
16077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
16078 $as_echo_n "checking for alloca... " >&6; }
16079 if test "${ac_cv_func_alloca_works+set}" = set; then :
16080 $as_echo_n "(cached) " >&6
16081 else
16082 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16083 /* end confdefs.h. */
16084 #ifdef __GNUC__
16085 # define alloca __builtin_alloca
16086 #else
16087 # ifdef _MSC_VER
16088 # include <malloc.h>
16089 # define alloca _alloca
16090 # else
16091 # ifdef HAVE_ALLOCA_H
16092 # include <alloca.h>
16093 # else
16094 # ifdef _AIX
16095 #pragma alloca
16096 # else
16097 # ifndef alloca /* predefined by HP cc +Olibcalls */
16098 char *alloca ();
16099 # endif
16100 # endif
16101 # endif
16102 # endif
16103 #endif
16104
16105 int
16106 main ()
16107 {
16108 char *p = (char *) alloca (1);
16109 if (p) return 0;
16110 ;
16111 return 0;
16112 }
16113 _ACEOF
16114 if ac_fn_c_try_link "$LINENO"; then :
16115 ac_cv_func_alloca_works=yes
16116 else
16117 ac_cv_func_alloca_works=no
16118 fi
16119 rm -f core conftest.err conftest.$ac_objext \
16120 conftest$ac_exeext conftest.$ac_ext
16121 fi
16122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
16123 $as_echo "$ac_cv_func_alloca_works" >&6; }
16124
16125 if test $ac_cv_func_alloca_works = yes; then
16126
16127 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16128
16129 else
16130 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
16131 # that cause trouble. Some versions do not even contain alloca or
16132 # contain a buggy version. If you still want to use their alloca,
16133 # use ar to extract alloca.o from them instead of compiling alloca.c.
16134
16135
16136
16137
16138
16139 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
16140
16141 $as_echo "#define C_ALLOCA 1" >>confdefs.h
16142
16143
16144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether 'alloca.c' needs Cray hooks" >&5
16145 $as_echo_n "checking whether 'alloca.c' needs Cray hooks... " >&6; }
16146 if test "${ac_cv_os_cray+set}" = set; then :
16147 $as_echo_n "(cached) " >&6
16148 else
16149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16150 /* end confdefs.h. */
16151 #if defined CRAY && ! defined CRAY2
16152 webecray
16153 #else
16154 wenotbecray
16155 #endif
16156
16157 _ACEOF
16158 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16159 $EGREP "webecray" >/dev/null 2>&1; then :
16160 ac_cv_os_cray=yes
16161 else
16162 ac_cv_os_cray=no
16163 fi
16164 rm -f conftest*
16165
16166 fi
16167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16168 $as_echo "$ac_cv_os_cray" >&6; }
16169 if test $ac_cv_os_cray = yes; then
16170 for ac_func in _getb67 GETB67 getb67; do
16171 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16172 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16173 eval as_val=\$$as_ac_var
16174 if test "x$as_val" = x""yes; then :
16175
16176 cat >>confdefs.h <<_ACEOF
16177 #define CRAY_STACKSEG_END $ac_func
16178 _ACEOF
16179
16180 break
16181 fi
16182
16183 done
16184 fi
16185
16186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16187 $as_echo_n "checking stack direction for C alloca... " >&6; }
16188 if test "${ac_cv_c_stack_direction+set}" = set; then :
16189 $as_echo_n "(cached) " >&6
16190 else
16191 if test "$cross_compiling" = yes; then :
16192 ac_cv_c_stack_direction=0
16193 else
16194 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16195 /* end confdefs.h. */
16196 $ac_includes_default
16197 int
16198 find_stack_direction (int *addr, int depth)
16199 {
16200 int dir, dummy = 0;
16201 if (! addr)
16202 addr = &dummy;
16203 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16204 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16205 return dir + dummy;
16206 }
16207
16208 int
16209 main (int argc, char **argv)
16210 {
16211 return find_stack_direction (0, argc + !argv + 20) < 0;
16212 }
16213 _ACEOF
16214 if ac_fn_c_try_run "$LINENO"; then :
16215 ac_cv_c_stack_direction=1
16216 else
16217 ac_cv_c_stack_direction=-1
16218 fi
16219 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16220 conftest.$ac_objext conftest.beam conftest.$ac_ext
16221 fi
16222
16223 fi
16224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16225 $as_echo "$ac_cv_c_stack_direction" >&6; }
16226 cat >>confdefs.h <<_ACEOF
16227 #define STACK_DIRECTION $ac_cv_c_stack_direction
16228 _ACEOF
16229
16230
16231 fi
16232
16233
16234
16235
16236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16237 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16238 if test "${ac_cv_c_bigendian+set}" = set; then :
16239 $as_echo_n "(cached) " >&6
16240 else
16241 ac_cv_c_bigendian=unknown
16242 # See if we're dealing with a universal compiler.
16243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16244 /* end confdefs.h. */
16245 #ifndef __APPLE_CC__
16246 not a universal capable compiler
16247 #endif
16248 typedef int dummy;
16249
16250 _ACEOF
16251 if ac_fn_c_try_compile "$LINENO"; then :
16252
16253 # Check for potential -arch flags. It is not universal unless
16254 # there are at least two -arch flags with different values.
16255 ac_arch=
16256 ac_prev=
16257 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16258 if test -n "$ac_prev"; then
16259 case $ac_word in
16260 i?86 | x86_64 | ppc | ppc64)
16261 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16262 ac_arch=$ac_word
16263 else
16264 ac_cv_c_bigendian=universal
16265 break
16266 fi
16267 ;;
16268 esac
16269 ac_prev=
16270 elif test "x$ac_word" = "x-arch"; then
16271 ac_prev=arch
16272 fi
16273 done
16274 fi
16275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16276 if test $ac_cv_c_bigendian = unknown; then
16277 # See if sys/param.h defines the BYTE_ORDER macro.
16278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16279 /* end confdefs.h. */
16280 #include <sys/types.h>
16281 #include <sys/param.h>
16282
16283 int
16284 main ()
16285 {
16286 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16287 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16288 && LITTLE_ENDIAN)
16289 bogus endian macros
16290 #endif
16291
16292 ;
16293 return 0;
16294 }
16295 _ACEOF
16296 if ac_fn_c_try_compile "$LINENO"; then :
16297 # It does; now see whether it defined to BIG_ENDIAN or not.
16298 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16299 /* end confdefs.h. */
16300 #include <sys/types.h>
16301 #include <sys/param.h>
16302
16303 int
16304 main ()
16305 {
16306 #if BYTE_ORDER != BIG_ENDIAN
16307 not big endian
16308 #endif
16309
16310 ;
16311 return 0;
16312 }
16313 _ACEOF
16314 if ac_fn_c_try_compile "$LINENO"; then :
16315 ac_cv_c_bigendian=yes
16316 else
16317 ac_cv_c_bigendian=no
16318 fi
16319 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16320 fi
16321 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16322 fi
16323 if test $ac_cv_c_bigendian = unknown; then
16324 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16326 /* end confdefs.h. */
16327 #include <limits.h>
16328
16329 int
16330 main ()
16331 {
16332 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16333 bogus endian macros
16334 #endif
16335
16336 ;
16337 return 0;
16338 }
16339 _ACEOF
16340 if ac_fn_c_try_compile "$LINENO"; then :
16341 # It does; now see whether it defined to _BIG_ENDIAN or not.
16342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16343 /* end confdefs.h. */
16344 #include <limits.h>
16345
16346 int
16347 main ()
16348 {
16349 #ifndef _BIG_ENDIAN
16350 not big endian
16351 #endif
16352
16353 ;
16354 return 0;
16355 }
16356 _ACEOF
16357 if ac_fn_c_try_compile "$LINENO"; then :
16358 ac_cv_c_bigendian=yes
16359 else
16360 ac_cv_c_bigendian=no
16361 fi
16362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16363 fi
16364 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16365 fi
16366 if test $ac_cv_c_bigendian = unknown; then
16367 # Compile a test program.
16368 if test "$cross_compiling" = yes; then :
16369 # Try to guess by grepping values from an object file.
16370 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16371 /* end confdefs.h. */
16372 short int ascii_mm[] =
16373 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16374 short int ascii_ii[] =
16375 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16376 int use_ascii (int i) {
16377 return ascii_mm[i] + ascii_ii[i];
16378 }
16379 short int ebcdic_ii[] =
16380 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16381 short int ebcdic_mm[] =
16382 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16383 int use_ebcdic (int i) {
16384 return ebcdic_mm[i] + ebcdic_ii[i];
16385 }
16386 extern int foo;
16387
16388 int
16389 main ()
16390 {
16391 return use_ascii (foo) == use_ebcdic (foo);
16392 ;
16393 return 0;
16394 }
16395 _ACEOF
16396 if ac_fn_c_try_compile "$LINENO"; then :
16397 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16398 ac_cv_c_bigendian=yes
16399 fi
16400 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16401 if test "$ac_cv_c_bigendian" = unknown; then
16402 ac_cv_c_bigendian=no
16403 else
16404 # finding both strings is unlikely to happen, but who knows?
16405 ac_cv_c_bigendian=unknown
16406 fi
16407 fi
16408 fi
16409 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16410 else
16411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16412 /* end confdefs.h. */
16413 $ac_includes_default
16414 int
16415 main ()
16416 {
16417
16418 /* Are we little or big endian? From Harbison&Steele. */
16419 union
16420 {
16421 long int l;
16422 char c[sizeof (long int)];
16423 } u;
16424 u.l = 1;
16425 return u.c[sizeof (long int) - 1] == 1;
16426
16427 ;
16428 return 0;
16429 }
16430 _ACEOF
16431 if ac_fn_c_try_run "$LINENO"; then :
16432 ac_cv_c_bigendian=no
16433 else
16434 ac_cv_c_bigendian=yes
16435 fi
16436 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16437 conftest.$ac_objext conftest.beam conftest.$ac_ext
16438 fi
16439
16440 fi
16441 fi
16442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16443 $as_echo "$ac_cv_c_bigendian" >&6; }
16444 case $ac_cv_c_bigendian in #(
16445 yes)
16446 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16447 ;; #(
16448 no)
16449 ;; #(
16450 universal)
16451
16452 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16453
16454 ;; #(
16455 *)
16456 as_fn_error "unknown endianness
16457 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16458 esac
16459
16460
16461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16462 $as_echo_n "checking for inline... " >&6; }
16463 if test "${ac_cv_c_inline+set}" = set; then :
16464 $as_echo_n "(cached) " >&6
16465 else
16466 ac_cv_c_inline=no
16467 for ac_kw in inline __inline__ __inline; do
16468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16469 /* end confdefs.h. */
16470 #ifndef __cplusplus
16471 typedef int foo_t;
16472 static $ac_kw foo_t static_foo () {return 0; }
16473 $ac_kw foo_t foo () {return 0; }
16474 #endif
16475
16476 _ACEOF
16477 if ac_fn_c_try_compile "$LINENO"; then :
16478 ac_cv_c_inline=$ac_kw
16479 fi
16480 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16481 test "$ac_cv_c_inline" != no && break
16482 done
16483
16484 fi
16485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16486 $as_echo "$ac_cv_c_inline" >&6; }
16487
16488 case $ac_cv_c_inline in
16489 inline | yes) ;;
16490 *)
16491 case $ac_cv_c_inline in
16492 no) ac_val=;;
16493 *) ac_val=$ac_cv_c_inline;;
16494 esac
16495 cat >>confdefs.h <<_ACEOF
16496 #ifndef __cplusplus
16497 #define inline $ac_val
16498 #endif
16499 _ACEOF
16500 ;;
16501 esac
16502
16503
16504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16505 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16506 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16507 $as_echo_n "(cached) " >&6
16508 else
16509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16510 /* end confdefs.h. */
16511 /* On HP-UX before 11.23, strtold returns a struct instead of
16512 long double. Reject implementations like that, by requiring
16513 compatibility with the C99 prototype. */
16514 #include <stdlib.h>
16515 static long double (*p) (char const *, char **) = strtold;
16516 static long double
16517 test (char const *nptr, char **endptr)
16518 {
16519 long double r;
16520 r = strtold (nptr, endptr);
16521 return r;
16522 }
16523 int
16524 main ()
16525 {
16526 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16527 ;
16528 return 0;
16529 }
16530 _ACEOF
16531 if ac_fn_c_try_link "$LINENO"; then :
16532 gl_cv_func_c99_strtold=yes
16533 else
16534 gl_cv_func_c99_strtold=no
16535 fi
16536 rm -f core conftest.err conftest.$ac_objext \
16537 conftest$ac_exeext conftest.$ac_ext
16538 fi
16539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16540 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16541 if test $gl_cv_func_c99_strtold = yes; then
16542
16543 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16544
16545 fi
16546
16547
16548 GNULIB_CHDIR=0;
16549 GNULIB_CHOWN=0;
16550 GNULIB_CLOSE=0;
16551 GNULIB_DUP=0;
16552 GNULIB_DUP2=0;
16553 GNULIB_DUP3=0;
16554 GNULIB_ENVIRON=0;
16555 GNULIB_EUIDACCESS=0;
16556 GNULIB_FACCESSAT=0;
16557 GNULIB_FCHDIR=0;
16558 GNULIB_FCHOWNAT=0;
16559 GNULIB_FDATASYNC=0;
16560 GNULIB_FSYNC=0;
16561 GNULIB_FTRUNCATE=0;
16562 GNULIB_GETCWD=0;
16563 GNULIB_GETDOMAINNAME=0;
16564 GNULIB_GETDTABLESIZE=0;
16565 GNULIB_GETGROUPS=0;
16566 GNULIB_GETHOSTNAME=0;
16567 GNULIB_GETLOGIN=0;
16568 GNULIB_GETLOGIN_R=0;
16569 GNULIB_GETPAGESIZE=0;
16570 GNULIB_GETUSERSHELL=0;
16571 GNULIB_GROUP_MEMBER=0;
16572 GNULIB_ISATTY=0;
16573 GNULIB_LCHOWN=0;
16574 GNULIB_LINK=0;
16575 GNULIB_LINKAT=0;
16576 GNULIB_LSEEK=0;
16577 GNULIB_PIPE=0;
16578 GNULIB_PIPE2=0;
16579 GNULIB_PREAD=0;
16580 GNULIB_PWRITE=0;
16581 GNULIB_READ=0;
16582 GNULIB_READLINK=0;
16583 GNULIB_READLINKAT=0;
16584 GNULIB_RMDIR=0;
16585 GNULIB_SETHOSTNAME=0;
16586 GNULIB_SLEEP=0;
16587 GNULIB_SYMLINK=0;
16588 GNULIB_SYMLINKAT=0;
16589 GNULIB_TTYNAME_R=0;
16590 GNULIB_UNISTD_H_NONBLOCKING=0;
16591 GNULIB_UNISTD_H_SIGPIPE=0;
16592 GNULIB_UNLINK=0;
16593 GNULIB_UNLINKAT=0;
16594 GNULIB_USLEEP=0;
16595 GNULIB_WRITE=0;
16596 HAVE_CHOWN=1;
16597 HAVE_DUP2=1;
16598 HAVE_DUP3=1;
16599 HAVE_EUIDACCESS=1;
16600 HAVE_FACCESSAT=1;
16601 HAVE_FCHDIR=1;
16602 HAVE_FCHOWNAT=1;
16603 HAVE_FDATASYNC=1;
16604 HAVE_FSYNC=1;
16605 HAVE_FTRUNCATE=1;
16606 HAVE_GETDTABLESIZE=1;
16607 HAVE_GETGROUPS=1;
16608 HAVE_GETHOSTNAME=1;
16609 HAVE_GETLOGIN=1;
16610 HAVE_GETPAGESIZE=1;
16611 HAVE_GROUP_MEMBER=1;
16612 HAVE_LCHOWN=1;
16613 HAVE_LINK=1;
16614 HAVE_LINKAT=1;
16615 HAVE_PIPE=1;
16616 HAVE_PIPE2=1;
16617 HAVE_PREAD=1;
16618 HAVE_PWRITE=1;
16619 HAVE_READLINK=1;
16620 HAVE_READLINKAT=1;
16621 HAVE_SETHOSTNAME=1;
16622 HAVE_SLEEP=1;
16623 HAVE_SYMLINK=1;
16624 HAVE_SYMLINKAT=1;
16625 HAVE_UNLINKAT=1;
16626 HAVE_USLEEP=1;
16627 HAVE_DECL_ENVIRON=1;
16628 HAVE_DECL_FCHDIR=1;
16629 HAVE_DECL_FDATASYNC=1;
16630 HAVE_DECL_GETDOMAINNAME=1;
16631 HAVE_DECL_GETLOGIN_R=1;
16632 HAVE_DECL_GETPAGESIZE=1;
16633 HAVE_DECL_GETUSERSHELL=1;
16634 HAVE_DECL_SETHOSTNAME=1;
16635 HAVE_DECL_TTYNAME_R=1;
16636 HAVE_OS_H=0;
16637 HAVE_SYS_PARAM_H=0;
16638 REPLACE_CHOWN=0;
16639 REPLACE_CLOSE=0;
16640 REPLACE_DUP=0;
16641 REPLACE_DUP2=0;
16642 REPLACE_FCHOWNAT=0;
16643 REPLACE_FTRUNCATE=0;
16644 REPLACE_GETCWD=0;
16645 REPLACE_GETDOMAINNAME=0;
16646 REPLACE_GETLOGIN_R=0;
16647 REPLACE_GETGROUPS=0;
16648 REPLACE_GETPAGESIZE=0;
16649 REPLACE_ISATTY=0;
16650 REPLACE_LCHOWN=0;
16651 REPLACE_LINK=0;
16652 REPLACE_LINKAT=0;
16653 REPLACE_LSEEK=0;
16654 REPLACE_PREAD=0;
16655 REPLACE_PWRITE=0;
16656 REPLACE_READ=0;
16657 REPLACE_READLINK=0;
16658 REPLACE_RMDIR=0;
16659 REPLACE_SLEEP=0;
16660 REPLACE_SYMLINK=0;
16661 REPLACE_TTYNAME_R=0;
16662 REPLACE_UNLINK=0;
16663 REPLACE_UNLINKAT=0;
16664 REPLACE_USLEEP=0;
16665 REPLACE_WRITE=0;
16666 UNISTD_H_HAVE_WINSOCK2_H=0;
16667 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16668
16669
16670
16671
16672
16673
16674
16675
16676
16677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if environ is properly declared" >&5
16678 $as_echo_n "checking if environ is properly declared... " >&6; }
16679 if test "${gt_cv_var_environ_declaration+set}" = set; then :
16680 $as_echo_n "(cached) " >&6
16681 else
16682
16683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16684 /* end confdefs.h. */
16685 #if HAVE_UNISTD_H
16686 #include <unistd.h>
16687 #endif
16688 /* mingw, BeOS, Haiku declare environ in <stdlib.h>, not in <unistd.h>. */
16689 #include <stdlib.h>
16690
16691 extern struct { int foo; } environ;
16692 int
16693 main ()
16694 {
16695 environ.foo = 1;
16696 ;
16697 return 0;
16698 }
16699 _ACEOF
16700 if ac_fn_c_try_compile "$LINENO"; then :
16701 gt_cv_var_environ_declaration=no
16702 else
16703 gt_cv_var_environ_declaration=yes
16704 fi
16705 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16706 fi
16707
16708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_var_environ_declaration" >&5
16709 $as_echo "$gt_cv_var_environ_declaration" >&6; }
16710 if test $gt_cv_var_environ_declaration = yes; then
16711
16712 $as_echo "#define HAVE_ENVIRON_DECL 1" >>confdefs.h
16713
16714 fi
16715
16716
16717 if test $gt_cv_var_environ_declaration != yes; then
16718 HAVE_DECL_ENVIRON=0
16719 fi
16720
16721
16722
16723
16724
16725
16726
16727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16728 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16729 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16730 $as_echo_n "(cached) " >&6
16731 else
16732 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16733 /* end confdefs.h. */
16734
16735 #include <sys/types.h>
16736 #include <sys/stat.h>
16737 int
16738 main ()
16739 {
16740 struct stat s; s.st_dm_mode;
16741 ;
16742 return 0;
16743 }
16744 _ACEOF
16745 if ac_fn_c_try_compile "$LINENO"; then :
16746 ac_cv_struct_st_dm_mode=yes
16747 else
16748 ac_cv_struct_st_dm_mode=no
16749 fi
16750 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16751 fi
16752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16753 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16754
16755 if test $ac_cv_struct_st_dm_mode = yes; then
16756
16757 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16758
16759 fi
16760
16761
16762 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16763 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16764 ac_have_decl=1
16765 else
16766 ac_have_decl=0
16767 fi
16768
16769 cat >>confdefs.h <<_ACEOF
16770 #define HAVE_DECL_STRMODE $ac_have_decl
16771 _ACEOF
16772
16773
16774 GNULIB__EXIT=0;
16775 GNULIB_ATOLL=0;
16776 GNULIB_CALLOC_POSIX=0;
16777 GNULIB_CANONICALIZE_FILE_NAME=0;
16778 GNULIB_GETLOADAVG=0;
16779 GNULIB_GETSUBOPT=0;
16780 GNULIB_GRANTPT=0;
16781 GNULIB_MALLOC_POSIX=0;
16782 GNULIB_MBTOWC=0;
16783 GNULIB_MKDTEMP=0;
16784 GNULIB_MKOSTEMP=0;
16785 GNULIB_MKOSTEMPS=0;
16786 GNULIB_MKSTEMP=0;
16787 GNULIB_MKSTEMPS=0;
16788 GNULIB_POSIX_OPENPT=0;
16789 GNULIB_PTSNAME=0;
16790 GNULIB_PTSNAME_R=0;
16791 GNULIB_PUTENV=0;
16792 GNULIB_RANDOM=0;
16793 GNULIB_RANDOM_R=0;
16794 GNULIB_REALLOC_POSIX=0;
16795 GNULIB_REALPATH=0;
16796 GNULIB_RPMATCH=0;
16797 GNULIB_SETENV=0;
16798 GNULIB_STRTOD=0;
16799 GNULIB_STRTOLL=0;
16800 GNULIB_STRTOULL=0;
16801 GNULIB_SYSTEM_POSIX=0;
16802 GNULIB_UNLOCKPT=0;
16803 GNULIB_UNSETENV=0;
16804 GNULIB_WCTOMB=0;
16805 HAVE__EXIT=1;
16806 HAVE_ATOLL=1;
16807 HAVE_CANONICALIZE_FILE_NAME=1;
16808 HAVE_DECL_GETLOADAVG=1;
16809 HAVE_GETSUBOPT=1;
16810 HAVE_GRANTPT=1;
16811 HAVE_MKDTEMP=1;
16812 HAVE_MKOSTEMP=1;
16813 HAVE_MKOSTEMPS=1;
16814 HAVE_MKSTEMP=1;
16815 HAVE_MKSTEMPS=1;
16816 HAVE_POSIX_OPENPT=1;
16817 HAVE_PTSNAME=1;
16818 HAVE_PTSNAME_R=1;
16819 HAVE_RANDOM=1;
16820 HAVE_RANDOM_H=1;
16821 HAVE_RANDOM_R=1;
16822 HAVE_REALPATH=1;
16823 HAVE_RPMATCH=1;
16824 HAVE_SETENV=1;
16825 HAVE_DECL_SETENV=1;
16826 HAVE_STRTOD=1;
16827 HAVE_STRTOLL=1;
16828 HAVE_STRTOULL=1;
16829 HAVE_STRUCT_RANDOM_DATA=1;
16830 HAVE_SYS_LOADAVG_H=0;
16831 HAVE_UNLOCKPT=1;
16832 HAVE_DECL_UNSETENV=1;
16833 REPLACE_CALLOC=0;
16834 REPLACE_CANONICALIZE_FILE_NAME=0;
16835 REPLACE_MALLOC=0;
16836 REPLACE_MBTOWC=0;
16837 REPLACE_MKSTEMP=0;
16838 REPLACE_PTSNAME_R=0;
16839 REPLACE_PUTENV=0;
16840 REPLACE_RANDOM_R=0;
16841 REPLACE_REALLOC=0;
16842 REPLACE_REALPATH=0;
16843 REPLACE_SETENV=0;
16844 REPLACE_STRTOD=0;
16845 REPLACE_UNSETENV=0;
16846 REPLACE_WCTOMB=0;
16847
16848
16849
16850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16851 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16852 if test "${gl_cv_have_include_next+set}" = set; then :
16853 $as_echo_n "(cached) " >&6
16854 else
16855 rm -rf conftestd1a conftestd1b conftestd2
16856 mkdir conftestd1a conftestd1b conftestd2
16857 cat <<EOF > conftestd1a/conftest.h
16858 #define DEFINED_IN_CONFTESTD1
16859 #include_next <conftest.h>
16860 #ifdef DEFINED_IN_CONFTESTD2
16861 int foo;
16862 #else
16863 #error "include_next doesn't work"
16864 #endif
16865 EOF
16866 cat <<EOF > conftestd1b/conftest.h
16867 #define DEFINED_IN_CONFTESTD1
16868 #include <stdio.h>
16869 #include_next <conftest.h>
16870 #ifdef DEFINED_IN_CONFTESTD2
16871 int foo;
16872 #else
16873 #error "include_next doesn't work"
16874 #endif
16875 EOF
16876 cat <<EOF > conftestd2/conftest.h
16877 #ifndef DEFINED_IN_CONFTESTD1
16878 #error "include_next test doesn't work"
16879 #endif
16880 #define DEFINED_IN_CONFTESTD2
16881 EOF
16882 gl_save_CPPFLAGS="$CPPFLAGS"
16883 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16885 /* end confdefs.h. */
16886 #include <conftest.h>
16887 _ACEOF
16888 if ac_fn_c_try_compile "$LINENO"; then :
16889 gl_cv_have_include_next=yes
16890 else
16891 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16892 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16893 /* end confdefs.h. */
16894 #include <conftest.h>
16895 _ACEOF
16896 if ac_fn_c_try_compile "$LINENO"; then :
16897 gl_cv_have_include_next=buggy
16898 else
16899 gl_cv_have_include_next=no
16900 fi
16901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16902
16903 fi
16904 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16905 CPPFLAGS="$gl_save_CPPFLAGS"
16906 rm -rf conftestd1a conftestd1b conftestd2
16907
16908 fi
16909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16910 $as_echo "$gl_cv_have_include_next" >&6; }
16911 PRAGMA_SYSTEM_HEADER=
16912 if test $gl_cv_have_include_next = yes; then
16913 INCLUDE_NEXT=include_next
16914 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16915 if test -n "$GCC"; then
16916 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16917 fi
16918 else
16919 if test $gl_cv_have_include_next = buggy; then
16920 INCLUDE_NEXT=include
16921 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16922 else
16923 INCLUDE_NEXT=include
16924 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16925 fi
16926 fi
16927
16928
16929
16930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16931 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16932 if test "${gl_cv_pragma_columns+set}" = set; then :
16933 $as_echo_n "(cached) " >&6
16934 else
16935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16936 /* end confdefs.h. */
16937
16938 #ifdef __TANDEM
16939 choke me
16940 #endif
16941
16942 _ACEOF
16943 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16944 $EGREP "choke me" >/dev/null 2>&1; then :
16945 gl_cv_pragma_columns=yes
16946 else
16947 gl_cv_pragma_columns=no
16948 fi
16949 rm -f conftest*
16950
16951
16952 fi
16953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16954 $as_echo "$gl_cv_pragma_columns" >&6; }
16955 if test $gl_cv_pragma_columns = yes; then
16956 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16957 else
16958 PRAGMA_COLUMNS=
16959 fi
16960
16961
16962
16963
16964
16965
16966
16967
16968
16969
16970
16971
16972
16973
16974
16975
16976
16977 if test $gl_cv_have_include_next = yes; then
16978 gl_cv_next_getopt_h='<'getopt.h'>'
16979 else
16980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16981 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
16982 if test "${gl_cv_next_getopt_h+set}" = set; then :
16983 $as_echo_n "(cached) " >&6
16984 else
16985
16986 if test $ac_cv_header_getopt_h = yes; then
16987
16988
16989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16990 /* end confdefs.h. */
16991 #include <getopt.h>
16992
16993 _ACEOF
16994 case "$host_os" in
16995 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16996 *) gl_absname_cpp="$ac_cpp" ;;
16997 esac
16998
16999 case "$host_os" in
17000 mingw*)
17001 gl_dirsep_regex='[/\\]'
17002 ;;
17003 *)
17004 gl_dirsep_regex='\/'
17005 ;;
17006 esac
17007 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17008
17009 gl_header_literal_regex=`echo 'getopt.h' \
17010 | sed -e "$gl_make_literal_regex_sed"`
17011 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17012 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17013 s|^/[^/]|//&|
17014 p
17015 q
17016 }'
17017 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17018 sed -n "$gl_absolute_header_sed"`'"'
17019 else
17020 gl_cv_next_getopt_h='<'getopt.h'>'
17021 fi
17022
17023
17024 fi
17025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
17026 $as_echo "$gl_cv_next_getopt_h" >&6; }
17027 fi
17028 NEXT_GETOPT_H=$gl_cv_next_getopt_h
17029
17030 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17031 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17032 gl_next_as_first_directive='<'getopt.h'>'
17033 else
17034 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17035 gl_next_as_first_directive=$gl_cv_next_getopt_h
17036 fi
17037 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
17038
17039
17040
17041
17042 if test $ac_cv_header_getopt_h = yes; then
17043 HAVE_GETOPT_H=1
17044 else
17045 HAVE_GETOPT_H=0
17046 fi
17047
17048
17049 gl_replace_getopt=
17050
17051 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17052 for ac_header in getopt.h
17053 do :
17054 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
17055 if test "x$ac_cv_header_getopt_h" = x""yes; then :
17056 cat >>confdefs.h <<_ACEOF
17057 #define HAVE_GETOPT_H 1
17058 _ACEOF
17059
17060 else
17061 gl_replace_getopt=yes
17062 fi
17063
17064 done
17065
17066 fi
17067
17068 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17069 for ac_func in getopt_long_only
17070 do :
17071 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
17072 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
17073 cat >>confdefs.h <<_ACEOF
17074 #define HAVE_GETOPT_LONG_ONLY 1
17075 _ACEOF
17076
17077 else
17078 gl_replace_getopt=yes
17079 fi
17080 done
17081
17082 fi
17083
17084 if test -z "$gl_replace_getopt"; then
17085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
17086 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
17087 if test "${gl_cv_func_getopt_posix+set}" = set; then :
17088 $as_echo_n "(cached) " >&6
17089 else
17090
17091 if test $cross_compiling = no; then
17092 if test "$cross_compiling" = yes; then :
17093 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17094 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17095 as_fn_error "cannot run test program while cross compiling
17096 See \`config.log' for more details." "$LINENO" 5; }
17097 else
17098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17099 /* end confdefs.h. */
17100
17101 #include <unistd.h>
17102 #include <stdlib.h>
17103 #include <string.h>
17104
17105 int
17106 main ()
17107 {
17108 static char program[] = "program";
17109 static char a[] = "-a";
17110 static char foo[] = "foo";
17111 static char bar[] = "bar";
17112 char *argv[] = { program, a, foo, bar, NULL };
17113 int c;
17114
17115 c = getopt (4, argv, "ab");
17116 if (!(c == 'a'))
17117 return 1;
17118 c = getopt (4, argv, "ab");
17119 if (!(c == -1))
17120 return 2;
17121 if (!(optind == 2))
17122 return 3;
17123 return 0;
17124 }
17125
17126 _ACEOF
17127 if ac_fn_c_try_run "$LINENO"; then :
17128 gl_cv_func_getopt_posix=maybe
17129 else
17130 gl_cv_func_getopt_posix=no
17131 fi
17132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17133 conftest.$ac_objext conftest.beam conftest.$ac_ext
17134 fi
17135
17136 if test $gl_cv_func_getopt_posix = maybe; then
17137 if test "$cross_compiling" = yes; then :
17138 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17139 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17140 as_fn_error "cannot run test program while cross compiling
17141 See \`config.log' for more details." "$LINENO" 5; }
17142 else
17143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17144 /* end confdefs.h. */
17145
17146 #include <unistd.h>
17147 #include <stdlib.h>
17148 #include <string.h>
17149
17150 int
17151 main ()
17152 {
17153 static char program[] = "program";
17154 static char donald[] = "donald";
17155 static char p[] = "-p";
17156 static char billy[] = "billy";
17157 static char duck[] = "duck";
17158 static char a[] = "-a";
17159 static char bar[] = "bar";
17160 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
17161 int c;
17162
17163 c = getopt (7, argv, "+abp:q:");
17164 if (!(c == -1))
17165 return 4;
17166 if (!(strcmp (argv[0], "program") == 0))
17167 return 5;
17168 if (!(strcmp (argv[1], "donald") == 0))
17169 return 6;
17170 if (!(strcmp (argv[2], "-p") == 0))
17171 return 7;
17172 if (!(strcmp (argv[3], "billy") == 0))
17173 return 8;
17174 if (!(strcmp (argv[4], "duck") == 0))
17175 return 9;
17176 if (!(strcmp (argv[5], "-a") == 0))
17177 return 10;
17178 if (!(strcmp (argv[6], "bar") == 0))
17179 return 11;
17180 if (!(optind == 1))
17181 return 12;
17182 return 0;
17183 }
17184
17185 _ACEOF
17186 if ac_fn_c_try_run "$LINENO"; then :
17187 gl_cv_func_getopt_posix=maybe
17188 else
17189 gl_cv_func_getopt_posix=no
17190 fi
17191 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17192 conftest.$ac_objext conftest.beam conftest.$ac_ext
17193 fi
17194
17195 fi
17196 if test $gl_cv_func_getopt_posix = maybe; then
17197 if test "$cross_compiling" = yes; then :
17198 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
17199 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
17200 as_fn_error "cannot run test program while cross compiling
17201 See \`config.log' for more details." "$LINENO" 5; }
17202 else
17203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17204 /* end confdefs.h. */
17205
17206 #include <unistd.h>
17207 #include <stdlib.h>
17208 #include <string.h>
17209
17210 int
17211 main ()
17212 {
17213 static char program[] = "program";
17214 static char ab[] = "-ab";
17215 char *argv[3] = { program, ab, NULL };
17216 if (getopt (2, argv, "ab:") != 'a')
17217 return 13;
17218 if (getopt (2, argv, "ab:") != '?')
17219 return 14;
17220 if (optopt != 'b')
17221 return 15;
17222 if (optind != 2)
17223 return 16;
17224 return 0;
17225 }
17226
17227 _ACEOF
17228 if ac_fn_c_try_run "$LINENO"; then :
17229 gl_cv_func_getopt_posix=yes
17230 else
17231 gl_cv_func_getopt_posix=no
17232 fi
17233 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17234 conftest.$ac_objext conftest.beam conftest.$ac_ext
17235 fi
17236
17237 fi
17238 else
17239 case "$host_os" in
17240 darwin* | aix* | mingw*) gl_cv_func_getopt_posix="guessing no";;
17241 *) gl_cv_func_getopt_posix="guessing yes";;
17242 esac
17243 fi
17244
17245 fi
17246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17247 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17248 case "$gl_cv_func_getopt_posix" in
17249 *no) gl_replace_getopt=yes ;;
17250 esac
17251 fi
17252
17253 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17255 $as_echo_n "checking for working GNU getopt function... " >&6; }
17256 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17257 $as_echo_n "(cached) " >&6
17258 else
17259 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17260 # optstring is necessary for programs like m4 that have POSIX-mandated
17261 # semantics for supporting options interspersed with files.
17262 # Also, since getopt_long is a GNU extension, we require optind=0.
17263 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17264 # so take care to revert to the correct (non-)export state.
17265 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17266 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17267 xx) gl_had_POSIXLY_CORRECT=exported ;;
17268 x) gl_had_POSIXLY_CORRECT=yes ;;
17269 *) gl_had_POSIXLY_CORRECT= ;;
17270 esac
17271 POSIXLY_CORRECT=1
17272 export POSIXLY_CORRECT
17273 if test "$cross_compiling" = yes; then :
17274 gl_cv_func_getopt_gnu="guessing no"
17275
17276 else
17277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17278 /* end confdefs.h. */
17279 #include <getopt.h>
17280 #include <stddef.h>
17281 #include <string.h>
17282
17283 #include <stdlib.h>
17284 #if defined __MACH__ && defined __APPLE__
17285 /* Avoid a crash on Mac OS X. */
17286 #include <mach/mach.h>
17287 #include <mach/mach_error.h>
17288 #include <mach/thread_status.h>
17289 #include <mach/exception.h>
17290 #include <mach/task.h>
17291 #include <pthread.h>
17292 /* The exception port on which our thread listens. */
17293 static mach_port_t our_exception_port;
17294 /* The main function of the thread listening for exceptions of type
17295 EXC_BAD_ACCESS. */
17296 static void *
17297 mach_exception_thread (void *arg)
17298 {
17299 /* Buffer for a message to be received. */
17300 struct {
17301 mach_msg_header_t head;
17302 mach_msg_body_t msgh_body;
17303 char data[1024];
17304 } msg;
17305 mach_msg_return_t retval;
17306 /* Wait for a message on the exception port. */
17307 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17308 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17309 if (retval != MACH_MSG_SUCCESS)
17310 abort ();
17311 exit (1);
17312 }
17313 static void
17314 nocrash_init (void)
17315 {
17316 mach_port_t self = mach_task_self ();
17317 /* Allocate a port on which the thread shall listen for exceptions. */
17318 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17319 == KERN_SUCCESS) {
17320 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17321 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17322 MACH_MSG_TYPE_MAKE_SEND)
17323 == KERN_SUCCESS) {
17324 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17325 for us. */
17326 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17327 /* Create the thread listening on the exception port. */
17328 pthread_attr_t attr;
17329 pthread_t thread;
17330 if (pthread_attr_init (&attr) == 0
17331 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17332 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17333 pthread_attr_destroy (&attr);
17334 /* Replace the exception port info for these exceptions with our own.
17335 Note that we replace the exception port for the entire task, not only
17336 for a particular thread. This has the effect that when our exception
17337 port gets the message, the thread specific exception port has already
17338 been asked, and we don't need to bother about it.
17339 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17340 task_set_exception_ports (self, mask, our_exception_port,
17341 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17342 }
17343 }
17344 }
17345 }
17346 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17347 /* Avoid a crash on native Windows. */
17348 #define WIN32_LEAN_AND_MEAN
17349 #include <windows.h>
17350 #include <winerror.h>
17351 static LONG WINAPI
17352 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17353 {
17354 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17355 {
17356 case EXCEPTION_ACCESS_VIOLATION:
17357 case EXCEPTION_IN_PAGE_ERROR:
17358 case EXCEPTION_STACK_OVERFLOW:
17359 case EXCEPTION_GUARD_PAGE:
17360 case EXCEPTION_PRIV_INSTRUCTION:
17361 case EXCEPTION_ILLEGAL_INSTRUCTION:
17362 case EXCEPTION_DATATYPE_MISALIGNMENT:
17363 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17364 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17365 exit (1);
17366 }
17367 return EXCEPTION_CONTINUE_SEARCH;
17368 }
17369 static void
17370 nocrash_init (void)
17371 {
17372 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17373 }
17374 #else
17375 /* Avoid a crash on POSIX systems. */
17376 #include <signal.h>
17377 /* A POSIX signal handler. */
17378 static void
17379 exception_handler (int sig)
17380 {
17381 exit (1);
17382 }
17383 static void
17384 nocrash_init (void)
17385 {
17386 #ifdef SIGSEGV
17387 signal (SIGSEGV, exception_handler);
17388 #endif
17389 #ifdef SIGBUS
17390 signal (SIGBUS, exception_handler);
17391 #endif
17392 }
17393 #endif
17394
17395
17396 int
17397 main ()
17398 {
17399
17400 int result = 0;
17401
17402 nocrash_init();
17403
17404 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17405 and fails on Mac OS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17406 OSF/1 5.1, Solaris 10. */
17407 {
17408 static char conftest[] = "conftest";
17409 static char plus[] = "-+";
17410 char *argv[3] = { conftest, plus, NULL };
17411 opterr = 0;
17412 if (getopt (2, argv, "+a") != '?')
17413 result |= 1;
17414 }
17415 /* This code succeeds on glibc 2.8, mingw,
17416 and fails on Mac OS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17417 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17418 {
17419 static char program[] = "program";
17420 static char p[] = "-p";
17421 static char foo[] = "foo";
17422 static char bar[] = "bar";
17423 char *argv[] = { program, p, foo, bar, NULL };
17424
17425 optind = 1;
17426 if (getopt (4, argv, "p::") != 'p')
17427 result |= 2;
17428 else if (optarg != NULL)
17429 result |= 4;
17430 else if (getopt (4, argv, "p::") != -1)
17431 result |= 6;
17432 else if (optind != 2)
17433 result |= 8;
17434 }
17435 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17436 {
17437 static char program[] = "program";
17438 static char foo[] = "foo";
17439 static char p[] = "-p";
17440 char *argv[] = { program, foo, p, NULL };
17441 optind = 0;
17442 if (getopt (3, argv, "-p") != 1)
17443 result |= 16;
17444 else if (getopt (3, argv, "-p") != 'p')
17445 result |= 16;
17446 }
17447 /* This code fails on glibc 2.11. */
17448 {
17449 static char program[] = "program";
17450 static char b[] = "-b";
17451 static char a[] = "-a";
17452 char *argv[] = { program, b, a, NULL };
17453 optind = opterr = 0;
17454 if (getopt (3, argv, "+:a:b") != 'b')
17455 result |= 32;
17456 else if (getopt (3, argv, "+:a:b") != ':')
17457 result |= 32;
17458 }
17459 /* This code dumps core on glibc 2.14. */
17460 {
17461 static char program[] = "program";
17462 static char w[] = "-W";
17463 static char dummy[] = "dummy";
17464 char *argv[] = { program, w, dummy, NULL };
17465 optind = opterr = 1;
17466 if (getopt (3, argv, "W;") != 'W')
17467 result |= 64;
17468 }
17469 return result;
17470
17471 ;
17472 return 0;
17473 }
17474 _ACEOF
17475 if ac_fn_c_try_run "$LINENO"; then :
17476 gl_cv_func_getopt_gnu=yes
17477 else
17478 gl_cv_func_getopt_gnu=no
17479 fi
17480 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17481 conftest.$ac_objext conftest.beam conftest.$ac_ext
17482 fi
17483
17484 case $gl_had_POSIXLY_CORRECT in
17485 exported) ;;
17486 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17487 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17488 esac
17489
17490 fi
17491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17492 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17493 if test "$gl_cv_func_getopt_gnu" != yes; then
17494 gl_replace_getopt=yes
17495 else
17496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt_long function" >&5
17497 $as_echo_n "checking for working GNU getopt_long function... " >&6; }
17498 if test "${gl_cv_func_getopt_long_gnu+set}" = set; then :
17499 $as_echo_n "(cached) " >&6
17500 else
17501 if test "$cross_compiling" = yes; then :
17502 case "$host_os" in
17503 openbsd*) gl_cv_func_getopt_long_gnu="guessing no";;
17504 *) gl_cv_func_getopt_long_gnu="guessing yes";;
17505 esac
17506
17507 else
17508 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17509 /* end confdefs.h. */
17510 #include <getopt.h>
17511 #include <stddef.h>
17512 #include <string.h>
17513
17514 int
17515 main ()
17516 {
17517 static const struct option long_options[] =
17518 {
17519 { "xtremely-",no_argument, NULL, 1003 },
17520 { "xtra", no_argument, NULL, 1001 },
17521 { "xtreme", no_argument, NULL, 1002 },
17522 { "xtremely", no_argument, NULL, 1003 },
17523 { NULL, 0, NULL, 0 }
17524 };
17525 /* This code fails on OpenBSD 5.0. */
17526 {
17527 static char program[] = "program";
17528 static char xtremel[] = "--xtremel";
17529 char *argv[] = { program, xtremel, NULL };
17530 int option_index;
17531 optind = 1; opterr = 0;
17532 if (getopt_long (2, argv, "", long_options, &option_index) != 1003)
17533 return 1;
17534 }
17535 return 0;
17536
17537 ;
17538 return 0;
17539 }
17540 _ACEOF
17541 if ac_fn_c_try_run "$LINENO"; then :
17542 gl_cv_func_getopt_long_gnu=yes
17543 else
17544 gl_cv_func_getopt_long_gnu=no
17545 fi
17546 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17547 conftest.$ac_objext conftest.beam conftest.$ac_ext
17548 fi
17549
17550
17551 fi
17552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_long_gnu" >&5
17553 $as_echo "$gl_cv_func_getopt_long_gnu" >&6; }
17554 case "$gl_cv_func_getopt_long_gnu" in
17555 *yes) ;;
17556 *) gl_replace_getopt=yes ;;
17557 esac
17558 fi
17559 fi
17560
17561
17562
17563
17564
17565
17566 REPLACE_GETOPT=0
17567 if test -n "$gl_replace_getopt"; then
17568 REPLACE_GETOPT=1
17569 fi
17570
17571 if test $REPLACE_GETOPT = 1; then
17572
17573 GETOPT_H=getopt.h
17574
17575 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17576
17577
17578
17579 fi
17580
17581 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17582 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17583 ac_have_decl=1
17584 else
17585 ac_have_decl=0
17586 fi
17587
17588 cat >>confdefs.h <<_ACEOF
17589 #define HAVE_DECL_GETENV $ac_have_decl
17590 _ACEOF
17591
17592 :
17593
17594
17595
17596
17597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
17598 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
17599 if test "${ac_cv_c_restrict+set}" = set; then :
17600 $as_echo_n "(cached) " >&6
17601 else
17602 ac_cv_c_restrict=no
17603 # The order here caters to the fact that C++ does not require restrict.
17604 for ac_kw in __restrict __restrict__ _Restrict restrict; do
17605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17606 /* end confdefs.h. */
17607 typedef int * int_ptr;
17608 int foo (int_ptr $ac_kw ip) {
17609 return ip[0];
17610 }
17611 int
17612 main ()
17613 {
17614 int s[1];
17615 int * $ac_kw t = s;
17616 t[0] = 0;
17617 return foo(t)
17618 ;
17619 return 0;
17620 }
17621 _ACEOF
17622 if ac_fn_c_try_compile "$LINENO"; then :
17623 ac_cv_c_restrict=$ac_kw
17624 fi
17625 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17626 test "$ac_cv_c_restrict" != no && break
17627 done
17628
17629 fi
17630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
17631 $as_echo "$ac_cv_c_restrict" >&6; }
17632
17633 case $ac_cv_c_restrict in
17634 restrict) ;;
17635 no) $as_echo "#define restrict /**/" >>confdefs.h
17636 ;;
17637 *) cat >>confdefs.h <<_ACEOF
17638 #define restrict $ac_cv_c_restrict
17639 _ACEOF
17640 ;;
17641 esac
17642
17643
17644 GNULIB_GETTIMEOFDAY=0;
17645 HAVE_GETTIMEOFDAY=1;
17646 HAVE_STRUCT_TIMEVAL=1;
17647 HAVE_SYS_TIME_H=1;
17648 REPLACE_GETTIMEOFDAY=0;
17649 REPLACE_STRUCT_TIMEVAL=0;
17650
17651
17652
17653
17654
17655
17656
17657
17658
17659
17660
17661
17662
17663
17664
17665
17666 if test $gl_cv_have_include_next = yes; then
17667 gl_cv_next_sys_time_h='<'sys/time.h'>'
17668 else
17669 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/time.h>" >&5
17670 $as_echo_n "checking absolute name of <sys/time.h>... " >&6; }
17671 if test "${gl_cv_next_sys_time_h+set}" = set; then :
17672 $as_echo_n "(cached) " >&6
17673 else
17674
17675 if test $ac_cv_header_sys_time_h = yes; then
17676
17677
17678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17679 /* end confdefs.h. */
17680 #include <sys/time.h>
17681
17682 _ACEOF
17683 case "$host_os" in
17684 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17685 *) gl_absname_cpp="$ac_cpp" ;;
17686 esac
17687
17688 case "$host_os" in
17689 mingw*)
17690 gl_dirsep_regex='[/\\]'
17691 ;;
17692 *)
17693 gl_dirsep_regex='\/'
17694 ;;
17695 esac
17696 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
17697
17698 gl_header_literal_regex=`echo 'sys/time.h' \
17699 | sed -e "$gl_make_literal_regex_sed"`
17700 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
17701 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
17702 s|^/[^/]|//&|
17703 p
17704 q
17705 }'
17706 gl_cv_next_sys_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17707 sed -n "$gl_absolute_header_sed"`'"'
17708 else
17709 gl_cv_next_sys_time_h='<'sys/time.h'>'
17710 fi
17711
17712
17713 fi
17714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_time_h" >&5
17715 $as_echo "$gl_cv_next_sys_time_h" >&6; }
17716 fi
17717 NEXT_SYS_TIME_H=$gl_cv_next_sys_time_h
17718
17719 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17720 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17721 gl_next_as_first_directive='<'sys/time.h'>'
17722 else
17723 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17724 gl_next_as_first_directive=$gl_cv_next_sys_time_h
17725 fi
17726 NEXT_AS_FIRST_DIRECTIVE_SYS_TIME_H=$gl_next_as_first_directive
17727
17728
17729
17730
17731
17732 if test $ac_cv_header_sys_time_h != yes; then
17733 HAVE_SYS_TIME_H=0
17734 fi
17735
17736
17737
17738
17739
17740 if test $ac_cv_header_sys_socket_h != yes; then
17741 for ac_header in winsock2.h
17742 do :
17743 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
17744 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
17745 cat >>confdefs.h <<_ACEOF
17746 #define HAVE_WINSOCK2_H 1
17747 _ACEOF
17748
17749 fi
17750
17751 done
17752
17753 fi
17754 if test "$ac_cv_header_winsock2_h" = yes; then
17755 HAVE_WINSOCK2_H=1
17756 UNISTD_H_HAVE_WINSOCK2_H=1
17757 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
17758 else
17759 HAVE_WINSOCK2_H=0
17760 fi
17761
17762
17763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
17764 $as_echo_n "checking for struct timeval... " >&6; }
17765 if test "${gl_cv_sys_struct_timeval+set}" = set; then :
17766 $as_echo_n "(cached) " >&6
17767 else
17768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17769 /* end confdefs.h. */
17770 #if HAVE_SYS_TIME_H
17771 #include <sys/time.h>
17772 #endif
17773 #include <time.h>
17774 #if HAVE_WINSOCK2_H
17775 # include <winsock2.h>
17776 #endif
17777
17778 int
17779 main ()
17780 {
17781 static struct timeval x; x.tv_sec = x.tv_usec;
17782 ;
17783 return 0;
17784 }
17785 _ACEOF
17786 if ac_fn_c_try_compile "$LINENO"; then :
17787 gl_cv_sys_struct_timeval=yes
17788 else
17789 gl_cv_sys_struct_timeval=no
17790 fi
17791 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17792
17793 fi
17794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval" >&5
17795 $as_echo "$gl_cv_sys_struct_timeval" >&6; }
17796 if test $gl_cv_sys_struct_timeval != yes; then
17797 HAVE_STRUCT_TIMEVAL=0
17798 else
17799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wide-enough struct timeval.tv_sec member" >&5
17800 $as_echo_n "checking for wide-enough struct timeval.tv_sec member... " >&6; }
17801 if test "${gl_cv_sys_struct_timeval_tv_sec+set}" = set; then :
17802 $as_echo_n "(cached) " >&6
17803 else
17804 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17805 /* end confdefs.h. */
17806 #if HAVE_SYS_TIME_H
17807 #include <sys/time.h>
17808 #endif
17809 #include <time.h>
17810 #if HAVE_WINSOCK2_H
17811 # include <winsock2.h>
17812 #endif
17813
17814 int
17815 main ()
17816 {
17817 static struct timeval x;
17818 typedef int verify_tv_sec_type[
17819 sizeof (time_t) <= sizeof x.tv_sec ? 1 : -1
17820 ];
17821
17822 ;
17823 return 0;
17824 }
17825 _ACEOF
17826 if ac_fn_c_try_compile "$LINENO"; then :
17827 gl_cv_sys_struct_timeval_tv_sec=yes
17828 else
17829 gl_cv_sys_struct_timeval_tv_sec=no
17830 fi
17831 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17832
17833 fi
17834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timeval_tv_sec" >&5
17835 $as_echo "$gl_cv_sys_struct_timeval_tv_sec" >&6; }
17836 if test $gl_cv_sys_struct_timeval_tv_sec != yes; then
17837 REPLACE_STRUCT_TIMEVAL=1
17838 fi
17839 fi
17840
17841
17842
17843
17844
17845
17846
17847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17848 $as_echo_n "checking for unsigned long long int... " >&6; }
17849 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17850 $as_echo_n "(cached) " >&6
17851 else
17852 ac_cv_type_unsigned_long_long_int=yes
17853 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17854 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17855 /* end confdefs.h. */
17856
17857 /* For now, do not test the preprocessor; as of 2007 there are too many
17858 implementations with broken preprocessors. Perhaps this can
17859 be revisited in 2012. In the meantime, code should not expect
17860 #if to work with literals wider than 32 bits. */
17861 /* Test literals. */
17862 long long int ll = 9223372036854775807ll;
17863 long long int nll = -9223372036854775807LL;
17864 unsigned long long int ull = 18446744073709551615ULL;
17865 /* Test constant expressions. */
17866 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17867 ? 1 : -1)];
17868 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17869 ? 1 : -1)];
17870 int i = 63;
17871 int
17872 main ()
17873 {
17874 /* Test availability of runtime routines for shift and division. */
17875 long long int llmax = 9223372036854775807ll;
17876 unsigned long long int ullmax = 18446744073709551615ull;
17877 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17878 | (llmax / ll) | (llmax % ll)
17879 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17880 | (ullmax / ull) | (ullmax % ull));
17881 ;
17882 return 0;
17883 }
17884
17885 _ACEOF
17886 if ac_fn_c_try_link "$LINENO"; then :
17887
17888 else
17889 ac_cv_type_unsigned_long_long_int=no
17890 fi
17891 rm -f core conftest.err conftest.$ac_objext \
17892 conftest$ac_exeext conftest.$ac_ext
17893 fi
17894 fi
17895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17896 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17897 if test $ac_cv_type_unsigned_long_long_int = yes; then
17898
17899 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17900
17901 fi
17902
17903
17904
17905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17906 $as_echo_n "checking for long long int... " >&6; }
17907 if test "${ac_cv_type_long_long_int+set}" = set; then :
17908 $as_echo_n "(cached) " >&6
17909 else
17910 ac_cv_type_long_long_int=yes
17911 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17912 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17913 if test $ac_cv_type_long_long_int = yes; then
17914 if test "$cross_compiling" = yes; then :
17915 :
17916 else
17917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17918 /* end confdefs.h. */
17919 #include <limits.h>
17920 #ifndef LLONG_MAX
17921 # define HALF \
17922 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17923 # define LLONG_MAX (HALF - 1 + HALF)
17924 #endif
17925 int
17926 main ()
17927 {
17928 long long int n = 1;
17929 int i;
17930 for (i = 0; ; i++)
17931 {
17932 long long int m = n << i;
17933 if (m >> i != n)
17934 return 1;
17935 if (LLONG_MAX / 2 < m)
17936 break;
17937 }
17938 return 0;
17939 ;
17940 return 0;
17941 }
17942 _ACEOF
17943 if ac_fn_c_try_run "$LINENO"; then :
17944
17945 else
17946 ac_cv_type_long_long_int=no
17947 fi
17948 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17949 conftest.$ac_objext conftest.beam conftest.$ac_ext
17950 fi
17951
17952 fi
17953 fi
17954 fi
17955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17956 $as_echo "$ac_cv_type_long_long_int" >&6; }
17957 if test $ac_cv_type_long_long_int = yes; then
17958
17959 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
17960
17961 fi
17962
17963
17964
17965
17966
17967
17968 gl_cv_c_multiarch=no
17969 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17970 /* end confdefs.h. */
17971 #ifndef __APPLE_CC__
17972 not a universal capable compiler
17973 #endif
17974 typedef int dummy;
17975
17976 _ACEOF
17977 if ac_fn_c_try_compile "$LINENO"; then :
17978
17979 arch=
17980 prev=
17981 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17982 if test -n "$prev"; then
17983 case $word in
17984 i?86 | x86_64 | ppc | ppc64)
17985 if test -z "$arch" || test "$arch" = "$word"; then
17986 arch="$word"
17987 else
17988 gl_cv_c_multiarch=yes
17989 fi
17990 ;;
17991 esac
17992 prev=
17993 else
17994 if test "x$word" = "x-arch"; then
17995 prev=arch
17996 fi
17997 fi
17998 done
17999
18000 fi
18001 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18002 if test $gl_cv_c_multiarch = yes; then
18003 APPLE_UNIVERSAL_BUILD=1
18004 else
18005 APPLE_UNIVERSAL_BUILD=0
18006 fi
18007
18008
18009
18010
18011
18012 if test $ac_cv_type_long_long_int = yes; then
18013 HAVE_LONG_LONG_INT=1
18014 else
18015 HAVE_LONG_LONG_INT=0
18016 fi
18017
18018
18019 if test $ac_cv_type_unsigned_long_long_int = yes; then
18020 HAVE_UNSIGNED_LONG_LONG_INT=1
18021 else
18022 HAVE_UNSIGNED_LONG_LONG_INT=0
18023 fi
18024
18025
18026
18027 if test $ac_cv_header_wchar_h = yes; then
18028 HAVE_WCHAR_H=1
18029 else
18030 HAVE_WCHAR_H=0
18031 fi
18032
18033
18034 if test $ac_cv_header_inttypes_h = yes; then
18035 HAVE_INTTYPES_H=1
18036 else
18037 HAVE_INTTYPES_H=0
18038 fi
18039
18040
18041 if test $ac_cv_header_sys_types_h = yes; then
18042 HAVE_SYS_TYPES_H=1
18043 else
18044 HAVE_SYS_TYPES_H=0
18045 fi
18046
18047
18048
18049
18050
18051
18052
18053
18054
18055
18056
18057 if test $gl_cv_have_include_next = yes; then
18058 gl_cv_next_stdint_h='<'stdint.h'>'
18059 else
18060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
18061 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
18062 if test "${gl_cv_next_stdint_h+set}" = set; then :
18063 $as_echo_n "(cached) " >&6
18064 else
18065
18066 if test $ac_cv_header_stdint_h = yes; then
18067
18068
18069 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18070 /* end confdefs.h. */
18071 #include <stdint.h>
18072
18073 _ACEOF
18074 case "$host_os" in
18075 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18076 *) gl_absname_cpp="$ac_cpp" ;;
18077 esac
18078
18079 case "$host_os" in
18080 mingw*)
18081 gl_dirsep_regex='[/\\]'
18082 ;;
18083 *)
18084 gl_dirsep_regex='\/'
18085 ;;
18086 esac
18087 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18088
18089 gl_header_literal_regex=`echo 'stdint.h' \
18090 | sed -e "$gl_make_literal_regex_sed"`
18091 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18092 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18093 s|^/[^/]|//&|
18094 p
18095 q
18096 }'
18097 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18098 sed -n "$gl_absolute_header_sed"`'"'
18099 else
18100 gl_cv_next_stdint_h='<'stdint.h'>'
18101 fi
18102
18103
18104 fi
18105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
18106 $as_echo "$gl_cv_next_stdint_h" >&6; }
18107 fi
18108 NEXT_STDINT_H=$gl_cv_next_stdint_h
18109
18110 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18111 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18112 gl_next_as_first_directive='<'stdint.h'>'
18113 else
18114 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18115 gl_next_as_first_directive=$gl_cv_next_stdint_h
18116 fi
18117 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
18118
18119
18120
18121
18122 if test $ac_cv_header_stdint_h = yes; then
18123 HAVE_STDINT_H=1
18124 else
18125 HAVE_STDINT_H=0
18126 fi
18127
18128
18129 if test $ac_cv_header_stdint_h = yes; then
18130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
18131 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
18132 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
18133 $as_echo_n "(cached) " >&6
18134 else
18135 gl_cv_header_working_stdint_h=no
18136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18137 /* end confdefs.h. */
18138
18139
18140 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18141 #include <stdint.h>
18142 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
18143 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
18144 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
18145 #endif
18146
18147
18148 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18149 included before <wchar.h>. */
18150 #include <stddef.h>
18151 #include <signal.h>
18152 #if HAVE_WCHAR_H
18153 # include <stdio.h>
18154 # include <time.h>
18155 # include <wchar.h>
18156 #endif
18157
18158
18159 #ifdef INT8_MAX
18160 int8_t a1 = INT8_MAX;
18161 int8_t a1min = INT8_MIN;
18162 #endif
18163 #ifdef INT16_MAX
18164 int16_t a2 = INT16_MAX;
18165 int16_t a2min = INT16_MIN;
18166 #endif
18167 #ifdef INT32_MAX
18168 int32_t a3 = INT32_MAX;
18169 int32_t a3min = INT32_MIN;
18170 #endif
18171 #ifdef INT64_MAX
18172 int64_t a4 = INT64_MAX;
18173 int64_t a4min = INT64_MIN;
18174 #endif
18175 #ifdef UINT8_MAX
18176 uint8_t b1 = UINT8_MAX;
18177 #else
18178 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
18179 #endif
18180 #ifdef UINT16_MAX
18181 uint16_t b2 = UINT16_MAX;
18182 #endif
18183 #ifdef UINT32_MAX
18184 uint32_t b3 = UINT32_MAX;
18185 #endif
18186 #ifdef UINT64_MAX
18187 uint64_t b4 = UINT64_MAX;
18188 #endif
18189 int_least8_t c1 = INT8_C (0x7f);
18190 int_least8_t c1max = INT_LEAST8_MAX;
18191 int_least8_t c1min = INT_LEAST8_MIN;
18192 int_least16_t c2 = INT16_C (0x7fff);
18193 int_least16_t c2max = INT_LEAST16_MAX;
18194 int_least16_t c2min = INT_LEAST16_MIN;
18195 int_least32_t c3 = INT32_C (0x7fffffff);
18196 int_least32_t c3max = INT_LEAST32_MAX;
18197 int_least32_t c3min = INT_LEAST32_MIN;
18198 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
18199 int_least64_t c4max = INT_LEAST64_MAX;
18200 int_least64_t c4min = INT_LEAST64_MIN;
18201 uint_least8_t d1 = UINT8_C (0xff);
18202 uint_least8_t d1max = UINT_LEAST8_MAX;
18203 uint_least16_t d2 = UINT16_C (0xffff);
18204 uint_least16_t d2max = UINT_LEAST16_MAX;
18205 uint_least32_t d3 = UINT32_C (0xffffffff);
18206 uint_least32_t d3max = UINT_LEAST32_MAX;
18207 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
18208 uint_least64_t d4max = UINT_LEAST64_MAX;
18209 int_fast8_t e1 = INT_FAST8_MAX;
18210 int_fast8_t e1min = INT_FAST8_MIN;
18211 int_fast16_t e2 = INT_FAST16_MAX;
18212 int_fast16_t e2min = INT_FAST16_MIN;
18213 int_fast32_t e3 = INT_FAST32_MAX;
18214 int_fast32_t e3min = INT_FAST32_MIN;
18215 int_fast64_t e4 = INT_FAST64_MAX;
18216 int_fast64_t e4min = INT_FAST64_MIN;
18217 uint_fast8_t f1 = UINT_FAST8_MAX;
18218 uint_fast16_t f2 = UINT_FAST16_MAX;
18219 uint_fast32_t f3 = UINT_FAST32_MAX;
18220 uint_fast64_t f4 = UINT_FAST64_MAX;
18221 #ifdef INTPTR_MAX
18222 intptr_t g = INTPTR_MAX;
18223 intptr_t gmin = INTPTR_MIN;
18224 #endif
18225 #ifdef UINTPTR_MAX
18226 uintptr_t h = UINTPTR_MAX;
18227 #endif
18228 intmax_t i = INTMAX_MAX;
18229 uintmax_t j = UINTMAX_MAX;
18230
18231 #include <limits.h> /* for CHAR_BIT */
18232 #define TYPE_MINIMUM(t) \
18233 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
18234 #define TYPE_MAXIMUM(t) \
18235 ((t) ((t) 0 < (t) -1 \
18236 ? (t) -1 \
18237 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
18238 struct s {
18239 int check_PTRDIFF:
18240 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
18241 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
18242 ? 1 : -1;
18243 /* Detect bug in FreeBSD 6.0 / ia64. */
18244 int check_SIG_ATOMIC:
18245 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
18246 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
18247 ? 1 : -1;
18248 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
18249 int check_WCHAR:
18250 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
18251 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
18252 ? 1 : -1;
18253 /* Detect bug in mingw. */
18254 int check_WINT:
18255 WINT_MIN == TYPE_MINIMUM (wint_t)
18256 && WINT_MAX == TYPE_MAXIMUM (wint_t)
18257 ? 1 : -1;
18258
18259 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
18260 int check_UINT8_C:
18261 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
18262 int check_UINT16_C:
18263 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
18264
18265 /* Detect bugs in OpenBSD 3.9 stdint.h. */
18266 #ifdef UINT8_MAX
18267 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
18268 #endif
18269 #ifdef UINT16_MAX
18270 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
18271 #endif
18272 #ifdef UINT32_MAX
18273 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
18274 #endif
18275 #ifdef UINT64_MAX
18276 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
18277 #endif
18278 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
18279 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
18280 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
18281 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
18282 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
18283 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
18284 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
18285 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
18286 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
18287 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
18288 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
18289 };
18290
18291 int
18292 main ()
18293 {
18294
18295 ;
18296 return 0;
18297 }
18298 _ACEOF
18299 if ac_fn_c_try_compile "$LINENO"; then :
18300 if test "$cross_compiling" = yes; then :
18301 gl_cv_header_working_stdint_h=yes
18302
18303 else
18304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18305 /* end confdefs.h. */
18306
18307
18308 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
18309 #include <stdint.h>
18310
18311
18312 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18313 included before <wchar.h>. */
18314 #include <stddef.h>
18315 #include <signal.h>
18316 #if HAVE_WCHAR_H
18317 # include <stdio.h>
18318 # include <time.h>
18319 # include <wchar.h>
18320 #endif
18321
18322
18323 #include <stdio.h>
18324 #include <string.h>
18325 #define MVAL(macro) MVAL1(macro)
18326 #define MVAL1(expression) #expression
18327 static const char *macro_values[] =
18328 {
18329 #ifdef INT8_MAX
18330 MVAL (INT8_MAX),
18331 #endif
18332 #ifdef INT16_MAX
18333 MVAL (INT16_MAX),
18334 #endif
18335 #ifdef INT32_MAX
18336 MVAL (INT32_MAX),
18337 #endif
18338 #ifdef INT64_MAX
18339 MVAL (INT64_MAX),
18340 #endif
18341 #ifdef UINT8_MAX
18342 MVAL (UINT8_MAX),
18343 #endif
18344 #ifdef UINT16_MAX
18345 MVAL (UINT16_MAX),
18346 #endif
18347 #ifdef UINT32_MAX
18348 MVAL (UINT32_MAX),
18349 #endif
18350 #ifdef UINT64_MAX
18351 MVAL (UINT64_MAX),
18352 #endif
18353 NULL
18354 };
18355
18356 int
18357 main ()
18358 {
18359
18360 const char **mv;
18361 for (mv = macro_values; *mv != NULL; mv++)
18362 {
18363 const char *value = *mv;
18364 /* Test whether it looks like a cast expression. */
18365 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
18366 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
18367 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
18368 || strncmp (value, "((int)"/*)*/, 6) == 0
18369 || strncmp (value, "((signed short)"/*)*/, 15) == 0
18370 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
18371 return mv - macro_values + 1;
18372 }
18373 return 0;
18374
18375 ;
18376 return 0;
18377 }
18378 _ACEOF
18379 if ac_fn_c_try_run "$LINENO"; then :
18380 gl_cv_header_working_stdint_h=yes
18381 fi
18382 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18383 conftest.$ac_objext conftest.beam conftest.$ac_ext
18384 fi
18385
18386
18387 fi
18388 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18389
18390 fi
18391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
18392 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
18393 fi
18394 if test "$gl_cv_header_working_stdint_h" = yes; then
18395 STDINT_H=
18396 else
18397 for ac_header in sys/inttypes.h sys/bitypes.h
18398 do :
18399 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
18400 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
18401 eval as_val=\$$as_ac_Header
18402 if test "x$as_val" = x""yes; then :
18403 cat >>confdefs.h <<_ACEOF
18404 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
18405 _ACEOF
18406
18407 fi
18408
18409 done
18410
18411 if test $ac_cv_header_sys_inttypes_h = yes; then
18412 HAVE_SYS_INTTYPES_H=1
18413 else
18414 HAVE_SYS_INTTYPES_H=0
18415 fi
18416
18417 if test $ac_cv_header_sys_bitypes_h = yes; then
18418 HAVE_SYS_BITYPES_H=1
18419 else
18420 HAVE_SYS_BITYPES_H=0
18421 fi
18422
18423
18424
18425
18426 if test $APPLE_UNIVERSAL_BUILD = 0; then
18427
18428
18429 for gltype in ptrdiff_t size_t ; do
18430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18431 $as_echo_n "checking for bit size of $gltype... " >&6; }
18432 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18433 $as_echo_n "(cached) " >&6
18434 else
18435 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18436 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18437 included before <wchar.h>. */
18438 #include <stddef.h>
18439 #include <signal.h>
18440 #if HAVE_WCHAR_H
18441 # include <stdio.h>
18442 # include <time.h>
18443 # include <wchar.h>
18444 #endif
18445
18446 #include <limits.h>"; then :
18447
18448 else
18449 result=unknown
18450 fi
18451
18452 eval gl_cv_bitsizeof_${gltype}=\$result
18453
18454 fi
18455 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18457 $as_echo "$ac_res" >&6; }
18458 eval result=\$gl_cv_bitsizeof_${gltype}
18459 if test $result = unknown; then
18460 result=0
18461 fi
18462 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18463 cat >>confdefs.h <<_ACEOF
18464 #define BITSIZEOF_${GLTYPE} $result
18465 _ACEOF
18466
18467 eval BITSIZEOF_${GLTYPE}=\$result
18468 done
18469
18470
18471 fi
18472
18473
18474 for gltype in sig_atomic_t wchar_t wint_t ; do
18475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
18476 $as_echo_n "checking for bit size of $gltype... " >&6; }
18477 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
18478 $as_echo_n "(cached) " >&6
18479 else
18480 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
18481 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18482 included before <wchar.h>. */
18483 #include <stddef.h>
18484 #include <signal.h>
18485 #if HAVE_WCHAR_H
18486 # include <stdio.h>
18487 # include <time.h>
18488 # include <wchar.h>
18489 #endif
18490
18491 #include <limits.h>"; then :
18492
18493 else
18494 result=unknown
18495 fi
18496
18497 eval gl_cv_bitsizeof_${gltype}=\$result
18498
18499 fi
18500 eval ac_res=\$gl_cv_bitsizeof_${gltype}
18501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18502 $as_echo "$ac_res" >&6; }
18503 eval result=\$gl_cv_bitsizeof_${gltype}
18504 if test $result = unknown; then
18505 result=0
18506 fi
18507 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18508 cat >>confdefs.h <<_ACEOF
18509 #define BITSIZEOF_${GLTYPE} $result
18510 _ACEOF
18511
18512 eval BITSIZEOF_${GLTYPE}=\$result
18513 done
18514
18515
18516
18517
18518 for gltype in sig_atomic_t wchar_t wint_t ; do
18519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
18520 $as_echo_n "checking whether $gltype is signed... " >&6; }
18521 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
18522 $as_echo_n "(cached) " >&6
18523 else
18524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18525 /* end confdefs.h. */
18526
18527 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18528 included before <wchar.h>. */
18529 #include <stddef.h>
18530 #include <signal.h>
18531 #if HAVE_WCHAR_H
18532 # include <stdio.h>
18533 # include <time.h>
18534 # include <wchar.h>
18535 #endif
18536
18537 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
18538 int
18539 main ()
18540 {
18541
18542 ;
18543 return 0;
18544 }
18545 _ACEOF
18546 if ac_fn_c_try_compile "$LINENO"; then :
18547 result=yes
18548 else
18549 result=no
18550 fi
18551 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18552 eval gl_cv_type_${gltype}_signed=\$result
18553
18554 fi
18555 eval ac_res=\$gl_cv_type_${gltype}_signed
18556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18557 $as_echo "$ac_res" >&6; }
18558 eval result=\$gl_cv_type_${gltype}_signed
18559 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18560 if test "$result" = yes; then
18561 cat >>confdefs.h <<_ACEOF
18562 #define HAVE_SIGNED_${GLTYPE} 1
18563 _ACEOF
18564
18565 eval HAVE_SIGNED_${GLTYPE}=1
18566 else
18567 eval HAVE_SIGNED_${GLTYPE}=0
18568 fi
18569 done
18570
18571
18572 gl_cv_type_ptrdiff_t_signed=yes
18573 gl_cv_type_size_t_signed=no
18574 if test $APPLE_UNIVERSAL_BUILD = 0; then
18575
18576
18577 for gltype in ptrdiff_t size_t ; do
18578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18579 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18580 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18581 $as_echo_n "(cached) " >&6
18582 else
18583 eval gl_cv_type_${gltype}_suffix=no
18584 eval result=\$gl_cv_type_${gltype}_signed
18585 if test "$result" = yes; then
18586 glsufu=
18587 else
18588 glsufu=u
18589 fi
18590 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18591 case $glsuf in
18592 '') gltype1='int';;
18593 l) gltype1='long int';;
18594 ll) gltype1='long long int';;
18595 i64) gltype1='__int64';;
18596 u) gltype1='unsigned int';;
18597 ul) gltype1='unsigned long int';;
18598 ull) gltype1='unsigned long long int';;
18599 ui64)gltype1='unsigned __int64';;
18600 esac
18601 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18602 /* end confdefs.h. */
18603
18604 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18605 included before <wchar.h>. */
18606 #include <stddef.h>
18607 #include <signal.h>
18608 #if HAVE_WCHAR_H
18609 # include <stdio.h>
18610 # include <time.h>
18611 # include <wchar.h>
18612 #endif
18613
18614 extern $gltype foo;
18615 extern $gltype1 foo;
18616 int
18617 main ()
18618 {
18619
18620 ;
18621 return 0;
18622 }
18623 _ACEOF
18624 if ac_fn_c_try_compile "$LINENO"; then :
18625 eval gl_cv_type_${gltype}_suffix=\$glsuf
18626 fi
18627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18628 eval result=\$gl_cv_type_${gltype}_suffix
18629 test "$result" != no && break
18630 done
18631 fi
18632 eval ac_res=\$gl_cv_type_${gltype}_suffix
18633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18634 $as_echo "$ac_res" >&6; }
18635 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18636 eval result=\$gl_cv_type_${gltype}_suffix
18637 test "$result" = no && result=
18638 eval ${GLTYPE}_SUFFIX=\$result
18639 cat >>confdefs.h <<_ACEOF
18640 #define ${GLTYPE}_SUFFIX $result
18641 _ACEOF
18642
18643 done
18644
18645
18646 fi
18647
18648
18649 for gltype in sig_atomic_t wchar_t wint_t ; do
18650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18651 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18652 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18653 $as_echo_n "(cached) " >&6
18654 else
18655 eval gl_cv_type_${gltype}_suffix=no
18656 eval result=\$gl_cv_type_${gltype}_signed
18657 if test "$result" = yes; then
18658 glsufu=
18659 else
18660 glsufu=u
18661 fi
18662 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18663 case $glsuf in
18664 '') gltype1='int';;
18665 l) gltype1='long int';;
18666 ll) gltype1='long long int';;
18667 i64) gltype1='__int64';;
18668 u) gltype1='unsigned int';;
18669 ul) gltype1='unsigned long int';;
18670 ull) gltype1='unsigned long long int';;
18671 ui64)gltype1='unsigned __int64';;
18672 esac
18673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18674 /* end confdefs.h. */
18675
18676 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18677 included before <wchar.h>. */
18678 #include <stddef.h>
18679 #include <signal.h>
18680 #if HAVE_WCHAR_H
18681 # include <stdio.h>
18682 # include <time.h>
18683 # include <wchar.h>
18684 #endif
18685
18686 extern $gltype foo;
18687 extern $gltype1 foo;
18688 int
18689 main ()
18690 {
18691
18692 ;
18693 return 0;
18694 }
18695 _ACEOF
18696 if ac_fn_c_try_compile "$LINENO"; then :
18697 eval gl_cv_type_${gltype}_suffix=\$glsuf
18698 fi
18699 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18700 eval result=\$gl_cv_type_${gltype}_suffix
18701 test "$result" != no && break
18702 done
18703 fi
18704 eval ac_res=\$gl_cv_type_${gltype}_suffix
18705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18706 $as_echo "$ac_res" >&6; }
18707 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18708 eval result=\$gl_cv_type_${gltype}_suffix
18709 test "$result" = no && result=
18710 eval ${GLTYPE}_SUFFIX=\$result
18711 cat >>confdefs.h <<_ACEOF
18712 #define ${GLTYPE}_SUFFIX $result
18713 _ACEOF
18714
18715 done
18716
18717
18718
18719 if test $BITSIZEOF_WINT_T -lt 32; then
18720 BITSIZEOF_WINT_T=32
18721 fi
18722
18723 STDINT_H=stdint.h
18724 fi
18725
18726 if test -n "$STDINT_H"; then
18727 GL_GENERATE_STDINT_H_TRUE=
18728 GL_GENERATE_STDINT_H_FALSE='#'
18729 else
18730 GL_GENERATE_STDINT_H_TRUE='#'
18731 GL_GENERATE_STDINT_H_FALSE=
18732 fi
18733
18734
18735
18736
18737
18738 GNULIB_IMAXABS=0;
18739 GNULIB_IMAXDIV=0;
18740 GNULIB_STRTOIMAX=0;
18741 GNULIB_STRTOUMAX=0;
18742 HAVE_DECL_IMAXABS=1;
18743 HAVE_DECL_IMAXDIV=1;
18744 HAVE_DECL_STRTOIMAX=1;
18745 HAVE_DECL_STRTOUMAX=1;
18746 REPLACE_STRTOIMAX=0;
18747 INT32_MAX_LT_INTMAX_MAX=1;
18748 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18749 PRI_MACROS_BROKEN=0;
18750 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18751 UINT32_MAX_LT_UINTMAX_MAX=1;
18752 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18753
18754
18755
18756
18757
18758
18759
18760
18761
18762
18763
18764
18765
18766
18767
18768 if test $gl_cv_have_include_next = yes; then
18769 gl_cv_next_inttypes_h='<'inttypes.h'>'
18770 else
18771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18772 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18773 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18774 $as_echo_n "(cached) " >&6
18775 else
18776
18777 if test $ac_cv_header_inttypes_h = yes; then
18778
18779
18780 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18781 /* end confdefs.h. */
18782 #include <inttypes.h>
18783
18784 _ACEOF
18785 case "$host_os" in
18786 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18787 *) gl_absname_cpp="$ac_cpp" ;;
18788 esac
18789
18790 case "$host_os" in
18791 mingw*)
18792 gl_dirsep_regex='[/\\]'
18793 ;;
18794 *)
18795 gl_dirsep_regex='\/'
18796 ;;
18797 esac
18798 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
18799
18800 gl_header_literal_regex=`echo 'inttypes.h' \
18801 | sed -e "$gl_make_literal_regex_sed"`
18802 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
18803 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
18804 s|^/[^/]|//&|
18805 p
18806 q
18807 }'
18808 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18809 sed -n "$gl_absolute_header_sed"`'"'
18810 else
18811 gl_cv_next_inttypes_h='<'inttypes.h'>'
18812 fi
18813
18814
18815 fi
18816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18817 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18818 fi
18819 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18820
18821 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18822 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18823 gl_next_as_first_directive='<'inttypes.h'>'
18824 else
18825 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18826 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18827 fi
18828 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18829
18830
18831
18832
18833
18834
18835
18836
18837
18838
18839
18840 case "$host_os" in
18841 mingw*)
18842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for 64-bit off_t" >&5
18843 $as_echo_n "checking for 64-bit off_t... " >&6; }
18844 if test "${gl_cv_type_off_t_64+set}" = set; then :
18845 $as_echo_n "(cached) " >&6
18846 else
18847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18848 /* end confdefs.h. */
18849 #include <sys/types.h>
18850 int verify_off_t_size[sizeof (off_t) >= 8 ? 1 : -1];
18851
18852 int
18853 main ()
18854 {
18855
18856 ;
18857 return 0;
18858 }
18859 _ACEOF
18860 if ac_fn_c_try_compile "$LINENO"; then :
18861 gl_cv_type_off_t_64=yes
18862 else
18863 gl_cv_type_off_t_64=no
18864 fi
18865 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18866
18867 fi
18868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_off_t_64" >&5
18869 $as_echo "$gl_cv_type_off_t_64" >&6; }
18870 if test $gl_cv_type_off_t_64 = no; then
18871 WINDOWS_64_BIT_OFF_T=1
18872 else
18873 WINDOWS_64_BIT_OFF_T=0
18874 fi
18875 WINDOWS_64_BIT_ST_SIZE=1
18876 ;;
18877 *)
18878 WINDOWS_64_BIT_OFF_T=0
18879 WINDOWS_64_BIT_ST_SIZE=0
18880 ;;
18881 esac
18882
18883
18884 GNULIB_FCHMODAT=0;
18885 GNULIB_FSTAT=0;
18886 GNULIB_FSTATAT=0;
18887 GNULIB_FUTIMENS=0;
18888 GNULIB_LCHMOD=0;
18889 GNULIB_LSTAT=0;
18890 GNULIB_MKDIRAT=0;
18891 GNULIB_MKFIFO=0;
18892 GNULIB_MKFIFOAT=0;
18893 GNULIB_MKNOD=0;
18894 GNULIB_MKNODAT=0;
18895 GNULIB_STAT=0;
18896 GNULIB_UTIMENSAT=0;
18897 HAVE_FCHMODAT=1;
18898 HAVE_FSTATAT=1;
18899 HAVE_FUTIMENS=1;
18900 HAVE_LCHMOD=1;
18901 HAVE_LSTAT=1;
18902 HAVE_MKDIRAT=1;
18903 HAVE_MKFIFO=1;
18904 HAVE_MKFIFOAT=1;
18905 HAVE_MKNOD=1;
18906 HAVE_MKNODAT=1;
18907 HAVE_UTIMENSAT=1;
18908 REPLACE_FSTAT=0;
18909 REPLACE_FSTATAT=0;
18910 REPLACE_FUTIMENS=0;
18911 REPLACE_LSTAT=0;
18912 REPLACE_MKDIR=0;
18913 REPLACE_MKFIFO=0;
18914 REPLACE_MKNOD=0;
18915 REPLACE_STAT=0;
18916 REPLACE_UTIMENSAT=0;
18917
18918
18919
18920
18921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18922 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18923 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18924 $as_echo_n "(cached) " >&6
18925 else
18926 rm -f conftest.sym conftest.file
18927 echo >conftest.file
18928 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18929 if test "$cross_compiling" = yes; then :
18930 case "$host_os" in
18931 # Guess yes on glibc systems.
18932 *-gnu*) gl_cv_func_lstat_dereferences_slashed_symlink="guessing yes" ;;
18933 # If we don't know, assume the worst.
18934 *) gl_cv_func_lstat_dereferences_slashed_symlink="guessing no" ;;
18935 esac
18936
18937 else
18938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18939 /* end confdefs.h. */
18940 $ac_includes_default
18941 int
18942 main ()
18943 {
18944 struct stat sbuf;
18945 /* Linux will dereference the symlink and fail, as required by
18946 POSIX. That is better in the sense that it means we will not
18947 have to compile and use the lstat wrapper. */
18948 return lstat ("conftest.sym/", &sbuf) == 0;
18949
18950 ;
18951 return 0;
18952 }
18953 _ACEOF
18954 if ac_fn_c_try_run "$LINENO"; then :
18955 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18956 else
18957 gl_cv_func_lstat_dereferences_slashed_symlink=no
18958 fi
18959 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18960 conftest.$ac_objext conftest.beam conftest.$ac_ext
18961 fi
18962
18963 else
18964 # If the 'ln -s' command failed, then we probably don't even
18965 # have an lstat function.
18966 gl_cv_func_lstat_dereferences_slashed_symlink="guessing no"
18967 fi
18968 rm -f conftest.sym conftest.file
18969
18970 fi
18971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18972 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18973 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
18974 *yes)
18975
18976 cat >>confdefs.h <<_ACEOF
18977 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18978 _ACEOF
18979
18980 ;;
18981 esac
18982
18983
18984 GNULIB_MKTIME=0;
18985 GNULIB_NANOSLEEP=0;
18986 GNULIB_STRPTIME=0;
18987 GNULIB_TIMEGM=0;
18988 GNULIB_TIME_R=0;
18989 HAVE_DECL_LOCALTIME_R=1;
18990 HAVE_NANOSLEEP=1;
18991 HAVE_STRPTIME=1;
18992 HAVE_TIMEGM=1;
18993 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18994 REPLACE_MKTIME=GNULIB_PORTCHECK;
18995 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18996 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18997
18998
18999
19000
19001 GNULIB_PSELECT=0;
19002 GNULIB_SELECT=0;
19003 HAVE_PSELECT=1;
19004 REPLACE_PSELECT=0;
19005 REPLACE_SELECT=0;
19006
19007
19008
19009
19010
19011
19012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
19013 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
19014 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
19015 $as_echo_n "(cached) " >&6
19016 else
19017
19018 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19019 /* end confdefs.h. */
19020 #include <sys/select.h>
19021 int
19022 main ()
19023 {
19024 struct timeval b;
19025 ;
19026 return 0;
19027 }
19028 _ACEOF
19029 if ac_fn_c_try_compile "$LINENO"; then :
19030 gl_cv_header_sys_select_h_selfcontained=yes
19031 else
19032 gl_cv_header_sys_select_h_selfcontained=no
19033 fi
19034 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19035 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
19036 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19037 /* end confdefs.h. */
19038 #include <sys/select.h>
19039 int
19040 main ()
19041 {
19042 int memset; int bzero;
19043 ;
19044 return 0;
19045 }
19046
19047 _ACEOF
19048 if ac_fn_c_try_compile "$LINENO"; then :
19049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19050 /* end confdefs.h. */
19051 #include <sys/select.h>
19052 int
19053 main ()
19054 {
19055
19056 #undef memset
19057 #define memset nonexistent_memset
19058 extern
19059 #ifdef __cplusplus
19060 "C"
19061 #endif
19062 void *memset (void *, int, unsigned long);
19063 #undef bzero
19064 #define bzero nonexistent_bzero
19065 extern
19066 #ifdef __cplusplus
19067 "C"
19068 #endif
19069 void bzero (void *, unsigned long);
19070 fd_set fds;
19071 FD_ZERO (&fds);
19072
19073 ;
19074 return 0;
19075 }
19076
19077 _ACEOF
19078 if ac_fn_c_try_link "$LINENO"; then :
19079
19080 else
19081 gl_cv_header_sys_select_h_selfcontained=no
19082 fi
19083 rm -f core conftest.err conftest.$ac_objext \
19084 conftest$ac_exeext conftest.$ac_ext
19085
19086 fi
19087 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19088 fi
19089
19090 fi
19091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
19092 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
19093
19094
19095
19096
19097
19098
19099
19100
19101
19102 if test $gl_cv_have_include_next = yes; then
19103 gl_cv_next_sys_select_h='<'sys/select.h'>'
19104 else
19105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
19106 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
19107 if test "${gl_cv_next_sys_select_h+set}" = set; then :
19108 $as_echo_n "(cached) " >&6
19109 else
19110
19111 if test $ac_cv_header_sys_select_h = yes; then
19112
19113
19114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19115 /* end confdefs.h. */
19116 #include <sys/select.h>
19117
19118 _ACEOF
19119 case "$host_os" in
19120 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19121 *) gl_absname_cpp="$ac_cpp" ;;
19122 esac
19123
19124 case "$host_os" in
19125 mingw*)
19126 gl_dirsep_regex='[/\\]'
19127 ;;
19128 *)
19129 gl_dirsep_regex='\/'
19130 ;;
19131 esac
19132 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19133
19134 gl_header_literal_regex=`echo 'sys/select.h' \
19135 | sed -e "$gl_make_literal_regex_sed"`
19136 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19137 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19138 s|^/[^/]|//&|
19139 p
19140 q
19141 }'
19142 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19143 sed -n "$gl_absolute_header_sed"`'"'
19144 else
19145 gl_cv_next_sys_select_h='<'sys/select.h'>'
19146 fi
19147
19148
19149 fi
19150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
19151 $as_echo "$gl_cv_next_sys_select_h" >&6; }
19152 fi
19153 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
19154
19155 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19156 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19157 gl_next_as_first_directive='<'sys/select.h'>'
19158 else
19159 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19160 gl_next_as_first_directive=$gl_cv_next_sys_select_h
19161 fi
19162 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
19163
19164
19165
19166
19167 if test $ac_cv_header_sys_select_h = yes; then
19168 HAVE_SYS_SELECT_H=1
19169 else
19170 HAVE_SYS_SELECT_H=0
19171 fi
19172
19173
19174
19175
19176
19177 if test $ac_cv_header_sys_socket_h != yes; then
19178 for ac_header in winsock2.h
19179 do :
19180 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
19181 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
19182 cat >>confdefs.h <<_ACEOF
19183 #define HAVE_WINSOCK2_H 1
19184 _ACEOF
19185
19186 fi
19187
19188 done
19189
19190 fi
19191 if test "$ac_cv_header_winsock2_h" = yes; then
19192 HAVE_WINSOCK2_H=1
19193 UNISTD_H_HAVE_WINSOCK2_H=1
19194 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
19195 else
19196 HAVE_WINSOCK2_H=0
19197 fi
19198
19199
19200
19201
19202
19203
19204
19205
19206 GNULIB_PTHREAD_SIGMASK=0;
19207 GNULIB_RAISE=0;
19208 GNULIB_SIGNAL_H_SIGPIPE=0;
19209 GNULIB_SIGPROCMASK=0;
19210 GNULIB_SIGACTION=0;
19211 HAVE_POSIX_SIGNALBLOCKING=1;
19212 HAVE_PTHREAD_SIGMASK=1;
19213 HAVE_RAISE=1;
19214 HAVE_SIGSET_T=1;
19215 HAVE_SIGINFO_T=1;
19216 HAVE_SIGACTION=1;
19217 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
19218
19219 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
19220
19221 HAVE_SIGHANDLER_T=1;
19222 REPLACE_PTHREAD_SIGMASK=0;
19223 REPLACE_RAISE=0;
19224
19225
19226
19227
19228
19229
19230 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
19231 #include <signal.h>
19232 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
19233 #include <sys/types.h>
19234
19235 "
19236 if test "x$ac_cv_type_sigset_t" = x""yes; then :
19237
19238 cat >>confdefs.h <<_ACEOF
19239 #define HAVE_SIGSET_T 1
19240 _ACEOF
19241
19242 gl_cv_type_sigset_t=yes
19243 else
19244 gl_cv_type_sigset_t=no
19245 fi
19246
19247 if test $gl_cv_type_sigset_t != yes; then
19248 HAVE_SIGSET_T=0
19249 fi
19250
19251
19252
19253 if test $ac_cv_header_sys_socket_h = no; then
19254 for ac_header in ws2tcpip.h
19255 do :
19256 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
19257 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
19258 cat >>confdefs.h <<_ACEOF
19259 #define HAVE_WS2TCPIP_H 1
19260 _ACEOF
19261
19262 fi
19263
19264 done
19265
19266 fi
19267
19268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
19269 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
19270 if test "${ac_cv_header_stdbool_h+set}" = set; then :
19271 $as_echo_n "(cached) " >&6
19272 else
19273 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19274 /* end confdefs.h. */
19275
19276 #include <stdbool.h>
19277 #ifndef bool
19278 "error: bool is not defined"
19279 #endif
19280 #ifndef false
19281 "error: false is not defined"
19282 #endif
19283 #if false
19284 "error: false is not 0"
19285 #endif
19286 #ifndef true
19287 "error: true is not defined"
19288 #endif
19289 #if true != 1
19290 "error: true is not 1"
19291 #endif
19292 #ifndef __bool_true_false_are_defined
19293 "error: __bool_true_false_are_defined is not defined"
19294 #endif
19295
19296 struct s { _Bool s: 1; _Bool t; } s;
19297
19298 char a[true == 1 ? 1 : -1];
19299 char b[false == 0 ? 1 : -1];
19300 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
19301 char d[(bool) 0.5 == true ? 1 : -1];
19302 /* See body of main program for 'e'. */
19303 char f[(_Bool) 0.0 == false ? 1 : -1];
19304 char g[true];
19305 char h[sizeof (_Bool)];
19306 char i[sizeof s.t];
19307 enum { j = false, k = true, l = false * true, m = true * 256 };
19308 /* The following fails for
19309 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
19310 _Bool n[m];
19311 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
19312 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
19313 /* Catch a bug in an HP-UX C compiler. See
19314 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
19315 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
19316 */
19317 _Bool q = true;
19318 _Bool *pq = &q;
19319
19320 int
19321 main ()
19322 {
19323
19324 bool e = &s;
19325 *pq |= q;
19326 *pq |= ! q;
19327 /* Refer to every declared value, to avoid compiler optimizations. */
19328 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
19329 + !m + !n + !o + !p + !q + !pq);
19330
19331 ;
19332 return 0;
19333 }
19334 _ACEOF
19335 if ac_fn_c_try_compile "$LINENO"; then :
19336 ac_cv_header_stdbool_h=yes
19337 else
19338 ac_cv_header_stdbool_h=no
19339 fi
19340 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19341 fi
19342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
19343 $as_echo "$ac_cv_header_stdbool_h" >&6; }
19344 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
19345 if test "x$ac_cv_type__Bool" = x""yes; then :
19346
19347 cat >>confdefs.h <<_ACEOF
19348 #define HAVE__BOOL 1
19349 _ACEOF
19350
19351
19352 fi
19353
19354
19355
19356 REPLACE_NULL=0;
19357 HAVE_WCHAR_T=1;
19358
19359
19360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
19361 $as_echo_n "checking for wchar_t... " >&6; }
19362 if test "${gt_cv_c_wchar_t+set}" = set; then :
19363 $as_echo_n "(cached) " >&6
19364 else
19365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19366 /* end confdefs.h. */
19367 #include <stddef.h>
19368 wchar_t foo = (wchar_t)'\0';
19369 int
19370 main ()
19371 {
19372
19373 ;
19374 return 0;
19375 }
19376 _ACEOF
19377 if ac_fn_c_try_compile "$LINENO"; then :
19378 gt_cv_c_wchar_t=yes
19379 else
19380 gt_cv_c_wchar_t=no
19381 fi
19382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19383 fi
19384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
19385 $as_echo "$gt_cv_c_wchar_t" >&6; }
19386 if test $gt_cv_c_wchar_t = yes; then
19387
19388 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
19389
19390 fi
19391
19392
19393 GNULIB_DPRINTF=0;
19394 GNULIB_FCLOSE=0;
19395 GNULIB_FDOPEN=0;
19396 GNULIB_FFLUSH=0;
19397 GNULIB_FGETC=0;
19398 GNULIB_FGETS=0;
19399 GNULIB_FOPEN=0;
19400 GNULIB_FPRINTF=0;
19401 GNULIB_FPRINTF_POSIX=0;
19402 GNULIB_FPURGE=0;
19403 GNULIB_FPUTC=0;
19404 GNULIB_FPUTS=0;
19405 GNULIB_FREAD=0;
19406 GNULIB_FREOPEN=0;
19407 GNULIB_FSCANF=0;
19408 GNULIB_FSEEK=0;
19409 GNULIB_FSEEKO=0;
19410 GNULIB_FTELL=0;
19411 GNULIB_FTELLO=0;
19412 GNULIB_FWRITE=0;
19413 GNULIB_GETC=0;
19414 GNULIB_GETCHAR=0;
19415 GNULIB_GETDELIM=0;
19416 GNULIB_GETLINE=0;
19417 GNULIB_OBSTACK_PRINTF=0;
19418 GNULIB_OBSTACK_PRINTF_POSIX=0;
19419 GNULIB_PCLOSE=0;
19420 GNULIB_PERROR=0;
19421 GNULIB_POPEN=0;
19422 GNULIB_PRINTF=0;
19423 GNULIB_PRINTF_POSIX=0;
19424 GNULIB_PUTC=0;
19425 GNULIB_PUTCHAR=0;
19426 GNULIB_PUTS=0;
19427 GNULIB_REMOVE=0;
19428 GNULIB_RENAME=0;
19429 GNULIB_RENAMEAT=0;
19430 GNULIB_SCANF=0;
19431 GNULIB_SNPRINTF=0;
19432 GNULIB_SPRINTF_POSIX=0;
19433 GNULIB_STDIO_H_NONBLOCKING=0;
19434 GNULIB_STDIO_H_SIGPIPE=0;
19435 GNULIB_TMPFILE=0;
19436 GNULIB_VASPRINTF=0;
19437 GNULIB_VFSCANF=0;
19438 GNULIB_VSCANF=0;
19439 GNULIB_VDPRINTF=0;
19440 GNULIB_VFPRINTF=0;
19441 GNULIB_VFPRINTF_POSIX=0;
19442 GNULIB_VPRINTF=0;
19443 GNULIB_VPRINTF_POSIX=0;
19444 GNULIB_VSNPRINTF=0;
19445 GNULIB_VSPRINTF_POSIX=0;
19446 HAVE_DECL_FPURGE=1;
19447 HAVE_DECL_FSEEKO=1;
19448 HAVE_DECL_FTELLO=1;
19449 HAVE_DECL_GETDELIM=1;
19450 HAVE_DECL_GETLINE=1;
19451 HAVE_DECL_OBSTACK_PRINTF=1;
19452 HAVE_DECL_SNPRINTF=1;
19453 HAVE_DECL_VSNPRINTF=1;
19454 HAVE_DPRINTF=1;
19455 HAVE_FSEEKO=1;
19456 HAVE_FTELLO=1;
19457 HAVE_PCLOSE=1;
19458 HAVE_POPEN=1;
19459 HAVE_RENAMEAT=1;
19460 HAVE_VASPRINTF=1;
19461 HAVE_VDPRINTF=1;
19462 REPLACE_DPRINTF=0;
19463 REPLACE_FCLOSE=0;
19464 REPLACE_FDOPEN=0;
19465 REPLACE_FFLUSH=0;
19466 REPLACE_FOPEN=0;
19467 REPLACE_FPRINTF=0;
19468 REPLACE_FPURGE=0;
19469 REPLACE_FREOPEN=0;
19470 REPLACE_FSEEK=0;
19471 REPLACE_FSEEKO=0;
19472 REPLACE_FTELL=0;
19473 REPLACE_FTELLO=0;
19474 REPLACE_GETDELIM=0;
19475 REPLACE_GETLINE=0;
19476 REPLACE_OBSTACK_PRINTF=0;
19477 REPLACE_PERROR=0;
19478 REPLACE_POPEN=0;
19479 REPLACE_PRINTF=0;
19480 REPLACE_REMOVE=0;
19481 REPLACE_RENAME=0;
19482 REPLACE_RENAMEAT=0;
19483 REPLACE_SNPRINTF=0;
19484 REPLACE_SPRINTF=0;
19485 REPLACE_STDIO_READ_FUNCS=0;
19486 REPLACE_STDIO_WRITE_FUNCS=0;
19487 REPLACE_TMPFILE=0;
19488 REPLACE_VASPRINTF=0;
19489 REPLACE_VDPRINTF=0;
19490 REPLACE_VFPRINTF=0;
19491 REPLACE_VPRINTF=0;
19492 REPLACE_VSNPRINTF=0;
19493 REPLACE_VSPRINTF=0;
19494
19495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
19496 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
19497 if test "${ac_cv_struct_tm+set}" = set; then :
19498 $as_echo_n "(cached) " >&6
19499 else
19500 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19501 /* end confdefs.h. */
19502 #include <sys/types.h>
19503 #include <time.h>
19504
19505 int
19506 main ()
19507 {
19508 struct tm tm;
19509 int *p = &tm.tm_sec;
19510 return !p;
19511 ;
19512 return 0;
19513 }
19514 _ACEOF
19515 if ac_fn_c_try_compile "$LINENO"; then :
19516 ac_cv_struct_tm=time.h
19517 else
19518 ac_cv_struct_tm=sys/time.h
19519 fi
19520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19521 fi
19522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
19523 $as_echo "$ac_cv_struct_tm" >&6; }
19524 if test $ac_cv_struct_tm = sys/time.h; then
19525
19526 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
19527
19528 fi
19529
19530 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
19531 #include <$ac_cv_struct_tm>
19532
19533 "
19534 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
19535
19536 cat >>confdefs.h <<_ACEOF
19537 #define HAVE_STRUCT_TM_TM_ZONE 1
19538 _ACEOF
19539
19540
19541 fi
19542
19543 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
19544
19545 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
19546
19547 else
19548 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
19549 "
19550 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
19551 ac_have_decl=1
19552 else
19553 ac_have_decl=0
19554 fi
19555
19556 cat >>confdefs.h <<_ACEOF
19557 #define HAVE_DECL_TZNAME $ac_have_decl
19558 _ACEOF
19559
19560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
19561 $as_echo_n "checking for tzname... " >&6; }
19562 if test "${ac_cv_var_tzname+set}" = set; then :
19563 $as_echo_n "(cached) " >&6
19564 else
19565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19566 /* end confdefs.h. */
19567 #include <time.h>
19568 #if !HAVE_DECL_TZNAME
19569 extern char *tzname[];
19570 #endif
19571
19572 int
19573 main ()
19574 {
19575 return tzname[0][0];
19576 ;
19577 return 0;
19578 }
19579 _ACEOF
19580 if ac_fn_c_try_link "$LINENO"; then :
19581 ac_cv_var_tzname=yes
19582 else
19583 ac_cv_var_tzname=no
19584 fi
19585 rm -f core conftest.err conftest.$ac_objext \
19586 conftest$ac_exeext conftest.$ac_ext
19587 fi
19588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
19589 $as_echo "$ac_cv_var_tzname" >&6; }
19590 if test $ac_cv_var_tzname = yes; then
19591
19592 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
19593
19594 fi
19595 fi
19596
19597
19598 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
19599 "
19600 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
19601
19602 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
19603
19604 fi
19605
19606
19607
19608
19609 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
19610 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
19611 ac_have_decl=1
19612 else
19613 ac_have_decl=0
19614 fi
19615
19616 cat >>confdefs.h <<_ACEOF
19617 #define HAVE_DECL_STRTOIMAX $ac_have_decl
19618 _ACEOF
19619
19620
19621
19622 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
19623 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
19624 ac_have_decl=1
19625 else
19626 ac_have_decl=0
19627 fi
19628
19629 cat >>confdefs.h <<_ACEOF
19630 #define HAVE_DECL_STRTOUMAX $ac_have_decl
19631 _ACEOF
19632
19633
19634
19635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19636 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
19637 if test "${ac_cv_header_stat_broken+set}" = set; then :
19638 $as_echo_n "(cached) " >&6
19639 else
19640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19641 /* end confdefs.h. */
19642 #include <sys/types.h>
19643 #include <sys/stat.h>
19644
19645 #if defined S_ISBLK && defined S_IFDIR
19646 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19647 #endif
19648
19649 #if defined S_ISBLK && defined S_IFCHR
19650 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19651 #endif
19652
19653 #if defined S_ISLNK && defined S_IFREG
19654 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19655 #endif
19656
19657 #if defined S_ISSOCK && defined S_IFREG
19658 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19659 #endif
19660
19661 _ACEOF
19662 if ac_fn_c_try_compile "$LINENO"; then :
19663 ac_cv_header_stat_broken=no
19664 else
19665 ac_cv_header_stat_broken=yes
19666 fi
19667 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19668 fi
19669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19670 $as_echo "$ac_cv_header_stat_broken" >&6; }
19671 if test $ac_cv_header_stat_broken = yes; then
19672
19673 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19674
19675 fi
19676
19677
19678
19679 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
19680 if test "x$ac_cv_type_mode_t" = x""yes; then :
19681
19682 else
19683
19684 cat >>confdefs.h <<_ACEOF
19685 #define mode_t int
19686 _ACEOF
19687
19688 fi
19689
19690
19691
19692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
19693 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
19694 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
19695 $as_echo_n "(cached) " >&6
19696 else
19697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19698 /* end confdefs.h. */
19699 #include <time.h>
19700
19701 int
19702 main ()
19703 {
19704 static struct timespec x; x.tv_sec = x.tv_nsec;
19705 ;
19706 return 0;
19707 }
19708 _ACEOF
19709 if ac_fn_c_try_compile "$LINENO"; then :
19710 gl_cv_sys_struct_timespec_in_time_h=yes
19711 else
19712 gl_cv_sys_struct_timespec_in_time_h=no
19713 fi
19714 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19715 fi
19716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
19717 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
19718
19719 TIME_H_DEFINES_STRUCT_TIMESPEC=0
19720 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
19721 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
19722 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
19723 TIME_H_DEFINES_STRUCT_TIMESPEC=1
19724 else
19725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
19726 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
19727 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
19728 $as_echo_n "(cached) " >&6
19729 else
19730 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19731 /* end confdefs.h. */
19732 #include <sys/time.h>
19733
19734 int
19735 main ()
19736 {
19737 static struct timespec x; x.tv_sec = x.tv_nsec;
19738 ;
19739 return 0;
19740 }
19741 _ACEOF
19742 if ac_fn_c_try_compile "$LINENO"; then :
19743 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19744 else
19745 gl_cv_sys_struct_timespec_in_sys_time_h=no
19746 fi
19747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19748 fi
19749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19750 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19751 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19752 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19753 else
19754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19755 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19756 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19757 $as_echo_n "(cached) " >&6
19758 else
19759 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19760 /* end confdefs.h. */
19761 #include <pthread.h>
19762
19763 int
19764 main ()
19765 {
19766 static struct timespec x; x.tv_sec = x.tv_nsec;
19767 ;
19768 return 0;
19769 }
19770 _ACEOF
19771 if ac_fn_c_try_compile "$LINENO"; then :
19772 gl_cv_sys_struct_timespec_in_pthread_h=yes
19773 else
19774 gl_cv_sys_struct_timespec_in_pthread_h=no
19775 fi
19776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19777 fi
19778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19779 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19780 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19781 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19782 fi
19783 fi
19784 fi
19785
19786
19787
19788
19789
19790
19791
19792
19793
19794
19795
19796
19797
19798
19799
19800 if test $gl_cv_have_include_next = yes; then
19801 gl_cv_next_time_h='<'time.h'>'
19802 else
19803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19804 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19805 if test "${gl_cv_next_time_h+set}" = set; then :
19806 $as_echo_n "(cached) " >&6
19807 else
19808
19809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19810 /* end confdefs.h. */
19811 #include <time.h>
19812
19813 _ACEOF
19814 case "$host_os" in
19815 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19816 *) gl_absname_cpp="$ac_cpp" ;;
19817 esac
19818
19819 case "$host_os" in
19820 mingw*)
19821 gl_dirsep_regex='[/\\]'
19822 ;;
19823 *)
19824 gl_dirsep_regex='\/'
19825 ;;
19826 esac
19827 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
19828
19829 gl_header_literal_regex=`echo 'time.h' \
19830 | sed -e "$gl_make_literal_regex_sed"`
19831 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
19832 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
19833 s|^/[^/]|//&|
19834 p
19835 q
19836 }'
19837 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19838 sed -n "$gl_absolute_header_sed"`'"'
19839
19840
19841 fi
19842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19843 $as_echo "$gl_cv_next_time_h" >&6; }
19844 fi
19845 NEXT_TIME_H=$gl_cv_next_time_h
19846
19847 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19848 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19849 gl_next_as_first_directive='<'time.h'>'
19850 else
19851 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19852 gl_next_as_first_directive=$gl_cv_next_time_h
19853 fi
19854 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19855
19856
19857
19858
19859
19860
19861
19862
19863
19864
19865
19866
19867
19868
19869
19870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the utimes function works" >&5
19871 $as_echo_n "checking whether the utimes function works... " >&6; }
19872 if test "${gl_cv_func_working_utimes+set}" = set; then :
19873 $as_echo_n "(cached) " >&6
19874 else
19875
19876 if test "$cross_compiling" = yes; then :
19877 gl_cv_func_working_utimes=no
19878 else
19879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19880 /* end confdefs.h. */
19881
19882 #include <sys/types.h>
19883 #include <sys/stat.h>
19884 #include <fcntl.h>
19885 #include <sys/time.h>
19886 #include <time.h>
19887 #include <unistd.h>
19888 #include <stdlib.h>
19889 #include <stdio.h>
19890 #include <utime.h>
19891
19892 static int
19893 inorder (time_t a, time_t b, time_t c)
19894 {
19895 return a <= b && b <= c;
19896 }
19897
19898 int
19899 main ()
19900 {
19901 int result = 0;
19902 char const *file = "conftest.utimes";
19903 static struct timeval timeval[2] = {{9, 10}, {999999, 999999}};
19904
19905 /* Test whether utimes() essentially works. */
19906 {
19907 struct stat sbuf;
19908 FILE *f = fopen (file, "w");
19909 if (f == NULL)
19910 result |= 1;
19911 else if (fclose (f) != 0)
19912 result |= 1;
19913 else if (utimes (file, timeval) != 0)
19914 result |= 2;
19915 else if (lstat (file, &sbuf) != 0)
19916 result |= 1;
19917 else if (!(sbuf.st_atime == timeval[0].tv_sec
19918 && sbuf.st_mtime == timeval[1].tv_sec))
19919 result |= 4;
19920 if (unlink (file) != 0)
19921 result |= 1;
19922 }
19923
19924 /* Test whether utimes() with a NULL argument sets the file's timestamp
19925 to the current time. Use 'fstat' as well as 'time' to
19926 determine the "current" time, to accommodate NFS file systems
19927 if there is a time skew between the host and the NFS server. */
19928 {
19929 int fd = open (file, O_WRONLY|O_CREAT, 0644);
19930 if (fd < 0)
19931 result |= 1;
19932 else
19933 {
19934 time_t t0, t2;
19935 struct stat st0, st1, st2;
19936 if (time (&t0) == (time_t) -1)
19937 result |= 1;
19938 else if (fstat (fd, &st0) != 0)
19939 result |= 1;
19940 else if (utimes (file, timeval) != 0)
19941 result |= 2;
19942 else if (utimes (file, NULL) != 0)
19943 result |= 8;
19944 else if (fstat (fd, &st1) != 0)
19945 result |= 1;
19946 else if (write (fd, "\n", 1) != 1)
19947 result |= 1;
19948 else if (fstat (fd, &st2) != 0)
19949 result |= 1;
19950 else if (time (&t2) == (time_t) -1)
19951 result |= 1;
19952 else
19953 {
19954 int m_ok_POSIX = inorder (t0, st1.st_mtime, t2);
19955 int m_ok_NFS = inorder (st0.st_mtime, st1.st_mtime, st2.st_mtime);
19956 if (! (st1.st_atime == st1.st_mtime))
19957 result |= 16;
19958 if (! (m_ok_POSIX || m_ok_NFS))
19959 result |= 32;
19960 }
19961 if (close (fd) != 0)
19962 result |= 1;
19963 }
19964 if (unlink (file) != 0)
19965 result |= 1;
19966 }
19967
19968 /* Test whether utimes() with a NULL argument works on read-only files. */
19969 {
19970 int fd = open (file, O_WRONLY|O_CREAT, 0444);
19971 if (fd < 0)
19972 result |= 1;
19973 else if (close (fd) != 0)
19974 result |= 1;
19975 else if (utimes (file, NULL) != 0)
19976 result |= 64;
19977 if (unlink (file) != 0)
19978 result |= 1;
19979 }
19980
19981 return result;
19982 }
19983
19984 _ACEOF
19985 if ac_fn_c_try_run "$LINENO"; then :
19986 gl_cv_func_working_utimes=yes
19987 else
19988 gl_cv_func_working_utimes=no
19989 fi
19990 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19991 conftest.$ac_objext conftest.beam conftest.$ac_ext
19992 fi
19993
19994 fi
19995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_utimes" >&5
19996 $as_echo "$gl_cv_func_working_utimes" >&6; }
19997
19998 if test $gl_cv_func_working_utimes = yes; then
19999
20000 $as_echo "#define HAVE_WORKING_UTIMES 1" >>confdefs.h
20001
20002 fi
20003
20004
20005
20006
20007
20008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
20009 $as_echo_n "checking for struct utimbuf... " >&6; }
20010 if test "${gl_cv_sys_struct_utimbuf+set}" = set; then :
20011 $as_echo_n "(cached) " >&6
20012 else
20013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20014 /* end confdefs.h. */
20015 #if HAVE_SYS_TIME_H
20016 #include <sys/time.h>
20017 #endif
20018 #include <time.h>
20019 #ifdef HAVE_UTIME_H
20020 #include <utime.h>
20021 #endif
20022
20023 int
20024 main ()
20025 {
20026 static struct utimbuf x; x.actime = x.modtime;
20027 ;
20028 return 0;
20029 }
20030 _ACEOF
20031 if ac_fn_c_try_compile "$LINENO"; then :
20032 gl_cv_sys_struct_utimbuf=yes
20033 else
20034 gl_cv_sys_struct_utimbuf=no
20035 fi
20036 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20037 fi
20038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_utimbuf" >&5
20039 $as_echo "$gl_cv_sys_struct_utimbuf" >&6; }
20040
20041 if test $gl_cv_sys_struct_utimbuf = yes; then
20042
20043 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
20044
20045 fi
20046
20047
20048
20049
20050
20051
20052
20053
20054
20055
20056
20057
20058 if false; then
20059 GL_COND_LIBTOOL_TRUE=
20060 GL_COND_LIBTOOL_FALSE='#'
20061 else
20062 GL_COND_LIBTOOL_TRUE='#'
20063 GL_COND_LIBTOOL_FALSE=
20064 fi
20065
20066 gl_cond_libtool=false
20067 gl_libdeps=
20068 gl_ltlibdeps=
20069 gl_m4_base='m4'
20070
20071
20072
20073
20074
20075
20076
20077
20078
20079 gl_source_base='lib'
20080
20081
20082 if test $ac_cv_func_alloca_works = no; then
20083 :
20084 fi
20085
20086 # Define an additional variable used in the Makefile substitution.
20087 if test $ac_cv_working_alloca_h = yes; then
20088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
20089 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
20090 if test "${gl_cv_rpl_alloca+set}" = set; then :
20091 $as_echo_n "(cached) " >&6
20092 else
20093
20094 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20095 /* end confdefs.h. */
20096
20097 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
20098 Need own alloca
20099 #endif
20100
20101 _ACEOF
20102 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20103 $EGREP "Need own alloca" >/dev/null 2>&1; then :
20104 gl_cv_rpl_alloca=yes
20105 else
20106 gl_cv_rpl_alloca=no
20107 fi
20108 rm -f conftest*
20109
20110
20111 fi
20112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
20113 $as_echo "$gl_cv_rpl_alloca" >&6; }
20114 if test $gl_cv_rpl_alloca = yes; then
20115
20116 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
20117
20118 ALLOCA_H=alloca.h
20119 else
20120 ALLOCA_H=
20121 fi
20122 else
20123 ALLOCA_H=alloca.h
20124 fi
20125
20126 if test -n "$ALLOCA_H"; then
20127 GL_GENERATE_ALLOCA_H_TRUE=
20128 GL_GENERATE_ALLOCA_H_FALSE='#'
20129 else
20130 GL_GENERATE_ALLOCA_H_TRUE='#'
20131 GL_GENERATE_ALLOCA_H_FALSE=
20132 fi
20133
20134
20135
20136
20137
20138
20139 # Solaris 2.5.1 needs -lposix4 to get the clock_gettime function.
20140 # Solaris 7 prefers the library name -lrt to the obsolescent name -lposix4.
20141
20142 # Save and restore LIBS so e.g., -lrt, isn't added to it. Otherwise, *all*
20143 # programs in the package would end up linked with that potentially-shared
20144 # library, inducing unnecessary run-time overhead.
20145 LIB_CLOCK_GETTIME=
20146
20147 gl_saved_libs=$LIBS
20148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing clock_gettime" >&5
20149 $as_echo_n "checking for library containing clock_gettime... " >&6; }
20150 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20151 $as_echo_n "(cached) " >&6
20152 else
20153 ac_func_search_save_LIBS=$LIBS
20154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20155 /* end confdefs.h. */
20156
20157 /* Override any GCC internal prototype to avoid an error.
20158 Use char because int might match the return type of a GCC
20159 builtin and then its argument prototype would still apply. */
20160 #ifdef __cplusplus
20161 extern "C"
20162 #endif
20163 char clock_gettime ();
20164 int
20165 main ()
20166 {
20167 return clock_gettime ();
20168 ;
20169 return 0;
20170 }
20171 _ACEOF
20172 for ac_lib in '' rt posix4; do
20173 if test -z "$ac_lib"; then
20174 ac_res="none required"
20175 else
20176 ac_res=-l$ac_lib
20177 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20178 fi
20179 if ac_fn_c_try_link "$LINENO"; then :
20180 ac_cv_search_clock_gettime=$ac_res
20181 fi
20182 rm -f core conftest.err conftest.$ac_objext \
20183 conftest$ac_exeext
20184 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20185 break
20186 fi
20187 done
20188 if test "${ac_cv_search_clock_gettime+set}" = set; then :
20189
20190 else
20191 ac_cv_search_clock_gettime=no
20192 fi
20193 rm conftest.$ac_ext
20194 LIBS=$ac_func_search_save_LIBS
20195 fi
20196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_clock_gettime" >&5
20197 $as_echo "$ac_cv_search_clock_gettime" >&6; }
20198 ac_res=$ac_cv_search_clock_gettime
20199 if test "$ac_res" != no; then :
20200 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20201 test "$ac_cv_search_clock_gettime" = "none required" ||
20202 LIB_CLOCK_GETTIME=$ac_cv_search_clock_gettime
20203 fi
20204
20205 for ac_func in clock_gettime clock_settime
20206 do :
20207 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20208 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20209 eval as_val=\$$as_ac_var
20210 if test "x$as_val" = x""yes; then :
20211 cat >>confdefs.h <<_ACEOF
20212 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20213 _ACEOF
20214
20215 fi
20216 done
20217
20218 LIBS=$gl_saved_libs
20219
20220
20221
20222
20223 :
20224
20225
20226
20227
20228 :
20229
20230
20231
20232
20233
20234
20235
20236
20237
20238
20239
20240
20241
20242
20243
20244 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
20245
20246
20247 if test $HAVE_DUP2 = 1; then
20248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
20249 $as_echo_n "checking whether dup2 works... " >&6; }
20250 if test "${gl_cv_func_dup2_works+set}" = set; then :
20251 $as_echo_n "(cached) " >&6
20252 else
20253 if test "$cross_compiling" = yes; then :
20254 case "$host_os" in
20255 mingw*) # on this platform, dup2 always returns 0 for success
20256 gl_cv_func_dup2_works="guessing no" ;;
20257 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
20258 gl_cv_func_dup2_works="guessing no" ;;
20259 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
20260 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
20261 gl_cv_func_dup2_works="guessing no" ;;
20262 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
20263 gl_cv_func_dup2_works="guessing no" ;;
20264 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
20265 gl_cv_func_dup2_works="guessing no" ;;
20266 *) gl_cv_func_dup2_works="guessing yes" ;;
20267 esac
20268 else
20269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20270 /* end confdefs.h. */
20271
20272 #include <unistd.h>
20273 #include <fcntl.h>
20274 #include <errno.h>
20275 int
20276 main ()
20277 {
20278 int result = 0;
20279 #ifdef FD_CLOEXEC
20280 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
20281 result |= 1;
20282 #endif
20283 if (dup2 (1, 1) == 0)
20284 result |= 2;
20285 #ifdef FD_CLOEXEC
20286 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
20287 result |= 4;
20288 #endif
20289 close (0);
20290 if (dup2 (0, 0) != -1)
20291 result |= 8;
20292 /* Many gnulib modules require POSIX conformance of EBADF. */
20293 if (dup2 (2, 1000000) == -1 && errno != EBADF)
20294 result |= 16;
20295 return result;
20296
20297 ;
20298 return 0;
20299 }
20300
20301 _ACEOF
20302 if ac_fn_c_try_run "$LINENO"; then :
20303 gl_cv_func_dup2_works=yes
20304 else
20305 gl_cv_func_dup2_works=no
20306 fi
20307 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20308 conftest.$ac_objext conftest.beam conftest.$ac_ext
20309 fi
20310
20311
20312 fi
20313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
20314 $as_echo "$gl_cv_func_dup2_works" >&6; }
20315 case "$gl_cv_func_dup2_works" in
20316 *yes) ;;
20317 *)
20318 REPLACE_DUP2=1
20319 ;;
20320 esac
20321 fi
20322
20323
20324 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
20325
20326
20327
20328
20329
20330
20331
20332
20333 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
20334
20335
20336 fi
20337
20338
20339
20340
20341
20342 GNULIB_DUP2=1
20343
20344
20345
20346
20347
20348
20349
20350
20351
20352
20353
20354 GNULIB_ENVIRON=1
20355
20356
20357
20358
20359
20360
20361
20362
20363 LIB_EXECINFO=''
20364 EXECINFO_H='execinfo.h'
20365
20366 if test $ac_cv_header_execinfo_h = yes; then
20367 gl_saved_libs=$LIBS
20368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing backtrace_symbols_fd" >&5
20369 $as_echo_n "checking for library containing backtrace_symbols_fd... " >&6; }
20370 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20371 $as_echo_n "(cached) " >&6
20372 else
20373 ac_func_search_save_LIBS=$LIBS
20374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20375 /* end confdefs.h. */
20376
20377 /* Override any GCC internal prototype to avoid an error.
20378 Use char because int might match the return type of a GCC
20379 builtin and then its argument prototype would still apply. */
20380 #ifdef __cplusplus
20381 extern "C"
20382 #endif
20383 char backtrace_symbols_fd ();
20384 int
20385 main ()
20386 {
20387 return backtrace_symbols_fd ();
20388 ;
20389 return 0;
20390 }
20391 _ACEOF
20392 for ac_lib in '' execinfo; do
20393 if test -z "$ac_lib"; then
20394 ac_res="none required"
20395 else
20396 ac_res=-l$ac_lib
20397 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
20398 fi
20399 if ac_fn_c_try_link "$LINENO"; then :
20400 ac_cv_search_backtrace_symbols_fd=$ac_res
20401 fi
20402 rm -f core conftest.err conftest.$ac_objext \
20403 conftest$ac_exeext
20404 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20405 break
20406 fi
20407 done
20408 if test "${ac_cv_search_backtrace_symbols_fd+set}" = set; then :
20409
20410 else
20411 ac_cv_search_backtrace_symbols_fd=no
20412 fi
20413 rm conftest.$ac_ext
20414 LIBS=$ac_func_search_save_LIBS
20415 fi
20416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_backtrace_symbols_fd" >&5
20417 $as_echo "$ac_cv_search_backtrace_symbols_fd" >&6; }
20418 ac_res=$ac_cv_search_backtrace_symbols_fd
20419 if test "$ac_res" != no; then :
20420 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
20421 test "$ac_cv_search_backtrace_symbols_fd" = "none required" ||
20422 LIB_EXECINFO=$ac_cv_search_backtrace_symbols_fd
20423 fi
20424
20425 LIBS=$gl_saved_libs
20426 test "$ac_cv_search_backtrace_symbols_fd" = no || EXECINFO_H=''
20427 fi
20428
20429 if test -n "$EXECINFO_H"; then
20430
20431
20432
20433
20434
20435
20436
20437
20438 gl_LIBOBJS="$gl_LIBOBJS execinfo.$ac_objext"
20439
20440 fi
20441
20442
20443
20444 if test -n "$EXECINFO_H"; then
20445 GL_GENERATE_EXECINFO_H_TRUE=
20446 GL_GENERATE_EXECINFO_H_FALSE='#'
20447 else
20448 GL_GENERATE_EXECINFO_H_TRUE='#'
20449 GL_GENERATE_EXECINFO_H_FALSE=
20450 fi
20451
20452
20453
20454
20455
20456
20457
20458
20459
20460 # Persuade glibc <stdlib.h> to declare getloadavg().
20461
20462
20463 gl_save_LIBS=$LIBS
20464
20465 # getloadvg is present in libc on glibc >= 2.2, Mac OS X, FreeBSD >= 2.0,
20466 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
20467 HAVE_GETLOADAVG=1
20468 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
20469 if test "x$ac_cv_func_getloadavg" = x""yes; then :
20470
20471 else
20472 gl_func_getloadavg_done=no
20473
20474 # Some systems with -lutil have (and need) -lkvm as well, some do not.
20475 # On Solaris, -lkvm requires nlist from -lelf, so check that first
20476 # to get the right answer into the cache.
20477 # For kstat on solaris, we need to test for libelf and libkvm to force the
20478 # definition of SVR4 below.
20479 if test $gl_func_getloadavg_done = no; then
20480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
20481 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
20482 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
20483 $as_echo_n "(cached) " >&6
20484 else
20485 ac_check_lib_save_LIBS=$LIBS
20486 LIBS="-lelf $LIBS"
20487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20488 /* end confdefs.h. */
20489
20490 /* Override any GCC internal prototype to avoid an error.
20491 Use char because int might match the return type of a GCC
20492 builtin and then its argument prototype would still apply. */
20493 #ifdef __cplusplus
20494 extern "C"
20495 #endif
20496 char elf_begin ();
20497 int
20498 main ()
20499 {
20500 return elf_begin ();
20501 ;
20502 return 0;
20503 }
20504 _ACEOF
20505 if ac_fn_c_try_link "$LINENO"; then :
20506 ac_cv_lib_elf_elf_begin=yes
20507 else
20508 ac_cv_lib_elf_elf_begin=no
20509 fi
20510 rm -f core conftest.err conftest.$ac_objext \
20511 conftest$ac_exeext conftest.$ac_ext
20512 LIBS=$ac_check_lib_save_LIBS
20513 fi
20514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
20515 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
20516 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
20517 LIBS="-lelf $LIBS"
20518 fi
20519
20520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
20521 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
20522 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
20523 $as_echo_n "(cached) " >&6
20524 else
20525 ac_check_lib_save_LIBS=$LIBS
20526 LIBS="-lkvm $LIBS"
20527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20528 /* end confdefs.h. */
20529
20530 /* Override any GCC internal prototype to avoid an error.
20531 Use char because int might match the return type of a GCC
20532 builtin and then its argument prototype would still apply. */
20533 #ifdef __cplusplus
20534 extern "C"
20535 #endif
20536 char kvm_open ();
20537 int
20538 main ()
20539 {
20540 return kvm_open ();
20541 ;
20542 return 0;
20543 }
20544 _ACEOF
20545 if ac_fn_c_try_link "$LINENO"; then :
20546 ac_cv_lib_kvm_kvm_open=yes
20547 else
20548 ac_cv_lib_kvm_kvm_open=no
20549 fi
20550 rm -f core conftest.err conftest.$ac_objext \
20551 conftest$ac_exeext conftest.$ac_ext
20552 LIBS=$ac_check_lib_save_LIBS
20553 fi
20554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
20555 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
20556 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
20557 LIBS="-lkvm $LIBS"
20558 fi
20559
20560 # Check for the 4.4BSD definition of getloadavg.
20561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
20562 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
20563 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
20564 $as_echo_n "(cached) " >&6
20565 else
20566 ac_check_lib_save_LIBS=$LIBS
20567 LIBS="-lutil $LIBS"
20568 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20569 /* end confdefs.h. */
20570
20571 /* Override any GCC internal prototype to avoid an error.
20572 Use char because int might match the return type of a GCC
20573 builtin and then its argument prototype would still apply. */
20574 #ifdef __cplusplus
20575 extern "C"
20576 #endif
20577 char getloadavg ();
20578 int
20579 main ()
20580 {
20581 return getloadavg ();
20582 ;
20583 return 0;
20584 }
20585 _ACEOF
20586 if ac_fn_c_try_link "$LINENO"; then :
20587 ac_cv_lib_util_getloadavg=yes
20588 else
20589 ac_cv_lib_util_getloadavg=no
20590 fi
20591 rm -f core conftest.err conftest.$ac_objext \
20592 conftest$ac_exeext conftest.$ac_ext
20593 LIBS=$ac_check_lib_save_LIBS
20594 fi
20595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
20596 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
20597 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
20598 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
20599 fi
20600
20601 fi
20602
20603 if test $gl_func_getloadavg_done = no; then
20604 # There is a commonly available library for RS/6000 AIX.
20605 # Since it is not a standard part of AIX, it might be installed locally.
20606 gl_getloadavg_LIBS=$LIBS
20607 LIBS="-L/usr/local/lib $LIBS"
20608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
20609 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
20610 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
20611 $as_echo_n "(cached) " >&6
20612 else
20613 ac_check_lib_save_LIBS=$LIBS
20614 LIBS="-lgetloadavg $LIBS"
20615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20616 /* end confdefs.h. */
20617
20618 /* Override any GCC internal prototype to avoid an error.
20619 Use char because int might match the return type of a GCC
20620 builtin and then its argument prototype would still apply. */
20621 #ifdef __cplusplus
20622 extern "C"
20623 #endif
20624 char getloadavg ();
20625 int
20626 main ()
20627 {
20628 return getloadavg ();
20629 ;
20630 return 0;
20631 }
20632 _ACEOF
20633 if ac_fn_c_try_link "$LINENO"; then :
20634 ac_cv_lib_getloadavg_getloadavg=yes
20635 else
20636 ac_cv_lib_getloadavg_getloadavg=no
20637 fi
20638 rm -f core conftest.err conftest.$ac_objext \
20639 conftest$ac_exeext conftest.$ac_ext
20640 LIBS=$ac_check_lib_save_LIBS
20641 fi
20642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
20643 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
20644 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
20645 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
20646 else
20647 LIBS=$gl_getloadavg_LIBS
20648 fi
20649
20650 fi
20651
20652 # Set up the replacement function if necessary.
20653 if test $gl_func_getloadavg_done = no; then
20654 HAVE_GETLOADAVG=0
20655
20656 # Solaris has libkstat which does not require root.
20657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
20658 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
20659 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
20660 $as_echo_n "(cached) " >&6
20661 else
20662 ac_check_lib_save_LIBS=$LIBS
20663 LIBS="-lkstat $LIBS"
20664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20665 /* end confdefs.h. */
20666
20667 /* Override any GCC internal prototype to avoid an error.
20668 Use char because int might match the return type of a GCC
20669 builtin and then its argument prototype would still apply. */
20670 #ifdef __cplusplus
20671 extern "C"
20672 #endif
20673 char kstat_open ();
20674 int
20675 main ()
20676 {
20677 return kstat_open ();
20678 ;
20679 return 0;
20680 }
20681 _ACEOF
20682 if ac_fn_c_try_link "$LINENO"; then :
20683 ac_cv_lib_kstat_kstat_open=yes
20684 else
20685 ac_cv_lib_kstat_kstat_open=no
20686 fi
20687 rm -f core conftest.err conftest.$ac_objext \
20688 conftest$ac_exeext conftest.$ac_ext
20689 LIBS=$ac_check_lib_save_LIBS
20690 fi
20691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
20692 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
20693 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
20694 cat >>confdefs.h <<_ACEOF
20695 #define HAVE_LIBKSTAT 1
20696 _ACEOF
20697
20698 LIBS="-lkstat $LIBS"
20699
20700 fi
20701
20702 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
20703
20704 # AIX has libperfstat which does not require root
20705 if test $gl_func_getloadavg_done = no; then
20706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
20707 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
20708 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
20709 $as_echo_n "(cached) " >&6
20710 else
20711 ac_check_lib_save_LIBS=$LIBS
20712 LIBS="-lperfstat $LIBS"
20713 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20714 /* end confdefs.h. */
20715
20716 /* Override any GCC internal prototype to avoid an error.
20717 Use char because int might match the return type of a GCC
20718 builtin and then its argument prototype would still apply. */
20719 #ifdef __cplusplus
20720 extern "C"
20721 #endif
20722 char perfstat_cpu_total ();
20723 int
20724 main ()
20725 {
20726 return perfstat_cpu_total ();
20727 ;
20728 return 0;
20729 }
20730 _ACEOF
20731 if ac_fn_c_try_link "$LINENO"; then :
20732 ac_cv_lib_perfstat_perfstat_cpu_total=yes
20733 else
20734 ac_cv_lib_perfstat_perfstat_cpu_total=no
20735 fi
20736 rm -f core conftest.err conftest.$ac_objext \
20737 conftest$ac_exeext conftest.$ac_ext
20738 LIBS=$ac_check_lib_save_LIBS
20739 fi
20740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
20741 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
20742 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
20743 cat >>confdefs.h <<_ACEOF
20744 #define HAVE_LIBPERFSTAT 1
20745 _ACEOF
20746
20747 LIBS="-lperfstat $LIBS"
20748
20749 fi
20750
20751 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
20752 fi
20753
20754 if test $gl_func_getloadavg_done = no; then
20755 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
20756 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
20757 gl_func_getloadavg_done=yes
20758
20759 $as_echo "#define DGUX 1" >>confdefs.h
20760
20761 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
20762 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
20763 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
20764 $as_echo_n "(cached) " >&6
20765 else
20766 ac_check_lib_save_LIBS=$LIBS
20767 LIBS="-ldgc $LIBS"
20768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20769 /* end confdefs.h. */
20770
20771 /* Override any GCC internal prototype to avoid an error.
20772 Use char because int might match the return type of a GCC
20773 builtin and then its argument prototype would still apply. */
20774 #ifdef __cplusplus
20775 extern "C"
20776 #endif
20777 char dg_sys_info ();
20778 int
20779 main ()
20780 {
20781 return dg_sys_info ();
20782 ;
20783 return 0;
20784 }
20785 _ACEOF
20786 if ac_fn_c_try_link "$LINENO"; then :
20787 ac_cv_lib_dgc_dg_sys_info=yes
20788 else
20789 ac_cv_lib_dgc_dg_sys_info=no
20790 fi
20791 rm -f core conftest.err conftest.$ac_objext \
20792 conftest$ac_exeext conftest.$ac_ext
20793 LIBS=$ac_check_lib_save_LIBS
20794 fi
20795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
20796 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
20797 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
20798 cat >>confdefs.h <<_ACEOF
20799 #define HAVE_LIBDGC 1
20800 _ACEOF
20801
20802 LIBS="-ldgc $LIBS"
20803
20804 fi
20805
20806 fi
20807
20808
20809 fi
20810 fi
20811 fi
20812
20813
20814 if test "x$gl_save_LIBS" = x; then
20815 GETLOADAVG_LIBS=$LIBS
20816 else
20817 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
20818 fi
20819 LIBS=$gl_save_LIBS
20820
20821
20822 # Test whether the system declares getloadavg. Solaris has the function
20823 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
20824 for ac_header in sys/loadavg.h
20825 do :
20826 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
20827 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
20828 cat >>confdefs.h <<_ACEOF
20829 #define HAVE_SYS_LOADAVG_H 1
20830 _ACEOF
20831
20832 fi
20833
20834 done
20835
20836 if test $ac_cv_header_sys_loadavg_h = yes; then
20837 HAVE_SYS_LOADAVG_H=1
20838 else
20839 HAVE_SYS_LOADAVG_H=0
20840 fi
20841 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
20842 # include <sys/loadavg.h>
20843 #endif
20844 #include <stdlib.h>
20845 "
20846 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
20847
20848 else
20849 HAVE_DECL_GETLOADAVG=0
20850 fi
20851
20852
20853 if test $HAVE_GETLOADAVG = 0; then
20854
20855
20856
20857
20858
20859
20860
20861
20862 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
20863
20864
20865 # Figure out what our getloadavg.c needs.
20866
20867
20868
20869 # On HPUX9, an unprivileged user can get load averages this way.
20870 if test $gl_func_getloadavg_done = no; then
20871 for ac_func in pstat_getdynamic
20872 do :
20873 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
20874 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
20875 cat >>confdefs.h <<_ACEOF
20876 #define HAVE_PSTAT_GETDYNAMIC 1
20877 _ACEOF
20878 gl_func_getloadavg_done=yes
20879 fi
20880 done
20881
20882 fi
20883
20884 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
20885 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
20886 # Irix 4.0.5F has the header but not the library.
20887 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
20888 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
20889 gl_func_getloadavg_done=yes
20890
20891 $as_echo "#define SVR4 1" >>confdefs.h
20892
20893 fi
20894
20895 if test $gl_func_getloadavg_done = no; then
20896 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
20897 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
20898 gl_func_getloadavg_done=yes
20899
20900 $as_echo "#define UMAX 1" >>confdefs.h
20901
20902
20903 $as_echo "#define UMAX4_3 1" >>confdefs.h
20904
20905 fi
20906
20907
20908 fi
20909
20910 if test $gl_func_getloadavg_done = no; then
20911 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
20912 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
20913 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
20914
20915 fi
20916
20917
20918 fi
20919
20920 if test $gl_func_getloadavg_done = no; then
20921 for ac_header in mach/mach.h
20922 do :
20923 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
20924 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
20925 cat >>confdefs.h <<_ACEOF
20926 #define HAVE_MACH_MACH_H 1
20927 _ACEOF
20928
20929 fi
20930
20931 done
20932
20933 fi
20934
20935 for ac_header in nlist.h
20936 do :
20937 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
20938 if test "x$ac_cv_header_nlist_h" = x""yes; then :
20939 cat >>confdefs.h <<_ACEOF
20940 #define HAVE_NLIST_H 1
20941 _ACEOF
20942 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
20943 "
20944 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
20945
20946 cat >>confdefs.h <<_ACEOF
20947 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
20948 _ACEOF
20949
20950
20951 fi
20952
20953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20954 /* end confdefs.h. */
20955 #include <nlist.h>
20956 int
20957 main ()
20958 {
20959 struct nlist x;
20960 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
20961 x.n_un.n_name = "";
20962 #else
20963 x.n_name = "";
20964 #endif
20965 ;
20966 return 0;
20967 }
20968 _ACEOF
20969 if ac_fn_c_try_link "$LINENO"; then :
20970
20971 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
20972
20973 fi
20974 rm -f core conftest.err conftest.$ac_objext \
20975 conftest$ac_exeext conftest.$ac_ext
20976
20977 fi
20978
20979 done
20980
20981 fi
20982
20983
20984
20985
20986
20987 GNULIB_GETLOADAVG=1
20988
20989
20990
20991
20992
20993
20994
20995
20996
20997
20998 if test $REPLACE_GETOPT = 1; then
20999
21000
21001
21002
21003
21004
21005
21006
21007 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21008
21009
21010
21011
21012
21013
21014
21015
21016
21017 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21018
21019
21020
21021
21022 GNULIB_GL_UNISTD_H_GETOPT=1
21023 fi
21024
21025
21026
21027
21028
21029
21030
21031 REPLACE_GETOPT=0
21032 if test -n "$gl_replace_getopt"; then
21033 REPLACE_GETOPT=1
21034 fi
21035
21036 if test $REPLACE_GETOPT = 1; then
21037
21038 GETOPT_H=getopt.h
21039
21040 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
21041
21042
21043
21044 fi
21045
21046 if test $REPLACE_GETOPT = 1; then
21047
21048
21049
21050
21051
21052
21053
21054
21055 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
21056
21057
21058
21059
21060
21061
21062
21063
21064
21065 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
21066
21067
21068
21069
21070 GNULIB_GL_UNISTD_H_GETOPT=1
21071 fi
21072
21073
21074
21075
21076
21077
21078
21079
21080
21081
21082
21083
21084 gl_gettimeofday_timezone=void
21085 if test $ac_cv_func_gettimeofday != yes; then
21086 HAVE_GETTIMEOFDAY=0
21087 else
21088
21089
21090
21091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday clobbers localtime buffer" >&5
21092 $as_echo_n "checking whether gettimeofday clobbers localtime buffer... " >&6; }
21093 if test "${gl_cv_func_gettimeofday_clobber+set}" = set; then :
21094 $as_echo_n "(cached) " >&6
21095 else
21096 if test "$cross_compiling" = yes; then :
21097 # When cross-compiling:
21098 case "$host_os" in
21099 # Guess all is fine on glibc systems.
21100 *-gnu*) gl_cv_func_gettimeofday_clobber="guessing no" ;;
21101 # If we don't know, assume the worst.
21102 *) gl_cv_func_gettimeofday_clobber="guessing yes" ;;
21103 esac
21104
21105 else
21106 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21107 /* end confdefs.h. */
21108 #include <string.h>
21109 #include <sys/time.h>
21110 #include <time.h>
21111 #include <stdlib.h>
21112
21113 int
21114 main ()
21115 {
21116
21117 time_t t = 0;
21118 struct tm *lt;
21119 struct tm saved_lt;
21120 struct timeval tv;
21121 lt = localtime (&t);
21122 saved_lt = *lt;
21123 gettimeofday (&tv, NULL);
21124 return memcmp (lt, &saved_lt, sizeof (struct tm)) != 0;
21125
21126 ;
21127 return 0;
21128 }
21129 _ACEOF
21130 if ac_fn_c_try_run "$LINENO"; then :
21131 gl_cv_func_gettimeofday_clobber=no
21132 else
21133 gl_cv_func_gettimeofday_clobber=yes
21134 fi
21135 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21136 conftest.$ac_objext conftest.beam conftest.$ac_ext
21137 fi
21138
21139 fi
21140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_clobber" >&5
21141 $as_echo "$gl_cv_func_gettimeofday_clobber" >&6; }
21142
21143 case "$gl_cv_func_gettimeofday_clobber" in
21144 *yes)
21145 REPLACE_GETTIMEOFDAY=1
21146
21147
21148 $as_echo "#define gmtime rpl_gmtime" >>confdefs.h
21149
21150
21151 $as_echo "#define localtime rpl_localtime" >>confdefs.h
21152
21153
21154
21155 $as_echo "#define GETTIMEOFDAY_CLOBBERS_LOCALTIME 1" >>confdefs.h
21156
21157 ;;
21158 esac
21159
21160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gettimeofday with POSIX signature" >&5
21161 $as_echo_n "checking for gettimeofday with POSIX signature... " >&6; }
21162 if test "${gl_cv_func_gettimeofday_posix_signature+set}" = set; then :
21163 $as_echo_n "(cached) " >&6
21164 else
21165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21166 /* end confdefs.h. */
21167 #include <sys/time.h>
21168 struct timeval c;
21169 int gettimeofday (struct timeval *restrict, void *restrict);
21170
21171 int
21172 main ()
21173 {
21174 /* glibc uses struct timezone * rather than the POSIX void *
21175 if _GNU_SOURCE is defined. However, since the only portable
21176 use of gettimeofday uses NULL as the second parameter, and
21177 since the glibc definition is actually more typesafe, it is
21178 not worth wrapping this to get a compliant signature. */
21179 int (*f) (struct timeval *restrict, void *restrict)
21180 = gettimeofday;
21181 int x = f (&c, 0);
21182 return !(x | c.tv_sec | c.tv_usec);
21183
21184 ;
21185 return 0;
21186 }
21187 _ACEOF
21188 if ac_fn_c_try_compile "$LINENO"; then :
21189 gl_cv_func_gettimeofday_posix_signature=yes
21190 else
21191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21192 /* end confdefs.h. */
21193 #include <sys/time.h>
21194 int gettimeofday (struct timeval *restrict, struct timezone *restrict);
21195
21196 int
21197 main ()
21198 {
21199
21200 ;
21201 return 0;
21202 }
21203 _ACEOF
21204 if ac_fn_c_try_compile "$LINENO"; then :
21205 gl_cv_func_gettimeofday_posix_signature=almost
21206 else
21207 gl_cv_func_gettimeofday_posix_signature=no
21208 fi
21209 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21210 fi
21211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21212 fi
21213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_gettimeofday_posix_signature" >&5
21214 $as_echo "$gl_cv_func_gettimeofday_posix_signature" >&6; }
21215 if test $gl_cv_func_gettimeofday_posix_signature = almost; then
21216 gl_gettimeofday_timezone='struct timezone'
21217 elif test $gl_cv_func_gettimeofday_posix_signature != yes; then
21218 REPLACE_GETTIMEOFDAY=1
21219 fi
21220 if test $REPLACE_STRUCT_TIMEVAL = 1; then
21221 REPLACE_GETTIMEOFDAY=1
21222 fi
21223
21224 fi
21225
21226 cat >>confdefs.h <<_ACEOF
21227 #define GETTIMEOFDAY_TIMEZONE $gl_gettimeofday_timezone
21228 _ACEOF
21229
21230
21231 if test $HAVE_GETTIMEOFDAY = 0 || test $REPLACE_GETTIMEOFDAY = 1; then
21232
21233
21234
21235
21236
21237
21238
21239
21240 gl_LIBOBJS="$gl_LIBOBJS gettimeofday.$ac_objext"
21241
21242
21243 for ac_header in sys/timeb.h
21244 do :
21245 ac_fn_c_check_header_mongrel "$LINENO" "sys/timeb.h" "ac_cv_header_sys_timeb_h" "$ac_includes_default"
21246 if test "x$ac_cv_header_sys_timeb_h" = x""yes; then :
21247 cat >>confdefs.h <<_ACEOF
21248 #define HAVE_SYS_TIMEB_H 1
21249 _ACEOF
21250
21251 fi
21252
21253 done
21254
21255 for ac_func in _ftime
21256 do :
21257 ac_fn_c_check_func "$LINENO" "_ftime" "ac_cv_func__ftime"
21258 if test "x$ac_cv_func__ftime" = x""yes; then :
21259 cat >>confdefs.h <<_ACEOF
21260 #define HAVE__FTIME 1
21261 _ACEOF
21262
21263 fi
21264 done
21265
21266
21267 fi
21268
21269
21270
21271
21272
21273 GNULIB_GETTIMEOFDAY=1
21274
21275
21276
21277
21278
21279
21280
21281
21282
21283
21284 if test $ac_cv_func_lstat = yes; then
21285
21286 case "$gl_cv_func_lstat_dereferences_slashed_symlink" in
21287 *no)
21288 REPLACE_LSTAT=1
21289 ;;
21290 esac
21291 else
21292 HAVE_LSTAT=0
21293 fi
21294
21295 if test $REPLACE_LSTAT = 1; then
21296
21297
21298
21299
21300
21301
21302
21303
21304 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
21305
21306
21307
21308 :
21309
21310 fi
21311
21312
21313
21314
21315
21316 GNULIB_LSTAT=1
21317
21318
21319
21320
21321
21322
21323
21324
21325
21326
21327
21328 if test $APPLE_UNIVERSAL_BUILD = 1; then
21329 # A universal build on Apple Mac OS X platforms.
21330 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
21331 # But we need a configuration result that is valid in both modes.
21332 gl_cv_func_working_mktime=no
21333 fi
21334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
21335 $as_echo_n "checking for working mktime... " >&6; }
21336 if test "${gl_cv_func_working_mktime+set}" = set; then :
21337 $as_echo_n "(cached) " >&6
21338 else
21339 if test "$cross_compiling" = yes; then :
21340 gl_cv_func_working_mktime=no
21341 else
21342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21343 /* end confdefs.h. */
21344 /* Test program from Paul Eggert and Tony Leneis. */
21345 #include <limits.h>
21346 #include <stdlib.h>
21347 #include <time.h>
21348
21349 #ifdef HAVE_UNISTD_H
21350 # include <unistd.h>
21351 #endif
21352
21353 #ifndef HAVE_ALARM
21354 # define alarm(X) /* empty */
21355 #endif
21356
21357 /* Work around redefinition to rpl_putenv by other config tests. */
21358 #undef putenv
21359
21360 static time_t time_t_max;
21361 static time_t time_t_min;
21362
21363 /* Values we'll use to set the TZ environment variable. */
21364 static char *tz_strings[] = {
21365 (char *) 0, "TZ=GMT0", "TZ=JST-9",
21366 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
21367 };
21368 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
21369
21370 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
21371 Based on a problem report from Andreas Jaeger. */
21372 static int
21373 spring_forward_gap ()
21374 {
21375 /* glibc (up to about 1998-10-07) failed this test. */
21376 struct tm tm;
21377
21378 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21379 instead of "TZ=America/Vancouver" in order to detect the bug even
21380 on systems that don't support the Olson extension, or don't have the
21381 full zoneinfo tables installed. */
21382 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21383
21384 tm.tm_year = 98;
21385 tm.tm_mon = 3;
21386 tm.tm_mday = 5;
21387 tm.tm_hour = 2;
21388 tm.tm_min = 0;
21389 tm.tm_sec = 0;
21390 tm.tm_isdst = -1;
21391 return mktime (&tm) != (time_t) -1;
21392 }
21393
21394 static int
21395 mktime_test1 (time_t now)
21396 {
21397 struct tm *lt;
21398 return ! (lt = localtime (&now)) || mktime (lt) == now;
21399 }
21400
21401 static int
21402 mktime_test (time_t now)
21403 {
21404 return (mktime_test1 (now)
21405 && mktime_test1 ((time_t) (time_t_max - now))
21406 && mktime_test1 ((time_t) (time_t_min + now)));
21407 }
21408
21409 static int
21410 irix_6_4_bug ()
21411 {
21412 /* Based on code from Ariel Faigon. */
21413 struct tm tm;
21414 tm.tm_year = 96;
21415 tm.tm_mon = 3;
21416 tm.tm_mday = 0;
21417 tm.tm_hour = 0;
21418 tm.tm_min = 0;
21419 tm.tm_sec = 0;
21420 tm.tm_isdst = -1;
21421 mktime (&tm);
21422 return tm.tm_mon == 2 && tm.tm_mday == 31;
21423 }
21424
21425 static int
21426 bigtime_test (int j)
21427 {
21428 struct tm tm;
21429 time_t now;
21430 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
21431 now = mktime (&tm);
21432 if (now != (time_t) -1)
21433 {
21434 struct tm *lt = localtime (&now);
21435 if (! (lt
21436 && lt->tm_year == tm.tm_year
21437 && lt->tm_mon == tm.tm_mon
21438 && lt->tm_mday == tm.tm_mday
21439 && lt->tm_hour == tm.tm_hour
21440 && lt->tm_min == tm.tm_min
21441 && lt->tm_sec == tm.tm_sec
21442 && lt->tm_yday == tm.tm_yday
21443 && lt->tm_wday == tm.tm_wday
21444 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
21445 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
21446 return 0;
21447 }
21448 return 1;
21449 }
21450
21451 static int
21452 year_2050_test ()
21453 {
21454 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
21455 ignoring leap seconds. */
21456 unsigned long int answer = 2527315200UL;
21457
21458 struct tm tm;
21459 time_t t;
21460 tm.tm_year = 2050 - 1900;
21461 tm.tm_mon = 2 - 1;
21462 tm.tm_mday = 1;
21463 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
21464 tm.tm_isdst = -1;
21465
21466 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
21467 instead of "TZ=America/Vancouver" in order to detect the bug even
21468 on systems that don't support the Olson extension, or don't have the
21469 full zoneinfo tables installed. */
21470 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
21471
21472 t = mktime (&tm);
21473
21474 /* Check that the result is either a failure, or close enough
21475 to the correct answer that we can assume the discrepancy is
21476 due to leap seconds. */
21477 return (t == (time_t) -1
21478 || (0 < t && answer - 120 <= t && t <= answer + 120));
21479 }
21480
21481 int
21482 main ()
21483 {
21484 int result = 0;
21485 time_t t, delta;
21486 int i, j;
21487 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
21488 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
21489
21490 /* This test makes some buggy mktime implementations loop.
21491 Give up after 60 seconds; a mktime slower than that
21492 isn't worth using anyway. */
21493 alarm (60);
21494
21495 time_t_max = (! time_t_signed
21496 ? (time_t) -1
21497 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
21498 * 2 + 1));
21499 time_t_min = (! time_t_signed
21500 ? (time_t) 0
21501 : time_t_signed_magnitude
21502 ? ~ (time_t) 0
21503 : ~ time_t_max);
21504
21505 delta = time_t_max / 997; /* a suitable prime number */
21506 for (i = 0; i < N_STRINGS; i++)
21507 {
21508 if (tz_strings[i])
21509 putenv (tz_strings[i]);
21510
21511 for (t = 0; t <= time_t_max - delta && (result & 1) == 0; t += delta)
21512 if (! mktime_test (t))
21513 result |= 1;
21514 if ((result & 2) == 0
21515 && ! (mktime_test ((time_t) 1)
21516 && mktime_test ((time_t) (60 * 60))
21517 && mktime_test ((time_t) (60 * 60 * 24))))
21518 result |= 2;
21519
21520 for (j = 1; (result & 4) == 0; j <<= 1)
21521 {
21522 if (! bigtime_test (j))
21523 result |= 4;
21524 if (INT_MAX / 2 < j)
21525 break;
21526 }
21527 if ((result & 8) == 0 && ! bigtime_test (INT_MAX))
21528 result |= 8;
21529 }
21530 if (! irix_6_4_bug ())
21531 result |= 16;
21532 if (! spring_forward_gap ())
21533 result |= 32;
21534 if (! year_2050_test ())
21535 result |= 64;
21536 return result;
21537 }
21538 _ACEOF
21539 if ac_fn_c_try_run "$LINENO"; then :
21540 gl_cv_func_working_mktime=yes
21541 else
21542 gl_cv_func_working_mktime=no
21543 fi
21544 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21545 conftest.$ac_objext conftest.beam conftest.$ac_ext
21546 fi
21547
21548
21549 fi
21550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
21551 $as_echo "$gl_cv_func_working_mktime" >&6; }
21552
21553 if test $gl_cv_func_working_mktime = no; then
21554 REPLACE_MKTIME=1
21555 else
21556 REPLACE_MKTIME=0
21557 fi
21558
21559 if test $REPLACE_MKTIME = 1; then
21560
21561
21562
21563
21564
21565
21566
21567
21568 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
21569
21570 :
21571 fi
21572
21573
21574
21575
21576
21577 GNULIB_MKTIME=1
21578
21579
21580
21581
21582
21583
21584
21585
21586
21587
21588
21589 if test $ac_cv_func_pselect = yes; then
21590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signature of pselect conforms to POSIX" >&5
21591 $as_echo_n "checking whether signature of pselect conforms to POSIX... " >&6; }
21592 if test "${gl_cv_sig_pselect+set}" = set; then :
21593 $as_echo_n "(cached) " >&6
21594 else
21595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21596 /* end confdefs.h. */
21597 #include <sys/select.h>
21598
21599 int
21600 main ()
21601 {
21602 int (*p) (int, fd_set *, fd_set *, fd_set *restrict,
21603 struct timespec const *restrict,
21604 sigset_t const *restrict) = pselect;
21605 return !p;
21606 ;
21607 return 0;
21608 }
21609 _ACEOF
21610 if ac_fn_c_try_link "$LINENO"; then :
21611 gl_cv_sig_pselect=yes
21612 else
21613 gl_cv_sig_pselect=no
21614 fi
21615 rm -f core conftest.err conftest.$ac_objext \
21616 conftest$ac_exeext conftest.$ac_ext
21617 fi
21618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sig_pselect" >&5
21619 $as_echo "$gl_cv_sig_pselect" >&6; }
21620 fi
21621
21622 if test $ac_cv_func_pselect = no || test $gl_cv_sig_pselect = no; then
21623 REPLACE_PSELECT=1
21624 fi
21625
21626 if test $HAVE_PSELECT = 0 || test $REPLACE_PSELECT = 1; then
21627
21628
21629
21630
21631
21632
21633
21634
21635 gl_LIBOBJS="$gl_LIBOBJS pselect.$ac_objext"
21636
21637 fi
21638
21639
21640
21641
21642
21643 GNULIB_PSELECT=1
21644
21645
21646
21647
21648
21649
21650
21651
21652
21653 LIB_PTHREAD_SIGMASK=
21654
21655
21656 if test $ac_cv_func_pthread_sigmask = yes; then
21657 :
21658 else
21659 HAVE_PTHREAD_SIGMASK=0
21660 REPLACE_PTHREAD_SIGMASK=1
21661 fi
21662
21663
21664
21665
21666 if test $HAVE_PTHREAD_SIGMASK = 1; then
21667
21668
21669 if test -z "$LIB_PTHREAD_SIGMASK"; then
21670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
21671 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
21672 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
21673 $as_echo_n "(cached) " >&6
21674 else
21675
21676 if test "$cross_compiling" = yes; then :
21677
21678 case "$host_os" in
21679 freebsd* | hpux* | solaris | solaris2.[2-9]*)
21680 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
21681 *)
21682 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
21683 esac
21684
21685 else
21686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21687 /* end confdefs.h. */
21688
21689 #include <pthread.h>
21690 #include <signal.h>
21691 #include <stddef.h>
21692 int main ()
21693 {
21694 sigset_t set;
21695 sigemptyset (&set);
21696 return pthread_sigmask (1729, &set, NULL) != 0;
21697 }
21698 _ACEOF
21699 if ac_fn_c_try_run "$LINENO"; then :
21700 gl_cv_func_pthread_sigmask_in_libc_works=no
21701 else
21702 gl_cv_func_pthread_sigmask_in_libc_works=yes
21703 fi
21704 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21705 conftest.$ac_objext conftest.beam conftest.$ac_ext
21706 fi
21707
21708
21709 fi
21710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
21711 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
21712 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
21713 *no)
21714 REPLACE_PTHREAD_SIGMASK=1
21715
21716 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
21717
21718 ;;
21719 esac
21720 fi
21721
21722 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
21723 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
21724 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
21725 $as_echo_n "(cached) " >&6
21726 else
21727
21728 gl_save_LIBS="$LIBS"
21729 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
21730 if test "$cross_compiling" = yes; then :
21731 case "$host_os" in
21732 cygwin*)
21733 gl_cv_func_pthread_sigmask_return_works="guessing no";;
21734 *)
21735 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
21736 esac
21737
21738 else
21739 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21740 /* end confdefs.h. */
21741
21742 #include <pthread.h>
21743 #include <signal.h>
21744 #include <stddef.h>
21745 int main ()
21746 {
21747 sigset_t set;
21748 sigemptyset (&set);
21749 if (pthread_sigmask (1729, &set, NULL) == -1)
21750 return 1;
21751 return 0;
21752 }
21753 _ACEOF
21754 if ac_fn_c_try_run "$LINENO"; then :
21755 gl_cv_func_pthread_sigmask_return_works=yes
21756 else
21757 gl_cv_func_pthread_sigmask_return_works=no
21758 fi
21759 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21760 conftest.$ac_objext conftest.beam conftest.$ac_ext
21761 fi
21762
21763 LIBS="$gl_save_LIBS"
21764
21765 fi
21766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
21767 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
21768 case "$gl_cv_func_pthread_sigmask_return_works" in
21769 *no)
21770 REPLACE_PTHREAD_SIGMASK=1
21771
21772 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
21773
21774 ;;
21775 esac
21776
21777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
21778 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
21779 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
21780 $as_echo_n "(cached) " >&6
21781 else
21782
21783 case "$host_os" in
21784 irix*)
21785 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
21786 *)
21787 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
21788 esac
21789 gl_save_LIBS="$LIBS"
21790 LIBS="$LIBS $LIBMULTITHREAD"
21791 if test "$cross_compiling" = yes; then :
21792 :
21793 else
21794 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21795 /* end confdefs.h. */
21796
21797 #include <pthread.h>
21798 #include <signal.h>
21799 #include <stdio.h>
21800 #include <stdlib.h>
21801 #include <unistd.h>
21802 static volatile int sigint_occurred;
21803 static void
21804 sigint_handler (int sig)
21805 {
21806 sigint_occurred++;
21807 }
21808 int main ()
21809 {
21810 sigset_t set;
21811 int pid = getpid ();
21812 char command[80];
21813 signal (SIGINT, sigint_handler);
21814 sigemptyset (&set);
21815 sigaddset (&set, SIGINT);
21816 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
21817 return 1;
21818 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
21819 if (!(system (command) == 0))
21820 return 2;
21821 sleep (2);
21822 if (!(sigint_occurred == 0))
21823 return 3;
21824 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
21825 return 4;
21826 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
21827 return 5;
21828 return 0;
21829 }
21830 _ACEOF
21831 if ac_fn_c_try_run "$LINENO"; then :
21832 :
21833 else
21834 gl_cv_func_pthread_sigmask_unblock_works=no
21835 fi
21836 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21837 conftest.$ac_objext conftest.beam conftest.$ac_ext
21838 fi
21839
21840 LIBS="$gl_save_LIBS"
21841
21842 fi
21843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
21844 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
21845 case "$gl_cv_func_pthread_sigmask_unblock_works" in
21846 *no)
21847 REPLACE_PTHREAD_SIGMASK=1
21848
21849 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
21850
21851 ;;
21852 esac
21853 fi
21854
21855 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
21856
21857
21858
21859
21860
21861
21862
21863
21864 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
21865
21866
21867 if test $HAVE_PTHREAD_SIGMASK = 1; then
21868
21869 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
21870
21871 fi
21872
21873 fi
21874
21875
21876
21877
21878
21879 GNULIB_PTHREAD_SIGMASK=1
21880
21881
21882
21883
21884
21885
21886
21887
21888 if test $ac_cv_func_readlink = no; then
21889 HAVE_READLINK=0
21890 else
21891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
21892 $as_echo_n "checking whether readlink signature is correct... " >&6; }
21893 if test "${gl_cv_decl_readlink_works+set}" = set; then :
21894 $as_echo_n "(cached) " >&6
21895 else
21896 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21897 /* end confdefs.h. */
21898 #include <unistd.h>
21899 /* Cause compilation failure if original declaration has wrong type. */
21900 ssize_t readlink (const char *, char *, size_t);
21901 int
21902 main ()
21903 {
21904
21905 ;
21906 return 0;
21907 }
21908 _ACEOF
21909 if ac_fn_c_try_compile "$LINENO"; then :
21910 gl_cv_decl_readlink_works=yes
21911 else
21912 gl_cv_decl_readlink_works=no
21913 fi
21914 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21915 fi
21916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
21917 $as_echo "$gl_cv_decl_readlink_works" >&6; }
21918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
21919 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
21920 if test "${gl_cv_func_readlink_works+set}" = set; then :
21921 $as_echo_n "(cached) " >&6
21922 else
21923 # We have readlink, so assume ln -s works.
21924 ln -s conftest.no-such conftest.link
21925 ln -s conftest.link conftest.lnk2
21926 if test "$cross_compiling" = yes; then :
21927 case "$host_os" in
21928 # Guess yes on glibc systems.
21929 *-gnu*) gl_cv_func_readlink_works="guessing yes" ;;
21930 # If we don't know, assume the worst.
21931 *) gl_cv_func_readlink_works="guessing no" ;;
21932 esac
21933
21934 else
21935 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21936 /* end confdefs.h. */
21937 #include <unistd.h>
21938
21939 int
21940 main ()
21941 {
21942 char buf[20];
21943 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
21944 ;
21945 return 0;
21946 }
21947 _ACEOF
21948 if ac_fn_c_try_run "$LINENO"; then :
21949 gl_cv_func_readlink_works=yes
21950 else
21951 gl_cv_func_readlink_works=no
21952 fi
21953 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21954 conftest.$ac_objext conftest.beam conftest.$ac_ext
21955 fi
21956
21957 rm -f conftest.link conftest.lnk2
21958 fi
21959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
21960 $as_echo "$gl_cv_func_readlink_works" >&6; }
21961 case "$gl_cv_func_readlink_works" in
21962 *yes)
21963 if test "$gl_cv_decl_readlink_works" != yes; then
21964 REPLACE_READLINK=1
21965 fi
21966 ;;
21967 *)
21968
21969 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
21970
21971 REPLACE_READLINK=1
21972 ;;
21973 esac
21974 fi
21975
21976 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
21977
21978
21979
21980
21981
21982
21983
21984
21985 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
21986
21987
21988 :
21989
21990 fi
21991
21992
21993
21994
21995
21996 GNULIB_READLINK=1
21997
21998
21999
22000
22001
22002
22003
22004
22005
22006
22007
22008
22009
22010
22011
22012
22013 if test $gl_cv_have_include_next = yes; then
22014 gl_cv_next_signal_h='<'signal.h'>'
22015 else
22016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
22017 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
22018 if test "${gl_cv_next_signal_h+set}" = set; then :
22019 $as_echo_n "(cached) " >&6
22020 else
22021
22022 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22023 /* end confdefs.h. */
22024 #include <signal.h>
22025
22026 _ACEOF
22027 case "$host_os" in
22028 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22029 *) gl_absname_cpp="$ac_cpp" ;;
22030 esac
22031
22032 case "$host_os" in
22033 mingw*)
22034 gl_dirsep_regex='[/\\]'
22035 ;;
22036 *)
22037 gl_dirsep_regex='\/'
22038 ;;
22039 esac
22040 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22041
22042 gl_header_literal_regex=`echo 'signal.h' \
22043 | sed -e "$gl_make_literal_regex_sed"`
22044 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22045 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22046 s|^/[^/]|//&|
22047 p
22048 q
22049 }'
22050 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22051 sed -n "$gl_absolute_header_sed"`'"'
22052
22053
22054 fi
22055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
22056 $as_echo "$gl_cv_next_signal_h" >&6; }
22057 fi
22058 NEXT_SIGNAL_H=$gl_cv_next_signal_h
22059
22060 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22061 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22062 gl_next_as_first_directive='<'signal.h'>'
22063 else
22064 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22065 gl_next_as_first_directive=$gl_cv_next_signal_h
22066 fi
22067 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
22068
22069
22070
22071
22072
22073 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
22074 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
22075 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
22076 #include <signal.h>
22077
22078 "
22079 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
22080
22081 else
22082 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
22083 fi
22084
22085
22086
22087
22088
22089
22090
22091 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
22092 #include <signal.h>
22093
22094 "
22095 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
22096
22097 else
22098 HAVE_SIGHANDLER_T=0
22099 fi
22100
22101
22102
22103
22104 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
22105 /* <sys/types.h> is not needed according to POSIX, but the
22106 <sys/socket.h> in i386-unknown-freebsd4.10 and
22107 powerpc-apple-darwin5.5 required it. */
22108 #include <sys/types.h>
22109 #if HAVE_SYS_SOCKET_H
22110 # include <sys/socket.h>
22111 #elif HAVE_WS2TCPIP_H
22112 # include <ws2tcpip.h>
22113 #endif
22114
22115 "
22116 if test "x$ac_cv_type_socklen_t" = x""yes; then :
22117
22118 else
22119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
22120 $as_echo_n "checking for socklen_t equivalent... " >&6; }
22121 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
22122 $as_echo_n "(cached) " >&6
22123 else
22124 # Systems have either "struct sockaddr *" or
22125 # "void *" as the second argument to getpeername
22126 gl_cv_socklen_t_equiv=
22127 for arg2 in "struct sockaddr" void; do
22128 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
22129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22130 /* end confdefs.h. */
22131 #include <sys/types.h>
22132 #include <sys/socket.h>
22133
22134 int getpeername (int, $arg2 *, $t *);
22135 int
22136 main ()
22137 {
22138 $t len;
22139 getpeername (0, 0, &len);
22140 ;
22141 return 0;
22142 }
22143 _ACEOF
22144 if ac_fn_c_try_compile "$LINENO"; then :
22145 gl_cv_socklen_t_equiv="$t"
22146 fi
22147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22148 test "$gl_cv_socklen_t_equiv" != "" && break
22149 done
22150 test "$gl_cv_socklen_t_equiv" != "" && break
22151 done
22152
22153 fi
22154
22155 if test "$gl_cv_socklen_t_equiv" = ""; then
22156 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
22157 fi
22158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
22159 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
22160
22161 cat >>confdefs.h <<_ACEOF
22162 #define socklen_t $gl_cv_socklen_t_equiv
22163 _ACEOF
22164
22165 fi
22166
22167
22168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
22169 $as_echo_n "checking for ssize_t... " >&6; }
22170 if test "${gt_cv_ssize_t+set}" = set; then :
22171 $as_echo_n "(cached) " >&6
22172 else
22173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22174 /* end confdefs.h. */
22175 #include <sys/types.h>
22176 int
22177 main ()
22178 {
22179 int x = sizeof (ssize_t *) + sizeof (ssize_t);
22180 return !x;
22181 ;
22182 return 0;
22183 }
22184 _ACEOF
22185 if ac_fn_c_try_compile "$LINENO"; then :
22186 gt_cv_ssize_t=yes
22187 else
22188 gt_cv_ssize_t=no
22189 fi
22190 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22191 fi
22192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
22193 $as_echo "$gt_cv_ssize_t" >&6; }
22194 if test $gt_cv_ssize_t = no; then
22195
22196 $as_echo "#define ssize_t int" >>confdefs.h
22197
22198 fi
22199
22200
22201
22202
22203
22204 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>
22205 #include <sys/stat.h>
22206 "
22207 if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = x""yes; then :
22208
22209 cat >>confdefs.h <<_ACEOF
22210 #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1
22211 _ACEOF
22212
22213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
22214 $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
22215 if test "${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+set}" = set; then :
22216 $as_echo_n "(cached) " >&6
22217 else
22218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22219 /* end confdefs.h. */
22220
22221 #include <sys/types.h>
22222 #include <sys/stat.h>
22223 #if HAVE_SYS_TIME_H
22224 # include <sys/time.h>
22225 #endif
22226 #include <time.h>
22227 struct timespec ts;
22228 struct stat st;
22229
22230 int
22231 main ()
22232 {
22233
22234 st.st_atim = ts;
22235
22236 ;
22237 return 0;
22238 }
22239 _ACEOF
22240 if ac_fn_c_try_compile "$LINENO"; then :
22241 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
22242 else
22243 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no
22244 fi
22245 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22246 fi
22247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
22248 $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
22249 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
22250
22251 $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
22252
22253 fi
22254 else
22255 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>
22256 #include <sys/stat.h>
22257 "
22258 if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = x""yes; then :
22259
22260 cat >>confdefs.h <<_ACEOF
22261 #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1
22262 _ACEOF
22263
22264
22265 else
22266 ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
22267 #include <sys/stat.h>
22268 "
22269 if test "x$ac_cv_member_struct_stat_st_atimensec" = x""yes; then :
22270
22271 cat >>confdefs.h <<_ACEOF
22272 #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1
22273 _ACEOF
22274
22275
22276 else
22277 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>
22278 #include <sys/stat.h>
22279 "
22280 if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = x""yes; then :
22281
22282 cat >>confdefs.h <<_ACEOF
22283 #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1
22284 _ACEOF
22285
22286
22287 fi
22288
22289 fi
22290
22291 fi
22292
22293 fi
22294
22295
22296
22297
22298
22299 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>
22300 #include <sys/stat.h>
22301 "
22302 if test "x$ac_cv_member_struct_stat_st_birthtimespec_tv_nsec" = x""yes; then :
22303
22304 cat >>confdefs.h <<_ACEOF
22305 #define HAVE_STRUCT_STAT_ST_BIRTHTIMESPEC_TV_NSEC 1
22306 _ACEOF
22307
22308
22309 else
22310 ac_fn_c_check_member "$LINENO" "struct stat" "st_birthtimensec" "ac_cv_member_struct_stat_st_birthtimensec" "#include <sys/types.h>
22311 #include <sys/stat.h>
22312 "
22313 if test "x$ac_cv_member_struct_stat_st_birthtimensec" = x""yes; then :
22314
22315 cat >>confdefs.h <<_ACEOF
22316 #define HAVE_STRUCT_STAT_ST_BIRTHTIMENSEC 1
22317 _ACEOF
22318
22319
22320 else
22321 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>
22322 #include <sys/stat.h>
22323 "
22324 if test "x$ac_cv_member_struct_stat_st_birthtim_tv_nsec" = x""yes; then :
22325
22326 cat >>confdefs.h <<_ACEOF
22327 #define HAVE_STRUCT_STAT_ST_BIRTHTIM_TV_NSEC 1
22328 _ACEOF
22329
22330
22331 fi
22332
22333 fi
22334
22335 fi
22336
22337
22338
22339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working stdalign.h" >&5
22340 $as_echo_n "checking for working stdalign.h... " >&6; }
22341 if test "${gl_cv_header_working_stdalign_h+set}" = set; then :
22342 $as_echo_n "(cached) " >&6
22343 else
22344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22345 /* end confdefs.h. */
22346 #include <stdalign.h>
22347 #include <stddef.h>
22348
22349 /* Test that alignof yields a result consistent with offsetof.
22350 This catches GCC bug 52023
22351 <http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52023>. */
22352 #ifdef __cplusplus
22353 template <class t> struct alignof_helper { char a; t b; };
22354 # define ao(type) offsetof (alignof_helper<type>, b)
22355 #else
22356 # define ao(type) offsetof (struct { char a; type b; }, b)
22357 #endif
22358 char test_double[ao (double) % _Alignof (double) == 0 ? 1 : -1];
22359 char test_long[ao (long int) % _Alignof (long int) == 0 ? 1 : -1];
22360 char test_alignof[alignof (double) == _Alignof (double) ? 1 : -1];
22361
22362 /* Test _Alignas only on platforms where gnulib can help. */
22363 #if \
22364 (__GNUC__ || __IBMC__ || __IBMCPP__ \
22365 || 0x5110 <= __SUNPRO_C || 1300 <= _MSC_VER)
22366 int alignas (8) alignas_int = 1;
22367 char test_alignas[_Alignof (alignas_int) == 8 ? 1 : -1];
22368 #endif
22369
22370 int
22371 main ()
22372 {
22373
22374 ;
22375 return 0;
22376 }
22377 _ACEOF
22378 if ac_fn_c_try_compile "$LINENO"; then :
22379 gl_cv_header_working_stdalign_h=yes
22380 else
22381 gl_cv_header_working_stdalign_h=no
22382 fi
22383 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22384 fi
22385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdalign_h" >&5
22386 $as_echo "$gl_cv_header_working_stdalign_h" >&6; }
22387
22388 if test $gl_cv_header_working_stdalign_h = yes; then
22389 STDALIGN_H=''
22390 else
22391 STDALIGN_H='stdalign.h'
22392 fi
22393
22394
22395 if test -n "$STDALIGN_H"; then
22396 GL_GENERATE_STDALIGN_H_TRUE=
22397 GL_GENERATE_STDALIGN_H_FALSE='#'
22398 else
22399 GL_GENERATE_STDALIGN_H_TRUE='#'
22400 GL_GENERATE_STDALIGN_H_FALSE=
22401 fi
22402
22403
22404
22405 STDARG_H=''
22406 NEXT_STDARG_H='<stdarg.h>'
22407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
22408 $as_echo_n "checking for va_copy... " >&6; }
22409 if test "${gl_cv_func_va_copy+set}" = set; then :
22410 $as_echo_n "(cached) " >&6
22411 else
22412
22413 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22414 /* end confdefs.h. */
22415 #include <stdarg.h>
22416 int
22417 main ()
22418 {
22419
22420 #ifndef va_copy
22421 void (*func) (va_list, va_list) = va_copy;
22422 #endif
22423
22424 ;
22425 return 0;
22426 }
22427 _ACEOF
22428 if ac_fn_c_try_compile "$LINENO"; then :
22429 gl_cv_func_va_copy=yes
22430 else
22431 gl_cv_func_va_copy=no
22432 fi
22433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22434 fi
22435
22436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
22437 $as_echo "$gl_cv_func_va_copy" >&6; }
22438 if test $gl_cv_func_va_copy = no; then
22439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22440 /* end confdefs.h. */
22441 #if defined _AIX && !defined __GNUC__
22442 AIX vaccine
22443 #endif
22444
22445 _ACEOF
22446 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22447 $EGREP "vaccine" >/dev/null 2>&1; then :
22448 gl_aixcc=yes
22449 else
22450 gl_aixcc=no
22451 fi
22452 rm -f conftest*
22453
22454 if test $gl_aixcc = yes; then
22455 STDARG_H=stdarg.h
22456
22457
22458
22459
22460
22461
22462
22463
22464 if test $gl_cv_have_include_next = yes; then
22465 gl_cv_next_stdarg_h='<'stdarg.h'>'
22466 else
22467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
22468 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
22469 if test "${gl_cv_next_stdarg_h+set}" = set; then :
22470 $as_echo_n "(cached) " >&6
22471 else
22472
22473 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22474 /* end confdefs.h. */
22475 #include <stdarg.h>
22476
22477 _ACEOF
22478 case "$host_os" in
22479 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22480 *) gl_absname_cpp="$ac_cpp" ;;
22481 esac
22482
22483 case "$host_os" in
22484 mingw*)
22485 gl_dirsep_regex='[/\\]'
22486 ;;
22487 *)
22488 gl_dirsep_regex='\/'
22489 ;;
22490 esac
22491 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22492
22493 gl_header_literal_regex=`echo 'stdarg.h' \
22494 | sed -e "$gl_make_literal_regex_sed"`
22495 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22496 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22497 s|^/[^/]|//&|
22498 p
22499 q
22500 }'
22501 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22502 sed -n "$gl_absolute_header_sed"`'"'
22503
22504
22505 fi
22506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
22507 $as_echo "$gl_cv_next_stdarg_h" >&6; }
22508 fi
22509 NEXT_STDARG_H=$gl_cv_next_stdarg_h
22510
22511 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22512 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22513 gl_next_as_first_directive='<'stdarg.h'>'
22514 else
22515 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22516 gl_next_as_first_directive=$gl_cv_next_stdarg_h
22517 fi
22518 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
22519
22520
22521
22522
22523 if test "$gl_cv_next_stdarg_h" = '""'; then
22524 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
22525 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
22526 fi
22527 else
22528
22529 saved_as_echo_n="$as_echo_n"
22530 as_echo_n=':'
22531 if test "${gl_cv_func___va_copy+set}" = set; then :
22532 $as_echo_n "(cached) " >&6
22533 else
22534
22535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22536 /* end confdefs.h. */
22537 #include <stdarg.h>
22538 int
22539 main ()
22540 {
22541
22542 #ifndef __va_copy
22543 error, bail out
22544 #endif
22545
22546 ;
22547 return 0;
22548 }
22549 _ACEOF
22550 if ac_fn_c_try_compile "$LINENO"; then :
22551 gl_cv_func___va_copy=yes
22552 else
22553 gl_cv_func___va_copy=no
22554 fi
22555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22556 fi
22557
22558 as_echo_n="$saved_as_echo_n"
22559
22560 if test $gl_cv_func___va_copy = yes; then
22561
22562 $as_echo "#define va_copy __va_copy" >>confdefs.h
22563
22564 else
22565
22566
22567 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
22568
22569 fi
22570 fi
22571 fi
22572
22573 if test -n "$STDARG_H"; then
22574 GL_GENERATE_STDARG_H_TRUE=
22575 GL_GENERATE_STDARG_H_FALSE='#'
22576 else
22577 GL_GENERATE_STDARG_H_TRUE='#'
22578 GL_GENERATE_STDARG_H_FALSE=
22579 fi
22580
22581
22582
22583
22584
22585
22586 # Define two additional variables used in the Makefile substitution.
22587
22588 if test "$ac_cv_header_stdbool_h" = yes; then
22589 STDBOOL_H=''
22590 else
22591 STDBOOL_H='stdbool.h'
22592 fi
22593
22594 if test -n "$STDBOOL_H"; then
22595 GL_GENERATE_STDBOOL_H_TRUE=
22596 GL_GENERATE_STDBOOL_H_FALSE='#'
22597 else
22598 GL_GENERATE_STDBOOL_H_TRUE='#'
22599 GL_GENERATE_STDBOOL_H_FALSE=
22600 fi
22601
22602
22603 if test "$ac_cv_type__Bool" = yes; then
22604 HAVE__BOOL=1
22605 else
22606 HAVE__BOOL=0
22607 fi
22608
22609
22610
22611
22612
22613 STDDEF_H=
22614 if test $gt_cv_c_wchar_t = no; then
22615 HAVE_WCHAR_T=0
22616 STDDEF_H=stddef.h
22617 fi
22618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
22619 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
22620 if test "${gl_cv_decl_null_works+set}" = set; then :
22621 $as_echo_n "(cached) " >&6
22622 else
22623 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22624 /* end confdefs.h. */
22625 #include <stddef.h>
22626 int test[2 * (sizeof NULL == sizeof (void *)) -1];
22627
22628 int
22629 main ()
22630 {
22631
22632 ;
22633 return 0;
22634 }
22635 _ACEOF
22636 if ac_fn_c_try_compile "$LINENO"; then :
22637 gl_cv_decl_null_works=yes
22638 else
22639 gl_cv_decl_null_works=no
22640 fi
22641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22642 fi
22643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
22644 $as_echo "$gl_cv_decl_null_works" >&6; }
22645 if test $gl_cv_decl_null_works = no; then
22646 REPLACE_NULL=1
22647 STDDEF_H=stddef.h
22648 fi
22649
22650 if test -n "$STDDEF_H"; then
22651 GL_GENERATE_STDDEF_H_TRUE=
22652 GL_GENERATE_STDDEF_H_FALSE='#'
22653 else
22654 GL_GENERATE_STDDEF_H_TRUE='#'
22655 GL_GENERATE_STDDEF_H_FALSE=
22656 fi
22657
22658 if test -n "$STDDEF_H"; then
22659
22660
22661
22662
22663
22664
22665
22666
22667 if test $gl_cv_have_include_next = yes; then
22668 gl_cv_next_stddef_h='<'stddef.h'>'
22669 else
22670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
22671 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
22672 if test "${gl_cv_next_stddef_h+set}" = set; then :
22673 $as_echo_n "(cached) " >&6
22674 else
22675
22676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22677 /* end confdefs.h. */
22678 #include <stddef.h>
22679
22680 _ACEOF
22681 case "$host_os" in
22682 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22683 *) gl_absname_cpp="$ac_cpp" ;;
22684 esac
22685
22686 case "$host_os" in
22687 mingw*)
22688 gl_dirsep_regex='[/\\]'
22689 ;;
22690 *)
22691 gl_dirsep_regex='\/'
22692 ;;
22693 esac
22694 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22695
22696 gl_header_literal_regex=`echo 'stddef.h' \
22697 | sed -e "$gl_make_literal_regex_sed"`
22698 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22699 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22700 s|^/[^/]|//&|
22701 p
22702 q
22703 }'
22704 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22705 sed -n "$gl_absolute_header_sed"`'"'
22706
22707
22708 fi
22709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
22710 $as_echo "$gl_cv_next_stddef_h" >&6; }
22711 fi
22712 NEXT_STDDEF_H=$gl_cv_next_stddef_h
22713
22714 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22715 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22716 gl_next_as_first_directive='<'stddef.h'>'
22717 else
22718 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22719 gl_next_as_first_directive=$gl_cv_next_stddef_h
22720 fi
22721 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
22722
22723
22724
22725
22726 fi
22727
22728
22729
22730
22731
22732
22733
22734
22735
22736
22737
22738
22739
22740 if test $gl_cv_have_include_next = yes; then
22741 gl_cv_next_stdio_h='<'stdio.h'>'
22742 else
22743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
22744 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
22745 if test "${gl_cv_next_stdio_h+set}" = set; then :
22746 $as_echo_n "(cached) " >&6
22747 else
22748
22749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22750 /* end confdefs.h. */
22751 #include <stdio.h>
22752
22753 _ACEOF
22754 case "$host_os" in
22755 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22756 *) gl_absname_cpp="$ac_cpp" ;;
22757 esac
22758
22759 case "$host_os" in
22760 mingw*)
22761 gl_dirsep_regex='[/\\]'
22762 ;;
22763 *)
22764 gl_dirsep_regex='\/'
22765 ;;
22766 esac
22767 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22768
22769 gl_header_literal_regex=`echo 'stdio.h' \
22770 | sed -e "$gl_make_literal_regex_sed"`
22771 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22772 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22773 s|^/[^/]|//&|
22774 p
22775 q
22776 }'
22777 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22778 sed -n "$gl_absolute_header_sed"`'"'
22779
22780
22781 fi
22782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
22783 $as_echo "$gl_cv_next_stdio_h" >&6; }
22784 fi
22785 NEXT_STDIO_H=$gl_cv_next_stdio_h
22786
22787 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22788 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22789 gl_next_as_first_directive='<'stdio.h'>'
22790 else
22791 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22792 gl_next_as_first_directive=$gl_cv_next_stdio_h
22793 fi
22794 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
22795
22796
22797
22798
22799
22800 GNULIB_FSCANF=1
22801
22802
22803 cat >>confdefs.h <<_ACEOF
22804 #define GNULIB_FSCANF 1
22805 _ACEOF
22806
22807
22808 GNULIB_SCANF=1
22809
22810
22811 cat >>confdefs.h <<_ACEOF
22812 #define GNULIB_SCANF 1
22813 _ACEOF
22814
22815
22816 GNULIB_FGETC=1
22817 GNULIB_GETC=1
22818 GNULIB_GETCHAR=1
22819 GNULIB_FGETS=1
22820 GNULIB_FREAD=1
22821
22822
22823 GNULIB_FPRINTF=1
22824 GNULIB_PRINTF=1
22825 GNULIB_VFPRINTF=1
22826 GNULIB_VPRINTF=1
22827 GNULIB_FPUTC=1
22828 GNULIB_PUTC=1
22829 GNULIB_PUTCHAR=1
22830 GNULIB_FPUTS=1
22831 GNULIB_PUTS=1
22832 GNULIB_FWRITE=1
22833
22834
22835
22836
22837
22838
22839
22840
22841
22842
22843
22844
22845
22846
22847
22848 if test $gl_cv_have_include_next = yes; then
22849 gl_cv_next_stdlib_h='<'stdlib.h'>'
22850 else
22851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
22852 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
22853 if test "${gl_cv_next_stdlib_h+set}" = set; then :
22854 $as_echo_n "(cached) " >&6
22855 else
22856
22857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22858 /* end confdefs.h. */
22859 #include <stdlib.h>
22860
22861 _ACEOF
22862 case "$host_os" in
22863 aix*) gl_absname_cpp="$ac_cpp -C" ;;
22864 *) gl_absname_cpp="$ac_cpp" ;;
22865 esac
22866
22867 case "$host_os" in
22868 mingw*)
22869 gl_dirsep_regex='[/\\]'
22870 ;;
22871 *)
22872 gl_dirsep_regex='\/'
22873 ;;
22874 esac
22875 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
22876
22877 gl_header_literal_regex=`echo 'stdlib.h' \
22878 | sed -e "$gl_make_literal_regex_sed"`
22879 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
22880 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
22881 s|^/[^/]|//&|
22882 p
22883 q
22884 }'
22885 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
22886 sed -n "$gl_absolute_header_sed"`'"'
22887
22888
22889 fi
22890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
22891 $as_echo "$gl_cv_next_stdlib_h" >&6; }
22892 fi
22893 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
22894
22895 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
22896 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
22897 gl_next_as_first_directive='<'stdlib.h'>'
22898 else
22899 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
22900 gl_next_as_first_directive=$gl_cv_next_stdlib_h
22901 fi
22902 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
22903
22904
22905
22906
22907
22908
22909
22910
22911
22912 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
22913
22914
22915
22916
22917
22918
22919
22920 $as_echo "#define my_strftime nstrftime" >>confdefs.h
22921
22922
22923
22924
22925
22926
22927
22928
22929 if test "$ac_cv_have_decl_strtoimax" != yes; then
22930 HAVE_DECL_STRTOIMAX=0
22931 fi
22932
22933 if test $ac_cv_func_strtoimax = yes; then
22934 HAVE_STRTOIMAX=1
22935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtoimax works" >&5
22936 $as_echo_n "checking whether strtoimax works... " >&6; }
22937 if test "${gl_cv_func_strtoimax+set}" = set; then :
22938 $as_echo_n "(cached) " >&6
22939 else
22940 if test "$cross_compiling" = yes; then :
22941 case "$host_os" in
22942 # Guess no on AIX 5.
22943 aix5*) gl_cv_func_strtoimax="guessing no" ;;
22944 # Guess yes otherwise.
22945 *) gl_cv_func_strtoimax="guessing yes" ;;
22946 esac
22947
22948 else
22949 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22950 /* end confdefs.h. */
22951
22952 #include <errno.h>
22953 #include <string.h>
22954 #include <inttypes.h>
22955 int main ()
22956 {
22957 if (sizeof (intmax_t) > sizeof (int))
22958 {
22959 const char *s = "4294967295";
22960 char *p;
22961 intmax_t res;
22962 errno = 0;
22963 res = strtoimax (s, &p, 10);
22964 if (p != s + strlen (s))
22965 return 1;
22966 if (errno != 0)
22967 return 2;
22968 if (res != (intmax_t) 65535 * (intmax_t) 65537)
22969 return 3;
22970 }
22971 else
22972 {
22973 const char *s = "2147483647";
22974 char *p;
22975 intmax_t res;
22976 errno = 0;
22977 res = strtoimax (s, &p, 10);
22978 if (p != s + strlen (s))
22979 return 1;
22980 if (errno != 0)
22981 return 2;
22982 if (res != 2147483647)
22983 return 3;
22984 }
22985 return 0;
22986 }
22987
22988 _ACEOF
22989 if ac_fn_c_try_run "$LINENO"; then :
22990 gl_cv_func_strtoimax=yes
22991 else
22992 gl_cv_func_strtoimax=no
22993 fi
22994 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22995 conftest.$ac_objext conftest.beam conftest.$ac_ext
22996 fi
22997
22998
22999 fi
23000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_strtoimax" >&5
23001 $as_echo "$gl_cv_func_strtoimax" >&6; }
23002 case "$gl_cv_func_strtoimax" in
23003 *no) REPLACE_STRTOIMAX=1 ;;
23004 esac
23005 else
23006 HAVE_STRTOIMAX=0
23007 fi
23008
23009 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
23010
23011
23012
23013
23014
23015
23016
23017
23018 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
23019
23020
23021 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
23022 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
23023 ac_have_decl=1
23024 else
23025 ac_have_decl=0
23026 fi
23027
23028 cat >>confdefs.h <<_ACEOF
23029 #define HAVE_DECL_STRTOLL $ac_have_decl
23030 _ACEOF
23031
23032
23033
23034 fi
23035
23036
23037
23038
23039
23040 GNULIB_STRTOIMAX=1
23041
23042
23043
23044
23045
23046
23047
23048
23049
23050 if test "$ac_cv_have_decl_strtoumax" != yes; then
23051 HAVE_DECL_STRTOUMAX=0
23052 fi
23053
23054 if test $ac_cv_func_strtoumax = no; then
23055
23056
23057
23058
23059
23060
23061
23062
23063 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
23064
23065
23066 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
23067 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
23068 ac_have_decl=1
23069 else
23070 ac_have_decl=0
23071 fi
23072
23073 cat >>confdefs.h <<_ACEOF
23074 #define HAVE_DECL_STRTOULL $ac_have_decl
23075 _ACEOF
23076
23077
23078
23079 fi
23080
23081
23082
23083
23084
23085 GNULIB_STRTOUMAX=1
23086
23087
23088
23089
23090
23091
23092
23093 if test $ac_cv_func_symlink = no; then
23094 HAVE_SYMLINK=0
23095 else
23096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
23097 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
23098 if test "${gl_cv_func_symlink_works+set}" = set; then :
23099 $as_echo_n "(cached) " >&6
23100 else
23101 if test "$cross_compiling" = yes; then :
23102 case "$host_os" in
23103 # Guess yes on glibc systems.
23104 *-gnu*) gl_cv_func_symlink_works="guessing yes" ;;
23105 # If we don't know, assume the worst.
23106 *) gl_cv_func_symlink_works="guessing no" ;;
23107 esac
23108
23109 else
23110 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23111 /* end confdefs.h. */
23112 #include <unistd.h>
23113
23114 int
23115 main ()
23116 {
23117 int result = 0;
23118 if (!symlink ("a", "conftest.link/"))
23119 result |= 1;
23120 if (symlink ("conftest.f", "conftest.lnk2"))
23121 result |= 2;
23122 else if (!symlink ("a", "conftest.lnk2/"))
23123 result |= 4;
23124 return result;
23125
23126 ;
23127 return 0;
23128 }
23129 _ACEOF
23130 if ac_fn_c_try_run "$LINENO"; then :
23131 gl_cv_func_symlink_works=yes
23132 else
23133 gl_cv_func_symlink_works=no
23134 fi
23135 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23136 conftest.$ac_objext conftest.beam conftest.$ac_ext
23137 fi
23138
23139 rm -f conftest.f conftest.link conftest.lnk2
23140 fi
23141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
23142 $as_echo "$gl_cv_func_symlink_works" >&6; }
23143 case "$gl_cv_func_symlink_works" in
23144 *yes) ;;
23145 *)
23146 REPLACE_SYMLINK=1
23147 ;;
23148 esac
23149 fi
23150
23151 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
23152
23153
23154
23155
23156
23157
23158
23159
23160 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
23161
23162 fi
23163
23164
23165
23166
23167
23168 GNULIB_SYMLINK=1
23169
23170
23171
23172
23173
23174
23175
23176
23177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether <sys/select.h> is self-contained" >&5
23178 $as_echo_n "checking whether <sys/select.h> is self-contained... " >&6; }
23179 if test "${gl_cv_header_sys_select_h_selfcontained+set}" = set; then :
23180 $as_echo_n "(cached) " >&6
23181 else
23182
23183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23184 /* end confdefs.h. */
23185 #include <sys/select.h>
23186 int
23187 main ()
23188 {
23189 struct timeval b;
23190 ;
23191 return 0;
23192 }
23193 _ACEOF
23194 if ac_fn_c_try_compile "$LINENO"; then :
23195 gl_cv_header_sys_select_h_selfcontained=yes
23196 else
23197 gl_cv_header_sys_select_h_selfcontained=no
23198 fi
23199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23200 if test $gl_cv_header_sys_select_h_selfcontained = yes; then
23201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23202 /* end confdefs.h. */
23203 #include <sys/select.h>
23204 int
23205 main ()
23206 {
23207 int memset; int bzero;
23208 ;
23209 return 0;
23210 }
23211
23212 _ACEOF
23213 if ac_fn_c_try_compile "$LINENO"; then :
23214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23215 /* end confdefs.h. */
23216 #include <sys/select.h>
23217 int
23218 main ()
23219 {
23220
23221 #undef memset
23222 #define memset nonexistent_memset
23223 extern
23224 #ifdef __cplusplus
23225 "C"
23226 #endif
23227 void *memset (void *, int, unsigned long);
23228 #undef bzero
23229 #define bzero nonexistent_bzero
23230 extern
23231 #ifdef __cplusplus
23232 "C"
23233 #endif
23234 void bzero (void *, unsigned long);
23235 fd_set fds;
23236 FD_ZERO (&fds);
23237
23238 ;
23239 return 0;
23240 }
23241
23242 _ACEOF
23243 if ac_fn_c_try_link "$LINENO"; then :
23244
23245 else
23246 gl_cv_header_sys_select_h_selfcontained=no
23247 fi
23248 rm -f core conftest.err conftest.$ac_objext \
23249 conftest$ac_exeext conftest.$ac_ext
23250
23251 fi
23252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23253 fi
23254
23255 fi
23256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_sys_select_h_selfcontained" >&5
23257 $as_echo "$gl_cv_header_sys_select_h_selfcontained" >&6; }
23258
23259
23260
23261
23262
23263
23264
23265
23266
23267 if test $gl_cv_have_include_next = yes; then
23268 gl_cv_next_sys_select_h='<'sys/select.h'>'
23269 else
23270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/select.h>" >&5
23271 $as_echo_n "checking absolute name of <sys/select.h>... " >&6; }
23272 if test "${gl_cv_next_sys_select_h+set}" = set; then :
23273 $as_echo_n "(cached) " >&6
23274 else
23275
23276 if test $ac_cv_header_sys_select_h = yes; then
23277
23278
23279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23280 /* end confdefs.h. */
23281 #include <sys/select.h>
23282
23283 _ACEOF
23284 case "$host_os" in
23285 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23286 *) gl_absname_cpp="$ac_cpp" ;;
23287 esac
23288
23289 case "$host_os" in
23290 mingw*)
23291 gl_dirsep_regex='[/\\]'
23292 ;;
23293 *)
23294 gl_dirsep_regex='\/'
23295 ;;
23296 esac
23297 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23298
23299 gl_header_literal_regex=`echo 'sys/select.h' \
23300 | sed -e "$gl_make_literal_regex_sed"`
23301 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23302 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23303 s|^/[^/]|//&|
23304 p
23305 q
23306 }'
23307 gl_cv_next_sys_select_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23308 sed -n "$gl_absolute_header_sed"`'"'
23309 else
23310 gl_cv_next_sys_select_h='<'sys/select.h'>'
23311 fi
23312
23313
23314 fi
23315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_select_h" >&5
23316 $as_echo "$gl_cv_next_sys_select_h" >&6; }
23317 fi
23318 NEXT_SYS_SELECT_H=$gl_cv_next_sys_select_h
23319
23320 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23321 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23322 gl_next_as_first_directive='<'sys/select.h'>'
23323 else
23324 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23325 gl_next_as_first_directive=$gl_cv_next_sys_select_h
23326 fi
23327 NEXT_AS_FIRST_DIRECTIVE_SYS_SELECT_H=$gl_next_as_first_directive
23328
23329
23330
23331
23332 if test $ac_cv_header_sys_select_h = yes; then
23333 HAVE_SYS_SELECT_H=1
23334 else
23335 HAVE_SYS_SELECT_H=0
23336 fi
23337
23338
23339
23340
23341
23342 if test $ac_cv_header_sys_socket_h != yes; then
23343 for ac_header in winsock2.h
23344 do :
23345 ac_fn_c_check_header_mongrel "$LINENO" "winsock2.h" "ac_cv_header_winsock2_h" "$ac_includes_default"
23346 if test "x$ac_cv_header_winsock2_h" = x""yes; then :
23347 cat >>confdefs.h <<_ACEOF
23348 #define HAVE_WINSOCK2_H 1
23349 _ACEOF
23350
23351 fi
23352
23353 done
23354
23355 fi
23356 if test "$ac_cv_header_winsock2_h" = yes; then
23357 HAVE_WINSOCK2_H=1
23358 UNISTD_H_HAVE_WINSOCK2_H=1
23359 SYS_IOCTL_H_HAVE_WINSOCK2_H=1
23360 else
23361 HAVE_WINSOCK2_H=0
23362 fi
23363
23364
23365
23366
23367
23368
23369
23370
23371
23372
23373
23374
23375
23376
23377
23378
23379
23380
23381
23382
23383
23384
23385 if test $gl_cv_have_include_next = yes; then
23386 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23387 else
23388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
23389 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
23390 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
23391 $as_echo_n "(cached) " >&6
23392 else
23393
23394 if test $ac_cv_header_sys_stat_h = yes; then
23395
23396
23397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23398 /* end confdefs.h. */
23399 #include <sys/stat.h>
23400
23401 _ACEOF
23402 case "$host_os" in
23403 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23404 *) gl_absname_cpp="$ac_cpp" ;;
23405 esac
23406
23407 case "$host_os" in
23408 mingw*)
23409 gl_dirsep_regex='[/\\]'
23410 ;;
23411 *)
23412 gl_dirsep_regex='\/'
23413 ;;
23414 esac
23415 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23416
23417 gl_header_literal_regex=`echo 'sys/stat.h' \
23418 | sed -e "$gl_make_literal_regex_sed"`
23419 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23420 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23421 s|^/[^/]|//&|
23422 p
23423 q
23424 }'
23425 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23426 sed -n "$gl_absolute_header_sed"`'"'
23427 else
23428 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
23429 fi
23430
23431
23432 fi
23433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
23434 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
23435 fi
23436 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
23437
23438 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23439 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23440 gl_next_as_first_directive='<'sys/stat.h'>'
23441 else
23442 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23443 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
23444 fi
23445 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
23446
23447
23448
23449
23450
23451
23452
23453
23454
23455
23456
23457 if test $WINDOWS_64_BIT_ST_SIZE = 1; then
23458
23459 $as_echo "#define _GL_WINDOWS_64_BIT_ST_SIZE 1" >>confdefs.h
23460
23461 fi
23462
23463 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
23464 #include <sys/stat.h>
23465 "
23466 if test "x$ac_cv_type_nlink_t" = x""yes; then :
23467
23468 else
23469
23470 $as_echo "#define nlink_t int" >>confdefs.h
23471
23472 fi
23473
23474
23475
23476
23477
23478
23479
23480
23481
23482
23483
23484
23485
23486
23487
23488
23489
23490
23491 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "#include <time.h>
23492 "
23493 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
23494 ac_have_decl=1
23495 else
23496 ac_have_decl=0
23497 fi
23498
23499 cat >>confdefs.h <<_ACEOF
23500 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
23501 _ACEOF
23502
23503 if test $ac_cv_have_decl_localtime_r = no; then
23504 HAVE_DECL_LOCALTIME_R=0
23505 fi
23506
23507
23508 if test $ac_cv_func_localtime_r = yes; then
23509 HAVE_LOCALTIME_R=1
23510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
23511 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
23512 if test "${gl_cv_time_r_posix+set}" = set; then :
23513 $as_echo_n "(cached) " >&6
23514 else
23515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23516 /* end confdefs.h. */
23517 #include <time.h>
23518 int
23519 main ()
23520 {
23521 /* We don't need to append 'restrict's to the argument types,
23522 even though the POSIX signature has the 'restrict's,
23523 since C99 says they can't affect type compatibility. */
23524 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
23525 if (ptr) return 0;
23526 /* Check the return type is a pointer.
23527 On HP-UX 10 it is 'int'. */
23528 *localtime_r (0, 0);
23529 ;
23530 return 0;
23531 }
23532
23533 _ACEOF
23534 if ac_fn_c_try_compile "$LINENO"; then :
23535 gl_cv_time_r_posix=yes
23536 else
23537 gl_cv_time_r_posix=no
23538 fi
23539 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23540
23541 fi
23542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
23543 $as_echo "$gl_cv_time_r_posix" >&6; }
23544 if test $gl_cv_time_r_posix = yes; then
23545 REPLACE_LOCALTIME_R=0
23546 else
23547 REPLACE_LOCALTIME_R=1
23548 fi
23549 else
23550 HAVE_LOCALTIME_R=0
23551 fi
23552
23553 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
23554
23555
23556
23557
23558
23559
23560
23561
23562 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
23563
23564
23565 :
23566
23567 fi
23568
23569
23570
23571
23572
23573 GNULIB_TIME_R=1
23574
23575
23576
23577
23578
23579 :
23580
23581
23582
23583
23584
23585
23586
23587
23588
23589
23590
23591
23592
23593 if test $gl_cv_have_include_next = yes; then
23594 gl_cv_next_unistd_h='<'unistd.h'>'
23595 else
23596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
23597 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
23598 if test "${gl_cv_next_unistd_h+set}" = set; then :
23599 $as_echo_n "(cached) " >&6
23600 else
23601
23602 if test $ac_cv_header_unistd_h = yes; then
23603
23604
23605 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23606 /* end confdefs.h. */
23607 #include <unistd.h>
23608
23609 _ACEOF
23610 case "$host_os" in
23611 aix*) gl_absname_cpp="$ac_cpp -C" ;;
23612 *) gl_absname_cpp="$ac_cpp" ;;
23613 esac
23614
23615 case "$host_os" in
23616 mingw*)
23617 gl_dirsep_regex='[/\\]'
23618 ;;
23619 *)
23620 gl_dirsep_regex='\/'
23621 ;;
23622 esac
23623 gl_make_literal_regex_sed='s,[]$^\\.*/[],\\&,g'
23624
23625 gl_header_literal_regex=`echo 'unistd.h' \
23626 | sed -e "$gl_make_literal_regex_sed"`
23627 gl_absolute_header_sed="/${gl_dirsep_regex}${gl_header_literal_regex}/"'{
23628 s/.*"\(.*'"${gl_dirsep_regex}${gl_header_literal_regex}"'\)".*/\1/
23629 s|^/[^/]|//&|
23630 p
23631 q
23632 }'
23633 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
23634 sed -n "$gl_absolute_header_sed"`'"'
23635 else
23636 gl_cv_next_unistd_h='<'unistd.h'>'
23637 fi
23638
23639
23640 fi
23641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
23642 $as_echo "$gl_cv_next_unistd_h" >&6; }
23643 fi
23644 NEXT_UNISTD_H=$gl_cv_next_unistd_h
23645
23646 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
23647 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
23648 gl_next_as_first_directive='<'unistd.h'>'
23649 else
23650 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
23651 gl_next_as_first_directive=$gl_cv_next_unistd_h
23652 fi
23653 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
23654
23655
23656
23657
23658 if test $ac_cv_header_unistd_h = yes; then
23659 HAVE_UNISTD_H=1
23660 else
23661 HAVE_UNISTD_H=0
23662 fi
23663
23664
23665
23666
23667
23668
23669
23670
23671
23672
23673
23674
23675
23676
23677 if test $ac_cv_func_futimens = no && test $ac_cv_func_futimesat = yes; then
23678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether futimesat handles NULL file" >&5
23679 $as_echo_n "checking whether futimesat handles NULL file... " >&6; }
23680 if test "${gl_cv_func_futimesat_works+set}" = set; then :
23681 $as_echo_n "(cached) " >&6
23682 else
23683 touch conftest.file
23684 if test "$cross_compiling" = yes; then :
23685 case "$host_os" in
23686 # Guess yes on glibc systems.
23687 *-gnu*) gl_cv_func_futimesat_works="guessing yes" ;;
23688 # If we don't know, assume the worst.
23689 *) gl_cv_func_futimesat_works="guessing no" ;;
23690 esac
23691
23692 else
23693 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23694 /* end confdefs.h. */
23695
23696 #include <stddef.h>
23697 #include <sys/times.h>
23698 #include <fcntl.h>
23699
23700 int
23701 main ()
23702 {
23703 int fd = open ("conftest.file", O_RDWR);
23704 if (fd < 0) return 1;
23705 if (futimesat (fd, NULL, NULL)) return 2;
23706
23707 ;
23708 return 0;
23709 }
23710 _ACEOF
23711 if ac_fn_c_try_run "$LINENO"; then :
23712 gl_cv_func_futimesat_works=yes
23713 else
23714 gl_cv_func_futimesat_works=no
23715 fi
23716 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23717 conftest.$ac_objext conftest.beam conftest.$ac_ext
23718 fi
23719
23720 rm -f conftest.file
23721 fi
23722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_futimesat_works" >&5
23723 $as_echo "$gl_cv_func_futimesat_works" >&6; }
23724 case "$gl_cv_func_futimesat_works" in
23725 *yes) ;;
23726 *)
23727
23728 $as_echo "#define FUTIMESAT_NULL_BUG 1" >>confdefs.h
23729
23730 ;;
23731 esac
23732 fi
23733
23734 gl_gnulib_enabled_dosname=false
23735 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
23736 gl_gnulib_enabled_pathmax=false
23737 gl_gnulib_enabled_stat=false
23738 gl_gnulib_enabled_strtoll=false
23739 gl_gnulib_enabled_strtoull=false
23740 gl_gnulib_enabled_verify=false
23741 func_gl_gnulib_m4code_dosname ()
23742 {
23743 if ! $gl_gnulib_enabled_dosname; then
23744 gl_gnulib_enabled_dosname=true
23745 fi
23746 }
23747 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
23748 {
23749 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
23750
23751
23752 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
23753 fi
23754 }
23755 func_gl_gnulib_m4code_pathmax ()
23756 {
23757 if ! $gl_gnulib_enabled_pathmax; then
23758
23759
23760
23761 gl_gnulib_enabled_pathmax=true
23762 fi
23763 }
23764 func_gl_gnulib_m4code_stat ()
23765 {
23766 if ! $gl_gnulib_enabled_stat; then
23767
23768
23769
23770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
23771 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
23772 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
23773 $as_echo_n "(cached) " >&6
23774 else
23775 if test "$cross_compiling" = yes; then :
23776 case $host_os in
23777 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
23778 *) gl_cv_func_stat_dir_slash="guessing yes";;
23779 esac
23780 else
23781 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23782 /* end confdefs.h. */
23783 #include <sys/stat.h>
23784
23785 int
23786 main ()
23787 {
23788 struct stat st; return stat (".", &st) != stat ("./", &st);
23789 ;
23790 return 0;
23791 }
23792 _ACEOF
23793 if ac_fn_c_try_run "$LINENO"; then :
23794 gl_cv_func_stat_dir_slash=yes
23795 else
23796 gl_cv_func_stat_dir_slash=no
23797 fi
23798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23799 conftest.$ac_objext conftest.beam conftest.$ac_ext
23800 fi
23801
23802 fi
23803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
23804 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
23805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
23806 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
23807 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
23808 $as_echo_n "(cached) " >&6
23809 else
23810 touch conftest.tmp
23811 # Assume that if we have lstat, we can also check symlinks.
23812 if test $ac_cv_func_lstat = yes; then
23813 ln -s conftest.tmp conftest.lnk
23814 fi
23815 if test "$cross_compiling" = yes; then :
23816 case "$host_os" in
23817 # Guess yes on glibc systems.
23818 *-gnu*) gl_cv_func_stat_file_slash="guessing yes" ;;
23819 # If we don't know, assume the worst.
23820 *) gl_cv_func_stat_file_slash="guessing no" ;;
23821 esac
23822
23823 else
23824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
23825 /* end confdefs.h. */
23826 #include <sys/stat.h>
23827
23828 int
23829 main ()
23830 {
23831 int result = 0;
23832 struct stat st;
23833 if (!stat ("conftest.tmp/", &st))
23834 result |= 1;
23835 #if HAVE_LSTAT
23836 if (!stat ("conftest.lnk/", &st))
23837 result |= 2;
23838 #endif
23839 return result;
23840
23841 ;
23842 return 0;
23843 }
23844 _ACEOF
23845 if ac_fn_c_try_run "$LINENO"; then :
23846 gl_cv_func_stat_file_slash=yes
23847 else
23848 gl_cv_func_stat_file_slash=no
23849 fi
23850 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
23851 conftest.$ac_objext conftest.beam conftest.$ac_ext
23852 fi
23853
23854 rm -f conftest.tmp conftest.lnk
23855 fi
23856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
23857 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
23858 case $gl_cv_func_stat_dir_slash in
23859 *no) REPLACE_STAT=1
23860
23861 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
23862 ;;
23863 esac
23864 case $gl_cv_func_stat_file_slash in
23865 *no) REPLACE_STAT=1
23866
23867 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
23868 ;;
23869 esac
23870
23871 if test $REPLACE_STAT = 1; then
23872
23873
23874
23875
23876
23877
23878
23879
23880 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
23881
23882
23883
23884 :
23885
23886 fi
23887
23888
23889
23890
23891
23892 GNULIB_STAT=1
23893
23894
23895
23896
23897
23898 gl_gnulib_enabled_stat=true
23899 if test $REPLACE_STAT = 1; then
23900 func_gl_gnulib_m4code_dosname
23901 fi
23902 if test $REPLACE_STAT = 1; then
23903 func_gl_gnulib_m4code_pathmax
23904 fi
23905 if test $REPLACE_STAT = 1; then
23906 func_gl_gnulib_m4code_verify
23907 fi
23908 fi
23909 }
23910 func_gl_gnulib_m4code_strtoll ()
23911 {
23912 if ! $gl_gnulib_enabled_strtoll; then
23913
23914
23915
23916 if test "$ac_cv_type_long_long_int" = yes; then
23917 for ac_func in strtoll
23918 do :
23919 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
23920 if test "x$ac_cv_func_strtoll" = x""yes; then :
23921 cat >>confdefs.h <<_ACEOF
23922 #define HAVE_STRTOLL 1
23923 _ACEOF
23924
23925 fi
23926 done
23927
23928 if test $ac_cv_func_strtoll = no; then
23929 HAVE_STRTOLL=0
23930 fi
23931 fi
23932
23933 if test $HAVE_STRTOLL = 0; then
23934
23935
23936
23937
23938
23939
23940
23941
23942 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
23943
23944
23945 :
23946
23947 fi
23948
23949
23950
23951
23952
23953 GNULIB_STRTOLL=1
23954
23955
23956
23957
23958
23959 gl_gnulib_enabled_strtoll=true
23960 fi
23961 }
23962 func_gl_gnulib_m4code_strtoull ()
23963 {
23964 if ! $gl_gnulib_enabled_strtoull; then
23965
23966
23967
23968 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
23969 for ac_func in strtoull
23970 do :
23971 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
23972 if test "x$ac_cv_func_strtoull" = x""yes; then :
23973 cat >>confdefs.h <<_ACEOF
23974 #define HAVE_STRTOULL 1
23975 _ACEOF
23976
23977 fi
23978 done
23979
23980 if test $ac_cv_func_strtoull = no; then
23981 HAVE_STRTOULL=0
23982 fi
23983 fi
23984
23985 if test $HAVE_STRTOULL = 0; then
23986
23987
23988
23989
23990
23991
23992
23993
23994 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
23995
23996
23997 :
23998
23999 fi
24000
24001
24002
24003
24004
24005 GNULIB_STRTOULL=1
24006
24007
24008
24009
24010
24011 gl_gnulib_enabled_strtoull=true
24012 fi
24013 }
24014 func_gl_gnulib_m4code_verify ()
24015 {
24016 if ! $gl_gnulib_enabled_verify; then
24017 gl_gnulib_enabled_verify=true
24018 fi
24019 }
24020 if test $REPLACE_GETOPT = 1; then
24021 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
24022 fi
24023 if test $REPLACE_LSTAT = 1; then
24024 func_gl_gnulib_m4code_dosname
24025 fi
24026 if test $REPLACE_LSTAT = 1; then
24027 func_gl_gnulib_m4code_stat
24028 fi
24029 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
24030 func_gl_gnulib_m4code_stat
24031 fi
24032 if { test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; } && test $ac_cv_type_long_long_int = yes; then
24033 func_gl_gnulib_m4code_strtoll
24034 fi
24035 if test $HAVE_STRTOIMAX = 0 || test $REPLACE_STRTOIMAX = 1; then
24036 func_gl_gnulib_m4code_verify
24037 fi
24038 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
24039 func_gl_gnulib_m4code_strtoull
24040 fi
24041 if test $ac_cv_func_strtoumax = no; then
24042 func_gl_gnulib_m4code_verify
24043 fi
24044
24045 if $gl_gnulib_enabled_dosname; then
24046 gl_GNULIB_ENABLED_dosname_TRUE=
24047 gl_GNULIB_ENABLED_dosname_FALSE='#'
24048 else
24049 gl_GNULIB_ENABLED_dosname_TRUE='#'
24050 gl_GNULIB_ENABLED_dosname_FALSE=
24051 fi
24052
24053 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
24054 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
24055 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
24056 else
24057 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
24058 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
24059 fi
24060
24061 if $gl_gnulib_enabled_pathmax; then
24062 gl_GNULIB_ENABLED_pathmax_TRUE=
24063 gl_GNULIB_ENABLED_pathmax_FALSE='#'
24064 else
24065 gl_GNULIB_ENABLED_pathmax_TRUE='#'
24066 gl_GNULIB_ENABLED_pathmax_FALSE=
24067 fi
24068
24069 if $gl_gnulib_enabled_stat; then
24070 gl_GNULIB_ENABLED_stat_TRUE=
24071 gl_GNULIB_ENABLED_stat_FALSE='#'
24072 else
24073 gl_GNULIB_ENABLED_stat_TRUE='#'
24074 gl_GNULIB_ENABLED_stat_FALSE=
24075 fi
24076
24077 if $gl_gnulib_enabled_strtoll; then
24078 gl_GNULIB_ENABLED_strtoll_TRUE=
24079 gl_GNULIB_ENABLED_strtoll_FALSE='#'
24080 else
24081 gl_GNULIB_ENABLED_strtoll_TRUE='#'
24082 gl_GNULIB_ENABLED_strtoll_FALSE=
24083 fi
24084
24085 if $gl_gnulib_enabled_strtoull; then
24086 gl_GNULIB_ENABLED_strtoull_TRUE=
24087 gl_GNULIB_ENABLED_strtoull_FALSE='#'
24088 else
24089 gl_GNULIB_ENABLED_strtoull_TRUE='#'
24090 gl_GNULIB_ENABLED_strtoull_FALSE=
24091 fi
24092
24093 if $gl_gnulib_enabled_verify; then
24094 gl_GNULIB_ENABLED_verify_TRUE=
24095 gl_GNULIB_ENABLED_verify_FALSE='#'
24096 else
24097 gl_GNULIB_ENABLED_verify_TRUE='#'
24098 gl_GNULIB_ENABLED_verify_FALSE=
24099 fi
24100
24101 # End of code from modules
24102
24103
24104
24105
24106
24107
24108
24109
24110
24111 gltests_libdeps=
24112 gltests_ltlibdeps=
24113
24114
24115
24116
24117
24118
24119
24120
24121
24122 gl_source_base='tests'
24123 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
24124
24125 gl_module_indicator_condition=$gltests_WITNESS
24126
24127
24128
24129
24130
24131
24132
24133
24134
24135
24136 LIBGNU_LIBDEPS="$gl_libdeps"
24137
24138 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
24139
24140
24141 CFLAGS=$SAVE_CFLAGS
24142 LIBS=$SAVE_LIBS
24143
24144 case "$opsys" in
24145 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
24146
24147 darwin)
24148 ## The -headerpad option tells ld (see man page) to leave room at the
24149 ## end of the header for adding load commands. Needed for dumping.
24150 ## 0x690 is the total size of 30 segment load commands (at 56
24151 ## each); under Cocoa 31 commands are required.
24152 if test "$HAVE_NS" = "yes"; then
24153 libs_nsgui="-framework AppKit"
24154 headerpad_extra=6C8
24155 else
24156 libs_nsgui=
24157 headerpad_extra=690
24158 fi
24159 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
24160
24161 ## This is here because src/Makefile.in did some extra fiddling around
24162 ## with LD_SWITCH_SYSTEM. The cpp logic was:
24163 ## #ifndef LD_SWITCH_SYSTEM
24164 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
24165 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
24166 ## not using gcc, darwin.
24167 ## Because this was done in src/Makefile.in, the resulting part of
24168 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
24169 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
24170 ## rather than LD_SWITCH_SYSTEM.
24171 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
24172 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
24173 ;;
24174
24175 ## LD_SWITCH_X_SITE_RPATH is a -rpath option saying where to
24176 ## find X at run-time.
24177 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at the
24178 ## point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_RPATH
24179 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
24180 ## had different values in configure (in ac_link) and src/Makefile.in.
24181 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
24182 gnu*) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_RPATH)" ;;
24183
24184 *) LD_SWITCH_SYSTEM_TEMACS= ;;
24185 esac
24186
24187 if test "$NS_IMPL_GNUSTEP" = "yes"; then
24188 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
24189 fi
24190
24191
24192
24193
24194 LD_FIRSTFLAG=
24195 ORDINARY_LINK=
24196 case "$opsys" in
24197 ## gnu: GNU needs its own crt0.
24198 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
24199
24200 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
24201 ## library search parth, i.e. it won't search /usr/lib for libc and
24202 ## friends. Using -nostartfiles instead avoids this problem, and
24203 ## will also work on earlier NetBSD releases.
24204 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
24205
24206 ## powerpc*: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
24207 ## MkLinux/LinuxPPC needs this.
24208 ## s390x-* only supports opsys = gnu-linux so it can be added here.
24209 gnu-*)
24210 case "$canonical" in
24211 powerpc*|s390x-*) LD_FIRSTFLAG="-nostdlib" ;;
24212 esac
24213 ;;
24214 esac
24215
24216
24217 if test "x$ORDINARY_LINK" = "xyes"; then
24218
24219 LD_FIRSTFLAG=""
24220
24221 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
24222
24223
24224 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
24225 ## freebsd, gnu-* not on powerpc*|s390x*.
24226 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
24227
24228 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
24229 ## places that are difficult to figure out at make time. Fortunately,
24230 ## these same versions allow you to pass arbitrary flags on to the
24231 ## linker, so there is no reason not to use it as a linker.
24232 ##
24233 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
24234 ## searching for libraries in its internal directories, so we have to
24235 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
24236 LD_FIRSTFLAG="-nostdlib"
24237 fi
24238
24239 ## FIXME? What setting of EDIT_LDFLAGS should this have?
24240 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
24241
24242
24243
24244
24245 ## FIXME? The logic here is not precisely the same as that above.
24246 ## There is no check here for a pre-defined LD_FIRSTFLAG.
24247 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
24248 LIB_GCC=
24249 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
24250
24251 case "$opsys" in
24252 freebsd|netbsd|openbsd) LIB_GCC= ;;
24253
24254 gnu-*)
24255 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
24256 ## build on ARM EABI under GNU/Linux. (Bug#5518)
24257 case $host_cpu in
24258 arm*)
24259 LIB_GCC="-lgcc_s"
24260 ;;
24261 *)
24262 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
24263 ## immediately undefine it again and redefine it to empty.
24264 ## Was the C_SWITCH_X_SITE part really necessary?
24265 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
24266 LIB_GCC=
24267 ;;
24268 esac
24269 ;;
24270
24271 ## Ask GCC where to find libgcc.a.
24272 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
24273 esac
24274 fi
24275
24276 ## Common for all window systems
24277 if test "$window_system" != "none"; then
24278
24279 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
24280
24281
24282 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
24283
24284 WINDOW_SYSTEM_OBJ="fontset.o fringe.o image.o"
24285 fi
24286
24287
24288
24289
24290
24291 #### Report on what we decided to do.
24292 #### Report GTK as a toolkit, even if it doesn't use Xt.
24293 #### It makes printing result more understandable as using GTK sets
24294 #### toolkit_scroll_bars to yes by default.
24295 if test "${HAVE_GTK}" = "yes"; then
24296 USE_X_TOOLKIT=GTK
24297 fi
24298
24299 echo "
24300 Configured for \`${canonical}'.
24301
24302 Where should the build process find the source code? ${srcdir}
24303 What compiler should emacs be built with? ${CC} ${CFLAGS}
24304 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
24305 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
24306 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
24307 What window system should Emacs use? ${window_system}
24308 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
24309
24310 if test -n "${x_includes}"; then
24311 echo " Where do we find X Windows header files? ${x_includes}"
24312 else
24313 echo " Where do we find X Windows header files? Standard dirs"
24314 fi
24315 if test -n "${x_libraries}"; then
24316 echo " Where do we find X Windows libraries? ${x_libraries}"
24317 else
24318 echo " Where do we find X Windows libraries? Standard dirs"
24319 fi
24320
24321 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
24322 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
24323 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
24324 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
24325 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
24326 echo " Does Emacs use -lpng? ${HAVE_PNG}"
24327 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
24328 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
24329
24330 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
24331 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
24332 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
24333 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
24334 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
24335 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
24336 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
24337
24338 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
24339 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
24340 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
24341 echo " Does Emacs use -lxft? ${HAVE_XFT}"
24342
24343 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
24344 echo
24345
24346 if test -n "${EMACSDATA}"; then
24347 echo " Environment variable EMACSDATA set to: $EMACSDATA"
24348 fi
24349 if test -n "${EMACSDOC}"; then
24350 echo " Environment variable EMACSDOC set to: $EMACSDOC"
24351 fi
24352
24353 echo
24354
24355 if test "$HAVE_NS" = "yes"; then
24356 echo
24357 echo "You must run \"${MAKE-make} install\" in order to test the built application.
24358 The installed application will go to nextstep/Emacs.app and can be
24359 run or moved from there."
24360 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
24361 echo "The application will be fully self-contained."
24362 else
24363 echo "The lisp resources for the application will be installed under ${prefix}.
24364 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
24365 to run if these resources are not installed."
24366 fi
24367 echo
24368 fi
24369
24370 if test "${opsys}" = "cygwin"; then
24371 case `uname -r` in
24372 1.5.*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: building Emacs on Cygwin 1.5 is not supported." >&5
24373 $as_echo "$as_me: WARNING: building Emacs on Cygwin 1.5 is not supported." >&2;}
24374 echo
24375 ;;
24376 esac
24377 fi
24378
24379 # Remove any trailing slashes in these variables.
24380 test "${prefix}" != NONE &&
24381 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
24382 test "${exec_prefix}" != NONE &&
24383 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
24384
24385 if test "$HAVE_NS" = "yes"; then
24386 if test "$NS_IMPL_GNUSTEP" = yes; then
24387 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"
24388
24389 else
24390 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"
24391
24392 fi
24393 fi
24394
24395 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"
24396
24397 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"
24398
24399
24400 opt_makefile=test/automated/Makefile
24401
24402 if test -f $srcdir/${opt_makefile}.in; then
24403 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24404 ac_config_files="$ac_config_files test/automated/Makefile"
24405
24406 fi
24407
24408
24409 opt_makefile=admin/unidata/Makefile
24410
24411 if test -f $srcdir/${opt_makefile}.in; then
24412 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
24413 ac_config_files="$ac_config_files admin/unidata/Makefile"
24414
24415 fi
24416
24417
24418 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
24419
24420
24421
24422 ac_config_commands="$ac_config_commands mkdirs"
24423
24424
24425 ac_config_commands="$ac_config_commands epaths"
24426
24427
24428 ac_config_commands="$ac_config_commands gdbinit"
24429
24430
24431 cat >confcache <<\_ACEOF
24432 # This file is a shell script that caches the results of configure
24433 # tests run on this system so they can be shared between configure
24434 # scripts and configure runs, see configure's option --config-cache.
24435 # It is not useful on other systems. If it contains results you don't
24436 # want to keep, you may remove or edit it.
24437 #
24438 # config.status only pays attention to the cache file if you give it
24439 # the --recheck option to rerun configure.
24440 #
24441 # `ac_cv_env_foo' variables (set or unset) will be overridden when
24442 # loading this file, other *unset* `ac_cv_foo' will be assigned the
24443 # following values.
24444
24445 _ACEOF
24446
24447 # The following way of writing the cache mishandles newlines in values,
24448 # but we know of no workaround that is simple, portable, and efficient.
24449 # So, we kill variables containing newlines.
24450 # Ultrix sh set writes to stderr and can't be redirected directly,
24451 # and sets the high bit in the cache file unless we assign to the vars.
24452 (
24453 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
24454 eval ac_val=\$$ac_var
24455 case $ac_val in #(
24456 *${as_nl}*)
24457 case $ac_var in #(
24458 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
24459 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
24460 esac
24461 case $ac_var in #(
24462 _ | IFS | as_nl) ;; #(
24463 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
24464 *) { eval $ac_var=; unset $ac_var;} ;;
24465 esac ;;
24466 esac
24467 done
24468
24469 (set) 2>&1 |
24470 case $as_nl`(ac_space=' '; set) 2>&1` in #(
24471 *${as_nl}ac_space=\ *)
24472 # `set' does not quote correctly, so add quotes: double-quote
24473 # substitution turns \\\\ into \\, and sed turns \\ into \.
24474 sed -n \
24475 "s/'/'\\\\''/g;
24476 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
24477 ;; #(
24478 *)
24479 # `set' quotes correctly as required by POSIX, so do not add quotes.
24480 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
24481 ;;
24482 esac |
24483 sort
24484 ) |
24485 sed '
24486 /^ac_cv_env_/b end
24487 t clear
24488 :clear
24489 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
24490 t end
24491 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
24492 :end' >>confcache
24493 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
24494 if test -w "$cache_file"; then
24495 test "x$cache_file" != "x/dev/null" &&
24496 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
24497 $as_echo "$as_me: updating cache $cache_file" >&6;}
24498 cat confcache >$cache_file
24499 else
24500 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
24501 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
24502 fi
24503 fi
24504 rm -f confcache
24505
24506 test "x$prefix" = xNONE && prefix=$ac_default_prefix
24507 # Let make expand exec_prefix.
24508 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
24509
24510 DEFS=-DHAVE_CONFIG_H
24511
24512 ac_libobjs=
24513 ac_ltlibobjs=
24514 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
24515 # 1. Remove the extension, and $U if already installed.
24516 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
24517 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
24518 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
24519 # will be set to the directory where LIBOBJS objects are built.
24520 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
24521 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
24522 done
24523 LIBOBJS=$ac_libobjs
24524
24525 LTLIBOBJS=$ac_ltlibobjs
24526
24527
24528 if test -n "$EXEEXT"; then
24529 am__EXEEXT_TRUE=
24530 am__EXEEXT_FALSE='#'
24531 else
24532 am__EXEEXT_TRUE='#'
24533 am__EXEEXT_FALSE=
24534 fi
24535
24536 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
24537 as_fn_error "conditional \"AMDEP\" was never defined.
24538 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24539 fi
24540 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
24541 as_fn_error "conditional \"am__fastdepCC\" was never defined.
24542 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24543 fi
24544 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
24545 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
24546 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24547 fi
24548 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
24549 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
24550 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24551 fi
24552
24553 if test -z "${GL_GENERATE_EXECINFO_H_TRUE}" && test -z "${GL_GENERATE_EXECINFO_H_FALSE}"; then
24554 as_fn_error "conditional \"GL_GENERATE_EXECINFO_H\" was never defined.
24555 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24556 fi
24557 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
24558 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
24559 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24560 fi
24561 if test -z "${GL_GENERATE_STDALIGN_H_TRUE}" && test -z "${GL_GENERATE_STDALIGN_H_FALSE}"; then
24562 as_fn_error "conditional \"GL_GENERATE_STDALIGN_H\" was never defined.
24563 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24564 fi
24565 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
24566 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
24567 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24568 fi
24569 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
24570 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
24571 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24572 fi
24573 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
24574 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
24575 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24576 fi
24577 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
24578 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
24579 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24580 fi
24581 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
24582 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
24583 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24584 fi
24585 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
24586 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
24587 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24588 fi
24589 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
24590 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
24591 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24592 fi
24593 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
24594 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
24595 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24596 fi
24597 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
24598 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
24599 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24600 fi
24601 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
24602 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
24603 Usually this means the macro was only invoked conditionally." "$LINENO" 5
24604 fi
24605
24606 gl_libobjs=
24607 gl_ltlibobjs=
24608 if test -n "$gl_LIBOBJS"; then
24609 # Remove the extension.
24610 sed_drop_objext='s/\.o$//;s/\.obj$//'
24611 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24612 gl_libobjs="$gl_libobjs $i.$ac_objext"
24613 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
24614 done
24615 fi
24616 gl_LIBOBJS=$gl_libobjs
24617
24618 gl_LTLIBOBJS=$gl_ltlibobjs
24619
24620
24621
24622 gltests_libobjs=
24623 gltests_ltlibobjs=
24624 if test -n "$gltests_LIBOBJS"; then
24625 # Remove the extension.
24626 sed_drop_objext='s/\.o$//;s/\.obj$//'
24627 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
24628 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
24629 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
24630 done
24631 fi
24632 gltests_LIBOBJS=$gltests_libobjs
24633
24634 gltests_LTLIBOBJS=$gltests_ltlibobjs
24635
24636
24637
24638 : ${CONFIG_STATUS=./config.status}
24639 ac_write_fail=0
24640 ac_clean_files_save=$ac_clean_files
24641 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
24642 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
24643 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
24644 as_write_fail=0
24645 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
24646 #! $SHELL
24647 # Generated by $as_me.
24648 # Run this file to recreate the current configuration.
24649 # Compiler output produced by configure, useful for debugging
24650 # configure, is in config.log if it exists.
24651
24652 debug=false
24653 ac_cs_recheck=false
24654 ac_cs_silent=false
24655
24656 SHELL=\${CONFIG_SHELL-$SHELL}
24657 export SHELL
24658 _ASEOF
24659 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
24660 ## -------------------- ##
24661 ## M4sh Initialization. ##
24662 ## -------------------- ##
24663
24664 # Be more Bourne compatible
24665 DUALCASE=1; export DUALCASE # for MKS sh
24666 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
24667 emulate sh
24668 NULLCMD=:
24669 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
24670 # is contrary to our usage. Disable this feature.
24671 alias -g '${1+"$@"}'='"$@"'
24672 setopt NO_GLOB_SUBST
24673 else
24674 case `(set -o) 2>/dev/null` in #(
24675 *posix*) :
24676 set -o posix ;; #(
24677 *) :
24678 ;;
24679 esac
24680 fi
24681
24682
24683 as_nl='
24684 '
24685 export as_nl
24686 # Printing a long string crashes Solaris 7 /usr/bin/printf.
24687 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
24688 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
24689 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
24690 # Prefer a ksh shell builtin over an external printf program on Solaris,
24691 # but without wasting forks for bash or zsh.
24692 if test -z "$BASH_VERSION$ZSH_VERSION" \
24693 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
24694 as_echo='print -r --'
24695 as_echo_n='print -rn --'
24696 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
24697 as_echo='printf %s\n'
24698 as_echo_n='printf %s'
24699 else
24700 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
24701 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
24702 as_echo_n='/usr/ucb/echo -n'
24703 else
24704 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
24705 as_echo_n_body='eval
24706 arg=$1;
24707 case $arg in #(
24708 *"$as_nl"*)
24709 expr "X$arg" : "X\\(.*\\)$as_nl";
24710 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
24711 esac;
24712 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
24713 '
24714 export as_echo_n_body
24715 as_echo_n='sh -c $as_echo_n_body as_echo'
24716 fi
24717 export as_echo_body
24718 as_echo='sh -c $as_echo_body as_echo'
24719 fi
24720
24721 # The user is always right.
24722 if test "${PATH_SEPARATOR+set}" != set; then
24723 PATH_SEPARATOR=:
24724 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
24725 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
24726 PATH_SEPARATOR=';'
24727 }
24728 fi
24729
24730
24731 # IFS
24732 # We need space, tab and new line, in precisely that order. Quoting is
24733 # there to prevent editors from complaining about space-tab.
24734 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
24735 # splitting by setting IFS to empty value.)
24736 IFS=" "" $as_nl"
24737
24738 # Find who we are. Look in the path if we contain no directory separator.
24739 case $0 in #((
24740 *[\\/]* ) as_myself=$0 ;;
24741 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
24742 for as_dir in $PATH
24743 do
24744 IFS=$as_save_IFS
24745 test -z "$as_dir" && as_dir=.
24746 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
24747 done
24748 IFS=$as_save_IFS
24749
24750 ;;
24751 esac
24752 # We did not find ourselves, most probably we were run as `sh COMMAND'
24753 # in which case we are not to be found in the path.
24754 if test "x$as_myself" = x; then
24755 as_myself=$0
24756 fi
24757 if test ! -f "$as_myself"; then
24758 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
24759 exit 1
24760 fi
24761
24762 # Unset variables that we do not need and which cause bugs (e.g. in
24763 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
24764 # suppresses any "Segmentation fault" message there. '((' could
24765 # trigger a bug in pdksh 5.2.14.
24766 for as_var in BASH_ENV ENV MAIL MAILPATH
24767 do eval test x\${$as_var+set} = xset \
24768 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
24769 done
24770 PS1='$ '
24771 PS2='> '
24772 PS4='+ '
24773
24774 # NLS nuisances.
24775 LC_ALL=C
24776 export LC_ALL
24777 LANGUAGE=C
24778 export LANGUAGE
24779
24780 # CDPATH.
24781 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
24782
24783
24784 # as_fn_error ERROR [LINENO LOG_FD]
24785 # ---------------------------------
24786 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
24787 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
24788 # script with status $?, using 1 if that was 0.
24789 as_fn_error ()
24790 {
24791 as_status=$?; test $as_status -eq 0 && as_status=1
24792 if test "$3"; then
24793 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
24794 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
24795 fi
24796 $as_echo "$as_me: error: $1" >&2
24797 as_fn_exit $as_status
24798 } # as_fn_error
24799
24800
24801 # as_fn_set_status STATUS
24802 # -----------------------
24803 # Set $? to STATUS, without forking.
24804 as_fn_set_status ()
24805 {
24806 return $1
24807 } # as_fn_set_status
24808
24809 # as_fn_exit STATUS
24810 # -----------------
24811 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
24812 as_fn_exit ()
24813 {
24814 set +e
24815 as_fn_set_status $1
24816 exit $1
24817 } # as_fn_exit
24818
24819 # as_fn_unset VAR
24820 # ---------------
24821 # Portably unset VAR.
24822 as_fn_unset ()
24823 {
24824 { eval $1=; unset $1;}
24825 }
24826 as_unset=as_fn_unset
24827 # as_fn_append VAR VALUE
24828 # ----------------------
24829 # Append the text in VALUE to the end of the definition contained in VAR. Take
24830 # advantage of any shell optimizations that allow amortized linear growth over
24831 # repeated appends, instead of the typical quadratic growth present in naive
24832 # implementations.
24833 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
24834 eval 'as_fn_append ()
24835 {
24836 eval $1+=\$2
24837 }'
24838 else
24839 as_fn_append ()
24840 {
24841 eval $1=\$$1\$2
24842 }
24843 fi # as_fn_append
24844
24845 # as_fn_arith ARG...
24846 # ------------------
24847 # Perform arithmetic evaluation on the ARGs, and store the result in the
24848 # global $as_val. Take advantage of shells that can avoid forks. The arguments
24849 # must be portable across $(()) and expr.
24850 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
24851 eval 'as_fn_arith ()
24852 {
24853 as_val=$(( $* ))
24854 }'
24855 else
24856 as_fn_arith ()
24857 {
24858 as_val=`expr "$@" || test $? -eq 1`
24859 }
24860 fi # as_fn_arith
24861
24862
24863 if expr a : '\(a\)' >/dev/null 2>&1 &&
24864 test "X`expr 00001 : '.*\(...\)'`" = X001; then
24865 as_expr=expr
24866 else
24867 as_expr=false
24868 fi
24869
24870 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
24871 as_basename=basename
24872 else
24873 as_basename=false
24874 fi
24875
24876 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
24877 as_dirname=dirname
24878 else
24879 as_dirname=false
24880 fi
24881
24882 as_me=`$as_basename -- "$0" ||
24883 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
24884 X"$0" : 'X\(//\)$' \| \
24885 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
24886 $as_echo X/"$0" |
24887 sed '/^.*\/\([^/][^/]*\)\/*$/{
24888 s//\1/
24889 q
24890 }
24891 /^X\/\(\/\/\)$/{
24892 s//\1/
24893 q
24894 }
24895 /^X\/\(\/\).*/{
24896 s//\1/
24897 q
24898 }
24899 s/.*/./; q'`
24900
24901 # Avoid depending upon Character Ranges.
24902 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
24903 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
24904 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
24905 as_cr_digits='0123456789'
24906 as_cr_alnum=$as_cr_Letters$as_cr_digits
24907
24908 ECHO_C= ECHO_N= ECHO_T=
24909 case `echo -n x` in #(((((
24910 -n*)
24911 case `echo 'xy\c'` in
24912 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
24913 xy) ECHO_C='\c';;
24914 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
24915 ECHO_T=' ';;
24916 esac;;
24917 *)
24918 ECHO_N='-n';;
24919 esac
24920
24921 rm -f conf$$ conf$$.exe conf$$.file
24922 if test -d conf$$.dir; then
24923 rm -f conf$$.dir/conf$$.file
24924 else
24925 rm -f conf$$.dir
24926 mkdir conf$$.dir 2>/dev/null
24927 fi
24928 if (echo >conf$$.file) 2>/dev/null; then
24929 if ln -s conf$$.file conf$$ 2>/dev/null; then
24930 as_ln_s='ln -s'
24931 # ... but there are two gotchas:
24932 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
24933 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
24934 # In both cases, we have to default to `cp -p'.
24935 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
24936 as_ln_s='cp -p'
24937 elif ln conf$$.file conf$$ 2>/dev/null; then
24938 as_ln_s=ln
24939 else
24940 as_ln_s='cp -p'
24941 fi
24942 else
24943 as_ln_s='cp -p'
24944 fi
24945 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
24946 rmdir conf$$.dir 2>/dev/null
24947
24948
24949 # as_fn_mkdir_p
24950 # -------------
24951 # Create "$as_dir" as a directory, including parents if necessary.
24952 as_fn_mkdir_p ()
24953 {
24954
24955 case $as_dir in #(
24956 -*) as_dir=./$as_dir;;
24957 esac
24958 test -d "$as_dir" || eval $as_mkdir_p || {
24959 as_dirs=
24960 while :; do
24961 case $as_dir in #(
24962 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
24963 *) as_qdir=$as_dir;;
24964 esac
24965 as_dirs="'$as_qdir' $as_dirs"
24966 as_dir=`$as_dirname -- "$as_dir" ||
24967 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24968 X"$as_dir" : 'X\(//\)[^/]' \| \
24969 X"$as_dir" : 'X\(//\)$' \| \
24970 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
24971 $as_echo X"$as_dir" |
24972 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24973 s//\1/
24974 q
24975 }
24976 /^X\(\/\/\)[^/].*/{
24977 s//\1/
24978 q
24979 }
24980 /^X\(\/\/\)$/{
24981 s//\1/
24982 q
24983 }
24984 /^X\(\/\).*/{
24985 s//\1/
24986 q
24987 }
24988 s/.*/./; q'`
24989 test -d "$as_dir" && break
24990 done
24991 test -z "$as_dirs" || eval "mkdir $as_dirs"
24992 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
24993
24994
24995 } # as_fn_mkdir_p
24996 if mkdir -p . 2>/dev/null; then
24997 as_mkdir_p='mkdir -p "$as_dir"'
24998 else
24999 test -d ./-p && rmdir ./-p
25000 as_mkdir_p=false
25001 fi
25002
25003 if test -x / >/dev/null 2>&1; then
25004 as_test_x='test -x'
25005 else
25006 if ls -dL / >/dev/null 2>&1; then
25007 as_ls_L_option=L
25008 else
25009 as_ls_L_option=
25010 fi
25011 as_test_x='
25012 eval sh -c '\''
25013 if test -d "$1"; then
25014 test -d "$1/.";
25015 else
25016 case $1 in #(
25017 -*)set "./$1";;
25018 esac;
25019 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
25020 ???[sx]*):;;*)false;;esac;fi
25021 '\'' sh
25022 '
25023 fi
25024 as_executable_p=$as_test_x
25025
25026 # Sed expression to map a string onto a valid CPP name.
25027 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
25028
25029 # Sed expression to map a string onto a valid variable name.
25030 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
25031
25032
25033 exec 6>&1
25034 ## ----------------------------------- ##
25035 ## Main body of $CONFIG_STATUS script. ##
25036 ## ----------------------------------- ##
25037 _ASEOF
25038 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
25039
25040 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25041 # Save the log message, to keep $0 and so on meaningful, and to
25042 # report actual input values of CONFIG_FILES etc. instead of their
25043 # values after options handling.
25044 ac_log="
25045 This file was extended by emacs $as_me 24.2.50, which was
25046 generated by GNU Autoconf 2.65. Invocation command line was
25047
25048 CONFIG_FILES = $CONFIG_FILES
25049 CONFIG_HEADERS = $CONFIG_HEADERS
25050 CONFIG_LINKS = $CONFIG_LINKS
25051 CONFIG_COMMANDS = $CONFIG_COMMANDS
25052 $ $0 $@
25053
25054 on `(hostname || uname -n) 2>/dev/null | sed 1q`
25055 "
25056
25057 _ACEOF
25058
25059 case $ac_config_files in *"
25060 "*) set x $ac_config_files; shift; ac_config_files=$*;;
25061 esac
25062
25063 case $ac_config_headers in *"
25064 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
25065 esac
25066
25067
25068 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25069 # Files that config.status was made for.
25070 config_files="$ac_config_files"
25071 config_headers="$ac_config_headers"
25072 config_commands="$ac_config_commands"
25073
25074 _ACEOF
25075
25076 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25077 ac_cs_usage="\
25078 \`$as_me' instantiates files and other configuration actions
25079 from templates according to the current configuration. Unless the files
25080 and actions are specified as TAGs, all are instantiated by default.
25081
25082 Usage: $0 [OPTION]... [TAG]...
25083
25084 -h, --help print this help, then exit
25085 -V, --version print version number and configuration settings, then exit
25086 --config print configuration, then exit
25087 -q, --quiet, --silent
25088 do not print progress messages
25089 -d, --debug don't remove temporary files
25090 --recheck update $as_me by reconfiguring in the same conditions
25091 --file=FILE[:TEMPLATE]
25092 instantiate the configuration file FILE
25093 --header=FILE[:TEMPLATE]
25094 instantiate the configuration header FILE
25095
25096 Configuration files:
25097 $config_files
25098
25099 Configuration headers:
25100 $config_headers
25101
25102 Configuration commands:
25103 $config_commands
25104
25105 Report bugs to the package provider."
25106
25107 _ACEOF
25108 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25109 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
25110 ac_cs_version="\\
25111 emacs config.status 24.2.50
25112 configured by $0, generated by GNU Autoconf 2.65,
25113 with options \\"\$ac_cs_config\\"
25114
25115 Copyright (C) 2009 Free Software Foundation, Inc.
25116 This config.status script is free software; the Free Software Foundation
25117 gives unlimited permission to copy, distribute and modify it."
25118
25119 ac_pwd='$ac_pwd'
25120 srcdir='$srcdir'
25121 INSTALL='$INSTALL'
25122 MKDIR_P='$MKDIR_P'
25123 AWK='$AWK'
25124 test -n "\$AWK" || AWK=awk
25125 _ACEOF
25126
25127 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25128 # The default lists apply if the user does not specify any file.
25129 ac_need_defaults=:
25130 while test $# != 0
25131 do
25132 case $1 in
25133 --*=*)
25134 ac_option=`expr "X$1" : 'X\([^=]*\)='`
25135 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
25136 ac_shift=:
25137 ;;
25138 *)
25139 ac_option=$1
25140 ac_optarg=$2
25141 ac_shift=shift
25142 ;;
25143 esac
25144
25145 case $ac_option in
25146 # Handling of the options.
25147 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
25148 ac_cs_recheck=: ;;
25149 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
25150 $as_echo "$ac_cs_version"; exit ;;
25151 --config | --confi | --conf | --con | --co | --c )
25152 $as_echo "$ac_cs_config"; exit ;;
25153 --debug | --debu | --deb | --de | --d | -d )
25154 debug=: ;;
25155 --file | --fil | --fi | --f )
25156 $ac_shift
25157 case $ac_optarg in
25158 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25159 esac
25160 as_fn_append CONFIG_FILES " '$ac_optarg'"
25161 ac_need_defaults=false;;
25162 --header | --heade | --head | --hea )
25163 $ac_shift
25164 case $ac_optarg in
25165 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
25166 esac
25167 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
25168 ac_need_defaults=false;;
25169 --he | --h)
25170 # Conflict between --help and --header
25171 as_fn_error "ambiguous option: \`$1'
25172 Try \`$0 --help' for more information.";;
25173 --help | --hel | -h )
25174 $as_echo "$ac_cs_usage"; exit ;;
25175 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
25176 | -silent | --silent | --silen | --sile | --sil | --si | --s)
25177 ac_cs_silent=: ;;
25178
25179 # This is an error.
25180 -*) as_fn_error "unrecognized option: \`$1'
25181 Try \`$0 --help' for more information." ;;
25182
25183 *) as_fn_append ac_config_targets " $1"
25184 ac_need_defaults=false ;;
25185
25186 esac
25187 shift
25188 done
25189
25190 ac_configure_extra_args=
25191
25192 if $ac_cs_silent; then
25193 exec 6>/dev/null
25194 ac_configure_extra_args="$ac_configure_extra_args --silent"
25195 fi
25196
25197 _ACEOF
25198 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25199 if \$ac_cs_recheck; then
25200 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
25201 shift
25202 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
25203 CONFIG_SHELL='$SHELL'
25204 export CONFIG_SHELL
25205 exec "\$@"
25206 fi
25207
25208 _ACEOF
25209 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25210 exec 5>>config.log
25211 {
25212 echo
25213 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
25214 ## Running $as_me. ##
25215 _ASBOX
25216 $as_echo "$ac_log"
25217 } >&5
25218
25219 _ACEOF
25220 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25221 #
25222 # INIT-COMMANDS
25223 #
25224 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
25225 GCC="$GCC" CPPFLAGS="$CPPFLAGS"
25226
25227 _ACEOF
25228
25229 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25230
25231 # Handling of arguments.
25232 for ac_config_target in $ac_config_targets
25233 do
25234 case $ac_config_target in
25235 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
25236 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
25237 "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" ;;
25238 "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop") CONFIG_FILES="$CONFIG_FILES nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop:nextstep/templates/Emacs.desktop.in" ;;
25239 "nextstep/Cocoa/Emacs.base/Contents/Info.plist") CONFIG_FILES="$CONFIG_FILES nextstep/Cocoa/Emacs.base/Contents/Info.plist:nextstep/templates/Info.plist.in" ;;
25240 "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" ;;
25241 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
25242 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
25243 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
25244 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
25245 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
25246 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
25247 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
25248 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
25249 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
25250 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
25251 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
25252 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
25253 "nextstep/Makefile") CONFIG_FILES="$CONFIG_FILES nextstep/Makefile" ;;
25254 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
25255 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
25256 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
25257 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
25258 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
25259
25260 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
25261 esac
25262 done
25263
25264
25265 # If the user did not use the arguments to specify the items to instantiate,
25266 # then the envvar interface is used. Set only those that are not.
25267 # We use the long form for the default assignment because of an extremely
25268 # bizarre bug on SunOS 4.1.3.
25269 if $ac_need_defaults; then
25270 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
25271 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
25272 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
25273 fi
25274
25275 # Have a temporary directory for convenience. Make it in the build tree
25276 # simply because there is no reason against having it here, and in addition,
25277 # creating and moving files from /tmp can sometimes cause problems.
25278 # Hook for its removal unless debugging.
25279 # Note that there is a small window in which the directory will not be cleaned:
25280 # after its creation but before its name has been assigned to `$tmp'.
25281 $debug ||
25282 {
25283 tmp=
25284 trap 'exit_status=$?
25285 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
25286 ' 0
25287 trap 'as_fn_exit 1' 1 2 13 15
25288 }
25289 # Create a (secure) tmp directory for tmp files.
25290
25291 {
25292 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
25293 test -n "$tmp" && test -d "$tmp"
25294 } ||
25295 {
25296 tmp=./conf$$-$RANDOM
25297 (umask 077 && mkdir "$tmp")
25298 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
25299
25300 # Set up the scripts for CONFIG_FILES section.
25301 # No need to generate them if there are no CONFIG_FILES.
25302 # This happens for instance with `./config.status config.h'.
25303 if test -n "$CONFIG_FILES"; then
25304
25305 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
25306 ac_cs_awk_getline=:
25307 ac_cs_awk_pipe_init=
25308 ac_cs_awk_read_file='
25309 while ((getline aline < (F[key])) > 0)
25310 print(aline)
25311 close(F[key])'
25312 ac_cs_awk_pipe_fini=
25313 else
25314 ac_cs_awk_getline=false
25315 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
25316 ac_cs_awk_read_file='
25317 print "|#_!!_#|"
25318 print "cat " F[key] " &&"
25319 '$ac_cs_awk_pipe_init
25320 # The final `:' finishes the AND list.
25321 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
25322 fi
25323 ac_cr=`echo X | tr X '\015'`
25324 # On cygwin, bash can eat \r inside `` if the user requested igncr.
25325 # But we know of no other shell where ac_cr would be empty at this
25326 # point, so we can use a bashism as a fallback.
25327 if test "x$ac_cr" = x; then
25328 eval ac_cr=\$\'\\r\'
25329 fi
25330 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
25331 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
25332 ac_cs_awk_cr='\r'
25333 else
25334 ac_cs_awk_cr=$ac_cr
25335 fi
25336
25337 echo 'BEGIN {' >"$tmp/subs1.awk" &&
25338 _ACEOF
25339
25340 # Create commands to substitute file output variables.
25341 {
25342 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
25343 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
25344 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
25345 echo "_ACAWK" &&
25346 echo "_ACEOF"
25347 } >conf$$files.sh &&
25348 . ./conf$$files.sh ||
25349 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25350 rm -f conf$$files.sh
25351
25352 {
25353 echo "cat >conf$$subs.awk <<_ACEOF" &&
25354 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
25355 echo "_ACEOF"
25356 } >conf$$subs.sh ||
25357 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25358 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
25359 ac_delim='%!_!# '
25360 for ac_last_try in false false false false false :; do
25361 . ./conf$$subs.sh ||
25362 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25363
25364 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
25365 if test $ac_delim_n = $ac_delim_num; then
25366 break
25367 elif $ac_last_try; then
25368 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
25369 else
25370 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25371 fi
25372 done
25373 rm -f conf$$subs.sh
25374
25375 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25376 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
25377 _ACEOF
25378 sed -n '
25379 h
25380 s/^/S["/; s/!.*/"]=/
25381 p
25382 g
25383 s/^[^!]*!//
25384 :repl
25385 t repl
25386 s/'"$ac_delim"'$//
25387 t delim
25388 :nl
25389 h
25390 s/\(.\{148\}\)..*/\1/
25391 t more1
25392 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
25393 p
25394 n
25395 b repl
25396 :more1
25397 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25398 p
25399 g
25400 s/.\{148\}//
25401 t nl
25402 :delim
25403 h
25404 s/\(.\{148\}\)..*/\1/
25405 t more2
25406 s/["\\]/\\&/g; s/^/"/; s/$/"/
25407 p
25408 b
25409 :more2
25410 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
25411 p
25412 g
25413 s/.\{148\}//
25414 t delim
25415 ' <conf$$subs.awk | sed '
25416 /^[^""]/{
25417 N
25418 s/\n//
25419 }
25420 ' >>$CONFIG_STATUS || ac_write_fail=1
25421 rm -f conf$$subs.awk
25422 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25423 _ACAWK
25424 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
25425 for (key in S) S_is_set[key] = 1
25426 FS = "\a"
25427 \$ac_cs_awk_pipe_init
25428 }
25429 {
25430 line = $ 0
25431 nfields = split(line, field, "@")
25432 substed = 0
25433 len = length(field[1])
25434 for (i = 2; i < nfields; i++) {
25435 key = field[i]
25436 keylen = length(key)
25437 if (S_is_set[key]) {
25438 value = S[key]
25439 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
25440 len += length(value) + length(field[++i])
25441 substed = 1
25442 } else
25443 len += 1 + keylen
25444 }
25445 if (nfields == 3 && !substed) {
25446 key = field[2]
25447 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
25448 \$ac_cs_awk_read_file
25449 next
25450 }
25451 }
25452 print line
25453 }
25454 \$ac_cs_awk_pipe_fini
25455 _ACAWK
25456 _ACEOF
25457 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25458 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
25459 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
25460 else
25461 cat
25462 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
25463 || as_fn_error "could not setup config files machinery" "$LINENO" 5
25464 _ACEOF
25465
25466 # VPATH may cause trouble with some makes, so we remove $(srcdir),
25467 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
25468 # trailing colons and then remove the whole line if VPATH becomes empty
25469 # (actually we leave an empty line to preserve line numbers).
25470 if test "x$srcdir" = x.; then
25471 ac_vpsub='/^[ ]*VPATH[ ]*=/{
25472 s/:*\$(srcdir):*/:/
25473 s/:*\${srcdir}:*/:/
25474 s/:*@srcdir@:*/:/
25475 s/^\([^=]*=[ ]*\):*/\1/
25476 s/:*$//
25477 s/^[^=]*=[ ]*$//
25478 }'
25479 fi
25480
25481 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25482 fi # test -n "$CONFIG_FILES"
25483
25484 # Set up the scripts for CONFIG_HEADERS section.
25485 # No need to generate them if there are no CONFIG_HEADERS.
25486 # This happens for instance with `./config.status Makefile'.
25487 if test -n "$CONFIG_HEADERS"; then
25488 cat >"$tmp/defines.awk" <<\_ACAWK ||
25489 BEGIN {
25490 _ACEOF
25491
25492 # Transform confdefs.h into an awk script `defines.awk', embedded as
25493 # here-document in config.status, that substitutes the proper values into
25494 # config.h.in to produce config.h.
25495
25496 # Create a delimiter string that does not exist in confdefs.h, to ease
25497 # handling of long lines.
25498 ac_delim='%!_!# '
25499 for ac_last_try in false false :; do
25500 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
25501 if test -z "$ac_t"; then
25502 break
25503 elif $ac_last_try; then
25504 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
25505 else
25506 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
25507 fi
25508 done
25509
25510 # For the awk script, D is an array of macro values keyed by name,
25511 # likewise P contains macro parameters if any. Preserve backslash
25512 # newline sequences.
25513
25514 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
25515 sed -n '
25516 s/.\{148\}/&'"$ac_delim"'/g
25517 t rset
25518 :rset
25519 s/^[ ]*#[ ]*define[ ][ ]*/ /
25520 t def
25521 d
25522 :def
25523 s/\\$//
25524 t bsnl
25525 s/["\\]/\\&/g
25526 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25527 D["\1"]=" \3"/p
25528 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
25529 d
25530 :bsnl
25531 s/["\\]/\\&/g
25532 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
25533 D["\1"]=" \3\\\\\\n"\\/p
25534 t cont
25535 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
25536 t cont
25537 d
25538 :cont
25539 n
25540 s/.\{148\}/&'"$ac_delim"'/g
25541 t clear
25542 :clear
25543 s/\\$//
25544 t bsnlc
25545 s/["\\]/\\&/g; s/^/"/; s/$/"/p
25546 d
25547 :bsnlc
25548 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
25549 b cont
25550 ' <confdefs.h | sed '
25551 s/'"$ac_delim"'/"\\\
25552 "/g' >>$CONFIG_STATUS || ac_write_fail=1
25553
25554 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25555 for (key in D) D_is_set[key] = 1
25556 FS = "\a"
25557 }
25558 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
25559 line = \$ 0
25560 split(line, arg, " ")
25561 if (arg[1] == "#") {
25562 defundef = arg[2]
25563 mac1 = arg[3]
25564 } else {
25565 defundef = substr(arg[1], 2)
25566 mac1 = arg[2]
25567 }
25568 split(mac1, mac2, "(") #)
25569 macro = mac2[1]
25570 prefix = substr(line, 1, index(line, defundef) - 1)
25571 if (D_is_set[macro]) {
25572 # Preserve the white space surrounding the "#".
25573 print prefix "define", macro P[macro] D[macro]
25574 next
25575 } else {
25576 # Replace #undef with comments. This is necessary, for example,
25577 # in the case of _POSIX_SOURCE, which is predefined and required
25578 # on some systems where configure will not decide to define it.
25579 if (defundef == "undef") {
25580 print "/*", prefix defundef, macro, "*/"
25581 next
25582 }
25583 }
25584 }
25585 { print }
25586 _ACAWK
25587 _ACEOF
25588 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25589 as_fn_error "could not setup config headers machinery" "$LINENO" 5
25590 fi # test -n "$CONFIG_HEADERS"
25591
25592
25593 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
25594 shift
25595 for ac_tag
25596 do
25597 case $ac_tag in
25598 :[FHLC]) ac_mode=$ac_tag; continue;;
25599 esac
25600 case $ac_mode$ac_tag in
25601 :[FHL]*:*);;
25602 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
25603 :[FH]-) ac_tag=-:-;;
25604 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
25605 esac
25606 ac_save_IFS=$IFS
25607 IFS=:
25608 set x $ac_tag
25609 IFS=$ac_save_IFS
25610 shift
25611 ac_file=$1
25612 shift
25613
25614 case $ac_mode in
25615 :L) ac_source=$1;;
25616 :[FH])
25617 ac_file_inputs=
25618 for ac_f
25619 do
25620 case $ac_f in
25621 -) ac_f="$tmp/stdin";;
25622 *) # Look for the file first in the build tree, then in the source tree
25623 # (if the path is not absolute). The absolute path cannot be DOS-style,
25624 # because $ac_f cannot contain `:'.
25625 test -f "$ac_f" ||
25626 case $ac_f in
25627 [\\/$]*) false;;
25628 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
25629 esac ||
25630 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
25631 esac
25632 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
25633 as_fn_append ac_file_inputs " '$ac_f'"
25634 done
25635
25636 # Let's still pretend it is `configure' which instantiates (i.e., don't
25637 # use $as_me), people would be surprised to read:
25638 # /* config.h. Generated by config.status. */
25639 configure_input='Generated from '`
25640 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
25641 `' by configure.'
25642 if test x"$ac_file" != x-; then
25643 configure_input="$ac_file. $configure_input"
25644 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
25645 $as_echo "$as_me: creating $ac_file" >&6;}
25646 fi
25647 # Neutralize special characters interpreted by sed in replacement strings.
25648 case $configure_input in #(
25649 *\&* | *\|* | *\\* )
25650 ac_sed_conf_input=`$as_echo "$configure_input" |
25651 sed 's/[\\\\&|]/\\\\&/g'`;; #(
25652 *) ac_sed_conf_input=$configure_input;;
25653 esac
25654
25655 case $ac_tag in
25656 *:-:* | *:-) cat >"$tmp/stdin" \
25657 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
25658 esac
25659 ;;
25660 esac
25661
25662 ac_dir=`$as_dirname -- "$ac_file" ||
25663 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25664 X"$ac_file" : 'X\(//\)[^/]' \| \
25665 X"$ac_file" : 'X\(//\)$' \| \
25666 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
25667 $as_echo X"$ac_file" |
25668 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25669 s//\1/
25670 q
25671 }
25672 /^X\(\/\/\)[^/].*/{
25673 s//\1/
25674 q
25675 }
25676 /^X\(\/\/\)$/{
25677 s//\1/
25678 q
25679 }
25680 /^X\(\/\).*/{
25681 s//\1/
25682 q
25683 }
25684 s/.*/./; q'`
25685 as_dir="$ac_dir"; as_fn_mkdir_p
25686 ac_builddir=.
25687
25688 case "$ac_dir" in
25689 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
25690 *)
25691 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
25692 # A ".." for each directory in $ac_dir_suffix.
25693 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
25694 case $ac_top_builddir_sub in
25695 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
25696 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
25697 esac ;;
25698 esac
25699 ac_abs_top_builddir=$ac_pwd
25700 ac_abs_builddir=$ac_pwd$ac_dir_suffix
25701 # for backward compatibility:
25702 ac_top_builddir=$ac_top_build_prefix
25703
25704 case $srcdir in
25705 .) # We are building in place.
25706 ac_srcdir=.
25707 ac_top_srcdir=$ac_top_builddir_sub
25708 ac_abs_top_srcdir=$ac_pwd ;;
25709 [\\/]* | ?:[\\/]* ) # Absolute name.
25710 ac_srcdir=$srcdir$ac_dir_suffix;
25711 ac_top_srcdir=$srcdir
25712 ac_abs_top_srcdir=$srcdir ;;
25713 *) # Relative name.
25714 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
25715 ac_top_srcdir=$ac_top_build_prefix$srcdir
25716 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
25717 esac
25718 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
25719
25720
25721 case $ac_mode in
25722 :F)
25723 #
25724 # CONFIG_FILE
25725 #
25726
25727 case $INSTALL in
25728 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
25729 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
25730 esac
25731 ac_MKDIR_P=$MKDIR_P
25732 case $MKDIR_P in
25733 [\\/$]* | ?:[\\/]* ) ;;
25734 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
25735 esac
25736 _ACEOF
25737
25738 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25739 # If the template does not know about datarootdir, expand it.
25740 # FIXME: This hack should be removed a few years after 2.60.
25741 ac_datarootdir_hack=; ac_datarootdir_seen=
25742 ac_sed_dataroot='
25743 /datarootdir/ {
25744 p
25745 q
25746 }
25747 /@datadir@/p
25748 /@docdir@/p
25749 /@infodir@/p
25750 /@localedir@/p
25751 /@mandir@/p'
25752 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
25753 *datarootdir*) ac_datarootdir_seen=yes;;
25754 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
25755 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
25756 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
25757 _ACEOF
25758 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25759 ac_datarootdir_hack='
25760 s&@datadir@&$datadir&g
25761 s&@docdir@&$docdir&g
25762 s&@infodir@&$infodir&g
25763 s&@localedir@&$localedir&g
25764 s&@mandir@&$mandir&g
25765 s&\\\${datarootdir}&$datarootdir&g' ;;
25766 esac
25767 _ACEOF
25768
25769 # Neutralize VPATH when `$srcdir' = `.'.
25770 # Shell code in configure.ac might set extrasub.
25771 # FIXME: do we really want to maintain this feature?
25772 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
25773 ac_sed_extra="$ac_vpsub
25774 $extrasub
25775 _ACEOF
25776 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
25777 :t
25778 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
25779 s|@configure_input@|$ac_sed_conf_input|;t t
25780 s&@top_builddir@&$ac_top_builddir_sub&;t t
25781 s&@top_build_prefix@&$ac_top_build_prefix&;t t
25782 s&@srcdir@&$ac_srcdir&;t t
25783 s&@abs_srcdir@&$ac_abs_srcdir&;t t
25784 s&@top_srcdir@&$ac_top_srcdir&;t t
25785 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
25786 s&@builddir@&$ac_builddir&;t t
25787 s&@abs_builddir@&$ac_abs_builddir&;t t
25788 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
25789 s&@INSTALL@&$ac_INSTALL&;t t
25790 s&@MKDIR_P@&$ac_MKDIR_P&;t t
25791 $ac_datarootdir_hack
25792 "
25793 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
25794 if $ac_cs_awk_getline; then
25795 $AWK -f "$tmp/subs.awk"
25796 else
25797 $AWK -f "$tmp/subs.awk" | $SHELL
25798 fi >$tmp/out \
25799 || as_fn_error "could not create $ac_file" "$LINENO" 5
25800
25801 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
25802 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
25803 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
25804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25805 which seems to be undefined. Please make sure it is defined." >&5
25806 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
25807 which seems to be undefined. Please make sure it is defined." >&2;}
25808
25809 rm -f "$tmp/stdin"
25810 case $ac_file in
25811 -) cat "$tmp/out" && rm -f "$tmp/out";;
25812 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
25813 esac \
25814 || as_fn_error "could not create $ac_file" "$LINENO" 5
25815 ;;
25816 :H)
25817 #
25818 # CONFIG_HEADER
25819 #
25820 if test x"$ac_file" != x-; then
25821 {
25822 $as_echo "/* $configure_input */" \
25823 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
25824 } >"$tmp/config.h" \
25825 || as_fn_error "could not create $ac_file" "$LINENO" 5
25826 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
25827 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
25828 $as_echo "$as_me: $ac_file is unchanged" >&6;}
25829 else
25830 rm -f "$ac_file"
25831 mv "$tmp/config.h" "$ac_file" \
25832 || as_fn_error "could not create $ac_file" "$LINENO" 5
25833 fi
25834 else
25835 $as_echo "/* $configure_input */" \
25836 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
25837 || as_fn_error "could not create -" "$LINENO" 5
25838 fi
25839 # Compute "$ac_file"'s index in $config_headers.
25840 _am_arg="$ac_file"
25841 _am_stamp_count=1
25842 for _am_header in $config_headers :; do
25843 case $_am_header in
25844 $_am_arg | $_am_arg:* )
25845 break ;;
25846 * )
25847 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
25848 esac
25849 done
25850 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
25851 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25852 X"$_am_arg" : 'X\(//\)[^/]' \| \
25853 X"$_am_arg" : 'X\(//\)$' \| \
25854 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
25855 $as_echo X"$_am_arg" |
25856 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25857 s//\1/
25858 q
25859 }
25860 /^X\(\/\/\)[^/].*/{
25861 s//\1/
25862 q
25863 }
25864 /^X\(\/\/\)$/{
25865 s//\1/
25866 q
25867 }
25868 /^X\(\/\).*/{
25869 s//\1/
25870 q
25871 }
25872 s/.*/./; q'`/stamp-h$_am_stamp_count
25873 ;;
25874
25875 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
25876 $as_echo "$as_me: executing $ac_file commands" >&6;}
25877 ;;
25878 esac
25879
25880
25881 case $ac_file$ac_mode in
25882 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
25883 # Autoconf 2.62 quotes --file arguments for eval, but not when files
25884 # are listed without --file. Let's play safe and only enable the eval
25885 # if we detect the quoting.
25886 case $CONFIG_FILES in
25887 *\'*) eval set x "$CONFIG_FILES" ;;
25888 *) set x $CONFIG_FILES ;;
25889 esac
25890 shift
25891 for mf
25892 do
25893 # Strip MF so we end up with the name of the file.
25894 mf=`echo "$mf" | sed -e 's/:.*$//'`
25895 # Check whether this is an Automake generated Makefile or not.
25896 # We used to match only the files named `Makefile.in', but
25897 # some people rename them; so instead we look at the file content.
25898 # Grep'ing the first line is not enough: some people post-process
25899 # each Makefile.in and add a new line on top of each file to say so.
25900 # Grep'ing the whole file is not good either: AIX grep has a line
25901 # limit of 2048, but all sed's we know have understand at least 4000.
25902 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
25903 dirpart=`$as_dirname -- "$mf" ||
25904 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25905 X"$mf" : 'X\(//\)[^/]' \| \
25906 X"$mf" : 'X\(//\)$' \| \
25907 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
25908 $as_echo X"$mf" |
25909 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25910 s//\1/
25911 q
25912 }
25913 /^X\(\/\/\)[^/].*/{
25914 s//\1/
25915 q
25916 }
25917 /^X\(\/\/\)$/{
25918 s//\1/
25919 q
25920 }
25921 /^X\(\/\).*/{
25922 s//\1/
25923 q
25924 }
25925 s/.*/./; q'`
25926 else
25927 continue
25928 fi
25929 # Extract the definition of DEPDIR, am__include, and am__quote
25930 # from the Makefile without running `make'.
25931 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
25932 test -z "$DEPDIR" && continue
25933 am__include=`sed -n 's/^am__include = //p' < "$mf"`
25934 test -z "am__include" && continue
25935 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
25936 # When using ansi2knr, U may be empty or an underscore; expand it
25937 U=`sed -n 's/^U = //p' < "$mf"`
25938 # Find all dependency output files, they are included files with
25939 # $(DEPDIR) in their names. We invoke sed twice because it is the
25940 # simplest approach to changing $(DEPDIR) to its actual value in the
25941 # expansion.
25942 for file in `sed -n "
25943 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
25944 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
25945 # Make sure the directory exists.
25946 test -f "$dirpart/$file" && continue
25947 fdir=`$as_dirname -- "$file" ||
25948 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
25949 X"$file" : 'X\(//\)[^/]' \| \
25950 X"$file" : 'X\(//\)$' \| \
25951 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
25952 $as_echo X"$file" |
25953 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
25954 s//\1/
25955 q
25956 }
25957 /^X\(\/\/\)[^/].*/{
25958 s//\1/
25959 q
25960 }
25961 /^X\(\/\/\)$/{
25962 s//\1/
25963 q
25964 }
25965 /^X\(\/\).*/{
25966 s//\1/
25967 q
25968 }
25969 s/.*/./; q'`
25970 as_dir=$dirpart/$fdir; as_fn_mkdir_p
25971 # echo "creating $dirpart/$file"
25972 echo '# dummy' > "$dirpart/$file"
25973 done
25974 done
25975 }
25976 ;;
25977 "mkdirs":C)
25978 for dir in etc lisp ; do
25979 test -d ${dir} || mkdir ${dir}
25980 done
25981 ;;
25982 "epaths":C)
25983 echo creating src/epaths.h
25984 ${MAKE-make} MAKEFILE_NAME=do-not-make-Makefile epaths-force
25985 ;;
25986 "gdbinit":C)
25987 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
25988 echo creating src/.gdbinit
25989 echo source $srcdir/src/.gdbinit > src/.gdbinit
25990 fi
25991 ;;
25992
25993 esac
25994 done # for ac_tag
25995
25996
25997 as_fn_exit 0
25998 _ACEOF
25999 ac_clean_files=$ac_clean_files_save
26000
26001 test $ac_write_fail = 0 ||
26002 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
26003
26004
26005 # configure is writing to config.log, and then calls config.status.
26006 # config.status does its own redirection, appending to config.log.
26007 # Unfortunately, on DOS this fails, as config.log is still kept open
26008 # by configure, so config.status won't be able to write to it; its
26009 # output is simply discarded. So we exec the FD to /dev/null,
26010 # effectively closing config.log, so it can be properly (re)opened and
26011 # appended to by config.status. When coming back to configure, we
26012 # need to make the FD available again.
26013 if test "$no_create" != yes; then
26014 ac_cs_success=:
26015 ac_config_status_args=
26016 test "$silent" = yes &&
26017 ac_config_status_args="$ac_config_status_args --quiet"
26018 exec 5>/dev/null
26019 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
26020 exec 5>>config.log
26021 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
26022 # would make configure fail if this is the last instruction.
26023 $ac_cs_success || as_fn_exit $?
26024 fi
26025 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
26026 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
26027 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
26028 fi
26029