Assume freestanding C89 headers, string.h, stdlib.h.
[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.0.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.0.50'
553 PACKAGE_STRING='emacs 24.0.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 LIB_GCC
608 LD_FIRSTFLAG
609 LD_SWITCH_SYSTEM_TEMACS
610 POST_ALLOC_OBJ
611 PRE_ALLOC_OBJ
612 CYGWIN_OBJ
613 RALLOC_OBJ
614 OLDXMENU_DEPS
615 LIBX_OTHER
616 LIBXMENU
617 OLDXMENU
618 OLDXMENU_TARGET
619 LIBXT_OTHER
620 TOOLKIT_LIBW
621 WIDGET_OBJ
622 XOBJ
623 XMENU_OBJ
624 FONT_OBJ
625 OTHER_FILES
626 GNU_OBJC_CFLAGS
627 ns_appsrc
628 ns_appresdir
629 ns_appbindir
630 ns_appdir
631 S_FILE
632 M_FILE
633 X_TOOLKIT_TYPE
634 C_SWITCH_X_SYSTEM
635 C_SWITCH_X_SITE
636 LD_SWITCH_X_SITE
637 gameuser
638 gamedir
639 bitmapdir
640 archlibdir
641 etcdir
642 x_default_search_path
643 lisppath
644 locallisppath
645 lispdir
646 srcdir
647 canonical
648 configuration
649 version
650 KRB4LIB
651 DESLIB
652 KRB5LIB
653 CRYPTOLIB
654 COM_ERRLIB
655 LIBRESOLV
656 LIBHESIOD
657 TERMCAP_OBJ
658 LIBS_TERMCAP
659 LIBGNU_LTLIBDEPS
660 LIBGNU_LIBDEPS
661 gltests_WITNESS
662 gl_GNULIB_ENABLED_verify_FALSE
663 gl_GNULIB_ENABLED_verify_TRUE
664 gl_GNULIB_ENABLED_strtoull_FALSE
665 gl_GNULIB_ENABLED_strtoull_TRUE
666 gl_GNULIB_ENABLED_stat_FALSE
667 gl_GNULIB_ENABLED_stat_TRUE
668 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
669 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
670 gl_GNULIB_ENABLED_dosname_FALSE
671 gl_GNULIB_ENABLED_dosname_TRUE
672 LTLIBINTL
673 LIBINTL
674 HAVE_UNISTD_H
675 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
676 NEXT_UNISTD_H
677 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
678 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
679 TIME_H_DEFINES_STRUCT_TIMESPEC
680 NEXT_AS_FIRST_DIRECTIVE_TIME_H
681 NEXT_TIME_H
682 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
683 NEXT_SYS_STAT_H
684 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
685 NEXT_STDLIB_H
686 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
687 NEXT_STDIO_H
688 REPLACE_VSPRINTF
689 REPLACE_VSNPRINTF
690 REPLACE_VPRINTF
691 REPLACE_VFPRINTF
692 REPLACE_VDPRINTF
693 REPLACE_VASPRINTF
694 REPLACE_TMPFILE
695 REPLACE_STDIO_WRITE_FUNCS
696 REPLACE_STDIO_READ_FUNCS
697 REPLACE_SPRINTF
698 REPLACE_SNPRINTF
699 REPLACE_RENAMEAT
700 REPLACE_RENAME
701 REPLACE_REMOVE
702 REPLACE_PRINTF
703 REPLACE_POPEN
704 REPLACE_PERROR
705 REPLACE_OBSTACK_PRINTF
706 REPLACE_GETLINE
707 REPLACE_GETDELIM
708 REPLACE_FTELLO
709 REPLACE_FTELL
710 REPLACE_FSEEKO
711 REPLACE_FSEEK
712 REPLACE_FREOPEN
713 REPLACE_FPURGE
714 REPLACE_FPRINTF
715 REPLACE_FOPEN
716 REPLACE_FFLUSH
717 REPLACE_FCLOSE
718 REPLACE_DPRINTF
719 HAVE_VDPRINTF
720 HAVE_VASPRINTF
721 HAVE_RENAMEAT
722 HAVE_FTELLO
723 HAVE_FSEEKO
724 HAVE_DPRINTF
725 HAVE_DECL_VSNPRINTF
726 HAVE_DECL_SNPRINTF
727 HAVE_DECL_OBSTACK_PRINTF
728 HAVE_DECL_GETLINE
729 HAVE_DECL_GETDELIM
730 HAVE_DECL_FTELLO
731 HAVE_DECL_FSEEKO
732 HAVE_DECL_FPURGE
733 GNULIB_VSPRINTF_POSIX
734 GNULIB_VSNPRINTF
735 GNULIB_VPRINTF_POSIX
736 GNULIB_VPRINTF
737 GNULIB_VFPRINTF_POSIX
738 GNULIB_VFPRINTF
739 GNULIB_VDPRINTF
740 GNULIB_VSCANF
741 GNULIB_VFSCANF
742 GNULIB_VASPRINTF
743 GNULIB_TMPFILE
744 GNULIB_STDIO_H_SIGPIPE
745 GNULIB_STDIO_H_NONBLOCKING
746 GNULIB_SPRINTF_POSIX
747 GNULIB_SNPRINTF
748 GNULIB_SCANF
749 GNULIB_RENAMEAT
750 GNULIB_RENAME
751 GNULIB_REMOVE
752 GNULIB_PUTS
753 GNULIB_PUTCHAR
754 GNULIB_PUTC
755 GNULIB_PRINTF_POSIX
756 GNULIB_PRINTF
757 GNULIB_POPEN
758 GNULIB_PERROR
759 GNULIB_OBSTACK_PRINTF_POSIX
760 GNULIB_OBSTACK_PRINTF
761 GNULIB_GETS
762 GNULIB_GETLINE
763 GNULIB_GETDELIM
764 GNULIB_GETCHAR
765 GNULIB_GETC
766 GNULIB_FWRITE
767 GNULIB_FTELLO
768 GNULIB_FTELL
769 GNULIB_FSEEKO
770 GNULIB_FSEEK
771 GNULIB_FSCANF
772 GNULIB_FREOPEN
773 GNULIB_FREAD
774 GNULIB_FPUTS
775 GNULIB_FPUTC
776 GNULIB_FPURGE
777 GNULIB_FPRINTF_POSIX
778 GNULIB_FPRINTF
779 GNULIB_FOPEN
780 GNULIB_FGETS
781 GNULIB_FGETC
782 GNULIB_FFLUSH
783 GNULIB_FCLOSE
784 GNULIB_DPRINTF
785 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
786 NEXT_STDDEF_H
787 GL_GENERATE_STDDEF_H_FALSE
788 GL_GENERATE_STDDEF_H_TRUE
789 STDDEF_H
790 HAVE_WCHAR_T
791 REPLACE_NULL
792 HAVE__BOOL
793 GL_GENERATE_STDBOOL_H_FALSE
794 GL_GENERATE_STDBOOL_H_TRUE
795 STDBOOL_H
796 GL_GENERATE_STDARG_H_FALSE
797 GL_GENERATE_STDARG_H_TRUE
798 STDARG_H
799 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
800 NEXT_STDARG_H
801 REPLACE_TIMEGM
802 REPLACE_NANOSLEEP
803 REPLACE_MKTIME
804 REPLACE_LOCALTIME_R
805 HAVE_TIMEGM
806 HAVE_STRPTIME
807 HAVE_NANOSLEEP
808 HAVE_DECL_LOCALTIME_R
809 GNULIB_TIME_R
810 GNULIB_TIMEGM
811 GNULIB_STRPTIME
812 GNULIB_NANOSLEEP
813 GNULIB_MKTIME
814 REPLACE_UTIMENSAT
815 REPLACE_STAT
816 REPLACE_MKNOD
817 REPLACE_MKFIFO
818 REPLACE_MKDIR
819 REPLACE_LSTAT
820 REPLACE_FUTIMENS
821 REPLACE_FSTATAT
822 REPLACE_FSTAT
823 HAVE_UTIMENSAT
824 HAVE_MKNODAT
825 HAVE_MKNOD
826 HAVE_MKFIFOAT
827 HAVE_MKFIFO
828 HAVE_MKDIRAT
829 HAVE_LSTAT
830 HAVE_LCHMOD
831 HAVE_FUTIMENS
832 HAVE_FSTATAT
833 HAVE_FCHMODAT
834 GNULIB_UTIMENSAT
835 GNULIB_STAT
836 GNULIB_MKNODAT
837 GNULIB_MKNOD
838 GNULIB_MKFIFOAT
839 GNULIB_MKFIFO
840 GNULIB_MKDIRAT
841 GNULIB_LSTAT
842 GNULIB_LCHMOD
843 GNULIB_FUTIMENS
844 GNULIB_FSTATAT
845 GNULIB_FCHMODAT
846 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
847 NEXT_INTTYPES_H
848 UINT64_MAX_EQ_ULONG_MAX
849 UINT32_MAX_LT_UINTMAX_MAX
850 PRIPTR_PREFIX
851 PRI_MACROS_BROKEN
852 INT64_MAX_EQ_LONG_MAX
853 INT32_MAX_LT_INTMAX_MAX
854 HAVE_DECL_STRTOUMAX
855 HAVE_DECL_STRTOIMAX
856 HAVE_DECL_IMAXDIV
857 HAVE_DECL_IMAXABS
858 GNULIB_STRTOUMAX
859 GNULIB_STRTOIMAX
860 GNULIB_IMAXDIV
861 GNULIB_IMAXABS
862 GL_GENERATE_STDINT_H_FALSE
863 GL_GENERATE_STDINT_H_TRUE
864 STDINT_H
865 WINT_T_SUFFIX
866 WCHAR_T_SUFFIX
867 SIG_ATOMIC_T_SUFFIX
868 SIZE_T_SUFFIX
869 PTRDIFF_T_SUFFIX
870 HAVE_SIGNED_WINT_T
871 HAVE_SIGNED_WCHAR_T
872 HAVE_SIGNED_SIG_ATOMIC_T
873 BITSIZEOF_WINT_T
874 BITSIZEOF_WCHAR_T
875 BITSIZEOF_SIG_ATOMIC_T
876 BITSIZEOF_SIZE_T
877 BITSIZEOF_PTRDIFF_T
878 APPLE_UNIVERSAL_BUILD
879 HAVE_SYS_BITYPES_H
880 HAVE_SYS_INTTYPES_H
881 HAVE_STDINT_H
882 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
883 NEXT_STDINT_H
884 HAVE_SYS_TYPES_H
885 HAVE_INTTYPES_H
886 HAVE_WCHAR_H
887 HAVE_UNSIGNED_LONG_LONG_INT
888 HAVE_LONG_LONG_INT
889 GETOPT_H
890 HAVE_GETOPT_H
891 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
892 NEXT_GETOPT_H
893 PRAGMA_COLUMNS
894 PRAGMA_SYSTEM_HEADER
895 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
896 INCLUDE_NEXT
897 GETLOADAVG_LIBS
898 REPLACE_WCTOMB
899 REPLACE_UNSETENV
900 REPLACE_STRTOD
901 REPLACE_SETENV
902 REPLACE_REALPATH
903 REPLACE_REALLOC
904 REPLACE_PUTENV
905 REPLACE_MKSTEMP
906 REPLACE_MBTOWC
907 REPLACE_MALLOC
908 REPLACE_CANONICALIZE_FILE_NAME
909 REPLACE_CALLOC
910 HAVE_DECL_UNSETENV
911 HAVE_UNLOCKPT
912 HAVE_SYS_LOADAVG_H
913 HAVE_STRUCT_RANDOM_DATA
914 HAVE_STRTOULL
915 HAVE_STRTOLL
916 HAVE_STRTOD
917 HAVE_DECL_SETENV
918 HAVE_SETENV
919 HAVE_RPMATCH
920 HAVE_REALPATH
921 HAVE_RANDOM_R
922 HAVE_RANDOM_H
923 HAVE_PTSNAME
924 HAVE_MKSTEMPS
925 HAVE_MKSTEMP
926 HAVE_MKOSTEMPS
927 HAVE_MKOSTEMP
928 HAVE_MKDTEMP
929 HAVE_GRANTPT
930 HAVE_GETSUBOPT
931 HAVE_DECL_GETLOADAVG
932 HAVE_CANONICALIZE_FILE_NAME
933 HAVE_ATOLL
934 HAVE__EXIT
935 GNULIB_WCTOMB
936 GNULIB_UNSETENV
937 GNULIB_UNLOCKPT
938 GNULIB_SYSTEM_POSIX
939 GNULIB_STRTOULL
940 GNULIB_STRTOLL
941 GNULIB_STRTOD
942 GNULIB_SETENV
943 GNULIB_RPMATCH
944 GNULIB_REALPATH
945 GNULIB_REALLOC_POSIX
946 GNULIB_RANDOM_R
947 GNULIB_PUTENV
948 GNULIB_PTSNAME
949 GNULIB_MKSTEMPS
950 GNULIB_MKSTEMP
951 GNULIB_MKOSTEMPS
952 GNULIB_MKOSTEMP
953 GNULIB_MKDTEMP
954 GNULIB_MBTOWC
955 GNULIB_MALLOC_POSIX
956 GNULIB_GRANTPT
957 GNULIB_GETSUBOPT
958 GNULIB_GETLOADAVG
959 GNULIB_CANONICALIZE_FILE_NAME
960 GNULIB_CALLOC_POSIX
961 GNULIB_ATOLL
962 GNULIB__EXIT
963 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
964 UNISTD_H_HAVE_WINSOCK2_H
965 REPLACE_WRITE
966 REPLACE_USLEEP
967 REPLACE_UNLINKAT
968 REPLACE_UNLINK
969 REPLACE_TTYNAME_R
970 REPLACE_SYMLINK
971 REPLACE_SLEEP
972 REPLACE_RMDIR
973 REPLACE_READLINK
974 REPLACE_READ
975 REPLACE_PWRITE
976 REPLACE_PREAD
977 REPLACE_LSEEK
978 REPLACE_LINKAT
979 REPLACE_LINK
980 REPLACE_LCHOWN
981 REPLACE_GETPAGESIZE
982 REPLACE_GETGROUPS
983 REPLACE_GETLOGIN_R
984 REPLACE_GETDOMAINNAME
985 REPLACE_GETCWD
986 REPLACE_FCHOWNAT
987 REPLACE_DUP2
988 REPLACE_DUP
989 REPLACE_CLOSE
990 REPLACE_CHOWN
991 HAVE_SYS_PARAM_H
992 HAVE_OS_H
993 HAVE_DECL_TTYNAME_R
994 HAVE_DECL_GETUSERSHELL
995 HAVE_DECL_GETPAGESIZE
996 HAVE_DECL_GETLOGIN_R
997 HAVE_DECL_GETDOMAINNAME
998 HAVE_DECL_FCHDIR
999 HAVE_DECL_ENVIRON
1000 HAVE_USLEEP
1001 HAVE_UNLINKAT
1002 HAVE_SYMLINKAT
1003 HAVE_SYMLINK
1004 HAVE_SLEEP
1005 HAVE_READLINKAT
1006 HAVE_READLINK
1007 HAVE_PWRITE
1008 HAVE_PREAD
1009 HAVE_PIPE2
1010 HAVE_PIPE
1011 HAVE_LINKAT
1012 HAVE_LINK
1013 HAVE_LCHOWN
1014 HAVE_GROUP_MEMBER
1015 HAVE_GETPAGESIZE
1016 HAVE_GETLOGIN
1017 HAVE_GETHOSTNAME
1018 HAVE_GETGROUPS
1019 HAVE_GETDTABLESIZE
1020 HAVE_FTRUNCATE
1021 HAVE_FSYNC
1022 HAVE_FCHOWNAT
1023 HAVE_FCHDIR
1024 HAVE_FACCESSAT
1025 HAVE_EUIDACCESS
1026 HAVE_DUP3
1027 HAVE_DUP2
1028 HAVE_CHOWN
1029 GNULIB_WRITE
1030 GNULIB_USLEEP
1031 GNULIB_UNLINKAT
1032 GNULIB_UNLINK
1033 GNULIB_UNISTD_H_SIGPIPE
1034 GNULIB_UNISTD_H_NONBLOCKING
1035 GNULIB_UNISTD_H_GETOPT
1036 GNULIB_TTYNAME_R
1037 GNULIB_SYMLINKAT
1038 GNULIB_SYMLINK
1039 GNULIB_SLEEP
1040 GNULIB_RMDIR
1041 GNULIB_READLINKAT
1042 GNULIB_READLINK
1043 GNULIB_READ
1044 GNULIB_PWRITE
1045 GNULIB_PREAD
1046 GNULIB_PIPE2
1047 GNULIB_PIPE
1048 GNULIB_LSEEK
1049 GNULIB_LINKAT
1050 GNULIB_LINK
1051 GNULIB_LCHOWN
1052 GNULIB_GROUP_MEMBER
1053 GNULIB_GETUSERSHELL
1054 GNULIB_GETPAGESIZE
1055 GNULIB_GETLOGIN_R
1056 GNULIB_GETLOGIN
1057 GNULIB_GETHOSTNAME
1058 GNULIB_GETGROUPS
1059 GNULIB_GETDTABLESIZE
1060 GNULIB_GETDOMAINNAME
1061 GNULIB_GETCWD
1062 GNULIB_FTRUNCATE
1063 GNULIB_FSYNC
1064 GNULIB_FCHOWNAT
1065 GNULIB_FCHDIR
1066 GNULIB_FACCESSAT
1067 GNULIB_EUIDACCESS
1068 GNULIB_ENVIRON
1069 GNULIB_DUP3
1070 GNULIB_DUP2
1071 GNULIB_CLOSE
1072 GNULIB_CHOWN
1073 GL_GENERATE_ALLOCA_H_FALSE
1074 GL_GENERATE_ALLOCA_H_TRUE
1075 ALLOCA_H
1076 ALLOCA
1077 GL_COND_LIBTOOL_FALSE
1078 GL_COND_LIBTOOL_TRUE
1079 BLESSMAIL_TARGET
1080 LIBS_MAIL
1081 liblockfile
1082 LIBXML2_LIBS
1083 LIBXML2_CFLAGS
1084 LIBXSM
1085 LIBGPM
1086 LIBGIF
1087 LIBTIFF
1088 LIBPNG
1089 LIBJPEG
1090 LIBXPM
1091 M17N_FLT_LIBS
1092 M17N_FLT_CFLAGS
1093 LIBOTF_LIBS
1094 LIBOTF_CFLAGS
1095 FREETYPE_LIBS
1096 FREETYPE_CFLAGS
1097 XFT_LIBS
1098 XFT_CFLAGS
1099 FONTCONFIG_LIBS
1100 FONTCONFIG_CFLAGS
1101 LIBXMU
1102 LIBXTR6
1103 LIBGNUTLS_LIBS
1104 LIBGNUTLS_CFLAGS
1105 LIBSELINUX_LIBS
1106 SETTINGS_LIBS
1107 SETTINGS_CFLAGS
1108 GCONF_LIBS
1109 GCONF_CFLAGS
1110 GSETTINGS_LIBS
1111 GSETTINGS_CFLAGS
1112 DBUS_OBJ
1113 DBUS_LIBS
1114 DBUS_CFLAGS
1115 GTK_OBJ
1116 GTK_LIBS
1117 GTK_CFLAGS
1118 IMAGEMAGICK_LIBS
1119 IMAGEMAGICK_CFLAGS
1120 RSVG_LIBS
1121 RSVG_CFLAGS
1122 VMLIMIT_OBJ
1123 GMALLOC_OBJ
1124 HAVE_XSERVER
1125 LIB_STANDARD
1126 NS_OBJC_OBJ
1127 NS_OBJ
1128 TEMACS_LDFLAGS2
1129 LD_SWITCH_X_SITE_AUX_RPATH
1130 LD_SWITCH_X_SITE_AUX
1131 XMKMF
1132 DEPFLAGS
1133 MKDEPDIR
1134 CFLAGS_SOUND
1135 ALSA_LIBS
1136 ALSA_CFLAGS
1137 PKG_CONFIG
1138 LIBSOUND
1139 CRT_DIR
1140 START_FILES
1141 LIB_MATH
1142 LIBS_SYSTEM
1143 C_SWITCH_SYSTEM
1144 UNEXEC_OBJ
1145 C_SWITCH_MACHINE
1146 LD_SWITCH_SYSTEM
1147 CANNOT_DUMP
1148 HAVE_MAKEINFO
1149 GZIP_PROG
1150 INSTALL_INFO
1151 C_WARNINGS_SWITCH
1152 EGREP
1153 GREP
1154 CPP
1155 RANLIB
1156 am__fastdepCC_FALSE
1157 am__fastdepCC_TRUE
1158 CCDEPMODE
1159 AMDEPBACKSLASH
1160 AMDEP_FALSE
1161 AMDEP_TRUE
1162 am__quote
1163 am__include
1164 DEPDIR
1165 OBJEXT
1166 EXEEXT
1167 ac_ct_CC
1168 CPPFLAGS
1169 LDFLAGS
1170 CFLAGS
1171 CC
1172 host_os
1173 host_vendor
1174 host_cpu
1175 host
1176 build_os
1177 build_vendor
1178 build_cpu
1179 build
1180 PROFILING_CFLAGS
1181 MAINT
1182 GZIP_INFO
1183 am__untar
1184 am__tar
1185 AMTAR
1186 am__leading_dot
1187 SET_MAKE
1188 AWK
1189 mkdir_p
1190 MKDIR_P
1191 INSTALL_STRIP_PROGRAM
1192 STRIP
1193 install_sh
1194 MAKEINFO
1195 AUTOHEADER
1196 AUTOMAKE
1197 AUTOCONF
1198 ACLOCAL
1199 VERSION
1200 PACKAGE
1201 CYGPATH_W
1202 am__isrc
1203 INSTALL_DATA
1204 INSTALL_SCRIPT
1205 INSTALL_PROGRAM
1206 target_alias
1207 host_alias
1208 build_alias
1209 LIBS
1210 ECHO_T
1211 ECHO_N
1212 ECHO_C
1213 DEFS
1214 mandir
1215 localedir
1216 libdir
1217 psdir
1218 pdfdir
1219 dvidir
1220 htmldir
1221 infodir
1222 docdir
1223 oldincludedir
1224 includedir
1225 localstatedir
1226 sharedstatedir
1227 sysconfdir
1228 datadir
1229 datarootdir
1230 libexecdir
1231 sbindir
1232 bindir
1233 program_transform_name
1234 prefix
1235 exec_prefix
1236 PACKAGE_URL
1237 PACKAGE_BUGREPORT
1238 PACKAGE_STRING
1239 PACKAGE_VERSION
1240 PACKAGE_TARNAME
1241 PACKAGE_NAME
1242 PATH_SEPARATOR
1243 SHELL'
1244 ac_subst_files='deps_frag
1245 lisp_frag
1246 ns_frag'
1247 ac_user_opts='
1248 enable_option_checking
1249 with_pop
1250 with_kerberos
1251 with_kerberos5
1252 with_hesiod
1253 with_mmdf
1254 with_mail_unlink
1255 with_mailhost
1256 with_sound
1257 with_sync_input
1258 with_x_toolkit
1259 with_wide_int
1260 with_xpm
1261 with_jpeg
1262 with_tiff
1263 with_gif
1264 with_png
1265 with_rsvg
1266 with_xml2
1267 with_imagemagick
1268 with_xft
1269 with_libotf
1270 with_m17n_flt
1271 with_toolkit_scroll_bars
1272 with_xaw3d
1273 with_xim
1274 with_ns
1275 with_gpm
1276 with_dbus
1277 with_gconf
1278 with_gsettings
1279 with_selinux
1280 with_gnutls
1281 with_makeinfo
1282 with_compress_info
1283 with_pkg_config_prog
1284 with_crt_dir
1285 with_gameuser
1286 with_gnustep_conf
1287 enable_ns_self_contained
1288 enable_asserts
1289 enable_maintainer_mode
1290 enable_locallisppath
1291 enable_checking
1292 enable_use_lisp_union_type
1293 enable_profiling
1294 enable_autodepend
1295 enable_dependency_tracking
1296 enable_largefile
1297 with_x
1298 '
1299 ac_precious_vars='build_alias
1300 host_alias
1301 target_alias
1302 CC
1303 CFLAGS
1304 LDFLAGS
1305 LIBS
1306 CPPFLAGS
1307 CPP
1308 XMKMF'
1309
1310
1311 # Initialize some variables set by options.
1312 ac_init_help=
1313 ac_init_version=false
1314 ac_unrecognized_opts=
1315 ac_unrecognized_sep=
1316 # The variables have the same names as the options, with
1317 # dashes changed to underlines.
1318 cache_file=/dev/null
1319 exec_prefix=NONE
1320 no_create=
1321 no_recursion=
1322 prefix=NONE
1323 program_prefix=NONE
1324 program_suffix=NONE
1325 program_transform_name=s,x,x,
1326 silent=
1327 site=
1328 srcdir=
1329 verbose=
1330 x_includes=NONE
1331 x_libraries=NONE
1332
1333 # Installation directory options.
1334 # These are left unexpanded so users can "make install exec_prefix=/foo"
1335 # and all the variables that are supposed to be based on exec_prefix
1336 # by default will actually change.
1337 # Use braces instead of parens because sh, perl, etc. also accept them.
1338 # (The list follows the same order as the GNU Coding Standards.)
1339 bindir='${exec_prefix}/bin'
1340 sbindir='${exec_prefix}/sbin'
1341 libexecdir='${exec_prefix}/libexec'
1342 datarootdir='${prefix}/share'
1343 datadir='${datarootdir}'
1344 sysconfdir='${prefix}/etc'
1345 sharedstatedir='${prefix}/com'
1346 localstatedir='${prefix}/var'
1347 includedir='${prefix}/include'
1348 oldincludedir='/usr/include'
1349 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1350 infodir='${datarootdir}/info'
1351 htmldir='${docdir}'
1352 dvidir='${docdir}'
1353 pdfdir='${docdir}'
1354 psdir='${docdir}'
1355 libdir='${exec_prefix}/lib'
1356 localedir='${datarootdir}/locale'
1357 mandir='${datarootdir}/man'
1358
1359 ac_prev=
1360 ac_dashdash=
1361 for ac_option
1362 do
1363 # If the previous option needs an argument, assign it.
1364 if test -n "$ac_prev"; then
1365 eval $ac_prev=\$ac_option
1366 ac_prev=
1367 continue
1368 fi
1369
1370 case $ac_option in
1371 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1372 *) ac_optarg=yes ;;
1373 esac
1374
1375 # Accept the important Cygnus configure options, so we can diagnose typos.
1376
1377 case $ac_dashdash$ac_option in
1378 --)
1379 ac_dashdash=yes ;;
1380
1381 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1382 ac_prev=bindir ;;
1383 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1384 bindir=$ac_optarg ;;
1385
1386 -build | --build | --buil | --bui | --bu)
1387 ac_prev=build_alias ;;
1388 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1389 build_alias=$ac_optarg ;;
1390
1391 -cache-file | --cache-file | --cache-fil | --cache-fi \
1392 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1393 ac_prev=cache_file ;;
1394 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1395 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1396 cache_file=$ac_optarg ;;
1397
1398 --config-cache | -C)
1399 cache_file=config.cache ;;
1400
1401 -datadir | --datadir | --datadi | --datad)
1402 ac_prev=datadir ;;
1403 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1404 datadir=$ac_optarg ;;
1405
1406 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1407 | --dataroo | --dataro | --datar)
1408 ac_prev=datarootdir ;;
1409 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1410 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1411 datarootdir=$ac_optarg ;;
1412
1413 -disable-* | --disable-*)
1414 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1415 # Reject names that are not valid shell variable names.
1416 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1417 as_fn_error "invalid feature name: $ac_useropt"
1418 ac_useropt_orig=$ac_useropt
1419 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1420 case $ac_user_opts in
1421 *"
1422 "enable_$ac_useropt"
1423 "*) ;;
1424 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1425 ac_unrecognized_sep=', ';;
1426 esac
1427 eval enable_$ac_useropt=no ;;
1428
1429 -docdir | --docdir | --docdi | --doc | --do)
1430 ac_prev=docdir ;;
1431 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1432 docdir=$ac_optarg ;;
1433
1434 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1435 ac_prev=dvidir ;;
1436 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1437 dvidir=$ac_optarg ;;
1438
1439 -enable-* | --enable-*)
1440 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1441 # Reject names that are not valid shell variable names.
1442 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1443 as_fn_error "invalid feature name: $ac_useropt"
1444 ac_useropt_orig=$ac_useropt
1445 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1446 case $ac_user_opts in
1447 *"
1448 "enable_$ac_useropt"
1449 "*) ;;
1450 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1451 ac_unrecognized_sep=', ';;
1452 esac
1453 eval enable_$ac_useropt=\$ac_optarg ;;
1454
1455 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1456 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1457 | --exec | --exe | --ex)
1458 ac_prev=exec_prefix ;;
1459 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1460 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1461 | --exec=* | --exe=* | --ex=*)
1462 exec_prefix=$ac_optarg ;;
1463
1464 -gas | --gas | --ga | --g)
1465 # Obsolete; use --with-gas.
1466 with_gas=yes ;;
1467
1468 -help | --help | --hel | --he | -h)
1469 ac_init_help=long ;;
1470 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1471 ac_init_help=recursive ;;
1472 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1473 ac_init_help=short ;;
1474
1475 -host | --host | --hos | --ho)
1476 ac_prev=host_alias ;;
1477 -host=* | --host=* | --hos=* | --ho=*)
1478 host_alias=$ac_optarg ;;
1479
1480 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1481 ac_prev=htmldir ;;
1482 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1483 | --ht=*)
1484 htmldir=$ac_optarg ;;
1485
1486 -includedir | --includedir | --includedi | --included | --include \
1487 | --includ | --inclu | --incl | --inc)
1488 ac_prev=includedir ;;
1489 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1490 | --includ=* | --inclu=* | --incl=* | --inc=*)
1491 includedir=$ac_optarg ;;
1492
1493 -infodir | --infodir | --infodi | --infod | --info | --inf)
1494 ac_prev=infodir ;;
1495 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1496 infodir=$ac_optarg ;;
1497
1498 -libdir | --libdir | --libdi | --libd)
1499 ac_prev=libdir ;;
1500 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1501 libdir=$ac_optarg ;;
1502
1503 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1504 | --libexe | --libex | --libe)
1505 ac_prev=libexecdir ;;
1506 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1507 | --libexe=* | --libex=* | --libe=*)
1508 libexecdir=$ac_optarg ;;
1509
1510 -localedir | --localedir | --localedi | --localed | --locale)
1511 ac_prev=localedir ;;
1512 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1513 localedir=$ac_optarg ;;
1514
1515 -localstatedir | --localstatedir | --localstatedi | --localstated \
1516 | --localstate | --localstat | --localsta | --localst | --locals)
1517 ac_prev=localstatedir ;;
1518 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1519 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1520 localstatedir=$ac_optarg ;;
1521
1522 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1523 ac_prev=mandir ;;
1524 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1525 mandir=$ac_optarg ;;
1526
1527 -nfp | --nfp | --nf)
1528 # Obsolete; use --without-fp.
1529 with_fp=no ;;
1530
1531 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1532 | --no-cr | --no-c | -n)
1533 no_create=yes ;;
1534
1535 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1536 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1537 no_recursion=yes ;;
1538
1539 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1540 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1541 | --oldin | --oldi | --old | --ol | --o)
1542 ac_prev=oldincludedir ;;
1543 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1544 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1545 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1546 oldincludedir=$ac_optarg ;;
1547
1548 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1549 ac_prev=prefix ;;
1550 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1551 prefix=$ac_optarg ;;
1552
1553 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1554 | --program-pre | --program-pr | --program-p)
1555 ac_prev=program_prefix ;;
1556 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1557 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1558 program_prefix=$ac_optarg ;;
1559
1560 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1561 | --program-suf | --program-su | --program-s)
1562 ac_prev=program_suffix ;;
1563 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1564 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1565 program_suffix=$ac_optarg ;;
1566
1567 -program-transform-name | --program-transform-name \
1568 | --program-transform-nam | --program-transform-na \
1569 | --program-transform-n | --program-transform- \
1570 | --program-transform | --program-transfor \
1571 | --program-transfo | --program-transf \
1572 | --program-trans | --program-tran \
1573 | --progr-tra | --program-tr | --program-t)
1574 ac_prev=program_transform_name ;;
1575 -program-transform-name=* | --program-transform-name=* \
1576 | --program-transform-nam=* | --program-transform-na=* \
1577 | --program-transform-n=* | --program-transform-=* \
1578 | --program-transform=* | --program-transfor=* \
1579 | --program-transfo=* | --program-transf=* \
1580 | --program-trans=* | --program-tran=* \
1581 | --progr-tra=* | --program-tr=* | --program-t=*)
1582 program_transform_name=$ac_optarg ;;
1583
1584 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1585 ac_prev=pdfdir ;;
1586 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1587 pdfdir=$ac_optarg ;;
1588
1589 -psdir | --psdir | --psdi | --psd | --ps)
1590 ac_prev=psdir ;;
1591 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1592 psdir=$ac_optarg ;;
1593
1594 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1595 | -silent | --silent | --silen | --sile | --sil)
1596 silent=yes ;;
1597
1598 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1599 ac_prev=sbindir ;;
1600 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1601 | --sbi=* | --sb=*)
1602 sbindir=$ac_optarg ;;
1603
1604 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1605 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1606 | --sharedst | --shareds | --shared | --share | --shar \
1607 | --sha | --sh)
1608 ac_prev=sharedstatedir ;;
1609 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1610 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1611 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1612 | --sha=* | --sh=*)
1613 sharedstatedir=$ac_optarg ;;
1614
1615 -site | --site | --sit)
1616 ac_prev=site ;;
1617 -site=* | --site=* | --sit=*)
1618 site=$ac_optarg ;;
1619
1620 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1621 ac_prev=srcdir ;;
1622 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1623 srcdir=$ac_optarg ;;
1624
1625 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1626 | --syscon | --sysco | --sysc | --sys | --sy)
1627 ac_prev=sysconfdir ;;
1628 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1629 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1630 sysconfdir=$ac_optarg ;;
1631
1632 -target | --target | --targe | --targ | --tar | --ta | --t)
1633 ac_prev=target_alias ;;
1634 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1635 target_alias=$ac_optarg ;;
1636
1637 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1638 verbose=yes ;;
1639
1640 -version | --version | --versio | --versi | --vers | -V)
1641 ac_init_version=: ;;
1642
1643 -with-* | --with-*)
1644 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1645 # Reject names that are not valid shell variable names.
1646 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1647 as_fn_error "invalid package name: $ac_useropt"
1648 ac_useropt_orig=$ac_useropt
1649 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1650 case $ac_user_opts in
1651 *"
1652 "with_$ac_useropt"
1653 "*) ;;
1654 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1655 ac_unrecognized_sep=', ';;
1656 esac
1657 eval with_$ac_useropt=\$ac_optarg ;;
1658
1659 -without-* | --without-*)
1660 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1661 # Reject names that are not valid shell variable names.
1662 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1663 as_fn_error "invalid package name: $ac_useropt"
1664 ac_useropt_orig=$ac_useropt
1665 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1666 case $ac_user_opts in
1667 *"
1668 "with_$ac_useropt"
1669 "*) ;;
1670 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1671 ac_unrecognized_sep=', ';;
1672 esac
1673 eval with_$ac_useropt=no ;;
1674
1675 --x)
1676 # Obsolete; use --with-x.
1677 with_x=yes ;;
1678
1679 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1680 | --x-incl | --x-inc | --x-in | --x-i)
1681 ac_prev=x_includes ;;
1682 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1683 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1684 x_includes=$ac_optarg ;;
1685
1686 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1687 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1688 ac_prev=x_libraries ;;
1689 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1690 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1691 x_libraries=$ac_optarg ;;
1692
1693 -*) as_fn_error "unrecognized option: \`$ac_option'
1694 Try \`$0 --help' for more information."
1695 ;;
1696
1697 *=*)
1698 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1699 # Reject names that are not valid shell variable names.
1700 case $ac_envvar in #(
1701 '' | [0-9]* | *[!_$as_cr_alnum]* )
1702 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1703 esac
1704 eval $ac_envvar=\$ac_optarg
1705 export $ac_envvar ;;
1706
1707 *)
1708 # FIXME: should be removed in autoconf 3.0.
1709 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1710 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1711 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1712 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1713 ;;
1714
1715 esac
1716 done
1717
1718 if test -n "$ac_prev"; then
1719 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1720 as_fn_error "missing argument to $ac_option"
1721 fi
1722
1723 if test -n "$ac_unrecognized_opts"; then
1724 case $enable_option_checking in
1725 no) ;;
1726 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1727 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1728 esac
1729 fi
1730
1731 # Check all directory arguments for consistency.
1732 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1733 datadir sysconfdir sharedstatedir localstatedir includedir \
1734 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1735 libdir localedir mandir
1736 do
1737 eval ac_val=\$$ac_var
1738 # Remove trailing slashes.
1739 case $ac_val in
1740 */ )
1741 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1742 eval $ac_var=\$ac_val;;
1743 esac
1744 # Be sure to have absolute directory names.
1745 case $ac_val in
1746 [\\/$]* | ?:[\\/]* ) continue;;
1747 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1748 esac
1749 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1750 done
1751
1752 # There might be people who depend on the old broken behavior: `$host'
1753 # used to hold the argument of --host etc.
1754 # FIXME: To remove some day.
1755 build=$build_alias
1756 host=$host_alias
1757 target=$target_alias
1758
1759 # FIXME: To remove some day.
1760 if test "x$host_alias" != x; then
1761 if test "x$build_alias" = x; then
1762 cross_compiling=maybe
1763 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1764 If a cross compiler is detected then cross compile mode will be used." >&2
1765 elif test "x$build_alias" != "x$host_alias"; then
1766 cross_compiling=yes
1767 fi
1768 fi
1769
1770 ac_tool_prefix=
1771 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1772
1773 test "$silent" = yes && exec 6>/dev/null
1774
1775
1776 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1777 ac_ls_di=`ls -di .` &&
1778 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1779 as_fn_error "working directory cannot be determined"
1780 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1781 as_fn_error "pwd does not report name of working directory"
1782
1783
1784 # Find the source files, if location was not specified.
1785 if test -z "$srcdir"; then
1786 ac_srcdir_defaulted=yes
1787 # Try the directory containing this script, then the parent directory.
1788 ac_confdir=`$as_dirname -- "$as_myself" ||
1789 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1790 X"$as_myself" : 'X\(//\)[^/]' \| \
1791 X"$as_myself" : 'X\(//\)$' \| \
1792 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1793 $as_echo X"$as_myself" |
1794 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1795 s//\1/
1796 q
1797 }
1798 /^X\(\/\/\)[^/].*/{
1799 s//\1/
1800 q
1801 }
1802 /^X\(\/\/\)$/{
1803 s//\1/
1804 q
1805 }
1806 /^X\(\/\).*/{
1807 s//\1/
1808 q
1809 }
1810 s/.*/./; q'`
1811 srcdir=$ac_confdir
1812 if test ! -r "$srcdir/$ac_unique_file"; then
1813 srcdir=..
1814 fi
1815 else
1816 ac_srcdir_defaulted=no
1817 fi
1818 if test ! -r "$srcdir/$ac_unique_file"; then
1819 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1820 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1821 fi
1822 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1823 ac_abs_confdir=`(
1824 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1825 pwd)`
1826 # When building in place, set srcdir=.
1827 if test "$ac_abs_confdir" = "$ac_pwd"; then
1828 srcdir=.
1829 fi
1830 # Remove unnecessary trailing slashes from srcdir.
1831 # Double slashes in file names in object file debugging info
1832 # mess up M-x gdb in Emacs.
1833 case $srcdir in
1834 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1835 esac
1836 for ac_var in $ac_precious_vars; do
1837 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1838 eval ac_env_${ac_var}_value=\$${ac_var}
1839 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1840 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1841 done
1842
1843 #
1844 # Report the --help message.
1845 #
1846 if test "$ac_init_help" = "long"; then
1847 # Omit some internal or obsolete options to make the list less imposing.
1848 # This message is too long to be a string in the A/UX 3.1 sh.
1849 cat <<_ACEOF
1850 \`configure' configures emacs 24.0.50 to adapt to many kinds of systems.
1851
1852 Usage: $0 [OPTION]... [VAR=VALUE]...
1853
1854 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1855 VAR=VALUE. See below for descriptions of some of the useful variables.
1856
1857 Defaults for the options are specified in brackets.
1858
1859 Configuration:
1860 -h, --help display this help and exit
1861 --help=short display options specific to this package
1862 --help=recursive display the short help of all the included packages
1863 -V, --version display version information and exit
1864 -q, --quiet, --silent do not print \`checking...' messages
1865 --cache-file=FILE cache test results in FILE [disabled]
1866 -C, --config-cache alias for \`--cache-file=config.cache'
1867 -n, --no-create do not create output files
1868 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1869
1870 Installation directories:
1871 --prefix=PREFIX install architecture-independent files in PREFIX
1872 [$ac_default_prefix]
1873 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1874 [PREFIX]
1875
1876 By default, \`make install' will install all the files in
1877 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1878 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1879 for instance \`--prefix=\$HOME'.
1880
1881 For better control, use the options below.
1882
1883 Fine tuning of the installation directories:
1884 --bindir=DIR user executables [EPREFIX/bin]
1885 --sbindir=DIR system admin executables [EPREFIX/sbin]
1886 --libexecdir=DIR program executables [EPREFIX/libexec]
1887 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1888 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1889 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1890 --libdir=DIR object code libraries [EPREFIX/lib]
1891 --includedir=DIR C header files [PREFIX/include]
1892 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1893 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1894 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1895 --infodir=DIR info documentation [DATAROOTDIR/info]
1896 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1897 --mandir=DIR man documentation [DATAROOTDIR/man]
1898 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1899 --htmldir=DIR html documentation [DOCDIR]
1900 --dvidir=DIR dvi documentation [DOCDIR]
1901 --pdfdir=DIR pdf documentation [DOCDIR]
1902 --psdir=DIR ps documentation [DOCDIR]
1903 _ACEOF
1904
1905 cat <<\_ACEOF
1906
1907 Program names:
1908 --program-prefix=PREFIX prepend PREFIX to installed program names
1909 --program-suffix=SUFFIX append SUFFIX to installed program names
1910 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1911
1912 X features:
1913 --x-includes=DIR X include files are in DIR
1914 --x-libraries=DIR X library files are in DIR
1915
1916 System types:
1917 --build=BUILD configure for building on BUILD [guessed]
1918 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1919 _ACEOF
1920 fi
1921
1922 if test -n "$ac_init_help"; then
1923 case $ac_init_help in
1924 short | recursive ) echo "Configuration of emacs 24.0.50:";;
1925 esac
1926 cat <<\_ACEOF
1927
1928 Optional Features:
1929 --disable-option-checking ignore unrecognized --enable/--with options
1930 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1931 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1932 --disable-ns-self-contained
1933 disable self contained build under NeXTstep
1934 --enable-asserts compile code with asserts enabled
1935 --enable-maintainer-mode
1936 enable make rules and dependencies not useful (and
1937 sometimes confusing) to the casual installer
1938 --enable-locallisppath=PATH
1939 directories Emacs should search for lisp files
1940 specific to this site
1941 --enable-checking[=LIST]
1942 enable expensive run-time checks. With LIST, enable
1943 only specific categories of checks. Categories are:
1944 all,yes,no. Flags are: stringbytes, stringoverrun,
1945 stringfreelist, xmallocoverrun, conslist
1946 --enable-use-lisp-union-type
1947 use a union for the Lisp_Object data type. This is
1948 only useful for development for catching certain
1949 types of bugs.
1950 --enable-profiling build emacs with profiling support. This might not
1951 work on all platforms
1952 --enable-autodepend automatically generate dependencies to .h-files.
1953 Requires GNU Make and Gcc. Enabled if GNU Make and
1954 Gcc is found
1955 --disable-dependency-tracking speeds up one-time build
1956 --enable-dependency-tracking do not reject slow dependency extractors
1957 --disable-largefile omit support for large files
1958
1959 Optional Packages:
1960 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1961 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1962 --without-pop don't support POP mail retrieval with movemail
1963 --with-kerberos support Kerberos-authenticated POP
1964 --with-kerberos5 support Kerberos version 5 authenticated POP
1965 --with-hesiod support Hesiod to get the POP server host
1966 --with-mmdf support MMDF mailboxes
1967 --with-mail-unlink unlink, rather than empty, mail spool after reading
1968 --with-mailhost=HOSTNAME
1969 string giving default POP mail host
1970 --without-sound don't compile with sound support
1971 --without-sync-input process async input synchronously
1972 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
1973 lucid or athena, motif, no)
1974 --with-wide-int prefer wide Emacs integers (typically 62-bit)
1975 --without-xpm don't compile with XPM image support
1976 --without-jpeg don't compile with JPEG image support
1977 --without-tiff don't compile with TIFF image support
1978 --without-gif don't compile with GIF image support
1979 --without-png don't compile with PNG image support
1980 --without-rsvg don't compile with SVG image support
1981 --without-xml2 don't compile with XML parsing support
1982 --without-imagemagick don't compile with ImageMagick image support
1983 --without-xft don't use XFT for anti aliased fonts
1984 --without-libotf don't use libotf for OpenType font support
1985 --without-m17n-flt don't use m17n-flt for text shaping
1986 --without-toolkit-scroll-bars
1987 don't use Motif or Xaw3d scroll bars
1988 --without-xaw3d don't use Xaw3d
1989 --without-xim don't use X11 XIM
1990 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
1991 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
1992 console
1993 --without-dbus don't compile with D-Bus support
1994 --without-gconf don't compile with GConf support
1995 --without-gsettings don't compile with GSettings support
1996 --without-selinux don't compile with SELinux support
1997 --without-gnutls don't use -lgnutls for SSL/TLS support
1998 --without-makeinfo don't require makeinfo for building manuals
1999 --without-compress-info don't compress the installed Info pages
2000 --with-pkg-config-prog=PATH
2001 path to pkg-config for finding GTK and librsvg
2002 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2003 /usr/lib, or /usr/lib64 on some platforms.
2004 --with-gameuser=USER user for shared game score files
2005 --with-gnustep-conf=PATH
2006 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2007 or /etc/GNUstep/GNUstep.conf
2008 --with-x use the X Window System
2009
2010 Some influential environment variables:
2011 CC C compiler command
2012 CFLAGS C compiler flags
2013 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2014 nonstandard directory <lib dir>
2015 LIBS libraries to pass to the linker, e.g. -l<library>
2016 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2017 you have headers in a nonstandard directory <include dir>
2018 CPP C preprocessor
2019 XMKMF Path to xmkmf, Makefile generator for X Window System
2020
2021 Use these variables to override the choices made by `configure' or to help
2022 it to find libraries and programs with nonstandard names/locations.
2023
2024 Report bugs to the package provider.
2025 _ACEOF
2026 ac_status=$?
2027 fi
2028
2029 if test "$ac_init_help" = "recursive"; then
2030 # If there are subdirs, report their specific --help.
2031 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2032 test -d "$ac_dir" ||
2033 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2034 continue
2035 ac_builddir=.
2036
2037 case "$ac_dir" in
2038 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2039 *)
2040 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2041 # A ".." for each directory in $ac_dir_suffix.
2042 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2043 case $ac_top_builddir_sub in
2044 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2045 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2046 esac ;;
2047 esac
2048 ac_abs_top_builddir=$ac_pwd
2049 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2050 # for backward compatibility:
2051 ac_top_builddir=$ac_top_build_prefix
2052
2053 case $srcdir in
2054 .) # We are building in place.
2055 ac_srcdir=.
2056 ac_top_srcdir=$ac_top_builddir_sub
2057 ac_abs_top_srcdir=$ac_pwd ;;
2058 [\\/]* | ?:[\\/]* ) # Absolute name.
2059 ac_srcdir=$srcdir$ac_dir_suffix;
2060 ac_top_srcdir=$srcdir
2061 ac_abs_top_srcdir=$srcdir ;;
2062 *) # Relative name.
2063 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2064 ac_top_srcdir=$ac_top_build_prefix$srcdir
2065 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2066 esac
2067 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2068
2069 cd "$ac_dir" || { ac_status=$?; continue; }
2070 # Check for guested configure.
2071 if test -f "$ac_srcdir/configure.gnu"; then
2072 echo &&
2073 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2074 elif test -f "$ac_srcdir/configure"; then
2075 echo &&
2076 $SHELL "$ac_srcdir/configure" --help=recursive
2077 else
2078 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2079 fi || ac_status=$?
2080 cd "$ac_pwd" || { ac_status=$?; break; }
2081 done
2082 fi
2083
2084 test -n "$ac_init_help" && exit $ac_status
2085 if $ac_init_version; then
2086 cat <<\_ACEOF
2087 emacs configure 24.0.50
2088 generated by GNU Autoconf 2.65
2089
2090 Copyright (C) 2009 Free Software Foundation, Inc.
2091 This configure script is free software; the Free Software Foundation
2092 gives unlimited permission to copy, distribute and modify it.
2093 _ACEOF
2094 exit
2095 fi
2096
2097 ## ------------------------ ##
2098 ## Autoconf initialization. ##
2099 ## ------------------------ ##
2100
2101 # ac_fn_c_try_compile LINENO
2102 # --------------------------
2103 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2104 ac_fn_c_try_compile ()
2105 {
2106 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2107 rm -f conftest.$ac_objext
2108 if { { ac_try="$ac_compile"
2109 case "(($ac_try" in
2110 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2111 *) ac_try_echo=$ac_try;;
2112 esac
2113 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2114 $as_echo "$ac_try_echo"; } >&5
2115 (eval "$ac_compile") 2>conftest.err
2116 ac_status=$?
2117 if test -s conftest.err; then
2118 grep -v '^ *+' conftest.err >conftest.er1
2119 cat conftest.er1 >&5
2120 mv -f conftest.er1 conftest.err
2121 fi
2122 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2123 test $ac_status = 0; } && {
2124 test -z "$ac_c_werror_flag" ||
2125 test ! -s conftest.err
2126 } && test -s conftest.$ac_objext; then :
2127 ac_retval=0
2128 else
2129 $as_echo "$as_me: failed program was:" >&5
2130 sed 's/^/| /' conftest.$ac_ext >&5
2131
2132 ac_retval=1
2133 fi
2134 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2135 as_fn_set_status $ac_retval
2136
2137 } # ac_fn_c_try_compile
2138
2139 # ac_fn_c_try_cpp LINENO
2140 # ----------------------
2141 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2142 ac_fn_c_try_cpp ()
2143 {
2144 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2145 if { { ac_try="$ac_cpp conftest.$ac_ext"
2146 case "(($ac_try" in
2147 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2148 *) ac_try_echo=$ac_try;;
2149 esac
2150 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2151 $as_echo "$ac_try_echo"; } >&5
2152 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2153 ac_status=$?
2154 if test -s conftest.err; then
2155 grep -v '^ *+' conftest.err >conftest.er1
2156 cat conftest.er1 >&5
2157 mv -f conftest.er1 conftest.err
2158 fi
2159 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2160 test $ac_status = 0; } >/dev/null && {
2161 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2162 test ! -s conftest.err
2163 }; then :
2164 ac_retval=0
2165 else
2166 $as_echo "$as_me: failed program was:" >&5
2167 sed 's/^/| /' conftest.$ac_ext >&5
2168
2169 ac_retval=1
2170 fi
2171 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2172 as_fn_set_status $ac_retval
2173
2174 } # ac_fn_c_try_cpp
2175
2176 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2177 # -------------------------------------------------------
2178 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2179 # the include files in INCLUDES and setting the cache variable VAR
2180 # accordingly.
2181 ac_fn_c_check_header_mongrel ()
2182 {
2183 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2184 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2186 $as_echo_n "checking for $2... " >&6; }
2187 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2188 $as_echo_n "(cached) " >&6
2189 fi
2190 eval ac_res=\$$3
2191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2192 $as_echo "$ac_res" >&6; }
2193 else
2194 # Is the header compilable?
2195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2196 $as_echo_n "checking $2 usability... " >&6; }
2197 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2198 /* end confdefs.h. */
2199 $4
2200 #include <$2>
2201 _ACEOF
2202 if ac_fn_c_try_compile "$LINENO"; then :
2203 ac_header_compiler=yes
2204 else
2205 ac_header_compiler=no
2206 fi
2207 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2209 $as_echo "$ac_header_compiler" >&6; }
2210
2211 # Is the header present?
2212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2213 $as_echo_n "checking $2 presence... " >&6; }
2214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2215 /* end confdefs.h. */
2216 #include <$2>
2217 _ACEOF
2218 if ac_fn_c_try_cpp "$LINENO"; then :
2219 ac_header_preproc=yes
2220 else
2221 ac_header_preproc=no
2222 fi
2223 rm -f conftest.err conftest.$ac_ext
2224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2225 $as_echo "$ac_header_preproc" >&6; }
2226
2227 # So? What about this header?
2228 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2229 yes:no: )
2230 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2231 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2232 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2233 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2234 ;;
2235 no:yes:* )
2236 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2237 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2239 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2240 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2241 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2242 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2243 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2244 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2245 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2246 ;;
2247 esac
2248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2249 $as_echo_n "checking for $2... " >&6; }
2250 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2251 $as_echo_n "(cached) " >&6
2252 else
2253 eval "$3=\$ac_header_compiler"
2254 fi
2255 eval ac_res=\$$3
2256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2257 $as_echo "$ac_res" >&6; }
2258 fi
2259 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2260
2261 } # ac_fn_c_check_header_mongrel
2262
2263 # ac_fn_c_try_run LINENO
2264 # ----------------------
2265 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2266 # that executables *can* be run.
2267 ac_fn_c_try_run ()
2268 {
2269 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2270 if { { ac_try="$ac_link"
2271 case "(($ac_try" in
2272 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2273 *) ac_try_echo=$ac_try;;
2274 esac
2275 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2276 $as_echo "$ac_try_echo"; } >&5
2277 (eval "$ac_link") 2>&5
2278 ac_status=$?
2279 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2280 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2281 { { case "(($ac_try" in
2282 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2283 *) ac_try_echo=$ac_try;;
2284 esac
2285 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2286 $as_echo "$ac_try_echo"; } >&5
2287 (eval "$ac_try") 2>&5
2288 ac_status=$?
2289 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2290 test $ac_status = 0; }; }; then :
2291 ac_retval=0
2292 else
2293 $as_echo "$as_me: program exited with status $ac_status" >&5
2294 $as_echo "$as_me: failed program was:" >&5
2295 sed 's/^/| /' conftest.$ac_ext >&5
2296
2297 ac_retval=$ac_status
2298 fi
2299 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2300 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2301 as_fn_set_status $ac_retval
2302
2303 } # ac_fn_c_try_run
2304
2305 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2306 # -------------------------------------------------------
2307 # Tests whether HEADER exists and can be compiled using the include files in
2308 # INCLUDES, setting the cache variable VAR accordingly.
2309 ac_fn_c_check_header_compile ()
2310 {
2311 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2313 $as_echo_n "checking for $2... " >&6; }
2314 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2315 $as_echo_n "(cached) " >&6
2316 else
2317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2318 /* end confdefs.h. */
2319 $4
2320 #include <$2>
2321 _ACEOF
2322 if ac_fn_c_try_compile "$LINENO"; then :
2323 eval "$3=yes"
2324 else
2325 eval "$3=no"
2326 fi
2327 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2328 fi
2329 eval ac_res=\$$3
2330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2331 $as_echo "$ac_res" >&6; }
2332 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2333
2334 } # ac_fn_c_check_header_compile
2335
2336 # ac_fn_c_try_link LINENO
2337 # -----------------------
2338 # Try to link conftest.$ac_ext, and return whether this succeeded.
2339 ac_fn_c_try_link ()
2340 {
2341 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2342 rm -f conftest.$ac_objext conftest$ac_exeext
2343 if { { ac_try="$ac_link"
2344 case "(($ac_try" in
2345 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2346 *) ac_try_echo=$ac_try;;
2347 esac
2348 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2349 $as_echo "$ac_try_echo"; } >&5
2350 (eval "$ac_link") 2>conftest.err
2351 ac_status=$?
2352 if test -s conftest.err; then
2353 grep -v '^ *+' conftest.err >conftest.er1
2354 cat conftest.er1 >&5
2355 mv -f conftest.er1 conftest.err
2356 fi
2357 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2358 test $ac_status = 0; } && {
2359 test -z "$ac_c_werror_flag" ||
2360 test ! -s conftest.err
2361 } && test -s conftest$ac_exeext && {
2362 test "$cross_compiling" = yes ||
2363 $as_test_x conftest$ac_exeext
2364 }; then :
2365 ac_retval=0
2366 else
2367 $as_echo "$as_me: failed program was:" >&5
2368 sed 's/^/| /' conftest.$ac_ext >&5
2369
2370 ac_retval=1
2371 fi
2372 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2373 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2374 # interfere with the next link command; also delete a directory that is
2375 # left behind by Apple's compiler. We do this before executing the actions.
2376 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2377 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2378 as_fn_set_status $ac_retval
2379
2380 } # ac_fn_c_try_link
2381
2382 # ac_fn_c_check_decl LINENO SYMBOL VAR
2383 # ------------------------------------
2384 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2385 ac_fn_c_check_decl ()
2386 {
2387 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2389 $as_echo_n "checking whether $2 is declared... " >&6; }
2390 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2391 $as_echo_n "(cached) " >&6
2392 else
2393 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2394 /* end confdefs.h. */
2395 $4
2396 int
2397 main ()
2398 {
2399 #ifndef $2
2400 (void) $2;
2401 #endif
2402
2403 ;
2404 return 0;
2405 }
2406 _ACEOF
2407 if ac_fn_c_try_compile "$LINENO"; then :
2408 eval "$3=yes"
2409 else
2410 eval "$3=no"
2411 fi
2412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2413 fi
2414 eval ac_res=\$$3
2415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2416 $as_echo "$ac_res" >&6; }
2417 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2418
2419 } # ac_fn_c_check_decl
2420
2421 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2422 # ----------------------------------------------
2423 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2424 ac_fn_c_check_header_preproc ()
2425 {
2426 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2428 $as_echo_n "checking for $2... " >&6; }
2429 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2430 $as_echo_n "(cached) " >&6
2431 else
2432 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2433 /* end confdefs.h. */
2434 #include <$2>
2435 _ACEOF
2436 if ac_fn_c_try_cpp "$LINENO"; then :
2437 eval "$3=yes"
2438 else
2439 eval "$3=no"
2440 fi
2441 rm -f conftest.err conftest.$ac_ext
2442 fi
2443 eval ac_res=\$$3
2444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2445 $as_echo "$ac_res" >&6; }
2446 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2447
2448 } # ac_fn_c_check_header_preproc
2449
2450 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2451 # ----------------------------------------------------
2452 # Tries to find if the field MEMBER exists in type AGGR, after including
2453 # INCLUDES, setting cache variable VAR accordingly.
2454 ac_fn_c_check_member ()
2455 {
2456 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2458 $as_echo_n "checking for $2.$3... " >&6; }
2459 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2460 $as_echo_n "(cached) " >&6
2461 else
2462 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2463 /* end confdefs.h. */
2464 $5
2465 int
2466 main ()
2467 {
2468 static $2 ac_aggr;
2469 if (ac_aggr.$3)
2470 return 0;
2471 ;
2472 return 0;
2473 }
2474 _ACEOF
2475 if ac_fn_c_try_compile "$LINENO"; then :
2476 eval "$4=yes"
2477 else
2478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2479 /* end confdefs.h. */
2480 $5
2481 int
2482 main ()
2483 {
2484 static $2 ac_aggr;
2485 if (sizeof ac_aggr.$3)
2486 return 0;
2487 ;
2488 return 0;
2489 }
2490 _ACEOF
2491 if ac_fn_c_try_compile "$LINENO"; then :
2492 eval "$4=yes"
2493 else
2494 eval "$4=no"
2495 fi
2496 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2497 fi
2498 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2499 fi
2500 eval ac_res=\$$4
2501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2502 $as_echo "$ac_res" >&6; }
2503 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2504
2505 } # ac_fn_c_check_member
2506
2507 # ac_fn_c_check_func LINENO FUNC VAR
2508 # ----------------------------------
2509 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2510 ac_fn_c_check_func ()
2511 {
2512 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2514 $as_echo_n "checking for $2... " >&6; }
2515 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2516 $as_echo_n "(cached) " >&6
2517 else
2518 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2519 /* end confdefs.h. */
2520 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2521 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2522 #define $2 innocuous_$2
2523
2524 /* System header to define __stub macros and hopefully few prototypes,
2525 which can conflict with char $2 (); below.
2526 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2527 <limits.h> exists even on freestanding compilers. */
2528
2529 #ifdef __STDC__
2530 # include <limits.h>
2531 #else
2532 # include <assert.h>
2533 #endif
2534
2535 #undef $2
2536
2537 /* Override any GCC internal prototype to avoid an error.
2538 Use char because int might match the return type of a GCC
2539 builtin and then its argument prototype would still apply. */
2540 #ifdef __cplusplus
2541 extern "C"
2542 #endif
2543 char $2 ();
2544 /* The GNU C library defines this for functions which it implements
2545 to always fail with ENOSYS. Some functions are actually named
2546 something starting with __ and the normal name is an alias. */
2547 #if defined __stub_$2 || defined __stub___$2
2548 choke me
2549 #endif
2550
2551 int
2552 main ()
2553 {
2554 return $2 ();
2555 ;
2556 return 0;
2557 }
2558 _ACEOF
2559 if ac_fn_c_try_link "$LINENO"; then :
2560 eval "$3=yes"
2561 else
2562 eval "$3=no"
2563 fi
2564 rm -f core conftest.err conftest.$ac_objext \
2565 conftest$ac_exeext conftest.$ac_ext
2566 fi
2567 eval ac_res=\$$3
2568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2569 $as_echo "$ac_res" >&6; }
2570 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2571
2572 } # ac_fn_c_check_func
2573
2574 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2575 # --------------------------------------------
2576 # Tries to find the compile-time value of EXPR in a program that includes
2577 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2578 # computed
2579 ac_fn_c_compute_int ()
2580 {
2581 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2582 if test "$cross_compiling" = yes; then
2583 # Depending upon the size, compute the lo and hi bounds.
2584 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2585 /* end confdefs.h. */
2586 $4
2587 int
2588 main ()
2589 {
2590 static int test_array [1 - 2 * !(($2) >= 0)];
2591 test_array [0] = 0
2592
2593 ;
2594 return 0;
2595 }
2596 _ACEOF
2597 if ac_fn_c_try_compile "$LINENO"; then :
2598 ac_lo=0 ac_mid=0
2599 while :; do
2600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2601 /* end confdefs.h. */
2602 $4
2603 int
2604 main ()
2605 {
2606 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2607 test_array [0] = 0
2608
2609 ;
2610 return 0;
2611 }
2612 _ACEOF
2613 if ac_fn_c_try_compile "$LINENO"; then :
2614 ac_hi=$ac_mid; break
2615 else
2616 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2617 if test $ac_lo -le $ac_mid; then
2618 ac_lo= ac_hi=
2619 break
2620 fi
2621 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2622 fi
2623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2624 done
2625 else
2626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2627 /* end confdefs.h. */
2628 $4
2629 int
2630 main ()
2631 {
2632 static int test_array [1 - 2 * !(($2) < 0)];
2633 test_array [0] = 0
2634
2635 ;
2636 return 0;
2637 }
2638 _ACEOF
2639 if ac_fn_c_try_compile "$LINENO"; then :
2640 ac_hi=-1 ac_mid=-1
2641 while :; do
2642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2643 /* end confdefs.h. */
2644 $4
2645 int
2646 main ()
2647 {
2648 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2649 test_array [0] = 0
2650
2651 ;
2652 return 0;
2653 }
2654 _ACEOF
2655 if ac_fn_c_try_compile "$LINENO"; then :
2656 ac_lo=$ac_mid; break
2657 else
2658 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2659 if test $ac_mid -le $ac_hi; then
2660 ac_lo= ac_hi=
2661 break
2662 fi
2663 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2664 fi
2665 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2666 done
2667 else
2668 ac_lo= ac_hi=
2669 fi
2670 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2671 fi
2672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2673 # Binary search between lo and hi bounds.
2674 while test "x$ac_lo" != "x$ac_hi"; do
2675 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2677 /* end confdefs.h. */
2678 $4
2679 int
2680 main ()
2681 {
2682 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2683 test_array [0] = 0
2684
2685 ;
2686 return 0;
2687 }
2688 _ACEOF
2689 if ac_fn_c_try_compile "$LINENO"; then :
2690 ac_hi=$ac_mid
2691 else
2692 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2693 fi
2694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2695 done
2696 case $ac_lo in #((
2697 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2698 '') ac_retval=1 ;;
2699 esac
2700 else
2701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2702 /* end confdefs.h. */
2703 $4
2704 static long int longval () { return $2; }
2705 static unsigned long int ulongval () { return $2; }
2706 #include <stdio.h>
2707 #include <stdlib.h>
2708 int
2709 main ()
2710 {
2711
2712 FILE *f = fopen ("conftest.val", "w");
2713 if (! f)
2714 return 1;
2715 if (($2) < 0)
2716 {
2717 long int i = longval ();
2718 if (i != ($2))
2719 return 1;
2720 fprintf (f, "%ld", i);
2721 }
2722 else
2723 {
2724 unsigned long int i = ulongval ();
2725 if (i != ($2))
2726 return 1;
2727 fprintf (f, "%lu", i);
2728 }
2729 /* Do not output a trailing newline, as this causes \r\n confusion
2730 on some platforms. */
2731 return ferror (f) || fclose (f) != 0;
2732
2733 ;
2734 return 0;
2735 }
2736 _ACEOF
2737 if ac_fn_c_try_run "$LINENO"; then :
2738 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2739 else
2740 ac_retval=1
2741 fi
2742 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2743 conftest.$ac_objext conftest.beam conftest.$ac_ext
2744 rm -f conftest.val
2745
2746 fi
2747 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2748 as_fn_set_status $ac_retval
2749
2750 } # ac_fn_c_compute_int
2751
2752 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2753 # -------------------------------------------
2754 # Tests whether TYPE exists after having included INCLUDES, setting cache
2755 # variable VAR accordingly.
2756 ac_fn_c_check_type ()
2757 {
2758 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2760 $as_echo_n "checking for $2... " >&6; }
2761 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2762 $as_echo_n "(cached) " >&6
2763 else
2764 eval "$3=no"
2765 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2766 /* end confdefs.h. */
2767 $4
2768 int
2769 main ()
2770 {
2771 if (sizeof ($2))
2772 return 0;
2773 ;
2774 return 0;
2775 }
2776 _ACEOF
2777 if ac_fn_c_try_compile "$LINENO"; then :
2778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2779 /* end confdefs.h. */
2780 $4
2781 int
2782 main ()
2783 {
2784 if (sizeof (($2)))
2785 return 0;
2786 ;
2787 return 0;
2788 }
2789 _ACEOF
2790 if ac_fn_c_try_compile "$LINENO"; then :
2791
2792 else
2793 eval "$3=yes"
2794 fi
2795 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2796 fi
2797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2798 fi
2799 eval ac_res=\$$3
2800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2801 $as_echo "$ac_res" >&6; }
2802 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2803
2804 } # ac_fn_c_check_type
2805 cat >config.log <<_ACEOF
2806 This file contains any messages produced by compilers while
2807 running configure, to aid debugging if configure makes a mistake.
2808
2809 It was created by emacs $as_me 24.0.50, which was
2810 generated by GNU Autoconf 2.65. Invocation command line was
2811
2812 $ $0 $@
2813
2814 _ACEOF
2815 exec 5>>config.log
2816 {
2817 cat <<_ASUNAME
2818 ## --------- ##
2819 ## Platform. ##
2820 ## --------- ##
2821
2822 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2823 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2824 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2825 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2826 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2827
2828 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2829 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2830
2831 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2832 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2833 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2834 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2835 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2836 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2837 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2838
2839 _ASUNAME
2840
2841 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2842 for as_dir in $PATH
2843 do
2844 IFS=$as_save_IFS
2845 test -z "$as_dir" && as_dir=.
2846 $as_echo "PATH: $as_dir"
2847 done
2848 IFS=$as_save_IFS
2849
2850 } >&5
2851
2852 cat >&5 <<_ACEOF
2853
2854
2855 ## ----------- ##
2856 ## Core tests. ##
2857 ## ----------- ##
2858
2859 _ACEOF
2860
2861
2862 # Keep a trace of the command line.
2863 # Strip out --no-create and --no-recursion so they do not pile up.
2864 # Strip out --silent because we don't want to record it for future runs.
2865 # Also quote any args containing shell meta-characters.
2866 # Make two passes to allow for proper duplicate-argument suppression.
2867 ac_configure_args=
2868 ac_configure_args0=
2869 ac_configure_args1=
2870 ac_must_keep_next=false
2871 for ac_pass in 1 2
2872 do
2873 for ac_arg
2874 do
2875 case $ac_arg in
2876 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2877 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2878 | -silent | --silent | --silen | --sile | --sil)
2879 continue ;;
2880 *\'*)
2881 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2882 esac
2883 case $ac_pass in
2884 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2885 2)
2886 as_fn_append ac_configure_args1 " '$ac_arg'"
2887 if test $ac_must_keep_next = true; then
2888 ac_must_keep_next=false # Got value, back to normal.
2889 else
2890 case $ac_arg in
2891 *=* | --config-cache | -C | -disable-* | --disable-* \
2892 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2893 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2894 | -with-* | --with-* | -without-* | --without-* | --x)
2895 case "$ac_configure_args0 " in
2896 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2897 esac
2898 ;;
2899 -* ) ac_must_keep_next=true ;;
2900 esac
2901 fi
2902 as_fn_append ac_configure_args " '$ac_arg'"
2903 ;;
2904 esac
2905 done
2906 done
2907 { ac_configure_args0=; unset ac_configure_args0;}
2908 { ac_configure_args1=; unset ac_configure_args1;}
2909
2910 # When interrupted or exit'd, cleanup temporary files, and complete
2911 # config.log. We remove comments because anyway the quotes in there
2912 # would cause problems or look ugly.
2913 # WARNING: Use '\'' to represent an apostrophe within the trap.
2914 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2915 trap 'exit_status=$?
2916 # Save into config.log some information that might help in debugging.
2917 {
2918 echo
2919
2920 cat <<\_ASBOX
2921 ## ---------------- ##
2922 ## Cache variables. ##
2923 ## ---------------- ##
2924 _ASBOX
2925 echo
2926 # The following way of writing the cache mishandles newlines in values,
2927 (
2928 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2929 eval ac_val=\$$ac_var
2930 case $ac_val in #(
2931 *${as_nl}*)
2932 case $ac_var in #(
2933 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2934 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2935 esac
2936 case $ac_var in #(
2937 _ | IFS | as_nl) ;; #(
2938 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2939 *) { eval $ac_var=; unset $ac_var;} ;;
2940 esac ;;
2941 esac
2942 done
2943 (set) 2>&1 |
2944 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2945 *${as_nl}ac_space=\ *)
2946 sed -n \
2947 "s/'\''/'\''\\\\'\'''\''/g;
2948 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2949 ;; #(
2950 *)
2951 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2952 ;;
2953 esac |
2954 sort
2955 )
2956 echo
2957
2958 cat <<\_ASBOX
2959 ## ----------------- ##
2960 ## Output variables. ##
2961 ## ----------------- ##
2962 _ASBOX
2963 echo
2964 for ac_var in $ac_subst_vars
2965 do
2966 eval ac_val=\$$ac_var
2967 case $ac_val in
2968 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2969 esac
2970 $as_echo "$ac_var='\''$ac_val'\''"
2971 done | sort
2972 echo
2973
2974 if test -n "$ac_subst_files"; then
2975 cat <<\_ASBOX
2976 ## ------------------- ##
2977 ## File substitutions. ##
2978 ## ------------------- ##
2979 _ASBOX
2980 echo
2981 for ac_var in $ac_subst_files
2982 do
2983 eval ac_val=\$$ac_var
2984 case $ac_val in
2985 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2986 esac
2987 $as_echo "$ac_var='\''$ac_val'\''"
2988 done | sort
2989 echo
2990 fi
2991
2992 if test -s confdefs.h; then
2993 cat <<\_ASBOX
2994 ## ----------- ##
2995 ## confdefs.h. ##
2996 ## ----------- ##
2997 _ASBOX
2998 echo
2999 cat confdefs.h
3000 echo
3001 fi
3002 test "$ac_signal" != 0 &&
3003 $as_echo "$as_me: caught signal $ac_signal"
3004 $as_echo "$as_me: exit $exit_status"
3005 } >&5
3006 rm -f core *.core core.conftest.* &&
3007 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3008 exit $exit_status
3009 ' 0
3010 for ac_signal in 1 2 13 15; do
3011 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3012 done
3013 ac_signal=0
3014
3015 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3016 rm -f -r conftest* confdefs.h
3017
3018 $as_echo "/* confdefs.h */" > confdefs.h
3019
3020 # Predefined preprocessor variables.
3021
3022 cat >>confdefs.h <<_ACEOF
3023 #define PACKAGE_NAME "$PACKAGE_NAME"
3024 _ACEOF
3025
3026 cat >>confdefs.h <<_ACEOF
3027 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3028 _ACEOF
3029
3030 cat >>confdefs.h <<_ACEOF
3031 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3032 _ACEOF
3033
3034 cat >>confdefs.h <<_ACEOF
3035 #define PACKAGE_STRING "$PACKAGE_STRING"
3036 _ACEOF
3037
3038 cat >>confdefs.h <<_ACEOF
3039 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3040 _ACEOF
3041
3042 cat >>confdefs.h <<_ACEOF
3043 #define PACKAGE_URL "$PACKAGE_URL"
3044 _ACEOF
3045
3046
3047 # Let the site file select an alternate cache file if it wants to.
3048 # Prefer an explicitly selected file to automatically selected ones.
3049 ac_site_file1=NONE
3050 ac_site_file2=NONE
3051 if test -n "$CONFIG_SITE"; then
3052 ac_site_file1=$CONFIG_SITE
3053 elif test "x$prefix" != xNONE; then
3054 ac_site_file1=$prefix/share/config.site
3055 ac_site_file2=$prefix/etc/config.site
3056 else
3057 ac_site_file1=$ac_default_prefix/share/config.site
3058 ac_site_file2=$ac_default_prefix/etc/config.site
3059 fi
3060 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3061 do
3062 test "x$ac_site_file" = xNONE && continue
3063 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3064 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3065 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3066 sed 's/^/| /' "$ac_site_file" >&5
3067 . "$ac_site_file"
3068 fi
3069 done
3070
3071 if test -r "$cache_file"; then
3072 # Some versions of bash will fail to source /dev/null (special files
3073 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3074 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3075 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3076 $as_echo "$as_me: loading cache $cache_file" >&6;}
3077 case $cache_file in
3078 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3079 *) . "./$cache_file";;
3080 esac
3081 fi
3082 else
3083 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3084 $as_echo "$as_me: creating cache $cache_file" >&6;}
3085 >$cache_file
3086 fi
3087
3088 as_fn_append ac_header_list " stdlib.h"
3089 as_fn_append ac_header_list " unistd.h"
3090 as_fn_append ac_header_list " sys/param.h"
3091 as_fn_append ac_func_list " readlinkat"
3092 as_fn_append ac_func_list " dup2"
3093 gl_getopt_required=GNU
3094 as_fn_append ac_header_list " getopt.h"
3095 as_fn_append ac_header_list " wchar.h"
3096 as_fn_append ac_header_list " stdint.h"
3097 as_fn_append ac_header_list " inttypes.h"
3098 as_fn_append ac_func_list " lstat"
3099 as_fn_append ac_func_list " alarm"
3100 as_fn_append ac_func_list " readlink"
3101 as_fn_append ac_header_list " sys/socket.h"
3102 as_fn_append ac_func_list " tzset"
3103 as_fn_append ac_func_list " symlink"
3104 as_fn_append ac_header_list " sys/stat.h"
3105 as_fn_append ac_header_list " sys/time.h"
3106 as_fn_append ac_func_list " localtime_r"
3107 # Check that the precious variables saved in the cache have kept the same
3108 # value.
3109 ac_cache_corrupted=false
3110 for ac_var in $ac_precious_vars; do
3111 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3112 eval ac_new_set=\$ac_env_${ac_var}_set
3113 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3114 eval ac_new_val=\$ac_env_${ac_var}_value
3115 case $ac_old_set,$ac_new_set in
3116 set,)
3117 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3118 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3119 ac_cache_corrupted=: ;;
3120 ,set)
3121 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3122 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3123 ac_cache_corrupted=: ;;
3124 ,);;
3125 *)
3126 if test "x$ac_old_val" != "x$ac_new_val"; then
3127 # differences in whitespace do not lead to failure.
3128 ac_old_val_w=`echo x $ac_old_val`
3129 ac_new_val_w=`echo x $ac_new_val`
3130 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3131 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3132 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3133 ac_cache_corrupted=:
3134 else
3135 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3136 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3137 eval $ac_var=\$ac_old_val
3138 fi
3139 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3140 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3141 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3142 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3143 fi;;
3144 esac
3145 # Pass precious variables to config.status.
3146 if test "$ac_new_set" = set; then
3147 case $ac_new_val in
3148 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3149 *) ac_arg=$ac_var=$ac_new_val ;;
3150 esac
3151 case " $ac_configure_args " in
3152 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3153 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3154 esac
3155 fi
3156 done
3157 if $ac_cache_corrupted; then
3158 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3159 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3160 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3161 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3162 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3163 fi
3164 ## -------------------- ##
3165 ## Main body of script. ##
3166 ## -------------------- ##
3167
3168 ac_ext=c
3169 ac_cpp='$CPP $CPPFLAGS'
3170 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3171 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3172 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3173
3174
3175 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3176
3177
3178 am__api_version='1.11'
3179
3180 ac_aux_dir=
3181 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3182 for ac_t in install-sh install.sh shtool; do
3183 if test -f "$ac_dir/$ac_t"; then
3184 ac_aux_dir=$ac_dir
3185 ac_install_sh="$ac_aux_dir/$ac_t -c"
3186 break 2
3187 fi
3188 done
3189 done
3190 if test -z "$ac_aux_dir"; then
3191 as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3192 fi
3193
3194 # These three variables are undocumented and unsupported,
3195 # and are intended to be withdrawn in a future Autoconf release.
3196 # They can cause serious problems if a builder's source tree is in a directory
3197 # whose full name contains unusual characters.
3198 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3199 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3200 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3201
3202
3203 # Find a good install program. We prefer a C program (faster),
3204 # so one script is as good as another. But avoid the broken or
3205 # incompatible versions:
3206 # SysV /etc/install, /usr/sbin/install
3207 # SunOS /usr/etc/install
3208 # IRIX /sbin/install
3209 # AIX /bin/install
3210 # AmigaOS /C/install, which installs bootblocks on floppy discs
3211 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3212 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3213 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3214 # OS/2's system install, which has a completely different semantic
3215 # ./install, which can be erroneously created by make from ./install.sh.
3216 # Reject install programs that cannot install multiple files.
3217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3218 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3219 if test -z "$INSTALL"; then
3220 if test "${ac_cv_path_install+set}" = set; then :
3221 $as_echo_n "(cached) " >&6
3222 else
3223 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3224 for as_dir in $PATH
3225 do
3226 IFS=$as_save_IFS
3227 test -z "$as_dir" && as_dir=.
3228 # Account for people who put trailing slashes in PATH elements.
3229 case $as_dir/ in #((
3230 ./ | .// | /[cC]/* | \
3231 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3232 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3233 /usr/ucb/* ) ;;
3234 *)
3235 # OSF1 and SCO ODT 3.0 have their own names for install.
3236 # Don't use installbsd from OSF since it installs stuff as root
3237 # by default.
3238 for ac_prog in ginstall scoinst install; do
3239 for ac_exec_ext in '' $ac_executable_extensions; do
3240 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3241 if test $ac_prog = install &&
3242 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3243 # AIX install. It has an incompatible calling convention.
3244 :
3245 elif test $ac_prog = install &&
3246 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3247 # program-specific install script used by HP pwplus--don't use.
3248 :
3249 else
3250 rm -rf conftest.one conftest.two conftest.dir
3251 echo one > conftest.one
3252 echo two > conftest.two
3253 mkdir conftest.dir
3254 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3255 test -s conftest.one && test -s conftest.two &&
3256 test -s conftest.dir/conftest.one &&
3257 test -s conftest.dir/conftest.two
3258 then
3259 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3260 break 3
3261 fi
3262 fi
3263 fi
3264 done
3265 done
3266 ;;
3267 esac
3268
3269 done
3270 IFS=$as_save_IFS
3271
3272 rm -rf conftest.one conftest.two conftest.dir
3273
3274 fi
3275 if test "${ac_cv_path_install+set}" = set; then
3276 INSTALL=$ac_cv_path_install
3277 else
3278 # As a last resort, use the slow shell script. Don't cache a
3279 # value for INSTALL within a source directory, because that will
3280 # break other packages using the cache if that directory is
3281 # removed, or if the value is a relative name.
3282 INSTALL=$ac_install_sh
3283 fi
3284 fi
3285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3286 $as_echo "$INSTALL" >&6; }
3287
3288 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3289 # It thinks the first close brace ends the variable substitution.
3290 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3291
3292 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3293
3294 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3295
3296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3297 $as_echo_n "checking whether build environment is sane... " >&6; }
3298 # Just in case
3299 sleep 1
3300 echo timestamp > conftest.file
3301 # Reject unsafe characters in $srcdir or the absolute working directory
3302 # name. Accept space and tab only in the latter.
3303 am_lf='
3304 '
3305 case `pwd` in
3306 *[\\\"\#\$\&\'\`$am_lf]*)
3307 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3308 esac
3309 case $srcdir in
3310 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3311 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3312 esac
3313
3314 # Do `set' in a subshell so we don't clobber the current shell's
3315 # arguments. Must try -L first in case configure is actually a
3316 # symlink; some systems play weird games with the mod time of symlinks
3317 # (eg FreeBSD returns the mod time of the symlink's containing
3318 # directory).
3319 if (
3320 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3321 if test "$*" = "X"; then
3322 # -L didn't work.
3323 set X `ls -t "$srcdir/configure" conftest.file`
3324 fi
3325 rm -f conftest.file
3326 if test "$*" != "X $srcdir/configure conftest.file" \
3327 && test "$*" != "X conftest.file $srcdir/configure"; then
3328
3329 # If neither matched, then we have a broken ls. This can happen
3330 # if, for instance, CONFIG_SHELL is bash and it inherits a
3331 # broken ls alias from the environment. This has actually
3332 # happened. Such a system could not be considered "sane".
3333 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3334 alias in your environment" "$LINENO" 5
3335 fi
3336
3337 test "$2" = conftest.file
3338 )
3339 then
3340 # Ok.
3341 :
3342 else
3343 as_fn_error "newly created file is older than distributed files!
3344 Check your system clock" "$LINENO" 5
3345 fi
3346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3347 $as_echo "yes" >&6; }
3348 test "$program_prefix" != NONE &&
3349 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3350 # Use a double $ so make ignores it.
3351 test "$program_suffix" != NONE &&
3352 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3353 # Double any \ or $.
3354 # By default was `s,x,x', remove it if useless.
3355 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3356 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3357
3358 # expand $ac_aux_dir to an absolute path
3359 am_aux_dir=`cd $ac_aux_dir && pwd`
3360
3361 if test x"${MISSING+set}" != xset; then
3362 case $am_aux_dir in
3363 *\ * | *\ *)
3364 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3365 *)
3366 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3367 esac
3368 fi
3369 # Use eval to expand $SHELL
3370 if eval "$MISSING --run true"; then
3371 am_missing_run="$MISSING --run "
3372 else
3373 am_missing_run=
3374 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3375 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3376 fi
3377
3378 if test x"${install_sh}" != xset; then
3379 case $am_aux_dir in
3380 *\ * | *\ *)
3381 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3382 *)
3383 install_sh="\${SHELL} $am_aux_dir/install-sh"
3384 esac
3385 fi
3386
3387 # Installed binaries are usually stripped using `strip' when the user
3388 # run `make install-strip'. However `strip' might not be the right
3389 # tool to use in cross-compilation environments, therefore Automake
3390 # will honor the `STRIP' environment variable to overrule this program.
3391 if test "$cross_compiling" != no; then
3392 if test -n "$ac_tool_prefix"; then
3393 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3394 set dummy ${ac_tool_prefix}strip; ac_word=$2
3395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3396 $as_echo_n "checking for $ac_word... " >&6; }
3397 if test "${ac_cv_prog_STRIP+set}" = set; then :
3398 $as_echo_n "(cached) " >&6
3399 else
3400 if test -n "$STRIP"; then
3401 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3402 else
3403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3404 for as_dir in $PATH
3405 do
3406 IFS=$as_save_IFS
3407 test -z "$as_dir" && as_dir=.
3408 for ac_exec_ext in '' $ac_executable_extensions; do
3409 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3410 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3412 break 2
3413 fi
3414 done
3415 done
3416 IFS=$as_save_IFS
3417
3418 fi
3419 fi
3420 STRIP=$ac_cv_prog_STRIP
3421 if test -n "$STRIP"; then
3422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3423 $as_echo "$STRIP" >&6; }
3424 else
3425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3426 $as_echo "no" >&6; }
3427 fi
3428
3429
3430 fi
3431 if test -z "$ac_cv_prog_STRIP"; then
3432 ac_ct_STRIP=$STRIP
3433 # Extract the first word of "strip", so it can be a program name with args.
3434 set dummy strip; ac_word=$2
3435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3436 $as_echo_n "checking for $ac_word... " >&6; }
3437 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3438 $as_echo_n "(cached) " >&6
3439 else
3440 if test -n "$ac_ct_STRIP"; then
3441 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3442 else
3443 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3444 for as_dir in $PATH
3445 do
3446 IFS=$as_save_IFS
3447 test -z "$as_dir" && as_dir=.
3448 for ac_exec_ext in '' $ac_executable_extensions; do
3449 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3450 ac_cv_prog_ac_ct_STRIP="strip"
3451 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3452 break 2
3453 fi
3454 done
3455 done
3456 IFS=$as_save_IFS
3457
3458 fi
3459 fi
3460 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3461 if test -n "$ac_ct_STRIP"; then
3462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3463 $as_echo "$ac_ct_STRIP" >&6; }
3464 else
3465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3466 $as_echo "no" >&6; }
3467 fi
3468
3469 if test "x$ac_ct_STRIP" = x; then
3470 STRIP=":"
3471 else
3472 case $cross_compiling:$ac_tool_warned in
3473 yes:)
3474 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3475 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3476 ac_tool_warned=yes ;;
3477 esac
3478 STRIP=$ac_ct_STRIP
3479 fi
3480 else
3481 STRIP="$ac_cv_prog_STRIP"
3482 fi
3483
3484 fi
3485 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3486
3487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3488 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3489 if test -z "$MKDIR_P"; then
3490 if test "${ac_cv_path_mkdir+set}" = set; then :
3491 $as_echo_n "(cached) " >&6
3492 else
3493 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3494 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3495 do
3496 IFS=$as_save_IFS
3497 test -z "$as_dir" && as_dir=.
3498 for ac_prog in mkdir gmkdir; do
3499 for ac_exec_ext in '' $ac_executable_extensions; do
3500 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3501 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3502 'mkdir (GNU coreutils) '* | \
3503 'mkdir (coreutils) '* | \
3504 'mkdir (fileutils) '4.1*)
3505 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3506 break 3;;
3507 esac
3508 done
3509 done
3510 done
3511 IFS=$as_save_IFS
3512
3513 fi
3514
3515 test -d ./--version && rmdir ./--version
3516 if test "${ac_cv_path_mkdir+set}" = set; then
3517 MKDIR_P="$ac_cv_path_mkdir -p"
3518 else
3519 # As a last resort, use the slow shell script. Don't cache a
3520 # value for MKDIR_P within a source directory, because that will
3521 # break other packages using the cache if that directory is
3522 # removed, or if the value is a relative name.
3523 MKDIR_P="$ac_install_sh -d"
3524 fi
3525 fi
3526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3527 $as_echo "$MKDIR_P" >&6; }
3528
3529
3530 mkdir_p="$MKDIR_P"
3531 case $mkdir_p in
3532 [\\/$]* | ?:[\\/]*) ;;
3533 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3534 esac
3535
3536 for ac_prog in gawk mawk nawk awk
3537 do
3538 # Extract the first word of "$ac_prog", so it can be a program name with args.
3539 set dummy $ac_prog; ac_word=$2
3540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3541 $as_echo_n "checking for $ac_word... " >&6; }
3542 if test "${ac_cv_prog_AWK+set}" = set; then :
3543 $as_echo_n "(cached) " >&6
3544 else
3545 if test -n "$AWK"; then
3546 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3547 else
3548 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3549 for as_dir in $PATH
3550 do
3551 IFS=$as_save_IFS
3552 test -z "$as_dir" && as_dir=.
3553 for ac_exec_ext in '' $ac_executable_extensions; do
3554 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3555 ac_cv_prog_AWK="$ac_prog"
3556 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3557 break 2
3558 fi
3559 done
3560 done
3561 IFS=$as_save_IFS
3562
3563 fi
3564 fi
3565 AWK=$ac_cv_prog_AWK
3566 if test -n "$AWK"; then
3567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3568 $as_echo "$AWK" >&6; }
3569 else
3570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3571 $as_echo "no" >&6; }
3572 fi
3573
3574
3575 test -n "$AWK" && break
3576 done
3577
3578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3579 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3580 set x ${MAKE-make}
3581 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3582 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3583 $as_echo_n "(cached) " >&6
3584 else
3585 cat >conftest.make <<\_ACEOF
3586 SHELL = /bin/sh
3587 all:
3588 @echo '@@@%%%=$(MAKE)=@@@%%%'
3589 _ACEOF
3590 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3591 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3592 *@@@%%%=?*=@@@%%%*)
3593 eval ac_cv_prog_make_${ac_make}_set=yes;;
3594 *)
3595 eval ac_cv_prog_make_${ac_make}_set=no;;
3596 esac
3597 rm -f conftest.make
3598 fi
3599 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3601 $as_echo "yes" >&6; }
3602 SET_MAKE=
3603 else
3604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3605 $as_echo "no" >&6; }
3606 SET_MAKE="MAKE=${MAKE-make}"
3607 fi
3608
3609 rm -rf .tst 2>/dev/null
3610 mkdir .tst 2>/dev/null
3611 if test -d .tst; then
3612 am__leading_dot=.
3613 else
3614 am__leading_dot=_
3615 fi
3616 rmdir .tst 2>/dev/null
3617
3618 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3619 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3620 # is not polluted with repeated "-I."
3621 am__isrc=' -I$(srcdir)'
3622 # test to see if srcdir already configured
3623 if test -f $srcdir/config.status; then
3624 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3625 fi
3626 fi
3627
3628 # test whether we have cygpath
3629 if test -z "$CYGPATH_W"; then
3630 if (cygpath --version) >/dev/null 2>/dev/null; then
3631 CYGPATH_W='cygpath -w'
3632 else
3633 CYGPATH_W=echo
3634 fi
3635 fi
3636
3637
3638 # Define the identity of the package.
3639 PACKAGE='emacs'
3640 VERSION='24.0.50'
3641
3642
3643 cat >>confdefs.h <<_ACEOF
3644 #define PACKAGE "$PACKAGE"
3645 _ACEOF
3646
3647
3648 cat >>confdefs.h <<_ACEOF
3649 #define VERSION "$VERSION"
3650 _ACEOF
3651
3652 # Some tools Automake needs.
3653
3654 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3655
3656
3657 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3658
3659
3660 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3661
3662
3663 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3664
3665
3666 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3667
3668 # We need awk for the "check" target. The system "awk" is bad on
3669 # some platforms.
3670 # Always define AMTAR for backward compatibility.
3671
3672 AMTAR=${AMTAR-"${am_missing_run}tar"}
3673
3674 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3675
3676
3677
3678
3679
3680
3681
3682
3683 lispdir='${datadir}/emacs/${version}/lisp'
3684 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3685 '${datadir}/emacs/site-lisp'
3686 lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
3687 etcdir='${datadir}/emacs/${version}/etc'
3688 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3689 docdir='${datadir}/emacs/${version}/etc'
3690 gamedir='${localstatedir}/games/emacs'
3691
3692
3693
3694
3695 # Check whether --with-pop was given.
3696 if test "${with_pop+set}" = set; then :
3697 withval=$with_pop;
3698 else
3699 with_pop=yes
3700 fi
3701
3702 if test "$with_pop" = yes; then
3703 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3704
3705 fi
3706
3707
3708 # Check whether --with-kerberos was given.
3709 if test "${with_kerberos+set}" = set; then :
3710 withval=$with_kerberos;
3711 else
3712 with_kerberos=no
3713 fi
3714
3715 if test "$with_kerberos" != no; then
3716 $as_echo "#define KERBEROS 1" >>confdefs.h
3717
3718 fi
3719
3720
3721 # Check whether --with-kerberos5 was given.
3722 if test "${with_kerberos5+set}" = set; then :
3723 withval=$with_kerberos5;
3724 else
3725 with_kerberos5=no
3726 fi
3727
3728 if test "${with_kerberos5}" != no; then
3729 if test "${with_kerberos}" = no; then
3730 with_kerberos=yes
3731 $as_echo "#define KERBEROS 1" >>confdefs.h
3732
3733 fi
3734
3735 $as_echo "#define KERBEROS5 1" >>confdefs.h
3736
3737 fi
3738
3739
3740 # Check whether --with-hesiod was given.
3741 if test "${with_hesiod+set}" = set; then :
3742 withval=$with_hesiod;
3743 else
3744 with_hesiod=no
3745 fi
3746
3747 if test "$with_hesiod" != no; then
3748
3749 $as_echo "#define HESIOD 1" >>confdefs.h
3750
3751 fi
3752
3753
3754 # Check whether --with-mmdf was given.
3755 if test "${with_mmdf+set}" = set; then :
3756 withval=$with_mmdf;
3757 else
3758 with_mmdf=no
3759 fi
3760
3761 if test "$with_mmdf" != no; then
3762
3763 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3764
3765 fi
3766
3767
3768 # Check whether --with-mail-unlink was given.
3769 if test "${with_mail_unlink+set}" = set; then :
3770 withval=$with_mail_unlink;
3771 else
3772 with_mail_unlink=no
3773 fi
3774
3775 if test "$with_mail_unlink" != no; then
3776
3777 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3778
3779 fi
3780
3781
3782 # Check whether --with-mailhost was given.
3783 if test "${with_mailhost+set}" = set; then :
3784 withval=$with_mailhost;
3785 cat >>confdefs.h <<_ACEOF
3786 #define MAILHOST "$withval"
3787 _ACEOF
3788
3789 fi
3790
3791
3792
3793 # Check whether --with-sound was given.
3794 if test "${with_sound+set}" = set; then :
3795 withval=$with_sound;
3796 else
3797 with_sound=yes
3798 fi
3799
3800
3801
3802 # Check whether --with-sync-input was given.
3803 if test "${with_sync_input+set}" = set; then :
3804 withval=$with_sync_input;
3805 else
3806 with_sync_input=yes
3807 fi
3808
3809 if test "$with_sync_input" = yes; then
3810
3811 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
3812
3813 fi
3814
3815
3816 # Check whether --with-x-toolkit was given.
3817 if test "${with_x_toolkit+set}" = set; then :
3818 withval=$with_x_toolkit; case "${withval}" in
3819 y | ye | yes ) val=gtk ;;
3820 n | no ) val=no ;;
3821 l | lu | luc | luci | lucid ) val=lucid ;;
3822 a | at | ath | athe | athen | athena ) val=athena ;;
3823 m | mo | mot | moti | motif ) val=motif ;;
3824 g | gt | gtk ) val=gtk ;;
3825 gtk3 ) val=gtk3 ;;
3826 * )
3827 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3828 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3829 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3830 ;;
3831 esac
3832 with_x_toolkit=$val
3833
3834 fi
3835
3836
3837
3838 # Check whether --with-wide-int was given.
3839 if test "${with_wide_int+set}" = set; then :
3840 withval=$with_wide_int;
3841 else
3842 with_wide_int=no
3843 fi
3844
3845 if test "$with_wide_int" = yes; then
3846
3847 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3848
3849 fi
3850
3851
3852 # Check whether --with-xpm was given.
3853 if test "${with_xpm+set}" = set; then :
3854 withval=$with_xpm;
3855 else
3856 with_xpm=yes
3857 fi
3858
3859
3860 # Check whether --with-jpeg was given.
3861 if test "${with_jpeg+set}" = set; then :
3862 withval=$with_jpeg;
3863 else
3864 with_jpeg=yes
3865 fi
3866
3867
3868 # Check whether --with-tiff was given.
3869 if test "${with_tiff+set}" = set; then :
3870 withval=$with_tiff;
3871 else
3872 with_tiff=yes
3873 fi
3874
3875
3876 # Check whether --with-gif was given.
3877 if test "${with_gif+set}" = set; then :
3878 withval=$with_gif;
3879 else
3880 with_gif=yes
3881 fi
3882
3883
3884 # Check whether --with-png was given.
3885 if test "${with_png+set}" = set; then :
3886 withval=$with_png;
3887 else
3888 with_png=yes
3889 fi
3890
3891
3892 # Check whether --with-rsvg was given.
3893 if test "${with_rsvg+set}" = set; then :
3894 withval=$with_rsvg;
3895 else
3896 with_rsvg=yes
3897 fi
3898
3899
3900 # Check whether --with-xml2 was given.
3901 if test "${with_xml2+set}" = set; then :
3902 withval=$with_xml2;
3903 else
3904 with_xml2=yes
3905 fi
3906
3907
3908 # Check whether --with-imagemagick was given.
3909 if test "${with_imagemagick+set}" = set; then :
3910 withval=$with_imagemagick;
3911 else
3912 with_imagemagick=yes
3913 fi
3914
3915
3916
3917 # Check whether --with-xft was given.
3918 if test "${with_xft+set}" = set; then :
3919 withval=$with_xft;
3920 else
3921 with_xft=yes
3922 fi
3923
3924
3925 # Check whether --with-libotf was given.
3926 if test "${with_libotf+set}" = set; then :
3927 withval=$with_libotf;
3928 else
3929 with_libotf=yes
3930 fi
3931
3932
3933 # Check whether --with-m17n-flt was given.
3934 if test "${with_m17n_flt+set}" = set; then :
3935 withval=$with_m17n_flt;
3936 else
3937 with_m17n_flt=yes
3938 fi
3939
3940
3941
3942 # Check whether --with-toolkit-scroll-bars was given.
3943 if test "${with_toolkit_scroll_bars+set}" = set; then :
3944 withval=$with_toolkit_scroll_bars;
3945 else
3946 with_toolkit_scroll_bars=yes
3947 fi
3948
3949
3950 # Check whether --with-xaw3d was given.
3951 if test "${with_xaw3d+set}" = set; then :
3952 withval=$with_xaw3d;
3953 else
3954 with_xaw3d=yes
3955 fi
3956
3957
3958 # Check whether --with-xim was given.
3959 if test "${with_xim+set}" = set; then :
3960 withval=$with_xim;
3961 else
3962 with_xim=yes
3963 fi
3964
3965
3966 # Check whether --with-ns was given.
3967 if test "${with_ns+set}" = set; then :
3968 withval=$with_ns;
3969 else
3970 with_ns=no
3971 fi
3972
3973
3974
3975 # Check whether --with-gpm was given.
3976 if test "${with_gpm+set}" = set; then :
3977 withval=$with_gpm;
3978 else
3979 with_gpm=yes
3980 fi
3981
3982
3983 # Check whether --with-dbus was given.
3984 if test "${with_dbus+set}" = set; then :
3985 withval=$with_dbus;
3986 else
3987 with_dbus=yes
3988 fi
3989
3990
3991 # Check whether --with-gconf was given.
3992 if test "${with_gconf+set}" = set; then :
3993 withval=$with_gconf;
3994 else
3995 with_gconf=yes
3996 fi
3997
3998
3999 # Check whether --with-gsettings was given.
4000 if test "${with_gsettings+set}" = set; then :
4001 withval=$with_gsettings;
4002 else
4003 with_gsettings=yes
4004 fi
4005
4006
4007 # Check whether --with-selinux was given.
4008 if test "${with_selinux+set}" = set; then :
4009 withval=$with_selinux;
4010 else
4011 with_selinux=yes
4012 fi
4013
4014
4015 # Check whether --with-gnutls was given.
4016 if test "${with_gnutls+set}" = set; then :
4017 withval=$with_gnutls;
4018 else
4019 with_gnutls=yes
4020 fi
4021
4022
4023 ## For the times when you want to build Emacs but don't have
4024 ## a suitable makeinfo, and can live without the manuals.
4025
4026 # Check whether --with-makeinfo was given.
4027 if test "${with_makeinfo+set}" = set; then :
4028 withval=$with_makeinfo;
4029 else
4030 with_makeinfo=yes
4031 fi
4032
4033
4034 ## This is an option because I do not know if all info/man support
4035 ## compressed files, nor how to test if they do so.
4036
4037 # Check whether --with-compress-info was given.
4038 if test "${with_compress_info+set}" = set; then :
4039 withval=$with_compress_info;
4040 else
4041 with_compress_info=yes
4042 fi
4043
4044 if test $with_compress_info = yes; then
4045 GZIP_INFO=yes
4046 else
4047 GZIP_INFO=
4048 fi
4049
4050
4051
4052 # Check whether --with-pkg-config-prog was given.
4053 if test "${with_pkg_config_prog+set}" = set; then :
4054 withval=$with_pkg_config_prog;
4055 fi
4056
4057 if test "X${with_pkg_config_prog}" != X; then
4058 if test "${with_pkg_config_prog}" != yes; then
4059 PKG_CONFIG="${with_pkg_config_prog}"
4060 fi
4061 fi
4062
4063 CRT_DIR=
4064
4065 # Check whether --with-crt-dir was given.
4066 if test "${with_crt_dir+set}" = set; then :
4067 withval=$with_crt_dir;
4068 fi
4069
4070 CRT_DIR="${with_crt_dir}"
4071
4072
4073 # Check whether --with-gameuser was given.
4074 if test "${with_gameuser+set}" = set; then :
4075 withval=$with_gameuser;
4076 fi
4077
4078 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4079 && gameuser="${with_gameuser}"
4080 test "X$gameuser" = X && gameuser=games
4081
4082
4083 # Check whether --with-gnustep-conf was given.
4084 if test "${with_gnustep_conf+set}" = set; then :
4085 withval=$with_gnustep_conf;
4086 fi
4087
4088 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4089 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4090 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4091 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4092
4093 # Check whether --enable-ns-self-contained was given.
4094 if test "${enable_ns_self_contained+set}" = set; then :
4095 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4096 else
4097 EN_NS_SELF_CONTAINED=yes
4098 fi
4099
4100
4101 # Check whether --enable-asserts was given.
4102 if test "${enable_asserts+set}" = set; then :
4103 enableval=$enable_asserts; USE_XASSERTS=$enableval
4104 else
4105 USE_XASSERTS=no
4106 fi
4107
4108
4109 # Check whether --enable-maintainer-mode was given.
4110 if test "${enable_maintainer_mode+set}" = set; then :
4111 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
4112 else
4113 USE_MAINTAINER_MODE=yes
4114 fi
4115
4116 if test $USE_MAINTAINER_MODE = yes; then
4117 MAINT=
4118 else
4119 MAINT=#
4120 fi
4121
4122
4123 # Check whether --enable-locallisppath was given.
4124 if test "${enable_locallisppath+set}" = set; then :
4125 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4126 locallisppath=
4127 elif test "${enableval}" != "yes"; then
4128 locallisppath=${enableval}
4129 fi
4130 fi
4131
4132
4133 # Check whether --enable-checking was given.
4134 if test "${enable_checking+set}" = set; then :
4135 enableval=$enable_checking; ac_checking_flags="${enableval}"
4136 fi
4137
4138 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4139 for check in $ac_checking_flags
4140 do
4141 case $check in
4142 # these set all the flags to specific states
4143 yes) ac_enable_checking=1 ;;
4144 no) ac_enable_checking= ;
4145 ac_gc_check_stringbytes= ;
4146 ac_gc_check_string_overrun= ;
4147 ac_gc_check_string_free_list= ;
4148 ac_xmalloc_overrun= ;
4149 ac_gc_check_cons_list= ;;
4150 all) ac_enable_checking=1 ;
4151 ac_gc_check_stringbytes=1 ;
4152 ac_gc_check_string_overrun=1 ;
4153 ac_gc_check_string_free_list=1 ;
4154 ac_xmalloc_overrun=1 ;
4155 ac_gc_check_cons_list=1 ;;
4156 # these enable particular checks
4157 stringbytes) ac_gc_check_stringbytes=1 ;;
4158 stringoverrun) ac_gc_check_string_overrun=1 ;;
4159 stringfreelist) ac_gc_check_string_free_list=1 ;;
4160 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4161 conslist) ac_gc_check_cons_list=1 ;;
4162 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4163 esac
4164 done
4165 IFS="$ac_save_IFS"
4166
4167 if test x$ac_enable_checking != x ; then
4168
4169 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4170
4171 fi
4172 if test x$ac_gc_check_stringbytes != x ; then
4173
4174 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4175
4176 fi
4177 if test x$ac_gc_check_string_overrun != x ; then
4178
4179 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4180
4181 fi
4182 if test x$ac_gc_check_string_free_list != x ; then
4183
4184 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4185
4186 fi
4187 if test x$ac_xmalloc_overrun != x ; then
4188
4189 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4190
4191 fi
4192 if test x$ac_gc_check_cons_list != x ; then
4193
4194 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4195
4196 fi
4197
4198 # Check whether --enable-use-lisp-union-type was given.
4199 if test "${enable_use_lisp_union_type+set}" = set; then :
4200 enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then
4201
4202 $as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h
4203
4204 fi
4205 fi
4206
4207
4208
4209 # Check whether --enable-profiling was given.
4210 if test "${enable_profiling+set}" = set; then :
4211 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4212 fi
4213
4214 if test x$ac_enable_profiling != x ; then
4215 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4216 else
4217 PROFILING_CFLAGS=
4218 fi
4219
4220
4221 # Check whether --enable-autodepend was given.
4222 if test "${enable_autodepend+set}" = set; then :
4223 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4224 else
4225 ac_enable_autodepend=yes
4226 fi
4227
4228
4229 #### Make srcdir absolute, if it isn't already. It's important to
4230 #### avoid running the path through pwd unnecessarily, since pwd can
4231 #### give you automounter prefixes, which can go away. We do all this
4232 #### so Emacs can find its files when run uninstalled.
4233 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4234 unset CDPATH
4235 case "${srcdir}" in
4236 /* ) ;;
4237 . )
4238 ## We may be able to use the $PWD environment variable to make this
4239 ## absolute. But sometimes PWD is inaccurate.
4240 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4241 ## but that tested only for a well-formed and valid PWD,
4242 ## it did not object when PWD was well-formed and valid but just wrong.
4243 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4244 then
4245 srcdir="$PWD"
4246 else
4247 srcdir="`(cd ${srcdir}; pwd)`"
4248 fi
4249 ;;
4250 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4251 esac
4252
4253 #### Given the configuration name, set machfile and opsysfile to the
4254 #### names of the m/*.h and s/*.h files we should use.
4255
4256 ### Canonicalize the configuration name.
4257
4258 # Make sure we can run config.sub.
4259 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4260 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4261
4262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4263 $as_echo_n "checking build system type... " >&6; }
4264 if test "${ac_cv_build+set}" = set; then :
4265 $as_echo_n "(cached) " >&6
4266 else
4267 ac_build_alias=$build_alias
4268 test "x$ac_build_alias" = x &&
4269 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4270 test "x$ac_build_alias" = x &&
4271 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4272 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4273 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4274
4275 fi
4276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4277 $as_echo "$ac_cv_build" >&6; }
4278 case $ac_cv_build in
4279 *-*-*) ;;
4280 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4281 esac
4282 build=$ac_cv_build
4283 ac_save_IFS=$IFS; IFS='-'
4284 set x $ac_cv_build
4285 shift
4286 build_cpu=$1
4287 build_vendor=$2
4288 shift; shift
4289 # Remember, the first character of IFS is used to create $*,
4290 # except with old shells:
4291 build_os=$*
4292 IFS=$ac_save_IFS
4293 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4294
4295
4296 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4297 $as_echo_n "checking host system type... " >&6; }
4298 if test "${ac_cv_host+set}" = set; then :
4299 $as_echo_n "(cached) " >&6
4300 else
4301 if test "x$host_alias" = x; then
4302 ac_cv_host=$ac_cv_build
4303 else
4304 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4305 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4306 fi
4307
4308 fi
4309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4310 $as_echo "$ac_cv_host" >&6; }
4311 case $ac_cv_host in
4312 *-*-*) ;;
4313 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4314 esac
4315 host=$ac_cv_host
4316 ac_save_IFS=$IFS; IFS='-'
4317 set x $ac_cv_host
4318 shift
4319 host_cpu=$1
4320 host_vendor=$2
4321 shift; shift
4322 # Remember, the first character of IFS is used to create $*,
4323 # except with old shells:
4324 host_os=$*
4325 IFS=$ac_save_IFS
4326 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4327
4328
4329 canonical=$host
4330 configuration=${host_alias-${build_alias-$host}}
4331
4332
4333
4334 ### If you add support for a new configuration, add code to this
4335 ### switch statement to recognize your configuration name and select
4336 ### the appropriate operating system and machine description files.
4337
4338 ### You would hope that you could choose an m/*.h file pretty much
4339 ### based on the machine portion of the configuration name, and an s/*.h
4340 ### file based on the operating system portion. However, it turns out
4341 ### that each m/*.h file is pretty manufacturer-specific - for
4342 ### example mips.h is MIPS
4343 ### So we basically have to have a special case for each
4344 ### configuration name.
4345 ###
4346 ### As far as handling version numbers on operating systems is
4347 ### concerned, make sure things will fail in a fixable way. If
4348 ### /etc/MACHINES doesn't say anything about version numbers, be
4349 ### prepared to handle anything reasonably. If version numbers
4350 ### matter, be sure /etc/MACHINES says something about it.
4351
4352 machine='' opsys='' unported=no
4353 case "${canonical}" in
4354
4355 ## GNU/Linux ports
4356 *-*-linux-gnu*)
4357 opsys=gnu-linux
4358 case ${canonical} in
4359 alpha*) machine=alpha ;;
4360 s390-*) machine=ibms390 ;;
4361 s390x-*) machine=ibms390x ;;
4362 powerpc*) machine=macppc ;;
4363 sparc*) machine=sparc ;;
4364 ia64*) machine=ia64 ;;
4365 m68k*) machine=m68k ;;
4366 x86_64*) machine=amdx86-64 ;;
4367 esac
4368 ;;
4369
4370 ## FreeBSD ports
4371 *-*-freebsd* )
4372 opsys=freebsd
4373 case "${canonical}" in
4374 alpha*) machine=alpha ;;
4375 amd64-*|x86_64-*) machine=amdx86-64 ;;
4376 ia64-*) machine=ia64 ;;
4377 i[3456]86-*) machine=intel386 ;;
4378 powerpc-*) machine=macppc ;;
4379 sparc-*) machine=sparc ;;
4380 sparc64-*) machine=sparc ;;
4381 esac
4382 ;;
4383
4384 ## FreeBSD kernel + glibc based userland
4385 *-*-kfreebsd*gnu* )
4386 opsys=gnu-kfreebsd
4387 case "${canonical}" in
4388 alpha*) machine=alpha ;;
4389 amd64-*|x86_64-*) machine=amdx86-64 ;;
4390 ia64-*) machine=ia64 ;;
4391 i[3456]86-*) machine=intel386 ;;
4392 powerpc-*) machine=macppc ;;
4393 sparc-*) machine=sparc ;;
4394 sparc64-*) machine=sparc ;;
4395 esac
4396 ;;
4397
4398 ## NetBSD ports
4399 *-*-netbsd* )
4400 opsys=netbsd
4401 case "${canonical}" in
4402 alpha*) machine=alpha ;;
4403 x86_64-*) machine=amdx86-64 ;;
4404 i[3456]86-*) machine=intel386 ;;
4405 m68k-*) machine=m68k ;;
4406 powerpc-*) machine=macppc ;;
4407 sparc*-) machine=sparc ;;
4408 vax-*) machine=vax ;;
4409 esac
4410 ;;
4411
4412 ## OpenBSD ports
4413 *-*-openbsd* )
4414 opsys=openbsd
4415 case "${canonical}" in
4416 alpha*) machine=alpha ;;
4417 x86_64-*) machine=amdx86-64 ;;
4418 i386-*) machine=intel386 ;;
4419 powerpc-*) machine=macppc ;;
4420 sparc*) machine=sparc ;;
4421 vax-*) machine=vax ;;
4422 esac
4423 ;;
4424
4425 ## Apple Darwin / Mac OS X
4426 *-apple-darwin* )
4427 case "${canonical}" in
4428 i[3456]86-* ) machine=intel386 ;;
4429 powerpc-* ) machine=macppc ;;
4430 x86_64-* ) machine=amdx86-64 ;;
4431 * ) unported=yes ;;
4432 esac
4433 opsys=darwin
4434 # Define CPP as follows to make autoconf work correctly.
4435 CPP="${CC-cc} -E -no-cpp-precomp"
4436 # Use fink packages if available.
4437 if test -d /sw/include && test -d /sw/lib; then
4438 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4439 CPP="${CPP} ${GCC_TEST_OPTIONS}"
4440 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4441 fi
4442 ;;
4443
4444 ## HP 9000 series 700 and 800, running HP/UX
4445 hppa*-hp-hpux10.2* )
4446 opsys=hpux10-20
4447 ;;
4448 hppa*-hp-hpux1[1-9]* )
4449 opsys=hpux11
4450 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4451 ;;
4452
4453 ia64*-hp-hpux1[1-9]* )
4454 machine=hp800 opsys=hpux11
4455 ## FIXME. Peter O'Gorman reports that dumping using unexelf.o doesn't
4456 ## work either: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6811
4457 CANNOT_DUMP=yes
4458 ;;
4459
4460 hppa*-*-linux-gnu* )
4461 machine=hp800 opsys=gnu-linux
4462 ;;
4463
4464 ## IBM machines
4465 rs6000-ibm-aix4.[23]* )
4466 machine=ibmrs6000 opsys=aix4-2
4467 ;;
4468 powerpc-ibm-aix4.[23]* )
4469 machine=ibmrs6000 opsys=aix4-2
4470 ;;
4471 rs6000-ibm-aix[56]* )
4472 machine=ibmrs6000 opsys=aix4-2
4473 ;;
4474 powerpc-ibm-aix[56]* )
4475 machine=ibmrs6000 opsys=aix4-2
4476 ;;
4477
4478 ## Silicon Graphics machines
4479 ## Iris 4D
4480 mips-sgi-irix6.5 )
4481 machine=iris4d opsys=irix6-5
4482 # Without defining _LANGUAGE_C, things get masked out in the headers
4483 # so that, for instance, grepping for `free' in stdlib.h fails and
4484 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4485 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
4486 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4487 ;;
4488
4489 ## Suns
4490 *-sun-solaris* \
4491 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4492 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4493 case "${canonical}" in
4494 i[3456]86-*-* ) machine=intel386 ;;
4495 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
4496 sparc* ) machine=sparc ;;
4497 * ) unported=yes ;;
4498 esac
4499 case "${canonical}" in
4500 *-sunos5.6* | *-solaris2.6* )
4501 opsys=sol2-6
4502 NON_GNU_CPP=/usr/ccs/lib/cpp
4503 RANLIB="ar -ts"
4504 ;;
4505 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4506 opsys=sol2-6
4507 emacs_check_sunpro_c=yes
4508 NON_GNU_CPP=/usr/ccs/lib/cpp
4509 ;;
4510 *-sunos5* | *-solaris* )
4511 opsys=sol2-10
4512 emacs_check_sunpro_c=yes
4513 NON_GNU_CPP=/usr/ccs/lib/cpp
4514 ;;
4515 esac
4516 ## Watch out for a compiler that we know will not work.
4517 case "${canonical}" in
4518 *-solaris* | *-sunos5* )
4519 if [ "x$CC" = x/usr/ucb/cc ]; then
4520 ## /usr/ucb/cc doesn't work;
4521 ## we should find some other compiler that does work.
4522 unset CC
4523 fi
4524 ;;
4525 *) ;;
4526 esac
4527 ;;
4528
4529 ## Intel 386 machines where we don't care about the manufacturer.
4530 i[3456]86-*-* )
4531 machine=intel386
4532 case "${canonical}" in
4533 *-cygwin ) opsys=cygwin ;;
4534 *-darwin* ) opsys=darwin
4535 CPP="${CC-cc} -E -no-cpp-precomp"
4536 ;;
4537 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4538 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4539 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4540 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4541 esac
4542 ;;
4543
4544 * )
4545 unported=yes
4546 ;;
4547 esac
4548
4549 ### If the code above didn't choose an operating system, just choose
4550 ### an operating system based on the configuration name. You really
4551 ### only want to use this when you have no idea what the right
4552 ### operating system is; if you know what operating systems a machine
4553 ### runs, it's cleaner to make it explicit in the case statement
4554 ### above.
4555 if test x"${opsys}" = x; then
4556 case "${canonical}" in
4557 *-gnu* ) opsys=gnu ;;
4558 * )
4559 unported=yes
4560 ;;
4561 esac
4562 fi
4563
4564
4565
4566 if test $unported = yes; then
4567 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4568 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4569 fi
4570
4571 if test -n "$machine"; then
4572 machfile="m/${machine}.h"
4573 else
4574 machfile=
4575 fi
4576 opsysfile="s/${opsys}.h"
4577
4578
4579 #### Choose a compiler.
4580 test -n "$CC" && cc_specified=yes
4581
4582 # Save the value of CFLAGS that the user specified.
4583 SPECIFIED_CFLAGS="$CFLAGS"
4584
4585 ac_ext=c
4586 ac_cpp='$CPP $CPPFLAGS'
4587 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4588 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4589 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4590 if test -n "$ac_tool_prefix"; then
4591 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4592 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4594 $as_echo_n "checking for $ac_word... " >&6; }
4595 if test "${ac_cv_prog_CC+set}" = set; then :
4596 $as_echo_n "(cached) " >&6
4597 else
4598 if test -n "$CC"; then
4599 ac_cv_prog_CC="$CC" # Let the user override the test.
4600 else
4601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4602 for as_dir in $PATH
4603 do
4604 IFS=$as_save_IFS
4605 test -z "$as_dir" && as_dir=.
4606 for ac_exec_ext in '' $ac_executable_extensions; do
4607 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4608 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4610 break 2
4611 fi
4612 done
4613 done
4614 IFS=$as_save_IFS
4615
4616 fi
4617 fi
4618 CC=$ac_cv_prog_CC
4619 if test -n "$CC"; then
4620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4621 $as_echo "$CC" >&6; }
4622 else
4623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4624 $as_echo "no" >&6; }
4625 fi
4626
4627
4628 fi
4629 if test -z "$ac_cv_prog_CC"; then
4630 ac_ct_CC=$CC
4631 # Extract the first word of "gcc", so it can be a program name with args.
4632 set dummy gcc; ac_word=$2
4633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4634 $as_echo_n "checking for $ac_word... " >&6; }
4635 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4636 $as_echo_n "(cached) " >&6
4637 else
4638 if test -n "$ac_ct_CC"; then
4639 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4640 else
4641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4642 for as_dir in $PATH
4643 do
4644 IFS=$as_save_IFS
4645 test -z "$as_dir" && as_dir=.
4646 for ac_exec_ext in '' $ac_executable_extensions; do
4647 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4648 ac_cv_prog_ac_ct_CC="gcc"
4649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4650 break 2
4651 fi
4652 done
4653 done
4654 IFS=$as_save_IFS
4655
4656 fi
4657 fi
4658 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4659 if test -n "$ac_ct_CC"; then
4660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4661 $as_echo "$ac_ct_CC" >&6; }
4662 else
4663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4664 $as_echo "no" >&6; }
4665 fi
4666
4667 if test "x$ac_ct_CC" = x; then
4668 CC=""
4669 else
4670 case $cross_compiling:$ac_tool_warned in
4671 yes:)
4672 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4673 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4674 ac_tool_warned=yes ;;
4675 esac
4676 CC=$ac_ct_CC
4677 fi
4678 else
4679 CC="$ac_cv_prog_CC"
4680 fi
4681
4682 if test -z "$CC"; then
4683 if test -n "$ac_tool_prefix"; then
4684 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4685 set dummy ${ac_tool_prefix}cc; ac_word=$2
4686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4687 $as_echo_n "checking for $ac_word... " >&6; }
4688 if test "${ac_cv_prog_CC+set}" = set; then :
4689 $as_echo_n "(cached) " >&6
4690 else
4691 if test -n "$CC"; then
4692 ac_cv_prog_CC="$CC" # Let the user override the test.
4693 else
4694 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4695 for as_dir in $PATH
4696 do
4697 IFS=$as_save_IFS
4698 test -z "$as_dir" && as_dir=.
4699 for ac_exec_ext in '' $ac_executable_extensions; do
4700 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4701 ac_cv_prog_CC="${ac_tool_prefix}cc"
4702 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4703 break 2
4704 fi
4705 done
4706 done
4707 IFS=$as_save_IFS
4708
4709 fi
4710 fi
4711 CC=$ac_cv_prog_CC
4712 if test -n "$CC"; then
4713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4714 $as_echo "$CC" >&6; }
4715 else
4716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4717 $as_echo "no" >&6; }
4718 fi
4719
4720
4721 fi
4722 fi
4723 if test -z "$CC"; then
4724 # Extract the first word of "cc", so it can be a program name with args.
4725 set dummy cc; ac_word=$2
4726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4727 $as_echo_n "checking for $ac_word... " >&6; }
4728 if test "${ac_cv_prog_CC+set}" = set; then :
4729 $as_echo_n "(cached) " >&6
4730 else
4731 if test -n "$CC"; then
4732 ac_cv_prog_CC="$CC" # Let the user override the test.
4733 else
4734 ac_prog_rejected=no
4735 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4736 for as_dir in $PATH
4737 do
4738 IFS=$as_save_IFS
4739 test -z "$as_dir" && as_dir=.
4740 for ac_exec_ext in '' $ac_executable_extensions; do
4741 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4742 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4743 ac_prog_rejected=yes
4744 continue
4745 fi
4746 ac_cv_prog_CC="cc"
4747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4748 break 2
4749 fi
4750 done
4751 done
4752 IFS=$as_save_IFS
4753
4754 if test $ac_prog_rejected = yes; then
4755 # We found a bogon in the path, so make sure we never use it.
4756 set dummy $ac_cv_prog_CC
4757 shift
4758 if test $# != 0; then
4759 # We chose a different compiler from the bogus one.
4760 # However, it has the same basename, so the bogon will be chosen
4761 # first if we set CC to just the basename; use the full file name.
4762 shift
4763 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4764 fi
4765 fi
4766 fi
4767 fi
4768 CC=$ac_cv_prog_CC
4769 if test -n "$CC"; then
4770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4771 $as_echo "$CC" >&6; }
4772 else
4773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4774 $as_echo "no" >&6; }
4775 fi
4776
4777
4778 fi
4779 if test -z "$CC"; then
4780 if test -n "$ac_tool_prefix"; then
4781 for ac_prog in cl.exe
4782 do
4783 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4784 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4786 $as_echo_n "checking for $ac_word... " >&6; }
4787 if test "${ac_cv_prog_CC+set}" = set; then :
4788 $as_echo_n "(cached) " >&6
4789 else
4790 if test -n "$CC"; then
4791 ac_cv_prog_CC="$CC" # Let the user override the test.
4792 else
4793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4794 for as_dir in $PATH
4795 do
4796 IFS=$as_save_IFS
4797 test -z "$as_dir" && as_dir=.
4798 for ac_exec_ext in '' $ac_executable_extensions; do
4799 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4800 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4802 break 2
4803 fi
4804 done
4805 done
4806 IFS=$as_save_IFS
4807
4808 fi
4809 fi
4810 CC=$ac_cv_prog_CC
4811 if test -n "$CC"; then
4812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4813 $as_echo "$CC" >&6; }
4814 else
4815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4816 $as_echo "no" >&6; }
4817 fi
4818
4819
4820 test -n "$CC" && break
4821 done
4822 fi
4823 if test -z "$CC"; then
4824 ac_ct_CC=$CC
4825 for ac_prog in cl.exe
4826 do
4827 # Extract the first word of "$ac_prog", so it can be a program name with args.
4828 set dummy $ac_prog; ac_word=$2
4829 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4830 $as_echo_n "checking for $ac_word... " >&6; }
4831 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4832 $as_echo_n "(cached) " >&6
4833 else
4834 if test -n "$ac_ct_CC"; then
4835 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4836 else
4837 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4838 for as_dir in $PATH
4839 do
4840 IFS=$as_save_IFS
4841 test -z "$as_dir" && as_dir=.
4842 for ac_exec_ext in '' $ac_executable_extensions; do
4843 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4844 ac_cv_prog_ac_ct_CC="$ac_prog"
4845 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4846 break 2
4847 fi
4848 done
4849 done
4850 IFS=$as_save_IFS
4851
4852 fi
4853 fi
4854 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4855 if test -n "$ac_ct_CC"; then
4856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4857 $as_echo "$ac_ct_CC" >&6; }
4858 else
4859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4860 $as_echo "no" >&6; }
4861 fi
4862
4863
4864 test -n "$ac_ct_CC" && break
4865 done
4866
4867 if test "x$ac_ct_CC" = x; then
4868 CC=""
4869 else
4870 case $cross_compiling:$ac_tool_warned in
4871 yes:)
4872 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4873 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4874 ac_tool_warned=yes ;;
4875 esac
4876 CC=$ac_ct_CC
4877 fi
4878 fi
4879
4880 fi
4881
4882
4883 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4884 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4885 as_fn_error "no acceptable C compiler found in \$PATH
4886 See \`config.log' for more details." "$LINENO" 5; }
4887
4888 # Provide some information about the compiler.
4889 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4890 set X $ac_compile
4891 ac_compiler=$2
4892 for ac_option in --version -v -V -qversion; do
4893 { { ac_try="$ac_compiler $ac_option >&5"
4894 case "(($ac_try" in
4895 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4896 *) ac_try_echo=$ac_try;;
4897 esac
4898 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4899 $as_echo "$ac_try_echo"; } >&5
4900 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4901 ac_status=$?
4902 if test -s conftest.err; then
4903 sed '10a\
4904 ... rest of stderr output deleted ...
4905 10q' conftest.err >conftest.er1
4906 cat conftest.er1 >&5
4907 fi
4908 rm -f conftest.er1 conftest.err
4909 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4910 test $ac_status = 0; }
4911 done
4912
4913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4914 /* end confdefs.h. */
4915
4916 int
4917 main ()
4918 {
4919
4920 ;
4921 return 0;
4922 }
4923 _ACEOF
4924 ac_clean_files_save=$ac_clean_files
4925 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4926 # Try to create an executable without -o first, disregard a.out.
4927 # It will help us diagnose broken compilers, and finding out an intuition
4928 # of exeext.
4929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4930 $as_echo_n "checking whether the C compiler works... " >&6; }
4931 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4932
4933 # The possible output files:
4934 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4935
4936 ac_rmfiles=
4937 for ac_file in $ac_files
4938 do
4939 case $ac_file in
4940 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4941 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4942 esac
4943 done
4944 rm -f $ac_rmfiles
4945
4946 if { { ac_try="$ac_link_default"
4947 case "(($ac_try" in
4948 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4949 *) ac_try_echo=$ac_try;;
4950 esac
4951 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4952 $as_echo "$ac_try_echo"; } >&5
4953 (eval "$ac_link_default") 2>&5
4954 ac_status=$?
4955 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4956 test $ac_status = 0; }; then :
4957 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4958 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4959 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4960 # so that the user can short-circuit this test for compilers unknown to
4961 # Autoconf.
4962 for ac_file in $ac_files ''
4963 do
4964 test -f "$ac_file" || continue
4965 case $ac_file in
4966 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4967 ;;
4968 [ab].out )
4969 # We found the default executable, but exeext='' is most
4970 # certainly right.
4971 break;;
4972 *.* )
4973 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
4974 then :; else
4975 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4976 fi
4977 # We set ac_cv_exeext here because the later test for it is not
4978 # safe: cross compilers may not add the suffix if given an `-o'
4979 # argument, so we may need to know it at that point already.
4980 # Even if this section looks crufty: it has the advantage of
4981 # actually working.
4982 break;;
4983 * )
4984 break;;
4985 esac
4986 done
4987 test "$ac_cv_exeext" = no && ac_cv_exeext=
4988
4989 else
4990 ac_file=''
4991 fi
4992 if test -z "$ac_file"; then :
4993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4994 $as_echo "no" >&6; }
4995 $as_echo "$as_me: failed program was:" >&5
4996 sed 's/^/| /' conftest.$ac_ext >&5
4997
4998 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4999 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5000 { as_fn_set_status 77
5001 as_fn_error "C compiler cannot create executables
5002 See \`config.log' for more details." "$LINENO" 5; }; }
5003 else
5004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5005 $as_echo "yes" >&6; }
5006 fi
5007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5008 $as_echo_n "checking for C compiler default output file name... " >&6; }
5009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5010 $as_echo "$ac_file" >&6; }
5011 ac_exeext=$ac_cv_exeext
5012
5013 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5014 ac_clean_files=$ac_clean_files_save
5015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5016 $as_echo_n "checking for suffix of executables... " >&6; }
5017 if { { ac_try="$ac_link"
5018 case "(($ac_try" in
5019 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5020 *) ac_try_echo=$ac_try;;
5021 esac
5022 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5023 $as_echo "$ac_try_echo"; } >&5
5024 (eval "$ac_link") 2>&5
5025 ac_status=$?
5026 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5027 test $ac_status = 0; }; then :
5028 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5029 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5030 # work properly (i.e., refer to `conftest.exe'), while it won't with
5031 # `rm'.
5032 for ac_file in conftest.exe conftest conftest.*; do
5033 test -f "$ac_file" || continue
5034 case $ac_file in
5035 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5036 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5037 break;;
5038 * ) break;;
5039 esac
5040 done
5041 else
5042 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5043 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5044 as_fn_error "cannot compute suffix of executables: cannot compile and link
5045 See \`config.log' for more details." "$LINENO" 5; }
5046 fi
5047 rm -f conftest conftest$ac_cv_exeext
5048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5049 $as_echo "$ac_cv_exeext" >&6; }
5050
5051 rm -f conftest.$ac_ext
5052 EXEEXT=$ac_cv_exeext
5053 ac_exeext=$EXEEXT
5054 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5055 /* end confdefs.h. */
5056 #include <stdio.h>
5057 int
5058 main ()
5059 {
5060 FILE *f = fopen ("conftest.out", "w");
5061 return ferror (f) || fclose (f) != 0;
5062
5063 ;
5064 return 0;
5065 }
5066 _ACEOF
5067 ac_clean_files="$ac_clean_files conftest.out"
5068 # Check that the compiler produces executables we can run. If not, either
5069 # the compiler is broken, or we cross compile.
5070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5071 $as_echo_n "checking whether we are cross compiling... " >&6; }
5072 if test "$cross_compiling" != yes; then
5073 { { ac_try="$ac_link"
5074 case "(($ac_try" in
5075 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5076 *) ac_try_echo=$ac_try;;
5077 esac
5078 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5079 $as_echo "$ac_try_echo"; } >&5
5080 (eval "$ac_link") 2>&5
5081 ac_status=$?
5082 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5083 test $ac_status = 0; }
5084 if { ac_try='./conftest$ac_cv_exeext'
5085 { { case "(($ac_try" in
5086 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5087 *) ac_try_echo=$ac_try;;
5088 esac
5089 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5090 $as_echo "$ac_try_echo"; } >&5
5091 (eval "$ac_try") 2>&5
5092 ac_status=$?
5093 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5094 test $ac_status = 0; }; }; then
5095 cross_compiling=no
5096 else
5097 if test "$cross_compiling" = maybe; then
5098 cross_compiling=yes
5099 else
5100 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5101 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5102 as_fn_error "cannot run C compiled programs.
5103 If you meant to cross compile, use \`--host'.
5104 See \`config.log' for more details." "$LINENO" 5; }
5105 fi
5106 fi
5107 fi
5108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5109 $as_echo "$cross_compiling" >&6; }
5110
5111 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5112 ac_clean_files=$ac_clean_files_save
5113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5114 $as_echo_n "checking for suffix of object files... " >&6; }
5115 if test "${ac_cv_objext+set}" = set; then :
5116 $as_echo_n "(cached) " >&6
5117 else
5118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5119 /* end confdefs.h. */
5120
5121 int
5122 main ()
5123 {
5124
5125 ;
5126 return 0;
5127 }
5128 _ACEOF
5129 rm -f conftest.o conftest.obj
5130 if { { ac_try="$ac_compile"
5131 case "(($ac_try" in
5132 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5133 *) ac_try_echo=$ac_try;;
5134 esac
5135 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5136 $as_echo "$ac_try_echo"; } >&5
5137 (eval "$ac_compile") 2>&5
5138 ac_status=$?
5139 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5140 test $ac_status = 0; }; then :
5141 for ac_file in conftest.o conftest.obj conftest.*; do
5142 test -f "$ac_file" || continue;
5143 case $ac_file in
5144 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5145 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5146 break;;
5147 esac
5148 done
5149 else
5150 $as_echo "$as_me: failed program was:" >&5
5151 sed 's/^/| /' conftest.$ac_ext >&5
5152
5153 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5154 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5155 as_fn_error "cannot compute suffix of object files: cannot compile
5156 See \`config.log' for more details." "$LINENO" 5; }
5157 fi
5158 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5159 fi
5160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5161 $as_echo "$ac_cv_objext" >&6; }
5162 OBJEXT=$ac_cv_objext
5163 ac_objext=$OBJEXT
5164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5165 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5166 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5167 $as_echo_n "(cached) " >&6
5168 else
5169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5170 /* end confdefs.h. */
5171
5172 int
5173 main ()
5174 {
5175 #ifndef __GNUC__
5176 choke me
5177 #endif
5178
5179 ;
5180 return 0;
5181 }
5182 _ACEOF
5183 if ac_fn_c_try_compile "$LINENO"; then :
5184 ac_compiler_gnu=yes
5185 else
5186 ac_compiler_gnu=no
5187 fi
5188 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5189 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5190
5191 fi
5192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5193 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5194 if test $ac_compiler_gnu = yes; then
5195 GCC=yes
5196 else
5197 GCC=
5198 fi
5199 ac_test_CFLAGS=${CFLAGS+set}
5200 ac_save_CFLAGS=$CFLAGS
5201 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5202 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5203 if test "${ac_cv_prog_cc_g+set}" = set; then :
5204 $as_echo_n "(cached) " >&6
5205 else
5206 ac_save_c_werror_flag=$ac_c_werror_flag
5207 ac_c_werror_flag=yes
5208 ac_cv_prog_cc_g=no
5209 CFLAGS="-g"
5210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5211 /* end confdefs.h. */
5212
5213 int
5214 main ()
5215 {
5216
5217 ;
5218 return 0;
5219 }
5220 _ACEOF
5221 if ac_fn_c_try_compile "$LINENO"; then :
5222 ac_cv_prog_cc_g=yes
5223 else
5224 CFLAGS=""
5225 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5226 /* end confdefs.h. */
5227
5228 int
5229 main ()
5230 {
5231
5232 ;
5233 return 0;
5234 }
5235 _ACEOF
5236 if ac_fn_c_try_compile "$LINENO"; then :
5237
5238 else
5239 ac_c_werror_flag=$ac_save_c_werror_flag
5240 CFLAGS="-g"
5241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5242 /* end confdefs.h. */
5243
5244 int
5245 main ()
5246 {
5247
5248 ;
5249 return 0;
5250 }
5251 _ACEOF
5252 if ac_fn_c_try_compile "$LINENO"; then :
5253 ac_cv_prog_cc_g=yes
5254 fi
5255 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5256 fi
5257 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5258 fi
5259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5260 ac_c_werror_flag=$ac_save_c_werror_flag
5261 fi
5262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5263 $as_echo "$ac_cv_prog_cc_g" >&6; }
5264 if test "$ac_test_CFLAGS" = set; then
5265 CFLAGS=$ac_save_CFLAGS
5266 elif test $ac_cv_prog_cc_g = yes; then
5267 if test "$GCC" = yes; then
5268 CFLAGS="-g -O2"
5269 else
5270 CFLAGS="-g"
5271 fi
5272 else
5273 if test "$GCC" = yes; then
5274 CFLAGS="-O2"
5275 else
5276 CFLAGS=
5277 fi
5278 fi
5279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5280 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5281 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5282 $as_echo_n "(cached) " >&6
5283 else
5284 ac_cv_prog_cc_c89=no
5285 ac_save_CC=$CC
5286 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5287 /* end confdefs.h. */
5288 #include <stdarg.h>
5289 #include <stdio.h>
5290 #include <sys/types.h>
5291 #include <sys/stat.h>
5292 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5293 struct buf { int x; };
5294 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5295 static char *e (p, i)
5296 char **p;
5297 int i;
5298 {
5299 return p[i];
5300 }
5301 static char *f (char * (*g) (char **, int), char **p, ...)
5302 {
5303 char *s;
5304 va_list v;
5305 va_start (v,p);
5306 s = g (p, va_arg (v,int));
5307 va_end (v);
5308 return s;
5309 }
5310
5311 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5312 function prototypes and stuff, but not '\xHH' hex character constants.
5313 These don't provoke an error unfortunately, instead are silently treated
5314 as 'x'. The following induces an error, until -std is added to get
5315 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5316 array size at least. It's necessary to write '\x00'==0 to get something
5317 that's true only with -std. */
5318 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5319
5320 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5321 inside strings and character constants. */
5322 #define FOO(x) 'x'
5323 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5324
5325 int test (int i, double x);
5326 struct s1 {int (*f) (int a);};
5327 struct s2 {int (*f) (double a);};
5328 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5329 int argc;
5330 char **argv;
5331 int
5332 main ()
5333 {
5334 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5335 ;
5336 return 0;
5337 }
5338 _ACEOF
5339 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5340 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5341 do
5342 CC="$ac_save_CC $ac_arg"
5343 if ac_fn_c_try_compile "$LINENO"; then :
5344 ac_cv_prog_cc_c89=$ac_arg
5345 fi
5346 rm -f core conftest.err conftest.$ac_objext
5347 test "x$ac_cv_prog_cc_c89" != "xno" && break
5348 done
5349 rm -f conftest.$ac_ext
5350 CC=$ac_save_CC
5351
5352 fi
5353 # AC_CACHE_VAL
5354 case "x$ac_cv_prog_cc_c89" in
5355 x)
5356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5357 $as_echo "none needed" >&6; } ;;
5358 xno)
5359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5360 $as_echo "unsupported" >&6; } ;;
5361 *)
5362 CC="$CC $ac_cv_prog_cc_c89"
5363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5364 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5365 esac
5366 if test "x$ac_cv_prog_cc_c89" != xno; then :
5367
5368 fi
5369
5370 ac_ext=c
5371 ac_cpp='$CPP $CPPFLAGS'
5372 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5373 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5374 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5375 DEPDIR="${am__leading_dot}deps"
5376
5377 ac_config_commands="$ac_config_commands depfiles"
5378
5379
5380 am_make=${MAKE-make}
5381 cat > confinc << 'END'
5382 am__doit:
5383 @echo this is the am__doit target
5384 .PHONY: am__doit
5385 END
5386 # If we don't find an include directive, just comment out the code.
5387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5388 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5389 am__include="#"
5390 am__quote=
5391 _am_result=none
5392 # First try GNU make style include.
5393 echo "include confinc" > confmf
5394 # Ignore all kinds of additional output from `make'.
5395 case `$am_make -s -f confmf 2> /dev/null` in #(
5396 *the\ am__doit\ target*)
5397 am__include=include
5398 am__quote=
5399 _am_result=GNU
5400 ;;
5401 esac
5402 # Now try BSD make style include.
5403 if test "$am__include" = "#"; then
5404 echo '.include "confinc"' > confmf
5405 case `$am_make -s -f confmf 2> /dev/null` in #(
5406 *the\ am__doit\ target*)
5407 am__include=.include
5408 am__quote="\""
5409 _am_result=BSD
5410 ;;
5411 esac
5412 fi
5413
5414
5415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5416 $as_echo "$_am_result" >&6; }
5417 rm -f confinc confmf
5418
5419 # Check whether --enable-dependency-tracking was given.
5420 if test "${enable_dependency_tracking+set}" = set; then :
5421 enableval=$enable_dependency_tracking;
5422 fi
5423
5424 if test "x$enable_dependency_tracking" != xno; then
5425 am_depcomp="$ac_aux_dir/depcomp"
5426 AMDEPBACKSLASH='\'
5427 fi
5428 if test "x$enable_dependency_tracking" != xno; then
5429 AMDEP_TRUE=
5430 AMDEP_FALSE='#'
5431 else
5432 AMDEP_TRUE='#'
5433 AMDEP_FALSE=
5434 fi
5435
5436
5437
5438 depcc="$CC" am_compiler_list=
5439
5440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5441 $as_echo_n "checking dependency style of $depcc... " >&6; }
5442 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5443 $as_echo_n "(cached) " >&6
5444 else
5445 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5446 # We make a subdir and do the tests there. Otherwise we can end up
5447 # making bogus files that we don't know about and never remove. For
5448 # instance it was reported that on HP-UX the gcc test will end up
5449 # making a dummy file named `D' -- because `-MD' means `put the output
5450 # in D'.
5451 mkdir conftest.dir
5452 # Copy depcomp to subdir because otherwise we won't find it if we're
5453 # using a relative directory.
5454 cp "$am_depcomp" conftest.dir
5455 cd conftest.dir
5456 # We will build objects and dependencies in a subdirectory because
5457 # it helps to detect inapplicable dependency modes. For instance
5458 # both Tru64's cc and ICC support -MD to output dependencies as a
5459 # side effect of compilation, but ICC will put the dependencies in
5460 # the current directory while Tru64 will put them in the object
5461 # directory.
5462 mkdir sub
5463
5464 am_cv_CC_dependencies_compiler_type=none
5465 if test "$am_compiler_list" = ""; then
5466 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5467 fi
5468 am__universal=false
5469 case " $depcc " in #(
5470 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5471 esac
5472
5473 for depmode in $am_compiler_list; do
5474 # Setup a source with many dependencies, because some compilers
5475 # like to wrap large dependency lists on column 80 (with \), and
5476 # we should not choose a depcomp mode which is confused by this.
5477 #
5478 # We need to recreate these files for each test, as the compiler may
5479 # overwrite some of them when testing with obscure command lines.
5480 # This happens at least with the AIX C compiler.
5481 : > sub/conftest.c
5482 for i in 1 2 3 4 5 6; do
5483 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5484 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5485 # Solaris 8's {/usr,}/bin/sh.
5486 touch sub/conftst$i.h
5487 done
5488 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5489
5490 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5491 # mode. It turns out that the SunPro C++ compiler does not properly
5492 # handle `-M -o', and we need to detect this. Also, some Intel
5493 # versions had trouble with output in subdirs
5494 am__obj=sub/conftest.${OBJEXT-o}
5495 am__minus_obj="-o $am__obj"
5496 case $depmode in
5497 gcc)
5498 # This depmode causes a compiler race in universal mode.
5499 test "$am__universal" = false || continue
5500 ;;
5501 nosideeffect)
5502 # after this tag, mechanisms are not by side-effect, so they'll
5503 # only be used when explicitly requested
5504 if test "x$enable_dependency_tracking" = xyes; then
5505 continue
5506 else
5507 break
5508 fi
5509 ;;
5510 msvisualcpp | msvcmsys)
5511 # This compiler won't grok `-c -o', but also, the minuso test has
5512 # not run yet. These depmodes are late enough in the game, and
5513 # so weak that their functioning should not be impacted.
5514 am__obj=conftest.${OBJEXT-o}
5515 am__minus_obj=
5516 ;;
5517 none) break ;;
5518 esac
5519 if depmode=$depmode \
5520 source=sub/conftest.c object=$am__obj \
5521 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5522 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5523 >/dev/null 2>conftest.err &&
5524 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5525 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5526 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5527 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5528 # icc doesn't choke on unknown options, it will just issue warnings
5529 # or remarks (even with -Werror). So we grep stderr for any message
5530 # that says an option was ignored or not supported.
5531 # When given -MP, icc 7.0 and 7.1 complain thusly:
5532 # icc: Command line warning: ignoring option '-M'; no argument required
5533 # The diagnosis changed in icc 8.0:
5534 # icc: Command line remark: option '-MP' not supported
5535 if (grep 'ignoring option' conftest.err ||
5536 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5537 am_cv_CC_dependencies_compiler_type=$depmode
5538 break
5539 fi
5540 fi
5541 done
5542
5543 cd ..
5544 rm -rf conftest.dir
5545 else
5546 am_cv_CC_dependencies_compiler_type=none
5547 fi
5548
5549 fi
5550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5551 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5552 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5553
5554 if
5555 test "x$enable_dependency_tracking" != xno \
5556 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5557 am__fastdepCC_TRUE=
5558 am__fastdepCC_FALSE='#'
5559 else
5560 am__fastdepCC_TRUE='#'
5561 am__fastdepCC_FALSE=
5562 fi
5563
5564
5565 if test "x$CC" != xcc; then
5566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5567 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5568 else
5569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5570 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5571 fi
5572 set dummy $CC; ac_cc=`$as_echo "$2" |
5573 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5574 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5575 $as_echo_n "(cached) " >&6
5576 else
5577 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5578 /* end confdefs.h. */
5579
5580 int
5581 main ()
5582 {
5583
5584 ;
5585 return 0;
5586 }
5587 _ACEOF
5588 # Make sure it works both with $CC and with simple cc.
5589 # We do the test twice because some compilers refuse to overwrite an
5590 # existing .o file with -o, though they will create one.
5591 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5592 rm -f conftest2.*
5593 if { { case "(($ac_try" in
5594 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5595 *) ac_try_echo=$ac_try;;
5596 esac
5597 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5598 $as_echo "$ac_try_echo"; } >&5
5599 (eval "$ac_try") 2>&5
5600 ac_status=$?
5601 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5602 test $ac_status = 0; } &&
5603 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5604 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5605 *) ac_try_echo=$ac_try;;
5606 esac
5607 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5608 $as_echo "$ac_try_echo"; } >&5
5609 (eval "$ac_try") 2>&5
5610 ac_status=$?
5611 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5612 test $ac_status = 0; };
5613 then
5614 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5615 if test "x$CC" != xcc; then
5616 # Test first that cc exists at all.
5617 if { ac_try='cc -c conftest.$ac_ext >&5'
5618 { { case "(($ac_try" in
5619 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5620 *) ac_try_echo=$ac_try;;
5621 esac
5622 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5623 $as_echo "$ac_try_echo"; } >&5
5624 (eval "$ac_try") 2>&5
5625 ac_status=$?
5626 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5627 test $ac_status = 0; }; }; then
5628 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5629 rm -f conftest2.*
5630 if { { case "(($ac_try" in
5631 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5632 *) ac_try_echo=$ac_try;;
5633 esac
5634 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5635 $as_echo "$ac_try_echo"; } >&5
5636 (eval "$ac_try") 2>&5
5637 ac_status=$?
5638 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5639 test $ac_status = 0; } &&
5640 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5641 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5642 *) ac_try_echo=$ac_try;;
5643 esac
5644 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5645 $as_echo "$ac_try_echo"; } >&5
5646 (eval "$ac_try") 2>&5
5647 ac_status=$?
5648 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5649 test $ac_status = 0; };
5650 then
5651 # cc works too.
5652 :
5653 else
5654 # cc exists but doesn't like -o.
5655 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5656 fi
5657 fi
5658 fi
5659 else
5660 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5661 fi
5662 rm -f core conftest*
5663
5664 fi
5665 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5667 $as_echo "yes" >&6; }
5668 else
5669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5670 $as_echo "no" >&6; }
5671
5672 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5673
5674 fi
5675
5676 # FIXME: we rely on the cache variable name because
5677 # there is no other way.
5678 set dummy $CC
5679 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5680 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5681 if test "$am_t" != yes; then
5682 # Losing compiler, so override with the script.
5683 # FIXME: It is wrong to rewrite CC.
5684 # But if we don't then we get into trouble of one sort or another.
5685 # A longer-term fix would be to have automake use am__CC in this case,
5686 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5687 CC="$am_aux_dir/compile $CC"
5688 fi
5689
5690
5691
5692 # Initialize gnulib right after verifying that the C compiler works.
5693 if test -n "$ac_tool_prefix"; then
5694 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
5695 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
5696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5697 $as_echo_n "checking for $ac_word... " >&6; }
5698 if test "${ac_cv_prog_RANLIB+set}" = set; then :
5699 $as_echo_n "(cached) " >&6
5700 else
5701 if test -n "$RANLIB"; then
5702 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
5703 else
5704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5705 for as_dir in $PATH
5706 do
5707 IFS=$as_save_IFS
5708 test -z "$as_dir" && as_dir=.
5709 for ac_exec_ext in '' $ac_executable_extensions; do
5710 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5711 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
5712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5713 break 2
5714 fi
5715 done
5716 done
5717 IFS=$as_save_IFS
5718
5719 fi
5720 fi
5721 RANLIB=$ac_cv_prog_RANLIB
5722 if test -n "$RANLIB"; then
5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
5724 $as_echo "$RANLIB" >&6; }
5725 else
5726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5727 $as_echo "no" >&6; }
5728 fi
5729
5730
5731 fi
5732 if test -z "$ac_cv_prog_RANLIB"; then
5733 ac_ct_RANLIB=$RANLIB
5734 # Extract the first word of "ranlib", so it can be a program name with args.
5735 set dummy ranlib; ac_word=$2
5736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5737 $as_echo_n "checking for $ac_word... " >&6; }
5738 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
5739 $as_echo_n "(cached) " >&6
5740 else
5741 if test -n "$ac_ct_RANLIB"; then
5742 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
5743 else
5744 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5745 for as_dir in $PATH
5746 do
5747 IFS=$as_save_IFS
5748 test -z "$as_dir" && as_dir=.
5749 for ac_exec_ext in '' $ac_executable_extensions; do
5750 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5751 ac_cv_prog_ac_ct_RANLIB="ranlib"
5752 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5753 break 2
5754 fi
5755 done
5756 done
5757 IFS=$as_save_IFS
5758
5759 fi
5760 fi
5761 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
5762 if test -n "$ac_ct_RANLIB"; then
5763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
5764 $as_echo "$ac_ct_RANLIB" >&6; }
5765 else
5766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5767 $as_echo "no" >&6; }
5768 fi
5769
5770 if test "x$ac_ct_RANLIB" = x; then
5771 RANLIB=":"
5772 else
5773 case $cross_compiling:$ac_tool_warned in
5774 yes:)
5775 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
5776 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
5777 ac_tool_warned=yes ;;
5778 esac
5779 RANLIB=$ac_ct_RANLIB
5780 fi
5781 else
5782 RANLIB="$ac_cv_prog_RANLIB"
5783 fi
5784
5785
5786 ac_ext=c
5787 ac_cpp='$CPP $CPPFLAGS'
5788 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5789 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5790 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5792 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5793 # On Suns, sometimes $CPP names a directory.
5794 if test -n "$CPP" && test -d "$CPP"; then
5795 CPP=
5796 fi
5797 if test -z "$CPP"; then
5798 if test "${ac_cv_prog_CPP+set}" = set; then :
5799 $as_echo_n "(cached) " >&6
5800 else
5801 # Double quotes because CPP needs to be expanded
5802 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5803 do
5804 ac_preproc_ok=false
5805 for ac_c_preproc_warn_flag in '' yes
5806 do
5807 # Use a header file that comes with gcc, so configuring glibc
5808 # with a fresh cross-compiler works.
5809 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5810 # <limits.h> exists even on freestanding compilers.
5811 # On the NeXT, cc -E runs the code through the compiler's parser,
5812 # not just through cpp. "Syntax error" is here to catch this case.
5813 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5814 /* end confdefs.h. */
5815 #ifdef __STDC__
5816 # include <limits.h>
5817 #else
5818 # include <assert.h>
5819 #endif
5820 Syntax error
5821 _ACEOF
5822 if ac_fn_c_try_cpp "$LINENO"; then :
5823
5824 else
5825 # Broken: fails on valid input.
5826 continue
5827 fi
5828 rm -f conftest.err conftest.$ac_ext
5829
5830 # OK, works on sane cases. Now check whether nonexistent headers
5831 # can be detected and how.
5832 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5833 /* end confdefs.h. */
5834 #include <ac_nonexistent.h>
5835 _ACEOF
5836 if ac_fn_c_try_cpp "$LINENO"; then :
5837 # Broken: success on invalid input.
5838 continue
5839 else
5840 # Passes both tests.
5841 ac_preproc_ok=:
5842 break
5843 fi
5844 rm -f conftest.err conftest.$ac_ext
5845
5846 done
5847 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5848 rm -f conftest.err conftest.$ac_ext
5849 if $ac_preproc_ok; then :
5850 break
5851 fi
5852
5853 done
5854 ac_cv_prog_CPP=$CPP
5855
5856 fi
5857 CPP=$ac_cv_prog_CPP
5858 else
5859 ac_cv_prog_CPP=$CPP
5860 fi
5861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5862 $as_echo "$CPP" >&6; }
5863 ac_preproc_ok=false
5864 for ac_c_preproc_warn_flag in '' yes
5865 do
5866 # Use a header file that comes with gcc, so configuring glibc
5867 # with a fresh cross-compiler works.
5868 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5869 # <limits.h> exists even on freestanding compilers.
5870 # On the NeXT, cc -E runs the code through the compiler's parser,
5871 # not just through cpp. "Syntax error" is here to catch this case.
5872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5873 /* end confdefs.h. */
5874 #ifdef __STDC__
5875 # include <limits.h>
5876 #else
5877 # include <assert.h>
5878 #endif
5879 Syntax error
5880 _ACEOF
5881 if ac_fn_c_try_cpp "$LINENO"; then :
5882
5883 else
5884 # Broken: fails on valid input.
5885 continue
5886 fi
5887 rm -f conftest.err conftest.$ac_ext
5888
5889 # OK, works on sane cases. Now check whether nonexistent headers
5890 # can be detected and how.
5891 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5892 /* end confdefs.h. */
5893 #include <ac_nonexistent.h>
5894 _ACEOF
5895 if ac_fn_c_try_cpp "$LINENO"; then :
5896 # Broken: success on invalid input.
5897 continue
5898 else
5899 # Passes both tests.
5900 ac_preproc_ok=:
5901 break
5902 fi
5903 rm -f conftest.err conftest.$ac_ext
5904
5905 done
5906 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5907 rm -f conftest.err conftest.$ac_ext
5908 if $ac_preproc_ok; then :
5909
5910 else
5911 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5912 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5913 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5914 See \`config.log' for more details." "$LINENO" 5; }
5915 fi
5916
5917 ac_ext=c
5918 ac_cpp='$CPP $CPPFLAGS'
5919 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5920 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5921 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5922
5923
5924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5925 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5926 if test "${ac_cv_path_GREP+set}" = set; then :
5927 $as_echo_n "(cached) " >&6
5928 else
5929 if test -z "$GREP"; then
5930 ac_path_GREP_found=false
5931 # Loop through the user's path and test for each of PROGNAME-LIST
5932 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5933 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5934 do
5935 IFS=$as_save_IFS
5936 test -z "$as_dir" && as_dir=.
5937 for ac_prog in grep ggrep; do
5938 for ac_exec_ext in '' $ac_executable_extensions; do
5939 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5940 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5941 # Check for GNU ac_path_GREP and select it if it is found.
5942 # Check for GNU $ac_path_GREP
5943 case `"$ac_path_GREP" --version 2>&1` in
5944 *GNU*)
5945 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5946 *)
5947 ac_count=0
5948 $as_echo_n 0123456789 >"conftest.in"
5949 while :
5950 do
5951 cat "conftest.in" "conftest.in" >"conftest.tmp"
5952 mv "conftest.tmp" "conftest.in"
5953 cp "conftest.in" "conftest.nl"
5954 $as_echo 'GREP' >> "conftest.nl"
5955 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5956 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5957 as_fn_arith $ac_count + 1 && ac_count=$as_val
5958 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5959 # Best one so far, save it but keep looking for a better one
5960 ac_cv_path_GREP="$ac_path_GREP"
5961 ac_path_GREP_max=$ac_count
5962 fi
5963 # 10*(2^10) chars as input seems more than enough
5964 test $ac_count -gt 10 && break
5965 done
5966 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5967 esac
5968
5969 $ac_path_GREP_found && break 3
5970 done
5971 done
5972 done
5973 IFS=$as_save_IFS
5974 if test -z "$ac_cv_path_GREP"; then
5975 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5976 fi
5977 else
5978 ac_cv_path_GREP=$GREP
5979 fi
5980
5981 fi
5982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5983 $as_echo "$ac_cv_path_GREP" >&6; }
5984 GREP="$ac_cv_path_GREP"
5985
5986
5987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5988 $as_echo_n "checking for egrep... " >&6; }
5989 if test "${ac_cv_path_EGREP+set}" = set; then :
5990 $as_echo_n "(cached) " >&6
5991 else
5992 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5993 then ac_cv_path_EGREP="$GREP -E"
5994 else
5995 if test -z "$EGREP"; then
5996 ac_path_EGREP_found=false
5997 # Loop through the user's path and test for each of PROGNAME-LIST
5998 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5999 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
6000 do
6001 IFS=$as_save_IFS
6002 test -z "$as_dir" && as_dir=.
6003 for ac_prog in egrep; do
6004 for ac_exec_ext in '' $ac_executable_extensions; do
6005 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
6006 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
6007 # Check for GNU ac_path_EGREP and select it if it is found.
6008 # Check for GNU $ac_path_EGREP
6009 case `"$ac_path_EGREP" --version 2>&1` in
6010 *GNU*)
6011 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
6012 *)
6013 ac_count=0
6014 $as_echo_n 0123456789 >"conftest.in"
6015 while :
6016 do
6017 cat "conftest.in" "conftest.in" >"conftest.tmp"
6018 mv "conftest.tmp" "conftest.in"
6019 cp "conftest.in" "conftest.nl"
6020 $as_echo 'EGREP' >> "conftest.nl"
6021 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
6022 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
6023 as_fn_arith $ac_count + 1 && ac_count=$as_val
6024 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
6025 # Best one so far, save it but keep looking for a better one
6026 ac_cv_path_EGREP="$ac_path_EGREP"
6027 ac_path_EGREP_max=$ac_count
6028 fi
6029 # 10*(2^10) chars as input seems more than enough
6030 test $ac_count -gt 10 && break
6031 done
6032 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
6033 esac
6034
6035 $ac_path_EGREP_found && break 3
6036 done
6037 done
6038 done
6039 IFS=$as_save_IFS
6040 if test -z "$ac_cv_path_EGREP"; then
6041 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
6042 fi
6043 else
6044 ac_cv_path_EGREP=$EGREP
6045 fi
6046
6047 fi
6048 fi
6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
6050 $as_echo "$ac_cv_path_EGREP" >&6; }
6051 EGREP="$ac_cv_path_EGREP"
6052
6053
6054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6055 $as_echo_n "checking for ANSI C header files... " >&6; }
6056 if test "${ac_cv_header_stdc+set}" = set; then :
6057 $as_echo_n "(cached) " >&6
6058 else
6059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6060 /* end confdefs.h. */
6061 #include <stdlib.h>
6062 #include <stdarg.h>
6063 #include <string.h>
6064 #include <float.h>
6065
6066 int
6067 main ()
6068 {
6069
6070 ;
6071 return 0;
6072 }
6073 _ACEOF
6074 if ac_fn_c_try_compile "$LINENO"; then :
6075 ac_cv_header_stdc=yes
6076 else
6077 ac_cv_header_stdc=no
6078 fi
6079 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6080
6081 if test $ac_cv_header_stdc = yes; then
6082 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6084 /* end confdefs.h. */
6085 #include <string.h>
6086
6087 _ACEOF
6088 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6089 $EGREP "memchr" >/dev/null 2>&1; then :
6090
6091 else
6092 ac_cv_header_stdc=no
6093 fi
6094 rm -f conftest*
6095
6096 fi
6097
6098 if test $ac_cv_header_stdc = yes; then
6099 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6100 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6101 /* end confdefs.h. */
6102 #include <stdlib.h>
6103
6104 _ACEOF
6105 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6106 $EGREP "free" >/dev/null 2>&1; then :
6107
6108 else
6109 ac_cv_header_stdc=no
6110 fi
6111 rm -f conftest*
6112
6113 fi
6114
6115 if test $ac_cv_header_stdc = yes; then
6116 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6117 if test "$cross_compiling" = yes; then :
6118 :
6119 else
6120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6121 /* end confdefs.h. */
6122 #include <ctype.h>
6123 #include <stdlib.h>
6124 #if ((' ' & 0x0FF) == 0x020)
6125 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6126 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6127 #else
6128 # define ISLOWER(c) \
6129 (('a' <= (c) && (c) <= 'i') \
6130 || ('j' <= (c) && (c) <= 'r') \
6131 || ('s' <= (c) && (c) <= 'z'))
6132 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6133 #endif
6134
6135 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6136 int
6137 main ()
6138 {
6139 int i;
6140 for (i = 0; i < 256; i++)
6141 if (XOR (islower (i), ISLOWER (i))
6142 || toupper (i) != TOUPPER (i))
6143 return 2;
6144 return 0;
6145 }
6146 _ACEOF
6147 if ac_fn_c_try_run "$LINENO"; then :
6148
6149 else
6150 ac_cv_header_stdc=no
6151 fi
6152 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6153 conftest.$ac_objext conftest.beam conftest.$ac_ext
6154 fi
6155
6156 fi
6157 fi
6158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6159 $as_echo "$ac_cv_header_stdc" >&6; }
6160 if test $ac_cv_header_stdc = yes; then
6161
6162 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6163
6164 fi
6165
6166 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6167 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6168 inttypes.h stdint.h unistd.h
6169 do :
6170 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6171 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6172 "
6173 eval as_val=\$$as_ac_Header
6174 if test "x$as_val" = x""yes; then :
6175 cat >>confdefs.h <<_ACEOF
6176 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6177 _ACEOF
6178
6179 fi
6180
6181 done
6182
6183
6184
6185
6186
6187 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6188 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6189 MINIX=yes
6190 else
6191 MINIX=
6192 fi
6193
6194
6195 if test "$MINIX" = yes; then
6196
6197 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6198
6199
6200 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6201
6202
6203 $as_echo "#define _MINIX 1" >>confdefs.h
6204
6205 fi
6206
6207 case "$host_os" in
6208 hpux*)
6209
6210 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6211
6212 ;;
6213 esac
6214
6215
6216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6217 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6218 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6219 $as_echo_n "(cached) " >&6
6220 else
6221 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6222 /* end confdefs.h. */
6223
6224 # define __EXTENSIONS__ 1
6225 $ac_includes_default
6226 int
6227 main ()
6228 {
6229
6230 ;
6231 return 0;
6232 }
6233 _ACEOF
6234 if ac_fn_c_try_compile "$LINENO"; then :
6235 ac_cv_safe_to_define___extensions__=yes
6236 else
6237 ac_cv_safe_to_define___extensions__=no
6238 fi
6239 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6240 fi
6241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6242 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6243 test $ac_cv_safe_to_define___extensions__ = yes &&
6244 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6245
6246 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6247
6248 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6249
6250 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6251
6252 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6253
6254
6255
6256
6257
6258
6259
6260
6261 case $ac_cv_prog_cc_stdc in #(
6262 no) :
6263 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6264 *) :
6265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6266 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6267 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6268 $as_echo_n "(cached) " >&6
6269 else
6270 ac_cv_prog_cc_c99=no
6271 ac_save_CC=$CC
6272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6273 /* end confdefs.h. */
6274 #include <stdarg.h>
6275 #include <stdbool.h>
6276 #include <stdlib.h>
6277 #include <wchar.h>
6278 #include <stdio.h>
6279
6280 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6281 #define debug(...) fprintf (stderr, __VA_ARGS__)
6282 #define showlist(...) puts (#__VA_ARGS__)
6283 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6284 static void
6285 test_varargs_macros (void)
6286 {
6287 int x = 1234;
6288 int y = 5678;
6289 debug ("Flag");
6290 debug ("X = %d\n", x);
6291 showlist (The first, second, and third items.);
6292 report (x>y, "x is %d but y is %d", x, y);
6293 }
6294
6295 // Check long long types.
6296 #define BIG64 18446744073709551615ull
6297 #define BIG32 4294967295ul
6298 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6299 #if !BIG_OK
6300 your preprocessor is broken;
6301 #endif
6302 #if BIG_OK
6303 #else
6304 your preprocessor is broken;
6305 #endif
6306 static long long int bignum = -9223372036854775807LL;
6307 static unsigned long long int ubignum = BIG64;
6308
6309 struct incomplete_array
6310 {
6311 int datasize;
6312 double data[];
6313 };
6314
6315 struct named_init {
6316 int number;
6317 const wchar_t *name;
6318 double average;
6319 };
6320
6321 typedef const char *ccp;
6322
6323 static inline int
6324 test_restrict (ccp restrict text)
6325 {
6326 // See if C++-style comments work.
6327 // Iterate through items via the restricted pointer.
6328 // Also check for declarations in for loops.
6329 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6330 continue;
6331 return 0;
6332 }
6333
6334 // Check varargs and va_copy.
6335 static void
6336 test_varargs (const char *format, ...)
6337 {
6338 va_list args;
6339 va_start (args, format);
6340 va_list args_copy;
6341 va_copy (args_copy, args);
6342
6343 const char *str;
6344 int number;
6345 float fnumber;
6346
6347 while (*format)
6348 {
6349 switch (*format++)
6350 {
6351 case 's': // string
6352 str = va_arg (args_copy, const char *);
6353 break;
6354 case 'd': // int
6355 number = va_arg (args_copy, int);
6356 break;
6357 case 'f': // float
6358 fnumber = va_arg (args_copy, double);
6359 break;
6360 default:
6361 break;
6362 }
6363 }
6364 va_end (args_copy);
6365 va_end (args);
6366 }
6367
6368 int
6369 main ()
6370 {
6371
6372 // Check bool.
6373 _Bool success = false;
6374
6375 // Check restrict.
6376 if (test_restrict ("String literal") == 0)
6377 success = true;
6378 char *restrict newvar = "Another string";
6379
6380 // Check varargs.
6381 test_varargs ("s, d' f .", "string", 65, 34.234);
6382 test_varargs_macros ();
6383
6384 // Check flexible array members.
6385 struct incomplete_array *ia =
6386 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6387 ia->datasize = 10;
6388 for (int i = 0; i < ia->datasize; ++i)
6389 ia->data[i] = i * 1.234;
6390
6391 // Check named initializers.
6392 struct named_init ni = {
6393 .number = 34,
6394 .name = L"Test wide string",
6395 .average = 543.34343,
6396 };
6397
6398 ni.number = 58;
6399
6400 int dynamic_array[ni.number];
6401 dynamic_array[ni.number - 1] = 543;
6402
6403 // work around unused variable warnings
6404 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6405 || dynamic_array[ni.number - 1] != 543);
6406
6407 ;
6408 return 0;
6409 }
6410 _ACEOF
6411 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6412 do
6413 CC="$ac_save_CC $ac_arg"
6414 if ac_fn_c_try_compile "$LINENO"; then :
6415 ac_cv_prog_cc_c99=$ac_arg
6416 fi
6417 rm -f core conftest.err conftest.$ac_objext
6418 test "x$ac_cv_prog_cc_c99" != "xno" && break
6419 done
6420 rm -f conftest.$ac_ext
6421 CC=$ac_save_CC
6422
6423 fi
6424 # AC_CACHE_VAL
6425 case "x$ac_cv_prog_cc_c99" in
6426 x)
6427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6428 $as_echo "none needed" >&6; } ;;
6429 xno)
6430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6431 $as_echo "unsupported" >&6; } ;;
6432 *)
6433 CC="$CC $ac_cv_prog_cc_c99"
6434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6435 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6436 esac
6437 if test "x$ac_cv_prog_cc_c99" != xno; then :
6438 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6439 else
6440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6441 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6442 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6443 $as_echo_n "(cached) " >&6
6444 else
6445 ac_cv_prog_cc_c89=no
6446 ac_save_CC=$CC
6447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6448 /* end confdefs.h. */
6449 #include <stdarg.h>
6450 #include <stdio.h>
6451 #include <sys/types.h>
6452 #include <sys/stat.h>
6453 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6454 struct buf { int x; };
6455 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6456 static char *e (p, i)
6457 char **p;
6458 int i;
6459 {
6460 return p[i];
6461 }
6462 static char *f (char * (*g) (char **, int), char **p, ...)
6463 {
6464 char *s;
6465 va_list v;
6466 va_start (v,p);
6467 s = g (p, va_arg (v,int));
6468 va_end (v);
6469 return s;
6470 }
6471
6472 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6473 function prototypes and stuff, but not '\xHH' hex character constants.
6474 These don't provoke an error unfortunately, instead are silently treated
6475 as 'x'. The following induces an error, until -std is added to get
6476 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6477 array size at least. It's necessary to write '\x00'==0 to get something
6478 that's true only with -std. */
6479 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6480
6481 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6482 inside strings and character constants. */
6483 #define FOO(x) 'x'
6484 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6485
6486 int test (int i, double x);
6487 struct s1 {int (*f) (int a);};
6488 struct s2 {int (*f) (double a);};
6489 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6490 int argc;
6491 char **argv;
6492 int
6493 main ()
6494 {
6495 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6496 ;
6497 return 0;
6498 }
6499 _ACEOF
6500 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6501 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6502 do
6503 CC="$ac_save_CC $ac_arg"
6504 if ac_fn_c_try_compile "$LINENO"; then :
6505 ac_cv_prog_cc_c89=$ac_arg
6506 fi
6507 rm -f core conftest.err conftest.$ac_objext
6508 test "x$ac_cv_prog_cc_c89" != "xno" && break
6509 done
6510 rm -f conftest.$ac_ext
6511 CC=$ac_save_CC
6512
6513 fi
6514 # AC_CACHE_VAL
6515 case "x$ac_cv_prog_cc_c89" in
6516 x)
6517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6518 $as_echo "none needed" >&6; } ;;
6519 xno)
6520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6521 $as_echo "unsupported" >&6; } ;;
6522 *)
6523 CC="$CC $ac_cv_prog_cc_c89"
6524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6525 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6526 esac
6527 if test "x$ac_cv_prog_cc_c89" != xno; then :
6528 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6529 else
6530 ac_cv_prog_cc_stdc=no
6531 fi
6532
6533 fi
6534 ;;
6535 esac
6536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6537 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6538 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6539 $as_echo_n "(cached) " >&6
6540 fi
6541
6542 case $ac_cv_prog_cc_stdc in #(
6543 no) :
6544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6545 $as_echo "unsupported" >&6; } ;; #(
6546 '') :
6547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6548 $as_echo "none needed" >&6; } ;; #(
6549 *) :
6550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6551 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6552 esac
6553
6554
6555
6556 # Code from module alloca-opt:
6557 # Code from module allocator:
6558 # Code from module arg-nonnull:
6559 # Code from module c++defs:
6560 # Code from module careadlinkat:
6561 # Code from module crypto/md5:
6562 # Code from module crypto/sha1:
6563 # Code from module crypto/sha256:
6564 # Code from module crypto/sha512:
6565 # Code from module dosname:
6566 # Code from module dtoastr:
6567 # Code from module dup2:
6568 # Code from module extensions:
6569
6570 # Code from module filemode:
6571 # Code from module getloadavg:
6572 # Code from module getopt-gnu:
6573 # Code from module getopt-posix:
6574 # Code from module gettext-h:
6575 # Code from module ignore-value:
6576 # Code from module include_next:
6577 # Code from module intprops:
6578 # Code from module inttypes-incomplete:
6579 # Code from module lstat:
6580 # Code from module mktime:
6581 # Code from module multiarch:
6582 # Code from module readlink:
6583 # Code from module socklen:
6584 # Code from module ssize_t:
6585 # Code from module stat:
6586 # Code from module stdarg:
6587
6588 # Code from module stdbool:
6589 # Code from module stddef:
6590 # Code from module stdint:
6591 # Code from module stdio:
6592 # Code from module stdlib:
6593 # Code from module strftime:
6594 # Code from module strtoull:
6595 # Code from module strtoumax:
6596 # Code from module symlink:
6597 # Code from module sys_stat:
6598 # Code from module time:
6599 # Code from module time_r:
6600 # Code from module u64:
6601 # Code from module unistd:
6602 # Code from module verify:
6603 # Code from module warn-on-use:
6604
6605
6606 # On Suns, sometimes $CPP names a directory.
6607 if test -n "$CPP" && test -d "$CPP"; then
6608 CPP=
6609 fi
6610
6611 ## If not using gcc, and on Solaris, and no CPP specified, see if
6612 ## using a Sun compiler, which needs -Xs to prevent whitespace.
6613 if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
6614 test x"$CPP" = x; then
6615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
6616 $as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
6617 if test "${emacs_cv_sunpro_c+set}" = set; then :
6618 $as_echo_n "(cached) " >&6
6619 else
6620 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6621 /* end confdefs.h. */
6622
6623 int
6624 main ()
6625 {
6626 #ifndef __SUNPRO_C
6627 fail;
6628 #endif
6629
6630 ;
6631 return 0;
6632 }
6633 _ACEOF
6634 if ac_fn_c_try_link "$LINENO"; then :
6635 emacs_cv_sunpro_c=yes
6636 else
6637 emacs_cv_sunpro_c=no
6638 fi
6639 rm -f core conftest.err conftest.$ac_objext \
6640 conftest$ac_exeext conftest.$ac_ext
6641 fi
6642
6643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
6644 $as_echo "$emacs_cv_sunpro_c" >&6; }
6645
6646 if test x"$emacs_cv_sunpro_c" = xyes; then
6647 NON_GNU_CPP="$CC -E -Xs"
6648 fi
6649 fi
6650
6651 #### Some systems specify a CPP to use unless we are using GCC.
6652 #### Now that we know whether we are using GCC, we can decide whether
6653 #### to use that one.
6654 if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
6655 then
6656 CPP="$NON_GNU_CPP"
6657 fi
6658
6659 #### Some systems specify a CC to use unless we are using GCC.
6660 #### Now that we know whether we are using GCC, we can decide whether
6661 #### to use that one.
6662 if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
6663 test x$cc_specified != xyes
6664 then
6665 CC="$NON_GNU_CC"
6666 fi
6667
6668 if test x$GCC = xyes; then
6669 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
6670 else
6671 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
6672 fi
6673
6674 ### Use -Wdeclaration-after-statement if the compiler supports it
6675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
6676 $as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
6677 SAVE_CFLAGS="$CFLAGS"
6678 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
6679 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6680 /* end confdefs.h. */
6681
6682 int
6683 main ()
6684 {
6685
6686 ;
6687 return 0;
6688 }
6689 _ACEOF
6690 if ac_fn_c_try_compile "$LINENO"; then :
6691 has_option=yes
6692 else
6693 has_option=no
6694 fi
6695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6696 if test $has_option = yes; then
6697 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
6698 fi
6699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6700 $as_echo "$has_option" >&6; }
6701 CFLAGS="$SAVE_CFLAGS"
6702 unset has_option
6703 unset SAVE_CFLAGS
6704
6705 ### Use -Wold-style-definition if the compiler supports it
6706 # This can be removed when conversion to standard C is finished.
6707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5
6708 $as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; }
6709 SAVE_CFLAGS="$CFLAGS"
6710 CFLAGS="$CFLAGS -Wold-style-definition"
6711 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6712 /* end confdefs.h. */
6713
6714 int
6715 main ()
6716 {
6717
6718 ;
6719 return 0;
6720 }
6721 _ACEOF
6722 if ac_fn_c_try_compile "$LINENO"; then :
6723 has_option=yes
6724 else
6725 has_option=no
6726 fi
6727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6728 if test $has_option = yes; then
6729 C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH"
6730 fi
6731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6732 $as_echo "$has_option" >&6; }
6733 CFLAGS="$SAVE_CFLAGS"
6734 unset has_option
6735 unset SAVE_CFLAGS
6736
6737 ### Use -Wimplicit-function-declaration if the compiler supports it
6738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5
6739 $as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; }
6740 SAVE_CFLAGS="$CFLAGS"
6741 CFLAGS="$CFLAGS -Wimplicit-function-declaration"
6742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6743 /* end confdefs.h. */
6744
6745 int
6746 main ()
6747 {
6748
6749 ;
6750 return 0;
6751 }
6752 _ACEOF
6753 if ac_fn_c_try_compile "$LINENO"; then :
6754 has_option=yes
6755 else
6756 has_option=no
6757 fi
6758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6759 if test $has_option = yes; then
6760 C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH"
6761 fi
6762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
6763 $as_echo "$has_option" >&6; }
6764 CFLAGS="$SAVE_CFLAGS"
6765 unset has_option
6766 unset SAVE_CFLAGS
6767
6768
6769
6770
6771 #### Some other nice autoconf tests.
6772
6773 ac_ext=c
6774 ac_cpp='$CPP $CPPFLAGS'
6775 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6776 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6777 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
6779 $as_echo_n "checking how to run the C preprocessor... " >&6; }
6780 # On Suns, sometimes $CPP names a directory.
6781 if test -n "$CPP" && test -d "$CPP"; then
6782 CPP=
6783 fi
6784 if test -z "$CPP"; then
6785 if test "${ac_cv_prog_CPP+set}" = set; then :
6786 $as_echo_n "(cached) " >&6
6787 else
6788 # Double quotes because CPP needs to be expanded
6789 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
6790 do
6791 ac_preproc_ok=false
6792 for ac_c_preproc_warn_flag in '' yes
6793 do
6794 # Use a header file that comes with gcc, so configuring glibc
6795 # with a fresh cross-compiler works.
6796 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6797 # <limits.h> exists even on freestanding compilers.
6798 # On the NeXT, cc -E runs the code through the compiler's parser,
6799 # not just through cpp. "Syntax error" is here to catch this case.
6800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6801 /* end confdefs.h. */
6802 #ifdef __STDC__
6803 # include <limits.h>
6804 #else
6805 # include <assert.h>
6806 #endif
6807 Syntax error
6808 _ACEOF
6809 if ac_fn_c_try_cpp "$LINENO"; then :
6810
6811 else
6812 # Broken: fails on valid input.
6813 continue
6814 fi
6815 rm -f conftest.err conftest.$ac_ext
6816
6817 # OK, works on sane cases. Now check whether nonexistent headers
6818 # can be detected and how.
6819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6820 /* end confdefs.h. */
6821 #include <ac_nonexistent.h>
6822 _ACEOF
6823 if ac_fn_c_try_cpp "$LINENO"; then :
6824 # Broken: success on invalid input.
6825 continue
6826 else
6827 # Passes both tests.
6828 ac_preproc_ok=:
6829 break
6830 fi
6831 rm -f conftest.err conftest.$ac_ext
6832
6833 done
6834 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6835 rm -f conftest.err conftest.$ac_ext
6836 if $ac_preproc_ok; then :
6837 break
6838 fi
6839
6840 done
6841 ac_cv_prog_CPP=$CPP
6842
6843 fi
6844 CPP=$ac_cv_prog_CPP
6845 else
6846 ac_cv_prog_CPP=$CPP
6847 fi
6848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
6849 $as_echo "$CPP" >&6; }
6850 ac_preproc_ok=false
6851 for ac_c_preproc_warn_flag in '' yes
6852 do
6853 # Use a header file that comes with gcc, so configuring glibc
6854 # with a fresh cross-compiler works.
6855 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
6856 # <limits.h> exists even on freestanding compilers.
6857 # On the NeXT, cc -E runs the code through the compiler's parser,
6858 # not just through cpp. "Syntax error" is here to catch this case.
6859 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6860 /* end confdefs.h. */
6861 #ifdef __STDC__
6862 # include <limits.h>
6863 #else
6864 # include <assert.h>
6865 #endif
6866 Syntax error
6867 _ACEOF
6868 if ac_fn_c_try_cpp "$LINENO"; then :
6869
6870 else
6871 # Broken: fails on valid input.
6872 continue
6873 fi
6874 rm -f conftest.err conftest.$ac_ext
6875
6876 # OK, works on sane cases. Now check whether nonexistent headers
6877 # can be detected and how.
6878 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6879 /* end confdefs.h. */
6880 #include <ac_nonexistent.h>
6881 _ACEOF
6882 if ac_fn_c_try_cpp "$LINENO"; then :
6883 # Broken: success on invalid input.
6884 continue
6885 else
6886 # Passes both tests.
6887 ac_preproc_ok=:
6888 break
6889 fi
6890 rm -f conftest.err conftest.$ac_ext
6891
6892 done
6893 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
6894 rm -f conftest.err conftest.$ac_ext
6895 if $ac_preproc_ok; then :
6896
6897 else
6898 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
6899 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
6900 as_fn_error "C preprocessor \"$CPP\" fails sanity check
6901 See \`config.log' for more details." "$LINENO" 5; }
6902 fi
6903
6904 ac_ext=c
6905 ac_cpp='$CPP $CPPFLAGS'
6906 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
6907 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
6908 ac_compiler_gnu=$ac_cv_c_compiler_gnu
6909
6910
6911 if test "x$RANLIB" = x; then
6912 if test -n "$ac_tool_prefix"; then
6913 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6914 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6916 $as_echo_n "checking for $ac_word... " >&6; }
6917 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6918 $as_echo_n "(cached) " >&6
6919 else
6920 if test -n "$RANLIB"; then
6921 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6922 else
6923 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6924 for as_dir in $PATH
6925 do
6926 IFS=$as_save_IFS
6927 test -z "$as_dir" && as_dir=.
6928 for ac_exec_ext in '' $ac_executable_extensions; do
6929 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6930 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6931 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6932 break 2
6933 fi
6934 done
6935 done
6936 IFS=$as_save_IFS
6937
6938 fi
6939 fi
6940 RANLIB=$ac_cv_prog_RANLIB
6941 if test -n "$RANLIB"; then
6942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6943 $as_echo "$RANLIB" >&6; }
6944 else
6945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6946 $as_echo "no" >&6; }
6947 fi
6948
6949
6950 fi
6951 if test -z "$ac_cv_prog_RANLIB"; then
6952 ac_ct_RANLIB=$RANLIB
6953 # Extract the first word of "ranlib", so it can be a program name with args.
6954 set dummy ranlib; ac_word=$2
6955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6956 $as_echo_n "checking for $ac_word... " >&6; }
6957 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6958 $as_echo_n "(cached) " >&6
6959 else
6960 if test -n "$ac_ct_RANLIB"; then
6961 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6962 else
6963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6964 for as_dir in $PATH
6965 do
6966 IFS=$as_save_IFS
6967 test -z "$as_dir" && as_dir=.
6968 for ac_exec_ext in '' $ac_executable_extensions; do
6969 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6970 ac_cv_prog_ac_ct_RANLIB="ranlib"
6971 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6972 break 2
6973 fi
6974 done
6975 done
6976 IFS=$as_save_IFS
6977
6978 fi
6979 fi
6980 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6981 if test -n "$ac_ct_RANLIB"; then
6982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6983 $as_echo "$ac_ct_RANLIB" >&6; }
6984 else
6985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6986 $as_echo "no" >&6; }
6987 fi
6988
6989 if test "x$ac_ct_RANLIB" = x; then
6990 RANLIB=":"
6991 else
6992 case $cross_compiling:$ac_tool_warned in
6993 yes:)
6994 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6995 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6996 ac_tool_warned=yes ;;
6997 esac
6998 RANLIB=$ac_ct_RANLIB
6999 fi
7000 else
7001 RANLIB="$ac_cv_prog_RANLIB"
7002 fi
7003
7004 fi
7005
7006 ## Although we're running on an amd64 kernel, we're actually compiling for
7007 ## the x86 architecture. The user should probably have provided an
7008 ## explicit --build to `configure', but if everything else than the kernel
7009 ## is running in i386 mode, we can help them out.
7010 if test "$machine" = "amdx86-64"; then
7011 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
7012 if test "x$ac_cv_have_decl_i386" = x""yes; then :
7013
7014 fi
7015
7016 if test "$ac_cv_have_decl_i386" = "yes"; then
7017 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
7018 machine=intel386
7019 machfile="m/${machine}.h"
7020 fi
7021 fi
7022
7023 # Extract the first word of "install-info", so it can be a program name with args.
7024 set dummy install-info; ac_word=$2
7025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7026 $as_echo_n "checking for $ac_word... " >&6; }
7027 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7028 $as_echo_n "(cached) " >&6
7029 else
7030 case $INSTALL_INFO in
7031 [\\/]* | ?:[\\/]*)
7032 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7033 ;;
7034 *)
7035 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7036 for as_dir in $PATH
7037 do
7038 IFS=$as_save_IFS
7039 test -z "$as_dir" && as_dir=.
7040 for ac_exec_ext in '' $ac_executable_extensions; do
7041 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7042 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7043 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7044 break 2
7045 fi
7046 done
7047 done
7048 IFS=$as_save_IFS
7049
7050 ;;
7051 esac
7052 fi
7053 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7054 if test -n "$INSTALL_INFO"; then
7055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7056 $as_echo "$INSTALL_INFO" >&6; }
7057 else
7058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7059 $as_echo "no" >&6; }
7060 fi
7061
7062
7063 # Extract the first word of "install-info", so it can be a program name with args.
7064 set dummy install-info; ac_word=$2
7065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7066 $as_echo_n "checking for $ac_word... " >&6; }
7067 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7068 $as_echo_n "(cached) " >&6
7069 else
7070 case $INSTALL_INFO in
7071 [\\/]* | ?:[\\/]*)
7072 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7073 ;;
7074 *)
7075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7076 for as_dir in /usr/sbin
7077 do
7078 IFS=$as_save_IFS
7079 test -z "$as_dir" && as_dir=.
7080 for ac_exec_ext in '' $ac_executable_extensions; do
7081 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7082 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7084 break 2
7085 fi
7086 done
7087 done
7088 IFS=$as_save_IFS
7089
7090 ;;
7091 esac
7092 fi
7093 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7094 if test -n "$INSTALL_INFO"; then
7095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7096 $as_echo "$INSTALL_INFO" >&6; }
7097 else
7098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7099 $as_echo "no" >&6; }
7100 fi
7101
7102
7103 # Extract the first word of "install-info", so it can be a program name with args.
7104 set dummy install-info; ac_word=$2
7105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7106 $as_echo_n "checking for $ac_word... " >&6; }
7107 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7108 $as_echo_n "(cached) " >&6
7109 else
7110 case $INSTALL_INFO in
7111 [\\/]* | ?:[\\/]*)
7112 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7113 ;;
7114 *)
7115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7116 for as_dir in /sbin
7117 do
7118 IFS=$as_save_IFS
7119 test -z "$as_dir" && as_dir=.
7120 for ac_exec_ext in '' $ac_executable_extensions; do
7121 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7122 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7124 break 2
7125 fi
7126 done
7127 done
7128 IFS=$as_save_IFS
7129
7130 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7131 ;;
7132 esac
7133 fi
7134 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7135 if test -n "$INSTALL_INFO"; then
7136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7137 $as_echo "$INSTALL_INFO" >&6; }
7138 else
7139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7140 $as_echo "no" >&6; }
7141 fi
7142
7143
7144 # Extract the first word of "gzip", so it can be a program name with args.
7145 set dummy gzip; ac_word=$2
7146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7147 $as_echo_n "checking for $ac_word... " >&6; }
7148 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7149 $as_echo_n "(cached) " >&6
7150 else
7151 case $GZIP_PROG in
7152 [\\/]* | ?:[\\/]*)
7153 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7154 ;;
7155 *)
7156 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7157 for as_dir in $PATH
7158 do
7159 IFS=$as_save_IFS
7160 test -z "$as_dir" && as_dir=.
7161 for ac_exec_ext in '' $ac_executable_extensions; do
7162 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7163 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7164 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7165 break 2
7166 fi
7167 done
7168 done
7169 IFS=$as_save_IFS
7170
7171 ;;
7172 esac
7173 fi
7174 GZIP_PROG=$ac_cv_path_GZIP_PROG
7175 if test -n "$GZIP_PROG"; then
7176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7177 $as_echo "$GZIP_PROG" >&6; }
7178 else
7179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7180 $as_echo "no" >&6; }
7181 fi
7182
7183
7184
7185
7186 ## Need makeinfo >= 4.6 (?) to build the manuals.
7187 # Extract the first word of "makeinfo", so it can be a program name with args.
7188 set dummy makeinfo; ac_word=$2
7189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7190 $as_echo_n "checking for $ac_word... " >&6; }
7191 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
7192 $as_echo_n "(cached) " >&6
7193 else
7194 case $MAKEINFO in
7195 [\\/]* | ?:[\\/]*)
7196 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7197 ;;
7198 *)
7199 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7200 for as_dir in $PATH
7201 do
7202 IFS=$as_save_IFS
7203 test -z "$as_dir" && as_dir=.
7204 for ac_exec_ext in '' $ac_executable_extensions; do
7205 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7206 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
7207 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7208 break 2
7209 fi
7210 done
7211 done
7212 IFS=$as_save_IFS
7213
7214 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
7215 ;;
7216 esac
7217 fi
7218 MAKEINFO=$ac_cv_path_MAKEINFO
7219 if test -n "$MAKEINFO"; then
7220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
7221 $as_echo "$MAKEINFO" >&6; }
7222 else
7223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7224 $as_echo "no" >&6; }
7225 fi
7226
7227
7228 if test "$MAKEINFO" != "no" && \
7229 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[6-9]|4\.[1-5][0-9]+)'`" = x; then
7230 MAKEINFO=no
7231 fi
7232
7233 ## Makeinfo is unusual. For a released Emacs, the manuals are
7234 ## pre-built, and not deleted by the normal clean rules. makeinfo is
7235 ## therefore in the category of "special tools" not normally required, which
7236 ## configure does not have to check for (eg autoconf itself).
7237 ## In a Bazaar checkout on the other hand, the manuals are not included.
7238 ## So makeinfo is a requirement to build from Bazaar, and configure
7239 ## should test for it as it does for any other build requirement.
7240 ## We use the presence of $srcdir/info/emacs to distinguish a release,
7241 ## with pre-built manuals, from a Bazaar checkout.
7242 HAVE_MAKEINFO=yes
7243
7244 if test "$MAKEINFO" = "no"; then
7245 MAKEINFO=makeinfo
7246 if test "x${with_makeinfo}" = "xno"; then
7247 HAVE_MAKEINFO=no
7248 elif test ! -e $srcdir/info/emacs; then
7249 as_fn_error "You do not seem to have makeinfo >= 4.6, and your
7250 source tree does not seem to have pre-built manuals in the \`info' directory.
7251 Either install a suitable version of makeinfo, or re-run configure
7252 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
7253 fi
7254 fi
7255
7256
7257
7258 if test x$GCC = xyes; then
7259 test "x$GCC_LINK_TEST_OPTIONS" != x && \
7260 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
7261 else
7262 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
7263 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
7264 fi
7265
7266
7267 late_LDFLAGS=$LDFLAGS
7268 if test x$GCC = xyes; then
7269 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
7270 else
7271 LDFLAGS="$LDFLAGS -znocombreloc"
7272 fi
7273
7274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
7275 $as_echo_n "checking for -znocombreloc... " >&6; }
7276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7277 /* end confdefs.h. */
7278
7279 int
7280 main ()
7281 {
7282
7283 ;
7284 return 0;
7285 }
7286 _ACEOF
7287 if ac_fn_c_try_link "$LINENO"; then :
7288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7289 $as_echo "yes" >&6; }
7290 else
7291 LDFLAGS=$late_LDFLAGS
7292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7293 $as_echo "no" >&6; }
7294 fi
7295 rm -f core conftest.err conftest.$ac_objext \
7296 conftest$ac_exeext conftest.$ac_ext
7297
7298
7299 # The value of CPP is a quoted variable reference, so we need to do this
7300 # to get its actual value...
7301 CPP=`eval "echo $CPP"`
7302
7303
7304 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
7305 case "$opsys" in
7306 your-opsys-here) CANNOT_DUMP=yes ;;
7307 esac
7308
7309 test "$CANNOT_DUMP" = "yes" && \
7310
7311 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
7312
7313
7314
7315
7316
7317 UNEXEC_OBJ=unexelf.o
7318 case "$opsys" in
7319 # MSDOS uses unexcoff.o
7320 # MSWindows uses unexw32.o
7321 aix4-2)
7322 UNEXEC_OBJ=unexaix.o
7323 ;;
7324 cygwin)
7325 UNEXEC_OBJ=unexcw.o
7326 ;;
7327 darwin)
7328 UNEXEC_OBJ=unexmacosx.o
7329 ;;
7330 hpux10-20 | hpux11)
7331 UNEXEC_OBJ=unexhp9k800.o
7332 ;;
7333 sol2-10)
7334 # Use the Solaris dldump() function, called from unexsol.c, to dump
7335 # emacs, instead of the generic ELF dump code found in unexelf.c.
7336 # The resulting binary has a complete symbol table, and is better
7337 # for debugging and other observability tools (debuggers, pstack, etc).
7338 #
7339 # If you encounter a problem using dldump(), please consider sending
7340 # a message to the OpenSolaris tools-linking mailing list:
7341 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
7342 #
7343 # It is likely that dldump() works with older Solaris too, but this has
7344 # not been tested, so for now this change is for Solaris 10 or newer.
7345 UNEXEC_OBJ=unexsol.o
7346 ;;
7347 esac
7348
7349 LD_SWITCH_SYSTEM=
7350 case "$opsys" in
7351 freebsd)
7352 ## Let `ld' find image libs and similar things in /usr/local/lib.
7353 ## The system compiler, GCC, has apparently been modified to not
7354 ## look there, contrary to what a stock GCC would do.
7355 LD_SWITCH_SYSTEM=-L/usr/local/lib
7356 ;;
7357
7358 gnu-linux)
7359 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
7360 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
7361 ;;
7362
7363 netbsd)
7364 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
7365 ;;
7366
7367 openbsd)
7368 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
7369 ## otherwise Emacs dumps core on elf systems.
7370 LD_SWITCH_SYSTEM="-Z"
7371 ;;
7372 esac
7373
7374
7375 ac_link="$ac_link $LD_SWITCH_SYSTEM"
7376
7377 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
7378 ## which has not been defined yet. When this was handled with cpp,
7379 ## it was expanded to null when configure sourced the s/*.h file.
7380 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
7381 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
7382 ## (or somesuch), but because it is supposed to go at the _front_
7383 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
7384 ## Compare with the gnu-linux case below, which added to the end
7385 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
7386 ## LD_SWITCH_SYSTEM_TEMACS.
7387 case "$opsys" in
7388 netbsd|openbsd)
7389 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
7390 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
7391 esac
7392
7393
7394 C_SWITCH_MACHINE=
7395 if test "$machine" = "alpha"; then
7396 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
7397 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
7398
7399 fi
7400
7401 if test "$ac_cv_have_decl___ELF__" = "yes"; then
7402 ## With ELF, make sure that all common symbols get allocated to in the
7403 ## data section. Otherwise, the dump of temacs may miss variables in
7404 ## the shared library that have been initialized. For example, with
7405 ## GNU libc, __malloc_initialized would normally be resolved to the
7406 ## shared library's .bss section, which is fatal.
7407 if test "x$GCC" = "xyes"; then
7408 C_SWITCH_MACHINE="-fno-common"
7409 else
7410 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
7411 fi
7412 else
7413 UNEXEC_OBJ=unexalpha.o
7414 fi
7415 fi
7416
7417
7418
7419
7420 C_SWITCH_SYSTEM=
7421 ## Some programs in src produce warnings saying certain subprograms
7422 ## are too complex and need a MAXMEM value greater than 2000 for
7423 ## additional optimization. --nils@exp-math.uni-essen.de
7424 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
7425 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
7426 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
7427 ## It is redundant in glibc2, since we define _GNU_SOURCE.
7428
7429
7430
7431 LIBS_SYSTEM=
7432 case "$opsys" in
7433 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
7434 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
7435
7436 freebsd) LIBS_SYSTEM="-lutil" ;;
7437
7438 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
7439
7440 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
7441
7442 ## Motif needs -lgen.
7443 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
7444 esac
7445
7446
7447
7448 ### Make sure subsequent tests use flags consistent with the build flags.
7449
7450 if test x"${OVERRIDE_CPPFLAGS}" != x; then
7451 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
7452 else
7453 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
7454 fi
7455
7456 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
7457
7458
7459 # Check whether --enable-largefile was given.
7460 if test "${enable_largefile+set}" = set; then :
7461 enableval=$enable_largefile;
7462 fi
7463
7464 if test "$enable_largefile" != no; then
7465
7466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7467 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7468 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
7469 $as_echo_n "(cached) " >&6
7470 else
7471 ac_cv_sys_largefile_CC=no
7472 if test "$GCC" != yes; then
7473 ac_save_CC=$CC
7474 while :; do
7475 # IRIX 6.2 and later do not support large files by default,
7476 # so use the C compiler's -n32 option if that helps.
7477 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7478 /* end confdefs.h. */
7479 #include <sys/types.h>
7480 /* Check that off_t can represent 2**63 - 1 correctly.
7481 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7482 since some C++ compilers masquerading as C compilers
7483 incorrectly reject 9223372036854775807. */
7484 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7485 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7486 && LARGE_OFF_T % 2147483647 == 1)
7487 ? 1 : -1];
7488 int
7489 main ()
7490 {
7491
7492 ;
7493 return 0;
7494 }
7495 _ACEOF
7496 if ac_fn_c_try_compile "$LINENO"; then :
7497 break
7498 fi
7499 rm -f core conftest.err conftest.$ac_objext
7500 CC="$CC -n32"
7501 if ac_fn_c_try_compile "$LINENO"; then :
7502 ac_cv_sys_largefile_CC=' -n32'; break
7503 fi
7504 rm -f core conftest.err conftest.$ac_objext
7505 break
7506 done
7507 CC=$ac_save_CC
7508 rm -f conftest.$ac_ext
7509 fi
7510 fi
7511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7512 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
7513 if test "$ac_cv_sys_largefile_CC" != no; then
7514 CC=$CC$ac_cv_sys_largefile_CC
7515 fi
7516
7517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7518 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7519 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
7520 $as_echo_n "(cached) " >&6
7521 else
7522 while :; do
7523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7524 /* end confdefs.h. */
7525 #include <sys/types.h>
7526 /* Check that off_t can represent 2**63 - 1 correctly.
7527 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7528 since some C++ compilers masquerading as C compilers
7529 incorrectly reject 9223372036854775807. */
7530 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7531 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7532 && LARGE_OFF_T % 2147483647 == 1)
7533 ? 1 : -1];
7534 int
7535 main ()
7536 {
7537
7538 ;
7539 return 0;
7540 }
7541 _ACEOF
7542 if ac_fn_c_try_compile "$LINENO"; then :
7543 ac_cv_sys_file_offset_bits=no; break
7544 fi
7545 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7547 /* end confdefs.h. */
7548 #define _FILE_OFFSET_BITS 64
7549 #include <sys/types.h>
7550 /* Check that off_t can represent 2**63 - 1 correctly.
7551 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7552 since some C++ compilers masquerading as C compilers
7553 incorrectly reject 9223372036854775807. */
7554 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7555 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7556 && LARGE_OFF_T % 2147483647 == 1)
7557 ? 1 : -1];
7558 int
7559 main ()
7560 {
7561
7562 ;
7563 return 0;
7564 }
7565 _ACEOF
7566 if ac_fn_c_try_compile "$LINENO"; then :
7567 ac_cv_sys_file_offset_bits=64; break
7568 fi
7569 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7570 ac_cv_sys_file_offset_bits=unknown
7571 break
7572 done
7573 fi
7574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7575 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7576 case $ac_cv_sys_file_offset_bits in #(
7577 no | unknown) ;;
7578 *)
7579 cat >>confdefs.h <<_ACEOF
7580 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7581 _ACEOF
7582 ;;
7583 esac
7584 rm -rf conftest*
7585 if test $ac_cv_sys_file_offset_bits = unknown; then
7586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7587 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7588 if test "${ac_cv_sys_large_files+set}" = set; then :
7589 $as_echo_n "(cached) " >&6
7590 else
7591 while :; do
7592 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7593 /* end confdefs.h. */
7594 #include <sys/types.h>
7595 /* Check that off_t can represent 2**63 - 1 correctly.
7596 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7597 since some C++ compilers masquerading as C compilers
7598 incorrectly reject 9223372036854775807. */
7599 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7600 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7601 && LARGE_OFF_T % 2147483647 == 1)
7602 ? 1 : -1];
7603 int
7604 main ()
7605 {
7606
7607 ;
7608 return 0;
7609 }
7610 _ACEOF
7611 if ac_fn_c_try_compile "$LINENO"; then :
7612 ac_cv_sys_large_files=no; break
7613 fi
7614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7615 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7616 /* end confdefs.h. */
7617 #define _LARGE_FILES 1
7618 #include <sys/types.h>
7619 /* Check that off_t can represent 2**63 - 1 correctly.
7620 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7621 since some C++ compilers masquerading as C compilers
7622 incorrectly reject 9223372036854775807. */
7623 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7624 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7625 && LARGE_OFF_T % 2147483647 == 1)
7626 ? 1 : -1];
7627 int
7628 main ()
7629 {
7630
7631 ;
7632 return 0;
7633 }
7634 _ACEOF
7635 if ac_fn_c_try_compile "$LINENO"; then :
7636 ac_cv_sys_large_files=1; break
7637 fi
7638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7639 ac_cv_sys_large_files=unknown
7640 break
7641 done
7642 fi
7643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
7644 $as_echo "$ac_cv_sys_large_files" >&6; }
7645 case $ac_cv_sys_large_files in #(
7646 no | unknown) ;;
7647 *)
7648 cat >>confdefs.h <<_ACEOF
7649 #define _LARGE_FILES $ac_cv_sys_large_files
7650 _ACEOF
7651 ;;
7652 esac
7653 rm -rf conftest*
7654 fi
7655 fi
7656
7657
7658
7659 LIB_MATH=-lm
7660 LIB_STANDARD=
7661 START_FILES=
7662
7663 case $opsys in
7664 cygwin )
7665 LIB_MATH=
7666 START_FILES='pre-crt0.o'
7667 ;;
7668 darwin )
7669 ## Adding -lm confuses the dynamic linker, so omit it.
7670 LIB_MATH=
7671 START_FILES='pre-crt0.o'
7672 ;;
7673 freebsd )
7674 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
7675 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
7676 ;;
7677 gnu-linux | gnu-kfreebsd )
7678 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
7679 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
7680 ;;
7681 hpux10-20 | hpux11 )
7682 LIB_STANDARD=-lc
7683 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
7684 ;;
7685 netbsd | openbsd )
7686 if test -f $CRT_DIR/crti.o; then
7687 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
7688 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
7689 else
7690 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
7691 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
7692 fi
7693 ;;
7694 esac
7695
7696
7697
7698
7699 crt_files=
7700
7701 for file in x $LIB_STANDARD $START_FILES; do
7702 case "$file" in
7703 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
7704 esac
7705 done
7706
7707 if test "x$crt_files" != x; then
7708
7709 ## If user specified a crt-dir, use that unconditionally.
7710 crt_gcc=no
7711
7712 if test "X$CRT_DIR" = "X"; then
7713
7714 CRT_DIR=/usr/lib # default
7715
7716 case "$canonical" in
7717 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
7718 ## On x86-64 and s390x GNU/Linux distributions, the standard library
7719 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
7720 ## For anything else (eg /usr/lib32), it is up the user to specify
7721 ## the location (bug#5655).
7722 ## Test for crtn.o, not just the directory, because sometimes the
7723 ## directory exists but does not have the relevant files (bug#1287).
7724 ## FIXME better to test for binary compatibility somehow.
7725 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
7726 ;;
7727
7728 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
7729 esac
7730
7731 case "$opsys" in
7732 hpux10-20) CRT_DIR=/lib ;;
7733 esac
7734
7735 test "x${GCC}" = xyes && crt_gcc=yes
7736
7737 fi # CRT_DIR = ""
7738
7739 crt_missing=
7740
7741 for file in $crt_files; do
7742
7743 ## If we're using gcc, try to determine it automatically by asking
7744 ## gcc. [If this doesn't work, CRT_DIR will remain at the
7745 ## system-dependent default from above.]
7746 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
7747
7748 crt_file=`$CC --print-file-name=$file 2>/dev/null`
7749 case "$crt_file" in
7750 */*)
7751 CRT_DIR=`$as_dirname -- "$crt_file" ||
7752 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
7753 X"$crt_file" : 'X\(//\)[^/]' \| \
7754 X"$crt_file" : 'X\(//\)$' \| \
7755 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
7756 $as_echo X"$crt_file" |
7757 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
7758 s//\1/
7759 q
7760 }
7761 /^X\(\/\/\)[^/].*/{
7762 s//\1/
7763 q
7764 }
7765 /^X\(\/\/\)$/{
7766 s//\1/
7767 q
7768 }
7769 /^X\(\/\).*/{
7770 s//\1/
7771 q
7772 }
7773 s/.*/./; q'`
7774 ;;
7775 esac
7776 fi
7777
7778 crt_gcc=no
7779
7780 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
7781 done # $crt_files
7782
7783 test "x$crt_missing" = x || \
7784 as_fn_error "Required file(s) not found:$crt_missing
7785 Try using the --with-crt-dir option." "$LINENO" 5
7786
7787 fi # crt_files != ""
7788
7789
7790
7791
7792
7793
7794
7795 if test "${with_sound}" != "no"; then
7796 # Sound support for GNU/Linux and the free BSDs.
7797 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
7798 do :
7799 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
7800 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
7801 eval as_val=\$$as_ac_Header
7802 if test "x$as_val" = x""yes; then :
7803 cat >>confdefs.h <<_ACEOF
7804 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
7805 _ACEOF
7806 have_sound_header=yes
7807 fi
7808
7809 done
7810
7811 # Emulation library used on NetBSD.
7812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
7813 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
7814 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
7815 $as_echo_n "(cached) " >&6
7816 else
7817 ac_check_lib_save_LIBS=$LIBS
7818 LIBS="-lossaudio $LIBS"
7819 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7820 /* end confdefs.h. */
7821
7822 /* Override any GCC internal prototype to avoid an error.
7823 Use char because int might match the return type of a GCC
7824 builtin and then its argument prototype would still apply. */
7825 #ifdef __cplusplus
7826 extern "C"
7827 #endif
7828 char _oss_ioctl ();
7829 int
7830 main ()
7831 {
7832 return _oss_ioctl ();
7833 ;
7834 return 0;
7835 }
7836 _ACEOF
7837 if ac_fn_c_try_link "$LINENO"; then :
7838 ac_cv_lib_ossaudio__oss_ioctl=yes
7839 else
7840 ac_cv_lib_ossaudio__oss_ioctl=no
7841 fi
7842 rm -f core conftest.err conftest.$ac_objext \
7843 conftest$ac_exeext conftest.$ac_ext
7844 LIBS=$ac_check_lib_save_LIBS
7845 fi
7846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
7847 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
7848 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
7849 LIBSOUND=-lossaudio
7850 else
7851 LIBSOUND=
7852 fi
7853
7854
7855
7856 ALSA_REQUIRED=1.0.0
7857 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
7858
7859 succeeded=no
7860
7861 # Extract the first word of "pkg-config", so it can be a program name with args.
7862 set dummy pkg-config; ac_word=$2
7863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7864 $as_echo_n "checking for $ac_word... " >&6; }
7865 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
7866 $as_echo_n "(cached) " >&6
7867 else
7868 case $PKG_CONFIG in
7869 [\\/]* | ?:[\\/]*)
7870 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
7871 ;;
7872 *)
7873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7874 for as_dir in $PATH
7875 do
7876 IFS=$as_save_IFS
7877 test -z "$as_dir" && as_dir=.
7878 for ac_exec_ext in '' $ac_executable_extensions; do
7879 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7880 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
7881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7882 break 2
7883 fi
7884 done
7885 done
7886 IFS=$as_save_IFS
7887
7888 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
7889 ;;
7890 esac
7891 fi
7892 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
7893 if test -n "$PKG_CONFIG"; then
7894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
7895 $as_echo "$PKG_CONFIG" >&6; }
7896 else
7897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7898 $as_echo "no" >&6; }
7899 fi
7900
7901
7902
7903 if test "$PKG_CONFIG" = "no" ; then
7904 HAVE_ALSA=no
7905 else
7906 PKG_CONFIG_MIN_VERSION=0.9.0
7907 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
7908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
7909 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
7910
7911 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5; then
7912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7913 $as_echo "yes" >&6; }
7914 succeeded=yes
7915
7916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_CFLAGS" >&5
7917 $as_echo_n "checking ALSA_CFLAGS... " >&6; }
7918 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES"|sed -e 's,///*,/,g'`
7919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_CFLAGS" >&5
7920 $as_echo "$ALSA_CFLAGS" >&6; }
7921
7922 { $as_echo "$as_me:${as_lineno-$LINENO}: checking ALSA_LIBS" >&5
7923 $as_echo_n "checking ALSA_LIBS... " >&6; }
7924 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES"|sed -e 's,///*,/,g'`
7925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ALSA_LIBS" >&5
7926 $as_echo "$ALSA_LIBS" >&6; }
7927 else
7928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7929 $as_echo "no" >&6; }
7930 ALSA_CFLAGS=""
7931 ALSA_LIBS=""
7932 ## If we have a custom action on failure, don't print errors, but
7933 ## do set a variable so people can do so.
7934 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
7935
7936 fi
7937
7938
7939
7940 else
7941 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
7942 echo "*** See http://www.freedesktop.org/software/pkgconfig"
7943 fi
7944 fi
7945
7946 if test $succeeded = yes; then
7947 HAVE_ALSA=yes
7948 else
7949 HAVE_ALSA=no
7950 fi
7951
7952 if test $HAVE_ALSA = yes; then
7953 SAVE_CFLAGS="$CFLAGS"
7954 SAVE_LDFLAGS="$LDFLAGS"
7955 CFLAGS="$ALSA_CFLAGS $CFLAGS"
7956 LDFLAGS="$ALSA_LIBS $LDFLAGS"
7957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7958 /* end confdefs.h. */
7959 #include <asoundlib.h>
7960 int
7961 main ()
7962 {
7963 snd_lib_error_set_handler (0);
7964 ;
7965 return 0;
7966 }
7967 _ACEOF
7968 if ac_fn_c_try_compile "$LINENO"; then :
7969 emacs_alsa_normal=yes
7970 else
7971 emacs_alsa_normal=no
7972 fi
7973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7974 if test "$emacs_alsa_normal" != yes; then
7975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7976 /* end confdefs.h. */
7977 #include <alsa/asoundlib.h>
7978 int
7979 main ()
7980 {
7981 snd_lib_error_set_handler (0);
7982 ;
7983 return 0;
7984 }
7985 _ACEOF
7986 if ac_fn_c_try_compile "$LINENO"; then :
7987 emacs_alsa_subdir=yes
7988 else
7989 emacs_alsa_subdir=no
7990 fi
7991 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7992 if test "$emacs_alsa_subdir" != yes; then
7993 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
7994 fi
7995 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
7996 fi
7997
7998 CFLAGS="$SAVE_CFLAGS"
7999 LDFLAGS="$SAVE_LDFLAGS"
8000 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8001 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8002
8003 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8004
8005 fi
8006
8007 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8008 case "$opsys" in
8009 gnu-linux|freebsd|netbsd)
8010
8011 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8012
8013 ;;
8014 esac
8015 fi
8016
8017
8018 fi
8019
8020 for ac_header in sys/select.h sys/time.h unistd.h utime.h \
8021 linux/version.h sys/systeminfo.h limits.h \
8022 stdio_ext.h fcntl.h coff.h pty.h sys/mman.h \
8023 sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
8024 sys/utsname.h pwd.h utmp.h dirent.h util.h
8025 do :
8026 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8027 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8028 eval as_val=\$$as_ac_Header
8029 if test "x$as_val" = x""yes; then :
8030 cat >>confdefs.h <<_ACEOF
8031 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8032 _ACEOF
8033
8034 fi
8035
8036 done
8037
8038
8039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8040 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8042 /* end confdefs.h. */
8043 #include <sys/personality.h>
8044 int
8045 main ()
8046 {
8047 personality (PER_LINUX32)
8048 ;
8049 return 0;
8050 }
8051 _ACEOF
8052 if ac_fn_c_try_compile "$LINENO"; then :
8053 emacs_cv_personality_linux32=yes
8054 else
8055 emacs_cv_personality_linux32=no
8056 fi
8057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8059 $as_echo "$emacs_cv_personality_linux32" >&6; }
8060
8061 if test $emacs_cv_personality_linux32 = yes; then
8062
8063 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8064
8065 fi
8066
8067 for ac_header in term.h
8068 do :
8069 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8070 if test "x$ac_cv_header_term_h" = x""yes; then :
8071 cat >>confdefs.h <<_ACEOF
8072 #define HAVE_TERM_H 1
8073 _ACEOF
8074
8075 fi
8076
8077 done
8078
8079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
8080 $as_echo_n "checking for ANSI C header files... " >&6; }
8081 if test "${ac_cv_header_stdc+set}" = set; then :
8082 $as_echo_n "(cached) " >&6
8083 else
8084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8085 /* end confdefs.h. */
8086 #include <stdlib.h>
8087 #include <stdarg.h>
8088 #include <string.h>
8089 #include <float.h>
8090
8091 int
8092 main ()
8093 {
8094
8095 ;
8096 return 0;
8097 }
8098 _ACEOF
8099 if ac_fn_c_try_compile "$LINENO"; then :
8100 ac_cv_header_stdc=yes
8101 else
8102 ac_cv_header_stdc=no
8103 fi
8104 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8105
8106 if test $ac_cv_header_stdc = yes; then
8107 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
8108 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8109 /* end confdefs.h. */
8110 #include <string.h>
8111
8112 _ACEOF
8113 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8114 $EGREP "memchr" >/dev/null 2>&1; then :
8115
8116 else
8117 ac_cv_header_stdc=no
8118 fi
8119 rm -f conftest*
8120
8121 fi
8122
8123 if test $ac_cv_header_stdc = yes; then
8124 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
8125 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8126 /* end confdefs.h. */
8127 #include <stdlib.h>
8128
8129 _ACEOF
8130 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8131 $EGREP "free" >/dev/null 2>&1; then :
8132
8133 else
8134 ac_cv_header_stdc=no
8135 fi
8136 rm -f conftest*
8137
8138 fi
8139
8140 if test $ac_cv_header_stdc = yes; then
8141 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
8142 if test "$cross_compiling" = yes; then :
8143 :
8144 else
8145 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8146 /* end confdefs.h. */
8147 #include <ctype.h>
8148 #include <stdlib.h>
8149 #if ((' ' & 0x0FF) == 0x020)
8150 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
8151 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
8152 #else
8153 # define ISLOWER(c) \
8154 (('a' <= (c) && (c) <= 'i') \
8155 || ('j' <= (c) && (c) <= 'r') \
8156 || ('s' <= (c) && (c) <= 'z'))
8157 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
8158 #endif
8159
8160 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
8161 int
8162 main ()
8163 {
8164 int i;
8165 for (i = 0; i < 256; i++)
8166 if (XOR (islower (i), ISLOWER (i))
8167 || toupper (i) != TOUPPER (i))
8168 return 2;
8169 return 0;
8170 }
8171 _ACEOF
8172 if ac_fn_c_try_run "$LINENO"; then :
8173
8174 else
8175 ac_cv_header_stdc=no
8176 fi
8177 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8178 conftest.$ac_objext conftest.beam conftest.$ac_ext
8179 fi
8180
8181 fi
8182 fi
8183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
8184 $as_echo "$ac_cv_header_stdc" >&6; }
8185 if test $ac_cv_header_stdc = yes; then
8186
8187 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
8188
8189 fi
8190
8191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8192 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8193 if test "${ac_cv_header_time+set}" = set; then :
8194 $as_echo_n "(cached) " >&6
8195 else
8196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8197 /* end confdefs.h. */
8198 #include <sys/types.h>
8199 #include <sys/time.h>
8200 #include <time.h>
8201
8202 int
8203 main ()
8204 {
8205 if ((struct tm *) 0)
8206 return 0;
8207 ;
8208 return 0;
8209 }
8210 _ACEOF
8211 if ac_fn_c_try_compile "$LINENO"; then :
8212 ac_cv_header_time=yes
8213 else
8214 ac_cv_header_time=no
8215 fi
8216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8217 fi
8218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8219 $as_echo "$ac_cv_header_time" >&6; }
8220 if test $ac_cv_header_time = yes; then
8221
8222 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8223
8224 fi
8225
8226 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8227 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8228 ac_have_decl=1
8229 else
8230 ac_have_decl=0
8231 fi
8232
8233 cat >>confdefs.h <<_ACEOF
8234 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8235 _ACEOF
8236
8237 if test $ac_cv_have_decl_sys_siglist != yes; then
8238 # For Tru64, at least:
8239 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8240 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8241 ac_have_decl=1
8242 else
8243 ac_have_decl=0
8244 fi
8245
8246 cat >>confdefs.h <<_ACEOF
8247 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8248 _ACEOF
8249
8250 if test $ac_cv_have_decl___sys_siglist = yes; then
8251
8252 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8253
8254 fi
8255 fi
8256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8257 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8258 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8259 $as_echo_n "(cached) " >&6
8260 else
8261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8262 /* end confdefs.h. */
8263 #include <sys/types.h>
8264 #include <sys/wait.h>
8265 #ifndef WEXITSTATUS
8266 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8267 #endif
8268 #ifndef WIFEXITED
8269 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8270 #endif
8271
8272 int
8273 main ()
8274 {
8275 int s;
8276 wait (&s);
8277 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8278 ;
8279 return 0;
8280 }
8281 _ACEOF
8282 if ac_fn_c_try_compile "$LINENO"; then :
8283 ac_cv_header_sys_wait_h=yes
8284 else
8285 ac_cv_header_sys_wait_h=no
8286 fi
8287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8288 fi
8289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8290 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8291 if test $ac_cv_header_sys_wait_h = yes; then
8292
8293 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8294
8295 fi
8296
8297
8298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
8299 $as_echo_n "checking for struct utimbuf... " >&6; }
8300 if test "${emacs_cv_struct_utimbuf+set}" = set; then :
8301 $as_echo_n "(cached) " >&6
8302 else
8303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8304 /* end confdefs.h. */
8305 #ifdef TIME_WITH_SYS_TIME
8306 #include <sys/time.h>
8307 #include <time.h>
8308 #else
8309 #ifdef HAVE_SYS_TIME_H
8310 #include <sys/time.h>
8311 #else
8312 #include <time.h>
8313 #endif
8314 #endif
8315 #ifdef HAVE_UTIME_H
8316 #include <utime.h>
8317 #endif
8318 int
8319 main ()
8320 {
8321 static struct utimbuf x; x.actime = x.modtime;
8322 ;
8323 return 0;
8324 }
8325 _ACEOF
8326 if ac_fn_c_try_compile "$LINENO"; then :
8327 emacs_cv_struct_utimbuf=yes
8328 else
8329 emacs_cv_struct_utimbuf=no
8330 fi
8331 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8332 fi
8333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
8334 $as_echo "$emacs_cv_struct_utimbuf" >&6; }
8335 if test $emacs_cv_struct_utimbuf = yes; then
8336
8337 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
8338
8339 fi
8340
8341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8342 $as_echo_n "checking for speed_t... " >&6; }
8343 if test "${emacs_cv_speed_t+set}" = set; then :
8344 $as_echo_n "(cached) " >&6
8345 else
8346 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8347 /* end confdefs.h. */
8348 #include <termios.h>
8349 int
8350 main ()
8351 {
8352 speed_t x = 1;
8353 ;
8354 return 0;
8355 }
8356 _ACEOF
8357 if ac_fn_c_try_compile "$LINENO"; then :
8358 emacs_cv_speed_t=yes
8359 else
8360 emacs_cv_speed_t=no
8361 fi
8362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8363 fi
8364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8365 $as_echo "$emacs_cv_speed_t" >&6; }
8366 if test $emacs_cv_speed_t = yes; then
8367
8368 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8369
8370 fi
8371
8372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
8373 $as_echo_n "checking for struct timeval... " >&6; }
8374 if test "${emacs_cv_struct_timeval+set}" = set; then :
8375 $as_echo_n "(cached) " >&6
8376 else
8377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8378 /* end confdefs.h. */
8379 #ifdef TIME_WITH_SYS_TIME
8380 #include <sys/time.h>
8381 #include <time.h>
8382 #else
8383 #ifdef HAVE_SYS_TIME_H
8384 #include <sys/time.h>
8385 #else
8386 #include <time.h>
8387 #endif
8388 #endif
8389 int
8390 main ()
8391 {
8392 static struct timeval x; x.tv_sec = x.tv_usec;
8393 ;
8394 return 0;
8395 }
8396 _ACEOF
8397 if ac_fn_c_try_compile "$LINENO"; then :
8398 emacs_cv_struct_timeval=yes
8399 else
8400 emacs_cv_struct_timeval=no
8401 fi
8402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8403 fi
8404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
8405 $as_echo "$emacs_cv_struct_timeval" >&6; }
8406 HAVE_TIMEVAL=$emacs_cv_struct_timeval
8407 if test $emacs_cv_struct_timeval = yes; then
8408
8409 $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
8410
8411 fi
8412
8413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8414 $as_echo_n "checking for struct exception... " >&6; }
8415 if test "${emacs_cv_struct_exception+set}" = set; then :
8416 $as_echo_n "(cached) " >&6
8417 else
8418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8419 /* end confdefs.h. */
8420 #include <math.h>
8421 int
8422 main ()
8423 {
8424 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8425 ;
8426 return 0;
8427 }
8428 _ACEOF
8429 if ac_fn_c_try_compile "$LINENO"; then :
8430 emacs_cv_struct_exception=yes
8431 else
8432 emacs_cv_struct_exception=no
8433 fi
8434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8435 fi
8436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8437 $as_echo "$emacs_cv_struct_exception" >&6; }
8438 HAVE_EXCEPTION=$emacs_cv_struct_exception
8439 if test $emacs_cv_struct_exception != yes; then
8440
8441 $as_echo "#define NO_MATHERR 1" >>confdefs.h
8442
8443 fi
8444
8445 for ac_header in net/if.h
8446 do :
8447 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8448 #if HAVE_SYS_SOCKET_H
8449 #include <sys/socket.h>
8450 #endif
8451 "
8452 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8453 cat >>confdefs.h <<_ACEOF
8454 #define HAVE_NET_IF_H 1
8455 _ACEOF
8456
8457 fi
8458
8459 done
8460
8461
8462 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
8463 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
8464 if test "${ac_cv_struct_tm+set}" = set; then :
8465 $as_echo_n "(cached) " >&6
8466 else
8467 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8468 /* end confdefs.h. */
8469 #include <sys/types.h>
8470 #include <time.h>
8471
8472 int
8473 main ()
8474 {
8475 struct tm tm;
8476 int *p = &tm.tm_sec;
8477 return !p;
8478 ;
8479 return 0;
8480 }
8481 _ACEOF
8482 if ac_fn_c_try_compile "$LINENO"; then :
8483 ac_cv_struct_tm=time.h
8484 else
8485 ac_cv_struct_tm=sys/time.h
8486 fi
8487 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8488 fi
8489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
8490 $as_echo "$ac_cv_struct_tm" >&6; }
8491 if test $ac_cv_struct_tm = sys/time.h; then
8492
8493 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
8494
8495 fi
8496
8497 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
8498 #include <$ac_cv_struct_tm>
8499
8500 "
8501 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
8502
8503 cat >>confdefs.h <<_ACEOF
8504 #define HAVE_STRUCT_TM_TM_ZONE 1
8505 _ACEOF
8506
8507
8508 fi
8509
8510 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
8511
8512 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
8513
8514 else
8515 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
8516 "
8517 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
8518 ac_have_decl=1
8519 else
8520 ac_have_decl=0
8521 fi
8522
8523 cat >>confdefs.h <<_ACEOF
8524 #define HAVE_DECL_TZNAME $ac_have_decl
8525 _ACEOF
8526
8527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
8528 $as_echo_n "checking for tzname... " >&6; }
8529 if test "${ac_cv_var_tzname+set}" = set; then :
8530 $as_echo_n "(cached) " >&6
8531 else
8532 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8533 /* end confdefs.h. */
8534 #include <time.h>
8535 #if !HAVE_DECL_TZNAME
8536 extern char *tzname[];
8537 #endif
8538
8539 int
8540 main ()
8541 {
8542 return tzname[0][0];
8543 ;
8544 return 0;
8545 }
8546 _ACEOF
8547 if ac_fn_c_try_link "$LINENO"; then :
8548 ac_cv_var_tzname=yes
8549 else
8550 ac_cv_var_tzname=no
8551 fi
8552 rm -f core conftest.err conftest.$ac_objext \
8553 conftest$ac_exeext conftest.$ac_ext
8554 fi
8555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
8556 $as_echo "$ac_cv_var_tzname" >&6; }
8557 if test $ac_cv_var_tzname = yes; then
8558
8559 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
8560
8561 fi
8562 fi
8563
8564 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
8565 "
8566 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
8567
8568 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
8569
8570 fi
8571
8572 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8573 #if HAVE_SYS_SOCKET_H
8574 #include <sys/socket.h>
8575 #endif
8576 #if HAVE_NET_IF_H
8577 #include <net/if.h>
8578 #endif
8579 "
8580 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8581
8582 cat >>confdefs.h <<_ACEOF
8583 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8584 _ACEOF
8585
8586
8587 fi
8588 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8589 #if HAVE_SYS_SOCKET_H
8590 #include <sys/socket.h>
8591 #endif
8592 #if HAVE_NET_IF_H
8593 #include <net/if.h>
8594 #endif
8595 "
8596 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8597
8598 cat >>confdefs.h <<_ACEOF
8599 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8600 _ACEOF
8601
8602
8603 fi
8604 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8605 #if HAVE_SYS_SOCKET_H
8606 #include <sys/socket.h>
8607 #endif
8608 #if HAVE_NET_IF_H
8609 #include <net/if.h>
8610 #endif
8611 "
8612 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
8613
8614 cat >>confdefs.h <<_ACEOF
8615 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8616 _ACEOF
8617
8618
8619 fi
8620 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8621 #if HAVE_SYS_SOCKET_H
8622 #include <sys/socket.h>
8623 #endif
8624 #if HAVE_NET_IF_H
8625 #include <net/if.h>
8626 #endif
8627 "
8628 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
8629
8630 cat >>confdefs.h <<_ACEOF
8631 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8632 _ACEOF
8633
8634
8635 fi
8636 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8637 #if HAVE_SYS_SOCKET_H
8638 #include <sys/socket.h>
8639 #endif
8640 #if HAVE_NET_IF_H
8641 #include <net/if.h>
8642 #endif
8643 "
8644 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
8645
8646 cat >>confdefs.h <<_ACEOF
8647 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8648 _ACEOF
8649
8650
8651 fi
8652
8653
8654
8655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
8656 $as_echo_n "checking for function prototypes... " >&6; }
8657 if test "$ac_cv_prog_cc_c89" != no; then
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8659 $as_echo "yes" >&6; }
8660
8661 $as_echo "#define PROTOTYPES 1" >>confdefs.h
8662
8663
8664 $as_echo "#define __PROTOTYPES 1" >>confdefs.h
8665
8666 else
8667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8668 $as_echo "no" >&6; }
8669 fi
8670
8671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
8672 $as_echo_n "checking for working volatile... " >&6; }
8673 if test "${ac_cv_c_volatile+set}" = set; then :
8674 $as_echo_n "(cached) " >&6
8675 else
8676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8677 /* end confdefs.h. */
8678
8679 int
8680 main ()
8681 {
8682
8683 volatile int x;
8684 int * volatile y = (int *) 0;
8685 return !x && !y;
8686 ;
8687 return 0;
8688 }
8689 _ACEOF
8690 if ac_fn_c_try_compile "$LINENO"; then :
8691 ac_cv_c_volatile=yes
8692 else
8693 ac_cv_c_volatile=no
8694 fi
8695 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8696 fi
8697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
8698 $as_echo "$ac_cv_c_volatile" >&6; }
8699 if test $ac_cv_c_volatile = no; then
8700
8701 $as_echo "#define volatile /**/" >>confdefs.h
8702
8703 fi
8704
8705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
8706 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
8707 if test "${ac_cv_c_const+set}" = set; then :
8708 $as_echo_n "(cached) " >&6
8709 else
8710 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8711 /* end confdefs.h. */
8712
8713 int
8714 main ()
8715 {
8716 /* FIXME: Include the comments suggested by Paul. */
8717 #ifndef __cplusplus
8718 /* Ultrix mips cc rejects this. */
8719 typedef int charset[2];
8720 const charset cs;
8721 /* SunOS 4.1.1 cc rejects this. */
8722 char const *const *pcpcc;
8723 char **ppc;
8724 /* NEC SVR4.0.2 mips cc rejects this. */
8725 struct point {int x, y;};
8726 static struct point const zero = {0,0};
8727 /* AIX XL C 1.02.0.0 rejects this.
8728 It does not let you subtract one const X* pointer from another in
8729 an arm of an if-expression whose if-part is not a constant
8730 expression */
8731 const char *g = "string";
8732 pcpcc = &g + (g ? g-g : 0);
8733 /* HPUX 7.0 cc rejects these. */
8734 ++pcpcc;
8735 ppc = (char**) pcpcc;
8736 pcpcc = (char const *const *) ppc;
8737 { /* SCO 3.2v4 cc rejects this. */
8738 char *t;
8739 char const *s = 0 ? (char *) 0 : (char const *) 0;
8740
8741 *t++ = 0;
8742 if (s) return 0;
8743 }
8744 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
8745 int x[] = {25, 17};
8746 const int *foo = &x[0];
8747 ++foo;
8748 }
8749 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
8750 typedef const int *iptr;
8751 iptr p = 0;
8752 ++p;
8753 }
8754 { /* AIX XL C 1.02.0.0 rejects this saying
8755 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
8756 struct s { int j; const int *ap[3]; };
8757 struct s *b; b->j = 5;
8758 }
8759 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
8760 const int foo = 10;
8761 if (!foo) return 0;
8762 }
8763 return !cs[0] && !zero.x;
8764 #endif
8765
8766 ;
8767 return 0;
8768 }
8769 _ACEOF
8770 if ac_fn_c_try_compile "$LINENO"; then :
8771 ac_cv_c_const=yes
8772 else
8773 ac_cv_c_const=no
8774 fi
8775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8776 fi
8777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
8778 $as_echo "$ac_cv_c_const" >&6; }
8779 if test $ac_cv_c_const = no; then
8780
8781 $as_echo "#define const /**/" >>confdefs.h
8782
8783 fi
8784
8785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
8786 $as_echo_n "checking for void * support... " >&6; }
8787 if test "${emacs_cv_void_star+set}" = set; then :
8788 $as_echo_n "(cached) " >&6
8789 else
8790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8791 /* end confdefs.h. */
8792
8793 int
8794 main ()
8795 {
8796 void * foo;
8797 ;
8798 return 0;
8799 }
8800 _ACEOF
8801 if ac_fn_c_try_compile "$LINENO"; then :
8802 emacs_cv_void_star=yes
8803 else
8804 emacs_cv_void_star=no
8805 fi
8806 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8807 fi
8808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
8809 $as_echo "$emacs_cv_void_star" >&6; }
8810 if test $emacs_cv_void_star = yes; then
8811 $as_echo "#define POINTER_TYPE void" >>confdefs.h
8812
8813 else
8814 $as_echo "#define POINTER_TYPE char" >>confdefs.h
8815
8816 fi
8817
8818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
8819 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
8820 if test "${ac_cv_c_bigendian+set}" = set; then :
8821 $as_echo_n "(cached) " >&6
8822 else
8823 ac_cv_c_bigendian=unknown
8824 # See if we're dealing with a universal compiler.
8825 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8826 /* end confdefs.h. */
8827 #ifndef __APPLE_CC__
8828 not a universal capable compiler
8829 #endif
8830 typedef int dummy;
8831
8832 _ACEOF
8833 if ac_fn_c_try_compile "$LINENO"; then :
8834
8835 # Check for potential -arch flags. It is not universal unless
8836 # there are at least two -arch flags with different values.
8837 ac_arch=
8838 ac_prev=
8839 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
8840 if test -n "$ac_prev"; then
8841 case $ac_word in
8842 i?86 | x86_64 | ppc | ppc64)
8843 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
8844 ac_arch=$ac_word
8845 else
8846 ac_cv_c_bigendian=universal
8847 break
8848 fi
8849 ;;
8850 esac
8851 ac_prev=
8852 elif test "x$ac_word" = "x-arch"; then
8853 ac_prev=arch
8854 fi
8855 done
8856 fi
8857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8858 if test $ac_cv_c_bigendian = unknown; then
8859 # See if sys/param.h defines the BYTE_ORDER macro.
8860 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8861 /* end confdefs.h. */
8862 #include <sys/types.h>
8863 #include <sys/param.h>
8864
8865 int
8866 main ()
8867 {
8868 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
8869 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
8870 && LITTLE_ENDIAN)
8871 bogus endian macros
8872 #endif
8873
8874 ;
8875 return 0;
8876 }
8877 _ACEOF
8878 if ac_fn_c_try_compile "$LINENO"; then :
8879 # It does; now see whether it defined to BIG_ENDIAN or not.
8880 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8881 /* end confdefs.h. */
8882 #include <sys/types.h>
8883 #include <sys/param.h>
8884
8885 int
8886 main ()
8887 {
8888 #if BYTE_ORDER != BIG_ENDIAN
8889 not big endian
8890 #endif
8891
8892 ;
8893 return 0;
8894 }
8895 _ACEOF
8896 if ac_fn_c_try_compile "$LINENO"; then :
8897 ac_cv_c_bigendian=yes
8898 else
8899 ac_cv_c_bigendian=no
8900 fi
8901 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8902 fi
8903 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8904 fi
8905 if test $ac_cv_c_bigendian = unknown; then
8906 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
8907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8908 /* end confdefs.h. */
8909 #include <limits.h>
8910
8911 int
8912 main ()
8913 {
8914 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
8915 bogus endian macros
8916 #endif
8917
8918 ;
8919 return 0;
8920 }
8921 _ACEOF
8922 if ac_fn_c_try_compile "$LINENO"; then :
8923 # It does; now see whether it defined to _BIG_ENDIAN or not.
8924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8925 /* end confdefs.h. */
8926 #include <limits.h>
8927
8928 int
8929 main ()
8930 {
8931 #ifndef _BIG_ENDIAN
8932 not big endian
8933 #endif
8934
8935 ;
8936 return 0;
8937 }
8938 _ACEOF
8939 if ac_fn_c_try_compile "$LINENO"; then :
8940 ac_cv_c_bigendian=yes
8941 else
8942 ac_cv_c_bigendian=no
8943 fi
8944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8945 fi
8946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8947 fi
8948 if test $ac_cv_c_bigendian = unknown; then
8949 # Compile a test program.
8950 if test "$cross_compiling" = yes; then :
8951 # Try to guess by grepping values from an object file.
8952 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8953 /* end confdefs.h. */
8954 short int ascii_mm[] =
8955 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
8956 short int ascii_ii[] =
8957 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
8958 int use_ascii (int i) {
8959 return ascii_mm[i] + ascii_ii[i];
8960 }
8961 short int ebcdic_ii[] =
8962 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
8963 short int ebcdic_mm[] =
8964 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
8965 int use_ebcdic (int i) {
8966 return ebcdic_mm[i] + ebcdic_ii[i];
8967 }
8968 extern int foo;
8969
8970 int
8971 main ()
8972 {
8973 return use_ascii (foo) == use_ebcdic (foo);
8974 ;
8975 return 0;
8976 }
8977 _ACEOF
8978 if ac_fn_c_try_compile "$LINENO"; then :
8979 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
8980 ac_cv_c_bigendian=yes
8981 fi
8982 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
8983 if test "$ac_cv_c_bigendian" = unknown; then
8984 ac_cv_c_bigendian=no
8985 else
8986 # finding both strings is unlikely to happen, but who knows?
8987 ac_cv_c_bigendian=unknown
8988 fi
8989 fi
8990 fi
8991 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8992 else
8993 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8994 /* end confdefs.h. */
8995 $ac_includes_default
8996 int
8997 main ()
8998 {
8999
9000 /* Are we little or big endian? From Harbison&Steele. */
9001 union
9002 {
9003 long int l;
9004 char c[sizeof (long int)];
9005 } u;
9006 u.l = 1;
9007 return u.c[sizeof (long int) - 1] == 1;
9008
9009 ;
9010 return 0;
9011 }
9012 _ACEOF
9013 if ac_fn_c_try_run "$LINENO"; then :
9014 ac_cv_c_bigendian=no
9015 else
9016 ac_cv_c_bigendian=yes
9017 fi
9018 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9019 conftest.$ac_objext conftest.beam conftest.$ac_ext
9020 fi
9021
9022 fi
9023 fi
9024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9025 $as_echo "$ac_cv_c_bigendian" >&6; }
9026 case $ac_cv_c_bigendian in #(
9027 yes)
9028 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9029 ;; #(
9030 no)
9031 ;; #(
9032 universal)
9033
9034 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9035
9036 ;; #(
9037 *)
9038 as_fn_error "unknown endianness
9039 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9040 esac
9041
9042
9043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__ ((__aligned__ (expr)))" >&5
9044 $as_echo_n "checking for __attribute__ ((__aligned__ (expr)))... " >&6; }
9045 if test "${emacs_cv_attribute_aligned+set}" = set; then :
9046 $as_echo_n "(cached) " >&6
9047 else
9048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9049 /* end confdefs.h. */
9050 char __attribute__ ((__aligned__ (1 << 3))) c;
9051 int
9052 main ()
9053 {
9054
9055 ;
9056 return 0;
9057 }
9058 _ACEOF
9059 if ac_fn_c_try_compile "$LINENO"; then :
9060 emacs_cv_attribute_aligned=yes
9061 else
9062 emacs_cv_attribute_aligned=no
9063 fi
9064 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9065 fi
9066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_attribute_aligned" >&5
9067 $as_echo "$emacs_cv_attribute_aligned" >&6; }
9068 if test $emacs_cv_attribute_aligned = yes; then
9069
9070 $as_echo "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h
9071
9072 fi
9073
9074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
9075 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
9076 set x ${MAKE-make}
9077 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
9078 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
9079 $as_echo_n "(cached) " >&6
9080 else
9081 cat >conftest.make <<\_ACEOF
9082 SHELL = /bin/sh
9083 all:
9084 @echo '@@@%%%=$(MAKE)=@@@%%%'
9085 _ACEOF
9086 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9087 case `${MAKE-make} -f conftest.make 2>/dev/null` in
9088 *@@@%%%=?*=@@@%%%*)
9089 eval ac_cv_prog_make_${ac_make}_set=yes;;
9090 *)
9091 eval ac_cv_prog_make_${ac_make}_set=no;;
9092 esac
9093 rm -f conftest.make
9094 fi
9095 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
9096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9097 $as_echo "yes" >&6; }
9098 SET_MAKE=
9099 else
9100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9101 $as_echo "no" >&6; }
9102 SET_MAKE="MAKE=${MAKE-make}"
9103 fi
9104
9105
9106 DEPFLAGS=
9107 MKDEPDIR=":"
9108 deps_frag=deps.mk
9109 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9111 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9112 HAVE_GNU_MAKE=no
9113 testval=`make --version 2>/dev/null | grep 'GNU Make'`
9114 if test "x$testval" != x; then
9115 HAVE_GNU_MAKE=yes
9116 else
9117 ac_enable_autodepend=no
9118 fi
9119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9120 $as_echo "$HAVE_GNU_MAKE" >&6; }
9121 if test $HAVE_GNU_MAKE = yes; then
9122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9123 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9124 SAVE_CFLAGS="$CFLAGS"
9125 CFLAGS="$CFLAGS -MMD -MF deps.d"
9126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9127 /* end confdefs.h. */
9128
9129 int
9130 main ()
9131 {
9132
9133 ;
9134 return 0;
9135 }
9136 _ACEOF
9137 if ac_fn_c_try_compile "$LINENO"; then :
9138
9139 else
9140 ac_enable_autodepend=no
9141 fi
9142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9143 CFLAGS="$SAVE_CFLAGS"
9144 test -f deps.d || ac_enable_autodepend=no
9145 rm -rf deps.d
9146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9147 $as_echo "$ac_enable_autodepend" >&6; }
9148 fi
9149 if test $ac_enable_autodepend = yes; then
9150 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d'
9151 ## In parallel builds, another make might create depdir between
9152 ## the first test and mkdir, so stick another test on the end.
9153 ## Or use install-sh -d? mkdir -p is not portable.
9154 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
9155 deps_frag=autodeps.mk
9156 fi
9157 fi
9158 deps_frag=$srcdir/src/$deps_frag
9159
9160
9161
9162
9163
9164 lisp_frag=$srcdir/src/lisp.mk
9165
9166
9167
9168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9169 $as_echo_n "checking for long file names... " >&6; }
9170 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9171 $as_echo_n "(cached) " >&6
9172 else
9173 ac_cv_sys_long_file_names=yes
9174 # Test for long file names in all the places we know might matter:
9175 # . the current directory, where building will happen
9176 # $prefix/lib where we will be installing things
9177 # $exec_prefix/lib likewise
9178 # $TMPDIR if set, where it might want to write temporary files
9179 # /tmp where it might want to write temporary files
9180 # /var/tmp likewise
9181 # /usr/tmp likewise
9182 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9183 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9184 # in the usual case where exec_prefix is '${prefix}'.
9185 case $ac_dir in #(
9186 . | /* | ?:[\\/]*) ;; #(
9187 *) continue;;
9188 esac
9189 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9190 ac_xdir=$ac_dir/cf$$
9191 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9192 ac_tf1=$ac_xdir/conftest9012345
9193 ac_tf2=$ac_xdir/conftest9012346
9194 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9195 ac_cv_sys_long_file_names=no
9196 rm -f -r "$ac_xdir" 2>/dev/null
9197 test $ac_cv_sys_long_file_names = no && break
9198 done
9199 fi
9200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9201 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9202 if test $ac_cv_sys_long_file_names = yes; then
9203
9204 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9205
9206 fi
9207
9208
9209 #### Choose a window system.
9210
9211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9212 $as_echo_n "checking for X... " >&6; }
9213
9214
9215 # Check whether --with-x was given.
9216 if test "${with_x+set}" = set; then :
9217 withval=$with_x;
9218 fi
9219
9220 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9221 if test "x$with_x" = xno; then
9222 # The user explicitly disabled X.
9223 have_x=disabled
9224 else
9225 case $x_includes,$x_libraries in #(
9226 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9227 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9228 $as_echo_n "(cached) " >&6
9229 else
9230 # One or both of the vars are not set, and there is no cached value.
9231 ac_x_includes=no ac_x_libraries=no
9232 rm -f -r conftest.dir
9233 if mkdir conftest.dir; then
9234 cd conftest.dir
9235 cat >Imakefile <<'_ACEOF'
9236 incroot:
9237 @echo incroot='${INCROOT}'
9238 usrlibdir:
9239 @echo usrlibdir='${USRLIBDIR}'
9240 libdir:
9241 @echo libdir='${LIBDIR}'
9242 _ACEOF
9243 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9244 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9245 for ac_var in incroot usrlibdir libdir; do
9246 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9247 done
9248 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9249 for ac_extension in a so sl dylib la dll; do
9250 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9251 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9252 ac_im_usrlibdir=$ac_im_libdir; break
9253 fi
9254 done
9255 # Screen out bogus values from the imake configuration. They are
9256 # bogus both because they are the default anyway, and because
9257 # using them would break gcc on systems where it needs fixed includes.
9258 case $ac_im_incroot in
9259 /usr/include) ac_x_includes= ;;
9260 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9261 esac
9262 case $ac_im_usrlibdir in
9263 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9264 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9265 esac
9266 fi
9267 cd ..
9268 rm -f -r conftest.dir
9269 fi
9270
9271 # Standard set of common directories for X headers.
9272 # Check X11 before X11Rn because it is often a symlink to the current release.
9273 ac_x_header_dirs='
9274 /usr/X11/include
9275 /usr/X11R7/include
9276 /usr/X11R6/include
9277 /usr/X11R5/include
9278 /usr/X11R4/include
9279
9280 /usr/include/X11
9281 /usr/include/X11R7
9282 /usr/include/X11R6
9283 /usr/include/X11R5
9284 /usr/include/X11R4
9285
9286 /usr/local/X11/include
9287 /usr/local/X11R7/include
9288 /usr/local/X11R6/include
9289 /usr/local/X11R5/include
9290 /usr/local/X11R4/include
9291
9292 /usr/local/include/X11
9293 /usr/local/include/X11R7
9294 /usr/local/include/X11R6
9295 /usr/local/include/X11R5
9296 /usr/local/include/X11R4
9297
9298 /usr/X386/include
9299 /usr/x386/include
9300 /usr/XFree86/include/X11
9301
9302 /usr/include
9303 /usr/local/include
9304 /usr/unsupported/include
9305 /usr/athena/include
9306 /usr/local/x11r5/include
9307 /usr/lpp/Xamples/include
9308
9309 /usr/openwin/include
9310 /usr/openwin/share/include'
9311
9312 if test "$ac_x_includes" = no; then
9313 # Guess where to find include files, by looking for Xlib.h.
9314 # First, try using that file with no special directory specified.
9315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9316 /* end confdefs.h. */
9317 #include <X11/Xlib.h>
9318 _ACEOF
9319 if ac_fn_c_try_cpp "$LINENO"; then :
9320 # We can compile using X headers with no special include directory.
9321 ac_x_includes=
9322 else
9323 for ac_dir in $ac_x_header_dirs; do
9324 if test -r "$ac_dir/X11/Xlib.h"; then
9325 ac_x_includes=$ac_dir
9326 break
9327 fi
9328 done
9329 fi
9330 rm -f conftest.err conftest.$ac_ext
9331 fi # $ac_x_includes = no
9332
9333 if test "$ac_x_libraries" = no; then
9334 # Check for the libraries.
9335 # See if we find them without any special options.
9336 # Don't add to $LIBS permanently.
9337 ac_save_LIBS=$LIBS
9338 LIBS="-lX11 $LIBS"
9339 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9340 /* end confdefs.h. */
9341 #include <X11/Xlib.h>
9342 int
9343 main ()
9344 {
9345 XrmInitialize ()
9346 ;
9347 return 0;
9348 }
9349 _ACEOF
9350 if ac_fn_c_try_link "$LINENO"; then :
9351 LIBS=$ac_save_LIBS
9352 # We can link X programs with no special library path.
9353 ac_x_libraries=
9354 else
9355 LIBS=$ac_save_LIBS
9356 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9357 do
9358 # Don't even attempt the hair of trying to link an X program!
9359 for ac_extension in a so sl dylib la dll; do
9360 if test -r "$ac_dir/libX11.$ac_extension"; then
9361 ac_x_libraries=$ac_dir
9362 break 2
9363 fi
9364 done
9365 done
9366 fi
9367 rm -f core conftest.err conftest.$ac_objext \
9368 conftest$ac_exeext conftest.$ac_ext
9369 fi # $ac_x_libraries = no
9370
9371 case $ac_x_includes,$ac_x_libraries in #(
9372 no,* | *,no | *\'*)
9373 # Didn't find X, or a directory has "'" in its name.
9374 ac_cv_have_x="have_x=no";; #(
9375 *)
9376 # Record where we found X for the cache.
9377 ac_cv_have_x="have_x=yes\
9378 ac_x_includes='$ac_x_includes'\
9379 ac_x_libraries='$ac_x_libraries'"
9380 esac
9381 fi
9382 ;; #(
9383 *) have_x=yes;;
9384 esac
9385 eval "$ac_cv_have_x"
9386 fi # $with_x != no
9387
9388 if test "$have_x" != yes; then
9389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9390 $as_echo "$have_x" >&6; }
9391 no_x=yes
9392 else
9393 # If each of the values was on the command line, it overrides each guess.
9394 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9395 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9396 # Update the cache value to reflect the command line values.
9397 ac_cv_have_x="have_x=yes\
9398 ac_x_includes='$x_includes'\
9399 ac_x_libraries='$x_libraries'"
9400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9401 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9402 fi
9403
9404 if test "$no_x" = yes; then
9405 window_system=none
9406 else
9407 window_system=x11
9408 fi
9409
9410 ## Workaround for bug in autoconf <= 2.62.
9411 ## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
9412 ## No need to do anything special for these standard directories.
9413 if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
9414
9415 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
9416
9417 fi
9418
9419 LD_SWITCH_X_SITE_AUX=
9420 LD_SWITCH_X_SITE_AUX_RPATH=
9421 if test "${x_libraries}" != NONE; then
9422 if test -n "${x_libraries}"; then
9423 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9424 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
9425 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
9426 fi
9427 x_default_search_path=""
9428 x_search_path=${x_libraries}
9429 if test -z "${x_search_path}"; then
9430 x_search_path=/usr/lib
9431 fi
9432 for x_library in `echo ${x_search_path}: | \
9433 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9434 x_search_path="\
9435 ${x_library}/X11/%L/%T/%N%C%S:\
9436 ${x_library}/X11/%l/%T/%N%C%S:\
9437 ${x_library}/X11/%T/%N%C%S:\
9438 ${x_library}/X11/%L/%T/%N%S:\
9439 ${x_library}/X11/%l/%T/%N%S:\
9440 ${x_library}/X11/%T/%N%S"
9441 if test x"${x_default_search_path}" = x; then
9442 x_default_search_path=${x_search_path}
9443 else
9444 x_default_search_path="${x_search_path}:${x_default_search_path}"
9445 fi
9446 done
9447 fi
9448
9449
9450
9451 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9452 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
9453 fi
9454
9455 if test x"${x_includes}" = x; then
9456 bitmapdir=/usr/include/X11/bitmaps
9457 else
9458 # accumulate include directories that have X11 bitmap subdirectories
9459 bmd_acc="dummyval"
9460 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9461 if test -d "${bmd}/X11/bitmaps"; then
9462 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9463 fi
9464 if test -d "${bmd}/bitmaps"; then
9465 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9466 fi
9467 done
9468 if test ${bmd_acc} != "dummyval"; then
9469 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9470 fi
9471 fi
9472
9473 HAVE_NS=no
9474 NS_IMPL_COCOA=no
9475 NS_IMPL_GNUSTEP=no
9476 tmp_CPPFLAGS="$CPPFLAGS"
9477 tmp_CFLAGS="$CFLAGS"
9478 CPPFLAGS="$CPPFLAGS -x objective-c"
9479 CFLAGS="$CFLAGS -x objective-c"
9480 TEMACS_LDFLAGS2="\${LDFLAGS}"
9481 if test "${with_ns}" != no; then
9482 if test "${opsys}" = darwin; then
9483 NS_IMPL_COCOA=yes
9484 ns_appdir=`pwd`/nextstep/Emacs.app
9485 ns_appbindir=${ns_appdir}/Contents/MacOS/
9486 ns_appresdir=${ns_appdir}/Contents/Resources
9487 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9488 elif test -f $GNUSTEP_CONFIG_FILE; then
9489 NS_IMPL_GNUSTEP=yes
9490 ns_appdir=`pwd`/nextstep/Emacs.app
9491 ns_appbindir=${ns_appdir}/
9492 ns_appresdir=${ns_appdir}/Resources
9493 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9494 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9495 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9496 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9497 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9498 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9499 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9500 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9501 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9502 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9503 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9504 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9505 LIB_STANDARD=
9506 START_FILES=
9507 TEMACS_LDFLAGS2=
9508 fi
9509 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9510 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9511 HAVE_NS=yes
9512 else
9513 as_fn_error "\`--with-ns' was specified, but the include
9514 files are missing or cannot be compiled." "$LINENO" 5
9515 fi
9516
9517
9518 NS_HAVE_NSINTEGER=yes
9519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9520 /* end confdefs.h. */
9521 #include <Foundation/NSObjCRuntime.h>
9522 int
9523 main ()
9524 {
9525 NSInteger i;
9526 ;
9527 return 0;
9528 }
9529 _ACEOF
9530 if ac_fn_c_try_compile "$LINENO"; then :
9531 ns_have_nsinteger=yes
9532 else
9533 ns_have_nsinteger=no
9534 fi
9535 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9536 if test $ns_have_nsinteger = no; then
9537 NS_HAVE_NSINTEGER=no
9538 fi
9539 fi
9540
9541
9542 ns_frag=/dev/null
9543 NS_OBJ=
9544 NS_OBJC_OBJ=
9545 if test "${HAVE_NS}" = yes; then
9546 window_system=nextstep
9547 with_xft=no
9548 # set up packaging dirs
9549 exec_prefix=${ns_appbindir}
9550 libexecdir=${ns_appbindir}/libexec
9551 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9552 prefix=${ns_appresdir}
9553 fi
9554 ns_frag=$srcdir/src/ns.mk
9555 NS_OBJ="fontset.o fringe.o image.o"
9556 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9557 fi
9558 CFLAGS="$tmp_CFLAGS"
9559 CPPFLAGS="$tmp_CPPFLAGS"
9560
9561
9562
9563
9564
9565 case "${window_system}" in
9566 x11 )
9567 HAVE_X_WINDOWS=yes
9568 HAVE_X11=yes
9569 case "${with_x_toolkit}" in
9570 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9571 motif ) USE_X_TOOLKIT=MOTIF ;;
9572 gtk ) with_gtk=yes
9573 USE_X_TOOLKIT=none ;;
9574 gtk3 ) with_gtk3=yes
9575 USE_X_TOOLKIT=none ;;
9576 no ) USE_X_TOOLKIT=none ;;
9577 * ) USE_X_TOOLKIT=maybe ;;
9578 esac
9579 ;;
9580 nextstep | none )
9581 HAVE_X_WINDOWS=no
9582 HAVE_X11=no
9583 USE_X_TOOLKIT=none
9584 ;;
9585 esac
9586
9587 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9588 # Extract the first word of "X", so it can be a program name with args.
9589 set dummy X; ac_word=$2
9590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9591 $as_echo_n "checking for $ac_word... " >&6; }
9592 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9593 $as_echo_n "(cached) " >&6
9594 else
9595 if test -n "$HAVE_XSERVER"; then
9596 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9597 else
9598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9599 for as_dir in $PATH
9600 do
9601 IFS=$as_save_IFS
9602 test -z "$as_dir" && as_dir=.
9603 for ac_exec_ext in '' $ac_executable_extensions; do
9604 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9605 ac_cv_prog_HAVE_XSERVER="true"
9606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9607 break 2
9608 fi
9609 done
9610 done
9611 IFS=$as_save_IFS
9612
9613 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9614 fi
9615 fi
9616 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9617 if test -n "$HAVE_XSERVER"; then
9618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9619 $as_echo "$HAVE_XSERVER" >&6; }
9620 else
9621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9622 $as_echo "no" >&6; }
9623 fi
9624
9625
9626 if test "$HAVE_XSERVER" = true ||
9627 test -n "$DISPLAY" ||
9628 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9629 as_fn_error "You seem to be running X, but no X development libraries
9630 were found. You should install the relevant development files for X
9631 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9632 sure you have development files for image handling, i.e.
9633 tiff, gif, jpeg, png and xpm.
9634 If you are sure you want Emacs compiled without X window support, pass
9635 --without-x
9636 to configure." "$LINENO" 5
9637 fi
9638 fi
9639
9640 ### If we're using X11, we should use the X menu package.
9641 HAVE_MENUS=no
9642 case ${HAVE_X11} in
9643 yes ) HAVE_MENUS=yes ;;
9644 esac
9645
9646 # Do the opsystem or machine files prohibit the use of the GNU malloc?
9647 # Assume not, until told otherwise.
9648 GNU_MALLOC=yes
9649 doug_lea_malloc=yes
9650 ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
9651 if test "x$ac_cv_func_malloc_get_state" = x""yes; then :
9652
9653 else
9654 doug_lea_malloc=no
9655 fi
9656
9657 ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
9658 if test "x$ac_cv_func_malloc_set_state" = x""yes; then :
9659
9660 else
9661 doug_lea_malloc=no
9662 fi
9663
9664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
9665 $as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
9666 if test "${emacs_cv_var___after_morecore_hook+set}" = set; then :
9667 $as_echo_n "(cached) " >&6
9668 else
9669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9670 /* end confdefs.h. */
9671 extern void (* __after_morecore_hook)();
9672 int
9673 main ()
9674 {
9675 __after_morecore_hook = 0
9676 ;
9677 return 0;
9678 }
9679 _ACEOF
9680 if ac_fn_c_try_link "$LINENO"; then :
9681 emacs_cv_var___after_morecore_hook=yes
9682 else
9683 emacs_cv_var___after_morecore_hook=no
9684 fi
9685 rm -f core conftest.err conftest.$ac_objext \
9686 conftest$ac_exeext conftest.$ac_ext
9687 fi
9688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
9689 $as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
9690 if test $emacs_cv_var___after_morecore_hook = no; then
9691 doug_lea_malloc=no
9692 fi
9693
9694
9695 system_malloc=no
9696 case "$opsys" in
9697 ## darwin ld insists on the use of malloc routines in the System framework.
9698 darwin|sol2-10) system_malloc=yes ;;
9699 esac
9700
9701 if test "${system_malloc}" = "yes"; then
9702
9703 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9704
9705 GNU_MALLOC=no
9706 GNU_MALLOC_reason="
9707 (The GNU allocators don't work with this system configuration.)"
9708 GMALLOC_OBJ=
9709 VMLIMIT_OBJ=
9710 else
9711 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
9712 VMLIMIT_OBJ=vm-limit.o
9713 fi
9714
9715
9716
9717 if test "$doug_lea_malloc" = "yes" ; then
9718 if test "$GNU_MALLOC" = yes ; then
9719 GNU_MALLOC_reason="
9720 (Using Doug Lea's new malloc from the GNU C Library.)"
9721 fi
9722
9723 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
9724
9725
9726 ## Use mmap directly for allocating larger buffers.
9727 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
9728 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
9729 ## Does the AC_FUNC_MMAP test below make this check unecessary?
9730 case "$opsys" in
9731 gnu*) REL_ALLOC=no ;;
9732 esac
9733 fi
9734
9735 if test x"${REL_ALLOC}" = x; then
9736 REL_ALLOC=${GNU_MALLOC}
9737 fi
9738
9739 use_mmap_for_buffers=no
9740 case "$opsys" in
9741 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
9742 esac
9743
9744
9745
9746
9747 for ac_header in $ac_header_list
9748 do :
9749 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9750 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
9751 "
9752 eval as_val=\$$as_ac_Header
9753 if test "x$as_val" = x""yes; then :
9754 cat >>confdefs.h <<_ACEOF
9755 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9756 _ACEOF
9757
9758 fi
9759
9760 done
9761
9762
9763
9764
9765
9766
9767
9768
9769 for ac_func in getpagesize
9770 do :
9771 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9772 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9773 cat >>confdefs.h <<_ACEOF
9774 #define HAVE_GETPAGESIZE 1
9775 _ACEOF
9776
9777 fi
9778 done
9779
9780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
9781 $as_echo_n "checking for working mmap... " >&6; }
9782 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
9783 $as_echo_n "(cached) " >&6
9784 else
9785 if test "$cross_compiling" = yes; then :
9786 ac_cv_func_mmap_fixed_mapped=no
9787 else
9788 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9789 /* end confdefs.h. */
9790 $ac_includes_default
9791 /* malloc might have been renamed as rpl_malloc. */
9792 #undef malloc
9793
9794 /* Thanks to Mike Haertel and Jim Avera for this test.
9795 Here is a matrix of mmap possibilities:
9796 mmap private not fixed
9797 mmap private fixed at somewhere currently unmapped
9798 mmap private fixed at somewhere already mapped
9799 mmap shared not fixed
9800 mmap shared fixed at somewhere currently unmapped
9801 mmap shared fixed at somewhere already mapped
9802 For private mappings, we should verify that changes cannot be read()
9803 back from the file, nor mmap's back from the file at a different
9804 address. (There have been systems where private was not correctly
9805 implemented like the infamous i386 svr4.0, and systems where the
9806 VM page cache was not coherent with the file system buffer cache
9807 like early versions of FreeBSD and possibly contemporary NetBSD.)
9808 For shared mappings, we should conversely verify that changes get
9809 propagated back to all the places they're supposed to be.
9810
9811 Grep wants private fixed already mapped.
9812 The main things grep needs to know about mmap are:
9813 * does it exist and is it safe to write into the mmap'd area
9814 * how to use it (BSD variants) */
9815
9816 #include <fcntl.h>
9817 #include <sys/mman.h>
9818
9819 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
9820 char *malloc ();
9821 #endif
9822
9823 /* This mess was copied from the GNU getpagesize.h. */
9824 #ifndef HAVE_GETPAGESIZE
9825 # ifdef _SC_PAGESIZE
9826 # define getpagesize() sysconf(_SC_PAGESIZE)
9827 # else /* no _SC_PAGESIZE */
9828 # ifdef HAVE_SYS_PARAM_H
9829 # include <sys/param.h>
9830 # ifdef EXEC_PAGESIZE
9831 # define getpagesize() EXEC_PAGESIZE
9832 # else /* no EXEC_PAGESIZE */
9833 # ifdef NBPG
9834 # define getpagesize() NBPG * CLSIZE
9835 # ifndef CLSIZE
9836 # define CLSIZE 1
9837 # endif /* no CLSIZE */
9838 # else /* no NBPG */
9839 # ifdef NBPC
9840 # define getpagesize() NBPC
9841 # else /* no NBPC */
9842 # ifdef PAGESIZE
9843 # define getpagesize() PAGESIZE
9844 # endif /* PAGESIZE */
9845 # endif /* no NBPC */
9846 # endif /* no NBPG */
9847 # endif /* no EXEC_PAGESIZE */
9848 # else /* no HAVE_SYS_PARAM_H */
9849 # define getpagesize() 8192 /* punt totally */
9850 # endif /* no HAVE_SYS_PARAM_H */
9851 # endif /* no _SC_PAGESIZE */
9852
9853 #endif /* no HAVE_GETPAGESIZE */
9854
9855 int
9856 main ()
9857 {
9858 char *data, *data2, *data3;
9859 const char *cdata2;
9860 int i, pagesize;
9861 int fd, fd2;
9862
9863 pagesize = getpagesize ();
9864
9865 /* First, make a file with some known garbage in it. */
9866 data = (char *) malloc (pagesize);
9867 if (!data)
9868 return 1;
9869 for (i = 0; i < pagesize; ++i)
9870 *(data + i) = rand ();
9871 umask (0);
9872 fd = creat ("conftest.mmap", 0600);
9873 if (fd < 0)
9874 return 2;
9875 if (write (fd, data, pagesize) != pagesize)
9876 return 3;
9877 close (fd);
9878
9879 /* Next, check that the tail of a page is zero-filled. File must have
9880 non-zero length, otherwise we risk SIGBUS for entire page. */
9881 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
9882 if (fd2 < 0)
9883 return 4;
9884 cdata2 = "";
9885 if (write (fd2, cdata2, 1) != 1)
9886 return 5;
9887 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
9888 if (data2 == MAP_FAILED)
9889 return 6;
9890 for (i = 0; i < pagesize; ++i)
9891 if (*(data2 + i))
9892 return 7;
9893 close (fd2);
9894 if (munmap (data2, pagesize))
9895 return 8;
9896
9897 /* Next, try to mmap the file at a fixed address which already has
9898 something else allocated at it. If we can, also make sure that
9899 we see the same garbage. */
9900 fd = open ("conftest.mmap", O_RDWR);
9901 if (fd < 0)
9902 return 9;
9903 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
9904 MAP_PRIVATE | MAP_FIXED, fd, 0L))
9905 return 10;
9906 for (i = 0; i < pagesize; ++i)
9907 if (*(data + i) != *(data2 + i))
9908 return 11;
9909
9910 /* Finally, make sure that changes to the mapped area do not
9911 percolate back to the file as seen by read(). (This is a bug on
9912 some variants of i386 svr4.0.) */
9913 for (i = 0; i < pagesize; ++i)
9914 *(data2 + i) = *(data2 + i) + 1;
9915 data3 = (char *) malloc (pagesize);
9916 if (!data3)
9917 return 12;
9918 if (read (fd, data3, pagesize) != pagesize)
9919 return 13;
9920 for (i = 0; i < pagesize; ++i)
9921 if (*(data + i) != *(data3 + i))
9922 return 14;
9923 close (fd);
9924 return 0;
9925 }
9926 _ACEOF
9927 if ac_fn_c_try_run "$LINENO"; then :
9928 ac_cv_func_mmap_fixed_mapped=yes
9929 else
9930 ac_cv_func_mmap_fixed_mapped=no
9931 fi
9932 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9933 conftest.$ac_objext conftest.beam conftest.$ac_ext
9934 fi
9935
9936 fi
9937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
9938 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
9939 if test $ac_cv_func_mmap_fixed_mapped = yes; then
9940
9941 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
9942
9943 fi
9944 rm -f conftest.mmap conftest.txt
9945
9946 if test $use_mmap_for_buffers = yes; then
9947
9948 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
9949
9950 REL_ALLOC=no
9951 fi
9952
9953 LIBS="$LIBS_SYSTEM $LIBS"
9954
9955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
9956 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
9957 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
9958 $as_echo_n "(cached) " >&6
9959 else
9960 ac_check_lib_save_LIBS=$LIBS
9961 LIBS="-ldnet $LIBS"
9962 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9963 /* end confdefs.h. */
9964
9965 /* Override any GCC internal prototype to avoid an error.
9966 Use char because int might match the return type of a GCC
9967 builtin and then its argument prototype would still apply. */
9968 #ifdef __cplusplus
9969 extern "C"
9970 #endif
9971 char dnet_ntoa ();
9972 int
9973 main ()
9974 {
9975 return dnet_ntoa ();
9976 ;
9977 return 0;
9978 }
9979 _ACEOF
9980 if ac_fn_c_try_link "$LINENO"; then :
9981 ac_cv_lib_dnet_dnet_ntoa=yes
9982 else
9983 ac_cv_lib_dnet_dnet_ntoa=no
9984 fi
9985 rm -f core conftest.err conftest.$ac_objext \
9986 conftest$ac_exeext conftest.$ac_ext
9987 LIBS=$ac_check_lib_save_LIBS
9988 fi
9989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
9990 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
9991 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
9992 cat >>confdefs.h <<_ACEOF
9993 #define HAVE_LIBDNET 1
9994 _ACEOF
9995
9996 LIBS="-ldnet $LIBS"
9997
9998 fi
9999
10000
10001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10002 $as_echo_n "checking for main in -lXbsd... " >&6; }
10003 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10004 $as_echo_n "(cached) " >&6
10005 else
10006 ac_check_lib_save_LIBS=$LIBS
10007 LIBS="-lXbsd $LIBS"
10008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10009 /* end confdefs.h. */
10010
10011
10012 int
10013 main ()
10014 {
10015 return main ();
10016 ;
10017 return 0;
10018 }
10019 _ACEOF
10020 if ac_fn_c_try_link "$LINENO"; then :
10021 ac_cv_lib_Xbsd_main=yes
10022 else
10023 ac_cv_lib_Xbsd_main=no
10024 fi
10025 rm -f core conftest.err conftest.$ac_objext \
10026 conftest$ac_exeext conftest.$ac_ext
10027 LIBS=$ac_check_lib_save_LIBS
10028 fi
10029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10030 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10031 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10032 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10033 fi
10034
10035
10036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10037 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10038 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10039 $as_echo_n "(cached) " >&6
10040 else
10041 ac_check_lib_save_LIBS=$LIBS
10042 LIBS="-lpthreads $LIBS"
10043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10044 /* end confdefs.h. */
10045
10046 /* Override any GCC internal prototype to avoid an error.
10047 Use char because int might match the return type of a GCC
10048 builtin and then its argument prototype would still apply. */
10049 #ifdef __cplusplus
10050 extern "C"
10051 #endif
10052 char cma_open ();
10053 int
10054 main ()
10055 {
10056 return cma_open ();
10057 ;
10058 return 0;
10059 }
10060 _ACEOF
10061 if ac_fn_c_try_link "$LINENO"; then :
10062 ac_cv_lib_pthreads_cma_open=yes
10063 else
10064 ac_cv_lib_pthreads_cma_open=no
10065 fi
10066 rm -f core conftest.err conftest.$ac_objext \
10067 conftest$ac_exeext conftest.$ac_ext
10068 LIBS=$ac_check_lib_save_LIBS
10069 fi
10070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10071 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10072 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10073 cat >>confdefs.h <<_ACEOF
10074 #define HAVE_LIBPTHREADS 1
10075 _ACEOF
10076
10077 LIBS="-lpthreads $LIBS"
10078
10079 fi
10080
10081
10082 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10083 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10084 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10085 ## added to LIBS in configure would never contain the pthreads part,
10086 ## but the value used in Makefiles might. FIXME?
10087 ##
10088 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10089 ## be harmless on older versions of X where it happens to exist.
10090 test "$opsys" = "aix4-2" && \
10091 test $ac_cv_lib_pthreads_cma_open = yes && \
10092 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10093
10094
10095 case ${host_os} in
10096 aix*)
10097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10098 $as_echo_n "checking for -bbigtoc option... " >&6; }
10099 if test "${gdb_cv_bigtoc+set}" = set; then :
10100 $as_echo_n "(cached) " >&6
10101 else
10102
10103 case $GCC in
10104 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10105 *) gdb_cv_bigtoc=-bbigtoc ;;
10106 esac
10107
10108 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10110 /* end confdefs.h. */
10111
10112 int
10113 main ()
10114 {
10115 int i;
10116 ;
10117 return 0;
10118 }
10119 _ACEOF
10120 if ac_fn_c_try_link "$LINENO"; then :
10121
10122 else
10123 gdb_cv_bigtoc=
10124 fi
10125 rm -f core conftest.err conftest.$ac_objext \
10126 conftest$ac_exeext conftest.$ac_ext
10127
10128 fi
10129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10130 $as_echo "$gdb_cv_bigtoc" >&6; }
10131 ;;
10132 esac
10133
10134 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10135 # used for the tests that follow. We set them back to REAL_CFLAGS and
10136 # REAL_CPPFLAGS later on.
10137
10138 REAL_CFLAGS="$CFLAGS"
10139 REAL_CPPFLAGS="$CPPFLAGS"
10140
10141 if test "${HAVE_X11}" = "yes"; then
10142 DEFS="$C_SWITCH_X_SITE $DEFS"
10143 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10144 LIBS="-lX11 $LIBS"
10145 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10146 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10147
10148 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10149 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
10150 # but it's more convenient here to set LD_RUN_PATH
10151 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
10152 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10153 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10154 export LD_RUN_PATH
10155 fi
10156
10157 if test "${opsys}" = "gnu-linux"; then
10158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10159 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10160 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10161 /* end confdefs.h. */
10162
10163 int
10164 main ()
10165 {
10166 XOpenDisplay ("foo");
10167 ;
10168 return 0;
10169 }
10170 _ACEOF
10171 if ac_fn_c_try_link "$LINENO"; then :
10172 xlinux_first_failure=no
10173 else
10174 xlinux_first_failure=yes
10175 fi
10176 rm -f core conftest.err conftest.$ac_objext \
10177 conftest$ac_exeext conftest.$ac_ext
10178 if test "${xlinux_first_failure}" = "yes"; then
10179 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10180 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10181 OLD_CPPFLAGS="$CPPFLAGS"
10182 OLD_LIBS="$LIBS"
10183 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10184 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10185 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10186 LIBS="$LIBS -b i486-linuxaout"
10187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10188 /* end confdefs.h. */
10189
10190 int
10191 main ()
10192 {
10193 XOpenDisplay ("foo");
10194 ;
10195 return 0;
10196 }
10197 _ACEOF
10198 if ac_fn_c_try_link "$LINENO"; then :
10199 xlinux_second_failure=no
10200 else
10201 xlinux_second_failure=yes
10202 fi
10203 rm -f core conftest.err conftest.$ac_objext \
10204 conftest$ac_exeext conftest.$ac_ext
10205 if test "${xlinux_second_failure}" = "yes"; then
10206 # If we get the same failure with -b, there is no use adding -b.
10207 # So take it out. This plays safe.
10208 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10209 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10210 CPPFLAGS="$OLD_CPPFLAGS"
10211 LIBS="$OLD_LIBS"
10212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10213 $as_echo "no" >&6; }
10214 else
10215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10216 $as_echo "yes" >&6; }
10217 fi
10218 else
10219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10220 $as_echo "no" >&6; }
10221 fi
10222 fi
10223
10224 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10225 # header files included from there.
10226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10227 $as_echo_n "checking for Xkb... " >&6; }
10228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10229 /* end confdefs.h. */
10230 #include <X11/Xlib.h>
10231 #include <X11/XKBlib.h>
10232 int
10233 main ()
10234 {
10235 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10236 ;
10237 return 0;
10238 }
10239 _ACEOF
10240 if ac_fn_c_try_link "$LINENO"; then :
10241 emacs_xkb=yes
10242 else
10243 emacs_xkb=no
10244 fi
10245 rm -f core conftest.err conftest.$ac_objext \
10246 conftest$ac_exeext conftest.$ac_ext
10247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10248 $as_echo "$emacs_xkb" >&6; }
10249 if test $emacs_xkb = yes; then
10250
10251 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10252
10253 fi
10254
10255 for ac_func in XrmSetDatabase XScreenResourceString \
10256 XScreenNumberOfScreen XSetWMProtocols
10257 do :
10258 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10259 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10260 eval as_val=\$$as_ac_var
10261 if test "x$as_val" = x""yes; then :
10262 cat >>confdefs.h <<_ACEOF
10263 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10264 _ACEOF
10265
10266 fi
10267 done
10268
10269 fi
10270
10271 if test "${window_system}" = "x11"; then
10272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10273 $as_echo_n "checking X11 version 6... " >&6; }
10274 if test "${emacs_cv_x11_version_6+set}" = set; then :
10275 $as_echo_n "(cached) " >&6
10276 else
10277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10278 /* end confdefs.h. */
10279 #include <X11/Xlib.h>
10280 int
10281 main ()
10282 {
10283 #if XlibSpecificationRelease < 6
10284 fail;
10285 #endif
10286
10287 ;
10288 return 0;
10289 }
10290 _ACEOF
10291 if ac_fn_c_try_link "$LINENO"; then :
10292 emacs_cv_x11_version_6=yes
10293 else
10294 emacs_cv_x11_version_6=no
10295 fi
10296 rm -f core conftest.err conftest.$ac_objext \
10297 conftest$ac_exeext conftest.$ac_ext
10298 fi
10299
10300 if test $emacs_cv_x11_version_6 = yes; then
10301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10302 $as_echo "6 or newer" >&6; }
10303
10304 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10305
10306
10307 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10308
10309 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10310 ## XIM support.
10311 case "$opsys" in
10312 sol2-*) : ;;
10313 *)
10314 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10315
10316 ;;
10317 esac
10318 else
10319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10320 $as_echo "before 6" >&6; }
10321 fi
10322 fi
10323
10324
10325 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10326 HAVE_RSVG=no
10327 if test "${HAVE_X11}" = "yes" || test "${NS_IMPL_GNUSTEP}" = "yes"; then
10328 if test "${with_rsvg}" != "no"; then
10329 RSVG_REQUIRED=2.11.0
10330 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10331
10332
10333 succeeded=no
10334
10335 # Extract the first word of "pkg-config", so it can be a program name with args.
10336 set dummy pkg-config; ac_word=$2
10337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10338 $as_echo_n "checking for $ac_word... " >&6; }
10339 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10340 $as_echo_n "(cached) " >&6
10341 else
10342 case $PKG_CONFIG in
10343 [\\/]* | ?:[\\/]*)
10344 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10345 ;;
10346 *)
10347 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10348 for as_dir in $PATH
10349 do
10350 IFS=$as_save_IFS
10351 test -z "$as_dir" && as_dir=.
10352 for ac_exec_ext in '' $ac_executable_extensions; do
10353 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10354 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10355 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10356 break 2
10357 fi
10358 done
10359 done
10360 IFS=$as_save_IFS
10361
10362 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10363 ;;
10364 esac
10365 fi
10366 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10367 if test -n "$PKG_CONFIG"; then
10368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10369 $as_echo "$PKG_CONFIG" >&6; }
10370 else
10371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10372 $as_echo "no" >&6; }
10373 fi
10374
10375
10376
10377 if test "$PKG_CONFIG" = "no" ; then
10378 :
10379 else
10380 PKG_CONFIG_MIN_VERSION=0.9.0
10381 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10383 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10384
10385 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5; then
10386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10387 $as_echo "yes" >&6; }
10388 succeeded=yes
10389
10390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_CFLAGS" >&5
10391 $as_echo_n "checking RSVG_CFLAGS... " >&6; }
10392 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE"|sed -e 's,///*,/,g'`
10393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_CFLAGS" >&5
10394 $as_echo "$RSVG_CFLAGS" >&6; }
10395
10396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking RSVG_LIBS" >&5
10397 $as_echo_n "checking RSVG_LIBS... " >&6; }
10398 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE"|sed -e 's,///*,/,g'`
10399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RSVG_LIBS" >&5
10400 $as_echo "$RSVG_LIBS" >&6; }
10401 else
10402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10403 $as_echo "no" >&6; }
10404 RSVG_CFLAGS=""
10405 RSVG_LIBS=""
10406 ## If we have a custom action on failure, don't print errors, but
10407 ## do set a variable so people can do so.
10408 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10409
10410 fi
10411
10412
10413
10414 else
10415 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10416 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10417 fi
10418 fi
10419
10420 if test $succeeded = yes; then
10421 HAVE_RSVG=yes
10422 else
10423 :
10424 fi
10425
10426
10427
10428
10429 if test $HAVE_RSVG = yes; then
10430
10431 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10432
10433 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10434 LIBS="$RSVG_LIBS $LIBS"
10435 fi
10436 fi
10437 fi
10438
10439 HAVE_IMAGEMAGICK=no
10440 if test "${HAVE_X11}" = "yes"; then
10441 if test "${with_imagemagick}" != "no"; then
10442 ## 6.2.8 is the earliest version known to work, but earlier versions
10443 ## might work - let us know if you find one.
10444 ## 6.0.7 does not work. See bug#7955.
10445 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10446
10447 succeeded=no
10448
10449 # Extract the first word of "pkg-config", so it can be a program name with args.
10450 set dummy pkg-config; ac_word=$2
10451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10452 $as_echo_n "checking for $ac_word... " >&6; }
10453 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10454 $as_echo_n "(cached) " >&6
10455 else
10456 case $PKG_CONFIG in
10457 [\\/]* | ?:[\\/]*)
10458 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10459 ;;
10460 *)
10461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10462 for as_dir in $PATH
10463 do
10464 IFS=$as_save_IFS
10465 test -z "$as_dir" && as_dir=.
10466 for ac_exec_ext in '' $ac_executable_extensions; do
10467 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10468 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10470 break 2
10471 fi
10472 done
10473 done
10474 IFS=$as_save_IFS
10475
10476 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10477 ;;
10478 esac
10479 fi
10480 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10481 if test -n "$PKG_CONFIG"; then
10482 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10483 $as_echo "$PKG_CONFIG" >&6; }
10484 else
10485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10486 $as_echo "no" >&6; }
10487 fi
10488
10489
10490
10491 if test "$PKG_CONFIG" = "no" ; then
10492 :
10493 else
10494 PKG_CONFIG_MIN_VERSION=0.9.0
10495 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10497 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10498
10499 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5; then
10500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10501 $as_echo "yes" >&6; }
10502 succeeded=yes
10503
10504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_CFLAGS" >&5
10505 $as_echo_n "checking IMAGEMAGICK_CFLAGS... " >&6; }
10506 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_CFLAGS" >&5
10508 $as_echo "$IMAGEMAGICK_CFLAGS" >&6; }
10509
10510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking IMAGEMAGICK_LIBS" >&5
10511 $as_echo_n "checking IMAGEMAGICK_LIBS... " >&6; }
10512 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE"|sed -e 's,///*,/,g'`
10513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $IMAGEMAGICK_LIBS" >&5
10514 $as_echo "$IMAGEMAGICK_LIBS" >&6; }
10515 else
10516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10517 $as_echo "no" >&6; }
10518 IMAGEMAGICK_CFLAGS=""
10519 IMAGEMAGICK_LIBS=""
10520 ## If we have a custom action on failure, don't print errors, but
10521 ## do set a variable so people can do so.
10522 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10523
10524 fi
10525
10526
10527
10528 else
10529 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10530 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10531 fi
10532 fi
10533
10534 if test $succeeded = yes; then
10535 HAVE_IMAGEMAGICK=yes
10536 else
10537 :
10538 fi
10539
10540
10541
10542
10543 if test $HAVE_IMAGEMAGICK = yes; then
10544
10545 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10546
10547 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10548 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10549 for ac_func in MagickExportImagePixels
10550 do :
10551 ac_fn_c_check_func "$LINENO" "MagickExportImagePixels" "ac_cv_func_MagickExportImagePixels"
10552 if test "x$ac_cv_func_MagickExportImagePixels" = x""yes; then :
10553 cat >>confdefs.h <<_ACEOF
10554 #define HAVE_MAGICKEXPORTIMAGEPIXELS 1
10555 _ACEOF
10556
10557 fi
10558 done
10559
10560 fi
10561 fi
10562 fi
10563
10564
10565 HAVE_GTK=no
10566 GTK_OBJ=
10567 if test "${with_gtk3}" = "yes"; then
10568 GLIB_REQUIRED=2.28
10569 GTK_REQUIRED=3.0
10570 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10571
10572
10573 succeeded=no
10574
10575 # Extract the first word of "pkg-config", so it can be a program name with args.
10576 set dummy pkg-config; ac_word=$2
10577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10578 $as_echo_n "checking for $ac_word... " >&6; }
10579 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10580 $as_echo_n "(cached) " >&6
10581 else
10582 case $PKG_CONFIG in
10583 [\\/]* | ?:[\\/]*)
10584 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10585 ;;
10586 *)
10587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10588 for as_dir in $PATH
10589 do
10590 IFS=$as_save_IFS
10591 test -z "$as_dir" && as_dir=.
10592 for ac_exec_ext in '' $ac_executable_extensions; do
10593 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10594 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10595 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10596 break 2
10597 fi
10598 done
10599 done
10600 IFS=$as_save_IFS
10601
10602 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10603 ;;
10604 esac
10605 fi
10606 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10607 if test -n "$PKG_CONFIG"; then
10608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10609 $as_echo "$PKG_CONFIG" >&6; }
10610 else
10611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10612 $as_echo "no" >&6; }
10613 fi
10614
10615
10616
10617 if test "$PKG_CONFIG" = "no" ; then
10618 pkg_check_gtk=no
10619 else
10620 PKG_CONFIG_MIN_VERSION=0.9.0
10621 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10623 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10624
10625 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
10626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10627 $as_echo "yes" >&6; }
10628 succeeded=yes
10629
10630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
10631 $as_echo_n "checking GTK_CFLAGS... " >&6; }
10632 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
10633 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
10634 $as_echo "$GTK_CFLAGS" >&6; }
10635
10636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
10637 $as_echo_n "checking GTK_LIBS... " >&6; }
10638 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
10639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
10640 $as_echo "$GTK_LIBS" >&6; }
10641 else
10642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10643 $as_echo "no" >&6; }
10644 GTK_CFLAGS=""
10645 GTK_LIBS=""
10646 ## If we have a custom action on failure, don't print errors, but
10647 ## do set a variable so people can do so.
10648 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10649
10650 fi
10651
10652
10653
10654 else
10655 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10656 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10657 fi
10658 fi
10659
10660 if test $succeeded = yes; then
10661 pkg_check_gtk=yes
10662 else
10663 pkg_check_gtk=no
10664 fi
10665
10666 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10667 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10668 fi
10669
10670 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
10671
10672 GTK_OBJ=emacsgtkfixed.o
10673 fi
10674
10675 if test "$pkg_check_gtk" != "yes"; then
10676 HAVE_GTK=no
10677 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
10678 GLIB_REQUIRED=2.6
10679 GTK_REQUIRED=2.6
10680 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10681
10682
10683 succeeded=no
10684
10685 # Extract the first word of "pkg-config", so it can be a program name with args.
10686 set dummy pkg-config; ac_word=$2
10687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10688 $as_echo_n "checking for $ac_word... " >&6; }
10689 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10690 $as_echo_n "(cached) " >&6
10691 else
10692 case $PKG_CONFIG in
10693 [\\/]* | ?:[\\/]*)
10694 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10695 ;;
10696 *)
10697 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10698 for as_dir in $PATH
10699 do
10700 IFS=$as_save_IFS
10701 test -z "$as_dir" && as_dir=.
10702 for ac_exec_ext in '' $ac_executable_extensions; do
10703 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10704 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10705 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10706 break 2
10707 fi
10708 done
10709 done
10710 IFS=$as_save_IFS
10711
10712 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10713 ;;
10714 esac
10715 fi
10716 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10717 if test -n "$PKG_CONFIG"; then
10718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10719 $as_echo "$PKG_CONFIG" >&6; }
10720 else
10721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10722 $as_echo "no" >&6; }
10723 fi
10724
10725
10726
10727 if test "$PKG_CONFIG" = "no" ; then
10728 pkg_check_gtk=no
10729 else
10730 PKG_CONFIG_MIN_VERSION=0.9.0
10731 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10733 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10734
10735 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5; then
10736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10737 $as_echo "yes" >&6; }
10738 succeeded=yes
10739
10740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_CFLAGS" >&5
10741 $as_echo_n "checking GTK_CFLAGS... " >&6; }
10742 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES"|sed -e 's,///*,/,g'`
10743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_CFLAGS" >&5
10744 $as_echo "$GTK_CFLAGS" >&6; }
10745
10746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GTK_LIBS" >&5
10747 $as_echo_n "checking GTK_LIBS... " >&6; }
10748 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES"|sed -e 's,///*,/,g'`
10749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GTK_LIBS" >&5
10750 $as_echo "$GTK_LIBS" >&6; }
10751 else
10752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10753 $as_echo "no" >&6; }
10754 GTK_CFLAGS=""
10755 GTK_LIBS=""
10756 ## If we have a custom action on failure, don't print errors, but
10757 ## do set a variable so people can do so.
10758 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10759
10760 fi
10761
10762
10763
10764 else
10765 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10766 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10767 fi
10768 fi
10769
10770 if test $succeeded = yes; then
10771 pkg_check_gtk=yes
10772 else
10773 pkg_check_gtk=no
10774 fi
10775
10776 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
10777 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
10778 fi
10779 fi
10780 fi
10781
10782 if test x"$pkg_check_gtk" = xyes; then
10783
10784
10785
10786 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
10787 CFLAGS="$CFLAGS $GTK_CFLAGS"
10788 LIBS="$GTK_LIBS $LIBS"
10789 GTK_COMPILES=no
10790 for ac_func in gtk_main
10791 do :
10792 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
10793 if test "x$ac_cv_func_gtk_main" = x""yes; then :
10794 cat >>confdefs.h <<_ACEOF
10795 #define HAVE_GTK_MAIN 1
10796 _ACEOF
10797 GTK_COMPILES=yes
10798 fi
10799 done
10800
10801 if test "${GTK_COMPILES}" != "yes"; then
10802 if test "$USE_X_TOOLKIT" != "maybe"; then
10803 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
10804 fi
10805 else
10806 HAVE_GTK=yes
10807
10808 $as_echo "#define USE_GTK 1" >>confdefs.h
10809
10810 GTK_OBJ="gtkutil.o $GTK_OBJ"
10811 USE_X_TOOLKIT=none
10812 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
10813 :
10814 else
10815 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
10816 closing open displays. This is no problem if you just use
10817 one display, but if you use more than one and close one of them
10818 Emacs may crash." >&5
10819 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
10820 closing open displays. This is no problem if you just use
10821 one display, but if you use more than one and close one of them
10822 Emacs may crash." >&2;}
10823 sleep 3
10824 fi
10825 fi
10826
10827 fi
10828
10829
10830
10831 if test "${HAVE_GTK}" = "yes"; then
10832
10833 if test "$with_toolkit_scroll_bars" != no; then
10834 with_toolkit_scroll_bars=yes
10835 fi
10836
10837 HAVE_GTK_FILE_SELECTION=no
10838 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
10839 #include <gtk/gtk.h>
10840 "
10841 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
10842 HAVE_GTK_FILE_SELECTION=yes
10843 else
10844 HAVE_GTK_FILE_SELECTION=no
10845 fi
10846
10847 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
10848 for ac_func in gtk_file_selection_new
10849 do :
10850 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
10851 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
10852 cat >>confdefs.h <<_ACEOF
10853 #define HAVE_GTK_FILE_SELECTION_NEW 1
10854 _ACEOF
10855
10856 fi
10857 done
10858
10859 fi
10860
10861 HAVE_GTK_AND_PTHREAD=no
10862 for ac_header in pthread.h
10863 do :
10864 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10865 if test "x$ac_cv_header_pthread_h" = x""yes; then :
10866 cat >>confdefs.h <<_ACEOF
10867 #define HAVE_PTHREAD_H 1
10868 _ACEOF
10869
10870 fi
10871
10872 done
10873
10874 if test "$ac_cv_header_pthread_h"; then
10875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pthread_self in -lpthread" >&5
10876 $as_echo_n "checking for pthread_self in -lpthread... " >&6; }
10877 if test "${ac_cv_lib_pthread_pthread_self+set}" = set; then :
10878 $as_echo_n "(cached) " >&6
10879 else
10880 ac_check_lib_save_LIBS=$LIBS
10881 LIBS="-lpthread $LIBS"
10882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10883 /* end confdefs.h. */
10884
10885 /* Override any GCC internal prototype to avoid an error.
10886 Use char because int might match the return type of a GCC
10887 builtin and then its argument prototype would still apply. */
10888 #ifdef __cplusplus
10889 extern "C"
10890 #endif
10891 char pthread_self ();
10892 int
10893 main ()
10894 {
10895 return pthread_self ();
10896 ;
10897 return 0;
10898 }
10899 _ACEOF
10900 if ac_fn_c_try_link "$LINENO"; then :
10901 ac_cv_lib_pthread_pthread_self=yes
10902 else
10903 ac_cv_lib_pthread_pthread_self=no
10904 fi
10905 rm -f core conftest.err conftest.$ac_objext \
10906 conftest$ac_exeext conftest.$ac_ext
10907 LIBS=$ac_check_lib_save_LIBS
10908 fi
10909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_self" >&5
10910 $as_echo "$ac_cv_lib_pthread_pthread_self" >&6; }
10911 if test "x$ac_cv_lib_pthread_pthread_self" = x""yes; then :
10912 HAVE_GTK_AND_PTHREAD=yes
10913 fi
10914
10915 fi
10916 if test "$HAVE_GTK_AND_PTHREAD" = yes; then
10917 case "${canonical}" in
10918 *-hpux*) ;;
10919 *) GTK_LIBS="$GTK_LIBS -lpthread" ;;
10920 esac
10921
10922 $as_echo "#define HAVE_GTK_AND_PTHREAD 1" >>confdefs.h
10923
10924 fi
10925
10926 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
10927 gtk_dialog_get_action_area gtk_widget_get_sensitive \
10928 gtk_widget_get_mapped gtk_adjustment_get_page_size \
10929 gtk_orientable_set_orientation
10930 do :
10931 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10932 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10933 eval as_val=\$$as_ac_var
10934 if test "x$as_val" = x""yes; then :
10935 cat >>confdefs.h <<_ACEOF
10936 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10937 _ACEOF
10938
10939 fi
10940 done
10941
10942
10943 fi
10944
10945 HAVE_DBUS=no
10946 DBUS_OBJ=
10947 if test "${with_dbus}" = "yes"; then
10948
10949 succeeded=no
10950
10951 # Extract the first word of "pkg-config", so it can be a program name with args.
10952 set dummy pkg-config; ac_word=$2
10953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10954 $as_echo_n "checking for $ac_word... " >&6; }
10955 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10956 $as_echo_n "(cached) " >&6
10957 else
10958 case $PKG_CONFIG in
10959 [\\/]* | ?:[\\/]*)
10960 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10961 ;;
10962 *)
10963 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10964 for as_dir in $PATH
10965 do
10966 IFS=$as_save_IFS
10967 test -z "$as_dir" && as_dir=.
10968 for ac_exec_ext in '' $ac_executable_extensions; do
10969 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10970 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10971 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10972 break 2
10973 fi
10974 done
10975 done
10976 IFS=$as_save_IFS
10977
10978 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10979 ;;
10980 esac
10981 fi
10982 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10983 if test -n "$PKG_CONFIG"; then
10984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10985 $as_echo "$PKG_CONFIG" >&6; }
10986 else
10987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10988 $as_echo "no" >&6; }
10989 fi
10990
10991
10992
10993 if test "$PKG_CONFIG" = "no" ; then
10994 HAVE_DBUS=no
10995 else
10996 PKG_CONFIG_MIN_VERSION=0.9.0
10997 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
10999 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11000
11001 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5; then
11002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11003 $as_echo "yes" >&6; }
11004 succeeded=yes
11005
11006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_CFLAGS" >&5
11007 $as_echo_n "checking DBUS_CFLAGS... " >&6; }
11008 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
11009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_CFLAGS" >&5
11010 $as_echo "$DBUS_CFLAGS" >&6; }
11011
11012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking DBUS_LIBS" >&5
11013 $as_echo_n "checking DBUS_LIBS... " >&6; }
11014 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0"|sed -e 's,///*,/,g'`
11015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DBUS_LIBS" >&5
11016 $as_echo "$DBUS_LIBS" >&6; }
11017 else
11018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11019 $as_echo "no" >&6; }
11020 DBUS_CFLAGS=""
11021 DBUS_LIBS=""
11022 ## If we have a custom action on failure, don't print errors, but
11023 ## do set a variable so people can do so.
11024 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
11025
11026 fi
11027
11028
11029
11030 else
11031 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11032 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11033 fi
11034 fi
11035
11036 if test $succeeded = yes; then
11037 HAVE_DBUS=yes
11038 else
11039 HAVE_DBUS=no
11040 fi
11041
11042 if test "$HAVE_DBUS" = yes; then
11043 LIBS="$LIBS $DBUS_LIBS"
11044
11045 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11046
11047 for ac_func in dbus_watch_get_unix_fd
11048 do :
11049 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
11050 if test "x$ac_cv_func_dbus_watch_get_unix_fd" = x""yes; then :
11051 cat >>confdefs.h <<_ACEOF
11052 #define HAVE_DBUS_WATCH_GET_UNIX_FD 1
11053 _ACEOF
11054
11055 fi
11056 done
11057
11058 DBUS_OBJ=dbusbind.o
11059 fi
11060 fi
11061
11062
11063 HAVE_GSETTINGS=no
11064 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11065
11066 succeeded=no
11067
11068 # Extract the first word of "pkg-config", so it can be a program name with args.
11069 set dummy pkg-config; ac_word=$2
11070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11071 $as_echo_n "checking for $ac_word... " >&6; }
11072 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11073 $as_echo_n "(cached) " >&6
11074 else
11075 case $PKG_CONFIG in
11076 [\\/]* | ?:[\\/]*)
11077 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11078 ;;
11079 *)
11080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11081 for as_dir in $PATH
11082 do
11083 IFS=$as_save_IFS
11084 test -z "$as_dir" && as_dir=.
11085 for ac_exec_ext in '' $ac_executable_extensions; do
11086 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11087 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11089 break 2
11090 fi
11091 done
11092 done
11093 IFS=$as_save_IFS
11094
11095 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11096 ;;
11097 esac
11098 fi
11099 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11100 if test -n "$PKG_CONFIG"; then
11101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11102 $as_echo "$PKG_CONFIG" >&6; }
11103 else
11104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11105 $as_echo "no" >&6; }
11106 fi
11107
11108
11109
11110 if test "$PKG_CONFIG" = "no" ; then
11111 HAVE_GSETTINGS=no
11112 else
11113 PKG_CONFIG_MIN_VERSION=0.9.0
11114 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for glib-2.0 >= 2.26" >&5
11116 $as_echo_n "checking for glib-2.0 >= 2.26... " >&6; }
11117
11118 if $PKG_CONFIG --exists "glib-2.0 >= 2.26" 2>&5; then
11119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11120 $as_echo "yes" >&6; }
11121 succeeded=yes
11122
11123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GSETTINGS_CFLAGS" >&5
11124 $as_echo_n "checking GSETTINGS_CFLAGS... " >&6; }
11125 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "glib-2.0 >= 2.26"|sed -e 's,///*,/,g'`
11126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GSETTINGS_CFLAGS" >&5
11127 $as_echo "$GSETTINGS_CFLAGS" >&6; }
11128
11129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GSETTINGS_LIBS" >&5
11130 $as_echo_n "checking GSETTINGS_LIBS... " >&6; }
11131 GSETTINGS_LIBS=`$PKG_CONFIG --libs "glib-2.0 >= 2.26"|sed -e 's,///*,/,g'`
11132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GSETTINGS_LIBS" >&5
11133 $as_echo "$GSETTINGS_LIBS" >&6; }
11134 else
11135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11136 $as_echo "no" >&6; }
11137 GSETTINGS_CFLAGS=""
11138 GSETTINGS_LIBS=""
11139 ## If we have a custom action on failure, don't print errors, but
11140 ## do set a variable so people can do so.
11141 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "glib-2.0 >= 2.26"`
11142
11143 fi
11144
11145
11146
11147 else
11148 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11149 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11150 fi
11151 fi
11152
11153 if test $succeeded = yes; then
11154 HAVE_GSETTINGS=yes
11155 else
11156 HAVE_GSETTINGS=no
11157 fi
11158
11159 if test "$HAVE_GSETTINGS" = "yes"; then
11160
11161 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11162
11163 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11164 SETTINGS_LIBS="$GSETTINGS_LIBS"
11165 fi
11166 fi
11167
11168 HAVE_GCONF=no
11169 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11170
11171 succeeded=no
11172
11173 # Extract the first word of "pkg-config", so it can be a program name with args.
11174 set dummy pkg-config; ac_word=$2
11175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11176 $as_echo_n "checking for $ac_word... " >&6; }
11177 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11178 $as_echo_n "(cached) " >&6
11179 else
11180 case $PKG_CONFIG in
11181 [\\/]* | ?:[\\/]*)
11182 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11183 ;;
11184 *)
11185 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11186 for as_dir in $PATH
11187 do
11188 IFS=$as_save_IFS
11189 test -z "$as_dir" && as_dir=.
11190 for ac_exec_ext in '' $ac_executable_extensions; do
11191 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11192 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11193 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11194 break 2
11195 fi
11196 done
11197 done
11198 IFS=$as_save_IFS
11199
11200 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11201 ;;
11202 esac
11203 fi
11204 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11205 if test -n "$PKG_CONFIG"; then
11206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11207 $as_echo "$PKG_CONFIG" >&6; }
11208 else
11209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11210 $as_echo "no" >&6; }
11211 fi
11212
11213
11214
11215 if test "$PKG_CONFIG" = "no" ; then
11216 HAVE_GCONF=no
11217 else
11218 PKG_CONFIG_MIN_VERSION=0.9.0
11219 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11221 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11222
11223 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5; then
11224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11225 $as_echo "yes" >&6; }
11226 succeeded=yes
11227
11228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_CFLAGS" >&5
11229 $as_echo_n "checking GCONF_CFLAGS... " >&6; }
11230 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
11231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_CFLAGS" >&5
11232 $as_echo "$GCONF_CFLAGS" >&6; }
11233
11234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCONF_LIBS" >&5
11235 $as_echo_n "checking GCONF_LIBS... " >&6; }
11236 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13"|sed -e 's,///*,/,g'`
11237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCONF_LIBS" >&5
11238 $as_echo "$GCONF_LIBS" >&6; }
11239 else
11240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11241 $as_echo "no" >&6; }
11242 GCONF_CFLAGS=""
11243 GCONF_LIBS=""
11244 ## If we have a custom action on failure, don't print errors, but
11245 ## do set a variable so people can do so.
11246 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
11247
11248 fi
11249
11250
11251
11252 else
11253 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11254 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11255 fi
11256 fi
11257
11258 if test $succeeded = yes; then
11259 HAVE_GCONF=yes
11260 else
11261 HAVE_GCONF=no
11262 fi
11263
11264 if test "$HAVE_GCONF" = yes; then
11265
11266 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11267
11268 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11269 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11270 fi
11271 fi
11272
11273 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11274 SAVE_CFLAGS="$CFLAGS"
11275 SAVE_LDFLAGS="$LDFLAGS"
11276 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11277 LDFLAGS="$SETTINGS_LIBS $LDFLAGS"
11278 for ac_func in g_type_init
11279 do :
11280 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11281 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11282 cat >>confdefs.h <<_ACEOF
11283 #define HAVE_G_TYPE_INIT 1
11284 _ACEOF
11285
11286 fi
11287 done
11288
11289 CFLAGS="$SAVE_CFLAGS"
11290 LDFLAGS="$SAVE_LDFLAGS"
11291 fi
11292
11293
11294
11295
11296 HAVE_LIBSELINUX=no
11297 LIBSELINUX_LIBS=
11298 if test "${with_selinux}" = "yes"; then
11299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11300 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11301 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11302 $as_echo_n "(cached) " >&6
11303 else
11304 ac_check_lib_save_LIBS=$LIBS
11305 LIBS="-lselinux $LIBS"
11306 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11307 /* end confdefs.h. */
11308
11309 /* Override any GCC internal prototype to avoid an error.
11310 Use char because int might match the return type of a GCC
11311 builtin and then its argument prototype would still apply. */
11312 #ifdef __cplusplus
11313 extern "C"
11314 #endif
11315 char lgetfilecon ();
11316 int
11317 main ()
11318 {
11319 return lgetfilecon ();
11320 ;
11321 return 0;
11322 }
11323 _ACEOF
11324 if ac_fn_c_try_link "$LINENO"; then :
11325 ac_cv_lib_selinux_lgetfilecon=yes
11326 else
11327 ac_cv_lib_selinux_lgetfilecon=no
11328 fi
11329 rm -f core conftest.err conftest.$ac_objext \
11330 conftest$ac_exeext conftest.$ac_ext
11331 LIBS=$ac_check_lib_save_LIBS
11332 fi
11333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11334 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11335 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11336 HAVE_LIBSELINUX=yes
11337 else
11338 HAVE_LIBSELINUX=no
11339 fi
11340
11341 if test "$HAVE_LIBSELINUX" = yes; then
11342
11343 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11344
11345 LIBSELINUX_LIBS=-lselinux
11346 fi
11347 fi
11348
11349
11350 HAVE_GNUTLS=no
11351 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11352 if test "${with_gnutls}" = "yes" ; then
11353
11354 succeeded=no
11355
11356 # Extract the first word of "pkg-config", so it can be a program name with args.
11357 set dummy pkg-config; ac_word=$2
11358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11359 $as_echo_n "checking for $ac_word... " >&6; }
11360 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11361 $as_echo_n "(cached) " >&6
11362 else
11363 case $PKG_CONFIG in
11364 [\\/]* | ?:[\\/]*)
11365 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11366 ;;
11367 *)
11368 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11369 for as_dir in $PATH
11370 do
11371 IFS=$as_save_IFS
11372 test -z "$as_dir" && as_dir=.
11373 for ac_exec_ext in '' $ac_executable_extensions; do
11374 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11375 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11376 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11377 break 2
11378 fi
11379 done
11380 done
11381 IFS=$as_save_IFS
11382
11383 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11384 ;;
11385 esac
11386 fi
11387 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11388 if test -n "$PKG_CONFIG"; then
11389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11390 $as_echo "$PKG_CONFIG" >&6; }
11391 else
11392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11393 $as_echo "no" >&6; }
11394 fi
11395
11396
11397
11398 if test "$PKG_CONFIG" = "no" ; then
11399 HAVE_GNUTLS=no
11400 else
11401 PKG_CONFIG_MIN_VERSION=0.9.0
11402 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.0" >&5
11404 $as_echo_n "checking for gnutls >= 2.6.0... " >&6; }
11405
11406 if $PKG_CONFIG --exists "gnutls >= 2.6.0" 2>&5; then
11407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11408 $as_echo "yes" >&6; }
11409 succeeded=yes
11410
11411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_CFLAGS" >&5
11412 $as_echo_n "checking LIBGNUTLS_CFLAGS... " >&6; }
11413 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.0"|sed -e 's,///*,/,g'`
11414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_CFLAGS" >&5
11415 $as_echo "$LIBGNUTLS_CFLAGS" >&6; }
11416
11417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBGNUTLS_LIBS" >&5
11418 $as_echo_n "checking LIBGNUTLS_LIBS... " >&6; }
11419 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.0"|sed -e 's,///*,/,g'`
11420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBGNUTLS_LIBS" >&5
11421 $as_echo "$LIBGNUTLS_LIBS" >&6; }
11422 else
11423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11424 $as_echo "no" >&6; }
11425 LIBGNUTLS_CFLAGS=""
11426 LIBGNUTLS_LIBS=""
11427 ## If we have a custom action on failure, don't print errors, but
11428 ## do set a variable so people can do so.
11429 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.0"`
11430
11431 fi
11432
11433
11434
11435 else
11436 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11437 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11438 fi
11439 fi
11440
11441 if test $succeeded = yes; then
11442 HAVE_GNUTLS=yes
11443 else
11444 HAVE_GNUTLS=no
11445 fi
11446
11447 if test "${HAVE_GNUTLS}" = "yes"; then
11448
11449 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11450
11451 fi
11452
11453 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11454 LIBS="$LIBGNUTLS_LIBS $LIBS"
11455 for ac_func in gnutls_certificate_set_verify_function
11456 do :
11457 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11458 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11459 cat >>confdefs.h <<_ACEOF
11460 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11461 _ACEOF
11462 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11463 fi
11464 done
11465
11466
11467 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11468
11469 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11470
11471 fi
11472 fi
11473
11474
11475
11476
11477 HAVE_XAW3D=no
11478 LUCID_LIBW=
11479 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11480 if test "$with_xaw3d" != no; then
11481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11482 $as_echo_n "checking for xaw3d... " >&6; }
11483 if test "${emacs_cv_xaw3d+set}" = set; then :
11484 $as_echo_n "(cached) " >&6
11485 else
11486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11487 /* end confdefs.h. */
11488
11489 #include <X11/Intrinsic.h>
11490 #include <X11/Xaw3d/Simple.h>
11491 int
11492 main ()
11493 {
11494
11495 ;
11496 return 0;
11497 }
11498 _ACEOF
11499 if ac_fn_c_try_link "$LINENO"; then :
11500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11501 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11502 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11503 $as_echo_n "(cached) " >&6
11504 else
11505 ac_check_lib_save_LIBS=$LIBS
11506 LIBS="-lXaw3d $LIBS"
11507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11508 /* end confdefs.h. */
11509
11510 /* Override any GCC internal prototype to avoid an error.
11511 Use char because int might match the return type of a GCC
11512 builtin and then its argument prototype would still apply. */
11513 #ifdef __cplusplus
11514 extern "C"
11515 #endif
11516 char XawScrollbarSetThumb ();
11517 int
11518 main ()
11519 {
11520 return XawScrollbarSetThumb ();
11521 ;
11522 return 0;
11523 }
11524 _ACEOF
11525 if ac_fn_c_try_link "$LINENO"; then :
11526 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11527 else
11528 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11529 fi
11530 rm -f core conftest.err conftest.$ac_objext \
11531 conftest$ac_exeext conftest.$ac_ext
11532 LIBS=$ac_check_lib_save_LIBS
11533 fi
11534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11535 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11536 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11537 emacs_cv_xaw3d=yes
11538 else
11539 emacs_cv_xaw3d=no
11540 fi
11541
11542 else
11543 emacs_cv_xaw3d=no
11544 fi
11545 rm -f core conftest.err conftest.$ac_objext \
11546 conftest$ac_exeext conftest.$ac_ext
11547 fi
11548
11549 else
11550 emacs_cv_xaw3d=no
11551 fi
11552 if test $emacs_cv_xaw3d = yes; then
11553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11554 $as_echo "yes; using Lucid toolkit" >&6; }
11555 USE_X_TOOLKIT=LUCID
11556 HAVE_XAW3D=yes
11557 LUCID_LIBW=-lXaw3d
11558
11559 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11560
11561 else
11562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11563 $as_echo "no" >&6; }
11564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11565 $as_echo_n "checking for libXaw... " >&6; }
11566 if test "${emacs_cv_xaw+set}" = set; then :
11567 $as_echo_n "(cached) " >&6
11568 else
11569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11570 /* end confdefs.h. */
11571
11572 #include <X11/Intrinsic.h>
11573 #include <X11/Xaw/Simple.h>
11574 int
11575 main ()
11576 {
11577
11578 ;
11579 return 0;
11580 }
11581 _ACEOF
11582 if ac_fn_c_try_link "$LINENO"; then :
11583 emacs_cv_xaw=yes
11584 else
11585 emacs_cv_xaw=no
11586 fi
11587 rm -f core conftest.err conftest.$ac_objext \
11588 conftest$ac_exeext conftest.$ac_ext
11589 fi
11590
11591 if test $emacs_cv_xaw = yes; then
11592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11593 $as_echo "yes; using Lucid toolkit" >&6; }
11594 USE_X_TOOLKIT=LUCID
11595 LUCID_LIBW=-lXaw
11596 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11597 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11598 else
11599 as_fn_error "No X toolkit could be found.
11600 If you are sure you want Emacs compiled without an X toolkit, pass
11601 --with-x-toolkit=no
11602 to configure. Otherwise, install the development libraries for the toolkit
11603 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11604 fi
11605 fi
11606 fi
11607
11608 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11609
11610 LIBXTR6=
11611 if test "${USE_X_TOOLKIT}" != "none"; then
11612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11613 $as_echo_n "checking X11 toolkit version... " >&6; }
11614 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11615 $as_echo_n "(cached) " >&6
11616 else
11617 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11618 /* end confdefs.h. */
11619 #include <X11/Intrinsic.h>
11620 int
11621 main ()
11622 {
11623 #if XtSpecificationRelease < 6
11624 fail;
11625 #endif
11626
11627 ;
11628 return 0;
11629 }
11630 _ACEOF
11631 if ac_fn_c_try_link "$LINENO"; then :
11632 emacs_cv_x11_toolkit_version_6=yes
11633 else
11634 emacs_cv_x11_toolkit_version_6=no
11635 fi
11636 rm -f core conftest.err conftest.$ac_objext \
11637 conftest$ac_exeext conftest.$ac_ext
11638 fi
11639
11640 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11641 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11643 $as_echo "6 or newer" >&6; }
11644
11645 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11646
11647 LIBXTR6="-lSM -lICE"
11648 case "$opsys" in
11649 ## Use libw.a along with X11R6 Xt.
11650 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11651 esac
11652 else
11653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11654 $as_echo "before 6" >&6; }
11655 fi
11656
11657 OLDLIBS="$LIBS"
11658 if test x$HAVE_X11XTR6 = xyes; then
11659 LIBS="-lXt -lSM -lICE $LIBS"
11660 else
11661 LIBS="-lXt $LIBS"
11662 fi
11663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11664 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11665 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11666 $as_echo_n "(cached) " >&6
11667 else
11668 ac_check_lib_save_LIBS=$LIBS
11669 LIBS="-lXmu $LIBS"
11670 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11671 /* end confdefs.h. */
11672
11673 /* Override any GCC internal prototype to avoid an error.
11674 Use char because int might match the return type of a GCC
11675 builtin and then its argument prototype would still apply. */
11676 #ifdef __cplusplus
11677 extern "C"
11678 #endif
11679 char XmuConvertStandardSelection ();
11680 int
11681 main ()
11682 {
11683 return XmuConvertStandardSelection ();
11684 ;
11685 return 0;
11686 }
11687 _ACEOF
11688 if ac_fn_c_try_link "$LINENO"; then :
11689 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11690 else
11691 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11692 fi
11693 rm -f core conftest.err conftest.$ac_objext \
11694 conftest$ac_exeext conftest.$ac_ext
11695 LIBS=$ac_check_lib_save_LIBS
11696 fi
11697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11698 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11699 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11700 cat >>confdefs.h <<_ACEOF
11701 #define HAVE_LIBXMU 1
11702 _ACEOF
11703
11704 LIBS="-lXmu $LIBS"
11705
11706 fi
11707
11708 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11709 fi
11710
11711
11712 LIBXMU=-lXmu
11713 case $opsys in
11714 ## These systems don't supply Xmu.
11715 hpux* | aix4-2 )
11716 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11717 ;;
11718 esac
11719
11720
11721 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11722 if test "${HAVE_X11}" = "yes"; then
11723 if test "${USE_X_TOOLKIT}" != "none"; then
11724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11725 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11726 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11727 $as_echo_n "(cached) " >&6
11728 else
11729 ac_check_lib_save_LIBS=$LIBS
11730 LIBS="-lXext $LIBS"
11731 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11732 /* end confdefs.h. */
11733
11734 /* Override any GCC internal prototype to avoid an error.
11735 Use char because int might match the return type of a GCC
11736 builtin and then its argument prototype would still apply. */
11737 #ifdef __cplusplus
11738 extern "C"
11739 #endif
11740 char XShapeQueryExtension ();
11741 int
11742 main ()
11743 {
11744 return XShapeQueryExtension ();
11745 ;
11746 return 0;
11747 }
11748 _ACEOF
11749 if ac_fn_c_try_link "$LINENO"; then :
11750 ac_cv_lib_Xext_XShapeQueryExtension=yes
11751 else
11752 ac_cv_lib_Xext_XShapeQueryExtension=no
11753 fi
11754 rm -f core conftest.err conftest.$ac_objext \
11755 conftest$ac_exeext conftest.$ac_ext
11756 LIBS=$ac_check_lib_save_LIBS
11757 fi
11758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
11759 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
11760 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
11761 cat >>confdefs.h <<_ACEOF
11762 #define HAVE_LIBXEXT 1
11763 _ACEOF
11764
11765 LIBS="-lXext $LIBS"
11766
11767 fi
11768
11769 fi
11770 fi
11771
11772 LIBXP=
11773 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
11775 $as_echo_n "checking for Motif version 2.1... " >&6; }
11776 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
11777 $as_echo_n "(cached) " >&6
11778 else
11779 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11780 /* end confdefs.h. */
11781 #include <Xm/Xm.h>
11782 int
11783 main ()
11784 {
11785 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
11786 int x = 5;
11787 #else
11788 Motif version prior to 2.1.
11789 #endif
11790 ;
11791 return 0;
11792 }
11793 _ACEOF
11794 if ac_fn_c_try_compile "$LINENO"; then :
11795 emacs_cv_motif_version_2_1=yes
11796 else
11797 emacs_cv_motif_version_2_1=no
11798 fi
11799 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11800 fi
11801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
11802 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
11803 if test $emacs_cv_motif_version_2_1 = yes; then
11804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
11805 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
11806 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
11807 $as_echo_n "(cached) " >&6
11808 else
11809 ac_check_lib_save_LIBS=$LIBS
11810 LIBS="-lXp $LIBS"
11811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11812 /* end confdefs.h. */
11813
11814 /* Override any GCC internal prototype to avoid an error.
11815 Use char because int might match the return type of a GCC
11816 builtin and then its argument prototype would still apply. */
11817 #ifdef __cplusplus
11818 extern "C"
11819 #endif
11820 char XpCreateContext ();
11821 int
11822 main ()
11823 {
11824 return XpCreateContext ();
11825 ;
11826 return 0;
11827 }
11828 _ACEOF
11829 if ac_fn_c_try_link "$LINENO"; then :
11830 ac_cv_lib_Xp_XpCreateContext=yes
11831 else
11832 ac_cv_lib_Xp_XpCreateContext=no
11833 fi
11834 rm -f core conftest.err conftest.$ac_objext \
11835 conftest$ac_exeext conftest.$ac_ext
11836 LIBS=$ac_check_lib_save_LIBS
11837 fi
11838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
11839 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
11840 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
11841 LIBXP=-lXp
11842 fi
11843
11844 else
11845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
11846 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
11847 if test "${emacs_cv_lesstif+set}" = set; then :
11848 $as_echo_n "(cached) " >&6
11849 else
11850 # We put this in CFLAGS temporarily to precede other -I options
11851 # that might be in CFLAGS temporarily.
11852 # We put this in CPPFLAGS where it precedes the other -I options.
11853 OLD_CPPFLAGS=$CPPFLAGS
11854 OLD_CFLAGS=$CFLAGS
11855 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
11856 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
11857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11858 /* end confdefs.h. */
11859 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
11860 int
11861 main ()
11862 {
11863 int x = 5;
11864 ;
11865 return 0;
11866 }
11867 _ACEOF
11868 if ac_fn_c_try_compile "$LINENO"; then :
11869 emacs_cv_lesstif=yes
11870 else
11871 emacs_cv_lesstif=no
11872 fi
11873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11874 fi
11875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
11876 $as_echo "$emacs_cv_lesstif" >&6; }
11877 if test $emacs_cv_lesstif = yes; then
11878 # Make sure this -I option remains in CPPFLAGS after it is set
11879 # back to REAL_CPPFLAGS.
11880 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
11881 # have those other -I options anyway. Ultimately, having this
11882 # directory ultimately in CPPFLAGS will be enough.
11883 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
11884 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
11885 else
11886 CFLAGS=$OLD_CFLAGS
11887 CPPFLAGS=$OLD_CPPFLAGS
11888 fi
11889 fi
11890 fi
11891
11892
11893 USE_TOOLKIT_SCROLL_BARS=no
11894 if test "${with_toolkit_scroll_bars}" != "no"; then
11895 if test "${USE_X_TOOLKIT}" != "none"; then
11896 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
11897 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11898
11899 HAVE_XAW3D=no
11900 USE_TOOLKIT_SCROLL_BARS=yes
11901 elif test "${HAVE_XAW3D}" = "yes"; then
11902 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11903
11904 USE_TOOLKIT_SCROLL_BARS=yes
11905 fi
11906 elif test "${HAVE_GTK}" = "yes"; then
11907 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11908
11909 USE_TOOLKIT_SCROLL_BARS=yes
11910 elif test "${HAVE_NS}" = "yes"; then
11911 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
11912
11913 USE_TOOLKIT_SCROLL_BARS=yes
11914 fi
11915 fi
11916
11917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11918 /* end confdefs.h. */
11919
11920 #include <X11/Xlib.h>
11921 #include <X11/Xresource.h>
11922 int
11923 main ()
11924 {
11925 XIMProc callback;
11926 ;
11927 return 0;
11928 }
11929 _ACEOF
11930 if ac_fn_c_try_compile "$LINENO"; then :
11931 HAVE_XIM=yes
11932
11933 $as_echo "#define HAVE_XIM 1" >>confdefs.h
11934
11935 else
11936 HAVE_XIM=no
11937 fi
11938 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11939
11940
11941 if test "${with_xim}" != "no"; then
11942
11943 $as_echo "#define USE_XIM 1" >>confdefs.h
11944
11945 fi
11946
11947
11948 if test "${HAVE_XIM}" != "no"; then
11949 late_CFLAGS=$CFLAGS
11950 if test "$GCC" = yes; then
11951 CFLAGS="$CFLAGS --pedantic-errors"
11952 fi
11953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11954 /* end confdefs.h. */
11955
11956 #include <X11/Xlib.h>
11957 #include <X11/Xresource.h>
11958 int
11959 main ()
11960 {
11961 Display *display;
11962 XrmDatabase db;
11963 char *res_name;
11964 char *res_class;
11965 XIMProc callback;
11966 XPointer *client_data;
11967 #ifndef __GNUC__
11968 /* If we're not using GCC, it's probably not XFree86, and this is
11969 probably right, but we can't use something like --pedantic-errors. */
11970 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
11971 char*, XIMProc, XPointer*);
11972 #endif
11973 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
11974 client_data);
11975 ;
11976 return 0;
11977 }
11978 _ACEOF
11979 if ac_fn_c_try_compile "$LINENO"; then :
11980 emacs_cv_arg6_star=yes
11981 fi
11982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11983 if test "$emacs_cv_arg6_star" = yes; then
11984 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
11985
11986 else
11987 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
11988
11989 fi
11990 CFLAGS=$late_CFLAGS
11991 fi
11992
11993 ### Start of font-backend (under any platform) section.
11994 # (nothing here yet -- this is a placeholder)
11995 ### End of font-backend (under any platform) section.
11996
11997 ### Start of font-backend (under X11) section.
11998 if test "${HAVE_X11}" = "yes"; then
11999
12000 succeeded=no
12001
12002 # Extract the first word of "pkg-config", so it can be a program name with args.
12003 set dummy pkg-config; ac_word=$2
12004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12005 $as_echo_n "checking for $ac_word... " >&6; }
12006 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12007 $as_echo_n "(cached) " >&6
12008 else
12009 case $PKG_CONFIG in
12010 [\\/]* | ?:[\\/]*)
12011 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12012 ;;
12013 *)
12014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12015 for as_dir in $PATH
12016 do
12017 IFS=$as_save_IFS
12018 test -z "$as_dir" && as_dir=.
12019 for ac_exec_ext in '' $ac_executable_extensions; do
12020 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12021 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12023 break 2
12024 fi
12025 done
12026 done
12027 IFS=$as_save_IFS
12028
12029 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12030 ;;
12031 esac
12032 fi
12033 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12034 if test -n "$PKG_CONFIG"; then
12035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12036 $as_echo "$PKG_CONFIG" >&6; }
12037 else
12038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12039 $as_echo "no" >&6; }
12040 fi
12041
12042
12043
12044 if test "$PKG_CONFIG" = "no" ; then
12045 HAVE_FC=no
12046 else
12047 PKG_CONFIG_MIN_VERSION=0.9.0
12048 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12050 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12051
12052 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5; then
12053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12054 $as_echo "yes" >&6; }
12055 succeeded=yes
12056
12057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_CFLAGS" >&5
12058 $as_echo_n "checking FONTCONFIG_CFLAGS... " >&6; }
12059 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
12060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_CFLAGS" >&5
12061 $as_echo "$FONTCONFIG_CFLAGS" >&6; }
12062
12063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FONTCONFIG_LIBS" >&5
12064 $as_echo_n "checking FONTCONFIG_LIBS... " >&6; }
12065 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0"|sed -e 's,///*,/,g'`
12066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FONTCONFIG_LIBS" >&5
12067 $as_echo "$FONTCONFIG_LIBS" >&6; }
12068 else
12069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12070 $as_echo "no" >&6; }
12071 FONTCONFIG_CFLAGS=""
12072 FONTCONFIG_LIBS=""
12073 ## If we have a custom action on failure, don't print errors, but
12074 ## do set a variable so people can do so.
12075 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
12076
12077 fi
12078
12079
12080
12081 else
12082 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12083 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12084 fi
12085 fi
12086
12087 if test $succeeded = yes; then
12088 HAVE_FC=yes
12089 else
12090 HAVE_FC=no
12091 fi
12092
12093
12094 ## Use -lXft if available, unless `--with-xft=no'.
12095 HAVE_XFT=maybe
12096 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12097 with_xft="no";
12098 fi
12099 if test "x${with_xft}" != "xno"; then
12100
12101
12102 succeeded=no
12103
12104 # Extract the first word of "pkg-config", so it can be a program name with args.
12105 set dummy pkg-config; ac_word=$2
12106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12107 $as_echo_n "checking for $ac_word... " >&6; }
12108 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12109 $as_echo_n "(cached) " >&6
12110 else
12111 case $PKG_CONFIG in
12112 [\\/]* | ?:[\\/]*)
12113 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12114 ;;
12115 *)
12116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12117 for as_dir in $PATH
12118 do
12119 IFS=$as_save_IFS
12120 test -z "$as_dir" && as_dir=.
12121 for ac_exec_ext in '' $ac_executable_extensions; do
12122 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12123 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12125 break 2
12126 fi
12127 done
12128 done
12129 IFS=$as_save_IFS
12130
12131 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12132 ;;
12133 esac
12134 fi
12135 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12136 if test -n "$PKG_CONFIG"; then
12137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12138 $as_echo "$PKG_CONFIG" >&6; }
12139 else
12140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12141 $as_echo "no" >&6; }
12142 fi
12143
12144
12145
12146 if test "$PKG_CONFIG" = "no" ; then
12147 HAVE_XFT=no
12148 else
12149 PKG_CONFIG_MIN_VERSION=0.9.0
12150 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12152 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12153
12154 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5; then
12155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12156 $as_echo "yes" >&6; }
12157 succeeded=yes
12158
12159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_CFLAGS" >&5
12160 $as_echo_n "checking XFT_CFLAGS... " >&6; }
12161 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0"|sed -e 's,///*,/,g'`
12162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_CFLAGS" >&5
12163 $as_echo "$XFT_CFLAGS" >&6; }
12164
12165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking XFT_LIBS" >&5
12166 $as_echo_n "checking XFT_LIBS... " >&6; }
12167 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0"|sed -e 's,///*,/,g'`
12168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XFT_LIBS" >&5
12169 $as_echo "$XFT_LIBS" >&6; }
12170 else
12171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12172 $as_echo "no" >&6; }
12173 XFT_CFLAGS=""
12174 XFT_LIBS=""
12175 ## If we have a custom action on failure, don't print errors, but
12176 ## do set a variable so people can do so.
12177 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
12178
12179 fi
12180
12181
12182
12183 else
12184 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12185 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12186 fi
12187 fi
12188
12189 if test $succeeded = yes; then
12190 :
12191 else
12192 HAVE_XFT=no
12193 fi
12194
12195 ## Because xftfont.c uses XRenderQueryExtension, we also
12196 ## need to link to -lXrender.
12197 HAVE_XRENDER=no
12198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12199 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12200 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12201 $as_echo_n "(cached) " >&6
12202 else
12203 ac_check_lib_save_LIBS=$LIBS
12204 LIBS="-lXrender $LIBS"
12205 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12206 /* end confdefs.h. */
12207
12208 /* Override any GCC internal prototype to avoid an error.
12209 Use char because int might match the return type of a GCC
12210 builtin and then its argument prototype would still apply. */
12211 #ifdef __cplusplus
12212 extern "C"
12213 #endif
12214 char XRenderQueryExtension ();
12215 int
12216 main ()
12217 {
12218 return XRenderQueryExtension ();
12219 ;
12220 return 0;
12221 }
12222 _ACEOF
12223 if ac_fn_c_try_link "$LINENO"; then :
12224 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12225 else
12226 ac_cv_lib_Xrender_XRenderQueryExtension=no
12227 fi
12228 rm -f core conftest.err conftest.$ac_objext \
12229 conftest$ac_exeext conftest.$ac_ext
12230 LIBS=$ac_check_lib_save_LIBS
12231 fi
12232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12233 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12234 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12235 HAVE_XRENDER=yes
12236 fi
12237
12238 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12239 OLD_CPPFLAGS="$CPPFLAGS"
12240 OLD_CFLAGS="$CFLAGS"
12241 OLD_LIBS="$LIBS"
12242 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12243 CFLAGS="$CFLAGS $XFT_CFLAGS"
12244 XFT_LIBS="-lXrender $XFT_LIBS"
12245 LIBS="$XFT_LIBS $LIBS"
12246 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12247 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12249 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12250 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12251 $as_echo_n "(cached) " >&6
12252 else
12253 ac_check_lib_save_LIBS=$LIBS
12254 LIBS="-lXft $XFT_LIBS $LIBS"
12255 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12256 /* end confdefs.h. */
12257
12258 /* Override any GCC internal prototype to avoid an error.
12259 Use char because int might match the return type of a GCC
12260 builtin and then its argument prototype would still apply. */
12261 #ifdef __cplusplus
12262 extern "C"
12263 #endif
12264 char XftFontOpen ();
12265 int
12266 main ()
12267 {
12268 return XftFontOpen ();
12269 ;
12270 return 0;
12271 }
12272 _ACEOF
12273 if ac_fn_c_try_link "$LINENO"; then :
12274 ac_cv_lib_Xft_XftFontOpen=yes
12275 else
12276 ac_cv_lib_Xft_XftFontOpen=no
12277 fi
12278 rm -f core conftest.err conftest.$ac_objext \
12279 conftest$ac_exeext conftest.$ac_ext
12280 LIBS=$ac_check_lib_save_LIBS
12281 fi
12282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12283 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12284 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12285 HAVE_XFT=yes
12286 fi
12287
12288 fi
12289
12290
12291
12292 if test "${HAVE_XFT}" = "yes"; then
12293
12294 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12295
12296
12297 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12298 else
12299 CPPFLAGS="$OLD_CPPFLAGS"
12300 CFLAGS="$OLD_CFLAGS"
12301 LIBS="$OLD_LIBS"
12302 fi # "${HAVE_XFT}" = "yes"
12303 fi # "$HAVE_XFT" != no
12304 fi # "x${with_xft}" != "xno"
12305
12306 ## We used to allow building with FreeType and without Xft.
12307 ## However, the ftx font backend driver is not in good shape.
12308 if test "$HAVE_XFT" != "yes"; then
12309 HAVE_XFT=no
12310 HAVE_FREETYPE=no
12311 else
12312
12313 succeeded=no
12314
12315 # Extract the first word of "pkg-config", so it can be a program name with args.
12316 set dummy pkg-config; ac_word=$2
12317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12318 $as_echo_n "checking for $ac_word... " >&6; }
12319 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12320 $as_echo_n "(cached) " >&6
12321 else
12322 case $PKG_CONFIG in
12323 [\\/]* | ?:[\\/]*)
12324 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12325 ;;
12326 *)
12327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12328 for as_dir in $PATH
12329 do
12330 IFS=$as_save_IFS
12331 test -z "$as_dir" && as_dir=.
12332 for ac_exec_ext in '' $ac_executable_extensions; do
12333 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12334 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12336 break 2
12337 fi
12338 done
12339 done
12340 IFS=$as_save_IFS
12341
12342 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12343 ;;
12344 esac
12345 fi
12346 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12347 if test -n "$PKG_CONFIG"; then
12348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12349 $as_echo "$PKG_CONFIG" >&6; }
12350 else
12351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12352 $as_echo "no" >&6; }
12353 fi
12354
12355
12356
12357 if test "$PKG_CONFIG" = "no" ; then
12358 HAVE_FREETYPE=no
12359 else
12360 PKG_CONFIG_MIN_VERSION=0.9.0
12361 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12363 $as_echo_n "checking for freetype2... " >&6; }
12364
12365 if $PKG_CONFIG --exists "freetype2" 2>&5; then
12366 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12367 $as_echo "yes" >&6; }
12368 succeeded=yes
12369
12370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FREETYPE_CFLAGS" >&5
12371 $as_echo_n "checking FREETYPE_CFLAGS... " >&6; }
12372 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2"|sed -e 's,///*,/,g'`
12373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_CFLAGS" >&5
12374 $as_echo "$FREETYPE_CFLAGS" >&6; }
12375
12376 { $as_echo "$as_me:${as_lineno-$LINENO}: checking FREETYPE_LIBS" >&5
12377 $as_echo_n "checking FREETYPE_LIBS... " >&6; }
12378 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2"|sed -e 's,///*,/,g'`
12379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIBS" >&5
12380 $as_echo "$FREETYPE_LIBS" >&6; }
12381 else
12382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12383 $as_echo "no" >&6; }
12384 FREETYPE_CFLAGS=""
12385 FREETYPE_LIBS=""
12386 ## If we have a custom action on failure, don't print errors, but
12387 ## do set a variable so people can do so.
12388 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
12389
12390 fi
12391
12392
12393
12394 else
12395 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12396 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12397 fi
12398 fi
12399
12400 if test $succeeded = yes; then
12401 HAVE_FREETYPE=yes
12402 else
12403 HAVE_FREETYPE=no
12404 fi
12405
12406
12407 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12408 fi
12409
12410 HAVE_LIBOTF=no
12411 if test "${HAVE_FREETYPE}" = "yes"; then
12412
12413 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12414
12415 if test "${with_libotf}" != "no"; then
12416
12417 succeeded=no
12418
12419 # Extract the first word of "pkg-config", so it can be a program name with args.
12420 set dummy pkg-config; ac_word=$2
12421 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12422 $as_echo_n "checking for $ac_word... " >&6; }
12423 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12424 $as_echo_n "(cached) " >&6
12425 else
12426 case $PKG_CONFIG in
12427 [\\/]* | ?:[\\/]*)
12428 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12429 ;;
12430 *)
12431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12432 for as_dir in $PATH
12433 do
12434 IFS=$as_save_IFS
12435 test -z "$as_dir" && as_dir=.
12436 for ac_exec_ext in '' $ac_executable_extensions; do
12437 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12438 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12439 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12440 break 2
12441 fi
12442 done
12443 done
12444 IFS=$as_save_IFS
12445
12446 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12447 ;;
12448 esac
12449 fi
12450 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12451 if test -n "$PKG_CONFIG"; then
12452 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12453 $as_echo "$PKG_CONFIG" >&6; }
12454 else
12455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12456 $as_echo "no" >&6; }
12457 fi
12458
12459
12460
12461 if test "$PKG_CONFIG" = "no" ; then
12462 HAVE_LIBOTF=no
12463 else
12464 PKG_CONFIG_MIN_VERSION=0.9.0
12465 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12467 $as_echo_n "checking for libotf... " >&6; }
12468
12469 if $PKG_CONFIG --exists "libotf" 2>&5; then
12470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12471 $as_echo "yes" >&6; }
12472 succeeded=yes
12473
12474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_CFLAGS" >&5
12475 $as_echo_n "checking LIBOTF_CFLAGS... " >&6; }
12476 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf"|sed -e 's,///*,/,g'`
12477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_CFLAGS" >&5
12478 $as_echo "$LIBOTF_CFLAGS" >&6; }
12479
12480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBOTF_LIBS" >&5
12481 $as_echo_n "checking LIBOTF_LIBS... " >&6; }
12482 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf"|sed -e 's,///*,/,g'`
12483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBOTF_LIBS" >&5
12484 $as_echo "$LIBOTF_LIBS" >&6; }
12485 else
12486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12487 $as_echo "no" >&6; }
12488 LIBOTF_CFLAGS=""
12489 LIBOTF_LIBS=""
12490 ## If we have a custom action on failure, don't print errors, but
12491 ## do set a variable so people can do so.
12492 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
12493
12494 fi
12495
12496
12497
12498 else
12499 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12500 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12501 fi
12502 fi
12503
12504 if test $succeeded = yes; then
12505 HAVE_LIBOTF=yes
12506 else
12507 HAVE_LIBOTF=no
12508 fi
12509
12510 if test "$HAVE_LIBOTF" = "yes"; then
12511
12512 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12513
12514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12515 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12516 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12517 $as_echo_n "(cached) " >&6
12518 else
12519 ac_check_lib_save_LIBS=$LIBS
12520 LIBS="-lotf $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 OTF_get_variation_glyphs ();
12531 int
12532 main ()
12533 {
12534 return OTF_get_variation_glyphs ();
12535 ;
12536 return 0;
12537 }
12538 _ACEOF
12539 if ac_fn_c_try_link "$LINENO"; then :
12540 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12541 else
12542 ac_cv_lib_otf_OTF_get_variation_glyphs=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_otf_OTF_get_variation_glyphs" >&5
12549 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12550 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12551 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12552 else
12553 HAVE_OTF_GET_VARIATION_GLYPHS=no
12554 fi
12555
12556 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12557
12558 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12559
12560 fi
12561 fi
12562 fi
12563 fi
12564
12565 HAVE_M17N_FLT=no
12566 if test "${HAVE_LIBOTF}" = yes; then
12567 if test "${with_m17n_flt}" != "no"; then
12568
12569 succeeded=no
12570
12571 # Extract the first word of "pkg-config", so it can be a program name with args.
12572 set dummy pkg-config; ac_word=$2
12573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12574 $as_echo_n "checking for $ac_word... " >&6; }
12575 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12576 $as_echo_n "(cached) " >&6
12577 else
12578 case $PKG_CONFIG in
12579 [\\/]* | ?:[\\/]*)
12580 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12581 ;;
12582 *)
12583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12584 for as_dir in $PATH
12585 do
12586 IFS=$as_save_IFS
12587 test -z "$as_dir" && as_dir=.
12588 for ac_exec_ext in '' $ac_executable_extensions; do
12589 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12590 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12592 break 2
12593 fi
12594 done
12595 done
12596 IFS=$as_save_IFS
12597
12598 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12599 ;;
12600 esac
12601 fi
12602 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12603 if test -n "$PKG_CONFIG"; then
12604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12605 $as_echo "$PKG_CONFIG" >&6; }
12606 else
12607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12608 $as_echo "no" >&6; }
12609 fi
12610
12611
12612
12613 if test "$PKG_CONFIG" = "no" ; then
12614 HAVE_M17N_FLT=no
12615 else
12616 PKG_CONFIG_MIN_VERSION=0.9.0
12617 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12619 $as_echo_n "checking for m17n-flt... " >&6; }
12620
12621 if $PKG_CONFIG --exists "m17n-flt" 2>&5; then
12622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12623 $as_echo "yes" >&6; }
12624 succeeded=yes
12625
12626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_CFLAGS" >&5
12627 $as_echo_n "checking M17N_FLT_CFLAGS... " >&6; }
12628 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt"|sed -e 's,///*,/,g'`
12629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_CFLAGS" >&5
12630 $as_echo "$M17N_FLT_CFLAGS" >&6; }
12631
12632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking M17N_FLT_LIBS" >&5
12633 $as_echo_n "checking M17N_FLT_LIBS... " >&6; }
12634 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt"|sed -e 's,///*,/,g'`
12635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $M17N_FLT_LIBS" >&5
12636 $as_echo "$M17N_FLT_LIBS" >&6; }
12637 else
12638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12639 $as_echo "no" >&6; }
12640 M17N_FLT_CFLAGS=""
12641 M17N_FLT_LIBS=""
12642 ## If we have a custom action on failure, don't print errors, but
12643 ## do set a variable so people can do so.
12644 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
12645
12646 fi
12647
12648
12649
12650 else
12651 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12652 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12653 fi
12654 fi
12655
12656 if test $succeeded = yes; then
12657 HAVE_M17N_FLT=yes
12658 else
12659 HAVE_M17N_FLT=no
12660 fi
12661
12662 if test "$HAVE_M17N_FLT" = "yes"; then
12663
12664 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12665
12666 fi
12667 fi
12668 fi
12669 else
12670 HAVE_XFT=no
12671 HAVE_FREETYPE=no
12672 HAVE_LIBOTF=no
12673 HAVE_M17N_FLT=no
12674 fi
12675
12676 ### End of font-backend (under X11) section.
12677
12678
12679
12680
12681
12682
12683
12684
12685
12686
12687 ### Use -lXpm if available, unless `--with-xpm=no'.
12688 HAVE_XPM=no
12689 LIBXPM=
12690 if test "${HAVE_X11}" = "yes"; then
12691 if test "${with_xpm}" != "no"; then
12692 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12693 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12695 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12696 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12697 $as_echo_n "(cached) " >&6
12698 else
12699 ac_check_lib_save_LIBS=$LIBS
12700 LIBS="-lXpm -lX11 $LIBS"
12701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12702 /* end confdefs.h. */
12703
12704 /* Override any GCC internal prototype to avoid an error.
12705 Use char because int might match the return type of a GCC
12706 builtin and then its argument prototype would still apply. */
12707 #ifdef __cplusplus
12708 extern "C"
12709 #endif
12710 char XpmReadFileToPixmap ();
12711 int
12712 main ()
12713 {
12714 return XpmReadFileToPixmap ();
12715 ;
12716 return 0;
12717 }
12718 _ACEOF
12719 if ac_fn_c_try_link "$LINENO"; then :
12720 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12721 else
12722 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12723 fi
12724 rm -f core conftest.err conftest.$ac_objext \
12725 conftest$ac_exeext conftest.$ac_ext
12726 LIBS=$ac_check_lib_save_LIBS
12727 fi
12728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12729 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12730 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12731 HAVE_XPM=yes
12732 fi
12733
12734 fi
12735
12736
12737 if test "${HAVE_XPM}" = "yes"; then
12738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12739 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12741 /* end confdefs.h. */
12742 #include "X11/xpm.h"
12743 #ifndef XpmReturnAllocPixels
12744 no_return_alloc_pixels
12745 #endif
12746
12747 _ACEOF
12748 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12749 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12750 HAVE_XPM=no
12751 else
12752 HAVE_XPM=yes
12753 fi
12754 rm -f conftest*
12755
12756
12757 if test "${HAVE_XPM}" = "yes"; then
12758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12759 $as_echo "yes" >&6; }
12760 else
12761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12762 $as_echo "no" >&6; }
12763 fi
12764 fi
12765 fi
12766
12767 if test "${HAVE_XPM}" = "yes"; then
12768
12769 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12770
12771 LIBXPM=-lXpm
12772 fi
12773 fi
12774
12775
12776 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12777 HAVE_JPEG=no
12778 LIBJPEG=
12779 if test "${HAVE_X11}" = "yes"; then
12780 if test "${with_jpeg}" != "no"; then
12781 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
12782 if test "x$ac_cv_header_jerror_h" = x""yes; then :
12783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
12784 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
12785 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
12786 $as_echo_n "(cached) " >&6
12787 else
12788 ac_check_lib_save_LIBS=$LIBS
12789 LIBS="-ljpeg $LIBS"
12790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12791 /* end confdefs.h. */
12792
12793 /* Override any GCC internal prototype to avoid an error.
12794 Use char because int might match the return type of a GCC
12795 builtin and then its argument prototype would still apply. */
12796 #ifdef __cplusplus
12797 extern "C"
12798 #endif
12799 char jpeg_destroy_compress ();
12800 int
12801 main ()
12802 {
12803 return jpeg_destroy_compress ();
12804 ;
12805 return 0;
12806 }
12807 _ACEOF
12808 if ac_fn_c_try_link "$LINENO"; then :
12809 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
12810 else
12811 ac_cv_lib_jpeg_jpeg_destroy_compress=no
12812 fi
12813 rm -f core conftest.err conftest.$ac_objext \
12814 conftest$ac_exeext conftest.$ac_ext
12815 LIBS=$ac_check_lib_save_LIBS
12816 fi
12817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
12818 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
12819 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
12820 HAVE_JPEG=yes
12821 fi
12822
12823 fi
12824
12825
12826 fi
12827
12828 if test "${HAVE_JPEG}" = "yes"; then
12829 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12830
12831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12832 /* end confdefs.h. */
12833 #include <jpeglib.h>
12834 version=JPEG_LIB_VERSION
12835
12836 _ACEOF
12837 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12838 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
12839 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
12840
12841 else
12842 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
12843 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
12844 HAVE_JPEG=no
12845 fi
12846 rm -f conftest*
12847
12848 fi
12849 if test "${HAVE_JPEG}" = "yes"; then
12850 LIBJPEG=-ljpeg
12851 fi
12852 fi
12853
12854
12855 ### Use -lpng if available, unless `--with-png=no'.
12856 HAVE_PNG=no
12857 LIBPNG=
12858 if test "${HAVE_X11}" = "yes"; then
12859 if test "${with_png}" != "no"; then
12860 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
12861 # in /usr/include/libpng.
12862 for ac_header in png.h libpng/png.h
12863 do :
12864 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12865 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
12866 eval as_val=\$$as_ac_Header
12867 if test "x$as_val" = x""yes; then :
12868 cat >>confdefs.h <<_ACEOF
12869 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12870 _ACEOF
12871
12872 fi
12873
12874 done
12875
12876 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
12877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
12878 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
12879 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
12880 $as_echo_n "(cached) " >&6
12881 else
12882 ac_check_lib_save_LIBS=$LIBS
12883 LIBS="-lpng -lz -lm $LIBS"
12884 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12885 /* end confdefs.h. */
12886
12887 /* Override any GCC internal prototype to avoid an error.
12888 Use char because int might match the return type of a GCC
12889 builtin and then its argument prototype would still apply. */
12890 #ifdef __cplusplus
12891 extern "C"
12892 #endif
12893 char png_get_channels ();
12894 int
12895 main ()
12896 {
12897 return png_get_channels ();
12898 ;
12899 return 0;
12900 }
12901 _ACEOF
12902 if ac_fn_c_try_link "$LINENO"; then :
12903 ac_cv_lib_png_png_get_channels=yes
12904 else
12905 ac_cv_lib_png_png_get_channels=no
12906 fi
12907 rm -f core conftest.err conftest.$ac_objext \
12908 conftest$ac_exeext conftest.$ac_ext
12909 LIBS=$ac_check_lib_save_LIBS
12910 fi
12911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
12912 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
12913 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
12914 HAVE_PNG=yes
12915 fi
12916
12917 fi
12918 fi
12919
12920 if test "${HAVE_PNG}" = "yes"; then
12921
12922 $as_echo "#define HAVE_PNG 1" >>confdefs.h
12923
12924 LIBPNG="-lpng -lz -lm"
12925 fi
12926 fi
12927
12928
12929 ### Use -ltiff if available, unless `--with-tiff=no'.
12930 HAVE_TIFF=no
12931 LIBTIFF=
12932 if test "${HAVE_X11}" = "yes"; then
12933 if test "${with_tiff}" != "no"; then
12934 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
12935 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
12936 tifflibs="-lz -lm"
12937 # At least one tiff package requires the jpeg library.
12938 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
12939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
12940 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
12941 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
12942 $as_echo_n "(cached) " >&6
12943 else
12944 ac_check_lib_save_LIBS=$LIBS
12945 LIBS="-ltiff $tifflibs $LIBS"
12946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12947 /* end confdefs.h. */
12948
12949 /* Override any GCC internal prototype to avoid an error.
12950 Use char because int might match the return type of a GCC
12951 builtin and then its argument prototype would still apply. */
12952 #ifdef __cplusplus
12953 extern "C"
12954 #endif
12955 char TIFFGetVersion ();
12956 int
12957 main ()
12958 {
12959 return TIFFGetVersion ();
12960 ;
12961 return 0;
12962 }
12963 _ACEOF
12964 if ac_fn_c_try_link "$LINENO"; then :
12965 ac_cv_lib_tiff_TIFFGetVersion=yes
12966 else
12967 ac_cv_lib_tiff_TIFFGetVersion=no
12968 fi
12969 rm -f core conftest.err conftest.$ac_objext \
12970 conftest$ac_exeext conftest.$ac_ext
12971 LIBS=$ac_check_lib_save_LIBS
12972 fi
12973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
12974 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
12975 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
12976 HAVE_TIFF=yes
12977 fi
12978
12979 fi
12980
12981
12982 fi
12983
12984 if test "${HAVE_TIFF}" = "yes"; then
12985
12986 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
12987
12988 LIBTIFF=-ltiff
12989 fi
12990 fi
12991
12992
12993 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
12994 HAVE_GIF=no
12995 LIBGIF=
12996 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
12997 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
12998 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
12999 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13000 # Earlier versions can crash Emacs.
13001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13002 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13003 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13004 $as_echo_n "(cached) " >&6
13005 else
13006 ac_check_lib_save_LIBS=$LIBS
13007 LIBS="-lgif $LIBS"
13008 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13009 /* end confdefs.h. */
13010
13011 /* Override any GCC internal prototype to avoid an error.
13012 Use char because int might match the return type of a GCC
13013 builtin and then its argument prototype would still apply. */
13014 #ifdef __cplusplus
13015 extern "C"
13016 #endif
13017 char EGifPutExtensionLast ();
13018 int
13019 main ()
13020 {
13021 return EGifPutExtensionLast ();
13022 ;
13023 return 0;
13024 }
13025 _ACEOF
13026 if ac_fn_c_try_link "$LINENO"; then :
13027 ac_cv_lib_gif_EGifPutExtensionLast=yes
13028 else
13029 ac_cv_lib_gif_EGifPutExtensionLast=no
13030 fi
13031 rm -f core conftest.err conftest.$ac_objext \
13032 conftest$ac_exeext conftest.$ac_ext
13033 LIBS=$ac_check_lib_save_LIBS
13034 fi
13035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13036 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13037 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13038 HAVE_GIF=yes
13039 else
13040 HAVE_GIF=maybe
13041 fi
13042
13043 fi
13044
13045
13046
13047 if test "$HAVE_GIF" = yes; then
13048 LIBGIF=-lgif
13049 elif test "$HAVE_GIF" = maybe; then
13050 # If gif_lib.h but no libgif, try libungif.
13051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13052 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13053 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13054 $as_echo_n "(cached) " >&6
13055 else
13056 ac_check_lib_save_LIBS=$LIBS
13057 LIBS="-lungif $LIBS"
13058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13059 /* end confdefs.h. */
13060
13061 /* Override any GCC internal prototype to avoid an error.
13062 Use char because int might match the return type of a GCC
13063 builtin and then its argument prototype would still apply. */
13064 #ifdef __cplusplus
13065 extern "C"
13066 #endif
13067 char EGifPutExtensionLast ();
13068 int
13069 main ()
13070 {
13071 return EGifPutExtensionLast ();
13072 ;
13073 return 0;
13074 }
13075 _ACEOF
13076 if ac_fn_c_try_link "$LINENO"; then :
13077 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13078 else
13079 ac_cv_lib_ungif_EGifPutExtensionLast=no
13080 fi
13081 rm -f core conftest.err conftest.$ac_objext \
13082 conftest$ac_exeext conftest.$ac_ext
13083 LIBS=$ac_check_lib_save_LIBS
13084 fi
13085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13086 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13087 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13088 HAVE_GIF=yes
13089 else
13090 HAVE_GIF=no
13091 fi
13092
13093 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13094 fi
13095
13096 if test "${HAVE_GIF}" = "yes"; then
13097
13098 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13099
13100 fi
13101 fi
13102
13103
13104 if test "${HAVE_X11}" = "yes"; then
13105 MISSING=""
13106 WITH_NO=""
13107 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13108 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13109 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13110 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13111 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13112 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13113 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13114 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13115 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13116 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13117
13118 if test "X${MISSING}" != X; then
13119 as_fn_error "The following required libraries were not found:
13120 $MISSING
13121 Maybe some development libraries/packages are missing?
13122 If you don't want to link with them give
13123 $WITH_NO
13124 as options to configure" "$LINENO" 5
13125 fi
13126 fi
13127
13128 ### Use -lgpm if available, unless `--with-gpm=no'.
13129 HAVE_GPM=no
13130 LIBGPM=
13131 if test "${with_gpm}" != "no"; then
13132 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13133 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13135 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13136 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13137 $as_echo_n "(cached) " >&6
13138 else
13139 ac_check_lib_save_LIBS=$LIBS
13140 LIBS="-lgpm $LIBS"
13141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13142 /* end confdefs.h. */
13143
13144 /* Override any GCC internal prototype to avoid an error.
13145 Use char because int might match the return type of a GCC
13146 builtin and then its argument prototype would still apply. */
13147 #ifdef __cplusplus
13148 extern "C"
13149 #endif
13150 char Gpm_Open ();
13151 int
13152 main ()
13153 {
13154 return Gpm_Open ();
13155 ;
13156 return 0;
13157 }
13158 _ACEOF
13159 if ac_fn_c_try_link "$LINENO"; then :
13160 ac_cv_lib_gpm_Gpm_Open=yes
13161 else
13162 ac_cv_lib_gpm_Gpm_Open=no
13163 fi
13164 rm -f core conftest.err conftest.$ac_objext \
13165 conftest$ac_exeext conftest.$ac_ext
13166 LIBS=$ac_check_lib_save_LIBS
13167 fi
13168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13169 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13170 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13171 HAVE_GPM=yes
13172 fi
13173
13174 fi
13175
13176
13177
13178 if test "${HAVE_GPM}" = "yes"; then
13179
13180 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13181
13182 LIBGPM=-lgpm
13183 fi
13184 fi
13185
13186
13187 ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
13188 if test "x$ac_cv_header_malloc_malloc_h" = x""yes; then :
13189
13190 $as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
13191
13192 fi
13193
13194
13195
13196 C_SWITCH_X_SYSTEM=
13197 ### Use NeXTstep API to implement GUI.
13198 if test "${HAVE_NS}" = "yes"; then
13199
13200 $as_echo "#define HAVE_NS 1" >>confdefs.h
13201
13202 if test "${NS_IMPL_COCOA}" = "yes"; then
13203
13204 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13205
13206 GNU_OBJC_CFLAGS=
13207 fi
13208 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13209
13210 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13211
13212 # See also .m.o rule in Makefile.in */
13213 # FIXME: are all these flags really needed? Document here why. */
13214 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing"
13215 GNU_OBJC_CFLAGS="-fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
13216 fi
13217 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
13218
13219 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
13220
13221 fi
13222 # We also have mouse menus.
13223 HAVE_MENUS=yes
13224 OTHER_FILES=ns-app
13225 fi
13226
13227
13228 ### Use session management (-lSM -lICE) if available
13229 HAVE_X_SM=no
13230 LIBXSM=
13231 if test "${HAVE_X11}" = "yes"; then
13232 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13233 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13235 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13236 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13237 $as_echo_n "(cached) " >&6
13238 else
13239 ac_check_lib_save_LIBS=$LIBS
13240 LIBS="-lSM -lICE $LIBS"
13241 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13242 /* end confdefs.h. */
13243
13244 /* Override any GCC internal prototype to avoid an error.
13245 Use char because int might match the return type of a GCC
13246 builtin and then its argument prototype would still apply. */
13247 #ifdef __cplusplus
13248 extern "C"
13249 #endif
13250 char SmcOpenConnection ();
13251 int
13252 main ()
13253 {
13254 return SmcOpenConnection ();
13255 ;
13256 return 0;
13257 }
13258 _ACEOF
13259 if ac_fn_c_try_link "$LINENO"; then :
13260 ac_cv_lib_SM_SmcOpenConnection=yes
13261 else
13262 ac_cv_lib_SM_SmcOpenConnection=no
13263 fi
13264 rm -f core conftest.err conftest.$ac_objext \
13265 conftest$ac_exeext conftest.$ac_ext
13266 LIBS=$ac_check_lib_save_LIBS
13267 fi
13268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13269 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13270 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13271 HAVE_X_SM=yes
13272 fi
13273
13274 fi
13275
13276
13277
13278 if test "${HAVE_X_SM}" = "yes"; then
13279
13280 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13281
13282 LIBXSM="-lSM -lICE"
13283 case "$LIBS" in
13284 *-lSM*) ;;
13285 *) LIBS="$LIBXSM $LIBS" ;;
13286 esac
13287 fi
13288 fi
13289
13290
13291 ### Use libxml (-lxml2) if available
13292 if test "${with_xml2}" != "no"; then
13293 ### I'm not sure what the version number should be, so I just guessed.
13294
13295 succeeded=no
13296
13297 # Extract the first word of "pkg-config", so it can be a program name with args.
13298 set dummy pkg-config; ac_word=$2
13299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13300 $as_echo_n "checking for $ac_word... " >&6; }
13301 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
13302 $as_echo_n "(cached) " >&6
13303 else
13304 case $PKG_CONFIG in
13305 [\\/]* | ?:[\\/]*)
13306 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
13307 ;;
13308 *)
13309 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13310 for as_dir in $PATH
13311 do
13312 IFS=$as_save_IFS
13313 test -z "$as_dir" && as_dir=.
13314 for ac_exec_ext in '' $ac_executable_extensions; do
13315 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13316 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
13317 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13318 break 2
13319 fi
13320 done
13321 done
13322 IFS=$as_save_IFS
13323
13324 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
13325 ;;
13326 esac
13327 fi
13328 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
13329 if test -n "$PKG_CONFIG"; then
13330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
13331 $as_echo "$PKG_CONFIG" >&6; }
13332 else
13333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13334 $as_echo "no" >&6; }
13335 fi
13336
13337
13338
13339 if test "$PKG_CONFIG" = "no" ; then
13340 HAVE_LIBXML2=no
13341 else
13342 PKG_CONFIG_MIN_VERSION=0.9.0
13343 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13345 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13346
13347 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5; then
13348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13349 $as_echo "yes" >&6; }
13350 succeeded=yes
13351
13352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_CFLAGS" >&5
13353 $as_echo_n "checking LIBXML2_CFLAGS... " >&6; }
13354 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
13355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_CFLAGS" >&5
13356 $as_echo "$LIBXML2_CFLAGS" >&6; }
13357
13358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBXML2_LIBS" >&5
13359 $as_echo_n "checking LIBXML2_LIBS... " >&6; }
13360 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17"|sed -e 's,///*,/,g'`
13361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBXML2_LIBS" >&5
13362 $as_echo "$LIBXML2_LIBS" >&6; }
13363 else
13364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13365 $as_echo "no" >&6; }
13366 LIBXML2_CFLAGS=""
13367 LIBXML2_LIBS=""
13368 ## If we have a custom action on failure, don't print errors, but
13369 ## do set a variable so people can do so.
13370 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
13371
13372 fi
13373
13374
13375
13376 else
13377 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13378 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13379 fi
13380 fi
13381
13382 if test $succeeded = yes; then
13383 HAVE_LIBXML2=yes
13384 else
13385 HAVE_LIBXML2=no
13386 fi
13387
13388 if test "${HAVE_LIBXML2}" = "yes"; then
13389 LIBS="$LIBXML2_LIBS $LIBS"
13390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13391 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13392 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13393 $as_echo_n "(cached) " >&6
13394 else
13395 ac_check_lib_save_LIBS=$LIBS
13396 LIBS="-lxml2 $LIBS"
13397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13398 /* end confdefs.h. */
13399
13400 /* Override any GCC internal prototype to avoid an error.
13401 Use char because int might match the return type of a GCC
13402 builtin and then its argument prototype would still apply. */
13403 #ifdef __cplusplus
13404 extern "C"
13405 #endif
13406 char htmlReadMemory ();
13407 int
13408 main ()
13409 {
13410 return htmlReadMemory ();
13411 ;
13412 return 0;
13413 }
13414 _ACEOF
13415 if ac_fn_c_try_link "$LINENO"; then :
13416 ac_cv_lib_xml2_htmlReadMemory=yes
13417 else
13418 ac_cv_lib_xml2_htmlReadMemory=no
13419 fi
13420 rm -f core conftest.err conftest.$ac_objext \
13421 conftest$ac_exeext conftest.$ac_ext
13422 LIBS=$ac_check_lib_save_LIBS
13423 fi
13424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13425 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13426 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13427 HAVE_LIBXML2=yes
13428 else
13429 HAVE_LIBXML2=no
13430 fi
13431
13432 if test "${HAVE_LIBXML2}" = "yes"; then
13433
13434 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13435
13436 else
13437 LIBXML2_LIBS=""
13438 LIBXML2_CFLAGS=""
13439 fi
13440 fi
13441 fi
13442
13443
13444
13445 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13447 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13448 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13449 $as_echo_n "(cached) " >&6
13450 else
13451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13452 /* end confdefs.h. */
13453 #include <netdb.h>
13454 int
13455 main ()
13456 {
13457 return h_errno;
13458 ;
13459 return 0;
13460 }
13461 _ACEOF
13462 if ac_fn_c_try_link "$LINENO"; then :
13463 emacs_cv_netdb_declares_h_errno=yes
13464 else
13465 emacs_cv_netdb_declares_h_errno=no
13466 fi
13467 rm -f core conftest.err conftest.$ac_objext \
13468 conftest$ac_exeext conftest.$ac_ext
13469 fi
13470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13471 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13472 if test $emacs_cv_netdb_declares_h_errno = yes; then
13473
13474 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13475
13476 fi
13477
13478 # fmod, logb, and frexp are found in -lm on most systems.
13479 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
13480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13481 $as_echo_n "checking for sqrt in -lm... " >&6; }
13482 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13483 $as_echo_n "(cached) " >&6
13484 else
13485 ac_check_lib_save_LIBS=$LIBS
13486 LIBS="-lm $LIBS"
13487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13488 /* end confdefs.h. */
13489
13490 /* Override any GCC internal prototype to avoid an error.
13491 Use char because int might match the return type of a GCC
13492 builtin and then its argument prototype would still apply. */
13493 #ifdef __cplusplus
13494 extern "C"
13495 #endif
13496 char sqrt ();
13497 int
13498 main ()
13499 {
13500 return sqrt ();
13501 ;
13502 return 0;
13503 }
13504 _ACEOF
13505 if ac_fn_c_try_link "$LINENO"; then :
13506 ac_cv_lib_m_sqrt=yes
13507 else
13508 ac_cv_lib_m_sqrt=no
13509 fi
13510 rm -f core conftest.err conftest.$ac_objext \
13511 conftest$ac_exeext conftest.$ac_ext
13512 LIBS=$ac_check_lib_save_LIBS
13513 fi
13514 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13515 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13516 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13517 cat >>confdefs.h <<_ACEOF
13518 #define HAVE_LIBM 1
13519 _ACEOF
13520
13521 LIBS="-lm $LIBS"
13522
13523 fi
13524
13525
13526 # Check for mail-locking functions in a "mail" library. Probably this should
13527 # have the same check as for liblockfile below.
13528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13529 $as_echo_n "checking for maillock in -lmail... " >&6; }
13530 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13531 $as_echo_n "(cached) " >&6
13532 else
13533 ac_check_lib_save_LIBS=$LIBS
13534 LIBS="-lmail $LIBS"
13535 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13536 /* end confdefs.h. */
13537
13538 /* Override any GCC internal prototype to avoid an error.
13539 Use char because int might match the return type of a GCC
13540 builtin and then its argument prototype would still apply. */
13541 #ifdef __cplusplus
13542 extern "C"
13543 #endif
13544 char maillock ();
13545 int
13546 main ()
13547 {
13548 return maillock ();
13549 ;
13550 return 0;
13551 }
13552 _ACEOF
13553 if ac_fn_c_try_link "$LINENO"; then :
13554 ac_cv_lib_mail_maillock=yes
13555 else
13556 ac_cv_lib_mail_maillock=no
13557 fi
13558 rm -f core conftest.err conftest.$ac_objext \
13559 conftest$ac_exeext conftest.$ac_ext
13560 LIBS=$ac_check_lib_save_LIBS
13561 fi
13562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13563 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13564 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13565 have_mail=yes
13566 else
13567 have_mail=no
13568 fi
13569
13570 if test $have_mail = yes; then
13571 LIBS_MAIL=-lmail
13572 LIBS="$LIBS_MAIL $LIBS"
13573
13574 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13575
13576 else
13577 LIBS_MAIL=
13578 fi
13579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13580 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13581 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13582 $as_echo_n "(cached) " >&6
13583 else
13584 ac_check_lib_save_LIBS=$LIBS
13585 LIBS="-llockfile $LIBS"
13586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13587 /* end confdefs.h. */
13588
13589 /* Override any GCC internal prototype to avoid an error.
13590 Use char because int might match the return type of a GCC
13591 builtin and then its argument prototype would still apply. */
13592 #ifdef __cplusplus
13593 extern "C"
13594 #endif
13595 char maillock ();
13596 int
13597 main ()
13598 {
13599 return maillock ();
13600 ;
13601 return 0;
13602 }
13603 _ACEOF
13604 if ac_fn_c_try_link "$LINENO"; then :
13605 ac_cv_lib_lockfile_maillock=yes
13606 else
13607 ac_cv_lib_lockfile_maillock=no
13608 fi
13609 rm -f core conftest.err conftest.$ac_objext \
13610 conftest$ac_exeext conftest.$ac_ext
13611 LIBS=$ac_check_lib_save_LIBS
13612 fi
13613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13614 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13615 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13616 have_lockfile=yes
13617 else
13618 have_lockfile=no
13619 fi
13620
13621 if test $have_lockfile = yes; then
13622 LIBS_MAIL=-llockfile
13623 LIBS="$LIBS_MAIL $LIBS"
13624
13625 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13626
13627 else
13628 # If we have the shared liblockfile, assume we must use it for mail
13629 # locking (e.g. Debian). If we couldn't link against liblockfile
13630 # (no liblockfile.a installed), ensure that we don't need to.
13631 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13632 set dummy liblockfile.so; ac_word=$2
13633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13634 $as_echo_n "checking for $ac_word... " >&6; }
13635 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13636 $as_echo_n "(cached) " >&6
13637 else
13638 if test -n "$liblockfile"; then
13639 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13640 else
13641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13642 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13643 for as_dir in $as_dummy
13644 do
13645 IFS=$as_save_IFS
13646 test -z "$as_dir" && as_dir=.
13647 for ac_exec_ext in '' $ac_executable_extensions; do
13648 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13649 ac_cv_prog_liblockfile="yes"
13650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13651 break 2
13652 fi
13653 done
13654 done
13655 IFS=$as_save_IFS
13656
13657 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13658 fi
13659 fi
13660 liblockfile=$ac_cv_prog_liblockfile
13661 if test -n "$liblockfile"; then
13662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13663 $as_echo "$liblockfile" >&6; }
13664 else
13665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13666 $as_echo "no" >&6; }
13667 fi
13668
13669
13670 if test $ac_cv_prog_liblockfile = yes; then
13671 as_fn_error "Shared liblockfile found but can't link against it.
13672 This probably means that movemail could lose mail.
13673 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13674 fi
13675 fi
13676 for ac_func in touchlock
13677 do :
13678 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
13679 if test "x$ac_cv_func_touchlock" = x""yes; then :
13680 cat >>confdefs.h <<_ACEOF
13681 #define HAVE_TOUCHLOCK 1
13682 _ACEOF
13683
13684 fi
13685 done
13686
13687 for ac_header in maillock.h
13688 do :
13689 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
13690 if test "x$ac_cv_header_maillock_h" = x""yes; then :
13691 cat >>confdefs.h <<_ACEOF
13692 #define HAVE_MAILLOCK_H 1
13693 _ACEOF
13694
13695 fi
13696
13697 done
13698
13699
13700
13701 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13702 ## interlock access to the mail spool. The alternative is a lock file named
13703 ## /usr/spool/mail/$USER.lock.
13704 mail_lock=no
13705 case "$opsys" in
13706 aix4-2) mail_lock="lockf" ;;
13707
13708 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13709
13710 ## On GNU/Linux systems, both methods are used by various mail programs.
13711 ## I assume most people are using newer mailers that have heard of flock.
13712 ## Change this if you need to.
13713 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13714 ## configure gets the right answers, and that means *NOT* using flock.
13715 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13716 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13717 ## Debian maintainer hasn't provided a clean fix for Emacs.
13718 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13719 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13720 ## correct logic. -- fx
13721 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13722 ## liblockfile is a Free Software replacement for libmail, used on
13723 ## Debian systems and elsewhere. -rfr.
13724 gnu-*)
13725 mail_lock="flock"
13726 if test $have_mail = yes || test $have_lockfile = yes; then
13727 test $ac_cv_header_maillock_h = yes && mail_lock=no
13728 fi
13729 ;;
13730 esac
13731
13732 BLESSMAIL_TARGET=
13733 case "$mail_lock" in
13734 flock)
13735 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13736 ;;
13737
13738 lockf)
13739 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13740 ;;
13741
13742 *) BLESSMAIL_TARGET="need-blessmail" ;;
13743 esac
13744
13745
13746
13747 for ac_func in gethostname getdomainname \
13748 rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
13749 random lrand48 logb frexp fmod rint cbrt ftime setsid \
13750 strerror fpathconf select euidaccess getpagesize tzset setlocale \
13751 utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
13752 __fpending mblen mbrlen mbsinit strsignal setitimer ualarm strchr strrchr \
13753 sendto recvfrom getsockopt setsockopt getsockname getpeername \
13754 gai_strerror mkstemp getline getdelim mremap memmove fsync sync \
13755 memset memcmp difftime memcpy mempcpy mblen mbrlen posix_memalign \
13756 cfmakeraw cfsetspeed isnan copysign __executable_start
13757 do :
13758 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13759 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13760 eval as_val=\$$as_ac_var
13761 if test "x$as_val" = x""yes; then :
13762 cat >>confdefs.h <<_ACEOF
13763 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13764 _ACEOF
13765
13766 fi
13767 done
13768
13769
13770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13771 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13772 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13773 $as_echo_n "(cached) " >&6
13774 else
13775 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13776 /* end confdefs.h. */
13777
13778 int
13779 main ()
13780 {
13781 __builtin_unwind_init ();
13782 ;
13783 return 0;
13784 }
13785 _ACEOF
13786 if ac_fn_c_try_link "$LINENO"; then :
13787 emacs_cv_func___builtin_unwind_init=yes
13788 else
13789 emacs_cv_func___builtin_unwind_init=no
13790 fi
13791 rm -f core conftest.err conftest.$ac_objext \
13792 conftest$ac_exeext conftest.$ac_ext
13793 fi
13794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
13795 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
13796 if test $emacs_cv_func___builtin_unwind_init = yes; then
13797
13798 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
13799
13800 fi
13801
13802 for ac_header in sys/un.h
13803 do :
13804 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
13805 if test "x$ac_cv_header_sys_un_h" = x""yes; then :
13806 cat >>confdefs.h <<_ACEOF
13807 #define HAVE_SYS_UN_H 1
13808 _ACEOF
13809
13810 fi
13811
13812 done
13813
13814
13815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
13816 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
13817 if test "${ac_cv_sys_largefile_source+set}" = set; then :
13818 $as_echo_n "(cached) " >&6
13819 else
13820 while :; do
13821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13822 /* end confdefs.h. */
13823 #include <sys/types.h> /* for off_t */
13824 #include <stdio.h>
13825 int
13826 main ()
13827 {
13828 int (*fp) (FILE *, off_t, int) = fseeko;
13829 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13830 ;
13831 return 0;
13832 }
13833 _ACEOF
13834 if ac_fn_c_try_link "$LINENO"; then :
13835 ac_cv_sys_largefile_source=no; break
13836 fi
13837 rm -f core conftest.err conftest.$ac_objext \
13838 conftest$ac_exeext conftest.$ac_ext
13839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13840 /* end confdefs.h. */
13841 #define _LARGEFILE_SOURCE 1
13842 #include <sys/types.h> /* for off_t */
13843 #include <stdio.h>
13844 int
13845 main ()
13846 {
13847 int (*fp) (FILE *, off_t, int) = fseeko;
13848 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
13849 ;
13850 return 0;
13851 }
13852 _ACEOF
13853 if ac_fn_c_try_link "$LINENO"; then :
13854 ac_cv_sys_largefile_source=1; break
13855 fi
13856 rm -f core conftest.err conftest.$ac_objext \
13857 conftest$ac_exeext conftest.$ac_ext
13858 ac_cv_sys_largefile_source=unknown
13859 break
13860 done
13861 fi
13862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
13863 $as_echo "$ac_cv_sys_largefile_source" >&6; }
13864 case $ac_cv_sys_largefile_source in #(
13865 no | unknown) ;;
13866 *)
13867 cat >>confdefs.h <<_ACEOF
13868 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
13869 _ACEOF
13870 ;;
13871 esac
13872 rm -rf conftest*
13873
13874 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
13875 # in glibc 2.1.3, but that breaks too many other things.
13876 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
13877 if test $ac_cv_sys_largefile_source != unknown; then
13878
13879 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
13880
13881 fi
13882
13883
13884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
13885 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
13886 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
13887 $as_echo_n "(cached) " >&6
13888 else
13889 # Use it with a single arg.
13890 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13891 /* end confdefs.h. */
13892 $ac_includes_default
13893 int
13894 main ()
13895 {
13896 getpgrp (0);
13897 ;
13898 return 0;
13899 }
13900 _ACEOF
13901 if ac_fn_c_try_compile "$LINENO"; then :
13902 ac_cv_func_getpgrp_void=no
13903 else
13904 ac_cv_func_getpgrp_void=yes
13905 fi
13906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13907
13908 fi
13909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
13910 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
13911 if test $ac_cv_func_getpgrp_void = yes; then
13912
13913 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
13914
13915 fi
13916
13917
13918 # Configure gnulib.
13919
13920
13921
13922
13923
13924
13925
13926
13927
13928
13929 LIBC_FATAL_STDERR_=1
13930 export LIBC_FATAL_STDERR_
13931
13932 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
13933 # for constant arguments. Useless!
13934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
13935 $as_echo_n "checking for working alloca.h... " >&6; }
13936 if test "${ac_cv_working_alloca_h+set}" = set; then :
13937 $as_echo_n "(cached) " >&6
13938 else
13939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13940 /* end confdefs.h. */
13941 #include <alloca.h>
13942 int
13943 main ()
13944 {
13945 char *p = (char *) alloca (2 * sizeof (int));
13946 if (p) return 0;
13947 ;
13948 return 0;
13949 }
13950 _ACEOF
13951 if ac_fn_c_try_link "$LINENO"; then :
13952 ac_cv_working_alloca_h=yes
13953 else
13954 ac_cv_working_alloca_h=no
13955 fi
13956 rm -f core conftest.err conftest.$ac_objext \
13957 conftest$ac_exeext conftest.$ac_ext
13958 fi
13959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
13960 $as_echo "$ac_cv_working_alloca_h" >&6; }
13961 if test $ac_cv_working_alloca_h = yes; then
13962
13963 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
13964
13965 fi
13966
13967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
13968 $as_echo_n "checking for alloca... " >&6; }
13969 if test "${ac_cv_func_alloca_works+set}" = set; then :
13970 $as_echo_n "(cached) " >&6
13971 else
13972 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13973 /* end confdefs.h. */
13974 #ifdef __GNUC__
13975 # define alloca __builtin_alloca
13976 #else
13977 # ifdef _MSC_VER
13978 # include <malloc.h>
13979 # define alloca _alloca
13980 # else
13981 # ifdef HAVE_ALLOCA_H
13982 # include <alloca.h>
13983 # else
13984 # ifdef _AIX
13985 #pragma alloca
13986 # else
13987 # ifndef alloca /* predefined by HP cc +Olibcalls */
13988 char *alloca ();
13989 # endif
13990 # endif
13991 # endif
13992 # endif
13993 #endif
13994
13995 int
13996 main ()
13997 {
13998 char *p = (char *) alloca (1);
13999 if (p) return 0;
14000 ;
14001 return 0;
14002 }
14003 _ACEOF
14004 if ac_fn_c_try_link "$LINENO"; then :
14005 ac_cv_func_alloca_works=yes
14006 else
14007 ac_cv_func_alloca_works=no
14008 fi
14009 rm -f core conftest.err conftest.$ac_objext \
14010 conftest$ac_exeext conftest.$ac_ext
14011 fi
14012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
14013 $as_echo "$ac_cv_func_alloca_works" >&6; }
14014
14015 if test $ac_cv_func_alloca_works = yes; then
14016
14017 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
14018
14019 else
14020 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
14021 # that cause trouble. Some versions do not even contain alloca or
14022 # contain a buggy version. If you still want to use their alloca,
14023 # use ar to extract alloca.o from them instead of compiling alloca.c.
14024
14025
14026
14027
14028
14029 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
14030
14031 $as_echo "#define C_ALLOCA 1" >>confdefs.h
14032
14033
14034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
14035 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
14036 if test "${ac_cv_os_cray+set}" = set; then :
14037 $as_echo_n "(cached) " >&6
14038 else
14039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14040 /* end confdefs.h. */
14041 #if defined CRAY && ! defined CRAY2
14042 webecray
14043 #else
14044 wenotbecray
14045 #endif
14046
14047 _ACEOF
14048 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14049 $EGREP "webecray" >/dev/null 2>&1; then :
14050 ac_cv_os_cray=yes
14051 else
14052 ac_cv_os_cray=no
14053 fi
14054 rm -f conftest*
14055
14056 fi
14057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
14058 $as_echo "$ac_cv_os_cray" >&6; }
14059 if test $ac_cv_os_cray = yes; then
14060 for ac_func in _getb67 GETB67 getb67; do
14061 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14062 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14063 eval as_val=\$$as_ac_var
14064 if test "x$as_val" = x""yes; then :
14065
14066 cat >>confdefs.h <<_ACEOF
14067 #define CRAY_STACKSEG_END $ac_func
14068 _ACEOF
14069
14070 break
14071 fi
14072
14073 done
14074 fi
14075
14076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
14077 $as_echo_n "checking stack direction for C alloca... " >&6; }
14078 if test "${ac_cv_c_stack_direction+set}" = set; then :
14079 $as_echo_n "(cached) " >&6
14080 else
14081 if test "$cross_compiling" = yes; then :
14082 ac_cv_c_stack_direction=0
14083 else
14084 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14085 /* end confdefs.h. */
14086 $ac_includes_default
14087 int
14088 find_stack_direction (int *addr, int depth)
14089 {
14090 int dir, dummy = 0;
14091 if (! addr)
14092 addr = &dummy;
14093 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
14094 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
14095 return dir + dummy;
14096 }
14097
14098 int
14099 main (int argc, char **argv)
14100 {
14101 return find_stack_direction (0, argc + !argv + 20) < 0;
14102 }
14103 _ACEOF
14104 if ac_fn_c_try_run "$LINENO"; then :
14105 ac_cv_c_stack_direction=1
14106 else
14107 ac_cv_c_stack_direction=-1
14108 fi
14109 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14110 conftest.$ac_objext conftest.beam conftest.$ac_ext
14111 fi
14112
14113 fi
14114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
14115 $as_echo "$ac_cv_c_stack_direction" >&6; }
14116 cat >>confdefs.h <<_ACEOF
14117 #define STACK_DIRECTION $ac_cv_c_stack_direction
14118 _ACEOF
14119
14120
14121 fi
14122
14123
14124
14125
14126 for ac_func in $ac_func_list
14127 do :
14128 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14129 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14130 eval as_val=\$$as_ac_var
14131 if test "x$as_val" = x""yes; then :
14132 cat >>confdefs.h <<_ACEOF
14133 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14134 _ACEOF
14135
14136 fi
14137 done
14138
14139
14140
14141
14142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
14143 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14144 if test "${ac_cv_c_bigendian+set}" = set; then :
14145 $as_echo_n "(cached) " >&6
14146 else
14147 ac_cv_c_bigendian=unknown
14148 # See if we're dealing with a universal compiler.
14149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14150 /* end confdefs.h. */
14151 #ifndef __APPLE_CC__
14152 not a universal capable compiler
14153 #endif
14154 typedef int dummy;
14155
14156 _ACEOF
14157 if ac_fn_c_try_compile "$LINENO"; then :
14158
14159 # Check for potential -arch flags. It is not universal unless
14160 # there are at least two -arch flags with different values.
14161 ac_arch=
14162 ac_prev=
14163 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
14164 if test -n "$ac_prev"; then
14165 case $ac_word in
14166 i?86 | x86_64 | ppc | ppc64)
14167 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
14168 ac_arch=$ac_word
14169 else
14170 ac_cv_c_bigendian=universal
14171 break
14172 fi
14173 ;;
14174 esac
14175 ac_prev=
14176 elif test "x$ac_word" = "x-arch"; then
14177 ac_prev=arch
14178 fi
14179 done
14180 fi
14181 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14182 if test $ac_cv_c_bigendian = unknown; then
14183 # See if sys/param.h defines the BYTE_ORDER macro.
14184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14185 /* end confdefs.h. */
14186 #include <sys/types.h>
14187 #include <sys/param.h>
14188
14189 int
14190 main ()
14191 {
14192 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14193 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14194 && LITTLE_ENDIAN)
14195 bogus endian macros
14196 #endif
14197
14198 ;
14199 return 0;
14200 }
14201 _ACEOF
14202 if ac_fn_c_try_compile "$LINENO"; then :
14203 # It does; now see whether it defined to BIG_ENDIAN or not.
14204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14205 /* end confdefs.h. */
14206 #include <sys/types.h>
14207 #include <sys/param.h>
14208
14209 int
14210 main ()
14211 {
14212 #if BYTE_ORDER != BIG_ENDIAN
14213 not big endian
14214 #endif
14215
14216 ;
14217 return 0;
14218 }
14219 _ACEOF
14220 if ac_fn_c_try_compile "$LINENO"; then :
14221 ac_cv_c_bigendian=yes
14222 else
14223 ac_cv_c_bigendian=no
14224 fi
14225 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14226 fi
14227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14228 fi
14229 if test $ac_cv_c_bigendian = unknown; then
14230 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14232 /* end confdefs.h. */
14233 #include <limits.h>
14234
14235 int
14236 main ()
14237 {
14238 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14239 bogus endian macros
14240 #endif
14241
14242 ;
14243 return 0;
14244 }
14245 _ACEOF
14246 if ac_fn_c_try_compile "$LINENO"; then :
14247 # It does; now see whether it defined to _BIG_ENDIAN or not.
14248 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14249 /* end confdefs.h. */
14250 #include <limits.h>
14251
14252 int
14253 main ()
14254 {
14255 #ifndef _BIG_ENDIAN
14256 not big endian
14257 #endif
14258
14259 ;
14260 return 0;
14261 }
14262 _ACEOF
14263 if ac_fn_c_try_compile "$LINENO"; then :
14264 ac_cv_c_bigendian=yes
14265 else
14266 ac_cv_c_bigendian=no
14267 fi
14268 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14269 fi
14270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14271 fi
14272 if test $ac_cv_c_bigendian = unknown; then
14273 # Compile a test program.
14274 if test "$cross_compiling" = yes; then :
14275 # Try to guess by grepping values from an object file.
14276 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14277 /* end confdefs.h. */
14278 short int ascii_mm[] =
14279 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14280 short int ascii_ii[] =
14281 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14282 int use_ascii (int i) {
14283 return ascii_mm[i] + ascii_ii[i];
14284 }
14285 short int ebcdic_ii[] =
14286 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14287 short int ebcdic_mm[] =
14288 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14289 int use_ebcdic (int i) {
14290 return ebcdic_mm[i] + ebcdic_ii[i];
14291 }
14292 extern int foo;
14293
14294 int
14295 main ()
14296 {
14297 return use_ascii (foo) == use_ebcdic (foo);
14298 ;
14299 return 0;
14300 }
14301 _ACEOF
14302 if ac_fn_c_try_compile "$LINENO"; then :
14303 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14304 ac_cv_c_bigendian=yes
14305 fi
14306 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14307 if test "$ac_cv_c_bigendian" = unknown; then
14308 ac_cv_c_bigendian=no
14309 else
14310 # finding both strings is unlikely to happen, but who knows?
14311 ac_cv_c_bigendian=unknown
14312 fi
14313 fi
14314 fi
14315 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14316 else
14317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14318 /* end confdefs.h. */
14319 $ac_includes_default
14320 int
14321 main ()
14322 {
14323
14324 /* Are we little or big endian? From Harbison&Steele. */
14325 union
14326 {
14327 long int l;
14328 char c[sizeof (long int)];
14329 } u;
14330 u.l = 1;
14331 return u.c[sizeof (long int) - 1] == 1;
14332
14333 ;
14334 return 0;
14335 }
14336 _ACEOF
14337 if ac_fn_c_try_run "$LINENO"; then :
14338 ac_cv_c_bigendian=no
14339 else
14340 ac_cv_c_bigendian=yes
14341 fi
14342 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14343 conftest.$ac_objext conftest.beam conftest.$ac_ext
14344 fi
14345
14346 fi
14347 fi
14348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
14349 $as_echo "$ac_cv_c_bigendian" >&6; }
14350 case $ac_cv_c_bigendian in #(
14351 yes)
14352 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
14353 ;; #(
14354 no)
14355 ;; #(
14356 universal)
14357
14358 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
14359
14360 ;; #(
14361 *)
14362 as_fn_error "unknown endianness
14363 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
14364 esac
14365
14366
14367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
14368 $as_echo_n "checking for inline... " >&6; }
14369 if test "${ac_cv_c_inline+set}" = set; then :
14370 $as_echo_n "(cached) " >&6
14371 else
14372 ac_cv_c_inline=no
14373 for ac_kw in inline __inline__ __inline; do
14374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14375 /* end confdefs.h. */
14376 #ifndef __cplusplus
14377 typedef int foo_t;
14378 static $ac_kw foo_t static_foo () {return 0; }
14379 $ac_kw foo_t foo () {return 0; }
14380 #endif
14381
14382 _ACEOF
14383 if ac_fn_c_try_compile "$LINENO"; then :
14384 ac_cv_c_inline=$ac_kw
14385 fi
14386 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14387 test "$ac_cv_c_inline" != no && break
14388 done
14389
14390 fi
14391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
14392 $as_echo "$ac_cv_c_inline" >&6; }
14393
14394 case $ac_cv_c_inline in
14395 inline | yes) ;;
14396 *)
14397 case $ac_cv_c_inline in
14398 no) ac_val=;;
14399 *) ac_val=$ac_cv_c_inline;;
14400 esac
14401 cat >>confdefs.h <<_ACEOF
14402 #ifndef __cplusplus
14403 #define inline $ac_val
14404 #endif
14405 _ACEOF
14406 ;;
14407 esac
14408
14409
14410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
14411 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
14412 if test "${gl_cv_func_c99_strtold+set}" = set; then :
14413 $as_echo_n "(cached) " >&6
14414 else
14415 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14416 /* end confdefs.h. */
14417 /* On HP-UX before 11.23, strtold returns a struct instead of
14418 long double. Reject implementations like that, by requiring
14419 compatibility with the C99 prototype. */
14420 #include <stdlib.h>
14421 static long double (*p) (char const *, char **) = strtold;
14422 static long double
14423 test (char const *nptr, char **endptr)
14424 {
14425 long double r;
14426 r = strtold (nptr, endptr);
14427 return r;
14428 }
14429 int
14430 main ()
14431 {
14432 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
14433 ;
14434 return 0;
14435 }
14436 _ACEOF
14437 if ac_fn_c_try_link "$LINENO"; then :
14438 gl_cv_func_c99_strtold=yes
14439 else
14440 gl_cv_func_c99_strtold=no
14441 fi
14442 rm -f core conftest.err conftest.$ac_objext \
14443 conftest$ac_exeext conftest.$ac_ext
14444 fi
14445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
14446 $as_echo "$gl_cv_func_c99_strtold" >&6; }
14447 if test $gl_cv_func_c99_strtold = yes; then
14448
14449 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
14450
14451 fi
14452
14453
14454 GNULIB_CHOWN=0;
14455 GNULIB_CLOSE=0;
14456 GNULIB_DUP2=0;
14457 GNULIB_DUP3=0;
14458 GNULIB_ENVIRON=0;
14459 GNULIB_EUIDACCESS=0;
14460 GNULIB_FACCESSAT=0;
14461 GNULIB_FCHDIR=0;
14462 GNULIB_FCHOWNAT=0;
14463 GNULIB_FSYNC=0;
14464 GNULIB_FTRUNCATE=0;
14465 GNULIB_GETCWD=0;
14466 GNULIB_GETDOMAINNAME=0;
14467 GNULIB_GETDTABLESIZE=0;
14468 GNULIB_GETGROUPS=0;
14469 GNULIB_GETHOSTNAME=0;
14470 GNULIB_GETLOGIN=0;
14471 GNULIB_GETLOGIN_R=0;
14472 GNULIB_GETPAGESIZE=0;
14473 GNULIB_GETUSERSHELL=0;
14474 GNULIB_GROUP_MEMBER=0;
14475 GNULIB_LCHOWN=0;
14476 GNULIB_LINK=0;
14477 GNULIB_LINKAT=0;
14478 GNULIB_LSEEK=0;
14479 GNULIB_PIPE=0;
14480 GNULIB_PIPE2=0;
14481 GNULIB_PREAD=0;
14482 GNULIB_PWRITE=0;
14483 GNULIB_READ=0;
14484 GNULIB_READLINK=0;
14485 GNULIB_READLINKAT=0;
14486 GNULIB_RMDIR=0;
14487 GNULIB_SLEEP=0;
14488 GNULIB_SYMLINK=0;
14489 GNULIB_SYMLINKAT=0;
14490 GNULIB_TTYNAME_R=0;
14491 GNULIB_UNISTD_H_GETOPT=0;
14492 GNULIB_UNISTD_H_NONBLOCKING=0;
14493 GNULIB_UNISTD_H_SIGPIPE=0;
14494 GNULIB_UNLINK=0;
14495 GNULIB_UNLINKAT=0;
14496 GNULIB_USLEEP=0;
14497 GNULIB_WRITE=0;
14498 HAVE_CHOWN=1;
14499 HAVE_DUP2=1;
14500 HAVE_DUP3=1;
14501 HAVE_EUIDACCESS=1;
14502 HAVE_FACCESSAT=1;
14503 HAVE_FCHDIR=1;
14504 HAVE_FCHOWNAT=1;
14505 HAVE_FSYNC=1;
14506 HAVE_FTRUNCATE=1;
14507 HAVE_GETDTABLESIZE=1;
14508 HAVE_GETGROUPS=1;
14509 HAVE_GETHOSTNAME=1;
14510 HAVE_GETLOGIN=1;
14511 HAVE_GETPAGESIZE=1;
14512 HAVE_GROUP_MEMBER=1;
14513 HAVE_LCHOWN=1;
14514 HAVE_LINK=1;
14515 HAVE_LINKAT=1;
14516 HAVE_PIPE=1;
14517 HAVE_PIPE2=1;
14518 HAVE_PREAD=1;
14519 HAVE_PWRITE=1;
14520 HAVE_READLINK=1;
14521 HAVE_READLINKAT=1;
14522 HAVE_SLEEP=1;
14523 HAVE_SYMLINK=1;
14524 HAVE_SYMLINKAT=1;
14525 HAVE_UNLINKAT=1;
14526 HAVE_USLEEP=1;
14527 HAVE_DECL_ENVIRON=1;
14528 HAVE_DECL_FCHDIR=1;
14529 HAVE_DECL_GETDOMAINNAME=1;
14530 HAVE_DECL_GETLOGIN_R=1;
14531 HAVE_DECL_GETPAGESIZE=1;
14532 HAVE_DECL_GETUSERSHELL=1;
14533 HAVE_DECL_TTYNAME_R=1;
14534 HAVE_OS_H=0;
14535 HAVE_SYS_PARAM_H=0;
14536 REPLACE_CHOWN=0;
14537 REPLACE_CLOSE=0;
14538 REPLACE_DUP=0;
14539 REPLACE_DUP2=0;
14540 REPLACE_FCHOWNAT=0;
14541 REPLACE_GETCWD=0;
14542 REPLACE_GETDOMAINNAME=0;
14543 REPLACE_GETLOGIN_R=0;
14544 REPLACE_GETGROUPS=0;
14545 REPLACE_GETPAGESIZE=0;
14546 REPLACE_LCHOWN=0;
14547 REPLACE_LINK=0;
14548 REPLACE_LINKAT=0;
14549 REPLACE_LSEEK=0;
14550 REPLACE_PREAD=0;
14551 REPLACE_PWRITE=0;
14552 REPLACE_READ=0;
14553 REPLACE_READLINK=0;
14554 REPLACE_RMDIR=0;
14555 REPLACE_SLEEP=0;
14556 REPLACE_SYMLINK=0;
14557 REPLACE_TTYNAME_R=0;
14558 REPLACE_UNLINK=0;
14559 REPLACE_UNLINKAT=0;
14560 REPLACE_USLEEP=0;
14561 REPLACE_WRITE=0;
14562 UNISTD_H_HAVE_WINSOCK2_H=0;
14563 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
14564
14565
14566
14567
14568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
14569 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
14570 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
14571 $as_echo_n "(cached) " >&6
14572 else
14573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14574 /* end confdefs.h. */
14575
14576 #include <sys/types.h>
14577 #include <sys/stat.h>
14578 int
14579 main ()
14580 {
14581 struct stat s; s.st_dm_mode;
14582 ;
14583 return 0;
14584 }
14585 _ACEOF
14586 if ac_fn_c_try_compile "$LINENO"; then :
14587 ac_cv_struct_st_dm_mode=yes
14588 else
14589 ac_cv_struct_st_dm_mode=no
14590 fi
14591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14592 fi
14593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
14594 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
14595
14596 if test $ac_cv_struct_st_dm_mode = yes; then
14597
14598 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
14599
14600 fi
14601
14602
14603 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
14604 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
14605 ac_have_decl=1
14606 else
14607 ac_have_decl=0
14608 fi
14609
14610 cat >>confdefs.h <<_ACEOF
14611 #define HAVE_DECL_STRMODE $ac_have_decl
14612 _ACEOF
14613
14614
14615 GNULIB__EXIT=0;
14616 GNULIB_ATOLL=0;
14617 GNULIB_CALLOC_POSIX=0;
14618 GNULIB_CANONICALIZE_FILE_NAME=0;
14619 GNULIB_GETLOADAVG=0;
14620 GNULIB_GETSUBOPT=0;
14621 GNULIB_GRANTPT=0;
14622 GNULIB_MALLOC_POSIX=0;
14623 GNULIB_MBTOWC=0;
14624 GNULIB_MKDTEMP=0;
14625 GNULIB_MKOSTEMP=0;
14626 GNULIB_MKOSTEMPS=0;
14627 GNULIB_MKSTEMP=0;
14628 GNULIB_MKSTEMPS=0;
14629 GNULIB_PTSNAME=0;
14630 GNULIB_PUTENV=0;
14631 GNULIB_RANDOM_R=0;
14632 GNULIB_REALLOC_POSIX=0;
14633 GNULIB_REALPATH=0;
14634 GNULIB_RPMATCH=0;
14635 GNULIB_SETENV=0;
14636 GNULIB_STRTOD=0;
14637 GNULIB_STRTOLL=0;
14638 GNULIB_STRTOULL=0;
14639 GNULIB_SYSTEM_POSIX=0;
14640 GNULIB_UNLOCKPT=0;
14641 GNULIB_UNSETENV=0;
14642 GNULIB_WCTOMB=0;
14643 HAVE__EXIT=1;
14644 HAVE_ATOLL=1;
14645 HAVE_CANONICALIZE_FILE_NAME=1;
14646 HAVE_DECL_GETLOADAVG=1;
14647 HAVE_GETSUBOPT=1;
14648 HAVE_GRANTPT=1;
14649 HAVE_MKDTEMP=1;
14650 HAVE_MKOSTEMP=1;
14651 HAVE_MKOSTEMPS=1;
14652 HAVE_MKSTEMP=1;
14653 HAVE_MKSTEMPS=1;
14654 HAVE_PTSNAME=1;
14655 HAVE_RANDOM_H=1;
14656 HAVE_RANDOM_R=1;
14657 HAVE_REALPATH=1;
14658 HAVE_RPMATCH=1;
14659 HAVE_SETENV=1;
14660 HAVE_DECL_SETENV=1;
14661 HAVE_STRTOD=1;
14662 HAVE_STRTOLL=1;
14663 HAVE_STRTOULL=1;
14664 HAVE_STRUCT_RANDOM_DATA=1;
14665 HAVE_SYS_LOADAVG_H=0;
14666 HAVE_UNLOCKPT=1;
14667 HAVE_DECL_UNSETENV=1;
14668 REPLACE_CALLOC=0;
14669 REPLACE_CANONICALIZE_FILE_NAME=0;
14670 REPLACE_MALLOC=0;
14671 REPLACE_MBTOWC=0;
14672 REPLACE_MKSTEMP=0;
14673 REPLACE_PUTENV=0;
14674 REPLACE_REALLOC=0;
14675 REPLACE_REALPATH=0;
14676 REPLACE_SETENV=0;
14677 REPLACE_STRTOD=0;
14678 REPLACE_UNSETENV=0;
14679 REPLACE_WCTOMB=0;
14680
14681
14682
14683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
14684 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
14685 if test "${gl_cv_have_include_next+set}" = set; then :
14686 $as_echo_n "(cached) " >&6
14687 else
14688 rm -rf conftestd1a conftestd1b conftestd2
14689 mkdir conftestd1a conftestd1b conftestd2
14690 cat <<EOF > conftestd1a/conftest.h
14691 #define DEFINED_IN_CONFTESTD1
14692 #include_next <conftest.h>
14693 #ifdef DEFINED_IN_CONFTESTD2
14694 int foo;
14695 #else
14696 #error "include_next doesn't work"
14697 #endif
14698 EOF
14699 cat <<EOF > conftestd1b/conftest.h
14700 #define DEFINED_IN_CONFTESTD1
14701 #include <stdio.h>
14702 #include_next <conftest.h>
14703 #ifdef DEFINED_IN_CONFTESTD2
14704 int foo;
14705 #else
14706 #error "include_next doesn't work"
14707 #endif
14708 EOF
14709 cat <<EOF > conftestd2/conftest.h
14710 #ifndef DEFINED_IN_CONFTESTD1
14711 #error "include_next test doesn't work"
14712 #endif
14713 #define DEFINED_IN_CONFTESTD2
14714 EOF
14715 gl_save_CPPFLAGS="$CPPFLAGS"
14716 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
14717 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14718 /* end confdefs.h. */
14719 #include <conftest.h>
14720 _ACEOF
14721 if ac_fn_c_try_compile "$LINENO"; then :
14722 gl_cv_have_include_next=yes
14723 else
14724 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
14725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14726 /* end confdefs.h. */
14727 #include <conftest.h>
14728 _ACEOF
14729 if ac_fn_c_try_compile "$LINENO"; then :
14730 gl_cv_have_include_next=buggy
14731 else
14732 gl_cv_have_include_next=no
14733 fi
14734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14735
14736 fi
14737 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14738 CPPFLAGS="$gl_save_CPPFLAGS"
14739 rm -rf conftestd1a conftestd1b conftestd2
14740
14741 fi
14742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
14743 $as_echo "$gl_cv_have_include_next" >&6; }
14744 PRAGMA_SYSTEM_HEADER=
14745 if test $gl_cv_have_include_next = yes; then
14746 INCLUDE_NEXT=include_next
14747 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
14748 if test -n "$GCC"; then
14749 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
14750 fi
14751 else
14752 if test $gl_cv_have_include_next = buggy; then
14753 INCLUDE_NEXT=include
14754 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
14755 else
14756 INCLUDE_NEXT=include
14757 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
14758 fi
14759 fi
14760
14761
14762
14763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
14764 $as_echo_n "checking whether system header files limit the line length... " >&6; }
14765 if test "${gl_cv_pragma_columns+set}" = set; then :
14766 $as_echo_n "(cached) " >&6
14767 else
14768 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14769 /* end confdefs.h. */
14770
14771 #ifdef __TANDEM
14772 choke me
14773 #endif
14774
14775 _ACEOF
14776 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14777 $EGREP "choke me" >/dev/null 2>&1; then :
14778 gl_cv_pragma_columns=yes
14779 else
14780 gl_cv_pragma_columns=no
14781 fi
14782 rm -f conftest*
14783
14784
14785 fi
14786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
14787 $as_echo "$gl_cv_pragma_columns" >&6; }
14788 if test $gl_cv_pragma_columns = yes; then
14789 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
14790 else
14791 PRAGMA_COLUMNS=
14792 fi
14793
14794
14795
14796
14797
14798
14799
14800
14801
14802
14803
14804
14805
14806
14807
14808
14809
14810 if test $gl_cv_have_include_next = yes; then
14811 gl_cv_next_getopt_h='<'getopt.h'>'
14812 else
14813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
14814 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
14815 if test "${gl_cv_next_getopt_h+set}" = set; then :
14816 $as_echo_n "(cached) " >&6
14817 else
14818
14819 if test $ac_cv_header_getopt_h = yes; then
14820
14821
14822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14823 /* end confdefs.h. */
14824 #include <getopt.h>
14825
14826 _ACEOF
14827 case "$host_os" in
14828 aix*) gl_absname_cpp="$ac_cpp -C" ;;
14829 *) gl_absname_cpp="$ac_cpp" ;;
14830 esac
14831 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
14832 sed -n '\#/getopt.h#{
14833 s#.*"\(.*/getopt.h\)".*#\1#
14834 s#^/[^/]#//&#
14835 p
14836 q
14837 }'`'"'
14838 else
14839 gl_cv_next_getopt_h='<'getopt.h'>'
14840 fi
14841
14842
14843 fi
14844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
14845 $as_echo "$gl_cv_next_getopt_h" >&6; }
14846 fi
14847 NEXT_GETOPT_H=$gl_cv_next_getopt_h
14848
14849 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
14850 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
14851 gl_next_as_first_directive='<'getopt.h'>'
14852 else
14853 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
14854 gl_next_as_first_directive=$gl_cv_next_getopt_h
14855 fi
14856 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
14857
14858
14859
14860
14861 if test $ac_cv_header_getopt_h = yes; then
14862 HAVE_GETOPT_H=1
14863 else
14864 HAVE_GETOPT_H=0
14865 fi
14866
14867
14868 gl_replace_getopt=
14869
14870 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
14871 for ac_header in getopt.h
14872 do :
14873 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
14874 if test "x$ac_cv_header_getopt_h" = x""yes; then :
14875 cat >>confdefs.h <<_ACEOF
14876 #define HAVE_GETOPT_H 1
14877 _ACEOF
14878
14879 else
14880 gl_replace_getopt=yes
14881 fi
14882
14883 done
14884
14885 fi
14886
14887 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
14888 for ac_func in getopt_long_only
14889 do :
14890 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
14891 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
14892 cat >>confdefs.h <<_ACEOF
14893 #define HAVE_GETOPT_LONG_ONLY 1
14894 _ACEOF
14895
14896 else
14897 gl_replace_getopt=yes
14898 fi
14899 done
14900
14901 fi
14902
14903 if test -z "$gl_replace_getopt"; then
14904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
14905 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
14906 if test "${gl_cv_func_getopt_posix+set}" = set; then :
14907 $as_echo_n "(cached) " >&6
14908 else
14909
14910 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14911 /* end confdefs.h. */
14912 #include <unistd.h>
14913 int
14914 main ()
14915 {
14916 int *p = &optreset; return optreset;
14917 ;
14918 return 0;
14919 }
14920 _ACEOF
14921 if ac_fn_c_try_compile "$LINENO"; then :
14922 gl_optind_min=1
14923 else
14924 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14925 /* end confdefs.h. */
14926 #include <getopt.h>
14927 int
14928 main ()
14929 {
14930 return !getopt_clip;
14931 ;
14932 return 0;
14933 }
14934 _ACEOF
14935 if ac_fn_c_try_compile "$LINENO"; then :
14936 gl_optind_min=1
14937 else
14938 gl_optind_min=0
14939 fi
14940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14941 fi
14942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14943
14944 gl_save_CPPFLAGS=$CPPFLAGS
14945 CPPFLAGS="$CPPFLAGS -DOPTIND_MIN=$gl_optind_min"
14946 if test "$cross_compiling" = yes; then :
14947 case "$host_os" in
14948 mingw*) gl_cv_func_getopt_posix="guessing no";;
14949 darwin* | aix*) gl_cv_func_getopt_posix="guessing no";;
14950 *) gl_cv_func_getopt_posix="guessing yes";;
14951 esac
14952
14953 else
14954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14955 /* end confdefs.h. */
14956
14957 #include <unistd.h>
14958 #include <stdlib.h>
14959 #include <string.h>
14960
14961 int
14962 main ()
14963 {
14964 {
14965 int argc = 0;
14966 char *argv[10];
14967 int c;
14968
14969 argv[argc++] = "program";
14970 argv[argc++] = "-a";
14971 argv[argc++] = "foo";
14972 argv[argc++] = "bar";
14973 argv[argc] = NULL;
14974 optind = OPTIND_MIN;
14975 opterr = 0;
14976
14977 c = getopt (argc, argv, "ab");
14978 if (!(c == 'a'))
14979 return 1;
14980 c = getopt (argc, argv, "ab");
14981 if (!(c == -1))
14982 return 2;
14983 if (!(optind == 2))
14984 return 3;
14985 }
14986 /* Some internal state exists at this point. */
14987 {
14988 int argc = 0;
14989 char *argv[10];
14990 int c;
14991
14992 argv[argc++] = "program";
14993 argv[argc++] = "donald";
14994 argv[argc++] = "-p";
14995 argv[argc++] = "billy";
14996 argv[argc++] = "duck";
14997 argv[argc++] = "-a";
14998 argv[argc++] = "bar";
14999 argv[argc] = NULL;
15000 optind = OPTIND_MIN;
15001 opterr = 0;
15002
15003 c = getopt (argc, argv, "+abp:q:");
15004 if (!(c == -1))
15005 return 4;
15006 if (!(strcmp (argv[0], "program") == 0))
15007 return 5;
15008 if (!(strcmp (argv[1], "donald") == 0))
15009 return 6;
15010 if (!(strcmp (argv[2], "-p") == 0))
15011 return 7;
15012 if (!(strcmp (argv[3], "billy") == 0))
15013 return 8;
15014 if (!(strcmp (argv[4], "duck") == 0))
15015 return 9;
15016 if (!(strcmp (argv[5], "-a") == 0))
15017 return 10;
15018 if (!(strcmp (argv[6], "bar") == 0))
15019 return 11;
15020 if (!(optind == 1))
15021 return 12;
15022 }
15023 /* Detect MacOS 10.5, AIX 7.1 bug. */
15024 {
15025 char *argv[3] = { "program", "-ab", NULL };
15026 optind = OPTIND_MIN;
15027 opterr = 0;
15028 if (getopt (2, argv, "ab:") != 'a')
15029 return 13;
15030 if (getopt (2, argv, "ab:") != '?')
15031 return 14;
15032 if (optopt != 'b')
15033 return 15;
15034 if (optind != 2)
15035 return 16;
15036 }
15037
15038 return 0;
15039 }
15040
15041 _ACEOF
15042 if ac_fn_c_try_run "$LINENO"; then :
15043 gl_cv_func_getopt_posix=yes
15044 else
15045 gl_cv_func_getopt_posix=no
15046 fi
15047 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15048 conftest.$ac_objext conftest.beam conftest.$ac_ext
15049 fi
15050
15051 CPPFLAGS=$gl_save_CPPFLAGS
15052
15053 fi
15054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
15055 $as_echo "$gl_cv_func_getopt_posix" >&6; }
15056 case "$gl_cv_func_getopt_posix" in
15057 *no) gl_replace_getopt=yes ;;
15058 esac
15059 fi
15060
15061 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
15062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
15063 $as_echo_n "checking for working GNU getopt function... " >&6; }
15064 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
15065 $as_echo_n "(cached) " >&6
15066 else
15067 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
15068 # optstring is necessary for programs like m4 that have POSIX-mandated
15069 # semantics for supporting options interspersed with files.
15070 # Also, since getopt_long is a GNU extension, we require optind=0.
15071 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
15072 # so take care to revert to the correct (non-)export state.
15073 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
15074 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
15075 xx) gl_had_POSIXLY_CORRECT=exported ;;
15076 x) gl_had_POSIXLY_CORRECT=yes ;;
15077 *) gl_had_POSIXLY_CORRECT= ;;
15078 esac
15079 POSIXLY_CORRECT=1
15080 export POSIXLY_CORRECT
15081 if test "$cross_compiling" = yes; then :
15082 case $host_os:$ac_cv_have_decl_optreset in
15083 *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;;
15084 *:yes) gl_cv_func_getopt_gnu=no;;
15085 *) gl_cv_func_getopt_gnu=yes;;
15086 esac
15087
15088 else
15089 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15090 /* end confdefs.h. */
15091 #include <getopt.h>
15092 #include <stddef.h>
15093 #include <string.h>
15094
15095 int
15096 main ()
15097 {
15098
15099 int result = 0;
15100 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
15101 and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
15102 OSF/1 5.1, Solaris 10. */
15103 {
15104 char *myargv[3];
15105 myargv[0] = "conftest";
15106 myargv[1] = "-+";
15107 myargv[2] = 0;
15108 opterr = 0;
15109 if (getopt (2, myargv, "+a") != '?')
15110 result |= 1;
15111 }
15112 /* This code succeeds on glibc 2.8, mingw,
15113 and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
15114 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
15115 {
15116 char *argv[] = { "program", "-p", "foo", "bar", NULL };
15117
15118 optind = 1;
15119 if (getopt (4, argv, "p::") != 'p')
15120 result |= 2;
15121 else if (optarg != NULL)
15122 result |= 4;
15123 else if (getopt (4, argv, "p::") != -1)
15124 result |= 6;
15125 else if (optind != 2)
15126 result |= 8;
15127 }
15128 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
15129 {
15130 char *argv[] = { "program", "foo", "-p", NULL };
15131 optind = 0;
15132 if (getopt (3, argv, "-p") != 1)
15133 result |= 16;
15134 else if (getopt (3, argv, "-p") != 'p')
15135 result |= 32;
15136 }
15137 /* This code fails on glibc 2.11. */
15138 {
15139 char *argv[] = { "program", "-b", "-a", NULL };
15140 optind = opterr = 0;
15141 if (getopt (3, argv, "+:a:b") != 'b')
15142 result |= 64;
15143 else if (getopt (3, argv, "+:a:b") != ':')
15144 result |= 64;
15145 }
15146 return result;
15147
15148 ;
15149 return 0;
15150 }
15151 _ACEOF
15152 if ac_fn_c_try_run "$LINENO"; then :
15153 gl_cv_func_getopt_gnu=yes
15154 else
15155 gl_cv_func_getopt_gnu=no
15156 fi
15157 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15158 conftest.$ac_objext conftest.beam conftest.$ac_ext
15159 fi
15160
15161 case $gl_had_POSIXLY_CORRECT in
15162 exported) ;;
15163 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
15164 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
15165 esac
15166
15167 fi
15168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
15169 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
15170 if test "$gl_cv_func_getopt_gnu" = "no"; then
15171 gl_replace_getopt=yes
15172 fi
15173 fi
15174
15175
15176
15177
15178
15179 REPLACE_GETOPT=0
15180
15181
15182 if test -n "$gl_replace_getopt"; then :
15183
15184 REPLACE_GETOPT=1
15185
15186 fi
15187
15188
15189 if test $REPLACE_GETOPT = 1; then
15190
15191 GETOPT_H=getopt.h
15192
15193 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
15194
15195
15196
15197 GNULIB_UNISTD_H_GETOPT=1
15198 fi
15199
15200 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
15201 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
15202 ac_have_decl=1
15203 else
15204 ac_have_decl=0
15205 fi
15206
15207 cat >>confdefs.h <<_ACEOF
15208 #define HAVE_DECL_GETENV $ac_have_decl
15209 _ACEOF
15210
15211
15212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
15213 $as_echo_n "checking for unsigned long long int... " >&6; }
15214 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
15215 $as_echo_n "(cached) " >&6
15216 else
15217 ac_cv_type_unsigned_long_long_int=yes
15218 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
15219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15220 /* end confdefs.h. */
15221
15222 /* For now, do not test the preprocessor; as of 2007 there are too many
15223 implementations with broken preprocessors. Perhaps this can
15224 be revisited in 2012. In the meantime, code should not expect
15225 #if to work with literals wider than 32 bits. */
15226 /* Test literals. */
15227 long long int ll = 9223372036854775807ll;
15228 long long int nll = -9223372036854775807LL;
15229 unsigned long long int ull = 18446744073709551615ULL;
15230 /* Test constant expressions. */
15231 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
15232 ? 1 : -1)];
15233 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
15234 ? 1 : -1)];
15235 int i = 63;
15236 int
15237 main ()
15238 {
15239 /* Test availability of runtime routines for shift and division. */
15240 long long int llmax = 9223372036854775807ll;
15241 unsigned long long int ullmax = 18446744073709551615ull;
15242 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
15243 | (llmax / ll) | (llmax % ll)
15244 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
15245 | (ullmax / ull) | (ullmax % ull));
15246 ;
15247 return 0;
15248 }
15249
15250 _ACEOF
15251 if ac_fn_c_try_link "$LINENO"; then :
15252
15253 else
15254 ac_cv_type_unsigned_long_long_int=no
15255 fi
15256 rm -f core conftest.err conftest.$ac_objext \
15257 conftest$ac_exeext conftest.$ac_ext
15258 fi
15259 fi
15260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
15261 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
15262 if test $ac_cv_type_unsigned_long_long_int = yes; then
15263
15264 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
15265
15266 fi
15267
15268
15269
15270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
15271 $as_echo_n "checking for long long int... " >&6; }
15272 if test "${ac_cv_type_long_long_int+set}" = set; then :
15273 $as_echo_n "(cached) " >&6
15274 else
15275 ac_cv_type_long_long_int=yes
15276 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
15277 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
15278 if test $ac_cv_type_long_long_int = yes; then
15279 if test "$cross_compiling" = yes; then :
15280 :
15281 else
15282 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15283 /* end confdefs.h. */
15284 #include <limits.h>
15285 #ifndef LLONG_MAX
15286 # define HALF \
15287 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
15288 # define LLONG_MAX (HALF - 1 + HALF)
15289 #endif
15290 int
15291 main ()
15292 {
15293 long long int n = 1;
15294 int i;
15295 for (i = 0; ; i++)
15296 {
15297 long long int m = n << i;
15298 if (m >> i != n)
15299 return 1;
15300 if (LLONG_MAX / 2 < m)
15301 break;
15302 }
15303 return 0;
15304 ;
15305 return 0;
15306 }
15307 _ACEOF
15308 if ac_fn_c_try_run "$LINENO"; then :
15309
15310 else
15311 ac_cv_type_long_long_int=no
15312 fi
15313 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15314 conftest.$ac_objext conftest.beam conftest.$ac_ext
15315 fi
15316
15317 fi
15318 fi
15319 fi
15320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
15321 $as_echo "$ac_cv_type_long_long_int" >&6; }
15322 if test $ac_cv_type_long_long_int = yes; then
15323
15324 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
15325
15326 fi
15327
15328
15329
15330
15331
15332
15333 gl_cv_c_multiarch=no
15334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15335 /* end confdefs.h. */
15336 #ifndef __APPLE_CC__
15337 not a universal capable compiler
15338 #endif
15339 typedef int dummy;
15340
15341 _ACEOF
15342 if ac_fn_c_try_compile "$LINENO"; then :
15343
15344 arch=
15345 prev=
15346 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
15347 if test -n "$prev"; then
15348 case $word in
15349 i?86 | x86_64 | ppc | ppc64)
15350 if test -z "$arch" || test "$arch" = "$word"; then
15351 arch="$word"
15352 else
15353 gl_cv_c_multiarch=yes
15354 fi
15355 ;;
15356 esac
15357 prev=
15358 else
15359 if test "x$word" = "x-arch"; then
15360 prev=arch
15361 fi
15362 fi
15363 done
15364
15365 fi
15366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15367 if test $gl_cv_c_multiarch = yes; then
15368 APPLE_UNIVERSAL_BUILD=1
15369 else
15370 APPLE_UNIVERSAL_BUILD=0
15371 fi
15372
15373
15374
15375
15376
15377 if test $ac_cv_type_long_long_int = yes; then
15378 HAVE_LONG_LONG_INT=1
15379 else
15380 HAVE_LONG_LONG_INT=0
15381 fi
15382
15383
15384 if test $ac_cv_type_unsigned_long_long_int = yes; then
15385 HAVE_UNSIGNED_LONG_LONG_INT=1
15386 else
15387 HAVE_UNSIGNED_LONG_LONG_INT=0
15388 fi
15389
15390
15391
15392 if test $ac_cv_header_wchar_h = yes; then
15393 HAVE_WCHAR_H=1
15394 else
15395 HAVE_WCHAR_H=0
15396 fi
15397
15398
15399 if test $ac_cv_header_inttypes_h = yes; then
15400 HAVE_INTTYPES_H=1
15401 else
15402 HAVE_INTTYPES_H=0
15403 fi
15404
15405
15406 if test $ac_cv_header_sys_types_h = yes; then
15407 HAVE_SYS_TYPES_H=1
15408 else
15409 HAVE_SYS_TYPES_H=0
15410 fi
15411
15412
15413
15414
15415
15416
15417
15418
15419
15420
15421
15422 if test $gl_cv_have_include_next = yes; then
15423 gl_cv_next_stdint_h='<'stdint.h'>'
15424 else
15425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
15426 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
15427 if test "${gl_cv_next_stdint_h+set}" = set; then :
15428 $as_echo_n "(cached) " >&6
15429 else
15430
15431 if test $ac_cv_header_stdint_h = yes; then
15432
15433
15434 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15435 /* end confdefs.h. */
15436 #include <stdint.h>
15437
15438 _ACEOF
15439 case "$host_os" in
15440 aix*) gl_absname_cpp="$ac_cpp -C" ;;
15441 *) gl_absname_cpp="$ac_cpp" ;;
15442 esac
15443 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
15444 sed -n '\#/stdint.h#{
15445 s#.*"\(.*/stdint.h\)".*#\1#
15446 s#^/[^/]#//&#
15447 p
15448 q
15449 }'`'"'
15450 else
15451 gl_cv_next_stdint_h='<'stdint.h'>'
15452 fi
15453
15454
15455 fi
15456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
15457 $as_echo "$gl_cv_next_stdint_h" >&6; }
15458 fi
15459 NEXT_STDINT_H=$gl_cv_next_stdint_h
15460
15461 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
15462 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
15463 gl_next_as_first_directive='<'stdint.h'>'
15464 else
15465 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
15466 gl_next_as_first_directive=$gl_cv_next_stdint_h
15467 fi
15468 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
15469
15470
15471
15472
15473 if test $ac_cv_header_stdint_h = yes; then
15474 HAVE_STDINT_H=1
15475 else
15476 HAVE_STDINT_H=0
15477 fi
15478
15479
15480 if test $ac_cv_header_stdint_h = yes; then
15481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
15482 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
15483 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
15484 $as_echo_n "(cached) " >&6
15485 else
15486 gl_cv_header_working_stdint_h=no
15487 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15488 /* end confdefs.h. */
15489
15490
15491 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
15492 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
15493 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
15494 #include <stdint.h>
15495 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
15496 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
15497 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
15498 #endif
15499
15500
15501 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15502 included before <wchar.h>. */
15503 #include <stddef.h>
15504 #include <signal.h>
15505 #if HAVE_WCHAR_H
15506 # include <stdio.h>
15507 # include <time.h>
15508 # include <wchar.h>
15509 #endif
15510
15511
15512 #ifdef INT8_MAX
15513 int8_t a1 = INT8_MAX;
15514 int8_t a1min = INT8_MIN;
15515 #endif
15516 #ifdef INT16_MAX
15517 int16_t a2 = INT16_MAX;
15518 int16_t a2min = INT16_MIN;
15519 #endif
15520 #ifdef INT32_MAX
15521 int32_t a3 = INT32_MAX;
15522 int32_t a3min = INT32_MIN;
15523 #endif
15524 #ifdef INT64_MAX
15525 int64_t a4 = INT64_MAX;
15526 int64_t a4min = INT64_MIN;
15527 #endif
15528 #ifdef UINT8_MAX
15529 uint8_t b1 = UINT8_MAX;
15530 #else
15531 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
15532 #endif
15533 #ifdef UINT16_MAX
15534 uint16_t b2 = UINT16_MAX;
15535 #endif
15536 #ifdef UINT32_MAX
15537 uint32_t b3 = UINT32_MAX;
15538 #endif
15539 #ifdef UINT64_MAX
15540 uint64_t b4 = UINT64_MAX;
15541 #endif
15542 int_least8_t c1 = INT8_C (0x7f);
15543 int_least8_t c1max = INT_LEAST8_MAX;
15544 int_least8_t c1min = INT_LEAST8_MIN;
15545 int_least16_t c2 = INT16_C (0x7fff);
15546 int_least16_t c2max = INT_LEAST16_MAX;
15547 int_least16_t c2min = INT_LEAST16_MIN;
15548 int_least32_t c3 = INT32_C (0x7fffffff);
15549 int_least32_t c3max = INT_LEAST32_MAX;
15550 int_least32_t c3min = INT_LEAST32_MIN;
15551 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
15552 int_least64_t c4max = INT_LEAST64_MAX;
15553 int_least64_t c4min = INT_LEAST64_MIN;
15554 uint_least8_t d1 = UINT8_C (0xff);
15555 uint_least8_t d1max = UINT_LEAST8_MAX;
15556 uint_least16_t d2 = UINT16_C (0xffff);
15557 uint_least16_t d2max = UINT_LEAST16_MAX;
15558 uint_least32_t d3 = UINT32_C (0xffffffff);
15559 uint_least32_t d3max = UINT_LEAST32_MAX;
15560 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
15561 uint_least64_t d4max = UINT_LEAST64_MAX;
15562 int_fast8_t e1 = INT_FAST8_MAX;
15563 int_fast8_t e1min = INT_FAST8_MIN;
15564 int_fast16_t e2 = INT_FAST16_MAX;
15565 int_fast16_t e2min = INT_FAST16_MIN;
15566 int_fast32_t e3 = INT_FAST32_MAX;
15567 int_fast32_t e3min = INT_FAST32_MIN;
15568 int_fast64_t e4 = INT_FAST64_MAX;
15569 int_fast64_t e4min = INT_FAST64_MIN;
15570 uint_fast8_t f1 = UINT_FAST8_MAX;
15571 uint_fast16_t f2 = UINT_FAST16_MAX;
15572 uint_fast32_t f3 = UINT_FAST32_MAX;
15573 uint_fast64_t f4 = UINT_FAST64_MAX;
15574 #ifdef INTPTR_MAX
15575 intptr_t g = INTPTR_MAX;
15576 intptr_t gmin = INTPTR_MIN;
15577 #endif
15578 #ifdef UINTPTR_MAX
15579 uintptr_t h = UINTPTR_MAX;
15580 #endif
15581 intmax_t i = INTMAX_MAX;
15582 uintmax_t j = UINTMAX_MAX;
15583
15584 #include <limits.h> /* for CHAR_BIT */
15585 #define TYPE_MINIMUM(t) \
15586 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
15587 #define TYPE_MAXIMUM(t) \
15588 ((t) ((t) 0 < (t) -1 \
15589 ? (t) -1 \
15590 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
15591 struct s {
15592 int check_PTRDIFF:
15593 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
15594 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
15595 ? 1 : -1;
15596 /* Detect bug in FreeBSD 6.0 / ia64. */
15597 int check_SIG_ATOMIC:
15598 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
15599 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
15600 ? 1 : -1;
15601 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
15602 int check_WCHAR:
15603 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
15604 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
15605 ? 1 : -1;
15606 /* Detect bug in mingw. */
15607 int check_WINT:
15608 WINT_MIN == TYPE_MINIMUM (wint_t)
15609 && WINT_MAX == TYPE_MAXIMUM (wint_t)
15610 ? 1 : -1;
15611
15612 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
15613 int check_UINT8_C:
15614 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
15615 int check_UINT16_C:
15616 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
15617
15618 /* Detect bugs in OpenBSD 3.9 stdint.h. */
15619 #ifdef UINT8_MAX
15620 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
15621 #endif
15622 #ifdef UINT16_MAX
15623 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
15624 #endif
15625 #ifdef UINT32_MAX
15626 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
15627 #endif
15628 #ifdef UINT64_MAX
15629 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
15630 #endif
15631 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
15632 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
15633 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
15634 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
15635 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
15636 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
15637 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
15638 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
15639 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
15640 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
15641 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
15642 };
15643
15644 int
15645 main ()
15646 {
15647
15648 ;
15649 return 0;
15650 }
15651 _ACEOF
15652 if ac_fn_c_try_compile "$LINENO"; then :
15653 if test "$cross_compiling" = yes; then :
15654 gl_cv_header_working_stdint_h=yes
15655
15656 else
15657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15658 /* end confdefs.h. */
15659
15660
15661 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
15662 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
15663 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
15664 #include <stdint.h>
15665
15666
15667 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15668 included before <wchar.h>. */
15669 #include <stddef.h>
15670 #include <signal.h>
15671 #if HAVE_WCHAR_H
15672 # include <stdio.h>
15673 # include <time.h>
15674 # include <wchar.h>
15675 #endif
15676
15677
15678 #include <stdio.h>
15679 #include <string.h>
15680 #define MVAL(macro) MVAL1(macro)
15681 #define MVAL1(expression) #expression
15682 static const char *macro_values[] =
15683 {
15684 #ifdef INT8_MAX
15685 MVAL (INT8_MAX),
15686 #endif
15687 #ifdef INT16_MAX
15688 MVAL (INT16_MAX),
15689 #endif
15690 #ifdef INT32_MAX
15691 MVAL (INT32_MAX),
15692 #endif
15693 #ifdef INT64_MAX
15694 MVAL (INT64_MAX),
15695 #endif
15696 #ifdef UINT8_MAX
15697 MVAL (UINT8_MAX),
15698 #endif
15699 #ifdef UINT16_MAX
15700 MVAL (UINT16_MAX),
15701 #endif
15702 #ifdef UINT32_MAX
15703 MVAL (UINT32_MAX),
15704 #endif
15705 #ifdef UINT64_MAX
15706 MVAL (UINT64_MAX),
15707 #endif
15708 NULL
15709 };
15710
15711 int
15712 main ()
15713 {
15714
15715 const char **mv;
15716 for (mv = macro_values; *mv != NULL; mv++)
15717 {
15718 const char *value = *mv;
15719 /* Test whether it looks like a cast expression. */
15720 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
15721 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
15722 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
15723 || strncmp (value, "((int)"/*)*/, 6) == 0
15724 || strncmp (value, "((signed short)"/*)*/, 15) == 0
15725 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
15726 return mv - macro_values + 1;
15727 }
15728 return 0;
15729
15730 ;
15731 return 0;
15732 }
15733 _ACEOF
15734 if ac_fn_c_try_run "$LINENO"; then :
15735 gl_cv_header_working_stdint_h=yes
15736 fi
15737 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15738 conftest.$ac_objext conftest.beam conftest.$ac_ext
15739 fi
15740
15741
15742 fi
15743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15744
15745 fi
15746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
15747 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
15748 fi
15749 if test "$gl_cv_header_working_stdint_h" = yes; then
15750 STDINT_H=
15751 else
15752 for ac_header in sys/inttypes.h sys/bitypes.h
15753 do :
15754 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15755 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
15756 eval as_val=\$$as_ac_Header
15757 if test "x$as_val" = x""yes; then :
15758 cat >>confdefs.h <<_ACEOF
15759 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15760 _ACEOF
15761
15762 fi
15763
15764 done
15765
15766 if test $ac_cv_header_sys_inttypes_h = yes; then
15767 HAVE_SYS_INTTYPES_H=1
15768 else
15769 HAVE_SYS_INTTYPES_H=0
15770 fi
15771
15772 if test $ac_cv_header_sys_bitypes_h = yes; then
15773 HAVE_SYS_BITYPES_H=1
15774 else
15775 HAVE_SYS_BITYPES_H=0
15776 fi
15777
15778
15779
15780
15781 if test $APPLE_UNIVERSAL_BUILD = 0; then
15782
15783
15784 for gltype in ptrdiff_t size_t ; do
15785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
15786 $as_echo_n "checking for bit size of $gltype... " >&6; }
15787 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
15788 $as_echo_n "(cached) " >&6
15789 else
15790 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
15791 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15792 included before <wchar.h>. */
15793 #include <stddef.h>
15794 #include <signal.h>
15795 #if HAVE_WCHAR_H
15796 # include <stdio.h>
15797 # include <time.h>
15798 # include <wchar.h>
15799 #endif
15800
15801 #include <limits.h>"; then :
15802
15803 else
15804 result=unknown
15805 fi
15806
15807 eval gl_cv_bitsizeof_${gltype}=\$result
15808
15809 fi
15810 eval ac_res=\$gl_cv_bitsizeof_${gltype}
15811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15812 $as_echo "$ac_res" >&6; }
15813 eval result=\$gl_cv_bitsizeof_${gltype}
15814 if test $result = unknown; then
15815 result=0
15816 fi
15817 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15818 cat >>confdefs.h <<_ACEOF
15819 #define BITSIZEOF_${GLTYPE} $result
15820 _ACEOF
15821
15822 eval BITSIZEOF_${GLTYPE}=\$result
15823 done
15824
15825
15826 fi
15827
15828
15829 for gltype in sig_atomic_t wchar_t wint_t ; do
15830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
15831 $as_echo_n "checking for bit size of $gltype... " >&6; }
15832 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
15833 $as_echo_n "(cached) " >&6
15834 else
15835 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
15836 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15837 included before <wchar.h>. */
15838 #include <stddef.h>
15839 #include <signal.h>
15840 #if HAVE_WCHAR_H
15841 # include <stdio.h>
15842 # include <time.h>
15843 # include <wchar.h>
15844 #endif
15845
15846 #include <limits.h>"; then :
15847
15848 else
15849 result=unknown
15850 fi
15851
15852 eval gl_cv_bitsizeof_${gltype}=\$result
15853
15854 fi
15855 eval ac_res=\$gl_cv_bitsizeof_${gltype}
15856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15857 $as_echo "$ac_res" >&6; }
15858 eval result=\$gl_cv_bitsizeof_${gltype}
15859 if test $result = unknown; then
15860 result=0
15861 fi
15862 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15863 cat >>confdefs.h <<_ACEOF
15864 #define BITSIZEOF_${GLTYPE} $result
15865 _ACEOF
15866
15867 eval BITSIZEOF_${GLTYPE}=\$result
15868 done
15869
15870
15871
15872
15873 for gltype in sig_atomic_t wchar_t wint_t ; do
15874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
15875 $as_echo_n "checking whether $gltype is signed... " >&6; }
15876 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
15877 $as_echo_n "(cached) " >&6
15878 else
15879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15880 /* end confdefs.h. */
15881
15882 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15883 included before <wchar.h>. */
15884 #include <stddef.h>
15885 #include <signal.h>
15886 #if HAVE_WCHAR_H
15887 # include <stdio.h>
15888 # include <time.h>
15889 # include <wchar.h>
15890 #endif
15891
15892 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
15893 int
15894 main ()
15895 {
15896
15897 ;
15898 return 0;
15899 }
15900 _ACEOF
15901 if ac_fn_c_try_compile "$LINENO"; then :
15902 result=yes
15903 else
15904 result=no
15905 fi
15906 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15907 eval gl_cv_type_${gltype}_signed=\$result
15908
15909 fi
15910 eval ac_res=\$gl_cv_type_${gltype}_signed
15911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15912 $as_echo "$ac_res" >&6; }
15913 eval result=\$gl_cv_type_${gltype}_signed
15914 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15915 if test "$result" = yes; then
15916 cat >>confdefs.h <<_ACEOF
15917 #define HAVE_SIGNED_${GLTYPE} 1
15918 _ACEOF
15919
15920 eval HAVE_SIGNED_${GLTYPE}=1
15921 else
15922 eval HAVE_SIGNED_${GLTYPE}=0
15923 fi
15924 done
15925
15926
15927 gl_cv_type_ptrdiff_t_signed=yes
15928 gl_cv_type_size_t_signed=no
15929 if test $APPLE_UNIVERSAL_BUILD = 0; then
15930
15931
15932 for gltype in ptrdiff_t size_t ; do
15933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
15934 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
15935 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
15936 $as_echo_n "(cached) " >&6
15937 else
15938 eval gl_cv_type_${gltype}_suffix=no
15939 eval result=\$gl_cv_type_${gltype}_signed
15940 if test "$result" = yes; then
15941 glsufu=
15942 else
15943 glsufu=u
15944 fi
15945 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
15946 case $glsuf in
15947 '') gltype1='int';;
15948 l) gltype1='long int';;
15949 ll) gltype1='long long int';;
15950 i64) gltype1='__int64';;
15951 u) gltype1='unsigned int';;
15952 ul) gltype1='unsigned long int';;
15953 ull) gltype1='unsigned long long int';;
15954 ui64)gltype1='unsigned __int64';;
15955 esac
15956 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15957 /* end confdefs.h. */
15958
15959 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
15960 included before <wchar.h>. */
15961 #include <stddef.h>
15962 #include <signal.h>
15963 #if HAVE_WCHAR_H
15964 # include <stdio.h>
15965 # include <time.h>
15966 # include <wchar.h>
15967 #endif
15968
15969 extern $gltype foo;
15970 extern $gltype1 foo;
15971 int
15972 main ()
15973 {
15974
15975 ;
15976 return 0;
15977 }
15978 _ACEOF
15979 if ac_fn_c_try_compile "$LINENO"; then :
15980 eval gl_cv_type_${gltype}_suffix=\$glsuf
15981 fi
15982 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15983 eval result=\$gl_cv_type_${gltype}_suffix
15984 test "$result" != no && break
15985 done
15986 fi
15987 eval ac_res=\$gl_cv_type_${gltype}_suffix
15988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15989 $as_echo "$ac_res" >&6; }
15990 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
15991 eval result=\$gl_cv_type_${gltype}_suffix
15992 test "$result" = no && result=
15993 eval ${GLTYPE}_SUFFIX=\$result
15994 cat >>confdefs.h <<_ACEOF
15995 #define ${GLTYPE}_SUFFIX $result
15996 _ACEOF
15997
15998 done
15999
16000
16001 fi
16002
16003
16004 for gltype in sig_atomic_t wchar_t wint_t ; do
16005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
16006 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
16007 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
16008 $as_echo_n "(cached) " >&6
16009 else
16010 eval gl_cv_type_${gltype}_suffix=no
16011 eval result=\$gl_cv_type_${gltype}_signed
16012 if test "$result" = yes; then
16013 glsufu=
16014 else
16015 glsufu=u
16016 fi
16017 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
16018 case $glsuf in
16019 '') gltype1='int';;
16020 l) gltype1='long int';;
16021 ll) gltype1='long long int';;
16022 i64) gltype1='__int64';;
16023 u) gltype1='unsigned int';;
16024 ul) gltype1='unsigned long int';;
16025 ull) gltype1='unsigned long long int';;
16026 ui64)gltype1='unsigned __int64';;
16027 esac
16028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16029 /* end confdefs.h. */
16030
16031 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
16032 included before <wchar.h>. */
16033 #include <stddef.h>
16034 #include <signal.h>
16035 #if HAVE_WCHAR_H
16036 # include <stdio.h>
16037 # include <time.h>
16038 # include <wchar.h>
16039 #endif
16040
16041 extern $gltype foo;
16042 extern $gltype1 foo;
16043 int
16044 main ()
16045 {
16046
16047 ;
16048 return 0;
16049 }
16050 _ACEOF
16051 if ac_fn_c_try_compile "$LINENO"; then :
16052 eval gl_cv_type_${gltype}_suffix=\$glsuf
16053 fi
16054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16055 eval result=\$gl_cv_type_${gltype}_suffix
16056 test "$result" != no && break
16057 done
16058 fi
16059 eval ac_res=\$gl_cv_type_${gltype}_suffix
16060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
16061 $as_echo "$ac_res" >&6; }
16062 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
16063 eval result=\$gl_cv_type_${gltype}_suffix
16064 test "$result" = no && result=
16065 eval ${GLTYPE}_SUFFIX=\$result
16066 cat >>confdefs.h <<_ACEOF
16067 #define ${GLTYPE}_SUFFIX $result
16068 _ACEOF
16069
16070 done
16071
16072
16073
16074 STDINT_H=stdint.h
16075 fi
16076
16077 if test -n "$STDINT_H"; then
16078 GL_GENERATE_STDINT_H_TRUE=
16079 GL_GENERATE_STDINT_H_FALSE='#'
16080 else
16081 GL_GENERATE_STDINT_H_TRUE='#'
16082 GL_GENERATE_STDINT_H_FALSE=
16083 fi
16084
16085
16086
16087
16088
16089 GNULIB_IMAXABS=0;
16090 GNULIB_IMAXDIV=0;
16091 GNULIB_STRTOIMAX=0;
16092 GNULIB_STRTOUMAX=0;
16093 HAVE_DECL_IMAXABS=1;
16094 HAVE_DECL_IMAXDIV=1;
16095 HAVE_DECL_STRTOIMAX=1;
16096 HAVE_DECL_STRTOUMAX=1;
16097 INT32_MAX_LT_INTMAX_MAX=1;
16098 INT64_MAX_EQ_LONG_MAX='defined _LP64';
16099 PRI_MACROS_BROKEN=0;
16100 PRIPTR_PREFIX=__PRIPTR_PREFIX;
16101 UINT32_MAX_LT_UINTMAX_MAX=1;
16102 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
16103
16104
16105
16106
16107
16108
16109
16110
16111
16112
16113
16114
16115
16116
16117
16118 if test $gl_cv_have_include_next = yes; then
16119 gl_cv_next_inttypes_h='<'inttypes.h'>'
16120 else
16121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
16122 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
16123 if test "${gl_cv_next_inttypes_h+set}" = set; then :
16124 $as_echo_n "(cached) " >&6
16125 else
16126
16127 if test $ac_cv_header_inttypes_h = yes; then
16128
16129
16130 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16131 /* end confdefs.h. */
16132 #include <inttypes.h>
16133
16134 _ACEOF
16135 case "$host_os" in
16136 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16137 *) gl_absname_cpp="$ac_cpp" ;;
16138 esac
16139 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16140 sed -n '\#/inttypes.h#{
16141 s#.*"\(.*/inttypes.h\)".*#\1#
16142 s#^/[^/]#//&#
16143 p
16144 q
16145 }'`'"'
16146 else
16147 gl_cv_next_inttypes_h='<'inttypes.h'>'
16148 fi
16149
16150
16151 fi
16152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
16153 $as_echo "$gl_cv_next_inttypes_h" >&6; }
16154 fi
16155 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
16156
16157 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16158 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16159 gl_next_as_first_directive='<'inttypes.h'>'
16160 else
16161 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16162 gl_next_as_first_directive=$gl_cv_next_inttypes_h
16163 fi
16164 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
16165
16166
16167
16168
16169
16170
16171
16172
16173 $as_echo "#define GL_TRIGGER_STDC_LIMIT_MACROS 1" >>confdefs.h
16174
16175
16176
16177
16178
16179
16180 GNULIB_FCHMODAT=0;
16181 GNULIB_FSTATAT=0;
16182 GNULIB_FUTIMENS=0;
16183 GNULIB_LCHMOD=0;
16184 GNULIB_LSTAT=0;
16185 GNULIB_MKDIRAT=0;
16186 GNULIB_MKFIFO=0;
16187 GNULIB_MKFIFOAT=0;
16188 GNULIB_MKNOD=0;
16189 GNULIB_MKNODAT=0;
16190 GNULIB_STAT=0;
16191 GNULIB_UTIMENSAT=0;
16192 HAVE_FCHMODAT=1;
16193 HAVE_FSTATAT=1;
16194 HAVE_FUTIMENS=1;
16195 HAVE_LCHMOD=1;
16196 HAVE_LSTAT=1;
16197 HAVE_MKDIRAT=1;
16198 HAVE_MKFIFO=1;
16199 HAVE_MKFIFOAT=1;
16200 HAVE_MKNOD=1;
16201 HAVE_MKNODAT=1;
16202 HAVE_UTIMENSAT=1;
16203 REPLACE_FSTAT=0;
16204 REPLACE_FSTATAT=0;
16205 REPLACE_FUTIMENS=0;
16206 REPLACE_LSTAT=0;
16207 REPLACE_MKDIR=0;
16208 REPLACE_MKFIFO=0;
16209 REPLACE_MKNOD=0;
16210 REPLACE_STAT=0;
16211 REPLACE_UTIMENSAT=0;
16212
16213
16214
16215
16216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
16217 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
16218 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
16219 $as_echo_n "(cached) " >&6
16220 else
16221 rm -f conftest.sym conftest.file
16222 echo >conftest.file
16223 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
16224 if test "$cross_compiling" = yes; then :
16225 # When cross-compiling, be pessimistic so we will end up using the
16226 # replacement version of lstat that checks for trailing slashes and
16227 # calls lstat a second time when necessary.
16228 gl_cv_func_lstat_dereferences_slashed_symlink=no
16229
16230 else
16231 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16232 /* end confdefs.h. */
16233 $ac_includes_default
16234 int
16235 main ()
16236 {
16237 struct stat sbuf;
16238 /* Linux will dereference the symlink and fail, as required by
16239 POSIX. That is better in the sense that it means we will not
16240 have to compile and use the lstat wrapper. */
16241 return lstat ("conftest.sym/", &sbuf) == 0;
16242
16243 ;
16244 return 0;
16245 }
16246 _ACEOF
16247 if ac_fn_c_try_run "$LINENO"; then :
16248 gl_cv_func_lstat_dereferences_slashed_symlink=yes
16249 else
16250 gl_cv_func_lstat_dereferences_slashed_symlink=no
16251 fi
16252 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16253 conftest.$ac_objext conftest.beam conftest.$ac_ext
16254 fi
16255
16256 else
16257 # If the 'ln -s' command failed, then we probably don't even
16258 # have an lstat function.
16259 gl_cv_func_lstat_dereferences_slashed_symlink=no
16260 fi
16261 rm -f conftest.sym conftest.file
16262
16263 fi
16264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
16265 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
16266 test $gl_cv_func_lstat_dereferences_slashed_symlink = yes &&
16267
16268 cat >>confdefs.h <<_ACEOF
16269 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
16270 _ACEOF
16271
16272
16273
16274 GNULIB_MKTIME=0;
16275 GNULIB_NANOSLEEP=0;
16276 GNULIB_STRPTIME=0;
16277 GNULIB_TIMEGM=0;
16278 GNULIB_TIME_R=0;
16279 HAVE_DECL_LOCALTIME_R=1;
16280 HAVE_NANOSLEEP=1;
16281 HAVE_STRPTIME=1;
16282 HAVE_TIMEGM=1;
16283 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
16284 REPLACE_MKTIME=GNULIB_PORTCHECK;
16285 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
16286 REPLACE_TIMEGM=GNULIB_PORTCHECK;
16287
16288
16289
16290
16291
16292
16293
16294
16295 if test $ac_cv_header_sys_socket_h = no; then
16296 for ac_header in ws2tcpip.h
16297 do :
16298 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
16299 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
16300 cat >>confdefs.h <<_ACEOF
16301 #define HAVE_WS2TCPIP_H 1
16302 _ACEOF
16303
16304 fi
16305
16306 done
16307
16308 fi
16309
16310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
16311 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
16312 if test "${ac_cv_header_stdbool_h+set}" = set; then :
16313 $as_echo_n "(cached) " >&6
16314 else
16315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16316 /* end confdefs.h. */
16317
16318 #include <stdbool.h>
16319 #ifndef bool
16320 "error: bool is not defined"
16321 #endif
16322 #ifndef false
16323 "error: false is not defined"
16324 #endif
16325 #if false
16326 "error: false is not 0"
16327 #endif
16328 #ifndef true
16329 "error: true is not defined"
16330 #endif
16331 #if true != 1
16332 "error: true is not 1"
16333 #endif
16334 #ifndef __bool_true_false_are_defined
16335 "error: __bool_true_false_are_defined is not defined"
16336 #endif
16337
16338 struct s { _Bool s: 1; _Bool t; } s;
16339
16340 char a[true == 1 ? 1 : -1];
16341 char b[false == 0 ? 1 : -1];
16342 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
16343 char d[(bool) 0.5 == true ? 1 : -1];
16344 /* See body of main program for 'e'. */
16345 char f[(_Bool) 0.0 == false ? 1 : -1];
16346 char g[true];
16347 char h[sizeof (_Bool)];
16348 char i[sizeof s.t];
16349 enum { j = false, k = true, l = false * true, m = true * 256 };
16350 /* The following fails for
16351 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
16352 _Bool n[m];
16353 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
16354 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
16355 /* Catch a bug in an HP-UX C compiler. See
16356 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
16357 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
16358 */
16359 _Bool q = true;
16360 _Bool *pq = &q;
16361
16362 int
16363 main ()
16364 {
16365
16366 bool e = &s;
16367 *pq |= q;
16368 *pq |= ! q;
16369 /* Refer to every declared value, to avoid compiler optimizations. */
16370 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
16371 + !m + !n + !o + !p + !q + !pq);
16372
16373 ;
16374 return 0;
16375 }
16376 _ACEOF
16377 if ac_fn_c_try_compile "$LINENO"; then :
16378 ac_cv_header_stdbool_h=yes
16379 else
16380 ac_cv_header_stdbool_h=no
16381 fi
16382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16383 fi
16384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
16385 $as_echo "$ac_cv_header_stdbool_h" >&6; }
16386 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
16387 if test "x$ac_cv_type__Bool" = x""yes; then :
16388
16389 cat >>confdefs.h <<_ACEOF
16390 #define HAVE__BOOL 1
16391 _ACEOF
16392
16393
16394 fi
16395
16396
16397
16398 REPLACE_NULL=0;
16399 HAVE_WCHAR_T=1;
16400
16401
16402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
16403 $as_echo_n "checking for wchar_t... " >&6; }
16404 if test "${gt_cv_c_wchar_t+set}" = set; then :
16405 $as_echo_n "(cached) " >&6
16406 else
16407 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16408 /* end confdefs.h. */
16409 #include <stddef.h>
16410 wchar_t foo = (wchar_t)'\0';
16411 int
16412 main ()
16413 {
16414
16415 ;
16416 return 0;
16417 }
16418 _ACEOF
16419 if ac_fn_c_try_compile "$LINENO"; then :
16420 gt_cv_c_wchar_t=yes
16421 else
16422 gt_cv_c_wchar_t=no
16423 fi
16424 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16425 fi
16426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
16427 $as_echo "$gt_cv_c_wchar_t" >&6; }
16428 if test $gt_cv_c_wchar_t = yes; then
16429
16430 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
16431
16432 fi
16433
16434
16435 GNULIB_DPRINTF=0;
16436 GNULIB_FCLOSE=0;
16437 GNULIB_FFLUSH=0;
16438 GNULIB_FGETC=0;
16439 GNULIB_FGETS=0;
16440 GNULIB_FOPEN=0;
16441 GNULIB_FPRINTF=0;
16442 GNULIB_FPRINTF_POSIX=0;
16443 GNULIB_FPURGE=0;
16444 GNULIB_FPUTC=0;
16445 GNULIB_FPUTS=0;
16446 GNULIB_FREAD=0;
16447 GNULIB_FREOPEN=0;
16448 GNULIB_FSCANF=0;
16449 GNULIB_FSEEK=0;
16450 GNULIB_FSEEKO=0;
16451 GNULIB_FTELL=0;
16452 GNULIB_FTELLO=0;
16453 GNULIB_FWRITE=0;
16454 GNULIB_GETC=0;
16455 GNULIB_GETCHAR=0;
16456 GNULIB_GETDELIM=0;
16457 GNULIB_GETLINE=0;
16458 GNULIB_GETS=0;
16459 GNULIB_OBSTACK_PRINTF=0;
16460 GNULIB_OBSTACK_PRINTF_POSIX=0;
16461 GNULIB_PERROR=0;
16462 GNULIB_POPEN=0;
16463 GNULIB_PRINTF=0;
16464 GNULIB_PRINTF_POSIX=0;
16465 GNULIB_PUTC=0;
16466 GNULIB_PUTCHAR=0;
16467 GNULIB_PUTS=0;
16468 GNULIB_REMOVE=0;
16469 GNULIB_RENAME=0;
16470 GNULIB_RENAMEAT=0;
16471 GNULIB_SCANF=0;
16472 GNULIB_SNPRINTF=0;
16473 GNULIB_SPRINTF_POSIX=0;
16474 GNULIB_STDIO_H_NONBLOCKING=0;
16475 GNULIB_STDIO_H_SIGPIPE=0;
16476 GNULIB_TMPFILE=0;
16477 GNULIB_VASPRINTF=0;
16478 GNULIB_VFSCANF=0;
16479 GNULIB_VSCANF=0;
16480 GNULIB_VDPRINTF=0;
16481 GNULIB_VFPRINTF=0;
16482 GNULIB_VFPRINTF_POSIX=0;
16483 GNULIB_VPRINTF=0;
16484 GNULIB_VPRINTF_POSIX=0;
16485 GNULIB_VSNPRINTF=0;
16486 GNULIB_VSPRINTF_POSIX=0;
16487 HAVE_DECL_FPURGE=1;
16488 HAVE_DECL_FSEEKO=1;
16489 HAVE_DECL_FTELLO=1;
16490 HAVE_DECL_GETDELIM=1;
16491 HAVE_DECL_GETLINE=1;
16492 HAVE_DECL_OBSTACK_PRINTF=1;
16493 HAVE_DECL_SNPRINTF=1;
16494 HAVE_DECL_VSNPRINTF=1;
16495 HAVE_DPRINTF=1;
16496 HAVE_FSEEKO=1;
16497 HAVE_FTELLO=1;
16498 HAVE_RENAMEAT=1;
16499 HAVE_VASPRINTF=1;
16500 HAVE_VDPRINTF=1;
16501 REPLACE_DPRINTF=0;
16502 REPLACE_FCLOSE=0;
16503 REPLACE_FFLUSH=0;
16504 REPLACE_FOPEN=0;
16505 REPLACE_FPRINTF=0;
16506 REPLACE_FPURGE=0;
16507 REPLACE_FREOPEN=0;
16508 REPLACE_FSEEK=0;
16509 REPLACE_FSEEKO=0;
16510 REPLACE_FTELL=0;
16511 REPLACE_FTELLO=0;
16512 REPLACE_GETDELIM=0;
16513 REPLACE_GETLINE=0;
16514 REPLACE_OBSTACK_PRINTF=0;
16515 REPLACE_PERROR=0;
16516 REPLACE_POPEN=0;
16517 REPLACE_PRINTF=0;
16518 REPLACE_REMOVE=0;
16519 REPLACE_RENAME=0;
16520 REPLACE_RENAMEAT=0;
16521 REPLACE_SNPRINTF=0;
16522 REPLACE_SPRINTF=0;
16523 REPLACE_STDIO_READ_FUNCS=0;
16524 REPLACE_STDIO_WRITE_FUNCS=0;
16525 REPLACE_TMPFILE=0;
16526 REPLACE_VASPRINTF=0;
16527 REPLACE_VDPRINTF=0;
16528 REPLACE_VFPRINTF=0;
16529 REPLACE_VPRINTF=0;
16530 REPLACE_VSNPRINTF=0;
16531 REPLACE_VSPRINTF=0;
16532
16533
16534 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
16535 "
16536 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
16537
16538 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
16539
16540 fi
16541
16542
16543
16544
16545 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
16546 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
16547 ac_have_decl=1
16548 else
16549 ac_have_decl=0
16550 fi
16551
16552 cat >>confdefs.h <<_ACEOF
16553 #define HAVE_DECL_STRTOUMAX $ac_have_decl
16554 _ACEOF
16555
16556
16557
16558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
16559 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
16560 if test "${ac_cv_header_stat_broken+set}" = set; then :
16561 $as_echo_n "(cached) " >&6
16562 else
16563 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16564 /* end confdefs.h. */
16565 #include <sys/types.h>
16566 #include <sys/stat.h>
16567
16568 #if defined S_ISBLK && defined S_IFDIR
16569 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
16570 #endif
16571
16572 #if defined S_ISBLK && defined S_IFCHR
16573 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
16574 #endif
16575
16576 #if defined S_ISLNK && defined S_IFREG
16577 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
16578 #endif
16579
16580 #if defined S_ISSOCK && defined S_IFREG
16581 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
16582 #endif
16583
16584 _ACEOF
16585 if ac_fn_c_try_compile "$LINENO"; then :
16586 ac_cv_header_stat_broken=no
16587 else
16588 ac_cv_header_stat_broken=yes
16589 fi
16590 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16591 fi
16592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
16593 $as_echo "$ac_cv_header_stat_broken" >&6; }
16594 if test $ac_cv_header_stat_broken = yes; then
16595
16596 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
16597
16598 fi
16599
16600
16601
16602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
16603 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
16604 if test "${ac_cv_c_restrict+set}" = set; then :
16605 $as_echo_n "(cached) " >&6
16606 else
16607 ac_cv_c_restrict=no
16608 # The order here caters to the fact that C++ does not require restrict.
16609 for ac_kw in __restrict __restrict__ _Restrict restrict; do
16610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16611 /* end confdefs.h. */
16612 typedef int * int_ptr;
16613 int foo (int_ptr $ac_kw ip) {
16614 return ip[0];
16615 }
16616 int
16617 main ()
16618 {
16619 int s[1];
16620 int * $ac_kw t = s;
16621 t[0] = 0;
16622 return foo(t)
16623 ;
16624 return 0;
16625 }
16626 _ACEOF
16627 if ac_fn_c_try_compile "$LINENO"; then :
16628 ac_cv_c_restrict=$ac_kw
16629 fi
16630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16631 test "$ac_cv_c_restrict" != no && break
16632 done
16633
16634 fi
16635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
16636 $as_echo "$ac_cv_c_restrict" >&6; }
16637
16638 case $ac_cv_c_restrict in
16639 restrict) ;;
16640 no) $as_echo "#define restrict /**/" >>confdefs.h
16641 ;;
16642 *) cat >>confdefs.h <<_ACEOF
16643 #define restrict $ac_cv_c_restrict
16644 _ACEOF
16645 ;;
16646 esac
16647
16648
16649
16650
16651
16652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
16653 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
16654 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
16655 $as_echo_n "(cached) " >&6
16656 else
16657 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16658 /* end confdefs.h. */
16659 #include <time.h>
16660
16661 int
16662 main ()
16663 {
16664 static struct timespec x; x.tv_sec = x.tv_nsec;
16665 ;
16666 return 0;
16667 }
16668 _ACEOF
16669 if ac_fn_c_try_compile "$LINENO"; then :
16670 gl_cv_sys_struct_timespec_in_time_h=yes
16671 else
16672 gl_cv_sys_struct_timespec_in_time_h=no
16673 fi
16674 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16675 fi
16676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
16677 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
16678
16679 TIME_H_DEFINES_STRUCT_TIMESPEC=0
16680 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
16681 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
16682 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
16683 TIME_H_DEFINES_STRUCT_TIMESPEC=1
16684 else
16685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
16686 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
16687 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
16688 $as_echo_n "(cached) " >&6
16689 else
16690 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16691 /* end confdefs.h. */
16692 #include <sys/time.h>
16693
16694 int
16695 main ()
16696 {
16697 static struct timespec x; x.tv_sec = x.tv_nsec;
16698 ;
16699 return 0;
16700 }
16701 _ACEOF
16702 if ac_fn_c_try_compile "$LINENO"; then :
16703 gl_cv_sys_struct_timespec_in_sys_time_h=yes
16704 else
16705 gl_cv_sys_struct_timespec_in_sys_time_h=no
16706 fi
16707 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16708 fi
16709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
16710 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
16711 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
16712 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
16713 else
16714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
16715 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
16716 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
16717 $as_echo_n "(cached) " >&6
16718 else
16719 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16720 /* end confdefs.h. */
16721 #include <pthread.h>
16722
16723 int
16724 main ()
16725 {
16726 static struct timespec x; x.tv_sec = x.tv_nsec;
16727 ;
16728 return 0;
16729 }
16730 _ACEOF
16731 if ac_fn_c_try_compile "$LINENO"; then :
16732 gl_cv_sys_struct_timespec_in_pthread_h=yes
16733 else
16734 gl_cv_sys_struct_timespec_in_pthread_h=no
16735 fi
16736 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16737 fi
16738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
16739 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
16740 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
16741 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
16742 fi
16743 fi
16744 fi
16745
16746
16747
16748
16749
16750
16751
16752
16753
16754
16755
16756
16757
16758
16759
16760 if test $gl_cv_have_include_next = yes; then
16761 gl_cv_next_time_h='<'time.h'>'
16762 else
16763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
16764 $as_echo_n "checking absolute name of <time.h>... " >&6; }
16765 if test "${gl_cv_next_time_h+set}" = set; then :
16766 $as_echo_n "(cached) " >&6
16767 else
16768
16769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16770 /* end confdefs.h. */
16771 #include <time.h>
16772
16773 _ACEOF
16774 case "$host_os" in
16775 aix*) gl_absname_cpp="$ac_cpp -C" ;;
16776 *) gl_absname_cpp="$ac_cpp" ;;
16777 esac
16778 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16779 sed -n '\#/time.h#{
16780 s#.*"\(.*/time.h\)".*#\1#
16781 s#^/[^/]#//&#
16782 p
16783 q
16784 }'`'"'
16785
16786
16787 fi
16788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
16789 $as_echo "$gl_cv_next_time_h" >&6; }
16790 fi
16791 NEXT_TIME_H=$gl_cv_next_time_h
16792
16793 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16794 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16795 gl_next_as_first_directive='<'time.h'>'
16796 else
16797 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16798 gl_next_as_first_directive=$gl_cv_next_time_h
16799 fi
16800 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
16801
16802
16803
16804
16805
16806
16807 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "$ac_includes_default"
16808 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
16809 ac_have_decl=1
16810 else
16811 ac_have_decl=0
16812 fi
16813
16814 cat >>confdefs.h <<_ACEOF
16815 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
16816 _ACEOF
16817
16818
16819
16820
16821 if false; then
16822 GL_COND_LIBTOOL_TRUE=
16823 GL_COND_LIBTOOL_FALSE='#'
16824 else
16825 GL_COND_LIBTOOL_TRUE='#'
16826 GL_COND_LIBTOOL_FALSE=
16827 fi
16828
16829 gl_cond_libtool=false
16830 gl_libdeps=
16831 gl_ltlibdeps=
16832 gl_m4_base='m4'
16833
16834
16835
16836
16837
16838
16839
16840
16841
16842 gl_source_base='lib'
16843
16844
16845 if test $ac_cv_func_alloca_works = no; then
16846 :
16847 fi
16848
16849 # Define an additional variable used in the Makefile substitution.
16850 if test $ac_cv_working_alloca_h = yes; then
16851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
16852 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
16853 if test "${gl_cv_rpl_alloca+set}" = set; then :
16854 $as_echo_n "(cached) " >&6
16855 else
16856
16857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16858 /* end confdefs.h. */
16859
16860 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
16861 Need own alloca
16862 #endif
16863
16864 _ACEOF
16865 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16866 $EGREP "Need own alloca" >/dev/null 2>&1; then :
16867 gl_cv_rpl_alloca=yes
16868 else
16869 gl_cv_rpl_alloca=no
16870 fi
16871 rm -f conftest*
16872
16873
16874 fi
16875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
16876 $as_echo "$gl_cv_rpl_alloca" >&6; }
16877 if test $gl_cv_rpl_alloca = yes; then
16878
16879 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
16880
16881 ALLOCA_H=alloca.h
16882 else
16883 ALLOCA_H=
16884 fi
16885 else
16886 ALLOCA_H=alloca.h
16887 fi
16888
16889 if test -n "$ALLOCA_H"; then
16890 GL_GENERATE_ALLOCA_H_TRUE=
16891 GL_GENERATE_ALLOCA_H_FALSE='#'
16892 else
16893 GL_GENERATE_ALLOCA_H_TRUE='#'
16894 GL_GENERATE_ALLOCA_H_FALSE=
16895 fi
16896
16897
16898
16899
16900
16901
16902 :
16903
16904
16905
16906
16907 :
16908
16909
16910
16911
16912
16913
16914
16915
16916
16917
16918
16919
16920
16921
16922
16923 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
16924
16925
16926 if test $HAVE_DUP2 = 1; then
16927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
16928 $as_echo_n "checking whether dup2 works... " >&6; }
16929 if test "${gl_cv_func_dup2_works+set}" = set; then :
16930 $as_echo_n "(cached) " >&6
16931 else
16932 if test "$cross_compiling" = yes; then :
16933 case "$host_os" in
16934 mingw*) # on this platform, dup2 always returns 0 for success
16935 gl_cv_func_dup2_works=no;;
16936 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
16937 gl_cv_func_dup2_works=no;;
16938 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
16939 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
16940 gl_cv_func_dup2_works=no;;
16941 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
16942 gl_cv_func_dup2_works=no;;
16943 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
16944 gl_cv_func_dup2_works=no;;
16945 *) gl_cv_func_dup2_works=yes;;
16946 esac
16947 else
16948 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16949 /* end confdefs.h. */
16950
16951 #include <unistd.h>
16952 #include <fcntl.h>
16953 #include <errno.h>
16954 int
16955 main ()
16956 {
16957 int result = 0;
16958 #ifdef FD_CLOEXEC
16959 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
16960 result |= 1;
16961 #endif
16962 if (dup2 (1, 1) == 0)
16963 result |= 2;
16964 #ifdef FD_CLOEXEC
16965 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
16966 result |= 4;
16967 #endif
16968 close (0);
16969 if (dup2 (0, 0) != -1)
16970 result |= 8;
16971 /* Many gnulib modules require POSIX conformance of EBADF. */
16972 if (dup2 (2, 1000000) == -1 && errno != EBADF)
16973 result |= 16;
16974 return result;
16975
16976 ;
16977 return 0;
16978 }
16979
16980 _ACEOF
16981 if ac_fn_c_try_run "$LINENO"; then :
16982 gl_cv_func_dup2_works=yes
16983 else
16984 gl_cv_func_dup2_works=no
16985 fi
16986 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16987 conftest.$ac_objext conftest.beam conftest.$ac_ext
16988 fi
16989
16990
16991 fi
16992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
16993 $as_echo "$gl_cv_func_dup2_works" >&6; }
16994 if test "$gl_cv_func_dup2_works" = no; then
16995
16996
16997
16998 if test $ac_cv_func_dup2 = yes; then
16999 REPLACE_DUP2=1
17000 fi
17001
17002
17003
17004
17005
17006
17007
17008
17009 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
17010
17011
17012 fi
17013 fi
17014
17015
17016
17017
17018
17019
17020 GNULIB_DUP2=1
17021
17022
17023
17024
17025
17026
17027
17028
17029
17030
17031
17032 # Persuade glibc <stdlib.h> to declare getloadavg().
17033
17034
17035 gl_save_LIBS=$LIBS
17036
17037 # getloadvg is present in libc on glibc >= 2.2, MacOS X, FreeBSD >= 2.0,
17038 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
17039 HAVE_GETLOADAVG=1
17040 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
17041 if test "x$ac_cv_func_getloadavg" = x""yes; then :
17042
17043 else
17044 gl_func_getloadavg_done=no
17045
17046 # Some systems with -lutil have (and need) -lkvm as well, some do not.
17047 # On Solaris, -lkvm requires nlist from -lelf, so check that first
17048 # to get the right answer into the cache.
17049 # For kstat on solaris, we need to test for libelf and libkvm to force the
17050 # definition of SVR4 below.
17051 if test $gl_func_getloadavg_done = no; then
17052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
17053 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
17054 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
17055 $as_echo_n "(cached) " >&6
17056 else
17057 ac_check_lib_save_LIBS=$LIBS
17058 LIBS="-lelf $LIBS"
17059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17060 /* end confdefs.h. */
17061
17062 /* Override any GCC internal prototype to avoid an error.
17063 Use char because int might match the return type of a GCC
17064 builtin and then its argument prototype would still apply. */
17065 #ifdef __cplusplus
17066 extern "C"
17067 #endif
17068 char elf_begin ();
17069 int
17070 main ()
17071 {
17072 return elf_begin ();
17073 ;
17074 return 0;
17075 }
17076 _ACEOF
17077 if ac_fn_c_try_link "$LINENO"; then :
17078 ac_cv_lib_elf_elf_begin=yes
17079 else
17080 ac_cv_lib_elf_elf_begin=no
17081 fi
17082 rm -f core conftest.err conftest.$ac_objext \
17083 conftest$ac_exeext conftest.$ac_ext
17084 LIBS=$ac_check_lib_save_LIBS
17085 fi
17086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
17087 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
17088 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
17089 LIBS="-lelf $LIBS"
17090 fi
17091
17092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
17093 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
17094 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
17095 $as_echo_n "(cached) " >&6
17096 else
17097 ac_check_lib_save_LIBS=$LIBS
17098 LIBS="-lkvm $LIBS"
17099 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17100 /* end confdefs.h. */
17101
17102 /* Override any GCC internal prototype to avoid an error.
17103 Use char because int might match the return type of a GCC
17104 builtin and then its argument prototype would still apply. */
17105 #ifdef __cplusplus
17106 extern "C"
17107 #endif
17108 char kvm_open ();
17109 int
17110 main ()
17111 {
17112 return kvm_open ();
17113 ;
17114 return 0;
17115 }
17116 _ACEOF
17117 if ac_fn_c_try_link "$LINENO"; then :
17118 ac_cv_lib_kvm_kvm_open=yes
17119 else
17120 ac_cv_lib_kvm_kvm_open=no
17121 fi
17122 rm -f core conftest.err conftest.$ac_objext \
17123 conftest$ac_exeext conftest.$ac_ext
17124 LIBS=$ac_check_lib_save_LIBS
17125 fi
17126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
17127 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
17128 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
17129 LIBS="-lkvm $LIBS"
17130 fi
17131
17132 # Check for the 4.4BSD definition of getloadavg.
17133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
17134 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
17135 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
17136 $as_echo_n "(cached) " >&6
17137 else
17138 ac_check_lib_save_LIBS=$LIBS
17139 LIBS="-lutil $LIBS"
17140 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17141 /* end confdefs.h. */
17142
17143 /* Override any GCC internal prototype to avoid an error.
17144 Use char because int might match the return type of a GCC
17145 builtin and then its argument prototype would still apply. */
17146 #ifdef __cplusplus
17147 extern "C"
17148 #endif
17149 char getloadavg ();
17150 int
17151 main ()
17152 {
17153 return getloadavg ();
17154 ;
17155 return 0;
17156 }
17157 _ACEOF
17158 if ac_fn_c_try_link "$LINENO"; then :
17159 ac_cv_lib_util_getloadavg=yes
17160 else
17161 ac_cv_lib_util_getloadavg=no
17162 fi
17163 rm -f core conftest.err conftest.$ac_objext \
17164 conftest$ac_exeext conftest.$ac_ext
17165 LIBS=$ac_check_lib_save_LIBS
17166 fi
17167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
17168 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
17169 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
17170 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
17171 fi
17172
17173 fi
17174
17175 if test $gl_func_getloadavg_done = no; then
17176 # There is a commonly available library for RS/6000 AIX.
17177 # Since it is not a standard part of AIX, it might be installed locally.
17178 gl_getloadavg_LIBS=$LIBS
17179 LIBS="-L/usr/local/lib $LIBS"
17180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
17181 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
17182 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
17183 $as_echo_n "(cached) " >&6
17184 else
17185 ac_check_lib_save_LIBS=$LIBS
17186 LIBS="-lgetloadavg $LIBS"
17187 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17188 /* end confdefs.h. */
17189
17190 /* Override any GCC internal prototype to avoid an error.
17191 Use char because int might match the return type of a GCC
17192 builtin and then its argument prototype would still apply. */
17193 #ifdef __cplusplus
17194 extern "C"
17195 #endif
17196 char getloadavg ();
17197 int
17198 main ()
17199 {
17200 return getloadavg ();
17201 ;
17202 return 0;
17203 }
17204 _ACEOF
17205 if ac_fn_c_try_link "$LINENO"; then :
17206 ac_cv_lib_getloadavg_getloadavg=yes
17207 else
17208 ac_cv_lib_getloadavg_getloadavg=no
17209 fi
17210 rm -f core conftest.err conftest.$ac_objext \
17211 conftest$ac_exeext conftest.$ac_ext
17212 LIBS=$ac_check_lib_save_LIBS
17213 fi
17214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
17215 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
17216 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
17217 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
17218 else
17219 LIBS=$gl_getloadavg_LIBS
17220 fi
17221
17222 fi
17223
17224 # Set up the replacement function if necessary.
17225 if test $gl_func_getloadavg_done = no; then
17226 HAVE_GETLOADAVG=0
17227
17228 # Solaris has libkstat which does not require root.
17229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
17230 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
17231 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
17232 $as_echo_n "(cached) " >&6
17233 else
17234 ac_check_lib_save_LIBS=$LIBS
17235 LIBS="-lkstat $LIBS"
17236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17237 /* end confdefs.h. */
17238
17239 /* Override any GCC internal prototype to avoid an error.
17240 Use char because int might match the return type of a GCC
17241 builtin and then its argument prototype would still apply. */
17242 #ifdef __cplusplus
17243 extern "C"
17244 #endif
17245 char kstat_open ();
17246 int
17247 main ()
17248 {
17249 return kstat_open ();
17250 ;
17251 return 0;
17252 }
17253 _ACEOF
17254 if ac_fn_c_try_link "$LINENO"; then :
17255 ac_cv_lib_kstat_kstat_open=yes
17256 else
17257 ac_cv_lib_kstat_kstat_open=no
17258 fi
17259 rm -f core conftest.err conftest.$ac_objext \
17260 conftest$ac_exeext conftest.$ac_ext
17261 LIBS=$ac_check_lib_save_LIBS
17262 fi
17263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
17264 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
17265 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
17266 cat >>confdefs.h <<_ACEOF
17267 #define HAVE_LIBKSTAT 1
17268 _ACEOF
17269
17270 LIBS="-lkstat $LIBS"
17271
17272 fi
17273
17274 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
17275
17276 # AIX has libperfstat which does not require root
17277 if test $gl_func_getloadavg_done = no; then
17278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
17279 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
17280 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
17281 $as_echo_n "(cached) " >&6
17282 else
17283 ac_check_lib_save_LIBS=$LIBS
17284 LIBS="-lperfstat $LIBS"
17285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17286 /* end confdefs.h. */
17287
17288 /* Override any GCC internal prototype to avoid an error.
17289 Use char because int might match the return type of a GCC
17290 builtin and then its argument prototype would still apply. */
17291 #ifdef __cplusplus
17292 extern "C"
17293 #endif
17294 char perfstat_cpu_total ();
17295 int
17296 main ()
17297 {
17298 return perfstat_cpu_total ();
17299 ;
17300 return 0;
17301 }
17302 _ACEOF
17303 if ac_fn_c_try_link "$LINENO"; then :
17304 ac_cv_lib_perfstat_perfstat_cpu_total=yes
17305 else
17306 ac_cv_lib_perfstat_perfstat_cpu_total=no
17307 fi
17308 rm -f core conftest.err conftest.$ac_objext \
17309 conftest$ac_exeext conftest.$ac_ext
17310 LIBS=$ac_check_lib_save_LIBS
17311 fi
17312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
17313 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
17314 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
17315 cat >>confdefs.h <<_ACEOF
17316 #define HAVE_LIBPERFSTAT 1
17317 _ACEOF
17318
17319 LIBS="-lperfstat $LIBS"
17320
17321 fi
17322
17323 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
17324 fi
17325
17326 if test $gl_func_getloadavg_done = no; then
17327 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
17328 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
17329 gl_func_getloadavg_done=yes
17330
17331 $as_echo "#define DGUX 1" >>confdefs.h
17332
17333 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
17334 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
17335 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
17336 $as_echo_n "(cached) " >&6
17337 else
17338 ac_check_lib_save_LIBS=$LIBS
17339 LIBS="-ldgc $LIBS"
17340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17341 /* end confdefs.h. */
17342
17343 /* Override any GCC internal prototype to avoid an error.
17344 Use char because int might match the return type of a GCC
17345 builtin and then its argument prototype would still apply. */
17346 #ifdef __cplusplus
17347 extern "C"
17348 #endif
17349 char dg_sys_info ();
17350 int
17351 main ()
17352 {
17353 return dg_sys_info ();
17354 ;
17355 return 0;
17356 }
17357 _ACEOF
17358 if ac_fn_c_try_link "$LINENO"; then :
17359 ac_cv_lib_dgc_dg_sys_info=yes
17360 else
17361 ac_cv_lib_dgc_dg_sys_info=no
17362 fi
17363 rm -f core conftest.err conftest.$ac_objext \
17364 conftest$ac_exeext conftest.$ac_ext
17365 LIBS=$ac_check_lib_save_LIBS
17366 fi
17367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
17368 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
17369 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
17370 cat >>confdefs.h <<_ACEOF
17371 #define HAVE_LIBDGC 1
17372 _ACEOF
17373
17374 LIBS="-ldgc $LIBS"
17375
17376 fi
17377
17378 fi
17379
17380
17381 fi
17382 fi
17383 fi
17384
17385
17386 if test "x$gl_save_LIBS" = x; then
17387 GETLOADAVG_LIBS=$LIBS
17388 else
17389 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
17390 fi
17391 LIBS=$gl_save_LIBS
17392
17393
17394 # Test whether the system declares getloadavg. Solaris has the function
17395 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
17396 for ac_header in sys/loadavg.h
17397 do :
17398 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
17399 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
17400 cat >>confdefs.h <<_ACEOF
17401 #define HAVE_SYS_LOADAVG_H 1
17402 _ACEOF
17403
17404 fi
17405
17406 done
17407
17408 if test $ac_cv_header_sys_loadavg_h = yes; then
17409 HAVE_SYS_LOADAVG_H=1
17410 else
17411 HAVE_SYS_LOADAVG_H=0
17412 fi
17413 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
17414 # include <sys/loadavg.h>
17415 #endif
17416 #include <stdlib.h>
17417 "
17418 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
17419
17420 else
17421 HAVE_DECL_GETLOADAVG=0
17422 fi
17423
17424
17425 if test $HAVE_GETLOADAVG = 0; then
17426
17427
17428
17429
17430
17431
17432
17433
17434 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
17435
17436
17437 # Figure out what our getloadavg.c needs.
17438
17439 # On HPUX9, an unprivileged user can get load averages this way.
17440 if test $gl_func_getloadavg_done = no; then
17441 for ac_func in pstat_getdynamic
17442 do :
17443 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
17444 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
17445 cat >>confdefs.h <<_ACEOF
17446 #define HAVE_PSTAT_GETDYNAMIC 1
17447 _ACEOF
17448 gl_func_getloadavg_done=yes
17449 fi
17450 done
17451
17452 fi
17453
17454 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
17455 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
17456 # Irix 4.0.5F has the header but not the library.
17457 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
17458 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
17459 gl_func_getloadavg_done=yes
17460
17461 $as_echo "#define SVR4 1" >>confdefs.h
17462
17463 fi
17464
17465 if test $gl_func_getloadavg_done = no; then
17466 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
17467 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
17468 gl_func_getloadavg_done=yes
17469
17470 $as_echo "#define UMAX 1" >>confdefs.h
17471
17472
17473 $as_echo "#define UMAX4_3 1" >>confdefs.h
17474
17475 fi
17476
17477
17478 fi
17479
17480 if test $gl_func_getloadavg_done = no; then
17481 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
17482 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
17483 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
17484
17485 fi
17486
17487
17488 fi
17489
17490 if test $gl_func_getloadavg_done = no; then
17491 for ac_header in mach/mach.h
17492 do :
17493 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
17494 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
17495 cat >>confdefs.h <<_ACEOF
17496 #define HAVE_MACH_MACH_H 1
17497 _ACEOF
17498
17499 fi
17500
17501 done
17502
17503 fi
17504
17505 for ac_header in nlist.h
17506 do :
17507 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
17508 if test "x$ac_cv_header_nlist_h" = x""yes; then :
17509 cat >>confdefs.h <<_ACEOF
17510 #define HAVE_NLIST_H 1
17511 _ACEOF
17512 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
17513 "
17514 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
17515
17516 cat >>confdefs.h <<_ACEOF
17517 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
17518 _ACEOF
17519
17520
17521 fi
17522
17523 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17524 /* end confdefs.h. */
17525 #include <nlist.h>
17526 int
17527 main ()
17528 {
17529 struct nlist x;
17530 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
17531 x.n_un.n_name = "";
17532 #else
17533 x.n_name = "";
17534 #endif
17535 ;
17536 return 0;
17537 }
17538 _ACEOF
17539 if ac_fn_c_try_link "$LINENO"; then :
17540
17541 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
17542
17543 fi
17544 rm -f core conftest.err conftest.$ac_objext \
17545 conftest$ac_exeext conftest.$ac_ext
17546
17547 fi
17548
17549 done
17550
17551 fi
17552
17553
17554
17555
17556
17557 GNULIB_GETLOADAVG=1
17558
17559
17560
17561
17562
17563
17564
17565
17566
17567
17568 if test $REPLACE_GETOPT = 1; then
17569
17570
17571
17572
17573
17574
17575
17576
17577 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
17578
17579
17580
17581
17582
17583
17584
17585
17586
17587 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
17588
17589
17590
17591
17592 fi
17593
17594
17595
17596
17597
17598 REPLACE_GETOPT=0
17599
17600
17601 if test -n "$gl_replace_getopt"; then :
17602
17603 REPLACE_GETOPT=1
17604
17605 fi
17606
17607
17608 if test $REPLACE_GETOPT = 1; then
17609
17610 GETOPT_H=getopt.h
17611
17612 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17613
17614
17615
17616 GNULIB_UNISTD_H_GETOPT=1
17617 fi
17618
17619 if test $REPLACE_GETOPT = 1; then
17620
17621
17622
17623
17624
17625
17626
17627
17628 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
17629
17630
17631
17632
17633
17634
17635
17636
17637
17638 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
17639
17640
17641
17642
17643 fi
17644
17645
17646
17647
17648
17649 if test $ac_cv_func_lstat = yes; then
17650
17651 if test $gl_cv_func_lstat_dereferences_slashed_symlink = no; then
17652 REPLACE_LSTAT=1
17653 fi
17654 else
17655 HAVE_LSTAT=0
17656 fi
17657
17658 if test $REPLACE_LSTAT = 1; then
17659
17660
17661
17662
17663
17664
17665
17666
17667 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
17668
17669
17670
17671 :
17672
17673 fi
17674
17675
17676
17677
17678
17679 GNULIB_LSTAT=1
17680
17681
17682
17683
17684
17685
17686
17687
17688
17689
17690
17691 if test $APPLE_UNIVERSAL_BUILD = 1; then
17692 # A universal build on Apple MacOS X platforms.
17693 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
17694 # But we need a configuration result that is valid in both modes.
17695 gl_cv_func_working_mktime=no
17696 fi
17697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
17698 $as_echo_n "checking for working mktime... " >&6; }
17699 if test "${gl_cv_func_working_mktime+set}" = set; then :
17700 $as_echo_n "(cached) " >&6
17701 else
17702 if test "$cross_compiling" = yes; then :
17703 gl_cv_func_working_mktime=no
17704 else
17705 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17706 /* end confdefs.h. */
17707 /* Test program from Paul Eggert and Tony Leneis. */
17708 #include <limits.h>
17709 #include <stdlib.h>
17710 #include <time.h>
17711
17712 #ifdef HAVE_UNISTD_H
17713 # include <unistd.h>
17714 #endif
17715
17716 #ifndef HAVE_ALARM
17717 # define alarm(X) /* empty */
17718 #endif
17719
17720 /* Work around redefinition to rpl_putenv by other config tests. */
17721 #undef putenv
17722
17723 static time_t time_t_max;
17724 static time_t time_t_min;
17725
17726 /* Values we'll use to set the TZ environment variable. */
17727 static char *tz_strings[] = {
17728 (char *) 0, "TZ=GMT0", "TZ=JST-9",
17729 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
17730 };
17731 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
17732
17733 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
17734 Based on a problem report from Andreas Jaeger. */
17735 static int
17736 spring_forward_gap ()
17737 {
17738 /* glibc (up to about 1998-10-07) failed this test. */
17739 struct tm tm;
17740
17741 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
17742 instead of "TZ=America/Vancouver" in order to detect the bug even
17743 on systems that don't support the Olson extension, or don't have the
17744 full zoneinfo tables installed. */
17745 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
17746
17747 tm.tm_year = 98;
17748 tm.tm_mon = 3;
17749 tm.tm_mday = 5;
17750 tm.tm_hour = 2;
17751 tm.tm_min = 0;
17752 tm.tm_sec = 0;
17753 tm.tm_isdst = -1;
17754 return mktime (&tm) != (time_t) -1;
17755 }
17756
17757 static int
17758 mktime_test1 (time_t now)
17759 {
17760 struct tm *lt;
17761 return ! (lt = localtime (&now)) || mktime (lt) == now;
17762 }
17763
17764 static int
17765 mktime_test (time_t now)
17766 {
17767 return (mktime_test1 (now)
17768 && mktime_test1 ((time_t) (time_t_max - now))
17769 && mktime_test1 ((time_t) (time_t_min + now)));
17770 }
17771
17772 static int
17773 irix_6_4_bug ()
17774 {
17775 /* Based on code from Ariel Faigon. */
17776 struct tm tm;
17777 tm.tm_year = 96;
17778 tm.tm_mon = 3;
17779 tm.tm_mday = 0;
17780 tm.tm_hour = 0;
17781 tm.tm_min = 0;
17782 tm.tm_sec = 0;
17783 tm.tm_isdst = -1;
17784 mktime (&tm);
17785 return tm.tm_mon == 2 && tm.tm_mday == 31;
17786 }
17787
17788 static int
17789 bigtime_test (int j)
17790 {
17791 struct tm tm;
17792 time_t now;
17793 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
17794 now = mktime (&tm);
17795 if (now != (time_t) -1)
17796 {
17797 struct tm *lt = localtime (&now);
17798 if (! (lt
17799 && lt->tm_year == tm.tm_year
17800 && lt->tm_mon == tm.tm_mon
17801 && lt->tm_mday == tm.tm_mday
17802 && lt->tm_hour == tm.tm_hour
17803 && lt->tm_min == tm.tm_min
17804 && lt->tm_sec == tm.tm_sec
17805 && lt->tm_yday == tm.tm_yday
17806 && lt->tm_wday == tm.tm_wday
17807 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
17808 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
17809 return 0;
17810 }
17811 return 1;
17812 }
17813
17814 static int
17815 year_2050_test ()
17816 {
17817 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
17818 ignoring leap seconds. */
17819 unsigned long int answer = 2527315200UL;
17820
17821 struct tm tm;
17822 time_t t;
17823 tm.tm_year = 2050 - 1900;
17824 tm.tm_mon = 2 - 1;
17825 tm.tm_mday = 1;
17826 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
17827 tm.tm_isdst = -1;
17828
17829 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
17830 instead of "TZ=America/Vancouver" in order to detect the bug even
17831 on systems that don't support the Olson extension, or don't have the
17832 full zoneinfo tables installed. */
17833 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
17834
17835 t = mktime (&tm);
17836
17837 /* Check that the result is either a failure, or close enough
17838 to the correct answer that we can assume the discrepancy is
17839 due to leap seconds. */
17840 return (t == (time_t) -1
17841 || (0 < t && answer - 120 <= t && t <= answer + 120));
17842 }
17843
17844 int
17845 main ()
17846 {
17847 int result = 0;
17848 time_t t, delta;
17849 int i, j;
17850 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
17851 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
17852
17853 /* This test makes some buggy mktime implementations loop.
17854 Give up after 60 seconds; a mktime slower than that
17855 isn't worth using anyway. */
17856 alarm (60);
17857
17858 time_t_max = (! time_t_signed
17859 ? (time_t) -1
17860 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
17861 * 2 + 1));
17862 time_t_min = (! time_t_signed
17863 ? (time_t) 0
17864 : time_t_signed_magnitude
17865 ? ~ (time_t) 0
17866 : ~ time_t_max);
17867
17868 delta = time_t_max / 997; /* a suitable prime number */
17869 for (i = 0; i < N_STRINGS; i++)
17870 {
17871 if (tz_strings[i])
17872 putenv (tz_strings[i]);
17873
17874 for (t = 0; t <= time_t_max - delta; t += delta)
17875 if (! mktime_test (t))
17876 result |= 1;
17877 if (! (mktime_test ((time_t) 1)
17878 && mktime_test ((time_t) (60 * 60))
17879 && mktime_test ((time_t) (60 * 60 * 24))))
17880 result |= 2;
17881
17882 for (j = 1; ; j <<= 1)
17883 if (! bigtime_test (j))
17884 result |= 4;
17885 else if (INT_MAX / 2 < j)
17886 break;
17887 if (! bigtime_test (INT_MAX))
17888 result |= 8;
17889 }
17890 if (! irix_6_4_bug ())
17891 result |= 16;
17892 if (! spring_forward_gap ())
17893 result |= 32;
17894 if (! year_2050_test ())
17895 result |= 64;
17896 return result;
17897 }
17898 _ACEOF
17899 if ac_fn_c_try_run "$LINENO"; then :
17900 gl_cv_func_working_mktime=yes
17901 else
17902 gl_cv_func_working_mktime=no
17903 fi
17904 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17905 conftest.$ac_objext conftest.beam conftest.$ac_ext
17906 fi
17907
17908
17909 fi
17910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
17911 $as_echo "$gl_cv_func_working_mktime" >&6; }
17912
17913 if test $gl_cv_func_working_mktime = no; then
17914 REPLACE_MKTIME=1
17915 else
17916 REPLACE_MKTIME=0
17917 fi
17918
17919 if test $REPLACE_MKTIME = 1; then
17920
17921
17922
17923
17924
17925
17926
17927
17928 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
17929
17930
17931
17932
17933 fi
17934
17935
17936
17937
17938
17939 GNULIB_MKTIME=1
17940
17941
17942
17943
17944
17945
17946
17947
17948
17949 if test $ac_cv_func_readlink = no; then
17950 HAVE_READLINK=0
17951 else
17952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
17953 $as_echo_n "checking whether readlink signature is correct... " >&6; }
17954 if test "${gl_cv_decl_readlink_works+set}" = set; then :
17955 $as_echo_n "(cached) " >&6
17956 else
17957 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17958 /* end confdefs.h. */
17959 #include <unistd.h>
17960 /* Cause compilation failure if original declaration has wrong type. */
17961 ssize_t readlink (const char *, char *, size_t);
17962 int
17963 main ()
17964 {
17965
17966 ;
17967 return 0;
17968 }
17969 _ACEOF
17970 if ac_fn_c_try_compile "$LINENO"; then :
17971 gl_cv_decl_readlink_works=yes
17972 else
17973 gl_cv_decl_readlink_works=no
17974 fi
17975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17976 fi
17977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
17978 $as_echo "$gl_cv_decl_readlink_works" >&6; }
17979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
17980 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
17981 if test "${gl_cv_func_readlink_works+set}" = set; then :
17982 $as_echo_n "(cached) " >&6
17983 else
17984 # We have readlink, so assume ln -s works.
17985 ln -s conftest.no-such conftest.link
17986 ln -s conftest.link conftest.lnk2
17987 if test "$cross_compiling" = yes; then :
17988 gl_cv_func_readlink_works="guessing no"
17989 else
17990 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17991 /* end confdefs.h. */
17992 #include <unistd.h>
17993
17994 int
17995 main ()
17996 {
17997 char buf[20];
17998 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
17999 ;
18000 return 0;
18001 }
18002 _ACEOF
18003 if ac_fn_c_try_run "$LINENO"; then :
18004 gl_cv_func_readlink_works=yes
18005 else
18006 gl_cv_func_readlink_works=no
18007 fi
18008 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18009 conftest.$ac_objext conftest.beam conftest.$ac_ext
18010 fi
18011
18012 rm -f conftest.link conftest.lnk2
18013 fi
18014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
18015 $as_echo "$gl_cv_func_readlink_works" >&6; }
18016 if test "$gl_cv_func_readlink_works" != yes; then
18017
18018 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
18019
18020 REPLACE_READLINK=1
18021 elif test "$gl_cv_decl_readlink_works" != yes; then
18022 REPLACE_READLINK=1
18023 fi
18024 fi
18025
18026 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
18027
18028
18029
18030
18031
18032
18033
18034
18035 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
18036
18037
18038 :
18039
18040 fi
18041
18042
18043
18044
18045
18046 GNULIB_READLINK=1
18047
18048
18049
18050
18051
18052 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
18053 /* <sys/types.h> is not needed according to POSIX, but the
18054 <sys/socket.h> in i386-unknown-freebsd4.10 and
18055 powerpc-apple-darwin5.5 required it. */
18056 #include <sys/types.h>
18057 #if HAVE_SYS_SOCKET_H
18058 # include <sys/socket.h>
18059 #elif HAVE_WS2TCPIP_H
18060 # include <ws2tcpip.h>
18061 #endif
18062
18063 "
18064 if test "x$ac_cv_type_socklen_t" = x""yes; then :
18065
18066 else
18067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
18068 $as_echo_n "checking for socklen_t equivalent... " >&6; }
18069 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
18070 $as_echo_n "(cached) " >&6
18071 else
18072 # Systems have either "struct sockaddr *" or
18073 # "void *" as the second argument to getpeername
18074 gl_cv_socklen_t_equiv=
18075 for arg2 in "struct sockaddr" void; do
18076 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
18077 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18078 /* end confdefs.h. */
18079 #include <sys/types.h>
18080 #include <sys/socket.h>
18081
18082 int getpeername (int, $arg2 *, $t *);
18083 int
18084 main ()
18085 {
18086 $t len;
18087 getpeername (0, 0, &len);
18088 ;
18089 return 0;
18090 }
18091 _ACEOF
18092 if ac_fn_c_try_compile "$LINENO"; then :
18093 gl_cv_socklen_t_equiv="$t"
18094 fi
18095 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18096 test "$gl_cv_socklen_t_equiv" != "" && break
18097 done
18098 test "$gl_cv_socklen_t_equiv" != "" && break
18099 done
18100
18101 fi
18102
18103 if test "$gl_cv_socklen_t_equiv" = ""; then
18104 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
18105 fi
18106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
18107 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
18108
18109 cat >>confdefs.h <<_ACEOF
18110 #define socklen_t $gl_cv_socklen_t_equiv
18111 _ACEOF
18112
18113 fi
18114
18115
18116 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
18117 $as_echo_n "checking for ssize_t... " >&6; }
18118 if test "${gt_cv_ssize_t+set}" = set; then :
18119 $as_echo_n "(cached) " >&6
18120 else
18121 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18122 /* end confdefs.h. */
18123 #include <sys/types.h>
18124 int
18125 main ()
18126 {
18127 int x = sizeof (ssize_t *) + sizeof (ssize_t);
18128 return !x;
18129 ;
18130 return 0;
18131 }
18132 _ACEOF
18133 if ac_fn_c_try_compile "$LINENO"; then :
18134 gt_cv_ssize_t=yes
18135 else
18136 gt_cv_ssize_t=no
18137 fi
18138 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18139 fi
18140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
18141 $as_echo "$gt_cv_ssize_t" >&6; }
18142 if test $gt_cv_ssize_t = no; then
18143
18144 $as_echo "#define ssize_t int" >>confdefs.h
18145
18146 fi
18147
18148
18149 STDARG_H=''
18150 NEXT_STDARG_H='<stdarg.h>'
18151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
18152 $as_echo_n "checking for va_copy... " >&6; }
18153 if test "${gl_cv_func_va_copy+set}" = set; then :
18154 $as_echo_n "(cached) " >&6
18155 else
18156
18157 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18158 /* end confdefs.h. */
18159 #include <stdarg.h>
18160 int
18161 main ()
18162 {
18163
18164 #ifndef va_copy
18165 void (*func) (va_list, va_list) = va_copy;
18166 #endif
18167
18168 ;
18169 return 0;
18170 }
18171 _ACEOF
18172 if ac_fn_c_try_compile "$LINENO"; then :
18173 gl_cv_func_va_copy=yes
18174 else
18175 gl_cv_func_va_copy=no
18176 fi
18177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18178 fi
18179
18180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
18181 $as_echo "$gl_cv_func_va_copy" >&6; }
18182 if test $gl_cv_func_va_copy = no; then
18183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18184 /* end confdefs.h. */
18185 #if defined _AIX && !defined __GNUC__
18186 AIX vaccine
18187 #endif
18188
18189 _ACEOF
18190 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18191 $EGREP "vaccine" >/dev/null 2>&1; then :
18192 gl_aixcc=yes
18193 else
18194 gl_aixcc=no
18195 fi
18196 rm -f conftest*
18197
18198 if test $gl_aixcc = yes; then
18199 STDARG_H=stdarg.h
18200
18201
18202
18203
18204
18205
18206
18207
18208 if test $gl_cv_have_include_next = yes; then
18209 gl_cv_next_stdarg_h='<'stdarg.h'>'
18210 else
18211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
18212 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
18213 if test "${gl_cv_next_stdarg_h+set}" = set; then :
18214 $as_echo_n "(cached) " >&6
18215 else
18216
18217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18218 /* end confdefs.h. */
18219 #include <stdarg.h>
18220
18221 _ACEOF
18222 case "$host_os" in
18223 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18224 *) gl_absname_cpp="$ac_cpp" ;;
18225 esac
18226 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18227 sed -n '\#/stdarg.h#{
18228 s#.*"\(.*/stdarg.h\)".*#\1#
18229 s#^/[^/]#//&#
18230 p
18231 q
18232 }'`'"'
18233
18234
18235 fi
18236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
18237 $as_echo "$gl_cv_next_stdarg_h" >&6; }
18238 fi
18239 NEXT_STDARG_H=$gl_cv_next_stdarg_h
18240
18241 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18242 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18243 gl_next_as_first_directive='<'stdarg.h'>'
18244 else
18245 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18246 gl_next_as_first_directive=$gl_cv_next_stdarg_h
18247 fi
18248 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
18249
18250
18251
18252
18253 if test "$gl_cv_next_stdarg_h" = '""'; then
18254 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
18255 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
18256 fi
18257 else
18258
18259 saved_as_echo_n="$as_echo_n"
18260 as_echo_n=':'
18261 if test "${gl_cv_func___va_copy+set}" = set; then :
18262 $as_echo_n "(cached) " >&6
18263 else
18264
18265 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18266 /* end confdefs.h. */
18267 #include <stdarg.h>
18268 int
18269 main ()
18270 {
18271
18272 #ifndef __va_copy
18273 error, bail out
18274 #endif
18275
18276 ;
18277 return 0;
18278 }
18279 _ACEOF
18280 if ac_fn_c_try_compile "$LINENO"; then :
18281 gl_cv_func___va_copy=yes
18282 else
18283 gl_cv_func___va_copy=no
18284 fi
18285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18286 fi
18287
18288 as_echo_n="$saved_as_echo_n"
18289
18290 if test $gl_cv_func___va_copy = yes; then
18291
18292 $as_echo "#define va_copy __va_copy" >>confdefs.h
18293
18294 else
18295
18296
18297 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
18298
18299 fi
18300 fi
18301 fi
18302
18303 if test -n "$STDARG_H"; then
18304 GL_GENERATE_STDARG_H_TRUE=
18305 GL_GENERATE_STDARG_H_FALSE='#'
18306 else
18307 GL_GENERATE_STDARG_H_TRUE='#'
18308 GL_GENERATE_STDARG_H_FALSE=
18309 fi
18310
18311
18312
18313
18314
18315
18316 # Define two additional variables used in the Makefile substitution.
18317
18318 if test "$ac_cv_header_stdbool_h" = yes; then
18319 STDBOOL_H=''
18320 else
18321 STDBOOL_H='stdbool.h'
18322 fi
18323
18324 if test -n "$STDBOOL_H"; then
18325 GL_GENERATE_STDBOOL_H_TRUE=
18326 GL_GENERATE_STDBOOL_H_FALSE='#'
18327 else
18328 GL_GENERATE_STDBOOL_H_TRUE='#'
18329 GL_GENERATE_STDBOOL_H_FALSE=
18330 fi
18331
18332
18333 if test "$ac_cv_type__Bool" = yes; then
18334 HAVE__BOOL=1
18335 else
18336 HAVE__BOOL=0
18337 fi
18338
18339
18340
18341
18342
18343 STDDEF_H=
18344 if test $gt_cv_c_wchar_t = no; then
18345 HAVE_WCHAR_T=0
18346 STDDEF_H=stddef.h
18347 fi
18348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
18349 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
18350 if test "${gl_cv_decl_null_works+set}" = set; then :
18351 $as_echo_n "(cached) " >&6
18352 else
18353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18354 /* end confdefs.h. */
18355 #include <stddef.h>
18356 int test[2 * (sizeof NULL == sizeof (void *)) -1];
18357
18358 int
18359 main ()
18360 {
18361
18362 ;
18363 return 0;
18364 }
18365 _ACEOF
18366 if ac_fn_c_try_compile "$LINENO"; then :
18367 gl_cv_decl_null_works=yes
18368 else
18369 gl_cv_decl_null_works=no
18370 fi
18371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18372 fi
18373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
18374 $as_echo "$gl_cv_decl_null_works" >&6; }
18375 if test $gl_cv_decl_null_works = no; then
18376 REPLACE_NULL=1
18377 STDDEF_H=stddef.h
18378 fi
18379
18380 if test -n "$STDDEF_H"; then
18381 GL_GENERATE_STDDEF_H_TRUE=
18382 GL_GENERATE_STDDEF_H_FALSE='#'
18383 else
18384 GL_GENERATE_STDDEF_H_TRUE='#'
18385 GL_GENERATE_STDDEF_H_FALSE=
18386 fi
18387
18388 if test -n "$STDDEF_H"; then
18389
18390
18391
18392
18393
18394
18395
18396
18397 if test $gl_cv_have_include_next = yes; then
18398 gl_cv_next_stddef_h='<'stddef.h'>'
18399 else
18400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
18401 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
18402 if test "${gl_cv_next_stddef_h+set}" = set; then :
18403 $as_echo_n "(cached) " >&6
18404 else
18405
18406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18407 /* end confdefs.h. */
18408 #include <stddef.h>
18409
18410 _ACEOF
18411 case "$host_os" in
18412 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18413 *) gl_absname_cpp="$ac_cpp" ;;
18414 esac
18415 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18416 sed -n '\#/stddef.h#{
18417 s#.*"\(.*/stddef.h\)".*#\1#
18418 s#^/[^/]#//&#
18419 p
18420 q
18421 }'`'"'
18422
18423
18424 fi
18425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
18426 $as_echo "$gl_cv_next_stddef_h" >&6; }
18427 fi
18428 NEXT_STDDEF_H=$gl_cv_next_stddef_h
18429
18430 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18431 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18432 gl_next_as_first_directive='<'stddef.h'>'
18433 else
18434 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18435 gl_next_as_first_directive=$gl_cv_next_stddef_h
18436 fi
18437 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
18438
18439
18440
18441
18442 fi
18443
18444
18445
18446
18447
18448
18449
18450
18451
18452
18453
18454
18455
18456 if test $gl_cv_have_include_next = yes; then
18457 gl_cv_next_stdio_h='<'stdio.h'>'
18458 else
18459 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
18460 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
18461 if test "${gl_cv_next_stdio_h+set}" = set; then :
18462 $as_echo_n "(cached) " >&6
18463 else
18464
18465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18466 /* end confdefs.h. */
18467 #include <stdio.h>
18468
18469 _ACEOF
18470 case "$host_os" in
18471 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18472 *) gl_absname_cpp="$ac_cpp" ;;
18473 esac
18474 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18475 sed -n '\#/stdio.h#{
18476 s#.*"\(.*/stdio.h\)".*#\1#
18477 s#^/[^/]#//&#
18478 p
18479 q
18480 }'`'"'
18481
18482
18483 fi
18484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
18485 $as_echo "$gl_cv_next_stdio_h" >&6; }
18486 fi
18487 NEXT_STDIO_H=$gl_cv_next_stdio_h
18488
18489 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18490 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18491 gl_next_as_first_directive='<'stdio.h'>'
18492 else
18493 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18494 gl_next_as_first_directive=$gl_cv_next_stdio_h
18495 fi
18496 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
18497
18498
18499
18500
18501
18502 GNULIB_FSCANF=1
18503 GNULIB_SCANF=1
18504 GNULIB_FGETC=1
18505 GNULIB_GETC=1
18506 GNULIB_GETCHAR=1
18507 GNULIB_FGETS=1
18508 GNULIB_GETS=1
18509 GNULIB_FREAD=1
18510
18511
18512 GNULIB_FPRINTF=1
18513 GNULIB_PRINTF=1
18514 GNULIB_VFPRINTF=1
18515 GNULIB_VPRINTF=1
18516 GNULIB_FPUTC=1
18517 GNULIB_PUTC=1
18518 GNULIB_PUTCHAR=1
18519 GNULIB_FPUTS=1
18520 GNULIB_PUTS=1
18521 GNULIB_FWRITE=1
18522
18523
18524
18525
18526
18527
18528
18529
18530
18531
18532
18533
18534
18535
18536
18537 if test $gl_cv_have_include_next = yes; then
18538 gl_cv_next_stdlib_h='<'stdlib.h'>'
18539 else
18540 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
18541 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
18542 if test "${gl_cv_next_stdlib_h+set}" = set; then :
18543 $as_echo_n "(cached) " >&6
18544 else
18545
18546 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18547 /* end confdefs.h. */
18548 #include <stdlib.h>
18549
18550 _ACEOF
18551 case "$host_os" in
18552 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18553 *) gl_absname_cpp="$ac_cpp" ;;
18554 esac
18555 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18556 sed -n '\#/stdlib.h#{
18557 s#.*"\(.*/stdlib.h\)".*#\1#
18558 s#^/[^/]#//&#
18559 p
18560 q
18561 }'`'"'
18562
18563
18564 fi
18565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
18566 $as_echo "$gl_cv_next_stdlib_h" >&6; }
18567 fi
18568 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
18569
18570 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18571 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18572 gl_next_as_first_directive='<'stdlib.h'>'
18573 else
18574 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18575 gl_next_as_first_directive=$gl_cv_next_stdlib_h
18576 fi
18577 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
18578
18579
18580
18581
18582
18583
18584
18585
18586
18587 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
18588
18589
18590
18591
18592
18593
18594
18595 $as_echo "#define my_strftime nstrftime" >>confdefs.h
18596
18597
18598
18599
18600
18601
18602
18603 if test "$ac_cv_have_decl_strtoumax" != yes; then
18604 HAVE_DECL_STRTOUMAX=0
18605
18606 for ac_func in strtoumax
18607 do :
18608 ac_fn_c_check_func "$LINENO" "strtoumax" "ac_cv_func_strtoumax"
18609 if test "x$ac_cv_func_strtoumax" = x""yes; then :
18610 cat >>confdefs.h <<_ACEOF
18611 #define HAVE_STRTOUMAX 1
18612 _ACEOF
18613
18614 fi
18615 done
18616
18617 fi
18618
18619 if test "$ac_cv_have_decl_strtoumax" != yes && test $ac_cv_func_strtoumax = no; then
18620
18621
18622
18623
18624
18625
18626
18627
18628 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
18629
18630
18631 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
18632 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
18633 ac_have_decl=1
18634 else
18635 ac_have_decl=0
18636 fi
18637
18638 cat >>confdefs.h <<_ACEOF
18639 #define HAVE_DECL_STRTOULL $ac_have_decl
18640 _ACEOF
18641
18642
18643
18644 fi
18645
18646
18647
18648
18649
18650 GNULIB_STRTOUMAX=1
18651
18652
18653
18654
18655
18656
18657
18658 if test $ac_cv_func_symlink = no; then
18659 HAVE_SYMLINK=0
18660 else
18661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
18662 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
18663 if test "${gl_cv_func_symlink_works+set}" = set; then :
18664 $as_echo_n "(cached) " >&6
18665 else
18666 if test "$cross_compiling" = yes; then :
18667 gl_cv_func_symlink_works="guessing no"
18668 else
18669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18670 /* end confdefs.h. */
18671 #include <unistd.h>
18672
18673 int
18674 main ()
18675 {
18676 int result = 0;
18677 if (!symlink ("a", "conftest.link/"))
18678 result |= 1;
18679 if (symlink ("conftest.f", "conftest.lnk2"))
18680 result |= 2;
18681 else if (!symlink ("a", "conftest.lnk2/"))
18682 result |= 4;
18683 return result;
18684
18685 ;
18686 return 0;
18687 }
18688 _ACEOF
18689 if ac_fn_c_try_run "$LINENO"; then :
18690 gl_cv_func_symlink_works=yes
18691 else
18692 gl_cv_func_symlink_works=no
18693 fi
18694 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18695 conftest.$ac_objext conftest.beam conftest.$ac_ext
18696 fi
18697
18698 rm -f conftest.f conftest.link conftest.lnk2
18699 fi
18700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
18701 $as_echo "$gl_cv_func_symlink_works" >&6; }
18702 if test "$gl_cv_func_symlink_works" != yes; then
18703 REPLACE_SYMLINK=1
18704 fi
18705 fi
18706
18707 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
18708
18709
18710
18711
18712
18713
18714
18715
18716 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
18717
18718 fi
18719
18720
18721
18722
18723
18724 GNULIB_SYMLINK=1
18725
18726
18727
18728
18729
18730
18731
18732
18733
18734
18735
18736
18737
18738
18739
18740
18741
18742
18743
18744
18745
18746 if test $gl_cv_have_include_next = yes; then
18747 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
18748 else
18749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
18750 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
18751 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
18752 $as_echo_n "(cached) " >&6
18753 else
18754
18755 if test $ac_cv_header_sys_stat_h = yes; then
18756
18757
18758 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18759 /* end confdefs.h. */
18760 #include <sys/stat.h>
18761
18762 _ACEOF
18763 case "$host_os" in
18764 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18765 *) gl_absname_cpp="$ac_cpp" ;;
18766 esac
18767 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18768 sed -n '\#/sys/stat.h#{
18769 s#.*"\(.*/sys/stat.h\)".*#\1#
18770 s#^/[^/]#//&#
18771 p
18772 q
18773 }'`'"'
18774 else
18775 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
18776 fi
18777
18778
18779 fi
18780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
18781 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
18782 fi
18783 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
18784
18785 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18786 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18787 gl_next_as_first_directive='<'sys/stat.h'>'
18788 else
18789 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18790 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
18791 fi
18792 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
18793
18794
18795
18796
18797
18798 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
18799 #include <sys/stat.h>
18800 "
18801 if test "x$ac_cv_type_nlink_t" = x""yes; then :
18802
18803 else
18804
18805 $as_echo "#define nlink_t int" >>confdefs.h
18806
18807 fi
18808
18809
18810
18811
18812
18813
18814
18815
18816
18817
18818
18819
18820
18821
18822
18823 if test $ac_cv_have_decl_localtime_r = no; then
18824 HAVE_DECL_LOCALTIME_R=0
18825 fi
18826
18827
18828 if test $ac_cv_func_localtime_r = yes; then
18829 HAVE_LOCALTIME_R=1
18830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
18831 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
18832 if test "${gl_cv_time_r_posix+set}" = set; then :
18833 $as_echo_n "(cached) " >&6
18834 else
18835 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18836 /* end confdefs.h. */
18837 #include <time.h>
18838 int
18839 main ()
18840 {
18841 /* We don't need to append 'restrict's to the argument types,
18842 even though the POSIX signature has the 'restrict's,
18843 since C99 says they can't affect type compatibility. */
18844 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
18845 if (ptr) return 0;
18846 /* Check the return type is a pointer.
18847 On HP-UX 10 it is 'int'. */
18848 *localtime_r (0, 0);
18849 ;
18850 return 0;
18851 }
18852
18853 _ACEOF
18854 if ac_fn_c_try_compile "$LINENO"; then :
18855 gl_cv_time_r_posix=yes
18856 else
18857 gl_cv_time_r_posix=no
18858 fi
18859 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18860
18861 fi
18862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
18863 $as_echo "$gl_cv_time_r_posix" >&6; }
18864 if test $gl_cv_time_r_posix = yes; then
18865 REPLACE_LOCALTIME_R=0
18866 else
18867 REPLACE_LOCALTIME_R=1
18868 fi
18869 else
18870 HAVE_LOCALTIME_R=0
18871 fi
18872
18873 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
18874
18875
18876
18877
18878
18879
18880
18881
18882 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
18883
18884
18885 :
18886
18887 fi
18888
18889
18890
18891
18892
18893 GNULIB_TIME_R=1
18894
18895
18896
18897
18898
18899
18900
18901
18902
18903
18904
18905
18906
18907
18908
18909
18910
18911
18912
18913 if test $gl_cv_have_include_next = yes; then
18914 gl_cv_next_unistd_h='<'unistd.h'>'
18915 else
18916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
18917 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
18918 if test "${gl_cv_next_unistd_h+set}" = set; then :
18919 $as_echo_n "(cached) " >&6
18920 else
18921
18922 if test $ac_cv_header_unistd_h = yes; then
18923
18924
18925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18926 /* end confdefs.h. */
18927 #include <unistd.h>
18928
18929 _ACEOF
18930 case "$host_os" in
18931 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18932 *) gl_absname_cpp="$ac_cpp" ;;
18933 esac
18934 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18935 sed -n '\#/unistd.h#{
18936 s#.*"\(.*/unistd.h\)".*#\1#
18937 s#^/[^/]#//&#
18938 p
18939 q
18940 }'`'"'
18941 else
18942 gl_cv_next_unistd_h='<'unistd.h'>'
18943 fi
18944
18945
18946 fi
18947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
18948 $as_echo "$gl_cv_next_unistd_h" >&6; }
18949 fi
18950 NEXT_UNISTD_H=$gl_cv_next_unistd_h
18951
18952 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18953 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18954 gl_next_as_first_directive='<'unistd.h'>'
18955 else
18956 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18957 gl_next_as_first_directive=$gl_cv_next_unistd_h
18958 fi
18959 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
18960
18961
18962
18963
18964 if test $ac_cv_header_unistd_h = yes; then
18965 HAVE_UNISTD_H=1
18966 else
18967 HAVE_UNISTD_H=0
18968 fi
18969
18970
18971
18972
18973 gl_gnulib_enabled_dosname=false
18974 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
18975 gl_gnulib_enabled_stat=false
18976 gl_gnulib_enabled_strtoull=false
18977 gl_gnulib_enabled_verify=false
18978 func_gl_gnulib_m4code_dosname ()
18979 {
18980 if ! $gl_gnulib_enabled_dosname; then
18981 gl_gnulib_enabled_dosname=true
18982 fi
18983 }
18984 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
18985 {
18986 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
18987
18988
18989 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
18990 fi
18991 }
18992 func_gl_gnulib_m4code_stat ()
18993 {
18994 if ! $gl_gnulib_enabled_stat; then
18995
18996
18997
18998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
18999 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
19000 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
19001 $as_echo_n "(cached) " >&6
19002 else
19003 if test "$cross_compiling" = yes; then :
19004 case $host_os in
19005 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
19006 *) gl_cv_func_stat_dir_slash="guessing yes";;
19007 esac
19008 else
19009 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19010 /* end confdefs.h. */
19011 #include <sys/stat.h>
19012
19013 int
19014 main ()
19015 {
19016 struct stat st; return stat (".", &st) != stat ("./", &st);
19017 ;
19018 return 0;
19019 }
19020 _ACEOF
19021 if ac_fn_c_try_run "$LINENO"; then :
19022 gl_cv_func_stat_dir_slash=yes
19023 else
19024 gl_cv_func_stat_dir_slash=no
19025 fi
19026 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19027 conftest.$ac_objext conftest.beam conftest.$ac_ext
19028 fi
19029
19030 fi
19031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
19032 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
19033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
19034 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
19035 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
19036 $as_echo_n "(cached) " >&6
19037 else
19038 touch conftest.tmp
19039 # Assume that if we have lstat, we can also check symlinks.
19040 if test $ac_cv_func_lstat = yes; then
19041 ln -s conftest.tmp conftest.lnk
19042 fi
19043 if test "$cross_compiling" = yes; then :
19044 gl_cv_func_stat_file_slash="guessing no"
19045 else
19046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19047 /* end confdefs.h. */
19048 #include <sys/stat.h>
19049
19050 int
19051 main ()
19052 {
19053 int result = 0;
19054 struct stat st;
19055 if (!stat ("conftest.tmp/", &st))
19056 result |= 1;
19057 #if HAVE_LSTAT
19058 if (!stat ("conftest.lnk/", &st))
19059 result |= 2;
19060 #endif
19061 return result;
19062
19063 ;
19064 return 0;
19065 }
19066 _ACEOF
19067 if ac_fn_c_try_run "$LINENO"; then :
19068 gl_cv_func_stat_file_slash=yes
19069 else
19070 gl_cv_func_stat_file_slash=no
19071 fi
19072 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19073 conftest.$ac_objext conftest.beam conftest.$ac_ext
19074 fi
19075
19076 rm -f conftest.tmp conftest.lnk
19077 fi
19078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
19079 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
19080 case $gl_cv_func_stat_dir_slash in
19081 *no) REPLACE_STAT=1
19082
19083 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
19084 ;;
19085 esac
19086 case $gl_cv_func_stat_file_slash in
19087 *no) REPLACE_STAT=1
19088
19089 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
19090 ;;
19091 esac
19092
19093 if test $REPLACE_STAT = 1; then
19094
19095
19096
19097
19098
19099
19100
19101
19102 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
19103
19104
19105
19106 :
19107
19108 fi
19109
19110
19111
19112
19113
19114 GNULIB_STAT=1
19115
19116
19117
19118
19119
19120 gl_gnulib_enabled_stat=true
19121 if $condition; then
19122 func_gl_gnulib_m4code_dosname
19123 fi
19124 if $condition; then
19125 func_gl_gnulib_m4code_verify
19126 fi
19127 fi
19128 }
19129 func_gl_gnulib_m4code_strtoull ()
19130 {
19131 if ! $gl_gnulib_enabled_strtoull; then
19132
19133
19134
19135 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
19136 for ac_func in strtoull
19137 do :
19138 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
19139 if test "x$ac_cv_func_strtoull" = x""yes; then :
19140 cat >>confdefs.h <<_ACEOF
19141 #define HAVE_STRTOULL 1
19142 _ACEOF
19143
19144 fi
19145 done
19146
19147 if test $ac_cv_func_strtoull = no; then
19148 HAVE_STRTOULL=0
19149 fi
19150 fi
19151
19152 if test $HAVE_STRTOULL = 0; then
19153
19154
19155
19156
19157
19158
19159
19160
19161 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
19162
19163
19164 :
19165
19166 fi
19167
19168
19169
19170
19171
19172 GNULIB_STRTOULL=1
19173
19174
19175
19176
19177
19178 gl_gnulib_enabled_strtoull=true
19179 fi
19180 }
19181 func_gl_gnulib_m4code_verify ()
19182 {
19183 if ! $gl_gnulib_enabled_verify; then
19184 gl_gnulib_enabled_verify=true
19185 fi
19186 }
19187 if test $REPLACE_GETOPT = 1; then
19188 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
19189 fi
19190 if test $REPLACE_LSTAT = 1; then
19191 func_gl_gnulib_m4code_dosname
19192 fi
19193 if test $REPLACE_LSTAT = 1; then
19194 func_gl_gnulib_m4code_stat
19195 fi
19196 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
19197 func_gl_gnulib_m4code_stat
19198 fi
19199 if test "$ac_cv_have_decl_strtoumax" != yes && test $ac_cv_func_strtoumax = no; then
19200 func_gl_gnulib_m4code_verify
19201 fi
19202 if test "$ac_cv_have_decl_strtoumax" != yes && test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
19203 func_gl_gnulib_m4code_strtoull
19204 fi
19205
19206 if $gl_gnulib_enabled_dosname; then
19207 gl_GNULIB_ENABLED_dosname_TRUE=
19208 gl_GNULIB_ENABLED_dosname_FALSE='#'
19209 else
19210 gl_GNULIB_ENABLED_dosname_TRUE='#'
19211 gl_GNULIB_ENABLED_dosname_FALSE=
19212 fi
19213
19214 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
19215 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
19216 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
19217 else
19218 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
19219 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
19220 fi
19221
19222 if $gl_gnulib_enabled_stat; then
19223 gl_GNULIB_ENABLED_stat_TRUE=
19224 gl_GNULIB_ENABLED_stat_FALSE='#'
19225 else
19226 gl_GNULIB_ENABLED_stat_TRUE='#'
19227 gl_GNULIB_ENABLED_stat_FALSE=
19228 fi
19229
19230 if $gl_gnulib_enabled_strtoull; then
19231 gl_GNULIB_ENABLED_strtoull_TRUE=
19232 gl_GNULIB_ENABLED_strtoull_FALSE='#'
19233 else
19234 gl_GNULIB_ENABLED_strtoull_TRUE='#'
19235 gl_GNULIB_ENABLED_strtoull_FALSE=
19236 fi
19237
19238 if $gl_gnulib_enabled_verify; then
19239 gl_GNULIB_ENABLED_verify_TRUE=
19240 gl_GNULIB_ENABLED_verify_FALSE='#'
19241 else
19242 gl_GNULIB_ENABLED_verify_TRUE='#'
19243 gl_GNULIB_ENABLED_verify_FALSE=
19244 fi
19245
19246 # End of code from modules
19247
19248
19249
19250
19251
19252
19253
19254
19255
19256 gltests_libdeps=
19257 gltests_ltlibdeps=
19258
19259
19260
19261
19262
19263
19264
19265
19266
19267 gl_source_base='tests'
19268 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
19269
19270 gl_module_indicator_condition=$gltests_WITNESS
19271
19272
19273
19274
19275
19276
19277
19278
19279
19280
19281 LIBGNU_LIBDEPS="$gl_libdeps"
19282
19283 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
19284
19285
19286
19287 # UNIX98 PTYs.
19288 for ac_func in grantpt
19289 do :
19290 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
19291 if test "x$ac_cv_func_grantpt" = x""yes; then :
19292 cat >>confdefs.h <<_ACEOF
19293 #define HAVE_GRANTPT 1
19294 _ACEOF
19295
19296 fi
19297 done
19298
19299
19300 # PTY-related GNU extensions.
19301 for ac_func in getpt
19302 do :
19303 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
19304 if test "x$ac_cv_func_getpt" = x""yes; then :
19305 cat >>confdefs.h <<_ACEOF
19306 #define HAVE_GETPT 1
19307 _ACEOF
19308
19309 fi
19310 done
19311
19312
19313 # Check this now, so that we will NOT find the above functions in ncurses.
19314 # That is because we have not set up to link ncurses in lib-src.
19315 # It's better to believe a function is not available
19316 # than to expect to find it in ncurses.
19317 # Also we need tputs and friends to be able to build at all.
19318 have_tputs_et_al=true
19319 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
19320 $as_echo_n "checking for library containing tputs... " >&6; }
19321 if test "${ac_cv_search_tputs+set}" = set; then :
19322 $as_echo_n "(cached) " >&6
19323 else
19324 ac_func_search_save_LIBS=$LIBS
19325 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19326 /* end confdefs.h. */
19327
19328 /* Override any GCC internal prototype to avoid an error.
19329 Use char because int might match the return type of a GCC
19330 builtin and then its argument prototype would still apply. */
19331 #ifdef __cplusplus
19332 extern "C"
19333 #endif
19334 char tputs ();
19335 int
19336 main ()
19337 {
19338 return tputs ();
19339 ;
19340 return 0;
19341 }
19342 _ACEOF
19343 for ac_lib in '' ncurses terminfo termcap; do
19344 if test -z "$ac_lib"; then
19345 ac_res="none required"
19346 else
19347 ac_res=-l$ac_lib
19348 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
19349 fi
19350 if ac_fn_c_try_link "$LINENO"; then :
19351 ac_cv_search_tputs=$ac_res
19352 fi
19353 rm -f core conftest.err conftest.$ac_objext \
19354 conftest$ac_exeext
19355 if test "${ac_cv_search_tputs+set}" = set; then :
19356 break
19357 fi
19358 done
19359 if test "${ac_cv_search_tputs+set}" = set; then :
19360
19361 else
19362 ac_cv_search_tputs=no
19363 fi
19364 rm conftest.$ac_ext
19365 LIBS=$ac_func_search_save_LIBS
19366 fi
19367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_tputs" >&5
19368 $as_echo "$ac_cv_search_tputs" >&6; }
19369 ac_res=$ac_cv_search_tputs
19370 if test "$ac_res" != no; then :
19371 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
19372
19373 else
19374 have_tputs_et_al=false
19375 fi
19376
19377 if test "$have_tputs_et_al" != true; then
19378 as_fn_error "I couldn't find termcap functions (tputs and friends).
19379 Maybe some development libraries/packages are missing? Try installing
19380 libncurses-dev(el), libterminfo-dev(el) or similar." "$LINENO" 5
19381 fi
19382 # Must define this when any termcap library is found.
19383
19384 $as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
19385
19386 ## FIXME This was the cpp logic, but I am not sure it is right.
19387 ## The above test has not necessarily found libncurses.
19388 HAVE_LIBNCURSES=yes
19389
19390 ## Use terminfo instead of termcap?
19391 ## Note only system files NOT using terminfo are:
19392 ## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
19393 ## darwin|gnu without ncurses.
19394 TERMINFO=no
19395 LIBS_TERMCAP=
19396 case "$opsys" in
19397 ## cygwin: Fewer environment variables to go wrong, more terminal types.
19398 ## hpux10-20: Use the system provided termcap(3) library.
19399 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
19400 ## is necessary. Otherwise Emacs dumps core when run -nw.
19401 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
19402
19403 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
19404 ## The ncurses library has been moved out of the System framework in
19405 ## Mac OS X 10.2. So if configure detects it, set the command-line
19406 ## option to use it.
19407 darwin|gnu*)
19408 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
19409 if test "x$HAVE_LIBNCURSES" = "xyes"; then
19410 TERMINFO=yes
19411 LIBS_TERMCAP="-lncurses"
19412 fi
19413 ;;
19414
19415 freebsd)
19416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
19417 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
19418 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
19419 $as_echo_n "(cached) " >&6
19420 else
19421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19422 /* end confdefs.h. */
19423 #include <osreldate.h>
19424 int
19425 main ()
19426 {
19427 #if __FreeBSD_version < 400000
19428 fail;
19429 #endif
19430
19431 ;
19432 return 0;
19433 }
19434 _ACEOF
19435 if ac_fn_c_try_link "$LINENO"; then :
19436 emacs_cv_freebsd_terminfo=yes
19437 else
19438 emacs_cv_freebsd_terminfo=no
19439 fi
19440 rm -f core conftest.err conftest.$ac_objext \
19441 conftest$ac_exeext conftest.$ac_ext
19442 fi
19443
19444
19445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
19446 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
19447
19448 if test $emacs_cv_freebsd_terminfo = yes; then
19449 TERMINFO=yes
19450 LIBS_TERMCAP="-lncurses"
19451 else
19452 LIBS_TERMCAP="-ltermcap"
19453 fi
19454 ;;
19455
19456 netbsd)
19457 if test $ac_cv_search_tputs = -lterminfo; then
19458 TERMINFO=yes
19459 LIBS_TERMCAP="-lterminfo"
19460 else
19461 LIBS_TERMCAP="-ltermcap"
19462 fi
19463 ;;
19464
19465 esac
19466
19467 case "$opsys" in
19468 ## hpux: Make sure we get select from libc rather than from libcurses
19469 ## because libcurses on HPUX 10.10 has a broken version of select.
19470 ## We used to use -lc -lcurses, but this may be cleaner.
19471 hpux*) LIBS_TERMCAP="-ltermcap" ;;
19472
19473 openbsd) LIBS_TERMCAP="-lncurses" ;;
19474
19475 ## Must use system termcap, if we use any termcap. It does special things.
19476 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
19477 esac
19478
19479 TERMCAP_OBJ=tparam.o
19480 if test $TERMINFO = yes; then
19481
19482 $as_echo "#define TERMINFO 1" >>confdefs.h
19483
19484
19485 ## Default used to be -ltermcap. Add a case above if need something else.
19486 test "x$LIBS_TERMCAP" = "x" && LIBS_TERMCAP="-lcurses"
19487
19488 TERMCAP_OBJ=terminfo.o
19489 fi
19490
19491
19492
19493
19494 # Do we have res_init, for detecting changes in /etc/resolv.conf?
19495 resolv=no
19496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19497 /* end confdefs.h. */
19498 #include <netinet/in.h>
19499 #include <arpa/nameser.h>
19500 #include <resolv.h>
19501 int
19502 main ()
19503 {
19504 return res_init();
19505 ;
19506 return 0;
19507 }
19508 _ACEOF
19509 if ac_fn_c_try_link "$LINENO"; then :
19510 have_res_init=yes
19511 else
19512 have_res_init=no
19513 fi
19514 rm -f core conftest.err conftest.$ac_objext \
19515 conftest$ac_exeext conftest.$ac_ext
19516 if test "$have_res_init" = no; then
19517 OLIBS="$LIBS"
19518 LIBS="$LIBS -lresolv"
19519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
19520 $as_echo_n "checking for res_init with -lresolv... " >&6; }
19521 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19522 /* end confdefs.h. */
19523 #include <netinet/in.h>
19524 #include <arpa/nameser.h>
19525 #include <resolv.h>
19526 int
19527 main ()
19528 {
19529 return res_init();
19530 ;
19531 return 0;
19532 }
19533 _ACEOF
19534 if ac_fn_c_try_link "$LINENO"; then :
19535 have_res_init=yes
19536 else
19537 have_res_init=no
19538 fi
19539 rm -f core conftest.err conftest.$ac_objext \
19540 conftest$ac_exeext conftest.$ac_ext
19541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
19542 $as_echo "$have_res_init" >&6; }
19543 if test "$have_res_init" = yes ; then
19544 resolv=yes
19545 fi
19546 LIBS="$OLIBS"
19547 fi
19548
19549 if test "$have_res_init" = yes; then
19550
19551 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
19552
19553 fi
19554
19555 # Do we need the Hesiod library to provide the support routines?
19556 LIBHESIOD=
19557 if test "$with_hesiod" != no ; then
19558 # Don't set $LIBS here -- see comments above. FIXME which comments?
19559 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
19560 if test "x$ac_cv_func_res_send" = x""yes; then :
19561
19562 else
19563 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
19564 if test "x$ac_cv_func___res_send" = x""yes; then :
19565
19566 else
19567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
19568 $as_echo_n "checking for res_send in -lresolv... " >&6; }
19569 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
19570 $as_echo_n "(cached) " >&6
19571 else
19572 ac_check_lib_save_LIBS=$LIBS
19573 LIBS="-lresolv $LIBS"
19574 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19575 /* end confdefs.h. */
19576
19577 /* Override any GCC internal prototype to avoid an error.
19578 Use char because int might match the return type of a GCC
19579 builtin and then its argument prototype would still apply. */
19580 #ifdef __cplusplus
19581 extern "C"
19582 #endif
19583 char res_send ();
19584 int
19585 main ()
19586 {
19587 return res_send ();
19588 ;
19589 return 0;
19590 }
19591 _ACEOF
19592 if ac_fn_c_try_link "$LINENO"; then :
19593 ac_cv_lib_resolv_res_send=yes
19594 else
19595 ac_cv_lib_resolv_res_send=no
19596 fi
19597 rm -f core conftest.err conftest.$ac_objext \
19598 conftest$ac_exeext conftest.$ac_ext
19599 LIBS=$ac_check_lib_save_LIBS
19600 fi
19601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
19602 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
19603 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
19604 resolv=yes
19605 else
19606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
19607 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
19608 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
19609 $as_echo_n "(cached) " >&6
19610 else
19611 ac_check_lib_save_LIBS=$LIBS
19612 LIBS="-lresolv $LIBS"
19613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19614 /* end confdefs.h. */
19615
19616 /* Override any GCC internal prototype to avoid an error.
19617 Use char because int might match the return type of a GCC
19618 builtin and then its argument prototype would still apply. */
19619 #ifdef __cplusplus
19620 extern "C"
19621 #endif
19622 char __res_send ();
19623 int
19624 main ()
19625 {
19626 return __res_send ();
19627 ;
19628 return 0;
19629 }
19630 _ACEOF
19631 if ac_fn_c_try_link "$LINENO"; then :
19632 ac_cv_lib_resolv___res_send=yes
19633 else
19634 ac_cv_lib_resolv___res_send=no
19635 fi
19636 rm -f core conftest.err conftest.$ac_objext \
19637 conftest$ac_exeext conftest.$ac_ext
19638 LIBS=$ac_check_lib_save_LIBS
19639 fi
19640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
19641 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
19642 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
19643 resolv=yes
19644 fi
19645
19646 fi
19647
19648 fi
19649
19650 fi
19651
19652 if test "$resolv" = yes ; then
19653 RESOLVLIB=-lresolv
19654 else
19655 RESOLVLIB=
19656 fi
19657 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
19658 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
19659
19660 else
19661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
19662 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
19663 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
19664 $as_echo_n "(cached) " >&6
19665 else
19666 ac_check_lib_save_LIBS=$LIBS
19667 LIBS="-lhesiod $RESOLVLIB $LIBS"
19668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19669 /* end confdefs.h. */
19670
19671 /* Override any GCC internal prototype to avoid an error.
19672 Use char because int might match the return type of a GCC
19673 builtin and then its argument prototype would still apply. */
19674 #ifdef __cplusplus
19675 extern "C"
19676 #endif
19677 char hes_getmailhost ();
19678 int
19679 main ()
19680 {
19681 return hes_getmailhost ();
19682 ;
19683 return 0;
19684 }
19685 _ACEOF
19686 if ac_fn_c_try_link "$LINENO"; then :
19687 ac_cv_lib_hesiod_hes_getmailhost=yes
19688 else
19689 ac_cv_lib_hesiod_hes_getmailhost=no
19690 fi
19691 rm -f core conftest.err conftest.$ac_objext \
19692 conftest$ac_exeext conftest.$ac_ext
19693 LIBS=$ac_check_lib_save_LIBS
19694 fi
19695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
19696 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
19697 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
19698 hesiod=yes
19699 else
19700 :
19701 fi
19702
19703 fi
19704
19705
19706 if test x"$hesiod" = xyes; then
19707
19708 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
19709
19710 LIBHESIOD=-lhesiod
19711 fi
19712 fi
19713
19714
19715 # Do we need libresolv (due to res_init or Hesiod)?
19716 if test "$resolv" = yes ; then
19717
19718 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
19719
19720 LIBRESOLV=-lresolv
19721 else
19722 LIBRESOLV=
19723 fi
19724
19725
19726 # These tell us which Kerberos-related libraries to use.
19727 COM_ERRLIB=
19728 CRYPTOLIB=
19729 KRB5LIB=
19730 DESLIB=
19731 KRB4LIB=
19732
19733 if test "${with_kerberos}" != no; then
19734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
19735 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
19736 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
19737 $as_echo_n "(cached) " >&6
19738 else
19739 ac_check_lib_save_LIBS=$LIBS
19740 LIBS="-lcom_err $LIBS"
19741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19742 /* end confdefs.h. */
19743
19744 /* Override any GCC internal prototype to avoid an error.
19745 Use char because int might match the return type of a GCC
19746 builtin and then its argument prototype would still apply. */
19747 #ifdef __cplusplus
19748 extern "C"
19749 #endif
19750 char com_err ();
19751 int
19752 main ()
19753 {
19754 return com_err ();
19755 ;
19756 return 0;
19757 }
19758 _ACEOF
19759 if ac_fn_c_try_link "$LINENO"; then :
19760 ac_cv_lib_com_err_com_err=yes
19761 else
19762 ac_cv_lib_com_err_com_err=no
19763 fi
19764 rm -f core conftest.err conftest.$ac_objext \
19765 conftest$ac_exeext conftest.$ac_ext
19766 LIBS=$ac_check_lib_save_LIBS
19767 fi
19768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
19769 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
19770 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
19771 have_com_err=yes
19772 else
19773 have_com_err=no
19774 fi
19775
19776 if test $have_com_err = yes; then
19777 COM_ERRLIB=-lcom_err
19778 LIBS="$COM_ERRLIB $LIBS"
19779
19780 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
19781
19782 fi
19783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
19784 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
19785 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
19786 $as_echo_n "(cached) " >&6
19787 else
19788 ac_check_lib_save_LIBS=$LIBS
19789 LIBS="-lcrypto $LIBS"
19790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19791 /* end confdefs.h. */
19792
19793 /* Override any GCC internal prototype to avoid an error.
19794 Use char because int might match the return type of a GCC
19795 builtin and then its argument prototype would still apply. */
19796 #ifdef __cplusplus
19797 extern "C"
19798 #endif
19799 char mit_des_cbc_encrypt ();
19800 int
19801 main ()
19802 {
19803 return mit_des_cbc_encrypt ();
19804 ;
19805 return 0;
19806 }
19807 _ACEOF
19808 if ac_fn_c_try_link "$LINENO"; then :
19809 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
19810 else
19811 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
19812 fi
19813 rm -f core conftest.err conftest.$ac_objext \
19814 conftest$ac_exeext conftest.$ac_ext
19815 LIBS=$ac_check_lib_save_LIBS
19816 fi
19817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
19818 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
19819 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
19820 have_crypto=yes
19821 else
19822 have_crypto=no
19823 fi
19824
19825 if test $have_crypto = yes; then
19826 CRYPTOLIB=-lcrypto
19827 LIBS="$CRYPTOLIB $LIBS"
19828
19829 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
19830
19831 fi
19832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
19833 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
19834 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
19835 $as_echo_n "(cached) " >&6
19836 else
19837 ac_check_lib_save_LIBS=$LIBS
19838 LIBS="-lk5crypto $LIBS"
19839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19840 /* end confdefs.h. */
19841
19842 /* Override any GCC internal prototype to avoid an error.
19843 Use char because int might match the return type of a GCC
19844 builtin and then its argument prototype would still apply. */
19845 #ifdef __cplusplus
19846 extern "C"
19847 #endif
19848 char mit_des_cbc_encrypt ();
19849 int
19850 main ()
19851 {
19852 return mit_des_cbc_encrypt ();
19853 ;
19854 return 0;
19855 }
19856 _ACEOF
19857 if ac_fn_c_try_link "$LINENO"; then :
19858 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
19859 else
19860 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
19861 fi
19862 rm -f core conftest.err conftest.$ac_objext \
19863 conftest$ac_exeext conftest.$ac_ext
19864 LIBS=$ac_check_lib_save_LIBS
19865 fi
19866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
19867 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
19868 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
19869 have_k5crypto=yes
19870 else
19871 have_k5crypto=no
19872 fi
19873
19874 if test $have_k5crypto = yes; then
19875 CRYPTOLIB=-lk5crypto
19876 LIBS="$CRYPTOLIB $LIBS"
19877
19878 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
19879
19880 fi
19881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
19882 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
19883 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
19884 $as_echo_n "(cached) " >&6
19885 else
19886 ac_check_lib_save_LIBS=$LIBS
19887 LIBS="-lkrb5 $LIBS"
19888 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19889 /* end confdefs.h. */
19890
19891 /* Override any GCC internal prototype to avoid an error.
19892 Use char because int might match the return type of a GCC
19893 builtin and then its argument prototype would still apply. */
19894 #ifdef __cplusplus
19895 extern "C"
19896 #endif
19897 char krb5_init_context ();
19898 int
19899 main ()
19900 {
19901 return krb5_init_context ();
19902 ;
19903 return 0;
19904 }
19905 _ACEOF
19906 if ac_fn_c_try_link "$LINENO"; then :
19907 ac_cv_lib_krb5_krb5_init_context=yes
19908 else
19909 ac_cv_lib_krb5_krb5_init_context=no
19910 fi
19911 rm -f core conftest.err conftest.$ac_objext \
19912 conftest$ac_exeext conftest.$ac_ext
19913 LIBS=$ac_check_lib_save_LIBS
19914 fi
19915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
19916 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
19917 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
19918 have_krb5=yes
19919 else
19920 have_krb5=no
19921 fi
19922
19923 if test $have_krb5=yes; then
19924 KRB5LIB=-lkrb5
19925 LIBS="$KRB5LIB $LIBS"
19926
19927 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
19928
19929 fi
19930 if test "${with_kerberos5}" = no; then
19931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
19932 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
19933 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
19934 $as_echo_n "(cached) " >&6
19935 else
19936 ac_check_lib_save_LIBS=$LIBS
19937 LIBS="-ldes425 $LIBS"
19938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19939 /* end confdefs.h. */
19940
19941 /* Override any GCC internal prototype to avoid an error.
19942 Use char because int might match the return type of a GCC
19943 builtin and then its argument prototype would still apply. */
19944 #ifdef __cplusplus
19945 extern "C"
19946 #endif
19947 char des_cbc_encrypt ();
19948 int
19949 main ()
19950 {
19951 return des_cbc_encrypt ();
19952 ;
19953 return 0;
19954 }
19955 _ACEOF
19956 if ac_fn_c_try_link "$LINENO"; then :
19957 ac_cv_lib_des425_des_cbc_encrypt=yes
19958 else
19959 ac_cv_lib_des425_des_cbc_encrypt=no
19960 fi
19961 rm -f core conftest.err conftest.$ac_objext \
19962 conftest$ac_exeext conftest.$ac_ext
19963 LIBS=$ac_check_lib_save_LIBS
19964 fi
19965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
19966 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
19967 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
19968 have_des425=yes
19969 else
19970 have_des425=no
19971 fi
19972
19973 if test $have_des425 = yes; then
19974 DESLIB=-ldes425
19975 LIBS="$DESLIB $LIBS"
19976
19977 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
19978
19979 else
19980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
19981 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
19982 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
19983 $as_echo_n "(cached) " >&6
19984 else
19985 ac_check_lib_save_LIBS=$LIBS
19986 LIBS="-ldes $LIBS"
19987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19988 /* end confdefs.h. */
19989
19990 /* Override any GCC internal prototype to avoid an error.
19991 Use char because int might match the return type of a GCC
19992 builtin and then its argument prototype would still apply. */
19993 #ifdef __cplusplus
19994 extern "C"
19995 #endif
19996 char des_cbc_encrypt ();
19997 int
19998 main ()
19999 {
20000 return des_cbc_encrypt ();
20001 ;
20002 return 0;
20003 }
20004 _ACEOF
20005 if ac_fn_c_try_link "$LINENO"; then :
20006 ac_cv_lib_des_des_cbc_encrypt=yes
20007 else
20008 ac_cv_lib_des_des_cbc_encrypt=no
20009 fi
20010 rm -f core conftest.err conftest.$ac_objext \
20011 conftest$ac_exeext conftest.$ac_ext
20012 LIBS=$ac_check_lib_save_LIBS
20013 fi
20014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
20015 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
20016 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
20017 have_des=yes
20018 else
20019 have_des=no
20020 fi
20021
20022 if test $have_des = yes; then
20023 DESLIB=-ldes
20024 LIBS="$DESLIB $LIBS"
20025
20026 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
20027
20028 fi
20029 fi
20030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
20031 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
20032 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
20033 $as_echo_n "(cached) " >&6
20034 else
20035 ac_check_lib_save_LIBS=$LIBS
20036 LIBS="-lkrb4 $LIBS"
20037 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20038 /* end confdefs.h. */
20039
20040 /* Override any GCC internal prototype to avoid an error.
20041 Use char because int might match the return type of a GCC
20042 builtin and then its argument prototype would still apply. */
20043 #ifdef __cplusplus
20044 extern "C"
20045 #endif
20046 char krb_get_cred ();
20047 int
20048 main ()
20049 {
20050 return krb_get_cred ();
20051 ;
20052 return 0;
20053 }
20054 _ACEOF
20055 if ac_fn_c_try_link "$LINENO"; then :
20056 ac_cv_lib_krb4_krb_get_cred=yes
20057 else
20058 ac_cv_lib_krb4_krb_get_cred=no
20059 fi
20060 rm -f core conftest.err conftest.$ac_objext \
20061 conftest$ac_exeext conftest.$ac_ext
20062 LIBS=$ac_check_lib_save_LIBS
20063 fi
20064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
20065 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
20066 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
20067 have_krb4=yes
20068 else
20069 have_krb4=no
20070 fi
20071
20072 if test $have_krb4 = yes; then
20073 KRB4LIB=-lkrb4
20074 LIBS="$KRB4LIB $LIBS"
20075
20076 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
20077
20078 else
20079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
20080 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
20081 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
20082 $as_echo_n "(cached) " >&6
20083 else
20084 ac_check_lib_save_LIBS=$LIBS
20085 LIBS="-lkrb $LIBS"
20086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20087 /* end confdefs.h. */
20088
20089 /* Override any GCC internal prototype to avoid an error.
20090 Use char because int might match the return type of a GCC
20091 builtin and then its argument prototype would still apply. */
20092 #ifdef __cplusplus
20093 extern "C"
20094 #endif
20095 char krb_get_cred ();
20096 int
20097 main ()
20098 {
20099 return krb_get_cred ();
20100 ;
20101 return 0;
20102 }
20103 _ACEOF
20104 if ac_fn_c_try_link "$LINENO"; then :
20105 ac_cv_lib_krb_krb_get_cred=yes
20106 else
20107 ac_cv_lib_krb_krb_get_cred=no
20108 fi
20109 rm -f core conftest.err conftest.$ac_objext \
20110 conftest$ac_exeext conftest.$ac_ext
20111 LIBS=$ac_check_lib_save_LIBS
20112 fi
20113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
20114 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
20115 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
20116 have_krb=yes
20117 else
20118 have_krb=no
20119 fi
20120
20121 if test $have_krb = yes; then
20122 KRB4LIB=-lkrb
20123 LIBS="$KRB4LIB $LIBS"
20124
20125 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
20126
20127 fi
20128 fi
20129 fi
20130
20131 if test "${with_kerberos5}" != no; then
20132 for ac_header in krb5.h
20133 do :
20134 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
20135 if test "x$ac_cv_header_krb5_h" = x""yes; then :
20136 cat >>confdefs.h <<_ACEOF
20137 #define HAVE_KRB5_H 1
20138 _ACEOF
20139 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
20140 "
20141 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
20142
20143 cat >>confdefs.h <<_ACEOF
20144 #define HAVE_KRB5_ERROR_TEXT 1
20145 _ACEOF
20146
20147
20148 fi
20149 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
20150 "
20151 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
20152
20153 cat >>confdefs.h <<_ACEOF
20154 #define HAVE_KRB5_ERROR_E_TEXT 1
20155 _ACEOF
20156
20157
20158 fi
20159
20160 fi
20161
20162 done
20163
20164 else
20165 for ac_header in des.h
20166 do :
20167 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
20168 if test "x$ac_cv_header_des_h" = x""yes; then :
20169 cat >>confdefs.h <<_ACEOF
20170 #define HAVE_DES_H 1
20171 _ACEOF
20172
20173 else
20174 for ac_header in kerberosIV/des.h
20175 do :
20176 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
20177 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
20178 cat >>confdefs.h <<_ACEOF
20179 #define HAVE_KERBEROSIV_DES_H 1
20180 _ACEOF
20181
20182 else
20183 for ac_header in kerberos/des.h
20184 do :
20185 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
20186 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
20187 cat >>confdefs.h <<_ACEOF
20188 #define HAVE_KERBEROS_DES_H 1
20189 _ACEOF
20190
20191 fi
20192
20193 done
20194
20195 fi
20196
20197 done
20198
20199 fi
20200
20201 done
20202
20203 for ac_header in krb.h
20204 do :
20205 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
20206 if test "x$ac_cv_header_krb_h" = x""yes; then :
20207 cat >>confdefs.h <<_ACEOF
20208 #define HAVE_KRB_H 1
20209 _ACEOF
20210
20211 else
20212 for ac_header in kerberosIV/krb.h
20213 do :
20214 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
20215 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
20216 cat >>confdefs.h <<_ACEOF
20217 #define HAVE_KERBEROSIV_KRB_H 1
20218 _ACEOF
20219
20220 else
20221 for ac_header in kerberos/krb.h
20222 do :
20223 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
20224 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
20225 cat >>confdefs.h <<_ACEOF
20226 #define HAVE_KERBEROS_KRB_H 1
20227 _ACEOF
20228
20229 fi
20230
20231 done
20232
20233 fi
20234
20235 done
20236
20237 fi
20238
20239 done
20240
20241 fi
20242 for ac_header in com_err.h
20243 do :
20244 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
20245 if test "x$ac_cv_header_com_err_h" = x""yes; then :
20246 cat >>confdefs.h <<_ACEOF
20247 #define HAVE_COM_ERR_H 1
20248 _ACEOF
20249
20250 fi
20251
20252 done
20253
20254 fi
20255
20256
20257
20258
20259
20260
20261
20262 # Solaris requires -lintl if you want strerror (which calls dgettext)
20263 # to return localized messages.
20264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dgettext in -lintl" >&5
20265 $as_echo_n "checking for dgettext in -lintl... " >&6; }
20266 if test "${ac_cv_lib_intl_dgettext+set}" = set; then :
20267 $as_echo_n "(cached) " >&6
20268 else
20269 ac_check_lib_save_LIBS=$LIBS
20270 LIBS="-lintl $LIBS"
20271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20272 /* end confdefs.h. */
20273
20274 /* Override any GCC internal prototype to avoid an error.
20275 Use char because int might match the return type of a GCC
20276 builtin and then its argument prototype would still apply. */
20277 #ifdef __cplusplus
20278 extern "C"
20279 #endif
20280 char dgettext ();
20281 int
20282 main ()
20283 {
20284 return dgettext ();
20285 ;
20286 return 0;
20287 }
20288 _ACEOF
20289 if ac_fn_c_try_link "$LINENO"; then :
20290 ac_cv_lib_intl_dgettext=yes
20291 else
20292 ac_cv_lib_intl_dgettext=no
20293 fi
20294 rm -f core conftest.err conftest.$ac_objext \
20295 conftest$ac_exeext conftest.$ac_ext
20296 LIBS=$ac_check_lib_save_LIBS
20297 fi
20298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_dgettext" >&5
20299 $as_echo "$ac_cv_lib_intl_dgettext" >&6; }
20300 if test "x$ac_cv_lib_intl_dgettext" = x""yes; then :
20301 cat >>confdefs.h <<_ACEOF
20302 #define HAVE_LIBINTL 1
20303 _ACEOF
20304
20305 LIBS="-lintl $LIBS"
20306
20307 fi
20308
20309
20310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
20311 $as_echo_n "checking whether localtime caches TZ... " >&6; }
20312 if test "${emacs_cv_localtime_cache+set}" = set; then :
20313 $as_echo_n "(cached) " >&6
20314 else
20315 if test x$ac_cv_func_tzset = xyes; then
20316 if test "$cross_compiling" = yes; then :
20317 # If we have tzset, assume the worst when cross-compiling.
20318 emacs_cv_localtime_cache=yes
20319 else
20320 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20321 /* end confdefs.h. */
20322 #include <time.h>
20323 char TZ_GMT0[] = "TZ=GMT0";
20324 char TZ_PST8[] = "TZ=PST8";
20325 main()
20326 {
20327 time_t now = time ((time_t *) 0);
20328 int hour_GMT0, hour_unset;
20329 if (putenv (TZ_GMT0) != 0)
20330 exit (1);
20331 hour_GMT0 = localtime (&now)->tm_hour;
20332 unsetenv("TZ");
20333 hour_unset = localtime (&now)->tm_hour;
20334 if (putenv (TZ_PST8) != 0)
20335 exit (1);
20336 if (localtime (&now)->tm_hour == hour_GMT0)
20337 exit (1);
20338 unsetenv("TZ");
20339 if (localtime (&now)->tm_hour != hour_unset)
20340 exit (1);
20341 exit (0);
20342 }
20343 _ACEOF
20344 if ac_fn_c_try_run "$LINENO"; then :
20345 emacs_cv_localtime_cache=no
20346 else
20347 emacs_cv_localtime_cache=yes
20348 fi
20349 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20350 conftest.$ac_objext conftest.beam conftest.$ac_ext
20351 fi
20352
20353 else
20354 # If we lack tzset, report that localtime does not cache TZ,
20355 # since we can't invalidate the cache if we don't have tzset.
20356 emacs_cv_localtime_cache=no
20357 fi
20358 fi
20359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
20360 $as_echo "$emacs_cv_localtime_cache" >&6; }
20361 if test $emacs_cv_localtime_cache = yes; then
20362
20363 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
20364
20365 fi
20366
20367 if test "x$HAVE_TIMEVAL" = xyes; then
20368 for ac_func in gettimeofday
20369 do :
20370 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
20371 if test "x$ac_cv_func_gettimeofday" = x""yes; then :
20372 cat >>confdefs.h <<_ACEOF
20373 #define HAVE_GETTIMEOFDAY 1
20374 _ACEOF
20375
20376 fi
20377 done
20378
20379 if test $ac_cv_func_gettimeofday = yes; then
20380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
20381 $as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
20382 if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then :
20383 $as_echo_n "(cached) " >&6
20384 else
20385 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20386 /* end confdefs.h. */
20387
20388 #ifdef TIME_WITH_SYS_TIME
20389 #include <sys/time.h>
20390 #include <time.h>
20391 #else
20392 #ifdef HAVE_SYS_TIME_H
20393 #include <sys/time.h>
20394 #else
20395 #include <time.h>
20396 #endif
20397 #endif
20398 int
20399 main ()
20400 {
20401 struct timeval time;
20402 gettimeofday (&time, 0);
20403 ;
20404 return 0;
20405 }
20406 _ACEOF
20407 if ac_fn_c_try_compile "$LINENO"; then :
20408 emacs_cv_gettimeofday_two_arguments=yes
20409 else
20410 emacs_cv_gettimeofday_two_arguments=no
20411 fi
20412 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20413 fi
20414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
20415 $as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
20416 if test $emacs_cv_gettimeofday_two_arguments = no; then
20417
20418 $as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
20419
20420 fi
20421 fi
20422 fi
20423
20424 ok_so_far=yes
20425 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
20426 if test "x$ac_cv_func_socket" = x""yes; then :
20427
20428 else
20429 ok_so_far=no
20430 fi
20431
20432 if test $ok_so_far = yes; then
20433 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
20434 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
20435
20436 else
20437 ok_so_far=no
20438 fi
20439
20440
20441 fi
20442 if test $ok_so_far = yes; then
20443 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
20444 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
20445
20446 else
20447 ok_so_far=no
20448 fi
20449
20450
20451 fi
20452 if test $ok_so_far = yes; then
20453
20454 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
20455
20456 fi
20457
20458 if test -f /usr/lpp/X11/bin/smt.exp; then
20459
20460 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
20461
20462 fi
20463
20464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
20465 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
20466 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
20467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
20468 $as_echo "yes" >&6; }
20469
20470 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
20471
20472 else
20473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
20474 $as_echo "no" >&6; }
20475 fi
20476
20477 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
20478 if test "x$ac_cv_type_pid_t" = x""yes; then :
20479
20480 else
20481
20482 cat >>confdefs.h <<_ACEOF
20483 #define pid_t int
20484 _ACEOF
20485
20486 fi
20487
20488 for ac_header in vfork.h
20489 do :
20490 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
20491 if test "x$ac_cv_header_vfork_h" = x""yes; then :
20492 cat >>confdefs.h <<_ACEOF
20493 #define HAVE_VFORK_H 1
20494 _ACEOF
20495
20496 fi
20497
20498 done
20499
20500 for ac_func in fork vfork
20501 do :
20502 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20503 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
20504 eval as_val=\$$as_ac_var
20505 if test "x$as_val" = x""yes; then :
20506 cat >>confdefs.h <<_ACEOF
20507 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20508 _ACEOF
20509
20510 fi
20511 done
20512
20513 if test "x$ac_cv_func_fork" = xyes; then
20514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
20515 $as_echo_n "checking for working fork... " >&6; }
20516 if test "${ac_cv_func_fork_works+set}" = set; then :
20517 $as_echo_n "(cached) " >&6
20518 else
20519 if test "$cross_compiling" = yes; then :
20520 ac_cv_func_fork_works=cross
20521 else
20522 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20523 /* end confdefs.h. */
20524 $ac_includes_default
20525 int
20526 main ()
20527 {
20528
20529 /* By Ruediger Kuhlmann. */
20530 return fork () < 0;
20531
20532 ;
20533 return 0;
20534 }
20535 _ACEOF
20536 if ac_fn_c_try_run "$LINENO"; then :
20537 ac_cv_func_fork_works=yes
20538 else
20539 ac_cv_func_fork_works=no
20540 fi
20541 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20542 conftest.$ac_objext conftest.beam conftest.$ac_ext
20543 fi
20544
20545 fi
20546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
20547 $as_echo "$ac_cv_func_fork_works" >&6; }
20548
20549 else
20550 ac_cv_func_fork_works=$ac_cv_func_fork
20551 fi
20552 if test "x$ac_cv_func_fork_works" = xcross; then
20553 case $host in
20554 *-*-amigaos* | *-*-msdosdjgpp*)
20555 # Override, as these systems have only a dummy fork() stub
20556 ac_cv_func_fork_works=no
20557 ;;
20558 *)
20559 ac_cv_func_fork_works=yes
20560 ;;
20561 esac
20562 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
20563 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
20564 fi
20565 ac_cv_func_vfork_works=$ac_cv_func_vfork
20566 if test "x$ac_cv_func_vfork" = xyes; then
20567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
20568 $as_echo_n "checking for working vfork... " >&6; }
20569 if test "${ac_cv_func_vfork_works+set}" = set; then :
20570 $as_echo_n "(cached) " >&6
20571 else
20572 if test "$cross_compiling" = yes; then :
20573 ac_cv_func_vfork_works=cross
20574 else
20575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20576 /* end confdefs.h. */
20577 /* Thanks to Paul Eggert for this test. */
20578 $ac_includes_default
20579 #include <sys/wait.h>
20580 #ifdef HAVE_VFORK_H
20581 # include <vfork.h>
20582 #endif
20583 /* On some sparc systems, changes by the child to local and incoming
20584 argument registers are propagated back to the parent. The compiler
20585 is told about this with #include <vfork.h>, but some compilers
20586 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
20587 static variable whose address is put into a register that is
20588 clobbered by the vfork. */
20589 static void
20590 #ifdef __cplusplus
20591 sparc_address_test (int arg)
20592 # else
20593 sparc_address_test (arg) int arg;
20594 #endif
20595 {
20596 static pid_t child;
20597 if (!child) {
20598 child = vfork ();
20599 if (child < 0) {
20600 perror ("vfork");
20601 _exit(2);
20602 }
20603 if (!child) {
20604 arg = getpid();
20605 write(-1, "", 0);
20606 _exit (arg);
20607 }
20608 }
20609 }
20610
20611 int
20612 main ()
20613 {
20614 pid_t parent = getpid ();
20615 pid_t child;
20616
20617 sparc_address_test (0);
20618
20619 child = vfork ();
20620
20621 if (child == 0) {
20622 /* Here is another test for sparc vfork register problems. This
20623 test uses lots of local variables, at least as many local
20624 variables as main has allocated so far including compiler
20625 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
20626 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
20627 reuse the register of parent for one of the local variables,
20628 since it will think that parent can't possibly be used any more
20629 in this routine. Assigning to the local variable will thus
20630 munge parent in the parent process. */
20631 pid_t
20632 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
20633 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
20634 /* Convince the compiler that p..p7 are live; otherwise, it might
20635 use the same hardware register for all 8 local variables. */
20636 if (p != p1 || p != p2 || p != p3 || p != p4
20637 || p != p5 || p != p6 || p != p7)
20638 _exit(1);
20639
20640 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
20641 from child file descriptors. If the child closes a descriptor
20642 before it execs or exits, this munges the parent's descriptor
20643 as well. Test for this by closing stdout in the child. */
20644 _exit(close(fileno(stdout)) != 0);
20645 } else {
20646 int status;
20647 struct stat st;
20648
20649 while (wait(&status) != child)
20650 ;
20651 return (
20652 /* Was there some problem with vforking? */
20653 child < 0
20654
20655 /* Did the child fail? (This shouldn't happen.) */
20656 || status
20657
20658 /* Did the vfork/compiler bug occur? */
20659 || parent != getpid()
20660
20661 /* Did the file descriptor bug occur? */
20662 || fstat(fileno(stdout), &st) != 0
20663 );
20664 }
20665 }
20666 _ACEOF
20667 if ac_fn_c_try_run "$LINENO"; then :
20668 ac_cv_func_vfork_works=yes
20669 else
20670 ac_cv_func_vfork_works=no
20671 fi
20672 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20673 conftest.$ac_objext conftest.beam conftest.$ac_ext
20674 fi
20675
20676 fi
20677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
20678 $as_echo "$ac_cv_func_vfork_works" >&6; }
20679
20680 fi;
20681 if test "x$ac_cv_func_fork_works" = xcross; then
20682 ac_cv_func_vfork_works=$ac_cv_func_vfork
20683 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
20684 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
20685 fi
20686
20687 if test "x$ac_cv_func_vfork_works" = xyes; then
20688
20689 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
20690
20691 else
20692
20693 $as_echo "#define vfork fork" >>confdefs.h
20694
20695 fi
20696 if test "x$ac_cv_func_fork_works" = xyes; then
20697
20698 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
20699
20700 fi
20701
20702
20703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
20704 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
20705 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
20706 $as_echo_n "(cached) " >&6
20707 else
20708 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20709 /* end confdefs.h. */
20710 #include <langinfo.h>
20711 int
20712 main ()
20713 {
20714 char* cs = nl_langinfo(CODESET);
20715 ;
20716 return 0;
20717 }
20718 _ACEOF
20719 if ac_fn_c_try_link "$LINENO"; then :
20720 emacs_cv_langinfo_codeset=yes
20721 else
20722 emacs_cv_langinfo_codeset=no
20723 fi
20724 rm -f core conftest.err conftest.$ac_objext \
20725 conftest$ac_exeext conftest.$ac_ext
20726
20727 fi
20728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
20729 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
20730 if test $emacs_cv_langinfo_codeset = yes; then
20731
20732 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
20733
20734 fi
20735
20736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
20737 $as_echo_n "checking for mbstate_t... " >&6; }
20738 if test "${ac_cv_type_mbstate_t+set}" = set; then :
20739 $as_echo_n "(cached) " >&6
20740 else
20741 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20742 /* end confdefs.h. */
20743 $ac_includes_default
20744 # include <wchar.h>
20745 int
20746 main ()
20747 {
20748 mbstate_t x; return sizeof x;
20749 ;
20750 return 0;
20751 }
20752 _ACEOF
20753 if ac_fn_c_try_compile "$LINENO"; then :
20754 ac_cv_type_mbstate_t=yes
20755 else
20756 ac_cv_type_mbstate_t=no
20757 fi
20758 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20759 fi
20760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
20761 $as_echo "$ac_cv_type_mbstate_t" >&6; }
20762 if test $ac_cv_type_mbstate_t = yes; then
20763
20764 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
20765
20766 else
20767
20768 $as_echo "#define mbstate_t int" >>confdefs.h
20769
20770 fi
20771
20772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
20773 $as_echo_n "checking for C restricted array declarations... " >&6; }
20774 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
20775 $as_echo_n "(cached) " >&6
20776 else
20777 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20778 /* end confdefs.h. */
20779 void fred (int x[__restrict]);
20780 int
20781 main ()
20782 {
20783
20784 ;
20785 return 0;
20786 }
20787 _ACEOF
20788 if ac_fn_c_try_compile "$LINENO"; then :
20789 emacs_cv_c_restrict_arr=yes
20790 else
20791 emacs_cv_c_restrict_arr=no
20792 fi
20793 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20794 fi
20795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
20796 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
20797 if test "$emacs_cv_c_restrict_arr" = yes; then
20798
20799 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
20800
20801 fi
20802
20803
20804
20805 # Set up the CFLAGS for real compilation, so we can substitute it.
20806 CFLAGS="$REAL_CFLAGS"
20807 CPPFLAGS="$REAL_CPPFLAGS"
20808
20809 ## Hack to detect a buggy GCC version.
20810 if test "x$GCC" = xyes \
20811 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
20812 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
20813 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
20814 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
20815 fi
20816
20817 version=$PACKAGE_VERSION
20818
20819 ### Specify what sort of things we'll be editing into Makefile and config.h.
20820 ### Use configuration here uncanonicalized to avoid exceeding size limits.
20821
20822
20823 ## Unused?
20824
20825
20826
20827
20828
20829
20830
20831
20832
20833
20834
20835
20836
20837
20838
20839
20840
20841
20842
20843
20844 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
20845 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
20846 ## end of LIBX_BASE, but nothing ever set it.
20847
20848
20849
20850
20851 ## Used in lwlib/Makefile.in.
20852
20853 if test -n "${machfile}"; then
20854 M_FILE="\$(srcdir)/${machfile}"
20855 else
20856 M_FILE=
20857 fi
20858 S_FILE="\$(srcdir)/${opsysfile}"
20859
20860
20861
20862
20863
20864
20865
20866
20867
20868
20869 cat >>confdefs.h <<_ACEOF
20870 #define EMACS_CONFIGURATION "${canonical}"
20871 _ACEOF
20872
20873
20874 cat >>confdefs.h <<_ACEOF
20875 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
20876 _ACEOF
20877
20878 if test -n "$machfile"; then
20879
20880 cat >>confdefs.h <<_ACEOF
20881 #define config_machfile "${machfile}"
20882 _ACEOF
20883
20884 fi
20885
20886 cat >>confdefs.h <<_ACEOF
20887 #define config_opsysfile "${opsysfile}"
20888 _ACEOF
20889
20890
20891 XMENU_OBJ=
20892 XOBJ=
20893 FONT_OBJ=
20894 if test "${HAVE_X_WINDOWS}" = "yes" ; then
20895
20896 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
20897
20898 XMENU_OBJ=xmenu.o
20899 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
20900 FONT_OBJ=xfont.o
20901 if test "$HAVE_XFT" = "yes"; then
20902 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
20903 elif test "$HAVE_FREETYPE" = "yes"; then
20904 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
20905 fi
20906
20907 fi
20908
20909
20910
20911
20912 WIDGET_OBJ=
20913 MOTIF_LIBW=
20914 if test "${USE_X_TOOLKIT}" != "none" ; then
20915 WIDGET_OBJ=widget.o
20916
20917 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
20918
20919 if test "${USE_X_TOOLKIT}" = "LUCID"; then
20920
20921 $as_echo "#define USE_LUCID 1" >>confdefs.h
20922
20923 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
20924
20925 $as_echo "#define USE_MOTIF 1" >>confdefs.h
20926
20927 MOTIF_LIBW=-lXm
20928 case "$opsys" in
20929 gnu-linux)
20930 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
20931 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
20932 ;;
20933
20934 unixware)
20935 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
20936 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
20937 MOTIF_LIBW="MOTIF_LIBW -lXimp"
20938 ;;
20939
20940 aix4-2)
20941 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
20942 MOTIF_LIBW="$MOTIF_LIBW -li18n"
20943 ;;
20944 esac
20945 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
20946 fi
20947 fi
20948
20949
20950 TOOLKIT_LIBW=
20951 case "$USE_X_TOOLKIT" in
20952 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
20953 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
20954 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
20955 esac
20956
20957
20958 if test "$USE_X_TOOLKIT" = "none"; then
20959 LIBXT_OTHER="\$(LIBXSM)"
20960 OLDXMENU_TARGET="really-oldXMenu"
20961 else
20962 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
20963 OLDXMENU_TARGET="really-lwlib"
20964 fi
20965
20966
20967 ## The X Menu stuff is present in the X10 distribution, but missing
20968 ## from X11. If we have X10, just use the installed library;
20969 ## otherwise, use our own copy.
20970 if test "${HAVE_X11}" = "yes" ; then
20971
20972 $as_echo "#define HAVE_X11 1" >>confdefs.h
20973
20974
20975 if test "$USE_X_TOOLKIT" = "none"; then
20976 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
20977 else
20978 OLDXMENU="\${lwlibdir}/liblw.a"
20979 fi
20980 LIBXMENU="\$(OLDXMENU)"
20981 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
20982 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
20983 else
20984 ## For a syntactically valid Makefile; not actually used for anything.
20985 ## See comments in src/Makefile.in.
20986 OLDXMENU=nothing
20987 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
20988 if test "${HAVE_X_WINDOWS}" = "yes"; then
20989 LIBXMENU="-lXMenu"
20990 else
20991 LIBXMENU=
20992 fi
20993 LIBX_OTHER=
20994 OLDXMENU_DEPS=
20995 fi
20996
20997 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
20998 OLDXMENU_TARGET=
20999 OLDXMENU=nothing
21000 LIBXMENU=
21001 OLDXMENU_DEPS=
21002 fi
21003
21004
21005
21006
21007
21008
21009
21010 if test "${HAVE_MENUS}" = "yes" ; then
21011
21012 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
21013
21014 fi
21015
21016 if test "${GNU_MALLOC}" = "yes" ; then
21017
21018 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
21019
21020 fi
21021
21022 RALLOC_OBJ=
21023 if test "${REL_ALLOC}" = "yes" ; then
21024
21025 $as_echo "#define REL_ALLOC 1" >>confdefs.h
21026
21027
21028 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
21029 fi
21030
21031
21032 if test "$opsys" = "cygwin"; then
21033 CYGWIN_OBJ="sheap.o"
21034 ## Cygwin differs because of its unexec().
21035 PRE_ALLOC_OBJ=
21036 POST_ALLOC_OBJ=lastfile.o
21037 else
21038 CYGWIN_OBJ=
21039 PRE_ALLOC_OBJ=lastfile.o
21040 POST_ALLOC_OBJ=
21041 fi
21042
21043
21044
21045
21046
21047 case "$opsys" in
21048 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
21049
21050 darwin)
21051 ## The -headerpad option tells ld (see man page) to leave room at the
21052 ## end of the header for adding load commands. Needed for dumping.
21053 ## 0x690 is the total size of 30 segment load commands (at 56
21054 ## each); under Cocoa 31 commands are required.
21055 if test "$HAVE_NS" = "yes"; then
21056 libs_nsgui="-framework AppKit"
21057 headerpad_extra=6C8
21058 else
21059 libs_nsgui=
21060 headerpad_extra=690
21061 fi
21062 LD_SWITCH_SYSTEM_TEMACS="-prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
21063
21064 ## This is here because src/Makefile.in did some extra fiddling around
21065 ## with LD_SWITCH_SYSTEM. The cpp logic was:
21066 ## #ifndef LD_SWITCH_SYSTEM
21067 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
21068 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
21069 ## not using gcc, darwin system not on an alpha (ie darwin, since
21070 ## darwin + alpha does not occur).
21071 ## Because this was done in src/Makefile.in, the resulting part of
21072 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
21073 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
21074 ## rather than LD_SWITCH_SYSTEM.
21075 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
21076 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
21077 ;;
21078
21079 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
21080 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
21081 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
21082 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
21083 ## had different values in configure (in ac_link) and src/Makefile.in.
21084 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
21085 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
21086
21087 *) LD_SWITCH_SYSTEM_TEMACS= ;;
21088 esac
21089
21090 if test "$NS_IMPL_GNUSTEP" = "yes"; then
21091 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
21092 fi
21093
21094
21095
21096
21097 LD_FIRSTFLAG=
21098 ORDINARY_LINK=
21099 case "$opsys" in
21100 ## gnu: GNU needs its own crt0.
21101 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
21102
21103 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
21104 ## library search parth, i.e. it won't search /usr/lib for libc and
21105 ## friends. Using -nostartfiles instead avoids this problem, and
21106 ## will also work on earlier NetBSD releases.
21107 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
21108
21109 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
21110 ## MkLinux/LinuxPPC needs this.
21111 ## ibms390x only supports opsys = gnu-linux so it can be added here.
21112 gnu-*)
21113 case "$machine" in
21114 macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;;
21115 esac
21116 ;;
21117 esac
21118
21119
21120 if test "x$ORDINARY_LINK" = "xyes"; then
21121
21122 LD_FIRSTFLAG=""
21123
21124 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
21125
21126
21127 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
21128 ## freebsd, gnu-* not on macppc|ibms390x.
21129 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
21130
21131 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
21132 ## places that are difficult to figure out at make time. Fortunately,
21133 ## these same versions allow you to pass arbitrary flags on to the
21134 ## linker, so there is no reason not to use it as a linker.
21135 ##
21136 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
21137 ## searching for libraries in its internal directories, so we have to
21138 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
21139 LD_FIRSTFLAG="-nostdlib"
21140 fi
21141
21142 ## FIXME? What setting of EDIT_LDFLAGS should this have?
21143 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
21144
21145
21146
21147
21148 ## FIXME? The logic here is not precisely the same as that above.
21149 ## There is no check here for a pre-defined LD_FIRSTFLAG.
21150 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
21151 LIB_GCC=
21152 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
21153
21154 case "$opsys" in
21155 freebsd|netbsd|openbsd) LIB_GCC= ;;
21156
21157 gnu-*)
21158 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
21159 ## build on ARM EABI under GNU/Linux. (Bug#5518)
21160 case $host_cpu in
21161 arm*)
21162 LIB_GCC="-lgcc_s"
21163 ;;
21164 *)
21165 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
21166 ## immediately undefine it again and redefine it to empty.
21167 ## Was the C_SWITCH_X_SITE part really necessary?
21168 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
21169 LIB_GCC=
21170 ;;
21171 esac
21172 ;;
21173
21174 ## Ask GCC where to find libgcc.a.
21175 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
21176 esac
21177 fi
21178
21179
21180 ## If we're using X11/GNUstep, define some consequences.
21181 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
21182
21183 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
21184
21185
21186 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
21187
21188 fi
21189
21190
21191
21192
21193 #### Report on what we decided to do.
21194 #### Report GTK as a toolkit, even if it doesn't use Xt.
21195 #### It makes printing result more understandable as using GTK sets
21196 #### toolkit_scroll_bars to yes by default.
21197 if test "${HAVE_GTK}" = "yes"; then
21198 USE_X_TOOLKIT=GTK
21199 fi
21200
21201 and_machfile=
21202 if test -n "$machfile"; then
21203 and_machfile=" and \`${machfile}'"
21204 fi
21205
21206 echo "
21207 Configured for \`${canonical}'.
21208
21209 Where should the build process find the source code? ${srcdir}
21210 What operating system and machine description files should Emacs use?
21211 \`${opsysfile}'${and_machfile}
21212 What compiler should emacs be built with? ${CC} ${CFLAGS}
21213 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
21214 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
21215 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
21216 What window system should Emacs use? ${window_system}
21217 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
21218
21219 if test -n "${x_includes}"; then
21220 echo " Where do we find X Windows header files? ${x_includes}"
21221 else
21222 echo " Where do we find X Windows header files? Standard dirs"
21223 fi
21224 if test -n "${x_libraries}"; then
21225 echo " Where do we find X Windows libraries? ${x_libraries}"
21226 else
21227 echo " Where do we find X Windows libraries? Standard dirs"
21228 fi
21229
21230 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
21231 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
21232 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
21233 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
21234 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
21235 echo " Does Emacs use -lpng? ${HAVE_PNG}"
21236 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
21237 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
21238
21239 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
21240 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
21241 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
21242 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
21243 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
21244 echo " Does Emacs use -lgnutls (2.6.x or higher)? ${HAVE_GNUTLS}"
21245 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
21246
21247 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
21248 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
21249 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
21250 echo " Does Emacs use -lxft? ${HAVE_XFT}"
21251
21252 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
21253 echo
21254
21255 if test $USE_XASSERTS = yes; then
21256 echo " Compiling with asserts turned on."
21257 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
21258 fi
21259
21260 echo
21261
21262 if test "$HAVE_NS" = "yes"; then
21263 echo
21264 echo "You must run \"make install\" in order to test the built application.
21265 The installed application will go to nextstep/Emacs.app and can be
21266 run or moved from there."
21267 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
21268 echo "The application will be fully self-contained."
21269 else
21270 echo "The lisp resources for the application will be installed under ${prefix}.
21271 You may need to run \"make install\" with sudo. The application will fail
21272 to run if these resources are not installed."
21273 fi
21274 echo
21275 fi
21276
21277
21278 # Remove any trailing slashes in these variables.
21279 test "${prefix}" != NONE &&
21280 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
21281 test "${exec_prefix}" != NONE &&
21282 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
21283
21284 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"
21285
21286 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"
21287
21288
21289 opt_makefile=test/automated/Makefile
21290
21291 if test -f $srcdir/${opt_makefile}.in; then
21292 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
21293 ac_config_files="$ac_config_files test/automated/Makefile"
21294
21295 fi
21296
21297 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
21298
21299
21300
21301 ac_config_commands="$ac_config_commands mkdirs"
21302
21303
21304 ac_config_commands="$ac_config_commands epaths"
21305
21306
21307 ac_config_commands="$ac_config_commands gdbinit"
21308
21309
21310 cat >confcache <<\_ACEOF
21311 # This file is a shell script that caches the results of configure
21312 # tests run on this system so they can be shared between configure
21313 # scripts and configure runs, see configure's option --config-cache.
21314 # It is not useful on other systems. If it contains results you don't
21315 # want to keep, you may remove or edit it.
21316 #
21317 # config.status only pays attention to the cache file if you give it
21318 # the --recheck option to rerun configure.
21319 #
21320 # `ac_cv_env_foo' variables (set or unset) will be overridden when
21321 # loading this file, other *unset* `ac_cv_foo' will be assigned the
21322 # following values.
21323
21324 _ACEOF
21325
21326 # The following way of writing the cache mishandles newlines in values,
21327 # but we know of no workaround that is simple, portable, and efficient.
21328 # So, we kill variables containing newlines.
21329 # Ultrix sh set writes to stderr and can't be redirected directly,
21330 # and sets the high bit in the cache file unless we assign to the vars.
21331 (
21332 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
21333 eval ac_val=\$$ac_var
21334 case $ac_val in #(
21335 *${as_nl}*)
21336 case $ac_var in #(
21337 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
21338 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
21339 esac
21340 case $ac_var in #(
21341 _ | IFS | as_nl) ;; #(
21342 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
21343 *) { eval $ac_var=; unset $ac_var;} ;;
21344 esac ;;
21345 esac
21346 done
21347
21348 (set) 2>&1 |
21349 case $as_nl`(ac_space=' '; set) 2>&1` in #(
21350 *${as_nl}ac_space=\ *)
21351 # `set' does not quote correctly, so add quotes: double-quote
21352 # substitution turns \\\\ into \\, and sed turns \\ into \.
21353 sed -n \
21354 "s/'/'\\\\''/g;
21355 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
21356 ;; #(
21357 *)
21358 # `set' quotes correctly as required by POSIX, so do not add quotes.
21359 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
21360 ;;
21361 esac |
21362 sort
21363 ) |
21364 sed '
21365 /^ac_cv_env_/b end
21366 t clear
21367 :clear
21368 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
21369 t end
21370 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
21371 :end' >>confcache
21372 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
21373 if test -w "$cache_file"; then
21374 test "x$cache_file" != "x/dev/null" &&
21375 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
21376 $as_echo "$as_me: updating cache $cache_file" >&6;}
21377 cat confcache >$cache_file
21378 else
21379 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
21380 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
21381 fi
21382 fi
21383 rm -f confcache
21384
21385 test "x$prefix" = xNONE && prefix=$ac_default_prefix
21386 # Let make expand exec_prefix.
21387 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
21388
21389 DEFS=-DHAVE_CONFIG_H
21390
21391 ac_libobjs=
21392 ac_ltlibobjs=
21393 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
21394 # 1. Remove the extension, and $U if already installed.
21395 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
21396 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
21397 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
21398 # will be set to the directory where LIBOBJS objects are built.
21399 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
21400 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
21401 done
21402 LIBOBJS=$ac_libobjs
21403
21404 LTLIBOBJS=$ac_ltlibobjs
21405
21406
21407 if test -n "$EXEEXT"; then
21408 am__EXEEXT_TRUE=
21409 am__EXEEXT_FALSE='#'
21410 else
21411 am__EXEEXT_TRUE='#'
21412 am__EXEEXT_FALSE=
21413 fi
21414
21415 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
21416 as_fn_error "conditional \"AMDEP\" was never defined.
21417 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21418 fi
21419 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
21420 as_fn_error "conditional \"am__fastdepCC\" was never defined.
21421 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21422 fi
21423
21424 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
21425 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
21426 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21427 fi
21428 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
21429 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
21430 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21431 fi
21432
21433 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
21434 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
21435 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21436 fi
21437 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
21438 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
21439 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21440 fi
21441 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
21442 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
21443 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21444 fi
21445 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
21446 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
21447 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21448 fi
21449 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
21450 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
21451 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21452 fi
21453 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
21454 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
21455 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21456 fi
21457 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
21458 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
21459 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21460 fi
21461 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
21462 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
21463 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21464 fi
21465 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
21466 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
21467 Usually this means the macro was only invoked conditionally." "$LINENO" 5
21468 fi
21469
21470 gl_libobjs=
21471 gl_ltlibobjs=
21472 if test -n "$gl_LIBOBJS"; then
21473 # Remove the extension.
21474 sed_drop_objext='s/\.o$//;s/\.obj$//'
21475 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
21476 gl_libobjs="$gl_libobjs $i.$ac_objext"
21477 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
21478 done
21479 fi
21480 gl_LIBOBJS=$gl_libobjs
21481
21482 gl_LTLIBOBJS=$gl_ltlibobjs
21483
21484
21485
21486 gltests_libobjs=
21487 gltests_ltlibobjs=
21488 if test -n "$gltests_LIBOBJS"; then
21489 # Remove the extension.
21490 sed_drop_objext='s/\.o$//;s/\.obj$//'
21491 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
21492 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
21493 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
21494 done
21495 fi
21496 gltests_LIBOBJS=$gltests_libobjs
21497
21498 gltests_LTLIBOBJS=$gltests_ltlibobjs
21499
21500
21501
21502 : ${CONFIG_STATUS=./config.status}
21503 ac_write_fail=0
21504 ac_clean_files_save=$ac_clean_files
21505 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
21506 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
21507 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
21508 as_write_fail=0
21509 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
21510 #! $SHELL
21511 # Generated by $as_me.
21512 # Run this file to recreate the current configuration.
21513 # Compiler output produced by configure, useful for debugging
21514 # configure, is in config.log if it exists.
21515
21516 debug=false
21517 ac_cs_recheck=false
21518 ac_cs_silent=false
21519
21520 SHELL=\${CONFIG_SHELL-$SHELL}
21521 export SHELL
21522 _ASEOF
21523 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
21524 ## -------------------- ##
21525 ## M4sh Initialization. ##
21526 ## -------------------- ##
21527
21528 # Be more Bourne compatible
21529 DUALCASE=1; export DUALCASE # for MKS sh
21530 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
21531 emulate sh
21532 NULLCMD=:
21533 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
21534 # is contrary to our usage. Disable this feature.
21535 alias -g '${1+"$@"}'='"$@"'
21536 setopt NO_GLOB_SUBST
21537 else
21538 case `(set -o) 2>/dev/null` in #(
21539 *posix*) :
21540 set -o posix ;; #(
21541 *) :
21542 ;;
21543 esac
21544 fi
21545
21546
21547 as_nl='
21548 '
21549 export as_nl
21550 # Printing a long string crashes Solaris 7 /usr/bin/printf.
21551 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
21552 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
21553 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
21554 # Prefer a ksh shell builtin over an external printf program on Solaris,
21555 # but without wasting forks for bash or zsh.
21556 if test -z "$BASH_VERSION$ZSH_VERSION" \
21557 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
21558 as_echo='print -r --'
21559 as_echo_n='print -rn --'
21560 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
21561 as_echo='printf %s\n'
21562 as_echo_n='printf %s'
21563 else
21564 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
21565 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
21566 as_echo_n='/usr/ucb/echo -n'
21567 else
21568 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
21569 as_echo_n_body='eval
21570 arg=$1;
21571 case $arg in #(
21572 *"$as_nl"*)
21573 expr "X$arg" : "X\\(.*\\)$as_nl";
21574 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
21575 esac;
21576 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
21577 '
21578 export as_echo_n_body
21579 as_echo_n='sh -c $as_echo_n_body as_echo'
21580 fi
21581 export as_echo_body
21582 as_echo='sh -c $as_echo_body as_echo'
21583 fi
21584
21585 # The user is always right.
21586 if test "${PATH_SEPARATOR+set}" != set; then
21587 PATH_SEPARATOR=:
21588 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
21589 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
21590 PATH_SEPARATOR=';'
21591 }
21592 fi
21593
21594
21595 # IFS
21596 # We need space, tab and new line, in precisely that order. Quoting is
21597 # there to prevent editors from complaining about space-tab.
21598 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
21599 # splitting by setting IFS to empty value.)
21600 IFS=" "" $as_nl"
21601
21602 # Find who we are. Look in the path if we contain no directory separator.
21603 case $0 in #((
21604 *[\\/]* ) as_myself=$0 ;;
21605 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
21606 for as_dir in $PATH
21607 do
21608 IFS=$as_save_IFS
21609 test -z "$as_dir" && as_dir=.
21610 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
21611 done
21612 IFS=$as_save_IFS
21613
21614 ;;
21615 esac
21616 # We did not find ourselves, most probably we were run as `sh COMMAND'
21617 # in which case we are not to be found in the path.
21618 if test "x$as_myself" = x; then
21619 as_myself=$0
21620 fi
21621 if test ! -f "$as_myself"; then
21622 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
21623 exit 1
21624 fi
21625
21626 # Unset variables that we do not need and which cause bugs (e.g. in
21627 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
21628 # suppresses any "Segmentation fault" message there. '((' could
21629 # trigger a bug in pdksh 5.2.14.
21630 for as_var in BASH_ENV ENV MAIL MAILPATH
21631 do eval test x\${$as_var+set} = xset \
21632 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
21633 done
21634 PS1='$ '
21635 PS2='> '
21636 PS4='+ '
21637
21638 # NLS nuisances.
21639 LC_ALL=C
21640 export LC_ALL
21641 LANGUAGE=C
21642 export LANGUAGE
21643
21644 # CDPATH.
21645 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
21646
21647
21648 # as_fn_error ERROR [LINENO LOG_FD]
21649 # ---------------------------------
21650 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
21651 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
21652 # script with status $?, using 1 if that was 0.
21653 as_fn_error ()
21654 {
21655 as_status=$?; test $as_status -eq 0 && as_status=1
21656 if test "$3"; then
21657 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
21658 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
21659 fi
21660 $as_echo "$as_me: error: $1" >&2
21661 as_fn_exit $as_status
21662 } # as_fn_error
21663
21664
21665 # as_fn_set_status STATUS
21666 # -----------------------
21667 # Set $? to STATUS, without forking.
21668 as_fn_set_status ()
21669 {
21670 return $1
21671 } # as_fn_set_status
21672
21673 # as_fn_exit STATUS
21674 # -----------------
21675 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
21676 as_fn_exit ()
21677 {
21678 set +e
21679 as_fn_set_status $1
21680 exit $1
21681 } # as_fn_exit
21682
21683 # as_fn_unset VAR
21684 # ---------------
21685 # Portably unset VAR.
21686 as_fn_unset ()
21687 {
21688 { eval $1=; unset $1;}
21689 }
21690 as_unset=as_fn_unset
21691 # as_fn_append VAR VALUE
21692 # ----------------------
21693 # Append the text in VALUE to the end of the definition contained in VAR. Take
21694 # advantage of any shell optimizations that allow amortized linear growth over
21695 # repeated appends, instead of the typical quadratic growth present in naive
21696 # implementations.
21697 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
21698 eval 'as_fn_append ()
21699 {
21700 eval $1+=\$2
21701 }'
21702 else
21703 as_fn_append ()
21704 {
21705 eval $1=\$$1\$2
21706 }
21707 fi # as_fn_append
21708
21709 # as_fn_arith ARG...
21710 # ------------------
21711 # Perform arithmetic evaluation on the ARGs, and store the result in the
21712 # global $as_val. Take advantage of shells that can avoid forks. The arguments
21713 # must be portable across $(()) and expr.
21714 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
21715 eval 'as_fn_arith ()
21716 {
21717 as_val=$(( $* ))
21718 }'
21719 else
21720 as_fn_arith ()
21721 {
21722 as_val=`expr "$@" || test $? -eq 1`
21723 }
21724 fi # as_fn_arith
21725
21726
21727 if expr a : '\(a\)' >/dev/null 2>&1 &&
21728 test "X`expr 00001 : '.*\(...\)'`" = X001; then
21729 as_expr=expr
21730 else
21731 as_expr=false
21732 fi
21733
21734 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
21735 as_basename=basename
21736 else
21737 as_basename=false
21738 fi
21739
21740 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
21741 as_dirname=dirname
21742 else
21743 as_dirname=false
21744 fi
21745
21746 as_me=`$as_basename -- "$0" ||
21747 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
21748 X"$0" : 'X\(//\)$' \| \
21749 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
21750 $as_echo X/"$0" |
21751 sed '/^.*\/\([^/][^/]*\)\/*$/{
21752 s//\1/
21753 q
21754 }
21755 /^X\/\(\/\/\)$/{
21756 s//\1/
21757 q
21758 }
21759 /^X\/\(\/\).*/{
21760 s//\1/
21761 q
21762 }
21763 s/.*/./; q'`
21764
21765 # Avoid depending upon Character Ranges.
21766 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
21767 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
21768 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
21769 as_cr_digits='0123456789'
21770 as_cr_alnum=$as_cr_Letters$as_cr_digits
21771
21772 ECHO_C= ECHO_N= ECHO_T=
21773 case `echo -n x` in #(((((
21774 -n*)
21775 case `echo 'xy\c'` in
21776 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
21777 xy) ECHO_C='\c';;
21778 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
21779 ECHO_T=' ';;
21780 esac;;
21781 *)
21782 ECHO_N='-n';;
21783 esac
21784
21785 rm -f conf$$ conf$$.exe conf$$.file
21786 if test -d conf$$.dir; then
21787 rm -f conf$$.dir/conf$$.file
21788 else
21789 rm -f conf$$.dir
21790 mkdir conf$$.dir 2>/dev/null
21791 fi
21792 if (echo >conf$$.file) 2>/dev/null; then
21793 if ln -s conf$$.file conf$$ 2>/dev/null; then
21794 as_ln_s='ln -s'
21795 # ... but there are two gotchas:
21796 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
21797 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
21798 # In both cases, we have to default to `cp -p'.
21799 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
21800 as_ln_s='cp -p'
21801 elif ln conf$$.file conf$$ 2>/dev/null; then
21802 as_ln_s=ln
21803 else
21804 as_ln_s='cp -p'
21805 fi
21806 else
21807 as_ln_s='cp -p'
21808 fi
21809 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
21810 rmdir conf$$.dir 2>/dev/null
21811
21812
21813 # as_fn_mkdir_p
21814 # -------------
21815 # Create "$as_dir" as a directory, including parents if necessary.
21816 as_fn_mkdir_p ()
21817 {
21818
21819 case $as_dir in #(
21820 -*) as_dir=./$as_dir;;
21821 esac
21822 test -d "$as_dir" || eval $as_mkdir_p || {
21823 as_dirs=
21824 while :; do
21825 case $as_dir in #(
21826 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
21827 *) as_qdir=$as_dir;;
21828 esac
21829 as_dirs="'$as_qdir' $as_dirs"
21830 as_dir=`$as_dirname -- "$as_dir" ||
21831 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
21832 X"$as_dir" : 'X\(//\)[^/]' \| \
21833 X"$as_dir" : 'X\(//\)$' \| \
21834 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
21835 $as_echo X"$as_dir" |
21836 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
21837 s//\1/
21838 q
21839 }
21840 /^X\(\/\/\)[^/].*/{
21841 s//\1/
21842 q
21843 }
21844 /^X\(\/\/\)$/{
21845 s//\1/
21846 q
21847 }
21848 /^X\(\/\).*/{
21849 s//\1/
21850 q
21851 }
21852 s/.*/./; q'`
21853 test -d "$as_dir" && break
21854 done
21855 test -z "$as_dirs" || eval "mkdir $as_dirs"
21856 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
21857
21858
21859 } # as_fn_mkdir_p
21860 if mkdir -p . 2>/dev/null; then
21861 as_mkdir_p='mkdir -p "$as_dir"'
21862 else
21863 test -d ./-p && rmdir ./-p
21864 as_mkdir_p=false
21865 fi
21866
21867 if test -x / >/dev/null 2>&1; then
21868 as_test_x='test -x'
21869 else
21870 if ls -dL / >/dev/null 2>&1; then
21871 as_ls_L_option=L
21872 else
21873 as_ls_L_option=
21874 fi
21875 as_test_x='
21876 eval sh -c '\''
21877 if test -d "$1"; then
21878 test -d "$1/.";
21879 else
21880 case $1 in #(
21881 -*)set "./$1";;
21882 esac;
21883 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
21884 ???[sx]*):;;*)false;;esac;fi
21885 '\'' sh
21886 '
21887 fi
21888 as_executable_p=$as_test_x
21889
21890 # Sed expression to map a string onto a valid CPP name.
21891 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
21892
21893 # Sed expression to map a string onto a valid variable name.
21894 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
21895
21896
21897 exec 6>&1
21898 ## ----------------------------------- ##
21899 ## Main body of $CONFIG_STATUS script. ##
21900 ## ----------------------------------- ##
21901 _ASEOF
21902 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
21903
21904 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21905 # Save the log message, to keep $0 and so on meaningful, and to
21906 # report actual input values of CONFIG_FILES etc. instead of their
21907 # values after options handling.
21908 ac_log="
21909 This file was extended by emacs $as_me 24.0.50, which was
21910 generated by GNU Autoconf 2.65. Invocation command line was
21911
21912 CONFIG_FILES = $CONFIG_FILES
21913 CONFIG_HEADERS = $CONFIG_HEADERS
21914 CONFIG_LINKS = $CONFIG_LINKS
21915 CONFIG_COMMANDS = $CONFIG_COMMANDS
21916 $ $0 $@
21917
21918 on `(hostname || uname -n) 2>/dev/null | sed 1q`
21919 "
21920
21921 _ACEOF
21922
21923 case $ac_config_files in *"
21924 "*) set x $ac_config_files; shift; ac_config_files=$*;;
21925 esac
21926
21927 case $ac_config_headers in *"
21928 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
21929 esac
21930
21931
21932 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21933 # Files that config.status was made for.
21934 config_files="$ac_config_files"
21935 config_headers="$ac_config_headers"
21936 config_commands="$ac_config_commands"
21937
21938 _ACEOF
21939
21940 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21941 ac_cs_usage="\
21942 \`$as_me' instantiates files and other configuration actions
21943 from templates according to the current configuration. Unless the files
21944 and actions are specified as TAGs, all are instantiated by default.
21945
21946 Usage: $0 [OPTION]... [TAG]...
21947
21948 -h, --help print this help, then exit
21949 -V, --version print version number and configuration settings, then exit
21950 --config print configuration, then exit
21951 -q, --quiet, --silent
21952 do not print progress messages
21953 -d, --debug don't remove temporary files
21954 --recheck update $as_me by reconfiguring in the same conditions
21955 --file=FILE[:TEMPLATE]
21956 instantiate the configuration file FILE
21957 --header=FILE[:TEMPLATE]
21958 instantiate the configuration header FILE
21959
21960 Configuration files:
21961 $config_files
21962
21963 Configuration headers:
21964 $config_headers
21965
21966 Configuration commands:
21967 $config_commands
21968
21969 Report bugs to the package provider."
21970
21971 _ACEOF
21972 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
21973 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
21974 ac_cs_version="\\
21975 emacs config.status 24.0.50
21976 configured by $0, generated by GNU Autoconf 2.65,
21977 with options \\"\$ac_cs_config\\"
21978
21979 Copyright (C) 2009 Free Software Foundation, Inc.
21980 This config.status script is free software; the Free Software Foundation
21981 gives unlimited permission to copy, distribute and modify it."
21982
21983 ac_pwd='$ac_pwd'
21984 srcdir='$srcdir'
21985 INSTALL='$INSTALL'
21986 MKDIR_P='$MKDIR_P'
21987 AWK='$AWK'
21988 test -n "\$AWK" || AWK=awk
21989 _ACEOF
21990
21991 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
21992 # The default lists apply if the user does not specify any file.
21993 ac_need_defaults=:
21994 while test $# != 0
21995 do
21996 case $1 in
21997 --*=*)
21998 ac_option=`expr "X$1" : 'X\([^=]*\)='`
21999 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
22000 ac_shift=:
22001 ;;
22002 *)
22003 ac_option=$1
22004 ac_optarg=$2
22005 ac_shift=shift
22006 ;;
22007 esac
22008
22009 case $ac_option in
22010 # Handling of the options.
22011 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
22012 ac_cs_recheck=: ;;
22013 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
22014 $as_echo "$ac_cs_version"; exit ;;
22015 --config | --confi | --conf | --con | --co | --c )
22016 $as_echo "$ac_cs_config"; exit ;;
22017 --debug | --debu | --deb | --de | --d | -d )
22018 debug=: ;;
22019 --file | --fil | --fi | --f )
22020 $ac_shift
22021 case $ac_optarg in
22022 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22023 esac
22024 as_fn_append CONFIG_FILES " '$ac_optarg'"
22025 ac_need_defaults=false;;
22026 --header | --heade | --head | --hea )
22027 $ac_shift
22028 case $ac_optarg in
22029 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
22030 esac
22031 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
22032 ac_need_defaults=false;;
22033 --he | --h)
22034 # Conflict between --help and --header
22035 as_fn_error "ambiguous option: \`$1'
22036 Try \`$0 --help' for more information.";;
22037 --help | --hel | -h )
22038 $as_echo "$ac_cs_usage"; exit ;;
22039 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
22040 | -silent | --silent | --silen | --sile | --sil | --si | --s)
22041 ac_cs_silent=: ;;
22042
22043 # This is an error.
22044 -*) as_fn_error "unrecognized option: \`$1'
22045 Try \`$0 --help' for more information." ;;
22046
22047 *) as_fn_append ac_config_targets " $1"
22048 ac_need_defaults=false ;;
22049
22050 esac
22051 shift
22052 done
22053
22054 ac_configure_extra_args=
22055
22056 if $ac_cs_silent; then
22057 exec 6>/dev/null
22058 ac_configure_extra_args="$ac_configure_extra_args --silent"
22059 fi
22060
22061 _ACEOF
22062 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22063 if \$ac_cs_recheck; then
22064 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
22065 shift
22066 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
22067 CONFIG_SHELL='$SHELL'
22068 export CONFIG_SHELL
22069 exec "\$@"
22070 fi
22071
22072 _ACEOF
22073 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22074 exec 5>>config.log
22075 {
22076 echo
22077 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
22078 ## Running $as_me. ##
22079 _ASBOX
22080 $as_echo "$ac_log"
22081 } >&5
22082
22083 _ACEOF
22084 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22085 #
22086 # INIT-COMMANDS
22087 #
22088 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
22089 GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
22090
22091 _ACEOF
22092
22093 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22094
22095 # Handling of arguments.
22096 for ac_config_target in $ac_config_targets
22097 do
22098 case $ac_config_target in
22099 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
22100 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
22101 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
22102 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
22103 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
22104 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
22105 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
22106 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
22107 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
22108 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
22109 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
22110 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
22111 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
22112 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
22113 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
22114 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
22115 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
22116 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
22117
22118 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
22119 esac
22120 done
22121
22122
22123 # If the user did not use the arguments to specify the items to instantiate,
22124 # then the envvar interface is used. Set only those that are not.
22125 # We use the long form for the default assignment because of an extremely
22126 # bizarre bug on SunOS 4.1.3.
22127 if $ac_need_defaults; then
22128 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
22129 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
22130 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
22131 fi
22132
22133 # Have a temporary directory for convenience. Make it in the build tree
22134 # simply because there is no reason against having it here, and in addition,
22135 # creating and moving files from /tmp can sometimes cause problems.
22136 # Hook for its removal unless debugging.
22137 # Note that there is a small window in which the directory will not be cleaned:
22138 # after its creation but before its name has been assigned to `$tmp'.
22139 $debug ||
22140 {
22141 tmp=
22142 trap 'exit_status=$?
22143 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
22144 ' 0
22145 trap 'as_fn_exit 1' 1 2 13 15
22146 }
22147 # Create a (secure) tmp directory for tmp files.
22148
22149 {
22150 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
22151 test -n "$tmp" && test -d "$tmp"
22152 } ||
22153 {
22154 tmp=./conf$$-$RANDOM
22155 (umask 077 && mkdir "$tmp")
22156 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
22157
22158 # Set up the scripts for CONFIG_FILES section.
22159 # No need to generate them if there are no CONFIG_FILES.
22160 # This happens for instance with `./config.status config.h'.
22161 if test -n "$CONFIG_FILES"; then
22162
22163 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
22164 ac_cs_awk_getline=:
22165 ac_cs_awk_pipe_init=
22166 ac_cs_awk_read_file='
22167 while ((getline aline < (F[key])) > 0)
22168 print(aline)
22169 close(F[key])'
22170 ac_cs_awk_pipe_fini=
22171 else
22172 ac_cs_awk_getline=false
22173 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
22174 ac_cs_awk_read_file='
22175 print "|#_!!_#|"
22176 print "cat " F[key] " &&"
22177 '$ac_cs_awk_pipe_init
22178 # The final `:' finishes the AND list.
22179 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
22180 fi
22181 ac_cr=`echo X | tr X '\015'`
22182 # On cygwin, bash can eat \r inside `` if the user requested igncr.
22183 # But we know of no other shell where ac_cr would be empty at this
22184 # point, so we can use a bashism as a fallback.
22185 if test "x$ac_cr" = x; then
22186 eval ac_cr=\$\'\\r\'
22187 fi
22188 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
22189 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
22190 ac_cs_awk_cr='\r'
22191 else
22192 ac_cs_awk_cr=$ac_cr
22193 fi
22194
22195 echo 'BEGIN {' >"$tmp/subs1.awk" &&
22196 _ACEOF
22197
22198 # Create commands to substitute file output variables.
22199 {
22200 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
22201 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
22202 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
22203 echo "_ACAWK" &&
22204 echo "_ACEOF"
22205 } >conf$$files.sh &&
22206 . ./conf$$files.sh ||
22207 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
22208 rm -f conf$$files.sh
22209
22210 {
22211 echo "cat >conf$$subs.awk <<_ACEOF" &&
22212 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
22213 echo "_ACEOF"
22214 } >conf$$subs.sh ||
22215 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
22216 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
22217 ac_delim='%!_!# '
22218 for ac_last_try in false false false false false :; do
22219 . ./conf$$subs.sh ||
22220 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
22221
22222 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
22223 if test $ac_delim_n = $ac_delim_num; then
22224 break
22225 elif $ac_last_try; then
22226 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
22227 else
22228 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
22229 fi
22230 done
22231 rm -f conf$$subs.sh
22232
22233 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22234 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
22235 _ACEOF
22236 sed -n '
22237 h
22238 s/^/S["/; s/!.*/"]=/
22239 p
22240 g
22241 s/^[^!]*!//
22242 :repl
22243 t repl
22244 s/'"$ac_delim"'$//
22245 t delim
22246 :nl
22247 h
22248 s/\(.\{148\}\)..*/\1/
22249 t more1
22250 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
22251 p
22252 n
22253 b repl
22254 :more1
22255 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
22256 p
22257 g
22258 s/.\{148\}//
22259 t nl
22260 :delim
22261 h
22262 s/\(.\{148\}\)..*/\1/
22263 t more2
22264 s/["\\]/\\&/g; s/^/"/; s/$/"/
22265 p
22266 b
22267 :more2
22268 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
22269 p
22270 g
22271 s/.\{148\}//
22272 t delim
22273 ' <conf$$subs.awk | sed '
22274 /^[^""]/{
22275 N
22276 s/\n//
22277 }
22278 ' >>$CONFIG_STATUS || ac_write_fail=1
22279 rm -f conf$$subs.awk
22280 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22281 _ACAWK
22282 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
22283 for (key in S) S_is_set[key] = 1
22284 FS = "\a"
22285 \$ac_cs_awk_pipe_init
22286 }
22287 {
22288 line = $ 0
22289 nfields = split(line, field, "@")
22290 substed = 0
22291 len = length(field[1])
22292 for (i = 2; i < nfields; i++) {
22293 key = field[i]
22294 keylen = length(key)
22295 if (S_is_set[key]) {
22296 value = S[key]
22297 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
22298 len += length(value) + length(field[++i])
22299 substed = 1
22300 } else
22301 len += 1 + keylen
22302 }
22303 if (nfields == 3 && !substed) {
22304 key = field[2]
22305 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
22306 \$ac_cs_awk_read_file
22307 next
22308 }
22309 }
22310 print line
22311 }
22312 \$ac_cs_awk_pipe_fini
22313 _ACAWK
22314 _ACEOF
22315 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22316 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
22317 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
22318 else
22319 cat
22320 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
22321 || as_fn_error "could not setup config files machinery" "$LINENO" 5
22322 _ACEOF
22323
22324 # VPATH may cause trouble with some makes, so we remove $(srcdir),
22325 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
22326 # trailing colons and then remove the whole line if VPATH becomes empty
22327 # (actually we leave an empty line to preserve line numbers).
22328 if test "x$srcdir" = x.; then
22329 ac_vpsub='/^[ ]*VPATH[ ]*=/{
22330 s/:*\$(srcdir):*/:/
22331 s/:*\${srcdir}:*/:/
22332 s/:*@srcdir@:*/:/
22333 s/^\([^=]*=[ ]*\):*/\1/
22334 s/:*$//
22335 s/^[^=]*=[ ]*$//
22336 }'
22337 fi
22338
22339 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22340 fi # test -n "$CONFIG_FILES"
22341
22342 # Set up the scripts for CONFIG_HEADERS section.
22343 # No need to generate them if there are no CONFIG_HEADERS.
22344 # This happens for instance with `./config.status Makefile'.
22345 if test -n "$CONFIG_HEADERS"; then
22346 cat >"$tmp/defines.awk" <<\_ACAWK ||
22347 BEGIN {
22348 _ACEOF
22349
22350 # Transform confdefs.h into an awk script `defines.awk', embedded as
22351 # here-document in config.status, that substitutes the proper values into
22352 # config.h.in to produce config.h.
22353
22354 # Create a delimiter string that does not exist in confdefs.h, to ease
22355 # handling of long lines.
22356 ac_delim='%!_!# '
22357 for ac_last_try in false false :; do
22358 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
22359 if test -z "$ac_t"; then
22360 break
22361 elif $ac_last_try; then
22362 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
22363 else
22364 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
22365 fi
22366 done
22367
22368 # For the awk script, D is an array of macro values keyed by name,
22369 # likewise P contains macro parameters if any. Preserve backslash
22370 # newline sequences.
22371
22372 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
22373 sed -n '
22374 s/.\{148\}/&'"$ac_delim"'/g
22375 t rset
22376 :rset
22377 s/^[ ]*#[ ]*define[ ][ ]*/ /
22378 t def
22379 d
22380 :def
22381 s/\\$//
22382 t bsnl
22383 s/["\\]/\\&/g
22384 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
22385 D["\1"]=" \3"/p
22386 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
22387 d
22388 :bsnl
22389 s/["\\]/\\&/g
22390 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
22391 D["\1"]=" \3\\\\\\n"\\/p
22392 t cont
22393 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
22394 t cont
22395 d
22396 :cont
22397 n
22398 s/.\{148\}/&'"$ac_delim"'/g
22399 t clear
22400 :clear
22401 s/\\$//
22402 t bsnlc
22403 s/["\\]/\\&/g; s/^/"/; s/$/"/p
22404 d
22405 :bsnlc
22406 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
22407 b cont
22408 ' <confdefs.h | sed '
22409 s/'"$ac_delim"'/"\\\
22410 "/g' >>$CONFIG_STATUS || ac_write_fail=1
22411
22412 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22413 for (key in D) D_is_set[key] = 1
22414 FS = "\a"
22415 }
22416 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
22417 line = \$ 0
22418 split(line, arg, " ")
22419 if (arg[1] == "#") {
22420 defundef = arg[2]
22421 mac1 = arg[3]
22422 } else {
22423 defundef = substr(arg[1], 2)
22424 mac1 = arg[2]
22425 }
22426 split(mac1, mac2, "(") #)
22427 macro = mac2[1]
22428 prefix = substr(line, 1, index(line, defundef) - 1)
22429 if (D_is_set[macro]) {
22430 # Preserve the white space surrounding the "#".
22431 print prefix "define", macro P[macro] D[macro]
22432 next
22433 } else {
22434 # Replace #undef with comments. This is necessary, for example,
22435 # in the case of _POSIX_SOURCE, which is predefined and required
22436 # on some systems where configure will not decide to define it.
22437 if (defundef == "undef") {
22438 print "/*", prefix defundef, macro, "*/"
22439 next
22440 }
22441 }
22442 }
22443 { print }
22444 _ACAWK
22445 _ACEOF
22446 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22447 as_fn_error "could not setup config headers machinery" "$LINENO" 5
22448 fi # test -n "$CONFIG_HEADERS"
22449
22450
22451 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
22452 shift
22453 for ac_tag
22454 do
22455 case $ac_tag in
22456 :[FHLC]) ac_mode=$ac_tag; continue;;
22457 esac
22458 case $ac_mode$ac_tag in
22459 :[FHL]*:*);;
22460 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
22461 :[FH]-) ac_tag=-:-;;
22462 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
22463 esac
22464 ac_save_IFS=$IFS
22465 IFS=:
22466 set x $ac_tag
22467 IFS=$ac_save_IFS
22468 shift
22469 ac_file=$1
22470 shift
22471
22472 case $ac_mode in
22473 :L) ac_source=$1;;
22474 :[FH])
22475 ac_file_inputs=
22476 for ac_f
22477 do
22478 case $ac_f in
22479 -) ac_f="$tmp/stdin";;
22480 *) # Look for the file first in the build tree, then in the source tree
22481 # (if the path is not absolute). The absolute path cannot be DOS-style,
22482 # because $ac_f cannot contain `:'.
22483 test -f "$ac_f" ||
22484 case $ac_f in
22485 [\\/$]*) false;;
22486 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
22487 esac ||
22488 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
22489 esac
22490 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
22491 as_fn_append ac_file_inputs " '$ac_f'"
22492 done
22493
22494 # Let's still pretend it is `configure' which instantiates (i.e., don't
22495 # use $as_me), people would be surprised to read:
22496 # /* config.h. Generated by config.status. */
22497 configure_input='Generated from '`
22498 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
22499 `' by configure.'
22500 if test x"$ac_file" != x-; then
22501 configure_input="$ac_file. $configure_input"
22502 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
22503 $as_echo "$as_me: creating $ac_file" >&6;}
22504 fi
22505 # Neutralize special characters interpreted by sed in replacement strings.
22506 case $configure_input in #(
22507 *\&* | *\|* | *\\* )
22508 ac_sed_conf_input=`$as_echo "$configure_input" |
22509 sed 's/[\\\\&|]/\\\\&/g'`;; #(
22510 *) ac_sed_conf_input=$configure_input;;
22511 esac
22512
22513 case $ac_tag in
22514 *:-:* | *:-) cat >"$tmp/stdin" \
22515 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
22516 esac
22517 ;;
22518 esac
22519
22520 ac_dir=`$as_dirname -- "$ac_file" ||
22521 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22522 X"$ac_file" : 'X\(//\)[^/]' \| \
22523 X"$ac_file" : 'X\(//\)$' \| \
22524 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
22525 $as_echo X"$ac_file" |
22526 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22527 s//\1/
22528 q
22529 }
22530 /^X\(\/\/\)[^/].*/{
22531 s//\1/
22532 q
22533 }
22534 /^X\(\/\/\)$/{
22535 s//\1/
22536 q
22537 }
22538 /^X\(\/\).*/{
22539 s//\1/
22540 q
22541 }
22542 s/.*/./; q'`
22543 as_dir="$ac_dir"; as_fn_mkdir_p
22544 ac_builddir=.
22545
22546 case "$ac_dir" in
22547 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
22548 *)
22549 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
22550 # A ".." for each directory in $ac_dir_suffix.
22551 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
22552 case $ac_top_builddir_sub in
22553 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
22554 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
22555 esac ;;
22556 esac
22557 ac_abs_top_builddir=$ac_pwd
22558 ac_abs_builddir=$ac_pwd$ac_dir_suffix
22559 # for backward compatibility:
22560 ac_top_builddir=$ac_top_build_prefix
22561
22562 case $srcdir in
22563 .) # We are building in place.
22564 ac_srcdir=.
22565 ac_top_srcdir=$ac_top_builddir_sub
22566 ac_abs_top_srcdir=$ac_pwd ;;
22567 [\\/]* | ?:[\\/]* ) # Absolute name.
22568 ac_srcdir=$srcdir$ac_dir_suffix;
22569 ac_top_srcdir=$srcdir
22570 ac_abs_top_srcdir=$srcdir ;;
22571 *) # Relative name.
22572 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
22573 ac_top_srcdir=$ac_top_build_prefix$srcdir
22574 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
22575 esac
22576 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
22577
22578
22579 case $ac_mode in
22580 :F)
22581 #
22582 # CONFIG_FILE
22583 #
22584
22585 case $INSTALL in
22586 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
22587 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
22588 esac
22589 ac_MKDIR_P=$MKDIR_P
22590 case $MKDIR_P in
22591 [\\/$]* | ?:[\\/]* ) ;;
22592 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
22593 esac
22594 _ACEOF
22595
22596 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22597 # If the template does not know about datarootdir, expand it.
22598 # FIXME: This hack should be removed a few years after 2.60.
22599 ac_datarootdir_hack=; ac_datarootdir_seen=
22600 ac_sed_dataroot='
22601 /datarootdir/ {
22602 p
22603 q
22604 }
22605 /@datadir@/p
22606 /@docdir@/p
22607 /@infodir@/p
22608 /@localedir@/p
22609 /@mandir@/p'
22610 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
22611 *datarootdir*) ac_datarootdir_seen=yes;;
22612 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
22613 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
22614 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
22615 _ACEOF
22616 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22617 ac_datarootdir_hack='
22618 s&@datadir@&$datadir&g
22619 s&@docdir@&$docdir&g
22620 s&@infodir@&$infodir&g
22621 s&@localedir@&$localedir&g
22622 s&@mandir@&$mandir&g
22623 s&\\\${datarootdir}&$datarootdir&g' ;;
22624 esac
22625 _ACEOF
22626
22627 # Neutralize VPATH when `$srcdir' = `.'.
22628 # Shell code in configure.ac might set extrasub.
22629 # FIXME: do we really want to maintain this feature?
22630 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
22631 ac_sed_extra="$ac_vpsub
22632 $extrasub
22633 _ACEOF
22634 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
22635 :t
22636 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
22637 s|@configure_input@|$ac_sed_conf_input|;t t
22638 s&@top_builddir@&$ac_top_builddir_sub&;t t
22639 s&@top_build_prefix@&$ac_top_build_prefix&;t t
22640 s&@srcdir@&$ac_srcdir&;t t
22641 s&@abs_srcdir@&$ac_abs_srcdir&;t t
22642 s&@top_srcdir@&$ac_top_srcdir&;t t
22643 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
22644 s&@builddir@&$ac_builddir&;t t
22645 s&@abs_builddir@&$ac_abs_builddir&;t t
22646 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
22647 s&@INSTALL@&$ac_INSTALL&;t t
22648 s&@MKDIR_P@&$ac_MKDIR_P&;t t
22649 $ac_datarootdir_hack
22650 "
22651 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
22652 if $ac_cs_awk_getline; then
22653 $AWK -f "$tmp/subs.awk"
22654 else
22655 $AWK -f "$tmp/subs.awk" | $SHELL
22656 fi >$tmp/out \
22657 || as_fn_error "could not create $ac_file" "$LINENO" 5
22658
22659 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
22660 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
22661 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
22662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22663 which seems to be undefined. Please make sure it is defined." >&5
22664 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
22665 which seems to be undefined. Please make sure it is defined." >&2;}
22666
22667 rm -f "$tmp/stdin"
22668 case $ac_file in
22669 -) cat "$tmp/out" && rm -f "$tmp/out";;
22670 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
22671 esac \
22672 || as_fn_error "could not create $ac_file" "$LINENO" 5
22673 ;;
22674 :H)
22675 #
22676 # CONFIG_HEADER
22677 #
22678 if test x"$ac_file" != x-; then
22679 {
22680 $as_echo "/* $configure_input */" \
22681 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
22682 } >"$tmp/config.h" \
22683 || as_fn_error "could not create $ac_file" "$LINENO" 5
22684 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
22685 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
22686 $as_echo "$as_me: $ac_file is unchanged" >&6;}
22687 else
22688 rm -f "$ac_file"
22689 mv "$tmp/config.h" "$ac_file" \
22690 || as_fn_error "could not create $ac_file" "$LINENO" 5
22691 fi
22692 else
22693 $as_echo "/* $configure_input */" \
22694 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
22695 || as_fn_error "could not create -" "$LINENO" 5
22696 fi
22697 # Compute "$ac_file"'s index in $config_headers.
22698 _am_arg="$ac_file"
22699 _am_stamp_count=1
22700 for _am_header in $config_headers :; do
22701 case $_am_header in
22702 $_am_arg | $_am_arg:* )
22703 break ;;
22704 * )
22705 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
22706 esac
22707 done
22708 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
22709 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22710 X"$_am_arg" : 'X\(//\)[^/]' \| \
22711 X"$_am_arg" : 'X\(//\)$' \| \
22712 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
22713 $as_echo X"$_am_arg" |
22714 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22715 s//\1/
22716 q
22717 }
22718 /^X\(\/\/\)[^/].*/{
22719 s//\1/
22720 q
22721 }
22722 /^X\(\/\/\)$/{
22723 s//\1/
22724 q
22725 }
22726 /^X\(\/\).*/{
22727 s//\1/
22728 q
22729 }
22730 s/.*/./; q'`/stamp-h$_am_stamp_count
22731 ;;
22732
22733 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
22734 $as_echo "$as_me: executing $ac_file commands" >&6;}
22735 ;;
22736 esac
22737
22738
22739 case $ac_file$ac_mode in
22740 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
22741 # Autoconf 2.62 quotes --file arguments for eval, but not when files
22742 # are listed without --file. Let's play safe and only enable the eval
22743 # if we detect the quoting.
22744 case $CONFIG_FILES in
22745 *\'*) eval set x "$CONFIG_FILES" ;;
22746 *) set x $CONFIG_FILES ;;
22747 esac
22748 shift
22749 for mf
22750 do
22751 # Strip MF so we end up with the name of the file.
22752 mf=`echo "$mf" | sed -e 's/:.*$//'`
22753 # Check whether this is an Automake generated Makefile or not.
22754 # We used to match only the files named `Makefile.in', but
22755 # some people rename them; so instead we look at the file content.
22756 # Grep'ing the first line is not enough: some people post-process
22757 # each Makefile.in and add a new line on top of each file to say so.
22758 # Grep'ing the whole file is not good either: AIX grep has a line
22759 # limit of 2048, but all sed's we know have understand at least 4000.
22760 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
22761 dirpart=`$as_dirname -- "$mf" ||
22762 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22763 X"$mf" : 'X\(//\)[^/]' \| \
22764 X"$mf" : 'X\(//\)$' \| \
22765 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
22766 $as_echo X"$mf" |
22767 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22768 s//\1/
22769 q
22770 }
22771 /^X\(\/\/\)[^/].*/{
22772 s//\1/
22773 q
22774 }
22775 /^X\(\/\/\)$/{
22776 s//\1/
22777 q
22778 }
22779 /^X\(\/\).*/{
22780 s//\1/
22781 q
22782 }
22783 s/.*/./; q'`
22784 else
22785 continue
22786 fi
22787 # Extract the definition of DEPDIR, am__include, and am__quote
22788 # from the Makefile without running `make'.
22789 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
22790 test -z "$DEPDIR" && continue
22791 am__include=`sed -n 's/^am__include = //p' < "$mf"`
22792 test -z "am__include" && continue
22793 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
22794 # When using ansi2knr, U may be empty or an underscore; expand it
22795 U=`sed -n 's/^U = //p' < "$mf"`
22796 # Find all dependency output files, they are included files with
22797 # $(DEPDIR) in their names. We invoke sed twice because it is the
22798 # simplest approach to changing $(DEPDIR) to its actual value in the
22799 # expansion.
22800 for file in `sed -n "
22801 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
22802 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
22803 # Make sure the directory exists.
22804 test -f "$dirpart/$file" && continue
22805 fdir=`$as_dirname -- "$file" ||
22806 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22807 X"$file" : 'X\(//\)[^/]' \| \
22808 X"$file" : 'X\(//\)$' \| \
22809 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
22810 $as_echo X"$file" |
22811 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22812 s//\1/
22813 q
22814 }
22815 /^X\(\/\/\)[^/].*/{
22816 s//\1/
22817 q
22818 }
22819 /^X\(\/\/\)$/{
22820 s//\1/
22821 q
22822 }
22823 /^X\(\/\).*/{
22824 s//\1/
22825 q
22826 }
22827 s/.*/./; q'`
22828 as_dir=$dirpart/$fdir; as_fn_mkdir_p
22829 # echo "creating $dirpart/$file"
22830 echo '# dummy' > "$dirpart/$file"
22831 done
22832 done
22833 }
22834 ;;
22835 "mkdirs":C)
22836 for dir in etc lisp ; do
22837 test -d ${dir} || mkdir ${dir}
22838 done
22839 ;;
22840 "epaths":C)
22841 echo creating src/epaths.h
22842 ${MAKE-make} epaths-force
22843 ;;
22844 "gdbinit":C)
22845 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
22846 echo creating src/.gdbinit
22847 echo source $srcdir/src/.gdbinit > src/.gdbinit
22848 fi
22849 ;;
22850
22851 esac
22852 done # for ac_tag
22853
22854
22855 as_fn_exit 0
22856 _ACEOF
22857 ac_clean_files=$ac_clean_files_save
22858
22859 test $ac_write_fail = 0 ||
22860 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
22861
22862
22863 # configure is writing to config.log, and then calls config.status.
22864 # config.status does its own redirection, appending to config.log.
22865 # Unfortunately, on DOS this fails, as config.log is still kept open
22866 # by configure, so config.status won't be able to write to it; its
22867 # output is simply discarded. So we exec the FD to /dev/null,
22868 # effectively closing config.log, so it can be properly (re)opened and
22869 # appended to by config.status. When coming back to configure, we
22870 # need to make the FD available again.
22871 if test "$no_create" != yes; then
22872 ac_cs_success=:
22873 ac_config_status_args=
22874 test "$silent" = yes &&
22875 ac_config_status_args="$ac_config_status_args --quiet"
22876 exec 5>/dev/null
22877 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
22878 exec 5>>config.log
22879 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
22880 # would make configure fail if this is the last instruction.
22881 $ac_cs_success || as_fn_exit $?
22882 fi
22883 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
22884 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
22885 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
22886 fi
22887
22888