]> code.delx.au - gnu-emacs/blob - autogen/configure
`python-fill-paragraph' filling fixup when font-lock is disabled
[gnu-emacs] / autogen / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.65 for emacs 24.1.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.1.50'
553 PACKAGE_STRING='emacs 24.1.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 LIBGNU_LTLIBDEPS
611 LIBGNU_LIBDEPS
612 gltests_WITNESS
613 gl_GNULIB_ENABLED_verify_FALSE
614 gl_GNULIB_ENABLED_verify_TRUE
615 gl_GNULIB_ENABLED_strtoull_FALSE
616 gl_GNULIB_ENABLED_strtoull_TRUE
617 gl_GNULIB_ENABLED_strtoll_FALSE
618 gl_GNULIB_ENABLED_strtoll_TRUE
619 gl_GNULIB_ENABLED_stat_FALSE
620 gl_GNULIB_ENABLED_stat_TRUE
621 gl_GNULIB_ENABLED_sigprocmask_FALSE
622 gl_GNULIB_ENABLED_sigprocmask_TRUE
623 gl_GNULIB_ENABLED_pathmax_FALSE
624 gl_GNULIB_ENABLED_pathmax_TRUE
625 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE
626 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE
627 gl_GNULIB_ENABLED_dosname_FALSE
628 gl_GNULIB_ENABLED_dosname_TRUE
629 LTLIBINTL
630 LIBINTL
631 HAVE_UNISTD_H
632 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H
633 NEXT_UNISTD_H
634 PTHREAD_H_DEFINES_STRUCT_TIMESPEC
635 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
636 TIME_H_DEFINES_STRUCT_TIMESPEC
637 NEXT_AS_FIRST_DIRECTIVE_TIME_H
638 NEXT_TIME_H
639 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H
640 NEXT_SYS_STAT_H
641 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H
642 NEXT_STDLIB_H
643 NEXT_AS_FIRST_DIRECTIVE_STDIO_H
644 NEXT_STDIO_H
645 REPLACE_VSPRINTF
646 REPLACE_VSNPRINTF
647 REPLACE_VPRINTF
648 REPLACE_VFPRINTF
649 REPLACE_VDPRINTF
650 REPLACE_VASPRINTF
651 REPLACE_TMPFILE
652 REPLACE_STDIO_WRITE_FUNCS
653 REPLACE_STDIO_READ_FUNCS
654 REPLACE_SPRINTF
655 REPLACE_SNPRINTF
656 REPLACE_RENAMEAT
657 REPLACE_RENAME
658 REPLACE_REMOVE
659 REPLACE_PRINTF
660 REPLACE_POPEN
661 REPLACE_PERROR
662 REPLACE_OBSTACK_PRINTF
663 REPLACE_GETLINE
664 REPLACE_GETDELIM
665 REPLACE_FTELLO
666 REPLACE_FTELL
667 REPLACE_FSEEKO
668 REPLACE_FSEEK
669 REPLACE_FREOPEN
670 REPLACE_FPURGE
671 REPLACE_FPRINTF
672 REPLACE_FOPEN
673 REPLACE_FFLUSH
674 REPLACE_FDOPEN
675 REPLACE_FCLOSE
676 REPLACE_DPRINTF
677 HAVE_VDPRINTF
678 HAVE_VASPRINTF
679 HAVE_RENAMEAT
680 HAVE_POPEN
681 HAVE_PCLOSE
682 HAVE_FTELLO
683 HAVE_FSEEKO
684 HAVE_DPRINTF
685 HAVE_DECL_VSNPRINTF
686 HAVE_DECL_SNPRINTF
687 HAVE_DECL_OBSTACK_PRINTF
688 HAVE_DECL_GETLINE
689 HAVE_DECL_GETDELIM
690 HAVE_DECL_FTELLO
691 HAVE_DECL_FSEEKO
692 HAVE_DECL_FPURGE
693 GNULIB_VSPRINTF_POSIX
694 GNULIB_VSNPRINTF
695 GNULIB_VPRINTF_POSIX
696 GNULIB_VPRINTF
697 GNULIB_VFPRINTF_POSIX
698 GNULIB_VFPRINTF
699 GNULIB_VDPRINTF
700 GNULIB_VSCANF
701 GNULIB_VFSCANF
702 GNULIB_VASPRINTF
703 GNULIB_TMPFILE
704 GNULIB_STDIO_H_SIGPIPE
705 GNULIB_STDIO_H_NONBLOCKING
706 GNULIB_SPRINTF_POSIX
707 GNULIB_SNPRINTF
708 GNULIB_SCANF
709 GNULIB_RENAMEAT
710 GNULIB_RENAME
711 GNULIB_REMOVE
712 GNULIB_PUTS
713 GNULIB_PUTCHAR
714 GNULIB_PUTC
715 GNULIB_PRINTF_POSIX
716 GNULIB_PRINTF
717 GNULIB_POPEN
718 GNULIB_PERROR
719 GNULIB_PCLOSE
720 GNULIB_OBSTACK_PRINTF_POSIX
721 GNULIB_OBSTACK_PRINTF
722 GNULIB_GETS
723 GNULIB_GETLINE
724 GNULIB_GETDELIM
725 GNULIB_GETCHAR
726 GNULIB_GETC
727 GNULIB_FWRITE
728 GNULIB_FTELLO
729 GNULIB_FTELL
730 GNULIB_FSEEKO
731 GNULIB_FSEEK
732 GNULIB_FSCANF
733 GNULIB_FREOPEN
734 GNULIB_FREAD
735 GNULIB_FPUTS
736 GNULIB_FPUTC
737 GNULIB_FPURGE
738 GNULIB_FPRINTF_POSIX
739 GNULIB_FPRINTF
740 GNULIB_FOPEN
741 GNULIB_FGETS
742 GNULIB_FGETC
743 GNULIB_FFLUSH
744 GNULIB_FDOPEN
745 GNULIB_FCLOSE
746 GNULIB_DPRINTF
747 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H
748 NEXT_STDDEF_H
749 GL_GENERATE_STDDEF_H_FALSE
750 GL_GENERATE_STDDEF_H_TRUE
751 STDDEF_H
752 HAVE_WCHAR_T
753 REPLACE_NULL
754 HAVE__BOOL
755 GL_GENERATE_STDBOOL_H_FALSE
756 GL_GENERATE_STDBOOL_H_TRUE
757 STDBOOL_H
758 GL_GENERATE_STDARG_H_FALSE
759 GL_GENERATE_STDARG_H_TRUE
760 STDARG_H
761 NEXT_AS_FIRST_DIRECTIVE_STDARG_H
762 NEXT_STDARG_H
763 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H
764 NEXT_SIGNAL_H
765 REPLACE_RAISE
766 REPLACE_PTHREAD_SIGMASK
767 HAVE_SIGHANDLER_T
768 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T
769 HAVE_STRUCT_SIGACTION_SA_SIGACTION
770 HAVE_SIGACTION
771 HAVE_SIGINFO_T
772 HAVE_SIGSET_T
773 HAVE_RAISE
774 HAVE_PTHREAD_SIGMASK
775 HAVE_POSIX_SIGNALBLOCKING
776 GNULIB_SIGACTION
777 GNULIB_SIGPROCMASK
778 GNULIB_SIGNAL_H_SIGPIPE
779 GNULIB_RAISE
780 GNULIB_PTHREAD_SIGMASK
781 LIB_PTHREAD_SIGMASK
782 REPLACE_TIMEGM
783 REPLACE_NANOSLEEP
784 REPLACE_MKTIME
785 REPLACE_LOCALTIME_R
786 HAVE_TIMEGM
787 HAVE_STRPTIME
788 HAVE_NANOSLEEP
789 HAVE_DECL_LOCALTIME_R
790 GNULIB_TIME_R
791 GNULIB_TIMEGM
792 GNULIB_STRPTIME
793 GNULIB_NANOSLEEP
794 GNULIB_MKTIME
795 REPLACE_UTIMENSAT
796 REPLACE_STAT
797 REPLACE_MKNOD
798 REPLACE_MKFIFO
799 REPLACE_MKDIR
800 REPLACE_LSTAT
801 REPLACE_FUTIMENS
802 REPLACE_FSTATAT
803 REPLACE_FSTAT
804 HAVE_UTIMENSAT
805 HAVE_MKNODAT
806 HAVE_MKNOD
807 HAVE_MKFIFOAT
808 HAVE_MKFIFO
809 HAVE_MKDIRAT
810 HAVE_LSTAT
811 HAVE_LCHMOD
812 HAVE_FUTIMENS
813 HAVE_FSTATAT
814 HAVE_FCHMODAT
815 GNULIB_UTIMENSAT
816 GNULIB_STAT
817 GNULIB_MKNODAT
818 GNULIB_MKNOD
819 GNULIB_MKFIFOAT
820 GNULIB_MKFIFO
821 GNULIB_MKDIRAT
822 GNULIB_LSTAT
823 GNULIB_LCHMOD
824 GNULIB_FUTIMENS
825 GNULIB_FSTATAT
826 GNULIB_FSTAT
827 GNULIB_FCHMODAT
828 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H
829 NEXT_INTTYPES_H
830 UINT64_MAX_EQ_ULONG_MAX
831 UINT32_MAX_LT_UINTMAX_MAX
832 PRIPTR_PREFIX
833 PRI_MACROS_BROKEN
834 INT64_MAX_EQ_LONG_MAX
835 INT32_MAX_LT_INTMAX_MAX
836 HAVE_DECL_STRTOUMAX
837 HAVE_DECL_STRTOIMAX
838 HAVE_DECL_IMAXDIV
839 HAVE_DECL_IMAXABS
840 GNULIB_STRTOUMAX
841 GNULIB_STRTOIMAX
842 GNULIB_IMAXDIV
843 GNULIB_IMAXABS
844 GL_GENERATE_STDINT_H_FALSE
845 GL_GENERATE_STDINT_H_TRUE
846 STDINT_H
847 WINT_T_SUFFIX
848 WCHAR_T_SUFFIX
849 SIG_ATOMIC_T_SUFFIX
850 SIZE_T_SUFFIX
851 PTRDIFF_T_SUFFIX
852 HAVE_SIGNED_WINT_T
853 HAVE_SIGNED_WCHAR_T
854 HAVE_SIGNED_SIG_ATOMIC_T
855 BITSIZEOF_WINT_T
856 BITSIZEOF_WCHAR_T
857 BITSIZEOF_SIG_ATOMIC_T
858 BITSIZEOF_SIZE_T
859 BITSIZEOF_PTRDIFF_T
860 APPLE_UNIVERSAL_BUILD
861 HAVE_SYS_BITYPES_H
862 HAVE_SYS_INTTYPES_H
863 HAVE_STDINT_H
864 NEXT_AS_FIRST_DIRECTIVE_STDINT_H
865 NEXT_STDINT_H
866 HAVE_SYS_TYPES_H
867 HAVE_INTTYPES_H
868 HAVE_WCHAR_H
869 HAVE_UNSIGNED_LONG_LONG_INT
870 HAVE_LONG_LONG_INT
871 GETOPT_H
872 HAVE_GETOPT_H
873 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H
874 NEXT_GETOPT_H
875 PRAGMA_COLUMNS
876 PRAGMA_SYSTEM_HEADER
877 INCLUDE_NEXT_AS_FIRST_DIRECTIVE
878 INCLUDE_NEXT
879 GETLOADAVG_LIBS
880 REPLACE_WCTOMB
881 REPLACE_UNSETENV
882 REPLACE_STRTOD
883 REPLACE_SETENV
884 REPLACE_REALPATH
885 REPLACE_REALLOC
886 REPLACE_PUTENV
887 REPLACE_MKSTEMP
888 REPLACE_MBTOWC
889 REPLACE_MALLOC
890 REPLACE_CANONICALIZE_FILE_NAME
891 REPLACE_CALLOC
892 HAVE_DECL_UNSETENV
893 HAVE_UNLOCKPT
894 HAVE_SYS_LOADAVG_H
895 HAVE_STRUCT_RANDOM_DATA
896 HAVE_STRTOULL
897 HAVE_STRTOLL
898 HAVE_STRTOD
899 HAVE_DECL_SETENV
900 HAVE_SETENV
901 HAVE_RPMATCH
902 HAVE_REALPATH
903 HAVE_RANDOM_R
904 HAVE_RANDOM_H
905 HAVE_PTSNAME
906 HAVE_MKSTEMPS
907 HAVE_MKSTEMP
908 HAVE_MKOSTEMPS
909 HAVE_MKOSTEMP
910 HAVE_MKDTEMP
911 HAVE_GRANTPT
912 HAVE_GETSUBOPT
913 HAVE_DECL_GETLOADAVG
914 HAVE_CANONICALIZE_FILE_NAME
915 HAVE_ATOLL
916 HAVE__EXIT
917 GNULIB_WCTOMB
918 GNULIB_UNSETENV
919 GNULIB_UNLOCKPT
920 GNULIB_SYSTEM_POSIX
921 GNULIB_STRTOULL
922 GNULIB_STRTOLL
923 GNULIB_STRTOD
924 GNULIB_SETENV
925 GNULIB_RPMATCH
926 GNULIB_REALPATH
927 GNULIB_REALLOC_POSIX
928 GNULIB_RANDOM_R
929 GNULIB_PUTENV
930 GNULIB_PTSNAME
931 GNULIB_MKSTEMPS
932 GNULIB_MKSTEMP
933 GNULIB_MKOSTEMPS
934 GNULIB_MKOSTEMP
935 GNULIB_MKDTEMP
936 GNULIB_MBTOWC
937 GNULIB_MALLOC_POSIX
938 GNULIB_GRANTPT
939 GNULIB_GETSUBOPT
940 GNULIB_GETLOADAVG
941 GNULIB_CANONICALIZE_FILE_NAME
942 GNULIB_CALLOC_POSIX
943 GNULIB_ATOLL
944 GNULIB__EXIT
945 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS
946 UNISTD_H_HAVE_WINSOCK2_H
947 REPLACE_WRITE
948 REPLACE_USLEEP
949 REPLACE_UNLINKAT
950 REPLACE_UNLINK
951 REPLACE_TTYNAME_R
952 REPLACE_SYMLINK
953 REPLACE_SLEEP
954 REPLACE_RMDIR
955 REPLACE_READLINK
956 REPLACE_READ
957 REPLACE_PWRITE
958 REPLACE_PREAD
959 REPLACE_LSEEK
960 REPLACE_LINKAT
961 REPLACE_LINK
962 REPLACE_LCHOWN
963 REPLACE_GETPAGESIZE
964 REPLACE_GETGROUPS
965 REPLACE_GETLOGIN_R
966 REPLACE_GETDOMAINNAME
967 REPLACE_GETCWD
968 REPLACE_FCHOWNAT
969 REPLACE_DUP2
970 REPLACE_DUP
971 REPLACE_CLOSE
972 REPLACE_CHOWN
973 HAVE_SYS_PARAM_H
974 HAVE_OS_H
975 HAVE_DECL_TTYNAME_R
976 HAVE_DECL_GETUSERSHELL
977 HAVE_DECL_GETPAGESIZE
978 HAVE_DECL_GETLOGIN_R
979 HAVE_DECL_GETDOMAINNAME
980 HAVE_DECL_FDATASYNC
981 HAVE_DECL_FCHDIR
982 HAVE_DECL_ENVIRON
983 HAVE_USLEEP
984 HAVE_UNLINKAT
985 HAVE_SYMLINKAT
986 HAVE_SYMLINK
987 HAVE_SLEEP
988 HAVE_READLINKAT
989 HAVE_READLINK
990 HAVE_PWRITE
991 HAVE_PREAD
992 HAVE_PIPE2
993 HAVE_PIPE
994 HAVE_LINKAT
995 HAVE_LINK
996 HAVE_LCHOWN
997 HAVE_GROUP_MEMBER
998 HAVE_GETPAGESIZE
999 HAVE_GETLOGIN
1000 HAVE_GETHOSTNAME
1001 HAVE_GETGROUPS
1002 HAVE_GETDTABLESIZE
1003 HAVE_FTRUNCATE
1004 HAVE_FSYNC
1005 HAVE_FDATASYNC
1006 HAVE_FCHOWNAT
1007 HAVE_FCHDIR
1008 HAVE_FACCESSAT
1009 HAVE_EUIDACCESS
1010 HAVE_DUP3
1011 HAVE_DUP2
1012 HAVE_CHOWN
1013 GNULIB_WRITE
1014 GNULIB_USLEEP
1015 GNULIB_UNLINKAT
1016 GNULIB_UNLINK
1017 GNULIB_UNISTD_H_SIGPIPE
1018 GNULIB_UNISTD_H_NONBLOCKING
1019 GNULIB_UNISTD_H_GETOPT
1020 GNULIB_TTYNAME_R
1021 GNULIB_SYMLINKAT
1022 GNULIB_SYMLINK
1023 GNULIB_SLEEP
1024 GNULIB_RMDIR
1025 GNULIB_READLINKAT
1026 GNULIB_READLINK
1027 GNULIB_READ
1028 GNULIB_PWRITE
1029 GNULIB_PREAD
1030 GNULIB_PIPE2
1031 GNULIB_PIPE
1032 GNULIB_LSEEK
1033 GNULIB_LINKAT
1034 GNULIB_LINK
1035 GNULIB_LCHOWN
1036 GNULIB_GROUP_MEMBER
1037 GNULIB_GETUSERSHELL
1038 GNULIB_GETPAGESIZE
1039 GNULIB_GETLOGIN_R
1040 GNULIB_GETLOGIN
1041 GNULIB_GETHOSTNAME
1042 GNULIB_GETGROUPS
1043 GNULIB_GETDTABLESIZE
1044 GNULIB_GETDOMAINNAME
1045 GNULIB_GETCWD
1046 GNULIB_FTRUNCATE
1047 GNULIB_FSYNC
1048 GNULIB_FDATASYNC
1049 GNULIB_FCHOWNAT
1050 GNULIB_FCHDIR
1051 GNULIB_FACCESSAT
1052 GNULIB_EUIDACCESS
1053 GNULIB_ENVIRON
1054 GNULIB_DUP3
1055 GNULIB_DUP2
1056 GNULIB_DUP
1057 GNULIB_CLOSE
1058 GNULIB_CHOWN
1059 GNULIB_CHDIR
1060 GL_GENERATE_ALLOCA_H_FALSE
1061 GL_GENERATE_ALLOCA_H_TRUE
1062 ALLOCA_H
1063 ALLOCA
1064 GL_COND_LIBTOOL_FALSE
1065 GL_COND_LIBTOOL_TRUE
1066 POST_ALLOC_OBJ
1067 PRE_ALLOC_OBJ
1068 CYGWIN_OBJ
1069 RALLOC_OBJ
1070 OLDXMENU_DEPS
1071 LIBX_OTHER
1072 LIBXMENU
1073 OLDXMENU
1074 OLDXMENU_TARGET
1075 LIBXT_OTHER
1076 TOOLKIT_LIBW
1077 WIDGET_OBJ
1078 XOBJ
1079 XMENU_OBJ
1080 FONT_OBJ
1081 OTHER_FILES
1082 GNU_OBJC_CFLAGS
1083 ns_appsrc
1084 ns_appresdir
1085 ns_appbindir
1086 ns_appdir
1087 S_FILE
1088 M_FILE
1089 X_TOOLKIT_TYPE
1090 C_SWITCH_X_SYSTEM
1091 C_SWITCH_X_SITE
1092 LD_SWITCH_X_SITE
1093 gameuser
1094 gamedir
1095 bitmapdir
1096 archlibdir
1097 etcdir
1098 x_default_search_path
1099 lisppath
1100 locallisppath
1101 lispdir
1102 srcdir
1103 canonical
1104 configuration
1105 version
1106 KRB4LIB
1107 DESLIB
1108 KRB5LIB
1109 CRYPTOLIB
1110 COM_ERRLIB
1111 LIBRESOLV
1112 LIBHESIOD
1113 TERMCAP_OBJ
1114 LIBS_TERMCAP
1115 BLESSMAIL_TARGET
1116 LIBS_MAIL
1117 liblockfile
1118 LIBXML2_LIBS
1119 LIBXML2_CFLAGS
1120 LIBXSM
1121 LIBGPM
1122 LIBGIF
1123 LIBTIFF
1124 LIBPNG
1125 LIBJPEG
1126 LIBXPM
1127 M17N_FLT_LIBS
1128 M17N_FLT_CFLAGS
1129 LIBOTF_LIBS
1130 LIBOTF_CFLAGS
1131 FREETYPE_LIBS
1132 FREETYPE_CFLAGS
1133 XFT_LIBS
1134 XFT_CFLAGS
1135 FONTCONFIG_LIBS
1136 FONTCONFIG_CFLAGS
1137 LIBXMU
1138 LIBXTR6
1139 LIBGNUTLS_LIBS
1140 LIBGNUTLS_CFLAGS
1141 LIBSELINUX_LIBS
1142 SETTINGS_LIBS
1143 SETTINGS_CFLAGS
1144 GCONF_LIBS
1145 GCONF_CFLAGS
1146 GSETTINGS_LIBS
1147 GSETTINGS_CFLAGS
1148 DBUS_OBJ
1149 DBUS_LIBS
1150 DBUS_CFLAGS
1151 GTK_OBJ
1152 GTK_LIBS
1153 GTK_CFLAGS
1154 IMAGEMAGICK_LIBS
1155 IMAGEMAGICK_CFLAGS
1156 RSVG_LIBS
1157 RSVG_CFLAGS
1158 LIB_PTHREAD
1159 VMLIMIT_OBJ
1160 GMALLOC_OBJ
1161 HAVE_XSERVER
1162 LIB_STANDARD
1163 NS_OBJC_OBJ
1164 NS_OBJ
1165 TEMACS_LDFLAGS2
1166 LD_SWITCH_X_SITE_AUX_RPATH
1167 LD_SWITCH_X_SITE_AUX
1168 XMKMF
1169 DEPFLAGS
1170 MKDEPDIR
1171 CFLAGS_SOUND
1172 ALSA_LIBS
1173 ALSA_CFLAGS
1174 PKG_CONFIG
1175 LIBSOUND
1176 CRT_DIR
1177 START_FILES
1178 LIB_MATH
1179 LIBS_SYSTEM
1180 C_SWITCH_SYSTEM
1181 UNEXEC_OBJ
1182 C_SWITCH_MACHINE
1183 LD_SWITCH_SYSTEM
1184 CANNOT_DUMP
1185 HAVE_MAKEINFO
1186 GZIP_PROG
1187 INSTALL_INFO
1188 C_WARNINGS_SWITCH
1189 RANLIB
1190 ARFLAGS
1191 AR
1192 EGREP
1193 GREP
1194 CPP
1195 am__fastdepCC_FALSE
1196 am__fastdepCC_TRUE
1197 CCDEPMODE
1198 AMDEPBACKSLASH
1199 AMDEP_FALSE
1200 AMDEP_TRUE
1201 am__quote
1202 am__include
1203 DEPDIR
1204 OBJEXT
1205 EXEEXT
1206 ac_ct_CC
1207 CPPFLAGS
1208 LDFLAGS
1209 CFLAGS
1210 CC
1211 host_os
1212 host_vendor
1213 host_cpu
1214 host
1215 build_os
1216 build_vendor
1217 build_cpu
1218 build
1219 PROFILING_CFLAGS
1220 MAINT
1221 GZIP_INFO
1222 cache_file
1223 am__untar
1224 am__tar
1225 AMTAR
1226 am__leading_dot
1227 SET_MAKE
1228 AWK
1229 mkdir_p
1230 MKDIR_P
1231 INSTALL_STRIP_PROGRAM
1232 STRIP
1233 install_sh
1234 MAKEINFO
1235 AUTOHEADER
1236 AUTOMAKE
1237 AUTOCONF
1238 ACLOCAL
1239 VERSION
1240 PACKAGE
1241 CYGPATH_W
1242 am__isrc
1243 INSTALL_DATA
1244 INSTALL_SCRIPT
1245 INSTALL_PROGRAM
1246 target_alias
1247 host_alias
1248 build_alias
1249 LIBS
1250 ECHO_T
1251 ECHO_N
1252 ECHO_C
1253 DEFS
1254 mandir
1255 localedir
1256 libdir
1257 psdir
1258 pdfdir
1259 dvidir
1260 htmldir
1261 infodir
1262 docdir
1263 oldincludedir
1264 includedir
1265 localstatedir
1266 sharedstatedir
1267 sysconfdir
1268 datadir
1269 datarootdir
1270 libexecdir
1271 sbindir
1272 bindir
1273 program_transform_name
1274 prefix
1275 exec_prefix
1276 PACKAGE_URL
1277 PACKAGE_BUGREPORT
1278 PACKAGE_STRING
1279 PACKAGE_VERSION
1280 PACKAGE_TARNAME
1281 PACKAGE_NAME
1282 PATH_SEPARATOR
1283 SHELL'
1284 ac_subst_files='deps_frag
1285 lisp_frag
1286 ns_frag'
1287 ac_user_opts='
1288 enable_option_checking
1289 with_pop
1290 with_kerberos
1291 with_kerberos5
1292 with_hesiod
1293 with_mmdf
1294 with_mail_unlink
1295 with_mailhost
1296 with_sound
1297 with_sync_input
1298 with_x_toolkit
1299 with_wide_int
1300 with_xpm
1301 with_jpeg
1302 with_tiff
1303 with_gif
1304 with_png
1305 with_rsvg
1306 with_xml2
1307 with_imagemagick
1308 with_xft
1309 with_libotf
1310 with_m17n_flt
1311 with_toolkit_scroll_bars
1312 with_xaw3d
1313 with_xim
1314 with_ns
1315 with_gpm
1316 with_dbus
1317 with_gconf
1318 with_gsettings
1319 with_selinux
1320 with_gnutls
1321 with_makeinfo
1322 with_compress_info
1323 with_pkg_config_prog
1324 with_crt_dir
1325 with_gameuser
1326 with_gnustep_conf
1327 enable_ns_self_contained
1328 enable_asserts
1329 enable_maintainer_mode
1330 enable_locallisppath
1331 enable_checking
1332 enable_use_lisp_union_type
1333 enable_profiling
1334 enable_autodepend
1335 enable_dependency_tracking
1336 enable_largefile
1337 with_x
1338 '
1339 ac_precious_vars='build_alias
1340 host_alias
1341 target_alias
1342 CC
1343 CFLAGS
1344 LDFLAGS
1345 LIBS
1346 CPPFLAGS
1347 CPP
1348 XMKMF'
1349
1350
1351 # Initialize some variables set by options.
1352 ac_init_help=
1353 ac_init_version=false
1354 ac_unrecognized_opts=
1355 ac_unrecognized_sep=
1356 # The variables have the same names as the options, with
1357 # dashes changed to underlines.
1358 cache_file=/dev/null
1359 exec_prefix=NONE
1360 no_create=
1361 no_recursion=
1362 prefix=NONE
1363 program_prefix=NONE
1364 program_suffix=NONE
1365 program_transform_name=s,x,x,
1366 silent=
1367 site=
1368 srcdir=
1369 verbose=
1370 x_includes=NONE
1371 x_libraries=NONE
1372
1373 # Installation directory options.
1374 # These are left unexpanded so users can "make install exec_prefix=/foo"
1375 # and all the variables that are supposed to be based on exec_prefix
1376 # by default will actually change.
1377 # Use braces instead of parens because sh, perl, etc. also accept them.
1378 # (The list follows the same order as the GNU Coding Standards.)
1379 bindir='${exec_prefix}/bin'
1380 sbindir='${exec_prefix}/sbin'
1381 libexecdir='${exec_prefix}/libexec'
1382 datarootdir='${prefix}/share'
1383 datadir='${datarootdir}'
1384 sysconfdir='${prefix}/etc'
1385 sharedstatedir='${prefix}/com'
1386 localstatedir='${prefix}/var'
1387 includedir='${prefix}/include'
1388 oldincludedir='/usr/include'
1389 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
1390 infodir='${datarootdir}/info'
1391 htmldir='${docdir}'
1392 dvidir='${docdir}'
1393 pdfdir='${docdir}'
1394 psdir='${docdir}'
1395 libdir='${exec_prefix}/lib'
1396 localedir='${datarootdir}/locale'
1397 mandir='${datarootdir}/man'
1398
1399 ac_prev=
1400 ac_dashdash=
1401 for ac_option
1402 do
1403 # If the previous option needs an argument, assign it.
1404 if test -n "$ac_prev"; then
1405 eval $ac_prev=\$ac_option
1406 ac_prev=
1407 continue
1408 fi
1409
1410 case $ac_option in
1411 *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
1412 *) ac_optarg=yes ;;
1413 esac
1414
1415 # Accept the important Cygnus configure options, so we can diagnose typos.
1416
1417 case $ac_dashdash$ac_option in
1418 --)
1419 ac_dashdash=yes ;;
1420
1421 -bindir | --bindir | --bindi | --bind | --bin | --bi)
1422 ac_prev=bindir ;;
1423 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
1424 bindir=$ac_optarg ;;
1425
1426 -build | --build | --buil | --bui | --bu)
1427 ac_prev=build_alias ;;
1428 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1429 build_alias=$ac_optarg ;;
1430
1431 -cache-file | --cache-file | --cache-fil | --cache-fi \
1432 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1433 ac_prev=cache_file ;;
1434 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1435 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1436 cache_file=$ac_optarg ;;
1437
1438 --config-cache | -C)
1439 cache_file=config.cache ;;
1440
1441 -datadir | --datadir | --datadi | --datad)
1442 ac_prev=datadir ;;
1443 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1444 datadir=$ac_optarg ;;
1445
1446 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1447 | --dataroo | --dataro | --datar)
1448 ac_prev=datarootdir ;;
1449 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1450 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1451 datarootdir=$ac_optarg ;;
1452
1453 -disable-* | --disable-*)
1454 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1455 # Reject names that are not valid shell variable names.
1456 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1457 as_fn_error "invalid feature name: $ac_useropt"
1458 ac_useropt_orig=$ac_useropt
1459 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1460 case $ac_user_opts in
1461 *"
1462 "enable_$ac_useropt"
1463 "*) ;;
1464 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1465 ac_unrecognized_sep=', ';;
1466 esac
1467 eval enable_$ac_useropt=no ;;
1468
1469 -docdir | --docdir | --docdi | --doc | --do)
1470 ac_prev=docdir ;;
1471 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1472 docdir=$ac_optarg ;;
1473
1474 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1475 ac_prev=dvidir ;;
1476 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1477 dvidir=$ac_optarg ;;
1478
1479 -enable-* | --enable-*)
1480 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1481 # Reject names that are not valid shell variable names.
1482 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1483 as_fn_error "invalid feature name: $ac_useropt"
1484 ac_useropt_orig=$ac_useropt
1485 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1486 case $ac_user_opts in
1487 *"
1488 "enable_$ac_useropt"
1489 "*) ;;
1490 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1491 ac_unrecognized_sep=', ';;
1492 esac
1493 eval enable_$ac_useropt=\$ac_optarg ;;
1494
1495 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1496 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1497 | --exec | --exe | --ex)
1498 ac_prev=exec_prefix ;;
1499 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1500 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1501 | --exec=* | --exe=* | --ex=*)
1502 exec_prefix=$ac_optarg ;;
1503
1504 -gas | --gas | --ga | --g)
1505 # Obsolete; use --with-gas.
1506 with_gas=yes ;;
1507
1508 -help | --help | --hel | --he | -h)
1509 ac_init_help=long ;;
1510 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1511 ac_init_help=recursive ;;
1512 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1513 ac_init_help=short ;;
1514
1515 -host | --host | --hos | --ho)
1516 ac_prev=host_alias ;;
1517 -host=* | --host=* | --hos=* | --ho=*)
1518 host_alias=$ac_optarg ;;
1519
1520 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1521 ac_prev=htmldir ;;
1522 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1523 | --ht=*)
1524 htmldir=$ac_optarg ;;
1525
1526 -includedir | --includedir | --includedi | --included | --include \
1527 | --includ | --inclu | --incl | --inc)
1528 ac_prev=includedir ;;
1529 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1530 | --includ=* | --inclu=* | --incl=* | --inc=*)
1531 includedir=$ac_optarg ;;
1532
1533 -infodir | --infodir | --infodi | --infod | --info | --inf)
1534 ac_prev=infodir ;;
1535 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1536 infodir=$ac_optarg ;;
1537
1538 -libdir | --libdir | --libdi | --libd)
1539 ac_prev=libdir ;;
1540 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1541 libdir=$ac_optarg ;;
1542
1543 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1544 | --libexe | --libex | --libe)
1545 ac_prev=libexecdir ;;
1546 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1547 | --libexe=* | --libex=* | --libe=*)
1548 libexecdir=$ac_optarg ;;
1549
1550 -localedir | --localedir | --localedi | --localed | --locale)
1551 ac_prev=localedir ;;
1552 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1553 localedir=$ac_optarg ;;
1554
1555 -localstatedir | --localstatedir | --localstatedi | --localstated \
1556 | --localstate | --localstat | --localsta | --localst | --locals)
1557 ac_prev=localstatedir ;;
1558 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1559 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1560 localstatedir=$ac_optarg ;;
1561
1562 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1563 ac_prev=mandir ;;
1564 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1565 mandir=$ac_optarg ;;
1566
1567 -nfp | --nfp | --nf)
1568 # Obsolete; use --without-fp.
1569 with_fp=no ;;
1570
1571 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1572 | --no-cr | --no-c | -n)
1573 no_create=yes ;;
1574
1575 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1576 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1577 no_recursion=yes ;;
1578
1579 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1580 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1581 | --oldin | --oldi | --old | --ol | --o)
1582 ac_prev=oldincludedir ;;
1583 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1584 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1585 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1586 oldincludedir=$ac_optarg ;;
1587
1588 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1589 ac_prev=prefix ;;
1590 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1591 prefix=$ac_optarg ;;
1592
1593 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1594 | --program-pre | --program-pr | --program-p)
1595 ac_prev=program_prefix ;;
1596 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1597 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1598 program_prefix=$ac_optarg ;;
1599
1600 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1601 | --program-suf | --program-su | --program-s)
1602 ac_prev=program_suffix ;;
1603 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1604 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1605 program_suffix=$ac_optarg ;;
1606
1607 -program-transform-name | --program-transform-name \
1608 | --program-transform-nam | --program-transform-na \
1609 | --program-transform-n | --program-transform- \
1610 | --program-transform | --program-transfor \
1611 | --program-transfo | --program-transf \
1612 | --program-trans | --program-tran \
1613 | --progr-tra | --program-tr | --program-t)
1614 ac_prev=program_transform_name ;;
1615 -program-transform-name=* | --program-transform-name=* \
1616 | --program-transform-nam=* | --program-transform-na=* \
1617 | --program-transform-n=* | --program-transform-=* \
1618 | --program-transform=* | --program-transfor=* \
1619 | --program-transfo=* | --program-transf=* \
1620 | --program-trans=* | --program-tran=* \
1621 | --progr-tra=* | --program-tr=* | --program-t=*)
1622 program_transform_name=$ac_optarg ;;
1623
1624 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1625 ac_prev=pdfdir ;;
1626 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1627 pdfdir=$ac_optarg ;;
1628
1629 -psdir | --psdir | --psdi | --psd | --ps)
1630 ac_prev=psdir ;;
1631 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1632 psdir=$ac_optarg ;;
1633
1634 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1635 | -silent | --silent | --silen | --sile | --sil)
1636 silent=yes ;;
1637
1638 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1639 ac_prev=sbindir ;;
1640 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1641 | --sbi=* | --sb=*)
1642 sbindir=$ac_optarg ;;
1643
1644 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1645 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1646 | --sharedst | --shareds | --shared | --share | --shar \
1647 | --sha | --sh)
1648 ac_prev=sharedstatedir ;;
1649 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1650 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1651 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1652 | --sha=* | --sh=*)
1653 sharedstatedir=$ac_optarg ;;
1654
1655 -site | --site | --sit)
1656 ac_prev=site ;;
1657 -site=* | --site=* | --sit=*)
1658 site=$ac_optarg ;;
1659
1660 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1661 ac_prev=srcdir ;;
1662 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1663 srcdir=$ac_optarg ;;
1664
1665 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1666 | --syscon | --sysco | --sysc | --sys | --sy)
1667 ac_prev=sysconfdir ;;
1668 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1669 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1670 sysconfdir=$ac_optarg ;;
1671
1672 -target | --target | --targe | --targ | --tar | --ta | --t)
1673 ac_prev=target_alias ;;
1674 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1675 target_alias=$ac_optarg ;;
1676
1677 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1678 verbose=yes ;;
1679
1680 -version | --version | --versio | --versi | --vers | -V)
1681 ac_init_version=: ;;
1682
1683 -with-* | --with-*)
1684 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1685 # Reject names that are not valid shell variable names.
1686 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1687 as_fn_error "invalid package name: $ac_useropt"
1688 ac_useropt_orig=$ac_useropt
1689 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1690 case $ac_user_opts in
1691 *"
1692 "with_$ac_useropt"
1693 "*) ;;
1694 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1695 ac_unrecognized_sep=', ';;
1696 esac
1697 eval with_$ac_useropt=\$ac_optarg ;;
1698
1699 -without-* | --without-*)
1700 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1701 # Reject names that are not valid shell variable names.
1702 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1703 as_fn_error "invalid package name: $ac_useropt"
1704 ac_useropt_orig=$ac_useropt
1705 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1706 case $ac_user_opts in
1707 *"
1708 "with_$ac_useropt"
1709 "*) ;;
1710 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1711 ac_unrecognized_sep=', ';;
1712 esac
1713 eval with_$ac_useropt=no ;;
1714
1715 --x)
1716 # Obsolete; use --with-x.
1717 with_x=yes ;;
1718
1719 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1720 | --x-incl | --x-inc | --x-in | --x-i)
1721 ac_prev=x_includes ;;
1722 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1723 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1724 x_includes=$ac_optarg ;;
1725
1726 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1727 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1728 ac_prev=x_libraries ;;
1729 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1730 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1731 x_libraries=$ac_optarg ;;
1732
1733 -*) as_fn_error "unrecognized option: \`$ac_option'
1734 Try \`$0 --help' for more information."
1735 ;;
1736
1737 *=*)
1738 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1739 # Reject names that are not valid shell variable names.
1740 case $ac_envvar in #(
1741 '' | [0-9]* | *[!_$as_cr_alnum]* )
1742 as_fn_error "invalid variable name: \`$ac_envvar'" ;;
1743 esac
1744 eval $ac_envvar=\$ac_optarg
1745 export $ac_envvar ;;
1746
1747 *)
1748 # FIXME: should be removed in autoconf 3.0.
1749 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1750 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1751 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1752 : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1753 ;;
1754
1755 esac
1756 done
1757
1758 if test -n "$ac_prev"; then
1759 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1760 as_fn_error "missing argument to $ac_option"
1761 fi
1762
1763 if test -n "$ac_unrecognized_opts"; then
1764 case $enable_option_checking in
1765 no) ;;
1766 fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;;
1767 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1768 esac
1769 fi
1770
1771 # Check all directory arguments for consistency.
1772 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1773 datadir sysconfdir sharedstatedir localstatedir includedir \
1774 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1775 libdir localedir mandir
1776 do
1777 eval ac_val=\$$ac_var
1778 # Remove trailing slashes.
1779 case $ac_val in
1780 */ )
1781 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1782 eval $ac_var=\$ac_val;;
1783 esac
1784 # Be sure to have absolute directory names.
1785 case $ac_val in
1786 [\\/$]* | ?:[\\/]* ) continue;;
1787 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1788 esac
1789 as_fn_error "expected an absolute directory name for --$ac_var: $ac_val"
1790 done
1791
1792 # There might be people who depend on the old broken behavior: `$host'
1793 # used to hold the argument of --host etc.
1794 # FIXME: To remove some day.
1795 build=$build_alias
1796 host=$host_alias
1797 target=$target_alias
1798
1799 # FIXME: To remove some day.
1800 if test "x$host_alias" != x; then
1801 if test "x$build_alias" = x; then
1802 cross_compiling=maybe
1803 $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1804 If a cross compiler is detected then cross compile mode will be used." >&2
1805 elif test "x$build_alias" != "x$host_alias"; then
1806 cross_compiling=yes
1807 fi
1808 fi
1809
1810 ac_tool_prefix=
1811 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1812
1813 test "$silent" = yes && exec 6>/dev/null
1814
1815
1816 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1817 ac_ls_di=`ls -di .` &&
1818 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1819 as_fn_error "working directory cannot be determined"
1820 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1821 as_fn_error "pwd does not report name of working directory"
1822
1823
1824 # Find the source files, if location was not specified.
1825 if test -z "$srcdir"; then
1826 ac_srcdir_defaulted=yes
1827 # Try the directory containing this script, then the parent directory.
1828 ac_confdir=`$as_dirname -- "$as_myself" ||
1829 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1830 X"$as_myself" : 'X\(//\)[^/]' \| \
1831 X"$as_myself" : 'X\(//\)$' \| \
1832 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1833 $as_echo X"$as_myself" |
1834 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1835 s//\1/
1836 q
1837 }
1838 /^X\(\/\/\)[^/].*/{
1839 s//\1/
1840 q
1841 }
1842 /^X\(\/\/\)$/{
1843 s//\1/
1844 q
1845 }
1846 /^X\(\/\).*/{
1847 s//\1/
1848 q
1849 }
1850 s/.*/./; q'`
1851 srcdir=$ac_confdir
1852 if test ! -r "$srcdir/$ac_unique_file"; then
1853 srcdir=..
1854 fi
1855 else
1856 ac_srcdir_defaulted=no
1857 fi
1858 if test ! -r "$srcdir/$ac_unique_file"; then
1859 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1860 as_fn_error "cannot find sources ($ac_unique_file) in $srcdir"
1861 fi
1862 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1863 ac_abs_confdir=`(
1864 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg"
1865 pwd)`
1866 # When building in place, set srcdir=.
1867 if test "$ac_abs_confdir" = "$ac_pwd"; then
1868 srcdir=.
1869 fi
1870 # Remove unnecessary trailing slashes from srcdir.
1871 # Double slashes in file names in object file debugging info
1872 # mess up M-x gdb in Emacs.
1873 case $srcdir in
1874 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1875 esac
1876 for ac_var in $ac_precious_vars; do
1877 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1878 eval ac_env_${ac_var}_value=\$${ac_var}
1879 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1880 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1881 done
1882
1883 #
1884 # Report the --help message.
1885 #
1886 if test "$ac_init_help" = "long"; then
1887 # Omit some internal or obsolete options to make the list less imposing.
1888 # This message is too long to be a string in the A/UX 3.1 sh.
1889 cat <<_ACEOF
1890 \`configure' configures emacs 24.1.50 to adapt to many kinds of systems.
1891
1892 Usage: $0 [OPTION]... [VAR=VALUE]...
1893
1894 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1895 VAR=VALUE. See below for descriptions of some of the useful variables.
1896
1897 Defaults for the options are specified in brackets.
1898
1899 Configuration:
1900 -h, --help display this help and exit
1901 --help=short display options specific to this package
1902 --help=recursive display the short help of all the included packages
1903 -V, --version display version information and exit
1904 -q, --quiet, --silent do not print \`checking...' messages
1905 --cache-file=FILE cache test results in FILE [disabled]
1906 -C, --config-cache alias for \`--cache-file=config.cache'
1907 -n, --no-create do not create output files
1908 --srcdir=DIR find the sources in DIR [configure dir or \`..']
1909
1910 Installation directories:
1911 --prefix=PREFIX install architecture-independent files in PREFIX
1912 [$ac_default_prefix]
1913 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1914 [PREFIX]
1915
1916 By default, \`make install' will install all the files in
1917 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify
1918 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1919 for instance \`--prefix=\$HOME'.
1920
1921 For better control, use the options below.
1922
1923 Fine tuning of the installation directories:
1924 --bindir=DIR user executables [EPREFIX/bin]
1925 --sbindir=DIR system admin executables [EPREFIX/sbin]
1926 --libexecdir=DIR program executables [EPREFIX/libexec]
1927 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1928 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1929 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1930 --libdir=DIR object code libraries [EPREFIX/lib]
1931 --includedir=DIR C header files [PREFIX/include]
1932 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1933 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1934 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1935 --infodir=DIR info documentation [DATAROOTDIR/info]
1936 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1937 --mandir=DIR man documentation [DATAROOTDIR/man]
1938 --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
1939 --htmldir=DIR html documentation [DOCDIR]
1940 --dvidir=DIR dvi documentation [DOCDIR]
1941 --pdfdir=DIR pdf documentation [DOCDIR]
1942 --psdir=DIR ps documentation [DOCDIR]
1943 _ACEOF
1944
1945 cat <<\_ACEOF
1946
1947 Program names:
1948 --program-prefix=PREFIX prepend PREFIX to installed program names
1949 --program-suffix=SUFFIX append SUFFIX to installed program names
1950 --program-transform-name=PROGRAM run sed PROGRAM on installed program names
1951
1952 X features:
1953 --x-includes=DIR X include files are in DIR
1954 --x-libraries=DIR X library files are in DIR
1955
1956 System types:
1957 --build=BUILD configure for building on BUILD [guessed]
1958 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1959 _ACEOF
1960 fi
1961
1962 if test -n "$ac_init_help"; then
1963 case $ac_init_help in
1964 short | recursive ) echo "Configuration of emacs 24.1.50:";;
1965 esac
1966 cat <<\_ACEOF
1967
1968 Optional Features:
1969 --disable-option-checking ignore unrecognized --enable/--with options
1970 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1971 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1972 --disable-ns-self-contained
1973 disable self contained build under NeXTstep
1974 --enable-asserts compile code with asserts enabled
1975 --disable-maintainer-mode
1976 disable make rules and dependencies not useful (and
1977 sometimes confusing) to the casual installer
1978 --enable-locallisppath=PATH
1979 directories Emacs should search for lisp files
1980 specific to this site
1981 --enable-checking[=LIST]
1982 enable expensive run-time checks. With LIST, enable
1983 only specific categories of checks. Categories are:
1984 all,yes,no. Flags are: stringbytes, stringoverrun,
1985 stringfreelist, xmallocoverrun, conslist
1986 --enable-use-lisp-union-type
1987 use a union for the Lisp_Object data type. This is
1988 only useful for development for catching certain
1989 types of bugs.
1990 --enable-profiling build emacs with profiling support. This might not
1991 work on all platforms
1992 --enable-autodepend automatically generate dependencies to .h-files.
1993 Requires GNU Make and Gcc. Enabled if GNU Make and
1994 Gcc is found
1995 --disable-dependency-tracking speeds up one-time build
1996 --enable-dependency-tracking do not reject slow dependency extractors
1997 --disable-largefile omit support for large files
1998
1999 Optional Packages:
2000 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
2001 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
2002 --without-pop don't support POP mail retrieval with movemail
2003 --with-kerberos support Kerberos-authenticated POP
2004 --with-kerberos5 support Kerberos version 5 authenticated POP
2005 --with-hesiod support Hesiod to get the POP server host
2006 --with-mmdf support MMDF mailboxes
2007 --with-mail-unlink unlink, rather than empty, mail spool after reading
2008 --with-mailhost=HOSTNAME
2009 string giving default POP mail host
2010 --without-sound don't compile with sound support
2011 --without-sync-input process async input synchronously
2012 --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk3,
2013 lucid or athena, motif, no)
2014 --with-wide-int prefer wide Emacs integers (typically 62-bit)
2015 --without-xpm don't compile with XPM image support
2016 --without-jpeg don't compile with JPEG image support
2017 --without-tiff don't compile with TIFF image support
2018 --without-gif don't compile with GIF image support
2019 --without-png don't compile with PNG image support
2020 --without-rsvg don't compile with SVG image support
2021 --without-xml2 don't compile with XML parsing support
2022 --without-imagemagick don't compile with ImageMagick image support
2023 --without-xft don't use XFT for anti aliased fonts
2024 --without-libotf don't use libotf for OpenType font support
2025 --without-m17n-flt don't use m17n-flt for text shaping
2026 --without-toolkit-scroll-bars
2027 don't use Motif or Xaw3d scroll bars
2028 --without-xaw3d don't use Xaw3d
2029 --without-xim don't use X11 XIM
2030 --with-ns use NeXTstep (Cocoa or GNUstep) windowing system
2031 --without-gpm don't use -lgpm for mouse support on a GNU/Linux
2032 console
2033 --without-dbus don't compile with D-Bus support
2034 --without-gconf don't compile with GConf support
2035 --without-gsettings don't compile with GSettings support
2036 --without-selinux don't compile with SELinux support
2037 --without-gnutls don't use -lgnutls for SSL/TLS support
2038 --without-makeinfo don't require makeinfo for building manuals
2039 --without-compress-info don't compress the installed Info pages
2040 --with-pkg-config-prog=PATH
2041 path to pkg-config for finding GTK and librsvg
2042 --with-crt-dir=DIR directory containing crtn.o etc. The default is
2043 /usr/lib, or /usr/lib64 on some platforms.
2044 --with-gameuser=USER user for shared game score files
2045 --with-gnustep-conf=PATH
2046 path to GNUstep.conf; default $GNUSTEP_CONFIG_FILE,
2047 or /etc/GNUstep/GNUstep.conf
2048 --with-x use the X Window System
2049
2050 Some influential environment variables:
2051 CC C compiler command
2052 CFLAGS C compiler flags
2053 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
2054 nonstandard directory <lib dir>
2055 LIBS libraries to pass to the linker, e.g. -l<library>
2056 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
2057 you have headers in a nonstandard directory <include dir>
2058 CPP C preprocessor
2059 XMKMF Path to xmkmf, Makefile generator for X Window System
2060
2061 Use these variables to override the choices made by `configure' or to help
2062 it to find libraries and programs with nonstandard names/locations.
2063
2064 Report bugs to the package provider.
2065 _ACEOF
2066 ac_status=$?
2067 fi
2068
2069 if test "$ac_init_help" = "recursive"; then
2070 # If there are subdirs, report their specific --help.
2071 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
2072 test -d "$ac_dir" ||
2073 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
2074 continue
2075 ac_builddir=.
2076
2077 case "$ac_dir" in
2078 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
2079 *)
2080 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
2081 # A ".." for each directory in $ac_dir_suffix.
2082 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
2083 case $ac_top_builddir_sub in
2084 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
2085 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
2086 esac ;;
2087 esac
2088 ac_abs_top_builddir=$ac_pwd
2089 ac_abs_builddir=$ac_pwd$ac_dir_suffix
2090 # for backward compatibility:
2091 ac_top_builddir=$ac_top_build_prefix
2092
2093 case $srcdir in
2094 .) # We are building in place.
2095 ac_srcdir=.
2096 ac_top_srcdir=$ac_top_builddir_sub
2097 ac_abs_top_srcdir=$ac_pwd ;;
2098 [\\/]* | ?:[\\/]* ) # Absolute name.
2099 ac_srcdir=$srcdir$ac_dir_suffix;
2100 ac_top_srcdir=$srcdir
2101 ac_abs_top_srcdir=$srcdir ;;
2102 *) # Relative name.
2103 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
2104 ac_top_srcdir=$ac_top_build_prefix$srcdir
2105 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
2106 esac
2107 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
2108
2109 cd "$ac_dir" || { ac_status=$?; continue; }
2110 # Check for guested configure.
2111 if test -f "$ac_srcdir/configure.gnu"; then
2112 echo &&
2113 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
2114 elif test -f "$ac_srcdir/configure"; then
2115 echo &&
2116 $SHELL "$ac_srcdir/configure" --help=recursive
2117 else
2118 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
2119 fi || ac_status=$?
2120 cd "$ac_pwd" || { ac_status=$?; break; }
2121 done
2122 fi
2123
2124 test -n "$ac_init_help" && exit $ac_status
2125 if $ac_init_version; then
2126 cat <<\_ACEOF
2127 emacs configure 24.1.50
2128 generated by GNU Autoconf 2.65
2129
2130 Copyright (C) 2009 Free Software Foundation, Inc.
2131 This configure script is free software; the Free Software Foundation
2132 gives unlimited permission to copy, distribute and modify it.
2133 _ACEOF
2134 exit
2135 fi
2136
2137 ## ------------------------ ##
2138 ## Autoconf initialization. ##
2139 ## ------------------------ ##
2140
2141 # ac_fn_c_try_compile LINENO
2142 # --------------------------
2143 # Try to compile conftest.$ac_ext, and return whether this succeeded.
2144 ac_fn_c_try_compile ()
2145 {
2146 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2147 rm -f conftest.$ac_objext
2148 if { { ac_try="$ac_compile"
2149 case "(($ac_try" in
2150 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2151 *) ac_try_echo=$ac_try;;
2152 esac
2153 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2154 $as_echo "$ac_try_echo"; } >&5
2155 (eval "$ac_compile") 2>conftest.err
2156 ac_status=$?
2157 if test -s conftest.err; then
2158 grep -v '^ *+' conftest.err >conftest.er1
2159 cat conftest.er1 >&5
2160 mv -f conftest.er1 conftest.err
2161 fi
2162 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2163 test $ac_status = 0; } && {
2164 test -z "$ac_c_werror_flag" ||
2165 test ! -s conftest.err
2166 } && test -s conftest.$ac_objext; then :
2167 ac_retval=0
2168 else
2169 $as_echo "$as_me: failed program was:" >&5
2170 sed 's/^/| /' conftest.$ac_ext >&5
2171
2172 ac_retval=1
2173 fi
2174 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2175 as_fn_set_status $ac_retval
2176
2177 } # ac_fn_c_try_compile
2178
2179 # ac_fn_c_try_cpp LINENO
2180 # ----------------------
2181 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
2182 ac_fn_c_try_cpp ()
2183 {
2184 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2185 if { { ac_try="$ac_cpp conftest.$ac_ext"
2186 case "(($ac_try" in
2187 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2188 *) ac_try_echo=$ac_try;;
2189 esac
2190 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2191 $as_echo "$ac_try_echo"; } >&5
2192 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2193 ac_status=$?
2194 if test -s conftest.err; then
2195 grep -v '^ *+' conftest.err >conftest.er1
2196 cat conftest.er1 >&5
2197 mv -f conftest.er1 conftest.err
2198 fi
2199 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2200 test $ac_status = 0; } >/dev/null && {
2201 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2202 test ! -s conftest.err
2203 }; then :
2204 ac_retval=0
2205 else
2206 $as_echo "$as_me: failed program was:" >&5
2207 sed 's/^/| /' conftest.$ac_ext >&5
2208
2209 ac_retval=1
2210 fi
2211 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2212 as_fn_set_status $ac_retval
2213
2214 } # ac_fn_c_try_cpp
2215
2216 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
2217 # -------------------------------------------------------
2218 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
2219 # the include files in INCLUDES and setting the cache variable VAR
2220 # accordingly.
2221 ac_fn_c_check_header_mongrel ()
2222 {
2223 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2224 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2226 $as_echo_n "checking for $2... " >&6; }
2227 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2228 $as_echo_n "(cached) " >&6
2229 fi
2230 eval ac_res=\$$3
2231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2232 $as_echo "$ac_res" >&6; }
2233 else
2234 # Is the header compilable?
2235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
2236 $as_echo_n "checking $2 usability... " >&6; }
2237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2238 /* end confdefs.h. */
2239 $4
2240 #include <$2>
2241 _ACEOF
2242 if ac_fn_c_try_compile "$LINENO"; then :
2243 ac_header_compiler=yes
2244 else
2245 ac_header_compiler=no
2246 fi
2247 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
2249 $as_echo "$ac_header_compiler" >&6; }
2250
2251 # Is the header present?
2252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
2253 $as_echo_n "checking $2 presence... " >&6; }
2254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2255 /* end confdefs.h. */
2256 #include <$2>
2257 _ACEOF
2258 if ac_fn_c_try_cpp "$LINENO"; then :
2259 ac_header_preproc=yes
2260 else
2261 ac_header_preproc=no
2262 fi
2263 rm -f conftest.err conftest.$ac_ext
2264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
2265 $as_echo "$ac_header_preproc" >&6; }
2266
2267 # So? What about this header?
2268 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
2269 yes:no: )
2270 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
2271 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
2272 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2273 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2274 ;;
2275 no:yes:* )
2276 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
2277 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
2278 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5
2279 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;}
2280 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
2281 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
2282 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5
2283 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;}
2284 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
2285 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
2286 ;;
2287 esac
2288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2289 $as_echo_n "checking for $2... " >&6; }
2290 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2291 $as_echo_n "(cached) " >&6
2292 else
2293 eval "$3=\$ac_header_compiler"
2294 fi
2295 eval ac_res=\$$3
2296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2297 $as_echo "$ac_res" >&6; }
2298 fi
2299 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2300
2301 } # ac_fn_c_check_header_mongrel
2302
2303 # ac_fn_c_try_run LINENO
2304 # ----------------------
2305 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
2306 # that executables *can* be run.
2307 ac_fn_c_try_run ()
2308 {
2309 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2310 if { { ac_try="$ac_link"
2311 case "(($ac_try" in
2312 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2313 *) ac_try_echo=$ac_try;;
2314 esac
2315 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2316 $as_echo "$ac_try_echo"; } >&5
2317 (eval "$ac_link") 2>&5
2318 ac_status=$?
2319 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2320 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
2321 { { case "(($ac_try" in
2322 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2323 *) ac_try_echo=$ac_try;;
2324 esac
2325 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2326 $as_echo "$ac_try_echo"; } >&5
2327 (eval "$ac_try") 2>&5
2328 ac_status=$?
2329 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2330 test $ac_status = 0; }; }; then :
2331 ac_retval=0
2332 else
2333 $as_echo "$as_me: program exited with status $ac_status" >&5
2334 $as_echo "$as_me: failed program was:" >&5
2335 sed 's/^/| /' conftest.$ac_ext >&5
2336
2337 ac_retval=$ac_status
2338 fi
2339 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2340 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2341 as_fn_set_status $ac_retval
2342
2343 } # ac_fn_c_try_run
2344
2345 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
2346 # -------------------------------------------------------
2347 # Tests whether HEADER exists and can be compiled using the include files in
2348 # INCLUDES, setting the cache variable VAR accordingly.
2349 ac_fn_c_check_header_compile ()
2350 {
2351 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2353 $as_echo_n "checking for $2... " >&6; }
2354 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2355 $as_echo_n "(cached) " >&6
2356 else
2357 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2358 /* end confdefs.h. */
2359 $4
2360 #include <$2>
2361 _ACEOF
2362 if ac_fn_c_try_compile "$LINENO"; then :
2363 eval "$3=yes"
2364 else
2365 eval "$3=no"
2366 fi
2367 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2368 fi
2369 eval ac_res=\$$3
2370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2371 $as_echo "$ac_res" >&6; }
2372 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2373
2374 } # ac_fn_c_check_header_compile
2375
2376 # ac_fn_c_try_link LINENO
2377 # -----------------------
2378 # Try to link conftest.$ac_ext, and return whether this succeeded.
2379 ac_fn_c_try_link ()
2380 {
2381 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2382 rm -f conftest.$ac_objext conftest$ac_exeext
2383 if { { ac_try="$ac_link"
2384 case "(($ac_try" in
2385 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2386 *) ac_try_echo=$ac_try;;
2387 esac
2388 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2389 $as_echo "$ac_try_echo"; } >&5
2390 (eval "$ac_link") 2>conftest.err
2391 ac_status=$?
2392 if test -s conftest.err; then
2393 grep -v '^ *+' conftest.err >conftest.er1
2394 cat conftest.er1 >&5
2395 mv -f conftest.er1 conftest.err
2396 fi
2397 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2398 test $ac_status = 0; } && {
2399 test -z "$ac_c_werror_flag" ||
2400 test ! -s conftest.err
2401 } && test -s conftest$ac_exeext && {
2402 test "$cross_compiling" = yes ||
2403 $as_test_x conftest$ac_exeext
2404 }; then :
2405 ac_retval=0
2406 else
2407 $as_echo "$as_me: failed program was:" >&5
2408 sed 's/^/| /' conftest.$ac_ext >&5
2409
2410 ac_retval=1
2411 fi
2412 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
2413 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
2414 # interfere with the next link command; also delete a directory that is
2415 # left behind by Apple's compiler. We do this before executing the actions.
2416 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
2417 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2418 as_fn_set_status $ac_retval
2419
2420 } # ac_fn_c_try_link
2421
2422 # ac_fn_c_check_decl LINENO SYMBOL VAR
2423 # ------------------------------------
2424 # Tests whether SYMBOL is declared, setting cache variable VAR accordingly.
2425 ac_fn_c_check_decl ()
2426 {
2427 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $2 is declared" >&5
2429 $as_echo_n "checking whether $2 is declared... " >&6; }
2430 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2431 $as_echo_n "(cached) " >&6
2432 else
2433 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2434 /* end confdefs.h. */
2435 $4
2436 int
2437 main ()
2438 {
2439 #ifndef $2
2440 (void) $2;
2441 #endif
2442
2443 ;
2444 return 0;
2445 }
2446 _ACEOF
2447 if ac_fn_c_try_compile "$LINENO"; then :
2448 eval "$3=yes"
2449 else
2450 eval "$3=no"
2451 fi
2452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2453 fi
2454 eval ac_res=\$$3
2455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2456 $as_echo "$ac_res" >&6; }
2457 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2458
2459 } # ac_fn_c_check_decl
2460
2461 # ac_fn_c_check_header_preproc LINENO HEADER VAR
2462 # ----------------------------------------------
2463 # Tests whether HEADER is present, setting the cache variable VAR accordingly.
2464 ac_fn_c_check_header_preproc ()
2465 {
2466 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2468 $as_echo_n "checking for $2... " >&6; }
2469 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2470 $as_echo_n "(cached) " >&6
2471 else
2472 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2473 /* end confdefs.h. */
2474 #include <$2>
2475 _ACEOF
2476 if ac_fn_c_try_cpp "$LINENO"; then :
2477 eval "$3=yes"
2478 else
2479 eval "$3=no"
2480 fi
2481 rm -f conftest.err conftest.$ac_ext
2482 fi
2483 eval ac_res=\$$3
2484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2485 $as_echo "$ac_res" >&6; }
2486 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2487
2488 } # ac_fn_c_check_header_preproc
2489
2490 # ac_fn_c_check_func LINENO FUNC VAR
2491 # ----------------------------------
2492 # Tests whether FUNC exists, setting the cache variable VAR accordingly
2493 ac_fn_c_check_func ()
2494 {
2495 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2497 $as_echo_n "checking for $2... " >&6; }
2498 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2499 $as_echo_n "(cached) " >&6
2500 else
2501 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2502 /* end confdefs.h. */
2503 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
2504 For example, HP-UX 11i <limits.h> declares gettimeofday. */
2505 #define $2 innocuous_$2
2506
2507 /* System header to define __stub macros and hopefully few prototypes,
2508 which can conflict with char $2 (); below.
2509 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2510 <limits.h> exists even on freestanding compilers. */
2511
2512 #ifdef __STDC__
2513 # include <limits.h>
2514 #else
2515 # include <assert.h>
2516 #endif
2517
2518 #undef $2
2519
2520 /* Override any GCC internal prototype to avoid an error.
2521 Use char because int might match the return type of a GCC
2522 builtin and then its argument prototype would still apply. */
2523 #ifdef __cplusplus
2524 extern "C"
2525 #endif
2526 char $2 ();
2527 /* The GNU C library defines this for functions which it implements
2528 to always fail with ENOSYS. Some functions are actually named
2529 something starting with __ and the normal name is an alias. */
2530 #if defined __stub_$2 || defined __stub___$2
2531 choke me
2532 #endif
2533
2534 int
2535 main ()
2536 {
2537 return $2 ();
2538 ;
2539 return 0;
2540 }
2541 _ACEOF
2542 if ac_fn_c_try_link "$LINENO"; then :
2543 eval "$3=yes"
2544 else
2545 eval "$3=no"
2546 fi
2547 rm -f core conftest.err conftest.$ac_objext \
2548 conftest$ac_exeext conftest.$ac_ext
2549 fi
2550 eval ac_res=\$$3
2551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2552 $as_echo "$ac_res" >&6; }
2553 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2554
2555 } # ac_fn_c_check_func
2556
2557 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2558 # ----------------------------------------------------
2559 # Tries to find if the field MEMBER exists in type AGGR, after including
2560 # INCLUDES, setting cache variable VAR accordingly.
2561 ac_fn_c_check_member ()
2562 {
2563 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2565 $as_echo_n "checking for $2.$3... " >&6; }
2566 if { as_var=$4; eval "test \"\${$as_var+set}\" = set"; }; then :
2567 $as_echo_n "(cached) " >&6
2568 else
2569 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2570 /* end confdefs.h. */
2571 $5
2572 int
2573 main ()
2574 {
2575 static $2 ac_aggr;
2576 if (ac_aggr.$3)
2577 return 0;
2578 ;
2579 return 0;
2580 }
2581 _ACEOF
2582 if ac_fn_c_try_compile "$LINENO"; then :
2583 eval "$4=yes"
2584 else
2585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2586 /* end confdefs.h. */
2587 $5
2588 int
2589 main ()
2590 {
2591 static $2 ac_aggr;
2592 if (sizeof ac_aggr.$3)
2593 return 0;
2594 ;
2595 return 0;
2596 }
2597 _ACEOF
2598 if ac_fn_c_try_compile "$LINENO"; then :
2599 eval "$4=yes"
2600 else
2601 eval "$4=no"
2602 fi
2603 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2604 fi
2605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2606 fi
2607 eval ac_res=\$$4
2608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2609 $as_echo "$ac_res" >&6; }
2610 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2611
2612 } # ac_fn_c_check_member
2613
2614 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2615 # -------------------------------------------
2616 # Tests whether TYPE exists after having included INCLUDES, setting cache
2617 # variable VAR accordingly.
2618 ac_fn_c_check_type ()
2619 {
2620 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2622 $as_echo_n "checking for $2... " >&6; }
2623 if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then :
2624 $as_echo_n "(cached) " >&6
2625 else
2626 eval "$3=no"
2627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2628 /* end confdefs.h. */
2629 $4
2630 int
2631 main ()
2632 {
2633 if (sizeof ($2))
2634 return 0;
2635 ;
2636 return 0;
2637 }
2638 _ACEOF
2639 if ac_fn_c_try_compile "$LINENO"; then :
2640 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2641 /* end confdefs.h. */
2642 $4
2643 int
2644 main ()
2645 {
2646 if (sizeof (($2)))
2647 return 0;
2648 ;
2649 return 0;
2650 }
2651 _ACEOF
2652 if ac_fn_c_try_compile "$LINENO"; then :
2653
2654 else
2655 eval "$3=yes"
2656 fi
2657 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2658 fi
2659 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2660 fi
2661 eval ac_res=\$$3
2662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2663 $as_echo "$ac_res" >&6; }
2664 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2665
2666 } # ac_fn_c_check_type
2667
2668 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2669 # --------------------------------------------
2670 # Tries to find the compile-time value of EXPR in a program that includes
2671 # INCLUDES, setting VAR accordingly. Returns whether the value could be
2672 # computed
2673 ac_fn_c_compute_int ()
2674 {
2675 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2676 if test "$cross_compiling" = yes; then
2677 # Depending upon the size, compute the lo and hi bounds.
2678 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2679 /* end confdefs.h. */
2680 $4
2681 int
2682 main ()
2683 {
2684 static int test_array [1 - 2 * !(($2) >= 0)];
2685 test_array [0] = 0
2686
2687 ;
2688 return 0;
2689 }
2690 _ACEOF
2691 if ac_fn_c_try_compile "$LINENO"; then :
2692 ac_lo=0 ac_mid=0
2693 while :; do
2694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2695 /* end confdefs.h. */
2696 $4
2697 int
2698 main ()
2699 {
2700 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2701 test_array [0] = 0
2702
2703 ;
2704 return 0;
2705 }
2706 _ACEOF
2707 if ac_fn_c_try_compile "$LINENO"; then :
2708 ac_hi=$ac_mid; break
2709 else
2710 as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2711 if test $ac_lo -le $ac_mid; then
2712 ac_lo= ac_hi=
2713 break
2714 fi
2715 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2716 fi
2717 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2718 done
2719 else
2720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2721 /* end confdefs.h. */
2722 $4
2723 int
2724 main ()
2725 {
2726 static int test_array [1 - 2 * !(($2) < 0)];
2727 test_array [0] = 0
2728
2729 ;
2730 return 0;
2731 }
2732 _ACEOF
2733 if ac_fn_c_try_compile "$LINENO"; then :
2734 ac_hi=-1 ac_mid=-1
2735 while :; do
2736 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2737 /* end confdefs.h. */
2738 $4
2739 int
2740 main ()
2741 {
2742 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2743 test_array [0] = 0
2744
2745 ;
2746 return 0;
2747 }
2748 _ACEOF
2749 if ac_fn_c_try_compile "$LINENO"; then :
2750 ac_lo=$ac_mid; break
2751 else
2752 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2753 if test $ac_mid -le $ac_hi; then
2754 ac_lo= ac_hi=
2755 break
2756 fi
2757 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2758 fi
2759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2760 done
2761 else
2762 ac_lo= ac_hi=
2763 fi
2764 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2765 fi
2766 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2767 # Binary search between lo and hi bounds.
2768 while test "x$ac_lo" != "x$ac_hi"; do
2769 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2771 /* end confdefs.h. */
2772 $4
2773 int
2774 main ()
2775 {
2776 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2777 test_array [0] = 0
2778
2779 ;
2780 return 0;
2781 }
2782 _ACEOF
2783 if ac_fn_c_try_compile "$LINENO"; then :
2784 ac_hi=$ac_mid
2785 else
2786 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2787 fi
2788 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2789 done
2790 case $ac_lo in #((
2791 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2792 '') ac_retval=1 ;;
2793 esac
2794 else
2795 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2796 /* end confdefs.h. */
2797 $4
2798 static long int longval () { return $2; }
2799 static unsigned long int ulongval () { return $2; }
2800 #include <stdio.h>
2801 #include <stdlib.h>
2802 int
2803 main ()
2804 {
2805
2806 FILE *f = fopen ("conftest.val", "w");
2807 if (! f)
2808 return 1;
2809 if (($2) < 0)
2810 {
2811 long int i = longval ();
2812 if (i != ($2))
2813 return 1;
2814 fprintf (f, "%ld", i);
2815 }
2816 else
2817 {
2818 unsigned long int i = ulongval ();
2819 if (i != ($2))
2820 return 1;
2821 fprintf (f, "%lu", i);
2822 }
2823 /* Do not output a trailing newline, as this causes \r\n confusion
2824 on some platforms. */
2825 return ferror (f) || fclose (f) != 0;
2826
2827 ;
2828 return 0;
2829 }
2830 _ACEOF
2831 if ac_fn_c_try_run "$LINENO"; then :
2832 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2833 else
2834 ac_retval=1
2835 fi
2836 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2837 conftest.$ac_objext conftest.beam conftest.$ac_ext
2838 rm -f conftest.val
2839
2840 fi
2841 eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2842 as_fn_set_status $ac_retval
2843
2844 } # ac_fn_c_compute_int
2845 cat >config.log <<_ACEOF
2846 This file contains any messages produced by compilers while
2847 running configure, to aid debugging if configure makes a mistake.
2848
2849 It was created by emacs $as_me 24.1.50, which was
2850 generated by GNU Autoconf 2.65. Invocation command line was
2851
2852 $ $0 $@
2853
2854 _ACEOF
2855 exec 5>>config.log
2856 {
2857 cat <<_ASUNAME
2858 ## --------- ##
2859 ## Platform. ##
2860 ## --------- ##
2861
2862 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2863 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2864 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2865 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2866 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2867
2868 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2869 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2870
2871 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2872 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2873 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2874 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2875 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2876 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2877 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2878
2879 _ASUNAME
2880
2881 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2882 for as_dir in $PATH
2883 do
2884 IFS=$as_save_IFS
2885 test -z "$as_dir" && as_dir=.
2886 $as_echo "PATH: $as_dir"
2887 done
2888 IFS=$as_save_IFS
2889
2890 } >&5
2891
2892 cat >&5 <<_ACEOF
2893
2894
2895 ## ----------- ##
2896 ## Core tests. ##
2897 ## ----------- ##
2898
2899 _ACEOF
2900
2901
2902 # Keep a trace of the command line.
2903 # Strip out --no-create and --no-recursion so they do not pile up.
2904 # Strip out --silent because we don't want to record it for future runs.
2905 # Also quote any args containing shell meta-characters.
2906 # Make two passes to allow for proper duplicate-argument suppression.
2907 ac_configure_args=
2908 ac_configure_args0=
2909 ac_configure_args1=
2910 ac_must_keep_next=false
2911 for ac_pass in 1 2
2912 do
2913 for ac_arg
2914 do
2915 case $ac_arg in
2916 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2917 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2918 | -silent | --silent | --silen | --sile | --sil)
2919 continue ;;
2920 *\'*)
2921 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2922 esac
2923 case $ac_pass in
2924 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2925 2)
2926 as_fn_append ac_configure_args1 " '$ac_arg'"
2927 if test $ac_must_keep_next = true; then
2928 ac_must_keep_next=false # Got value, back to normal.
2929 else
2930 case $ac_arg in
2931 *=* | --config-cache | -C | -disable-* | --disable-* \
2932 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2933 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2934 | -with-* | --with-* | -without-* | --without-* | --x)
2935 case "$ac_configure_args0 " in
2936 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2937 esac
2938 ;;
2939 -* ) ac_must_keep_next=true ;;
2940 esac
2941 fi
2942 as_fn_append ac_configure_args " '$ac_arg'"
2943 ;;
2944 esac
2945 done
2946 done
2947 { ac_configure_args0=; unset ac_configure_args0;}
2948 { ac_configure_args1=; unset ac_configure_args1;}
2949
2950 # When interrupted or exit'd, cleanup temporary files, and complete
2951 # config.log. We remove comments because anyway the quotes in there
2952 # would cause problems or look ugly.
2953 # WARNING: Use '\'' to represent an apostrophe within the trap.
2954 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2955 trap 'exit_status=$?
2956 # Save into config.log some information that might help in debugging.
2957 {
2958 echo
2959
2960 cat <<\_ASBOX
2961 ## ---------------- ##
2962 ## Cache variables. ##
2963 ## ---------------- ##
2964 _ASBOX
2965 echo
2966 # The following way of writing the cache mishandles newlines in values,
2967 (
2968 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2969 eval ac_val=\$$ac_var
2970 case $ac_val in #(
2971 *${as_nl}*)
2972 case $ac_var in #(
2973 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2974 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2975 esac
2976 case $ac_var in #(
2977 _ | IFS | as_nl) ;; #(
2978 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2979 *) { eval $ac_var=; unset $ac_var;} ;;
2980 esac ;;
2981 esac
2982 done
2983 (set) 2>&1 |
2984 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2985 *${as_nl}ac_space=\ *)
2986 sed -n \
2987 "s/'\''/'\''\\\\'\'''\''/g;
2988 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2989 ;; #(
2990 *)
2991 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2992 ;;
2993 esac |
2994 sort
2995 )
2996 echo
2997
2998 cat <<\_ASBOX
2999 ## ----------------- ##
3000 ## Output variables. ##
3001 ## ----------------- ##
3002 _ASBOX
3003 echo
3004 for ac_var in $ac_subst_vars
3005 do
3006 eval ac_val=\$$ac_var
3007 case $ac_val in
3008 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3009 esac
3010 $as_echo "$ac_var='\''$ac_val'\''"
3011 done | sort
3012 echo
3013
3014 if test -n "$ac_subst_files"; then
3015 cat <<\_ASBOX
3016 ## ------------------- ##
3017 ## File substitutions. ##
3018 ## ------------------- ##
3019 _ASBOX
3020 echo
3021 for ac_var in $ac_subst_files
3022 do
3023 eval ac_val=\$$ac_var
3024 case $ac_val in
3025 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
3026 esac
3027 $as_echo "$ac_var='\''$ac_val'\''"
3028 done | sort
3029 echo
3030 fi
3031
3032 if test -s confdefs.h; then
3033 cat <<\_ASBOX
3034 ## ----------- ##
3035 ## confdefs.h. ##
3036 ## ----------- ##
3037 _ASBOX
3038 echo
3039 cat confdefs.h
3040 echo
3041 fi
3042 test "$ac_signal" != 0 &&
3043 $as_echo "$as_me: caught signal $ac_signal"
3044 $as_echo "$as_me: exit $exit_status"
3045 } >&5
3046 rm -f core *.core core.conftest.* &&
3047 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
3048 exit $exit_status
3049 ' 0
3050 for ac_signal in 1 2 13 15; do
3051 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
3052 done
3053 ac_signal=0
3054
3055 # confdefs.h avoids OS command line length limits that DEFS can exceed.
3056 rm -f -r conftest* confdefs.h
3057
3058 $as_echo "/* confdefs.h */" > confdefs.h
3059
3060 # Predefined preprocessor variables.
3061
3062 cat >>confdefs.h <<_ACEOF
3063 #define PACKAGE_NAME "$PACKAGE_NAME"
3064 _ACEOF
3065
3066 cat >>confdefs.h <<_ACEOF
3067 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
3068 _ACEOF
3069
3070 cat >>confdefs.h <<_ACEOF
3071 #define PACKAGE_VERSION "$PACKAGE_VERSION"
3072 _ACEOF
3073
3074 cat >>confdefs.h <<_ACEOF
3075 #define PACKAGE_STRING "$PACKAGE_STRING"
3076 _ACEOF
3077
3078 cat >>confdefs.h <<_ACEOF
3079 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
3080 _ACEOF
3081
3082 cat >>confdefs.h <<_ACEOF
3083 #define PACKAGE_URL "$PACKAGE_URL"
3084 _ACEOF
3085
3086
3087 # Let the site file select an alternate cache file if it wants to.
3088 # Prefer an explicitly selected file to automatically selected ones.
3089 ac_site_file1=NONE
3090 ac_site_file2=NONE
3091 if test -n "$CONFIG_SITE"; then
3092 ac_site_file1=$CONFIG_SITE
3093 elif test "x$prefix" != xNONE; then
3094 ac_site_file1=$prefix/share/config.site
3095 ac_site_file2=$prefix/etc/config.site
3096 else
3097 ac_site_file1=$ac_default_prefix/share/config.site
3098 ac_site_file2=$ac_default_prefix/etc/config.site
3099 fi
3100 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
3101 do
3102 test "x$ac_site_file" = xNONE && continue
3103 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
3104 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
3105 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
3106 sed 's/^/| /' "$ac_site_file" >&5
3107 . "$ac_site_file"
3108 fi
3109 done
3110
3111 if test -r "$cache_file"; then
3112 # Some versions of bash will fail to source /dev/null (special files
3113 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
3114 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
3115 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
3116 $as_echo "$as_me: loading cache $cache_file" >&6;}
3117 case $cache_file in
3118 [\\/]* | ?:[\\/]* ) . "$cache_file";;
3119 *) . "./$cache_file";;
3120 esac
3121 fi
3122 else
3123 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
3124 $as_echo "$as_me: creating cache $cache_file" >&6;}
3125 >$cache_file
3126 fi
3127
3128 as_fn_append ac_header_list " stdlib.h"
3129 as_fn_append ac_header_list " unistd.h"
3130 as_fn_append ac_header_list " sys/param.h"
3131 as_fn_append ac_func_list " readlinkat"
3132 gl_getopt_required=GNU
3133 as_fn_append ac_header_list " getopt.h"
3134 as_fn_append ac_header_list " wchar.h"
3135 as_fn_append ac_header_list " stdint.h"
3136 as_fn_append ac_header_list " inttypes.h"
3137 as_fn_append ac_func_list " lstat"
3138 as_fn_append ac_func_list " alarm"
3139 as_fn_append ac_func_list " pthread_sigmask"
3140 as_fn_append ac_func_list " readlink"
3141 as_fn_append ac_header_list " sys/socket.h"
3142 as_fn_append ac_func_list " tzset"
3143 as_fn_append ac_func_list " strtoimax"
3144 as_fn_append ac_func_list " strtoumax"
3145 as_fn_append ac_func_list " symlink"
3146 as_fn_append ac_header_list " sys/stat.h"
3147 as_fn_append ac_header_list " sys/time.h"
3148 as_fn_append ac_func_list " localtime_r"
3149 # Check that the precious variables saved in the cache have kept the same
3150 # value.
3151 ac_cache_corrupted=false
3152 for ac_var in $ac_precious_vars; do
3153 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3154 eval ac_new_set=\$ac_env_${ac_var}_set
3155 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3156 eval ac_new_val=\$ac_env_${ac_var}_value
3157 case $ac_old_set,$ac_new_set in
3158 set,)
3159 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
3160 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
3161 ac_cache_corrupted=: ;;
3162 ,set)
3163 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
3164 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
3165 ac_cache_corrupted=: ;;
3166 ,);;
3167 *)
3168 if test "x$ac_old_val" != "x$ac_new_val"; then
3169 # differences in whitespace do not lead to failure.
3170 ac_old_val_w=`echo x $ac_old_val`
3171 ac_new_val_w=`echo x $ac_new_val`
3172 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3173 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
3174 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
3175 ac_cache_corrupted=:
3176 else
3177 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
3178 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
3179 eval $ac_var=\$ac_old_val
3180 fi
3181 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5
3182 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;}
3183 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5
3184 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;}
3185 fi;;
3186 esac
3187 # Pass precious variables to config.status.
3188 if test "$ac_new_set" = set; then
3189 case $ac_new_val in
3190 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3191 *) ac_arg=$ac_var=$ac_new_val ;;
3192 esac
3193 case " $ac_configure_args " in
3194 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3195 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3196 esac
3197 fi
3198 done
3199 if $ac_cache_corrupted; then
3200 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3201 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3202 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3203 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
3204 as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
3205 fi
3206 ## -------------------- ##
3207 ## Main body of script. ##
3208 ## -------------------- ##
3209
3210 ac_ext=c
3211 ac_cpp='$CPP $CPPFLAGS'
3212 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3213 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3214 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3215
3216
3217 ac_config_headers="$ac_config_headers src/config.h:src/config.in"
3218
3219
3220 ac_aux_dir=
3221 for ac_dir in build-aux "$srcdir"/build-aux; do
3222 for ac_t in install-sh install.sh shtool; do
3223 if test -f "$ac_dir/$ac_t"; then
3224 ac_aux_dir=$ac_dir
3225 ac_install_sh="$ac_aux_dir/$ac_t -c"
3226 break 2
3227 fi
3228 done
3229 done
3230 if test -z "$ac_aux_dir"; then
3231 as_fn_error "cannot find install-sh, install.sh, or shtool in build-aux \"$srcdir\"/build-aux" "$LINENO" 5
3232 fi
3233
3234 # These three variables are undocumented and unsupported,
3235 # and are intended to be withdrawn in a future Autoconf release.
3236 # They can cause serious problems if a builder's source tree is in a directory
3237 # whose full name contains unusual characters.
3238 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var.
3239 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var.
3240 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var.
3241
3242
3243 am__api_version='1.11'
3244
3245 # Find a good install program. We prefer a C program (faster),
3246 # so one script is as good as another. But avoid the broken or
3247 # incompatible versions:
3248 # SysV /etc/install, /usr/sbin/install
3249 # SunOS /usr/etc/install
3250 # IRIX /sbin/install
3251 # AIX /bin/install
3252 # AmigaOS /C/install, which installs bootblocks on floppy discs
3253 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
3254 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
3255 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
3256 # OS/2's system install, which has a completely different semantic
3257 # ./install, which can be erroneously created by make from ./install.sh.
3258 # Reject install programs that cannot install multiple files.
3259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
3260 $as_echo_n "checking for a BSD-compatible install... " >&6; }
3261 if test -z "$INSTALL"; then
3262 if test "${ac_cv_path_install+set}" = set; then :
3263 $as_echo_n "(cached) " >&6
3264 else
3265 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3266 for as_dir in $PATH
3267 do
3268 IFS=$as_save_IFS
3269 test -z "$as_dir" && as_dir=.
3270 # Account for people who put trailing slashes in PATH elements.
3271 case $as_dir/ in #((
3272 ./ | .// | /[cC]/* | \
3273 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
3274 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
3275 /usr/ucb/* ) ;;
3276 *)
3277 # OSF1 and SCO ODT 3.0 have their own names for install.
3278 # Don't use installbsd from OSF since it installs stuff as root
3279 # by default.
3280 for ac_prog in ginstall scoinst install; do
3281 for ac_exec_ext in '' $ac_executable_extensions; do
3282 if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
3283 if test $ac_prog = install &&
3284 grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3285 # AIX install. It has an incompatible calling convention.
3286 :
3287 elif test $ac_prog = install &&
3288 grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
3289 # program-specific install script used by HP pwplus--don't use.
3290 :
3291 else
3292 rm -rf conftest.one conftest.two conftest.dir
3293 echo one > conftest.one
3294 echo two > conftest.two
3295 mkdir conftest.dir
3296 if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
3297 test -s conftest.one && test -s conftest.two &&
3298 test -s conftest.dir/conftest.one &&
3299 test -s conftest.dir/conftest.two
3300 then
3301 ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
3302 break 3
3303 fi
3304 fi
3305 fi
3306 done
3307 done
3308 ;;
3309 esac
3310
3311 done
3312 IFS=$as_save_IFS
3313
3314 rm -rf conftest.one conftest.two conftest.dir
3315
3316 fi
3317 if test "${ac_cv_path_install+set}" = set; then
3318 INSTALL=$ac_cv_path_install
3319 else
3320 # As a last resort, use the slow shell script. Don't cache a
3321 # value for INSTALL within a source directory, because that will
3322 # break other packages using the cache if that directory is
3323 # removed, or if the value is a relative name.
3324 INSTALL=$ac_install_sh
3325 fi
3326 fi
3327 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
3328 $as_echo "$INSTALL" >&6; }
3329
3330 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
3331 # It thinks the first close brace ends the variable substitution.
3332 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
3333
3334 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
3335
3336 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
3337
3338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether build environment is sane" >&5
3339 $as_echo_n "checking whether build environment is sane... " >&6; }
3340 # Just in case
3341 sleep 1
3342 echo timestamp > conftest.file
3343 # Reject unsafe characters in $srcdir or the absolute working directory
3344 # name. Accept space and tab only in the latter.
3345 am_lf='
3346 '
3347 case `pwd` in
3348 *[\\\"\#\$\&\'\`$am_lf]*)
3349 as_fn_error "unsafe absolute working directory name" "$LINENO" 5;;
3350 esac
3351 case $srcdir in
3352 *[\\\"\#\$\&\'\`$am_lf\ \ ]*)
3353 as_fn_error "unsafe srcdir value: \`$srcdir'" "$LINENO" 5;;
3354 esac
3355
3356 # Do `set' in a subshell so we don't clobber the current shell's
3357 # arguments. Must try -L first in case configure is actually a
3358 # symlink; some systems play weird games with the mod time of symlinks
3359 # (eg FreeBSD returns the mod time of the symlink's containing
3360 # directory).
3361 if (
3362 set X `ls -Lt "$srcdir/configure" conftest.file 2> /dev/null`
3363 if test "$*" = "X"; then
3364 # -L didn't work.
3365 set X `ls -t "$srcdir/configure" conftest.file`
3366 fi
3367 rm -f conftest.file
3368 if test "$*" != "X $srcdir/configure conftest.file" \
3369 && test "$*" != "X conftest.file $srcdir/configure"; then
3370
3371 # If neither matched, then we have a broken ls. This can happen
3372 # if, for instance, CONFIG_SHELL is bash and it inherits a
3373 # broken ls alias from the environment. This has actually
3374 # happened. Such a system could not be considered "sane".
3375 as_fn_error "ls -t appears to fail. Make sure there is not a broken
3376 alias in your environment" "$LINENO" 5
3377 fi
3378
3379 test "$2" = conftest.file
3380 )
3381 then
3382 # Ok.
3383 :
3384 else
3385 as_fn_error "newly created file is older than distributed files!
3386 Check your system clock" "$LINENO" 5
3387 fi
3388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3389 $as_echo "yes" >&6; }
3390 test "$program_prefix" != NONE &&
3391 program_transform_name="s&^&$program_prefix&;$program_transform_name"
3392 # Use a double $ so make ignores it.
3393 test "$program_suffix" != NONE &&
3394 program_transform_name="s&\$&$program_suffix&;$program_transform_name"
3395 # Double any \ or $.
3396 # By default was `s,x,x', remove it if useless.
3397 ac_script='s/[\\$]/&&/g;s/;s,x,x,$//'
3398 program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"`
3399
3400 # expand $ac_aux_dir to an absolute path
3401 am_aux_dir=`cd $ac_aux_dir && pwd`
3402
3403 if test x"${MISSING+set}" != xset; then
3404 case $am_aux_dir in
3405 *\ * | *\ *)
3406 MISSING="\${SHELL} \"$am_aux_dir/missing\"" ;;
3407 *)
3408 MISSING="\${SHELL} $am_aux_dir/missing" ;;
3409 esac
3410 fi
3411 # Use eval to expand $SHELL
3412 if eval "$MISSING --run true"; then
3413 am_missing_run="$MISSING --run "
3414 else
3415 am_missing_run=
3416 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`missing' script is too old or missing" >&5
3417 $as_echo "$as_me: WARNING: \`missing' script is too old or missing" >&2;}
3418 fi
3419
3420 if test x"${install_sh}" != xset; then
3421 case $am_aux_dir in
3422 *\ * | *\ *)
3423 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
3424 *)
3425 install_sh="\${SHELL} $am_aux_dir/install-sh"
3426 esac
3427 fi
3428
3429 # Installed binaries are usually stripped using `strip' when the user
3430 # run `make install-strip'. However `strip' might not be the right
3431 # tool to use in cross-compilation environments, therefore Automake
3432 # will honor the `STRIP' environment variable to overrule this program.
3433 if test "$cross_compiling" != no; then
3434 if test -n "$ac_tool_prefix"; then
3435 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
3436 set dummy ${ac_tool_prefix}strip; ac_word=$2
3437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3438 $as_echo_n "checking for $ac_word... " >&6; }
3439 if test "${ac_cv_prog_STRIP+set}" = set; then :
3440 $as_echo_n "(cached) " >&6
3441 else
3442 if test -n "$STRIP"; then
3443 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
3444 else
3445 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3446 for as_dir in $PATH
3447 do
3448 IFS=$as_save_IFS
3449 test -z "$as_dir" && as_dir=.
3450 for ac_exec_ext in '' $ac_executable_extensions; do
3451 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3452 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
3453 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3454 break 2
3455 fi
3456 done
3457 done
3458 IFS=$as_save_IFS
3459
3460 fi
3461 fi
3462 STRIP=$ac_cv_prog_STRIP
3463 if test -n "$STRIP"; then
3464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
3465 $as_echo "$STRIP" >&6; }
3466 else
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3468 $as_echo "no" >&6; }
3469 fi
3470
3471
3472 fi
3473 if test -z "$ac_cv_prog_STRIP"; then
3474 ac_ct_STRIP=$STRIP
3475 # Extract the first word of "strip", so it can be a program name with args.
3476 set dummy strip; ac_word=$2
3477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3478 $as_echo_n "checking for $ac_word... " >&6; }
3479 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then :
3480 $as_echo_n "(cached) " >&6
3481 else
3482 if test -n "$ac_ct_STRIP"; then
3483 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
3484 else
3485 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3486 for as_dir in $PATH
3487 do
3488 IFS=$as_save_IFS
3489 test -z "$as_dir" && as_dir=.
3490 for ac_exec_ext in '' $ac_executable_extensions; do
3491 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3492 ac_cv_prog_ac_ct_STRIP="strip"
3493 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3494 break 2
3495 fi
3496 done
3497 done
3498 IFS=$as_save_IFS
3499
3500 fi
3501 fi
3502 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
3503 if test -n "$ac_ct_STRIP"; then
3504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
3505 $as_echo "$ac_ct_STRIP" >&6; }
3506 else
3507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3508 $as_echo "no" >&6; }
3509 fi
3510
3511 if test "x$ac_ct_STRIP" = x; then
3512 STRIP=":"
3513 else
3514 case $cross_compiling:$ac_tool_warned in
3515 yes:)
3516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
3517 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3518 ac_tool_warned=yes ;;
3519 esac
3520 STRIP=$ac_ct_STRIP
3521 fi
3522 else
3523 STRIP="$ac_cv_prog_STRIP"
3524 fi
3525
3526 fi
3527 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
3528
3529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a thread-safe mkdir -p" >&5
3530 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
3531 if test -z "$MKDIR_P"; then
3532 if test "${ac_cv_path_mkdir+set}" = set; then :
3533 $as_echo_n "(cached) " >&6
3534 else
3535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3536 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
3537 do
3538 IFS=$as_save_IFS
3539 test -z "$as_dir" && as_dir=.
3540 for ac_prog in mkdir gmkdir; do
3541 for ac_exec_ext in '' $ac_executable_extensions; do
3542 { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
3543 case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
3544 'mkdir (GNU coreutils) '* | \
3545 'mkdir (coreutils) '* | \
3546 'mkdir (fileutils) '4.1*)
3547 ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
3548 break 3;;
3549 esac
3550 done
3551 done
3552 done
3553 IFS=$as_save_IFS
3554
3555 fi
3556
3557 test -d ./--version && rmdir ./--version
3558 if test "${ac_cv_path_mkdir+set}" = set; then
3559 MKDIR_P="$ac_cv_path_mkdir -p"
3560 else
3561 # As a last resort, use the slow shell script. Don't cache a
3562 # value for MKDIR_P within a source directory, because that will
3563 # break other packages using the cache if that directory is
3564 # removed, or if the value is a relative name.
3565 MKDIR_P="$ac_install_sh -d"
3566 fi
3567 fi
3568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
3569 $as_echo "$MKDIR_P" >&6; }
3570
3571
3572 mkdir_p="$MKDIR_P"
3573 case $mkdir_p in
3574 [\\/$]* | ?:[\\/]*) ;;
3575 */*) mkdir_p="\$(top_builddir)/$mkdir_p" ;;
3576 esac
3577
3578 for ac_prog in gawk mawk nawk awk
3579 do
3580 # Extract the first word of "$ac_prog", so it can be a program name with args.
3581 set dummy $ac_prog; ac_word=$2
3582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3583 $as_echo_n "checking for $ac_word... " >&6; }
3584 if test "${ac_cv_prog_AWK+set}" = set; then :
3585 $as_echo_n "(cached) " >&6
3586 else
3587 if test -n "$AWK"; then
3588 ac_cv_prog_AWK="$AWK" # Let the user override the test.
3589 else
3590 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3591 for as_dir in $PATH
3592 do
3593 IFS=$as_save_IFS
3594 test -z "$as_dir" && as_dir=.
3595 for ac_exec_ext in '' $ac_executable_extensions; do
3596 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3597 ac_cv_prog_AWK="$ac_prog"
3598 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
3599 break 2
3600 fi
3601 done
3602 done
3603 IFS=$as_save_IFS
3604
3605 fi
3606 fi
3607 AWK=$ac_cv_prog_AWK
3608 if test -n "$AWK"; then
3609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
3610 $as_echo "$AWK" >&6; }
3611 else
3612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3613 $as_echo "no" >&6; }
3614 fi
3615
3616
3617 test -n "$AWK" && break
3618 done
3619
3620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
3621 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
3622 set x ${MAKE-make}
3623 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
3624 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
3625 $as_echo_n "(cached) " >&6
3626 else
3627 cat >conftest.make <<\_ACEOF
3628 SHELL = /bin/sh
3629 all:
3630 @echo '@@@%%%=$(MAKE)=@@@%%%'
3631 _ACEOF
3632 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
3633 case `${MAKE-make} -f conftest.make 2>/dev/null` in
3634 *@@@%%%=?*=@@@%%%*)
3635 eval ac_cv_prog_make_${ac_make}_set=yes;;
3636 *)
3637 eval ac_cv_prog_make_${ac_make}_set=no;;
3638 esac
3639 rm -f conftest.make
3640 fi
3641 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
3642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
3643 $as_echo "yes" >&6; }
3644 SET_MAKE=
3645 else
3646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
3647 $as_echo "no" >&6; }
3648 SET_MAKE="MAKE=${MAKE-make}"
3649 fi
3650
3651 rm -rf .tst 2>/dev/null
3652 mkdir .tst 2>/dev/null
3653 if test -d .tst; then
3654 am__leading_dot=.
3655 else
3656 am__leading_dot=_
3657 fi
3658 rmdir .tst 2>/dev/null
3659
3660 if test "`cd $srcdir && pwd`" != "`pwd`"; then
3661 # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
3662 # is not polluted with repeated "-I."
3663 am__isrc=' -I$(srcdir)'
3664 # test to see if srcdir already configured
3665 if test -f $srcdir/config.status; then
3666 as_fn_error "source directory already configured; run \"make distclean\" there first" "$LINENO" 5
3667 fi
3668 fi
3669
3670 # test whether we have cygpath
3671 if test -z "$CYGPATH_W"; then
3672 if (cygpath --version) >/dev/null 2>/dev/null; then
3673 CYGPATH_W='cygpath -w'
3674 else
3675 CYGPATH_W=echo
3676 fi
3677 fi
3678
3679
3680 # Define the identity of the package.
3681 PACKAGE='emacs'
3682 VERSION='24.1.50'
3683
3684
3685 cat >>confdefs.h <<_ACEOF
3686 #define PACKAGE "$PACKAGE"
3687 _ACEOF
3688
3689
3690 cat >>confdefs.h <<_ACEOF
3691 #define VERSION "$VERSION"
3692 _ACEOF
3693
3694 # Some tools Automake needs.
3695
3696 ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal-${am__api_version}"}
3697
3698
3699 AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
3700
3701
3702 AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake-${am__api_version}"}
3703
3704
3705 AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
3706
3707
3708 MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
3709
3710 # We need awk for the "check" target. The system "awk" is bad on
3711 # some platforms.
3712 # Always define AMTAR for backward compatibility.
3713
3714 AMTAR=${AMTAR-"${am_missing_run}tar"}
3715
3716 am__tar='${AMTAR} chof - "$$tardir"'; am__untar='${AMTAR} xf -'
3717
3718
3719
3720
3721
3722
3723
3724
3725 lispdir='${datadir}/emacs/${version}/lisp'
3726 locallisppath='${datadir}/emacs/${version}/site-lisp:'\
3727 '${datadir}/emacs/site-lisp'
3728 lisppath='${locallisppath}:${lispdir}:${datadir}/emacs/${version}/leim'
3729 etcdir='${datadir}/emacs/${version}/etc'
3730 archlibdir='${libexecdir}/emacs/${version}/${configuration}'
3731 docdir='${datadir}/emacs/${version}/etc'
3732 gamedir='${localstatedir}/games/emacs'
3733
3734
3735
3736
3737 # Check whether --with-pop was given.
3738 if test "${with_pop+set}" = set; then :
3739 withval=$with_pop;
3740 else
3741 with_pop=yes
3742 fi
3743
3744 if test "$with_pop" = yes; then
3745 $as_echo "#define MAIL_USE_POP 1" >>confdefs.h
3746
3747 fi
3748
3749
3750 # Check whether --with-kerberos was given.
3751 if test "${with_kerberos+set}" = set; then :
3752 withval=$with_kerberos;
3753 else
3754 with_kerberos=no
3755 fi
3756
3757 if test "$with_kerberos" != no; then
3758 $as_echo "#define KERBEROS 1" >>confdefs.h
3759
3760 fi
3761
3762
3763 # Check whether --with-kerberos5 was given.
3764 if test "${with_kerberos5+set}" = set; then :
3765 withval=$with_kerberos5;
3766 else
3767 with_kerberos5=no
3768 fi
3769
3770 if test "${with_kerberos5}" != no; then
3771 if test "${with_kerberos}" = no; then
3772 with_kerberos=yes
3773 $as_echo "#define KERBEROS 1" >>confdefs.h
3774
3775 fi
3776
3777 $as_echo "#define KERBEROS5 1" >>confdefs.h
3778
3779 fi
3780
3781
3782 # Check whether --with-hesiod was given.
3783 if test "${with_hesiod+set}" = set; then :
3784 withval=$with_hesiod;
3785 else
3786 with_hesiod=no
3787 fi
3788
3789 if test "$with_hesiod" != no; then
3790
3791 $as_echo "#define HESIOD 1" >>confdefs.h
3792
3793 fi
3794
3795
3796 # Check whether --with-mmdf was given.
3797 if test "${with_mmdf+set}" = set; then :
3798 withval=$with_mmdf;
3799 else
3800 with_mmdf=no
3801 fi
3802
3803 if test "$with_mmdf" != no; then
3804
3805 $as_echo "#define MAIL_USE_MMDF 1" >>confdefs.h
3806
3807 fi
3808
3809
3810 # Check whether --with-mail-unlink was given.
3811 if test "${with_mail_unlink+set}" = set; then :
3812 withval=$with_mail_unlink;
3813 else
3814 with_mail_unlink=no
3815 fi
3816
3817 if test "$with_mail_unlink" != no; then
3818
3819 $as_echo "#define MAIL_UNLINK_SPOOL 1" >>confdefs.h
3820
3821 fi
3822
3823
3824 # Check whether --with-mailhost was given.
3825 if test "${with_mailhost+set}" = set; then :
3826 withval=$with_mailhost;
3827 cat >>confdefs.h <<_ACEOF
3828 #define MAILHOST "$withval"
3829 _ACEOF
3830
3831 fi
3832
3833
3834
3835 # Check whether --with-sound was given.
3836 if test "${with_sound+set}" = set; then :
3837 withval=$with_sound;
3838 else
3839 with_sound=yes
3840 fi
3841
3842
3843
3844 # Check whether --with-sync-input was given.
3845 if test "${with_sync_input+set}" = set; then :
3846 withval=$with_sync_input;
3847 else
3848 with_sync_input=yes
3849 fi
3850
3851 if test "$with_sync_input" = yes; then
3852
3853 $as_echo "#define SYNC_INPUT 1" >>confdefs.h
3854
3855 fi
3856
3857
3858 # Check whether --with-x-toolkit was given.
3859 if test "${with_x_toolkit+set}" = set; then :
3860 withval=$with_x_toolkit; case "${withval}" in
3861 y | ye | yes ) val=gtk ;;
3862 n | no ) val=no ;;
3863 l | lu | luc | luci | lucid ) val=lucid ;;
3864 a | at | ath | athe | athen | athena ) val=athena ;;
3865 m | mo | mot | moti | motif ) val=motif ;;
3866 g | gt | gtk ) val=gtk ;;
3867 gtk3 ) val=gtk3 ;;
3868 * )
3869 as_fn_error "\`--with-x-toolkit=$withval' is invalid;
3870 this option's value should be \`yes', \`no', \`lucid', \`athena', \`motif', \`gtk' or
3871 \`gtk3'. \`yes' and \`gtk' are synonyms. \`athena' and \`lucid' are synonyms." "$LINENO" 5
3872 ;;
3873 esac
3874 with_x_toolkit=$val
3875
3876 fi
3877
3878
3879
3880 # Check whether --with-wide-int was given.
3881 if test "${with_wide_int+set}" = set; then :
3882 withval=$with_wide_int;
3883 else
3884 with_wide_int=no
3885 fi
3886
3887 if test "$with_wide_int" = yes; then
3888
3889 $as_echo "#define WIDE_EMACS_INT 1" >>confdefs.h
3890
3891 fi
3892
3893
3894 # Check whether --with-xpm was given.
3895 if test "${with_xpm+set}" = set; then :
3896 withval=$with_xpm;
3897 else
3898 with_xpm=yes
3899 fi
3900
3901
3902 # Check whether --with-jpeg was given.
3903 if test "${with_jpeg+set}" = set; then :
3904 withval=$with_jpeg;
3905 else
3906 with_jpeg=yes
3907 fi
3908
3909
3910 # Check whether --with-tiff was given.
3911 if test "${with_tiff+set}" = set; then :
3912 withval=$with_tiff;
3913 else
3914 with_tiff=yes
3915 fi
3916
3917
3918 # Check whether --with-gif was given.
3919 if test "${with_gif+set}" = set; then :
3920 withval=$with_gif;
3921 else
3922 with_gif=yes
3923 fi
3924
3925
3926 # Check whether --with-png was given.
3927 if test "${with_png+set}" = set; then :
3928 withval=$with_png;
3929 else
3930 with_png=yes
3931 fi
3932
3933
3934 # Check whether --with-rsvg was given.
3935 if test "${with_rsvg+set}" = set; then :
3936 withval=$with_rsvg;
3937 else
3938 with_rsvg=yes
3939 fi
3940
3941
3942 # Check whether --with-xml2 was given.
3943 if test "${with_xml2+set}" = set; then :
3944 withval=$with_xml2;
3945 else
3946 with_xml2=yes
3947 fi
3948
3949
3950 # Check whether --with-imagemagick was given.
3951 if test "${with_imagemagick+set}" = set; then :
3952 withval=$with_imagemagick;
3953 else
3954 with_imagemagick=yes
3955 fi
3956
3957
3958
3959 # Check whether --with-xft was given.
3960 if test "${with_xft+set}" = set; then :
3961 withval=$with_xft;
3962 else
3963 with_xft=yes
3964 fi
3965
3966
3967 # Check whether --with-libotf was given.
3968 if test "${with_libotf+set}" = set; then :
3969 withval=$with_libotf;
3970 else
3971 with_libotf=yes
3972 fi
3973
3974
3975 # Check whether --with-m17n-flt was given.
3976 if test "${with_m17n_flt+set}" = set; then :
3977 withval=$with_m17n_flt;
3978 else
3979 with_m17n_flt=yes
3980 fi
3981
3982
3983
3984 # Check whether --with-toolkit-scroll-bars was given.
3985 if test "${with_toolkit_scroll_bars+set}" = set; then :
3986 withval=$with_toolkit_scroll_bars;
3987 else
3988 with_toolkit_scroll_bars=yes
3989 fi
3990
3991
3992 # Check whether --with-xaw3d was given.
3993 if test "${with_xaw3d+set}" = set; then :
3994 withval=$with_xaw3d;
3995 else
3996 with_xaw3d=yes
3997 fi
3998
3999
4000 # Check whether --with-xim was given.
4001 if test "${with_xim+set}" = set; then :
4002 withval=$with_xim;
4003 else
4004 with_xim=yes
4005 fi
4006
4007
4008 # Check whether --with-ns was given.
4009 if test "${with_ns+set}" = set; then :
4010 withval=$with_ns;
4011 else
4012 with_ns=no
4013 fi
4014
4015
4016
4017 # Check whether --with-gpm was given.
4018 if test "${with_gpm+set}" = set; then :
4019 withval=$with_gpm;
4020 else
4021 with_gpm=yes
4022 fi
4023
4024
4025 # Check whether --with-dbus was given.
4026 if test "${with_dbus+set}" = set; then :
4027 withval=$with_dbus;
4028 else
4029 with_dbus=yes
4030 fi
4031
4032
4033 # Check whether --with-gconf was given.
4034 if test "${with_gconf+set}" = set; then :
4035 withval=$with_gconf;
4036 else
4037 with_gconf=yes
4038 fi
4039
4040
4041 # Check whether --with-gsettings was given.
4042 if test "${with_gsettings+set}" = set; then :
4043 withval=$with_gsettings;
4044 else
4045 with_gsettings=yes
4046 fi
4047
4048
4049 # Check whether --with-selinux was given.
4050 if test "${with_selinux+set}" = set; then :
4051 withval=$with_selinux;
4052 else
4053 with_selinux=yes
4054 fi
4055
4056
4057 # Check whether --with-gnutls was given.
4058 if test "${with_gnutls+set}" = set; then :
4059 withval=$with_gnutls;
4060 else
4061 with_gnutls=yes
4062 fi
4063
4064
4065 ## For the times when you want to build Emacs but don't have
4066 ## a suitable makeinfo, and can live without the manuals.
4067
4068 # Check whether --with-makeinfo was given.
4069 if test "${with_makeinfo+set}" = set; then :
4070 withval=$with_makeinfo;
4071 else
4072 with_makeinfo=yes
4073 fi
4074
4075
4076 ## Makefile.in needs the cache file name.
4077
4078
4079 ## This is an option because I do not know if all info/man support
4080 ## compressed files, nor how to test if they do so.
4081
4082 # Check whether --with-compress-info was given.
4083 if test "${with_compress_info+set}" = set; then :
4084 withval=$with_compress_info;
4085 else
4086 with_compress_info=yes
4087 fi
4088
4089 if test $with_compress_info = yes; then
4090 GZIP_INFO=yes
4091 else
4092 GZIP_INFO=
4093 fi
4094
4095
4096
4097 # Check whether --with-pkg-config-prog was given.
4098 if test "${with_pkg_config_prog+set}" = set; then :
4099 withval=$with_pkg_config_prog;
4100 fi
4101
4102 if test "X${with_pkg_config_prog}" != X; then
4103 if test "${with_pkg_config_prog}" != yes; then
4104 PKG_CONFIG="${with_pkg_config_prog}"
4105 fi
4106 fi
4107
4108 CRT_DIR=
4109
4110 # Check whether --with-crt-dir was given.
4111 if test "${with_crt_dir+set}" = set; then :
4112 withval=$with_crt_dir;
4113 fi
4114
4115 CRT_DIR="${with_crt_dir}"
4116
4117
4118 # Check whether --with-gameuser was given.
4119 if test "${with_gameuser+set}" = set; then :
4120 withval=$with_gameuser;
4121 fi
4122
4123 test "X${with_gameuser}" != X && test "${with_gameuser}" != yes \
4124 && gameuser="${with_gameuser}"
4125 test "X$gameuser" = X && gameuser=games
4126
4127
4128 # Check whether --with-gnustep-conf was given.
4129 if test "${with_gnustep_conf+set}" = set; then :
4130 withval=$with_gnustep_conf;
4131 fi
4132
4133 test "X${with_gnustep_conf}" != X && test "${with_gnustep_conf}" != yes && \
4134 GNUSTEP_CONFIG_FILE="${with_gnustep_conf}"
4135 test "X$GNUSTEP_CONFIG_FILE" = "X" && \
4136 GNUSTEP_CONFIG_FILE=/etc/GNUstep/GNUstep.conf
4137
4138 # Check whether --enable-ns-self-contained was given.
4139 if test "${enable_ns_self_contained+set}" = set; then :
4140 enableval=$enable_ns_self_contained; EN_NS_SELF_CONTAINED=$enableval
4141 else
4142 EN_NS_SELF_CONTAINED=yes
4143 fi
4144
4145
4146 # Check whether --enable-asserts was given.
4147 if test "${enable_asserts+set}" = set; then :
4148 enableval=$enable_asserts; USE_XASSERTS=$enableval
4149 else
4150 USE_XASSERTS=no
4151 fi
4152
4153
4154 # Check whether --enable-maintainer-mode was given.
4155 if test "${enable_maintainer_mode+set}" = set; then :
4156 enableval=$enable_maintainer_mode; USE_MAINTAINER_MODE=$enableval
4157 else
4158 USE_MAINTAINER_MODE=yes
4159 fi
4160
4161 if test $USE_MAINTAINER_MODE = yes; then
4162 MAINT=
4163 else
4164 MAINT=#
4165 fi
4166
4167
4168 # Check whether --enable-locallisppath was given.
4169 if test "${enable_locallisppath+set}" = set; then :
4170 enableval=$enable_locallisppath; if test "${enableval}" = "no"; then
4171 locallisppath=
4172 elif test "${enableval}" != "yes"; then
4173 locallisppath=${enableval}
4174 fi
4175 fi
4176
4177
4178 # Check whether --enable-checking was given.
4179 if test "${enable_checking+set}" = set; then :
4180 enableval=$enable_checking; ac_checking_flags="${enableval}"
4181 fi
4182
4183 IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS,"
4184 for check in $ac_checking_flags
4185 do
4186 case $check in
4187 # these set all the flags to specific states
4188 yes) ac_enable_checking=1 ;;
4189 no) ac_enable_checking= ;
4190 ac_gc_check_stringbytes= ;
4191 ac_gc_check_string_overrun= ;
4192 ac_gc_check_string_free_list= ;
4193 ac_xmalloc_overrun= ;
4194 ac_gc_check_cons_list= ;;
4195 all) ac_enable_checking=1 ;
4196 ac_gc_check_stringbytes=1 ;
4197 ac_gc_check_string_overrun=1 ;
4198 ac_gc_check_string_free_list=1 ;
4199 ac_xmalloc_overrun=1 ;
4200 ac_gc_check_cons_list=1 ;;
4201 # these enable particular checks
4202 stringbytes) ac_gc_check_stringbytes=1 ;;
4203 stringoverrun) ac_gc_check_string_overrun=1 ;;
4204 stringfreelist) ac_gc_check_string_free_list=1 ;;
4205 xmallocoverrun) ac_xmalloc_overrun=1 ;;
4206 conslist) ac_gc_check_cons_list=1 ;;
4207 *) as_fn_error "unknown check category $check" "$LINENO" 5 ;;
4208 esac
4209 done
4210 IFS="$ac_save_IFS"
4211
4212 if test x$ac_enable_checking != x ; then
4213
4214 $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h
4215
4216 fi
4217 if test x$ac_gc_check_stringbytes != x ; then
4218
4219 $as_echo "#define GC_CHECK_STRING_BYTES 1" >>confdefs.h
4220
4221 fi
4222 if test x$ac_gc_check_string_overrun != x ; then
4223
4224 $as_echo "#define GC_CHECK_STRING_OVERRUN 1" >>confdefs.h
4225
4226 fi
4227 if test x$ac_gc_check_string_free_list != x ; then
4228
4229 $as_echo "#define GC_CHECK_STRING_FREE_LIST 1" >>confdefs.h
4230
4231 fi
4232 if test x$ac_xmalloc_overrun != x ; then
4233
4234 $as_echo "#define XMALLOC_OVERRUN_CHECK 1" >>confdefs.h
4235
4236 fi
4237 if test x$ac_gc_check_cons_list != x ; then
4238
4239 $as_echo "#define GC_CHECK_CONS_LIST 1" >>confdefs.h
4240
4241 fi
4242
4243 # Check whether --enable-use-lisp-union-type was given.
4244 if test "${enable_use_lisp_union_type+set}" = set; then :
4245 enableval=$enable_use_lisp_union_type; if test "${enableval}" != "no"; then
4246
4247 $as_echo "#define USE_LISP_UNION_TYPE 1" >>confdefs.h
4248
4249 fi
4250 fi
4251
4252
4253
4254 # Check whether --enable-profiling was given.
4255 if test "${enable_profiling+set}" = set; then :
4256 enableval=$enable_profiling; ac_enable_profiling="${enableval}"
4257 fi
4258
4259 if test x$ac_enable_profiling != x ; then
4260 PROFILING_CFLAGS="-DPROFILING=1 -pg"
4261 else
4262 PROFILING_CFLAGS=
4263 fi
4264
4265
4266 # Check whether --enable-autodepend was given.
4267 if test "${enable_autodepend+set}" = set; then :
4268 enableval=$enable_autodepend; ac_enable_autodepend="${enableval}"
4269 else
4270 ac_enable_autodepend=yes
4271 fi
4272
4273
4274 #### Make srcdir absolute, if it isn't already. It's important to
4275 #### avoid running the path through pwd unnecessarily, since pwd can
4276 #### give you automounter prefixes, which can go away. We do all this
4277 #### so Emacs can find its files when run uninstalled.
4278 ## Make sure CDPATH doesn't affect cd (in case PWD is relative).
4279 unset CDPATH
4280 case "${srcdir}" in
4281 /* ) ;;
4282 . )
4283 ## We may be able to use the $PWD environment variable to make this
4284 ## absolute. But sometimes PWD is inaccurate.
4285 ## Note: we used to use ${PWD} at the end instead of `pwd`,
4286 ## but that tested only for a well-formed and valid PWD,
4287 ## it did not object when PWD was well-formed and valid but just wrong.
4288 if test ".${PWD}" != "." && test ".`(cd ${PWD} ; sh -c pwd)`" = ".`pwd`" ;
4289 then
4290 srcdir="$PWD"
4291 else
4292 srcdir="`(cd ${srcdir}; pwd)`"
4293 fi
4294 ;;
4295 * ) srcdir="`(cd ${srcdir}; pwd)`" ;;
4296 esac
4297
4298 #### Given the configuration name, set machfile and opsysfile to the
4299 #### names of the m/*.h and s/*.h files we should use.
4300
4301 ### Canonicalize the configuration name.
4302
4303 # Make sure we can run config.sub.
4304 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
4305 as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
4306
4307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
4308 $as_echo_n "checking build system type... " >&6; }
4309 if test "${ac_cv_build+set}" = set; then :
4310 $as_echo_n "(cached) " >&6
4311 else
4312 ac_build_alias=$build_alias
4313 test "x$ac_build_alias" = x &&
4314 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
4315 test "x$ac_build_alias" = x &&
4316 as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5
4317 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
4318 as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
4319
4320 fi
4321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
4322 $as_echo "$ac_cv_build" >&6; }
4323 case $ac_cv_build in
4324 *-*-*) ;;
4325 *) as_fn_error "invalid value of canonical build" "$LINENO" 5;;
4326 esac
4327 build=$ac_cv_build
4328 ac_save_IFS=$IFS; IFS='-'
4329 set x $ac_cv_build
4330 shift
4331 build_cpu=$1
4332 build_vendor=$2
4333 shift; shift
4334 # Remember, the first character of IFS is used to create $*,
4335 # except with old shells:
4336 build_os=$*
4337 IFS=$ac_save_IFS
4338 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
4339
4340
4341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
4342 $as_echo_n "checking host system type... " >&6; }
4343 if test "${ac_cv_host+set}" = set; then :
4344 $as_echo_n "(cached) " >&6
4345 else
4346 if test "x$host_alias" = x; then
4347 ac_cv_host=$ac_cv_build
4348 else
4349 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
4350 as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
4351 fi
4352
4353 fi
4354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
4355 $as_echo "$ac_cv_host" >&6; }
4356 case $ac_cv_host in
4357 *-*-*) ;;
4358 *) as_fn_error "invalid value of canonical host" "$LINENO" 5;;
4359 esac
4360 host=$ac_cv_host
4361 ac_save_IFS=$IFS; IFS='-'
4362 set x $ac_cv_host
4363 shift
4364 host_cpu=$1
4365 host_vendor=$2
4366 shift; shift
4367 # Remember, the first character of IFS is used to create $*,
4368 # except with old shells:
4369 host_os=$*
4370 IFS=$ac_save_IFS
4371 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
4372
4373
4374 canonical=$host
4375 configuration=${host_alias-${build_alias-$host}}
4376
4377
4378
4379 ### If you add support for a new configuration, add code to this
4380 ### switch statement to recognize your configuration name and select
4381 ### the appropriate operating system and machine description files.
4382
4383 ### You would hope that you could choose an m/*.h file pretty much
4384 ### based on the machine portion of the configuration name, and an s/*.h
4385 ### file based on the operating system portion. However, it turns out
4386 ### that each m/*.h file is pretty manufacturer-specific - for
4387 ### example mips.h is MIPS
4388 ### So we basically have to have a special case for each
4389 ### configuration name.
4390 ###
4391 ### As far as handling version numbers on operating systems is
4392 ### concerned, make sure things will fail in a fixable way. If
4393 ### /etc/MACHINES doesn't say anything about version numbers, be
4394 ### prepared to handle anything reasonably. If version numbers
4395 ### matter, be sure /etc/MACHINES says something about it.
4396
4397 machine='' opsys='' unported=no
4398 case "${canonical}" in
4399
4400 ## GNU/Linux and similar ports
4401 *-*-linux* )
4402 opsys=gnu-linux
4403 case ${canonical} in
4404 alpha*) machine=alpha ;;
4405 s390x-*) machine=ibms390x ;;
4406 powerpc*) machine=macppc ;;
4407 sparc*) machine=sparc ;;
4408 ia64*) machine=ia64 ;;
4409 m68k*) machine=m68k ;;
4410 x86_64*) machine=amdx86-64 ;;
4411 esac
4412 ;;
4413
4414 ## FreeBSD ports
4415 *-*-freebsd* )
4416 opsys=freebsd
4417 case "${canonical}" in
4418 alpha*) machine=alpha ;;
4419 amd64-*|x86_64-*) machine=amdx86-64 ;;
4420 ia64-*) machine=ia64 ;;
4421 i[3456]86-*) machine=intel386 ;;
4422 powerpc-*) machine=macppc ;;
4423 sparc-*) machine=sparc ;;
4424 sparc64-*) machine=sparc ;;
4425 esac
4426 ;;
4427
4428 ## FreeBSD kernel + glibc based userland
4429 *-*-kfreebsd*gnu* )
4430 opsys=gnu-kfreebsd
4431 case "${canonical}" in
4432 alpha*) machine=alpha ;;
4433 amd64-*|x86_64-*) machine=amdx86-64 ;;
4434 ia64-*) machine=ia64 ;;
4435 i[3456]86-*) machine=intel386 ;;
4436 powerpc-*) machine=macppc ;;
4437 sparc-*) machine=sparc ;;
4438 sparc64-*) machine=sparc ;;
4439 esac
4440 ;;
4441
4442 ## NetBSD ports
4443 *-*-netbsd* )
4444 opsys=netbsd
4445 case "${canonical}" in
4446 alpha*) machine=alpha ;;
4447 x86_64-*) machine=amdx86-64 ;;
4448 i[3456]86-*) machine=intel386 ;;
4449 m68k-*) machine=m68k ;;
4450 powerpc-*) machine=macppc ;;
4451 sparc*-) machine=sparc ;;
4452 vax-*) machine=vax ;;
4453 esac
4454 ;;
4455
4456 ## OpenBSD ports
4457 *-*-openbsd* )
4458 opsys=openbsd
4459 case "${canonical}" in
4460 alpha*) machine=alpha ;;
4461 x86_64-*) machine=amdx86-64 ;;
4462 i386-*) machine=intel386 ;;
4463 powerpc-*) machine=macppc ;;
4464 sparc*) machine=sparc ;;
4465 vax-*) machine=vax ;;
4466 esac
4467 ;;
4468
4469 ## Apple Darwin / Mac OS X
4470 *-apple-darwin* )
4471 case "${canonical}" in
4472 i[3456]86-* ) machine=intel386 ;;
4473 powerpc-* ) machine=macppc ;;
4474 x86_64-* ) machine=amdx86-64 ;;
4475 * ) unported=yes ;;
4476 esac
4477 opsys=darwin
4478 # Define CPP as follows to make autoconf work correctly.
4479 CPP="${CC-cc} -E -no-cpp-precomp"
4480 # Use fink packages if available.
4481 if test -d /sw/include && test -d /sw/lib; then
4482 GCC_TEST_OPTIONS="-I/sw/include -L/sw/lib"
4483 CPP="${CPP} ${GCC_TEST_OPTIONS}"
4484 NON_GCC_TEST_OPTIONS=${GCC_TEST_OPTIONS}
4485 fi
4486 ;;
4487
4488 ## HP 9000 series 700 and 800, running HP/UX
4489 hppa*-hp-hpux10.2* )
4490 opsys=hpux10-20
4491 ;;
4492 hppa*-hp-hpux1[1-9]* )
4493 opsys=hpux11
4494 CFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CFLAGS"
4495 ;;
4496
4497 ## IBM machines
4498 rs6000-ibm-aix4.[23]* )
4499 machine=ibmrs6000 opsys=aix4-2
4500 ;;
4501 powerpc-ibm-aix4.[23]* )
4502 machine=ibmrs6000 opsys=aix4-2
4503 ;;
4504 rs6000-ibm-aix[56]* )
4505 machine=ibmrs6000 opsys=aix4-2
4506 ;;
4507 powerpc-ibm-aix[56]* )
4508 machine=ibmrs6000 opsys=aix4-2
4509 ;;
4510
4511 ## Silicon Graphics machines
4512 ## Iris 4D
4513 mips-sgi-irix6.5 )
4514 opsys=irix6-5
4515 # Without defining _LANGUAGE_C, things get masked out in the headers
4516 # so that, for instance, grepping for `free' in stdlib.h fails and
4517 # AC_HEADER_STD_C fails. (MIPSPro 7.2.1.2m compilers, Irix 6.5.3m).
4518 NON_GNU_CPP="/lib/cpp -D_LANGUAGE_C"
4519 NON_GCC_TEST_OPTIONS="-D_LANGUAGE_C"
4520 ;;
4521
4522 ## Suns
4523 *-sun-solaris* \
4524 | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* \
4525 | x86_64-*-solaris2* | x86_64-*-sunos5*)
4526 case "${canonical}" in
4527 i[3456]86-*-* ) machine=intel386 ;;
4528 amd64-*-*|x86_64-*-*) machine=amdx86-64 ;;
4529 sparc* ) machine=sparc ;;
4530 * ) unported=yes ;;
4531 esac
4532 case "${canonical}" in
4533 *-sunos5.6* | *-solaris2.6* )
4534 opsys=sol2-6
4535 NON_GNU_CPP=/usr/ccs/lib/cpp
4536 RANLIB="ar -ts"
4537 ;;
4538 *-sunos5.[7-9]* | *-solaris2.[7-9]* )
4539 opsys=sol2-6
4540 emacs_check_sunpro_c=yes
4541 NON_GNU_CPP=/usr/ccs/lib/cpp
4542 ;;
4543 *-sunos5* | *-solaris* )
4544 opsys=sol2-10
4545 emacs_check_sunpro_c=yes
4546 NON_GNU_CPP=/usr/ccs/lib/cpp
4547 ;;
4548 esac
4549 ## Watch out for a compiler that we know will not work.
4550 case "${canonical}" in
4551 *-solaris* | *-sunos5* )
4552 if [ "x$CC" = x/usr/ucb/cc ]; then
4553 ## /usr/ucb/cc doesn't work;
4554 ## we should find some other compiler that does work.
4555 unset CC
4556 fi
4557 ;;
4558 *) ;;
4559 esac
4560 ;;
4561
4562 ## Intel 386 machines where we don't care about the manufacturer.
4563 i[3456]86-*-* )
4564 machine=intel386
4565 case "${canonical}" in
4566 *-cygwin ) opsys=cygwin ;;
4567 *-darwin* ) opsys=darwin
4568 CPP="${CC-cc} -E -no-cpp-precomp"
4569 ;;
4570 *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4571 *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4572 *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;;
4573 ## Otherwise, we'll fall through to the generic opsys code at the bottom.
4574 esac
4575 ;;
4576
4577 * )
4578 unported=yes
4579 ;;
4580 esac
4581
4582 ### If the code above didn't choose an operating system, just choose
4583 ### an operating system based on the configuration name. You really
4584 ### only want to use this when you have no idea what the right
4585 ### operating system is; if you know what operating systems a machine
4586 ### runs, it's cleaner to make it explicit in the case statement
4587 ### above.
4588 if test x"${opsys}" = x; then
4589 case "${canonical}" in
4590 *-gnu* ) opsys=gnu ;;
4591 * )
4592 unported=yes
4593 ;;
4594 esac
4595 fi
4596
4597
4598
4599 if test $unported = yes; then
4600 as_fn_error "Emacs hasn't been ported to \`${canonical}' systems.
4601 Check \`etc/MACHINES' for recognized configuration names." "$LINENO" 5
4602 fi
4603
4604 if test -n "$machine"; then
4605 machfile="m/${machine}.h"
4606 else
4607 machfile=
4608 fi
4609 opsysfile="s/${opsys}.h"
4610
4611
4612 #### Choose a compiler.
4613 test -n "$CC" && cc_specified=yes
4614
4615 # Save the value of CFLAGS that the user specified.
4616 SPECIFIED_CFLAGS="$CFLAGS"
4617
4618 ac_ext=c
4619 ac_cpp='$CPP $CPPFLAGS'
4620 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4621 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4622 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4623 if test -n "$ac_tool_prefix"; then
4624 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
4625 set dummy ${ac_tool_prefix}gcc; ac_word=$2
4626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4627 $as_echo_n "checking for $ac_word... " >&6; }
4628 if test "${ac_cv_prog_CC+set}" = set; then :
4629 $as_echo_n "(cached) " >&6
4630 else
4631 if test -n "$CC"; then
4632 ac_cv_prog_CC="$CC" # Let the user override the test.
4633 else
4634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4635 for as_dir in $PATH
4636 do
4637 IFS=$as_save_IFS
4638 test -z "$as_dir" && as_dir=.
4639 for ac_exec_ext in '' $ac_executable_extensions; do
4640 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4641 ac_cv_prog_CC="${ac_tool_prefix}gcc"
4642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4643 break 2
4644 fi
4645 done
4646 done
4647 IFS=$as_save_IFS
4648
4649 fi
4650 fi
4651 CC=$ac_cv_prog_CC
4652 if test -n "$CC"; then
4653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4654 $as_echo "$CC" >&6; }
4655 else
4656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4657 $as_echo "no" >&6; }
4658 fi
4659
4660
4661 fi
4662 if test -z "$ac_cv_prog_CC"; then
4663 ac_ct_CC=$CC
4664 # Extract the first word of "gcc", so it can be a program name with args.
4665 set dummy gcc; ac_word=$2
4666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4667 $as_echo_n "checking for $ac_word... " >&6; }
4668 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4669 $as_echo_n "(cached) " >&6
4670 else
4671 if test -n "$ac_ct_CC"; then
4672 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4673 else
4674 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4675 for as_dir in $PATH
4676 do
4677 IFS=$as_save_IFS
4678 test -z "$as_dir" && as_dir=.
4679 for ac_exec_ext in '' $ac_executable_extensions; do
4680 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4681 ac_cv_prog_ac_ct_CC="gcc"
4682 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4683 break 2
4684 fi
4685 done
4686 done
4687 IFS=$as_save_IFS
4688
4689 fi
4690 fi
4691 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4692 if test -n "$ac_ct_CC"; then
4693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4694 $as_echo "$ac_ct_CC" >&6; }
4695 else
4696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4697 $as_echo "no" >&6; }
4698 fi
4699
4700 if test "x$ac_ct_CC" = x; then
4701 CC=""
4702 else
4703 case $cross_compiling:$ac_tool_warned in
4704 yes:)
4705 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4706 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4707 ac_tool_warned=yes ;;
4708 esac
4709 CC=$ac_ct_CC
4710 fi
4711 else
4712 CC="$ac_cv_prog_CC"
4713 fi
4714
4715 if test -z "$CC"; then
4716 if test -n "$ac_tool_prefix"; then
4717 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4718 set dummy ${ac_tool_prefix}cc; ac_word=$2
4719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4720 $as_echo_n "checking for $ac_word... " >&6; }
4721 if test "${ac_cv_prog_CC+set}" = set; then :
4722 $as_echo_n "(cached) " >&6
4723 else
4724 if test -n "$CC"; then
4725 ac_cv_prog_CC="$CC" # Let the user override the test.
4726 else
4727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4728 for as_dir in $PATH
4729 do
4730 IFS=$as_save_IFS
4731 test -z "$as_dir" && as_dir=.
4732 for ac_exec_ext in '' $ac_executable_extensions; do
4733 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4734 ac_cv_prog_CC="${ac_tool_prefix}cc"
4735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4736 break 2
4737 fi
4738 done
4739 done
4740 IFS=$as_save_IFS
4741
4742 fi
4743 fi
4744 CC=$ac_cv_prog_CC
4745 if test -n "$CC"; then
4746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4747 $as_echo "$CC" >&6; }
4748 else
4749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4750 $as_echo "no" >&6; }
4751 fi
4752
4753
4754 fi
4755 fi
4756 if test -z "$CC"; then
4757 # Extract the first word of "cc", so it can be a program name with args.
4758 set dummy cc; ac_word=$2
4759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4760 $as_echo_n "checking for $ac_word... " >&6; }
4761 if test "${ac_cv_prog_CC+set}" = set; then :
4762 $as_echo_n "(cached) " >&6
4763 else
4764 if test -n "$CC"; then
4765 ac_cv_prog_CC="$CC" # Let the user override the test.
4766 else
4767 ac_prog_rejected=no
4768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4769 for as_dir in $PATH
4770 do
4771 IFS=$as_save_IFS
4772 test -z "$as_dir" && as_dir=.
4773 for ac_exec_ext in '' $ac_executable_extensions; do
4774 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4775 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4776 ac_prog_rejected=yes
4777 continue
4778 fi
4779 ac_cv_prog_CC="cc"
4780 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4781 break 2
4782 fi
4783 done
4784 done
4785 IFS=$as_save_IFS
4786
4787 if test $ac_prog_rejected = yes; then
4788 # We found a bogon in the path, so make sure we never use it.
4789 set dummy $ac_cv_prog_CC
4790 shift
4791 if test $# != 0; then
4792 # We chose a different compiler from the bogus one.
4793 # However, it has the same basename, so the bogon will be chosen
4794 # first if we set CC to just the basename; use the full file name.
4795 shift
4796 ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
4797 fi
4798 fi
4799 fi
4800 fi
4801 CC=$ac_cv_prog_CC
4802 if test -n "$CC"; then
4803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4804 $as_echo "$CC" >&6; }
4805 else
4806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4807 $as_echo "no" >&6; }
4808 fi
4809
4810
4811 fi
4812 if test -z "$CC"; then
4813 if test -n "$ac_tool_prefix"; then
4814 for ac_prog in cl.exe
4815 do
4816 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4817 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4819 $as_echo_n "checking for $ac_word... " >&6; }
4820 if test "${ac_cv_prog_CC+set}" = set; then :
4821 $as_echo_n "(cached) " >&6
4822 else
4823 if test -n "$CC"; then
4824 ac_cv_prog_CC="$CC" # Let the user override the test.
4825 else
4826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4827 for as_dir in $PATH
4828 do
4829 IFS=$as_save_IFS
4830 test -z "$as_dir" && as_dir=.
4831 for ac_exec_ext in '' $ac_executable_extensions; do
4832 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4833 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4835 break 2
4836 fi
4837 done
4838 done
4839 IFS=$as_save_IFS
4840
4841 fi
4842 fi
4843 CC=$ac_cv_prog_CC
4844 if test -n "$CC"; then
4845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4846 $as_echo "$CC" >&6; }
4847 else
4848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4849 $as_echo "no" >&6; }
4850 fi
4851
4852
4853 test -n "$CC" && break
4854 done
4855 fi
4856 if test -z "$CC"; then
4857 ac_ct_CC=$CC
4858 for ac_prog in cl.exe
4859 do
4860 # Extract the first word of "$ac_prog", so it can be a program name with args.
4861 set dummy $ac_prog; ac_word=$2
4862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4863 $as_echo_n "checking for $ac_word... " >&6; }
4864 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
4865 $as_echo_n "(cached) " >&6
4866 else
4867 if test -n "$ac_ct_CC"; then
4868 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4869 else
4870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4871 for as_dir in $PATH
4872 do
4873 IFS=$as_save_IFS
4874 test -z "$as_dir" && as_dir=.
4875 for ac_exec_ext in '' $ac_executable_extensions; do
4876 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4877 ac_cv_prog_ac_ct_CC="$ac_prog"
4878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4879 break 2
4880 fi
4881 done
4882 done
4883 IFS=$as_save_IFS
4884
4885 fi
4886 fi
4887 ac_ct_CC=$ac_cv_prog_ac_ct_CC
4888 if test -n "$ac_ct_CC"; then
4889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4890 $as_echo "$ac_ct_CC" >&6; }
4891 else
4892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4893 $as_echo "no" >&6; }
4894 fi
4895
4896
4897 test -n "$ac_ct_CC" && break
4898 done
4899
4900 if test "x$ac_ct_CC" = x; then
4901 CC=""
4902 else
4903 case $cross_compiling:$ac_tool_warned in
4904 yes:)
4905 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4906 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4907 ac_tool_warned=yes ;;
4908 esac
4909 CC=$ac_ct_CC
4910 fi
4911 fi
4912
4913 fi
4914
4915
4916 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4917 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4918 as_fn_error "no acceptable C compiler found in \$PATH
4919 See \`config.log' for more details." "$LINENO" 5; }
4920
4921 # Provide some information about the compiler.
4922 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4923 set X $ac_compile
4924 ac_compiler=$2
4925 for ac_option in --version -v -V -qversion; do
4926 { { ac_try="$ac_compiler $ac_option >&5"
4927 case "(($ac_try" in
4928 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4929 *) ac_try_echo=$ac_try;;
4930 esac
4931 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4932 $as_echo "$ac_try_echo"; } >&5
4933 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4934 ac_status=$?
4935 if test -s conftest.err; then
4936 sed '10a\
4937 ... rest of stderr output deleted ...
4938 10q' conftest.err >conftest.er1
4939 cat conftest.er1 >&5
4940 fi
4941 rm -f conftest.er1 conftest.err
4942 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4943 test $ac_status = 0; }
4944 done
4945
4946 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4947 /* end confdefs.h. */
4948
4949 int
4950 main ()
4951 {
4952
4953 ;
4954 return 0;
4955 }
4956 _ACEOF
4957 ac_clean_files_save=$ac_clean_files
4958 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4959 # Try to create an executable without -o first, disregard a.out.
4960 # It will help us diagnose broken compilers, and finding out an intuition
4961 # of exeext.
4962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4963 $as_echo_n "checking whether the C compiler works... " >&6; }
4964 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4965
4966 # The possible output files:
4967 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4968
4969 ac_rmfiles=
4970 for ac_file in $ac_files
4971 do
4972 case $ac_file in
4973 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4974 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4975 esac
4976 done
4977 rm -f $ac_rmfiles
4978
4979 if { { ac_try="$ac_link_default"
4980 case "(($ac_try" in
4981 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4982 *) ac_try_echo=$ac_try;;
4983 esac
4984 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4985 $as_echo "$ac_try_echo"; } >&5
4986 (eval "$ac_link_default") 2>&5
4987 ac_status=$?
4988 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4989 test $ac_status = 0; }; then :
4990 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
4991 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
4992 # in a Makefile. We should not override ac_cv_exeext if it was cached,
4993 # so that the user can short-circuit this test for compilers unknown to
4994 # Autoconf.
4995 for ac_file in $ac_files ''
4996 do
4997 test -f "$ac_file" || continue
4998 case $ac_file in
4999 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
5000 ;;
5001 [ab].out )
5002 # We found the default executable, but exeext='' is most
5003 # certainly right.
5004 break;;
5005 *.* )
5006 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
5007 then :; else
5008 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5009 fi
5010 # We set ac_cv_exeext here because the later test for it is not
5011 # safe: cross compilers may not add the suffix if given an `-o'
5012 # argument, so we may need to know it at that point already.
5013 # Even if this section looks crufty: it has the advantage of
5014 # actually working.
5015 break;;
5016 * )
5017 break;;
5018 esac
5019 done
5020 test "$ac_cv_exeext" = no && ac_cv_exeext=
5021
5022 else
5023 ac_file=''
5024 fi
5025 if test -z "$ac_file"; then :
5026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5027 $as_echo "no" >&6; }
5028 $as_echo "$as_me: failed program was:" >&5
5029 sed 's/^/| /' conftest.$ac_ext >&5
5030
5031 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5032 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5033 { as_fn_set_status 77
5034 as_fn_error "C compiler cannot create executables
5035 See \`config.log' for more details." "$LINENO" 5; }; }
5036 else
5037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5038 $as_echo "yes" >&6; }
5039 fi
5040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
5041 $as_echo_n "checking for C compiler default output file name... " >&6; }
5042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
5043 $as_echo "$ac_file" >&6; }
5044 ac_exeext=$ac_cv_exeext
5045
5046 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
5047 ac_clean_files=$ac_clean_files_save
5048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
5049 $as_echo_n "checking for suffix of executables... " >&6; }
5050 if { { ac_try="$ac_link"
5051 case "(($ac_try" in
5052 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5053 *) ac_try_echo=$ac_try;;
5054 esac
5055 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5056 $as_echo "$ac_try_echo"; } >&5
5057 (eval "$ac_link") 2>&5
5058 ac_status=$?
5059 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5060 test $ac_status = 0; }; then :
5061 # If both `conftest.exe' and `conftest' are `present' (well, observable)
5062 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will
5063 # work properly (i.e., refer to `conftest.exe'), while it won't with
5064 # `rm'.
5065 for ac_file in conftest.exe conftest conftest.*; do
5066 test -f "$ac_file" || continue
5067 case $ac_file in
5068 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
5069 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
5070 break;;
5071 * ) break;;
5072 esac
5073 done
5074 else
5075 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5076 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5077 as_fn_error "cannot compute suffix of executables: cannot compile and link
5078 See \`config.log' for more details." "$LINENO" 5; }
5079 fi
5080 rm -f conftest conftest$ac_cv_exeext
5081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
5082 $as_echo "$ac_cv_exeext" >&6; }
5083
5084 rm -f conftest.$ac_ext
5085 EXEEXT=$ac_cv_exeext
5086 ac_exeext=$EXEEXT
5087 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5088 /* end confdefs.h. */
5089 #include <stdio.h>
5090 int
5091 main ()
5092 {
5093 FILE *f = fopen ("conftest.out", "w");
5094 return ferror (f) || fclose (f) != 0;
5095
5096 ;
5097 return 0;
5098 }
5099 _ACEOF
5100 ac_clean_files="$ac_clean_files conftest.out"
5101 # Check that the compiler produces executables we can run. If not, either
5102 # the compiler is broken, or we cross compile.
5103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
5104 $as_echo_n "checking whether we are cross compiling... " >&6; }
5105 if test "$cross_compiling" != yes; then
5106 { { ac_try="$ac_link"
5107 case "(($ac_try" in
5108 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5109 *) ac_try_echo=$ac_try;;
5110 esac
5111 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5112 $as_echo "$ac_try_echo"; } >&5
5113 (eval "$ac_link") 2>&5
5114 ac_status=$?
5115 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5116 test $ac_status = 0; }
5117 if { ac_try='./conftest$ac_cv_exeext'
5118 { { case "(($ac_try" in
5119 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5120 *) ac_try_echo=$ac_try;;
5121 esac
5122 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5123 $as_echo "$ac_try_echo"; } >&5
5124 (eval "$ac_try") 2>&5
5125 ac_status=$?
5126 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5127 test $ac_status = 0; }; }; then
5128 cross_compiling=no
5129 else
5130 if test "$cross_compiling" = maybe; then
5131 cross_compiling=yes
5132 else
5133 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5134 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5135 as_fn_error "cannot run C compiled programs.
5136 If you meant to cross compile, use \`--host'.
5137 See \`config.log' for more details." "$LINENO" 5; }
5138 fi
5139 fi
5140 fi
5141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
5142 $as_echo "$cross_compiling" >&6; }
5143
5144 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
5145 ac_clean_files=$ac_clean_files_save
5146 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
5147 $as_echo_n "checking for suffix of object files... " >&6; }
5148 if test "${ac_cv_objext+set}" = set; then :
5149 $as_echo_n "(cached) " >&6
5150 else
5151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5152 /* end confdefs.h. */
5153
5154 int
5155 main ()
5156 {
5157
5158 ;
5159 return 0;
5160 }
5161 _ACEOF
5162 rm -f conftest.o conftest.obj
5163 if { { ac_try="$ac_compile"
5164 case "(($ac_try" in
5165 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5166 *) ac_try_echo=$ac_try;;
5167 esac
5168 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5169 $as_echo "$ac_try_echo"; } >&5
5170 (eval "$ac_compile") 2>&5
5171 ac_status=$?
5172 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5173 test $ac_status = 0; }; then :
5174 for ac_file in conftest.o conftest.obj conftest.*; do
5175 test -f "$ac_file" || continue;
5176 case $ac_file in
5177 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
5178 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
5179 break;;
5180 esac
5181 done
5182 else
5183 $as_echo "$as_me: failed program was:" >&5
5184 sed 's/^/| /' conftest.$ac_ext >&5
5185
5186 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5187 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5188 as_fn_error "cannot compute suffix of object files: cannot compile
5189 See \`config.log' for more details." "$LINENO" 5; }
5190 fi
5191 rm -f conftest.$ac_cv_objext conftest.$ac_ext
5192 fi
5193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
5194 $as_echo "$ac_cv_objext" >&6; }
5195 OBJEXT=$ac_cv_objext
5196 ac_objext=$OBJEXT
5197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
5198 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
5199 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
5200 $as_echo_n "(cached) " >&6
5201 else
5202 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5203 /* end confdefs.h. */
5204
5205 int
5206 main ()
5207 {
5208 #ifndef __GNUC__
5209 choke me
5210 #endif
5211
5212 ;
5213 return 0;
5214 }
5215 _ACEOF
5216 if ac_fn_c_try_compile "$LINENO"; then :
5217 ac_compiler_gnu=yes
5218 else
5219 ac_compiler_gnu=no
5220 fi
5221 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5222 ac_cv_c_compiler_gnu=$ac_compiler_gnu
5223
5224 fi
5225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
5226 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
5227 if test $ac_compiler_gnu = yes; then
5228 GCC=yes
5229 else
5230 GCC=
5231 fi
5232 ac_test_CFLAGS=${CFLAGS+set}
5233 ac_save_CFLAGS=$CFLAGS
5234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
5235 $as_echo_n "checking whether $CC accepts -g... " >&6; }
5236 if test "${ac_cv_prog_cc_g+set}" = set; then :
5237 $as_echo_n "(cached) " >&6
5238 else
5239 ac_save_c_werror_flag=$ac_c_werror_flag
5240 ac_c_werror_flag=yes
5241 ac_cv_prog_cc_g=no
5242 CFLAGS="-g"
5243 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5244 /* end confdefs.h. */
5245
5246 int
5247 main ()
5248 {
5249
5250 ;
5251 return 0;
5252 }
5253 _ACEOF
5254 if ac_fn_c_try_compile "$LINENO"; then :
5255 ac_cv_prog_cc_g=yes
5256 else
5257 CFLAGS=""
5258 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5259 /* end confdefs.h. */
5260
5261 int
5262 main ()
5263 {
5264
5265 ;
5266 return 0;
5267 }
5268 _ACEOF
5269 if ac_fn_c_try_compile "$LINENO"; then :
5270
5271 else
5272 ac_c_werror_flag=$ac_save_c_werror_flag
5273 CFLAGS="-g"
5274 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5275 /* end confdefs.h. */
5276
5277 int
5278 main ()
5279 {
5280
5281 ;
5282 return 0;
5283 }
5284 _ACEOF
5285 if ac_fn_c_try_compile "$LINENO"; then :
5286 ac_cv_prog_cc_g=yes
5287 fi
5288 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5289 fi
5290 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5291 fi
5292 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5293 ac_c_werror_flag=$ac_save_c_werror_flag
5294 fi
5295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
5296 $as_echo "$ac_cv_prog_cc_g" >&6; }
5297 if test "$ac_test_CFLAGS" = set; then
5298 CFLAGS=$ac_save_CFLAGS
5299 elif test $ac_cv_prog_cc_g = yes; then
5300 if test "$GCC" = yes; then
5301 CFLAGS="-g -O2"
5302 else
5303 CFLAGS="-g"
5304 fi
5305 else
5306 if test "$GCC" = yes; then
5307 CFLAGS="-O2"
5308 else
5309 CFLAGS=
5310 fi
5311 fi
5312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
5313 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
5314 if test "${ac_cv_prog_cc_c89+set}" = set; then :
5315 $as_echo_n "(cached) " >&6
5316 else
5317 ac_cv_prog_cc_c89=no
5318 ac_save_CC=$CC
5319 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5320 /* end confdefs.h. */
5321 #include <stdarg.h>
5322 #include <stdio.h>
5323 #include <sys/types.h>
5324 #include <sys/stat.h>
5325 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
5326 struct buf { int x; };
5327 FILE * (*rcsopen) (struct buf *, struct stat *, int);
5328 static char *e (p, i)
5329 char **p;
5330 int i;
5331 {
5332 return p[i];
5333 }
5334 static char *f (char * (*g) (char **, int), char **p, ...)
5335 {
5336 char *s;
5337 va_list v;
5338 va_start (v,p);
5339 s = g (p, va_arg (v,int));
5340 va_end (v);
5341 return s;
5342 }
5343
5344 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
5345 function prototypes and stuff, but not '\xHH' hex character constants.
5346 These don't provoke an error unfortunately, instead are silently treated
5347 as 'x'. The following induces an error, until -std is added to get
5348 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
5349 array size at least. It's necessary to write '\x00'==0 to get something
5350 that's true only with -std. */
5351 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
5352
5353 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
5354 inside strings and character constants. */
5355 #define FOO(x) 'x'
5356 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
5357
5358 int test (int i, double x);
5359 struct s1 {int (*f) (int a);};
5360 struct s2 {int (*f) (double a);};
5361 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
5362 int argc;
5363 char **argv;
5364 int
5365 main ()
5366 {
5367 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
5368 ;
5369 return 0;
5370 }
5371 _ACEOF
5372 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
5373 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
5374 do
5375 CC="$ac_save_CC $ac_arg"
5376 if ac_fn_c_try_compile "$LINENO"; then :
5377 ac_cv_prog_cc_c89=$ac_arg
5378 fi
5379 rm -f core conftest.err conftest.$ac_objext
5380 test "x$ac_cv_prog_cc_c89" != "xno" && break
5381 done
5382 rm -f conftest.$ac_ext
5383 CC=$ac_save_CC
5384
5385 fi
5386 # AC_CACHE_VAL
5387 case "x$ac_cv_prog_cc_c89" in
5388 x)
5389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
5390 $as_echo "none needed" >&6; } ;;
5391 xno)
5392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
5393 $as_echo "unsupported" >&6; } ;;
5394 *)
5395 CC="$CC $ac_cv_prog_cc_c89"
5396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
5397 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
5398 esac
5399 if test "x$ac_cv_prog_cc_c89" != xno; then :
5400
5401 fi
5402
5403 ac_ext=c
5404 ac_cpp='$CPP $CPPFLAGS'
5405 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5406 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5407 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5408 DEPDIR="${am__leading_dot}deps"
5409
5410 ac_config_commands="$ac_config_commands depfiles"
5411
5412
5413 am_make=${MAKE-make}
5414 cat > confinc << 'END'
5415 am__doit:
5416 @echo this is the am__doit target
5417 .PHONY: am__doit
5418 END
5419 # If we don't find an include directive, just comment out the code.
5420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for style of include used by $am_make" >&5
5421 $as_echo_n "checking for style of include used by $am_make... " >&6; }
5422 am__include="#"
5423 am__quote=
5424 _am_result=none
5425 # First try GNU make style include.
5426 echo "include confinc" > confmf
5427 # Ignore all kinds of additional output from `make'.
5428 case `$am_make -s -f confmf 2> /dev/null` in #(
5429 *the\ am__doit\ target*)
5430 am__include=include
5431 am__quote=
5432 _am_result=GNU
5433 ;;
5434 esac
5435 # Now try BSD make style include.
5436 if test "$am__include" = "#"; then
5437 echo '.include "confinc"' > confmf
5438 case `$am_make -s -f confmf 2> /dev/null` in #(
5439 *the\ am__doit\ target*)
5440 am__include=.include
5441 am__quote="\""
5442 _am_result=BSD
5443 ;;
5444 esac
5445 fi
5446
5447
5448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $_am_result" >&5
5449 $as_echo "$_am_result" >&6; }
5450 rm -f confinc confmf
5451
5452 # Check whether --enable-dependency-tracking was given.
5453 if test "${enable_dependency_tracking+set}" = set; then :
5454 enableval=$enable_dependency_tracking;
5455 fi
5456
5457 if test "x$enable_dependency_tracking" != xno; then
5458 am_depcomp="$ac_aux_dir/depcomp"
5459 AMDEPBACKSLASH='\'
5460 fi
5461 if test "x$enable_dependency_tracking" != xno; then
5462 AMDEP_TRUE=
5463 AMDEP_FALSE='#'
5464 else
5465 AMDEP_TRUE='#'
5466 AMDEP_FALSE=
5467 fi
5468
5469
5470
5471 depcc="$CC" am_compiler_list=
5472
5473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking dependency style of $depcc" >&5
5474 $as_echo_n "checking dependency style of $depcc... " >&6; }
5475 if test "${am_cv_CC_dependencies_compiler_type+set}" = set; then :
5476 $as_echo_n "(cached) " >&6
5477 else
5478 if test -z "$AMDEP_TRUE" && test -f "$am_depcomp"; then
5479 # We make a subdir and do the tests there. Otherwise we can end up
5480 # making bogus files that we don't know about and never remove. For
5481 # instance it was reported that on HP-UX the gcc test will end up
5482 # making a dummy file named `D' -- because `-MD' means `put the output
5483 # in D'.
5484 mkdir conftest.dir
5485 # Copy depcomp to subdir because otherwise we won't find it if we're
5486 # using a relative directory.
5487 cp "$am_depcomp" conftest.dir
5488 cd conftest.dir
5489 # We will build objects and dependencies in a subdirectory because
5490 # it helps to detect inapplicable dependency modes. For instance
5491 # both Tru64's cc and ICC support -MD to output dependencies as a
5492 # side effect of compilation, but ICC will put the dependencies in
5493 # the current directory while Tru64 will put them in the object
5494 # directory.
5495 mkdir sub
5496
5497 am_cv_CC_dependencies_compiler_type=none
5498 if test "$am_compiler_list" = ""; then
5499 am_compiler_list=`sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < ./depcomp`
5500 fi
5501 am__universal=false
5502 case " $depcc " in #(
5503 *\ -arch\ *\ -arch\ *) am__universal=true ;;
5504 esac
5505
5506 for depmode in $am_compiler_list; do
5507 # Setup a source with many dependencies, because some compilers
5508 # like to wrap large dependency lists on column 80 (with \), and
5509 # we should not choose a depcomp mode which is confused by this.
5510 #
5511 # We need to recreate these files for each test, as the compiler may
5512 # overwrite some of them when testing with obscure command lines.
5513 # This happens at least with the AIX C compiler.
5514 : > sub/conftest.c
5515 for i in 1 2 3 4 5 6; do
5516 echo '#include "conftst'$i'.h"' >> sub/conftest.c
5517 # Using `: > sub/conftst$i.h' creates only sub/conftst1.h with
5518 # Solaris 8's {/usr,}/bin/sh.
5519 touch sub/conftst$i.h
5520 done
5521 echo "${am__include} ${am__quote}sub/conftest.Po${am__quote}" > confmf
5522
5523 # We check with `-c' and `-o' for the sake of the "dashmstdout"
5524 # mode. It turns out that the SunPro C++ compiler does not properly
5525 # handle `-M -o', and we need to detect this. Also, some Intel
5526 # versions had trouble with output in subdirs
5527 am__obj=sub/conftest.${OBJEXT-o}
5528 am__minus_obj="-o $am__obj"
5529 case $depmode in
5530 gcc)
5531 # This depmode causes a compiler race in universal mode.
5532 test "$am__universal" = false || continue
5533 ;;
5534 nosideeffect)
5535 # after this tag, mechanisms are not by side-effect, so they'll
5536 # only be used when explicitly requested
5537 if test "x$enable_dependency_tracking" = xyes; then
5538 continue
5539 else
5540 break
5541 fi
5542 ;;
5543 msvisualcpp | msvcmsys)
5544 # This compiler won't grok `-c -o', but also, the minuso test has
5545 # not run yet. These depmodes are late enough in the game, and
5546 # so weak that their functioning should not be impacted.
5547 am__obj=conftest.${OBJEXT-o}
5548 am__minus_obj=
5549 ;;
5550 none) break ;;
5551 esac
5552 if depmode=$depmode \
5553 source=sub/conftest.c object=$am__obj \
5554 depfile=sub/conftest.Po tmpdepfile=sub/conftest.TPo \
5555 $SHELL ./depcomp $depcc -c $am__minus_obj sub/conftest.c \
5556 >/dev/null 2>conftest.err &&
5557 grep sub/conftst1.h sub/conftest.Po > /dev/null 2>&1 &&
5558 grep sub/conftst6.h sub/conftest.Po > /dev/null 2>&1 &&
5559 grep $am__obj sub/conftest.Po > /dev/null 2>&1 &&
5560 ${MAKE-make} -s -f confmf > /dev/null 2>&1; then
5561 # icc doesn't choke on unknown options, it will just issue warnings
5562 # or remarks (even with -Werror). So we grep stderr for any message
5563 # that says an option was ignored or not supported.
5564 # When given -MP, icc 7.0 and 7.1 complain thusly:
5565 # icc: Command line warning: ignoring option '-M'; no argument required
5566 # The diagnosis changed in icc 8.0:
5567 # icc: Command line remark: option '-MP' not supported
5568 if (grep 'ignoring option' conftest.err ||
5569 grep 'not supported' conftest.err) >/dev/null 2>&1; then :; else
5570 am_cv_CC_dependencies_compiler_type=$depmode
5571 break
5572 fi
5573 fi
5574 done
5575
5576 cd ..
5577 rm -rf conftest.dir
5578 else
5579 am_cv_CC_dependencies_compiler_type=none
5580 fi
5581
5582 fi
5583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_CC_dependencies_compiler_type" >&5
5584 $as_echo "$am_cv_CC_dependencies_compiler_type" >&6; }
5585 CCDEPMODE=depmode=$am_cv_CC_dependencies_compiler_type
5586
5587 if
5588 test "x$enable_dependency_tracking" != xno \
5589 && test "$am_cv_CC_dependencies_compiler_type" = gcc3; then
5590 am__fastdepCC_TRUE=
5591 am__fastdepCC_FALSE='#'
5592 else
5593 am__fastdepCC_TRUE='#'
5594 am__fastdepCC_FALSE=
5595 fi
5596
5597
5598 if test "x$CC" != xcc; then
5599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5
5600 $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; }
5601 else
5602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5
5603 $as_echo_n "checking whether cc understands -c and -o together... " >&6; }
5604 fi
5605 set dummy $CC; ac_cc=`$as_echo "$2" |
5606 sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5607 if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then :
5608 $as_echo_n "(cached) " >&6
5609 else
5610 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5611 /* end confdefs.h. */
5612
5613 int
5614 main ()
5615 {
5616
5617 ;
5618 return 0;
5619 }
5620 _ACEOF
5621 # Make sure it works both with $CC and with simple cc.
5622 # We do the test twice because some compilers refuse to overwrite an
5623 # existing .o file with -o, though they will create one.
5624 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5625 rm -f conftest2.*
5626 if { { case "(($ac_try" in
5627 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5628 *) ac_try_echo=$ac_try;;
5629 esac
5630 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5631 $as_echo "$ac_try_echo"; } >&5
5632 (eval "$ac_try") 2>&5
5633 ac_status=$?
5634 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5635 test $ac_status = 0; } &&
5636 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5637 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5638 *) ac_try_echo=$ac_try;;
5639 esac
5640 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5641 $as_echo "$ac_try_echo"; } >&5
5642 (eval "$ac_try") 2>&5
5643 ac_status=$?
5644 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5645 test $ac_status = 0; };
5646 then
5647 eval ac_cv_prog_cc_${ac_cc}_c_o=yes
5648 if test "x$CC" != xcc; then
5649 # Test first that cc exists at all.
5650 if { ac_try='cc -c conftest.$ac_ext >&5'
5651 { { case "(($ac_try" in
5652 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5653 *) ac_try_echo=$ac_try;;
5654 esac
5655 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5656 $as_echo "$ac_try_echo"; } >&5
5657 (eval "$ac_try") 2>&5
5658 ac_status=$?
5659 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5660 test $ac_status = 0; }; }; then
5661 ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
5662 rm -f conftest2.*
5663 if { { case "(($ac_try" in
5664 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5665 *) ac_try_echo=$ac_try;;
5666 esac
5667 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5668 $as_echo "$ac_try_echo"; } >&5
5669 (eval "$ac_try") 2>&5
5670 ac_status=$?
5671 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5672 test $ac_status = 0; } &&
5673 test -f conftest2.$ac_objext && { { case "(($ac_try" in
5674 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5675 *) ac_try_echo=$ac_try;;
5676 esac
5677 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
5678 $as_echo "$ac_try_echo"; } >&5
5679 (eval "$ac_try") 2>&5
5680 ac_status=$?
5681 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
5682 test $ac_status = 0; };
5683 then
5684 # cc works too.
5685 :
5686 else
5687 # cc exists but doesn't like -o.
5688 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5689 fi
5690 fi
5691 fi
5692 else
5693 eval ac_cv_prog_cc_${ac_cc}_c_o=no
5694 fi
5695 rm -f core conftest*
5696
5697 fi
5698 if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then
5699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5700 $as_echo "yes" >&6; }
5701 else
5702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5703 $as_echo "no" >&6; }
5704
5705 $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h
5706
5707 fi
5708
5709 # FIXME: we rely on the cache variable name because
5710 # there is no other way.
5711 set dummy $CC
5712 am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'`
5713 eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o
5714 if test "$am_t" != yes; then
5715 # Losing compiler, so override with the script.
5716 # FIXME: It is wrong to rewrite CC.
5717 # But if we don't then we get into trouble of one sort or another.
5718 # A longer-term fix would be to have automake use am__CC in this case,
5719 # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
5720 CC="$am_aux_dir/compile $CC"
5721 fi
5722
5723
5724
5725 # Initialize gnulib right after verifying that the C compiler works.
5726
5727 ac_ext=c
5728 ac_cpp='$CPP $CPPFLAGS'
5729 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5730 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5731 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
5733 $as_echo_n "checking how to run the C preprocessor... " >&6; }
5734 # On Suns, sometimes $CPP names a directory.
5735 if test -n "$CPP" && test -d "$CPP"; then
5736 CPP=
5737 fi
5738 if test -z "$CPP"; then
5739 if test "${ac_cv_prog_CPP+set}" = set; then :
5740 $as_echo_n "(cached) " >&6
5741 else
5742 # Double quotes because CPP needs to be expanded
5743 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
5744 do
5745 ac_preproc_ok=false
5746 for ac_c_preproc_warn_flag in '' yes
5747 do
5748 # Use a header file that comes with gcc, so configuring glibc
5749 # with a fresh cross-compiler works.
5750 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
5751 # <limits.h> exists even on freestanding compilers.
5752 # On the NeXT, cc -E runs the code through the compiler's parser,
5753 # not just through cpp. "Syntax error" is here to catch this case.
5754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5755 /* end confdefs.h. */
5756 #ifdef __STDC__
5757 # include <limits.h>
5758 #else
5759 # include <assert.h>
5760 #endif
5761 Syntax error
5762 _ACEOF
5763 if ac_fn_c_try_cpp "$LINENO"; then :
5764
5765 else
5766 # Broken: fails on valid input.
5767 continue
5768 fi
5769 rm -f conftest.err conftest.$ac_ext
5770
5771 # OK, works on sane cases. Now check whether nonexistent headers
5772 # can be detected and how.
5773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5774 /* end confdefs.h. */
5775 #include <ac_nonexistent.h>
5776 _ACEOF
5777 if ac_fn_c_try_cpp "$LINENO"; then :
5778 # Broken: success on invalid input.
5779 continue
5780 else
5781 # Passes both tests.
5782 ac_preproc_ok=:
5783 break
5784 fi
5785 rm -f conftest.err conftest.$ac_ext
5786
5787 done
5788 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
5789 rm -f conftest.err conftest.$ac_ext
5790 if $ac_preproc_ok; then :
5791 break
5792 fi
5793
5794 done
5795 ac_cv_prog_CPP=$CPP
5796
5797 fi
5798 CPP=$ac_cv_prog_CPP
5799 else
5800 ac_cv_prog_CPP=$CPP
5801 fi
5802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
5803 $as_echo "$CPP" >&6; }
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
5851 else
5852 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
5853 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
5854 as_fn_error "C preprocessor \"$CPP\" fails sanity check
5855 See \`config.log' for more details." "$LINENO" 5; }
5856 fi
5857
5858 ac_ext=c
5859 ac_cpp='$CPP $CPPFLAGS'
5860 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
5861 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
5862 ac_compiler_gnu=$ac_cv_c_compiler_gnu
5863
5864
5865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
5866 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5867 if test "${ac_cv_path_GREP+set}" = set; then :
5868 $as_echo_n "(cached) " >&6
5869 else
5870 if test -z "$GREP"; then
5871 ac_path_GREP_found=false
5872 # Loop through the user's path and test for each of PROGNAME-LIST
5873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5874 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5875 do
5876 IFS=$as_save_IFS
5877 test -z "$as_dir" && as_dir=.
5878 for ac_prog in grep ggrep; do
5879 for ac_exec_ext in '' $ac_executable_extensions; do
5880 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5881 { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5882 # Check for GNU ac_path_GREP and select it if it is found.
5883 # Check for GNU $ac_path_GREP
5884 case `"$ac_path_GREP" --version 2>&1` in
5885 *GNU*)
5886 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5887 *)
5888 ac_count=0
5889 $as_echo_n 0123456789 >"conftest.in"
5890 while :
5891 do
5892 cat "conftest.in" "conftest.in" >"conftest.tmp"
5893 mv "conftest.tmp" "conftest.in"
5894 cp "conftest.in" "conftest.nl"
5895 $as_echo 'GREP' >> "conftest.nl"
5896 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5897 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5898 as_fn_arith $ac_count + 1 && ac_count=$as_val
5899 if test $ac_count -gt ${ac_path_GREP_max-0}; then
5900 # Best one so far, save it but keep looking for a better one
5901 ac_cv_path_GREP="$ac_path_GREP"
5902 ac_path_GREP_max=$ac_count
5903 fi
5904 # 10*(2^10) chars as input seems more than enough
5905 test $ac_count -gt 10 && break
5906 done
5907 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5908 esac
5909
5910 $ac_path_GREP_found && break 3
5911 done
5912 done
5913 done
5914 IFS=$as_save_IFS
5915 if test -z "$ac_cv_path_GREP"; then
5916 as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5917 fi
5918 else
5919 ac_cv_path_GREP=$GREP
5920 fi
5921
5922 fi
5923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
5924 $as_echo "$ac_cv_path_GREP" >&6; }
5925 GREP="$ac_cv_path_GREP"
5926
5927
5928 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
5929 $as_echo_n "checking for egrep... " >&6; }
5930 if test "${ac_cv_path_EGREP+set}" = set; then :
5931 $as_echo_n "(cached) " >&6
5932 else
5933 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5934 then ac_cv_path_EGREP="$GREP -E"
5935 else
5936 if test -z "$EGREP"; then
5937 ac_path_EGREP_found=false
5938 # Loop through the user's path and test for each of PROGNAME-LIST
5939 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5940 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5941 do
5942 IFS=$as_save_IFS
5943 test -z "$as_dir" && as_dir=.
5944 for ac_prog in egrep; do
5945 for ac_exec_ext in '' $ac_executable_extensions; do
5946 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5947 { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5948 # Check for GNU ac_path_EGREP and select it if it is found.
5949 # Check for GNU $ac_path_EGREP
5950 case `"$ac_path_EGREP" --version 2>&1` in
5951 *GNU*)
5952 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5953 *)
5954 ac_count=0
5955 $as_echo_n 0123456789 >"conftest.in"
5956 while :
5957 do
5958 cat "conftest.in" "conftest.in" >"conftest.tmp"
5959 mv "conftest.tmp" "conftest.in"
5960 cp "conftest.in" "conftest.nl"
5961 $as_echo 'EGREP' >> "conftest.nl"
5962 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5963 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5964 as_fn_arith $ac_count + 1 && ac_count=$as_val
5965 if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5966 # Best one so far, save it but keep looking for a better one
5967 ac_cv_path_EGREP="$ac_path_EGREP"
5968 ac_path_EGREP_max=$ac_count
5969 fi
5970 # 10*(2^10) chars as input seems more than enough
5971 test $ac_count -gt 10 && break
5972 done
5973 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5974 esac
5975
5976 $ac_path_EGREP_found && break 3
5977 done
5978 done
5979 done
5980 IFS=$as_save_IFS
5981 if test -z "$ac_cv_path_EGREP"; then
5982 as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
5983 fi
5984 else
5985 ac_cv_path_EGREP=$EGREP
5986 fi
5987
5988 fi
5989 fi
5990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
5991 $as_echo "$ac_cv_path_EGREP" >&6; }
5992 EGREP="$ac_cv_path_EGREP"
5993
5994
5995
5996
5997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Minix Amsterdam compiler" >&5
5998 $as_echo_n "checking for Minix Amsterdam compiler... " >&6; }
5999 if test "${gl_cv_c_amsterdam_compiler+set}" = set; then :
6000 $as_echo_n "(cached) " >&6
6001 else
6002
6003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6004 /* end confdefs.h. */
6005
6006 #ifdef __ACK__
6007 Amsterdam
6008 #endif
6009
6010 _ACEOF
6011 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6012 $EGREP "Amsterdam" >/dev/null 2>&1; then :
6013 gl_cv_c_amsterdam_compiler=yes
6014 else
6015 gl_cv_c_amsterdam_compiler=no
6016 fi
6017 rm -f conftest*
6018
6019
6020 fi
6021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_amsterdam_compiler" >&5
6022 $as_echo "$gl_cv_c_amsterdam_compiler" >&6; }
6023 if test -z "$AR"; then
6024 if test $gl_cv_c_amsterdam_compiler = yes; then
6025 AR='cc -c.a'
6026 if test -z "$ARFLAGS"; then
6027 ARFLAGS='-o'
6028 fi
6029 else
6030 if test -n "$ac_tool_prefix"; then
6031 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6032 set dummy ${ac_tool_prefix}ar; ac_word=$2
6033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6034 $as_echo_n "checking for $ac_word... " >&6; }
6035 if test "${ac_cv_prog_AR+set}" = set; then :
6036 $as_echo_n "(cached) " >&6
6037 else
6038 if test -n "$AR"; then
6039 ac_cv_prog_AR="$AR" # Let the user override the test.
6040 else
6041 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6042 for as_dir in $PATH
6043 do
6044 IFS=$as_save_IFS
6045 test -z "$as_dir" && as_dir=.
6046 for ac_exec_ext in '' $ac_executable_extensions; do
6047 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6048 ac_cv_prog_AR="${ac_tool_prefix}ar"
6049 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6050 break 2
6051 fi
6052 done
6053 done
6054 IFS=$as_save_IFS
6055
6056 fi
6057 fi
6058 AR=$ac_cv_prog_AR
6059 if test -n "$AR"; then
6060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6061 $as_echo "$AR" >&6; }
6062 else
6063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6064 $as_echo "no" >&6; }
6065 fi
6066
6067
6068 fi
6069 if test -z "$ac_cv_prog_AR"; then
6070 ac_ct_AR=$AR
6071 # Extract the first word of "ar", so it can be a program name with args.
6072 set dummy ar; ac_word=$2
6073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6074 $as_echo_n "checking for $ac_word... " >&6; }
6075 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then :
6076 $as_echo_n "(cached) " >&6
6077 else
6078 if test -n "$ac_ct_AR"; then
6079 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6080 else
6081 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6082 for as_dir in $PATH
6083 do
6084 IFS=$as_save_IFS
6085 test -z "$as_dir" && as_dir=.
6086 for ac_exec_ext in '' $ac_executable_extensions; do
6087 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6088 ac_cv_prog_ac_ct_AR="ar"
6089 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6090 break 2
6091 fi
6092 done
6093 done
6094 IFS=$as_save_IFS
6095
6096 fi
6097 fi
6098 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6099 if test -n "$ac_ct_AR"; then
6100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6101 $as_echo "$ac_ct_AR" >&6; }
6102 else
6103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6104 $as_echo "no" >&6; }
6105 fi
6106
6107 if test "x$ac_ct_AR" = x; then
6108 AR="ar"
6109 else
6110 case $cross_compiling:$ac_tool_warned in
6111 yes:)
6112 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6113 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6114 ac_tool_warned=yes ;;
6115 esac
6116 AR=$ac_ct_AR
6117 fi
6118 else
6119 AR="$ac_cv_prog_AR"
6120 fi
6121
6122 if test -z "$ARFLAGS"; then
6123 ARFLAGS='cru'
6124 fi
6125 fi
6126 else
6127 if test -z "$ARFLAGS"; then
6128 ARFLAGS='cru'
6129 fi
6130 fi
6131
6132
6133 if test -z "$RANLIB"; then
6134 if test $gl_cv_c_amsterdam_compiler = yes; then
6135 RANLIB=':'
6136 else
6137 if test -n "$ac_tool_prefix"; then
6138 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6139 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6141 $as_echo_n "checking for $ac_word... " >&6; }
6142 if test "${ac_cv_prog_RANLIB+set}" = set; then :
6143 $as_echo_n "(cached) " >&6
6144 else
6145 if test -n "$RANLIB"; then
6146 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6147 else
6148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6149 for as_dir in $PATH
6150 do
6151 IFS=$as_save_IFS
6152 test -z "$as_dir" && as_dir=.
6153 for ac_exec_ext in '' $ac_executable_extensions; do
6154 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6155 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6157 break 2
6158 fi
6159 done
6160 done
6161 IFS=$as_save_IFS
6162
6163 fi
6164 fi
6165 RANLIB=$ac_cv_prog_RANLIB
6166 if test -n "$RANLIB"; then
6167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6168 $as_echo "$RANLIB" >&6; }
6169 else
6170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6171 $as_echo "no" >&6; }
6172 fi
6173
6174
6175 fi
6176 if test -z "$ac_cv_prog_RANLIB"; then
6177 ac_ct_RANLIB=$RANLIB
6178 # Extract the first word of "ranlib", so it can be a program name with args.
6179 set dummy ranlib; ac_word=$2
6180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6181 $as_echo_n "checking for $ac_word... " >&6; }
6182 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
6183 $as_echo_n "(cached) " >&6
6184 else
6185 if test -n "$ac_ct_RANLIB"; then
6186 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6187 else
6188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6189 for as_dir in $PATH
6190 do
6191 IFS=$as_save_IFS
6192 test -z "$as_dir" && as_dir=.
6193 for ac_exec_ext in '' $ac_executable_extensions; do
6194 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6195 ac_cv_prog_ac_ct_RANLIB="ranlib"
6196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
6197 break 2
6198 fi
6199 done
6200 done
6201 IFS=$as_save_IFS
6202
6203 fi
6204 fi
6205 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6206 if test -n "$ac_ct_RANLIB"; then
6207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6208 $as_echo "$ac_ct_RANLIB" >&6; }
6209 else
6210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6211 $as_echo "no" >&6; }
6212 fi
6213
6214 if test "x$ac_ct_RANLIB" = x; then
6215 RANLIB=":"
6216 else
6217 case $cross_compiling:$ac_tool_warned in
6218 yes:)
6219 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6220 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6221 ac_tool_warned=yes ;;
6222 esac
6223 RANLIB=$ac_ct_RANLIB
6224 fi
6225 else
6226 RANLIB="$ac_cv_prog_RANLIB"
6227 fi
6228
6229 fi
6230 fi
6231
6232
6233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
6234 $as_echo_n "checking for ANSI C header files... " >&6; }
6235 if test "${ac_cv_header_stdc+set}" = set; then :
6236 $as_echo_n "(cached) " >&6
6237 else
6238 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6239 /* end confdefs.h. */
6240 #include <stdlib.h>
6241 #include <stdarg.h>
6242 #include <string.h>
6243 #include <float.h>
6244
6245 int
6246 main ()
6247 {
6248
6249 ;
6250 return 0;
6251 }
6252 _ACEOF
6253 if ac_fn_c_try_compile "$LINENO"; then :
6254 ac_cv_header_stdc=yes
6255 else
6256 ac_cv_header_stdc=no
6257 fi
6258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6259
6260 if test $ac_cv_header_stdc = yes; then
6261 # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
6262 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6263 /* end confdefs.h. */
6264 #include <string.h>
6265
6266 _ACEOF
6267 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6268 $EGREP "memchr" >/dev/null 2>&1; then :
6269
6270 else
6271 ac_cv_header_stdc=no
6272 fi
6273 rm -f conftest*
6274
6275 fi
6276
6277 if test $ac_cv_header_stdc = yes; then
6278 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
6279 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6280 /* end confdefs.h. */
6281 #include <stdlib.h>
6282
6283 _ACEOF
6284 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
6285 $EGREP "free" >/dev/null 2>&1; then :
6286
6287 else
6288 ac_cv_header_stdc=no
6289 fi
6290 rm -f conftest*
6291
6292 fi
6293
6294 if test $ac_cv_header_stdc = yes; then
6295 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
6296 if test "$cross_compiling" = yes; then :
6297 :
6298 else
6299 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6300 /* end confdefs.h. */
6301 #include <ctype.h>
6302 #include <stdlib.h>
6303 #if ((' ' & 0x0FF) == 0x020)
6304 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
6305 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
6306 #else
6307 # define ISLOWER(c) \
6308 (('a' <= (c) && (c) <= 'i') \
6309 || ('j' <= (c) && (c) <= 'r') \
6310 || ('s' <= (c) && (c) <= 'z'))
6311 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
6312 #endif
6313
6314 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
6315 int
6316 main ()
6317 {
6318 int i;
6319 for (i = 0; i < 256; i++)
6320 if (XOR (islower (i), ISLOWER (i))
6321 || toupper (i) != TOUPPER (i))
6322 return 2;
6323 return 0;
6324 }
6325 _ACEOF
6326 if ac_fn_c_try_run "$LINENO"; then :
6327
6328 else
6329 ac_cv_header_stdc=no
6330 fi
6331 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6332 conftest.$ac_objext conftest.beam conftest.$ac_ext
6333 fi
6334
6335 fi
6336 fi
6337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
6338 $as_echo "$ac_cv_header_stdc" >&6; }
6339 if test $ac_cv_header_stdc = yes; then
6340
6341 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
6342
6343 fi
6344
6345 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
6346 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
6347 inttypes.h stdint.h unistd.h
6348 do :
6349 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6350 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
6351 "
6352 eval as_val=\$$as_ac_Header
6353 if test "x$as_val" = x""yes; then :
6354 cat >>confdefs.h <<_ACEOF
6355 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6356 _ACEOF
6357
6358 fi
6359
6360 done
6361
6362
6363
6364
6365
6366 ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default"
6367 if test "x$ac_cv_header_minix_config_h" = x""yes; then :
6368 MINIX=yes
6369 else
6370 MINIX=
6371 fi
6372
6373
6374 if test "$MINIX" = yes; then
6375
6376 $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h
6377
6378
6379 $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h
6380
6381
6382 $as_echo "#define _MINIX 1" >>confdefs.h
6383
6384 fi
6385
6386 case "$host_os" in
6387 hpux*)
6388
6389 $as_echo "#define _XOPEN_SOURCE 500" >>confdefs.h
6390
6391 ;;
6392 esac
6393
6394
6395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
6396 $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; }
6397 if test "${ac_cv_safe_to_define___extensions__+set}" = set; then :
6398 $as_echo_n "(cached) " >&6
6399 else
6400 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6401 /* end confdefs.h. */
6402
6403 # define __EXTENSIONS__ 1
6404 $ac_includes_default
6405 int
6406 main ()
6407 {
6408
6409 ;
6410 return 0;
6411 }
6412 _ACEOF
6413 if ac_fn_c_try_compile "$LINENO"; then :
6414 ac_cv_safe_to_define___extensions__=yes
6415 else
6416 ac_cv_safe_to_define___extensions__=no
6417 fi
6418 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6419 fi
6420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
6421 $as_echo "$ac_cv_safe_to_define___extensions__" >&6; }
6422 test $ac_cv_safe_to_define___extensions__ = yes &&
6423 $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h
6424
6425 $as_echo "#define _ALL_SOURCE 1" >>confdefs.h
6426
6427 $as_echo "#define _DARWIN_C_SOURCE 1" >>confdefs.h
6428
6429 $as_echo "#define _GNU_SOURCE 1" >>confdefs.h
6430
6431 $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
6432
6433 $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h
6434
6435
6436
6437
6438
6439
6440
6441
6442 # Check whether --enable-largefile was given.
6443 if test "${enable_largefile+set}" = set; then :
6444 enableval=$enable_largefile;
6445 fi
6446
6447 if test "$enable_largefile" != no; then
6448
6449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
6450 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
6451 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
6452 $as_echo_n "(cached) " >&6
6453 else
6454 ac_cv_sys_largefile_CC=no
6455 if test "$GCC" != yes; then
6456 ac_save_CC=$CC
6457 while :; do
6458 # IRIX 6.2 and later do not support large files by default,
6459 # so use the C compiler's -n32 option if that helps.
6460 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6461 /* end confdefs.h. */
6462 #include <sys/types.h>
6463 /* Check that off_t can represent 2**63 - 1 correctly.
6464 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6465 since some C++ compilers masquerading as C compilers
6466 incorrectly reject 9223372036854775807. */
6467 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6468 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6469 && LARGE_OFF_T % 2147483647 == 1)
6470 ? 1 : -1];
6471 int
6472 main ()
6473 {
6474
6475 ;
6476 return 0;
6477 }
6478 _ACEOF
6479 if ac_fn_c_try_compile "$LINENO"; then :
6480 break
6481 fi
6482 rm -f core conftest.err conftest.$ac_objext
6483 CC="$CC -n32"
6484 if ac_fn_c_try_compile "$LINENO"; then :
6485 ac_cv_sys_largefile_CC=' -n32'; break
6486 fi
6487 rm -f core conftest.err conftest.$ac_objext
6488 break
6489 done
6490 CC=$ac_save_CC
6491 rm -f conftest.$ac_ext
6492 fi
6493 fi
6494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
6495 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
6496 if test "$ac_cv_sys_largefile_CC" != no; then
6497 CC=$CC$ac_cv_sys_largefile_CC
6498 fi
6499
6500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
6501 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
6502 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
6503 $as_echo_n "(cached) " >&6
6504 else
6505 while :; do
6506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6507 /* end confdefs.h. */
6508 #include <sys/types.h>
6509 /* Check that off_t can represent 2**63 - 1 correctly.
6510 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6511 since some C++ compilers masquerading as C compilers
6512 incorrectly reject 9223372036854775807. */
6513 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6514 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6515 && LARGE_OFF_T % 2147483647 == 1)
6516 ? 1 : -1];
6517 int
6518 main ()
6519 {
6520
6521 ;
6522 return 0;
6523 }
6524 _ACEOF
6525 if ac_fn_c_try_compile "$LINENO"; then :
6526 ac_cv_sys_file_offset_bits=no; break
6527 fi
6528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6530 /* end confdefs.h. */
6531 #define _FILE_OFFSET_BITS 64
6532 #include <sys/types.h>
6533 /* Check that off_t can represent 2**63 - 1 correctly.
6534 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6535 since some C++ compilers masquerading as C compilers
6536 incorrectly reject 9223372036854775807. */
6537 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6538 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6539 && LARGE_OFF_T % 2147483647 == 1)
6540 ? 1 : -1];
6541 int
6542 main ()
6543 {
6544
6545 ;
6546 return 0;
6547 }
6548 _ACEOF
6549 if ac_fn_c_try_compile "$LINENO"; then :
6550 ac_cv_sys_file_offset_bits=64; break
6551 fi
6552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6553 ac_cv_sys_file_offset_bits=unknown
6554 break
6555 done
6556 fi
6557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
6558 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
6559 case $ac_cv_sys_file_offset_bits in #(
6560 no | unknown) ;;
6561 *)
6562 cat >>confdefs.h <<_ACEOF
6563 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
6564 _ACEOF
6565 ;;
6566 esac
6567 rm -rf conftest*
6568 if test $ac_cv_sys_file_offset_bits = unknown; then
6569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
6570 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
6571 if test "${ac_cv_sys_large_files+set}" = set; then :
6572 $as_echo_n "(cached) " >&6
6573 else
6574 while :; do
6575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6576 /* end confdefs.h. */
6577 #include <sys/types.h>
6578 /* Check that off_t can represent 2**63 - 1 correctly.
6579 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6580 since some C++ compilers masquerading as C compilers
6581 incorrectly reject 9223372036854775807. */
6582 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6583 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6584 && LARGE_OFF_T % 2147483647 == 1)
6585 ? 1 : -1];
6586 int
6587 main ()
6588 {
6589
6590 ;
6591 return 0;
6592 }
6593 _ACEOF
6594 if ac_fn_c_try_compile "$LINENO"; then :
6595 ac_cv_sys_large_files=no; break
6596 fi
6597 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6598 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6599 /* end confdefs.h. */
6600 #define _LARGE_FILES 1
6601 #include <sys/types.h>
6602 /* Check that off_t can represent 2**63 - 1 correctly.
6603 We can't simply define LARGE_OFF_T to be 9223372036854775807,
6604 since some C++ compilers masquerading as C compilers
6605 incorrectly reject 9223372036854775807. */
6606 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
6607 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
6608 && LARGE_OFF_T % 2147483647 == 1)
6609 ? 1 : -1];
6610 int
6611 main ()
6612 {
6613
6614 ;
6615 return 0;
6616 }
6617 _ACEOF
6618 if ac_fn_c_try_compile "$LINENO"; then :
6619 ac_cv_sys_large_files=1; break
6620 fi
6621 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6622 ac_cv_sys_large_files=unknown
6623 break
6624 done
6625 fi
6626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
6627 $as_echo "$ac_cv_sys_large_files" >&6; }
6628 case $ac_cv_sys_large_files in #(
6629 no | unknown) ;;
6630 *)
6631 cat >>confdefs.h <<_ACEOF
6632 #define _LARGE_FILES $ac_cv_sys_large_files
6633 _ACEOF
6634 ;;
6635 esac
6636 rm -rf conftest*
6637 fi
6638
6639
6640 fi
6641
6642 case $ac_cv_prog_cc_stdc in #(
6643 no) :
6644 ac_cv_prog_cc_c99=no; ac_cv_prog_cc_c89=no ;; #(
6645 *) :
6646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C99" >&5
6647 $as_echo_n "checking for $CC option to accept ISO C99... " >&6; }
6648 if test "${ac_cv_prog_cc_c99+set}" = set; then :
6649 $as_echo_n "(cached) " >&6
6650 else
6651 ac_cv_prog_cc_c99=no
6652 ac_save_CC=$CC
6653 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6654 /* end confdefs.h. */
6655 #include <stdarg.h>
6656 #include <stdbool.h>
6657 #include <stdlib.h>
6658 #include <wchar.h>
6659 #include <stdio.h>
6660
6661 // Check varargs macros. These examples are taken from C99 6.10.3.5.
6662 #define debug(...) fprintf (stderr, __VA_ARGS__)
6663 #define showlist(...) puts (#__VA_ARGS__)
6664 #define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
6665 static void
6666 test_varargs_macros (void)
6667 {
6668 int x = 1234;
6669 int y = 5678;
6670 debug ("Flag");
6671 debug ("X = %d\n", x);
6672 showlist (The first, second, and third items.);
6673 report (x>y, "x is %d but y is %d", x, y);
6674 }
6675
6676 // Check long long types.
6677 #define BIG64 18446744073709551615ull
6678 #define BIG32 4294967295ul
6679 #define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
6680 #if !BIG_OK
6681 your preprocessor is broken;
6682 #endif
6683 #if BIG_OK
6684 #else
6685 your preprocessor is broken;
6686 #endif
6687 static long long int bignum = -9223372036854775807LL;
6688 static unsigned long long int ubignum = BIG64;
6689
6690 struct incomplete_array
6691 {
6692 int datasize;
6693 double data[];
6694 };
6695
6696 struct named_init {
6697 int number;
6698 const wchar_t *name;
6699 double average;
6700 };
6701
6702 typedef const char *ccp;
6703
6704 static inline int
6705 test_restrict (ccp restrict text)
6706 {
6707 // See if C++-style comments work.
6708 // Iterate through items via the restricted pointer.
6709 // Also check for declarations in for loops.
6710 for (unsigned int i = 0; *(text+i) != '\0'; ++i)
6711 continue;
6712 return 0;
6713 }
6714
6715 // Check varargs and va_copy.
6716 static void
6717 test_varargs (const char *format, ...)
6718 {
6719 va_list args;
6720 va_start (args, format);
6721 va_list args_copy;
6722 va_copy (args_copy, args);
6723
6724 const char *str;
6725 int number;
6726 float fnumber;
6727
6728 while (*format)
6729 {
6730 switch (*format++)
6731 {
6732 case 's': // string
6733 str = va_arg (args_copy, const char *);
6734 break;
6735 case 'd': // int
6736 number = va_arg (args_copy, int);
6737 break;
6738 case 'f': // float
6739 fnumber = va_arg (args_copy, double);
6740 break;
6741 default:
6742 break;
6743 }
6744 }
6745 va_end (args_copy);
6746 va_end (args);
6747 }
6748
6749 int
6750 main ()
6751 {
6752
6753 // Check bool.
6754 _Bool success = false;
6755
6756 // Check restrict.
6757 if (test_restrict ("String literal") == 0)
6758 success = true;
6759 char *restrict newvar = "Another string";
6760
6761 // Check varargs.
6762 test_varargs ("s, d' f .", "string", 65, 34.234);
6763 test_varargs_macros ();
6764
6765 // Check flexible array members.
6766 struct incomplete_array *ia =
6767 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
6768 ia->datasize = 10;
6769 for (int i = 0; i < ia->datasize; ++i)
6770 ia->data[i] = i * 1.234;
6771
6772 // Check named initializers.
6773 struct named_init ni = {
6774 .number = 34,
6775 .name = L"Test wide string",
6776 .average = 543.34343,
6777 };
6778
6779 ni.number = 58;
6780
6781 int dynamic_array[ni.number];
6782 dynamic_array[ni.number - 1] = 543;
6783
6784 // work around unused variable warnings
6785 return (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == 'x'
6786 || dynamic_array[ni.number - 1] != 543);
6787
6788 ;
6789 return 0;
6790 }
6791 _ACEOF
6792 for ac_arg in '' -std=gnu99 -std=c99 -c99 -AC99 -xc99=all -qlanglvl=extc99
6793 do
6794 CC="$ac_save_CC $ac_arg"
6795 if ac_fn_c_try_compile "$LINENO"; then :
6796 ac_cv_prog_cc_c99=$ac_arg
6797 fi
6798 rm -f core conftest.err conftest.$ac_objext
6799 test "x$ac_cv_prog_cc_c99" != "xno" && break
6800 done
6801 rm -f conftest.$ac_ext
6802 CC=$ac_save_CC
6803
6804 fi
6805 # AC_CACHE_VAL
6806 case "x$ac_cv_prog_cc_c99" in
6807 x)
6808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6809 $as_echo "none needed" >&6; } ;;
6810 xno)
6811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6812 $as_echo "unsupported" >&6; } ;;
6813 *)
6814 CC="$CC $ac_cv_prog_cc_c99"
6815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
6816 $as_echo "$ac_cv_prog_cc_c99" >&6; } ;;
6817 esac
6818 if test "x$ac_cv_prog_cc_c99" != xno; then :
6819 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
6820 else
6821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
6822 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
6823 if test "${ac_cv_prog_cc_c89+set}" = set; then :
6824 $as_echo_n "(cached) " >&6
6825 else
6826 ac_cv_prog_cc_c89=no
6827 ac_save_CC=$CC
6828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6829 /* end confdefs.h. */
6830 #include <stdarg.h>
6831 #include <stdio.h>
6832 #include <sys/types.h>
6833 #include <sys/stat.h>
6834 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */
6835 struct buf { int x; };
6836 FILE * (*rcsopen) (struct buf *, struct stat *, int);
6837 static char *e (p, i)
6838 char **p;
6839 int i;
6840 {
6841 return p[i];
6842 }
6843 static char *f (char * (*g) (char **, int), char **p, ...)
6844 {
6845 char *s;
6846 va_list v;
6847 va_start (v,p);
6848 s = g (p, va_arg (v,int));
6849 va_end (v);
6850 return s;
6851 }
6852
6853 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
6854 function prototypes and stuff, but not '\xHH' hex character constants.
6855 These don't provoke an error unfortunately, instead are silently treated
6856 as 'x'. The following induces an error, until -std is added to get
6857 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an
6858 array size at least. It's necessary to write '\x00'==0 to get something
6859 that's true only with -std. */
6860 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
6861
6862 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
6863 inside strings and character constants. */
6864 #define FOO(x) 'x'
6865 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
6866
6867 int test (int i, double x);
6868 struct s1 {int (*f) (int a);};
6869 struct s2 {int (*f) (double a);};
6870 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
6871 int argc;
6872 char **argv;
6873 int
6874 main ()
6875 {
6876 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1];
6877 ;
6878 return 0;
6879 }
6880 _ACEOF
6881 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
6882 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
6883 do
6884 CC="$ac_save_CC $ac_arg"
6885 if ac_fn_c_try_compile "$LINENO"; then :
6886 ac_cv_prog_cc_c89=$ac_arg
6887 fi
6888 rm -f core conftest.err conftest.$ac_objext
6889 test "x$ac_cv_prog_cc_c89" != "xno" && break
6890 done
6891 rm -f conftest.$ac_ext
6892 CC=$ac_save_CC
6893
6894 fi
6895 # AC_CACHE_VAL
6896 case "x$ac_cv_prog_cc_c89" in
6897 x)
6898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6899 $as_echo "none needed" >&6; } ;;
6900 xno)
6901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6902 $as_echo "unsupported" >&6; } ;;
6903 *)
6904 CC="$CC $ac_cv_prog_cc_c89"
6905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
6906 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
6907 esac
6908 if test "x$ac_cv_prog_cc_c89" != xno; then :
6909 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
6910 else
6911 ac_cv_prog_cc_stdc=no
6912 fi
6913
6914 fi
6915 ;;
6916 esac
6917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO Standard C" >&5
6918 $as_echo_n "checking for $CC option to accept ISO Standard C... " >&6; }
6919 if test "${ac_cv_prog_cc_stdc+set}" = set; then :
6920 $as_echo_n "(cached) " >&6
6921 fi
6922
6923 case $ac_cv_prog_cc_stdc in #(
6924 no) :
6925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
6926 $as_echo "unsupported" >&6; } ;; #(
6927 '') :
6928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
6929 $as_echo "none needed" >&6; } ;; #(
6930 *) :
6931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_stdc" >&5
6932 $as_echo "$ac_cv_prog_cc_stdc" >&6; } ;;
6933 esac
6934
6935
6936
6937 # Code from module alloca-opt:
6938 # Code from module allocator:
6939 # Code from module careadlinkat:
6940 # Code from module crypto/md5:
6941 # Code from module crypto/sha1:
6942 # Code from module crypto/sha256:
6943 # Code from module crypto/sha512:
6944 # Code from module dosname:
6945 # Code from module dtoastr:
6946 # Code from module dup2:
6947 # Code from module extensions:
6948
6949 # Code from module filemode:
6950 # Code from module getloadavg:
6951 # Code from module getopt-gnu:
6952 # Code from module getopt-posix:
6953 # Code from module gettext-h:
6954 # Code from module ignore-value:
6955 # Code from module include_next:
6956 # Code from module intprops:
6957 # Code from module inttypes-incomplete:
6958 # Code from module largefile:
6959
6960 # Code from module lstat:
6961 # Code from module mktime:
6962 # Code from module multiarch:
6963 # Code from module nocrash:
6964 # Code from module pathmax:
6965 # Code from module pthread_sigmask:
6966 # Code from module readlink:
6967 # Code from module signal-h:
6968 # Code from module sigprocmask:
6969 # Code from module snippet/_Noreturn:
6970 # Code from module snippet/arg-nonnull:
6971 # Code from module snippet/c++defs:
6972 # Code from module snippet/warn-on-use:
6973 # Code from module socklen:
6974 # Code from module ssize_t:
6975 # Code from module stat:
6976 # Code from module stdarg:
6977
6978
6979
6980 # Code from module stdbool:
6981 # Code from module stddef:
6982 # Code from module stdint:
6983 # Code from module stdio:
6984 # Code from module stdlib:
6985 # Code from module strftime:
6986 # Code from module strtoimax:
6987 # Code from module strtoll:
6988 # Code from module strtoull:
6989 # Code from module strtoumax:
6990 # Code from module symlink:
6991 # Code from module sys_stat:
6992 # Code from module time:
6993 # Code from module time_r:
6994 # Code from module u64:
6995 # Code from module unistd:
6996 # Code from module verify:
6997
6998
6999 # On Suns, sometimes $CPP names a directory.
7000 if test -n "$CPP" && test -d "$CPP"; then
7001 CPP=
7002 fi
7003
7004 ## If not using gcc, and on Solaris, and no CPP specified, see if
7005 ## using a Sun compiler, which needs -Xs to prevent whitespace.
7006 if test x"$GCC" != xyes && test x"$emacs_check_sunpro_c" = xyes && \
7007 test x"$CPP" = x; then
7008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using a Sun C compiler" >&5
7009 $as_echo_n "checking whether we are using a Sun C compiler... " >&6; }
7010 if test "${emacs_cv_sunpro_c+set}" = set; then :
7011 $as_echo_n "(cached) " >&6
7012 else
7013 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7014 /* end confdefs.h. */
7015
7016 int
7017 main ()
7018 {
7019 #ifndef __SUNPRO_C
7020 fail;
7021 #endif
7022
7023 ;
7024 return 0;
7025 }
7026 _ACEOF
7027 if ac_fn_c_try_link "$LINENO"; then :
7028 emacs_cv_sunpro_c=yes
7029 else
7030 emacs_cv_sunpro_c=no
7031 fi
7032 rm -f core conftest.err conftest.$ac_objext \
7033 conftest$ac_exeext conftest.$ac_ext
7034 fi
7035
7036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_sunpro_c" >&5
7037 $as_echo "$emacs_cv_sunpro_c" >&6; }
7038
7039 if test x"$emacs_cv_sunpro_c" = xyes; then
7040 NON_GNU_CPP="$CC -E -Xs"
7041 fi
7042 fi
7043
7044 #### Some systems specify a CPP to use unless we are using GCC.
7045 #### Now that we know whether we are using GCC, we can decide whether
7046 #### to use that one.
7047 if test "x$NON_GNU_CPP" != x && test x$GCC != xyes && test "x$CPP" = x
7048 then
7049 CPP="$NON_GNU_CPP"
7050 fi
7051
7052 #### Some systems specify a CC to use unless we are using GCC.
7053 #### Now that we know whether we are using GCC, we can decide whether
7054 #### to use that one.
7055 if test "x$NON_GNU_CC" != x && test x$GCC != xyes &&
7056 test x$cc_specified != xyes
7057 then
7058 CC="$NON_GNU_CC"
7059 fi
7060
7061 if test x$GCC = xyes; then
7062 test "x$GCC_TEST_OPTIONS" != x && CC="$CC $GCC_TEST_OPTIONS"
7063 else
7064 test "x$NON_GCC_TEST_OPTIONS" != x && CC="$CC $NON_GCC_TEST_OPTIONS"
7065 fi
7066
7067 ### Use -Wdeclaration-after-statement if the compiler supports it
7068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wdeclaration-after-statement" >&5
7069 $as_echo_n "checking whether gcc understands -Wdeclaration-after-statement... " >&6; }
7070 SAVE_CFLAGS="$CFLAGS"
7071 CFLAGS="$CFLAGS -Wdeclaration-after-statement"
7072 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7073 /* end confdefs.h. */
7074
7075 int
7076 main ()
7077 {
7078
7079 ;
7080 return 0;
7081 }
7082 _ACEOF
7083 if ac_fn_c_try_compile "$LINENO"; then :
7084 has_option=yes
7085 else
7086 has_option=no
7087 fi
7088 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7089 if test $has_option = yes; then
7090 C_WARNINGS_SWITCH="-Wdeclaration-after-statement $C_WARNINGS_SWITCH"
7091 fi
7092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7093 $as_echo "$has_option" >&6; }
7094 CFLAGS="$SAVE_CFLAGS"
7095 unset has_option
7096 unset SAVE_CFLAGS
7097
7098 ### Use -Wold-style-definition if the compiler supports it
7099 # This can be removed when conversion to standard C is finished.
7100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wold-style-definition" >&5
7101 $as_echo_n "checking whether gcc understands -Wold-style-definition... " >&6; }
7102 SAVE_CFLAGS="$CFLAGS"
7103 CFLAGS="$CFLAGS -Wold-style-definition"
7104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7105 /* end confdefs.h. */
7106
7107 int
7108 main ()
7109 {
7110
7111 ;
7112 return 0;
7113 }
7114 _ACEOF
7115 if ac_fn_c_try_compile "$LINENO"; then :
7116 has_option=yes
7117 else
7118 has_option=no
7119 fi
7120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7121 if test $has_option = yes; then
7122 C_WARNINGS_SWITCH="-Wold-style-definition $C_WARNINGS_SWITCH"
7123 fi
7124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7125 $as_echo "$has_option" >&6; }
7126 CFLAGS="$SAVE_CFLAGS"
7127 unset has_option
7128 unset SAVE_CFLAGS
7129
7130 ### Use -Wimplicit-function-declaration if the compiler supports it
7131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -Wimplicit-function-declaration" >&5
7132 $as_echo_n "checking whether gcc understands -Wimplicit-function-declaration... " >&6; }
7133 SAVE_CFLAGS="$CFLAGS"
7134 CFLAGS="$CFLAGS -Wimplicit-function-declaration"
7135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7136 /* end confdefs.h. */
7137
7138 int
7139 main ()
7140 {
7141
7142 ;
7143 return 0;
7144 }
7145 _ACEOF
7146 if ac_fn_c_try_compile "$LINENO"; then :
7147 has_option=yes
7148 else
7149 has_option=no
7150 fi
7151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7152 if test $has_option = yes; then
7153 C_WARNINGS_SWITCH="-Wimplicit-function-declaration $C_WARNINGS_SWITCH"
7154 fi
7155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_option" >&5
7156 $as_echo "$has_option" >&6; }
7157 CFLAGS="$SAVE_CFLAGS"
7158 unset has_option
7159 unset SAVE_CFLAGS
7160
7161
7162
7163
7164 #### Some other nice autoconf tests.
7165
7166 ac_ext=c
7167 ac_cpp='$CPP $CPPFLAGS'
7168 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7169 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7170 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
7172 $as_echo_n "checking how to run the C preprocessor... " >&6; }
7173 # On Suns, sometimes $CPP names a directory.
7174 if test -n "$CPP" && test -d "$CPP"; then
7175 CPP=
7176 fi
7177 if test -z "$CPP"; then
7178 if test "${ac_cv_prog_CPP+set}" = set; then :
7179 $as_echo_n "(cached) " >&6
7180 else
7181 # Double quotes because CPP needs to be expanded
7182 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
7183 do
7184 ac_preproc_ok=false
7185 for ac_c_preproc_warn_flag in '' yes
7186 do
7187 # Use a header file that comes with gcc, so configuring glibc
7188 # with a fresh cross-compiler works.
7189 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7190 # <limits.h> exists even on freestanding compilers.
7191 # On the NeXT, cc -E runs the code through the compiler's parser,
7192 # not just through cpp. "Syntax error" is here to catch this case.
7193 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7194 /* end confdefs.h. */
7195 #ifdef __STDC__
7196 # include <limits.h>
7197 #else
7198 # include <assert.h>
7199 #endif
7200 Syntax error
7201 _ACEOF
7202 if ac_fn_c_try_cpp "$LINENO"; then :
7203
7204 else
7205 # Broken: fails on valid input.
7206 continue
7207 fi
7208 rm -f conftest.err conftest.$ac_ext
7209
7210 # OK, works on sane cases. Now check whether nonexistent headers
7211 # can be detected and how.
7212 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7213 /* end confdefs.h. */
7214 #include <ac_nonexistent.h>
7215 _ACEOF
7216 if ac_fn_c_try_cpp "$LINENO"; then :
7217 # Broken: success on invalid input.
7218 continue
7219 else
7220 # Passes both tests.
7221 ac_preproc_ok=:
7222 break
7223 fi
7224 rm -f conftest.err conftest.$ac_ext
7225
7226 done
7227 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7228 rm -f conftest.err conftest.$ac_ext
7229 if $ac_preproc_ok; then :
7230 break
7231 fi
7232
7233 done
7234 ac_cv_prog_CPP=$CPP
7235
7236 fi
7237 CPP=$ac_cv_prog_CPP
7238 else
7239 ac_cv_prog_CPP=$CPP
7240 fi
7241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
7242 $as_echo "$CPP" >&6; }
7243 ac_preproc_ok=false
7244 for ac_c_preproc_warn_flag in '' yes
7245 do
7246 # Use a header file that comes with gcc, so configuring glibc
7247 # with a fresh cross-compiler works.
7248 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
7249 # <limits.h> exists even on freestanding compilers.
7250 # On the NeXT, cc -E runs the code through the compiler's parser,
7251 # not just through cpp. "Syntax error" is here to catch this case.
7252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7253 /* end confdefs.h. */
7254 #ifdef __STDC__
7255 # include <limits.h>
7256 #else
7257 # include <assert.h>
7258 #endif
7259 Syntax error
7260 _ACEOF
7261 if ac_fn_c_try_cpp "$LINENO"; then :
7262
7263 else
7264 # Broken: fails on valid input.
7265 continue
7266 fi
7267 rm -f conftest.err conftest.$ac_ext
7268
7269 # OK, works on sane cases. Now check whether nonexistent headers
7270 # can be detected and how.
7271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7272 /* end confdefs.h. */
7273 #include <ac_nonexistent.h>
7274 _ACEOF
7275 if ac_fn_c_try_cpp "$LINENO"; then :
7276 # Broken: success on invalid input.
7277 continue
7278 else
7279 # Passes both tests.
7280 ac_preproc_ok=:
7281 break
7282 fi
7283 rm -f conftest.err conftest.$ac_ext
7284
7285 done
7286 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
7287 rm -f conftest.err conftest.$ac_ext
7288 if $ac_preproc_ok; then :
7289
7290 else
7291 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
7292 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
7293 as_fn_error "C preprocessor \"$CPP\" fails sanity check
7294 See \`config.log' for more details." "$LINENO" 5; }
7295 fi
7296
7297 ac_ext=c
7298 ac_cpp='$CPP $CPPFLAGS'
7299 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
7300 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
7301 ac_compiler_gnu=$ac_cv_c_compiler_gnu
7302
7303
7304 if test "x$RANLIB" = x; then
7305 if test -n "$ac_tool_prefix"; then
7306 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
7307 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
7308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7309 $as_echo_n "checking for $ac_word... " >&6; }
7310 if test "${ac_cv_prog_RANLIB+set}" = set; then :
7311 $as_echo_n "(cached) " >&6
7312 else
7313 if test -n "$RANLIB"; then
7314 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
7315 else
7316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7317 for as_dir in $PATH
7318 do
7319 IFS=$as_save_IFS
7320 test -z "$as_dir" && as_dir=.
7321 for ac_exec_ext in '' $ac_executable_extensions; do
7322 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7323 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
7324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7325 break 2
7326 fi
7327 done
7328 done
7329 IFS=$as_save_IFS
7330
7331 fi
7332 fi
7333 RANLIB=$ac_cv_prog_RANLIB
7334 if test -n "$RANLIB"; then
7335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
7336 $as_echo "$RANLIB" >&6; }
7337 else
7338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7339 $as_echo "no" >&6; }
7340 fi
7341
7342
7343 fi
7344 if test -z "$ac_cv_prog_RANLIB"; then
7345 ac_ct_RANLIB=$RANLIB
7346 # Extract the first word of "ranlib", so it can be a program name with args.
7347 set dummy ranlib; ac_word=$2
7348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7349 $as_echo_n "checking for $ac_word... " >&6; }
7350 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
7351 $as_echo_n "(cached) " >&6
7352 else
7353 if test -n "$ac_ct_RANLIB"; then
7354 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
7355 else
7356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7357 for as_dir in $PATH
7358 do
7359 IFS=$as_save_IFS
7360 test -z "$as_dir" && as_dir=.
7361 for ac_exec_ext in '' $ac_executable_extensions; do
7362 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7363 ac_cv_prog_ac_ct_RANLIB="ranlib"
7364 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7365 break 2
7366 fi
7367 done
7368 done
7369 IFS=$as_save_IFS
7370
7371 fi
7372 fi
7373 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
7374 if test -n "$ac_ct_RANLIB"; then
7375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
7376 $as_echo "$ac_ct_RANLIB" >&6; }
7377 else
7378 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7379 $as_echo "no" >&6; }
7380 fi
7381
7382 if test "x$ac_ct_RANLIB" = x; then
7383 RANLIB=":"
7384 else
7385 case $cross_compiling:$ac_tool_warned in
7386 yes:)
7387 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
7388 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
7389 ac_tool_warned=yes ;;
7390 esac
7391 RANLIB=$ac_ct_RANLIB
7392 fi
7393 else
7394 RANLIB="$ac_cv_prog_RANLIB"
7395 fi
7396
7397 fi
7398
7399 ## Although we're running on an amd64 kernel, we're actually compiling for
7400 ## the x86 architecture. The user should probably have provided an
7401 ## explicit --build to `configure', but if everything else than the kernel
7402 ## is running in i386 mode, we can help them out.
7403 if test "$machine" = "amdx86-64"; then
7404 ac_fn_c_check_decl "$LINENO" "i386" "ac_cv_have_decl_i386" "$ac_includes_default"
7405 if test "x$ac_cv_have_decl_i386" = x""yes; then :
7406
7407 fi
7408
7409 if test "$ac_cv_have_decl_i386" = "yes"; then
7410 canonical=`echo "$canonical" | sed -e 's/^amd64/i386/' -e 's/^x86_64/i386/'`
7411 machine=intel386
7412 machfile="m/${machine}.h"
7413 fi
7414 fi
7415
7416 # Extract the first word of "install-info", so it can be a program name with args.
7417 set dummy install-info; ac_word=$2
7418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7419 $as_echo_n "checking for $ac_word... " >&6; }
7420 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7421 $as_echo_n "(cached) " >&6
7422 else
7423 case $INSTALL_INFO in
7424 [\\/]* | ?:[\\/]*)
7425 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7426 ;;
7427 *)
7428 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7429 for as_dir in $PATH
7430 do
7431 IFS=$as_save_IFS
7432 test -z "$as_dir" && as_dir=.
7433 for ac_exec_ext in '' $ac_executable_extensions; do
7434 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7435 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7436 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7437 break 2
7438 fi
7439 done
7440 done
7441 IFS=$as_save_IFS
7442
7443 ;;
7444 esac
7445 fi
7446 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7447 if test -n "$INSTALL_INFO"; then
7448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7449 $as_echo "$INSTALL_INFO" >&6; }
7450 else
7451 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7452 $as_echo "no" >&6; }
7453 fi
7454
7455
7456 # Extract the first word of "install-info", so it can be a program name with args.
7457 set dummy install-info; ac_word=$2
7458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7459 $as_echo_n "checking for $ac_word... " >&6; }
7460 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7461 $as_echo_n "(cached) " >&6
7462 else
7463 case $INSTALL_INFO in
7464 [\\/]* | ?:[\\/]*)
7465 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7466 ;;
7467 *)
7468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7469 for as_dir in /usr/sbin
7470 do
7471 IFS=$as_save_IFS
7472 test -z "$as_dir" && as_dir=.
7473 for ac_exec_ext in '' $ac_executable_extensions; do
7474 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7475 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7477 break 2
7478 fi
7479 done
7480 done
7481 IFS=$as_save_IFS
7482
7483 ;;
7484 esac
7485 fi
7486 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7487 if test -n "$INSTALL_INFO"; then
7488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7489 $as_echo "$INSTALL_INFO" >&6; }
7490 else
7491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7492 $as_echo "no" >&6; }
7493 fi
7494
7495
7496 # Extract the first word of "install-info", so it can be a program name with args.
7497 set dummy install-info; ac_word=$2
7498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7499 $as_echo_n "checking for $ac_word... " >&6; }
7500 if test "${ac_cv_path_INSTALL_INFO+set}" = set; then :
7501 $as_echo_n "(cached) " >&6
7502 else
7503 case $INSTALL_INFO in
7504 [\\/]* | ?:[\\/]*)
7505 ac_cv_path_INSTALL_INFO="$INSTALL_INFO" # Let the user override the test with a path.
7506 ;;
7507 *)
7508 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7509 for as_dir in /sbin
7510 do
7511 IFS=$as_save_IFS
7512 test -z "$as_dir" && as_dir=.
7513 for ac_exec_ext in '' $ac_executable_extensions; do
7514 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7515 ac_cv_path_INSTALL_INFO="$as_dir/$ac_word$ac_exec_ext"
7516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7517 break 2
7518 fi
7519 done
7520 done
7521 IFS=$as_save_IFS
7522
7523 test -z "$ac_cv_path_INSTALL_INFO" && ac_cv_path_INSTALL_INFO=":"
7524 ;;
7525 esac
7526 fi
7527 INSTALL_INFO=$ac_cv_path_INSTALL_INFO
7528 if test -n "$INSTALL_INFO"; then
7529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL_INFO" >&5
7530 $as_echo "$INSTALL_INFO" >&6; }
7531 else
7532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7533 $as_echo "no" >&6; }
7534 fi
7535
7536
7537 # Extract the first word of "gzip", so it can be a program name with args.
7538 set dummy gzip; ac_word=$2
7539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7540 $as_echo_n "checking for $ac_word... " >&6; }
7541 if test "${ac_cv_path_GZIP_PROG+set}" = set; then :
7542 $as_echo_n "(cached) " >&6
7543 else
7544 case $GZIP_PROG in
7545 [\\/]* | ?:[\\/]*)
7546 ac_cv_path_GZIP_PROG="$GZIP_PROG" # Let the user override the test with a path.
7547 ;;
7548 *)
7549 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7550 for as_dir in $PATH
7551 do
7552 IFS=$as_save_IFS
7553 test -z "$as_dir" && as_dir=.
7554 for ac_exec_ext in '' $ac_executable_extensions; do
7555 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7556 ac_cv_path_GZIP_PROG="$as_dir/$ac_word$ac_exec_ext"
7557 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7558 break 2
7559 fi
7560 done
7561 done
7562 IFS=$as_save_IFS
7563
7564 ;;
7565 esac
7566 fi
7567 GZIP_PROG=$ac_cv_path_GZIP_PROG
7568 if test -n "$GZIP_PROG"; then
7569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP_PROG" >&5
7570 $as_echo "$GZIP_PROG" >&6; }
7571 else
7572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7573 $as_echo "no" >&6; }
7574 fi
7575
7576
7577
7578
7579 ## Need makeinfo >= 4.7 (?) to build the manuals.
7580 # Extract the first word of "makeinfo", so it can be a program name with args.
7581 set dummy makeinfo; ac_word=$2
7582 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7583 $as_echo_n "checking for $ac_word... " >&6; }
7584 if test "${ac_cv_path_MAKEINFO+set}" = set; then :
7585 $as_echo_n "(cached) " >&6
7586 else
7587 case $MAKEINFO in
7588 [\\/]* | ?:[\\/]*)
7589 ac_cv_path_MAKEINFO="$MAKEINFO" # Let the user override the test with a path.
7590 ;;
7591 *)
7592 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7593 for as_dir in $PATH
7594 do
7595 IFS=$as_save_IFS
7596 test -z "$as_dir" && as_dir=.
7597 for ac_exec_ext in '' $ac_executable_extensions; do
7598 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7599 ac_cv_path_MAKEINFO="$as_dir/$ac_word$ac_exec_ext"
7600 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
7601 break 2
7602 fi
7603 done
7604 done
7605 IFS=$as_save_IFS
7606
7607 test -z "$ac_cv_path_MAKEINFO" && ac_cv_path_MAKEINFO="no"
7608 ;;
7609 esac
7610 fi
7611 MAKEINFO=$ac_cv_path_MAKEINFO
7612 if test -n "$MAKEINFO"; then
7613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5
7614 $as_echo "$MAKEINFO" >&6; }
7615 else
7616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7617 $as_echo "no" >&6; }
7618 fi
7619
7620
7621 if test "$MAKEINFO" != "no" && \
7622 test x"`$MAKEINFO --version 2> /dev/null | $EGREP 'texinfo[^0-9]*([1-4][0-9]+|[5-9]|4\.[7-9]|4\.[1-6][0-9]+)'`" = x; then
7623 MAKEINFO=no
7624 fi
7625
7626 ## Makeinfo is unusual. For a released Emacs, the manuals are
7627 ## pre-built, and not deleted by the normal clean rules. makeinfo is
7628 ## therefore in the category of "special tools" not normally required, which
7629 ## configure does not have to check for (eg autoconf itself).
7630 ## In a Bazaar checkout on the other hand, the manuals are not included.
7631 ## So makeinfo is a requirement to build from Bazaar, and configure
7632 ## should test for it as it does for any other build requirement.
7633 ## We use the presence of $srcdir/info/emacs to distinguish a release,
7634 ## with pre-built manuals, from a Bazaar checkout.
7635 HAVE_MAKEINFO=yes
7636
7637 if test "$MAKEINFO" = "no"; then
7638 MAKEINFO=makeinfo
7639 if test "x${with_makeinfo}" = "xno"; then
7640 HAVE_MAKEINFO=no
7641 elif test ! -e $srcdir/info/emacs; then
7642 as_fn_error "You do not seem to have makeinfo >= 4.7, and your
7643 source tree does not seem to have pre-built manuals in the \`info' directory.
7644 Either install a suitable version of makeinfo, or re-run configure
7645 with the \`--without-makeinfo' option to build without the manuals. " "$LINENO" 5
7646 fi
7647 fi
7648
7649
7650
7651 if test x$GCC = xyes; then
7652 test "x$GCC_LINK_TEST_OPTIONS" != x && \
7653 ac_link="$ac_link $GCC_LINK_TEST_OPTIONS"
7654 else
7655 test "x$NON_GCC_LINK_TEST_OPTIONS" != x && \
7656 ac_link="$ac_link $NON_GCC_LINK_TEST_OPTIONS"
7657 fi
7658
7659
7660 late_LDFLAGS=$LDFLAGS
7661 if test x$GCC = xyes; then
7662 LDFLAGS="$LDFLAGS -Wl,-znocombreloc"
7663 else
7664 LDFLAGS="$LDFLAGS -znocombreloc"
7665 fi
7666
7667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -znocombreloc" >&5
7668 $as_echo_n "checking for -znocombreloc... " >&6; }
7669 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7670 /* end confdefs.h. */
7671
7672 int
7673 main ()
7674 {
7675
7676 ;
7677 return 0;
7678 }
7679 _ACEOF
7680 if ac_fn_c_try_link "$LINENO"; then :
7681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7682 $as_echo "yes" >&6; }
7683 else
7684 LDFLAGS=$late_LDFLAGS
7685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7686 $as_echo "no" >&6; }
7687 fi
7688 rm -f core conftest.err conftest.$ac_objext \
7689 conftest$ac_exeext conftest.$ac_ext
7690
7691
7692 # The value of CPP is a quoted variable reference, so we need to do this
7693 # to get its actual value...
7694 CPP=`eval "echo $CPP"`
7695
7696
7697 test "x$CANNOT_DUMP" = "x" && CANNOT_DUMP=no
7698 case "$opsys" in
7699 your-opsys-here) CANNOT_DUMP=yes ;;
7700 esac
7701
7702 test "$CANNOT_DUMP" = "yes" && \
7703
7704 $as_echo "#define CANNOT_DUMP 1" >>confdefs.h
7705
7706
7707
7708
7709
7710 UNEXEC_OBJ=unexelf.o
7711 case "$opsys" in
7712 # MSDOS uses unexcoff.o
7713 # MSWindows uses unexw32.o
7714 aix4-2)
7715 UNEXEC_OBJ=unexaix.o
7716 ;;
7717 cygwin)
7718 UNEXEC_OBJ=unexcw.o
7719 ;;
7720 darwin)
7721 UNEXEC_OBJ=unexmacosx.o
7722 ;;
7723 hpux10-20 | hpux11)
7724 UNEXEC_OBJ=unexhp9k800.o
7725 ;;
7726 sol2-10)
7727 # Use the Solaris dldump() function, called from unexsol.c, to dump
7728 # emacs, instead of the generic ELF dump code found in unexelf.c.
7729 # The resulting binary has a complete symbol table, and is better
7730 # for debugging and other observability tools (debuggers, pstack, etc).
7731 #
7732 # If you encounter a problem using dldump(), please consider sending
7733 # a message to the OpenSolaris tools-linking mailing list:
7734 # http://mail.opensolaris.org/mailman/listinfo/tools-linking
7735 #
7736 # It is likely that dldump() works with older Solaris too, but this has
7737 # not been tested, so for now this change is for Solaris 10 or newer.
7738 UNEXEC_OBJ=unexsol.o
7739 ;;
7740 esac
7741
7742 LD_SWITCH_SYSTEM=
7743 case "$opsys" in
7744 freebsd)
7745 ## Let `ld' find image libs and similar things in /usr/local/lib.
7746 ## The system compiler, GCC, has apparently been modified to not
7747 ## look there, contrary to what a stock GCC would do.
7748 LD_SWITCH_SYSTEM=-L/usr/local/lib
7749 ;;
7750
7751 gnu-linux)
7752 ## cpp test was "ifdef __mips__", but presumably this is equivalent...
7753 case $host_cpu in mips*) LD_SWITCH_SYSTEM="-G 0";; esac
7754 ;;
7755
7756 netbsd)
7757 LD_SWITCH_SYSTEM="-Wl,-rpath,/usr/pkg/lib -L/usr/pkg/lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib"
7758 ;;
7759
7760 openbsd)
7761 ## Han Boetes <han@mijncomputer.nl> says this is necessary,
7762 ## otherwise Emacs dumps core on elf systems.
7763 LD_SWITCH_SYSTEM="-Z"
7764 ;;
7765 esac
7766
7767
7768 ac_link="$ac_link $LD_SWITCH_SYSTEM"
7769
7770 ## This setting of LD_SWITCH_SYSTEM references LD_SWITCH_X_SITE_AUX,
7771 ## which has not been defined yet. When this was handled with cpp,
7772 ## it was expanded to null when configure sourced the s/*.h file.
7773 ## Thus LD_SWITCH_SYSTEM had different values in configure and the Makefiles.
7774 ## FIXME it would be cleaner to put this in LD_SWITCH_SYSTEM_TEMACS
7775 ## (or somesuch), but because it is supposed to go at the _front_
7776 ## of LD_SWITCH_SYSTEM, we cannot do that in exactly the same way.
7777 ## Compare with the gnu-linux case below, which added to the end
7778 ## of LD_SWITCH_SYSTEM, and so can instead go at the front of
7779 ## LD_SWITCH_SYSTEM_TEMACS.
7780 case "$opsys" in
7781 netbsd|openbsd)
7782 ## _AUX_RPATH is like _AUX, but uses -rpath instead of -R.
7783 LD_SWITCH_SYSTEM="\$(LD_SWITCH_X_SITE_AUX_RPATH) $LD_SWITCH_SYSTEM" ;;
7784 esac
7785
7786
7787 C_SWITCH_MACHINE=
7788 if test "$machine" = "alpha"; then
7789 ac_fn_c_check_decl "$LINENO" "__ELF__" "ac_cv_have_decl___ELF__" "$ac_includes_default"
7790 if test "x$ac_cv_have_decl___ELF__" = x""yes; then :
7791
7792 fi
7793
7794 if test "$ac_cv_have_decl___ELF__" = "yes"; then
7795 ## With ELF, make sure that all common symbols get allocated to in the
7796 ## data section. Otherwise, the dump of temacs may miss variables in
7797 ## the shared library that have been initialized. For example, with
7798 ## GNU libc, __malloc_initialized would normally be resolved to the
7799 ## shared library's .bss section, which is fatal.
7800 if test "x$GCC" = "xyes"; then
7801 C_SWITCH_MACHINE="-fno-common"
7802 else
7803 as_fn_error "What gives? Fix me if DEC Unix supports ELF now." "$LINENO" 5
7804 fi
7805 else
7806 UNEXEC_OBJ=unexalpha.o
7807 fi
7808 fi
7809
7810
7811
7812
7813 C_SWITCH_SYSTEM=
7814 ## Some programs in src produce warnings saying certain subprograms
7815 ## are too complex and need a MAXMEM value greater than 2000 for
7816 ## additional optimization. --nils@exp-math.uni-essen.de
7817 test "$opsys" = "aix4.2" && test "x$GCC" != "xyes" && \
7818 C_SWITCH_SYSTEM="-ma -qmaxmem=4000"
7819 ## gnu-linux might need -D_BSD_SOURCE on old libc5 systems.
7820 ## It is redundant in glibc2, since we define _GNU_SOURCE.
7821
7822
7823
7824 LIBS_SYSTEM=
7825 case "$opsys" in
7826 ## IBM's X11R5 uses -lIM and -liconv in AIX 3.2.2.
7827 aix4-2) LIBS_SYSTEM="-lrts -lIM -liconv" ;;
7828
7829 freebsd) LIBS_SYSTEM="-lutil" ;;
7830
7831 hpux*) LIBS_SYSTEM="-l:libdld.sl" ;;
7832
7833 sol2*) LIBS_SYSTEM="-lsocket -lnsl" ;;
7834
7835 ## Motif needs -lgen.
7836 unixware) LIBS_SYSTEM="-lsocket -lnsl -lelf -lgen" ;;
7837 esac
7838
7839
7840
7841 ### Make sure subsequent tests use flags consistent with the build flags.
7842
7843 if test x"${OVERRIDE_CPPFLAGS}" != x; then
7844 CPPFLAGS="${OVERRIDE_CPPFLAGS}"
7845 else
7846 CPPFLAGS="$C_SWITCH_SYSTEM $C_SWITCH_MACHINE $CPPFLAGS"
7847 fi
7848
7849 # Suppress obsolescent Autoconf test for size_t; Emacs assumes C89 or better.
7850
7851 # Likewise for obsolescent test for uid_t, gid_t; Emacs assumes them.
7852
7853
7854 # Check whether --enable-largefile was given.
7855 if test "${enable_largefile+set}" = set; then :
7856 enableval=$enable_largefile;
7857 fi
7858
7859 if test "$enable_largefile" != no; then
7860
7861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
7862 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
7863 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
7864 $as_echo_n "(cached) " >&6
7865 else
7866 ac_cv_sys_largefile_CC=no
7867 if test "$GCC" != yes; then
7868 ac_save_CC=$CC
7869 while :; do
7870 # IRIX 6.2 and later do not support large files by default,
7871 # so use the C compiler's -n32 option if that helps.
7872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7873 /* end confdefs.h. */
7874 #include <sys/types.h>
7875 /* Check that off_t can represent 2**63 - 1 correctly.
7876 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7877 since some C++ compilers masquerading as C compilers
7878 incorrectly reject 9223372036854775807. */
7879 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7880 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7881 && LARGE_OFF_T % 2147483647 == 1)
7882 ? 1 : -1];
7883 int
7884 main ()
7885 {
7886
7887 ;
7888 return 0;
7889 }
7890 _ACEOF
7891 if ac_fn_c_try_compile "$LINENO"; then :
7892 break
7893 fi
7894 rm -f core conftest.err conftest.$ac_objext
7895 CC="$CC -n32"
7896 if ac_fn_c_try_compile "$LINENO"; then :
7897 ac_cv_sys_largefile_CC=' -n32'; break
7898 fi
7899 rm -f core conftest.err conftest.$ac_objext
7900 break
7901 done
7902 CC=$ac_save_CC
7903 rm -f conftest.$ac_ext
7904 fi
7905 fi
7906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
7907 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
7908 if test "$ac_cv_sys_largefile_CC" != no; then
7909 CC=$CC$ac_cv_sys_largefile_CC
7910 fi
7911
7912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
7913 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
7914 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
7915 $as_echo_n "(cached) " >&6
7916 else
7917 while :; do
7918 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7919 /* end confdefs.h. */
7920 #include <sys/types.h>
7921 /* Check that off_t can represent 2**63 - 1 correctly.
7922 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7923 since some C++ compilers masquerading as C compilers
7924 incorrectly reject 9223372036854775807. */
7925 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7926 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7927 && LARGE_OFF_T % 2147483647 == 1)
7928 ? 1 : -1];
7929 int
7930 main ()
7931 {
7932
7933 ;
7934 return 0;
7935 }
7936 _ACEOF
7937 if ac_fn_c_try_compile "$LINENO"; then :
7938 ac_cv_sys_file_offset_bits=no; break
7939 fi
7940 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7942 /* end confdefs.h. */
7943 #define _FILE_OFFSET_BITS 64
7944 #include <sys/types.h>
7945 /* Check that off_t can represent 2**63 - 1 correctly.
7946 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7947 since some C++ compilers masquerading as C compilers
7948 incorrectly reject 9223372036854775807. */
7949 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7950 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7951 && LARGE_OFF_T % 2147483647 == 1)
7952 ? 1 : -1];
7953 int
7954 main ()
7955 {
7956
7957 ;
7958 return 0;
7959 }
7960 _ACEOF
7961 if ac_fn_c_try_compile "$LINENO"; then :
7962 ac_cv_sys_file_offset_bits=64; break
7963 fi
7964 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7965 ac_cv_sys_file_offset_bits=unknown
7966 break
7967 done
7968 fi
7969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
7970 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
7971 case $ac_cv_sys_file_offset_bits in #(
7972 no | unknown) ;;
7973 *)
7974 cat >>confdefs.h <<_ACEOF
7975 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
7976 _ACEOF
7977 ;;
7978 esac
7979 rm -rf conftest*
7980 if test $ac_cv_sys_file_offset_bits = unknown; then
7981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
7982 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
7983 if test "${ac_cv_sys_large_files+set}" = set; then :
7984 $as_echo_n "(cached) " >&6
7985 else
7986 while :; do
7987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7988 /* end confdefs.h. */
7989 #include <sys/types.h>
7990 /* Check that off_t can represent 2**63 - 1 correctly.
7991 We can't simply define LARGE_OFF_T to be 9223372036854775807,
7992 since some C++ compilers masquerading as C compilers
7993 incorrectly reject 9223372036854775807. */
7994 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
7995 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
7996 && LARGE_OFF_T % 2147483647 == 1)
7997 ? 1 : -1];
7998 int
7999 main ()
8000 {
8001
8002 ;
8003 return 0;
8004 }
8005 _ACEOF
8006 if ac_fn_c_try_compile "$LINENO"; then :
8007 ac_cv_sys_large_files=no; break
8008 fi
8009 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8011 /* end confdefs.h. */
8012 #define _LARGE_FILES 1
8013 #include <sys/types.h>
8014 /* Check that off_t can represent 2**63 - 1 correctly.
8015 We can't simply define LARGE_OFF_T to be 9223372036854775807,
8016 since some C++ compilers masquerading as C compilers
8017 incorrectly reject 9223372036854775807. */
8018 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
8019 int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
8020 && LARGE_OFF_T % 2147483647 == 1)
8021 ? 1 : -1];
8022 int
8023 main ()
8024 {
8025
8026 ;
8027 return 0;
8028 }
8029 _ACEOF
8030 if ac_fn_c_try_compile "$LINENO"; then :
8031 ac_cv_sys_large_files=1; break
8032 fi
8033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8034 ac_cv_sys_large_files=unknown
8035 break
8036 done
8037 fi
8038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
8039 $as_echo "$ac_cv_sys_large_files" >&6; }
8040 case $ac_cv_sys_large_files in #(
8041 no | unknown) ;;
8042 *)
8043 cat >>confdefs.h <<_ACEOF
8044 #define _LARGE_FILES $ac_cv_sys_large_files
8045 _ACEOF
8046 ;;
8047 esac
8048 rm -rf conftest*
8049 fi
8050
8051
8052 fi
8053
8054
8055
8056 LIB_MATH=-lm
8057 LIB_STANDARD=
8058 START_FILES=
8059
8060 case $opsys in
8061 cygwin )
8062 LIB_MATH=
8063 START_FILES='pre-crt0.o'
8064 ;;
8065 darwin )
8066 ## Adding -lm confuses the dynamic linker, so omit it.
8067 LIB_MATH=
8068 START_FILES='pre-crt0.o'
8069 ;;
8070 freebsd )
8071 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8072 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8073 ;;
8074 gnu-linux | gnu-kfreebsd )
8075 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtn.o'
8076 START_FILES='pre-crt0.o $(CRT_DIR)/crt1.o $(CRT_DIR)/crti.o'
8077 ;;
8078 hpux10-20 | hpux11 )
8079 LIB_STANDARD=-lc
8080 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o'
8081 ;;
8082 netbsd | openbsd )
8083 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o'
8084 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crtbegin.o'
8085 ;;
8086 esac
8087
8088
8089
8090
8091 crt_files=
8092
8093 for file in x $LIB_STANDARD $START_FILES; do
8094 case "$file" in
8095 *CRT_DIR*) crt_files="$crt_files `echo $file | sed -e 's|.*/||'`" ;;
8096 esac
8097 done
8098
8099 if test "x$crt_files" != x; then
8100
8101 ## If user specified a crt-dir, use that unconditionally.
8102 crt_gcc=no
8103
8104 if test "X$CRT_DIR" = "X"; then
8105
8106 CRT_DIR=/usr/lib # default
8107
8108 case "$canonical" in
8109 x86_64-*-linux-gnu* | s390x-*-linux-gnu*)
8110 ## On x86-64 and s390x GNU/Linux distributions, the standard library
8111 ## can be in a variety of places. We only try /usr/lib64 and /usr/lib.
8112 ## For anything else (eg /usr/lib32), it is up the user to specify
8113 ## the location (bug#5655).
8114 ## Test for crtn.o, not just the directory, because sometimes the
8115 ## directory exists but does not have the relevant files (bug#1287).
8116 ## FIXME better to test for binary compatibility somehow.
8117 test -e /usr/lib64/crtn.o && CRT_DIR=/usr/lib64
8118 ;;
8119
8120 powerpc64-*-linux-gnu* | sparc64-*-linux-gnu*) CRT_DIR=/usr/lib64 ;;
8121 esac
8122
8123 case "$opsys" in
8124 hpux10-20) CRT_DIR=/lib ;;
8125 esac
8126
8127 test "x${GCC}" = xyes && crt_gcc=yes
8128
8129 fi # CRT_DIR = ""
8130
8131 crt_missing=
8132
8133 for file in $crt_files; do
8134
8135 ## If we're using gcc, try to determine it automatically by asking
8136 ## gcc. [If this doesn't work, CRT_DIR will remain at the
8137 ## system-dependent default from above.]
8138 if test $crt_gcc = yes && test ! -e $CRT_DIR/$file; then
8139
8140 crt_file=`$CC --print-file-name=$file 2>/dev/null`
8141 case "$crt_file" in
8142 */*)
8143 CRT_DIR=`$as_dirname -- "$crt_file" ||
8144 $as_expr X"$crt_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
8145 X"$crt_file" : 'X\(//\)[^/]' \| \
8146 X"$crt_file" : 'X\(//\)$' \| \
8147 X"$crt_file" : 'X\(/\)' \| . 2>/dev/null ||
8148 $as_echo X"$crt_file" |
8149 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
8150 s//\1/
8151 q
8152 }
8153 /^X\(\/\/\)[^/].*/{
8154 s//\1/
8155 q
8156 }
8157 /^X\(\/\/\)$/{
8158 s//\1/
8159 q
8160 }
8161 /^X\(\/\).*/{
8162 s//\1/
8163 q
8164 }
8165 s/.*/./; q'`
8166 ;;
8167 esac
8168 fi
8169
8170 crt_gcc=no
8171
8172 test -e $CRT_DIR/$file || crt_missing="$crt_missing $file"
8173 done # $crt_files
8174
8175 test "x$crt_missing" = x || \
8176 as_fn_error "Required file(s) not found:$crt_missing
8177 Try using the --with-crt-dir option." "$LINENO" 5
8178
8179 fi # crt_files != ""
8180
8181
8182
8183 case $opsys in
8184 netbsd | openbsd )
8185 if test -f $CRT_DIR/crti.o; then
8186
8187 test -f $CRT_DIR/crtn.o || \
8188 as_fn_error "Required file not found: crtn.o" "$LINENO" 5
8189
8190 LIB_STANDARD='-lgcc -lc -lgcc $(CRT_DIR)/crtend.o $(CRT_DIR)/crtn.o'
8191 START_FILES='pre-crt0.o $(CRT_DIR)/crt0.o $(CRT_DIR)/crti.o $(CRT_DIR)/crtbegin.o'
8192 fi
8193 ;;
8194 esac
8195
8196
8197
8198
8199
8200 if test "${with_sound}" != "no"; then
8201 # Sound support for GNU/Linux and the free BSDs.
8202 for ac_header in machine/soundcard.h sys/soundcard.h soundcard.h
8203 do :
8204 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8205 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8206 eval as_val=\$$as_ac_Header
8207 if test "x$as_val" = x""yes; then :
8208 cat >>confdefs.h <<_ACEOF
8209 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8210 _ACEOF
8211 have_sound_header=yes
8212 fi
8213
8214 done
8215
8216 # Emulation library used on NetBSD.
8217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _oss_ioctl in -lossaudio" >&5
8218 $as_echo_n "checking for _oss_ioctl in -lossaudio... " >&6; }
8219 if test "${ac_cv_lib_ossaudio__oss_ioctl+set}" = set; then :
8220 $as_echo_n "(cached) " >&6
8221 else
8222 ac_check_lib_save_LIBS=$LIBS
8223 LIBS="-lossaudio $LIBS"
8224 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8225 /* end confdefs.h. */
8226
8227 /* Override any GCC internal prototype to avoid an error.
8228 Use char because int might match the return type of a GCC
8229 builtin and then its argument prototype would still apply. */
8230 #ifdef __cplusplus
8231 extern "C"
8232 #endif
8233 char _oss_ioctl ();
8234 int
8235 main ()
8236 {
8237 return _oss_ioctl ();
8238 ;
8239 return 0;
8240 }
8241 _ACEOF
8242 if ac_fn_c_try_link "$LINENO"; then :
8243 ac_cv_lib_ossaudio__oss_ioctl=yes
8244 else
8245 ac_cv_lib_ossaudio__oss_ioctl=no
8246 fi
8247 rm -f core conftest.err conftest.$ac_objext \
8248 conftest$ac_exeext conftest.$ac_ext
8249 LIBS=$ac_check_lib_save_LIBS
8250 fi
8251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ossaudio__oss_ioctl" >&5
8252 $as_echo "$ac_cv_lib_ossaudio__oss_ioctl" >&6; }
8253 if test "x$ac_cv_lib_ossaudio__oss_ioctl" = x""yes; then :
8254 LIBSOUND=-lossaudio
8255 else
8256 LIBSOUND=
8257 fi
8258
8259
8260
8261 ALSA_REQUIRED=1.0.0
8262 ALSA_MODULES="alsa >= $ALSA_REQUIRED"
8263
8264 succeeded=no
8265
8266 # Extract the first word of "pkg-config", so it can be a program name with args.
8267 set dummy pkg-config; ac_word=$2
8268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8269 $as_echo_n "checking for $ac_word... " >&6; }
8270 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
8271 $as_echo_n "(cached) " >&6
8272 else
8273 case $PKG_CONFIG in
8274 [\\/]* | ?:[\\/]*)
8275 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
8276 ;;
8277 *)
8278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8279 for as_dir in $PATH
8280 do
8281 IFS=$as_save_IFS
8282 test -z "$as_dir" && as_dir=.
8283 for ac_exec_ext in '' $ac_executable_extensions; do
8284 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8285 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
8286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8287 break 2
8288 fi
8289 done
8290 done
8291 IFS=$as_save_IFS
8292
8293 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
8294 ;;
8295 esac
8296 fi
8297 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
8298 if test -n "$PKG_CONFIG"; then
8299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
8300 $as_echo "$PKG_CONFIG" >&6; }
8301 else
8302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8303 $as_echo "no" >&6; }
8304 fi
8305
8306
8307
8308 if test "$PKG_CONFIG" = "no" ; then
8309 HAVE_ALSA=no
8310 else
8311 PKG_CONFIG_MIN_VERSION=0.9.0
8312 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
8313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ALSA_MODULES" >&5
8314 $as_echo_n "checking for $ALSA_MODULES... " >&6; }
8315
8316 if $PKG_CONFIG --exists "$ALSA_MODULES" 2>&5 &&
8317 ALSA_CFLAGS=`$PKG_CONFIG --cflags "$ALSA_MODULES" 2>&5` &&
8318 ALSA_LIBS=`$PKG_CONFIG --libs "$ALSA_MODULES" 2>&5`; then
8319
8320 ALSA_CFLAGS=`$as_echo "$ALSA_CFLAGS" | sed -e 's,///*,/,g'`
8321 ALSA_LIBS=`$as_echo "$ALSA_LIBS" | sed -e 's,///*,/,g'`
8322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&5
8323 $as_echo "yes CFLAGS='$ALSA_CFLAGS' LIBS='$ALSA_LIBS'" >&6; }
8324 succeeded=yes
8325 else
8326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8327 $as_echo "no" >&6; }
8328 ALSA_CFLAGS=""
8329 ALSA_LIBS=""
8330 ## If we have a custom action on failure, don't print errors, but
8331 ## do set a variable so people can do so.
8332 ALSA_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$ALSA_MODULES"`
8333
8334 fi
8335
8336
8337
8338 else
8339 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
8340 echo "*** See http://www.freedesktop.org/software/pkgconfig"
8341 fi
8342 fi
8343
8344 if test $succeeded = yes; then
8345 HAVE_ALSA=yes
8346 else
8347 HAVE_ALSA=no
8348 fi
8349
8350 if test $HAVE_ALSA = yes; then
8351 SAVE_CFLAGS="$CFLAGS"
8352 SAVE_LIBS="$LIBS"
8353 CFLAGS="$ALSA_CFLAGS $CFLAGS"
8354 LIBS="$ALSA_LIBS $LIBS"
8355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8356 /* end confdefs.h. */
8357 #include <asoundlib.h>
8358 int
8359 main ()
8360 {
8361 snd_lib_error_set_handler (0);
8362 ;
8363 return 0;
8364 }
8365 _ACEOF
8366 if ac_fn_c_try_compile "$LINENO"; then :
8367 emacs_alsa_normal=yes
8368 else
8369 emacs_alsa_normal=no
8370 fi
8371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8372 if test "$emacs_alsa_normal" != yes; then
8373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8374 /* end confdefs.h. */
8375 #include <alsa/asoundlib.h>
8376 int
8377 main ()
8378 {
8379 snd_lib_error_set_handler (0);
8380 ;
8381 return 0;
8382 }
8383 _ACEOF
8384 if ac_fn_c_try_compile "$LINENO"; then :
8385 emacs_alsa_subdir=yes
8386 else
8387 emacs_alsa_subdir=no
8388 fi
8389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8390 if test "$emacs_alsa_subdir" != yes; then
8391 as_fn_error "pkg-config found alsa, but it does not compile. See config.log for error messages." "$LINENO" 5
8392 fi
8393 ALSA_CFLAGS="$ALSA_CFLAGS -DALSA_SUBDIR_INCLUDE"
8394 fi
8395
8396 CFLAGS="$SAVE_CFLAGS"
8397 LIBS="$SAVE_LIBS"
8398 LIBSOUND="$LIBSOUND $ALSA_LIBS"
8399 CFLAGS_SOUND="$CFLAGS_SOUND $ALSA_CFLAGS"
8400
8401 $as_echo "#define HAVE_ALSA 1" >>confdefs.h
8402
8403 fi
8404
8405 if test x$have_sound_header = xyes || test $HAVE_ALSA = yes; then
8406 case "$opsys" in
8407 gnu-linux|freebsd|netbsd)
8408
8409 $as_echo "#define HAVE_SOUND 1" >>confdefs.h
8410
8411 ;;
8412 esac
8413 fi
8414
8415
8416 fi
8417
8418 for ac_header in sys/select.h sys/time.h unistd.h utime.h \
8419 linux/version.h sys/systeminfo.h \
8420 stdio_ext.h fcntl.h coff.h pty.h sys/mman.h \
8421 sys/vlimit.h sys/resource.h locale.h sys/_mbstate_t.h \
8422 sys/utsname.h pwd.h utmp.h dirent.h util.h
8423 do :
8424 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
8425 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
8426 eval as_val=\$$as_ac_Header
8427 if test "x$as_val" = x""yes; then :
8428 cat >>confdefs.h <<_ACEOF
8429 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
8430 _ACEOF
8431
8432 fi
8433
8434 done
8435
8436
8437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if personality LINUX32 can be set" >&5
8438 $as_echo_n "checking if personality LINUX32 can be set... " >&6; }
8439 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8440 /* end confdefs.h. */
8441 #include <sys/personality.h>
8442 int
8443 main ()
8444 {
8445 personality (PER_LINUX32)
8446 ;
8447 return 0;
8448 }
8449 _ACEOF
8450 if ac_fn_c_try_compile "$LINENO"; then :
8451 emacs_cv_personality_linux32=yes
8452 else
8453 emacs_cv_personality_linux32=no
8454 fi
8455 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_personality_linux32" >&5
8457 $as_echo "$emacs_cv_personality_linux32" >&6; }
8458
8459 if test $emacs_cv_personality_linux32 = yes; then
8460
8461 $as_echo "#define HAVE_PERSONALITY_LINUX32 1" >>confdefs.h
8462
8463 fi
8464
8465 for ac_header in term.h
8466 do :
8467 ac_fn_c_check_header_preproc "$LINENO" "term.h" "ac_cv_header_term_h"
8468 if test "x$ac_cv_header_term_h" = x""yes; then :
8469 cat >>confdefs.h <<_ACEOF
8470 #define HAVE_TERM_H 1
8471 _ACEOF
8472
8473 fi
8474
8475 done
8476
8477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5
8478 $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; }
8479 if test "${ac_cv_header_time+set}" = set; then :
8480 $as_echo_n "(cached) " >&6
8481 else
8482 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8483 /* end confdefs.h. */
8484 #include <sys/types.h>
8485 #include <sys/time.h>
8486 #include <time.h>
8487
8488 int
8489 main ()
8490 {
8491 if ((struct tm *) 0)
8492 return 0;
8493 ;
8494 return 0;
8495 }
8496 _ACEOF
8497 if ac_fn_c_try_compile "$LINENO"; then :
8498 ac_cv_header_time=yes
8499 else
8500 ac_cv_header_time=no
8501 fi
8502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8503 fi
8504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5
8505 $as_echo "$ac_cv_header_time" >&6; }
8506 if test $ac_cv_header_time = yes; then
8507
8508 $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h
8509
8510 fi
8511
8512 ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "$ac_includes_default"
8513 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then :
8514 ac_have_decl=1
8515 else
8516 ac_have_decl=0
8517 fi
8518
8519 cat >>confdefs.h <<_ACEOF
8520 #define HAVE_DECL_SYS_SIGLIST $ac_have_decl
8521 _ACEOF
8522
8523 if test $ac_cv_have_decl_sys_siglist != yes; then
8524 # For Tru64, at least:
8525 ac_fn_c_check_decl "$LINENO" "__sys_siglist" "ac_cv_have_decl___sys_siglist" "$ac_includes_default"
8526 if test "x$ac_cv_have_decl___sys_siglist" = x""yes; then :
8527 ac_have_decl=1
8528 else
8529 ac_have_decl=0
8530 fi
8531
8532 cat >>confdefs.h <<_ACEOF
8533 #define HAVE_DECL___SYS_SIGLIST $ac_have_decl
8534 _ACEOF
8535
8536 if test $ac_cv_have_decl___sys_siglist = yes; then
8537
8538 $as_echo "#define sys_siglist __sys_siglist" >>confdefs.h
8539
8540 fi
8541 fi
8542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5
8543 $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; }
8544 if test "${ac_cv_header_sys_wait_h+set}" = set; then :
8545 $as_echo_n "(cached) " >&6
8546 else
8547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8548 /* end confdefs.h. */
8549 #include <sys/types.h>
8550 #include <sys/wait.h>
8551 #ifndef WEXITSTATUS
8552 # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8)
8553 #endif
8554 #ifndef WIFEXITED
8555 # define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
8556 #endif
8557
8558 int
8559 main ()
8560 {
8561 int s;
8562 wait (&s);
8563 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
8564 ;
8565 return 0;
8566 }
8567 _ACEOF
8568 if ac_fn_c_try_compile "$LINENO"; then :
8569 ac_cv_header_sys_wait_h=yes
8570 else
8571 ac_cv_header_sys_wait_h=no
8572 fi
8573 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8574 fi
8575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5
8576 $as_echo "$ac_cv_header_sys_wait_h" >&6; }
8577 if test $ac_cv_header_sys_wait_h = yes; then
8578
8579 $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
8580
8581 fi
8582
8583
8584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct utimbuf" >&5
8585 $as_echo_n "checking for struct utimbuf... " >&6; }
8586 if test "${emacs_cv_struct_utimbuf+set}" = set; then :
8587 $as_echo_n "(cached) " >&6
8588 else
8589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8590 /* end confdefs.h. */
8591 #ifdef TIME_WITH_SYS_TIME
8592 #include <sys/time.h>
8593 #include <time.h>
8594 #else
8595 #ifdef HAVE_SYS_TIME_H
8596 #include <sys/time.h>
8597 #else
8598 #include <time.h>
8599 #endif
8600 #endif
8601 #ifdef HAVE_UTIME_H
8602 #include <utime.h>
8603 #endif
8604 int
8605 main ()
8606 {
8607 static struct utimbuf x; x.actime = x.modtime;
8608 ;
8609 return 0;
8610 }
8611 _ACEOF
8612 if ac_fn_c_try_compile "$LINENO"; then :
8613 emacs_cv_struct_utimbuf=yes
8614 else
8615 emacs_cv_struct_utimbuf=no
8616 fi
8617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8618 fi
8619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_utimbuf" >&5
8620 $as_echo "$emacs_cv_struct_utimbuf" >&6; }
8621 if test $emacs_cv_struct_utimbuf = yes; then
8622
8623 $as_echo "#define HAVE_STRUCT_UTIMBUF 1" >>confdefs.h
8624
8625 fi
8626
8627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t" >&5
8628 $as_echo_n "checking for speed_t... " >&6; }
8629 if test "${emacs_cv_speed_t+set}" = set; then :
8630 $as_echo_n "(cached) " >&6
8631 else
8632 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8633 /* end confdefs.h. */
8634 #include <termios.h>
8635 int
8636 main ()
8637 {
8638 speed_t x = 1;
8639 ;
8640 return 0;
8641 }
8642 _ACEOF
8643 if ac_fn_c_try_compile "$LINENO"; then :
8644 emacs_cv_speed_t=yes
8645 else
8646 emacs_cv_speed_t=no
8647 fi
8648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8649 fi
8650 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_speed_t" >&5
8651 $as_echo "$emacs_cv_speed_t" >&6; }
8652 if test $emacs_cv_speed_t = yes; then
8653
8654 $as_echo "#define HAVE_SPEED_T 1" >>confdefs.h
8655
8656 fi
8657
8658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
8659 $as_echo_n "checking for struct timeval... " >&6; }
8660 if test "${emacs_cv_struct_timeval+set}" = set; then :
8661 $as_echo_n "(cached) " >&6
8662 else
8663 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8664 /* end confdefs.h. */
8665 #ifdef TIME_WITH_SYS_TIME
8666 #include <sys/time.h>
8667 #include <time.h>
8668 #else
8669 #ifdef HAVE_SYS_TIME_H
8670 #include <sys/time.h>
8671 #else
8672 #include <time.h>
8673 #endif
8674 #endif
8675 int
8676 main ()
8677 {
8678 static struct timeval x; x.tv_sec = x.tv_usec;
8679 ;
8680 return 0;
8681 }
8682 _ACEOF
8683 if ac_fn_c_try_compile "$LINENO"; then :
8684 emacs_cv_struct_timeval=yes
8685 else
8686 emacs_cv_struct_timeval=no
8687 fi
8688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8689 fi
8690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_timeval" >&5
8691 $as_echo "$emacs_cv_struct_timeval" >&6; }
8692 HAVE_TIMEVAL=$emacs_cv_struct_timeval
8693 if test $emacs_cv_struct_timeval = yes; then
8694
8695 $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h
8696
8697 fi
8698
8699 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct exception" >&5
8700 $as_echo_n "checking for struct exception... " >&6; }
8701 if test "${emacs_cv_struct_exception+set}" = set; then :
8702 $as_echo_n "(cached) " >&6
8703 else
8704 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8705 /* end confdefs.h. */
8706 #include <math.h>
8707 int
8708 main ()
8709 {
8710 static struct exception x; x.arg1 = x.arg2 = x.retval; x.name = ""; x.type = 1;
8711 ;
8712 return 0;
8713 }
8714 _ACEOF
8715 if ac_fn_c_try_compile "$LINENO"; then :
8716 emacs_cv_struct_exception=yes
8717 else
8718 emacs_cv_struct_exception=no
8719 fi
8720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8721 fi
8722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_struct_exception" >&5
8723 $as_echo "$emacs_cv_struct_exception" >&6; }
8724 HAVE_EXCEPTION=$emacs_cv_struct_exception
8725 if test $emacs_cv_struct_exception != yes; then
8726
8727 $as_echo "#define NO_MATHERR 1" >>confdefs.h
8728
8729 fi
8730
8731 for ac_header in sys/socket.h
8732 do :
8733 ac_fn_c_check_header_mongrel "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
8734 if test "x$ac_cv_header_sys_socket_h" = x""yes; then :
8735 cat >>confdefs.h <<_ACEOF
8736 #define HAVE_SYS_SOCKET_H 1
8737 _ACEOF
8738
8739 fi
8740
8741 done
8742
8743 for ac_header in net/if.h
8744 do :
8745 ac_fn_c_check_header_compile "$LINENO" "net/if.h" "ac_cv_header_net_if_h" "$ac_includes_default
8746 #if HAVE_SYS_SOCKET_H
8747 #include <sys/socket.h>
8748 #endif
8749 "
8750 if test "x$ac_cv_header_net_if_h" = x""yes; then :
8751 cat >>confdefs.h <<_ACEOF
8752 #define HAVE_NET_IF_H 1
8753 _ACEOF
8754
8755 fi
8756
8757 done
8758
8759 for ac_header in ifaddrs.h
8760 do :
8761 ac_fn_c_check_header_compile "$LINENO" "ifaddrs.h" "ac_cv_header_ifaddrs_h" "$ac_includes_default
8762 #if HAVE_SYS_SOCKET_H
8763 #include <sys/socket.h>
8764 #endif
8765 "
8766 if test "x$ac_cv_header_ifaddrs_h" = x""yes; then :
8767 cat >>confdefs.h <<_ACEOF
8768 #define HAVE_IFADDRS_H 1
8769 _ACEOF
8770
8771 fi
8772
8773 done
8774
8775 for ac_header in net/if_dl.h
8776 do :
8777 ac_fn_c_check_header_compile "$LINENO" "net/if_dl.h" "ac_cv_header_net_if_dl_h" "$ac_includes_default
8778 #if HAVE_SYS_SOCKET_H
8779 #include <sys/socket.h>
8780 #endif
8781 "
8782 if test "x$ac_cv_header_net_if_dl_h" = x""yes; then :
8783 cat >>confdefs.h <<_ACEOF
8784 #define HAVE_NET_IF_DL_H 1
8785 _ACEOF
8786
8787 fi
8788
8789 done
8790
8791 for ac_func in getifaddrs freeifaddrs
8792 do :
8793 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8794 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8795 eval as_val=\$$as_ac_var
8796 if test "x$as_val" = x""yes; then :
8797 cat >>confdefs.h <<_ACEOF
8798 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8799 _ACEOF
8800
8801 fi
8802 done
8803
8804
8805 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_flags" "ac_cv_member_struct_ifreq_ifr_flags" "$ac_includes_default
8806 #if HAVE_SYS_SOCKET_H
8807 #include <sys/socket.h>
8808 #endif
8809 #if HAVE_NET_IF_H
8810 #include <net/if.h>
8811 #endif
8812 "
8813 if test "x$ac_cv_member_struct_ifreq_ifr_flags" = x""yes; then :
8814
8815 cat >>confdefs.h <<_ACEOF
8816 #define HAVE_STRUCT_IFREQ_IFR_FLAGS 1
8817 _ACEOF
8818
8819
8820 fi
8821 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_hwaddr" "ac_cv_member_struct_ifreq_ifr_hwaddr" "$ac_includes_default
8822 #if HAVE_SYS_SOCKET_H
8823 #include <sys/socket.h>
8824 #endif
8825 #if HAVE_NET_IF_H
8826 #include <net/if.h>
8827 #endif
8828 "
8829 if test "x$ac_cv_member_struct_ifreq_ifr_hwaddr" = x""yes; then :
8830
8831 cat >>confdefs.h <<_ACEOF
8832 #define HAVE_STRUCT_IFREQ_IFR_HWADDR 1
8833 _ACEOF
8834
8835
8836 fi
8837 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_netmask" "ac_cv_member_struct_ifreq_ifr_netmask" "$ac_includes_default
8838 #if HAVE_SYS_SOCKET_H
8839 #include <sys/socket.h>
8840 #endif
8841 #if HAVE_NET_IF_H
8842 #include <net/if.h>
8843 #endif
8844 "
8845 if test "x$ac_cv_member_struct_ifreq_ifr_netmask" = x""yes; then :
8846
8847 cat >>confdefs.h <<_ACEOF
8848 #define HAVE_STRUCT_IFREQ_IFR_NETMASK 1
8849 _ACEOF
8850
8851
8852 fi
8853 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_broadaddr" "ac_cv_member_struct_ifreq_ifr_broadaddr" "$ac_includes_default
8854 #if HAVE_SYS_SOCKET_H
8855 #include <sys/socket.h>
8856 #endif
8857 #if HAVE_NET_IF_H
8858 #include <net/if.h>
8859 #endif
8860 "
8861 if test "x$ac_cv_member_struct_ifreq_ifr_broadaddr" = x""yes; then :
8862
8863 cat >>confdefs.h <<_ACEOF
8864 #define HAVE_STRUCT_IFREQ_IFR_BROADADDR 1
8865 _ACEOF
8866
8867
8868 fi
8869 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr" "ac_cv_member_struct_ifreq_ifr_addr" "$ac_includes_default
8870 #if HAVE_SYS_SOCKET_H
8871 #include <sys/socket.h>
8872 #endif
8873 #if HAVE_NET_IF_H
8874 #include <net/if.h>
8875 #endif
8876 "
8877 if test "x$ac_cv_member_struct_ifreq_ifr_addr" = x""yes; then :
8878
8879 cat >>confdefs.h <<_ACEOF
8880 #define HAVE_STRUCT_IFREQ_IFR_ADDR 1
8881 _ACEOF
8882
8883
8884 fi
8885 ac_fn_c_check_member "$LINENO" "struct ifreq" "ifr_addr.sa_len" "ac_cv_member_struct_ifreq_ifr_addr_sa_len" "$ac_includes_default
8886 #if HAVE_SYS_SOCKET_H
8887 #include <sys/socket.h>
8888 #endif
8889 #if HAVE_NET_IF_H
8890 #include <net/if.h>
8891 #endif
8892 "
8893 if test "x$ac_cv_member_struct_ifreq_ifr_addr_sa_len" = x""yes; then :
8894
8895 cat >>confdefs.h <<_ACEOF
8896 #define HAVE_STRUCT_IFREQ_IFR_ADDR_SA_LEN 1
8897 _ACEOF
8898
8899
8900 fi
8901
8902
8903
8904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5
8905 $as_echo_n "checking for function prototypes... " >&6; }
8906 if test "$ac_cv_prog_cc_c89" != no; then
8907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8908 $as_echo "yes" >&6; }
8909
8910 $as_echo "#define PROTOTYPES 1" >>confdefs.h
8911
8912
8913 $as_echo "#define __PROTOTYPES 1" >>confdefs.h
8914
8915 else
8916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8917 $as_echo "no" >&6; }
8918 fi
8919
8920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
8921 $as_echo_n "checking for working volatile... " >&6; }
8922 if test "${ac_cv_c_volatile+set}" = set; then :
8923 $as_echo_n "(cached) " >&6
8924 else
8925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8926 /* end confdefs.h. */
8927
8928 int
8929 main ()
8930 {
8931
8932 volatile int x;
8933 int * volatile y = (int *) 0;
8934 return !x && !y;
8935 ;
8936 return 0;
8937 }
8938 _ACEOF
8939 if ac_fn_c_try_compile "$LINENO"; then :
8940 ac_cv_c_volatile=yes
8941 else
8942 ac_cv_c_volatile=no
8943 fi
8944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8945 fi
8946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
8947 $as_echo "$ac_cv_c_volatile" >&6; }
8948 if test $ac_cv_c_volatile = no; then
8949
8950 $as_echo "#define volatile /**/" >>confdefs.h
8951
8952 fi
8953
8954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
8955 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
8956 if test "${ac_cv_c_const+set}" = set; then :
8957 $as_echo_n "(cached) " >&6
8958 else
8959 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8960 /* end confdefs.h. */
8961
8962 int
8963 main ()
8964 {
8965 /* FIXME: Include the comments suggested by Paul. */
8966 #ifndef __cplusplus
8967 /* Ultrix mips cc rejects this. */
8968 typedef int charset[2];
8969 const charset cs;
8970 /* SunOS 4.1.1 cc rejects this. */
8971 char const *const *pcpcc;
8972 char **ppc;
8973 /* NEC SVR4.0.2 mips cc rejects this. */
8974 struct point {int x, y;};
8975 static struct point const zero = {0,0};
8976 /* AIX XL C 1.02.0.0 rejects this.
8977 It does not let you subtract one const X* pointer from another in
8978 an arm of an if-expression whose if-part is not a constant
8979 expression */
8980 const char *g = "string";
8981 pcpcc = &g + (g ? g-g : 0);
8982 /* HPUX 7.0 cc rejects these. */
8983 ++pcpcc;
8984 ppc = (char**) pcpcc;
8985 pcpcc = (char const *const *) ppc;
8986 { /* SCO 3.2v4 cc rejects this. */
8987 char *t;
8988 char const *s = 0 ? (char *) 0 : (char const *) 0;
8989
8990 *t++ = 0;
8991 if (s) return 0;
8992 }
8993 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
8994 int x[] = {25, 17};
8995 const int *foo = &x[0];
8996 ++foo;
8997 }
8998 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
8999 typedef const int *iptr;
9000 iptr p = 0;
9001 ++p;
9002 }
9003 { /* AIX XL C 1.02.0.0 rejects this saying
9004 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
9005 struct s { int j; const int *ap[3]; };
9006 struct s *b; b->j = 5;
9007 }
9008 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
9009 const int foo = 10;
9010 if (!foo) return 0;
9011 }
9012 return !cs[0] && !zero.x;
9013 #endif
9014
9015 ;
9016 return 0;
9017 }
9018 _ACEOF
9019 if ac_fn_c_try_compile "$LINENO"; then :
9020 ac_cv_c_const=yes
9021 else
9022 ac_cv_c_const=no
9023 fi
9024 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9025 fi
9026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
9027 $as_echo "$ac_cv_c_const" >&6; }
9028 if test $ac_cv_c_const = no; then
9029
9030 $as_echo "#define const /**/" >>confdefs.h
9031
9032 fi
9033
9034 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for void * support" >&5
9035 $as_echo_n "checking for void * support... " >&6; }
9036 if test "${emacs_cv_void_star+set}" = set; then :
9037 $as_echo_n "(cached) " >&6
9038 else
9039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9040 /* end confdefs.h. */
9041
9042 int
9043 main ()
9044 {
9045 void * foo;
9046 ;
9047 return 0;
9048 }
9049 _ACEOF
9050 if ac_fn_c_try_compile "$LINENO"; then :
9051 emacs_cv_void_star=yes
9052 else
9053 emacs_cv_void_star=no
9054 fi
9055 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9056 fi
9057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_void_star" >&5
9058 $as_echo "$emacs_cv_void_star" >&6; }
9059 if test $emacs_cv_void_star = yes; then
9060 $as_echo "#define POINTER_TYPE void" >>confdefs.h
9061
9062 else
9063 $as_echo "#define POINTER_TYPE char" >>confdefs.h
9064
9065 fi
9066
9067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
9068 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
9069 if test "${ac_cv_c_bigendian+set}" = set; then :
9070 $as_echo_n "(cached) " >&6
9071 else
9072 ac_cv_c_bigendian=unknown
9073 # See if we're dealing with a universal compiler.
9074 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9075 /* end confdefs.h. */
9076 #ifndef __APPLE_CC__
9077 not a universal capable compiler
9078 #endif
9079 typedef int dummy;
9080
9081 _ACEOF
9082 if ac_fn_c_try_compile "$LINENO"; then :
9083
9084 # Check for potential -arch flags. It is not universal unless
9085 # there are at least two -arch flags with different values.
9086 ac_arch=
9087 ac_prev=
9088 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
9089 if test -n "$ac_prev"; then
9090 case $ac_word in
9091 i?86 | x86_64 | ppc | ppc64)
9092 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
9093 ac_arch=$ac_word
9094 else
9095 ac_cv_c_bigendian=universal
9096 break
9097 fi
9098 ;;
9099 esac
9100 ac_prev=
9101 elif test "x$ac_word" = "x-arch"; then
9102 ac_prev=arch
9103 fi
9104 done
9105 fi
9106 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9107 if test $ac_cv_c_bigendian = unknown; then
9108 # See if sys/param.h defines the BYTE_ORDER macro.
9109 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9110 /* end confdefs.h. */
9111 #include <sys/types.h>
9112 #include <sys/param.h>
9113
9114 int
9115 main ()
9116 {
9117 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
9118 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
9119 && LITTLE_ENDIAN)
9120 bogus endian macros
9121 #endif
9122
9123 ;
9124 return 0;
9125 }
9126 _ACEOF
9127 if ac_fn_c_try_compile "$LINENO"; then :
9128 # It does; now see whether it defined to BIG_ENDIAN or not.
9129 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9130 /* end confdefs.h. */
9131 #include <sys/types.h>
9132 #include <sys/param.h>
9133
9134 int
9135 main ()
9136 {
9137 #if BYTE_ORDER != BIG_ENDIAN
9138 not big endian
9139 #endif
9140
9141 ;
9142 return 0;
9143 }
9144 _ACEOF
9145 if ac_fn_c_try_compile "$LINENO"; then :
9146 ac_cv_c_bigendian=yes
9147 else
9148 ac_cv_c_bigendian=no
9149 fi
9150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9151 fi
9152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9153 fi
9154 if test $ac_cv_c_bigendian = unknown; then
9155 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
9156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9157 /* end confdefs.h. */
9158 #include <limits.h>
9159
9160 int
9161 main ()
9162 {
9163 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
9164 bogus endian macros
9165 #endif
9166
9167 ;
9168 return 0;
9169 }
9170 _ACEOF
9171 if ac_fn_c_try_compile "$LINENO"; then :
9172 # It does; now see whether it defined to _BIG_ENDIAN or not.
9173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9174 /* end confdefs.h. */
9175 #include <limits.h>
9176
9177 int
9178 main ()
9179 {
9180 #ifndef _BIG_ENDIAN
9181 not big endian
9182 #endif
9183
9184 ;
9185 return 0;
9186 }
9187 _ACEOF
9188 if ac_fn_c_try_compile "$LINENO"; then :
9189 ac_cv_c_bigendian=yes
9190 else
9191 ac_cv_c_bigendian=no
9192 fi
9193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9194 fi
9195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9196 fi
9197 if test $ac_cv_c_bigendian = unknown; then
9198 # Compile a test program.
9199 if test "$cross_compiling" = yes; then :
9200 # Try to guess by grepping values from an object file.
9201 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9202 /* end confdefs.h. */
9203 short int ascii_mm[] =
9204 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
9205 short int ascii_ii[] =
9206 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
9207 int use_ascii (int i) {
9208 return ascii_mm[i] + ascii_ii[i];
9209 }
9210 short int ebcdic_ii[] =
9211 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
9212 short int ebcdic_mm[] =
9213 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
9214 int use_ebcdic (int i) {
9215 return ebcdic_mm[i] + ebcdic_ii[i];
9216 }
9217 extern int foo;
9218
9219 int
9220 main ()
9221 {
9222 return use_ascii (foo) == use_ebcdic (foo);
9223 ;
9224 return 0;
9225 }
9226 _ACEOF
9227 if ac_fn_c_try_compile "$LINENO"; then :
9228 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
9229 ac_cv_c_bigendian=yes
9230 fi
9231 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
9232 if test "$ac_cv_c_bigendian" = unknown; then
9233 ac_cv_c_bigendian=no
9234 else
9235 # finding both strings is unlikely to happen, but who knows?
9236 ac_cv_c_bigendian=unknown
9237 fi
9238 fi
9239 fi
9240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9241 else
9242 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9243 /* end confdefs.h. */
9244 $ac_includes_default
9245 int
9246 main ()
9247 {
9248
9249 /* Are we little or big endian? From Harbison&Steele. */
9250 union
9251 {
9252 long int l;
9253 char c[sizeof (long int)];
9254 } u;
9255 u.l = 1;
9256 return u.c[sizeof (long int) - 1] == 1;
9257
9258 ;
9259 return 0;
9260 }
9261 _ACEOF
9262 if ac_fn_c_try_run "$LINENO"; then :
9263 ac_cv_c_bigendian=no
9264 else
9265 ac_cv_c_bigendian=yes
9266 fi
9267 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9268 conftest.$ac_objext conftest.beam conftest.$ac_ext
9269 fi
9270
9271 fi
9272 fi
9273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
9274 $as_echo "$ac_cv_c_bigendian" >&6; }
9275 case $ac_cv_c_bigendian in #(
9276 yes)
9277 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
9278 ;; #(
9279 no)
9280 ;; #(
9281 universal)
9282
9283 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
9284
9285 ;; #(
9286 *)
9287 as_fn_error "unknown endianness
9288 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
9289 esac
9290
9291
9292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __attribute__ ((__aligned__ (expr)))" >&5
9293 $as_echo_n "checking for __attribute__ ((__aligned__ (expr)))... " >&6; }
9294 if test "${emacs_cv_attribute_aligned+set}" = set; then :
9295 $as_echo_n "(cached) " >&6
9296 else
9297 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9298 /* end confdefs.h. */
9299 char __attribute__ ((__aligned__ (1 << 3))) c;
9300 int
9301 main ()
9302 {
9303
9304 ;
9305 return 0;
9306 }
9307 _ACEOF
9308 if ac_fn_c_try_compile "$LINENO"; then :
9309 emacs_cv_attribute_aligned=yes
9310 else
9311 emacs_cv_attribute_aligned=no
9312 fi
9313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9314 fi
9315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_attribute_aligned" >&5
9316 $as_echo "$emacs_cv_attribute_aligned" >&6; }
9317 if test $emacs_cv_attribute_aligned = yes; then
9318
9319 $as_echo "#define HAVE_ATTRIBUTE_ALIGNED 1" >>confdefs.h
9320
9321 fi
9322
9323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
9324 $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
9325 set x ${MAKE-make}
9326 ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
9327 if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then :
9328 $as_echo_n "(cached) " >&6
9329 else
9330 cat >conftest.make <<\_ACEOF
9331 SHELL = /bin/sh
9332 all:
9333 @echo '@@@%%%=$(MAKE)=@@@%%%'
9334 _ACEOF
9335 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9336 case `${MAKE-make} -f conftest.make 2>/dev/null` in
9337 *@@@%%%=?*=@@@%%%*)
9338 eval ac_cv_prog_make_${ac_make}_set=yes;;
9339 *)
9340 eval ac_cv_prog_make_${ac_make}_set=no;;
9341 esac
9342 rm -f conftest.make
9343 fi
9344 if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
9345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9346 $as_echo "yes" >&6; }
9347 SET_MAKE=
9348 else
9349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9350 $as_echo "no" >&6; }
9351 SET_MAKE="MAKE=${MAKE-make}"
9352 fi
9353
9354
9355 DEPFLAGS=
9356 MKDEPDIR=":"
9357 deps_frag=deps.mk
9358 if test "$GCC" = yes && test "$ac_enable_autodepend" = yes; then
9359 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using GNU Make" >&5
9360 $as_echo_n "checking whether we are using GNU Make... " >&6; }
9361 HAVE_GNU_MAKE=no
9362 testval=`${MAKE-make} --version 2>/dev/null | grep 'GNU Make'`
9363 if test "x$testval" != x; then
9364 HAVE_GNU_MAKE=yes
9365 else
9366 ac_enable_autodepend=no
9367 fi
9368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_GNU_MAKE" >&5
9369 $as_echo "$HAVE_GNU_MAKE" >&6; }
9370 if test $HAVE_GNU_MAKE = yes; then
9371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gcc understands -MMD -MF" >&5
9372 $as_echo_n "checking whether gcc understands -MMD -MF... " >&6; }
9373 SAVE_CFLAGS="$CFLAGS"
9374 CFLAGS="$CFLAGS -MMD -MF deps.d -MP"
9375 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9376 /* end confdefs.h. */
9377
9378 int
9379 main ()
9380 {
9381
9382 ;
9383 return 0;
9384 }
9385 _ACEOF
9386 if ac_fn_c_try_compile "$LINENO"; then :
9387
9388 else
9389 ac_enable_autodepend=no
9390 fi
9391 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9392 CFLAGS="$SAVE_CFLAGS"
9393 test -f deps.d || ac_enable_autodepend=no
9394 rm -rf deps.d
9395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_enable_autodepend" >&5
9396 $as_echo "$ac_enable_autodepend" >&6; }
9397 fi
9398 if test $ac_enable_autodepend = yes; then
9399 DEPFLAGS='-MMD -MF ${DEPDIR}/$*.d -MP'
9400 ## In parallel builds, another make might create depdir between
9401 ## the first test and mkdir, so stick another test on the end.
9402 ## Or use install-sh -d? mkdir -p is not portable.
9403 MKDEPDIR='test -d ${DEPDIR} || mkdir ${DEPDIR} || test -d ${DEPDIR}'
9404 deps_frag=autodeps.mk
9405 fi
9406 fi
9407 deps_frag=$srcdir/src/$deps_frag
9408
9409
9410
9411
9412
9413 lisp_frag=$srcdir/src/lisp.mk
9414
9415
9416
9417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long file names" >&5
9418 $as_echo_n "checking for long file names... " >&6; }
9419 if test "${ac_cv_sys_long_file_names+set}" = set; then :
9420 $as_echo_n "(cached) " >&6
9421 else
9422 ac_cv_sys_long_file_names=yes
9423 # Test for long file names in all the places we know might matter:
9424 # . the current directory, where building will happen
9425 # $prefix/lib where we will be installing things
9426 # $exec_prefix/lib likewise
9427 # $TMPDIR if set, where it might want to write temporary files
9428 # /tmp where it might want to write temporary files
9429 # /var/tmp likewise
9430 # /usr/tmp likewise
9431 for ac_dir in . "$TMPDIR" /tmp /var/tmp /usr/tmp "$prefix/lib" "$exec_prefix/lib"; do
9432 # Skip $TMPDIR if it is empty or bogus, and skip $exec_prefix/lib
9433 # in the usual case where exec_prefix is '${prefix}'.
9434 case $ac_dir in #(
9435 . | /* | ?:[\\/]*) ;; #(
9436 *) continue;;
9437 esac
9438 test -w "$ac_dir/." || continue # It is less confusing to not echo anything here.
9439 ac_xdir=$ac_dir/cf$$
9440 (umask 077 && mkdir "$ac_xdir" 2>/dev/null) || continue
9441 ac_tf1=$ac_xdir/conftest9012345
9442 ac_tf2=$ac_xdir/conftest9012346
9443 touch "$ac_tf1" 2>/dev/null && test -f "$ac_tf1" && test ! -f "$ac_tf2" ||
9444 ac_cv_sys_long_file_names=no
9445 rm -f -r "$ac_xdir" 2>/dev/null
9446 test $ac_cv_sys_long_file_names = no && break
9447 done
9448 fi
9449 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_long_file_names" >&5
9450 $as_echo "$ac_cv_sys_long_file_names" >&6; }
9451 if test $ac_cv_sys_long_file_names = yes; then
9452
9453 $as_echo "#define HAVE_LONG_FILE_NAMES 1" >>confdefs.h
9454
9455 fi
9456
9457
9458 #### Choose a window system.
9459
9460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
9461 $as_echo_n "checking for X... " >&6; }
9462
9463
9464 # Check whether --with-x was given.
9465 if test "${with_x+set}" = set; then :
9466 withval=$with_x;
9467 fi
9468
9469 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
9470 if test "x$with_x" = xno; then
9471 # The user explicitly disabled X.
9472 have_x=disabled
9473 else
9474 case $x_includes,$x_libraries in #(
9475 *\'*) as_fn_error "cannot use X directory names containing '" "$LINENO" 5;; #(
9476 *,NONE | NONE,*) if test "${ac_cv_have_x+set}" = set; then :
9477 $as_echo_n "(cached) " >&6
9478 else
9479 # One or both of the vars are not set, and there is no cached value.
9480 ac_x_includes=no ac_x_libraries=no
9481 rm -f -r conftest.dir
9482 if mkdir conftest.dir; then
9483 cd conftest.dir
9484 cat >Imakefile <<'_ACEOF'
9485 incroot:
9486 @echo incroot='${INCROOT}'
9487 usrlibdir:
9488 @echo usrlibdir='${USRLIBDIR}'
9489 libdir:
9490 @echo libdir='${LIBDIR}'
9491 _ACEOF
9492 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then
9493 # GNU make sometimes prints "make[1]: Entering...", which would confuse us.
9494 for ac_var in incroot usrlibdir libdir; do
9495 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`"
9496 done
9497 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR.
9498 for ac_extension in a so sl dylib la dll; do
9499 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" &&
9500 test -f "$ac_im_libdir/libX11.$ac_extension"; then
9501 ac_im_usrlibdir=$ac_im_libdir; break
9502 fi
9503 done
9504 # Screen out bogus values from the imake configuration. They are
9505 # bogus both because they are the default anyway, and because
9506 # using them would break gcc on systems where it needs fixed includes.
9507 case $ac_im_incroot in
9508 /usr/include) ac_x_includes= ;;
9509 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;;
9510 esac
9511 case $ac_im_usrlibdir in
9512 /usr/lib | /usr/lib64 | /lib | /lib64) ;;
9513 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;;
9514 esac
9515 fi
9516 cd ..
9517 rm -f -r conftest.dir
9518 fi
9519
9520 # Standard set of common directories for X headers.
9521 # Check X11 before X11Rn because it is often a symlink to the current release.
9522 ac_x_header_dirs='
9523 /usr/X11/include
9524 /usr/X11R7/include
9525 /usr/X11R6/include
9526 /usr/X11R5/include
9527 /usr/X11R4/include
9528
9529 /usr/include/X11
9530 /usr/include/X11R7
9531 /usr/include/X11R6
9532 /usr/include/X11R5
9533 /usr/include/X11R4
9534
9535 /usr/local/X11/include
9536 /usr/local/X11R7/include
9537 /usr/local/X11R6/include
9538 /usr/local/X11R5/include
9539 /usr/local/X11R4/include
9540
9541 /usr/local/include/X11
9542 /usr/local/include/X11R7
9543 /usr/local/include/X11R6
9544 /usr/local/include/X11R5
9545 /usr/local/include/X11R4
9546
9547 /usr/X386/include
9548 /usr/x386/include
9549 /usr/XFree86/include/X11
9550
9551 /usr/include
9552 /usr/local/include
9553 /usr/unsupported/include
9554 /usr/athena/include
9555 /usr/local/x11r5/include
9556 /usr/lpp/Xamples/include
9557
9558 /usr/openwin/include
9559 /usr/openwin/share/include'
9560
9561 if test "$ac_x_includes" = no; then
9562 # Guess where to find include files, by looking for Xlib.h.
9563 # First, try using that file with no special directory specified.
9564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9565 /* end confdefs.h. */
9566 #include <X11/Xlib.h>
9567 _ACEOF
9568 if ac_fn_c_try_cpp "$LINENO"; then :
9569 # We can compile using X headers with no special include directory.
9570 ac_x_includes=
9571 else
9572 for ac_dir in $ac_x_header_dirs; do
9573 if test -r "$ac_dir/X11/Xlib.h"; then
9574 ac_x_includes=$ac_dir
9575 break
9576 fi
9577 done
9578 fi
9579 rm -f conftest.err conftest.$ac_ext
9580 fi # $ac_x_includes = no
9581
9582 if test "$ac_x_libraries" = no; then
9583 # Check for the libraries.
9584 # See if we find them without any special options.
9585 # Don't add to $LIBS permanently.
9586 ac_save_LIBS=$LIBS
9587 LIBS="-lX11 $LIBS"
9588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9589 /* end confdefs.h. */
9590 #include <X11/Xlib.h>
9591 int
9592 main ()
9593 {
9594 XrmInitialize ()
9595 ;
9596 return 0;
9597 }
9598 _ACEOF
9599 if ac_fn_c_try_link "$LINENO"; then :
9600 LIBS=$ac_save_LIBS
9601 # We can link X programs with no special library path.
9602 ac_x_libraries=
9603 else
9604 LIBS=$ac_save_LIBS
9605 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g`
9606 do
9607 # Don't even attempt the hair of trying to link an X program!
9608 for ac_extension in a so sl dylib la dll; do
9609 if test -r "$ac_dir/libX11.$ac_extension"; then
9610 ac_x_libraries=$ac_dir
9611 break 2
9612 fi
9613 done
9614 done
9615 fi
9616 rm -f core conftest.err conftest.$ac_objext \
9617 conftest$ac_exeext conftest.$ac_ext
9618 fi # $ac_x_libraries = no
9619
9620 case $ac_x_includes,$ac_x_libraries in #(
9621 no,* | *,no | *\'*)
9622 # Didn't find X, or a directory has "'" in its name.
9623 ac_cv_have_x="have_x=no";; #(
9624 *)
9625 # Record where we found X for the cache.
9626 ac_cv_have_x="have_x=yes\
9627 ac_x_includes='$ac_x_includes'\
9628 ac_x_libraries='$ac_x_libraries'"
9629 esac
9630 fi
9631 ;; #(
9632 *) have_x=yes;;
9633 esac
9634 eval "$ac_cv_have_x"
9635 fi # $with_x != no
9636
9637 if test "$have_x" != yes; then
9638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5
9639 $as_echo "$have_x" >&6; }
9640 no_x=yes
9641 else
9642 # If each of the values was on the command line, it overrides each guess.
9643 test "x$x_includes" = xNONE && x_includes=$ac_x_includes
9644 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries
9645 # Update the cache value to reflect the command line values.
9646 ac_cv_have_x="have_x=yes\
9647 ac_x_includes='$x_includes'\
9648 ac_x_libraries='$x_libraries'"
9649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5
9650 $as_echo "libraries $x_libraries, headers $x_includes" >&6; }
9651 fi
9652
9653 if test "$no_x" = yes; then
9654 window_system=none
9655 else
9656 window_system=x11
9657 fi
9658
9659 ## Workaround for bug in autoconf <= 2.62.
9660 ## http://lists.gnu.org/archive/html/emacs-devel/2008-04/msg01551.html
9661 ## No need to do anything special for these standard directories.
9662 if test -n "${x_libraries}" && test x"${x_libraries}" != xNONE; then
9663
9664 x_libraries=`echo :${x_libraries}: | sed -e 's|:/usr/lib64:|:|g' -e 's|:/lib64:|:|g' -e 's|^:||' -e 's|:$||'`
9665
9666 fi
9667
9668 LD_SWITCH_X_SITE_AUX=
9669 LD_SWITCH_X_SITE_AUX_RPATH=
9670 if test "${x_libraries}" != NONE; then
9671 if test -n "${x_libraries}"; then
9672 LD_SWITCH_X_SITE=-L`echo ${x_libraries} | sed -e "s/:/ -L/g"`
9673 LD_SWITCH_X_SITE_AUX=-R`echo ${x_libraries} | sed -e "s/:/ -R/g"`
9674 LD_SWITCH_X_SITE_AUX_RPATH=`echo ${LD_SWITCH_X_SITE_AUX} | sed -e 's/-R/-Wl,-rpath,/'`
9675 fi
9676 x_default_search_path=""
9677 x_search_path=${x_libraries}
9678 if test -z "${x_search_path}"; then
9679 x_search_path=/usr/lib
9680 fi
9681 for x_library in `echo ${x_search_path}: | \
9682 sed -e "s/:/ /g" -e p -e "s:/lib[^ /]* :/share :g"`; do
9683 x_search_path="\
9684 ${x_library}/X11/%L/%T/%N%C%S:\
9685 ${x_library}/X11/%l/%T/%N%C%S:\
9686 ${x_library}/X11/%T/%N%C%S:\
9687 ${x_library}/X11/%L/%T/%N%S:\
9688 ${x_library}/X11/%l/%T/%N%S:\
9689 ${x_library}/X11/%T/%N%S"
9690 if test x"${x_default_search_path}" = x; then
9691 x_default_search_path=${x_search_path}
9692 else
9693 x_default_search_path="${x_search_path}:${x_default_search_path}"
9694 fi
9695 done
9696 fi
9697
9698
9699
9700 if test "${x_includes}" != NONE && test -n "${x_includes}"; then
9701 C_SWITCH_X_SITE=-I`echo ${x_includes} | sed -e "s/:/ -I/g"`
9702 fi
9703
9704 if test x"${x_includes}" = x; then
9705 bitmapdir=/usr/include/X11/bitmaps
9706 else
9707 # accumulate include directories that have X11 bitmap subdirectories
9708 bmd_acc="dummyval"
9709 for bmd in `echo ${x_includes} | sed -e "s/:/ /g"`; do
9710 if test -d "${bmd}/X11/bitmaps"; then
9711 bmd_acc="${bmd_acc}:${bmd}/X11/bitmaps"
9712 fi
9713 if test -d "${bmd}/bitmaps"; then
9714 bmd_acc="${bmd_acc}:${bmd}/bitmaps"
9715 fi
9716 done
9717 if test ${bmd_acc} != "dummyval"; then
9718 bitmapdir=`echo ${bmd_acc} | sed -e "s/^dummyval://"`
9719 fi
9720 fi
9721
9722 HAVE_NS=no
9723 NS_IMPL_COCOA=no
9724 NS_IMPL_GNUSTEP=no
9725 tmp_CPPFLAGS="$CPPFLAGS"
9726 tmp_CFLAGS="$CFLAGS"
9727 CPPFLAGS="$CPPFLAGS -x objective-c"
9728 CFLAGS="$CFLAGS -x objective-c"
9729 TEMACS_LDFLAGS2="\${LDFLAGS}"
9730 GNU_OBJC_CFLAGS=
9731 if test "${with_ns}" != no; then
9732 if test "${opsys}" = darwin; then
9733 NS_IMPL_COCOA=yes
9734 ns_appdir=`pwd`/nextstep/Emacs.app
9735 ns_appbindir=${ns_appdir}/Contents/MacOS/
9736 ns_appresdir=${ns_appdir}/Contents/Resources
9737 ns_appsrc=${srcdir}/nextstep/Cocoa/Emacs.base
9738 elif test -f $GNUSTEP_CONFIG_FILE; then
9739 NS_IMPL_GNUSTEP=yes
9740 ns_appdir=`pwd`/nextstep/Emacs.app
9741 ns_appbindir=${ns_appdir}/
9742 ns_appresdir=${ns_appdir}/Resources
9743 ns_appsrc=${srcdir}/nextstep/GNUstep/Emacs.base
9744 GNUSTEP_SYSTEM_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_HEADERS)"
9745 GNUSTEP_SYSTEM_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_SYSTEM_LIBRARIES)"
9746 GNUSTEP_LOCAL_HEADERS="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_HEADERS)"
9747 GNUSTEP_LOCAL_LIBRARIES="$(. $GNUSTEP_CONFIG_FILE; echo $GNUSTEP_LOCAL_LIBRARIES)"
9748 test "x${GNUSTEP_LOCAL_HEADERS}" != "x" && \
9749 GNUSTEP_LOCAL_HEADERS="-I${GNUSTEP_LOCAL_HEADERS}"
9750 test "x${GNUSTEP_LOCAL_LIBRARIES}" != "x" && \
9751 GNUSTEP_LOCAL_LIBRARIES="-L${GNUSTEP_LOCAL_LIBRARIES}"
9752 CPPFLAGS="$CPPFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9753 CFLAGS="$CFLAGS -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
9754 LDFLAGS="$LDFLAGS -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES}"
9755 LIB_STANDARD=
9756 START_FILES=
9757 TEMACS_LDFLAGS2=
9758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS" >&5
9759 $as_echo_n "checking if GNUstep defines BASE_NATIVE_OBJC_EXCEPTIONS... " >&6; }
9760 if test "${emacs_cv_objc_exceptions+set}" = set; then :
9761 $as_echo_n "(cached) " >&6
9762 else
9763 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9764 /* end confdefs.h. */
9765 #include <GNUstepBase/GSConfig.h>
9766 int
9767 main ()
9768 {
9769 #if defined BASE_NATIVE_OBJC_EXCEPTIONS && BASE_NATIVE_OBJC_EXCEPTIONS > 0
9770 1;
9771 #else
9772 fail;
9773 #endif
9774 ;
9775 return 0;
9776 }
9777 _ACEOF
9778 if ac_fn_c_try_compile "$LINENO"; then :
9779 emacs_cv_objc_exceptions=yes
9780 else
9781 emacs_cv_objc_exceptions=no
9782 fi
9783 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9784 fi
9785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_objc_exceptions" >&5
9786 $as_echo "$emacs_cv_objc_exceptions" >&6; }
9787 if test $emacs_cv_objc_exceptions = yes; then
9788
9789 $as_echo "#define _NATIVE_OBJC_EXCEPTIONS 1" >>confdefs.h
9790
9791 GNU_OBJC_CFLAGS="-fobjc-exceptions"
9792 fi
9793 fi
9794
9795 CFLAGS="$CFLAGS $GNU_OBJC_CFLAGS"
9796
9797 ac_fn_c_check_header_mongrel "$LINENO" "AppKit/AppKit.h" "ac_cv_header_AppKit_AppKit_h" "$ac_includes_default"
9798 if test "x$ac_cv_header_AppKit_AppKit_h" = x""yes; then :
9799 HAVE_NS=yes
9800 else
9801 as_fn_error "\`--with-ns' was specified, but the include
9802 files are missing or cannot be compiled." "$LINENO" 5
9803 fi
9804
9805
9806 NS_HAVE_NSINTEGER=yes
9807 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9808 /* end confdefs.h. */
9809 #include <Foundation/NSObjCRuntime.h>
9810 int
9811 main ()
9812 {
9813 NSInteger i;
9814 ;
9815 return 0;
9816 }
9817 _ACEOF
9818 if ac_fn_c_try_compile "$LINENO"; then :
9819 ns_have_nsinteger=yes
9820 else
9821 ns_have_nsinteger=no
9822 fi
9823 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9824 if test $ns_have_nsinteger = no; then
9825 NS_HAVE_NSINTEGER=no
9826 fi
9827 fi
9828
9829
9830 ns_frag=/dev/null
9831 NS_OBJ=
9832 NS_OBJC_OBJ=
9833 if test "${HAVE_NS}" = yes; then
9834 if test "$with_toolkit_scroll_bars" = "no"; then
9835 as_fn_error "Non-toolkit scroll bars are not implemented for Nextstep." "$LINENO" 5
9836 fi
9837
9838 window_system=nextstep
9839 with_xft=no
9840 # set up packaging dirs
9841 if test "${EN_NS_SELF_CONTAINED}" = yes; then
9842 prefix=${ns_appresdir}
9843 exec_prefix=${ns_appbindir}
9844 libexecdir=${ns_appbindir}/libexec
9845 fi
9846 ns_frag=$srcdir/src/ns.mk
9847 NS_OBJ="fontset.o fringe.o image.o"
9848 NS_OBJC_OBJ="nsterm.o nsfns.o nsmenu.o nsselect.o nsimage.o nsfont.o"
9849 fi
9850 CFLAGS="$tmp_CFLAGS"
9851 CPPFLAGS="$tmp_CPPFLAGS"
9852
9853
9854
9855
9856
9857 case "${window_system}" in
9858 x11 )
9859 HAVE_X_WINDOWS=yes
9860 HAVE_X11=yes
9861 case "${with_x_toolkit}" in
9862 athena | lucid ) USE_X_TOOLKIT=LUCID ;;
9863 motif ) USE_X_TOOLKIT=MOTIF ;;
9864 gtk ) with_gtk=yes
9865 USE_X_TOOLKIT=none ;;
9866 gtk3 ) with_gtk3=yes
9867 USE_X_TOOLKIT=none ;;
9868 no ) USE_X_TOOLKIT=none ;;
9869 * ) USE_X_TOOLKIT=maybe ;;
9870 esac
9871 ;;
9872 nextstep | none )
9873 HAVE_X_WINDOWS=no
9874 HAVE_X11=no
9875 USE_X_TOOLKIT=none
9876 ;;
9877 esac
9878
9879 if test "$window_system" = none && test "X$with_x" != "Xno"; then
9880 # Extract the first word of "X", so it can be a program name with args.
9881 set dummy X; ac_word=$2
9882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
9883 $as_echo_n "checking for $ac_word... " >&6; }
9884 if test "${ac_cv_prog_HAVE_XSERVER+set}" = set; then :
9885 $as_echo_n "(cached) " >&6
9886 else
9887 if test -n "$HAVE_XSERVER"; then
9888 ac_cv_prog_HAVE_XSERVER="$HAVE_XSERVER" # Let the user override the test.
9889 else
9890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
9891 for as_dir in $PATH
9892 do
9893 IFS=$as_save_IFS
9894 test -z "$as_dir" && as_dir=.
9895 for ac_exec_ext in '' $ac_executable_extensions; do
9896 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
9897 ac_cv_prog_HAVE_XSERVER="true"
9898 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
9899 break 2
9900 fi
9901 done
9902 done
9903 IFS=$as_save_IFS
9904
9905 test -z "$ac_cv_prog_HAVE_XSERVER" && ac_cv_prog_HAVE_XSERVER="false"
9906 fi
9907 fi
9908 HAVE_XSERVER=$ac_cv_prog_HAVE_XSERVER
9909 if test -n "$HAVE_XSERVER"; then
9910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HAVE_XSERVER" >&5
9911 $as_echo "$HAVE_XSERVER" >&6; }
9912 else
9913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9914 $as_echo "no" >&6; }
9915 fi
9916
9917
9918 if test "$HAVE_XSERVER" = true ||
9919 test -n "$DISPLAY" ||
9920 test "`echo /usr/lib/libX11.*`" != "/usr/lib/libX11.*"; then
9921 as_fn_error "You seem to be running X, but no X development libraries
9922 were found. You should install the relevant development files for X
9923 and for the toolkit you want, such as Gtk+, Lesstif or Motif. Also make
9924 sure you have development files for image handling, i.e.
9925 tiff, gif, jpeg, png and xpm.
9926 If you are sure you want Emacs compiled without X window support, pass
9927 --without-x
9928 to configure." "$LINENO" 5
9929 fi
9930 fi
9931
9932 ### If we're using X11, we should use the X menu package.
9933 HAVE_MENUS=no
9934 case ${HAVE_X11} in
9935 yes ) HAVE_MENUS=yes ;;
9936 esac
9937
9938 # Do the opsystem or machine files prohibit the use of the GNU malloc?
9939 # Assume not, until told otherwise.
9940 GNU_MALLOC=yes
9941 doug_lea_malloc=yes
9942 ac_fn_c_check_func "$LINENO" "malloc_get_state" "ac_cv_func_malloc_get_state"
9943 if test "x$ac_cv_func_malloc_get_state" = x""yes; then :
9944
9945 else
9946 doug_lea_malloc=no
9947 fi
9948
9949 ac_fn_c_check_func "$LINENO" "malloc_set_state" "ac_cv_func_malloc_set_state"
9950 if test "x$ac_cv_func_malloc_set_state" = x""yes; then :
9951
9952 else
9953 doug_lea_malloc=no
9954 fi
9955
9956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __after_morecore_hook exists" >&5
9957 $as_echo_n "checking whether __after_morecore_hook exists... " >&6; }
9958 if test "${emacs_cv_var___after_morecore_hook+set}" = set; then :
9959 $as_echo_n "(cached) " >&6
9960 else
9961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9962 /* end confdefs.h. */
9963 extern void (* __after_morecore_hook)();
9964 int
9965 main ()
9966 {
9967 __after_morecore_hook = 0
9968 ;
9969 return 0;
9970 }
9971 _ACEOF
9972 if ac_fn_c_try_link "$LINENO"; then :
9973 emacs_cv_var___after_morecore_hook=yes
9974 else
9975 emacs_cv_var___after_morecore_hook=no
9976 fi
9977 rm -f core conftest.err conftest.$ac_objext \
9978 conftest$ac_exeext conftest.$ac_ext
9979 fi
9980 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_var___after_morecore_hook" >&5
9981 $as_echo "$emacs_cv_var___after_morecore_hook" >&6; }
9982 if test $emacs_cv_var___after_morecore_hook = no; then
9983 doug_lea_malloc=no
9984 fi
9985
9986
9987 system_malloc=no
9988 case "$opsys" in
9989 ## darwin ld insists on the use of malloc routines in the System framework.
9990 darwin|sol2-10) system_malloc=yes ;;
9991 esac
9992
9993 if test "${system_malloc}" = "yes"; then
9994
9995 $as_echo "#define SYSTEM_MALLOC 1" >>confdefs.h
9996
9997 GNU_MALLOC=no
9998 GNU_MALLOC_reason="
9999 (The GNU allocators don't work with this system configuration.)"
10000 GMALLOC_OBJ=
10001 VMLIMIT_OBJ=
10002 else
10003 test "$doug_lea_malloc" != "yes" && GMALLOC_OBJ=gmalloc.o
10004 VMLIMIT_OBJ=vm-limit.o
10005 fi
10006
10007
10008
10009 if test "$doug_lea_malloc" = "yes" ; then
10010 if test "$GNU_MALLOC" = yes ; then
10011 GNU_MALLOC_reason="
10012 (Using Doug Lea's new malloc from the GNU C Library.)"
10013 fi
10014
10015 $as_echo "#define DOUG_LEA_MALLOC 1" >>confdefs.h
10016
10017
10018 ## Use mmap directly for allocating larger buffers.
10019 ## FIXME this comes from src/s/{gnu,gnu-linux}.h:
10020 ## #ifdef DOUG_LEA_MALLOC; #undef REL_ALLOC; #endif
10021 ## Does the AC_FUNC_MMAP test below make this check unnecessary?
10022 case "$opsys" in
10023 gnu*) REL_ALLOC=no ;;
10024 esac
10025 fi
10026
10027 if test x"${REL_ALLOC}" = x; then
10028 REL_ALLOC=${GNU_MALLOC}
10029 fi
10030
10031 use_mmap_for_buffers=no
10032 case "$opsys" in
10033 cygwin|freebsd|irix6-5) use_mmap_for_buffers=yes ;;
10034 esac
10035
10036
10037
10038
10039 for ac_header in $ac_header_list
10040 do :
10041 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10042 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
10043 "
10044 eval as_val=\$$as_ac_Header
10045 if test "x$as_val" = x""yes; then :
10046 cat >>confdefs.h <<_ACEOF
10047 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10048 _ACEOF
10049
10050 fi
10051
10052 done
10053
10054
10055
10056
10057
10058
10059
10060
10061 for ac_func in getpagesize
10062 do :
10063 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
10064 if test "x$ac_cv_func_getpagesize" = x""yes; then :
10065 cat >>confdefs.h <<_ACEOF
10066 #define HAVE_GETPAGESIZE 1
10067 _ACEOF
10068
10069 fi
10070 done
10071
10072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
10073 $as_echo_n "checking for working mmap... " >&6; }
10074 if test "${ac_cv_func_mmap_fixed_mapped+set}" = set; then :
10075 $as_echo_n "(cached) " >&6
10076 else
10077 if test "$cross_compiling" = yes; then :
10078 ac_cv_func_mmap_fixed_mapped=no
10079 else
10080 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10081 /* end confdefs.h. */
10082 $ac_includes_default
10083 /* malloc might have been renamed as rpl_malloc. */
10084 #undef malloc
10085
10086 /* Thanks to Mike Haertel and Jim Avera for this test.
10087 Here is a matrix of mmap possibilities:
10088 mmap private not fixed
10089 mmap private fixed at somewhere currently unmapped
10090 mmap private fixed at somewhere already mapped
10091 mmap shared not fixed
10092 mmap shared fixed at somewhere currently unmapped
10093 mmap shared fixed at somewhere already mapped
10094 For private mappings, we should verify that changes cannot be read()
10095 back from the file, nor mmap's back from the file at a different
10096 address. (There have been systems where private was not correctly
10097 implemented like the infamous i386 svr4.0, and systems where the
10098 VM page cache was not coherent with the file system buffer cache
10099 like early versions of FreeBSD and possibly contemporary NetBSD.)
10100 For shared mappings, we should conversely verify that changes get
10101 propagated back to all the places they're supposed to be.
10102
10103 Grep wants private fixed already mapped.
10104 The main things grep needs to know about mmap are:
10105 * does it exist and is it safe to write into the mmap'd area
10106 * how to use it (BSD variants) */
10107
10108 #include <fcntl.h>
10109 #include <sys/mman.h>
10110
10111 #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H
10112 char *malloc ();
10113 #endif
10114
10115 /* This mess was copied from the GNU getpagesize.h. */
10116 #ifndef HAVE_GETPAGESIZE
10117 # ifdef _SC_PAGESIZE
10118 # define getpagesize() sysconf(_SC_PAGESIZE)
10119 # else /* no _SC_PAGESIZE */
10120 # ifdef HAVE_SYS_PARAM_H
10121 # include <sys/param.h>
10122 # ifdef EXEC_PAGESIZE
10123 # define getpagesize() EXEC_PAGESIZE
10124 # else /* no EXEC_PAGESIZE */
10125 # ifdef NBPG
10126 # define getpagesize() NBPG * CLSIZE
10127 # ifndef CLSIZE
10128 # define CLSIZE 1
10129 # endif /* no CLSIZE */
10130 # else /* no NBPG */
10131 # ifdef NBPC
10132 # define getpagesize() NBPC
10133 # else /* no NBPC */
10134 # ifdef PAGESIZE
10135 # define getpagesize() PAGESIZE
10136 # endif /* PAGESIZE */
10137 # endif /* no NBPC */
10138 # endif /* no NBPG */
10139 # endif /* no EXEC_PAGESIZE */
10140 # else /* no HAVE_SYS_PARAM_H */
10141 # define getpagesize() 8192 /* punt totally */
10142 # endif /* no HAVE_SYS_PARAM_H */
10143 # endif /* no _SC_PAGESIZE */
10144
10145 #endif /* no HAVE_GETPAGESIZE */
10146
10147 int
10148 main ()
10149 {
10150 char *data, *data2, *data3;
10151 const char *cdata2;
10152 int i, pagesize;
10153 int fd, fd2;
10154
10155 pagesize = getpagesize ();
10156
10157 /* First, make a file with some known garbage in it. */
10158 data = (char *) malloc (pagesize);
10159 if (!data)
10160 return 1;
10161 for (i = 0; i < pagesize; ++i)
10162 *(data + i) = rand ();
10163 umask (0);
10164 fd = creat ("conftest.mmap", 0600);
10165 if (fd < 0)
10166 return 2;
10167 if (write (fd, data, pagesize) != pagesize)
10168 return 3;
10169 close (fd);
10170
10171 /* Next, check that the tail of a page is zero-filled. File must have
10172 non-zero length, otherwise we risk SIGBUS for entire page. */
10173 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
10174 if (fd2 < 0)
10175 return 4;
10176 cdata2 = "";
10177 if (write (fd2, cdata2, 1) != 1)
10178 return 5;
10179 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
10180 if (data2 == MAP_FAILED)
10181 return 6;
10182 for (i = 0; i < pagesize; ++i)
10183 if (*(data2 + i))
10184 return 7;
10185 close (fd2);
10186 if (munmap (data2, pagesize))
10187 return 8;
10188
10189 /* Next, try to mmap the file at a fixed address which already has
10190 something else allocated at it. If we can, also make sure that
10191 we see the same garbage. */
10192 fd = open ("conftest.mmap", O_RDWR);
10193 if (fd < 0)
10194 return 9;
10195 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
10196 MAP_PRIVATE | MAP_FIXED, fd, 0L))
10197 return 10;
10198 for (i = 0; i < pagesize; ++i)
10199 if (*(data + i) != *(data2 + i))
10200 return 11;
10201
10202 /* Finally, make sure that changes to the mapped area do not
10203 percolate back to the file as seen by read(). (This is a bug on
10204 some variants of i386 svr4.0.) */
10205 for (i = 0; i < pagesize; ++i)
10206 *(data2 + i) = *(data2 + i) + 1;
10207 data3 = (char *) malloc (pagesize);
10208 if (!data3)
10209 return 12;
10210 if (read (fd, data3, pagesize) != pagesize)
10211 return 13;
10212 for (i = 0; i < pagesize; ++i)
10213 if (*(data + i) != *(data3 + i))
10214 return 14;
10215 close (fd);
10216 return 0;
10217 }
10218 _ACEOF
10219 if ac_fn_c_try_run "$LINENO"; then :
10220 ac_cv_func_mmap_fixed_mapped=yes
10221 else
10222 ac_cv_func_mmap_fixed_mapped=no
10223 fi
10224 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10225 conftest.$ac_objext conftest.beam conftest.$ac_ext
10226 fi
10227
10228 fi
10229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
10230 $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; }
10231 if test $ac_cv_func_mmap_fixed_mapped = yes; then
10232
10233 $as_echo "#define HAVE_MMAP 1" >>confdefs.h
10234
10235 fi
10236 rm -f conftest.mmap conftest.txt
10237
10238 if test $use_mmap_for_buffers = yes; then
10239
10240 $as_echo "#define USE_MMAP_FOR_BUFFERS 1" >>confdefs.h
10241
10242 REL_ALLOC=no
10243 fi
10244
10245 LIBS="$LIBS_SYSTEM $LIBS"
10246
10247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5
10248 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; }
10249 if test "${ac_cv_lib_dnet_dnet_ntoa+set}" = set; then :
10250 $as_echo_n "(cached) " >&6
10251 else
10252 ac_check_lib_save_LIBS=$LIBS
10253 LIBS="-ldnet $LIBS"
10254 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10255 /* end confdefs.h. */
10256
10257 /* Override any GCC internal prototype to avoid an error.
10258 Use char because int might match the return type of a GCC
10259 builtin and then its argument prototype would still apply. */
10260 #ifdef __cplusplus
10261 extern "C"
10262 #endif
10263 char dnet_ntoa ();
10264 int
10265 main ()
10266 {
10267 return dnet_ntoa ();
10268 ;
10269 return 0;
10270 }
10271 _ACEOF
10272 if ac_fn_c_try_link "$LINENO"; then :
10273 ac_cv_lib_dnet_dnet_ntoa=yes
10274 else
10275 ac_cv_lib_dnet_dnet_ntoa=no
10276 fi
10277 rm -f core conftest.err conftest.$ac_objext \
10278 conftest$ac_exeext conftest.$ac_ext
10279 LIBS=$ac_check_lib_save_LIBS
10280 fi
10281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5
10282 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; }
10283 if test "x$ac_cv_lib_dnet_dnet_ntoa" = x""yes; then :
10284 cat >>confdefs.h <<_ACEOF
10285 #define HAVE_LIBDNET 1
10286 _ACEOF
10287
10288 LIBS="-ldnet $LIBS"
10289
10290 fi
10291
10292
10293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for main in -lXbsd" >&5
10294 $as_echo_n "checking for main in -lXbsd... " >&6; }
10295 if test "${ac_cv_lib_Xbsd_main+set}" = set; then :
10296 $as_echo_n "(cached) " >&6
10297 else
10298 ac_check_lib_save_LIBS=$LIBS
10299 LIBS="-lXbsd $LIBS"
10300 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10301 /* end confdefs.h. */
10302
10303
10304 int
10305 main ()
10306 {
10307 return main ();
10308 ;
10309 return 0;
10310 }
10311 _ACEOF
10312 if ac_fn_c_try_link "$LINENO"; then :
10313 ac_cv_lib_Xbsd_main=yes
10314 else
10315 ac_cv_lib_Xbsd_main=no
10316 fi
10317 rm -f core conftest.err conftest.$ac_objext \
10318 conftest$ac_exeext conftest.$ac_ext
10319 LIBS=$ac_check_lib_save_LIBS
10320 fi
10321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xbsd_main" >&5
10322 $as_echo "$ac_cv_lib_Xbsd_main" >&6; }
10323 if test "x$ac_cv_lib_Xbsd_main" = x""yes; then :
10324 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -lXbsd"
10325 fi
10326
10327
10328 LIB_PTHREAD=
10329 for ac_header in pthread.h
10330 do :
10331 ac_fn_c_check_header_mongrel "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
10332 if test "x$ac_cv_header_pthread_h" = x""yes; then :
10333 cat >>confdefs.h <<_ACEOF
10334 #define HAVE_PTHREAD_H 1
10335 _ACEOF
10336
10337 fi
10338
10339 done
10340
10341 if test "$ac_cv_header_pthread_h"; then
10342 if test "$GMALLOC_OBJ" = gmalloc.o; then
10343 emacs_pthread_function=pthread_atfork
10344 else
10345 emacs_pthread_function=pthread_self
10346 fi
10347 as_ac_Lib=`$as_echo "ac_cv_lib_pthread_$emacs_pthread_function" | $as_tr_sh`
10348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $emacs_pthread_function in -lpthread" >&5
10349 $as_echo_n "checking for $emacs_pthread_function in -lpthread... " >&6; }
10350 if { as_var=$as_ac_Lib; eval "test \"\${$as_var+set}\" = set"; }; then :
10351 $as_echo_n "(cached) " >&6
10352 else
10353 ac_check_lib_save_LIBS=$LIBS
10354 LIBS="-lpthread $LIBS"
10355 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10356 /* end confdefs.h. */
10357
10358 /* Override any GCC internal prototype to avoid an error.
10359 Use char because int might match the return type of a GCC
10360 builtin and then its argument prototype would still apply. */
10361 #ifdef __cplusplus
10362 extern "C"
10363 #endif
10364 char $emacs_pthread_function ();
10365 int
10366 main ()
10367 {
10368 return $emacs_pthread_function ();
10369 ;
10370 return 0;
10371 }
10372 _ACEOF
10373 if ac_fn_c_try_link "$LINENO"; then :
10374 eval "$as_ac_Lib=yes"
10375 else
10376 eval "$as_ac_Lib=no"
10377 fi
10378 rm -f core conftest.err conftest.$ac_objext \
10379 conftest$ac_exeext conftest.$ac_ext
10380 LIBS=$ac_check_lib_save_LIBS
10381 fi
10382 eval ac_res=\$$as_ac_Lib
10383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
10384 $as_echo "$ac_res" >&6; }
10385 eval as_val=\$$as_ac_Lib
10386 if test "x$as_val" = x""yes; then :
10387 HAVE_PTHREAD=yes
10388 fi
10389
10390 fi
10391 if test "$HAVE_PTHREAD" = yes; then
10392 case "${canonical}" in
10393 *-hpux*) ;;
10394 *) LIB_PTHREAD="-lpthread"
10395 LIBS="$LIB_PTHREAD $LIBS" ;;
10396 esac
10397
10398 $as_echo "#define HAVE_PTHREAD 1" >>confdefs.h
10399
10400 fi
10401
10402
10403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cma_open in -lpthreads" >&5
10404 $as_echo_n "checking for cma_open in -lpthreads... " >&6; }
10405 if test "${ac_cv_lib_pthreads_cma_open+set}" = set; then :
10406 $as_echo_n "(cached) " >&6
10407 else
10408 ac_check_lib_save_LIBS=$LIBS
10409 LIBS="-lpthreads $LIBS"
10410 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10411 /* end confdefs.h. */
10412
10413 /* Override any GCC internal prototype to avoid an error.
10414 Use char because int might match the return type of a GCC
10415 builtin and then its argument prototype would still apply. */
10416 #ifdef __cplusplus
10417 extern "C"
10418 #endif
10419 char cma_open ();
10420 int
10421 main ()
10422 {
10423 return cma_open ();
10424 ;
10425 return 0;
10426 }
10427 _ACEOF
10428 if ac_fn_c_try_link "$LINENO"; then :
10429 ac_cv_lib_pthreads_cma_open=yes
10430 else
10431 ac_cv_lib_pthreads_cma_open=no
10432 fi
10433 rm -f core conftest.err conftest.$ac_objext \
10434 conftest$ac_exeext conftest.$ac_ext
10435 LIBS=$ac_check_lib_save_LIBS
10436 fi
10437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthreads_cma_open" >&5
10438 $as_echo "$ac_cv_lib_pthreads_cma_open" >&6; }
10439 if test "x$ac_cv_lib_pthreads_cma_open" = x""yes; then :
10440 cat >>confdefs.h <<_ACEOF
10441 #define HAVE_LIBPTHREADS 1
10442 _ACEOF
10443
10444 LIBS="-lpthreads $LIBS"
10445
10446 fi
10447
10448
10449 ## Note: when using cpp in s/aix4.2.h, this definition depended on
10450 ## HAVE_LIBPTHREADS. That was not defined earlier in configure when
10451 ## the system file was sourced. Hence the value of LIBS_SYSTEM
10452 ## added to LIBS in configure would never contain the pthreads part,
10453 ## but the value used in Makefiles might. FIXME?
10454 ##
10455 ## -lpthreads seems to be necessary for Xlib in X11R6, and should
10456 ## be harmless on older versions of X where it happens to exist.
10457 test "$opsys" = "aix4-2" && \
10458 test $ac_cv_lib_pthreads_cma_open = yes && \
10459 LIBS_SYSTEM="$LIBS_SYSTEM -lpthreads"
10460
10461
10462 case ${host_os} in
10463 aix*)
10464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -bbigtoc option" >&5
10465 $as_echo_n "checking for -bbigtoc option... " >&6; }
10466 if test "${gdb_cv_bigtoc+set}" = set; then :
10467 $as_echo_n "(cached) " >&6
10468 else
10469
10470 case $GCC in
10471 yes) gdb_cv_bigtoc=-Wl,-bbigtoc ;;
10472 *) gdb_cv_bigtoc=-bbigtoc ;;
10473 esac
10474
10475 LDFLAGS=$LDFLAGS\ $gdb_cv_bigtoc
10476 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10477 /* end confdefs.h. */
10478
10479 int
10480 main ()
10481 {
10482 int i;
10483 ;
10484 return 0;
10485 }
10486 _ACEOF
10487 if ac_fn_c_try_link "$LINENO"; then :
10488
10489 else
10490 gdb_cv_bigtoc=
10491 fi
10492 rm -f core conftest.err conftest.$ac_objext \
10493 conftest$ac_exeext conftest.$ac_ext
10494
10495 fi
10496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gdb_cv_bigtoc" >&5
10497 $as_echo "$gdb_cv_bigtoc" >&6; }
10498 ;;
10499 esac
10500
10501 # Change CFLAGS and CPPFLAGS temporarily so that C_SWITCH_X_SITE gets
10502 # used for the tests that follow. We set them back to REAL_CFLAGS and
10503 # REAL_CPPFLAGS later on.
10504
10505 REAL_CFLAGS="$CFLAGS"
10506 REAL_CPPFLAGS="$CPPFLAGS"
10507
10508 if test "${HAVE_X11}" = "yes"; then
10509 DEFS="$C_SWITCH_X_SITE $DEFS"
10510 LDFLAGS="$LDFLAGS $LD_SWITCH_X_SITE"
10511 LIBS="-lX11 $LIBS"
10512 CFLAGS="$C_SWITCH_X_SITE $CFLAGS"
10513 CPPFLAGS="$C_SWITCH_X_SITE $CPPFLAGS"
10514
10515 # On Solaris, arrange for LD_RUN_PATH to point to the X libraries for tests.
10516 # This is handled by LD_SWITCH_X_SITE_AUX during the real build,
10517 # but it's more convenient here to set LD_RUN_PATH
10518 # since this also works on hosts that don't understand LD_SWITCH_X_SITE_AUX.
10519 if test "${x_libraries}" != NONE && test -n "${x_libraries}"; then
10520 LD_RUN_PATH=$x_libraries${LD_RUN_PATH+:}$LD_RUN_PATH
10521 export LD_RUN_PATH
10522 fi
10523
10524 if test "${opsys}" = "gnu-linux"; then
10525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether X on GNU/Linux needs -b to link" >&5
10526 $as_echo_n "checking whether X on GNU/Linux needs -b to link... " >&6; }
10527 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10528 /* end confdefs.h. */
10529
10530 int
10531 main ()
10532 {
10533 XOpenDisplay ("foo");
10534 ;
10535 return 0;
10536 }
10537 _ACEOF
10538 if ac_fn_c_try_link "$LINENO"; then :
10539 xgnu_linux_first_failure=no
10540 else
10541 xgnu_linux_first_failure=yes
10542 fi
10543 rm -f core conftest.err conftest.$ac_objext \
10544 conftest$ac_exeext conftest.$ac_ext
10545 if test "${xgnu_linux_first_failure}" = "yes"; then
10546 OLD_LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE"
10547 OLD_C_SWITCH_X_SITE="$C_SWITCH_X_SITE"
10548 OLD_CPPFLAGS="$CPPFLAGS"
10549 OLD_LIBS="$LIBS"
10550 LD_SWITCH_X_SITE="$LD_SWITCH_X_SITE -b i486-linuxaout"
10551 C_SWITCH_X_SITE="$C_SWITCH_X_SITE -b i486-linuxaout"
10552 CPPFLAGS="$CPPFLAGS -b i486-linuxaout"
10553 LIBS="$LIBS -b i486-linuxaout"
10554 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10555 /* end confdefs.h. */
10556
10557 int
10558 main ()
10559 {
10560 XOpenDisplay ("foo");
10561 ;
10562 return 0;
10563 }
10564 _ACEOF
10565 if ac_fn_c_try_link "$LINENO"; then :
10566 xgnu_linux_second_failure=no
10567 else
10568 xgnu_linux_second_failure=yes
10569 fi
10570 rm -f core conftest.err conftest.$ac_objext \
10571 conftest$ac_exeext conftest.$ac_ext
10572 if test "${xgnu_linux_second_failure}" = "yes"; then
10573 # If we get the same failure with -b, there is no use adding -b.
10574 # So take it out. This plays safe.
10575 LD_SWITCH_X_SITE="$OLD_LD_SWITCH_X_SITE"
10576 C_SWITCH_X_SITE="$OLD_C_SWITCH_X_SITE"
10577 CPPFLAGS="$OLD_CPPFLAGS"
10578 LIBS="$OLD_LIBS"
10579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10580 $as_echo "no" >&6; }
10581 else
10582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10583 $as_echo "yes" >&6; }
10584 fi
10585 else
10586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10587 $as_echo "no" >&6; }
10588 fi
10589 fi
10590
10591 # Reportedly, some broken Solaris systems have XKBlib.h but are missing
10592 # header files included from there.
10593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Xkb" >&5
10594 $as_echo_n "checking for Xkb... " >&6; }
10595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10596 /* end confdefs.h. */
10597 #include <X11/Xlib.h>
10598 #include <X11/XKBlib.h>
10599 int
10600 main ()
10601 {
10602 XkbDescPtr kb = XkbGetKeyboard (0, XkbAllComponentsMask, XkbUseCoreKbd);
10603 ;
10604 return 0;
10605 }
10606 _ACEOF
10607 if ac_fn_c_try_link "$LINENO"; then :
10608 emacs_xkb=yes
10609 else
10610 emacs_xkb=no
10611 fi
10612 rm -f core conftest.err conftest.$ac_objext \
10613 conftest$ac_exeext conftest.$ac_ext
10614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_xkb" >&5
10615 $as_echo "$emacs_xkb" >&6; }
10616 if test $emacs_xkb = yes; then
10617
10618 $as_echo "#define HAVE_XKBGETKEYBOARD 1" >>confdefs.h
10619
10620 fi
10621
10622 for ac_func in XrmSetDatabase XScreenResourceString \
10623 XScreenNumberOfScreen XSetWMProtocols
10624 do :
10625 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10626 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10627 eval as_val=\$$as_ac_var
10628 if test "x$as_val" = x""yes; then :
10629 cat >>confdefs.h <<_ACEOF
10630 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10631 _ACEOF
10632
10633 fi
10634 done
10635
10636 fi
10637
10638 if test "${window_system}" = "x11"; then
10639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 version 6" >&5
10640 $as_echo_n "checking X11 version 6... " >&6; }
10641 if test "${emacs_cv_x11_version_6+set}" = set; then :
10642 $as_echo_n "(cached) " >&6
10643 else
10644 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10645 /* end confdefs.h. */
10646 #include <X11/Xlib.h>
10647 int
10648 main ()
10649 {
10650 #if XlibSpecificationRelease < 6
10651 fail;
10652 #endif
10653
10654 ;
10655 return 0;
10656 }
10657 _ACEOF
10658 if ac_fn_c_try_link "$LINENO"; then :
10659 emacs_cv_x11_version_6=yes
10660 else
10661 emacs_cv_x11_version_6=no
10662 fi
10663 rm -f core conftest.err conftest.$ac_objext \
10664 conftest$ac_exeext conftest.$ac_ext
10665 fi
10666
10667 if test $emacs_cv_x11_version_6 = yes; then
10668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
10669 $as_echo "6 or newer" >&6; }
10670
10671 $as_echo "#define HAVE_X11R6 1" >>confdefs.h
10672
10673
10674 $as_echo "#define HAVE_X_I18N 1" >>confdefs.h
10675
10676 ## inoue@ainet.or.jp says Solaris has a bug related to X11R6-style
10677 ## XIM support.
10678 case "$opsys" in
10679 sol2-*) : ;;
10680 *)
10681 $as_echo "#define HAVE_X11R6_XIM 1" >>confdefs.h
10682
10683 ;;
10684 esac
10685 else
10686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
10687 $as_echo "before 6" >&6; }
10688 fi
10689 fi
10690
10691
10692 ### Use -lrsvg-2 if available, unless `--with-rsvg=no' is specified.
10693 HAVE_RSVG=no
10694 if test "${HAVE_X11}" = "yes" || test "${HAVE_NS}" = "yes"; then
10695 if test "${with_rsvg}" != "no"; then
10696 RSVG_REQUIRED=2.11.0
10697 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED"
10698
10699
10700 succeeded=no
10701
10702 # Extract the first word of "pkg-config", so it can be a program name with args.
10703 set dummy pkg-config; ac_word=$2
10704 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10705 $as_echo_n "checking for $ac_word... " >&6; }
10706 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10707 $as_echo_n "(cached) " >&6
10708 else
10709 case $PKG_CONFIG in
10710 [\\/]* | ?:[\\/]*)
10711 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10712 ;;
10713 *)
10714 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10715 for as_dir in $PATH
10716 do
10717 IFS=$as_save_IFS
10718 test -z "$as_dir" && as_dir=.
10719 for ac_exec_ext in '' $ac_executable_extensions; do
10720 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10721 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10722 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10723 break 2
10724 fi
10725 done
10726 done
10727 IFS=$as_save_IFS
10728
10729 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10730 ;;
10731 esac
10732 fi
10733 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10734 if test -n "$PKG_CONFIG"; then
10735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10736 $as_echo "$PKG_CONFIG" >&6; }
10737 else
10738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10739 $as_echo "no" >&6; }
10740 fi
10741
10742
10743
10744 if test "$PKG_CONFIG" = "no" ; then
10745 :
10746 else
10747 PKG_CONFIG_MIN_VERSION=0.9.0
10748 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10749 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $RSVG_MODULE" >&5
10750 $as_echo_n "checking for $RSVG_MODULE... " >&6; }
10751
10752 if $PKG_CONFIG --exists "$RSVG_MODULE" 2>&5 &&
10753 RSVG_CFLAGS=`$PKG_CONFIG --cflags "$RSVG_MODULE" 2>&5` &&
10754 RSVG_LIBS=`$PKG_CONFIG --libs "$RSVG_MODULE" 2>&5`; then
10755
10756 RSVG_CFLAGS=`$as_echo "$RSVG_CFLAGS" | sed -e 's,///*,/,g'`
10757 RSVG_LIBS=`$as_echo "$RSVG_LIBS" | sed -e 's,///*,/,g'`
10758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&5
10759 $as_echo "yes CFLAGS='$RSVG_CFLAGS' LIBS='$RSVG_LIBS'" >&6; }
10760 succeeded=yes
10761 else
10762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10763 $as_echo "no" >&6; }
10764 RSVG_CFLAGS=""
10765 RSVG_LIBS=""
10766 ## If we have a custom action on failure, don't print errors, but
10767 ## do set a variable so people can do so.
10768 RSVG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$RSVG_MODULE"`
10769
10770 fi
10771
10772
10773
10774 else
10775 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10776 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10777 fi
10778 fi
10779
10780 if test $succeeded = yes; then
10781 HAVE_RSVG=yes
10782 else
10783 :
10784 fi
10785
10786
10787
10788
10789 if test $HAVE_RSVG = yes; then
10790
10791 $as_echo "#define HAVE_RSVG 1" >>confdefs.h
10792
10793 CFLAGS="$CFLAGS $RSVG_CFLAGS"
10794 LIBS="$RSVG_LIBS $LIBS"
10795 fi
10796 fi
10797 fi
10798
10799 HAVE_IMAGEMAGICK=no
10800 if test "${HAVE_X11}" = "yes"; then
10801 if test "${with_imagemagick}" != "no"; then
10802 ## 6.2.8 is the earliest version known to work, but earlier versions
10803 ## might work - let us know if you find one.
10804 ## 6.0.7 does not work. See bug#7955.
10805 IMAGEMAGICK_MODULE="Wand >= 6.2.8"
10806
10807 succeeded=no
10808
10809 # Extract the first word of "pkg-config", so it can be a program name with args.
10810 set dummy pkg-config; ac_word=$2
10811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10812 $as_echo_n "checking for $ac_word... " >&6; }
10813 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10814 $as_echo_n "(cached) " >&6
10815 else
10816 case $PKG_CONFIG in
10817 [\\/]* | ?:[\\/]*)
10818 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10819 ;;
10820 *)
10821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10822 for as_dir in $PATH
10823 do
10824 IFS=$as_save_IFS
10825 test -z "$as_dir" && as_dir=.
10826 for ac_exec_ext in '' $ac_executable_extensions; do
10827 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10828 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10830 break 2
10831 fi
10832 done
10833 done
10834 IFS=$as_save_IFS
10835
10836 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10837 ;;
10838 esac
10839 fi
10840 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10841 if test -n "$PKG_CONFIG"; then
10842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10843 $as_echo "$PKG_CONFIG" >&6; }
10844 else
10845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10846 $as_echo "no" >&6; }
10847 fi
10848
10849
10850
10851 if test "$PKG_CONFIG" = "no" ; then
10852 :
10853 else
10854 PKG_CONFIG_MIN_VERSION=0.9.0
10855 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $IMAGEMAGICK_MODULE" >&5
10857 $as_echo_n "checking for $IMAGEMAGICK_MODULE... " >&6; }
10858
10859 if $PKG_CONFIG --exists "$IMAGEMAGICK_MODULE" 2>&5 &&
10860 IMAGEMAGICK_CFLAGS=`$PKG_CONFIG --cflags "$IMAGEMAGICK_MODULE" 2>&5` &&
10861 IMAGEMAGICK_LIBS=`$PKG_CONFIG --libs "$IMAGEMAGICK_MODULE" 2>&5`; then
10862
10863 IMAGEMAGICK_CFLAGS=`$as_echo "$IMAGEMAGICK_CFLAGS" | sed -e 's,///*,/,g'`
10864 IMAGEMAGICK_LIBS=`$as_echo "$IMAGEMAGICK_LIBS" | sed -e 's,///*,/,g'`
10865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&5
10866 $as_echo "yes CFLAGS='$IMAGEMAGICK_CFLAGS' LIBS='$IMAGEMAGICK_LIBS'" >&6; }
10867 succeeded=yes
10868 else
10869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10870 $as_echo "no" >&6; }
10871 IMAGEMAGICK_CFLAGS=""
10872 IMAGEMAGICK_LIBS=""
10873 ## If we have a custom action on failure, don't print errors, but
10874 ## do set a variable so people can do so.
10875 IMAGEMAGICK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$IMAGEMAGICK_MODULE"`
10876
10877 fi
10878
10879
10880
10881 else
10882 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
10883 echo "*** See http://www.freedesktop.org/software/pkgconfig"
10884 fi
10885 fi
10886
10887 if test $succeeded = yes; then
10888 HAVE_IMAGEMAGICK=yes
10889 else
10890 :
10891 fi
10892
10893
10894
10895
10896 if test $HAVE_IMAGEMAGICK = yes; then
10897
10898 $as_echo "#define HAVE_IMAGEMAGICK 1" >>confdefs.h
10899
10900 CFLAGS="$CFLAGS $IMAGEMAGICK_CFLAGS"
10901 LIBS="$IMAGEMAGICK_LIBS $LIBS"
10902 for ac_func in MagickExportImagePixels
10903 do :
10904 ac_fn_c_check_func "$LINENO" "MagickExportImagePixels" "ac_cv_func_MagickExportImagePixels"
10905 if test "x$ac_cv_func_MagickExportImagePixels" = x""yes; then :
10906 cat >>confdefs.h <<_ACEOF
10907 #define HAVE_MAGICKEXPORTIMAGEPIXELS 1
10908 _ACEOF
10909
10910 fi
10911 done
10912
10913 fi
10914 fi
10915 fi
10916
10917
10918 HAVE_GTK=no
10919 GTK_OBJ=
10920 if test "${with_gtk3}" = "yes"; then
10921 GLIB_REQUIRED=2.28
10922 GTK_REQUIRED=3.0
10923 GTK_MODULES="gtk+-3.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
10924
10925
10926 succeeded=no
10927
10928 # Extract the first word of "pkg-config", so it can be a program name with args.
10929 set dummy pkg-config; ac_word=$2
10930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10931 $as_echo_n "checking for $ac_word... " >&6; }
10932 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
10933 $as_echo_n "(cached) " >&6
10934 else
10935 case $PKG_CONFIG in
10936 [\\/]* | ?:[\\/]*)
10937 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10938 ;;
10939 *)
10940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10941 for as_dir in $PATH
10942 do
10943 IFS=$as_save_IFS
10944 test -z "$as_dir" && as_dir=.
10945 for ac_exec_ext in '' $ac_executable_extensions; do
10946 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
10947 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
10948 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
10949 break 2
10950 fi
10951 done
10952 done
10953 IFS=$as_save_IFS
10954
10955 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
10956 ;;
10957 esac
10958 fi
10959 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10960 if test -n "$PKG_CONFIG"; then
10961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10962 $as_echo "$PKG_CONFIG" >&6; }
10963 else
10964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10965 $as_echo "no" >&6; }
10966 fi
10967
10968
10969
10970 if test "$PKG_CONFIG" = "no" ; then
10971 pkg_check_gtk=no
10972 else
10973 PKG_CONFIG_MIN_VERSION=0.9.0
10974 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
10975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
10976 $as_echo_n "checking for $GTK_MODULES... " >&6; }
10977
10978 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
10979 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
10980 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
10981
10982 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e 's,///*,/,g'`
10983 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
10984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
10985 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
10986 succeeded=yes
10987 else
10988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10989 $as_echo "no" >&6; }
10990 GTK_CFLAGS=""
10991 GTK_LIBS=""
10992 ## If we have a custom action on failure, don't print errors, but
10993 ## do set a variable so people can do so.
10994 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
10995
10996 fi
10997
10998
10999
11000 else
11001 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11002 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11003 fi
11004 fi
11005
11006 if test $succeeded = yes; then
11007 pkg_check_gtk=yes
11008 else
11009 pkg_check_gtk=no
11010 fi
11011
11012 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
11013 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11014 fi
11015
11016 $as_echo "#define HAVE_GTK3 1" >>confdefs.h
11017
11018 GTK_OBJ=emacsgtkfixed.o
11019 fi
11020
11021 if test "$pkg_check_gtk" != "yes"; then
11022 HAVE_GTK=no
11023 if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "maybe"; then
11024 GLIB_REQUIRED=2.10
11025 GTK_REQUIRED=2.10
11026 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED"
11027
11028
11029 succeeded=no
11030
11031 # Extract the first word of "pkg-config", so it can be a program name with args.
11032 set dummy pkg-config; ac_word=$2
11033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11034 $as_echo_n "checking for $ac_word... " >&6; }
11035 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11036 $as_echo_n "(cached) " >&6
11037 else
11038 case $PKG_CONFIG in
11039 [\\/]* | ?:[\\/]*)
11040 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11041 ;;
11042 *)
11043 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11044 for as_dir in $PATH
11045 do
11046 IFS=$as_save_IFS
11047 test -z "$as_dir" && as_dir=.
11048 for ac_exec_ext in '' $ac_executable_extensions; do
11049 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11050 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11051 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11052 break 2
11053 fi
11054 done
11055 done
11056 IFS=$as_save_IFS
11057
11058 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11059 ;;
11060 esac
11061 fi
11062 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11063 if test -n "$PKG_CONFIG"; then
11064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11065 $as_echo "$PKG_CONFIG" >&6; }
11066 else
11067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11068 $as_echo "no" >&6; }
11069 fi
11070
11071
11072
11073 if test "$PKG_CONFIG" = "no" ; then
11074 pkg_check_gtk=no
11075 else
11076 PKG_CONFIG_MIN_VERSION=0.9.0
11077 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $GTK_MODULES" >&5
11079 $as_echo_n "checking for $GTK_MODULES... " >&6; }
11080
11081 if $PKG_CONFIG --exists "$GTK_MODULES" 2>&5 &&
11082 GTK_CFLAGS=`$PKG_CONFIG --cflags "$GTK_MODULES" 2>&5` &&
11083 GTK_LIBS=`$PKG_CONFIG --libs "$GTK_MODULES" 2>&5`; then
11084
11085 GTK_CFLAGS=`$as_echo "$GTK_CFLAGS" | sed -e 's,///*,/,g'`
11086 GTK_LIBS=`$as_echo "$GTK_LIBS" | sed -e 's,///*,/,g'`
11087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&5
11088 $as_echo "yes CFLAGS='$GTK_CFLAGS' LIBS='$GTK_LIBS'" >&6; }
11089 succeeded=yes
11090 else
11091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11092 $as_echo "no" >&6; }
11093 GTK_CFLAGS=""
11094 GTK_LIBS=""
11095 ## If we have a custom action on failure, don't print errors, but
11096 ## do set a variable so people can do so.
11097 GTK_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "$GTK_MODULES"`
11098
11099 fi
11100
11101
11102
11103 else
11104 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11105 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11106 fi
11107 fi
11108
11109 if test $succeeded = yes; then
11110 pkg_check_gtk=yes
11111 else
11112 pkg_check_gtk=no
11113 fi
11114
11115 if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then
11116 as_fn_error "$GTK_PKG_ERRORS" "$LINENO" 5
11117 fi
11118 fi
11119 fi
11120
11121 if test x"$pkg_check_gtk" = xyes; then
11122
11123
11124
11125 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $GTK_CFLAGS"
11126 CFLAGS="$CFLAGS $GTK_CFLAGS"
11127 LIBS="$GTK_LIBS $LIBS"
11128 GTK_COMPILES=no
11129 for ac_func in gtk_main
11130 do :
11131 ac_fn_c_check_func "$LINENO" "gtk_main" "ac_cv_func_gtk_main"
11132 if test "x$ac_cv_func_gtk_main" = x""yes; then :
11133 cat >>confdefs.h <<_ACEOF
11134 #define HAVE_GTK_MAIN 1
11135 _ACEOF
11136 GTK_COMPILES=yes
11137 fi
11138 done
11139
11140 if test "${GTK_COMPILES}" != "yes"; then
11141 if test "$USE_X_TOOLKIT" != "maybe"; then
11142 as_fn_error "Gtk+ wanted, but it does not compile, see config.log. Maybe some x11-devel files missing?" "$LINENO" 5;
11143 fi
11144 else
11145 HAVE_GTK=yes
11146
11147 $as_echo "#define USE_GTK 1" >>confdefs.h
11148
11149 GTK_OBJ="gtkutil.o $GTK_OBJ"
11150 USE_X_TOOLKIT=none
11151 if $PKG_CONFIG --atleast-version=2.10 gtk+-2.0; then
11152 :
11153 else
11154 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your version of Gtk+ will have problems with
11155 closing open displays. This is no problem if you just use
11156 one display, but if you use more than one and close one of them
11157 Emacs may crash." >&5
11158 $as_echo "$as_me: WARNING: Your version of Gtk+ will have problems with
11159 closing open displays. This is no problem if you just use
11160 one display, but if you use more than one and close one of them
11161 Emacs may crash." >&2;}
11162 sleep 3
11163 fi
11164 fi
11165
11166 fi
11167
11168
11169
11170 if test "${HAVE_GTK}" = "yes"; then
11171
11172 if test "$with_toolkit_scroll_bars" != no; then
11173 with_toolkit_scroll_bars=yes
11174 fi
11175
11176 HAVE_GTK_FILE_SELECTION=no
11177 ac_fn_c_check_decl "$LINENO" "GTK_TYPE_FILE_SELECTION" "ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" "$ac_includes_default
11178 #include <gtk/gtk.h>
11179 "
11180 if test "x$ac_cv_have_decl_GTK_TYPE_FILE_SELECTION" = x""yes; then :
11181 HAVE_GTK_FILE_SELECTION=yes
11182 else
11183 HAVE_GTK_FILE_SELECTION=no
11184 fi
11185
11186 if test "$HAVE_GTK_FILE_SELECTION" = yes; then
11187 for ac_func in gtk_file_selection_new
11188 do :
11189 ac_fn_c_check_func "$LINENO" "gtk_file_selection_new" "ac_cv_func_gtk_file_selection_new"
11190 if test "x$ac_cv_func_gtk_file_selection_new" = x""yes; then :
11191 cat >>confdefs.h <<_ACEOF
11192 #define HAVE_GTK_FILE_SELECTION_NEW 1
11193 _ACEOF
11194
11195 fi
11196 done
11197
11198 fi
11199
11200
11201 for ac_func in gtk_widget_get_window gtk_widget_set_has_window \
11202 gtk_dialog_get_action_area gtk_widget_get_sensitive \
11203 gtk_widget_get_mapped gtk_adjustment_get_page_size \
11204 gtk_orientable_set_orientation \
11205 gtk_window_set_has_resize_grip
11206 do :
11207 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
11208 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
11209 eval as_val=\$$as_ac_var
11210 if test "x$as_val" = x""yes; then :
11211 cat >>confdefs.h <<_ACEOF
11212 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
11213 _ACEOF
11214
11215 fi
11216 done
11217
11218 fi
11219
11220 HAVE_DBUS=no
11221 DBUS_OBJ=
11222 if test "${with_dbus}" = "yes"; then
11223
11224 succeeded=no
11225
11226 # Extract the first word of "pkg-config", so it can be a program name with args.
11227 set dummy pkg-config; ac_word=$2
11228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11229 $as_echo_n "checking for $ac_word... " >&6; }
11230 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11231 $as_echo_n "(cached) " >&6
11232 else
11233 case $PKG_CONFIG in
11234 [\\/]* | ?:[\\/]*)
11235 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11236 ;;
11237 *)
11238 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11239 for as_dir in $PATH
11240 do
11241 IFS=$as_save_IFS
11242 test -z "$as_dir" && as_dir=.
11243 for ac_exec_ext in '' $ac_executable_extensions; do
11244 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11245 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11246 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11247 break 2
11248 fi
11249 done
11250 done
11251 IFS=$as_save_IFS
11252
11253 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11254 ;;
11255 esac
11256 fi
11257 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11258 if test -n "$PKG_CONFIG"; then
11259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11260 $as_echo "$PKG_CONFIG" >&6; }
11261 else
11262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11263 $as_echo "no" >&6; }
11264 fi
11265
11266
11267
11268 if test "$PKG_CONFIG" = "no" ; then
11269 HAVE_DBUS=no
11270 else
11271 PKG_CONFIG_MIN_VERSION=0.9.0
11272 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dbus-1 >= 1.0" >&5
11274 $as_echo_n "checking for dbus-1 >= 1.0... " >&6; }
11275
11276 if $PKG_CONFIG --exists "dbus-1 >= 1.0" 2>&5 &&
11277 DBUS_CFLAGS=`$PKG_CONFIG --cflags "dbus-1 >= 1.0" 2>&5` &&
11278 DBUS_LIBS=`$PKG_CONFIG --libs "dbus-1 >= 1.0" 2>&5`; then
11279
11280 DBUS_CFLAGS=`$as_echo "$DBUS_CFLAGS" | sed -e 's,///*,/,g'`
11281 DBUS_LIBS=`$as_echo "$DBUS_LIBS" | sed -e 's,///*,/,g'`
11282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&5
11283 $as_echo "yes CFLAGS='$DBUS_CFLAGS' LIBS='$DBUS_LIBS'" >&6; }
11284 succeeded=yes
11285 else
11286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11287 $as_echo "no" >&6; }
11288 DBUS_CFLAGS=""
11289 DBUS_LIBS=""
11290 ## If we have a custom action on failure, don't print errors, but
11291 ## do set a variable so people can do so.
11292 DBUS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "dbus-1 >= 1.0"`
11293
11294 fi
11295
11296
11297
11298 else
11299 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11300 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11301 fi
11302 fi
11303
11304 if test $succeeded = yes; then
11305 HAVE_DBUS=yes
11306 else
11307 HAVE_DBUS=no
11308 fi
11309
11310 if test "$HAVE_DBUS" = yes; then
11311 LIBS="$LIBS $DBUS_LIBS"
11312
11313 $as_echo "#define HAVE_DBUS 1" >>confdefs.h
11314
11315 for ac_func in dbus_watch_get_unix_fd
11316 do :
11317 ac_fn_c_check_func "$LINENO" "dbus_watch_get_unix_fd" "ac_cv_func_dbus_watch_get_unix_fd"
11318 if test "x$ac_cv_func_dbus_watch_get_unix_fd" = x""yes; then :
11319 cat >>confdefs.h <<_ACEOF
11320 #define HAVE_DBUS_WATCH_GET_UNIX_FD 1
11321 _ACEOF
11322
11323 fi
11324 done
11325
11326 DBUS_OBJ=dbusbind.o
11327 fi
11328 fi
11329
11330
11331 HAVE_GSETTINGS=no
11332 if test "${HAVE_X11}" = "yes" && test "${with_gsettings}" = "yes"; then
11333
11334 succeeded=no
11335
11336 # Extract the first word of "pkg-config", so it can be a program name with args.
11337 set dummy pkg-config; ac_word=$2
11338 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11339 $as_echo_n "checking for $ac_word... " >&6; }
11340 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11341 $as_echo_n "(cached) " >&6
11342 else
11343 case $PKG_CONFIG in
11344 [\\/]* | ?:[\\/]*)
11345 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11346 ;;
11347 *)
11348 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11349 for as_dir in $PATH
11350 do
11351 IFS=$as_save_IFS
11352 test -z "$as_dir" && as_dir=.
11353 for ac_exec_ext in '' $ac_executable_extensions; do
11354 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11355 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11356 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11357 break 2
11358 fi
11359 done
11360 done
11361 IFS=$as_save_IFS
11362
11363 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11364 ;;
11365 esac
11366 fi
11367 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11368 if test -n "$PKG_CONFIG"; then
11369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11370 $as_echo "$PKG_CONFIG" >&6; }
11371 else
11372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11373 $as_echo "no" >&6; }
11374 fi
11375
11376
11377
11378 if test "$PKG_CONFIG" = "no" ; then
11379 HAVE_GSETTINGS=no
11380 else
11381 PKG_CONFIG_MIN_VERSION=0.9.0
11382 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gio-2.0 >= 2.26" >&5
11384 $as_echo_n "checking for gio-2.0 >= 2.26... " >&6; }
11385
11386 if $PKG_CONFIG --exists "gio-2.0 >= 2.26" 2>&5 &&
11387 GSETTINGS_CFLAGS=`$PKG_CONFIG --cflags "gio-2.0 >= 2.26" 2>&5` &&
11388 GSETTINGS_LIBS=`$PKG_CONFIG --libs "gio-2.0 >= 2.26" 2>&5`; then
11389
11390 GSETTINGS_CFLAGS=`$as_echo "$GSETTINGS_CFLAGS" | sed -e 's,///*,/,g'`
11391 GSETTINGS_LIBS=`$as_echo "$GSETTINGS_LIBS" | sed -e 's,///*,/,g'`
11392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&5
11393 $as_echo "yes CFLAGS='$GSETTINGS_CFLAGS' LIBS='$GSETTINGS_LIBS'" >&6; }
11394 succeeded=yes
11395 else
11396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11397 $as_echo "no" >&6; }
11398 GSETTINGS_CFLAGS=""
11399 GSETTINGS_LIBS=""
11400 ## If we have a custom action on failure, don't print errors, but
11401 ## do set a variable so people can do so.
11402 GSETTINGS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gio-2.0 >= 2.26"`
11403
11404 fi
11405
11406
11407
11408 else
11409 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11410 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11411 fi
11412 fi
11413
11414 if test $succeeded = yes; then
11415 HAVE_GSETTINGS=yes
11416 else
11417 HAVE_GSETTINGS=no
11418 fi
11419
11420 if test "$HAVE_GSETTINGS" = "yes"; then
11421
11422 $as_echo "#define HAVE_GSETTINGS 1" >>confdefs.h
11423
11424 SETTINGS_CFLAGS="$GSETTINGS_CFLAGS"
11425 SETTINGS_LIBS="$GSETTINGS_LIBS"
11426 fi
11427 fi
11428
11429 HAVE_GCONF=no
11430 if test "${HAVE_X11}" = "yes" && test "${with_gconf}" = "yes"; then
11431
11432 succeeded=no
11433
11434 # Extract the first word of "pkg-config", so it can be a program name with args.
11435 set dummy pkg-config; ac_word=$2
11436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11437 $as_echo_n "checking for $ac_word... " >&6; }
11438 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11439 $as_echo_n "(cached) " >&6
11440 else
11441 case $PKG_CONFIG in
11442 [\\/]* | ?:[\\/]*)
11443 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11444 ;;
11445 *)
11446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11447 for as_dir in $PATH
11448 do
11449 IFS=$as_save_IFS
11450 test -z "$as_dir" && as_dir=.
11451 for ac_exec_ext in '' $ac_executable_extensions; do
11452 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11453 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11454 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11455 break 2
11456 fi
11457 done
11458 done
11459 IFS=$as_save_IFS
11460
11461 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11462 ;;
11463 esac
11464 fi
11465 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11466 if test -n "$PKG_CONFIG"; then
11467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11468 $as_echo "$PKG_CONFIG" >&6; }
11469 else
11470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11471 $as_echo "no" >&6; }
11472 fi
11473
11474
11475
11476 if test "$PKG_CONFIG" = "no" ; then
11477 HAVE_GCONF=no
11478 else
11479 PKG_CONFIG_MIN_VERSION=0.9.0
11480 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gconf-2.0 >= 2.13" >&5
11482 $as_echo_n "checking for gconf-2.0 >= 2.13... " >&6; }
11483
11484 if $PKG_CONFIG --exists "gconf-2.0 >= 2.13" 2>&5 &&
11485 GCONF_CFLAGS=`$PKG_CONFIG --cflags "gconf-2.0 >= 2.13" 2>&5` &&
11486 GCONF_LIBS=`$PKG_CONFIG --libs "gconf-2.0 >= 2.13" 2>&5`; then
11487
11488 GCONF_CFLAGS=`$as_echo "$GCONF_CFLAGS" | sed -e 's,///*,/,g'`
11489 GCONF_LIBS=`$as_echo "$GCONF_LIBS" | sed -e 's,///*,/,g'`
11490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&5
11491 $as_echo "yes CFLAGS='$GCONF_CFLAGS' LIBS='$GCONF_LIBS'" >&6; }
11492 succeeded=yes
11493 else
11494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11495 $as_echo "no" >&6; }
11496 GCONF_CFLAGS=""
11497 GCONF_LIBS=""
11498 ## If we have a custom action on failure, don't print errors, but
11499 ## do set a variable so people can do so.
11500 GCONF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gconf-2.0 >= 2.13"`
11501
11502 fi
11503
11504
11505
11506 else
11507 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11508 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11509 fi
11510 fi
11511
11512 if test $succeeded = yes; then
11513 HAVE_GCONF=yes
11514 else
11515 HAVE_GCONF=no
11516 fi
11517
11518 if test "$HAVE_GCONF" = yes; then
11519
11520 $as_echo "#define HAVE_GCONF 1" >>confdefs.h
11521
11522 SETTINGS_CFLAGS="$SETTINGS_CFLAGS $GCONF_CFLAGS"
11523 SETTINGS_LIBS="$SETTINGS_LIBS $GCONF_LIBS"
11524 fi
11525 fi
11526
11527 if test "$HAVE_GSETTINGS" = "yes" || test "$HAVE_GCONF" = "yes"; then
11528 SAVE_CFLAGS="$CFLAGS"
11529 SAVE_LIBS="$LIBS"
11530 CFLAGS="$SETTINGS_CFLAGS $CFLAGS"
11531 LIBS="$SETTINGS_LIBS $LIBS"
11532 for ac_func in g_type_init
11533 do :
11534 ac_fn_c_check_func "$LINENO" "g_type_init" "ac_cv_func_g_type_init"
11535 if test "x$ac_cv_func_g_type_init" = x""yes; then :
11536 cat >>confdefs.h <<_ACEOF
11537 #define HAVE_G_TYPE_INIT 1
11538 _ACEOF
11539
11540 fi
11541 done
11542
11543 CFLAGS="$SAVE_CFLAGS"
11544 LIBS="$SAVE_LIBS"
11545 fi
11546
11547
11548
11549
11550 HAVE_LIBSELINUX=no
11551 LIBSELINUX_LIBS=
11552 if test "${with_selinux}" = "yes"; then
11553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lgetfilecon in -lselinux" >&5
11554 $as_echo_n "checking for lgetfilecon in -lselinux... " >&6; }
11555 if test "${ac_cv_lib_selinux_lgetfilecon+set}" = set; then :
11556 $as_echo_n "(cached) " >&6
11557 else
11558 ac_check_lib_save_LIBS=$LIBS
11559 LIBS="-lselinux $LIBS"
11560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11561 /* end confdefs.h. */
11562
11563 /* Override any GCC internal prototype to avoid an error.
11564 Use char because int might match the return type of a GCC
11565 builtin and then its argument prototype would still apply. */
11566 #ifdef __cplusplus
11567 extern "C"
11568 #endif
11569 char lgetfilecon ();
11570 int
11571 main ()
11572 {
11573 return lgetfilecon ();
11574 ;
11575 return 0;
11576 }
11577 _ACEOF
11578 if ac_fn_c_try_link "$LINENO"; then :
11579 ac_cv_lib_selinux_lgetfilecon=yes
11580 else
11581 ac_cv_lib_selinux_lgetfilecon=no
11582 fi
11583 rm -f core conftest.err conftest.$ac_objext \
11584 conftest$ac_exeext conftest.$ac_ext
11585 LIBS=$ac_check_lib_save_LIBS
11586 fi
11587 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_lgetfilecon" >&5
11588 $as_echo "$ac_cv_lib_selinux_lgetfilecon" >&6; }
11589 if test "x$ac_cv_lib_selinux_lgetfilecon" = x""yes; then :
11590 HAVE_LIBSELINUX=yes
11591 else
11592 HAVE_LIBSELINUX=no
11593 fi
11594
11595 if test "$HAVE_LIBSELINUX" = yes; then
11596
11597 $as_echo "#define HAVE_LIBSELINUX 1" >>confdefs.h
11598
11599 LIBSELINUX_LIBS=-lselinux
11600 fi
11601 fi
11602
11603
11604 HAVE_GNUTLS=no
11605 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=no
11606 if test "${with_gnutls}" = "yes" ; then
11607
11608 succeeded=no
11609
11610 # Extract the first word of "pkg-config", so it can be a program name with args.
11611 set dummy pkg-config; ac_word=$2
11612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
11613 $as_echo_n "checking for $ac_word... " >&6; }
11614 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
11615 $as_echo_n "(cached) " >&6
11616 else
11617 case $PKG_CONFIG in
11618 [\\/]* | ?:[\\/]*)
11619 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
11620 ;;
11621 *)
11622 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
11623 for as_dir in $PATH
11624 do
11625 IFS=$as_save_IFS
11626 test -z "$as_dir" && as_dir=.
11627 for ac_exec_ext in '' $ac_executable_extensions; do
11628 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
11629 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
11630 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
11631 break 2
11632 fi
11633 done
11634 done
11635 IFS=$as_save_IFS
11636
11637 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
11638 ;;
11639 esac
11640 fi
11641 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
11642 if test -n "$PKG_CONFIG"; then
11643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
11644 $as_echo "$PKG_CONFIG" >&6; }
11645 else
11646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11647 $as_echo "no" >&6; }
11648 fi
11649
11650
11651
11652 if test "$PKG_CONFIG" = "no" ; then
11653 HAVE_GNUTLS=no
11654 else
11655 PKG_CONFIG_MIN_VERSION=0.9.0
11656 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
11657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gnutls >= 2.6.6" >&5
11658 $as_echo_n "checking for gnutls >= 2.6.6... " >&6; }
11659
11660 if $PKG_CONFIG --exists "gnutls >= 2.6.6" 2>&5 &&
11661 LIBGNUTLS_CFLAGS=`$PKG_CONFIG --cflags "gnutls >= 2.6.6" 2>&5` &&
11662 LIBGNUTLS_LIBS=`$PKG_CONFIG --libs "gnutls >= 2.6.6" 2>&5`; then
11663
11664 LIBGNUTLS_CFLAGS=`$as_echo "$LIBGNUTLS_CFLAGS" | sed -e 's,///*,/,g'`
11665 LIBGNUTLS_LIBS=`$as_echo "$LIBGNUTLS_LIBS" | sed -e 's,///*,/,g'`
11666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&5
11667 $as_echo "yes CFLAGS='$LIBGNUTLS_CFLAGS' LIBS='$LIBGNUTLS_LIBS'" >&6; }
11668 succeeded=yes
11669 else
11670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11671 $as_echo "no" >&6; }
11672 LIBGNUTLS_CFLAGS=""
11673 LIBGNUTLS_LIBS=""
11674 ## If we have a custom action on failure, don't print errors, but
11675 ## do set a variable so people can do so.
11676 LIBGNUTLS_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "gnutls >= 2.6.6"`
11677
11678 fi
11679
11680
11681
11682 else
11683 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
11684 echo "*** See http://www.freedesktop.org/software/pkgconfig"
11685 fi
11686 fi
11687
11688 if test $succeeded = yes; then
11689 HAVE_GNUTLS=yes
11690 else
11691 HAVE_GNUTLS=no
11692 fi
11693
11694 if test "${HAVE_GNUTLS}" = "yes"; then
11695
11696 $as_echo "#define HAVE_GNUTLS 1" >>confdefs.h
11697
11698 fi
11699
11700 CFLAGS="$CFLAGS $LIBGNUTLS_CFLAGS"
11701 LIBS="$LIBGNUTLS_LIBS $LIBS"
11702 for ac_func in gnutls_certificate_set_verify_function
11703 do :
11704 ac_fn_c_check_func "$LINENO" "gnutls_certificate_set_verify_function" "ac_cv_func_gnutls_certificate_set_verify_function"
11705 if test "x$ac_cv_func_gnutls_certificate_set_verify_function" = x""yes; then :
11706 cat >>confdefs.h <<_ACEOF
11707 #define HAVE_GNUTLS_CERTIFICATE_SET_VERIFY_FUNCTION 1
11708 _ACEOF
11709 HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY=yes
11710 fi
11711 done
11712
11713
11714 if test "${HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY}" = "yes"; then
11715
11716 $as_echo "#define HAVE_GNUTLS_CALLBACK_CERTIFICATE_VERIFY 1" >>confdefs.h
11717
11718 fi
11719 fi
11720
11721
11722
11723
11724 HAVE_XAW3D=no
11725 LUCID_LIBW=
11726 if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
11727 if test "$with_xaw3d" != no; then
11728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xaw3d" >&5
11729 $as_echo_n "checking for xaw3d... " >&6; }
11730 if test "${emacs_cv_xaw3d+set}" = set; then :
11731 $as_echo_n "(cached) " >&6
11732 else
11733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11734 /* end confdefs.h. */
11735
11736 #include <X11/Intrinsic.h>
11737 #include <X11/Xaw3d/Simple.h>
11738 int
11739 main ()
11740 {
11741
11742 ;
11743 return 0;
11744 }
11745 _ACEOF
11746 if ac_fn_c_try_link "$LINENO"; then :
11747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XawScrollbarSetThumb in -lXaw3d" >&5
11748 $as_echo_n "checking for XawScrollbarSetThumb in -lXaw3d... " >&6; }
11749 if test "${ac_cv_lib_Xaw3d_XawScrollbarSetThumb+set}" = set; then :
11750 $as_echo_n "(cached) " >&6
11751 else
11752 ac_check_lib_save_LIBS=$LIBS
11753 LIBS="-lXaw3d $LIBS"
11754 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11755 /* end confdefs.h. */
11756
11757 /* Override any GCC internal prototype to avoid an error.
11758 Use char because int might match the return type of a GCC
11759 builtin and then its argument prototype would still apply. */
11760 #ifdef __cplusplus
11761 extern "C"
11762 #endif
11763 char XawScrollbarSetThumb ();
11764 int
11765 main ()
11766 {
11767 return XawScrollbarSetThumb ();
11768 ;
11769 return 0;
11770 }
11771 _ACEOF
11772 if ac_fn_c_try_link "$LINENO"; then :
11773 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=yes
11774 else
11775 ac_cv_lib_Xaw3d_XawScrollbarSetThumb=no
11776 fi
11777 rm -f core conftest.err conftest.$ac_objext \
11778 conftest$ac_exeext conftest.$ac_ext
11779 LIBS=$ac_check_lib_save_LIBS
11780 fi
11781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&5
11782 $as_echo "$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" >&6; }
11783 if test "x$ac_cv_lib_Xaw3d_XawScrollbarSetThumb" = x""yes; then :
11784 emacs_cv_xaw3d=yes
11785 else
11786 emacs_cv_xaw3d=no
11787 fi
11788
11789 else
11790 emacs_cv_xaw3d=no
11791 fi
11792 rm -f core conftest.err conftest.$ac_objext \
11793 conftest$ac_exeext conftest.$ac_ext
11794 fi
11795
11796 else
11797 emacs_cv_xaw3d=no
11798 fi
11799 if test $emacs_cv_xaw3d = yes; then
11800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11801 $as_echo "yes; using Lucid toolkit" >&6; }
11802 USE_X_TOOLKIT=LUCID
11803 HAVE_XAW3D=yes
11804 LUCID_LIBW=-lXaw3d
11805
11806 $as_echo "#define HAVE_XAW3D 1" >>confdefs.h
11807
11808 else
11809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11810 $as_echo "no" >&6; }
11811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libXaw" >&5
11812 $as_echo_n "checking for libXaw... " >&6; }
11813 if test "${emacs_cv_xaw+set}" = set; then :
11814 $as_echo_n "(cached) " >&6
11815 else
11816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11817 /* end confdefs.h. */
11818
11819 #include <X11/Intrinsic.h>
11820 #include <X11/Xaw/Simple.h>
11821 int
11822 main ()
11823 {
11824
11825 ;
11826 return 0;
11827 }
11828 _ACEOF
11829 if ac_fn_c_try_link "$LINENO"; then :
11830 emacs_cv_xaw=yes
11831 else
11832 emacs_cv_xaw=no
11833 fi
11834 rm -f core conftest.err conftest.$ac_objext \
11835 conftest$ac_exeext conftest.$ac_ext
11836 fi
11837
11838 if test $emacs_cv_xaw = yes; then
11839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes; using Lucid toolkit" >&5
11840 $as_echo "yes; using Lucid toolkit" >&6; }
11841 USE_X_TOOLKIT=LUCID
11842 LUCID_LIBW=-lXaw
11843 elif test x"${USE_X_TOOLKIT}" = xLUCID; then
11844 as_fn_error "Lucid toolkit requires X11/Xaw include files" "$LINENO" 5
11845 else
11846 as_fn_error "No X toolkit could be found.
11847 If you are sure you want Emacs compiled without an X toolkit, pass
11848 --with-x-toolkit=no
11849 to configure. Otherwise, install the development libraries for the toolkit
11850 that you want to use (e.g. Gtk+) and re-run configure." "$LINENO" 5
11851 fi
11852 fi
11853 fi
11854
11855 X_TOOLKIT_TYPE=$USE_X_TOOLKIT
11856
11857 LIBXTR6=
11858 if test "${USE_X_TOOLKIT}" != "none"; then
11859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking X11 toolkit version" >&5
11860 $as_echo_n "checking X11 toolkit version... " >&6; }
11861 if test "${emacs_cv_x11_toolkit_version_6+set}" = set; then :
11862 $as_echo_n "(cached) " >&6
11863 else
11864 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11865 /* end confdefs.h. */
11866 #include <X11/Intrinsic.h>
11867 int
11868 main ()
11869 {
11870 #if XtSpecificationRelease < 6
11871 fail;
11872 #endif
11873
11874 ;
11875 return 0;
11876 }
11877 _ACEOF
11878 if ac_fn_c_try_link "$LINENO"; then :
11879 emacs_cv_x11_toolkit_version_6=yes
11880 else
11881 emacs_cv_x11_toolkit_version_6=no
11882 fi
11883 rm -f core conftest.err conftest.$ac_objext \
11884 conftest$ac_exeext conftest.$ac_ext
11885 fi
11886
11887 HAVE_X11XTR6=$emacs_cv_x11_toolkit_version_6
11888 if test $emacs_cv_x11_toolkit_version_6 = yes; then
11889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: 6 or newer" >&5
11890 $as_echo "6 or newer" >&6; }
11891
11892 $as_echo "#define HAVE_X11XTR6 1" >>confdefs.h
11893
11894 LIBXTR6="-lSM -lICE"
11895 case "$opsys" in
11896 ## Use libw.a along with X11R6 Xt.
11897 unixware) LIBXTR6="$LIBXTR6 -lw" ;;
11898 esac
11899 else
11900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: before 6" >&5
11901 $as_echo "before 6" >&6; }
11902 fi
11903
11904 OLDLIBS="$LIBS"
11905 if test x$HAVE_X11XTR6 = xyes; then
11906 LIBS="-lXt -lSM -lICE $LIBS"
11907 else
11908 LIBS="-lXt $LIBS"
11909 fi
11910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XmuConvertStandardSelection in -lXmu" >&5
11911 $as_echo_n "checking for XmuConvertStandardSelection in -lXmu... " >&6; }
11912 if test "${ac_cv_lib_Xmu_XmuConvertStandardSelection+set}" = set; then :
11913 $as_echo_n "(cached) " >&6
11914 else
11915 ac_check_lib_save_LIBS=$LIBS
11916 LIBS="-lXmu $LIBS"
11917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11918 /* end confdefs.h. */
11919
11920 /* Override any GCC internal prototype to avoid an error.
11921 Use char because int might match the return type of a GCC
11922 builtin and then its argument prototype would still apply. */
11923 #ifdef __cplusplus
11924 extern "C"
11925 #endif
11926 char XmuConvertStandardSelection ();
11927 int
11928 main ()
11929 {
11930 return XmuConvertStandardSelection ();
11931 ;
11932 return 0;
11933 }
11934 _ACEOF
11935 if ac_fn_c_try_link "$LINENO"; then :
11936 ac_cv_lib_Xmu_XmuConvertStandardSelection=yes
11937 else
11938 ac_cv_lib_Xmu_XmuConvertStandardSelection=no
11939 fi
11940 rm -f core conftest.err conftest.$ac_objext \
11941 conftest$ac_exeext conftest.$ac_ext
11942 LIBS=$ac_check_lib_save_LIBS
11943 fi
11944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xmu_XmuConvertStandardSelection" >&5
11945 $as_echo "$ac_cv_lib_Xmu_XmuConvertStandardSelection" >&6; }
11946 if test "x$ac_cv_lib_Xmu_XmuConvertStandardSelection" = x""yes; then :
11947 cat >>confdefs.h <<_ACEOF
11948 #define HAVE_LIBXMU 1
11949 _ACEOF
11950
11951 LIBS="-lXmu $LIBS"
11952
11953 fi
11954
11955 test $ac_cv_lib_Xmu_XmuConvertStandardSelection = no && LIBS="$OLDLIBS"
11956 fi
11957
11958
11959 LIBXMU=-lXmu
11960 case $opsys in
11961 ## These systems don't supply Xmu.
11962 hpux* | aix4-2 )
11963 test "X$ac_cv_lib_Xmu_XmuConvertStandardSelection" != "Xyes" && LIBXMU=
11964 ;;
11965 esac
11966
11967
11968 # On Irix 6.5, at least, we need XShapeQueryExtension from -lXext for Xaw3D.
11969 if test "${HAVE_X11}" = "yes"; then
11970 if test "${USE_X_TOOLKIT}" != "none"; then
11971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XShapeQueryExtension in -lXext" >&5
11972 $as_echo_n "checking for XShapeQueryExtension in -lXext... " >&6; }
11973 if test "${ac_cv_lib_Xext_XShapeQueryExtension+set}" = set; then :
11974 $as_echo_n "(cached) " >&6
11975 else
11976 ac_check_lib_save_LIBS=$LIBS
11977 LIBS="-lXext $LIBS"
11978 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11979 /* end confdefs.h. */
11980
11981 /* Override any GCC internal prototype to avoid an error.
11982 Use char because int might match the return type of a GCC
11983 builtin and then its argument prototype would still apply. */
11984 #ifdef __cplusplus
11985 extern "C"
11986 #endif
11987 char XShapeQueryExtension ();
11988 int
11989 main ()
11990 {
11991 return XShapeQueryExtension ();
11992 ;
11993 return 0;
11994 }
11995 _ACEOF
11996 if ac_fn_c_try_link "$LINENO"; then :
11997 ac_cv_lib_Xext_XShapeQueryExtension=yes
11998 else
11999 ac_cv_lib_Xext_XShapeQueryExtension=no
12000 fi
12001 rm -f core conftest.err conftest.$ac_objext \
12002 conftest$ac_exeext conftest.$ac_ext
12003 LIBS=$ac_check_lib_save_LIBS
12004 fi
12005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xext_XShapeQueryExtension" >&5
12006 $as_echo "$ac_cv_lib_Xext_XShapeQueryExtension" >&6; }
12007 if test "x$ac_cv_lib_Xext_XShapeQueryExtension" = x""yes; then :
12008 cat >>confdefs.h <<_ACEOF
12009 #define HAVE_LIBXEXT 1
12010 _ACEOF
12011
12012 LIBS="-lXext $LIBS"
12013
12014 fi
12015
12016 fi
12017 fi
12018
12019 LIBXP=
12020 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Motif version 2.1" >&5
12022 $as_echo_n "checking for Motif version 2.1... " >&6; }
12023 if test "${emacs_cv_motif_version_2_1+set}" = set; then :
12024 $as_echo_n "(cached) " >&6
12025 else
12026 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12027 /* end confdefs.h. */
12028 #include <Xm/Xm.h>
12029 int
12030 main ()
12031 {
12032 #if XmVERSION > 2 || (XmVERSION == 2 && XmREVISION >= 1)
12033 int x = 5;
12034 #else
12035 Motif version prior to 2.1.
12036 #endif
12037 ;
12038 return 0;
12039 }
12040 _ACEOF
12041 if ac_fn_c_try_compile "$LINENO"; then :
12042 emacs_cv_motif_version_2_1=yes
12043 else
12044 emacs_cv_motif_version_2_1=no
12045 fi
12046 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12047 fi
12048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_motif_version_2_1" >&5
12049 $as_echo "$emacs_cv_motif_version_2_1" >&6; }
12050 if test $emacs_cv_motif_version_2_1 = yes; then
12051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpCreateContext in -lXp" >&5
12052 $as_echo_n "checking for XpCreateContext in -lXp... " >&6; }
12053 if test "${ac_cv_lib_Xp_XpCreateContext+set}" = set; then :
12054 $as_echo_n "(cached) " >&6
12055 else
12056 ac_check_lib_save_LIBS=$LIBS
12057 LIBS="-lXp $LIBS"
12058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12059 /* end confdefs.h. */
12060
12061 /* Override any GCC internal prototype to avoid an error.
12062 Use char because int might match the return type of a GCC
12063 builtin and then its argument prototype would still apply. */
12064 #ifdef __cplusplus
12065 extern "C"
12066 #endif
12067 char XpCreateContext ();
12068 int
12069 main ()
12070 {
12071 return XpCreateContext ();
12072 ;
12073 return 0;
12074 }
12075 _ACEOF
12076 if ac_fn_c_try_link "$LINENO"; then :
12077 ac_cv_lib_Xp_XpCreateContext=yes
12078 else
12079 ac_cv_lib_Xp_XpCreateContext=no
12080 fi
12081 rm -f core conftest.err conftest.$ac_objext \
12082 conftest$ac_exeext conftest.$ac_ext
12083 LIBS=$ac_check_lib_save_LIBS
12084 fi
12085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xp_XpCreateContext" >&5
12086 $as_echo "$ac_cv_lib_Xp_XpCreateContext" >&6; }
12087 if test "x$ac_cv_lib_Xp_XpCreateContext" = x""yes; then :
12088 LIBXP=-lXp
12089 fi
12090
12091 else
12092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LessTif where some systems put it" >&5
12093 $as_echo_n "checking for LessTif where some systems put it... " >&6; }
12094 if test "${emacs_cv_lesstif+set}" = set; then :
12095 $as_echo_n "(cached) " >&6
12096 else
12097 # We put this in CFLAGS temporarily to precede other -I options
12098 # that might be in CFLAGS temporarily.
12099 # We put this in CPPFLAGS where it precedes the other -I options.
12100 OLD_CPPFLAGS=$CPPFLAGS
12101 OLD_CFLAGS=$CFLAGS
12102 CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CPPFLAGS"
12103 CFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $CFLAGS"
12104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12105 /* end confdefs.h. */
12106 #include </usr/X11R6/LessTif/Motif1.2/include/Xm/Xm.h>
12107 int
12108 main ()
12109 {
12110 int x = 5;
12111 ;
12112 return 0;
12113 }
12114 _ACEOF
12115 if ac_fn_c_try_compile "$LINENO"; then :
12116 emacs_cv_lesstif=yes
12117 else
12118 emacs_cv_lesstif=no
12119 fi
12120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12121 fi
12122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_lesstif" >&5
12123 $as_echo "$emacs_cv_lesstif" >&6; }
12124 if test $emacs_cv_lesstif = yes; then
12125 # Make sure this -I option remains in CPPFLAGS after it is set
12126 # back to REAL_CPPFLAGS.
12127 # There is no need to change REAL_CFLAGS, because REAL_CFLAGS does not
12128 # have those other -I options anyway. Ultimately, having this
12129 # directory ultimately in CPPFLAGS will be enough.
12130 REAL_CPPFLAGS="-I/usr/X11R6/LessTif/Motif1.2/include $REAL_CPPFLAGS"
12131 LDFLAGS="-L/usr/X11R6/LessTif/Motif1.2/lib $LDFLAGS"
12132 else
12133 CFLAGS=$OLD_CFLAGS
12134 CPPFLAGS=$OLD_CPPFLAGS
12135 fi
12136 fi
12137 ac_fn_c_check_header_mongrel "$LINENO" "Xm/BulletinB.h" "ac_cv_header_Xm_BulletinB_h" "$ac_includes_default"
12138 if test "x$ac_cv_header_Xm_BulletinB_h" = x""yes; then :
12139
12140 else
12141 as_fn_error "Motif toolkit requested but requirements not found." "$LINENO" 5
12142 fi
12143
12144
12145 fi
12146
12147
12148 USE_TOOLKIT_SCROLL_BARS=no
12149 if test "${with_toolkit_scroll_bars}" != "no"; then
12150 if test "${USE_X_TOOLKIT}" != "none"; then
12151 if test "${USE_X_TOOLKIT}" = "MOTIF"; then
12152 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12153
12154 HAVE_XAW3D=no
12155 USE_TOOLKIT_SCROLL_BARS=yes
12156 elif test "${HAVE_XAW3D}" = "yes" || test "${USE_X_TOOLKIT}" = "LUCID"; then
12157 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12158
12159 USE_TOOLKIT_SCROLL_BARS=yes
12160 fi
12161 elif test "${HAVE_GTK}" = "yes"; then
12162 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12163
12164 USE_TOOLKIT_SCROLL_BARS=yes
12165 elif test "${HAVE_NS}" = "yes"; then
12166 $as_echo "#define USE_TOOLKIT_SCROLL_BARS 1" >>confdefs.h
12167
12168 USE_TOOLKIT_SCROLL_BARS=yes
12169 fi
12170 fi
12171
12172 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12173 /* end confdefs.h. */
12174
12175 #include <X11/Xlib.h>
12176 #include <X11/Xresource.h>
12177 int
12178 main ()
12179 {
12180 XIMProc callback;
12181 ;
12182 return 0;
12183 }
12184 _ACEOF
12185 if ac_fn_c_try_compile "$LINENO"; then :
12186 HAVE_XIM=yes
12187
12188 $as_echo "#define HAVE_XIM 1" >>confdefs.h
12189
12190 else
12191 HAVE_XIM=no
12192 fi
12193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12194
12195
12196 if test "${with_xim}" != "no"; then
12197
12198 $as_echo "#define USE_XIM 1" >>confdefs.h
12199
12200 fi
12201
12202
12203 if test "${HAVE_XIM}" != "no"; then
12204 late_CFLAGS=$CFLAGS
12205 if test "$GCC" = yes; then
12206 CFLAGS="$CFLAGS --pedantic-errors"
12207 fi
12208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12209 /* end confdefs.h. */
12210
12211 #include <X11/Xlib.h>
12212 #include <X11/Xresource.h>
12213 int
12214 main ()
12215 {
12216 Display *display;
12217 XrmDatabase db;
12218 char *res_name;
12219 char *res_class;
12220 XIMProc callback;
12221 XPointer *client_data;
12222 #ifndef __GNUC__
12223 /* If we're not using GCC, it's probably not XFree86, and this is
12224 probably right, but we can't use something like --pedantic-errors. */
12225 extern Bool XRegisterIMInstantiateCallback(Display*, XrmDatabase, char*,
12226 char*, XIMProc, XPointer*);
12227 #endif
12228 (void)XRegisterIMInstantiateCallback(display, db, res_name, res_class, callback,
12229 client_data);
12230 ;
12231 return 0;
12232 }
12233 _ACEOF
12234 if ac_fn_c_try_compile "$LINENO"; then :
12235 emacs_cv_arg6_star=yes
12236 fi
12237 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12238 if test "$emacs_cv_arg6_star" = yes; then
12239 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer*" >>confdefs.h
12240
12241 else
12242 $as_echo "#define XRegisterIMInstantiateCallback_arg6 XPointer" >>confdefs.h
12243
12244 fi
12245 CFLAGS=$late_CFLAGS
12246 fi
12247
12248 ### Start of font-backend (under any platform) section.
12249 # (nothing here yet -- this is a placeholder)
12250 ### End of font-backend (under any platform) section.
12251
12252 ### Start of font-backend (under X11) section.
12253 if test "${HAVE_X11}" = "yes"; then
12254
12255 succeeded=no
12256
12257 # Extract the first word of "pkg-config", so it can be a program name with args.
12258 set dummy pkg-config; ac_word=$2
12259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12260 $as_echo_n "checking for $ac_word... " >&6; }
12261 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12262 $as_echo_n "(cached) " >&6
12263 else
12264 case $PKG_CONFIG in
12265 [\\/]* | ?:[\\/]*)
12266 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12267 ;;
12268 *)
12269 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12270 for as_dir in $PATH
12271 do
12272 IFS=$as_save_IFS
12273 test -z "$as_dir" && as_dir=.
12274 for ac_exec_ext in '' $ac_executable_extensions; do
12275 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12276 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12277 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12278 break 2
12279 fi
12280 done
12281 done
12282 IFS=$as_save_IFS
12283
12284 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12285 ;;
12286 esac
12287 fi
12288 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12289 if test -n "$PKG_CONFIG"; then
12290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12291 $as_echo "$PKG_CONFIG" >&6; }
12292 else
12293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12294 $as_echo "no" >&6; }
12295 fi
12296
12297
12298
12299 if test "$PKG_CONFIG" = "no" ; then
12300 HAVE_FC=no
12301 else
12302 PKG_CONFIG_MIN_VERSION=0.9.0
12303 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fontconfig >= 2.2.0" >&5
12305 $as_echo_n "checking for fontconfig >= 2.2.0... " >&6; }
12306
12307 if $PKG_CONFIG --exists "fontconfig >= 2.2.0" 2>&5 &&
12308 FONTCONFIG_CFLAGS=`$PKG_CONFIG --cflags "fontconfig >= 2.2.0" 2>&5` &&
12309 FONTCONFIG_LIBS=`$PKG_CONFIG --libs "fontconfig >= 2.2.0" 2>&5`; then
12310
12311 FONTCONFIG_CFLAGS=`$as_echo "$FONTCONFIG_CFLAGS" | sed -e 's,///*,/,g'`
12312 FONTCONFIG_LIBS=`$as_echo "$FONTCONFIG_LIBS" | sed -e 's,///*,/,g'`
12313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&5
12314 $as_echo "yes CFLAGS='$FONTCONFIG_CFLAGS' LIBS='$FONTCONFIG_LIBS'" >&6; }
12315 succeeded=yes
12316 else
12317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12318 $as_echo "no" >&6; }
12319 FONTCONFIG_CFLAGS=""
12320 FONTCONFIG_LIBS=""
12321 ## If we have a custom action on failure, don't print errors, but
12322 ## do set a variable so people can do so.
12323 FONTCONFIG_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "fontconfig >= 2.2.0"`
12324
12325 fi
12326
12327
12328
12329 else
12330 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12331 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12332 fi
12333 fi
12334
12335 if test $succeeded = yes; then
12336 HAVE_FC=yes
12337 else
12338 HAVE_FC=no
12339 fi
12340
12341
12342 ## Use -lXft if available, unless `--with-xft=no'.
12343 HAVE_XFT=maybe
12344 if test "${HAVE_FC}" = "no" || test "x${with_x}" = "xno"; then
12345 with_xft="no";
12346 fi
12347 if test "x${with_xft}" != "xno"; then
12348
12349
12350 succeeded=no
12351
12352 # Extract the first word of "pkg-config", so it can be a program name with args.
12353 set dummy pkg-config; ac_word=$2
12354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12355 $as_echo_n "checking for $ac_word... " >&6; }
12356 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12357 $as_echo_n "(cached) " >&6
12358 else
12359 case $PKG_CONFIG in
12360 [\\/]* | ?:[\\/]*)
12361 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12362 ;;
12363 *)
12364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12365 for as_dir in $PATH
12366 do
12367 IFS=$as_save_IFS
12368 test -z "$as_dir" && as_dir=.
12369 for ac_exec_ext in '' $ac_executable_extensions; do
12370 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12371 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12372 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12373 break 2
12374 fi
12375 done
12376 done
12377 IFS=$as_save_IFS
12378
12379 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12380 ;;
12381 esac
12382 fi
12383 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12384 if test -n "$PKG_CONFIG"; then
12385 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12386 $as_echo "$PKG_CONFIG" >&6; }
12387 else
12388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12389 $as_echo "no" >&6; }
12390 fi
12391
12392
12393
12394 if test "$PKG_CONFIG" = "no" ; then
12395 HAVE_XFT=no
12396 else
12397 PKG_CONFIG_MIN_VERSION=0.9.0
12398 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for xft >= 0.13.0" >&5
12400 $as_echo_n "checking for xft >= 0.13.0... " >&6; }
12401
12402 if $PKG_CONFIG --exists "xft >= 0.13.0" 2>&5 &&
12403 XFT_CFLAGS=`$PKG_CONFIG --cflags "xft >= 0.13.0" 2>&5` &&
12404 XFT_LIBS=`$PKG_CONFIG --libs "xft >= 0.13.0" 2>&5`; then
12405
12406 XFT_CFLAGS=`$as_echo "$XFT_CFLAGS" | sed -e 's,///*,/,g'`
12407 XFT_LIBS=`$as_echo "$XFT_LIBS" | sed -e 's,///*,/,g'`
12408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&5
12409 $as_echo "yes CFLAGS='$XFT_CFLAGS' LIBS='$XFT_LIBS'" >&6; }
12410 succeeded=yes
12411 else
12412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12413 $as_echo "no" >&6; }
12414 XFT_CFLAGS=""
12415 XFT_LIBS=""
12416 ## If we have a custom action on failure, don't print errors, but
12417 ## do set a variable so people can do so.
12418 XFT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "xft >= 0.13.0"`
12419
12420 fi
12421
12422
12423
12424 else
12425 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12426 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12427 fi
12428 fi
12429
12430 if test $succeeded = yes; then
12431 :
12432 else
12433 HAVE_XFT=no
12434 fi
12435
12436 ## Because xftfont.c uses XRenderQueryExtension, we also
12437 ## need to link to -lXrender.
12438 HAVE_XRENDER=no
12439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XRenderQueryExtension in -lXrender" >&5
12440 $as_echo_n "checking for XRenderQueryExtension in -lXrender... " >&6; }
12441 if test "${ac_cv_lib_Xrender_XRenderQueryExtension+set}" = set; then :
12442 $as_echo_n "(cached) " >&6
12443 else
12444 ac_check_lib_save_LIBS=$LIBS
12445 LIBS="-lXrender $LIBS"
12446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12447 /* end confdefs.h. */
12448
12449 /* Override any GCC internal prototype to avoid an error.
12450 Use char because int might match the return type of a GCC
12451 builtin and then its argument prototype would still apply. */
12452 #ifdef __cplusplus
12453 extern "C"
12454 #endif
12455 char XRenderQueryExtension ();
12456 int
12457 main ()
12458 {
12459 return XRenderQueryExtension ();
12460 ;
12461 return 0;
12462 }
12463 _ACEOF
12464 if ac_fn_c_try_link "$LINENO"; then :
12465 ac_cv_lib_Xrender_XRenderQueryExtension=yes
12466 else
12467 ac_cv_lib_Xrender_XRenderQueryExtension=no
12468 fi
12469 rm -f core conftest.err conftest.$ac_objext \
12470 conftest$ac_exeext conftest.$ac_ext
12471 LIBS=$ac_check_lib_save_LIBS
12472 fi
12473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xrender_XRenderQueryExtension" >&5
12474 $as_echo "$ac_cv_lib_Xrender_XRenderQueryExtension" >&6; }
12475 if test "x$ac_cv_lib_Xrender_XRenderQueryExtension" = x""yes; then :
12476 HAVE_XRENDER=yes
12477 fi
12478
12479 if test "$HAVE_XFT" != no && test "$HAVE_XRENDER" != no; then
12480 OLD_CPPFLAGS="$CPPFLAGS"
12481 OLD_CFLAGS="$CFLAGS"
12482 OLD_LIBS="$LIBS"
12483 CPPFLAGS="$CPPFLAGS $XFT_CFLAGS"
12484 CFLAGS="$CFLAGS $XFT_CFLAGS"
12485 XFT_LIBS="-lXrender $XFT_LIBS"
12486 LIBS="$XFT_LIBS $LIBS"
12487 ac_fn_c_check_header_mongrel "$LINENO" "X11/Xft/Xft.h" "ac_cv_header_X11_Xft_Xft_h" "$ac_includes_default"
12488 if test "x$ac_cv_header_X11_Xft_Xft_h" = x""yes; then :
12489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XftFontOpen in -lXft" >&5
12490 $as_echo_n "checking for XftFontOpen in -lXft... " >&6; }
12491 if test "${ac_cv_lib_Xft_XftFontOpen+set}" = set; then :
12492 $as_echo_n "(cached) " >&6
12493 else
12494 ac_check_lib_save_LIBS=$LIBS
12495 LIBS="-lXft $XFT_LIBS $LIBS"
12496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12497 /* end confdefs.h. */
12498
12499 /* Override any GCC internal prototype to avoid an error.
12500 Use char because int might match the return type of a GCC
12501 builtin and then its argument prototype would still apply. */
12502 #ifdef __cplusplus
12503 extern "C"
12504 #endif
12505 char XftFontOpen ();
12506 int
12507 main ()
12508 {
12509 return XftFontOpen ();
12510 ;
12511 return 0;
12512 }
12513 _ACEOF
12514 if ac_fn_c_try_link "$LINENO"; then :
12515 ac_cv_lib_Xft_XftFontOpen=yes
12516 else
12517 ac_cv_lib_Xft_XftFontOpen=no
12518 fi
12519 rm -f core conftest.err conftest.$ac_objext \
12520 conftest$ac_exeext conftest.$ac_ext
12521 LIBS=$ac_check_lib_save_LIBS
12522 fi
12523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xft_XftFontOpen" >&5
12524 $as_echo "$ac_cv_lib_Xft_XftFontOpen" >&6; }
12525 if test "x$ac_cv_lib_Xft_XftFontOpen" = x""yes; then :
12526 HAVE_XFT=yes
12527 fi
12528
12529 fi
12530
12531
12532
12533 if test "${HAVE_XFT}" = "yes"; then
12534
12535 $as_echo "#define HAVE_XFT 1" >>confdefs.h
12536
12537
12538 C_SWITCH_X_SITE="$C_SWITCH_X_SITE $XFT_CFLAGS"
12539 else
12540 CPPFLAGS="$OLD_CPPFLAGS"
12541 CFLAGS="$OLD_CFLAGS"
12542 LIBS="$OLD_LIBS"
12543 fi # "${HAVE_XFT}" = "yes"
12544 fi # "$HAVE_XFT" != no
12545 fi # "x${with_xft}" != "xno"
12546
12547 ## We used to allow building with FreeType and without Xft.
12548 ## However, the ftx font backend driver is not in good shape.
12549 if test "$HAVE_XFT" != "yes"; then
12550 HAVE_XFT=no
12551 HAVE_FREETYPE=no
12552 else
12553
12554 succeeded=no
12555
12556 # Extract the first word of "pkg-config", so it can be a program name with args.
12557 set dummy pkg-config; ac_word=$2
12558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12559 $as_echo_n "checking for $ac_word... " >&6; }
12560 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12561 $as_echo_n "(cached) " >&6
12562 else
12563 case $PKG_CONFIG in
12564 [\\/]* | ?:[\\/]*)
12565 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12566 ;;
12567 *)
12568 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12569 for as_dir in $PATH
12570 do
12571 IFS=$as_save_IFS
12572 test -z "$as_dir" && as_dir=.
12573 for ac_exec_ext in '' $ac_executable_extensions; do
12574 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12575 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12576 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12577 break 2
12578 fi
12579 done
12580 done
12581 IFS=$as_save_IFS
12582
12583 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12584 ;;
12585 esac
12586 fi
12587 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12588 if test -n "$PKG_CONFIG"; then
12589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12590 $as_echo "$PKG_CONFIG" >&6; }
12591 else
12592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12593 $as_echo "no" >&6; }
12594 fi
12595
12596
12597
12598 if test "$PKG_CONFIG" = "no" ; then
12599 HAVE_FREETYPE=no
12600 else
12601 PKG_CONFIG_MIN_VERSION=0.9.0
12602 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12603 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype2" >&5
12604 $as_echo_n "checking for freetype2... " >&6; }
12605
12606 if $PKG_CONFIG --exists "freetype2" 2>&5 &&
12607 FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>&5` &&
12608 FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>&5`; then
12609
12610 FREETYPE_CFLAGS=`$as_echo "$FREETYPE_CFLAGS" | sed -e 's,///*,/,g'`
12611 FREETYPE_LIBS=`$as_echo "$FREETYPE_LIBS" | sed -e 's,///*,/,g'`
12612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&5
12613 $as_echo "yes CFLAGS='$FREETYPE_CFLAGS' LIBS='$FREETYPE_LIBS'" >&6; }
12614 succeeded=yes
12615 else
12616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12617 $as_echo "no" >&6; }
12618 FREETYPE_CFLAGS=""
12619 FREETYPE_LIBS=""
12620 ## If we have a custom action on failure, don't print errors, but
12621 ## do set a variable so people can do so.
12622 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "freetype2"`
12623
12624 fi
12625
12626
12627
12628 else
12629 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12630 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12631 fi
12632 fi
12633
12634 if test $succeeded = yes; then
12635 HAVE_FREETYPE=yes
12636 else
12637 HAVE_FREETYPE=no
12638 fi
12639
12640
12641 test "$HAVE_FREETYPE" = "no" && as_fn_error "libxft requires libfreetype" "$LINENO" 5
12642 fi
12643
12644 HAVE_LIBOTF=no
12645 if test "${HAVE_FREETYPE}" = "yes"; then
12646
12647 $as_echo "#define HAVE_FREETYPE 1" >>confdefs.h
12648
12649 if test "${with_libotf}" != "no"; then
12650
12651 succeeded=no
12652
12653 # Extract the first word of "pkg-config", so it can be a program name with args.
12654 set dummy pkg-config; ac_word=$2
12655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12656 $as_echo_n "checking for $ac_word... " >&6; }
12657 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12658 $as_echo_n "(cached) " >&6
12659 else
12660 case $PKG_CONFIG in
12661 [\\/]* | ?:[\\/]*)
12662 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12663 ;;
12664 *)
12665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12666 for as_dir in $PATH
12667 do
12668 IFS=$as_save_IFS
12669 test -z "$as_dir" && as_dir=.
12670 for ac_exec_ext in '' $ac_executable_extensions; do
12671 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12672 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12674 break 2
12675 fi
12676 done
12677 done
12678 IFS=$as_save_IFS
12679
12680 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12681 ;;
12682 esac
12683 fi
12684 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12685 if test -n "$PKG_CONFIG"; then
12686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12687 $as_echo "$PKG_CONFIG" >&6; }
12688 else
12689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12690 $as_echo "no" >&6; }
12691 fi
12692
12693
12694
12695 if test "$PKG_CONFIG" = "no" ; then
12696 HAVE_LIBOTF=no
12697 else
12698 PKG_CONFIG_MIN_VERSION=0.9.0
12699 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libotf" >&5
12701 $as_echo_n "checking for libotf... " >&6; }
12702
12703 if $PKG_CONFIG --exists "libotf" 2>&5 &&
12704 LIBOTF_CFLAGS=`$PKG_CONFIG --cflags "libotf" 2>&5` &&
12705 LIBOTF_LIBS=`$PKG_CONFIG --libs "libotf" 2>&5`; then
12706
12707 LIBOTF_CFLAGS=`$as_echo "$LIBOTF_CFLAGS" | sed -e 's,///*,/,g'`
12708 LIBOTF_LIBS=`$as_echo "$LIBOTF_LIBS" | sed -e 's,///*,/,g'`
12709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&5
12710 $as_echo "yes CFLAGS='$LIBOTF_CFLAGS' LIBS='$LIBOTF_LIBS'" >&6; }
12711 succeeded=yes
12712 else
12713 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12714 $as_echo "no" >&6; }
12715 LIBOTF_CFLAGS=""
12716 LIBOTF_LIBS=""
12717 ## If we have a custom action on failure, don't print errors, but
12718 ## do set a variable so people can do so.
12719 LIBOTF_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libotf"`
12720
12721 fi
12722
12723
12724
12725 else
12726 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12727 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12728 fi
12729 fi
12730
12731 if test $succeeded = yes; then
12732 HAVE_LIBOTF=yes
12733 else
12734 HAVE_LIBOTF=no
12735 fi
12736
12737 if test "$HAVE_LIBOTF" = "yes"; then
12738
12739 $as_echo "#define HAVE_LIBOTF 1" >>confdefs.h
12740
12741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTF_get_variation_glyphs in -lotf" >&5
12742 $as_echo_n "checking for OTF_get_variation_glyphs in -lotf... " >&6; }
12743 if test "${ac_cv_lib_otf_OTF_get_variation_glyphs+set}" = set; then :
12744 $as_echo_n "(cached) " >&6
12745 else
12746 ac_check_lib_save_LIBS=$LIBS
12747 LIBS="-lotf $LIBS"
12748 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12749 /* end confdefs.h. */
12750
12751 /* Override any GCC internal prototype to avoid an error.
12752 Use char because int might match the return type of a GCC
12753 builtin and then its argument prototype would still apply. */
12754 #ifdef __cplusplus
12755 extern "C"
12756 #endif
12757 char OTF_get_variation_glyphs ();
12758 int
12759 main ()
12760 {
12761 return OTF_get_variation_glyphs ();
12762 ;
12763 return 0;
12764 }
12765 _ACEOF
12766 if ac_fn_c_try_link "$LINENO"; then :
12767 ac_cv_lib_otf_OTF_get_variation_glyphs=yes
12768 else
12769 ac_cv_lib_otf_OTF_get_variation_glyphs=no
12770 fi
12771 rm -f core conftest.err conftest.$ac_objext \
12772 conftest$ac_exeext conftest.$ac_ext
12773 LIBS=$ac_check_lib_save_LIBS
12774 fi
12775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_otf_OTF_get_variation_glyphs" >&5
12776 $as_echo "$ac_cv_lib_otf_OTF_get_variation_glyphs" >&6; }
12777 if test "x$ac_cv_lib_otf_OTF_get_variation_glyphs" = x""yes; then :
12778 HAVE_OTF_GET_VARIATION_GLYPHS=yes
12779 else
12780 HAVE_OTF_GET_VARIATION_GLYPHS=no
12781 fi
12782
12783 if test "${HAVE_OTF_GET_VARIATION_GLYPHS}" = "yes"; then
12784
12785 $as_echo "#define HAVE_OTF_GET_VARIATION_GLYPHS 1" >>confdefs.h
12786
12787 fi
12788 fi
12789 fi
12790 fi
12791
12792 HAVE_M17N_FLT=no
12793 if test "${HAVE_LIBOTF}" = yes; then
12794 if test "${with_m17n_flt}" != "no"; then
12795
12796 succeeded=no
12797
12798 # Extract the first word of "pkg-config", so it can be a program name with args.
12799 set dummy pkg-config; ac_word=$2
12800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12801 $as_echo_n "checking for $ac_word... " >&6; }
12802 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
12803 $as_echo_n "(cached) " >&6
12804 else
12805 case $PKG_CONFIG in
12806 [\\/]* | ?:[\\/]*)
12807 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
12808 ;;
12809 *)
12810 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12811 for as_dir in $PATH
12812 do
12813 IFS=$as_save_IFS
12814 test -z "$as_dir" && as_dir=.
12815 for ac_exec_ext in '' $ac_executable_extensions; do
12816 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
12817 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
12818 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
12819 break 2
12820 fi
12821 done
12822 done
12823 IFS=$as_save_IFS
12824
12825 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
12826 ;;
12827 esac
12828 fi
12829 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
12830 if test -n "$PKG_CONFIG"; then
12831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
12832 $as_echo "$PKG_CONFIG" >&6; }
12833 else
12834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12835 $as_echo "no" >&6; }
12836 fi
12837
12838
12839
12840 if test "$PKG_CONFIG" = "no" ; then
12841 HAVE_M17N_FLT=no
12842 else
12843 PKG_CONFIG_MIN_VERSION=0.9.0
12844 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
12845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for m17n-flt" >&5
12846 $as_echo_n "checking for m17n-flt... " >&6; }
12847
12848 if $PKG_CONFIG --exists "m17n-flt" 2>&5 &&
12849 M17N_FLT_CFLAGS=`$PKG_CONFIG --cflags "m17n-flt" 2>&5` &&
12850 M17N_FLT_LIBS=`$PKG_CONFIG --libs "m17n-flt" 2>&5`; then
12851
12852 M17N_FLT_CFLAGS=`$as_echo "$M17N_FLT_CFLAGS" | sed -e 's,///*,/,g'`
12853 M17N_FLT_LIBS=`$as_echo "$M17N_FLT_LIBS" | sed -e 's,///*,/,g'`
12854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&5
12855 $as_echo "yes CFLAGS='$M17N_FLT_CFLAGS' LIBS='$M17N_FLT_LIBS'" >&6; }
12856 succeeded=yes
12857 else
12858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12859 $as_echo "no" >&6; }
12860 M17N_FLT_CFLAGS=""
12861 M17N_FLT_LIBS=""
12862 ## If we have a custom action on failure, don't print errors, but
12863 ## do set a variable so people can do so.
12864 M17N_FLT_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "m17n-flt"`
12865
12866 fi
12867
12868
12869
12870 else
12871 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
12872 echo "*** See http://www.freedesktop.org/software/pkgconfig"
12873 fi
12874 fi
12875
12876 if test $succeeded = yes; then
12877 HAVE_M17N_FLT=yes
12878 else
12879 HAVE_M17N_FLT=no
12880 fi
12881
12882 if test "$HAVE_M17N_FLT" = "yes"; then
12883
12884 $as_echo "#define HAVE_M17N_FLT 1" >>confdefs.h
12885
12886 fi
12887 fi
12888 fi
12889 else
12890 HAVE_XFT=no
12891 HAVE_FREETYPE=no
12892 HAVE_LIBOTF=no
12893 HAVE_M17N_FLT=no
12894 fi
12895
12896 ### End of font-backend (under X11) section.
12897
12898
12899
12900
12901
12902
12903
12904
12905
12906
12907 ### Use -lXpm if available, unless `--with-xpm=no'.
12908 HAVE_XPM=no
12909 LIBXPM=
12910 if test "${HAVE_X11}" = "yes"; then
12911 if test "${with_xpm}" != "no"; then
12912 ac_fn_c_check_header_mongrel "$LINENO" "X11/xpm.h" "ac_cv_header_X11_xpm_h" "$ac_includes_default"
12913 if test "x$ac_cv_header_X11_xpm_h" = x""yes; then :
12914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReadFileToPixmap in -lXpm" >&5
12915 $as_echo_n "checking for XpmReadFileToPixmap in -lXpm... " >&6; }
12916 if test "${ac_cv_lib_Xpm_XpmReadFileToPixmap+set}" = set; then :
12917 $as_echo_n "(cached) " >&6
12918 else
12919 ac_check_lib_save_LIBS=$LIBS
12920 LIBS="-lXpm -lX11 $LIBS"
12921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12922 /* end confdefs.h. */
12923
12924 /* Override any GCC internal prototype to avoid an error.
12925 Use char because int might match the return type of a GCC
12926 builtin and then its argument prototype would still apply. */
12927 #ifdef __cplusplus
12928 extern "C"
12929 #endif
12930 char XpmReadFileToPixmap ();
12931 int
12932 main ()
12933 {
12934 return XpmReadFileToPixmap ();
12935 ;
12936 return 0;
12937 }
12938 _ACEOF
12939 if ac_fn_c_try_link "$LINENO"; then :
12940 ac_cv_lib_Xpm_XpmReadFileToPixmap=yes
12941 else
12942 ac_cv_lib_Xpm_XpmReadFileToPixmap=no
12943 fi
12944 rm -f core conftest.err conftest.$ac_objext \
12945 conftest$ac_exeext conftest.$ac_ext
12946 LIBS=$ac_check_lib_save_LIBS
12947 fi
12948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_Xpm_XpmReadFileToPixmap" >&5
12949 $as_echo "$ac_cv_lib_Xpm_XpmReadFileToPixmap" >&6; }
12950 if test "x$ac_cv_lib_Xpm_XpmReadFileToPixmap" = x""yes; then :
12951 HAVE_XPM=yes
12952 fi
12953
12954 fi
12955
12956
12957 if test "${HAVE_XPM}" = "yes"; then
12958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XpmReturnAllocPixels preprocessor define" >&5
12959 $as_echo_n "checking for XpmReturnAllocPixels preprocessor define... " >&6; }
12960 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12961 /* end confdefs.h. */
12962 #include "X11/xpm.h"
12963 #ifndef XpmReturnAllocPixels
12964 no_return_alloc_pixels
12965 #endif
12966
12967 _ACEOF
12968 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12969 $EGREP "no_return_alloc_pixels" >/dev/null 2>&1; then :
12970 HAVE_XPM=no
12971 else
12972 HAVE_XPM=yes
12973 fi
12974 rm -f conftest*
12975
12976
12977 if test "${HAVE_XPM}" = "yes"; then
12978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12979 $as_echo "yes" >&6; }
12980 else
12981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12982 $as_echo "no" >&6; }
12983 fi
12984 fi
12985 fi
12986
12987 if test "${HAVE_XPM}" = "yes"; then
12988
12989 $as_echo "#define HAVE_XPM 1" >>confdefs.h
12990
12991 LIBXPM=-lXpm
12992 fi
12993 fi
12994
12995
12996 ### Use -ljpeg if available, unless `--with-jpeg=no'.
12997 HAVE_JPEG=no
12998 LIBJPEG=
12999 if test "${HAVE_X11}" = "yes"; then
13000 if test "${with_jpeg}" != "no"; then
13001 ac_fn_c_check_header_mongrel "$LINENO" "jerror.h" "ac_cv_header_jerror_h" "$ac_includes_default"
13002 if test "x$ac_cv_header_jerror_h" = x""yes; then :
13003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_destroy_compress in -ljpeg" >&5
13004 $as_echo_n "checking for jpeg_destroy_compress in -ljpeg... " >&6; }
13005 if test "${ac_cv_lib_jpeg_jpeg_destroy_compress+set}" = set; then :
13006 $as_echo_n "(cached) " >&6
13007 else
13008 ac_check_lib_save_LIBS=$LIBS
13009 LIBS="-ljpeg $LIBS"
13010 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13011 /* end confdefs.h. */
13012
13013 /* Override any GCC internal prototype to avoid an error.
13014 Use char because int might match the return type of a GCC
13015 builtin and then its argument prototype would still apply. */
13016 #ifdef __cplusplus
13017 extern "C"
13018 #endif
13019 char jpeg_destroy_compress ();
13020 int
13021 main ()
13022 {
13023 return jpeg_destroy_compress ();
13024 ;
13025 return 0;
13026 }
13027 _ACEOF
13028 if ac_fn_c_try_link "$LINENO"; then :
13029 ac_cv_lib_jpeg_jpeg_destroy_compress=yes
13030 else
13031 ac_cv_lib_jpeg_jpeg_destroy_compress=no
13032 fi
13033 rm -f core conftest.err conftest.$ac_objext \
13034 conftest$ac_exeext conftest.$ac_ext
13035 LIBS=$ac_check_lib_save_LIBS
13036 fi
13037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_destroy_compress" >&5
13038 $as_echo "$ac_cv_lib_jpeg_jpeg_destroy_compress" >&6; }
13039 if test "x$ac_cv_lib_jpeg_jpeg_destroy_compress" = x""yes; then :
13040 HAVE_JPEG=yes
13041 fi
13042
13043 fi
13044
13045
13046 fi
13047
13048 if test "${HAVE_JPEG}" = "yes"; then
13049 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13050
13051 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13052 /* end confdefs.h. */
13053 #include <jpeglib.h>
13054 version=JPEG_LIB_VERSION
13055
13056 _ACEOF
13057 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13058 $EGREP "version= *(6[2-9]|[7-9][0-9])" >/dev/null 2>&1; then :
13059 $as_echo "#define HAVE_JPEG 1" >>confdefs.h
13060
13061 else
13062 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libjpeg found, but not version 6b or later" >&5
13063 $as_echo "$as_me: WARNING: libjpeg found, but not version 6b or later" >&2;}
13064 HAVE_JPEG=no
13065 fi
13066 rm -f conftest*
13067
13068 fi
13069 if test "${HAVE_JPEG}" = "yes"; then
13070 LIBJPEG=-ljpeg
13071 fi
13072 fi
13073
13074
13075 ### Use -lpng if available, unless `--with-png=no'.
13076 HAVE_PNG=no
13077 LIBPNG=
13078 if test "${HAVE_X11}" = "yes"; then
13079 if test "${with_png}" != "no"; then
13080 # Debian unstable as of July 2003 has multiple libpngs, and puts png.h
13081 # in /usr/include/libpng.
13082 for ac_header in png.h libpng/png.h
13083 do :
13084 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13085 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
13086 eval as_val=\$$as_ac_Header
13087 if test "x$as_val" = x""yes; then :
13088 cat >>confdefs.h <<_ACEOF
13089 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13090 _ACEOF
13091
13092 fi
13093
13094 done
13095
13096 if test "$ac_cv_header_png_h" = yes || test "$ac_cv_header_libpng_png_h" = yes ; then
13097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for png_get_channels in -lpng" >&5
13098 $as_echo_n "checking for png_get_channels in -lpng... " >&6; }
13099 if test "${ac_cv_lib_png_png_get_channels+set}" = set; then :
13100 $as_echo_n "(cached) " >&6
13101 else
13102 ac_check_lib_save_LIBS=$LIBS
13103 LIBS="-lpng -lz -lm $LIBS"
13104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13105 /* end confdefs.h. */
13106
13107 /* Override any GCC internal prototype to avoid an error.
13108 Use char because int might match the return type of a GCC
13109 builtin and then its argument prototype would still apply. */
13110 #ifdef __cplusplus
13111 extern "C"
13112 #endif
13113 char png_get_channels ();
13114 int
13115 main ()
13116 {
13117 return png_get_channels ();
13118 ;
13119 return 0;
13120 }
13121 _ACEOF
13122 if ac_fn_c_try_link "$LINENO"; then :
13123 ac_cv_lib_png_png_get_channels=yes
13124 else
13125 ac_cv_lib_png_png_get_channels=no
13126 fi
13127 rm -f core conftest.err conftest.$ac_objext \
13128 conftest$ac_exeext conftest.$ac_ext
13129 LIBS=$ac_check_lib_save_LIBS
13130 fi
13131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_png_png_get_channels" >&5
13132 $as_echo "$ac_cv_lib_png_png_get_channels" >&6; }
13133 if test "x$ac_cv_lib_png_png_get_channels" = x""yes; then :
13134 HAVE_PNG=yes
13135 fi
13136
13137 fi
13138 fi
13139
13140 if test "${HAVE_PNG}" = "yes"; then
13141
13142 $as_echo "#define HAVE_PNG 1" >>confdefs.h
13143
13144 LIBPNG="-lpng -lz -lm"
13145 fi
13146 fi
13147
13148
13149 ### Use -ltiff if available, unless `--with-tiff=no'.
13150 HAVE_TIFF=no
13151 LIBTIFF=
13152 if test "${HAVE_X11}" = "yes"; then
13153 if test "${with_tiff}" != "no"; then
13154 ac_fn_c_check_header_mongrel "$LINENO" "tiffio.h" "ac_cv_header_tiffio_h" "$ac_includes_default"
13155 if test "x$ac_cv_header_tiffio_h" = x""yes; then :
13156 tifflibs="-lz -lm"
13157 # At least one tiff package requires the jpeg library.
13158 if test "${HAVE_JPEG}" = yes; then tifflibs="-ljpeg $tifflibs"; fi
13159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIFFGetVersion in -ltiff" >&5
13160 $as_echo_n "checking for TIFFGetVersion in -ltiff... " >&6; }
13161 if test "${ac_cv_lib_tiff_TIFFGetVersion+set}" = set; then :
13162 $as_echo_n "(cached) " >&6
13163 else
13164 ac_check_lib_save_LIBS=$LIBS
13165 LIBS="-ltiff $tifflibs $LIBS"
13166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13167 /* end confdefs.h. */
13168
13169 /* Override any GCC internal prototype to avoid an error.
13170 Use char because int might match the return type of a GCC
13171 builtin and then its argument prototype would still apply. */
13172 #ifdef __cplusplus
13173 extern "C"
13174 #endif
13175 char TIFFGetVersion ();
13176 int
13177 main ()
13178 {
13179 return TIFFGetVersion ();
13180 ;
13181 return 0;
13182 }
13183 _ACEOF
13184 if ac_fn_c_try_link "$LINENO"; then :
13185 ac_cv_lib_tiff_TIFFGetVersion=yes
13186 else
13187 ac_cv_lib_tiff_TIFFGetVersion=no
13188 fi
13189 rm -f core conftest.err conftest.$ac_objext \
13190 conftest$ac_exeext conftest.$ac_ext
13191 LIBS=$ac_check_lib_save_LIBS
13192 fi
13193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tiff_TIFFGetVersion" >&5
13194 $as_echo "$ac_cv_lib_tiff_TIFFGetVersion" >&6; }
13195 if test "x$ac_cv_lib_tiff_TIFFGetVersion" = x""yes; then :
13196 HAVE_TIFF=yes
13197 fi
13198
13199 fi
13200
13201
13202 fi
13203
13204 if test "${HAVE_TIFF}" = "yes"; then
13205
13206 $as_echo "#define HAVE_TIFF 1" >>confdefs.h
13207
13208 LIBTIFF=-ltiff
13209 fi
13210 fi
13211
13212
13213 ### Use -lgif or -lungif if available, unless `--with-gif=no'.
13214 HAVE_GIF=no
13215 LIBGIF=
13216 if test "${HAVE_X11}" = "yes" && test "${with_gif}" != "no"; then
13217 ac_fn_c_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default"
13218 if test "x$ac_cv_header_gif_lib_h" = x""yes; then :
13219 # EGifPutExtensionLast only exists from version libungif-4.1.0b1.
13220 # Earlier versions can crash Emacs.
13221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lgif" >&5
13222 $as_echo_n "checking for EGifPutExtensionLast in -lgif... " >&6; }
13223 if test "${ac_cv_lib_gif_EGifPutExtensionLast+set}" = set; then :
13224 $as_echo_n "(cached) " >&6
13225 else
13226 ac_check_lib_save_LIBS=$LIBS
13227 LIBS="-lgif $LIBS"
13228 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13229 /* end confdefs.h. */
13230
13231 /* Override any GCC internal prototype to avoid an error.
13232 Use char because int might match the return type of a GCC
13233 builtin and then its argument prototype would still apply. */
13234 #ifdef __cplusplus
13235 extern "C"
13236 #endif
13237 char EGifPutExtensionLast ();
13238 int
13239 main ()
13240 {
13241 return EGifPutExtensionLast ();
13242 ;
13243 return 0;
13244 }
13245 _ACEOF
13246 if ac_fn_c_try_link "$LINENO"; then :
13247 ac_cv_lib_gif_EGifPutExtensionLast=yes
13248 else
13249 ac_cv_lib_gif_EGifPutExtensionLast=no
13250 fi
13251 rm -f core conftest.err conftest.$ac_objext \
13252 conftest$ac_exeext conftest.$ac_ext
13253 LIBS=$ac_check_lib_save_LIBS
13254 fi
13255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_EGifPutExtensionLast" >&5
13256 $as_echo "$ac_cv_lib_gif_EGifPutExtensionLast" >&6; }
13257 if test "x$ac_cv_lib_gif_EGifPutExtensionLast" = x""yes; then :
13258 HAVE_GIF=yes
13259 else
13260 HAVE_GIF=maybe
13261 fi
13262
13263 fi
13264
13265
13266
13267 if test "$HAVE_GIF" = yes; then
13268 LIBGIF=-lgif
13269 elif test "$HAVE_GIF" = maybe; then
13270 # If gif_lib.h but no libgif, try libungif.
13271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGifPutExtensionLast in -lungif" >&5
13272 $as_echo_n "checking for EGifPutExtensionLast in -lungif... " >&6; }
13273 if test "${ac_cv_lib_ungif_EGifPutExtensionLast+set}" = set; then :
13274 $as_echo_n "(cached) " >&6
13275 else
13276 ac_check_lib_save_LIBS=$LIBS
13277 LIBS="-lungif $LIBS"
13278 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13279 /* end confdefs.h. */
13280
13281 /* Override any GCC internal prototype to avoid an error.
13282 Use char because int might match the return type of a GCC
13283 builtin and then its argument prototype would still apply. */
13284 #ifdef __cplusplus
13285 extern "C"
13286 #endif
13287 char EGifPutExtensionLast ();
13288 int
13289 main ()
13290 {
13291 return EGifPutExtensionLast ();
13292 ;
13293 return 0;
13294 }
13295 _ACEOF
13296 if ac_fn_c_try_link "$LINENO"; then :
13297 ac_cv_lib_ungif_EGifPutExtensionLast=yes
13298 else
13299 ac_cv_lib_ungif_EGifPutExtensionLast=no
13300 fi
13301 rm -f core conftest.err conftest.$ac_objext \
13302 conftest$ac_exeext conftest.$ac_ext
13303 LIBS=$ac_check_lib_save_LIBS
13304 fi
13305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ungif_EGifPutExtensionLast" >&5
13306 $as_echo "$ac_cv_lib_ungif_EGifPutExtensionLast" >&6; }
13307 if test "x$ac_cv_lib_ungif_EGifPutExtensionLast" = x""yes; then :
13308 HAVE_GIF=yes
13309 else
13310 HAVE_GIF=no
13311 fi
13312
13313 test "$HAVE_GIF" = yes && LIBGIF=-lungif
13314 fi
13315
13316 if test "${HAVE_GIF}" = "yes"; then
13317
13318 $as_echo "#define HAVE_GIF 1" >>confdefs.h
13319
13320 fi
13321 fi
13322
13323
13324 if test "${HAVE_X11}" = "yes"; then
13325 MISSING=""
13326 WITH_NO=""
13327 test "${with_xpm}" != "no" && test "${HAVE_XPM}" != "yes" &&
13328 MISSING="libXpm" && WITH_NO="--with-xpm=no"
13329 test "${with_jpeg}" != "no" && test "${HAVE_JPEG}" != "yes" &&
13330 MISSING="$MISSING libjpeg" && WITH_NO="$WITH_NO --with-jpeg=no"
13331 test "${with_png}" != "no" && test "${HAVE_PNG}" != "yes" &&
13332 MISSING="$MISSING libpng" && WITH_NO="$WITH_NO --with-png=no"
13333 test "${with_gif}" != "no" && test "${HAVE_GIF}" != "yes" &&
13334 MISSING="$MISSING libgif/libungif" && WITH_NO="$WITH_NO --with-gif=no"
13335 test "${with_tiff}" != "no" && test "${HAVE_TIFF}" != "yes" &&
13336 MISSING="$MISSING libtiff" && WITH_NO="$WITH_NO --with-tiff=no"
13337
13338 if test "X${MISSING}" != X; then
13339 as_fn_error "The following required libraries were not found:
13340 $MISSING
13341 Maybe some development libraries/packages are missing?
13342 If you don't want to link with them give
13343 $WITH_NO
13344 as options to configure" "$LINENO" 5
13345 fi
13346 fi
13347
13348 ### Use -lgpm if available, unless `--with-gpm=no'.
13349 HAVE_GPM=no
13350 LIBGPM=
13351 if test "${with_gpm}" != "no"; then
13352 ac_fn_c_check_header_mongrel "$LINENO" "gpm.h" "ac_cv_header_gpm_h" "$ac_includes_default"
13353 if test "x$ac_cv_header_gpm_h" = x""yes; then :
13354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Gpm_Open in -lgpm" >&5
13355 $as_echo_n "checking for Gpm_Open in -lgpm... " >&6; }
13356 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then :
13357 $as_echo_n "(cached) " >&6
13358 else
13359 ac_check_lib_save_LIBS=$LIBS
13360 LIBS="-lgpm $LIBS"
13361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13362 /* end confdefs.h. */
13363
13364 /* Override any GCC internal prototype to avoid an error.
13365 Use char because int might match the return type of a GCC
13366 builtin and then its argument prototype would still apply. */
13367 #ifdef __cplusplus
13368 extern "C"
13369 #endif
13370 char Gpm_Open ();
13371 int
13372 main ()
13373 {
13374 return Gpm_Open ();
13375 ;
13376 return 0;
13377 }
13378 _ACEOF
13379 if ac_fn_c_try_link "$LINENO"; then :
13380 ac_cv_lib_gpm_Gpm_Open=yes
13381 else
13382 ac_cv_lib_gpm_Gpm_Open=no
13383 fi
13384 rm -f core conftest.err conftest.$ac_objext \
13385 conftest$ac_exeext conftest.$ac_ext
13386 LIBS=$ac_check_lib_save_LIBS
13387 fi
13388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gpm_Gpm_Open" >&5
13389 $as_echo "$ac_cv_lib_gpm_Gpm_Open" >&6; }
13390 if test "x$ac_cv_lib_gpm_Gpm_Open" = x""yes; then :
13391 HAVE_GPM=yes
13392 fi
13393
13394 fi
13395
13396
13397
13398 if test "${HAVE_GPM}" = "yes"; then
13399
13400 $as_echo "#define HAVE_GPM 1" >>confdefs.h
13401
13402 LIBGPM=-lgpm
13403 fi
13404 fi
13405
13406
13407 ac_fn_c_check_header_mongrel "$LINENO" "malloc/malloc.h" "ac_cv_header_malloc_malloc_h" "$ac_includes_default"
13408 if test "x$ac_cv_header_malloc_malloc_h" = x""yes; then :
13409
13410 $as_echo "#define HAVE_MALLOC_MALLOC_H 1" >>confdefs.h
13411
13412 fi
13413
13414
13415
13416 C_SWITCH_X_SYSTEM=
13417 ### Use NeXTstep API to implement GUI.
13418 if test "${HAVE_NS}" = "yes"; then
13419
13420 $as_echo "#define HAVE_NS 1" >>confdefs.h
13421
13422 if test "${NS_IMPL_COCOA}" = "yes"; then
13423
13424 $as_echo "#define NS_IMPL_COCOA 1" >>confdefs.h
13425
13426 fi
13427 if test "${NS_IMPL_GNUSTEP}" = "yes"; then
13428
13429 $as_echo "#define NS_IMPL_GNUSTEP 1" >>confdefs.h
13430
13431 # See also .m.o rule in Makefile.in */
13432 # FIXME: are all these flags really needed? Document here why. */
13433 C_SWITCH_X_SYSTEM="-D_REENTRANT -fPIC -fno-strict-aliasing -I${GNUSTEP_SYSTEM_HEADERS} ${GNUSTEP_LOCAL_HEADERS}"
13434 ## Extra CFLAGS applied to src/*.m files.
13435 GNU_OBJC_CFLAGS="$GNU_OBJC_CFLAGS -fgnu-runtime -Wno-import -fconstant-string-class=NSConstantString -DGNUSTEP_BASE_LIBRARY=1 -DGNU_GUI_LIBRARY=1 -DGNU_RUNTIME=1 -DGSWARN -DGSDIAGNOSE"
13436 fi
13437 if test "${NS_HAVE_NSINTEGER}" = "yes"; then
13438
13439 $as_echo "#define NS_HAVE_NSINTEGER 1" >>confdefs.h
13440
13441 fi
13442 # We also have mouse menus.
13443 HAVE_MENUS=yes
13444 OTHER_FILES=ns-app
13445 fi
13446
13447
13448 ### Use session management (-lSM -lICE) if available
13449 HAVE_X_SM=no
13450 LIBXSM=
13451 if test "${HAVE_X11}" = "yes"; then
13452 ac_fn_c_check_header_mongrel "$LINENO" "X11/SM/SMlib.h" "ac_cv_header_X11_SM_SMlib_h" "$ac_includes_default"
13453 if test "x$ac_cv_header_X11_SM_SMlib_h" = x""yes; then :
13454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SmcOpenConnection in -lSM" >&5
13455 $as_echo_n "checking for SmcOpenConnection in -lSM... " >&6; }
13456 if test "${ac_cv_lib_SM_SmcOpenConnection+set}" = set; then :
13457 $as_echo_n "(cached) " >&6
13458 else
13459 ac_check_lib_save_LIBS=$LIBS
13460 LIBS="-lSM -lICE $LIBS"
13461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13462 /* end confdefs.h. */
13463
13464 /* Override any GCC internal prototype to avoid an error.
13465 Use char because int might match the return type of a GCC
13466 builtin and then its argument prototype would still apply. */
13467 #ifdef __cplusplus
13468 extern "C"
13469 #endif
13470 char SmcOpenConnection ();
13471 int
13472 main ()
13473 {
13474 return SmcOpenConnection ();
13475 ;
13476 return 0;
13477 }
13478 _ACEOF
13479 if ac_fn_c_try_link "$LINENO"; then :
13480 ac_cv_lib_SM_SmcOpenConnection=yes
13481 else
13482 ac_cv_lib_SM_SmcOpenConnection=no
13483 fi
13484 rm -f core conftest.err conftest.$ac_objext \
13485 conftest$ac_exeext conftest.$ac_ext
13486 LIBS=$ac_check_lib_save_LIBS
13487 fi
13488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_SM_SmcOpenConnection" >&5
13489 $as_echo "$ac_cv_lib_SM_SmcOpenConnection" >&6; }
13490 if test "x$ac_cv_lib_SM_SmcOpenConnection" = x""yes; then :
13491 HAVE_X_SM=yes
13492 fi
13493
13494 fi
13495
13496
13497
13498 if test "${HAVE_X_SM}" = "yes"; then
13499
13500 $as_echo "#define HAVE_X_SM 1" >>confdefs.h
13501
13502 LIBXSM="-lSM -lICE"
13503 case "$LIBS" in
13504 *-lSM*) ;;
13505 *) LIBS="$LIBXSM $LIBS" ;;
13506 esac
13507 fi
13508 fi
13509
13510
13511 ### Use libxml (-lxml2) if available
13512 HAVE_LIBXML2=no
13513 if test "${with_xml2}" != "no"; then
13514 ### I'm not sure what the version number should be, so I just guessed.
13515
13516 succeeded=no
13517
13518 # Extract the first word of "pkg-config", so it can be a program name with args.
13519 set dummy pkg-config; ac_word=$2
13520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13521 $as_echo_n "checking for $ac_word... " >&6; }
13522 if test "${ac_cv_path_PKG_CONFIG+set}" = set; then :
13523 $as_echo_n "(cached) " >&6
13524 else
13525 case $PKG_CONFIG in
13526 [\\/]* | ?:[\\/]*)
13527 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
13528 ;;
13529 *)
13530 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13531 for as_dir in $PATH
13532 do
13533 IFS=$as_save_IFS
13534 test -z "$as_dir" && as_dir=.
13535 for ac_exec_ext in '' $ac_executable_extensions; do
13536 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13537 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext"
13538 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13539 break 2
13540 fi
13541 done
13542 done
13543 IFS=$as_save_IFS
13544
13545 test -z "$ac_cv_path_PKG_CONFIG" && ac_cv_path_PKG_CONFIG="no"
13546 ;;
13547 esac
13548 fi
13549 PKG_CONFIG=$ac_cv_path_PKG_CONFIG
13550 if test -n "$PKG_CONFIG"; then
13551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
13552 $as_echo "$PKG_CONFIG" >&6; }
13553 else
13554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13555 $as_echo "no" >&6; }
13556 fi
13557
13558
13559
13560 if test "$PKG_CONFIG" = "no" ; then
13561 HAVE_LIBXML2=no
13562 else
13563 PKG_CONFIG_MIN_VERSION=0.9.0
13564 if $PKG_CONFIG --atleast-pkgconfig-version $PKG_CONFIG_MIN_VERSION; then
13565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml-2.0 > 2.6.17" >&5
13566 $as_echo_n "checking for libxml-2.0 > 2.6.17... " >&6; }
13567
13568 if $PKG_CONFIG --exists "libxml-2.0 > 2.6.17" 2>&5 &&
13569 LIBXML2_CFLAGS=`$PKG_CONFIG --cflags "libxml-2.0 > 2.6.17" 2>&5` &&
13570 LIBXML2_LIBS=`$PKG_CONFIG --libs "libxml-2.0 > 2.6.17" 2>&5`; then
13571
13572 LIBXML2_CFLAGS=`$as_echo "$LIBXML2_CFLAGS" | sed -e 's,///*,/,g'`
13573 LIBXML2_LIBS=`$as_echo "$LIBXML2_LIBS" | sed -e 's,///*,/,g'`
13574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&5
13575 $as_echo "yes CFLAGS='$LIBXML2_CFLAGS' LIBS='$LIBXML2_LIBS'" >&6; }
13576 succeeded=yes
13577 else
13578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13579 $as_echo "no" >&6; }
13580 LIBXML2_CFLAGS=""
13581 LIBXML2_LIBS=""
13582 ## If we have a custom action on failure, don't print errors, but
13583 ## do set a variable so people can do so.
13584 LIBXML2_PKG_ERRORS=`$PKG_CONFIG --errors-to-stdout --print-errors "libxml-2.0 > 2.6.17"`
13585
13586 fi
13587
13588
13589
13590 else
13591 echo "*** Your version of pkg-config is too old. You need version $PKG_CONFIG_MIN_VERSION or newer."
13592 echo "*** See http://www.freedesktop.org/software/pkgconfig"
13593 fi
13594 fi
13595
13596 if test $succeeded = yes; then
13597 HAVE_LIBXML2=yes
13598 else
13599 HAVE_LIBXML2=no
13600 fi
13601
13602 if test "${HAVE_LIBXML2}" = "yes"; then
13603 LIBS="$LIBXML2_LIBS $LIBS"
13604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for htmlReadMemory in -lxml2" >&5
13605 $as_echo_n "checking for htmlReadMemory in -lxml2... " >&6; }
13606 if test "${ac_cv_lib_xml2_htmlReadMemory+set}" = set; then :
13607 $as_echo_n "(cached) " >&6
13608 else
13609 ac_check_lib_save_LIBS=$LIBS
13610 LIBS="-lxml2 $LIBS"
13611 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13612 /* end confdefs.h. */
13613
13614 /* Override any GCC internal prototype to avoid an error.
13615 Use char because int might match the return type of a GCC
13616 builtin and then its argument prototype would still apply. */
13617 #ifdef __cplusplus
13618 extern "C"
13619 #endif
13620 char htmlReadMemory ();
13621 int
13622 main ()
13623 {
13624 return htmlReadMemory ();
13625 ;
13626 return 0;
13627 }
13628 _ACEOF
13629 if ac_fn_c_try_link "$LINENO"; then :
13630 ac_cv_lib_xml2_htmlReadMemory=yes
13631 else
13632 ac_cv_lib_xml2_htmlReadMemory=no
13633 fi
13634 rm -f core conftest.err conftest.$ac_objext \
13635 conftest$ac_exeext conftest.$ac_ext
13636 LIBS=$ac_check_lib_save_LIBS
13637 fi
13638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xml2_htmlReadMemory" >&5
13639 $as_echo "$ac_cv_lib_xml2_htmlReadMemory" >&6; }
13640 if test "x$ac_cv_lib_xml2_htmlReadMemory" = x""yes; then :
13641 HAVE_LIBXML2=yes
13642 else
13643 HAVE_LIBXML2=no
13644 fi
13645
13646 if test "${HAVE_LIBXML2}" = "yes"; then
13647
13648 $as_echo "#define HAVE_LIBXML2 1" >>confdefs.h
13649
13650 else
13651 LIBXML2_LIBS=""
13652 LIBXML2_CFLAGS=""
13653 fi
13654 fi
13655 fi
13656
13657
13658
13659 # If netdb.h doesn't declare h_errno, we must declare it by hand.
13660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether netdb declares h_errno" >&5
13661 $as_echo_n "checking whether netdb declares h_errno... " >&6; }
13662 if test "${emacs_cv_netdb_declares_h_errno+set}" = set; then :
13663 $as_echo_n "(cached) " >&6
13664 else
13665 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13666 /* end confdefs.h. */
13667 #include <netdb.h>
13668 int
13669 main ()
13670 {
13671 return h_errno;
13672 ;
13673 return 0;
13674 }
13675 _ACEOF
13676 if ac_fn_c_try_link "$LINENO"; then :
13677 emacs_cv_netdb_declares_h_errno=yes
13678 else
13679 emacs_cv_netdb_declares_h_errno=no
13680 fi
13681 rm -f core conftest.err conftest.$ac_objext \
13682 conftest$ac_exeext conftest.$ac_ext
13683 fi
13684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_netdb_declares_h_errno" >&5
13685 $as_echo "$emacs_cv_netdb_declares_h_errno" >&6; }
13686 if test $emacs_cv_netdb_declares_h_errno = yes; then
13687
13688 $as_echo "#define HAVE_H_ERRNO 1" >>confdefs.h
13689
13690 fi
13691
13692 # fmod, logb, and frexp are found in -lm on most systems.
13693 # On HPUX 9.01, -lm does not contain logb, so check for sqrt.
13694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sqrt in -lm" >&5
13695 $as_echo_n "checking for sqrt in -lm... " >&6; }
13696 if test "${ac_cv_lib_m_sqrt+set}" = set; then :
13697 $as_echo_n "(cached) " >&6
13698 else
13699 ac_check_lib_save_LIBS=$LIBS
13700 LIBS="-lm $LIBS"
13701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13702 /* end confdefs.h. */
13703
13704 /* Override any GCC internal prototype to avoid an error.
13705 Use char because int might match the return type of a GCC
13706 builtin and then its argument prototype would still apply. */
13707 #ifdef __cplusplus
13708 extern "C"
13709 #endif
13710 char sqrt ();
13711 int
13712 main ()
13713 {
13714 return sqrt ();
13715 ;
13716 return 0;
13717 }
13718 _ACEOF
13719 if ac_fn_c_try_link "$LINENO"; then :
13720 ac_cv_lib_m_sqrt=yes
13721 else
13722 ac_cv_lib_m_sqrt=no
13723 fi
13724 rm -f core conftest.err conftest.$ac_objext \
13725 conftest$ac_exeext conftest.$ac_ext
13726 LIBS=$ac_check_lib_save_LIBS
13727 fi
13728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_sqrt" >&5
13729 $as_echo "$ac_cv_lib_m_sqrt" >&6; }
13730 if test "x$ac_cv_lib_m_sqrt" = x""yes; then :
13731 cat >>confdefs.h <<_ACEOF
13732 #define HAVE_LIBM 1
13733 _ACEOF
13734
13735 LIBS="-lm $LIBS"
13736
13737 fi
13738
13739
13740 # Check for mail-locking functions in a "mail" library. Probably this should
13741 # have the same check as for liblockfile below.
13742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -lmail" >&5
13743 $as_echo_n "checking for maillock in -lmail... " >&6; }
13744 if test "${ac_cv_lib_mail_maillock+set}" = set; then :
13745 $as_echo_n "(cached) " >&6
13746 else
13747 ac_check_lib_save_LIBS=$LIBS
13748 LIBS="-lmail $LIBS"
13749 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13750 /* end confdefs.h. */
13751
13752 /* Override any GCC internal prototype to avoid an error.
13753 Use char because int might match the return type of a GCC
13754 builtin and then its argument prototype would still apply. */
13755 #ifdef __cplusplus
13756 extern "C"
13757 #endif
13758 char maillock ();
13759 int
13760 main ()
13761 {
13762 return maillock ();
13763 ;
13764 return 0;
13765 }
13766 _ACEOF
13767 if ac_fn_c_try_link "$LINENO"; then :
13768 ac_cv_lib_mail_maillock=yes
13769 else
13770 ac_cv_lib_mail_maillock=no
13771 fi
13772 rm -f core conftest.err conftest.$ac_objext \
13773 conftest$ac_exeext conftest.$ac_ext
13774 LIBS=$ac_check_lib_save_LIBS
13775 fi
13776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_mail_maillock" >&5
13777 $as_echo "$ac_cv_lib_mail_maillock" >&6; }
13778 if test "x$ac_cv_lib_mail_maillock" = x""yes; then :
13779 have_mail=yes
13780 else
13781 have_mail=no
13782 fi
13783
13784 if test $have_mail = yes; then
13785 LIBS_MAIL=-lmail
13786 LIBS="$LIBS_MAIL $LIBS"
13787
13788 $as_echo "#define HAVE_LIBMAIL 1" >>confdefs.h
13789
13790 else
13791 LIBS_MAIL=
13792 fi
13793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for maillock in -llockfile" >&5
13794 $as_echo_n "checking for maillock in -llockfile... " >&6; }
13795 if test "${ac_cv_lib_lockfile_maillock+set}" = set; then :
13796 $as_echo_n "(cached) " >&6
13797 else
13798 ac_check_lib_save_LIBS=$LIBS
13799 LIBS="-llockfile $LIBS"
13800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13801 /* end confdefs.h. */
13802
13803 /* Override any GCC internal prototype to avoid an error.
13804 Use char because int might match the return type of a GCC
13805 builtin and then its argument prototype would still apply. */
13806 #ifdef __cplusplus
13807 extern "C"
13808 #endif
13809 char maillock ();
13810 int
13811 main ()
13812 {
13813 return maillock ();
13814 ;
13815 return 0;
13816 }
13817 _ACEOF
13818 if ac_fn_c_try_link "$LINENO"; then :
13819 ac_cv_lib_lockfile_maillock=yes
13820 else
13821 ac_cv_lib_lockfile_maillock=no
13822 fi
13823 rm -f core conftest.err conftest.$ac_objext \
13824 conftest$ac_exeext conftest.$ac_ext
13825 LIBS=$ac_check_lib_save_LIBS
13826 fi
13827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_lockfile_maillock" >&5
13828 $as_echo "$ac_cv_lib_lockfile_maillock" >&6; }
13829 if test "x$ac_cv_lib_lockfile_maillock" = x""yes; then :
13830 have_lockfile=yes
13831 else
13832 have_lockfile=no
13833 fi
13834
13835 if test $have_lockfile = yes; then
13836 LIBS_MAIL=-llockfile
13837 LIBS="$LIBS_MAIL $LIBS"
13838
13839 $as_echo "#define HAVE_LIBLOCKFILE 1" >>confdefs.h
13840
13841 else
13842 # If we have the shared liblockfile, assume we must use it for mail
13843 # locking (e.g. Debian). If we couldn't link against liblockfile
13844 # (no liblockfile.a installed), ensure that we don't need to.
13845 # Extract the first word of "liblockfile.so", so it can be a program name with args.
13846 set dummy liblockfile.so; ac_word=$2
13847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13848 $as_echo_n "checking for $ac_word... " >&6; }
13849 if test "${ac_cv_prog_liblockfile+set}" = set; then :
13850 $as_echo_n "(cached) " >&6
13851 else
13852 if test -n "$liblockfile"; then
13853 ac_cv_prog_liblockfile="$liblockfile" # Let the user override the test.
13854 else
13855 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13856 as_dummy="/usr/lib:/lib:/usr/local/lib:$LD_LIBRARY_PATH"
13857 for as_dir in $as_dummy
13858 do
13859 IFS=$as_save_IFS
13860 test -z "$as_dir" && as_dir=.
13861 for ac_exec_ext in '' $ac_executable_extensions; do
13862 if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
13863 ac_cv_prog_liblockfile="yes"
13864 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
13865 break 2
13866 fi
13867 done
13868 done
13869 IFS=$as_save_IFS
13870
13871 test -z "$ac_cv_prog_liblockfile" && ac_cv_prog_liblockfile="no"
13872 fi
13873 fi
13874 liblockfile=$ac_cv_prog_liblockfile
13875 if test -n "$liblockfile"; then
13876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liblockfile" >&5
13877 $as_echo "$liblockfile" >&6; }
13878 else
13879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13880 $as_echo "no" >&6; }
13881 fi
13882
13883
13884 if test $ac_cv_prog_liblockfile = yes; then
13885 as_fn_error "Shared liblockfile found but can't link against it.
13886 This probably means that movemail could lose mail.
13887 There may be a \`development' package to install containing liblockfile." "$LINENO" 5
13888 fi
13889 fi
13890 for ac_func in touchlock
13891 do :
13892 ac_fn_c_check_func "$LINENO" "touchlock" "ac_cv_func_touchlock"
13893 if test "x$ac_cv_func_touchlock" = x""yes; then :
13894 cat >>confdefs.h <<_ACEOF
13895 #define HAVE_TOUCHLOCK 1
13896 _ACEOF
13897
13898 fi
13899 done
13900
13901 for ac_header in maillock.h
13902 do :
13903 ac_fn_c_check_header_mongrel "$LINENO" "maillock.h" "ac_cv_header_maillock_h" "$ac_includes_default"
13904 if test "x$ac_cv_header_maillock_h" = x""yes; then :
13905 cat >>confdefs.h <<_ACEOF
13906 #define HAVE_MAILLOCK_H 1
13907 _ACEOF
13908
13909 fi
13910
13911 done
13912
13913
13914
13915 ## Define MAIL_USE_FLOCK (or LOCKF) if the mailer uses flock (or lockf) to
13916 ## interlock access to the mail spool. The alternative is a lock file named
13917 ## /usr/spool/mail/$USER.lock.
13918 mail_lock=no
13919 case "$opsys" in
13920 aix4-2) mail_lock="lockf" ;;
13921
13922 gnu|freebsd|netbsd|openbsd|darwin|irix6-5) mail_lock="flock" ;;
13923
13924 ## On GNU/Linux systems, both methods are used by various mail programs.
13925 ## I assume most people are using newer mailers that have heard of flock.
13926 ## Change this if you need to.
13927 ## Debian contains a patch which says: ``On Debian/GNU/Linux systems,
13928 ## configure gets the right answers, and that means *NOT* using flock.
13929 ## Using flock is guaranteed to be the wrong thing. See Debian Policy
13930 ## for details.'' and then uses `#ifdef DEBIAN'. Unfortunately the
13931 ## Debian maintainer hasn't provided a clean fix for Emacs.
13932 ## movemail.c will use `maillock' when MAILDIR, HAVE_LIBMAIL and
13933 ## HAVE_MAILLOCK_H are defined, so the following appears to be the
13934 ## correct logic. -- fx
13935 ## We must check for HAVE_LIBLOCKFILE too, as movemail does.
13936 ## liblockfile is a Free Software replacement for libmail, used on
13937 ## Debian systems and elsewhere. -rfr.
13938 gnu-*)
13939 mail_lock="flock"
13940 if test $have_mail = yes || test $have_lockfile = yes; then
13941 test $ac_cv_header_maillock_h = yes && mail_lock=no
13942 fi
13943 ;;
13944 esac
13945
13946 BLESSMAIL_TARGET=
13947 case "$mail_lock" in
13948 flock)
13949 $as_echo "#define MAIL_USE_FLOCK 1" >>confdefs.h
13950 ;;
13951
13952 lockf)
13953 $as_echo "#define MAIL_USE_LOCKF 1" >>confdefs.h
13954 ;;
13955
13956 *) BLESSMAIL_TARGET="need-blessmail" ;;
13957 esac
13958
13959
13960
13961 for ac_func in gethostname getdomainname \
13962 rename closedir mkdir rmdir sysinfo getrusage get_current_dir_name \
13963 random lrand48 logb frexp fmod rint cbrt ftime setsid \
13964 strerror fpathconf select euidaccess getpagesize tzset setlocale \
13965 utimes getrlimit setrlimit setpgid getcwd getwd shutdown getaddrinfo \
13966 __fpending mblen mbrlen mbsinit strsignal setitimer ualarm \
13967 sendto recvfrom getsockopt setsockopt getsockname getpeername \
13968 gai_strerror mkstemp getline getdelim mremap fsync sync \
13969 difftime mempcpy mblen mbrlen posix_memalign \
13970 cfmakeraw cfsetspeed copysign __executable_start
13971 do :
13972 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
13973 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
13974 eval as_val=\$$as_ac_var
13975 if test "x$as_val" = x""yes; then :
13976 cat >>confdefs.h <<_ACEOF
13977 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
13978 _ACEOF
13979
13980 fi
13981 done
13982
13983
13984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __builtin_unwind_init" >&5
13985 $as_echo_n "checking for __builtin_unwind_init... " >&6; }
13986 if test "${emacs_cv_func___builtin_unwind_init+set}" = set; then :
13987 $as_echo_n "(cached) " >&6
13988 else
13989 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13990 /* end confdefs.h. */
13991
13992 int
13993 main ()
13994 {
13995 __builtin_unwind_init ();
13996 ;
13997 return 0;
13998 }
13999 _ACEOF
14000 if ac_fn_c_try_link "$LINENO"; then :
14001 emacs_cv_func___builtin_unwind_init=yes
14002 else
14003 emacs_cv_func___builtin_unwind_init=no
14004 fi
14005 rm -f core conftest.err conftest.$ac_objext \
14006 conftest$ac_exeext conftest.$ac_ext
14007 fi
14008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_func___builtin_unwind_init" >&5
14009 $as_echo "$emacs_cv_func___builtin_unwind_init" >&6; }
14010 if test $emacs_cv_func___builtin_unwind_init = yes; then
14011
14012 $as_echo "#define HAVE___BUILTIN_UNWIND_INIT 1" >>confdefs.h
14013
14014 fi
14015
14016 for ac_header in sys/un.h
14017 do :
14018 ac_fn_c_check_header_mongrel "$LINENO" "sys/un.h" "ac_cv_header_sys_un_h" "$ac_includes_default"
14019 if test "x$ac_cv_header_sys_un_h" = x""yes; then :
14020 cat >>confdefs.h <<_ACEOF
14021 #define HAVE_SYS_UN_H 1
14022 _ACEOF
14023
14024 fi
14025
14026 done
14027
14028
14029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGEFILE_SOURCE value needed for large files" >&5
14030 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
14031 if test "${ac_cv_sys_largefile_source+set}" = set; then :
14032 $as_echo_n "(cached) " >&6
14033 else
14034 while :; do
14035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14036 /* end confdefs.h. */
14037 #include <sys/types.h> /* for off_t */
14038 #include <stdio.h>
14039 int
14040 main ()
14041 {
14042 int (*fp) (FILE *, off_t, int) = fseeko;
14043 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14044 ;
14045 return 0;
14046 }
14047 _ACEOF
14048 if ac_fn_c_try_link "$LINENO"; then :
14049 ac_cv_sys_largefile_source=no; break
14050 fi
14051 rm -f core conftest.err conftest.$ac_objext \
14052 conftest$ac_exeext conftest.$ac_ext
14053 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14054 /* end confdefs.h. */
14055 #define _LARGEFILE_SOURCE 1
14056 #include <sys/types.h> /* for off_t */
14057 #include <stdio.h>
14058 int
14059 main ()
14060 {
14061 int (*fp) (FILE *, off_t, int) = fseeko;
14062 return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
14063 ;
14064 return 0;
14065 }
14066 _ACEOF
14067 if ac_fn_c_try_link "$LINENO"; then :
14068 ac_cv_sys_largefile_source=1; break
14069 fi
14070 rm -f core conftest.err conftest.$ac_objext \
14071 conftest$ac_exeext conftest.$ac_ext
14072 ac_cv_sys_largefile_source=unknown
14073 break
14074 done
14075 fi
14076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_source" >&5
14077 $as_echo "$ac_cv_sys_largefile_source" >&6; }
14078 case $ac_cv_sys_largefile_source in #(
14079 no | unknown) ;;
14080 *)
14081 cat >>confdefs.h <<_ACEOF
14082 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
14083 _ACEOF
14084 ;;
14085 esac
14086 rm -rf conftest*
14087
14088 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
14089 # in glibc 2.1.3, but that breaks too many other things.
14090 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
14091 if test $ac_cv_sys_largefile_source != unknown; then
14092
14093 $as_echo "#define HAVE_FSEEKO 1" >>confdefs.h
14094
14095 fi
14096
14097
14098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
14099 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
14100 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
14101 $as_echo_n "(cached) " >&6
14102 else
14103 # Use it with a single arg.
14104 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14105 /* end confdefs.h. */
14106 $ac_includes_default
14107 int
14108 main ()
14109 {
14110 getpgrp (0);
14111 ;
14112 return 0;
14113 }
14114 _ACEOF
14115 if ac_fn_c_try_compile "$LINENO"; then :
14116 ac_cv_func_getpgrp_void=no
14117 else
14118 ac_cv_func_getpgrp_void=yes
14119 fi
14120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14121
14122 fi
14123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
14124 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
14125 if test $ac_cv_func_getpgrp_void = yes; then
14126
14127 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
14128
14129 fi
14130
14131
14132 # UNIX98 PTYs.
14133 for ac_func in grantpt
14134 do :
14135 ac_fn_c_check_func "$LINENO" "grantpt" "ac_cv_func_grantpt"
14136 if test "x$ac_cv_func_grantpt" = x""yes; then :
14137 cat >>confdefs.h <<_ACEOF
14138 #define HAVE_GRANTPT 1
14139 _ACEOF
14140
14141 fi
14142 done
14143
14144
14145 # PTY-related GNU extensions.
14146 for ac_func in getpt
14147 do :
14148 ac_fn_c_check_func "$LINENO" "getpt" "ac_cv_func_getpt"
14149 if test "x$ac_cv_func_getpt" = x""yes; then :
14150 cat >>confdefs.h <<_ACEOF
14151 #define HAVE_GETPT 1
14152 _ACEOF
14153
14154 fi
14155 done
14156
14157
14158 # Check this now, so that we will NOT find the above functions in ncurses.
14159 # That is because we have not set up to link ncurses in lib-src.
14160 # It's better to believe a function is not available
14161 # than to expect to find it in ncurses.
14162 # Also we need tputs and friends to be able to build at all.
14163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing tputs" >&5
14164 $as_echo_n "checking for library containing tputs... " >&6; }
14165 # Run a test program that contains a call to tputs, a call that is
14166 # never executed. This tests whether a pre-'main' dynamic linker
14167 # works with the library. It's too much trouble to actually call
14168 # tputs in the test program, due to portability hassles. When
14169 # cross-compiling, assume the test program will run if it links.
14170
14171 # Maybe curses should be tried earlier?
14172 # See http://debbugs.gnu.org/cgi/bugreport.cgi?bug=9736#35
14173 for tputs_library in '' ncurses terminfo termcap curses; do
14174 OLIBS=$LIBS
14175 if test -z "$tputs_library"; then
14176 LIBS_TERMCAP=
14177 msg='none required'
14178 else
14179 LIBS_TERMCAP=-l$tputs_library
14180 msg=$LIBS_TERMCAP
14181 LIBS="$LIBS_TERMCAP $LIBS"
14182 fi
14183 if test "$cross_compiling" = yes; then :
14184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14185 /* end confdefs.h. */
14186
14187 extern void tputs (const char *, int, int (*)(int));
14188 int main (int argc, char **argv)
14189 {
14190 if (argc == 10000)
14191 tputs (argv[0], 0, 0);
14192 return 0;
14193 }
14194
14195 _ACEOF
14196 if ac_fn_c_try_link "$LINENO"; then :
14197
14198 else
14199 msg=no
14200 fi
14201 rm -f core conftest.err conftest.$ac_objext \
14202 conftest$ac_exeext conftest.$ac_ext
14203 else
14204 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14205 /* end confdefs.h. */
14206
14207 extern void tputs (const char *, int, int (*)(int));
14208 int main (int argc, char **argv)
14209 {
14210 if (argc == 10000)
14211 tputs (argv[0], 0, 0);
14212 return 0;
14213 }
14214
14215 _ACEOF
14216 if ac_fn_c_try_run "$LINENO"; then :
14217
14218 else
14219 msg=no
14220 fi
14221 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
14222 conftest.$ac_objext conftest.beam conftest.$ac_ext
14223 fi
14224
14225 LIBS=$OLIBS
14226 if test "X$msg" != Xno; then
14227 break
14228 fi
14229 done
14230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $msg" >&5
14231 $as_echo "$msg" >&6; }
14232 if test "X$msg" = Xno; then
14233 as_fn_error "The required function \`tputs' was not found in any library.
14234 These libraries were tried: libncurses, libterminfo, libtermcap, libcurses.
14235 Please try installing whichever of these libraries is most appropriate
14236 for your system, together with its header files.
14237 For example, a libncurses-dev(el) or similar package." "$LINENO" 5
14238 fi
14239 # Must define this when any termcap library is found.
14240
14241 $as_echo "#define HAVE_LIBNCURSES 1" >>confdefs.h
14242
14243 ## FIXME This was the cpp logic, but I am not sure it is right.
14244 ## The above test has not necessarily found libncurses.
14245 HAVE_LIBNCURSES=yes
14246
14247 ## Use terminfo instead of termcap?
14248 ## Note only system files NOT using terminfo are:
14249 ## freebsd < 40000, ms-w32, msdos, netbsd < 599002500, and
14250 ## darwin|gnu without ncurses.
14251 TERMINFO=no
14252 case "$opsys" in
14253 ## cygwin: Fewer environment variables to go wrong, more terminal types.
14254 ## hpux10-20: Use the system provided termcap(3) library.
14255 ## openbsd: David Mazieres <dm@reeducation-labor.lcs.mit.edu> says this
14256 ## is necessary. Otherwise Emacs dumps core when run -nw.
14257 aix4-2|cygwin|hpux*|irix6-5|openbsd|sol2*|unixware) TERMINFO=yes ;;
14258
14259 ## darwin: Prevents crashes when running Emacs in Terminal.app under 10.2.
14260 ## The ncurses library has been moved out of the System framework in
14261 ## Mac OS X 10.2. So if configure detects it, set the command-line
14262 ## option to use it.
14263 darwin|gnu*)
14264 ## (HAVE_LIBNCURSES was not always true, but is since 2010-03-18.)
14265 if test "x$HAVE_LIBNCURSES" = "xyes"; then
14266 TERMINFO=yes
14267 LIBS_TERMCAP="-lncurses"
14268 fi
14269 ;;
14270
14271 freebsd)
14272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether FreeBSD is new enough to use terminfo" >&5
14273 $as_echo_n "checking whether FreeBSD is new enough to use terminfo... " >&6; }
14274 if test "${emacs_cv_freebsd_terminfo+set}" = set; then :
14275 $as_echo_n "(cached) " >&6
14276 else
14277 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14278 /* end confdefs.h. */
14279 #include <osreldate.h>
14280 int
14281 main ()
14282 {
14283 #if __FreeBSD_version < 400000
14284 fail;
14285 #endif
14286
14287 ;
14288 return 0;
14289 }
14290 _ACEOF
14291 if ac_fn_c_try_link "$LINENO"; then :
14292 emacs_cv_freebsd_terminfo=yes
14293 else
14294 emacs_cv_freebsd_terminfo=no
14295 fi
14296 rm -f core conftest.err conftest.$ac_objext \
14297 conftest$ac_exeext conftest.$ac_ext
14298 fi
14299
14300
14301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_freebsd_terminfo" >&5
14302 $as_echo "$emacs_cv_freebsd_terminfo" >&6; }
14303
14304 if test $emacs_cv_freebsd_terminfo = yes; then
14305 TERMINFO=yes
14306 LIBS_TERMCAP="-lncurses"
14307 else
14308 LIBS_TERMCAP="-ltermcap"
14309 fi
14310 ;;
14311
14312 netbsd)
14313 if test $ac_cv_search_tputs = -lterminfo; then
14314 TERMINFO=yes
14315 LIBS_TERMCAP="-lterminfo"
14316 else
14317 LIBS_TERMCAP="-ltermcap"
14318 fi
14319 ;;
14320
14321 esac
14322
14323 case "$opsys" in
14324 ## hpux: Make sure we get select from libc rather than from libcurses
14325 ## because libcurses on HPUX 10.10 has a broken version of select.
14326 ## We used to use -lc -lcurses, but this may be cleaner.
14327 hpux*) LIBS_TERMCAP="-ltermcap" ;;
14328
14329 openbsd) LIBS_TERMCAP="-lncurses" ;;
14330
14331 ## Must use system termcap, if we use any termcap. It does special things.
14332 sol2*) test "$TERMINFO" != yes && LIBS_TERMCAP="-ltermcap" ;;
14333 esac
14334
14335 TERMCAP_OBJ=tparam.o
14336 if test $TERMINFO = yes; then
14337
14338 $as_echo "#define TERMINFO 1" >>confdefs.h
14339
14340 TERMCAP_OBJ=terminfo.o
14341 fi
14342
14343
14344
14345
14346 # Do we have res_init, for detecting changes in /etc/resolv.conf?
14347 resolv=no
14348 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14349 /* end confdefs.h. */
14350 #include <netinet/in.h>
14351 #include <arpa/nameser.h>
14352 #include <resolv.h>
14353 int
14354 main ()
14355 {
14356 return res_init();
14357 ;
14358 return 0;
14359 }
14360 _ACEOF
14361 if ac_fn_c_try_link "$LINENO"; then :
14362 have_res_init=yes
14363 else
14364 have_res_init=no
14365 fi
14366 rm -f core conftest.err conftest.$ac_objext \
14367 conftest$ac_exeext conftest.$ac_ext
14368 if test "$have_res_init" = no; then
14369 OLIBS="$LIBS"
14370 LIBS="$LIBS -lresolv"
14371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_init with -lresolv" >&5
14372 $as_echo_n "checking for res_init with -lresolv... " >&6; }
14373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14374 /* end confdefs.h. */
14375 #include <netinet/in.h>
14376 #include <arpa/nameser.h>
14377 #include <resolv.h>
14378 int
14379 main ()
14380 {
14381 return res_init();
14382 ;
14383 return 0;
14384 }
14385 _ACEOF
14386 if ac_fn_c_try_link "$LINENO"; then :
14387 have_res_init=yes
14388 else
14389 have_res_init=no
14390 fi
14391 rm -f core conftest.err conftest.$ac_objext \
14392 conftest$ac_exeext conftest.$ac_ext
14393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_res_init" >&5
14394 $as_echo "$have_res_init" >&6; }
14395 if test "$have_res_init" = yes ; then
14396 resolv=yes
14397 fi
14398 LIBS="$OLIBS"
14399 fi
14400
14401 if test "$have_res_init" = yes; then
14402
14403 $as_echo "#define HAVE_RES_INIT 1" >>confdefs.h
14404
14405 fi
14406
14407 # Do we need the Hesiod library to provide the support routines?
14408 LIBHESIOD=
14409 if test "$with_hesiod" != no ; then
14410 # Don't set $LIBS here -- see comments above. FIXME which comments?
14411 ac_fn_c_check_func "$LINENO" "res_send" "ac_cv_func_res_send"
14412 if test "x$ac_cv_func_res_send" = x""yes; then :
14413
14414 else
14415 ac_fn_c_check_func "$LINENO" "__res_send" "ac_cv_func___res_send"
14416 if test "x$ac_cv_func___res_send" = x""yes; then :
14417
14418 else
14419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_send in -lresolv" >&5
14420 $as_echo_n "checking for res_send in -lresolv... " >&6; }
14421 if test "${ac_cv_lib_resolv_res_send+set}" = set; then :
14422 $as_echo_n "(cached) " >&6
14423 else
14424 ac_check_lib_save_LIBS=$LIBS
14425 LIBS="-lresolv $LIBS"
14426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14427 /* end confdefs.h. */
14428
14429 /* Override any GCC internal prototype to avoid an error.
14430 Use char because int might match the return type of a GCC
14431 builtin and then its argument prototype would still apply. */
14432 #ifdef __cplusplus
14433 extern "C"
14434 #endif
14435 char res_send ();
14436 int
14437 main ()
14438 {
14439 return res_send ();
14440 ;
14441 return 0;
14442 }
14443 _ACEOF
14444 if ac_fn_c_try_link "$LINENO"; then :
14445 ac_cv_lib_resolv_res_send=yes
14446 else
14447 ac_cv_lib_resolv_res_send=no
14448 fi
14449 rm -f core conftest.err conftest.$ac_objext \
14450 conftest$ac_exeext conftest.$ac_ext
14451 LIBS=$ac_check_lib_save_LIBS
14452 fi
14453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_send" >&5
14454 $as_echo "$ac_cv_lib_resolv_res_send" >&6; }
14455 if test "x$ac_cv_lib_resolv_res_send" = x""yes; then :
14456 resolv=yes
14457 else
14458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __res_send in -lresolv" >&5
14459 $as_echo_n "checking for __res_send in -lresolv... " >&6; }
14460 if test "${ac_cv_lib_resolv___res_send+set}" = set; then :
14461 $as_echo_n "(cached) " >&6
14462 else
14463 ac_check_lib_save_LIBS=$LIBS
14464 LIBS="-lresolv $LIBS"
14465 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14466 /* end confdefs.h. */
14467
14468 /* Override any GCC internal prototype to avoid an error.
14469 Use char because int might match the return type of a GCC
14470 builtin and then its argument prototype would still apply. */
14471 #ifdef __cplusplus
14472 extern "C"
14473 #endif
14474 char __res_send ();
14475 int
14476 main ()
14477 {
14478 return __res_send ();
14479 ;
14480 return 0;
14481 }
14482 _ACEOF
14483 if ac_fn_c_try_link "$LINENO"; then :
14484 ac_cv_lib_resolv___res_send=yes
14485 else
14486 ac_cv_lib_resolv___res_send=no
14487 fi
14488 rm -f core conftest.err conftest.$ac_objext \
14489 conftest$ac_exeext conftest.$ac_ext
14490 LIBS=$ac_check_lib_save_LIBS
14491 fi
14492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv___res_send" >&5
14493 $as_echo "$ac_cv_lib_resolv___res_send" >&6; }
14494 if test "x$ac_cv_lib_resolv___res_send" = x""yes; then :
14495 resolv=yes
14496 fi
14497
14498 fi
14499
14500 fi
14501
14502 fi
14503
14504 if test "$resolv" = yes ; then
14505 RESOLVLIB=-lresolv
14506 else
14507 RESOLVLIB=
14508 fi
14509 ac_fn_c_check_func "$LINENO" "hes_getmailhost" "ac_cv_func_hes_getmailhost"
14510 if test "x$ac_cv_func_hes_getmailhost" = x""yes; then :
14511
14512 else
14513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for hes_getmailhost in -lhesiod" >&5
14514 $as_echo_n "checking for hes_getmailhost in -lhesiod... " >&6; }
14515 if test "${ac_cv_lib_hesiod_hes_getmailhost+set}" = set; then :
14516 $as_echo_n "(cached) " >&6
14517 else
14518 ac_check_lib_save_LIBS=$LIBS
14519 LIBS="-lhesiod $RESOLVLIB $LIBS"
14520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14521 /* end confdefs.h. */
14522
14523 /* Override any GCC internal prototype to avoid an error.
14524 Use char because int might match the return type of a GCC
14525 builtin and then its argument prototype would still apply. */
14526 #ifdef __cplusplus
14527 extern "C"
14528 #endif
14529 char hes_getmailhost ();
14530 int
14531 main ()
14532 {
14533 return hes_getmailhost ();
14534 ;
14535 return 0;
14536 }
14537 _ACEOF
14538 if ac_fn_c_try_link "$LINENO"; then :
14539 ac_cv_lib_hesiod_hes_getmailhost=yes
14540 else
14541 ac_cv_lib_hesiod_hes_getmailhost=no
14542 fi
14543 rm -f core conftest.err conftest.$ac_objext \
14544 conftest$ac_exeext conftest.$ac_ext
14545 LIBS=$ac_check_lib_save_LIBS
14546 fi
14547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_hesiod_hes_getmailhost" >&5
14548 $as_echo "$ac_cv_lib_hesiod_hes_getmailhost" >&6; }
14549 if test "x$ac_cv_lib_hesiod_hes_getmailhost" = x""yes; then :
14550 hesiod=yes
14551 else
14552 :
14553 fi
14554
14555 fi
14556
14557
14558 if test x"$hesiod" = xyes; then
14559
14560 $as_echo "#define HAVE_LIBHESIOD 1" >>confdefs.h
14561
14562 LIBHESIOD=-lhesiod
14563 fi
14564 fi
14565
14566
14567 # Do we need libresolv (due to res_init or Hesiod)?
14568 if test "$resolv" = yes ; then
14569
14570 $as_echo "#define HAVE_LIBRESOLV 1" >>confdefs.h
14571
14572 LIBRESOLV=-lresolv
14573 else
14574 LIBRESOLV=
14575 fi
14576
14577
14578 # These tell us which Kerberos-related libraries to use.
14579 COM_ERRLIB=
14580 CRYPTOLIB=
14581 KRB5LIB=
14582 DESLIB=
14583 KRB4LIB=
14584
14585 if test "${with_kerberos}" != no; then
14586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for com_err in -lcom_err" >&5
14587 $as_echo_n "checking for com_err in -lcom_err... " >&6; }
14588 if test "${ac_cv_lib_com_err_com_err+set}" = set; then :
14589 $as_echo_n "(cached) " >&6
14590 else
14591 ac_check_lib_save_LIBS=$LIBS
14592 LIBS="-lcom_err $LIBS"
14593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14594 /* end confdefs.h. */
14595
14596 /* Override any GCC internal prototype to avoid an error.
14597 Use char because int might match the return type of a GCC
14598 builtin and then its argument prototype would still apply. */
14599 #ifdef __cplusplus
14600 extern "C"
14601 #endif
14602 char com_err ();
14603 int
14604 main ()
14605 {
14606 return com_err ();
14607 ;
14608 return 0;
14609 }
14610 _ACEOF
14611 if ac_fn_c_try_link "$LINENO"; then :
14612 ac_cv_lib_com_err_com_err=yes
14613 else
14614 ac_cv_lib_com_err_com_err=no
14615 fi
14616 rm -f core conftest.err conftest.$ac_objext \
14617 conftest$ac_exeext conftest.$ac_ext
14618 LIBS=$ac_check_lib_save_LIBS
14619 fi
14620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_com_err_com_err" >&5
14621 $as_echo "$ac_cv_lib_com_err_com_err" >&6; }
14622 if test "x$ac_cv_lib_com_err_com_err" = x""yes; then :
14623 have_com_err=yes
14624 else
14625 have_com_err=no
14626 fi
14627
14628 if test $have_com_err = yes; then
14629 COM_ERRLIB=-lcom_err
14630 LIBS="$COM_ERRLIB $LIBS"
14631
14632 $as_echo "#define HAVE_LIBCOM_ERR 1" >>confdefs.h
14633
14634 fi
14635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lcrypto" >&5
14636 $as_echo_n "checking for mit_des_cbc_encrypt in -lcrypto... " >&6; }
14637 if test "${ac_cv_lib_crypto_mit_des_cbc_encrypt+set}" = set; then :
14638 $as_echo_n "(cached) " >&6
14639 else
14640 ac_check_lib_save_LIBS=$LIBS
14641 LIBS="-lcrypto $LIBS"
14642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14643 /* end confdefs.h. */
14644
14645 /* Override any GCC internal prototype to avoid an error.
14646 Use char because int might match the return type of a GCC
14647 builtin and then its argument prototype would still apply. */
14648 #ifdef __cplusplus
14649 extern "C"
14650 #endif
14651 char mit_des_cbc_encrypt ();
14652 int
14653 main ()
14654 {
14655 return mit_des_cbc_encrypt ();
14656 ;
14657 return 0;
14658 }
14659 _ACEOF
14660 if ac_fn_c_try_link "$LINENO"; then :
14661 ac_cv_lib_crypto_mit_des_cbc_encrypt=yes
14662 else
14663 ac_cv_lib_crypto_mit_des_cbc_encrypt=no
14664 fi
14665 rm -f core conftest.err conftest.$ac_objext \
14666 conftest$ac_exeext conftest.$ac_ext
14667 LIBS=$ac_check_lib_save_LIBS
14668 fi
14669 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypto_mit_des_cbc_encrypt" >&5
14670 $as_echo "$ac_cv_lib_crypto_mit_des_cbc_encrypt" >&6; }
14671 if test "x$ac_cv_lib_crypto_mit_des_cbc_encrypt" = x""yes; then :
14672 have_crypto=yes
14673 else
14674 have_crypto=no
14675 fi
14676
14677 if test $have_crypto = yes; then
14678 CRYPTOLIB=-lcrypto
14679 LIBS="$CRYPTOLIB $LIBS"
14680
14681 $as_echo "#define HAVE_LIBCRYPTO 1" >>confdefs.h
14682
14683 fi
14684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mit_des_cbc_encrypt in -lk5crypto" >&5
14685 $as_echo_n "checking for mit_des_cbc_encrypt in -lk5crypto... " >&6; }
14686 if test "${ac_cv_lib_k5crypto_mit_des_cbc_encrypt+set}" = set; then :
14687 $as_echo_n "(cached) " >&6
14688 else
14689 ac_check_lib_save_LIBS=$LIBS
14690 LIBS="-lk5crypto $LIBS"
14691 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14692 /* end confdefs.h. */
14693
14694 /* Override any GCC internal prototype to avoid an error.
14695 Use char because int might match the return type of a GCC
14696 builtin and then its argument prototype would still apply. */
14697 #ifdef __cplusplus
14698 extern "C"
14699 #endif
14700 char mit_des_cbc_encrypt ();
14701 int
14702 main ()
14703 {
14704 return mit_des_cbc_encrypt ();
14705 ;
14706 return 0;
14707 }
14708 _ACEOF
14709 if ac_fn_c_try_link "$LINENO"; then :
14710 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=yes
14711 else
14712 ac_cv_lib_k5crypto_mit_des_cbc_encrypt=no
14713 fi
14714 rm -f core conftest.err conftest.$ac_objext \
14715 conftest$ac_exeext conftest.$ac_ext
14716 LIBS=$ac_check_lib_save_LIBS
14717 fi
14718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&5
14719 $as_echo "$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" >&6; }
14720 if test "x$ac_cv_lib_k5crypto_mit_des_cbc_encrypt" = x""yes; then :
14721 have_k5crypto=yes
14722 else
14723 have_k5crypto=no
14724 fi
14725
14726 if test $have_k5crypto = yes; then
14727 CRYPTOLIB=-lk5crypto
14728 LIBS="$CRYPTOLIB $LIBS"
14729
14730 $as_echo "#define HAVE_LIBK5CRYPTO 1" >>confdefs.h
14731
14732 fi
14733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb5_init_context in -lkrb5" >&5
14734 $as_echo_n "checking for krb5_init_context in -lkrb5... " >&6; }
14735 if test "${ac_cv_lib_krb5_krb5_init_context+set}" = set; then :
14736 $as_echo_n "(cached) " >&6
14737 else
14738 ac_check_lib_save_LIBS=$LIBS
14739 LIBS="-lkrb5 $LIBS"
14740 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14741 /* end confdefs.h. */
14742
14743 /* Override any GCC internal prototype to avoid an error.
14744 Use char because int might match the return type of a GCC
14745 builtin and then its argument prototype would still apply. */
14746 #ifdef __cplusplus
14747 extern "C"
14748 #endif
14749 char krb5_init_context ();
14750 int
14751 main ()
14752 {
14753 return krb5_init_context ();
14754 ;
14755 return 0;
14756 }
14757 _ACEOF
14758 if ac_fn_c_try_link "$LINENO"; then :
14759 ac_cv_lib_krb5_krb5_init_context=yes
14760 else
14761 ac_cv_lib_krb5_krb5_init_context=no
14762 fi
14763 rm -f core conftest.err conftest.$ac_objext \
14764 conftest$ac_exeext conftest.$ac_ext
14765 LIBS=$ac_check_lib_save_LIBS
14766 fi
14767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb5_krb5_init_context" >&5
14768 $as_echo "$ac_cv_lib_krb5_krb5_init_context" >&6; }
14769 if test "x$ac_cv_lib_krb5_krb5_init_context" = x""yes; then :
14770 have_krb5=yes
14771 else
14772 have_krb5=no
14773 fi
14774
14775 if test $have_krb5=yes; then
14776 KRB5LIB=-lkrb5
14777 LIBS="$KRB5LIB $LIBS"
14778
14779 $as_echo "#define HAVE_LIBKRB5 1" >>confdefs.h
14780
14781 fi
14782 if test "${with_kerberos5}" = no; then
14783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes425" >&5
14784 $as_echo_n "checking for des_cbc_encrypt in -ldes425... " >&6; }
14785 if test "${ac_cv_lib_des425_des_cbc_encrypt+set}" = set; then :
14786 $as_echo_n "(cached) " >&6
14787 else
14788 ac_check_lib_save_LIBS=$LIBS
14789 LIBS="-ldes425 $LIBS"
14790 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14791 /* end confdefs.h. */
14792
14793 /* Override any GCC internal prototype to avoid an error.
14794 Use char because int might match the return type of a GCC
14795 builtin and then its argument prototype would still apply. */
14796 #ifdef __cplusplus
14797 extern "C"
14798 #endif
14799 char des_cbc_encrypt ();
14800 int
14801 main ()
14802 {
14803 return des_cbc_encrypt ();
14804 ;
14805 return 0;
14806 }
14807 _ACEOF
14808 if ac_fn_c_try_link "$LINENO"; then :
14809 ac_cv_lib_des425_des_cbc_encrypt=yes
14810 else
14811 ac_cv_lib_des425_des_cbc_encrypt=no
14812 fi
14813 rm -f core conftest.err conftest.$ac_objext \
14814 conftest$ac_exeext conftest.$ac_ext
14815 LIBS=$ac_check_lib_save_LIBS
14816 fi
14817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des425_des_cbc_encrypt" >&5
14818 $as_echo "$ac_cv_lib_des425_des_cbc_encrypt" >&6; }
14819 if test "x$ac_cv_lib_des425_des_cbc_encrypt" = x""yes; then :
14820 have_des425=yes
14821 else
14822 have_des425=no
14823 fi
14824
14825 if test $have_des425 = yes; then
14826 DESLIB=-ldes425
14827 LIBS="$DESLIB $LIBS"
14828
14829 $as_echo "#define HAVE_LIBDES425 1" >>confdefs.h
14830
14831 else
14832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14833 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14834 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14835 $as_echo_n "(cached) " >&6
14836 else
14837 ac_check_lib_save_LIBS=$LIBS
14838 LIBS="-ldes $LIBS"
14839 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14840 /* end confdefs.h. */
14841
14842 /* Override any GCC internal prototype to avoid an error.
14843 Use char because int might match the return type of a GCC
14844 builtin and then its argument prototype would still apply. */
14845 #ifdef __cplusplus
14846 extern "C"
14847 #endif
14848 char des_cbc_encrypt ();
14849 int
14850 main ()
14851 {
14852 return des_cbc_encrypt ();
14853 ;
14854 return 0;
14855 }
14856 _ACEOF
14857 if ac_fn_c_try_link "$LINENO"; then :
14858 ac_cv_lib_des_des_cbc_encrypt=yes
14859 else
14860 ac_cv_lib_des_des_cbc_encrypt=no
14861 fi
14862 rm -f core conftest.err conftest.$ac_objext \
14863 conftest$ac_exeext conftest.$ac_ext
14864 LIBS=$ac_check_lib_save_LIBS
14865 fi
14866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14867 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14868 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14869 have_des=yes
14870 else
14871 have_des=no
14872 fi
14873
14874 if test $have_des = yes; then
14875 DESLIB=-ldes
14876 LIBS="$DESLIB $LIBS"
14877
14878 $as_echo "#define HAVE_LIBDES 1" >>confdefs.h
14879
14880 fi
14881 fi
14882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb4" >&5
14883 $as_echo_n "checking for krb_get_cred in -lkrb4... " >&6; }
14884 if test "${ac_cv_lib_krb4_krb_get_cred+set}" = set; then :
14885 $as_echo_n "(cached) " >&6
14886 else
14887 ac_check_lib_save_LIBS=$LIBS
14888 LIBS="-lkrb4 $LIBS"
14889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14890 /* end confdefs.h. */
14891
14892 /* Override any GCC internal prototype to avoid an error.
14893 Use char because int might match the return type of a GCC
14894 builtin and then its argument prototype would still apply. */
14895 #ifdef __cplusplus
14896 extern "C"
14897 #endif
14898 char krb_get_cred ();
14899 int
14900 main ()
14901 {
14902 return krb_get_cred ();
14903 ;
14904 return 0;
14905 }
14906 _ACEOF
14907 if ac_fn_c_try_link "$LINENO"; then :
14908 ac_cv_lib_krb4_krb_get_cred=yes
14909 else
14910 ac_cv_lib_krb4_krb_get_cred=no
14911 fi
14912 rm -f core conftest.err conftest.$ac_objext \
14913 conftest$ac_exeext conftest.$ac_ext
14914 LIBS=$ac_check_lib_save_LIBS
14915 fi
14916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb4_krb_get_cred" >&5
14917 $as_echo "$ac_cv_lib_krb4_krb_get_cred" >&6; }
14918 if test "x$ac_cv_lib_krb4_krb_get_cred" = x""yes; then :
14919 have_krb4=yes
14920 else
14921 have_krb4=no
14922 fi
14923
14924 if test $have_krb4 = yes; then
14925 KRB4LIB=-lkrb4
14926 LIBS="$KRB4LIB $LIBS"
14927
14928 $as_echo "#define HAVE_LIBKRB4 1" >>confdefs.h
14929
14930 else
14931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for krb_get_cred in -lkrb" >&5
14932 $as_echo_n "checking for krb_get_cred in -lkrb... " >&6; }
14933 if test "${ac_cv_lib_krb_krb_get_cred+set}" = set; then :
14934 $as_echo_n "(cached) " >&6
14935 else
14936 ac_check_lib_save_LIBS=$LIBS
14937 LIBS="-lkrb $LIBS"
14938 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14939 /* end confdefs.h. */
14940
14941 /* Override any GCC internal prototype to avoid an error.
14942 Use char because int might match the return type of a GCC
14943 builtin and then its argument prototype would still apply. */
14944 #ifdef __cplusplus
14945 extern "C"
14946 #endif
14947 char krb_get_cred ();
14948 int
14949 main ()
14950 {
14951 return krb_get_cred ();
14952 ;
14953 return 0;
14954 }
14955 _ACEOF
14956 if ac_fn_c_try_link "$LINENO"; then :
14957 ac_cv_lib_krb_krb_get_cred=yes
14958 else
14959 ac_cv_lib_krb_krb_get_cred=no
14960 fi
14961 rm -f core conftest.err conftest.$ac_objext \
14962 conftest$ac_exeext conftest.$ac_ext
14963 LIBS=$ac_check_lib_save_LIBS
14964 fi
14965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_krb_krb_get_cred" >&5
14966 $as_echo "$ac_cv_lib_krb_krb_get_cred" >&6; }
14967 if test "x$ac_cv_lib_krb_krb_get_cred" = x""yes; then :
14968 have_krb=yes
14969 else
14970 have_krb=no
14971 fi
14972
14973 if test $have_krb = yes; then
14974 KRB4LIB=-lkrb
14975 LIBS="$KRB4LIB $LIBS"
14976
14977 $as_echo "#define HAVE_LIBKRB 1" >>confdefs.h
14978
14979 fi
14980 fi
14981 fi
14982
14983 if test "${with_kerberos5}" != no; then
14984 for ac_header in krb5.h
14985 do :
14986 ac_fn_c_check_header_mongrel "$LINENO" "krb5.h" "ac_cv_header_krb5_h" "$ac_includes_default"
14987 if test "x$ac_cv_header_krb5_h" = x""yes; then :
14988 cat >>confdefs.h <<_ACEOF
14989 #define HAVE_KRB5_H 1
14990 _ACEOF
14991 ac_fn_c_check_member "$LINENO" "krb5_error" "text" "ac_cv_member_krb5_error_text" "#include <krb5.h>
14992 "
14993 if test "x$ac_cv_member_krb5_error_text" = x""yes; then :
14994
14995 cat >>confdefs.h <<_ACEOF
14996 #define HAVE_KRB5_ERROR_TEXT 1
14997 _ACEOF
14998
14999
15000 fi
15001 ac_fn_c_check_member "$LINENO" "krb5_error" "e_text" "ac_cv_member_krb5_error_e_text" "#include <krb5.h>
15002 "
15003 if test "x$ac_cv_member_krb5_error_e_text" = x""yes; then :
15004
15005 cat >>confdefs.h <<_ACEOF
15006 #define HAVE_KRB5_ERROR_E_TEXT 1
15007 _ACEOF
15008
15009
15010 fi
15011
15012 fi
15013
15014 done
15015
15016 else
15017 for ac_header in des.h
15018 do :
15019 ac_fn_c_check_header_mongrel "$LINENO" "des.h" "ac_cv_header_des_h" "$ac_includes_default"
15020 if test "x$ac_cv_header_des_h" = x""yes; then :
15021 cat >>confdefs.h <<_ACEOF
15022 #define HAVE_DES_H 1
15023 _ACEOF
15024
15025 else
15026 for ac_header in kerberosIV/des.h
15027 do :
15028 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/des.h" "ac_cv_header_kerberosIV_des_h" "$ac_includes_default"
15029 if test "x$ac_cv_header_kerberosIV_des_h" = x""yes; then :
15030 cat >>confdefs.h <<_ACEOF
15031 #define HAVE_KERBEROSIV_DES_H 1
15032 _ACEOF
15033
15034 else
15035 for ac_header in kerberos/des.h
15036 do :
15037 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/des.h" "ac_cv_header_kerberos_des_h" "$ac_includes_default"
15038 if test "x$ac_cv_header_kerberos_des_h" = x""yes; then :
15039 cat >>confdefs.h <<_ACEOF
15040 #define HAVE_KERBEROS_DES_H 1
15041 _ACEOF
15042
15043 fi
15044
15045 done
15046
15047 fi
15048
15049 done
15050
15051 fi
15052
15053 done
15054
15055 for ac_header in krb.h
15056 do :
15057 ac_fn_c_check_header_mongrel "$LINENO" "krb.h" "ac_cv_header_krb_h" "$ac_includes_default"
15058 if test "x$ac_cv_header_krb_h" = x""yes; then :
15059 cat >>confdefs.h <<_ACEOF
15060 #define HAVE_KRB_H 1
15061 _ACEOF
15062
15063 else
15064 for ac_header in kerberosIV/krb.h
15065 do :
15066 ac_fn_c_check_header_mongrel "$LINENO" "kerberosIV/krb.h" "ac_cv_header_kerberosIV_krb_h" "$ac_includes_default"
15067 if test "x$ac_cv_header_kerberosIV_krb_h" = x""yes; then :
15068 cat >>confdefs.h <<_ACEOF
15069 #define HAVE_KERBEROSIV_KRB_H 1
15070 _ACEOF
15071
15072 else
15073 for ac_header in kerberos/krb.h
15074 do :
15075 ac_fn_c_check_header_mongrel "$LINENO" "kerberos/krb.h" "ac_cv_header_kerberos_krb_h" "$ac_includes_default"
15076 if test "x$ac_cv_header_kerberos_krb_h" = x""yes; then :
15077 cat >>confdefs.h <<_ACEOF
15078 #define HAVE_KERBEROS_KRB_H 1
15079 _ACEOF
15080
15081 fi
15082
15083 done
15084
15085 fi
15086
15087 done
15088
15089 fi
15090
15091 done
15092
15093 fi
15094 for ac_header in com_err.h
15095 do :
15096 ac_fn_c_check_header_mongrel "$LINENO" "com_err.h" "ac_cv_header_com_err_h" "$ac_includes_default"
15097 if test "x$ac_cv_header_com_err_h" = x""yes; then :
15098 cat >>confdefs.h <<_ACEOF
15099 #define HAVE_COM_ERR_H 1
15100 _ACEOF
15101
15102 fi
15103
15104 done
15105
15106 fi
15107
15108
15109
15110
15111
15112
15113
15114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime caches TZ" >&5
15115 $as_echo_n "checking whether localtime caches TZ... " >&6; }
15116 if test "${emacs_cv_localtime_cache+set}" = set; then :
15117 $as_echo_n "(cached) " >&6
15118 else
15119 if test x$ac_cv_func_tzset = xyes; then
15120 if test "$cross_compiling" = yes; then :
15121 # If we have tzset, assume the worst when cross-compiling.
15122 emacs_cv_localtime_cache=yes
15123 else
15124 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15125 /* end confdefs.h. */
15126 #include <time.h>
15127 char TZ_GMT0[] = "TZ=GMT0";
15128 char TZ_PST8[] = "TZ=PST8";
15129 main()
15130 {
15131 time_t now = time ((time_t *) 0);
15132 int hour_GMT0, hour_unset;
15133 if (putenv (TZ_GMT0) != 0)
15134 exit (1);
15135 hour_GMT0 = localtime (&now)->tm_hour;
15136 unsetenv("TZ");
15137 hour_unset = localtime (&now)->tm_hour;
15138 if (putenv (TZ_PST8) != 0)
15139 exit (1);
15140 if (localtime (&now)->tm_hour == hour_GMT0)
15141 exit (1);
15142 unsetenv("TZ");
15143 if (localtime (&now)->tm_hour != hour_unset)
15144 exit (1);
15145 exit (0);
15146 }
15147 _ACEOF
15148 if ac_fn_c_try_run "$LINENO"; then :
15149 emacs_cv_localtime_cache=no
15150 else
15151 emacs_cv_localtime_cache=yes
15152 fi
15153 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15154 conftest.$ac_objext conftest.beam conftest.$ac_ext
15155 fi
15156
15157 else
15158 # If we lack tzset, report that localtime does not cache TZ,
15159 # since we can't invalidate the cache if we don't have tzset.
15160 emacs_cv_localtime_cache=no
15161 fi
15162 fi
15163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_localtime_cache" >&5
15164 $as_echo "$emacs_cv_localtime_cache" >&6; }
15165 if test $emacs_cv_localtime_cache = yes; then
15166
15167 $as_echo "#define LOCALTIME_CACHE 1" >>confdefs.h
15168
15169 fi
15170
15171 if test "x$HAVE_TIMEVAL" = xyes; then
15172 for ac_func in gettimeofday
15173 do :
15174 ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
15175 if test "x$ac_cv_func_gettimeofday" = x""yes; then :
15176 cat >>confdefs.h <<_ACEOF
15177 #define HAVE_GETTIMEOFDAY 1
15178 _ACEOF
15179
15180 fi
15181 done
15182
15183 if test $ac_cv_func_gettimeofday = yes; then
15184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether gettimeofday can accept two arguments" >&5
15185 $as_echo_n "checking whether gettimeofday can accept two arguments... " >&6; }
15186 if test "${emacs_cv_gettimeofday_two_arguments+set}" = set; then :
15187 $as_echo_n "(cached) " >&6
15188 else
15189 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15190 /* end confdefs.h. */
15191
15192 #ifdef TIME_WITH_SYS_TIME
15193 #include <sys/time.h>
15194 #include <time.h>
15195 #else
15196 #ifdef HAVE_SYS_TIME_H
15197 #include <sys/time.h>
15198 #else
15199 #include <time.h>
15200 #endif
15201 #endif
15202 int
15203 main ()
15204 {
15205 struct timeval time;
15206 gettimeofday (&time, 0);
15207 ;
15208 return 0;
15209 }
15210 _ACEOF
15211 if ac_fn_c_try_compile "$LINENO"; then :
15212 emacs_cv_gettimeofday_two_arguments=yes
15213 else
15214 emacs_cv_gettimeofday_two_arguments=no
15215 fi
15216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15217 fi
15218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_gettimeofday_two_arguments" >&5
15219 $as_echo "$emacs_cv_gettimeofday_two_arguments" >&6; }
15220 if test $emacs_cv_gettimeofday_two_arguments = no; then
15221
15222 $as_echo "#define GETTIMEOFDAY_ONE_ARGUMENT 1" >>confdefs.h
15223
15224 fi
15225 fi
15226 fi
15227
15228 ok_so_far=yes
15229 ac_fn_c_check_func "$LINENO" "socket" "ac_cv_func_socket"
15230 if test "x$ac_cv_func_socket" = x""yes; then :
15231
15232 else
15233 ok_so_far=no
15234 fi
15235
15236 if test $ok_so_far = yes; then
15237 ac_fn_c_check_header_mongrel "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
15238 if test "x$ac_cv_header_netinet_in_h" = x""yes; then :
15239
15240 else
15241 ok_so_far=no
15242 fi
15243
15244
15245 fi
15246 if test $ok_so_far = yes; then
15247 ac_fn_c_check_header_mongrel "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
15248 if test "x$ac_cv_header_arpa_inet_h" = x""yes; then :
15249
15250 else
15251 ok_so_far=no
15252 fi
15253
15254
15255 fi
15256 if test $ok_so_far = yes; then
15257
15258 $as_echo "#define HAVE_INET_SOCKETS 1" >>confdefs.h
15259
15260 fi
15261
15262 if test -f /usr/lpp/X11/bin/smt.exp; then
15263
15264 $as_echo "#define HAVE_AIX_SMT_EXP 1" >>confdefs.h
15265
15266 fi
15267
15268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports dynamic ptys" >&5
15269 $as_echo_n "checking whether system supports dynamic ptys... " >&6; }
15270 if test -d /dev/pts && ls -d /dev/ptmx > /dev/null 2>&1 ; then
15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15272 $as_echo "yes" >&6; }
15273
15274 $as_echo "#define HAVE_DEV_PTMX 1" >>confdefs.h
15275
15276 else
15277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15278 $as_echo "no" >&6; }
15279 fi
15280
15281 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default"
15282 if test "x$ac_cv_type_pid_t" = x""yes; then :
15283
15284 else
15285
15286 cat >>confdefs.h <<_ACEOF
15287 #define pid_t int
15288 _ACEOF
15289
15290 fi
15291
15292 for ac_header in vfork.h
15293 do :
15294 ac_fn_c_check_header_mongrel "$LINENO" "vfork.h" "ac_cv_header_vfork_h" "$ac_includes_default"
15295 if test "x$ac_cv_header_vfork_h" = x""yes; then :
15296 cat >>confdefs.h <<_ACEOF
15297 #define HAVE_VFORK_H 1
15298 _ACEOF
15299
15300 fi
15301
15302 done
15303
15304 for ac_func in fork vfork
15305 do :
15306 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
15307 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
15308 eval as_val=\$$as_ac_var
15309 if test "x$as_val" = x""yes; then :
15310 cat >>confdefs.h <<_ACEOF
15311 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
15312 _ACEOF
15313
15314 fi
15315 done
15316
15317 if test "x$ac_cv_func_fork" = xyes; then
15318 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5
15319 $as_echo_n "checking for working fork... " >&6; }
15320 if test "${ac_cv_func_fork_works+set}" = set; then :
15321 $as_echo_n "(cached) " >&6
15322 else
15323 if test "$cross_compiling" = yes; then :
15324 ac_cv_func_fork_works=cross
15325 else
15326 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15327 /* end confdefs.h. */
15328 $ac_includes_default
15329 int
15330 main ()
15331 {
15332
15333 /* By Ruediger Kuhlmann. */
15334 return fork () < 0;
15335
15336 ;
15337 return 0;
15338 }
15339 _ACEOF
15340 if ac_fn_c_try_run "$LINENO"; then :
15341 ac_cv_func_fork_works=yes
15342 else
15343 ac_cv_func_fork_works=no
15344 fi
15345 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15346 conftest.$ac_objext conftest.beam conftest.$ac_ext
15347 fi
15348
15349 fi
15350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5
15351 $as_echo "$ac_cv_func_fork_works" >&6; }
15352
15353 else
15354 ac_cv_func_fork_works=$ac_cv_func_fork
15355 fi
15356 if test "x$ac_cv_func_fork_works" = xcross; then
15357 case $host in
15358 *-*-amigaos* | *-*-msdosdjgpp*)
15359 # Override, as these systems have only a dummy fork() stub
15360 ac_cv_func_fork_works=no
15361 ;;
15362 *)
15363 ac_cv_func_fork_works=yes
15364 ;;
15365 esac
15366 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5
15367 $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;}
15368 fi
15369 ac_cv_func_vfork_works=$ac_cv_func_vfork
15370 if test "x$ac_cv_func_vfork" = xyes; then
15371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5
15372 $as_echo_n "checking for working vfork... " >&6; }
15373 if test "${ac_cv_func_vfork_works+set}" = set; then :
15374 $as_echo_n "(cached) " >&6
15375 else
15376 if test "$cross_compiling" = yes; then :
15377 ac_cv_func_vfork_works=cross
15378 else
15379 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15380 /* end confdefs.h. */
15381 /* Thanks to Paul Eggert for this test. */
15382 $ac_includes_default
15383 #include <sys/wait.h>
15384 #ifdef HAVE_VFORK_H
15385 # include <vfork.h>
15386 #endif
15387 /* On some sparc systems, changes by the child to local and incoming
15388 argument registers are propagated back to the parent. The compiler
15389 is told about this with #include <vfork.h>, but some compilers
15390 (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a
15391 static variable whose address is put into a register that is
15392 clobbered by the vfork. */
15393 static void
15394 #ifdef __cplusplus
15395 sparc_address_test (int arg)
15396 # else
15397 sparc_address_test (arg) int arg;
15398 #endif
15399 {
15400 static pid_t child;
15401 if (!child) {
15402 child = vfork ();
15403 if (child < 0) {
15404 perror ("vfork");
15405 _exit(2);
15406 }
15407 if (!child) {
15408 arg = getpid();
15409 write(-1, "", 0);
15410 _exit (arg);
15411 }
15412 }
15413 }
15414
15415 int
15416 main ()
15417 {
15418 pid_t parent = getpid ();
15419 pid_t child;
15420
15421 sparc_address_test (0);
15422
15423 child = vfork ();
15424
15425 if (child == 0) {
15426 /* Here is another test for sparc vfork register problems. This
15427 test uses lots of local variables, at least as many local
15428 variables as main has allocated so far including compiler
15429 temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris
15430 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should
15431 reuse the register of parent for one of the local variables,
15432 since it will think that parent can't possibly be used any more
15433 in this routine. Assigning to the local variable will thus
15434 munge parent in the parent process. */
15435 pid_t
15436 p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
15437 p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
15438 /* Convince the compiler that p..p7 are live; otherwise, it might
15439 use the same hardware register for all 8 local variables. */
15440 if (p != p1 || p != p2 || p != p3 || p != p4
15441 || p != p5 || p != p6 || p != p7)
15442 _exit(1);
15443
15444 /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent
15445 from child file descriptors. If the child closes a descriptor
15446 before it execs or exits, this munges the parent's descriptor
15447 as well. Test for this by closing stdout in the child. */
15448 _exit(close(fileno(stdout)) != 0);
15449 } else {
15450 int status;
15451 struct stat st;
15452
15453 while (wait(&status) != child)
15454 ;
15455 return (
15456 /* Was there some problem with vforking? */
15457 child < 0
15458
15459 /* Did the child fail? (This shouldn't happen.) */
15460 || status
15461
15462 /* Did the vfork/compiler bug occur? */
15463 || parent != getpid()
15464
15465 /* Did the file descriptor bug occur? */
15466 || fstat(fileno(stdout), &st) != 0
15467 );
15468 }
15469 }
15470 _ACEOF
15471 if ac_fn_c_try_run "$LINENO"; then :
15472 ac_cv_func_vfork_works=yes
15473 else
15474 ac_cv_func_vfork_works=no
15475 fi
15476 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15477 conftest.$ac_objext conftest.beam conftest.$ac_ext
15478 fi
15479
15480 fi
15481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5
15482 $as_echo "$ac_cv_func_vfork_works" >&6; }
15483
15484 fi;
15485 if test "x$ac_cv_func_fork_works" = xcross; then
15486 ac_cv_func_vfork_works=$ac_cv_func_vfork
15487 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5
15488 $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;}
15489 fi
15490
15491 if test "x$ac_cv_func_vfork_works" = xyes; then
15492
15493 $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h
15494
15495 else
15496
15497 $as_echo "#define vfork fork" >>confdefs.h
15498
15499 fi
15500 if test "x$ac_cv_func_fork_works" = xyes; then
15501
15502 $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h
15503
15504 fi
15505
15506
15507 for ac_func in snprintf
15508 do :
15509 ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
15510 if test "x$ac_cv_func_snprintf" = x""yes; then :
15511 cat >>confdefs.h <<_ACEOF
15512 #define HAVE_SNPRINTF 1
15513 _ACEOF
15514
15515 fi
15516 done
15517
15518
15519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
15520 $as_echo_n "checking for nl_langinfo and CODESET... " >&6; }
15521 if test "${emacs_cv_langinfo_codeset+set}" = set; then :
15522 $as_echo_n "(cached) " >&6
15523 else
15524 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15525 /* end confdefs.h. */
15526 #include <langinfo.h>
15527 int
15528 main ()
15529 {
15530 char* cs = nl_langinfo(CODESET);
15531 ;
15532 return 0;
15533 }
15534 _ACEOF
15535 if ac_fn_c_try_link "$LINENO"; then :
15536 emacs_cv_langinfo_codeset=yes
15537 else
15538 emacs_cv_langinfo_codeset=no
15539 fi
15540 rm -f core conftest.err conftest.$ac_objext \
15541 conftest$ac_exeext conftest.$ac_ext
15542
15543 fi
15544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_langinfo_codeset" >&5
15545 $as_echo "$emacs_cv_langinfo_codeset" >&6; }
15546 if test $emacs_cv_langinfo_codeset = yes; then
15547
15548 $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
15549
15550 fi
15551
15552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mbstate_t" >&5
15553 $as_echo_n "checking for mbstate_t... " >&6; }
15554 if test "${ac_cv_type_mbstate_t+set}" = set; then :
15555 $as_echo_n "(cached) " >&6
15556 else
15557 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15558 /* end confdefs.h. */
15559 $ac_includes_default
15560 # include <wchar.h>
15561 int
15562 main ()
15563 {
15564 mbstate_t x; return sizeof x;
15565 ;
15566 return 0;
15567 }
15568 _ACEOF
15569 if ac_fn_c_try_compile "$LINENO"; then :
15570 ac_cv_type_mbstate_t=yes
15571 else
15572 ac_cv_type_mbstate_t=no
15573 fi
15574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15575 fi
15576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_mbstate_t" >&5
15577 $as_echo "$ac_cv_type_mbstate_t" >&6; }
15578 if test $ac_cv_type_mbstate_t = yes; then
15579
15580 $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h
15581
15582 else
15583
15584 $as_echo "#define mbstate_t int" >>confdefs.h
15585
15586 fi
15587
15588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C restricted array declarations" >&5
15589 $as_echo_n "checking for C restricted array declarations... " >&6; }
15590 if test "${emacs_cv_c_restrict_arr+set}" = set; then :
15591 $as_echo_n "(cached) " >&6
15592 else
15593 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15594 /* end confdefs.h. */
15595 void fred (int x[__restrict]);
15596 int
15597 main ()
15598 {
15599
15600 ;
15601 return 0;
15602 }
15603 _ACEOF
15604 if ac_fn_c_try_compile "$LINENO"; then :
15605 emacs_cv_c_restrict_arr=yes
15606 else
15607 emacs_cv_c_restrict_arr=no
15608 fi
15609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15610 fi
15611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $emacs_cv_c_restrict_arr" >&5
15612 $as_echo "$emacs_cv_c_restrict_arr" >&6; }
15613 if test "$emacs_cv_c_restrict_arr" = yes; then
15614
15615 $as_echo "#define __restrict_arr __restrict" >>confdefs.h
15616
15617 fi
15618
15619
15620 # Set up the CFLAGS for real compilation, so we can substitute it.
15621 CFLAGS="$REAL_CFLAGS"
15622 CPPFLAGS="$REAL_CPPFLAGS"
15623
15624 ## Hack to detect a buggy GCC version.
15625 if test "x$GCC" = xyes \
15626 && test x"`$CC --version 2> /dev/null | grep 'gcc.* 4.5.0'`" != x \
15627 && test x"`echo $CFLAGS | grep '\-O[23]'`" != x \
15628 && test x"`echo $CFLAGS | grep '\-fno-optimize-sibling-calls'`" = x; then
15629 as_fn_error "GCC 4.5.0 has problems compiling Emacs; see etc/PROBLEMS'." "$LINENO" 5
15630 fi
15631
15632 version=$PACKAGE_VERSION
15633
15634 ### Specify what sort of things we'll be editing into Makefile and config.h.
15635 ### Use configuration here uncanonicalized to avoid exceeding size limits.
15636
15637
15638 ## Unused?
15639
15640
15641
15642
15643
15644
15645
15646
15647
15648
15649
15650
15651
15652
15653
15654
15655
15656
15657
15658
15659 ## FIXME? Nothing uses @LD_SWITCH_X_SITE@.
15660 ## src/Makefile.in did add LD_SWITCH_X_SITE (as a cpp define) to the
15661 ## end of LIBX_BASE, but nothing ever set it.
15662
15663
15664
15665
15666 ## Used in lwlib/Makefile.in.
15667
15668 if test -n "${machfile}"; then
15669 M_FILE="\$(srcdir)/${machfile}"
15670 else
15671 M_FILE=
15672 fi
15673 S_FILE="\$(srcdir)/${opsysfile}"
15674
15675
15676
15677
15678
15679
15680
15681
15682
15683
15684 cat >>confdefs.h <<_ACEOF
15685 #define EMACS_CONFIGURATION "${canonical}"
15686 _ACEOF
15687
15688
15689 cat >>confdefs.h <<_ACEOF
15690 #define EMACS_CONFIG_OPTIONS "${ac_configure_args}"
15691 _ACEOF
15692
15693 if test -n "$machfile"; then
15694
15695 cat >>confdefs.h <<_ACEOF
15696 #define config_machfile "${machfile}"
15697 _ACEOF
15698
15699 fi
15700
15701 cat >>confdefs.h <<_ACEOF
15702 #define config_opsysfile "${opsysfile}"
15703 _ACEOF
15704
15705
15706 XMENU_OBJ=
15707 XOBJ=
15708 FONT_OBJ=
15709 if test "${HAVE_X_WINDOWS}" = "yes" ; then
15710
15711 $as_echo "#define HAVE_X_WINDOWS 1" >>confdefs.h
15712
15713 XMENU_OBJ=xmenu.o
15714 XOBJ="xterm.o xfns.o xselect.o xrdb.o fontset.o xsmfns.o fringe.o image.o xsettings.o xgselect.o"
15715 FONT_OBJ=xfont.o
15716 if test "$HAVE_XFT" = "yes"; then
15717 FONT_OBJ="$FONT_OBJ ftfont.o xftfont.o ftxfont.o"
15718 elif test "$HAVE_FREETYPE" = "yes"; then
15719 FONT_OBJ="$FONT_OBJ ftfont.o ftxfont.o"
15720 fi
15721
15722 fi
15723
15724
15725
15726
15727 WIDGET_OBJ=
15728 MOTIF_LIBW=
15729 if test "${USE_X_TOOLKIT}" != "none" ; then
15730 WIDGET_OBJ=widget.o
15731
15732 $as_echo "#define USE_X_TOOLKIT 1" >>confdefs.h
15733
15734 if test "${USE_X_TOOLKIT}" = "LUCID"; then
15735
15736 $as_echo "#define USE_LUCID 1" >>confdefs.h
15737
15738 elif test "${USE_X_TOOLKIT}" = "MOTIF"; then
15739
15740 $as_echo "#define USE_MOTIF 1" >>confdefs.h
15741
15742 MOTIF_LIBW=-lXm
15743 case "$opsys" in
15744 gnu-linux)
15745 ## Paul Abrahams <abrahams at equinox.shaysnet.com> says this is needed.
15746 MOTIF_LIBW="$MOTIF_LIBW -lXpm"
15747 ;;
15748
15749 unixware)
15750 ## Richard Anthony Ryan <ryanr at ellingtn.ftc.nrcs.usda.gov>
15751 ## says -lXimp is needed in UNIX_SV ... 4.2 1.1.2.
15752 MOTIF_LIBW="MOTIF_LIBW -lXimp"
15753 ;;
15754
15755 aix4-2)
15756 ## olson@mcs.anl.gov says -li18n is needed by -lXm.
15757 MOTIF_LIBW="$MOTIF_LIBW -li18n"
15758 ;;
15759 esac
15760 MOTIF_LIBW="$MOTIF_LIBW $LIBXP"
15761 fi
15762 fi
15763
15764
15765 TOOLKIT_LIBW=
15766 case "$USE_X_TOOLKIT" in
15767 MOTIF) TOOLKIT_LIBW="$MOTIF_LIBW" ;;
15768 LUCID) TOOLKIT_LIBW="$LUCID_LIBW" ;;
15769 none) test "x$HAVE_GTK" = "xyes" && TOOLKIT_LIBW="$GTK_LIBS" ;;
15770 esac
15771
15772
15773 if test "$USE_X_TOOLKIT" = "none"; then
15774 LIBXT_OTHER="\$(LIBXSM)"
15775 OLDXMENU_TARGET="really-oldXMenu"
15776 else
15777 LIBXT_OTHER="\$(LIBXMU) -lXt \$(LIBXTR6) -lXext"
15778 OLDXMENU_TARGET="really-lwlib"
15779 fi
15780
15781
15782 ## The X Menu stuff is present in the X10 distribution, but missing
15783 ## from X11. If we have X10, just use the installed library;
15784 ## otherwise, use our own copy.
15785 if test "${HAVE_X11}" = "yes" ; then
15786
15787 $as_echo "#define HAVE_X11 1" >>confdefs.h
15788
15789
15790 if test "$USE_X_TOOLKIT" = "none"; then
15791 OLDXMENU="\${oldXMenudir}/libXMenu11.a"
15792 else
15793 OLDXMENU="\${lwlibdir}/liblw.a"
15794 fi
15795 LIBXMENU="\$(OLDXMENU)"
15796 LIBX_OTHER="\$(LIBXT) \$(LIBX_EXTRA)"
15797 OLDXMENU_DEPS="\${OLDXMENU} ../src/\${OLDXMENU}"
15798 else
15799 ## For a syntactically valid Makefile; not actually used for anything.
15800 ## See comments in src/Makefile.in.
15801 OLDXMENU=nothing
15802 ## FIXME This case (!HAVE_X11 && HAVE_X_WINDOWS) is no longer possible(?).
15803 if test "${HAVE_X_WINDOWS}" = "yes"; then
15804 LIBXMENU="-lXMenu"
15805 else
15806 LIBXMENU=
15807 fi
15808 LIBX_OTHER=
15809 OLDXMENU_DEPS=
15810 fi
15811
15812 if test "$HAVE_GTK" = "yes" || test "$HAVE_MENUS" != "yes"; then
15813 OLDXMENU_TARGET=
15814 OLDXMENU=nothing
15815 LIBXMENU=
15816 OLDXMENU_DEPS=
15817 fi
15818
15819
15820
15821
15822
15823
15824
15825 if test "${HAVE_MENUS}" = "yes" ; then
15826
15827 $as_echo "#define HAVE_MENUS 1" >>confdefs.h
15828
15829 fi
15830
15831 if test "${GNU_MALLOC}" = "yes" ; then
15832
15833 $as_echo "#define GNU_MALLOC 1" >>confdefs.h
15834
15835 fi
15836
15837 RALLOC_OBJ=
15838 if test "${REL_ALLOC}" = "yes" ; then
15839
15840 $as_echo "#define REL_ALLOC 1" >>confdefs.h
15841
15842
15843 test "$system_malloc" != "yes" && RALLOC_OBJ=ralloc.o
15844 fi
15845
15846
15847 if test "$opsys" = "cygwin"; then
15848 CYGWIN_OBJ="sheap.o"
15849 ## Cygwin differs because of its unexec().
15850 PRE_ALLOC_OBJ=
15851 POST_ALLOC_OBJ=lastfile.o
15852 else
15853 CYGWIN_OBJ=
15854 PRE_ALLOC_OBJ=lastfile.o
15855 POST_ALLOC_OBJ=
15856 fi
15857
15858
15859
15860
15861 # Configure gnulib here, now that we know LIBS.
15862
15863
15864
15865
15866
15867
15868
15869
15870
15871
15872
15873 LIBC_FATAL_STDERR_=1
15874 export LIBC_FATAL_STDERR_
15875
15876 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15877 # for constant arguments. Useless!
15878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15879 $as_echo_n "checking for working alloca.h... " >&6; }
15880 if test "${ac_cv_working_alloca_h+set}" = set; then :
15881 $as_echo_n "(cached) " >&6
15882 else
15883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15884 /* end confdefs.h. */
15885 #include <alloca.h>
15886 int
15887 main ()
15888 {
15889 char *p = (char *) alloca (2 * sizeof (int));
15890 if (p) return 0;
15891 ;
15892 return 0;
15893 }
15894 _ACEOF
15895 if ac_fn_c_try_link "$LINENO"; then :
15896 ac_cv_working_alloca_h=yes
15897 else
15898 ac_cv_working_alloca_h=no
15899 fi
15900 rm -f core conftest.err conftest.$ac_objext \
15901 conftest$ac_exeext conftest.$ac_ext
15902 fi
15903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
15904 $as_echo "$ac_cv_working_alloca_h" >&6; }
15905 if test $ac_cv_working_alloca_h = yes; then
15906
15907 $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h
15908
15909 fi
15910
15911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
15912 $as_echo_n "checking for alloca... " >&6; }
15913 if test "${ac_cv_func_alloca_works+set}" = set; then :
15914 $as_echo_n "(cached) " >&6
15915 else
15916 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15917 /* end confdefs.h. */
15918 #ifdef __GNUC__
15919 # define alloca __builtin_alloca
15920 #else
15921 # ifdef _MSC_VER
15922 # include <malloc.h>
15923 # define alloca _alloca
15924 # else
15925 # ifdef HAVE_ALLOCA_H
15926 # include <alloca.h>
15927 # else
15928 # ifdef _AIX
15929 #pragma alloca
15930 # else
15931 # ifndef alloca /* predefined by HP cc +Olibcalls */
15932 char *alloca ();
15933 # endif
15934 # endif
15935 # endif
15936 # endif
15937 #endif
15938
15939 int
15940 main ()
15941 {
15942 char *p = (char *) alloca (1);
15943 if (p) return 0;
15944 ;
15945 return 0;
15946 }
15947 _ACEOF
15948 if ac_fn_c_try_link "$LINENO"; then :
15949 ac_cv_func_alloca_works=yes
15950 else
15951 ac_cv_func_alloca_works=no
15952 fi
15953 rm -f core conftest.err conftest.$ac_objext \
15954 conftest$ac_exeext conftest.$ac_ext
15955 fi
15956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
15957 $as_echo "$ac_cv_func_alloca_works" >&6; }
15958
15959 if test $ac_cv_func_alloca_works = yes; then
15960
15961 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
15962
15963 else
15964 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
15965 # that cause trouble. Some versions do not even contain alloca or
15966 # contain a buggy version. If you still want to use their alloca,
15967 # use ar to extract alloca.o from them instead of compiling alloca.c.
15968
15969
15970
15971
15972
15973 ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
15974
15975 $as_echo "#define C_ALLOCA 1" >>confdefs.h
15976
15977
15978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5
15979 $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; }
15980 if test "${ac_cv_os_cray+set}" = set; then :
15981 $as_echo_n "(cached) " >&6
15982 else
15983 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15984 /* end confdefs.h. */
15985 #if defined CRAY && ! defined CRAY2
15986 webecray
15987 #else
15988 wenotbecray
15989 #endif
15990
15991 _ACEOF
15992 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15993 $EGREP "webecray" >/dev/null 2>&1; then :
15994 ac_cv_os_cray=yes
15995 else
15996 ac_cv_os_cray=no
15997 fi
15998 rm -f conftest*
15999
16000 fi
16001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5
16002 $as_echo "$ac_cv_os_cray" >&6; }
16003 if test $ac_cv_os_cray = yes; then
16004 for ac_func in _getb67 GETB67 getb67; do
16005 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16006 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16007 eval as_val=\$$as_ac_var
16008 if test "x$as_val" = x""yes; then :
16009
16010 cat >>confdefs.h <<_ACEOF
16011 #define CRAY_STACKSEG_END $ac_func
16012 _ACEOF
16013
16014 break
16015 fi
16016
16017 done
16018 fi
16019
16020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
16021 $as_echo_n "checking stack direction for C alloca... " >&6; }
16022 if test "${ac_cv_c_stack_direction+set}" = set; then :
16023 $as_echo_n "(cached) " >&6
16024 else
16025 if test "$cross_compiling" = yes; then :
16026 ac_cv_c_stack_direction=0
16027 else
16028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16029 /* end confdefs.h. */
16030 $ac_includes_default
16031 int
16032 find_stack_direction (int *addr, int depth)
16033 {
16034 int dir, dummy = 0;
16035 if (! addr)
16036 addr = &dummy;
16037 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
16038 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
16039 return dir + dummy;
16040 }
16041
16042 int
16043 main (int argc, char **argv)
16044 {
16045 return find_stack_direction (0, argc + !argv + 20) < 0;
16046 }
16047 _ACEOF
16048 if ac_fn_c_try_run "$LINENO"; then :
16049 ac_cv_c_stack_direction=1
16050 else
16051 ac_cv_c_stack_direction=-1
16052 fi
16053 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16054 conftest.$ac_objext conftest.beam conftest.$ac_ext
16055 fi
16056
16057 fi
16058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
16059 $as_echo "$ac_cv_c_stack_direction" >&6; }
16060 cat >>confdefs.h <<_ACEOF
16061 #define STACK_DIRECTION $ac_cv_c_stack_direction
16062 _ACEOF
16063
16064
16065 fi
16066
16067
16068
16069
16070 for ac_func in $ac_func_list
16071 do :
16072 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
16073 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
16074 eval as_val=\$$as_ac_var
16075 if test "x$as_val" = x""yes; then :
16076 cat >>confdefs.h <<_ACEOF
16077 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
16078 _ACEOF
16079
16080 fi
16081 done
16082
16083
16084
16085
16086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
16087 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
16088 if test "${ac_cv_c_bigendian+set}" = set; then :
16089 $as_echo_n "(cached) " >&6
16090 else
16091 ac_cv_c_bigendian=unknown
16092 # See if we're dealing with a universal compiler.
16093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16094 /* end confdefs.h. */
16095 #ifndef __APPLE_CC__
16096 not a universal capable compiler
16097 #endif
16098 typedef int dummy;
16099
16100 _ACEOF
16101 if ac_fn_c_try_compile "$LINENO"; then :
16102
16103 # Check for potential -arch flags. It is not universal unless
16104 # there are at least two -arch flags with different values.
16105 ac_arch=
16106 ac_prev=
16107 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
16108 if test -n "$ac_prev"; then
16109 case $ac_word in
16110 i?86 | x86_64 | ppc | ppc64)
16111 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
16112 ac_arch=$ac_word
16113 else
16114 ac_cv_c_bigendian=universal
16115 break
16116 fi
16117 ;;
16118 esac
16119 ac_prev=
16120 elif test "x$ac_word" = "x-arch"; then
16121 ac_prev=arch
16122 fi
16123 done
16124 fi
16125 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16126 if test $ac_cv_c_bigendian = unknown; then
16127 # See if sys/param.h defines the BYTE_ORDER macro.
16128 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16129 /* end confdefs.h. */
16130 #include <sys/types.h>
16131 #include <sys/param.h>
16132
16133 int
16134 main ()
16135 {
16136 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
16137 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
16138 && LITTLE_ENDIAN)
16139 bogus endian macros
16140 #endif
16141
16142 ;
16143 return 0;
16144 }
16145 _ACEOF
16146 if ac_fn_c_try_compile "$LINENO"; then :
16147 # It does; now see whether it defined to BIG_ENDIAN or not.
16148 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16149 /* end confdefs.h. */
16150 #include <sys/types.h>
16151 #include <sys/param.h>
16152
16153 int
16154 main ()
16155 {
16156 #if BYTE_ORDER != BIG_ENDIAN
16157 not big endian
16158 #endif
16159
16160 ;
16161 return 0;
16162 }
16163 _ACEOF
16164 if ac_fn_c_try_compile "$LINENO"; then :
16165 ac_cv_c_bigendian=yes
16166 else
16167 ac_cv_c_bigendian=no
16168 fi
16169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16170 fi
16171 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16172 fi
16173 if test $ac_cv_c_bigendian = unknown; then
16174 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
16175 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16176 /* end confdefs.h. */
16177 #include <limits.h>
16178
16179 int
16180 main ()
16181 {
16182 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
16183 bogus endian macros
16184 #endif
16185
16186 ;
16187 return 0;
16188 }
16189 _ACEOF
16190 if ac_fn_c_try_compile "$LINENO"; then :
16191 # It does; now see whether it defined to _BIG_ENDIAN or not.
16192 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16193 /* end confdefs.h. */
16194 #include <limits.h>
16195
16196 int
16197 main ()
16198 {
16199 #ifndef _BIG_ENDIAN
16200 not big endian
16201 #endif
16202
16203 ;
16204 return 0;
16205 }
16206 _ACEOF
16207 if ac_fn_c_try_compile "$LINENO"; then :
16208 ac_cv_c_bigendian=yes
16209 else
16210 ac_cv_c_bigendian=no
16211 fi
16212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16213 fi
16214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16215 fi
16216 if test $ac_cv_c_bigendian = unknown; then
16217 # Compile a test program.
16218 if test "$cross_compiling" = yes; then :
16219 # Try to guess by grepping values from an object file.
16220 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16221 /* end confdefs.h. */
16222 short int ascii_mm[] =
16223 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
16224 short int ascii_ii[] =
16225 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
16226 int use_ascii (int i) {
16227 return ascii_mm[i] + ascii_ii[i];
16228 }
16229 short int ebcdic_ii[] =
16230 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
16231 short int ebcdic_mm[] =
16232 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
16233 int use_ebcdic (int i) {
16234 return ebcdic_mm[i] + ebcdic_ii[i];
16235 }
16236 extern int foo;
16237
16238 int
16239 main ()
16240 {
16241 return use_ascii (foo) == use_ebcdic (foo);
16242 ;
16243 return 0;
16244 }
16245 _ACEOF
16246 if ac_fn_c_try_compile "$LINENO"; then :
16247 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
16248 ac_cv_c_bigendian=yes
16249 fi
16250 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
16251 if test "$ac_cv_c_bigendian" = unknown; then
16252 ac_cv_c_bigendian=no
16253 else
16254 # finding both strings is unlikely to happen, but who knows?
16255 ac_cv_c_bigendian=unknown
16256 fi
16257 fi
16258 fi
16259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16260 else
16261 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16262 /* end confdefs.h. */
16263 $ac_includes_default
16264 int
16265 main ()
16266 {
16267
16268 /* Are we little or big endian? From Harbison&Steele. */
16269 union
16270 {
16271 long int l;
16272 char c[sizeof (long int)];
16273 } u;
16274 u.l = 1;
16275 return u.c[sizeof (long int) - 1] == 1;
16276
16277 ;
16278 return 0;
16279 }
16280 _ACEOF
16281 if ac_fn_c_try_run "$LINENO"; then :
16282 ac_cv_c_bigendian=no
16283 else
16284 ac_cv_c_bigendian=yes
16285 fi
16286 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16287 conftest.$ac_objext conftest.beam conftest.$ac_ext
16288 fi
16289
16290 fi
16291 fi
16292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
16293 $as_echo "$ac_cv_c_bigendian" >&6; }
16294 case $ac_cv_c_bigendian in #(
16295 yes)
16296 $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
16297 ;; #(
16298 no)
16299 ;; #(
16300 universal)
16301
16302 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
16303
16304 ;; #(
16305 *)
16306 as_fn_error "unknown endianness
16307 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
16308 esac
16309
16310
16311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
16312 $as_echo_n "checking for inline... " >&6; }
16313 if test "${ac_cv_c_inline+set}" = set; then :
16314 $as_echo_n "(cached) " >&6
16315 else
16316 ac_cv_c_inline=no
16317 for ac_kw in inline __inline__ __inline; do
16318 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16319 /* end confdefs.h. */
16320 #ifndef __cplusplus
16321 typedef int foo_t;
16322 static $ac_kw foo_t static_foo () {return 0; }
16323 $ac_kw foo_t foo () {return 0; }
16324 #endif
16325
16326 _ACEOF
16327 if ac_fn_c_try_compile "$LINENO"; then :
16328 ac_cv_c_inline=$ac_kw
16329 fi
16330 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16331 test "$ac_cv_c_inline" != no && break
16332 done
16333
16334 fi
16335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
16336 $as_echo "$ac_cv_c_inline" >&6; }
16337
16338 case $ac_cv_c_inline in
16339 inline | yes) ;;
16340 *)
16341 case $ac_cv_c_inline in
16342 no) ac_val=;;
16343 *) ac_val=$ac_cv_c_inline;;
16344 esac
16345 cat >>confdefs.h <<_ACEOF
16346 #ifndef __cplusplus
16347 #define inline $ac_val
16348 #endif
16349 _ACEOF
16350 ;;
16351 esac
16352
16353
16354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether strtold conforms to C99" >&5
16355 $as_echo_n "checking whether strtold conforms to C99... " >&6; }
16356 if test "${gl_cv_func_c99_strtold+set}" = set; then :
16357 $as_echo_n "(cached) " >&6
16358 else
16359 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16360 /* end confdefs.h. */
16361 /* On HP-UX before 11.23, strtold returns a struct instead of
16362 long double. Reject implementations like that, by requiring
16363 compatibility with the C99 prototype. */
16364 #include <stdlib.h>
16365 static long double (*p) (char const *, char **) = strtold;
16366 static long double
16367 test (char const *nptr, char **endptr)
16368 {
16369 long double r;
16370 r = strtold (nptr, endptr);
16371 return r;
16372 }
16373 int
16374 main ()
16375 {
16376 return test ("1.0", NULL) != 1 || p ("1.0", NULL) != 1;
16377 ;
16378 return 0;
16379 }
16380 _ACEOF
16381 if ac_fn_c_try_link "$LINENO"; then :
16382 gl_cv_func_c99_strtold=yes
16383 else
16384 gl_cv_func_c99_strtold=no
16385 fi
16386 rm -f core conftest.err conftest.$ac_objext \
16387 conftest$ac_exeext conftest.$ac_ext
16388 fi
16389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_c99_strtold" >&5
16390 $as_echo "$gl_cv_func_c99_strtold" >&6; }
16391 if test $gl_cv_func_c99_strtold = yes; then
16392
16393 $as_echo "#define HAVE_C99_STRTOLD 1" >>confdefs.h
16394
16395 fi
16396
16397
16398 GNULIB_CHDIR=0;
16399 GNULIB_CHOWN=0;
16400 GNULIB_CLOSE=0;
16401 GNULIB_DUP=0;
16402 GNULIB_DUP2=0;
16403 GNULIB_DUP3=0;
16404 GNULIB_ENVIRON=0;
16405 GNULIB_EUIDACCESS=0;
16406 GNULIB_FACCESSAT=0;
16407 GNULIB_FCHDIR=0;
16408 GNULIB_FCHOWNAT=0;
16409 GNULIB_FDATASYNC=0;
16410 GNULIB_FSYNC=0;
16411 GNULIB_FTRUNCATE=0;
16412 GNULIB_GETCWD=0;
16413 GNULIB_GETDOMAINNAME=0;
16414 GNULIB_GETDTABLESIZE=0;
16415 GNULIB_GETGROUPS=0;
16416 GNULIB_GETHOSTNAME=0;
16417 GNULIB_GETLOGIN=0;
16418 GNULIB_GETLOGIN_R=0;
16419 GNULIB_GETPAGESIZE=0;
16420 GNULIB_GETUSERSHELL=0;
16421 GNULIB_GROUP_MEMBER=0;
16422 GNULIB_LCHOWN=0;
16423 GNULIB_LINK=0;
16424 GNULIB_LINKAT=0;
16425 GNULIB_LSEEK=0;
16426 GNULIB_PIPE=0;
16427 GNULIB_PIPE2=0;
16428 GNULIB_PREAD=0;
16429 GNULIB_PWRITE=0;
16430 GNULIB_READ=0;
16431 GNULIB_READLINK=0;
16432 GNULIB_READLINKAT=0;
16433 GNULIB_RMDIR=0;
16434 GNULIB_SLEEP=0;
16435 GNULIB_SYMLINK=0;
16436 GNULIB_SYMLINKAT=0;
16437 GNULIB_TTYNAME_R=0;
16438 GNULIB_UNISTD_H_GETOPT=0;
16439 GNULIB_UNISTD_H_NONBLOCKING=0;
16440 GNULIB_UNISTD_H_SIGPIPE=0;
16441 GNULIB_UNLINK=0;
16442 GNULIB_UNLINKAT=0;
16443 GNULIB_USLEEP=0;
16444 GNULIB_WRITE=0;
16445 HAVE_CHOWN=1;
16446 HAVE_DUP2=1;
16447 HAVE_DUP3=1;
16448 HAVE_EUIDACCESS=1;
16449 HAVE_FACCESSAT=1;
16450 HAVE_FCHDIR=1;
16451 HAVE_FCHOWNAT=1;
16452 HAVE_FDATASYNC=1;
16453 HAVE_FSYNC=1;
16454 HAVE_FTRUNCATE=1;
16455 HAVE_GETDTABLESIZE=1;
16456 HAVE_GETGROUPS=1;
16457 HAVE_GETHOSTNAME=1;
16458 HAVE_GETLOGIN=1;
16459 HAVE_GETPAGESIZE=1;
16460 HAVE_GROUP_MEMBER=1;
16461 HAVE_LCHOWN=1;
16462 HAVE_LINK=1;
16463 HAVE_LINKAT=1;
16464 HAVE_PIPE=1;
16465 HAVE_PIPE2=1;
16466 HAVE_PREAD=1;
16467 HAVE_PWRITE=1;
16468 HAVE_READLINK=1;
16469 HAVE_READLINKAT=1;
16470 HAVE_SLEEP=1;
16471 HAVE_SYMLINK=1;
16472 HAVE_SYMLINKAT=1;
16473 HAVE_UNLINKAT=1;
16474 HAVE_USLEEP=1;
16475 HAVE_DECL_ENVIRON=1;
16476 HAVE_DECL_FCHDIR=1;
16477 HAVE_DECL_FDATASYNC=1;
16478 HAVE_DECL_GETDOMAINNAME=1;
16479 HAVE_DECL_GETLOGIN_R=1;
16480 HAVE_DECL_GETPAGESIZE=1;
16481 HAVE_DECL_GETUSERSHELL=1;
16482 HAVE_DECL_TTYNAME_R=1;
16483 HAVE_OS_H=0;
16484 HAVE_SYS_PARAM_H=0;
16485 REPLACE_CHOWN=0;
16486 REPLACE_CLOSE=0;
16487 REPLACE_DUP=0;
16488 REPLACE_DUP2=0;
16489 REPLACE_FCHOWNAT=0;
16490 REPLACE_GETCWD=0;
16491 REPLACE_GETDOMAINNAME=0;
16492 REPLACE_GETLOGIN_R=0;
16493 REPLACE_GETGROUPS=0;
16494 REPLACE_GETPAGESIZE=0;
16495 REPLACE_LCHOWN=0;
16496 REPLACE_LINK=0;
16497 REPLACE_LINKAT=0;
16498 REPLACE_LSEEK=0;
16499 REPLACE_PREAD=0;
16500 REPLACE_PWRITE=0;
16501 REPLACE_READ=0;
16502 REPLACE_READLINK=0;
16503 REPLACE_RMDIR=0;
16504 REPLACE_SLEEP=0;
16505 REPLACE_SYMLINK=0;
16506 REPLACE_TTYNAME_R=0;
16507 REPLACE_UNLINK=0;
16508 REPLACE_UNLINKAT=0;
16509 REPLACE_USLEEP=0;
16510 REPLACE_WRITE=0;
16511 UNISTD_H_HAVE_WINSOCK2_H=0;
16512 UNISTD_H_HAVE_WINSOCK2_H_AND_USE_SOCKETS=0;
16513
16514
16515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for st_dm_mode in struct stat" >&5
16516 $as_echo_n "checking for st_dm_mode in struct stat... " >&6; }
16517 if test "${ac_cv_struct_st_dm_mode+set}" = set; then :
16518 $as_echo_n "(cached) " >&6
16519 else
16520 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16521 /* end confdefs.h. */
16522
16523 #include <sys/types.h>
16524 #include <sys/stat.h>
16525 int
16526 main ()
16527 {
16528 struct stat s; s.st_dm_mode;
16529 ;
16530 return 0;
16531 }
16532 _ACEOF
16533 if ac_fn_c_try_compile "$LINENO"; then :
16534 ac_cv_struct_st_dm_mode=yes
16535 else
16536 ac_cv_struct_st_dm_mode=no
16537 fi
16538 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16539 fi
16540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_st_dm_mode" >&5
16541 $as_echo "$ac_cv_struct_st_dm_mode" >&6; }
16542
16543 if test $ac_cv_struct_st_dm_mode = yes; then
16544
16545 $as_echo "#define HAVE_ST_DM_MODE 1" >>confdefs.h
16546
16547 fi
16548
16549
16550 ac_fn_c_check_decl "$LINENO" "strmode" "ac_cv_have_decl_strmode" "$ac_includes_default"
16551 if test "x$ac_cv_have_decl_strmode" = x""yes; then :
16552 ac_have_decl=1
16553 else
16554 ac_have_decl=0
16555 fi
16556
16557 cat >>confdefs.h <<_ACEOF
16558 #define HAVE_DECL_STRMODE $ac_have_decl
16559 _ACEOF
16560
16561
16562 GNULIB__EXIT=0;
16563 GNULIB_ATOLL=0;
16564 GNULIB_CALLOC_POSIX=0;
16565 GNULIB_CANONICALIZE_FILE_NAME=0;
16566 GNULIB_GETLOADAVG=0;
16567 GNULIB_GETSUBOPT=0;
16568 GNULIB_GRANTPT=0;
16569 GNULIB_MALLOC_POSIX=0;
16570 GNULIB_MBTOWC=0;
16571 GNULIB_MKDTEMP=0;
16572 GNULIB_MKOSTEMP=0;
16573 GNULIB_MKOSTEMPS=0;
16574 GNULIB_MKSTEMP=0;
16575 GNULIB_MKSTEMPS=0;
16576 GNULIB_PTSNAME=0;
16577 GNULIB_PUTENV=0;
16578 GNULIB_RANDOM_R=0;
16579 GNULIB_REALLOC_POSIX=0;
16580 GNULIB_REALPATH=0;
16581 GNULIB_RPMATCH=0;
16582 GNULIB_SETENV=0;
16583 GNULIB_STRTOD=0;
16584 GNULIB_STRTOLL=0;
16585 GNULIB_STRTOULL=0;
16586 GNULIB_SYSTEM_POSIX=0;
16587 GNULIB_UNLOCKPT=0;
16588 GNULIB_UNSETENV=0;
16589 GNULIB_WCTOMB=0;
16590 HAVE__EXIT=1;
16591 HAVE_ATOLL=1;
16592 HAVE_CANONICALIZE_FILE_NAME=1;
16593 HAVE_DECL_GETLOADAVG=1;
16594 HAVE_GETSUBOPT=1;
16595 HAVE_GRANTPT=1;
16596 HAVE_MKDTEMP=1;
16597 HAVE_MKOSTEMP=1;
16598 HAVE_MKOSTEMPS=1;
16599 HAVE_MKSTEMP=1;
16600 HAVE_MKSTEMPS=1;
16601 HAVE_PTSNAME=1;
16602 HAVE_RANDOM_H=1;
16603 HAVE_RANDOM_R=1;
16604 HAVE_REALPATH=1;
16605 HAVE_RPMATCH=1;
16606 HAVE_SETENV=1;
16607 HAVE_DECL_SETENV=1;
16608 HAVE_STRTOD=1;
16609 HAVE_STRTOLL=1;
16610 HAVE_STRTOULL=1;
16611 HAVE_STRUCT_RANDOM_DATA=1;
16612 HAVE_SYS_LOADAVG_H=0;
16613 HAVE_UNLOCKPT=1;
16614 HAVE_DECL_UNSETENV=1;
16615 REPLACE_CALLOC=0;
16616 REPLACE_CANONICALIZE_FILE_NAME=0;
16617 REPLACE_MALLOC=0;
16618 REPLACE_MBTOWC=0;
16619 REPLACE_MKSTEMP=0;
16620 REPLACE_PUTENV=0;
16621 REPLACE_REALLOC=0;
16622 REPLACE_REALPATH=0;
16623 REPLACE_SETENV=0;
16624 REPLACE_STRTOD=0;
16625 REPLACE_UNSETENV=0;
16626 REPLACE_WCTOMB=0;
16627
16628
16629
16630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the preprocessor supports include_next" >&5
16631 $as_echo_n "checking whether the preprocessor supports include_next... " >&6; }
16632 if test "${gl_cv_have_include_next+set}" = set; then :
16633 $as_echo_n "(cached) " >&6
16634 else
16635 rm -rf conftestd1a conftestd1b conftestd2
16636 mkdir conftestd1a conftestd1b conftestd2
16637 cat <<EOF > conftestd1a/conftest.h
16638 #define DEFINED_IN_CONFTESTD1
16639 #include_next <conftest.h>
16640 #ifdef DEFINED_IN_CONFTESTD2
16641 int foo;
16642 #else
16643 #error "include_next doesn't work"
16644 #endif
16645 EOF
16646 cat <<EOF > conftestd1b/conftest.h
16647 #define DEFINED_IN_CONFTESTD1
16648 #include <stdio.h>
16649 #include_next <conftest.h>
16650 #ifdef DEFINED_IN_CONFTESTD2
16651 int foo;
16652 #else
16653 #error "include_next doesn't work"
16654 #endif
16655 EOF
16656 cat <<EOF > conftestd2/conftest.h
16657 #ifndef DEFINED_IN_CONFTESTD1
16658 #error "include_next test doesn't work"
16659 #endif
16660 #define DEFINED_IN_CONFTESTD2
16661 EOF
16662 gl_save_CPPFLAGS="$CPPFLAGS"
16663 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1b -Iconftestd2"
16664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16665 /* end confdefs.h. */
16666 #include <conftest.h>
16667 _ACEOF
16668 if ac_fn_c_try_compile "$LINENO"; then :
16669 gl_cv_have_include_next=yes
16670 else
16671 CPPFLAGS="$gl_save_CPPFLAGS -Iconftestd1a -Iconftestd2"
16672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16673 /* end confdefs.h. */
16674 #include <conftest.h>
16675 _ACEOF
16676 if ac_fn_c_try_compile "$LINENO"; then :
16677 gl_cv_have_include_next=buggy
16678 else
16679 gl_cv_have_include_next=no
16680 fi
16681 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16682
16683 fi
16684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16685 CPPFLAGS="$gl_save_CPPFLAGS"
16686 rm -rf conftestd1a conftestd1b conftestd2
16687
16688 fi
16689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_include_next" >&5
16690 $as_echo "$gl_cv_have_include_next" >&6; }
16691 PRAGMA_SYSTEM_HEADER=
16692 if test $gl_cv_have_include_next = yes; then
16693 INCLUDE_NEXT=include_next
16694 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16695 if test -n "$GCC"; then
16696 PRAGMA_SYSTEM_HEADER='#pragma GCC system_header'
16697 fi
16698 else
16699 if test $gl_cv_have_include_next = buggy; then
16700 INCLUDE_NEXT=include
16701 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include_next
16702 else
16703 INCLUDE_NEXT=include
16704 INCLUDE_NEXT_AS_FIRST_DIRECTIVE=include
16705 fi
16706 fi
16707
16708
16709
16710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system header files limit the line length" >&5
16711 $as_echo_n "checking whether system header files limit the line length... " >&6; }
16712 if test "${gl_cv_pragma_columns+set}" = set; then :
16713 $as_echo_n "(cached) " >&6
16714 else
16715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16716 /* end confdefs.h. */
16717
16718 #ifdef __TANDEM
16719 choke me
16720 #endif
16721
16722 _ACEOF
16723 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
16724 $EGREP "choke me" >/dev/null 2>&1; then :
16725 gl_cv_pragma_columns=yes
16726 else
16727 gl_cv_pragma_columns=no
16728 fi
16729 rm -f conftest*
16730
16731
16732 fi
16733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pragma_columns" >&5
16734 $as_echo "$gl_cv_pragma_columns" >&6; }
16735 if test $gl_cv_pragma_columns = yes; then
16736 PRAGMA_COLUMNS="#pragma COLUMNS 10000"
16737 else
16738 PRAGMA_COLUMNS=
16739 fi
16740
16741
16742
16743
16744
16745
16746
16747
16748
16749
16750
16751
16752
16753
16754
16755
16756
16757 if test $gl_cv_have_include_next = yes; then
16758 gl_cv_next_getopt_h='<'getopt.h'>'
16759 else
16760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <getopt.h>" >&5
16761 $as_echo_n "checking absolute name of <getopt.h>... " >&6; }
16762 if test "${gl_cv_next_getopt_h+set}" = set; then :
16763 $as_echo_n "(cached) " >&6
16764 else
16765
16766 if test $ac_cv_header_getopt_h = yes; then
16767
16768
16769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16770 /* end confdefs.h. */
16771 #include <getopt.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
16779 case "$host_os" in
16780 mingw*)
16781 gl_dirsep_regex='[/\\]'
16782 ;;
16783 *)
16784 gl_dirsep_regex='/'
16785 ;;
16786 esac
16787
16788 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'getopt.h|{
16789 s|.*"\(.*'"${gl_dirsep_regex}"'getopt.h\)".*|\1|
16790 s|^/[^/]|//&|
16791 p
16792 q
16793 }'
16794 gl_cv_next_getopt_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
16795 sed -n "$gl_absolute_header_sed"`'"'
16796 else
16797 gl_cv_next_getopt_h='<'getopt.h'>'
16798 fi
16799
16800
16801 fi
16802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_getopt_h" >&5
16803 $as_echo "$gl_cv_next_getopt_h" >&6; }
16804 fi
16805 NEXT_GETOPT_H=$gl_cv_next_getopt_h
16806
16807 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
16808 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
16809 gl_next_as_first_directive='<'getopt.h'>'
16810 else
16811 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
16812 gl_next_as_first_directive=$gl_cv_next_getopt_h
16813 fi
16814 NEXT_AS_FIRST_DIRECTIVE_GETOPT_H=$gl_next_as_first_directive
16815
16816
16817
16818
16819 if test $ac_cv_header_getopt_h = yes; then
16820 HAVE_GETOPT_H=1
16821 else
16822 HAVE_GETOPT_H=0
16823 fi
16824
16825
16826 gl_replace_getopt=
16827
16828 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16829 for ac_header in getopt.h
16830 do :
16831 ac_fn_c_check_header_mongrel "$LINENO" "getopt.h" "ac_cv_header_getopt_h" "$ac_includes_default"
16832 if test "x$ac_cv_header_getopt_h" = x""yes; then :
16833 cat >>confdefs.h <<_ACEOF
16834 #define HAVE_GETOPT_H 1
16835 _ACEOF
16836
16837 else
16838 gl_replace_getopt=yes
16839 fi
16840
16841 done
16842
16843 fi
16844
16845 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
16846 for ac_func in getopt_long_only
16847 do :
16848 ac_fn_c_check_func "$LINENO" "getopt_long_only" "ac_cv_func_getopt_long_only"
16849 if test "x$ac_cv_func_getopt_long_only" = x""yes; then :
16850 cat >>confdefs.h <<_ACEOF
16851 #define HAVE_GETOPT_LONG_ONLY 1
16852 _ACEOF
16853
16854 else
16855 gl_replace_getopt=yes
16856 fi
16857 done
16858
16859 fi
16860
16861 if test -z "$gl_replace_getopt"; then
16862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt is POSIX compatible" >&5
16863 $as_echo_n "checking whether getopt is POSIX compatible... " >&6; }
16864 if test "${gl_cv_func_getopt_posix+set}" = set; then :
16865 $as_echo_n "(cached) " >&6
16866 else
16867
16868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16869 /* end confdefs.h. */
16870 #include <unistd.h>
16871 int
16872 main ()
16873 {
16874 int *p = &optreset; return optreset;
16875 ;
16876 return 0;
16877 }
16878 _ACEOF
16879 if ac_fn_c_try_link "$LINENO"; then :
16880 gl_optind_min=1
16881 else
16882 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16883 /* end confdefs.h. */
16884 #include <getopt.h>
16885 int
16886 main ()
16887 {
16888 return !getopt_clip;
16889 ;
16890 return 0;
16891 }
16892 _ACEOF
16893 if ac_fn_c_try_compile "$LINENO"; then :
16894 gl_optind_min=1
16895 else
16896 gl_optind_min=0
16897 fi
16898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16899 fi
16900 rm -f core conftest.err conftest.$ac_objext \
16901 conftest$ac_exeext conftest.$ac_ext
16902
16903 gl_save_CPPFLAGS=$CPPFLAGS
16904 CPPFLAGS="$CPPFLAGS -DOPTIND_MIN=$gl_optind_min"
16905 if test "$cross_compiling" = yes; then :
16906 case "$host_os" in
16907 mingw*) gl_cv_func_getopt_posix="guessing no";;
16908 darwin* | aix*) gl_cv_func_getopt_posix="guessing no";;
16909 *) gl_cv_func_getopt_posix="guessing yes";;
16910 esac
16911
16912 else
16913 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16914 /* end confdefs.h. */
16915
16916 #include <unistd.h>
16917 #include <stdlib.h>
16918 #include <string.h>
16919
16920 int
16921 main ()
16922 {
16923 {
16924 static char program[] = "program";
16925 static char a[] = "-a";
16926 static char foo[] = "foo";
16927 static char bar[] = "bar";
16928 char *argv[] = { program, a, foo, bar, NULL };
16929 int c;
16930
16931 optind = OPTIND_MIN;
16932 opterr = 0;
16933
16934 c = getopt (4, argv, "ab");
16935 if (!(c == 'a'))
16936 return 1;
16937 c = getopt (4, argv, "ab");
16938 if (!(c == -1))
16939 return 2;
16940 if (!(optind == 2))
16941 return 3;
16942 }
16943 /* Some internal state exists at this point. */
16944 {
16945 static char program[] = "program";
16946 static char donald[] = "donald";
16947 static char p[] = "-p";
16948 static char billy[] = "billy";
16949 static char duck[] = "duck";
16950 static char a[] = "-a";
16951 static char bar[] = "bar";
16952 char *argv[] = { program, donald, p, billy, duck, a, bar, NULL };
16953 int c;
16954
16955 optind = OPTIND_MIN;
16956 opterr = 0;
16957
16958 c = getopt (7, argv, "+abp:q:");
16959 if (!(c == -1))
16960 return 4;
16961 if (!(strcmp (argv[0], "program") == 0))
16962 return 5;
16963 if (!(strcmp (argv[1], "donald") == 0))
16964 return 6;
16965 if (!(strcmp (argv[2], "-p") == 0))
16966 return 7;
16967 if (!(strcmp (argv[3], "billy") == 0))
16968 return 8;
16969 if (!(strcmp (argv[4], "duck") == 0))
16970 return 9;
16971 if (!(strcmp (argv[5], "-a") == 0))
16972 return 10;
16973 if (!(strcmp (argv[6], "bar") == 0))
16974 return 11;
16975 if (!(optind == 1))
16976 return 12;
16977 }
16978 /* Detect MacOS 10.5, AIX 7.1 bug. */
16979 {
16980 static char program[] = "program";
16981 static char ab[] = "-ab";
16982 char *argv[3] = { program, ab, NULL };
16983 optind = OPTIND_MIN;
16984 opterr = 0;
16985 if (getopt (2, argv, "ab:") != 'a')
16986 return 13;
16987 if (getopt (2, argv, "ab:") != '?')
16988 return 14;
16989 if (optopt != 'b')
16990 return 15;
16991 if (optind != 2)
16992 return 16;
16993 }
16994
16995 return 0;
16996 }
16997
16998 _ACEOF
16999 if ac_fn_c_try_run "$LINENO"; then :
17000 gl_cv_func_getopt_posix=yes
17001 else
17002 gl_cv_func_getopt_posix=no
17003 fi
17004 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17005 conftest.$ac_objext conftest.beam conftest.$ac_ext
17006 fi
17007
17008 CPPFLAGS=$gl_save_CPPFLAGS
17009
17010 fi
17011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_posix" >&5
17012 $as_echo "$gl_cv_func_getopt_posix" >&6; }
17013 case "$gl_cv_func_getopt_posix" in
17014 *no) gl_replace_getopt=yes ;;
17015 esac
17016 fi
17017
17018 if test -z "$gl_replace_getopt" && test $gl_getopt_required = GNU; then
17019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working GNU getopt function" >&5
17020 $as_echo_n "checking for working GNU getopt function... " >&6; }
17021 if test "${gl_cv_func_getopt_gnu+set}" = set; then :
17022 $as_echo_n "(cached) " >&6
17023 else
17024 # Even with POSIXLY_CORRECT, the GNU extension of leading '-' in the
17025 # optstring is necessary for programs like m4 that have POSIX-mandated
17026 # semantics for supporting options interspersed with files.
17027 # Also, since getopt_long is a GNU extension, we require optind=0.
17028 # Bash ties 'set -o posix' to a non-exported POSIXLY_CORRECT;
17029 # so take care to revert to the correct (non-)export state.
17030 gl_awk_probe='BEGIN { if ("POSIXLY_CORRECT" in ENVIRON) print "x" }'
17031 case ${POSIXLY_CORRECT+x}`$AWK "$gl_awk_probe" </dev/null` in
17032 xx) gl_had_POSIXLY_CORRECT=exported ;;
17033 x) gl_had_POSIXLY_CORRECT=yes ;;
17034 *) gl_had_POSIXLY_CORRECT= ;;
17035 esac
17036 POSIXLY_CORRECT=1
17037 export POSIXLY_CORRECT
17038 if test "$cross_compiling" = yes; then :
17039 case $host_os:$ac_cv_have_decl_optreset in
17040 *-gnu*:* | mingw*:*) gl_cv_func_getopt_gnu=no;;
17041 *:yes) gl_cv_func_getopt_gnu=no;;
17042 *) gl_cv_func_getopt_gnu=yes;;
17043 esac
17044
17045 else
17046 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17047 /* end confdefs.h. */
17048 #include <getopt.h>
17049 #include <stddef.h>
17050 #include <string.h>
17051
17052 #include <stdlib.h>
17053 #if defined __MACH__ && defined __APPLE__
17054 /* Avoid a crash on MacOS X. */
17055 #include <mach/mach.h>
17056 #include <mach/mach_error.h>
17057 #include <mach/thread_status.h>
17058 #include <mach/exception.h>
17059 #include <mach/task.h>
17060 #include <pthread.h>
17061 /* The exception port on which our thread listens. */
17062 static mach_port_t our_exception_port;
17063 /* The main function of the thread listening for exceptions of type
17064 EXC_BAD_ACCESS. */
17065 static void *
17066 mach_exception_thread (void *arg)
17067 {
17068 /* Buffer for a message to be received. */
17069 struct {
17070 mach_msg_header_t head;
17071 mach_msg_body_t msgh_body;
17072 char data[1024];
17073 } msg;
17074 mach_msg_return_t retval;
17075 /* Wait for a message on the exception port. */
17076 retval = mach_msg (&msg.head, MACH_RCV_MSG | MACH_RCV_LARGE, 0, sizeof (msg),
17077 our_exception_port, MACH_MSG_TIMEOUT_NONE, MACH_PORT_NULL);
17078 if (retval != MACH_MSG_SUCCESS)
17079 abort ();
17080 exit (1);
17081 }
17082 static void
17083 nocrash_init (void)
17084 {
17085 mach_port_t self = mach_task_self ();
17086 /* Allocate a port on which the thread shall listen for exceptions. */
17087 if (mach_port_allocate (self, MACH_PORT_RIGHT_RECEIVE, &our_exception_port)
17088 == KERN_SUCCESS) {
17089 /* See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/mach_port_insert_right.html. */
17090 if (mach_port_insert_right (self, our_exception_port, our_exception_port,
17091 MACH_MSG_TYPE_MAKE_SEND)
17092 == KERN_SUCCESS) {
17093 /* The exceptions we want to catch. Only EXC_BAD_ACCESS is interesting
17094 for us. */
17095 exception_mask_t mask = EXC_MASK_BAD_ACCESS;
17096 /* Create the thread listening on the exception port. */
17097 pthread_attr_t attr;
17098 pthread_t thread;
17099 if (pthread_attr_init (&attr) == 0
17100 && pthread_attr_setdetachstate (&attr, PTHREAD_CREATE_DETACHED) == 0
17101 && pthread_create (&thread, &attr, mach_exception_thread, NULL) == 0) {
17102 pthread_attr_destroy (&attr);
17103 /* Replace the exception port info for these exceptions with our own.
17104 Note that we replace the exception port for the entire task, not only
17105 for a particular thread. This has the effect that when our exception
17106 port gets the message, the thread specific exception port has already
17107 been asked, and we don't need to bother about it.
17108 See http://web.mit.edu/darwin/src/modules/xnu/osfmk/man/task_set_exception_ports.html. */
17109 task_set_exception_ports (self, mask, our_exception_port,
17110 EXCEPTION_DEFAULT, MACHINE_THREAD_STATE);
17111 }
17112 }
17113 }
17114 }
17115 #elif (defined _WIN32 || defined __WIN32__) && ! defined __CYGWIN__
17116 /* Avoid a crash on native Windows. */
17117 #define WIN32_LEAN_AND_MEAN
17118 #include <windows.h>
17119 #include <winerror.h>
17120 static LONG WINAPI
17121 exception_filter (EXCEPTION_POINTERS *ExceptionInfo)
17122 {
17123 switch (ExceptionInfo->ExceptionRecord->ExceptionCode)
17124 {
17125 case EXCEPTION_ACCESS_VIOLATION:
17126 case EXCEPTION_IN_PAGE_ERROR:
17127 case EXCEPTION_STACK_OVERFLOW:
17128 case EXCEPTION_GUARD_PAGE:
17129 case EXCEPTION_PRIV_INSTRUCTION:
17130 case EXCEPTION_ILLEGAL_INSTRUCTION:
17131 case EXCEPTION_DATATYPE_MISALIGNMENT:
17132 case EXCEPTION_ARRAY_BOUNDS_EXCEEDED:
17133 case EXCEPTION_NONCONTINUABLE_EXCEPTION:
17134 exit (1);
17135 }
17136 return EXCEPTION_CONTINUE_SEARCH;
17137 }
17138 static void
17139 nocrash_init (void)
17140 {
17141 SetUnhandledExceptionFilter ((LPTOP_LEVEL_EXCEPTION_FILTER) exception_filter);
17142 }
17143 #else
17144 /* Avoid a crash on POSIX systems. */
17145 #include <signal.h>
17146 /* A POSIX signal handler. */
17147 static void
17148 exception_handler (int sig)
17149 {
17150 exit (1);
17151 }
17152 static void
17153 nocrash_init (void)
17154 {
17155 #ifdef SIGSEGV
17156 signal (SIGSEGV, exception_handler);
17157 #endif
17158 #ifdef SIGBUS
17159 signal (SIGBUS, exception_handler);
17160 #endif
17161 }
17162 #endif
17163
17164
17165 int
17166 main ()
17167 {
17168
17169 int result = 0;
17170
17171 nocrash_init();
17172
17173 /* This code succeeds on glibc 2.8, OpenBSD 4.0, Cygwin, mingw,
17174 and fails on MacOS X 10.5, AIX 5.2, HP-UX 11, IRIX 6.5,
17175 OSF/1 5.1, Solaris 10. */
17176 {
17177 static char conftest[] = "conftest";
17178 static char plus[] = "-+";
17179 char *argv[3] = { conftest, plus, NULL };
17180 opterr = 0;
17181 if (getopt (2, argv, "+a") != '?')
17182 result |= 1;
17183 }
17184 /* This code succeeds on glibc 2.8, mingw,
17185 and fails on MacOS X 10.5, OpenBSD 4.0, AIX 5.2, HP-UX 11,
17186 IRIX 6.5, OSF/1 5.1, Solaris 10, Cygwin 1.5.x. */
17187 {
17188 static char program[] = "program";
17189 static char p[] = "-p";
17190 static char foo[] = "foo";
17191 static char bar[] = "bar";
17192 char *argv[] = { program, p, foo, bar, NULL };
17193
17194 optind = 1;
17195 if (getopt (4, argv, "p::") != 'p')
17196 result |= 2;
17197 else if (optarg != NULL)
17198 result |= 4;
17199 else if (getopt (4, argv, "p::") != -1)
17200 result |= 6;
17201 else if (optind != 2)
17202 result |= 8;
17203 }
17204 /* This code succeeds on glibc 2.8 and fails on Cygwin 1.7.0. */
17205 {
17206 static char program[] = "program";
17207 static char foo[] = "foo";
17208 static char p[] = "-p";
17209 char *argv[] = { program, foo, p, NULL };
17210 optind = 0;
17211 if (getopt (3, argv, "-p") != 1)
17212 result |= 16;
17213 else if (getopt (3, argv, "-p") != 'p')
17214 result |= 32;
17215 }
17216 /* This code fails on glibc 2.11. */
17217 {
17218 static char program[] = "program";
17219 static char b[] = "-b";
17220 static char a[] = "-a";
17221 char *argv[] = { program, b, a, NULL };
17222 optind = opterr = 0;
17223 if (getopt (3, argv, "+:a:b") != 'b')
17224 result |= 64;
17225 else if (getopt (3, argv, "+:a:b") != ':')
17226 result |= 64;
17227 }
17228 /* This code dumps core on glibc 2.14. */
17229 {
17230 static char program[] = "program";
17231 static char w[] = "-W";
17232 static char dummy[] = "dummy";
17233 char *argv[] = { program, w, dummy, NULL };
17234 optind = opterr = 1;
17235 if (getopt (3, argv, "W;") != 'W')
17236 result |= 128;
17237 }
17238 return result;
17239
17240 ;
17241 return 0;
17242 }
17243 _ACEOF
17244 if ac_fn_c_try_run "$LINENO"; then :
17245 gl_cv_func_getopt_gnu=yes
17246 else
17247 gl_cv_func_getopt_gnu=no
17248 fi
17249 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17250 conftest.$ac_objext conftest.beam conftest.$ac_ext
17251 fi
17252
17253 case $gl_had_POSIXLY_CORRECT in
17254 exported) ;;
17255 yes) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;}; POSIXLY_CORRECT=1 ;;
17256 *) { POSIXLY_CORRECT=; unset POSIXLY_CORRECT;} ;;
17257 esac
17258
17259 fi
17260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_getopt_gnu" >&5
17261 $as_echo "$gl_cv_func_getopt_gnu" >&6; }
17262 if test "$gl_cv_func_getopt_gnu" = "no"; then
17263 gl_replace_getopt=yes
17264 fi
17265 fi
17266
17267
17268
17269
17270
17271 REPLACE_GETOPT=0
17272
17273
17274 if test -n "$gl_replace_getopt"; then :
17275
17276 REPLACE_GETOPT=1
17277
17278 fi
17279
17280
17281 if test $REPLACE_GETOPT = 1; then
17282
17283 GETOPT_H=getopt.h
17284
17285 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
17286
17287
17288
17289 GNULIB_UNISTD_H_GETOPT=1
17290 fi
17291
17292 ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default"
17293 if test "x$ac_cv_have_decl_getenv" = x""yes; then :
17294 ac_have_decl=1
17295 else
17296 ac_have_decl=0
17297 fi
17298
17299 cat >>confdefs.h <<_ACEOF
17300 #define HAVE_DECL_GETENV $ac_have_decl
17301 _ACEOF
17302
17303
17304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
17305 $as_echo_n "checking for unsigned long long int... " >&6; }
17306 if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then :
17307 $as_echo_n "(cached) " >&6
17308 else
17309 ac_cv_type_unsigned_long_long_int=yes
17310 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17312 /* end confdefs.h. */
17313
17314 /* For now, do not test the preprocessor; as of 2007 there are too many
17315 implementations with broken preprocessors. Perhaps this can
17316 be revisited in 2012. In the meantime, code should not expect
17317 #if to work with literals wider than 32 bits. */
17318 /* Test literals. */
17319 long long int ll = 9223372036854775807ll;
17320 long long int nll = -9223372036854775807LL;
17321 unsigned long long int ull = 18446744073709551615ULL;
17322 /* Test constant expressions. */
17323 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
17324 ? 1 : -1)];
17325 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
17326 ? 1 : -1)];
17327 int i = 63;
17328 int
17329 main ()
17330 {
17331 /* Test availability of runtime routines for shift and division. */
17332 long long int llmax = 9223372036854775807ll;
17333 unsigned long long int ullmax = 18446744073709551615ull;
17334 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
17335 | (llmax / ll) | (llmax % ll)
17336 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
17337 | (ullmax / ull) | (ullmax % ull));
17338 ;
17339 return 0;
17340 }
17341
17342 _ACEOF
17343 if ac_fn_c_try_link "$LINENO"; then :
17344
17345 else
17346 ac_cv_type_unsigned_long_long_int=no
17347 fi
17348 rm -f core conftest.err conftest.$ac_objext \
17349 conftest$ac_exeext conftest.$ac_ext
17350 fi
17351 fi
17352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
17353 $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; }
17354 if test $ac_cv_type_unsigned_long_long_int = yes; then
17355
17356 $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
17357
17358 fi
17359
17360
17361
17362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
17363 $as_echo_n "checking for long long int... " >&6; }
17364 if test "${ac_cv_type_long_long_int+set}" = set; then :
17365 $as_echo_n "(cached) " >&6
17366 else
17367 ac_cv_type_long_long_int=yes
17368 if test "x${ac_cv_prog_cc_c99-no}" = xno; then
17369 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
17370 if test $ac_cv_type_long_long_int = yes; then
17371 if test "$cross_compiling" = yes; then :
17372 :
17373 else
17374 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17375 /* end confdefs.h. */
17376 #include <limits.h>
17377 #ifndef LLONG_MAX
17378 # define HALF \
17379 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
17380 # define LLONG_MAX (HALF - 1 + HALF)
17381 #endif
17382 int
17383 main ()
17384 {
17385 long long int n = 1;
17386 int i;
17387 for (i = 0; ; i++)
17388 {
17389 long long int m = n << i;
17390 if (m >> i != n)
17391 return 1;
17392 if (LLONG_MAX / 2 < m)
17393 break;
17394 }
17395 return 0;
17396 ;
17397 return 0;
17398 }
17399 _ACEOF
17400 if ac_fn_c_try_run "$LINENO"; then :
17401
17402 else
17403 ac_cv_type_long_long_int=no
17404 fi
17405 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17406 conftest.$ac_objext conftest.beam conftest.$ac_ext
17407 fi
17408
17409 fi
17410 fi
17411 fi
17412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
17413 $as_echo "$ac_cv_type_long_long_int" >&6; }
17414 if test $ac_cv_type_long_long_int = yes; then
17415
17416 $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
17417
17418 fi
17419
17420
17421
17422
17423
17424
17425 gl_cv_c_multiarch=no
17426 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17427 /* end confdefs.h. */
17428 #ifndef __APPLE_CC__
17429 not a universal capable compiler
17430 #endif
17431 typedef int dummy;
17432
17433 _ACEOF
17434 if ac_fn_c_try_compile "$LINENO"; then :
17435
17436 arch=
17437 prev=
17438 for word in ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}; do
17439 if test -n "$prev"; then
17440 case $word in
17441 i?86 | x86_64 | ppc | ppc64)
17442 if test -z "$arch" || test "$arch" = "$word"; then
17443 arch="$word"
17444 else
17445 gl_cv_c_multiarch=yes
17446 fi
17447 ;;
17448 esac
17449 prev=
17450 else
17451 if test "x$word" = "x-arch"; then
17452 prev=arch
17453 fi
17454 fi
17455 done
17456
17457 fi
17458 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17459 if test $gl_cv_c_multiarch = yes; then
17460 APPLE_UNIVERSAL_BUILD=1
17461 else
17462 APPLE_UNIVERSAL_BUILD=0
17463 fi
17464
17465
17466
17467
17468
17469 if test $ac_cv_type_long_long_int = yes; then
17470 HAVE_LONG_LONG_INT=1
17471 else
17472 HAVE_LONG_LONG_INT=0
17473 fi
17474
17475
17476 if test $ac_cv_type_unsigned_long_long_int = yes; then
17477 HAVE_UNSIGNED_LONG_LONG_INT=1
17478 else
17479 HAVE_UNSIGNED_LONG_LONG_INT=0
17480 fi
17481
17482
17483
17484 if test $ac_cv_header_wchar_h = yes; then
17485 HAVE_WCHAR_H=1
17486 else
17487 HAVE_WCHAR_H=0
17488 fi
17489
17490
17491 if test $ac_cv_header_inttypes_h = yes; then
17492 HAVE_INTTYPES_H=1
17493 else
17494 HAVE_INTTYPES_H=0
17495 fi
17496
17497
17498 if test $ac_cv_header_sys_types_h = yes; then
17499 HAVE_SYS_TYPES_H=1
17500 else
17501 HAVE_SYS_TYPES_H=0
17502 fi
17503
17504
17505
17506
17507
17508
17509
17510
17511
17512
17513
17514 if test $gl_cv_have_include_next = yes; then
17515 gl_cv_next_stdint_h='<'stdint.h'>'
17516 else
17517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdint.h>" >&5
17518 $as_echo_n "checking absolute name of <stdint.h>... " >&6; }
17519 if test "${gl_cv_next_stdint_h+set}" = set; then :
17520 $as_echo_n "(cached) " >&6
17521 else
17522
17523 if test $ac_cv_header_stdint_h = yes; then
17524
17525
17526 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17527 /* end confdefs.h. */
17528 #include <stdint.h>
17529
17530 _ACEOF
17531 case "$host_os" in
17532 aix*) gl_absname_cpp="$ac_cpp -C" ;;
17533 *) gl_absname_cpp="$ac_cpp" ;;
17534 esac
17535
17536 case "$host_os" in
17537 mingw*)
17538 gl_dirsep_regex='[/\\]'
17539 ;;
17540 *)
17541 gl_dirsep_regex='/'
17542 ;;
17543 esac
17544
17545 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdint.h|{
17546 s|.*"\(.*'"${gl_dirsep_regex}"'stdint.h\)".*|\1|
17547 s|^/[^/]|//&|
17548 p
17549 q
17550 }'
17551 gl_cv_next_stdint_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
17552 sed -n "$gl_absolute_header_sed"`'"'
17553 else
17554 gl_cv_next_stdint_h='<'stdint.h'>'
17555 fi
17556
17557
17558 fi
17559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdint_h" >&5
17560 $as_echo "$gl_cv_next_stdint_h" >&6; }
17561 fi
17562 NEXT_STDINT_H=$gl_cv_next_stdint_h
17563
17564 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
17565 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
17566 gl_next_as_first_directive='<'stdint.h'>'
17567 else
17568 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
17569 gl_next_as_first_directive=$gl_cv_next_stdint_h
17570 fi
17571 NEXT_AS_FIRST_DIRECTIVE_STDINT_H=$gl_next_as_first_directive
17572
17573
17574
17575
17576 if test $ac_cv_header_stdint_h = yes; then
17577 HAVE_STDINT_H=1
17578 else
17579 HAVE_STDINT_H=0
17580 fi
17581
17582
17583 if test $ac_cv_header_stdint_h = yes; then
17584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stdint.h conforms to C99" >&5
17585 $as_echo_n "checking whether stdint.h conforms to C99... " >&6; }
17586 if test "${gl_cv_header_working_stdint_h+set}" = set; then :
17587 $as_echo_n "(cached) " >&6
17588 else
17589 gl_cv_header_working_stdint_h=no
17590 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17591 /* end confdefs.h. */
17592
17593
17594 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
17595 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
17596 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17597 #include <stdint.h>
17598 /* Dragonfly defines WCHAR_MIN, WCHAR_MAX only in <wchar.h>. */
17599 #if !(defined WCHAR_MIN && defined WCHAR_MAX)
17600 #error "WCHAR_MIN, WCHAR_MAX not defined in <stdint.h>"
17601 #endif
17602
17603
17604 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17605 included before <wchar.h>. */
17606 #include <stddef.h>
17607 #include <signal.h>
17608 #if HAVE_WCHAR_H
17609 # include <stdio.h>
17610 # include <time.h>
17611 # include <wchar.h>
17612 #endif
17613
17614
17615 #ifdef INT8_MAX
17616 int8_t a1 = INT8_MAX;
17617 int8_t a1min = INT8_MIN;
17618 #endif
17619 #ifdef INT16_MAX
17620 int16_t a2 = INT16_MAX;
17621 int16_t a2min = INT16_MIN;
17622 #endif
17623 #ifdef INT32_MAX
17624 int32_t a3 = INT32_MAX;
17625 int32_t a3min = INT32_MIN;
17626 #endif
17627 #ifdef INT64_MAX
17628 int64_t a4 = INT64_MAX;
17629 int64_t a4min = INT64_MIN;
17630 #endif
17631 #ifdef UINT8_MAX
17632 uint8_t b1 = UINT8_MAX;
17633 #else
17634 typedef int b1[(unsigned char) -1 != 255 ? 1 : -1];
17635 #endif
17636 #ifdef UINT16_MAX
17637 uint16_t b2 = UINT16_MAX;
17638 #endif
17639 #ifdef UINT32_MAX
17640 uint32_t b3 = UINT32_MAX;
17641 #endif
17642 #ifdef UINT64_MAX
17643 uint64_t b4 = UINT64_MAX;
17644 #endif
17645 int_least8_t c1 = INT8_C (0x7f);
17646 int_least8_t c1max = INT_LEAST8_MAX;
17647 int_least8_t c1min = INT_LEAST8_MIN;
17648 int_least16_t c2 = INT16_C (0x7fff);
17649 int_least16_t c2max = INT_LEAST16_MAX;
17650 int_least16_t c2min = INT_LEAST16_MIN;
17651 int_least32_t c3 = INT32_C (0x7fffffff);
17652 int_least32_t c3max = INT_LEAST32_MAX;
17653 int_least32_t c3min = INT_LEAST32_MIN;
17654 int_least64_t c4 = INT64_C (0x7fffffffffffffff);
17655 int_least64_t c4max = INT_LEAST64_MAX;
17656 int_least64_t c4min = INT_LEAST64_MIN;
17657 uint_least8_t d1 = UINT8_C (0xff);
17658 uint_least8_t d1max = UINT_LEAST8_MAX;
17659 uint_least16_t d2 = UINT16_C (0xffff);
17660 uint_least16_t d2max = UINT_LEAST16_MAX;
17661 uint_least32_t d3 = UINT32_C (0xffffffff);
17662 uint_least32_t d3max = UINT_LEAST32_MAX;
17663 uint_least64_t d4 = UINT64_C (0xffffffffffffffff);
17664 uint_least64_t d4max = UINT_LEAST64_MAX;
17665 int_fast8_t e1 = INT_FAST8_MAX;
17666 int_fast8_t e1min = INT_FAST8_MIN;
17667 int_fast16_t e2 = INT_FAST16_MAX;
17668 int_fast16_t e2min = INT_FAST16_MIN;
17669 int_fast32_t e3 = INT_FAST32_MAX;
17670 int_fast32_t e3min = INT_FAST32_MIN;
17671 int_fast64_t e4 = INT_FAST64_MAX;
17672 int_fast64_t e4min = INT_FAST64_MIN;
17673 uint_fast8_t f1 = UINT_FAST8_MAX;
17674 uint_fast16_t f2 = UINT_FAST16_MAX;
17675 uint_fast32_t f3 = UINT_FAST32_MAX;
17676 uint_fast64_t f4 = UINT_FAST64_MAX;
17677 #ifdef INTPTR_MAX
17678 intptr_t g = INTPTR_MAX;
17679 intptr_t gmin = INTPTR_MIN;
17680 #endif
17681 #ifdef UINTPTR_MAX
17682 uintptr_t h = UINTPTR_MAX;
17683 #endif
17684 intmax_t i = INTMAX_MAX;
17685 uintmax_t j = UINTMAX_MAX;
17686
17687 #include <limits.h> /* for CHAR_BIT */
17688 #define TYPE_MINIMUM(t) \
17689 ((t) ((t) 0 < (t) -1 ? (t) 0 : ~ TYPE_MAXIMUM (t)))
17690 #define TYPE_MAXIMUM(t) \
17691 ((t) ((t) 0 < (t) -1 \
17692 ? (t) -1 \
17693 : ((((t) 1 << (sizeof (t) * CHAR_BIT - 2)) - 1) * 2 + 1)))
17694 struct s {
17695 int check_PTRDIFF:
17696 PTRDIFF_MIN == TYPE_MINIMUM (ptrdiff_t)
17697 && PTRDIFF_MAX == TYPE_MAXIMUM (ptrdiff_t)
17698 ? 1 : -1;
17699 /* Detect bug in FreeBSD 6.0 / ia64. */
17700 int check_SIG_ATOMIC:
17701 SIG_ATOMIC_MIN == TYPE_MINIMUM (sig_atomic_t)
17702 && SIG_ATOMIC_MAX == TYPE_MAXIMUM (sig_atomic_t)
17703 ? 1 : -1;
17704 int check_SIZE: SIZE_MAX == TYPE_MAXIMUM (size_t) ? 1 : -1;
17705 int check_WCHAR:
17706 WCHAR_MIN == TYPE_MINIMUM (wchar_t)
17707 && WCHAR_MAX == TYPE_MAXIMUM (wchar_t)
17708 ? 1 : -1;
17709 /* Detect bug in mingw. */
17710 int check_WINT:
17711 WINT_MIN == TYPE_MINIMUM (wint_t)
17712 && WINT_MAX == TYPE_MAXIMUM (wint_t)
17713 ? 1 : -1;
17714
17715 /* Detect bugs in glibc 2.4 and Solaris 10 stdint.h, among others. */
17716 int check_UINT8_C:
17717 (-1 < UINT8_C (0)) == (-1 < (uint_least8_t) 0) ? 1 : -1;
17718 int check_UINT16_C:
17719 (-1 < UINT16_C (0)) == (-1 < (uint_least16_t) 0) ? 1 : -1;
17720
17721 /* Detect bugs in OpenBSD 3.9 stdint.h. */
17722 #ifdef UINT8_MAX
17723 int check_uint8: (uint8_t) -1 == UINT8_MAX ? 1 : -1;
17724 #endif
17725 #ifdef UINT16_MAX
17726 int check_uint16: (uint16_t) -1 == UINT16_MAX ? 1 : -1;
17727 #endif
17728 #ifdef UINT32_MAX
17729 int check_uint32: (uint32_t) -1 == UINT32_MAX ? 1 : -1;
17730 #endif
17731 #ifdef UINT64_MAX
17732 int check_uint64: (uint64_t) -1 == UINT64_MAX ? 1 : -1;
17733 #endif
17734 int check_uint_least8: (uint_least8_t) -1 == UINT_LEAST8_MAX ? 1 : -1;
17735 int check_uint_least16: (uint_least16_t) -1 == UINT_LEAST16_MAX ? 1 : -1;
17736 int check_uint_least32: (uint_least32_t) -1 == UINT_LEAST32_MAX ? 1 : -1;
17737 int check_uint_least64: (uint_least64_t) -1 == UINT_LEAST64_MAX ? 1 : -1;
17738 int check_uint_fast8: (uint_fast8_t) -1 == UINT_FAST8_MAX ? 1 : -1;
17739 int check_uint_fast16: (uint_fast16_t) -1 == UINT_FAST16_MAX ? 1 : -1;
17740 int check_uint_fast32: (uint_fast32_t) -1 == UINT_FAST32_MAX ? 1 : -1;
17741 int check_uint_fast64: (uint_fast64_t) -1 == UINT_FAST64_MAX ? 1 : -1;
17742 int check_uintptr: (uintptr_t) -1 == UINTPTR_MAX ? 1 : -1;
17743 int check_uintmax: (uintmax_t) -1 == UINTMAX_MAX ? 1 : -1;
17744 int check_size: (size_t) -1 == SIZE_MAX ? 1 : -1;
17745 };
17746
17747 int
17748 main ()
17749 {
17750
17751 ;
17752 return 0;
17753 }
17754 _ACEOF
17755 if ac_fn_c_try_compile "$LINENO"; then :
17756 if test "$cross_compiling" = yes; then :
17757 gl_cv_header_working_stdint_h=yes
17758
17759 else
17760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17761 /* end confdefs.h. */
17762
17763
17764 #define __STDC_LIMIT_MACROS 1 /* to make it work also in C++ mode */
17765 #define __STDC_CONSTANT_MACROS 1 /* to make it work also in C++ mode */
17766 #define _GL_JUST_INCLUDE_SYSTEM_STDINT_H 1 /* work if build isn't clean */
17767 #include <stdint.h>
17768
17769
17770 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17771 included before <wchar.h>. */
17772 #include <stddef.h>
17773 #include <signal.h>
17774 #if HAVE_WCHAR_H
17775 # include <stdio.h>
17776 # include <time.h>
17777 # include <wchar.h>
17778 #endif
17779
17780
17781 #include <stdio.h>
17782 #include <string.h>
17783 #define MVAL(macro) MVAL1(macro)
17784 #define MVAL1(expression) #expression
17785 static const char *macro_values[] =
17786 {
17787 #ifdef INT8_MAX
17788 MVAL (INT8_MAX),
17789 #endif
17790 #ifdef INT16_MAX
17791 MVAL (INT16_MAX),
17792 #endif
17793 #ifdef INT32_MAX
17794 MVAL (INT32_MAX),
17795 #endif
17796 #ifdef INT64_MAX
17797 MVAL (INT64_MAX),
17798 #endif
17799 #ifdef UINT8_MAX
17800 MVAL (UINT8_MAX),
17801 #endif
17802 #ifdef UINT16_MAX
17803 MVAL (UINT16_MAX),
17804 #endif
17805 #ifdef UINT32_MAX
17806 MVAL (UINT32_MAX),
17807 #endif
17808 #ifdef UINT64_MAX
17809 MVAL (UINT64_MAX),
17810 #endif
17811 NULL
17812 };
17813
17814 int
17815 main ()
17816 {
17817
17818 const char **mv;
17819 for (mv = macro_values; *mv != NULL; mv++)
17820 {
17821 const char *value = *mv;
17822 /* Test whether it looks like a cast expression. */
17823 if (strncmp (value, "((unsigned int)"/*)*/, 15) == 0
17824 || strncmp (value, "((unsigned short)"/*)*/, 17) == 0
17825 || strncmp (value, "((unsigned char)"/*)*/, 16) == 0
17826 || strncmp (value, "((int)"/*)*/, 6) == 0
17827 || strncmp (value, "((signed short)"/*)*/, 15) == 0
17828 || strncmp (value, "((signed char)"/*)*/, 14) == 0)
17829 return mv - macro_values + 1;
17830 }
17831 return 0;
17832
17833 ;
17834 return 0;
17835 }
17836 _ACEOF
17837 if ac_fn_c_try_run "$LINENO"; then :
17838 gl_cv_header_working_stdint_h=yes
17839 fi
17840 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17841 conftest.$ac_objext conftest.beam conftest.$ac_ext
17842 fi
17843
17844
17845 fi
17846 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17847
17848 fi
17849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_stdint_h" >&5
17850 $as_echo "$gl_cv_header_working_stdint_h" >&6; }
17851 fi
17852 if test "$gl_cv_header_working_stdint_h" = yes; then
17853 STDINT_H=
17854 else
17855 for ac_header in sys/inttypes.h sys/bitypes.h
17856 do :
17857 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
17858 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
17859 eval as_val=\$$as_ac_Header
17860 if test "x$as_val" = x""yes; then :
17861 cat >>confdefs.h <<_ACEOF
17862 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
17863 _ACEOF
17864
17865 fi
17866
17867 done
17868
17869 if test $ac_cv_header_sys_inttypes_h = yes; then
17870 HAVE_SYS_INTTYPES_H=1
17871 else
17872 HAVE_SYS_INTTYPES_H=0
17873 fi
17874
17875 if test $ac_cv_header_sys_bitypes_h = yes; then
17876 HAVE_SYS_BITYPES_H=1
17877 else
17878 HAVE_SYS_BITYPES_H=0
17879 fi
17880
17881
17882
17883
17884 if test $APPLE_UNIVERSAL_BUILD = 0; then
17885
17886
17887 for gltype in ptrdiff_t size_t ; do
17888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
17889 $as_echo_n "checking for bit size of $gltype... " >&6; }
17890 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
17891 $as_echo_n "(cached) " >&6
17892 else
17893 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
17894 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17895 included before <wchar.h>. */
17896 #include <stddef.h>
17897 #include <signal.h>
17898 #if HAVE_WCHAR_H
17899 # include <stdio.h>
17900 # include <time.h>
17901 # include <wchar.h>
17902 #endif
17903
17904 #include <limits.h>"; then :
17905
17906 else
17907 result=unknown
17908 fi
17909
17910 eval gl_cv_bitsizeof_${gltype}=\$result
17911
17912 fi
17913 eval ac_res=\$gl_cv_bitsizeof_${gltype}
17914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17915 $as_echo "$ac_res" >&6; }
17916 eval result=\$gl_cv_bitsizeof_${gltype}
17917 if test $result = unknown; then
17918 result=0
17919 fi
17920 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
17921 cat >>confdefs.h <<_ACEOF
17922 #define BITSIZEOF_${GLTYPE} $result
17923 _ACEOF
17924
17925 eval BITSIZEOF_${GLTYPE}=\$result
17926 done
17927
17928
17929 fi
17930
17931
17932 for gltype in sig_atomic_t wchar_t wint_t ; do
17933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for bit size of $gltype" >&5
17934 $as_echo_n "checking for bit size of $gltype... " >&6; }
17935 if { as_var=gl_cv_bitsizeof_${gltype}; eval "test \"\${$as_var+set}\" = set"; }; then :
17936 $as_echo_n "(cached) " >&6
17937 else
17938 if ac_fn_c_compute_int "$LINENO" "sizeof ($gltype) * CHAR_BIT" "result" "
17939 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17940 included before <wchar.h>. */
17941 #include <stddef.h>
17942 #include <signal.h>
17943 #if HAVE_WCHAR_H
17944 # include <stdio.h>
17945 # include <time.h>
17946 # include <wchar.h>
17947 #endif
17948
17949 #include <limits.h>"; then :
17950
17951 else
17952 result=unknown
17953 fi
17954
17955 eval gl_cv_bitsizeof_${gltype}=\$result
17956
17957 fi
17958 eval ac_res=\$gl_cv_bitsizeof_${gltype}
17959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
17960 $as_echo "$ac_res" >&6; }
17961 eval result=\$gl_cv_bitsizeof_${gltype}
17962 if test $result = unknown; then
17963 result=0
17964 fi
17965 GLTYPE=`echo "$gltype" | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
17966 cat >>confdefs.h <<_ACEOF
17967 #define BITSIZEOF_${GLTYPE} $result
17968 _ACEOF
17969
17970 eval BITSIZEOF_${GLTYPE}=\$result
17971 done
17972
17973
17974
17975
17976 for gltype in sig_atomic_t wchar_t wint_t ; do
17977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $gltype is signed" >&5
17978 $as_echo_n "checking whether $gltype is signed... " >&6; }
17979 if { as_var=gl_cv_type_${gltype}_signed; eval "test \"\${$as_var+set}\" = set"; }; then :
17980 $as_echo_n "(cached) " >&6
17981 else
17982 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17983 /* end confdefs.h. */
17984
17985 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
17986 included before <wchar.h>. */
17987 #include <stddef.h>
17988 #include <signal.h>
17989 #if HAVE_WCHAR_H
17990 # include <stdio.h>
17991 # include <time.h>
17992 # include <wchar.h>
17993 #endif
17994
17995 int verify[2 * (($gltype) -1 < ($gltype) 0) - 1];
17996 int
17997 main ()
17998 {
17999
18000 ;
18001 return 0;
18002 }
18003 _ACEOF
18004 if ac_fn_c_try_compile "$LINENO"; then :
18005 result=yes
18006 else
18007 result=no
18008 fi
18009 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18010 eval gl_cv_type_${gltype}_signed=\$result
18011
18012 fi
18013 eval ac_res=\$gl_cv_type_${gltype}_signed
18014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18015 $as_echo "$ac_res" >&6; }
18016 eval result=\$gl_cv_type_${gltype}_signed
18017 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18018 if test "$result" = yes; then
18019 cat >>confdefs.h <<_ACEOF
18020 #define HAVE_SIGNED_${GLTYPE} 1
18021 _ACEOF
18022
18023 eval HAVE_SIGNED_${GLTYPE}=1
18024 else
18025 eval HAVE_SIGNED_${GLTYPE}=0
18026 fi
18027 done
18028
18029
18030 gl_cv_type_ptrdiff_t_signed=yes
18031 gl_cv_type_size_t_signed=no
18032 if test $APPLE_UNIVERSAL_BUILD = 0; then
18033
18034
18035 for gltype in ptrdiff_t size_t ; do
18036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18037 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18038 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18039 $as_echo_n "(cached) " >&6
18040 else
18041 eval gl_cv_type_${gltype}_suffix=no
18042 eval result=\$gl_cv_type_${gltype}_signed
18043 if test "$result" = yes; then
18044 glsufu=
18045 else
18046 glsufu=u
18047 fi
18048 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18049 case $glsuf in
18050 '') gltype1='int';;
18051 l) gltype1='long int';;
18052 ll) gltype1='long long int';;
18053 i64) gltype1='__int64';;
18054 u) gltype1='unsigned int';;
18055 ul) gltype1='unsigned long int';;
18056 ull) gltype1='unsigned long long int';;
18057 ui64)gltype1='unsigned __int64';;
18058 esac
18059 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18060 /* end confdefs.h. */
18061
18062 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18063 included before <wchar.h>. */
18064 #include <stddef.h>
18065 #include <signal.h>
18066 #if HAVE_WCHAR_H
18067 # include <stdio.h>
18068 # include <time.h>
18069 # include <wchar.h>
18070 #endif
18071
18072 extern $gltype foo;
18073 extern $gltype1 foo;
18074 int
18075 main ()
18076 {
18077
18078 ;
18079 return 0;
18080 }
18081 _ACEOF
18082 if ac_fn_c_try_compile "$LINENO"; then :
18083 eval gl_cv_type_${gltype}_suffix=\$glsuf
18084 fi
18085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18086 eval result=\$gl_cv_type_${gltype}_suffix
18087 test "$result" != no && break
18088 done
18089 fi
18090 eval ac_res=\$gl_cv_type_${gltype}_suffix
18091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18092 $as_echo "$ac_res" >&6; }
18093 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18094 eval result=\$gl_cv_type_${gltype}_suffix
18095 test "$result" = no && result=
18096 eval ${GLTYPE}_SUFFIX=\$result
18097 cat >>confdefs.h <<_ACEOF
18098 #define ${GLTYPE}_SUFFIX $result
18099 _ACEOF
18100
18101 done
18102
18103
18104 fi
18105
18106
18107 for gltype in sig_atomic_t wchar_t wint_t ; do
18108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $gltype integer literal suffix" >&5
18109 $as_echo_n "checking for $gltype integer literal suffix... " >&6; }
18110 if { as_var=gl_cv_type_${gltype}_suffix; eval "test \"\${$as_var+set}\" = set"; }; then :
18111 $as_echo_n "(cached) " >&6
18112 else
18113 eval gl_cv_type_${gltype}_suffix=no
18114 eval result=\$gl_cv_type_${gltype}_signed
18115 if test "$result" = yes; then
18116 glsufu=
18117 else
18118 glsufu=u
18119 fi
18120 for glsuf in "$glsufu" ${glsufu}l ${glsufu}ll ${glsufu}i64; do
18121 case $glsuf in
18122 '') gltype1='int';;
18123 l) gltype1='long int';;
18124 ll) gltype1='long long int';;
18125 i64) gltype1='__int64';;
18126 u) gltype1='unsigned int';;
18127 ul) gltype1='unsigned long int';;
18128 ull) gltype1='unsigned long long int';;
18129 ui64)gltype1='unsigned __int64';;
18130 esac
18131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18132 /* end confdefs.h. */
18133
18134 /* BSD/OS 4.0.1 has a bug: <stddef.h>, <stdio.h> and <time.h> must be
18135 included before <wchar.h>. */
18136 #include <stddef.h>
18137 #include <signal.h>
18138 #if HAVE_WCHAR_H
18139 # include <stdio.h>
18140 # include <time.h>
18141 # include <wchar.h>
18142 #endif
18143
18144 extern $gltype foo;
18145 extern $gltype1 foo;
18146 int
18147 main ()
18148 {
18149
18150 ;
18151 return 0;
18152 }
18153 _ACEOF
18154 if ac_fn_c_try_compile "$LINENO"; then :
18155 eval gl_cv_type_${gltype}_suffix=\$glsuf
18156 fi
18157 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18158 eval result=\$gl_cv_type_${gltype}_suffix
18159 test "$result" != no && break
18160 done
18161 fi
18162 eval ac_res=\$gl_cv_type_${gltype}_suffix
18163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
18164 $as_echo "$ac_res" >&6; }
18165 GLTYPE=`echo $gltype | tr 'abcdefghijklmnopqrstuvwxyz ' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ_'`
18166 eval result=\$gl_cv_type_${gltype}_suffix
18167 test "$result" = no && result=
18168 eval ${GLTYPE}_SUFFIX=\$result
18169 cat >>confdefs.h <<_ACEOF
18170 #define ${GLTYPE}_SUFFIX $result
18171 _ACEOF
18172
18173 done
18174
18175
18176
18177 if test $BITSIZEOF_WINT_T -lt 32; then
18178 BITSIZEOF_WINT_T=32
18179 fi
18180
18181 STDINT_H=stdint.h
18182 fi
18183
18184 if test -n "$STDINT_H"; then
18185 GL_GENERATE_STDINT_H_TRUE=
18186 GL_GENERATE_STDINT_H_FALSE='#'
18187 else
18188 GL_GENERATE_STDINT_H_TRUE='#'
18189 GL_GENERATE_STDINT_H_FALSE=
18190 fi
18191
18192
18193
18194
18195
18196 GNULIB_IMAXABS=0;
18197 GNULIB_IMAXDIV=0;
18198 GNULIB_STRTOIMAX=0;
18199 GNULIB_STRTOUMAX=0;
18200 HAVE_DECL_IMAXABS=1;
18201 HAVE_DECL_IMAXDIV=1;
18202 HAVE_DECL_STRTOIMAX=1;
18203 HAVE_DECL_STRTOUMAX=1;
18204 INT32_MAX_LT_INTMAX_MAX=1;
18205 INT64_MAX_EQ_LONG_MAX='defined _LP64';
18206 PRI_MACROS_BROKEN=0;
18207 PRIPTR_PREFIX=__PRIPTR_PREFIX;
18208 UINT32_MAX_LT_UINTMAX_MAX=1;
18209 UINT64_MAX_EQ_ULONG_MAX='defined _LP64';
18210
18211
18212
18213
18214
18215
18216
18217
18218
18219
18220
18221
18222
18223
18224
18225 if test $gl_cv_have_include_next = yes; then
18226 gl_cv_next_inttypes_h='<'inttypes.h'>'
18227 else
18228 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <inttypes.h>" >&5
18229 $as_echo_n "checking absolute name of <inttypes.h>... " >&6; }
18230 if test "${gl_cv_next_inttypes_h+set}" = set; then :
18231 $as_echo_n "(cached) " >&6
18232 else
18233
18234 if test $ac_cv_header_inttypes_h = yes; then
18235
18236
18237 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18238 /* end confdefs.h. */
18239 #include <inttypes.h>
18240
18241 _ACEOF
18242 case "$host_os" in
18243 aix*) gl_absname_cpp="$ac_cpp -C" ;;
18244 *) gl_absname_cpp="$ac_cpp" ;;
18245 esac
18246
18247 case "$host_os" in
18248 mingw*)
18249 gl_dirsep_regex='[/\\]'
18250 ;;
18251 *)
18252 gl_dirsep_regex='/'
18253 ;;
18254 esac
18255
18256 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'inttypes.h|{
18257 s|.*"\(.*'"${gl_dirsep_regex}"'inttypes.h\)".*|\1|
18258 s|^/[^/]|//&|
18259 p
18260 q
18261 }'
18262 gl_cv_next_inttypes_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
18263 sed -n "$gl_absolute_header_sed"`'"'
18264 else
18265 gl_cv_next_inttypes_h='<'inttypes.h'>'
18266 fi
18267
18268
18269 fi
18270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_inttypes_h" >&5
18271 $as_echo "$gl_cv_next_inttypes_h" >&6; }
18272 fi
18273 NEXT_INTTYPES_H=$gl_cv_next_inttypes_h
18274
18275 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
18276 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
18277 gl_next_as_first_directive='<'inttypes.h'>'
18278 else
18279 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
18280 gl_next_as_first_directive=$gl_cv_next_inttypes_h
18281 fi
18282 NEXT_AS_FIRST_DIRECTIVE_INTTYPES_H=$gl_next_as_first_directive
18283
18284
18285
18286
18287
18288
18289
18290
18291 $as_echo "#define GL_TRIGGER_STDC_LIMIT_MACROS 1" >>confdefs.h
18292
18293
18294
18295
18296
18297
18298 GNULIB_FCHMODAT=0;
18299 GNULIB_FSTAT=0;
18300 GNULIB_FSTATAT=0;
18301 GNULIB_FUTIMENS=0;
18302 GNULIB_LCHMOD=0;
18303 GNULIB_LSTAT=0;
18304 GNULIB_MKDIRAT=0;
18305 GNULIB_MKFIFO=0;
18306 GNULIB_MKFIFOAT=0;
18307 GNULIB_MKNOD=0;
18308 GNULIB_MKNODAT=0;
18309 GNULIB_STAT=0;
18310 GNULIB_UTIMENSAT=0;
18311 HAVE_FCHMODAT=1;
18312 HAVE_FSTATAT=1;
18313 HAVE_FUTIMENS=1;
18314 HAVE_LCHMOD=1;
18315 HAVE_LSTAT=1;
18316 HAVE_MKDIRAT=1;
18317 HAVE_MKFIFO=1;
18318 HAVE_MKFIFOAT=1;
18319 HAVE_MKNOD=1;
18320 HAVE_MKNODAT=1;
18321 HAVE_UTIMENSAT=1;
18322 REPLACE_FSTAT=0;
18323 REPLACE_FSTATAT=0;
18324 REPLACE_FUTIMENS=0;
18325 REPLACE_LSTAT=0;
18326 REPLACE_MKDIR=0;
18327 REPLACE_MKFIFO=0;
18328 REPLACE_MKNOD=0;
18329 REPLACE_STAT=0;
18330 REPLACE_UTIMENSAT=0;
18331
18332
18333
18334
18335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether lstat correctly handles trailing slash" >&5
18336 $as_echo_n "checking whether lstat correctly handles trailing slash... " >&6; }
18337 if test "${gl_cv_func_lstat_dereferences_slashed_symlink+set}" = set; then :
18338 $as_echo_n "(cached) " >&6
18339 else
18340 rm -f conftest.sym conftest.file
18341 echo >conftest.file
18342 if test "$as_ln_s" = "ln -s" && ln -s conftest.file conftest.sym; then
18343 if test "$cross_compiling" = yes; then :
18344 # When cross-compiling, be pessimistic so we will end up using the
18345 # replacement version of lstat that checks for trailing slashes and
18346 # calls lstat a second time when necessary.
18347 gl_cv_func_lstat_dereferences_slashed_symlink=no
18348
18349 else
18350 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18351 /* end confdefs.h. */
18352 $ac_includes_default
18353 int
18354 main ()
18355 {
18356 struct stat sbuf;
18357 /* Linux will dereference the symlink and fail, as required by
18358 POSIX. That is better in the sense that it means we will not
18359 have to compile and use the lstat wrapper. */
18360 return lstat ("conftest.sym/", &sbuf) == 0;
18361
18362 ;
18363 return 0;
18364 }
18365 _ACEOF
18366 if ac_fn_c_try_run "$LINENO"; then :
18367 gl_cv_func_lstat_dereferences_slashed_symlink=yes
18368 else
18369 gl_cv_func_lstat_dereferences_slashed_symlink=no
18370 fi
18371 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18372 conftest.$ac_objext conftest.beam conftest.$ac_ext
18373 fi
18374
18375 else
18376 # If the 'ln -s' command failed, then we probably don't even
18377 # have an lstat function.
18378 gl_cv_func_lstat_dereferences_slashed_symlink=no
18379 fi
18380 rm -f conftest.sym conftest.file
18381
18382 fi
18383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_lstat_dereferences_slashed_symlink" >&5
18384 $as_echo "$gl_cv_func_lstat_dereferences_slashed_symlink" >&6; }
18385 test $gl_cv_func_lstat_dereferences_slashed_symlink = yes &&
18386
18387 cat >>confdefs.h <<_ACEOF
18388 #define LSTAT_FOLLOWS_SLASHED_SYMLINK 1
18389 _ACEOF
18390
18391
18392
18393 GNULIB_MKTIME=0;
18394 GNULIB_NANOSLEEP=0;
18395 GNULIB_STRPTIME=0;
18396 GNULIB_TIMEGM=0;
18397 GNULIB_TIME_R=0;
18398 HAVE_DECL_LOCALTIME_R=1;
18399 HAVE_NANOSLEEP=1;
18400 HAVE_STRPTIME=1;
18401 HAVE_TIMEGM=1;
18402 REPLACE_LOCALTIME_R=GNULIB_PORTCHECK;
18403 REPLACE_MKTIME=GNULIB_PORTCHECK;
18404 REPLACE_NANOSLEEP=GNULIB_PORTCHECK;
18405 REPLACE_TIMEGM=GNULIB_PORTCHECK;
18406
18407
18408
18409
18410
18411
18412 GNULIB_PTHREAD_SIGMASK=0;
18413 GNULIB_RAISE=0;
18414 GNULIB_SIGNAL_H_SIGPIPE=0;
18415 GNULIB_SIGPROCMASK=0;
18416 GNULIB_SIGACTION=0;
18417 HAVE_POSIX_SIGNALBLOCKING=1;
18418 HAVE_PTHREAD_SIGMASK=1;
18419 HAVE_RAISE=1;
18420 HAVE_SIGSET_T=1;
18421 HAVE_SIGINFO_T=1;
18422 HAVE_SIGACTION=1;
18423 HAVE_STRUCT_SIGACTION_SA_SIGACTION=1;
18424
18425 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=1;
18426
18427 HAVE_SIGHANDLER_T=1;
18428 REPLACE_PTHREAD_SIGMASK=0;
18429 REPLACE_RAISE=0;
18430
18431
18432
18433
18434 ac_fn_c_check_type "$LINENO" "sigset_t" "ac_cv_type_sigset_t" "
18435 #include <signal.h>
18436 /* Mingw defines sigset_t not in <signal.h>, but in <sys/types.h>. */
18437 #include <sys/types.h>
18438
18439 "
18440 if test "x$ac_cv_type_sigset_t" = x""yes; then :
18441
18442 cat >>confdefs.h <<_ACEOF
18443 #define HAVE_SIGSET_T 1
18444 _ACEOF
18445
18446 gl_cv_type_sigset_t=yes
18447 else
18448 gl_cv_type_sigset_t=no
18449 fi
18450
18451 if test $gl_cv_type_sigset_t != yes; then
18452 HAVE_SIGSET_T=0
18453 fi
18454
18455
18456
18457
18458
18459 if test $ac_cv_header_sys_socket_h = no; then
18460 for ac_header in ws2tcpip.h
18461 do :
18462 ac_fn_c_check_header_mongrel "$LINENO" "ws2tcpip.h" "ac_cv_header_ws2tcpip_h" "$ac_includes_default"
18463 if test "x$ac_cv_header_ws2tcpip_h" = x""yes; then :
18464 cat >>confdefs.h <<_ACEOF
18465 #define HAVE_WS2TCPIP_H 1
18466 _ACEOF
18467
18468 fi
18469
18470 done
18471
18472 fi
18473
18474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdbool.h that conforms to C99" >&5
18475 $as_echo_n "checking for stdbool.h that conforms to C99... " >&6; }
18476 if test "${ac_cv_header_stdbool_h+set}" = set; then :
18477 $as_echo_n "(cached) " >&6
18478 else
18479 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18480 /* end confdefs.h. */
18481
18482 #include <stdbool.h>
18483 #ifndef bool
18484 "error: bool is not defined"
18485 #endif
18486 #ifndef false
18487 "error: false is not defined"
18488 #endif
18489 #if false
18490 "error: false is not 0"
18491 #endif
18492 #ifndef true
18493 "error: true is not defined"
18494 #endif
18495 #if true != 1
18496 "error: true is not 1"
18497 #endif
18498 #ifndef __bool_true_false_are_defined
18499 "error: __bool_true_false_are_defined is not defined"
18500 #endif
18501
18502 struct s { _Bool s: 1; _Bool t; } s;
18503
18504 char a[true == 1 ? 1 : -1];
18505 char b[false == 0 ? 1 : -1];
18506 char c[__bool_true_false_are_defined == 1 ? 1 : -1];
18507 char d[(bool) 0.5 == true ? 1 : -1];
18508 /* See body of main program for 'e'. */
18509 char f[(_Bool) 0.0 == false ? 1 : -1];
18510 char g[true];
18511 char h[sizeof (_Bool)];
18512 char i[sizeof s.t];
18513 enum { j = false, k = true, l = false * true, m = true * 256 };
18514 /* The following fails for
18515 HP aC++/ANSI C B3910B A.05.55 [Dec 04 2003]. */
18516 _Bool n[m];
18517 char o[sizeof n == m * sizeof n[0] ? 1 : -1];
18518 char p[-1 - (_Bool) 0 < 0 && -1 - (bool) 0 < 0 ? 1 : -1];
18519 /* Catch a bug in an HP-UX C compiler. See
18520 http://gcc.gnu.org/ml/gcc-patches/2003-12/msg02303.html
18521 http://lists.gnu.org/archive/html/bug-coreutils/2005-11/msg00161.html
18522 */
18523 _Bool q = true;
18524 _Bool *pq = &q;
18525
18526 int
18527 main ()
18528 {
18529
18530 bool e = &s;
18531 *pq |= q;
18532 *pq |= ! q;
18533 /* Refer to every declared value, to avoid compiler optimizations. */
18534 return (!a + !b + !c + !d + !e + !f + !g + !h + !i + !!j + !k + !!l
18535 + !m + !n + !o + !p + !q + !pq);
18536
18537 ;
18538 return 0;
18539 }
18540 _ACEOF
18541 if ac_fn_c_try_compile "$LINENO"; then :
18542 ac_cv_header_stdbool_h=yes
18543 else
18544 ac_cv_header_stdbool_h=no
18545 fi
18546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18547 fi
18548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdbool_h" >&5
18549 $as_echo "$ac_cv_header_stdbool_h" >&6; }
18550 ac_fn_c_check_type "$LINENO" "_Bool" "ac_cv_type__Bool" "$ac_includes_default"
18551 if test "x$ac_cv_type__Bool" = x""yes; then :
18552
18553 cat >>confdefs.h <<_ACEOF
18554 #define HAVE__BOOL 1
18555 _ACEOF
18556
18557
18558 fi
18559
18560
18561
18562 REPLACE_NULL=0;
18563 HAVE_WCHAR_T=1;
18564
18565
18566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
18567 $as_echo_n "checking for wchar_t... " >&6; }
18568 if test "${gt_cv_c_wchar_t+set}" = set; then :
18569 $as_echo_n "(cached) " >&6
18570 else
18571 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18572 /* end confdefs.h. */
18573 #include <stddef.h>
18574 wchar_t foo = (wchar_t)'\0';
18575 int
18576 main ()
18577 {
18578
18579 ;
18580 return 0;
18581 }
18582 _ACEOF
18583 if ac_fn_c_try_compile "$LINENO"; then :
18584 gt_cv_c_wchar_t=yes
18585 else
18586 gt_cv_c_wchar_t=no
18587 fi
18588 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18589 fi
18590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
18591 $as_echo "$gt_cv_c_wchar_t" >&6; }
18592 if test $gt_cv_c_wchar_t = yes; then
18593
18594 $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h
18595
18596 fi
18597
18598
18599 GNULIB_DPRINTF=0;
18600 GNULIB_FCLOSE=0;
18601 GNULIB_FDOPEN=0;
18602 GNULIB_FFLUSH=0;
18603 GNULIB_FGETC=0;
18604 GNULIB_FGETS=0;
18605 GNULIB_FOPEN=0;
18606 GNULIB_FPRINTF=0;
18607 GNULIB_FPRINTF_POSIX=0;
18608 GNULIB_FPURGE=0;
18609 GNULIB_FPUTC=0;
18610 GNULIB_FPUTS=0;
18611 GNULIB_FREAD=0;
18612 GNULIB_FREOPEN=0;
18613 GNULIB_FSCANF=0;
18614 GNULIB_FSEEK=0;
18615 GNULIB_FSEEKO=0;
18616 GNULIB_FTELL=0;
18617 GNULIB_FTELLO=0;
18618 GNULIB_FWRITE=0;
18619 GNULIB_GETC=0;
18620 GNULIB_GETCHAR=0;
18621 GNULIB_GETDELIM=0;
18622 GNULIB_GETLINE=0;
18623 GNULIB_GETS=0;
18624 GNULIB_OBSTACK_PRINTF=0;
18625 GNULIB_OBSTACK_PRINTF_POSIX=0;
18626 GNULIB_PCLOSE=0;
18627 GNULIB_PERROR=0;
18628 GNULIB_POPEN=0;
18629 GNULIB_PRINTF=0;
18630 GNULIB_PRINTF_POSIX=0;
18631 GNULIB_PUTC=0;
18632 GNULIB_PUTCHAR=0;
18633 GNULIB_PUTS=0;
18634 GNULIB_REMOVE=0;
18635 GNULIB_RENAME=0;
18636 GNULIB_RENAMEAT=0;
18637 GNULIB_SCANF=0;
18638 GNULIB_SNPRINTF=0;
18639 GNULIB_SPRINTF_POSIX=0;
18640 GNULIB_STDIO_H_NONBLOCKING=0;
18641 GNULIB_STDIO_H_SIGPIPE=0;
18642 GNULIB_TMPFILE=0;
18643 GNULIB_VASPRINTF=0;
18644 GNULIB_VFSCANF=0;
18645 GNULIB_VSCANF=0;
18646 GNULIB_VDPRINTF=0;
18647 GNULIB_VFPRINTF=0;
18648 GNULIB_VFPRINTF_POSIX=0;
18649 GNULIB_VPRINTF=0;
18650 GNULIB_VPRINTF_POSIX=0;
18651 GNULIB_VSNPRINTF=0;
18652 GNULIB_VSPRINTF_POSIX=0;
18653 HAVE_DECL_FPURGE=1;
18654 HAVE_DECL_FSEEKO=1;
18655 HAVE_DECL_FTELLO=1;
18656 HAVE_DECL_GETDELIM=1;
18657 HAVE_DECL_GETLINE=1;
18658 HAVE_DECL_OBSTACK_PRINTF=1;
18659 HAVE_DECL_SNPRINTF=1;
18660 HAVE_DECL_VSNPRINTF=1;
18661 HAVE_DPRINTF=1;
18662 HAVE_FSEEKO=1;
18663 HAVE_FTELLO=1;
18664 HAVE_PCLOSE=1;
18665 HAVE_POPEN=1;
18666 HAVE_RENAMEAT=1;
18667 HAVE_VASPRINTF=1;
18668 HAVE_VDPRINTF=1;
18669 REPLACE_DPRINTF=0;
18670 REPLACE_FCLOSE=0;
18671 REPLACE_FDOPEN=0;
18672 REPLACE_FFLUSH=0;
18673 REPLACE_FOPEN=0;
18674 REPLACE_FPRINTF=0;
18675 REPLACE_FPURGE=0;
18676 REPLACE_FREOPEN=0;
18677 REPLACE_FSEEK=0;
18678 REPLACE_FSEEKO=0;
18679 REPLACE_FTELL=0;
18680 REPLACE_FTELLO=0;
18681 REPLACE_GETDELIM=0;
18682 REPLACE_GETLINE=0;
18683 REPLACE_OBSTACK_PRINTF=0;
18684 REPLACE_PERROR=0;
18685 REPLACE_POPEN=0;
18686 REPLACE_PRINTF=0;
18687 REPLACE_REMOVE=0;
18688 REPLACE_RENAME=0;
18689 REPLACE_RENAMEAT=0;
18690 REPLACE_SNPRINTF=0;
18691 REPLACE_SPRINTF=0;
18692 REPLACE_STDIO_READ_FUNCS=0;
18693 REPLACE_STDIO_WRITE_FUNCS=0;
18694 REPLACE_TMPFILE=0;
18695 REPLACE_VASPRINTF=0;
18696 REPLACE_VDPRINTF=0;
18697 REPLACE_VFPRINTF=0;
18698 REPLACE_VPRINTF=0;
18699 REPLACE_VSNPRINTF=0;
18700 REPLACE_VSPRINTF=0;
18701
18702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
18703 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
18704 if test "${ac_cv_struct_tm+set}" = set; then :
18705 $as_echo_n "(cached) " >&6
18706 else
18707 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18708 /* end confdefs.h. */
18709 #include <sys/types.h>
18710 #include <time.h>
18711
18712 int
18713 main ()
18714 {
18715 struct tm tm;
18716 int *p = &tm.tm_sec;
18717 return !p;
18718 ;
18719 return 0;
18720 }
18721 _ACEOF
18722 if ac_fn_c_try_compile "$LINENO"; then :
18723 ac_cv_struct_tm=time.h
18724 else
18725 ac_cv_struct_tm=sys/time.h
18726 fi
18727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18728 fi
18729 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
18730 $as_echo "$ac_cv_struct_tm" >&6; }
18731 if test $ac_cv_struct_tm = sys/time.h; then
18732
18733 $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h
18734
18735 fi
18736
18737 ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
18738 #include <$ac_cv_struct_tm>
18739
18740 "
18741 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then :
18742
18743 cat >>confdefs.h <<_ACEOF
18744 #define HAVE_STRUCT_TM_TM_ZONE 1
18745 _ACEOF
18746
18747
18748 fi
18749
18750 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
18751
18752 $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h
18753
18754 else
18755 ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
18756 "
18757 if test "x$ac_cv_have_decl_tzname" = x""yes; then :
18758 ac_have_decl=1
18759 else
18760 ac_have_decl=0
18761 fi
18762
18763 cat >>confdefs.h <<_ACEOF
18764 #define HAVE_DECL_TZNAME $ac_have_decl
18765 _ACEOF
18766
18767 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
18768 $as_echo_n "checking for tzname... " >&6; }
18769 if test "${ac_cv_var_tzname+set}" = set; then :
18770 $as_echo_n "(cached) " >&6
18771 else
18772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18773 /* end confdefs.h. */
18774 #include <time.h>
18775 #if !HAVE_DECL_TZNAME
18776 extern char *tzname[];
18777 #endif
18778
18779 int
18780 main ()
18781 {
18782 return tzname[0][0];
18783 ;
18784 return 0;
18785 }
18786 _ACEOF
18787 if ac_fn_c_try_link "$LINENO"; then :
18788 ac_cv_var_tzname=yes
18789 else
18790 ac_cv_var_tzname=no
18791 fi
18792 rm -f core conftest.err conftest.$ac_objext \
18793 conftest$ac_exeext conftest.$ac_ext
18794 fi
18795 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
18796 $as_echo "$ac_cv_var_tzname" >&6; }
18797 if test $ac_cv_var_tzname = yes; then
18798
18799 $as_echo "#define HAVE_TZNAME 1" >>confdefs.h
18800
18801 fi
18802 fi
18803
18804
18805 ac_fn_c_check_member "$LINENO" "struct tm" "tm_gmtoff" "ac_cv_member_struct_tm_tm_gmtoff" "#include <time.h>
18806 "
18807 if test "x$ac_cv_member_struct_tm_tm_gmtoff" = x""yes; then :
18808
18809 $as_echo "#define HAVE_TM_GMTOFF 1" >>confdefs.h
18810
18811 fi
18812
18813
18814
18815
18816
18817
18818 ac_fn_c_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default"
18819 if test "x$ac_cv_have_decl_strtoimax" = x""yes; then :
18820 ac_have_decl=1
18821 else
18822 ac_have_decl=0
18823 fi
18824
18825 cat >>confdefs.h <<_ACEOF
18826 #define HAVE_DECL_STRTOIMAX $ac_have_decl
18827 _ACEOF
18828
18829
18830
18831 ac_fn_c_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default"
18832 if test "x$ac_cv_have_decl_strtoumax" = x""yes; then :
18833 ac_have_decl=1
18834 else
18835 ac_have_decl=0
18836 fi
18837
18838 cat >>confdefs.h <<_ACEOF
18839 #define HAVE_DECL_STRTOUMAX $ac_have_decl
18840 _ACEOF
18841
18842
18843
18844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
18845 $as_echo_n "checking whether stat file-mode macros are broken... " >&6; }
18846 if test "${ac_cv_header_stat_broken+set}" = set; then :
18847 $as_echo_n "(cached) " >&6
18848 else
18849 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18850 /* end confdefs.h. */
18851 #include <sys/types.h>
18852 #include <sys/stat.h>
18853
18854 #if defined S_ISBLK && defined S_IFDIR
18855 extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
18856 #endif
18857
18858 #if defined S_ISBLK && defined S_IFCHR
18859 extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
18860 #endif
18861
18862 #if defined S_ISLNK && defined S_IFREG
18863 extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
18864 #endif
18865
18866 #if defined S_ISSOCK && defined S_IFREG
18867 extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
18868 #endif
18869
18870 _ACEOF
18871 if ac_fn_c_try_compile "$LINENO"; then :
18872 ac_cv_header_stat_broken=no
18873 else
18874 ac_cv_header_stat_broken=yes
18875 fi
18876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18877 fi
18878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
18879 $as_echo "$ac_cv_header_stat_broken" >&6; }
18880 if test $ac_cv_header_stat_broken = yes; then
18881
18882 $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h
18883
18884 fi
18885
18886
18887
18888 ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18889 if test "x$ac_cv_type_mode_t" = x""yes; then :
18890
18891 else
18892
18893 cat >>confdefs.h <<_ACEOF
18894 #define mode_t int
18895 _ACEOF
18896
18897 fi
18898
18899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
18900 $as_echo_n "checking for C/C++ restrict keyword... " >&6; }
18901 if test "${ac_cv_c_restrict+set}" = set; then :
18902 $as_echo_n "(cached) " >&6
18903 else
18904 ac_cv_c_restrict=no
18905 # The order here caters to the fact that C++ does not require restrict.
18906 for ac_kw in __restrict __restrict__ _Restrict restrict; do
18907 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18908 /* end confdefs.h. */
18909 typedef int * int_ptr;
18910 int foo (int_ptr $ac_kw ip) {
18911 return ip[0];
18912 }
18913 int
18914 main ()
18915 {
18916 int s[1];
18917 int * $ac_kw t = s;
18918 t[0] = 0;
18919 return foo(t)
18920 ;
18921 return 0;
18922 }
18923 _ACEOF
18924 if ac_fn_c_try_compile "$LINENO"; then :
18925 ac_cv_c_restrict=$ac_kw
18926 fi
18927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18928 test "$ac_cv_c_restrict" != no && break
18929 done
18930
18931 fi
18932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
18933 $as_echo "$ac_cv_c_restrict" >&6; }
18934
18935 case $ac_cv_c_restrict in
18936 restrict) ;;
18937 no) $as_echo "#define restrict /**/" >>confdefs.h
18938 ;;
18939 *) cat >>confdefs.h <<_ACEOF
18940 #define restrict $ac_cv_c_restrict
18941 _ACEOF
18942 ;;
18943 esac
18944
18945
18946
18947
18948
18949 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
18950 $as_echo_n "checking for struct timespec in <time.h>... " >&6; }
18951 if test "${gl_cv_sys_struct_timespec_in_time_h+set}" = set; then :
18952 $as_echo_n "(cached) " >&6
18953 else
18954 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18955 /* end confdefs.h. */
18956 #include <time.h>
18957
18958 int
18959 main ()
18960 {
18961 static struct timespec x; x.tv_sec = x.tv_nsec;
18962 ;
18963 return 0;
18964 }
18965 _ACEOF
18966 if ac_fn_c_try_compile "$LINENO"; then :
18967 gl_cv_sys_struct_timespec_in_time_h=yes
18968 else
18969 gl_cv_sys_struct_timespec_in_time_h=no
18970 fi
18971 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18972 fi
18973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_time_h" >&5
18974 $as_echo "$gl_cv_sys_struct_timespec_in_time_h" >&6; }
18975
18976 TIME_H_DEFINES_STRUCT_TIMESPEC=0
18977 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
18978 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
18979 if test $gl_cv_sys_struct_timespec_in_time_h = yes; then
18980 TIME_H_DEFINES_STRUCT_TIMESPEC=1
18981 else
18982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
18983 $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; }
18984 if test "${gl_cv_sys_struct_timespec_in_sys_time_h+set}" = set; then :
18985 $as_echo_n "(cached) " >&6
18986 else
18987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18988 /* end confdefs.h. */
18989 #include <sys/time.h>
18990
18991 int
18992 main ()
18993 {
18994 static struct timespec x; x.tv_sec = x.tv_nsec;
18995 ;
18996 return 0;
18997 }
18998 _ACEOF
18999 if ac_fn_c_try_compile "$LINENO"; then :
19000 gl_cv_sys_struct_timespec_in_sys_time_h=yes
19001 else
19002 gl_cv_sys_struct_timespec_in_sys_time_h=no
19003 fi
19004 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19005 fi
19006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_sys_time_h" >&5
19007 $as_echo "$gl_cv_sys_struct_timespec_in_sys_time_h" >&6; }
19008 if test $gl_cv_sys_struct_timespec_in_sys_time_h = yes; then
19009 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
19010 else
19011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
19012 $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; }
19013 if test "${gl_cv_sys_struct_timespec_in_pthread_h+set}" = set; then :
19014 $as_echo_n "(cached) " >&6
19015 else
19016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19017 /* end confdefs.h. */
19018 #include <pthread.h>
19019
19020 int
19021 main ()
19022 {
19023 static struct timespec x; x.tv_sec = x.tv_nsec;
19024 ;
19025 return 0;
19026 }
19027 _ACEOF
19028 if ac_fn_c_try_compile "$LINENO"; then :
19029 gl_cv_sys_struct_timespec_in_pthread_h=yes
19030 else
19031 gl_cv_sys_struct_timespec_in_pthread_h=no
19032 fi
19033 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19034 fi
19035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_sys_struct_timespec_in_pthread_h" >&5
19036 $as_echo "$gl_cv_sys_struct_timespec_in_pthread_h" >&6; }
19037 if test $gl_cv_sys_struct_timespec_in_pthread_h = yes; then
19038 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
19039 fi
19040 fi
19041 fi
19042
19043
19044
19045
19046
19047
19048
19049
19050
19051
19052
19053
19054
19055
19056
19057 if test $gl_cv_have_include_next = yes; then
19058 gl_cv_next_time_h='<'time.h'>'
19059 else
19060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <time.h>" >&5
19061 $as_echo_n "checking absolute name of <time.h>... " >&6; }
19062 if test "${gl_cv_next_time_h+set}" = set; then :
19063 $as_echo_n "(cached) " >&6
19064 else
19065
19066 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19067 /* end confdefs.h. */
19068 #include <time.h>
19069
19070 _ACEOF
19071 case "$host_os" in
19072 aix*) gl_absname_cpp="$ac_cpp -C" ;;
19073 *) gl_absname_cpp="$ac_cpp" ;;
19074 esac
19075
19076 case "$host_os" in
19077 mingw*)
19078 gl_dirsep_regex='[/\\]'
19079 ;;
19080 *)
19081 gl_dirsep_regex='/'
19082 ;;
19083 esac
19084
19085 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'time.h|{
19086 s|.*"\(.*'"${gl_dirsep_regex}"'time.h\)".*|\1|
19087 s|^/[^/]|//&|
19088 p
19089 q
19090 }'
19091 gl_cv_next_time_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
19092 sed -n "$gl_absolute_header_sed"`'"'
19093
19094
19095 fi
19096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_time_h" >&5
19097 $as_echo "$gl_cv_next_time_h" >&6; }
19098 fi
19099 NEXT_TIME_H=$gl_cv_next_time_h
19100
19101 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
19102 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
19103 gl_next_as_first_directive='<'time.h'>'
19104 else
19105 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
19106 gl_next_as_first_directive=$gl_cv_next_time_h
19107 fi
19108 NEXT_AS_FIRST_DIRECTIVE_TIME_H=$gl_next_as_first_directive
19109
19110
19111
19112
19113
19114
19115 ac_fn_c_check_decl "$LINENO" "localtime_r" "ac_cv_have_decl_localtime_r" "$ac_includes_default"
19116 if test "x$ac_cv_have_decl_localtime_r" = x""yes; then :
19117 ac_have_decl=1
19118 else
19119 ac_have_decl=0
19120 fi
19121
19122 cat >>confdefs.h <<_ACEOF
19123 #define HAVE_DECL_LOCALTIME_R $ac_have_decl
19124 _ACEOF
19125
19126
19127
19128
19129 if false; then
19130 GL_COND_LIBTOOL_TRUE=
19131 GL_COND_LIBTOOL_FALSE='#'
19132 else
19133 GL_COND_LIBTOOL_TRUE='#'
19134 GL_COND_LIBTOOL_FALSE=
19135 fi
19136
19137 gl_cond_libtool=false
19138 gl_libdeps=
19139 gl_ltlibdeps=
19140 gl_m4_base='m4'
19141
19142
19143
19144
19145
19146
19147
19148
19149
19150 gl_source_base='lib'
19151
19152
19153 if test $ac_cv_func_alloca_works = no; then
19154 :
19155 fi
19156
19157 # Define an additional variable used in the Makefile substitution.
19158 if test $ac_cv_working_alloca_h = yes; then
19159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca as a compiler built-in" >&5
19160 $as_echo_n "checking for alloca as a compiler built-in... " >&6; }
19161 if test "${gl_cv_rpl_alloca+set}" = set; then :
19162 $as_echo_n "(cached) " >&6
19163 else
19164
19165 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19166 /* end confdefs.h. */
19167
19168 #if defined __GNUC__ || defined _AIX || defined _MSC_VER
19169 Need own alloca
19170 #endif
19171
19172 _ACEOF
19173 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19174 $EGREP "Need own alloca" >/dev/null 2>&1; then :
19175 gl_cv_rpl_alloca=yes
19176 else
19177 gl_cv_rpl_alloca=no
19178 fi
19179 rm -f conftest*
19180
19181
19182 fi
19183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_rpl_alloca" >&5
19184 $as_echo "$gl_cv_rpl_alloca" >&6; }
19185 if test $gl_cv_rpl_alloca = yes; then
19186
19187 $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h
19188
19189 ALLOCA_H=alloca.h
19190 else
19191 ALLOCA_H=
19192 fi
19193 else
19194 ALLOCA_H=alloca.h
19195 fi
19196
19197 if test -n "$ALLOCA_H"; then
19198 GL_GENERATE_ALLOCA_H_TRUE=
19199 GL_GENERATE_ALLOCA_H_FALSE='#'
19200 else
19201 GL_GENERATE_ALLOCA_H_TRUE='#'
19202 GL_GENERATE_ALLOCA_H_FALSE=
19203 fi
19204
19205
19206
19207
19208
19209
19210 :
19211
19212
19213
19214
19215 :
19216
19217
19218
19219
19220
19221
19222
19223
19224
19225
19226
19227
19228
19229
19230
19231 $as_echo "#define HAVE_DUP2 1" >>confdefs.h
19232
19233
19234 if test $HAVE_DUP2 = 1; then
19235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether dup2 works" >&5
19236 $as_echo_n "checking whether dup2 works... " >&6; }
19237 if test "${gl_cv_func_dup2_works+set}" = set; then :
19238 $as_echo_n "(cached) " >&6
19239 else
19240 if test "$cross_compiling" = yes; then :
19241 case "$host_os" in
19242 mingw*) # on this platform, dup2 always returns 0 for success
19243 gl_cv_func_dup2_works=no;;
19244 cygwin*) # on cygwin 1.5.x, dup2(1,1) returns 0
19245 gl_cv_func_dup2_works=no;;
19246 linux*) # On linux between 2008-07-27 and 2009-05-11, dup2 of a
19247 # closed fd may yield -EBADF instead of -1 / errno=EBADF.
19248 gl_cv_func_dup2_works=no;;
19249 freebsd*) # on FreeBSD 6.1, dup2(1,1000000) gives EMFILE, not EBADF.
19250 gl_cv_func_dup2_works=no;;
19251 haiku*) # on Haiku alpha 2, dup2(1, 1) resets FD_CLOEXEC.
19252 gl_cv_func_dup2_works=no;;
19253 *) gl_cv_func_dup2_works=yes;;
19254 esac
19255 else
19256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19257 /* end confdefs.h. */
19258
19259 #include <unistd.h>
19260 #include <fcntl.h>
19261 #include <errno.h>
19262 int
19263 main ()
19264 {
19265 int result = 0;
19266 #ifdef FD_CLOEXEC
19267 if (fcntl (1, F_SETFD, FD_CLOEXEC) == -1)
19268 result |= 1;
19269 #endif
19270 if (dup2 (1, 1) == 0)
19271 result |= 2;
19272 #ifdef FD_CLOEXEC
19273 if (fcntl (1, F_GETFD) != FD_CLOEXEC)
19274 result |= 4;
19275 #endif
19276 close (0);
19277 if (dup2 (0, 0) != -1)
19278 result |= 8;
19279 /* Many gnulib modules require POSIX conformance of EBADF. */
19280 if (dup2 (2, 1000000) == -1 && errno != EBADF)
19281 result |= 16;
19282 return result;
19283
19284 ;
19285 return 0;
19286 }
19287
19288 _ACEOF
19289 if ac_fn_c_try_run "$LINENO"; then :
19290 gl_cv_func_dup2_works=yes
19291 else
19292 gl_cv_func_dup2_works=no
19293 fi
19294 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19295 conftest.$ac_objext conftest.beam conftest.$ac_ext
19296 fi
19297
19298
19299 fi
19300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_dup2_works" >&5
19301 $as_echo "$gl_cv_func_dup2_works" >&6; }
19302 if test "$gl_cv_func_dup2_works" = no; then
19303 REPLACE_DUP2=1
19304 fi
19305 fi
19306
19307
19308 if test $HAVE_DUP2 = 0 || test $REPLACE_DUP2 = 1; then
19309
19310
19311
19312
19313
19314
19315
19316
19317 gl_LIBOBJS="$gl_LIBOBJS dup2.$ac_objext"
19318
19319
19320 fi
19321
19322
19323
19324
19325
19326 GNULIB_DUP2=1
19327
19328
19329
19330
19331
19332
19333
19334
19335
19336
19337
19338 # Persuade glibc <stdlib.h> to declare getloadavg().
19339
19340
19341 gl_save_LIBS=$LIBS
19342
19343 # getloadvg is present in libc on glibc >= 2.2, MacOS X, FreeBSD >= 2.0,
19344 # NetBSD >= 0.9, OpenBSD >= 2.0, Solaris >= 7.
19345 HAVE_GETLOADAVG=1
19346 ac_fn_c_check_func "$LINENO" "getloadavg" "ac_cv_func_getloadavg"
19347 if test "x$ac_cv_func_getloadavg" = x""yes; then :
19348
19349 else
19350 gl_func_getloadavg_done=no
19351
19352 # Some systems with -lutil have (and need) -lkvm as well, some do not.
19353 # On Solaris, -lkvm requires nlist from -lelf, so check that first
19354 # to get the right answer into the cache.
19355 # For kstat on solaris, we need to test for libelf and libkvm to force the
19356 # definition of SVR4 below.
19357 if test $gl_func_getloadavg_done = no; then
19358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for elf_begin in -lelf" >&5
19359 $as_echo_n "checking for elf_begin in -lelf... " >&6; }
19360 if test "${ac_cv_lib_elf_elf_begin+set}" = set; then :
19361 $as_echo_n "(cached) " >&6
19362 else
19363 ac_check_lib_save_LIBS=$LIBS
19364 LIBS="-lelf $LIBS"
19365 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19366 /* end confdefs.h. */
19367
19368 /* Override any GCC internal prototype to avoid an error.
19369 Use char because int might match the return type of a GCC
19370 builtin and then its argument prototype would still apply. */
19371 #ifdef __cplusplus
19372 extern "C"
19373 #endif
19374 char elf_begin ();
19375 int
19376 main ()
19377 {
19378 return elf_begin ();
19379 ;
19380 return 0;
19381 }
19382 _ACEOF
19383 if ac_fn_c_try_link "$LINENO"; then :
19384 ac_cv_lib_elf_elf_begin=yes
19385 else
19386 ac_cv_lib_elf_elf_begin=no
19387 fi
19388 rm -f core conftest.err conftest.$ac_objext \
19389 conftest$ac_exeext conftest.$ac_ext
19390 LIBS=$ac_check_lib_save_LIBS
19391 fi
19392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_elf_elf_begin" >&5
19393 $as_echo "$ac_cv_lib_elf_elf_begin" >&6; }
19394 if test "x$ac_cv_lib_elf_elf_begin" = x""yes; then :
19395 LIBS="-lelf $LIBS"
19396 fi
19397
19398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kvm_open in -lkvm" >&5
19399 $as_echo_n "checking for kvm_open in -lkvm... " >&6; }
19400 if test "${ac_cv_lib_kvm_kvm_open+set}" = set; then :
19401 $as_echo_n "(cached) " >&6
19402 else
19403 ac_check_lib_save_LIBS=$LIBS
19404 LIBS="-lkvm $LIBS"
19405 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19406 /* end confdefs.h. */
19407
19408 /* Override any GCC internal prototype to avoid an error.
19409 Use char because int might match the return type of a GCC
19410 builtin and then its argument prototype would still apply. */
19411 #ifdef __cplusplus
19412 extern "C"
19413 #endif
19414 char kvm_open ();
19415 int
19416 main ()
19417 {
19418 return kvm_open ();
19419 ;
19420 return 0;
19421 }
19422 _ACEOF
19423 if ac_fn_c_try_link "$LINENO"; then :
19424 ac_cv_lib_kvm_kvm_open=yes
19425 else
19426 ac_cv_lib_kvm_kvm_open=no
19427 fi
19428 rm -f core conftest.err conftest.$ac_objext \
19429 conftest$ac_exeext conftest.$ac_ext
19430 LIBS=$ac_check_lib_save_LIBS
19431 fi
19432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kvm_kvm_open" >&5
19433 $as_echo "$ac_cv_lib_kvm_kvm_open" >&6; }
19434 if test "x$ac_cv_lib_kvm_kvm_open" = x""yes; then :
19435 LIBS="-lkvm $LIBS"
19436 fi
19437
19438 # Check for the 4.4BSD definition of getloadavg.
19439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lutil" >&5
19440 $as_echo_n "checking for getloadavg in -lutil... " >&6; }
19441 if test "${ac_cv_lib_util_getloadavg+set}" = set; then :
19442 $as_echo_n "(cached) " >&6
19443 else
19444 ac_check_lib_save_LIBS=$LIBS
19445 LIBS="-lutil $LIBS"
19446 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19447 /* end confdefs.h. */
19448
19449 /* Override any GCC internal prototype to avoid an error.
19450 Use char because int might match the return type of a GCC
19451 builtin and then its argument prototype would still apply. */
19452 #ifdef __cplusplus
19453 extern "C"
19454 #endif
19455 char getloadavg ();
19456 int
19457 main ()
19458 {
19459 return getloadavg ();
19460 ;
19461 return 0;
19462 }
19463 _ACEOF
19464 if ac_fn_c_try_link "$LINENO"; then :
19465 ac_cv_lib_util_getloadavg=yes
19466 else
19467 ac_cv_lib_util_getloadavg=no
19468 fi
19469 rm -f core conftest.err conftest.$ac_objext \
19470 conftest$ac_exeext conftest.$ac_ext
19471 LIBS=$ac_check_lib_save_LIBS
19472 fi
19473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_util_getloadavg" >&5
19474 $as_echo "$ac_cv_lib_util_getloadavg" >&6; }
19475 if test "x$ac_cv_lib_util_getloadavg" = x""yes; then :
19476 LIBS="-lutil $LIBS" gl_func_getloadavg_done=yes
19477 fi
19478
19479 fi
19480
19481 if test $gl_func_getloadavg_done = no; then
19482 # There is a commonly available library for RS/6000 AIX.
19483 # Since it is not a standard part of AIX, it might be installed locally.
19484 gl_getloadavg_LIBS=$LIBS
19485 LIBS="-L/usr/local/lib $LIBS"
19486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getloadavg in -lgetloadavg" >&5
19487 $as_echo_n "checking for getloadavg in -lgetloadavg... " >&6; }
19488 if test "${ac_cv_lib_getloadavg_getloadavg+set}" = set; then :
19489 $as_echo_n "(cached) " >&6
19490 else
19491 ac_check_lib_save_LIBS=$LIBS
19492 LIBS="-lgetloadavg $LIBS"
19493 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19494 /* end confdefs.h. */
19495
19496 /* Override any GCC internal prototype to avoid an error.
19497 Use char because int might match the return type of a GCC
19498 builtin and then its argument prototype would still apply. */
19499 #ifdef __cplusplus
19500 extern "C"
19501 #endif
19502 char getloadavg ();
19503 int
19504 main ()
19505 {
19506 return getloadavg ();
19507 ;
19508 return 0;
19509 }
19510 _ACEOF
19511 if ac_fn_c_try_link "$LINENO"; then :
19512 ac_cv_lib_getloadavg_getloadavg=yes
19513 else
19514 ac_cv_lib_getloadavg_getloadavg=no
19515 fi
19516 rm -f core conftest.err conftest.$ac_objext \
19517 conftest$ac_exeext conftest.$ac_ext
19518 LIBS=$ac_check_lib_save_LIBS
19519 fi
19520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_getloadavg_getloadavg" >&5
19521 $as_echo "$ac_cv_lib_getloadavg_getloadavg" >&6; }
19522 if test "x$ac_cv_lib_getloadavg_getloadavg" = x""yes; then :
19523 LIBS="-lgetloadavg $LIBS" gl_func_getloadavg_done=yes
19524 else
19525 LIBS=$gl_getloadavg_LIBS
19526 fi
19527
19528 fi
19529
19530 # Set up the replacement function if necessary.
19531 if test $gl_func_getloadavg_done = no; then
19532 HAVE_GETLOADAVG=0
19533
19534 # Solaris has libkstat which does not require root.
19535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for kstat_open in -lkstat" >&5
19536 $as_echo_n "checking for kstat_open in -lkstat... " >&6; }
19537 if test "${ac_cv_lib_kstat_kstat_open+set}" = set; then :
19538 $as_echo_n "(cached) " >&6
19539 else
19540 ac_check_lib_save_LIBS=$LIBS
19541 LIBS="-lkstat $LIBS"
19542 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19543 /* end confdefs.h. */
19544
19545 /* Override any GCC internal prototype to avoid an error.
19546 Use char because int might match the return type of a GCC
19547 builtin and then its argument prototype would still apply. */
19548 #ifdef __cplusplus
19549 extern "C"
19550 #endif
19551 char kstat_open ();
19552 int
19553 main ()
19554 {
19555 return kstat_open ();
19556 ;
19557 return 0;
19558 }
19559 _ACEOF
19560 if ac_fn_c_try_link "$LINENO"; then :
19561 ac_cv_lib_kstat_kstat_open=yes
19562 else
19563 ac_cv_lib_kstat_kstat_open=no
19564 fi
19565 rm -f core conftest.err conftest.$ac_objext \
19566 conftest$ac_exeext conftest.$ac_ext
19567 LIBS=$ac_check_lib_save_LIBS
19568 fi
19569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_kstat_kstat_open" >&5
19570 $as_echo "$ac_cv_lib_kstat_kstat_open" >&6; }
19571 if test "x$ac_cv_lib_kstat_kstat_open" = x""yes; then :
19572 cat >>confdefs.h <<_ACEOF
19573 #define HAVE_LIBKSTAT 1
19574 _ACEOF
19575
19576 LIBS="-lkstat $LIBS"
19577
19578 fi
19579
19580 test $ac_cv_lib_kstat_kstat_open = yes && gl_func_getloadavg_done=yes
19581
19582 # AIX has libperfstat which does not require root
19583 if test $gl_func_getloadavg_done = no; then
19584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for perfstat_cpu_total in -lperfstat" >&5
19585 $as_echo_n "checking for perfstat_cpu_total in -lperfstat... " >&6; }
19586 if test "${ac_cv_lib_perfstat_perfstat_cpu_total+set}" = set; then :
19587 $as_echo_n "(cached) " >&6
19588 else
19589 ac_check_lib_save_LIBS=$LIBS
19590 LIBS="-lperfstat $LIBS"
19591 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19592 /* end confdefs.h. */
19593
19594 /* Override any GCC internal prototype to avoid an error.
19595 Use char because int might match the return type of a GCC
19596 builtin and then its argument prototype would still apply. */
19597 #ifdef __cplusplus
19598 extern "C"
19599 #endif
19600 char perfstat_cpu_total ();
19601 int
19602 main ()
19603 {
19604 return perfstat_cpu_total ();
19605 ;
19606 return 0;
19607 }
19608 _ACEOF
19609 if ac_fn_c_try_link "$LINENO"; then :
19610 ac_cv_lib_perfstat_perfstat_cpu_total=yes
19611 else
19612 ac_cv_lib_perfstat_perfstat_cpu_total=no
19613 fi
19614 rm -f core conftest.err conftest.$ac_objext \
19615 conftest$ac_exeext conftest.$ac_ext
19616 LIBS=$ac_check_lib_save_LIBS
19617 fi
19618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_perfstat_perfstat_cpu_total" >&5
19619 $as_echo "$ac_cv_lib_perfstat_perfstat_cpu_total" >&6; }
19620 if test "x$ac_cv_lib_perfstat_perfstat_cpu_total" = x""yes; then :
19621 cat >>confdefs.h <<_ACEOF
19622 #define HAVE_LIBPERFSTAT 1
19623 _ACEOF
19624
19625 LIBS="-lperfstat $LIBS"
19626
19627 fi
19628
19629 test $ac_cv_lib_perfstat_perfstat_cpu_total = yes && gl_func_getloadavg_done=yes
19630 fi
19631
19632 if test $gl_func_getloadavg_done = no; then
19633 ac_fn_c_check_header_mongrel "$LINENO" "sys/dg_sys_info.h" "ac_cv_header_sys_dg_sys_info_h" "$ac_includes_default"
19634 if test "x$ac_cv_header_sys_dg_sys_info_h" = x""yes; then :
19635 gl_func_getloadavg_done=yes
19636
19637 $as_echo "#define DGUX 1" >>confdefs.h
19638
19639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dg_sys_info in -ldgc" >&5
19640 $as_echo_n "checking for dg_sys_info in -ldgc... " >&6; }
19641 if test "${ac_cv_lib_dgc_dg_sys_info+set}" = set; then :
19642 $as_echo_n "(cached) " >&6
19643 else
19644 ac_check_lib_save_LIBS=$LIBS
19645 LIBS="-ldgc $LIBS"
19646 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19647 /* end confdefs.h. */
19648
19649 /* Override any GCC internal prototype to avoid an error.
19650 Use char because int might match the return type of a GCC
19651 builtin and then its argument prototype would still apply. */
19652 #ifdef __cplusplus
19653 extern "C"
19654 #endif
19655 char dg_sys_info ();
19656 int
19657 main ()
19658 {
19659 return dg_sys_info ();
19660 ;
19661 return 0;
19662 }
19663 _ACEOF
19664 if ac_fn_c_try_link "$LINENO"; then :
19665 ac_cv_lib_dgc_dg_sys_info=yes
19666 else
19667 ac_cv_lib_dgc_dg_sys_info=no
19668 fi
19669 rm -f core conftest.err conftest.$ac_objext \
19670 conftest$ac_exeext conftest.$ac_ext
19671 LIBS=$ac_check_lib_save_LIBS
19672 fi
19673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dgc_dg_sys_info" >&5
19674 $as_echo "$ac_cv_lib_dgc_dg_sys_info" >&6; }
19675 if test "x$ac_cv_lib_dgc_dg_sys_info" = x""yes; then :
19676 cat >>confdefs.h <<_ACEOF
19677 #define HAVE_LIBDGC 1
19678 _ACEOF
19679
19680 LIBS="-ldgc $LIBS"
19681
19682 fi
19683
19684 fi
19685
19686
19687 fi
19688 fi
19689 fi
19690
19691
19692 if test "x$gl_save_LIBS" = x; then
19693 GETLOADAVG_LIBS=$LIBS
19694 else
19695 GETLOADAVG_LIBS=`echo "$LIBS" | sed "s!$gl_save_LIBS!!"`
19696 fi
19697 LIBS=$gl_save_LIBS
19698
19699
19700 # Test whether the system declares getloadavg. Solaris has the function
19701 # but declares it in <sys/loadavg.h>, not <stdlib.h>.
19702 for ac_header in sys/loadavg.h
19703 do :
19704 ac_fn_c_check_header_mongrel "$LINENO" "sys/loadavg.h" "ac_cv_header_sys_loadavg_h" "$ac_includes_default"
19705 if test "x$ac_cv_header_sys_loadavg_h" = x""yes; then :
19706 cat >>confdefs.h <<_ACEOF
19707 #define HAVE_SYS_LOADAVG_H 1
19708 _ACEOF
19709
19710 fi
19711
19712 done
19713
19714 if test $ac_cv_header_sys_loadavg_h = yes; then
19715 HAVE_SYS_LOADAVG_H=1
19716 else
19717 HAVE_SYS_LOADAVG_H=0
19718 fi
19719 ac_fn_c_check_decl "$LINENO" "getloadavg" "ac_cv_have_decl_getloadavg" "#if HAVE_SYS_LOADAVG_H
19720 # include <sys/loadavg.h>
19721 #endif
19722 #include <stdlib.h>
19723 "
19724 if test "x$ac_cv_have_decl_getloadavg" = x""yes; then :
19725
19726 else
19727 HAVE_DECL_GETLOADAVG=0
19728 fi
19729
19730
19731 if test $HAVE_GETLOADAVG = 0; then
19732
19733
19734
19735
19736
19737
19738
19739
19740 gl_LIBOBJS="$gl_LIBOBJS getloadavg.$ac_objext"
19741
19742
19743 # Figure out what our getloadavg.c needs.
19744
19745 # On HPUX9, an unprivileged user can get load averages this way.
19746 if test $gl_func_getloadavg_done = no; then
19747 for ac_func in pstat_getdynamic
19748 do :
19749 ac_fn_c_check_func "$LINENO" "pstat_getdynamic" "ac_cv_func_pstat_getdynamic"
19750 if test "x$ac_cv_func_pstat_getdynamic" = x""yes; then :
19751 cat >>confdefs.h <<_ACEOF
19752 #define HAVE_PSTAT_GETDYNAMIC 1
19753 _ACEOF
19754 gl_func_getloadavg_done=yes
19755 fi
19756 done
19757
19758 fi
19759
19760 # We cannot check for <dwarf.h>, because Solaris 2 does not use dwarf (it
19761 # uses stabs), but it is still SVR4. We cannot check for <elf.h> because
19762 # Irix 4.0.5F has the header but not the library.
19763 if test $gl_func_getloadavg_done = no && test "$ac_cv_lib_elf_elf_begin" = yes \
19764 && test "$ac_cv_lib_kvm_kvm_open" = yes; then
19765 gl_func_getloadavg_done=yes
19766
19767 $as_echo "#define SVR4 1" >>confdefs.h
19768
19769 fi
19770
19771 if test $gl_func_getloadavg_done = no; then
19772 ac_fn_c_check_header_mongrel "$LINENO" "inq_stats/cpustats.h" "ac_cv_header_inq_stats_cpustats_h" "$ac_includes_default"
19773 if test "x$ac_cv_header_inq_stats_cpustats_h" = x""yes; then :
19774 gl_func_getloadavg_done=yes
19775
19776 $as_echo "#define UMAX 1" >>confdefs.h
19777
19778
19779 $as_echo "#define UMAX4_3 1" >>confdefs.h
19780
19781 fi
19782
19783
19784 fi
19785
19786 if test $gl_func_getloadavg_done = no; then
19787 ac_fn_c_check_header_mongrel "$LINENO" "sys/cpustats.h" "ac_cv_header_sys_cpustats_h" "$ac_includes_default"
19788 if test "x$ac_cv_header_sys_cpustats_h" = x""yes; then :
19789 gl_func_getloadavg_done=yes; $as_echo "#define UMAX 1" >>confdefs.h
19790
19791 fi
19792
19793
19794 fi
19795
19796 if test $gl_func_getloadavg_done = no; then
19797 for ac_header in mach/mach.h
19798 do :
19799 ac_fn_c_check_header_mongrel "$LINENO" "mach/mach.h" "ac_cv_header_mach_mach_h" "$ac_includes_default"
19800 if test "x$ac_cv_header_mach_mach_h" = x""yes; then :
19801 cat >>confdefs.h <<_ACEOF
19802 #define HAVE_MACH_MACH_H 1
19803 _ACEOF
19804
19805 fi
19806
19807 done
19808
19809 fi
19810
19811 for ac_header in nlist.h
19812 do :
19813 ac_fn_c_check_header_mongrel "$LINENO" "nlist.h" "ac_cv_header_nlist_h" "$ac_includes_default"
19814 if test "x$ac_cv_header_nlist_h" = x""yes; then :
19815 cat >>confdefs.h <<_ACEOF
19816 #define HAVE_NLIST_H 1
19817 _ACEOF
19818 ac_fn_c_check_member "$LINENO" "struct nlist" "n_un.n_name" "ac_cv_member_struct_nlist_n_un_n_name" "#include <nlist.h>
19819 "
19820 if test "x$ac_cv_member_struct_nlist_n_un_n_name" = x""yes; then :
19821
19822 cat >>confdefs.h <<_ACEOF
19823 #define HAVE_STRUCT_NLIST_N_UN_N_NAME 1
19824 _ACEOF
19825
19826
19827 fi
19828
19829 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19830 /* end confdefs.h. */
19831 #include <nlist.h>
19832 int
19833 main ()
19834 {
19835 struct nlist x;
19836 #ifdef HAVE_STRUCT_NLIST_N_UN_N_NAME
19837 x.n_un.n_name = "";
19838 #else
19839 x.n_name = "";
19840 #endif
19841 ;
19842 return 0;
19843 }
19844 _ACEOF
19845 if ac_fn_c_try_link "$LINENO"; then :
19846
19847 $as_echo "#define N_NAME_POINTER 1" >>confdefs.h
19848
19849 fi
19850 rm -f core conftest.err conftest.$ac_objext \
19851 conftest$ac_exeext conftest.$ac_ext
19852
19853 fi
19854
19855 done
19856
19857 fi
19858
19859
19860
19861
19862
19863 GNULIB_GETLOADAVG=1
19864
19865
19866
19867
19868
19869
19870
19871
19872
19873
19874 if test $REPLACE_GETOPT = 1; then
19875
19876
19877
19878
19879
19880
19881
19882
19883 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
19884
19885
19886
19887
19888
19889
19890
19891
19892
19893 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
19894
19895
19896
19897
19898 fi
19899
19900
19901
19902
19903
19904 REPLACE_GETOPT=0
19905
19906
19907 if test -n "$gl_replace_getopt"; then :
19908
19909 REPLACE_GETOPT=1
19910
19911 fi
19912
19913
19914 if test $REPLACE_GETOPT = 1; then
19915
19916 GETOPT_H=getopt.h
19917
19918 $as_echo "#define __GETOPT_PREFIX rpl_" >>confdefs.h
19919
19920
19921
19922 GNULIB_UNISTD_H_GETOPT=1
19923 fi
19924
19925 if test $REPLACE_GETOPT = 1; then
19926
19927
19928
19929
19930
19931
19932
19933
19934 gl_LIBOBJS="$gl_LIBOBJS getopt.$ac_objext"
19935
19936
19937
19938
19939
19940
19941
19942
19943
19944 gl_LIBOBJS="$gl_LIBOBJS getopt1.$ac_objext"
19945
19946
19947
19948
19949 fi
19950
19951
19952
19953
19954
19955 if test $ac_cv_func_lstat = yes; then
19956
19957 if test $gl_cv_func_lstat_dereferences_slashed_symlink = no; then
19958 REPLACE_LSTAT=1
19959 fi
19960 else
19961 HAVE_LSTAT=0
19962 fi
19963
19964 if test $REPLACE_LSTAT = 1; then
19965
19966
19967
19968
19969
19970
19971
19972
19973 gl_LIBOBJS="$gl_LIBOBJS lstat.$ac_objext"
19974
19975
19976
19977 :
19978
19979 fi
19980
19981
19982
19983
19984
19985 GNULIB_LSTAT=1
19986
19987
19988
19989
19990
19991
19992
19993
19994
19995
19996
19997 if test $APPLE_UNIVERSAL_BUILD = 1; then
19998 # A universal build on Apple MacOS X platforms.
19999 # The test result would be 'yes' in 32-bit mode and 'no' in 64-bit mode.
20000 # But we need a configuration result that is valid in both modes.
20001 gl_cv_func_working_mktime=no
20002 fi
20003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
20004 $as_echo_n "checking for working mktime... " >&6; }
20005 if test "${gl_cv_func_working_mktime+set}" = set; then :
20006 $as_echo_n "(cached) " >&6
20007 else
20008 if test "$cross_compiling" = yes; then :
20009 gl_cv_func_working_mktime=no
20010 else
20011 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20012 /* end confdefs.h. */
20013 /* Test program from Paul Eggert and Tony Leneis. */
20014 #include <limits.h>
20015 #include <stdlib.h>
20016 #include <time.h>
20017
20018 #ifdef HAVE_UNISTD_H
20019 # include <unistd.h>
20020 #endif
20021
20022 #ifndef HAVE_ALARM
20023 # define alarm(X) /* empty */
20024 #endif
20025
20026 /* Work around redefinition to rpl_putenv by other config tests. */
20027 #undef putenv
20028
20029 static time_t time_t_max;
20030 static time_t time_t_min;
20031
20032 /* Values we'll use to set the TZ environment variable. */
20033 static char *tz_strings[] = {
20034 (char *) 0, "TZ=GMT0", "TZ=JST-9",
20035 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
20036 };
20037 #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
20038
20039 /* Return 0 if mktime fails to convert a date in the spring-forward gap.
20040 Based on a problem report from Andreas Jaeger. */
20041 static int
20042 spring_forward_gap ()
20043 {
20044 /* glibc (up to about 1998-10-07) failed this test. */
20045 struct tm tm;
20046
20047 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
20048 instead of "TZ=America/Vancouver" in order to detect the bug even
20049 on systems that don't support the Olson extension, or don't have the
20050 full zoneinfo tables installed. */
20051 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
20052
20053 tm.tm_year = 98;
20054 tm.tm_mon = 3;
20055 tm.tm_mday = 5;
20056 tm.tm_hour = 2;
20057 tm.tm_min = 0;
20058 tm.tm_sec = 0;
20059 tm.tm_isdst = -1;
20060 return mktime (&tm) != (time_t) -1;
20061 }
20062
20063 static int
20064 mktime_test1 (time_t now)
20065 {
20066 struct tm *lt;
20067 return ! (lt = localtime (&now)) || mktime (lt) == now;
20068 }
20069
20070 static int
20071 mktime_test (time_t now)
20072 {
20073 return (mktime_test1 (now)
20074 && mktime_test1 ((time_t) (time_t_max - now))
20075 && mktime_test1 ((time_t) (time_t_min + now)));
20076 }
20077
20078 static int
20079 irix_6_4_bug ()
20080 {
20081 /* Based on code from Ariel Faigon. */
20082 struct tm tm;
20083 tm.tm_year = 96;
20084 tm.tm_mon = 3;
20085 tm.tm_mday = 0;
20086 tm.tm_hour = 0;
20087 tm.tm_min = 0;
20088 tm.tm_sec = 0;
20089 tm.tm_isdst = -1;
20090 mktime (&tm);
20091 return tm.tm_mon == 2 && tm.tm_mday == 31;
20092 }
20093
20094 static int
20095 bigtime_test (int j)
20096 {
20097 struct tm tm;
20098 time_t now;
20099 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
20100 now = mktime (&tm);
20101 if (now != (time_t) -1)
20102 {
20103 struct tm *lt = localtime (&now);
20104 if (! (lt
20105 && lt->tm_year == tm.tm_year
20106 && lt->tm_mon == tm.tm_mon
20107 && lt->tm_mday == tm.tm_mday
20108 && lt->tm_hour == tm.tm_hour
20109 && lt->tm_min == tm.tm_min
20110 && lt->tm_sec == tm.tm_sec
20111 && lt->tm_yday == tm.tm_yday
20112 && lt->tm_wday == tm.tm_wday
20113 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
20114 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
20115 return 0;
20116 }
20117 return 1;
20118 }
20119
20120 static int
20121 year_2050_test ()
20122 {
20123 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
20124 ignoring leap seconds. */
20125 unsigned long int answer = 2527315200UL;
20126
20127 struct tm tm;
20128 time_t t;
20129 tm.tm_year = 2050 - 1900;
20130 tm.tm_mon = 2 - 1;
20131 tm.tm_mday = 1;
20132 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
20133 tm.tm_isdst = -1;
20134
20135 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
20136 instead of "TZ=America/Vancouver" in order to detect the bug even
20137 on systems that don't support the Olson extension, or don't have the
20138 full zoneinfo tables installed. */
20139 putenv ("TZ=PST8PDT,M4.1.0,M10.5.0");
20140
20141 t = mktime (&tm);
20142
20143 /* Check that the result is either a failure, or close enough
20144 to the correct answer that we can assume the discrepancy is
20145 due to leap seconds. */
20146 return (t == (time_t) -1
20147 || (0 < t && answer - 120 <= t && t <= answer + 120));
20148 }
20149
20150 int
20151 main ()
20152 {
20153 int result = 0;
20154 time_t t, delta;
20155 int i, j;
20156 int time_t_signed_magnitude = (time_t) ~ (time_t) 0 < (time_t) -1;
20157 int time_t_signed = ! ((time_t) 0 < (time_t) -1);
20158
20159 /* This test makes some buggy mktime implementations loop.
20160 Give up after 60 seconds; a mktime slower than that
20161 isn't worth using anyway. */
20162 alarm (60);
20163
20164 time_t_max = (! time_t_signed
20165 ? (time_t) -1
20166 : ((((time_t) 1 << (sizeof (time_t) * CHAR_BIT - 2)) - 1)
20167 * 2 + 1));
20168 time_t_min = (! time_t_signed
20169 ? (time_t) 0
20170 : time_t_signed_magnitude
20171 ? ~ (time_t) 0
20172 : ~ time_t_max);
20173
20174 delta = time_t_max / 997; /* a suitable prime number */
20175 for (i = 0; i < N_STRINGS; i++)
20176 {
20177 if (tz_strings[i])
20178 putenv (tz_strings[i]);
20179
20180 for (t = 0; t <= time_t_max - delta; t += delta)
20181 if (! mktime_test (t))
20182 result |= 1;
20183 if (! (mktime_test ((time_t) 1)
20184 && mktime_test ((time_t) (60 * 60))
20185 && mktime_test ((time_t) (60 * 60 * 24))))
20186 result |= 2;
20187
20188 for (j = 1; ; j <<= 1)
20189 if (! bigtime_test (j))
20190 result |= 4;
20191 else if (INT_MAX / 2 < j)
20192 break;
20193 if (! bigtime_test (INT_MAX))
20194 result |= 8;
20195 }
20196 if (! irix_6_4_bug ())
20197 result |= 16;
20198 if (! spring_forward_gap ())
20199 result |= 32;
20200 if (! year_2050_test ())
20201 result |= 64;
20202 return result;
20203 }
20204 _ACEOF
20205 if ac_fn_c_try_run "$LINENO"; then :
20206 gl_cv_func_working_mktime=yes
20207 else
20208 gl_cv_func_working_mktime=no
20209 fi
20210 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20211 conftest.$ac_objext conftest.beam conftest.$ac_ext
20212 fi
20213
20214
20215 fi
20216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_working_mktime" >&5
20217 $as_echo "$gl_cv_func_working_mktime" >&6; }
20218
20219 if test $gl_cv_func_working_mktime = no; then
20220 REPLACE_MKTIME=1
20221 else
20222 REPLACE_MKTIME=0
20223 fi
20224
20225 if test $REPLACE_MKTIME = 1; then
20226
20227
20228
20229
20230
20231
20232
20233
20234 gl_LIBOBJS="$gl_LIBOBJS mktime.$ac_objext"
20235
20236
20237
20238
20239 fi
20240
20241
20242
20243
20244
20245 GNULIB_MKTIME=1
20246
20247
20248
20249
20250
20251
20252
20253
20254 LIB_PTHREAD_SIGMASK=
20255
20256
20257 if test $ac_cv_func_pthread_sigmask = yes; then
20258 :
20259 else
20260 HAVE_PTHREAD_SIGMASK=0
20261 REPLACE_PTHREAD_SIGMASK=1
20262 fi
20263
20264
20265
20266
20267 if test $HAVE_PTHREAD_SIGMASK = 1; then
20268
20269
20270 if test -z "$LIB_PTHREAD_SIGMASK"; then
20271 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask works without -lpthread" >&5
20272 $as_echo_n "checking whether pthread_sigmask works without -lpthread... " >&6; }
20273 if test "${gl_cv_func_pthread_sigmask_in_libc_works+set}" = set; then :
20274 $as_echo_n "(cached) " >&6
20275 else
20276
20277 if test "$cross_compiling" = yes; then :
20278
20279 case "$host_os" in
20280 freebsd* | hpux* | solaris | solaris2.[2-9]*)
20281 gl_cv_func_pthread_sigmask_in_libc_works="guessing no";;
20282 *)
20283 gl_cv_func_pthread_sigmask_in_libc_works="guessing yes";;
20284 esac
20285
20286 else
20287 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20288 /* end confdefs.h. */
20289
20290 #include <pthread.h>
20291 #include <signal.h>
20292 #include <stddef.h>
20293 int main ()
20294 {
20295 sigset_t set;
20296 sigemptyset (&set);
20297 return pthread_sigmask (1729, &set, NULL) != 0;
20298 }
20299 _ACEOF
20300 if ac_fn_c_try_run "$LINENO"; then :
20301 gl_cv_func_pthread_sigmask_in_libc_works=no
20302 else
20303 gl_cv_func_pthread_sigmask_in_libc_works=yes
20304 fi
20305 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20306 conftest.$ac_objext conftest.beam conftest.$ac_ext
20307 fi
20308
20309
20310 fi
20311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_in_libc_works" >&5
20312 $as_echo "$gl_cv_func_pthread_sigmask_in_libc_works" >&6; }
20313 case "$gl_cv_func_pthread_sigmask_in_libc_works" in
20314 *no)
20315 REPLACE_PTHREAD_SIGMASK=1
20316
20317 $as_echo "#define PTHREAD_SIGMASK_INEFFECTIVE 1" >>confdefs.h
20318
20319 ;;
20320 esac
20321 fi
20322
20323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask returns error numbers" >&5
20324 $as_echo_n "checking whether pthread_sigmask returns error numbers... " >&6; }
20325 if test "${gl_cv_func_pthread_sigmask_return_works+set}" = set; then :
20326 $as_echo_n "(cached) " >&6
20327 else
20328
20329 gl_save_LIBS="$LIBS"
20330 LIBS="$LIBS $LIB_PTHREAD_SIGMASK"
20331 if test "$cross_compiling" = yes; then :
20332 case "$host_os" in
20333 cygwin*)
20334 gl_cv_func_pthread_sigmask_return_works="guessing no";;
20335 *)
20336 gl_cv_func_pthread_sigmask_return_works="guessing yes";;
20337 esac
20338
20339 else
20340 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20341 /* end confdefs.h. */
20342
20343 #include <pthread.h>
20344 #include <signal.h>
20345 #include <stddef.h>
20346 int main ()
20347 {
20348 sigset_t set;
20349 sigemptyset (&set);
20350 if (pthread_sigmask (1729, &set, NULL) == -1)
20351 return 1;
20352 return 0;
20353 }
20354 _ACEOF
20355 if ac_fn_c_try_run "$LINENO"; then :
20356 gl_cv_func_pthread_sigmask_return_works=yes
20357 else
20358 gl_cv_func_pthread_sigmask_return_works=no
20359 fi
20360 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20361 conftest.$ac_objext conftest.beam conftest.$ac_ext
20362 fi
20363
20364 LIBS="$gl_save_LIBS"
20365
20366 fi
20367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_return_works" >&5
20368 $as_echo "$gl_cv_func_pthread_sigmask_return_works" >&6; }
20369 case "$gl_cv_func_pthread_sigmask_return_works" in
20370 *no)
20371 REPLACE_PTHREAD_SIGMASK=1
20372
20373 $as_echo "#define PTHREAD_SIGMASK_FAILS_WITH_ERRNO 1" >>confdefs.h
20374
20375 ;;
20376 esac
20377
20378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pthread_sigmask unblocks signals correctly" >&5
20379 $as_echo_n "checking whether pthread_sigmask unblocks signals correctly... " >&6; }
20380 if test "${gl_cv_func_pthread_sigmask_unblock_works+set}" = set; then :
20381 $as_echo_n "(cached) " >&6
20382 else
20383
20384 case "$host_os" in
20385 irix*)
20386 gl_cv_func_pthread_sigmask_unblock_works="guessing no";;
20387 *)
20388 gl_cv_func_pthread_sigmask_unblock_works="guessing yes";;
20389 esac
20390 gl_save_LIBS="$LIBS"
20391 LIBS="$LIBS $LIBMULTITHREAD"
20392 if test "$cross_compiling" = yes; then :
20393 :
20394 else
20395 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20396 /* end confdefs.h. */
20397
20398 #include <pthread.h>
20399 #include <signal.h>
20400 #include <stdio.h>
20401 #include <stdlib.h>
20402 #include <unistd.h>
20403 static volatile int sigint_occurred;
20404 static void
20405 sigint_handler (int sig)
20406 {
20407 sigint_occurred++;
20408 }
20409 int main ()
20410 {
20411 sigset_t set;
20412 int pid = getpid ();
20413 char command[80];
20414 signal (SIGINT, sigint_handler);
20415 sigemptyset (&set);
20416 sigaddset (&set, SIGINT);
20417 if (!(pthread_sigmask (SIG_BLOCK, &set, NULL) == 0))
20418 return 1;
20419 sprintf (command, "sh -c 'sleep 1; kill -%d %d' &", SIGINT, pid);
20420 if (!(system (command) == 0))
20421 return 2;
20422 sleep (2);
20423 if (!(sigint_occurred == 0))
20424 return 3;
20425 if (!(pthread_sigmask (SIG_UNBLOCK, &set, NULL) == 0))
20426 return 4;
20427 if (!(sigint_occurred == 1)) /* This fails on IRIX. */
20428 return 5;
20429 return 0;
20430 }
20431 _ACEOF
20432 if ac_fn_c_try_run "$LINENO"; then :
20433 :
20434 else
20435 gl_cv_func_pthread_sigmask_unblock_works=no
20436 fi
20437 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20438 conftest.$ac_objext conftest.beam conftest.$ac_ext
20439 fi
20440
20441 LIBS="$gl_save_LIBS"
20442
20443 fi
20444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_pthread_sigmask_unblock_works" >&5
20445 $as_echo "$gl_cv_func_pthread_sigmask_unblock_works" >&6; }
20446 case "$gl_cv_func_pthread_sigmask_unblock_works" in
20447 *no)
20448 REPLACE_PTHREAD_SIGMASK=1
20449
20450 $as_echo "#define PTHREAD_SIGMASK_UNBLOCK_BUG 1" >>confdefs.h
20451
20452 ;;
20453 esac
20454 fi
20455
20456 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
20457
20458
20459
20460
20461
20462
20463
20464
20465 gl_LIBOBJS="$gl_LIBOBJS pthread_sigmask.$ac_objext"
20466
20467
20468 if test $HAVE_PTHREAD_SIGMASK = 1; then
20469
20470 $as_echo "#define HAVE_PTHREAD_SIGMASK 1" >>confdefs.h
20471
20472 fi
20473
20474 fi
20475
20476
20477
20478
20479
20480 GNULIB_PTHREAD_SIGMASK=1
20481
20482
20483
20484
20485
20486
20487
20488
20489 if test $ac_cv_func_readlink = no; then
20490 HAVE_READLINK=0
20491 else
20492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink signature is correct" >&5
20493 $as_echo_n "checking whether readlink signature is correct... " >&6; }
20494 if test "${gl_cv_decl_readlink_works+set}" = set; then :
20495 $as_echo_n "(cached) " >&6
20496 else
20497 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20498 /* end confdefs.h. */
20499 #include <unistd.h>
20500 /* Cause compilation failure if original declaration has wrong type. */
20501 ssize_t readlink (const char *, char *, size_t);
20502 int
20503 main ()
20504 {
20505
20506 ;
20507 return 0;
20508 }
20509 _ACEOF
20510 if ac_fn_c_try_compile "$LINENO"; then :
20511 gl_cv_decl_readlink_works=yes
20512 else
20513 gl_cv_decl_readlink_works=no
20514 fi
20515 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20516 fi
20517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_readlink_works" >&5
20518 $as_echo "$gl_cv_decl_readlink_works" >&6; }
20519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether readlink handles trailing slash correctly" >&5
20520 $as_echo_n "checking whether readlink handles trailing slash correctly... " >&6; }
20521 if test "${gl_cv_func_readlink_works+set}" = set; then :
20522 $as_echo_n "(cached) " >&6
20523 else
20524 # We have readlink, so assume ln -s works.
20525 ln -s conftest.no-such conftest.link
20526 ln -s conftest.link conftest.lnk2
20527 if test "$cross_compiling" = yes; then :
20528 gl_cv_func_readlink_works="guessing no"
20529 else
20530 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20531 /* end confdefs.h. */
20532 #include <unistd.h>
20533
20534 int
20535 main ()
20536 {
20537 char buf[20];
20538 return readlink ("conftest.lnk2/", buf, sizeof buf) != -1;
20539 ;
20540 return 0;
20541 }
20542 _ACEOF
20543 if ac_fn_c_try_run "$LINENO"; then :
20544 gl_cv_func_readlink_works=yes
20545 else
20546 gl_cv_func_readlink_works=no
20547 fi
20548 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20549 conftest.$ac_objext conftest.beam conftest.$ac_ext
20550 fi
20551
20552 rm -f conftest.link conftest.lnk2
20553 fi
20554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_readlink_works" >&5
20555 $as_echo "$gl_cv_func_readlink_works" >&6; }
20556 if test "$gl_cv_func_readlink_works" != yes; then
20557
20558 $as_echo "#define READLINK_TRAILING_SLASH_BUG 1" >>confdefs.h
20559
20560 REPLACE_READLINK=1
20561 elif test "$gl_cv_decl_readlink_works" != yes; then
20562 REPLACE_READLINK=1
20563 fi
20564 fi
20565
20566 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
20567
20568
20569
20570
20571
20572
20573
20574
20575 gl_LIBOBJS="$gl_LIBOBJS readlink.$ac_objext"
20576
20577
20578 :
20579
20580 fi
20581
20582
20583
20584
20585
20586 GNULIB_READLINK=1
20587
20588
20589
20590
20591
20592
20593
20594
20595
20596
20597
20598
20599
20600
20601
20602
20603 if test $gl_cv_have_include_next = yes; then
20604 gl_cv_next_signal_h='<'signal.h'>'
20605 else
20606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <signal.h>" >&5
20607 $as_echo_n "checking absolute name of <signal.h>... " >&6; }
20608 if test "${gl_cv_next_signal_h+set}" = set; then :
20609 $as_echo_n "(cached) " >&6
20610 else
20611
20612 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20613 /* end confdefs.h. */
20614 #include <signal.h>
20615
20616 _ACEOF
20617 case "$host_os" in
20618 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20619 *) gl_absname_cpp="$ac_cpp" ;;
20620 esac
20621
20622 case "$host_os" in
20623 mingw*)
20624 gl_dirsep_regex='[/\\]'
20625 ;;
20626 *)
20627 gl_dirsep_regex='/'
20628 ;;
20629 esac
20630
20631 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'signal.h|{
20632 s|.*"\(.*'"${gl_dirsep_regex}"'signal.h\)".*|\1|
20633 s|^/[^/]|//&|
20634 p
20635 q
20636 }'
20637 gl_cv_next_signal_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20638 sed -n "$gl_absolute_header_sed"`'"'
20639
20640
20641 fi
20642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_signal_h" >&5
20643 $as_echo "$gl_cv_next_signal_h" >&6; }
20644 fi
20645 NEXT_SIGNAL_H=$gl_cv_next_signal_h
20646
20647 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20648 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20649 gl_next_as_first_directive='<'signal.h'>'
20650 else
20651 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20652 gl_next_as_first_directive=$gl_cv_next_signal_h
20653 fi
20654 NEXT_AS_FIRST_DIRECTIVE_SIGNAL_H=$gl_next_as_first_directive
20655
20656
20657
20658
20659
20660 # AIX declares sig_atomic_t to already include volatile, and C89 compilers
20661 # then choke on 'volatile sig_atomic_t'. C99 requires that it compile.
20662 ac_fn_c_check_type "$LINENO" "volatile sig_atomic_t" "ac_cv_type_volatile_sig_atomic_t" "
20663 #include <signal.h>
20664
20665 "
20666 if test "x$ac_cv_type_volatile_sig_atomic_t" = x""yes; then :
20667
20668 else
20669 HAVE_TYPE_VOLATILE_SIG_ATOMIC_T=0
20670 fi
20671
20672
20673
20674
20675
20676
20677
20678 ac_fn_c_check_type "$LINENO" "sighandler_t" "ac_cv_type_sighandler_t" "
20679 #include <signal.h>
20680
20681 "
20682 if test "x$ac_cv_type_sighandler_t" = x""yes; then :
20683
20684 else
20685 HAVE_SIGHANDLER_T=0
20686 fi
20687
20688
20689
20690
20691 ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "
20692 /* <sys/types.h> is not needed according to POSIX, but the
20693 <sys/socket.h> in i386-unknown-freebsd4.10 and
20694 powerpc-apple-darwin5.5 required it. */
20695 #include <sys/types.h>
20696 #if HAVE_SYS_SOCKET_H
20697 # include <sys/socket.h>
20698 #elif HAVE_WS2TCPIP_H
20699 # include <ws2tcpip.h>
20700 #endif
20701
20702 "
20703 if test "x$ac_cv_type_socklen_t" = x""yes; then :
20704
20705 else
20706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
20707 $as_echo_n "checking for socklen_t equivalent... " >&6; }
20708 if test "${gl_cv_socklen_t_equiv+set}" = set; then :
20709 $as_echo_n "(cached) " >&6
20710 else
20711 # Systems have either "struct sockaddr *" or
20712 # "void *" as the second argument to getpeername
20713 gl_cv_socklen_t_equiv=
20714 for arg2 in "struct sockaddr" void; do
20715 for t in int size_t "unsigned int" "long int" "unsigned long int"; do
20716 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20717 /* end confdefs.h. */
20718 #include <sys/types.h>
20719 #include <sys/socket.h>
20720
20721 int getpeername (int, $arg2 *, $t *);
20722 int
20723 main ()
20724 {
20725 $t len;
20726 getpeername (0, 0, &len);
20727 ;
20728 return 0;
20729 }
20730 _ACEOF
20731 if ac_fn_c_try_compile "$LINENO"; then :
20732 gl_cv_socklen_t_equiv="$t"
20733 fi
20734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20735 test "$gl_cv_socklen_t_equiv" != "" && break
20736 done
20737 test "$gl_cv_socklen_t_equiv" != "" && break
20738 done
20739
20740 fi
20741
20742 if test "$gl_cv_socklen_t_equiv" = ""; then
20743 as_fn_error "Cannot find a type to use in place of socklen_t" "$LINENO" 5
20744 fi
20745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_socklen_t_equiv" >&5
20746 $as_echo "$gl_cv_socklen_t_equiv" >&6; }
20747
20748 cat >>confdefs.h <<_ACEOF
20749 #define socklen_t $gl_cv_socklen_t_equiv
20750 _ACEOF
20751
20752 fi
20753
20754
20755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
20756 $as_echo_n "checking for ssize_t... " >&6; }
20757 if test "${gt_cv_ssize_t+set}" = set; then :
20758 $as_echo_n "(cached) " >&6
20759 else
20760 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20761 /* end confdefs.h. */
20762 #include <sys/types.h>
20763 int
20764 main ()
20765 {
20766 int x = sizeof (ssize_t *) + sizeof (ssize_t);
20767 return !x;
20768 ;
20769 return 0;
20770 }
20771 _ACEOF
20772 if ac_fn_c_try_compile "$LINENO"; then :
20773 gt_cv_ssize_t=yes
20774 else
20775 gt_cv_ssize_t=no
20776 fi
20777 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20778 fi
20779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_ssize_t" >&5
20780 $as_echo "$gt_cv_ssize_t" >&6; }
20781 if test $gt_cv_ssize_t = no; then
20782
20783 $as_echo "#define ssize_t int" >>confdefs.h
20784
20785 fi
20786
20787
20788 STDARG_H=''
20789 NEXT_STDARG_H='<stdarg.h>'
20790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for va_copy" >&5
20791 $as_echo_n "checking for va_copy... " >&6; }
20792 if test "${gl_cv_func_va_copy+set}" = set; then :
20793 $as_echo_n "(cached) " >&6
20794 else
20795
20796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20797 /* end confdefs.h. */
20798 #include <stdarg.h>
20799 int
20800 main ()
20801 {
20802
20803 #ifndef va_copy
20804 void (*func) (va_list, va_list) = va_copy;
20805 #endif
20806
20807 ;
20808 return 0;
20809 }
20810 _ACEOF
20811 if ac_fn_c_try_compile "$LINENO"; then :
20812 gl_cv_func_va_copy=yes
20813 else
20814 gl_cv_func_va_copy=no
20815 fi
20816 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20817 fi
20818
20819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_va_copy" >&5
20820 $as_echo "$gl_cv_func_va_copy" >&6; }
20821 if test $gl_cv_func_va_copy = no; then
20822 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20823 /* end confdefs.h. */
20824 #if defined _AIX && !defined __GNUC__
20825 AIX vaccine
20826 #endif
20827
20828 _ACEOF
20829 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20830 $EGREP "vaccine" >/dev/null 2>&1; then :
20831 gl_aixcc=yes
20832 else
20833 gl_aixcc=no
20834 fi
20835 rm -f conftest*
20836
20837 if test $gl_aixcc = yes; then
20838 STDARG_H=stdarg.h
20839
20840
20841
20842
20843
20844
20845
20846
20847 if test $gl_cv_have_include_next = yes; then
20848 gl_cv_next_stdarg_h='<'stdarg.h'>'
20849 else
20850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdarg.h>" >&5
20851 $as_echo_n "checking absolute name of <stdarg.h>... " >&6; }
20852 if test "${gl_cv_next_stdarg_h+set}" = set; then :
20853 $as_echo_n "(cached) " >&6
20854 else
20855
20856 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20857 /* end confdefs.h. */
20858 #include <stdarg.h>
20859
20860 _ACEOF
20861 case "$host_os" in
20862 aix*) gl_absname_cpp="$ac_cpp -C" ;;
20863 *) gl_absname_cpp="$ac_cpp" ;;
20864 esac
20865
20866 case "$host_os" in
20867 mingw*)
20868 gl_dirsep_regex='[/\\]'
20869 ;;
20870 *)
20871 gl_dirsep_regex='/'
20872 ;;
20873 esac
20874
20875 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdarg.h|{
20876 s|.*"\(.*'"${gl_dirsep_regex}"'stdarg.h\)".*|\1|
20877 s|^/[^/]|//&|
20878 p
20879 q
20880 }'
20881 gl_cv_next_stdarg_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
20882 sed -n "$gl_absolute_header_sed"`'"'
20883
20884
20885 fi
20886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdarg_h" >&5
20887 $as_echo "$gl_cv_next_stdarg_h" >&6; }
20888 fi
20889 NEXT_STDARG_H=$gl_cv_next_stdarg_h
20890
20891 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
20892 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
20893 gl_next_as_first_directive='<'stdarg.h'>'
20894 else
20895 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
20896 gl_next_as_first_directive=$gl_cv_next_stdarg_h
20897 fi
20898 NEXT_AS_FIRST_DIRECTIVE_STDARG_H=$gl_next_as_first_directive
20899
20900
20901
20902
20903 if test "$gl_cv_next_stdarg_h" = '""'; then
20904 gl_cv_next_stdarg_h='"///usr/include/stdarg.h"'
20905 NEXT_STDARG_H="$gl_cv_next_stdarg_h"
20906 fi
20907 else
20908
20909 saved_as_echo_n="$as_echo_n"
20910 as_echo_n=':'
20911 if test "${gl_cv_func___va_copy+set}" = set; then :
20912 $as_echo_n "(cached) " >&6
20913 else
20914
20915 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20916 /* end confdefs.h. */
20917 #include <stdarg.h>
20918 int
20919 main ()
20920 {
20921
20922 #ifndef __va_copy
20923 error, bail out
20924 #endif
20925
20926 ;
20927 return 0;
20928 }
20929 _ACEOF
20930 if ac_fn_c_try_compile "$LINENO"; then :
20931 gl_cv_func___va_copy=yes
20932 else
20933 gl_cv_func___va_copy=no
20934 fi
20935 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20936 fi
20937
20938 as_echo_n="$saved_as_echo_n"
20939
20940 if test $gl_cv_func___va_copy = yes; then
20941
20942 $as_echo "#define va_copy __va_copy" >>confdefs.h
20943
20944 else
20945
20946
20947 $as_echo "#define va_copy gl_va_copy" >>confdefs.h
20948
20949 fi
20950 fi
20951 fi
20952
20953 if test -n "$STDARG_H"; then
20954 GL_GENERATE_STDARG_H_TRUE=
20955 GL_GENERATE_STDARG_H_FALSE='#'
20956 else
20957 GL_GENERATE_STDARG_H_TRUE='#'
20958 GL_GENERATE_STDARG_H_FALSE=
20959 fi
20960
20961
20962
20963
20964
20965
20966 # Define two additional variables used in the Makefile substitution.
20967
20968 if test "$ac_cv_header_stdbool_h" = yes; then
20969 STDBOOL_H=''
20970 else
20971 STDBOOL_H='stdbool.h'
20972 fi
20973
20974 if test -n "$STDBOOL_H"; then
20975 GL_GENERATE_STDBOOL_H_TRUE=
20976 GL_GENERATE_STDBOOL_H_FALSE='#'
20977 else
20978 GL_GENERATE_STDBOOL_H_TRUE='#'
20979 GL_GENERATE_STDBOOL_H_FALSE=
20980 fi
20981
20982
20983 if test "$ac_cv_type__Bool" = yes; then
20984 HAVE__BOOL=1
20985 else
20986 HAVE__BOOL=0
20987 fi
20988
20989
20990
20991
20992
20993 STDDEF_H=
20994 if test $gt_cv_c_wchar_t = no; then
20995 HAVE_WCHAR_T=0
20996 STDDEF_H=stddef.h
20997 fi
20998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NULL can be used in arbitrary expressions" >&5
20999 $as_echo_n "checking whether NULL can be used in arbitrary expressions... " >&6; }
21000 if test "${gl_cv_decl_null_works+set}" = set; then :
21001 $as_echo_n "(cached) " >&6
21002 else
21003 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21004 /* end confdefs.h. */
21005 #include <stddef.h>
21006 int test[2 * (sizeof NULL == sizeof (void *)) -1];
21007
21008 int
21009 main ()
21010 {
21011
21012 ;
21013 return 0;
21014 }
21015 _ACEOF
21016 if ac_fn_c_try_compile "$LINENO"; then :
21017 gl_cv_decl_null_works=yes
21018 else
21019 gl_cv_decl_null_works=no
21020 fi
21021 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21022 fi
21023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_decl_null_works" >&5
21024 $as_echo "$gl_cv_decl_null_works" >&6; }
21025 if test $gl_cv_decl_null_works = no; then
21026 REPLACE_NULL=1
21027 STDDEF_H=stddef.h
21028 fi
21029
21030 if test -n "$STDDEF_H"; then
21031 GL_GENERATE_STDDEF_H_TRUE=
21032 GL_GENERATE_STDDEF_H_FALSE='#'
21033 else
21034 GL_GENERATE_STDDEF_H_TRUE='#'
21035 GL_GENERATE_STDDEF_H_FALSE=
21036 fi
21037
21038 if test -n "$STDDEF_H"; then
21039
21040
21041
21042
21043
21044
21045
21046
21047 if test $gl_cv_have_include_next = yes; then
21048 gl_cv_next_stddef_h='<'stddef.h'>'
21049 else
21050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stddef.h>" >&5
21051 $as_echo_n "checking absolute name of <stddef.h>... " >&6; }
21052 if test "${gl_cv_next_stddef_h+set}" = set; then :
21053 $as_echo_n "(cached) " >&6
21054 else
21055
21056 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21057 /* end confdefs.h. */
21058 #include <stddef.h>
21059
21060 _ACEOF
21061 case "$host_os" in
21062 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21063 *) gl_absname_cpp="$ac_cpp" ;;
21064 esac
21065
21066 case "$host_os" in
21067 mingw*)
21068 gl_dirsep_regex='[/\\]'
21069 ;;
21070 *)
21071 gl_dirsep_regex='/'
21072 ;;
21073 esac
21074
21075 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stddef.h|{
21076 s|.*"\(.*'"${gl_dirsep_regex}"'stddef.h\)".*|\1|
21077 s|^/[^/]|//&|
21078 p
21079 q
21080 }'
21081 gl_cv_next_stddef_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21082 sed -n "$gl_absolute_header_sed"`'"'
21083
21084
21085 fi
21086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stddef_h" >&5
21087 $as_echo "$gl_cv_next_stddef_h" >&6; }
21088 fi
21089 NEXT_STDDEF_H=$gl_cv_next_stddef_h
21090
21091 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21092 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21093 gl_next_as_first_directive='<'stddef.h'>'
21094 else
21095 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21096 gl_next_as_first_directive=$gl_cv_next_stddef_h
21097 fi
21098 NEXT_AS_FIRST_DIRECTIVE_STDDEF_H=$gl_next_as_first_directive
21099
21100
21101
21102
21103 fi
21104
21105
21106
21107
21108
21109
21110
21111
21112
21113
21114
21115
21116
21117 if test $gl_cv_have_include_next = yes; then
21118 gl_cv_next_stdio_h='<'stdio.h'>'
21119 else
21120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdio.h>" >&5
21121 $as_echo_n "checking absolute name of <stdio.h>... " >&6; }
21122 if test "${gl_cv_next_stdio_h+set}" = set; then :
21123 $as_echo_n "(cached) " >&6
21124 else
21125
21126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21127 /* end confdefs.h. */
21128 #include <stdio.h>
21129
21130 _ACEOF
21131 case "$host_os" in
21132 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21133 *) gl_absname_cpp="$ac_cpp" ;;
21134 esac
21135
21136 case "$host_os" in
21137 mingw*)
21138 gl_dirsep_regex='[/\\]'
21139 ;;
21140 *)
21141 gl_dirsep_regex='/'
21142 ;;
21143 esac
21144
21145 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdio.h|{
21146 s|.*"\(.*'"${gl_dirsep_regex}"'stdio.h\)".*|\1|
21147 s|^/[^/]|//&|
21148 p
21149 q
21150 }'
21151 gl_cv_next_stdio_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21152 sed -n "$gl_absolute_header_sed"`'"'
21153
21154
21155 fi
21156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdio_h" >&5
21157 $as_echo "$gl_cv_next_stdio_h" >&6; }
21158 fi
21159 NEXT_STDIO_H=$gl_cv_next_stdio_h
21160
21161 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21162 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21163 gl_next_as_first_directive='<'stdio.h'>'
21164 else
21165 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21166 gl_next_as_first_directive=$gl_cv_next_stdio_h
21167 fi
21168 NEXT_AS_FIRST_DIRECTIVE_STDIO_H=$gl_next_as_first_directive
21169
21170
21171
21172
21173
21174 GNULIB_FSCANF=1
21175 GNULIB_SCANF=1
21176 GNULIB_FGETC=1
21177 GNULIB_GETC=1
21178 GNULIB_GETCHAR=1
21179 GNULIB_FGETS=1
21180 GNULIB_GETS=1
21181 GNULIB_FREAD=1
21182
21183
21184 GNULIB_FPRINTF=1
21185 GNULIB_PRINTF=1
21186 GNULIB_VFPRINTF=1
21187 GNULIB_VPRINTF=1
21188 GNULIB_FPUTC=1
21189 GNULIB_PUTC=1
21190 GNULIB_PUTCHAR=1
21191 GNULIB_FPUTS=1
21192 GNULIB_PUTS=1
21193 GNULIB_FWRITE=1
21194
21195
21196
21197
21198
21199
21200
21201
21202
21203
21204
21205
21206
21207
21208
21209 if test $gl_cv_have_include_next = yes; then
21210 gl_cv_next_stdlib_h='<'stdlib.h'>'
21211 else
21212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <stdlib.h>" >&5
21213 $as_echo_n "checking absolute name of <stdlib.h>... " >&6; }
21214 if test "${gl_cv_next_stdlib_h+set}" = set; then :
21215 $as_echo_n "(cached) " >&6
21216 else
21217
21218 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21219 /* end confdefs.h. */
21220 #include <stdlib.h>
21221
21222 _ACEOF
21223 case "$host_os" in
21224 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21225 *) gl_absname_cpp="$ac_cpp" ;;
21226 esac
21227
21228 case "$host_os" in
21229 mingw*)
21230 gl_dirsep_regex='[/\\]'
21231 ;;
21232 *)
21233 gl_dirsep_regex='/'
21234 ;;
21235 esac
21236
21237 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'stdlib.h|{
21238 s|.*"\(.*'"${gl_dirsep_regex}"'stdlib.h\)".*|\1|
21239 s|^/[^/]|//&|
21240 p
21241 q
21242 }'
21243 gl_cv_next_stdlib_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21244 sed -n "$gl_absolute_header_sed"`'"'
21245
21246
21247 fi
21248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_stdlib_h" >&5
21249 $as_echo "$gl_cv_next_stdlib_h" >&6; }
21250 fi
21251 NEXT_STDLIB_H=$gl_cv_next_stdlib_h
21252
21253 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21254 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21255 gl_next_as_first_directive='<'stdlib.h'>'
21256 else
21257 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21258 gl_next_as_first_directive=$gl_cv_next_stdlib_h
21259 fi
21260 NEXT_AS_FIRST_DIRECTIVE_STDLIB_H=$gl_next_as_first_directive
21261
21262
21263
21264
21265
21266
21267
21268
21269
21270 # This defines (or not) HAVE_TZNAME and HAVE_TM_ZONE.
21271
21272
21273
21274
21275
21276
21277
21278 $as_echo "#define my_strftime nstrftime" >>confdefs.h
21279
21280
21281
21282
21283
21284
21285
21286
21287 if test "$ac_cv_have_decl_strtoimax" != yes; then
21288 HAVE_DECL_STRTOIMAX=0
21289 fi
21290
21291 if test $ac_cv_func_strtoimax = no; then
21292
21293
21294
21295
21296
21297
21298
21299
21300 gl_LIBOBJS="$gl_LIBOBJS strtoimax.$ac_objext"
21301
21302
21303 ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default"
21304 if test "x$ac_cv_have_decl_strtoll" = x""yes; then :
21305 ac_have_decl=1
21306 else
21307 ac_have_decl=0
21308 fi
21309
21310 cat >>confdefs.h <<_ACEOF
21311 #define HAVE_DECL_STRTOLL $ac_have_decl
21312 _ACEOF
21313
21314
21315
21316 fi
21317
21318
21319
21320
21321
21322 GNULIB_STRTOIMAX=1
21323
21324
21325
21326
21327
21328
21329
21330
21331
21332 if test "$ac_cv_have_decl_strtoumax" != yes; then
21333 HAVE_DECL_STRTOUMAX=0
21334 fi
21335
21336 if test $ac_cv_func_strtoumax = no; then
21337
21338
21339
21340
21341
21342
21343
21344
21345 gl_LIBOBJS="$gl_LIBOBJS strtoumax.$ac_objext"
21346
21347
21348 ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default"
21349 if test "x$ac_cv_have_decl_strtoull" = x""yes; then :
21350 ac_have_decl=1
21351 else
21352 ac_have_decl=0
21353 fi
21354
21355 cat >>confdefs.h <<_ACEOF
21356 #define HAVE_DECL_STRTOULL $ac_have_decl
21357 _ACEOF
21358
21359
21360
21361 fi
21362
21363
21364
21365
21366
21367 GNULIB_STRTOUMAX=1
21368
21369
21370
21371
21372
21373
21374
21375 if test $ac_cv_func_symlink = no; then
21376 HAVE_SYMLINK=0
21377 else
21378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether symlink handles trailing slash correctly" >&5
21379 $as_echo_n "checking whether symlink handles trailing slash correctly... " >&6; }
21380 if test "${gl_cv_func_symlink_works+set}" = set; then :
21381 $as_echo_n "(cached) " >&6
21382 else
21383 if test "$cross_compiling" = yes; then :
21384 gl_cv_func_symlink_works="guessing no"
21385 else
21386 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21387 /* end confdefs.h. */
21388 #include <unistd.h>
21389
21390 int
21391 main ()
21392 {
21393 int result = 0;
21394 if (!symlink ("a", "conftest.link/"))
21395 result |= 1;
21396 if (symlink ("conftest.f", "conftest.lnk2"))
21397 result |= 2;
21398 else if (!symlink ("a", "conftest.lnk2/"))
21399 result |= 4;
21400 return result;
21401
21402 ;
21403 return 0;
21404 }
21405 _ACEOF
21406 if ac_fn_c_try_run "$LINENO"; then :
21407 gl_cv_func_symlink_works=yes
21408 else
21409 gl_cv_func_symlink_works=no
21410 fi
21411 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21412 conftest.$ac_objext conftest.beam conftest.$ac_ext
21413 fi
21414
21415 rm -f conftest.f conftest.link conftest.lnk2
21416 fi
21417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_symlink_works" >&5
21418 $as_echo "$gl_cv_func_symlink_works" >&6; }
21419 if test "$gl_cv_func_symlink_works" != yes; then
21420 REPLACE_SYMLINK=1
21421 fi
21422 fi
21423
21424 if test $HAVE_SYMLINK = 0 || test $REPLACE_SYMLINK = 1; then
21425
21426
21427
21428
21429
21430
21431
21432
21433 gl_LIBOBJS="$gl_LIBOBJS symlink.$ac_objext"
21434
21435 fi
21436
21437
21438
21439
21440
21441 GNULIB_SYMLINK=1
21442
21443
21444
21445
21446
21447
21448
21449
21450
21451
21452
21453
21454
21455
21456
21457
21458
21459
21460
21461
21462
21463 if test $gl_cv_have_include_next = yes; then
21464 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
21465 else
21466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <sys/stat.h>" >&5
21467 $as_echo_n "checking absolute name of <sys/stat.h>... " >&6; }
21468 if test "${gl_cv_next_sys_stat_h+set}" = set; then :
21469 $as_echo_n "(cached) " >&6
21470 else
21471
21472 if test $ac_cv_header_sys_stat_h = yes; then
21473
21474
21475 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21476 /* end confdefs.h. */
21477 #include <sys/stat.h>
21478
21479 _ACEOF
21480 case "$host_os" in
21481 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21482 *) gl_absname_cpp="$ac_cpp" ;;
21483 esac
21484
21485 case "$host_os" in
21486 mingw*)
21487 gl_dirsep_regex='[/\\]'
21488 ;;
21489 *)
21490 gl_dirsep_regex='/'
21491 ;;
21492 esac
21493
21494 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'sys/stat.h|{
21495 s|.*"\(.*'"${gl_dirsep_regex}"'sys/stat.h\)".*|\1|
21496 s|^/[^/]|//&|
21497 p
21498 q
21499 }'
21500 gl_cv_next_sys_stat_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21501 sed -n "$gl_absolute_header_sed"`'"'
21502 else
21503 gl_cv_next_sys_stat_h='<'sys/stat.h'>'
21504 fi
21505
21506
21507 fi
21508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_sys_stat_h" >&5
21509 $as_echo "$gl_cv_next_sys_stat_h" >&6; }
21510 fi
21511 NEXT_SYS_STAT_H=$gl_cv_next_sys_stat_h
21512
21513 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21514 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21515 gl_next_as_first_directive='<'sys/stat.h'>'
21516 else
21517 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21518 gl_next_as_first_directive=$gl_cv_next_sys_stat_h
21519 fi
21520 NEXT_AS_FIRST_DIRECTIVE_SYS_STAT_H=$gl_next_as_first_directive
21521
21522
21523
21524
21525
21526
21527
21528 ac_fn_c_check_type "$LINENO" "nlink_t" "ac_cv_type_nlink_t" "#include <sys/types.h>
21529 #include <sys/stat.h>
21530 "
21531 if test "x$ac_cv_type_nlink_t" = x""yes; then :
21532
21533 else
21534
21535 $as_echo "#define nlink_t int" >>confdefs.h
21536
21537 fi
21538
21539
21540
21541
21542
21543
21544
21545
21546
21547
21548
21549
21550
21551
21552
21553 if test $ac_cv_have_decl_localtime_r = no; then
21554 HAVE_DECL_LOCALTIME_R=0
21555 fi
21556
21557
21558 if test $ac_cv_func_localtime_r = yes; then
21559 HAVE_LOCALTIME_R=1
21560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether localtime_r is compatible with its POSIX signature" >&5
21561 $as_echo_n "checking whether localtime_r is compatible with its POSIX signature... " >&6; }
21562 if test "${gl_cv_time_r_posix+set}" = set; then :
21563 $as_echo_n "(cached) " >&6
21564 else
21565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21566 /* end confdefs.h. */
21567 #include <time.h>
21568 int
21569 main ()
21570 {
21571 /* We don't need to append 'restrict's to the argument types,
21572 even though the POSIX signature has the 'restrict's,
21573 since C99 says they can't affect type compatibility. */
21574 struct tm * (*ptr) (time_t const *, struct tm *) = localtime_r;
21575 if (ptr) return 0;
21576 /* Check the return type is a pointer.
21577 On HP-UX 10 it is 'int'. */
21578 *localtime_r (0, 0);
21579 ;
21580 return 0;
21581 }
21582
21583 _ACEOF
21584 if ac_fn_c_try_compile "$LINENO"; then :
21585 gl_cv_time_r_posix=yes
21586 else
21587 gl_cv_time_r_posix=no
21588 fi
21589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21590
21591 fi
21592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_time_r_posix" >&5
21593 $as_echo "$gl_cv_time_r_posix" >&6; }
21594 if test $gl_cv_time_r_posix = yes; then
21595 REPLACE_LOCALTIME_R=0
21596 else
21597 REPLACE_LOCALTIME_R=1
21598 fi
21599 else
21600 HAVE_LOCALTIME_R=0
21601 fi
21602
21603 if test $HAVE_LOCALTIME_R = 0 || test $REPLACE_LOCALTIME_R = 1; then
21604
21605
21606
21607
21608
21609
21610
21611
21612 gl_LIBOBJS="$gl_LIBOBJS time_r.$ac_objext"
21613
21614
21615 :
21616
21617 fi
21618
21619
21620
21621
21622
21623 GNULIB_TIME_R=1
21624
21625
21626
21627
21628
21629
21630
21631
21632
21633
21634
21635
21636
21637
21638
21639
21640
21641
21642
21643 if test $gl_cv_have_include_next = yes; then
21644 gl_cv_next_unistd_h='<'unistd.h'>'
21645 else
21646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking absolute name of <unistd.h>" >&5
21647 $as_echo_n "checking absolute name of <unistd.h>... " >&6; }
21648 if test "${gl_cv_next_unistd_h+set}" = set; then :
21649 $as_echo_n "(cached) " >&6
21650 else
21651
21652 if test $ac_cv_header_unistd_h = yes; then
21653
21654
21655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21656 /* end confdefs.h. */
21657 #include <unistd.h>
21658
21659 _ACEOF
21660 case "$host_os" in
21661 aix*) gl_absname_cpp="$ac_cpp -C" ;;
21662 *) gl_absname_cpp="$ac_cpp" ;;
21663 esac
21664
21665 case "$host_os" in
21666 mingw*)
21667 gl_dirsep_regex='[/\\]'
21668 ;;
21669 *)
21670 gl_dirsep_regex='/'
21671 ;;
21672 esac
21673
21674 gl_absolute_header_sed='\|'"${gl_dirsep_regex}"'unistd.h|{
21675 s|.*"\(.*'"${gl_dirsep_regex}"'unistd.h\)".*|\1|
21676 s|^/[^/]|//&|
21677 p
21678 q
21679 }'
21680 gl_cv_next_unistd_h='"'`(eval "$gl_absname_cpp conftest.$ac_ext") 2>&5 |
21681 sed -n "$gl_absolute_header_sed"`'"'
21682 else
21683 gl_cv_next_unistd_h='<'unistd.h'>'
21684 fi
21685
21686
21687 fi
21688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_next_unistd_h" >&5
21689 $as_echo "$gl_cv_next_unistd_h" >&6; }
21690 fi
21691 NEXT_UNISTD_H=$gl_cv_next_unistd_h
21692
21693 if test $gl_cv_have_include_next = yes || test $gl_cv_have_include_next = buggy; then
21694 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include_next'
21695 gl_next_as_first_directive='<'unistd.h'>'
21696 else
21697 # INCLUDE_NEXT_AS_FIRST_DIRECTIVE='include'
21698 gl_next_as_first_directive=$gl_cv_next_unistd_h
21699 fi
21700 NEXT_AS_FIRST_DIRECTIVE_UNISTD_H=$gl_next_as_first_directive
21701
21702
21703
21704
21705 if test $ac_cv_header_unistd_h = yes; then
21706 HAVE_UNISTD_H=1
21707 else
21708 HAVE_UNISTD_H=0
21709 fi
21710
21711
21712
21713
21714
21715
21716 gl_gnulib_enabled_dosname=false
21717 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=false
21718 gl_gnulib_enabled_pathmax=false
21719 gl_gnulib_enabled_sigprocmask=false
21720 gl_gnulib_enabled_stat=false
21721 gl_gnulib_enabled_strtoll=false
21722 gl_gnulib_enabled_strtoull=false
21723 gl_gnulib_enabled_verify=false
21724 func_gl_gnulib_m4code_dosname ()
21725 {
21726 if ! $gl_gnulib_enabled_dosname; then
21727 gl_gnulib_enabled_dosname=true
21728 fi
21729 }
21730 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36 ()
21731 {
21732 if ! $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
21733
21734
21735 gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36=true
21736 fi
21737 }
21738 func_gl_gnulib_m4code_pathmax ()
21739 {
21740 if ! $gl_gnulib_enabled_pathmax; then
21741
21742
21743
21744 gl_gnulib_enabled_pathmax=true
21745 fi
21746 }
21747 func_gl_gnulib_m4code_sigprocmask ()
21748 {
21749 if ! $gl_gnulib_enabled_sigprocmask; then
21750
21751
21752
21753 if test $gl_cv_type_sigset_t = yes; then
21754 ac_fn_c_check_func "$LINENO" "sigprocmask" "ac_cv_func_sigprocmask"
21755 if test "x$ac_cv_func_sigprocmask" = x""yes; then :
21756 gl_cv_func_sigprocmask=1
21757 fi
21758
21759 fi
21760 if test -z "$gl_cv_func_sigprocmask"; then
21761 HAVE_POSIX_SIGNALBLOCKING=0
21762 fi
21763
21764 if test $HAVE_POSIX_SIGNALBLOCKING = 0; then
21765
21766
21767
21768
21769
21770
21771
21772
21773 gl_LIBOBJS="$gl_LIBOBJS sigprocmask.$ac_objext"
21774
21775
21776
21777
21778 fi
21779
21780
21781
21782
21783
21784 GNULIB_SIGPROCMASK=1
21785
21786
21787
21788
21789
21790 gl_gnulib_enabled_sigprocmask=true
21791 fi
21792 }
21793 func_gl_gnulib_m4code_stat ()
21794 {
21795 if ! $gl_gnulib_enabled_stat; then
21796
21797
21798
21799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on directories" >&5
21800 $as_echo_n "checking whether stat handles trailing slashes on directories... " >&6; }
21801 if test "${gl_cv_func_stat_dir_slash+set}" = set; then :
21802 $as_echo_n "(cached) " >&6
21803 else
21804 if test "$cross_compiling" = yes; then :
21805 case $host_os in
21806 mingw*) gl_cv_func_stat_dir_slash="guessing no";;
21807 *) gl_cv_func_stat_dir_slash="guessing yes";;
21808 esac
21809 else
21810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21811 /* end confdefs.h. */
21812 #include <sys/stat.h>
21813
21814 int
21815 main ()
21816 {
21817 struct stat st; return stat (".", &st) != stat ("./", &st);
21818 ;
21819 return 0;
21820 }
21821 _ACEOF
21822 if ac_fn_c_try_run "$LINENO"; then :
21823 gl_cv_func_stat_dir_slash=yes
21824 else
21825 gl_cv_func_stat_dir_slash=no
21826 fi
21827 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21828 conftest.$ac_objext conftest.beam conftest.$ac_ext
21829 fi
21830
21831 fi
21832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_dir_slash" >&5
21833 $as_echo "$gl_cv_func_stat_dir_slash" >&6; }
21834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat handles trailing slashes on files" >&5
21835 $as_echo_n "checking whether stat handles trailing slashes on files... " >&6; }
21836 if test "${gl_cv_func_stat_file_slash+set}" = set; then :
21837 $as_echo_n "(cached) " >&6
21838 else
21839 touch conftest.tmp
21840 # Assume that if we have lstat, we can also check symlinks.
21841 if test $ac_cv_func_lstat = yes; then
21842 ln -s conftest.tmp conftest.lnk
21843 fi
21844 if test "$cross_compiling" = yes; then :
21845 gl_cv_func_stat_file_slash="guessing no"
21846 else
21847 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21848 /* end confdefs.h. */
21849 #include <sys/stat.h>
21850
21851 int
21852 main ()
21853 {
21854 int result = 0;
21855 struct stat st;
21856 if (!stat ("conftest.tmp/", &st))
21857 result |= 1;
21858 #if HAVE_LSTAT
21859 if (!stat ("conftest.lnk/", &st))
21860 result |= 2;
21861 #endif
21862 return result;
21863
21864 ;
21865 return 0;
21866 }
21867 _ACEOF
21868 if ac_fn_c_try_run "$LINENO"; then :
21869 gl_cv_func_stat_file_slash=yes
21870 else
21871 gl_cv_func_stat_file_slash=no
21872 fi
21873 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21874 conftest.$ac_objext conftest.beam conftest.$ac_ext
21875 fi
21876
21877 rm -f conftest.tmp conftest.lnk
21878 fi
21879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gl_cv_func_stat_file_slash" >&5
21880 $as_echo "$gl_cv_func_stat_file_slash" >&6; }
21881 case $gl_cv_func_stat_dir_slash in
21882 *no) REPLACE_STAT=1
21883
21884 $as_echo "#define REPLACE_FUNC_STAT_DIR 1" >>confdefs.h
21885 ;;
21886 esac
21887 case $gl_cv_func_stat_file_slash in
21888 *no) REPLACE_STAT=1
21889
21890 $as_echo "#define REPLACE_FUNC_STAT_FILE 1" >>confdefs.h
21891 ;;
21892 esac
21893
21894 if test $REPLACE_STAT = 1; then
21895
21896
21897
21898
21899
21900
21901
21902
21903 gl_LIBOBJS="$gl_LIBOBJS stat.$ac_objext"
21904
21905
21906
21907 :
21908
21909 fi
21910
21911
21912
21913
21914
21915 GNULIB_STAT=1
21916
21917
21918
21919
21920
21921 gl_gnulib_enabled_stat=true
21922 if test $REPLACE_STAT = 1; then
21923 func_gl_gnulib_m4code_dosname
21924 fi
21925 if test $REPLACE_STAT = 1; then
21926 func_gl_gnulib_m4code_pathmax
21927 fi
21928 if test $REPLACE_STAT = 1; then
21929 func_gl_gnulib_m4code_verify
21930 fi
21931 fi
21932 }
21933 func_gl_gnulib_m4code_strtoll ()
21934 {
21935 if ! $gl_gnulib_enabled_strtoll; then
21936
21937
21938
21939 if test "$ac_cv_type_long_long_int" = yes; then
21940 for ac_func in strtoll
21941 do :
21942 ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
21943 if test "x$ac_cv_func_strtoll" = x""yes; then :
21944 cat >>confdefs.h <<_ACEOF
21945 #define HAVE_STRTOLL 1
21946 _ACEOF
21947
21948 fi
21949 done
21950
21951 if test $ac_cv_func_strtoll = no; then
21952 HAVE_STRTOLL=0
21953 fi
21954 fi
21955
21956 if test $HAVE_STRTOLL = 0; then
21957
21958
21959
21960
21961
21962
21963
21964
21965 gl_LIBOBJS="$gl_LIBOBJS strtoll.$ac_objext"
21966
21967
21968 :
21969
21970 fi
21971
21972
21973
21974
21975
21976 GNULIB_STRTOLL=1
21977
21978
21979
21980
21981
21982 gl_gnulib_enabled_strtoll=true
21983 fi
21984 }
21985 func_gl_gnulib_m4code_strtoull ()
21986 {
21987 if ! $gl_gnulib_enabled_strtoull; then
21988
21989
21990
21991 if test "$ac_cv_type_unsigned_long_long_int" = yes; then
21992 for ac_func in strtoull
21993 do :
21994 ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
21995 if test "x$ac_cv_func_strtoull" = x""yes; then :
21996 cat >>confdefs.h <<_ACEOF
21997 #define HAVE_STRTOULL 1
21998 _ACEOF
21999
22000 fi
22001 done
22002
22003 if test $ac_cv_func_strtoull = no; then
22004 HAVE_STRTOULL=0
22005 fi
22006 fi
22007
22008 if test $HAVE_STRTOULL = 0; then
22009
22010
22011
22012
22013
22014
22015
22016
22017 gl_LIBOBJS="$gl_LIBOBJS strtoull.$ac_objext"
22018
22019
22020 :
22021
22022 fi
22023
22024
22025
22026
22027
22028 GNULIB_STRTOULL=1
22029
22030
22031
22032
22033
22034 gl_gnulib_enabled_strtoull=true
22035 fi
22036 }
22037 func_gl_gnulib_m4code_verify ()
22038 {
22039 if ! $gl_gnulib_enabled_verify; then
22040 gl_gnulib_enabled_verify=true
22041 fi
22042 }
22043 if test $REPLACE_GETOPT = 1; then
22044 func_gl_gnulib_m4code_be453cec5eecf5731a274f2de7f2db36
22045 fi
22046 if test $REPLACE_LSTAT = 1; then
22047 func_gl_gnulib_m4code_dosname
22048 fi
22049 if test $REPLACE_LSTAT = 1; then
22050 func_gl_gnulib_m4code_stat
22051 fi
22052 if test $HAVE_PTHREAD_SIGMASK = 0 || test $REPLACE_PTHREAD_SIGMASK = 1; then
22053 func_gl_gnulib_m4code_sigprocmask
22054 fi
22055 if test $HAVE_READLINK = 0 || test $REPLACE_READLINK = 1; then
22056 func_gl_gnulib_m4code_stat
22057 fi
22058 if test $ac_cv_func_strtoimax = no; then
22059 func_gl_gnulib_m4code_verify
22060 fi
22061 if test $ac_cv_func_strtoimax = no && test $ac_cv_type_long_long_int = yes; then
22062 func_gl_gnulib_m4code_strtoll
22063 fi
22064 if test $ac_cv_func_strtoumax = no; then
22065 func_gl_gnulib_m4code_verify
22066 fi
22067 if test $ac_cv_func_strtoumax = no && test $ac_cv_type_unsigned_long_long_int = yes; then
22068 func_gl_gnulib_m4code_strtoull
22069 fi
22070
22071 if $gl_gnulib_enabled_dosname; then
22072 gl_GNULIB_ENABLED_dosname_TRUE=
22073 gl_GNULIB_ENABLED_dosname_FALSE='#'
22074 else
22075 gl_GNULIB_ENABLED_dosname_TRUE='#'
22076 gl_GNULIB_ENABLED_dosname_FALSE=
22077 fi
22078
22079 if $gl_gnulib_enabled_be453cec5eecf5731a274f2de7f2db36; then
22080 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE=
22081 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE='#'
22082 else
22083 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE='#'
22084 gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE=
22085 fi
22086
22087 if $gl_gnulib_enabled_pathmax; then
22088 gl_GNULIB_ENABLED_pathmax_TRUE=
22089 gl_GNULIB_ENABLED_pathmax_FALSE='#'
22090 else
22091 gl_GNULIB_ENABLED_pathmax_TRUE='#'
22092 gl_GNULIB_ENABLED_pathmax_FALSE=
22093 fi
22094
22095 if $gl_gnulib_enabled_sigprocmask; then
22096 gl_GNULIB_ENABLED_sigprocmask_TRUE=
22097 gl_GNULIB_ENABLED_sigprocmask_FALSE='#'
22098 else
22099 gl_GNULIB_ENABLED_sigprocmask_TRUE='#'
22100 gl_GNULIB_ENABLED_sigprocmask_FALSE=
22101 fi
22102
22103 if $gl_gnulib_enabled_stat; then
22104 gl_GNULIB_ENABLED_stat_TRUE=
22105 gl_GNULIB_ENABLED_stat_FALSE='#'
22106 else
22107 gl_GNULIB_ENABLED_stat_TRUE='#'
22108 gl_GNULIB_ENABLED_stat_FALSE=
22109 fi
22110
22111 if $gl_gnulib_enabled_strtoll; then
22112 gl_GNULIB_ENABLED_strtoll_TRUE=
22113 gl_GNULIB_ENABLED_strtoll_FALSE='#'
22114 else
22115 gl_GNULIB_ENABLED_strtoll_TRUE='#'
22116 gl_GNULIB_ENABLED_strtoll_FALSE=
22117 fi
22118
22119 if $gl_gnulib_enabled_strtoull; then
22120 gl_GNULIB_ENABLED_strtoull_TRUE=
22121 gl_GNULIB_ENABLED_strtoull_FALSE='#'
22122 else
22123 gl_GNULIB_ENABLED_strtoull_TRUE='#'
22124 gl_GNULIB_ENABLED_strtoull_FALSE=
22125 fi
22126
22127 if $gl_gnulib_enabled_verify; then
22128 gl_GNULIB_ENABLED_verify_TRUE=
22129 gl_GNULIB_ENABLED_verify_FALSE='#'
22130 else
22131 gl_GNULIB_ENABLED_verify_TRUE='#'
22132 gl_GNULIB_ENABLED_verify_FALSE=
22133 fi
22134
22135 # End of code from modules
22136
22137
22138
22139
22140
22141
22142
22143
22144
22145 gltests_libdeps=
22146 gltests_ltlibdeps=
22147
22148
22149
22150
22151
22152
22153
22154
22155
22156 gl_source_base='tests'
22157 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
22158
22159 gl_module_indicator_condition=$gltests_WITNESS
22160
22161
22162
22163
22164
22165
22166
22167
22168
22169
22170 LIBGNU_LIBDEPS="$gl_libdeps"
22171
22172 LIBGNU_LTLIBDEPS="$gl_ltlibdeps"
22173
22174
22175
22176 case "$opsys" in
22177 aix4-2) LD_SWITCH_SYSTEM_TEMACS="-Wl,-bnodelcsect" ;;
22178
22179 darwin)
22180 ## The -headerpad option tells ld (see man page) to leave room at the
22181 ## end of the header for adding load commands. Needed for dumping.
22182 ## 0x690 is the total size of 30 segment load commands (at 56
22183 ## each); under Cocoa 31 commands are required.
22184 if test "$HAVE_NS" = "yes"; then
22185 libs_nsgui="-framework AppKit"
22186 headerpad_extra=6C8
22187 else
22188 libs_nsgui=
22189 headerpad_extra=690
22190 fi
22191 LD_SWITCH_SYSTEM_TEMACS="-fno-pie -prebind $libs_nsgui -Xlinker -headerpad -Xlinker $headerpad_extra"
22192
22193 ## This is here because src/Makefile.in did some extra fiddling around
22194 ## with LD_SWITCH_SYSTEM. The cpp logic was:
22195 ## #ifndef LD_SWITCH_SYSTEM
22196 ## #if !defined (__GNUC__) && ((defined (BSD_SYSTEM) && !defined (COFF)))
22197 ## Since all the *bsds define LD_SWITCH_SYSTEM, this simplifies to:
22198 ## not using gcc, darwin system not on an alpha (ie darwin, since
22199 ## darwin + alpha does not occur).
22200 ## Because this was done in src/Makefile.in, the resulting part of
22201 ## LD_SWITCH_SYSTEM was not used in configure (ie, in ac_link).
22202 ## It therefore seems cleaner to put this in LD_SWITCH_SYSTEM_TEMACS,
22203 ## rather than LD_SWITCH_SYSTEM.
22204 test "x$LD_SWITCH_SYSTEM" = "x" && test "x$GCC" != "xyes" && \
22205 LD_SWITCH_SYSTEM_TEMACS="-X $LD_SWITCH_SYSTEM_TEMACS"
22206 ;;
22207
22208 ## LD_SWITCH_X_SITE_AUX is a -R option saying where to find X at run-time.
22209 ## When handled by cpp, this was in LD_SWITCH_SYSTEM. However, at
22210 ## the point where configure sourced the s/*.h file, LD_SWITCH_X_SITE_AUX
22211 ## had not yet been defined and was expanded to null. Hence LD_SWITCH_SYSTEM
22212 ## had different values in configure (in ac_link) and src/Makefile.in.
22213 ## It seems clearer therefore to put this piece in LD_SWITCH_SYSTEM_TEMACS.
22214 gnu-linux) LD_SWITCH_SYSTEM_TEMACS="\$(LD_SWITCH_X_SITE_AUX)" ;;
22215
22216 *) LD_SWITCH_SYSTEM_TEMACS= ;;
22217 esac
22218
22219 if test "$NS_IMPL_GNUSTEP" = "yes"; then
22220 LD_SWITCH_SYSTEM_TEMACS="${LD_SWITCH_SYSTEM_TEMACS} -L${GNUSTEP_SYSTEM_LIBRARIES} ${GNUSTEP_LOCAL_LIBRARIES} -lgnustep-gui -lgnustep-base -lobjc -lpthread"
22221 fi
22222
22223
22224
22225
22226 LD_FIRSTFLAG=
22227 ORDINARY_LINK=
22228 case "$opsys" in
22229 ## gnu: GNU needs its own crt0.
22230 aix4-2|cygwin|darwin|gnu|hpux*|irix6-5|sol2*|unixware) ORDINARY_LINK=yes ;;
22231
22232 ## On post 1.3 releases of NetBSD, gcc -nostdlib also clears the
22233 ## library search parth, i.e. it won't search /usr/lib for libc and
22234 ## friends. Using -nostartfiles instead avoids this problem, and
22235 ## will also work on earlier NetBSD releases.
22236 netbsd|openbsd) LD_FIRSTFLAG="-nostartfiles" ;;
22237
22238 ## macpcc: NAKAJI Hiroyuki <nakaji@tutrp.tut.ac.jp> says
22239 ## MkLinux/LinuxPPC needs this.
22240 ## ibms390x only supports opsys = gnu-linux so it can be added here.
22241 gnu-*)
22242 case "$machine" in
22243 macppc|ibms390x) LD_FIRSTFLAG="-nostdlib" ;;
22244 esac
22245 ;;
22246 esac
22247
22248
22249 if test "x$ORDINARY_LINK" = "xyes"; then
22250
22251 LD_FIRSTFLAG=""
22252
22253 $as_echo "#define ORDINARY_LINK 1" >>confdefs.h
22254
22255
22256 ## The system files defining neither ORDINARY_LINK nor LD_FIRSTFLAG are:
22257 ## freebsd, gnu-* not on macppc|ibms390x.
22258 elif test "x$GCC" = "xyes" && test "x$LD_FIRSTFLAG" = "x"; then
22259
22260 ## Versions of GCC >= 2.0 put their library, libgcc.a, in obscure
22261 ## places that are difficult to figure out at make time. Fortunately,
22262 ## these same versions allow you to pass arbitrary flags on to the
22263 ## linker, so there is no reason not to use it as a linker.
22264 ##
22265 ## Well, it is not quite perfect. The "-nostdlib" keeps GCC from
22266 ## searching for libraries in its internal directories, so we have to
22267 ## ask GCC explicitly where to find libgcc.a (LIB_GCC below).
22268 LD_FIRSTFLAG="-nostdlib"
22269 fi
22270
22271 ## FIXME? What setting of EDIT_LDFLAGS should this have?
22272 test "$NS_IMPL_GNUSTEP" = "yes" && LD_FIRSTFLAG="-rdynamic"
22273
22274
22275
22276
22277 ## FIXME? The logic here is not precisely the same as that above.
22278 ## There is no check here for a pre-defined LD_FIRSTFLAG.
22279 ## Should we only be setting LIB_GCC if LD ~ -nostdlib?
22280 LIB_GCC=
22281 if test "x$GCC" = "xyes" && test "x$ORDINARY_LINK" != "xyes"; then
22282
22283 case "$opsys" in
22284 freebsd|netbsd|openbsd) LIB_GCC= ;;
22285
22286 gnu-*)
22287 ## armin76@gentoo.org reported that the lgcc_s flag is necessary to
22288 ## build on ARM EABI under GNU/Linux. (Bug#5518)
22289 case $host_cpu in
22290 arm*)
22291 LIB_GCC="-lgcc_s"
22292 ;;
22293 *)
22294 ## FIXME? s/gnu-linux.h used to define LIB_GCC as below, then
22295 ## immediately undefine it again and redefine it to empty.
22296 ## Was the C_SWITCH_X_SITE part really necessary?
22297 ## LIB_GCC=`$CC $C_SWITCH_X_SITE -print-libgcc-file-name`
22298 LIB_GCC=
22299 ;;
22300 esac
22301 ;;
22302
22303 ## Ask GCC where to find libgcc.a.
22304 *) LIB_GCC=`$CC -print-libgcc-file-name 2> /dev/null` ;;
22305 esac
22306 fi
22307
22308
22309 ## If we're using X11/GNUstep, define some consequences.
22310 if test "$HAVE_X_WINDOWS" = "yes" || test "$HAVE_NS" = "yes"; then
22311
22312 $as_echo "#define HAVE_WINDOW_SYSTEM 1" >>confdefs.h
22313
22314
22315 $as_echo "#define HAVE_MOUSE 1" >>confdefs.h
22316
22317 fi
22318
22319
22320
22321
22322 #### Report on what we decided to do.
22323 #### Report GTK as a toolkit, even if it doesn't use Xt.
22324 #### It makes printing result more understandable as using GTK sets
22325 #### toolkit_scroll_bars to yes by default.
22326 if test "${HAVE_GTK}" = "yes"; then
22327 USE_X_TOOLKIT=GTK
22328 fi
22329
22330 and_machfile=
22331 if test -n "$machfile"; then
22332 and_machfile=" and \`${machfile}'"
22333 fi
22334
22335 echo "
22336 Configured for \`${canonical}'.
22337
22338 Where should the build process find the source code? ${srcdir}
22339 What operating system and machine description files should Emacs use?
22340 \`${opsysfile}'${and_machfile}
22341 What compiler should emacs be built with? ${CC} ${CFLAGS}
22342 Should Emacs use the GNU version of malloc? ${GNU_MALLOC}${GNU_MALLOC_reason}
22343 Should Emacs use a relocating allocator for buffers? ${REL_ALLOC}
22344 Should Emacs use mmap(2) for buffer allocation? $use_mmap_for_buffers
22345 What window system should Emacs use? ${window_system}
22346 What toolkit should Emacs use? ${USE_X_TOOLKIT}"
22347
22348 if test -n "${x_includes}"; then
22349 echo " Where do we find X Windows header files? ${x_includes}"
22350 else
22351 echo " Where do we find X Windows header files? Standard dirs"
22352 fi
22353 if test -n "${x_libraries}"; then
22354 echo " Where do we find X Windows libraries? ${x_libraries}"
22355 else
22356 echo " Where do we find X Windows libraries? Standard dirs"
22357 fi
22358
22359 echo " Does Emacs use -lXaw3d? ${HAVE_XAW3D}"
22360 echo " Does Emacs use -lXpm? ${HAVE_XPM}"
22361 echo " Does Emacs use -ljpeg? ${HAVE_JPEG}"
22362 echo " Does Emacs use -ltiff? ${HAVE_TIFF}"
22363 echo " Does Emacs use a gif library? ${HAVE_GIF} $LIBGIF"
22364 echo " Does Emacs use -lpng? ${HAVE_PNG}"
22365 echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}"
22366 echo " Does Emacs use imagemagick? ${HAVE_IMAGEMAGICK}"
22367
22368 echo " Does Emacs use -lgpm? ${HAVE_GPM}"
22369 echo " Does Emacs use -ldbus? ${HAVE_DBUS}"
22370 echo " Does Emacs use -lgconf? ${HAVE_GCONF}"
22371 echo " Does Emacs use GSettings? ${HAVE_GSETTINGS}"
22372 echo " Does Emacs use -lselinux? ${HAVE_LIBSELINUX}"
22373 echo " Does Emacs use -lgnutls? ${HAVE_GNUTLS}"
22374 echo " Does Emacs use -lxml2? ${HAVE_LIBXML2}"
22375
22376 echo " Does Emacs use -lfreetype? ${HAVE_FREETYPE}"
22377 echo " Does Emacs use -lm17n-flt? ${HAVE_M17N_FLT}"
22378 echo " Does Emacs use -lotf? ${HAVE_LIBOTF}"
22379 echo " Does Emacs use -lxft? ${HAVE_XFT}"
22380
22381 echo " Does Emacs use toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}"
22382 echo
22383
22384 if test -n "${EMACSDATA}"; then
22385 echo " Environment variable EMACSDATA set to: $EMACSDATA"
22386 fi
22387 if test -n "${EMACSDOC}"; then
22388 echo " Environment variable EMACSDOC set to: $EMACSDOC"
22389 fi
22390
22391 if test $USE_XASSERTS = yes; then
22392 echo " Compiling with asserts turned on."
22393 CPPFLAGS="$CPPFLAGS -DXASSERTS=1"
22394 fi
22395
22396 echo
22397
22398 if test "$HAVE_NS" = "yes"; then
22399 echo
22400 echo "You must run \"${MAKE-make} install\" in order to test the built application.
22401 The installed application will go to nextstep/Emacs.app and can be
22402 run or moved from there."
22403 if test "$EN_NS_SELF_CONTAINED" = "yes"; then
22404 echo "The application will be fully self-contained."
22405 else
22406 echo "The lisp resources for the application will be installed under ${prefix}.
22407 You may need to run \"${MAKE-make} install\" with sudo. The application will fail
22408 to run if these resources are not installed."
22409 fi
22410 echo
22411 fi
22412
22413
22414 # Remove any trailing slashes in these variables.
22415 test "${prefix}" != NONE &&
22416 prefix=`echo "${prefix}" | sed 's,\([^/]\)/*$,\1,'`
22417 test "${exec_prefix}" != NONE &&
22418 exec_prefix=`echo "${exec_prefix}" | sed 's,\([^/]\)/*$,\1,'`
22419
22420 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"
22421
22422 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"
22423
22424
22425 opt_makefile=test/automated/Makefile
22426
22427 if test -f $srcdir/${opt_makefile}.in; then
22428 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
22429 ac_config_files="$ac_config_files test/automated/Makefile"
22430
22431 fi
22432
22433
22434 opt_makefile=admin/unidata/Makefile
22435
22436 if test -f $srcdir/${opt_makefile}.in; then
22437 SUBDIR_MAKEFILES="$SUBDIR_MAKEFILES $opt_makefile"
22438 ac_config_files="$ac_config_files admin/unidata/Makefile"
22439
22440 fi
22441
22442
22443 SUBDIR_MAKEFILES_IN=`echo " ${SUBDIR_MAKEFILES}" | sed -e 's| | $(srcdir)/|g' -e 's|Makefile|Makefile.in|g'`
22444
22445
22446
22447 ac_config_commands="$ac_config_commands mkdirs"
22448
22449
22450 ac_config_commands="$ac_config_commands epaths"
22451
22452
22453 ac_config_commands="$ac_config_commands gdbinit"
22454
22455
22456 cat >confcache <<\_ACEOF
22457 # This file is a shell script that caches the results of configure
22458 # tests run on this system so they can be shared between configure
22459 # scripts and configure runs, see configure's option --config-cache.
22460 # It is not useful on other systems. If it contains results you don't
22461 # want to keep, you may remove or edit it.
22462 #
22463 # config.status only pays attention to the cache file if you give it
22464 # the --recheck option to rerun configure.
22465 #
22466 # `ac_cv_env_foo' variables (set or unset) will be overridden when
22467 # loading this file, other *unset* `ac_cv_foo' will be assigned the
22468 # following values.
22469
22470 _ACEOF
22471
22472 # The following way of writing the cache mishandles newlines in values,
22473 # but we know of no workaround that is simple, portable, and efficient.
22474 # So, we kill variables containing newlines.
22475 # Ultrix sh set writes to stderr and can't be redirected directly,
22476 # and sets the high bit in the cache file unless we assign to the vars.
22477 (
22478 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
22479 eval ac_val=\$$ac_var
22480 case $ac_val in #(
22481 *${as_nl}*)
22482 case $ac_var in #(
22483 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
22484 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
22485 esac
22486 case $ac_var in #(
22487 _ | IFS | as_nl) ;; #(
22488 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
22489 *) { eval $ac_var=; unset $ac_var;} ;;
22490 esac ;;
22491 esac
22492 done
22493
22494 (set) 2>&1 |
22495 case $as_nl`(ac_space=' '; set) 2>&1` in #(
22496 *${as_nl}ac_space=\ *)
22497 # `set' does not quote correctly, so add quotes: double-quote
22498 # substitution turns \\\\ into \\, and sed turns \\ into \.
22499 sed -n \
22500 "s/'/'\\\\''/g;
22501 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
22502 ;; #(
22503 *)
22504 # `set' quotes correctly as required by POSIX, so do not add quotes.
22505 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
22506 ;;
22507 esac |
22508 sort
22509 ) |
22510 sed '
22511 /^ac_cv_env_/b end
22512 t clear
22513 :clear
22514 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
22515 t end
22516 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
22517 :end' >>confcache
22518 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
22519 if test -w "$cache_file"; then
22520 test "x$cache_file" != "x/dev/null" &&
22521 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
22522 $as_echo "$as_me: updating cache $cache_file" >&6;}
22523 cat confcache >$cache_file
22524 else
22525 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
22526 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
22527 fi
22528 fi
22529 rm -f confcache
22530
22531 test "x$prefix" = xNONE && prefix=$ac_default_prefix
22532 # Let make expand exec_prefix.
22533 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
22534
22535 DEFS=-DHAVE_CONFIG_H
22536
22537 ac_libobjs=
22538 ac_ltlibobjs=
22539 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
22540 # 1. Remove the extension, and $U if already installed.
22541 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
22542 ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
22543 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
22544 # will be set to the directory where LIBOBJS objects are built.
22545 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
22546 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
22547 done
22548 LIBOBJS=$ac_libobjs
22549
22550 LTLIBOBJS=$ac_ltlibobjs
22551
22552
22553 if test -n "$EXEEXT"; then
22554 am__EXEEXT_TRUE=
22555 am__EXEEXT_FALSE='#'
22556 else
22557 am__EXEEXT_TRUE='#'
22558 am__EXEEXT_FALSE=
22559 fi
22560
22561 if test -z "${AMDEP_TRUE}" && test -z "${AMDEP_FALSE}"; then
22562 as_fn_error "conditional \"AMDEP\" was never defined.
22563 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22564 fi
22565 if test -z "${am__fastdepCC_TRUE}" && test -z "${am__fastdepCC_FALSE}"; then
22566 as_fn_error "conditional \"am__fastdepCC\" was never defined.
22567 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22568 fi
22569
22570 if test -z "${GL_COND_LIBTOOL_TRUE}" && test -z "${GL_COND_LIBTOOL_FALSE}"; then
22571 as_fn_error "conditional \"GL_COND_LIBTOOL\" was never defined.
22572 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22573 fi
22574 if test -z "${GL_GENERATE_ALLOCA_H_TRUE}" && test -z "${GL_GENERATE_ALLOCA_H_FALSE}"; then
22575 as_fn_error "conditional \"GL_GENERATE_ALLOCA_H\" was never defined.
22576 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22577 fi
22578
22579 if test -z "${GL_GENERATE_STDINT_H_TRUE}" && test -z "${GL_GENERATE_STDINT_H_FALSE}"; then
22580 as_fn_error "conditional \"GL_GENERATE_STDINT_H\" was never defined.
22581 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22582 fi
22583 if test -z "${GL_GENERATE_STDARG_H_TRUE}" && test -z "${GL_GENERATE_STDARG_H_FALSE}"; then
22584 as_fn_error "conditional \"GL_GENERATE_STDARG_H\" was never defined.
22585 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22586 fi
22587 if test -z "${GL_GENERATE_STDBOOL_H_TRUE}" && test -z "${GL_GENERATE_STDBOOL_H_FALSE}"; then
22588 as_fn_error "conditional \"GL_GENERATE_STDBOOL_H\" was never defined.
22589 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22590 fi
22591 if test -z "${GL_GENERATE_STDDEF_H_TRUE}" && test -z "${GL_GENERATE_STDDEF_H_FALSE}"; then
22592 as_fn_error "conditional \"GL_GENERATE_STDDEF_H\" was never defined.
22593 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22594 fi
22595 if test -z "${gl_GNULIB_ENABLED_dosname_TRUE}" && test -z "${gl_GNULIB_ENABLED_dosname_FALSE}"; then
22596 as_fn_error "conditional \"gl_GNULIB_ENABLED_dosname\" was never defined.
22597 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22598 fi
22599 if test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_TRUE}" && test -z "${gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36_FALSE}"; then
22600 as_fn_error "conditional \"gl_GNULIB_ENABLED_be453cec5eecf5731a274f2de7f2db36\" was never defined.
22601 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22602 fi
22603 if test -z "${gl_GNULIB_ENABLED_pathmax_TRUE}" && test -z "${gl_GNULIB_ENABLED_pathmax_FALSE}"; then
22604 as_fn_error "conditional \"gl_GNULIB_ENABLED_pathmax\" was never defined.
22605 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22606 fi
22607 if test -z "${gl_GNULIB_ENABLED_sigprocmask_TRUE}" && test -z "${gl_GNULIB_ENABLED_sigprocmask_FALSE}"; then
22608 as_fn_error "conditional \"gl_GNULIB_ENABLED_sigprocmask\" was never defined.
22609 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22610 fi
22611 if test -z "${gl_GNULIB_ENABLED_stat_TRUE}" && test -z "${gl_GNULIB_ENABLED_stat_FALSE}"; then
22612 as_fn_error "conditional \"gl_GNULIB_ENABLED_stat\" was never defined.
22613 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22614 fi
22615 if test -z "${gl_GNULIB_ENABLED_strtoll_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoll_FALSE}"; then
22616 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoll\" was never defined.
22617 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22618 fi
22619 if test -z "${gl_GNULIB_ENABLED_strtoull_TRUE}" && test -z "${gl_GNULIB_ENABLED_strtoull_FALSE}"; then
22620 as_fn_error "conditional \"gl_GNULIB_ENABLED_strtoull\" was never defined.
22621 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22622 fi
22623 if test -z "${gl_GNULIB_ENABLED_verify_TRUE}" && test -z "${gl_GNULIB_ENABLED_verify_FALSE}"; then
22624 as_fn_error "conditional \"gl_GNULIB_ENABLED_verify\" was never defined.
22625 Usually this means the macro was only invoked conditionally." "$LINENO" 5
22626 fi
22627
22628 gl_libobjs=
22629 gl_ltlibobjs=
22630 if test -n "$gl_LIBOBJS"; then
22631 # Remove the extension.
22632 sed_drop_objext='s/\.o$//;s/\.obj$//'
22633 for i in `for i in $gl_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
22634 gl_libobjs="$gl_libobjs $i.$ac_objext"
22635 gl_ltlibobjs="$gl_ltlibobjs $i.lo"
22636 done
22637 fi
22638 gl_LIBOBJS=$gl_libobjs
22639
22640 gl_LTLIBOBJS=$gl_ltlibobjs
22641
22642
22643
22644 gltests_libobjs=
22645 gltests_ltlibobjs=
22646 if test -n "$gltests_LIBOBJS"; then
22647 # Remove the extension.
22648 sed_drop_objext='s/\.o$//;s/\.obj$//'
22649 for i in `for i in $gltests_LIBOBJS; do echo "$i"; done | sed -e "$sed_drop_objext" | sort | uniq`; do
22650 gltests_libobjs="$gltests_libobjs $i.$ac_objext"
22651 gltests_ltlibobjs="$gltests_ltlibobjs $i.lo"
22652 done
22653 fi
22654 gltests_LIBOBJS=$gltests_libobjs
22655
22656 gltests_LTLIBOBJS=$gltests_ltlibobjs
22657
22658
22659
22660 : ${CONFIG_STATUS=./config.status}
22661 ac_write_fail=0
22662 ac_clean_files_save=$ac_clean_files
22663 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
22664 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
22665 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
22666 as_write_fail=0
22667 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
22668 #! $SHELL
22669 # Generated by $as_me.
22670 # Run this file to recreate the current configuration.
22671 # Compiler output produced by configure, useful for debugging
22672 # configure, is in config.log if it exists.
22673
22674 debug=false
22675 ac_cs_recheck=false
22676 ac_cs_silent=false
22677
22678 SHELL=\${CONFIG_SHELL-$SHELL}
22679 export SHELL
22680 _ASEOF
22681 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
22682 ## -------------------- ##
22683 ## M4sh Initialization. ##
22684 ## -------------------- ##
22685
22686 # Be more Bourne compatible
22687 DUALCASE=1; export DUALCASE # for MKS sh
22688 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
22689 emulate sh
22690 NULLCMD=:
22691 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
22692 # is contrary to our usage. Disable this feature.
22693 alias -g '${1+"$@"}'='"$@"'
22694 setopt NO_GLOB_SUBST
22695 else
22696 case `(set -o) 2>/dev/null` in #(
22697 *posix*) :
22698 set -o posix ;; #(
22699 *) :
22700 ;;
22701 esac
22702 fi
22703
22704
22705 as_nl='
22706 '
22707 export as_nl
22708 # Printing a long string crashes Solaris 7 /usr/bin/printf.
22709 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
22710 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
22711 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
22712 # Prefer a ksh shell builtin over an external printf program on Solaris,
22713 # but without wasting forks for bash or zsh.
22714 if test -z "$BASH_VERSION$ZSH_VERSION" \
22715 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
22716 as_echo='print -r --'
22717 as_echo_n='print -rn --'
22718 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
22719 as_echo='printf %s\n'
22720 as_echo_n='printf %s'
22721 else
22722 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
22723 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
22724 as_echo_n='/usr/ucb/echo -n'
22725 else
22726 as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
22727 as_echo_n_body='eval
22728 arg=$1;
22729 case $arg in #(
22730 *"$as_nl"*)
22731 expr "X$arg" : "X\\(.*\\)$as_nl";
22732 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
22733 esac;
22734 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
22735 '
22736 export as_echo_n_body
22737 as_echo_n='sh -c $as_echo_n_body as_echo'
22738 fi
22739 export as_echo_body
22740 as_echo='sh -c $as_echo_body as_echo'
22741 fi
22742
22743 # The user is always right.
22744 if test "${PATH_SEPARATOR+set}" != set; then
22745 PATH_SEPARATOR=:
22746 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
22747 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
22748 PATH_SEPARATOR=';'
22749 }
22750 fi
22751
22752
22753 # IFS
22754 # We need space, tab and new line, in precisely that order. Quoting is
22755 # there to prevent editors from complaining about space-tab.
22756 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
22757 # splitting by setting IFS to empty value.)
22758 IFS=" "" $as_nl"
22759
22760 # Find who we are. Look in the path if we contain no directory separator.
22761 case $0 in #((
22762 *[\\/]* ) as_myself=$0 ;;
22763 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22764 for as_dir in $PATH
22765 do
22766 IFS=$as_save_IFS
22767 test -z "$as_dir" && as_dir=.
22768 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
22769 done
22770 IFS=$as_save_IFS
22771
22772 ;;
22773 esac
22774 # We did not find ourselves, most probably we were run as `sh COMMAND'
22775 # in which case we are not to be found in the path.
22776 if test "x$as_myself" = x; then
22777 as_myself=$0
22778 fi
22779 if test ! -f "$as_myself"; then
22780 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
22781 exit 1
22782 fi
22783
22784 # Unset variables that we do not need and which cause bugs (e.g. in
22785 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1"
22786 # suppresses any "Segmentation fault" message there. '((' could
22787 # trigger a bug in pdksh 5.2.14.
22788 for as_var in BASH_ENV ENV MAIL MAILPATH
22789 do eval test x\${$as_var+set} = xset \
22790 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
22791 done
22792 PS1='$ '
22793 PS2='> '
22794 PS4='+ '
22795
22796 # NLS nuisances.
22797 LC_ALL=C
22798 export LC_ALL
22799 LANGUAGE=C
22800 export LANGUAGE
22801
22802 # CDPATH.
22803 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
22804
22805
22806 # as_fn_error ERROR [LINENO LOG_FD]
22807 # ---------------------------------
22808 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
22809 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
22810 # script with status $?, using 1 if that was 0.
22811 as_fn_error ()
22812 {
22813 as_status=$?; test $as_status -eq 0 && as_status=1
22814 if test "$3"; then
22815 as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
22816 $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3
22817 fi
22818 $as_echo "$as_me: error: $1" >&2
22819 as_fn_exit $as_status
22820 } # as_fn_error
22821
22822
22823 # as_fn_set_status STATUS
22824 # -----------------------
22825 # Set $? to STATUS, without forking.
22826 as_fn_set_status ()
22827 {
22828 return $1
22829 } # as_fn_set_status
22830
22831 # as_fn_exit STATUS
22832 # -----------------
22833 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
22834 as_fn_exit ()
22835 {
22836 set +e
22837 as_fn_set_status $1
22838 exit $1
22839 } # as_fn_exit
22840
22841 # as_fn_unset VAR
22842 # ---------------
22843 # Portably unset VAR.
22844 as_fn_unset ()
22845 {
22846 { eval $1=; unset $1;}
22847 }
22848 as_unset=as_fn_unset
22849 # as_fn_append VAR VALUE
22850 # ----------------------
22851 # Append the text in VALUE to the end of the definition contained in VAR. Take
22852 # advantage of any shell optimizations that allow amortized linear growth over
22853 # repeated appends, instead of the typical quadratic growth present in naive
22854 # implementations.
22855 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
22856 eval 'as_fn_append ()
22857 {
22858 eval $1+=\$2
22859 }'
22860 else
22861 as_fn_append ()
22862 {
22863 eval $1=\$$1\$2
22864 }
22865 fi # as_fn_append
22866
22867 # as_fn_arith ARG...
22868 # ------------------
22869 # Perform arithmetic evaluation on the ARGs, and store the result in the
22870 # global $as_val. Take advantage of shells that can avoid forks. The arguments
22871 # must be portable across $(()) and expr.
22872 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
22873 eval 'as_fn_arith ()
22874 {
22875 as_val=$(( $* ))
22876 }'
22877 else
22878 as_fn_arith ()
22879 {
22880 as_val=`expr "$@" || test $? -eq 1`
22881 }
22882 fi # as_fn_arith
22883
22884
22885 if expr a : '\(a\)' >/dev/null 2>&1 &&
22886 test "X`expr 00001 : '.*\(...\)'`" = X001; then
22887 as_expr=expr
22888 else
22889 as_expr=false
22890 fi
22891
22892 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
22893 as_basename=basename
22894 else
22895 as_basename=false
22896 fi
22897
22898 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
22899 as_dirname=dirname
22900 else
22901 as_dirname=false
22902 fi
22903
22904 as_me=`$as_basename -- "$0" ||
22905 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
22906 X"$0" : 'X\(//\)$' \| \
22907 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
22908 $as_echo X/"$0" |
22909 sed '/^.*\/\([^/][^/]*\)\/*$/{
22910 s//\1/
22911 q
22912 }
22913 /^X\/\(\/\/\)$/{
22914 s//\1/
22915 q
22916 }
22917 /^X\/\(\/\).*/{
22918 s//\1/
22919 q
22920 }
22921 s/.*/./; q'`
22922
22923 # Avoid depending upon Character Ranges.
22924 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
22925 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
22926 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
22927 as_cr_digits='0123456789'
22928 as_cr_alnum=$as_cr_Letters$as_cr_digits
22929
22930 ECHO_C= ECHO_N= ECHO_T=
22931 case `echo -n x` in #(((((
22932 -n*)
22933 case `echo 'xy\c'` in
22934 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
22935 xy) ECHO_C='\c';;
22936 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
22937 ECHO_T=' ';;
22938 esac;;
22939 *)
22940 ECHO_N='-n';;
22941 esac
22942
22943 rm -f conf$$ conf$$.exe conf$$.file
22944 if test -d conf$$.dir; then
22945 rm -f conf$$.dir/conf$$.file
22946 else
22947 rm -f conf$$.dir
22948 mkdir conf$$.dir 2>/dev/null
22949 fi
22950 if (echo >conf$$.file) 2>/dev/null; then
22951 if ln -s conf$$.file conf$$ 2>/dev/null; then
22952 as_ln_s='ln -s'
22953 # ... but there are two gotchas:
22954 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
22955 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
22956 # In both cases, we have to default to `cp -p'.
22957 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
22958 as_ln_s='cp -p'
22959 elif ln conf$$.file conf$$ 2>/dev/null; then
22960 as_ln_s=ln
22961 else
22962 as_ln_s='cp -p'
22963 fi
22964 else
22965 as_ln_s='cp -p'
22966 fi
22967 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
22968 rmdir conf$$.dir 2>/dev/null
22969
22970
22971 # as_fn_mkdir_p
22972 # -------------
22973 # Create "$as_dir" as a directory, including parents if necessary.
22974 as_fn_mkdir_p ()
22975 {
22976
22977 case $as_dir in #(
22978 -*) as_dir=./$as_dir;;
22979 esac
22980 test -d "$as_dir" || eval $as_mkdir_p || {
22981 as_dirs=
22982 while :; do
22983 case $as_dir in #(
22984 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
22985 *) as_qdir=$as_dir;;
22986 esac
22987 as_dirs="'$as_qdir' $as_dirs"
22988 as_dir=`$as_dirname -- "$as_dir" ||
22989 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
22990 X"$as_dir" : 'X\(//\)[^/]' \| \
22991 X"$as_dir" : 'X\(//\)$' \| \
22992 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
22993 $as_echo X"$as_dir" |
22994 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
22995 s//\1/
22996 q
22997 }
22998 /^X\(\/\/\)[^/].*/{
22999 s//\1/
23000 q
23001 }
23002 /^X\(\/\/\)$/{
23003 s//\1/
23004 q
23005 }
23006 /^X\(\/\).*/{
23007 s//\1/
23008 q
23009 }
23010 s/.*/./; q'`
23011 test -d "$as_dir" && break
23012 done
23013 test -z "$as_dirs" || eval "mkdir $as_dirs"
23014 } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir"
23015
23016
23017 } # as_fn_mkdir_p
23018 if mkdir -p . 2>/dev/null; then
23019 as_mkdir_p='mkdir -p "$as_dir"'
23020 else
23021 test -d ./-p && rmdir ./-p
23022 as_mkdir_p=false
23023 fi
23024
23025 if test -x / >/dev/null 2>&1; then
23026 as_test_x='test -x'
23027 else
23028 if ls -dL / >/dev/null 2>&1; then
23029 as_ls_L_option=L
23030 else
23031 as_ls_L_option=
23032 fi
23033 as_test_x='
23034 eval sh -c '\''
23035 if test -d "$1"; then
23036 test -d "$1/.";
23037 else
23038 case $1 in #(
23039 -*)set "./$1";;
23040 esac;
23041 case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
23042 ???[sx]*):;;*)false;;esac;fi
23043 '\'' sh
23044 '
23045 fi
23046 as_executable_p=$as_test_x
23047
23048 # Sed expression to map a string onto a valid CPP name.
23049 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
23050
23051 # Sed expression to map a string onto a valid variable name.
23052 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
23053
23054
23055 exec 6>&1
23056 ## ----------------------------------- ##
23057 ## Main body of $CONFIG_STATUS script. ##
23058 ## ----------------------------------- ##
23059 _ASEOF
23060 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
23061
23062 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23063 # Save the log message, to keep $0 and so on meaningful, and to
23064 # report actual input values of CONFIG_FILES etc. instead of their
23065 # values after options handling.
23066 ac_log="
23067 This file was extended by emacs $as_me 24.1.50, which was
23068 generated by GNU Autoconf 2.65. Invocation command line was
23069
23070 CONFIG_FILES = $CONFIG_FILES
23071 CONFIG_HEADERS = $CONFIG_HEADERS
23072 CONFIG_LINKS = $CONFIG_LINKS
23073 CONFIG_COMMANDS = $CONFIG_COMMANDS
23074 $ $0 $@
23075
23076 on `(hostname || uname -n) 2>/dev/null | sed 1q`
23077 "
23078
23079 _ACEOF
23080
23081 case $ac_config_files in *"
23082 "*) set x $ac_config_files; shift; ac_config_files=$*;;
23083 esac
23084
23085 case $ac_config_headers in *"
23086 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
23087 esac
23088
23089
23090 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23091 # Files that config.status was made for.
23092 config_files="$ac_config_files"
23093 config_headers="$ac_config_headers"
23094 config_commands="$ac_config_commands"
23095
23096 _ACEOF
23097
23098 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23099 ac_cs_usage="\
23100 \`$as_me' instantiates files and other configuration actions
23101 from templates according to the current configuration. Unless the files
23102 and actions are specified as TAGs, all are instantiated by default.
23103
23104 Usage: $0 [OPTION]... [TAG]...
23105
23106 -h, --help print this help, then exit
23107 -V, --version print version number and configuration settings, then exit
23108 --config print configuration, then exit
23109 -q, --quiet, --silent
23110 do not print progress messages
23111 -d, --debug don't remove temporary files
23112 --recheck update $as_me by reconfiguring in the same conditions
23113 --file=FILE[:TEMPLATE]
23114 instantiate the configuration file FILE
23115 --header=FILE[:TEMPLATE]
23116 instantiate the configuration header FILE
23117
23118 Configuration files:
23119 $config_files
23120
23121 Configuration headers:
23122 $config_headers
23123
23124 Configuration commands:
23125 $config_commands
23126
23127 Report bugs to the package provider."
23128
23129 _ACEOF
23130 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23131 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
23132 ac_cs_version="\\
23133 emacs config.status 24.1.50
23134 configured by $0, generated by GNU Autoconf 2.65,
23135 with options \\"\$ac_cs_config\\"
23136
23137 Copyright (C) 2009 Free Software Foundation, Inc.
23138 This config.status script is free software; the Free Software Foundation
23139 gives unlimited permission to copy, distribute and modify it."
23140
23141 ac_pwd='$ac_pwd'
23142 srcdir='$srcdir'
23143 INSTALL='$INSTALL'
23144 MKDIR_P='$MKDIR_P'
23145 AWK='$AWK'
23146 test -n "\$AWK" || AWK=awk
23147 _ACEOF
23148
23149 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23150 # The default lists apply if the user does not specify any file.
23151 ac_need_defaults=:
23152 while test $# != 0
23153 do
23154 case $1 in
23155 --*=*)
23156 ac_option=`expr "X$1" : 'X\([^=]*\)='`
23157 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
23158 ac_shift=:
23159 ;;
23160 *)
23161 ac_option=$1
23162 ac_optarg=$2
23163 ac_shift=shift
23164 ;;
23165 esac
23166
23167 case $ac_option in
23168 # Handling of the options.
23169 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23170 ac_cs_recheck=: ;;
23171 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
23172 $as_echo "$ac_cs_version"; exit ;;
23173 --config | --confi | --conf | --con | --co | --c )
23174 $as_echo "$ac_cs_config"; exit ;;
23175 --debug | --debu | --deb | --de | --d | -d )
23176 debug=: ;;
23177 --file | --fil | --fi | --f )
23178 $ac_shift
23179 case $ac_optarg in
23180 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23181 esac
23182 as_fn_append CONFIG_FILES " '$ac_optarg'"
23183 ac_need_defaults=false;;
23184 --header | --heade | --head | --hea )
23185 $ac_shift
23186 case $ac_optarg in
23187 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23188 esac
23189 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
23190 ac_need_defaults=false;;
23191 --he | --h)
23192 # Conflict between --help and --header
23193 as_fn_error "ambiguous option: \`$1'
23194 Try \`$0 --help' for more information.";;
23195 --help | --hel | -h )
23196 $as_echo "$ac_cs_usage"; exit ;;
23197 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23198 | -silent | --silent | --silen | --sile | --sil | --si | --s)
23199 ac_cs_silent=: ;;
23200
23201 # This is an error.
23202 -*) as_fn_error "unrecognized option: \`$1'
23203 Try \`$0 --help' for more information." ;;
23204
23205 *) as_fn_append ac_config_targets " $1"
23206 ac_need_defaults=false ;;
23207
23208 esac
23209 shift
23210 done
23211
23212 ac_configure_extra_args=
23213
23214 if $ac_cs_silent; then
23215 exec 6>/dev/null
23216 ac_configure_extra_args="$ac_configure_extra_args --silent"
23217 fi
23218
23219 _ACEOF
23220 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23221 if \$ac_cs_recheck; then
23222 set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23223 shift
23224 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
23225 CONFIG_SHELL='$SHELL'
23226 export CONFIG_SHELL
23227 exec "\$@"
23228 fi
23229
23230 _ACEOF
23231 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23232 exec 5>>config.log
23233 {
23234 echo
23235 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23236 ## Running $as_me. ##
23237 _ASBOX
23238 $as_echo "$ac_log"
23239 } >&5
23240
23241 _ACEOF
23242 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23243 #
23244 # INIT-COMMANDS
23245 #
23246 AMDEP_TRUE="$AMDEP_TRUE" ac_aux_dir="$ac_aux_dir"
23247 GCC="$GCC" NON_GNU_CPP="$NON_GNU_CPP" CPP="$CPP" CPPFLAGS="$CPPFLAGS"
23248
23249 _ACEOF
23250
23251 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23252
23253 # Handling of arguments.
23254 for ac_config_target in $ac_config_targets
23255 do
23256 case $ac_config_target in
23257 "src/config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/config.h:src/config.in" ;;
23258 "depfiles") CONFIG_COMMANDS="$CONFIG_COMMANDS depfiles" ;;
23259 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
23260 "lib/Makefile") CONFIG_FILES="$CONFIG_FILES lib/Makefile" ;;
23261 "lib-src/Makefile") CONFIG_FILES="$CONFIG_FILES lib-src/Makefile" ;;
23262 "oldXMenu/Makefile") CONFIG_FILES="$CONFIG_FILES oldXMenu/Makefile" ;;
23263 "doc/emacs/Makefile") CONFIG_FILES="$CONFIG_FILES doc/emacs/Makefile" ;;
23264 "doc/misc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/misc/Makefile" ;;
23265 "doc/lispintro/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispintro/Makefile" ;;
23266 "doc/lispref/Makefile") CONFIG_FILES="$CONFIG_FILES doc/lispref/Makefile" ;;
23267 "src/Makefile") CONFIG_FILES="$CONFIG_FILES src/Makefile" ;;
23268 "lwlib/Makefile") CONFIG_FILES="$CONFIG_FILES lwlib/Makefile" ;;
23269 "lisp/Makefile") CONFIG_FILES="$CONFIG_FILES lisp/Makefile" ;;
23270 "leim/Makefile") CONFIG_FILES="$CONFIG_FILES leim/Makefile" ;;
23271 "test/automated/Makefile") CONFIG_FILES="$CONFIG_FILES test/automated/Makefile" ;;
23272 "admin/unidata/Makefile") CONFIG_FILES="$CONFIG_FILES admin/unidata/Makefile" ;;
23273 "mkdirs") CONFIG_COMMANDS="$CONFIG_COMMANDS mkdirs" ;;
23274 "epaths") CONFIG_COMMANDS="$CONFIG_COMMANDS epaths" ;;
23275 "gdbinit") CONFIG_COMMANDS="$CONFIG_COMMANDS gdbinit" ;;
23276
23277 *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;;
23278 esac
23279 done
23280
23281
23282 # If the user did not use the arguments to specify the items to instantiate,
23283 # then the envvar interface is used. Set only those that are not.
23284 # We use the long form for the default assignment because of an extremely
23285 # bizarre bug on SunOS 4.1.3.
23286 if $ac_need_defaults; then
23287 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
23288 test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
23289 test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
23290 fi
23291
23292 # Have a temporary directory for convenience. Make it in the build tree
23293 # simply because there is no reason against having it here, and in addition,
23294 # creating and moving files from /tmp can sometimes cause problems.
23295 # Hook for its removal unless debugging.
23296 # Note that there is a small window in which the directory will not be cleaned:
23297 # after its creation but before its name has been assigned to `$tmp'.
23298 $debug ||
23299 {
23300 tmp=
23301 trap 'exit_status=$?
23302 { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
23303 ' 0
23304 trap 'as_fn_exit 1' 1 2 13 15
23305 }
23306 # Create a (secure) tmp directory for tmp files.
23307
23308 {
23309 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
23310 test -n "$tmp" && test -d "$tmp"
23311 } ||
23312 {
23313 tmp=./conf$$-$RANDOM
23314 (umask 077 && mkdir "$tmp")
23315 } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5
23316
23317 # Set up the scripts for CONFIG_FILES section.
23318 # No need to generate them if there are no CONFIG_FILES.
23319 # This happens for instance with `./config.status config.h'.
23320 if test -n "$CONFIG_FILES"; then
23321
23322 if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then
23323 ac_cs_awk_getline=:
23324 ac_cs_awk_pipe_init=
23325 ac_cs_awk_read_file='
23326 while ((getline aline < (F[key])) > 0)
23327 print(aline)
23328 close(F[key])'
23329 ac_cs_awk_pipe_fini=
23330 else
23331 ac_cs_awk_getline=false
23332 ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\""
23333 ac_cs_awk_read_file='
23334 print "|#_!!_#|"
23335 print "cat " F[key] " &&"
23336 '$ac_cs_awk_pipe_init
23337 # The final `:' finishes the AND list.
23338 ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }'
23339 fi
23340 ac_cr=`echo X | tr X '\015'`
23341 # On cygwin, bash can eat \r inside `` if the user requested igncr.
23342 # But we know of no other shell where ac_cr would be empty at this
23343 # point, so we can use a bashism as a fallback.
23344 if test "x$ac_cr" = x; then
23345 eval ac_cr=\$\'\\r\'
23346 fi
23347 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
23348 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
23349 ac_cs_awk_cr='\r'
23350 else
23351 ac_cs_awk_cr=$ac_cr
23352 fi
23353
23354 echo 'BEGIN {' >"$tmp/subs1.awk" &&
23355 _ACEOF
23356
23357 # Create commands to substitute file output variables.
23358 {
23359 echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" &&
23360 echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' &&
23361 echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' &&
23362 echo "_ACAWK" &&
23363 echo "_ACEOF"
23364 } >conf$$files.sh &&
23365 . ./conf$$files.sh ||
23366 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23367 rm -f conf$$files.sh
23368
23369 {
23370 echo "cat >conf$$subs.awk <<_ACEOF" &&
23371 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
23372 echo "_ACEOF"
23373 } >conf$$subs.sh ||
23374 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23375 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
23376 ac_delim='%!_!# '
23377 for ac_last_try in false false false false false :; do
23378 . ./conf$$subs.sh ||
23379 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23380
23381 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
23382 if test $ac_delim_n = $ac_delim_num; then
23383 break
23384 elif $ac_last_try; then
23385 as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5
23386 else
23387 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23388 fi
23389 done
23390 rm -f conf$$subs.sh
23391
23392 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23393 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
23394 _ACEOF
23395 sed -n '
23396 h
23397 s/^/S["/; s/!.*/"]=/
23398 p
23399 g
23400 s/^[^!]*!//
23401 :repl
23402 t repl
23403 s/'"$ac_delim"'$//
23404 t delim
23405 :nl
23406 h
23407 s/\(.\{148\}\)..*/\1/
23408 t more1
23409 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
23410 p
23411 n
23412 b repl
23413 :more1
23414 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23415 p
23416 g
23417 s/.\{148\}//
23418 t nl
23419 :delim
23420 h
23421 s/\(.\{148\}\)..*/\1/
23422 t more2
23423 s/["\\]/\\&/g; s/^/"/; s/$/"/
23424 p
23425 b
23426 :more2
23427 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
23428 p
23429 g
23430 s/.\{148\}//
23431 t delim
23432 ' <conf$$subs.awk | sed '
23433 /^[^""]/{
23434 N
23435 s/\n//
23436 }
23437 ' >>$CONFIG_STATUS || ac_write_fail=1
23438 rm -f conf$$subs.awk
23439 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23440 _ACAWK
23441 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
23442 for (key in S) S_is_set[key] = 1
23443 FS = "\a"
23444 \$ac_cs_awk_pipe_init
23445 }
23446 {
23447 line = $ 0
23448 nfields = split(line, field, "@")
23449 substed = 0
23450 len = length(field[1])
23451 for (i = 2; i < nfields; i++) {
23452 key = field[i]
23453 keylen = length(key)
23454 if (S_is_set[key]) {
23455 value = S[key]
23456 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
23457 len += length(value) + length(field[++i])
23458 substed = 1
23459 } else
23460 len += 1 + keylen
23461 }
23462 if (nfields == 3 && !substed) {
23463 key = field[2]
23464 if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) {
23465 \$ac_cs_awk_read_file
23466 next
23467 }
23468 }
23469 print line
23470 }
23471 \$ac_cs_awk_pipe_fini
23472 _ACAWK
23473 _ACEOF
23474 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23475 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
23476 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
23477 else
23478 cat
23479 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
23480 || as_fn_error "could not setup config files machinery" "$LINENO" 5
23481 _ACEOF
23482
23483 # VPATH may cause trouble with some makes, so we remove $(srcdir),
23484 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
23485 # trailing colons and then remove the whole line if VPATH becomes empty
23486 # (actually we leave an empty line to preserve line numbers).
23487 if test "x$srcdir" = x.; then
23488 ac_vpsub='/^[ ]*VPATH[ ]*=/{
23489 s/:*\$(srcdir):*/:/
23490 s/:*\${srcdir}:*/:/
23491 s/:*@srcdir@:*/:/
23492 s/^\([^=]*=[ ]*\):*/\1/
23493 s/:*$//
23494 s/^[^=]*=[ ]*$//
23495 }'
23496 fi
23497
23498 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23499 fi # test -n "$CONFIG_FILES"
23500
23501 # Set up the scripts for CONFIG_HEADERS section.
23502 # No need to generate them if there are no CONFIG_HEADERS.
23503 # This happens for instance with `./config.status Makefile'.
23504 if test -n "$CONFIG_HEADERS"; then
23505 cat >"$tmp/defines.awk" <<\_ACAWK ||
23506 BEGIN {
23507 _ACEOF
23508
23509 # Transform confdefs.h into an awk script `defines.awk', embedded as
23510 # here-document in config.status, that substitutes the proper values into
23511 # config.h.in to produce config.h.
23512
23513 # Create a delimiter string that does not exist in confdefs.h, to ease
23514 # handling of long lines.
23515 ac_delim='%!_!# '
23516 for ac_last_try in false false :; do
23517 ac_t=`sed -n "/$ac_delim/p" confdefs.h`
23518 if test -z "$ac_t"; then
23519 break
23520 elif $ac_last_try; then
23521 as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5
23522 else
23523 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
23524 fi
23525 done
23526
23527 # For the awk script, D is an array of macro values keyed by name,
23528 # likewise P contains macro parameters if any. Preserve backslash
23529 # newline sequences.
23530
23531 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
23532 sed -n '
23533 s/.\{148\}/&'"$ac_delim"'/g
23534 t rset
23535 :rset
23536 s/^[ ]*#[ ]*define[ ][ ]*/ /
23537 t def
23538 d
23539 :def
23540 s/\\$//
23541 t bsnl
23542 s/["\\]/\\&/g
23543 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
23544 D["\1"]=" \3"/p
23545 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
23546 d
23547 :bsnl
23548 s/["\\]/\\&/g
23549 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
23550 D["\1"]=" \3\\\\\\n"\\/p
23551 t cont
23552 s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
23553 t cont
23554 d
23555 :cont
23556 n
23557 s/.\{148\}/&'"$ac_delim"'/g
23558 t clear
23559 :clear
23560 s/\\$//
23561 t bsnlc
23562 s/["\\]/\\&/g; s/^/"/; s/$/"/p
23563 d
23564 :bsnlc
23565 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
23566 b cont
23567 ' <confdefs.h | sed '
23568 s/'"$ac_delim"'/"\\\
23569 "/g' >>$CONFIG_STATUS || ac_write_fail=1
23570
23571 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23572 for (key in D) D_is_set[key] = 1
23573 FS = "\a"
23574 }
23575 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
23576 line = \$ 0
23577 split(line, arg, " ")
23578 if (arg[1] == "#") {
23579 defundef = arg[2]
23580 mac1 = arg[3]
23581 } else {
23582 defundef = substr(arg[1], 2)
23583 mac1 = arg[2]
23584 }
23585 split(mac1, mac2, "(") #)
23586 macro = mac2[1]
23587 prefix = substr(line, 1, index(line, defundef) - 1)
23588 if (D_is_set[macro]) {
23589 # Preserve the white space surrounding the "#".
23590 print prefix "define", macro P[macro] D[macro]
23591 next
23592 } else {
23593 # Replace #undef with comments. This is necessary, for example,
23594 # in the case of _POSIX_SOURCE, which is predefined and required
23595 # on some systems where configure will not decide to define it.
23596 if (defundef == "undef") {
23597 print "/*", prefix defundef, macro, "*/"
23598 next
23599 }
23600 }
23601 }
23602 { print }
23603 _ACAWK
23604 _ACEOF
23605 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23606 as_fn_error "could not setup config headers machinery" "$LINENO" 5
23607 fi # test -n "$CONFIG_HEADERS"
23608
23609
23610 eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
23611 shift
23612 for ac_tag
23613 do
23614 case $ac_tag in
23615 :[FHLC]) ac_mode=$ac_tag; continue;;
23616 esac
23617 case $ac_mode$ac_tag in
23618 :[FHL]*:*);;
23619 :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;;
23620 :[FH]-) ac_tag=-:-;;
23621 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
23622 esac
23623 ac_save_IFS=$IFS
23624 IFS=:
23625 set x $ac_tag
23626 IFS=$ac_save_IFS
23627 shift
23628 ac_file=$1
23629 shift
23630
23631 case $ac_mode in
23632 :L) ac_source=$1;;
23633 :[FH])
23634 ac_file_inputs=
23635 for ac_f
23636 do
23637 case $ac_f in
23638 -) ac_f="$tmp/stdin";;
23639 *) # Look for the file first in the build tree, then in the source tree
23640 # (if the path is not absolute). The absolute path cannot be DOS-style,
23641 # because $ac_f cannot contain `:'.
23642 test -f "$ac_f" ||
23643 case $ac_f in
23644 [\\/$]*) false;;
23645 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
23646 esac ||
23647 as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;;
23648 esac
23649 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
23650 as_fn_append ac_file_inputs " '$ac_f'"
23651 done
23652
23653 # Let's still pretend it is `configure' which instantiates (i.e., don't
23654 # use $as_me), people would be surprised to read:
23655 # /* config.h. Generated by config.status. */
23656 configure_input='Generated from '`
23657 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
23658 `' by configure.'
23659 if test x"$ac_file" != x-; then
23660 configure_input="$ac_file. $configure_input"
23661 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
23662 $as_echo "$as_me: creating $ac_file" >&6;}
23663 fi
23664 # Neutralize special characters interpreted by sed in replacement strings.
23665 case $configure_input in #(
23666 *\&* | *\|* | *\\* )
23667 ac_sed_conf_input=`$as_echo "$configure_input" |
23668 sed 's/[\\\\&|]/\\\\&/g'`;; #(
23669 *) ac_sed_conf_input=$configure_input;;
23670 esac
23671
23672 case $ac_tag in
23673 *:-:* | *:-) cat >"$tmp/stdin" \
23674 || as_fn_error "could not create $ac_file" "$LINENO" 5 ;;
23675 esac
23676 ;;
23677 esac
23678
23679 ac_dir=`$as_dirname -- "$ac_file" ||
23680 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23681 X"$ac_file" : 'X\(//\)[^/]' \| \
23682 X"$ac_file" : 'X\(//\)$' \| \
23683 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
23684 $as_echo X"$ac_file" |
23685 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23686 s//\1/
23687 q
23688 }
23689 /^X\(\/\/\)[^/].*/{
23690 s//\1/
23691 q
23692 }
23693 /^X\(\/\/\)$/{
23694 s//\1/
23695 q
23696 }
23697 /^X\(\/\).*/{
23698 s//\1/
23699 q
23700 }
23701 s/.*/./; q'`
23702 as_dir="$ac_dir"; as_fn_mkdir_p
23703 ac_builddir=.
23704
23705 case "$ac_dir" in
23706 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
23707 *)
23708 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
23709 # A ".." for each directory in $ac_dir_suffix.
23710 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
23711 case $ac_top_builddir_sub in
23712 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
23713 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
23714 esac ;;
23715 esac
23716 ac_abs_top_builddir=$ac_pwd
23717 ac_abs_builddir=$ac_pwd$ac_dir_suffix
23718 # for backward compatibility:
23719 ac_top_builddir=$ac_top_build_prefix
23720
23721 case $srcdir in
23722 .) # We are building in place.
23723 ac_srcdir=.
23724 ac_top_srcdir=$ac_top_builddir_sub
23725 ac_abs_top_srcdir=$ac_pwd ;;
23726 [\\/]* | ?:[\\/]* ) # Absolute name.
23727 ac_srcdir=$srcdir$ac_dir_suffix;
23728 ac_top_srcdir=$srcdir
23729 ac_abs_top_srcdir=$srcdir ;;
23730 *) # Relative name.
23731 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
23732 ac_top_srcdir=$ac_top_build_prefix$srcdir
23733 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
23734 esac
23735 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
23736
23737
23738 case $ac_mode in
23739 :F)
23740 #
23741 # CONFIG_FILE
23742 #
23743
23744 case $INSTALL in
23745 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
23746 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
23747 esac
23748 ac_MKDIR_P=$MKDIR_P
23749 case $MKDIR_P in
23750 [\\/$]* | ?:[\\/]* ) ;;
23751 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
23752 esac
23753 _ACEOF
23754
23755 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23756 # If the template does not know about datarootdir, expand it.
23757 # FIXME: This hack should be removed a few years after 2.60.
23758 ac_datarootdir_hack=; ac_datarootdir_seen=
23759 ac_sed_dataroot='
23760 /datarootdir/ {
23761 p
23762 q
23763 }
23764 /@datadir@/p
23765 /@docdir@/p
23766 /@infodir@/p
23767 /@localedir@/p
23768 /@mandir@/p'
23769 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
23770 *datarootdir*) ac_datarootdir_seen=yes;;
23771 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
23772 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
23773 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
23774 _ACEOF
23775 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23776 ac_datarootdir_hack='
23777 s&@datadir@&$datadir&g
23778 s&@docdir@&$docdir&g
23779 s&@infodir@&$infodir&g
23780 s&@localedir@&$localedir&g
23781 s&@mandir@&$mandir&g
23782 s&\\\${datarootdir}&$datarootdir&g' ;;
23783 esac
23784 _ACEOF
23785
23786 # Neutralize VPATH when `$srcdir' = `.'.
23787 # Shell code in configure.ac might set extrasub.
23788 # FIXME: do we really want to maintain this feature?
23789 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23790 ac_sed_extra="$ac_vpsub
23791 $extrasub
23792 _ACEOF
23793 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23794 :t
23795 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
23796 s|@configure_input@|$ac_sed_conf_input|;t t
23797 s&@top_builddir@&$ac_top_builddir_sub&;t t
23798 s&@top_build_prefix@&$ac_top_build_prefix&;t t
23799 s&@srcdir@&$ac_srcdir&;t t
23800 s&@abs_srcdir@&$ac_abs_srcdir&;t t
23801 s&@top_srcdir@&$ac_top_srcdir&;t t
23802 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
23803 s&@builddir@&$ac_builddir&;t t
23804 s&@abs_builddir@&$ac_abs_builddir&;t t
23805 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
23806 s&@INSTALL@&$ac_INSTALL&;t t
23807 s&@MKDIR_P@&$ac_MKDIR_P&;t t
23808 $ac_datarootdir_hack
23809 "
23810 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" |
23811 if $ac_cs_awk_getline; then
23812 $AWK -f "$tmp/subs.awk"
23813 else
23814 $AWK -f "$tmp/subs.awk" | $SHELL
23815 fi >$tmp/out \
23816 || as_fn_error "could not create $ac_file" "$LINENO" 5
23817
23818 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
23819 { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
23820 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
23821 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23822 which seems to be undefined. Please make sure it is defined." >&5
23823 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
23824 which seems to be undefined. Please make sure it is defined." >&2;}
23825
23826 rm -f "$tmp/stdin"
23827 case $ac_file in
23828 -) cat "$tmp/out" && rm -f "$tmp/out";;
23829 *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
23830 esac \
23831 || as_fn_error "could not create $ac_file" "$LINENO" 5
23832 ;;
23833 :H)
23834 #
23835 # CONFIG_HEADER
23836 #
23837 if test x"$ac_file" != x-; then
23838 {
23839 $as_echo "/* $configure_input */" \
23840 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
23841 } >"$tmp/config.h" \
23842 || as_fn_error "could not create $ac_file" "$LINENO" 5
23843 if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
23844 { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
23845 $as_echo "$as_me: $ac_file is unchanged" >&6;}
23846 else
23847 rm -f "$ac_file"
23848 mv "$tmp/config.h" "$ac_file" \
23849 || as_fn_error "could not create $ac_file" "$LINENO" 5
23850 fi
23851 else
23852 $as_echo "/* $configure_input */" \
23853 && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
23854 || as_fn_error "could not create -" "$LINENO" 5
23855 fi
23856 # Compute "$ac_file"'s index in $config_headers.
23857 _am_arg="$ac_file"
23858 _am_stamp_count=1
23859 for _am_header in $config_headers :; do
23860 case $_am_header in
23861 $_am_arg | $_am_arg:* )
23862 break ;;
23863 * )
23864 _am_stamp_count=`expr $_am_stamp_count + 1` ;;
23865 esac
23866 done
23867 echo "timestamp for $_am_arg" >`$as_dirname -- "$_am_arg" ||
23868 $as_expr X"$_am_arg" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23869 X"$_am_arg" : 'X\(//\)[^/]' \| \
23870 X"$_am_arg" : 'X\(//\)$' \| \
23871 X"$_am_arg" : 'X\(/\)' \| . 2>/dev/null ||
23872 $as_echo X"$_am_arg" |
23873 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23874 s//\1/
23875 q
23876 }
23877 /^X\(\/\/\)[^/].*/{
23878 s//\1/
23879 q
23880 }
23881 /^X\(\/\/\)$/{
23882 s//\1/
23883 q
23884 }
23885 /^X\(\/\).*/{
23886 s//\1/
23887 q
23888 }
23889 s/.*/./; q'`/stamp-h$_am_stamp_count
23890 ;;
23891
23892 :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
23893 $as_echo "$as_me: executing $ac_file commands" >&6;}
23894 ;;
23895 esac
23896
23897
23898 case $ac_file$ac_mode in
23899 "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
23900 # Autoconf 2.62 quotes --file arguments for eval, but not when files
23901 # are listed without --file. Let's play safe and only enable the eval
23902 # if we detect the quoting.
23903 case $CONFIG_FILES in
23904 *\'*) eval set x "$CONFIG_FILES" ;;
23905 *) set x $CONFIG_FILES ;;
23906 esac
23907 shift
23908 for mf
23909 do
23910 # Strip MF so we end up with the name of the file.
23911 mf=`echo "$mf" | sed -e 's/:.*$//'`
23912 # Check whether this is an Automake generated Makefile or not.
23913 # We used to match only the files named `Makefile.in', but
23914 # some people rename them; so instead we look at the file content.
23915 # Grep'ing the first line is not enough: some people post-process
23916 # each Makefile.in and add a new line on top of each file to say so.
23917 # Grep'ing the whole file is not good either: AIX grep has a line
23918 # limit of 2048, but all sed's we know have understand at least 4000.
23919 if sed -n 's,^#.*generated by automake.*,X,p' "$mf" | grep X >/dev/null 2>&1; then
23920 dirpart=`$as_dirname -- "$mf" ||
23921 $as_expr X"$mf" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23922 X"$mf" : 'X\(//\)[^/]' \| \
23923 X"$mf" : 'X\(//\)$' \| \
23924 X"$mf" : 'X\(/\)' \| . 2>/dev/null ||
23925 $as_echo X"$mf" |
23926 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23927 s//\1/
23928 q
23929 }
23930 /^X\(\/\/\)[^/].*/{
23931 s//\1/
23932 q
23933 }
23934 /^X\(\/\/\)$/{
23935 s//\1/
23936 q
23937 }
23938 /^X\(\/\).*/{
23939 s//\1/
23940 q
23941 }
23942 s/.*/./; q'`
23943 else
23944 continue
23945 fi
23946 # Extract the definition of DEPDIR, am__include, and am__quote
23947 # from the Makefile without running `make'.
23948 DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
23949 test -z "$DEPDIR" && continue
23950 am__include=`sed -n 's/^am__include = //p' < "$mf"`
23951 test -z "am__include" && continue
23952 am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
23953 # When using ansi2knr, U may be empty or an underscore; expand it
23954 U=`sed -n 's/^U = //p' < "$mf"`
23955 # Find all dependency output files, they are included files with
23956 # $(DEPDIR) in their names. We invoke sed twice because it is the
23957 # simplest approach to changing $(DEPDIR) to its actual value in the
23958 # expansion.
23959 for file in `sed -n "
23960 s/^$am__include $am__quote\(.*(DEPDIR).*\)$am__quote"'$/\1/p' <"$mf" | \
23961 sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
23962 # Make sure the directory exists.
23963 test -f "$dirpart/$file" && continue
23964 fdir=`$as_dirname -- "$file" ||
23965 $as_expr X"$file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23966 X"$file" : 'X\(//\)[^/]' \| \
23967 X"$file" : 'X\(//\)$' \| \
23968 X"$file" : 'X\(/\)' \| . 2>/dev/null ||
23969 $as_echo X"$file" |
23970 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23971 s//\1/
23972 q
23973 }
23974 /^X\(\/\/\)[^/].*/{
23975 s//\1/
23976 q
23977 }
23978 /^X\(\/\/\)$/{
23979 s//\1/
23980 q
23981 }
23982 /^X\(\/\).*/{
23983 s//\1/
23984 q
23985 }
23986 s/.*/./; q'`
23987 as_dir=$dirpart/$fdir; as_fn_mkdir_p
23988 # echo "creating $dirpart/$file"
23989 echo '# dummy' > "$dirpart/$file"
23990 done
23991 done
23992 }
23993 ;;
23994 "mkdirs":C)
23995 for dir in etc lisp ; do
23996 test -d ${dir} || mkdir ${dir}
23997 done
23998 ;;
23999 "epaths":C)
24000 echo creating src/epaths.h
24001 ${MAKE-make} epaths-force
24002 ;;
24003 "gdbinit":C)
24004 if test ! -f src/.gdbinit && test -f $srcdir/src/.gdbinit; then
24005 echo creating src/.gdbinit
24006 echo source $srcdir/src/.gdbinit > src/.gdbinit
24007 fi
24008 ;;
24009
24010 esac
24011 done # for ac_tag
24012
24013
24014 as_fn_exit 0
24015 _ACEOF
24016 ac_clean_files=$ac_clean_files_save
24017
24018 test $ac_write_fail = 0 ||
24019 as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5
24020
24021
24022 # configure is writing to config.log, and then calls config.status.
24023 # config.status does its own redirection, appending to config.log.
24024 # Unfortunately, on DOS this fails, as config.log is still kept open
24025 # by configure, so config.status won't be able to write to it; its
24026 # output is simply discarded. So we exec the FD to /dev/null,
24027 # effectively closing config.log, so it can be properly (re)opened and
24028 # appended to by config.status. When coming back to configure, we
24029 # need to make the FD available again.
24030 if test "$no_create" != yes; then
24031 ac_cs_success=:
24032 ac_config_status_args=
24033 test "$silent" = yes &&
24034 ac_config_status_args="$ac_config_status_args --quiet"
24035 exec 5>/dev/null
24036 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24037 exec 5>>config.log
24038 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24039 # would make configure fail if this is the last instruction.
24040 $ac_cs_success || as_fn_exit $?
24041 fi
24042 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24043 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24044 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
24045 fi
24046
24047