]> git.ipfire.org Git - thirdparty/bash.git/blame_incremental - configure
Bash-5.3 distribution sources and documentation
[thirdparty/bash.git] / configure
... / ...
CommitLineData
1#! /bin/sh
2# From configure.ac for Bash 5.3, version 5.080.
3# Guess values for system-dependent variables and create Makefiles.
4# Generated by GNU Autoconf 2.72 for bash 5.3-release.
5#
6# Report bugs to <bug-bash@gnu.org>.
7#
8#
9# Copyright (C) 1992-1996, 1998-2017, 2020-2023 Free Software Foundation,
10# Inc.
11#
12#
13# This configure script is free software; the Free Software Foundation
14# gives unlimited permission to copy, distribute and modify it.
15## -------------------- ##
16## M4sh Initialization. ##
17## -------------------- ##
18
19# Be more Bourne compatible
20DUALCASE=1; export DUALCASE # for MKS sh
21if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
22then :
23 emulate sh
24 NULLCMD=:
25 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26 # is contrary to our usage. Disable this feature.
27 alias -g '${1+"$@"}'='"$@"'
28 setopt NO_GLOB_SUBST
29else case e in #(
30 e) case `(set -o) 2>/dev/null` in #(
31 *posix*) :
32 set -o posix ;; #(
33 *) :
34 ;;
35esac ;;
36esac
37fi
38
39
40
41# Reset variables that may have inherited troublesome values from
42# the environment.
43
44# IFS needs to be set, to space, tab, and newline, in precisely that order.
45# (If _AS_PATH_WALK were called with IFS unset, it would have the
46# side effect of setting IFS to empty, thus disabling word splitting.)
47# Quoting is to prevent editors from complaining about space-tab.
48as_nl='
49'
50export as_nl
51IFS=" "" $as_nl"
52
53PS1='$ '
54PS2='> '
55PS4='+ '
56
57# Ensure predictable behavior from utilities with locale-dependent output.
58LC_ALL=C
59export LC_ALL
60LANGUAGE=C
61export LANGUAGE
62
63# We cannot yet rely on "unset" to work, but we need these variables
64# to be unset--not just set to an empty or harmless value--now, to
65# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
66# also avoids known problems related to "unset" and subshell syntax
67# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
68for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
69do eval test \${$as_var+y} \
70 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
71done
72
73# Ensure that fds 0, 1, and 2 are open.
74if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
75if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
76if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
77
78# The user is always right.
79if ${PATH_SEPARATOR+false} :; then
80 PATH_SEPARATOR=:
81 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
82 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
83 PATH_SEPARATOR=';'
84 }
85fi
86
87
88# Find who we are. Look in the path if we contain no directory separator.
89as_myself=
90case $0 in #((
91 *[\\/]* ) as_myself=$0 ;;
92 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
93for as_dir in $PATH
94do
95 IFS=$as_save_IFS
96 case $as_dir in #(((
97 '') as_dir=./ ;;
98 */) ;;
99 *) as_dir=$as_dir/ ;;
100 esac
101 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
102 done
103IFS=$as_save_IFS
104
105 ;;
106esac
107# We did not find ourselves, most probably we were run as 'sh COMMAND'
108# in which case we are not to be found in the path.
109if test "x$as_myself" = x; then
110 as_myself=$0
111fi
112if test ! -f "$as_myself"; then
113 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
114 exit 1
115fi
116
117
118# Use a proper internal environment variable to ensure we don't fall
119 # into an infinite loop, continuously re-executing ourselves.
120 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then
121 _as_can_reexec=no; export _as_can_reexec;
122 # We cannot yet assume a decent shell, so we have to provide a
123# neutralization value for shells without unset; and this also
124# works around shells that cannot unset nonexistent variables.
125# Preserve -v and -x to the replacement shell.
126BASH_ENV=/dev/null
127ENV=/dev/null
128(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
129case $- in # ((((
130 *v*x* | *x*v* ) as_opts=-vx ;;
131 *v* ) as_opts=-v ;;
132 *x* ) as_opts=-x ;;
133 * ) as_opts= ;;
134esac
135exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
136# Admittedly, this is quite paranoid, since all the known shells bail
137# out after a failed 'exec'.
138printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
139exit 255
140 fi
141 # We don't want this to propagate to other subprocesses.
142 { _as_can_reexec=; unset _as_can_reexec;}
143if test "x$CONFIG_SHELL" = x; then
144 as_bourne_compatible="if test \${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
145then :
146 emulate sh
147 NULLCMD=:
148 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
149 # is contrary to our usage. Disable this feature.
150 alias -g '\${1+\"\$@\"}'='\"\$@\"'
151 setopt NO_GLOB_SUBST
152else case e in #(
153 e) case \`(set -o) 2>/dev/null\` in #(
154 *posix*) :
155 set -o posix ;; #(
156 *) :
157 ;;
158esac ;;
159esac
160fi
161"
162 as_required="as_fn_return () { (exit \$1); }
163as_fn_success () { as_fn_return 0; }
164as_fn_failure () { as_fn_return 1; }
165as_fn_ret_success () { return 0; }
166as_fn_ret_failure () { return 1; }
167
168exitcode=0
169as_fn_success || { exitcode=1; echo as_fn_success failed.; }
170as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
171as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
172as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
173if ( set x; as_fn_ret_success y && test x = \"\$1\" )
174then :
175
176else case e in #(
177 e) exitcode=1; echo positional parameters were not saved. ;;
178esac
179fi
180test x\$exitcode = x0 || exit 1
181blah=\$(echo \$(echo blah))
182test x\"\$blah\" = xblah || exit 1
183test -x / || exit 1"
184 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
185 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
186 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
187 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
188test \$(( 1 + 1 )) = 2 || exit 1"
189 if (eval "$as_required") 2>/dev/null
190then :
191 as_have_required=yes
192else case e in #(
193 e) as_have_required=no ;;
194esac
195fi
196 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null
197then :
198
199else case e in #(
200 e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
201as_found=false
202for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
203do
204 IFS=$as_save_IFS
205 case $as_dir in #(((
206 '') as_dir=./ ;;
207 */) ;;
208 *) as_dir=$as_dir/ ;;
209 esac
210 as_found=:
211 case $as_dir in #(
212 /*)
213 for as_base in sh bash ksh sh5; do
214 # Try only shells that exist, to save several forks.
215 as_shell=$as_dir$as_base
216 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
217 as_run=a "$as_shell" -c "$as_bourne_compatible""$as_required" 2>/dev/null
218then :
219 CONFIG_SHELL=$as_shell as_have_required=yes
220 if as_run=a "$as_shell" -c "$as_bourne_compatible""$as_suggested" 2>/dev/null
221then :
222 break 2
223fi
224fi
225 done;;
226 esac
227 as_found=false
228done
229IFS=$as_save_IFS
230if $as_found
231then :
232
233else case e in #(
234 e) if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
235 as_run=a "$SHELL" -c "$as_bourne_compatible""$as_required" 2>/dev/null
236then :
237 CONFIG_SHELL=$SHELL as_have_required=yes
238fi ;;
239esac
240fi
241
242
243 if test "x$CONFIG_SHELL" != x
244then :
245 export CONFIG_SHELL
246 # We cannot yet assume a decent shell, so we have to provide a
247# neutralization value for shells without unset; and this also
248# works around shells that cannot unset nonexistent variables.
249# Preserve -v and -x to the replacement shell.
250BASH_ENV=/dev/null
251ENV=/dev/null
252(unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
253case $- in # ((((
254 *v*x* | *x*v* ) as_opts=-vx ;;
255 *v* ) as_opts=-v ;;
256 *x* ) as_opts=-x ;;
257 * ) as_opts= ;;
258esac
259exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"}
260# Admittedly, this is quite paranoid, since all the known shells bail
261# out after a failed 'exec'.
262printf "%s\n" "$0: could not re-execute with $CONFIG_SHELL" >&2
263exit 255
264fi
265
266 if test x$as_have_required = xno
267then :
268 printf "%s\n" "$0: This script requires a shell more modern than all"
269 printf "%s\n" "$0: the shells that I found on your system."
270 if test ${ZSH_VERSION+y} ; then
271 printf "%s\n" "$0: In particular, zsh $ZSH_VERSION has bugs and should"
272 printf "%s\n" "$0: be upgraded to zsh 4.3.4 or later."
273 else
274 printf "%s\n" "$0: Please tell bug-autoconf@gnu.org and bug-bash@gnu.org
275$0: about your system, including any error possibly output
276$0: before this message. Then install a modern shell, or
277$0: manually run the script under such a shell if you do
278$0: have one."
279 fi
280 exit 1
281fi ;;
282esac
283fi
284fi
285SHELL=${CONFIG_SHELL-/bin/sh}
286export SHELL
287# Unset more variables known to interfere with behavior of common tools.
288CLICOLOR_FORCE= GREP_OPTIONS=
289unset CLICOLOR_FORCE GREP_OPTIONS
290
291## --------------------- ##
292## M4sh Shell Functions. ##
293## --------------------- ##
294# as_fn_unset VAR
295# ---------------
296# Portably unset VAR.
297as_fn_unset ()
298{
299 { eval $1=; unset $1;}
300}
301as_unset=as_fn_unset
302
303
304# as_fn_set_status STATUS
305# -----------------------
306# Set $? to STATUS, without forking.
307as_fn_set_status ()
308{
309 return $1
310} # as_fn_set_status
311
312# as_fn_exit STATUS
313# -----------------
314# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
315as_fn_exit ()
316{
317 set +e
318 as_fn_set_status $1
319 exit $1
320} # as_fn_exit
321
322# as_fn_mkdir_p
323# -------------
324# Create "$as_dir" as a directory, including parents if necessary.
325as_fn_mkdir_p ()
326{
327
328 case $as_dir in #(
329 -*) as_dir=./$as_dir;;
330 esac
331 test -d "$as_dir" || eval $as_mkdir_p || {
332 as_dirs=
333 while :; do
334 case $as_dir in #(
335 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
336 *) as_qdir=$as_dir;;
337 esac
338 as_dirs="'$as_qdir' $as_dirs"
339 as_dir=`$as_dirname -- "$as_dir" ||
340$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
341 X"$as_dir" : 'X\(//\)[^/]' \| \
342 X"$as_dir" : 'X\(//\)$' \| \
343 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
344printf "%s\n" X"$as_dir" |
345 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
346 s//\1/
347 q
348 }
349 /^X\(\/\/\)[^/].*/{
350 s//\1/
351 q
352 }
353 /^X\(\/\/\)$/{
354 s//\1/
355 q
356 }
357 /^X\(\/\).*/{
358 s//\1/
359 q
360 }
361 s/.*/./; q'`
362 test -d "$as_dir" && break
363 done
364 test -z "$as_dirs" || eval "mkdir $as_dirs"
365 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
366
367
368} # as_fn_mkdir_p
369
370# as_fn_executable_p FILE
371# -----------------------
372# Test if FILE is an executable regular file.
373as_fn_executable_p ()
374{
375 test -f "$1" && test -x "$1"
376} # as_fn_executable_p
377# as_fn_append VAR VALUE
378# ----------------------
379# Append the text in VALUE to the end of the definition contained in VAR. Take
380# advantage of any shell optimizations that allow amortized linear growth over
381# repeated appends, instead of the typical quadratic growth present in naive
382# implementations.
383if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
384then :
385 eval 'as_fn_append ()
386 {
387 eval $1+=\$2
388 }'
389else case e in #(
390 e) as_fn_append ()
391 {
392 eval $1=\$$1\$2
393 } ;;
394esac
395fi # as_fn_append
396
397# as_fn_arith ARG...
398# ------------------
399# Perform arithmetic evaluation on the ARGs, and store the result in the
400# global $as_val. Take advantage of shells that can avoid forks. The arguments
401# must be portable across $(()) and expr.
402if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
403then :
404 eval 'as_fn_arith ()
405 {
406 as_val=$(( $* ))
407 }'
408else case e in #(
409 e) as_fn_arith ()
410 {
411 as_val=`expr "$@" || test $? -eq 1`
412 } ;;
413esac
414fi # as_fn_arith
415
416
417# as_fn_error STATUS ERROR [LINENO LOG_FD]
418# ----------------------------------------
419# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
420# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
421# script with STATUS, using 1 if that was 0.
422as_fn_error ()
423{
424 as_status=$1; test $as_status -eq 0 && as_status=1
425 if test "$4"; then
426 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
427 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
428 fi
429 printf "%s\n" "$as_me: error: $2" >&2
430 as_fn_exit $as_status
431} # as_fn_error
432
433if expr a : '\(a\)' >/dev/null 2>&1 &&
434 test "X`expr 00001 : '.*\(...\)'`" = X001; then
435 as_expr=expr
436else
437 as_expr=false
438fi
439
440if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
441 as_basename=basename
442else
443 as_basename=false
444fi
445
446if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
447 as_dirname=dirname
448else
449 as_dirname=false
450fi
451
452as_me=`$as_basename -- "$0" ||
453$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
454 X"$0" : 'X\(//\)$' \| \
455 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
456printf "%s\n" X/"$0" |
457 sed '/^.*\/\([^/][^/]*\)\/*$/{
458 s//\1/
459 q
460 }
461 /^X\/\(\/\/\)$/{
462 s//\1/
463 q
464 }
465 /^X\/\(\/\).*/{
466 s//\1/
467 q
468 }
469 s/.*/./; q'`
470
471# Avoid depending upon Character Ranges.
472as_cr_letters='abcdefghijklmnopqrstuvwxyz'
473as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
474as_cr_Letters=$as_cr_letters$as_cr_LETTERS
475as_cr_digits='0123456789'
476as_cr_alnum=$as_cr_Letters$as_cr_digits
477
478
479 as_lineno_1=$LINENO as_lineno_1a=$LINENO
480 as_lineno_2=$LINENO as_lineno_2a=$LINENO
481 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
482 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
483 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-)
484 sed -n '
485 p
486 /[$]LINENO/=
487 ' <$as_myself |
488 sed '
489 t clear
490 :clear
491 s/[$]LINENO.*/&-/
492 t lineno
493 b
494 :lineno
495 N
496 :loop
497 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
498 t loop
499 s/-\n.*//
500 ' >$as_me.lineno &&
501 chmod +x "$as_me.lineno" ||
502 { printf "%s\n" "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
503
504 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have
505 # already done that, so ensure we don't try to do so again and fall
506 # in an infinite loop. This has already happened in practice.
507 _as_can_reexec=no; export _as_can_reexec
508 # Don't try to exec as it changes $[0], causing all sort of problems
509 # (the dirname of $[0] is not the place where we might find the
510 # original and so on. Autoconf is especially sensitive to this).
511 . "./$as_me.lineno"
512 # Exit status is that of the last command.
513 exit
514}
515
516
517# Determine whether it's possible to make 'echo' print without a newline.
518# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
519# for compatibility with existing Makefiles.
520ECHO_C= ECHO_N= ECHO_T=
521case `echo -n x` in #(((((
522-n*)
523 case `echo 'xy\c'` in
524 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
525 xy) ECHO_C='\c';;
526 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
527 ECHO_T=' ';;
528 esac;;
529*)
530 ECHO_N='-n';;
531esac
532
533# For backward compatibility with old third-party macros, we provide
534# the shell variables $as_echo and $as_echo_n. New code should use
535# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
536as_echo='printf %s\n'
537as_echo_n='printf %s'
538
539rm -f conf$$ conf$$.exe conf$$.file
540if test -d conf$$.dir; then
541 rm -f conf$$.dir/conf$$.file
542else
543 rm -f conf$$.dir
544 mkdir conf$$.dir 2>/dev/null
545fi
546if (echo >conf$$.file) 2>/dev/null; then
547 if ln -s conf$$.file conf$$ 2>/dev/null; then
548 as_ln_s='ln -s'
549 # ... but there are two gotchas:
550 # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail.
551 # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable.
552 # In both cases, we have to default to 'cp -pR'.
553 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
554 as_ln_s='cp -pR'
555 elif ln conf$$.file conf$$ 2>/dev/null; then
556 as_ln_s=ln
557 else
558 as_ln_s='cp -pR'
559 fi
560else
561 as_ln_s='cp -pR'
562fi
563rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
564rmdir conf$$.dir 2>/dev/null
565
566if mkdir -p . 2>/dev/null; then
567 as_mkdir_p='mkdir -p "$as_dir"'
568else
569 test -d ./-p && rmdir ./-p
570 as_mkdir_p=false
571fi
572
573as_test_x='test -x'
574as_executable_p=as_fn_executable_p
575
576# Sed expression to map a string onto a valid CPP name.
577as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
578as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated
579
580# Sed expression to map a string onto a valid variable name.
581as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
582as_tr_sh="eval sed '$as_sed_sh'" # deprecated
583
584
585test -n "$DJDIR" || exec 7<&0 </dev/null
586exec 6>&1
587
588# Name of the host.
589# hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
590# so uname gets run too.
591ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
592
593#
594# Initializations.
595#
596ac_default_prefix=/usr/local
597ac_clean_files=
598ac_config_libobj_dir=.
599LIBOBJS=
600cross_compiling=no
601subdirs=
602MFLAGS=
603MAKEFLAGS=
604
605# Identity of this package.
606PACKAGE_NAME='bash'
607PACKAGE_TARNAME='bash'
608PACKAGE_VERSION='5.3-release'
609PACKAGE_STRING='bash 5.3-release'
610PACKAGE_BUGREPORT='bug-bash@gnu.org'
611PACKAGE_URL=''
612
613ac_unique_file="shell.h"
614# Factoring default headers for most tests.
615ac_includes_default="\
616#include <stddef.h>
617#ifdef HAVE_STDIO_H
618# include <stdio.h>
619#endif
620#ifdef HAVE_STDLIB_H
621# include <stdlib.h>
622#endif
623#ifdef HAVE_STRING_H
624# include <string.h>
625#endif
626#ifdef HAVE_INTTYPES_H
627# include <inttypes.h>
628#endif
629#ifdef HAVE_STDINT_H
630# include <stdint.h>
631#endif
632#ifdef HAVE_STRINGS_H
633# include <strings.h>
634#endif
635#ifdef HAVE_SYS_TYPES_H
636# include <sys/types.h>
637#endif
638#ifdef HAVE_SYS_STAT_H
639# include <sys/stat.h>
640#endif
641#ifdef HAVE_UNISTD_H
642# include <unistd.h>
643#endif"
644
645ac_header_c_list=
646gt_needs=
647ac_func_c_list=
648gl_use_threads_default=
649gl_use_winpthreads_default=
650enable_year2038=no
651ac_subst_vars='LTLIBOBJS
652STDCKDINT_H
653LOCAL_DEFS
654LOCAL_LDFLAGS
655LOCAL_CFLAGS
656LOCAL_LIBS
657MALLOC_DEBUG
658DEBUG
659RELSTATUS
660BASHVERS
661headersdir
662loadablesdir
663BUILD_DIR
664incdir
665PROFILE_FLAGS
666SHOBJ_STATUS
667SHOBJ_LIBS
668SHOBJ_XLDFLAGS
669SHOBJ_LDFLAGS
670SHOBJ_LD
671SHOBJ_CFLAGS
672SHOBJ_CC
673JOBS_O
674TERMCAP_DEP
675TERMCAP_LIB
676SIGLIST_O
677PTHREAD_H_DEFINES_STRUCT_TIMESPEC
678SYS_TIME_H_DEFINES_STRUCT_TIMESPEC
679TIME_H_DEFINES_STRUCT_TIMESPEC
680LIBINTL_H
681INTL_INC
682INTL_DEP
683LIBOBJS
684POSUB
685LTLIBINTL
686LIBINTL
687INTLLIBS
688CATOBJEXT
689USE_INCLUDED_LIBINTL
690BUILD_INCLUDED_LIBINTL
691WINDRES
692WOE32
693WOE32DLL
694ENHANCE_LOCALE_FUNCS
695HAVE_WPRINTF
696HAVE_SNPRINTF
697HAVE_ASPRINTF
698HAVE_POSIX_PRINTF
699INTL_DEFAULT_VERBOSITY
700ARFLAGS
701INTL_MACOSX_LIBS
702LOCALENAME_ENHANCE_LOCALE_FUNCS
703REPLACE_STRUCT_LCONV
704REPLACE_FREELOCALE
705REPLACE_DUPLOCALE
706REPLACE_NEWLOCALE
707REPLACE_SETLOCALE
708REPLACE_LOCALECONV
709HAVE_FREELOCALE
710HAVE_DUPLOCALE
711HAVE_NEWLOCALE
712GNULIBHEADERS_OVERRIDE_WINT_T
713INTLBISON
714LTLIBICONV
715LIBICONV
716LTLIBMULTITHREAD
717LIBMULTITHREAD
718LTLIBTHREAD
719LIBTHREAD
720LIBSTDTHREAD
721LIB_SCHED_YIELD
722LIBPMULTITHREAD
723LIBPTHREAD
724ALLOCA
725HAVE_VISIBILITY
726CFLAG_VISIBILITY
727GLIBC2
728CPP
729XGETTEXT_EXTRA_OPTIONS
730MSGMERGE_FOR_MSGFMT_OPTION
731MSGMERGE
732XGETTEXT_015
733XGETTEXT
734GMSGFMT_015
735GMSGFMT
736MSGFMT
737GETTEXT_MACRO_VERSION
738USE_NLS
739SED
740MKDIR_P
741SIZE
742MAKE_SHELL
743INSTALL_STRIP_PROGRAM
744STRIP
745install_sh
746SET_MAKE
747YFLAGS
748YACC
749RANLIB
750AR
751INSTALL_DATA
752INSTALL_SCRIPT
753INSTALL_PROGRAM
754TILDE_LIB
755HIST_INCLUDEDIR
756HIST_LIBDIR
757HISTORY_DEP
758HISTORY_LIB
759RL_INCLUDE
760RL_INCLUDEDIR
761RL_LIBDIR
762READLINE_DEP
763READLINE_LIB
764RL_MINOR
765RL_MAJOR
766RL_VERSION
767LIBS_FOR_BUILD
768STYLE_CFLAGS
769STATIC_LD
770SIGNAMES_O
771SIGNAMES_H
772CROSS_COMPILE
773OBJEXT
774EXEEXT
775ac_ct_CC
776CPPFLAGS
777LDFLAGS
778CFLAGS
779CC
780HELPSTRINGS
781HELPFILES_TARGET
782HELPINSTALL
783HELPDIRDEFINE
784HELPDIR
785ARRAY_O
786MALLOC_DEP
787MALLOC_LDFLAGS
788MALLOC_LIBRARY
789MALLOC_LIB
790MALLOC_SRC
791MALLOC_TARGET
792TESTSCRIPT
793CPPFLAGS_FOR_BUILD
794LDFLAGS_FOR_BUILD
795CFLAGS_FOR_BUILD
796CC_FOR_BUILD
797DEBUGGER_START_FILE
798host_os
799host_vendor
800host_cpu
801host
802build_os
803build_vendor
804build_cpu
805build
806target_alias
807host_alias
808build_alias
809LIBS
810ECHO_T
811ECHO_N
812ECHO_C
813DEFS
814mandir
815localedir
816libdir
817psdir
818pdfdir
819dvidir
820htmldir
821infodir
822docdir
823oldincludedir
824includedir
825runstatedir
826localstatedir
827sharedstatedir
828sysconfdir
829datadir
830datarootdir
831libexecdir
832sbindir
833bindir
834program_transform_name
835prefix
836exec_prefix
837PACKAGE_URL
838PACKAGE_BUGREPORT
839PACKAGE_STRING
840PACKAGE_VERSION
841PACKAGE_TARNAME
842PACKAGE_NAME
843PATH_SEPARATOR
844SHELL'
845ac_subst_files=''
846ac_user_opts='
847enable_option_checking
848with_afs
849with_bash_malloc
850with_curses
851with_gnu_malloc
852with_installed_readline
853enable_minimal_config
854enable_alias
855enable_alt_array_implementation
856enable_arith_for_command
857enable_array_variables
858enable_bang_history
859enable_bash_source_fullpath_default
860enable_brace_expansion
861enable_casemod_attributes
862enable_casemod_expansions
863enable_command_timing
864enable_cond_command
865enable_cond_regexp
866enable_coprocesses
867enable_debugger
868enable_dev_fd_stat_broken
869enable_direxpand_default
870enable_directory_stack
871enable_disabled_builtins
872enable_dparen_arithmetic
873enable_extended_glob
874enable_extended_glob_default
875enable_function_import
876enable_glob_asciiranges_default
877enable_help_builtin
878enable_history
879enable_job_control
880enable_multibyte
881enable_net_redirections
882enable_process_substitution
883enable_progcomp
884enable_prompt_string_decoding
885enable_readline
886enable_restricted
887enable_select
888enable_separate_helpfiles
889enable_single_help_strings
890enable_strict_posix_default
891enable_translatable_strings
892enable_usg_echo_default
893enable_xpg_echo_default
894enable_mem_scramble
895enable_profiling
896enable_static_link
897enable_largefile
898enable_nls
899enable_threads
900with_gnu_ld
901enable_rpath
902with_libiconv_prefix
903with_included_gettext
904with_libintl_prefix
905enable_year2038
906'
907 ac_precious_vars='build_alias
908host_alias
909target_alias
910DEBUGGER_START_FILE
911CC_FOR_BUILD
912CFLAGS_FOR_BUILD
913LDFLAGS_FOR_BUILD
914CPPFLAGS_FOR_BUILD
915CC
916CFLAGS
917LDFLAGS
918LIBS
919CPPFLAGS
920YACC
921YFLAGS
922CPP'
923
924
925# Initialize some variables set by options.
926ac_init_help=
927ac_init_version=false
928ac_unrecognized_opts=
929ac_unrecognized_sep=
930# The variables have the same names as the options, with
931# dashes changed to underlines.
932cache_file=/dev/null
933exec_prefix=NONE
934no_create=
935no_recursion=
936prefix=NONE
937program_prefix=NONE
938program_suffix=NONE
939program_transform_name=s,x,x,
940silent=
941site=
942srcdir=
943verbose=
944x_includes=NONE
945x_libraries=NONE
946
947# Installation directory options.
948# These are left unexpanded so users can "make install exec_prefix=/foo"
949# and all the variables that are supposed to be based on exec_prefix
950# by default will actually change.
951# Use braces instead of parens because sh, perl, etc. also accept them.
952# (The list follows the same order as the GNU Coding Standards.)
953bindir='${exec_prefix}/bin'
954sbindir='${exec_prefix}/sbin'
955libexecdir='${exec_prefix}/libexec'
956datarootdir='${prefix}/share'
957datadir='${datarootdir}'
958sysconfdir='${prefix}/etc'
959sharedstatedir='${prefix}/com'
960localstatedir='${prefix}/var'
961runstatedir='${localstatedir}/run'
962includedir='${prefix}/include'
963oldincludedir='/usr/include'
964docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
965infodir='${datarootdir}/info'
966htmldir='${docdir}'
967dvidir='${docdir}'
968pdfdir='${docdir}'
969psdir='${docdir}'
970libdir='${exec_prefix}/lib'
971localedir='${datarootdir}/locale'
972mandir='${datarootdir}/man'
973
974ac_prev=
975ac_dashdash=
976for ac_option
977do
978 # If the previous option needs an argument, assign it.
979 if test -n "$ac_prev"; then
980 eval $ac_prev=\$ac_option
981 ac_prev=
982 continue
983 fi
984
985 case $ac_option in
986 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
987 *=) ac_optarg= ;;
988 *) ac_optarg=yes ;;
989 esac
990
991 case $ac_dashdash$ac_option in
992 --)
993 ac_dashdash=yes ;;
994
995 -bindir | --bindir | --bindi | --bind | --bin | --bi)
996 ac_prev=bindir ;;
997 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
998 bindir=$ac_optarg ;;
999
1000 -build | --build | --buil | --bui | --bu)
1001 ac_prev=build_alias ;;
1002 -build=* | --build=* | --buil=* | --bui=* | --bu=*)
1003 build_alias=$ac_optarg ;;
1004
1005 -cache-file | --cache-file | --cache-fil | --cache-fi \
1006 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
1007 ac_prev=cache_file ;;
1008 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
1009 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
1010 cache_file=$ac_optarg ;;
1011
1012 --config-cache | -C)
1013 cache_file=config.cache ;;
1014
1015 -datadir | --datadir | --datadi | --datad)
1016 ac_prev=datadir ;;
1017 -datadir=* | --datadir=* | --datadi=* | --datad=*)
1018 datadir=$ac_optarg ;;
1019
1020 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
1021 | --dataroo | --dataro | --datar)
1022 ac_prev=datarootdir ;;
1023 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
1024 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
1025 datarootdir=$ac_optarg ;;
1026
1027 -disable-* | --disable-*)
1028 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
1029 # Reject names that are not valid shell variable names.
1030 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1031 as_fn_error $? "invalid feature name: '$ac_useropt'"
1032 ac_useropt_orig=$ac_useropt
1033 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1034 case $ac_user_opts in
1035 *"
1036"enable_$ac_useropt"
1037"*) ;;
1038 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
1039 ac_unrecognized_sep=', ';;
1040 esac
1041 eval enable_$ac_useropt=no ;;
1042
1043 -docdir | --docdir | --docdi | --doc | --do)
1044 ac_prev=docdir ;;
1045 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
1046 docdir=$ac_optarg ;;
1047
1048 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
1049 ac_prev=dvidir ;;
1050 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
1051 dvidir=$ac_optarg ;;
1052
1053 -enable-* | --enable-*)
1054 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
1055 # Reject names that are not valid shell variable names.
1056 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1057 as_fn_error $? "invalid feature name: '$ac_useropt'"
1058 ac_useropt_orig=$ac_useropt
1059 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1060 case $ac_user_opts in
1061 *"
1062"enable_$ac_useropt"
1063"*) ;;
1064 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1065 ac_unrecognized_sep=', ';;
1066 esac
1067 eval enable_$ac_useropt=\$ac_optarg ;;
1068
1069 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1070 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1071 | --exec | --exe | --ex)
1072 ac_prev=exec_prefix ;;
1073 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1074 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1075 | --exec=* | --exe=* | --ex=*)
1076 exec_prefix=$ac_optarg ;;
1077
1078 -gas | --gas | --ga | --g)
1079 # Obsolete; use --with-gas.
1080 with_gas=yes ;;
1081
1082 -help | --help | --hel | --he | -h)
1083 ac_init_help=long ;;
1084 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1085 ac_init_help=recursive ;;
1086 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1087 ac_init_help=short ;;
1088
1089 -host | --host | --hos | --ho)
1090 ac_prev=host_alias ;;
1091 -host=* | --host=* | --hos=* | --ho=*)
1092 host_alias=$ac_optarg ;;
1093
1094 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1095 ac_prev=htmldir ;;
1096 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1097 | --ht=*)
1098 htmldir=$ac_optarg ;;
1099
1100 -includedir | --includedir | --includedi | --included | --include \
1101 | --includ | --inclu | --incl | --inc)
1102 ac_prev=includedir ;;
1103 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1104 | --includ=* | --inclu=* | --incl=* | --inc=*)
1105 includedir=$ac_optarg ;;
1106
1107 -infodir | --infodir | --infodi | --infod | --info | --inf)
1108 ac_prev=infodir ;;
1109 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1110 infodir=$ac_optarg ;;
1111
1112 -libdir | --libdir | --libdi | --libd)
1113 ac_prev=libdir ;;
1114 -libdir=* | --libdir=* | --libdi=* | --libd=*)
1115 libdir=$ac_optarg ;;
1116
1117 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1118 | --libexe | --libex | --libe)
1119 ac_prev=libexecdir ;;
1120 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1121 | --libexe=* | --libex=* | --libe=*)
1122 libexecdir=$ac_optarg ;;
1123
1124 -localedir | --localedir | --localedi | --localed | --locale)
1125 ac_prev=localedir ;;
1126 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1127 localedir=$ac_optarg ;;
1128
1129 -localstatedir | --localstatedir | --localstatedi | --localstated \
1130 | --localstate | --localstat | --localsta | --localst | --locals)
1131 ac_prev=localstatedir ;;
1132 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1133 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1134 localstatedir=$ac_optarg ;;
1135
1136 -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1137 ac_prev=mandir ;;
1138 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1139 mandir=$ac_optarg ;;
1140
1141 -nfp | --nfp | --nf)
1142 # Obsolete; use --without-fp.
1143 with_fp=no ;;
1144
1145 -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1146 | --no-cr | --no-c | -n)
1147 no_create=yes ;;
1148
1149 -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1150 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1151 no_recursion=yes ;;
1152
1153 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1154 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1155 | --oldin | --oldi | --old | --ol | --o)
1156 ac_prev=oldincludedir ;;
1157 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1158 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1159 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1160 oldincludedir=$ac_optarg ;;
1161
1162 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1163 ac_prev=prefix ;;
1164 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1165 prefix=$ac_optarg ;;
1166
1167 -program-prefix | --program-prefix | --program-prefi | --program-pref \
1168 | --program-pre | --program-pr | --program-p)
1169 ac_prev=program_prefix ;;
1170 -program-prefix=* | --program-prefix=* | --program-prefi=* \
1171 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1172 program_prefix=$ac_optarg ;;
1173
1174 -program-suffix | --program-suffix | --program-suffi | --program-suff \
1175 | --program-suf | --program-su | --program-s)
1176 ac_prev=program_suffix ;;
1177 -program-suffix=* | --program-suffix=* | --program-suffi=* \
1178 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1179 program_suffix=$ac_optarg ;;
1180
1181 -program-transform-name | --program-transform-name \
1182 | --program-transform-nam | --program-transform-na \
1183 | --program-transform-n | --program-transform- \
1184 | --program-transform | --program-transfor \
1185 | --program-transfo | --program-transf \
1186 | --program-trans | --program-tran \
1187 | --progr-tra | --program-tr | --program-t)
1188 ac_prev=program_transform_name ;;
1189 -program-transform-name=* | --program-transform-name=* \
1190 | --program-transform-nam=* | --program-transform-na=* \
1191 | --program-transform-n=* | --program-transform-=* \
1192 | --program-transform=* | --program-transfor=* \
1193 | --program-transfo=* | --program-transf=* \
1194 | --program-trans=* | --program-tran=* \
1195 | --progr-tra=* | --program-tr=* | --program-t=*)
1196 program_transform_name=$ac_optarg ;;
1197
1198 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1199 ac_prev=pdfdir ;;
1200 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1201 pdfdir=$ac_optarg ;;
1202
1203 -psdir | --psdir | --psdi | --psd | --ps)
1204 ac_prev=psdir ;;
1205 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1206 psdir=$ac_optarg ;;
1207
1208 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1209 | -silent | --silent | --silen | --sile | --sil)
1210 silent=yes ;;
1211
1212 -runstatedir | --runstatedir | --runstatedi | --runstated \
1213 | --runstate | --runstat | --runsta | --runst | --runs \
1214 | --run | --ru | --r)
1215 ac_prev=runstatedir ;;
1216 -runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
1217 | --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
1218 | --run=* | --ru=* | --r=*)
1219 runstatedir=$ac_optarg ;;
1220
1221 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1222 ac_prev=sbindir ;;
1223 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1224 | --sbi=* | --sb=*)
1225 sbindir=$ac_optarg ;;
1226
1227 -sharedstatedir | --sharedstatedir | --sharedstatedi \
1228 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1229 | --sharedst | --shareds | --shared | --share | --shar \
1230 | --sha | --sh)
1231 ac_prev=sharedstatedir ;;
1232 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1233 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1234 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1235 | --sha=* | --sh=*)
1236 sharedstatedir=$ac_optarg ;;
1237
1238 -site | --site | --sit)
1239 ac_prev=site ;;
1240 -site=* | --site=* | --sit=*)
1241 site=$ac_optarg ;;
1242
1243 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1244 ac_prev=srcdir ;;
1245 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1246 srcdir=$ac_optarg ;;
1247
1248 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1249 | --syscon | --sysco | --sysc | --sys | --sy)
1250 ac_prev=sysconfdir ;;
1251 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1252 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1253 sysconfdir=$ac_optarg ;;
1254
1255 -target | --target | --targe | --targ | --tar | --ta | --t)
1256 ac_prev=target_alias ;;
1257 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1258 target_alias=$ac_optarg ;;
1259
1260 -v | -verbose | --verbose | --verbos | --verbo | --verb)
1261 verbose=yes ;;
1262
1263 -version | --version | --versio | --versi | --vers | -V)
1264 ac_init_version=: ;;
1265
1266 -with-* | --with-*)
1267 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1268 # Reject names that are not valid shell variable names.
1269 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1270 as_fn_error $? "invalid package name: '$ac_useropt'"
1271 ac_useropt_orig=$ac_useropt
1272 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1273 case $ac_user_opts in
1274 *"
1275"with_$ac_useropt"
1276"*) ;;
1277 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1278 ac_unrecognized_sep=', ';;
1279 esac
1280 eval with_$ac_useropt=\$ac_optarg ;;
1281
1282 -without-* | --without-*)
1283 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1284 # Reject names that are not valid shell variable names.
1285 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1286 as_fn_error $? "invalid package name: '$ac_useropt'"
1287 ac_useropt_orig=$ac_useropt
1288 ac_useropt=`printf "%s\n" "$ac_useropt" | sed 's/[-+.]/_/g'`
1289 case $ac_user_opts in
1290 *"
1291"with_$ac_useropt"
1292"*) ;;
1293 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1294 ac_unrecognized_sep=', ';;
1295 esac
1296 eval with_$ac_useropt=no ;;
1297
1298 --x)
1299 # Obsolete; use --with-x.
1300 with_x=yes ;;
1301
1302 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1303 | --x-incl | --x-inc | --x-in | --x-i)
1304 ac_prev=x_includes ;;
1305 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1306 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1307 x_includes=$ac_optarg ;;
1308
1309 -x-libraries | --x-libraries | --x-librarie | --x-librari \
1310 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1311 ac_prev=x_libraries ;;
1312 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1313 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1314 x_libraries=$ac_optarg ;;
1315
1316 -*) as_fn_error $? "unrecognized option: '$ac_option'
1317Try '$0 --help' for more information"
1318 ;;
1319
1320 *=*)
1321 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1322 # Reject names that are not valid shell variable names.
1323 case $ac_envvar in #(
1324 '' | [0-9]* | *[!_$as_cr_alnum]* )
1325 as_fn_error $? "invalid variable name: '$ac_envvar'" ;;
1326 esac
1327 eval $ac_envvar=\$ac_optarg
1328 export $ac_envvar ;;
1329
1330 *)
1331 # FIXME: should be removed in autoconf 3.0.
1332 printf "%s\n" "$as_me: WARNING: you should use --build, --host, --target" >&2
1333 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1334 printf "%s\n" "$as_me: WARNING: invalid host type: $ac_option" >&2
1335 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}"
1336 ;;
1337
1338 esac
1339done
1340
1341if test -n "$ac_prev"; then
1342 ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1343 as_fn_error $? "missing argument to $ac_option"
1344fi
1345
1346if test -n "$ac_unrecognized_opts"; then
1347 case $enable_option_checking in
1348 no) ;;
1349 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1350 *) printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1351 esac
1352fi
1353
1354# Check all directory arguments for consistency.
1355for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
1356 datadir sysconfdir sharedstatedir localstatedir includedir \
1357 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1358 libdir localedir mandir runstatedir
1359do
1360 eval ac_val=\$$ac_var
1361 # Remove trailing slashes.
1362 case $ac_val in
1363 */ )
1364 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1365 eval $ac_var=\$ac_val;;
1366 esac
1367 # Be sure to have absolute directory names.
1368 case $ac_val in
1369 [\\/$]* | ?:[\\/]* ) continue;;
1370 NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1371 esac
1372 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1373done
1374
1375# There might be people who depend on the old broken behavior: '$host'
1376# used to hold the argument of --host etc.
1377# FIXME: To remove some day.
1378build=$build_alias
1379host=$host_alias
1380target=$target_alias
1381
1382# FIXME: To remove some day.
1383if test "x$host_alias" != x; then
1384 if test "x$build_alias" = x; then
1385 cross_compiling=maybe
1386 elif test "x$build_alias" != "x$host_alias"; then
1387 cross_compiling=yes
1388 fi
1389fi
1390
1391ac_tool_prefix=
1392test -n "$host_alias" && ac_tool_prefix=$host_alias-
1393
1394test "$silent" = yes && exec 6>/dev/null
1395
1396
1397ac_pwd=`pwd` && test -n "$ac_pwd" &&
1398ac_ls_di=`ls -di .` &&
1399ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1400 as_fn_error $? "working directory cannot be determined"
1401test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1402 as_fn_error $? "pwd does not report name of working directory"
1403
1404
1405# Find the source files, if location was not specified.
1406if test -z "$srcdir"; then
1407 ac_srcdir_defaulted=yes
1408 # Try the directory containing this script, then the parent directory.
1409 ac_confdir=`$as_dirname -- "$as_myself" ||
1410$as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1411 X"$as_myself" : 'X\(//\)[^/]' \| \
1412 X"$as_myself" : 'X\(//\)$' \| \
1413 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1414printf "%s\n" X"$as_myself" |
1415 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1416 s//\1/
1417 q
1418 }
1419 /^X\(\/\/\)[^/].*/{
1420 s//\1/
1421 q
1422 }
1423 /^X\(\/\/\)$/{
1424 s//\1/
1425 q
1426 }
1427 /^X\(\/\).*/{
1428 s//\1/
1429 q
1430 }
1431 s/.*/./; q'`
1432 srcdir=$ac_confdir
1433 if test ! -r "$srcdir/$ac_unique_file"; then
1434 srcdir=..
1435 fi
1436else
1437 ac_srcdir_defaulted=no
1438fi
1439if test ! -r "$srcdir/$ac_unique_file"; then
1440 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1441 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1442fi
1443ac_msg="sources are in $srcdir, but 'cd $srcdir' does not work"
1444ac_abs_confdir=`(
1445 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1446 pwd)`
1447# When building in place, set srcdir=.
1448if test "$ac_abs_confdir" = "$ac_pwd"; then
1449 srcdir=.
1450fi
1451# Remove unnecessary trailing slashes from srcdir.
1452# Double slashes in file names in object file debugging info
1453# mess up M-x gdb in Emacs.
1454case $srcdir in
1455*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1456esac
1457for ac_var in $ac_precious_vars; do
1458 eval ac_env_${ac_var}_set=\${${ac_var}+set}
1459 eval ac_env_${ac_var}_value=\$${ac_var}
1460 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1461 eval ac_cv_env_${ac_var}_value=\$${ac_var}
1462done
1463
1464#
1465# Report the --help message.
1466#
1467if test "$ac_init_help" = "long"; then
1468 # Omit some internal or obsolete options to make the list less imposing.
1469 # This message is too long to be a string in the A/UX 3.1 sh.
1470 cat <<_ACEOF
1471'configure' configures bash 5.3-release to adapt to many kinds of systems.
1472
1473Usage: $0 [OPTION]... [VAR=VALUE]...
1474
1475To assign environment variables (e.g., CC, CFLAGS...), specify them as
1476VAR=VALUE. See below for descriptions of some of the useful variables.
1477
1478Defaults for the options are specified in brackets.
1479
1480Configuration:
1481 -h, --help display this help and exit
1482 --help=short display options specific to this package
1483 --help=recursive display the short help of all the included packages
1484 -V, --version display version information and exit
1485 -q, --quiet, --silent do not print 'checking ...' messages
1486 --cache-file=FILE cache test results in FILE [disabled]
1487 -C, --config-cache alias for '--cache-file=config.cache'
1488 -n, --no-create do not create output files
1489 --srcdir=DIR find the sources in DIR [configure dir or '..']
1490
1491Installation directories:
1492 --prefix=PREFIX install architecture-independent files in PREFIX
1493 [$ac_default_prefix]
1494 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
1495 [PREFIX]
1496
1497By default, 'make install' will install all the files in
1498'$ac_default_prefix/bin', '$ac_default_prefix/lib' etc. You can specify
1499an installation prefix other than '$ac_default_prefix' using '--prefix',
1500for instance '--prefix=\$HOME'.
1501
1502For better control, use the options below.
1503
1504Fine tuning of the installation directories:
1505 --bindir=DIR user executables [EPREFIX/bin]
1506 --sbindir=DIR system admin executables [EPREFIX/sbin]
1507 --libexecdir=DIR program executables [EPREFIX/libexec]
1508 --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
1509 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
1510 --localstatedir=DIR modifiable single-machine data [PREFIX/var]
1511 --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
1512 --libdir=DIR object code libraries [EPREFIX/lib]
1513 --includedir=DIR C header files [PREFIX/include]
1514 --oldincludedir=DIR C header files for non-gcc [/usr/include]
1515 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
1516 --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
1517 --infodir=DIR info documentation [DATAROOTDIR/info]
1518 --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
1519 --mandir=DIR man documentation [DATAROOTDIR/man]
1520 --docdir=DIR documentation root [DATAROOTDIR/doc/bash]
1521 --htmldir=DIR html documentation [DOCDIR]
1522 --dvidir=DIR dvi documentation [DOCDIR]
1523 --pdfdir=DIR pdf documentation [DOCDIR]
1524 --psdir=DIR ps documentation [DOCDIR]
1525_ACEOF
1526
1527 cat <<\_ACEOF
1528
1529System types:
1530 --build=BUILD configure for building on BUILD [guessed]
1531 --host=HOST cross-compile to build programs to run on HOST [BUILD]
1532_ACEOF
1533fi
1534
1535if test -n "$ac_init_help"; then
1536 case $ac_init_help in
1537 short | recursive ) echo "Configuration of bash 5.3-release:";;
1538 esac
1539 cat <<\_ACEOF
1540
1541Optional Features:
1542 --disable-option-checking ignore unrecognized --enable/--with options
1543 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
1544 --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
1545 --enable-minimal-config a minimal sh-like configuration
1546 --enable-alias enable shell aliases
1547 --enable-alt-array-implementation
1548 enable an alternate array implementation that
1549 optimizes speed at the cost of space
1550 --enable-arith-for-command
1551 enable arithmetic for command
1552 --enable-array-variables
1553 include shell array variables
1554 --enable-bang-history turn on csh-style history substitution
1555 --enable-bash-source-fullpath-default
1556 enable the bash_source_fullpath option by default
1557 --enable-brace-expansion
1558 include brace expansion
1559 --enable-casemod-attributes
1560 include case-modifying variable attributes
1561 --enable-casemod-expansions
1562 include case-modifying word expansions
1563 --enable-command-timing enable the time reserved word and command timing
1564 --enable-cond-command enable the conditional command
1565 --enable-cond-regexp enable extended regular expression matching in
1566 conditional commands
1567 --enable-coprocesses enable coprocess support and the coproc reserved
1568 word
1569 --enable-debugger enable support for bash debugger
1570 --enable-dev-fd-stat-broken
1571 enable this option if stat on /dev/fd/N and fstat on
1572 file descriptor N don't return the same results
1573 --enable-direxpand-default
1574 enable the direxpand shell option by default
1575 --enable-directory-stack
1576 enable builtins pushd/popd/dirs
1577 --enable-disabled-builtins
1578 allow disabled builtins to still be invoked
1579 --enable-dparen-arithmetic
1580 include ((...)) command
1581 --enable-extended-glob include ksh-style extended pattern matching
1582 --enable-extended-glob-default
1583 force extended pattern matching to be enabled by
1584 default
1585 --enable-function-import
1586 allow bash to import exported function definitions
1587 by default
1588 --enable-glob-asciiranges-default
1589 force bracket range expressions in pattern matching
1590 to use the C locale by default
1591 --enable-help-builtin include the help builtin
1592 --enable-history turn on command history
1593 --enable-job-control enable job control features
1594 --enable-multibyte enable multibyte characters if OS supports them
1595 --enable-net-redirections
1596 enable /dev/tcp/host/port redirection
1597 --enable-process-substitution
1598 enable process substitution
1599 --enable-progcomp enable programmable completion and the complete
1600 builtin
1601 --enable-prompt-string-decoding
1602 turn on escape character decoding in prompts
1603 --enable-readline turn on command line editing
1604 --enable-restricted enable a restricted shell
1605 --enable-select include select command
1606 --enable-separate-helpfiles
1607 use external files for help builtin documentation
1608 --enable-single-help-strings
1609 store help documentation as a single string to ease
1610 translation
1611 --enable-strict-posix-default
1612 configure bash to be posix-conformant by default
1613 --enable-translatable-strings
1614 include support for $"..." translatable strings
1615 --enable-usg-echo-default
1616 a synonym for --enable-xpg-echo-default
1617 --enable-xpg-echo-default
1618 make the echo builtin expand escape sequences by
1619 default
1620 --enable-mem-scramble scramble memory on calls to malloc and free
1621 --enable-profiling allow profiling with gprof
1622 --enable-static-link link bash statically, for use as a root shell
1623 --disable-largefile omit support for large files
1624 --disable-nls do not use Native Language Support
1625 --enable-threads={isoc|posix|isoc+posix|windows}
1626 specify multithreading API
1627 --disable-threads build without multithread safety
1628 --disable-rpath do not hardcode runtime library paths
1629 --enable-year2038 support timestamps after 2038
1630
1631Optional Packages:
1632 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
1633 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
1634 --with-afs if you are running AFS
1635 --with-bash-malloc use the Bash version of malloc
1636 --with-curses use the curses library instead of the termcap
1637 library
1638 --with-gnu-malloc synonym for --with-bash-malloc
1639 --with-installed-readline
1640 use a version of the readline library that is
1641 already installed
1642 --with-gnu-ld assume the C compiler uses GNU ld [default=no]
1643 --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib
1644 --without-libiconv-prefix don't search for libiconv in includedir and libdir
1645 --with-included-gettext use the GNU gettext library included here
1646 --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib
1647 --without-libintl-prefix don't search for libintl in includedir and libdir
1648
1649Some influential environment variables:
1650 DEBUGGER_START_FILE
1651 location of bash debugger initialization file
1652 CC_FOR_BUILD
1653 C compiler used when compiling binaries used only at build time
1654 CFLAGS_FOR_BUILD
1655 Compilation options (CFLAGS) used when compiling binaries used
1656 only at build time
1657 LDFLAGS_FOR_BUILD
1658 Linker options (LDFLAGS) used when compiling binaries used only
1659 at build time
1660 CPPFLAGS_FOR_BUILD
1661 C preprocessor options (CPPFLAGS) used when compiling binaries
1662 used only at build time
1663 CC C compiler command
1664 CFLAGS C compiler flags
1665 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a
1666 nonstandard directory <lib dir>
1667 LIBS libraries to pass to the linker, e.g. -l<library>
1668 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1669 you have headers in a nonstandard directory <include dir>
1670 YACC The 'Yet Another Compiler Compiler' implementation to use.
1671 Defaults to the first program found out of: 'bison -y', 'byacc',
1672 'yacc'.
1673 YFLAGS The list of arguments that will be passed by default to $YACC.
1674 This script will default YFLAGS to the empty string to avoid a
1675 default value of '-d' given by some make applications.
1676 CPP C preprocessor
1677
1678Use these variables to override the choices made by 'configure' or to help
1679it to find libraries and programs with nonstandard names/locations.
1680
1681Report bugs to <bug-bash@gnu.org>.
1682_ACEOF
1683ac_status=$?
1684fi
1685
1686if test "$ac_init_help" = "recursive"; then
1687 # If there are subdirs, report their specific --help.
1688 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1689 test -d "$ac_dir" ||
1690 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1691 continue
1692 ac_builddir=.
1693
1694case "$ac_dir" in
1695.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1696*)
1697 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
1698 # A ".." for each directory in $ac_dir_suffix.
1699 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1700 case $ac_top_builddir_sub in
1701 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1702 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1703 esac ;;
1704esac
1705ac_abs_top_builddir=$ac_pwd
1706ac_abs_builddir=$ac_pwd$ac_dir_suffix
1707# for backward compatibility:
1708ac_top_builddir=$ac_top_build_prefix
1709
1710case $srcdir in
1711 .) # We are building in place.
1712 ac_srcdir=.
1713 ac_top_srcdir=$ac_top_builddir_sub
1714 ac_abs_top_srcdir=$ac_pwd ;;
1715 [\\/]* | ?:[\\/]* ) # Absolute name.
1716 ac_srcdir=$srcdir$ac_dir_suffix;
1717 ac_top_srcdir=$srcdir
1718 ac_abs_top_srcdir=$srcdir ;;
1719 *) # Relative name.
1720 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1721 ac_top_srcdir=$ac_top_build_prefix$srcdir
1722 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1723esac
1724ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1725
1726 cd "$ac_dir" || { ac_status=$?; continue; }
1727 # Check for configure.gnu first; this name is used for a wrapper for
1728 # Metaconfig's "Configure" on case-insensitive file systems.
1729 if test -f "$ac_srcdir/configure.gnu"; then
1730 echo &&
1731 $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1732 elif test -f "$ac_srcdir/configure"; then
1733 echo &&
1734 $SHELL "$ac_srcdir/configure" --help=recursive
1735 else
1736 printf "%s\n" "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1737 fi || ac_status=$?
1738 cd "$ac_pwd" || { ac_status=$?; break; }
1739 done
1740fi
1741
1742test -n "$ac_init_help" && exit $ac_status
1743if $ac_init_version; then
1744 cat <<\_ACEOF
1745bash configure 5.3-release
1746generated by GNU Autoconf 2.72
1747
1748Copyright (C) 2023 Free Software Foundation, Inc.
1749This configure script is free software; the Free Software Foundation
1750gives unlimited permission to copy, distribute and modify it.
1751_ACEOF
1752 exit
1753fi
1754
1755## ------------------------ ##
1756## Autoconf initialization. ##
1757## ------------------------ ##
1758
1759# ac_fn_c_try_compile LINENO
1760# --------------------------
1761# Try to compile conftest.$ac_ext, and return whether this succeeded.
1762ac_fn_c_try_compile ()
1763{
1764 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1765 rm -f conftest.$ac_objext conftest.beam
1766 if { { ac_try="$ac_compile"
1767case "(($ac_try" in
1768 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1769 *) ac_try_echo=$ac_try;;
1770esac
1771eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1772printf "%s\n" "$ac_try_echo"; } >&5
1773 (eval "$ac_compile") 2>conftest.err
1774 ac_status=$?
1775 if test -s conftest.err; then
1776 grep -v '^ *+' conftest.err >conftest.er1
1777 cat conftest.er1 >&5
1778 mv -f conftest.er1 conftest.err
1779 fi
1780 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1781 test $ac_status = 0; } && {
1782 test -z "$ac_c_werror_flag" ||
1783 test ! -s conftest.err
1784 } && test -s conftest.$ac_objext
1785then :
1786 ac_retval=0
1787else case e in #(
1788 e) printf "%s\n" "$as_me: failed program was:" >&5
1789sed 's/^/| /' conftest.$ac_ext >&5
1790
1791 ac_retval=1 ;;
1792esac
1793fi
1794 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1795 as_fn_set_status $ac_retval
1796
1797} # ac_fn_c_try_compile
1798
1799# ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1800# -------------------------------------------------------
1801# Tests whether HEADER exists and can be compiled using the include files in
1802# INCLUDES, setting the cache variable VAR accordingly.
1803ac_fn_c_check_header_compile ()
1804{
1805 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1806 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1807printf %s "checking for $2... " >&6; }
1808if eval test \${$3+y}
1809then :
1810 printf %s "(cached) " >&6
1811else case e in #(
1812 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1813/* end confdefs.h. */
1814$4
1815#include <$2>
1816_ACEOF
1817if ac_fn_c_try_compile "$LINENO"
1818then :
1819 eval "$3=yes"
1820else case e in #(
1821 e) eval "$3=no" ;;
1822esac
1823fi
1824rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
1825esac
1826fi
1827eval ac_res=\$$3
1828 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1829printf "%s\n" "$ac_res" >&6; }
1830 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1831
1832} # ac_fn_c_check_header_compile
1833
1834# ac_fn_c_try_link LINENO
1835# -----------------------
1836# Try to link conftest.$ac_ext, and return whether this succeeded.
1837ac_fn_c_try_link ()
1838{
1839 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1840 rm -f conftest.$ac_objext conftest.beam conftest$ac_exeext
1841 if { { ac_try="$ac_link"
1842case "(($ac_try" in
1843 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1844 *) ac_try_echo=$ac_try;;
1845esac
1846eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1847printf "%s\n" "$ac_try_echo"; } >&5
1848 (eval "$ac_link") 2>conftest.err
1849 ac_status=$?
1850 if test -s conftest.err; then
1851 grep -v '^ *+' conftest.err >conftest.er1
1852 cat conftest.er1 >&5
1853 mv -f conftest.er1 conftest.err
1854 fi
1855 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1856 test $ac_status = 0; } && {
1857 test -z "$ac_c_werror_flag" ||
1858 test ! -s conftest.err
1859 } && test -s conftest$ac_exeext && {
1860 test "$cross_compiling" = yes ||
1861 test -x conftest$ac_exeext
1862 }
1863then :
1864 ac_retval=0
1865else case e in #(
1866 e) printf "%s\n" "$as_me: failed program was:" >&5
1867sed 's/^/| /' conftest.$ac_ext >&5
1868
1869 ac_retval=1 ;;
1870esac
1871fi
1872 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1873 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1874 # interfere with the next link command; also delete a directory that is
1875 # left behind by Apple's compiler. We do this before executing the actions.
1876 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1877 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1878 as_fn_set_status $ac_retval
1879
1880} # ac_fn_c_try_link
1881
1882# ac_fn_c_check_func LINENO FUNC VAR
1883# ----------------------------------
1884# Tests whether FUNC exists, setting the cache variable VAR accordingly
1885ac_fn_c_check_func ()
1886{
1887 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1888 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1889printf %s "checking for $2... " >&6; }
1890if eval test \${$3+y}
1891then :
1892 printf %s "(cached) " >&6
1893else case e in #(
1894 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1895/* end confdefs.h. */
1896/* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1897 For example, HP-UX 11i <limits.h> declares gettimeofday. */
1898#define $2 innocuous_$2
1899
1900/* System header to define __stub macros and hopefully few prototypes,
1901 which can conflict with char $2 (void); below. */
1902
1903#include <limits.h>
1904#undef $2
1905
1906/* Override any GCC internal prototype to avoid an error.
1907 Use char because int might match the return type of a GCC
1908 builtin and then its argument prototype would still apply. */
1909#ifdef __cplusplus
1910extern "C"
1911#endif
1912char $2 (void);
1913/* The GNU C library defines this for functions which it implements
1914 to always fail with ENOSYS. Some functions are actually named
1915 something starting with __ and the normal name is an alias. */
1916#if defined __stub_$2 || defined __stub___$2
1917choke me
1918#endif
1919
1920int
1921main (void)
1922{
1923return $2 ();
1924 ;
1925 return 0;
1926}
1927_ACEOF
1928if ac_fn_c_try_link "$LINENO"
1929then :
1930 eval "$3=yes"
1931else case e in #(
1932 e) eval "$3=no" ;;
1933esac
1934fi
1935rm -f core conftest.err conftest.$ac_objext conftest.beam \
1936 conftest$ac_exeext conftest.$ac_ext ;;
1937esac
1938fi
1939eval ac_res=\$$3
1940 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1941printf "%s\n" "$ac_res" >&6; }
1942 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1943
1944} # ac_fn_c_check_func
1945
1946# ac_fn_c_try_run LINENO
1947# ----------------------
1948# Try to run conftest.$ac_ext, and return whether this succeeded. Assumes that
1949# executables *can* be run.
1950ac_fn_c_try_run ()
1951{
1952 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1953 if { { ac_try="$ac_link"
1954case "(($ac_try" in
1955 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1956 *) ac_try_echo=$ac_try;;
1957esac
1958eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1959printf "%s\n" "$ac_try_echo"; } >&5
1960 (eval "$ac_link") 2>&5
1961 ac_status=$?
1962 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1963 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1964 { { case "(($ac_try" in
1965 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1966 *) ac_try_echo=$ac_try;;
1967esac
1968eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1969printf "%s\n" "$ac_try_echo"; } >&5
1970 (eval "$ac_try") 2>&5
1971 ac_status=$?
1972 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1973 test $ac_status = 0; }; }
1974then :
1975 ac_retval=0
1976else case e in #(
1977 e) printf "%s\n" "$as_me: program exited with status $ac_status" >&5
1978 printf "%s\n" "$as_me: failed program was:" >&5
1979sed 's/^/| /' conftest.$ac_ext >&5
1980
1981 ac_retval=$ac_status ;;
1982esac
1983fi
1984 rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1985 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
1986 as_fn_set_status $ac_retval
1987
1988} # ac_fn_c_try_run
1989
1990# ac_fn_c_try_cpp LINENO
1991# ----------------------
1992# Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1993ac_fn_c_try_cpp ()
1994{
1995 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1996 if { { ac_try="$ac_cpp conftest.$ac_ext"
1997case "(($ac_try" in
1998 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1999 *) ac_try_echo=$ac_try;;
2000esac
2001eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2002printf "%s\n" "$ac_try_echo"; } >&5
2003 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
2004 ac_status=$?
2005 if test -s conftest.err; then
2006 grep -v '^ *+' conftest.err >conftest.er1
2007 cat conftest.er1 >&5
2008 mv -f conftest.er1 conftest.err
2009 fi
2010 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2011 test $ac_status = 0; } > conftest.i && {
2012 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2013 test ! -s conftest.err
2014 }
2015then :
2016 ac_retval=0
2017else case e in #(
2018 e) printf "%s\n" "$as_me: failed program was:" >&5
2019sed 's/^/| /' conftest.$ac_ext >&5
2020
2021 ac_retval=1 ;;
2022esac
2023fi
2024 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2025 as_fn_set_status $ac_retval
2026
2027} # ac_fn_c_try_cpp
2028
2029# ac_fn_c_check_type LINENO TYPE VAR INCLUDES
2030# -------------------------------------------
2031# Tests whether TYPE exists after having included INCLUDES, setting cache
2032# variable VAR accordingly.
2033ac_fn_c_check_type ()
2034{
2035 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2036 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
2037printf %s "checking for $2... " >&6; }
2038if eval test \${$3+y}
2039then :
2040 printf %s "(cached) " >&6
2041else case e in #(
2042 e) eval "$3=no"
2043 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2044/* end confdefs.h. */
2045$4
2046int
2047main (void)
2048{
2049if (sizeof ($2))
2050 return 0;
2051 ;
2052 return 0;
2053}
2054_ACEOF
2055if ac_fn_c_try_compile "$LINENO"
2056then :
2057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2058/* end confdefs.h. */
2059$4
2060int
2061main (void)
2062{
2063if (sizeof (($2)))
2064 return 0;
2065 ;
2066 return 0;
2067}
2068_ACEOF
2069if ac_fn_c_try_compile "$LINENO"
2070then :
2071
2072else case e in #(
2073 e) eval "$3=yes" ;;
2074esac
2075fi
2076rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2077fi
2078rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
2079esac
2080fi
2081eval ac_res=\$$3
2082 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2083printf "%s\n" "$ac_res" >&6; }
2084 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2085
2086} # ac_fn_c_check_type
2087
2088# ac_fn_check_decl LINENO SYMBOL VAR INCLUDES EXTRA-OPTIONS FLAG-VAR
2089# ------------------------------------------------------------------
2090# Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
2091# accordingly. Pass EXTRA-OPTIONS to the compiler, using FLAG-VAR.
2092ac_fn_check_decl ()
2093{
2094 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2095 as_decl_name=`echo $2|sed 's/ *(.*//'`
2096 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
2097printf %s "checking whether $as_decl_name is declared... " >&6; }
2098if eval test \${$3+y}
2099then :
2100 printf %s "(cached) " >&6
2101else case e in #(
2102 e) as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
2103 eval ac_save_FLAGS=\$$6
2104 as_fn_append $6 " $5"
2105 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2106/* end confdefs.h. */
2107$4
2108int
2109main (void)
2110{
2111#ifndef $as_decl_name
2112#ifdef __cplusplus
2113 (void) $as_decl_use;
2114#else
2115 (void) $as_decl_name;
2116#endif
2117#endif
2118
2119 ;
2120 return 0;
2121}
2122_ACEOF
2123if ac_fn_c_try_compile "$LINENO"
2124then :
2125 eval "$3=yes"
2126else case e in #(
2127 e) eval "$3=no" ;;
2128esac
2129fi
2130rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2131 eval $6=\$ac_save_FLAGS
2132 ;;
2133esac
2134fi
2135eval ac_res=\$$3
2136 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2137printf "%s\n" "$ac_res" >&6; }
2138 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2139
2140} # ac_fn_check_decl
2141
2142# ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
2143# --------------------------------------------
2144# Tries to find the compile-time value of EXPR in a program that includes
2145# INCLUDES, setting VAR accordingly. Returns whether the value could be
2146# computed
2147ac_fn_c_compute_int ()
2148{
2149 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2150 if test "$cross_compiling" = yes; then
2151 # Depending upon the size, compute the lo and hi bounds.
2152cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2153/* end confdefs.h. */
2154$4
2155int
2156main (void)
2157{
2158static int test_array [1 - 2 * !(($2) >= 0)];
2159test_array [0] = 0;
2160return test_array [0];
2161
2162 ;
2163 return 0;
2164}
2165_ACEOF
2166if ac_fn_c_try_compile "$LINENO"
2167then :
2168 ac_lo=0 ac_mid=0
2169 while :; do
2170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2171/* end confdefs.h. */
2172$4
2173int
2174main (void)
2175{
2176static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2177test_array [0] = 0;
2178return test_array [0];
2179
2180 ;
2181 return 0;
2182}
2183_ACEOF
2184if ac_fn_c_try_compile "$LINENO"
2185then :
2186 ac_hi=$ac_mid; break
2187else case e in #(
2188 e) as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2189 if test $ac_lo -le $ac_mid; then
2190 ac_lo= ac_hi=
2191 break
2192 fi
2193 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val ;;
2194esac
2195fi
2196rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2197 done
2198else case e in #(
2199 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2200/* end confdefs.h. */
2201$4
2202int
2203main (void)
2204{
2205static int test_array [1 - 2 * !(($2) < 0)];
2206test_array [0] = 0;
2207return test_array [0];
2208
2209 ;
2210 return 0;
2211}
2212_ACEOF
2213if ac_fn_c_try_compile "$LINENO"
2214then :
2215 ac_hi=-1 ac_mid=-1
2216 while :; do
2217 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2218/* end confdefs.h. */
2219$4
2220int
2221main (void)
2222{
2223static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2224test_array [0] = 0;
2225return test_array [0];
2226
2227 ;
2228 return 0;
2229}
2230_ACEOF
2231if ac_fn_c_try_compile "$LINENO"
2232then :
2233 ac_lo=$ac_mid; break
2234else case e in #(
2235 e) as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2236 if test $ac_mid -le $ac_hi; then
2237 ac_lo= ac_hi=
2238 break
2239 fi
2240 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val ;;
2241esac
2242fi
2243rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2244 done
2245else case e in #(
2246 e) ac_lo= ac_hi= ;;
2247esac
2248fi
2249rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
2250esac
2251fi
2252rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2253# Binary search between lo and hi bounds.
2254while test "x$ac_lo" != "x$ac_hi"; do
2255 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2257/* end confdefs.h. */
2258$4
2259int
2260main (void)
2261{
2262static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2263test_array [0] = 0;
2264return test_array [0];
2265
2266 ;
2267 return 0;
2268}
2269_ACEOF
2270if ac_fn_c_try_compile "$LINENO"
2271then :
2272 ac_hi=$ac_mid
2273else case e in #(
2274 e) as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val ;;
2275esac
2276fi
2277rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
2278done
2279case $ac_lo in #((
2280?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2281'') ac_retval=1 ;;
2282esac
2283 else
2284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2285/* end confdefs.h. */
2286$4
2287static long int longval (void) { return $2; }
2288static unsigned long int ulongval (void) { return $2; }
2289#include <stdio.h>
2290#include <stdlib.h>
2291int
2292main (void)
2293{
2294
2295 FILE *f = fopen ("conftest.val", "w");
2296 if (! f)
2297 return 1;
2298 if (($2) < 0)
2299 {
2300 long int i = longval ();
2301 if (i != ($2))
2302 return 1;
2303 fprintf (f, "%ld", i);
2304 }
2305 else
2306 {
2307 unsigned long int i = ulongval ();
2308 if (i != ($2))
2309 return 1;
2310 fprintf (f, "%lu", i);
2311 }
2312 /* Do not output a trailing newline, as this causes \r\n confusion
2313 on some platforms. */
2314 return ferror (f) || fclose (f) != 0;
2315
2316 ;
2317 return 0;
2318}
2319_ACEOF
2320if ac_fn_c_try_run "$LINENO"
2321then :
2322 echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2323else case e in #(
2324 e) ac_retval=1 ;;
2325esac
2326fi
2327rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2328 conftest.$ac_objext conftest.beam conftest.$ac_ext
2329rm -f conftest.val
2330
2331 fi
2332 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2333 as_fn_set_status $ac_retval
2334
2335} # ac_fn_c_compute_int
2336
2337# ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2338# ----------------------------------------------------
2339# Tries to find if the field MEMBER exists in type AGGR, after including
2340# INCLUDES, setting cache variable VAR accordingly.
2341ac_fn_c_check_member ()
2342{
2343 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2344 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2345printf %s "checking for $2.$3... " >&6; }
2346if eval test \${$4+y}
2347then :
2348 printf %s "(cached) " >&6
2349else case e in #(
2350 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2351/* end confdefs.h. */
2352$5
2353int
2354main (void)
2355{
2356static $2 ac_aggr;
2357if (ac_aggr.$3)
2358return 0;
2359 ;
2360 return 0;
2361}
2362_ACEOF
2363if ac_fn_c_try_compile "$LINENO"
2364then :
2365 eval "$4=yes"
2366else case e in #(
2367 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2368/* end confdefs.h. */
2369$5
2370int
2371main (void)
2372{
2373static $2 ac_aggr;
2374if (sizeof ac_aggr.$3)
2375return 0;
2376 ;
2377 return 0;
2378}
2379_ACEOF
2380if ac_fn_c_try_compile "$LINENO"
2381then :
2382 eval "$4=yes"
2383else case e in #(
2384 e) eval "$4=no" ;;
2385esac
2386fi
2387rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
2388esac
2389fi
2390rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
2391esac
2392fi
2393eval ac_res=\$$4
2394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2395printf "%s\n" "$ac_res" >&6; }
2396 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno
2397
2398} # ac_fn_c_check_member
2399ac_configure_args_raw=
2400for ac_arg
2401do
2402 case $ac_arg in
2403 *\'*)
2404 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2405 esac
2406 as_fn_append ac_configure_args_raw " '$ac_arg'"
2407done
2408
2409case $ac_configure_args_raw in
2410 *$as_nl*)
2411 ac_safe_unquote= ;;
2412 *)
2413 ac_unsafe_z='|&;<>()$`\\"*?[ '' ' # This string ends in space, tab.
2414 ac_unsafe_a="$ac_unsafe_z#~"
2415 ac_safe_unquote="s/ '\\([^$ac_unsafe_a][^$ac_unsafe_z]*\\)'/ \\1/g"
2416 ac_configure_args_raw=` printf "%s\n" "$ac_configure_args_raw" | sed "$ac_safe_unquote"`;;
2417esac
2418
2419cat >config.log <<_ACEOF
2420This file contains any messages produced by compilers while
2421running configure, to aid debugging if configure makes a mistake.
2422
2423It was created by bash $as_me 5.3-release, which was
2424generated by GNU Autoconf 2.72. Invocation command line was
2425
2426 $ $0$ac_configure_args_raw
2427
2428_ACEOF
2429exec 5>>config.log
2430{
2431cat <<_ASUNAME
2432## --------- ##
2433## Platform. ##
2434## --------- ##
2435
2436hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2437uname -m = `(uname -m) 2>/dev/null || echo unknown`
2438uname -r = `(uname -r) 2>/dev/null || echo unknown`
2439uname -s = `(uname -s) 2>/dev/null || echo unknown`
2440uname -v = `(uname -v) 2>/dev/null || echo unknown`
2441
2442/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2443/bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown`
2444
2445/bin/arch = `(/bin/arch) 2>/dev/null || echo unknown`
2446/usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown`
2447/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2448/usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown`
2449/bin/machine = `(/bin/machine) 2>/dev/null || echo unknown`
2450/usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown`
2451/bin/universe = `(/bin/universe) 2>/dev/null || echo unknown`
2452
2453_ASUNAME
2454
2455as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2456for as_dir in $PATH
2457do
2458 IFS=$as_save_IFS
2459 case $as_dir in #(((
2460 '') as_dir=./ ;;
2461 */) ;;
2462 *) as_dir=$as_dir/ ;;
2463 esac
2464 printf "%s\n" "PATH: $as_dir"
2465 done
2466IFS=$as_save_IFS
2467
2468} >&5
2469
2470cat >&5 <<_ACEOF
2471
2472
2473## ----------- ##
2474## Core tests. ##
2475## ----------- ##
2476
2477_ACEOF
2478
2479
2480# Keep a trace of the command line.
2481# Strip out --no-create and --no-recursion so they do not pile up.
2482# Strip out --silent because we don't want to record it for future runs.
2483# Also quote any args containing shell meta-characters.
2484# Make two passes to allow for proper duplicate-argument suppression.
2485ac_configure_args=
2486ac_configure_args0=
2487ac_configure_args1=
2488ac_must_keep_next=false
2489for ac_pass in 1 2
2490do
2491 for ac_arg
2492 do
2493 case $ac_arg in
2494 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2495 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2496 | -silent | --silent | --silen | --sile | --sil)
2497 continue ;;
2498 *\'*)
2499 ac_arg=`printf "%s\n" "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2500 esac
2501 case $ac_pass in
2502 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2503 2)
2504 as_fn_append ac_configure_args1 " '$ac_arg'"
2505 if test $ac_must_keep_next = true; then
2506 ac_must_keep_next=false # Got value, back to normal.
2507 else
2508 case $ac_arg in
2509 *=* | --config-cache | -C | -disable-* | --disable-* \
2510 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2511 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2512 | -with-* | --with-* | -without-* | --without-* | --x)
2513 case "$ac_configure_args0 " in
2514 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2515 esac
2516 ;;
2517 -* ) ac_must_keep_next=true ;;
2518 esac
2519 fi
2520 as_fn_append ac_configure_args " '$ac_arg'"
2521 ;;
2522 esac
2523 done
2524done
2525{ ac_configure_args0=; unset ac_configure_args0;}
2526{ ac_configure_args1=; unset ac_configure_args1;}
2527
2528# When interrupted or exit'd, cleanup temporary files, and complete
2529# config.log. We remove comments because anyway the quotes in there
2530# would cause problems or look ugly.
2531# WARNING: Use '\'' to represent an apostrophe within the trap.
2532# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2533trap 'exit_status=$?
2534 # Sanitize IFS.
2535 IFS=" "" $as_nl"
2536 # Save into config.log some information that might help in debugging.
2537 {
2538 echo
2539
2540 printf "%s\n" "## ---------------- ##
2541## Cache variables. ##
2542## ---------------- ##"
2543 echo
2544 # The following way of writing the cache mishandles newlines in values,
2545(
2546 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2547 eval ac_val=\$$ac_var
2548 case $ac_val in #(
2549 *${as_nl}*)
2550 case $ac_var in #(
2551 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2552printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2553 esac
2554 case $ac_var in #(
2555 _ | IFS | as_nl) ;; #(
2556 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2557 *) { eval $ac_var=; unset $ac_var;} ;;
2558 esac ;;
2559 esac
2560 done
2561 (set) 2>&1 |
2562 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2563 *${as_nl}ac_space=\ *)
2564 sed -n \
2565 "s/'\''/'\''\\\\'\'''\''/g;
2566 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2567 ;; #(
2568 *)
2569 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2570 ;;
2571 esac |
2572 sort
2573)
2574 echo
2575
2576 printf "%s\n" "## ----------------- ##
2577## Output variables. ##
2578## ----------------- ##"
2579 echo
2580 for ac_var in $ac_subst_vars
2581 do
2582 eval ac_val=\$$ac_var
2583 case $ac_val in
2584 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2585 esac
2586 printf "%s\n" "$ac_var='\''$ac_val'\''"
2587 done | sort
2588 echo
2589
2590 if test -n "$ac_subst_files"; then
2591 printf "%s\n" "## ------------------- ##
2592## File substitutions. ##
2593## ------------------- ##"
2594 echo
2595 for ac_var in $ac_subst_files
2596 do
2597 eval ac_val=\$$ac_var
2598 case $ac_val in
2599 *\'\''*) ac_val=`printf "%s\n" "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2600 esac
2601 printf "%s\n" "$ac_var='\''$ac_val'\''"
2602 done | sort
2603 echo
2604 fi
2605
2606 if test -s confdefs.h; then
2607 printf "%s\n" "## ----------- ##
2608## confdefs.h. ##
2609## ----------- ##"
2610 echo
2611 cat confdefs.h
2612 echo
2613 fi
2614 test "$ac_signal" != 0 &&
2615 printf "%s\n" "$as_me: caught signal $ac_signal"
2616 printf "%s\n" "$as_me: exit $exit_status"
2617 } >&5
2618 rm -f core *.core core.conftest.* &&
2619 rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2620 exit $exit_status
2621' 0
2622for ac_signal in 1 2 13 15; do
2623 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2624done
2625ac_signal=0
2626
2627# confdefs.h avoids OS command line length limits that DEFS can exceed.
2628rm -f -r conftest* confdefs.h
2629
2630printf "%s\n" "/* confdefs.h */" > confdefs.h
2631
2632# Predefined preprocessor variables.
2633
2634printf "%s\n" "#define PACKAGE_NAME \"$PACKAGE_NAME\"" >>confdefs.h
2635
2636printf "%s\n" "#define PACKAGE_TARNAME \"$PACKAGE_TARNAME\"" >>confdefs.h
2637
2638printf "%s\n" "#define PACKAGE_VERSION \"$PACKAGE_VERSION\"" >>confdefs.h
2639
2640printf "%s\n" "#define PACKAGE_STRING \"$PACKAGE_STRING\"" >>confdefs.h
2641
2642printf "%s\n" "#define PACKAGE_BUGREPORT \"$PACKAGE_BUGREPORT\"" >>confdefs.h
2643
2644printf "%s\n" "#define PACKAGE_URL \"$PACKAGE_URL\"" >>confdefs.h
2645
2646
2647# Let the site file select an alternate cache file if it wants to.
2648# Prefer an explicitly selected file to automatically selected ones.
2649if test -n "$CONFIG_SITE"; then
2650 ac_site_files="$CONFIG_SITE"
2651elif test "x$prefix" != xNONE; then
2652 ac_site_files="$prefix/share/config.site $prefix/etc/config.site"
2653else
2654 ac_site_files="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
2655fi
2656
2657for ac_site_file in $ac_site_files
2658do
2659 case $ac_site_file in #(
2660 */*) :
2661 ;; #(
2662 *) :
2663 ac_site_file=./$ac_site_file ;;
2664esac
2665 if test -f "$ac_site_file" && test -r "$ac_site_file"; then
2666 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2667printf "%s\n" "$as_me: loading site script $ac_site_file" >&6;}
2668 sed 's/^/| /' "$ac_site_file" >&5
2669 . "$ac_site_file" \
2670 || { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
2671printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
2672as_fn_error $? "failed to load site script $ac_site_file
2673See 'config.log' for more details" "$LINENO" 5; }
2674 fi
2675done
2676
2677if test -r "$cache_file"; then
2678 # Some versions of bash will fail to source /dev/null (special files
2679 # actually), so we avoid doing that. DJGPP emulates it as a regular file.
2680 if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2681 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2682printf "%s\n" "$as_me: loading cache $cache_file" >&6;}
2683 case $cache_file in
2684 [\\/]* | ?:[\\/]* ) . "$cache_file";;
2685 *) . "./$cache_file";;
2686 esac
2687 fi
2688else
2689 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2690printf "%s\n" "$as_me: creating cache $cache_file" >&6;}
2691 >$cache_file
2692fi
2693
2694# Test code for whether the C compiler supports C89 (global declarations)
2695ac_c_conftest_c89_globals='
2696/* Does the compiler advertise C89 conformance?
2697 Do not test the value of __STDC__, because some compilers set it to 0
2698 while being otherwise adequately conformant. */
2699#if !defined __STDC__
2700# error "Compiler does not advertise C89 conformance"
2701#endif
2702
2703#include <stddef.h>
2704#include <stdarg.h>
2705struct stat;
2706/* Most of the following tests are stolen from RCS 5.7 src/conf.sh. */
2707struct buf { int x; };
2708struct buf * (*rcsopen) (struct buf *, struct stat *, int);
2709static char *e (char **p, int i)
2710{
2711 return p[i];
2712}
2713static char *f (char * (*g) (char **, int), char **p, ...)
2714{
2715 char *s;
2716 va_list v;
2717 va_start (v,p);
2718 s = g (p, va_arg (v,int));
2719 va_end (v);
2720 return s;
2721}
2722
2723/* C89 style stringification. */
2724#define noexpand_stringify(a) #a
2725const char *stringified = noexpand_stringify(arbitrary+token=sequence);
2726
2727/* C89 style token pasting. Exercises some of the corner cases that
2728 e.g. old MSVC gets wrong, but not very hard. */
2729#define noexpand_concat(a,b) a##b
2730#define expand_concat(a,b) noexpand_concat(a,b)
2731extern int vA;
2732extern int vbee;
2733#define aye A
2734#define bee B
2735int *pvA = &expand_concat(v,aye);
2736int *pvbee = &noexpand_concat(v,bee);
2737
2738/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has
2739 function prototypes and stuff, but not \xHH hex character constants.
2740 These do not provoke an error unfortunately, instead are silently treated
2741 as an "x". The following induces an error, until -std is added to get
2742 proper ANSI mode. Curiously \x00 != x always comes out true, for an
2743 array size at least. It is necessary to write \x00 == 0 to get something
2744 that is true only with -std. */
2745int osf4_cc_array ['\''\x00'\'' == 0 ? 1 : -1];
2746
2747/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2748 inside strings and character constants. */
2749#define FOO(x) '\''x'\''
2750int xlc6_cc_array[FOO(a) == '\''x'\'' ? 1 : -1];
2751
2752int test (int i, double x);
2753struct s1 {int (*f) (int a);};
2754struct s2 {int (*f) (double a);};
2755int pairnames (int, char **, int *(*)(struct buf *, struct stat *, int),
2756 int, int);'
2757
2758# Test code for whether the C compiler supports C89 (body of main).
2759ac_c_conftest_c89_main='
2760ok |= (argc == 0 || f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]);
2761'
2762
2763# Test code for whether the C compiler supports C99 (global declarations)
2764ac_c_conftest_c99_globals='
2765/* Does the compiler advertise C99 conformance? */
2766#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 199901L
2767# error "Compiler does not advertise C99 conformance"
2768#endif
2769
2770// See if C++-style comments work.
2771
2772#include <stdbool.h>
2773extern int puts (const char *);
2774extern int printf (const char *, ...);
2775extern int dprintf (int, const char *, ...);
2776extern void *malloc (size_t);
2777extern void free (void *);
2778
2779// Check varargs macros. These examples are taken from C99 6.10.3.5.
2780// dprintf is used instead of fprintf to avoid needing to declare
2781// FILE and stderr.
2782#define debug(...) dprintf (2, __VA_ARGS__)
2783#define showlist(...) puts (#__VA_ARGS__)
2784#define report(test,...) ((test) ? puts (#test) : printf (__VA_ARGS__))
2785static void
2786test_varargs_macros (void)
2787{
2788 int x = 1234;
2789 int y = 5678;
2790 debug ("Flag");
2791 debug ("X = %d\n", x);
2792 showlist (The first, second, and third items.);
2793 report (x>y, "x is %d but y is %d", x, y);
2794}
2795
2796// Check long long types.
2797#define BIG64 18446744073709551615ull
2798#define BIG32 4294967295ul
2799#define BIG_OK (BIG64 / BIG32 == 4294967297ull && BIG64 % BIG32 == 0)
2800#if !BIG_OK
2801 #error "your preprocessor is broken"
2802#endif
2803#if BIG_OK
2804#else
2805 #error "your preprocessor is broken"
2806#endif
2807static long long int bignum = -9223372036854775807LL;
2808static unsigned long long int ubignum = BIG64;
2809
2810struct incomplete_array
2811{
2812 int datasize;
2813 double data[];
2814};
2815
2816struct named_init {
2817 int number;
2818 const wchar_t *name;
2819 double average;
2820};
2821
2822typedef const char *ccp;
2823
2824static inline int
2825test_restrict (ccp restrict text)
2826{
2827 // Iterate through items via the restricted pointer.
2828 // Also check for declarations in for loops.
2829 for (unsigned int i = 0; *(text+i) != '\''\0'\''; ++i)
2830 continue;
2831 return 0;
2832}
2833
2834// Check varargs and va_copy.
2835static bool
2836test_varargs (const char *format, ...)
2837{
2838 va_list args;
2839 va_start (args, format);
2840 va_list args_copy;
2841 va_copy (args_copy, args);
2842
2843 const char *str = "";
2844 int number = 0;
2845 float fnumber = 0;
2846
2847 while (*format)
2848 {
2849 switch (*format++)
2850 {
2851 case '\''s'\'': // string
2852 str = va_arg (args_copy, const char *);
2853 break;
2854 case '\''d'\'': // int
2855 number = va_arg (args_copy, int);
2856 break;
2857 case '\''f'\'': // float
2858 fnumber = va_arg (args_copy, double);
2859 break;
2860 default:
2861 break;
2862 }
2863 }
2864 va_end (args_copy);
2865 va_end (args);
2866
2867 return *str && number && fnumber;
2868}
2869'
2870
2871# Test code for whether the C compiler supports C99 (body of main).
2872ac_c_conftest_c99_main='
2873 // Check bool.
2874 _Bool success = false;
2875 success |= (argc != 0);
2876
2877 // Check restrict.
2878 if (test_restrict ("String literal") == 0)
2879 success = true;
2880 char *restrict newvar = "Another string";
2881
2882 // Check varargs.
2883 success &= test_varargs ("s, d'\'' f .", "string", 65, 34.234);
2884 test_varargs_macros ();
2885
2886 // Check flexible array members.
2887 struct incomplete_array *ia =
2888 malloc (sizeof (struct incomplete_array) + (sizeof (double) * 10));
2889 ia->datasize = 10;
2890 for (int i = 0; i < ia->datasize; ++i)
2891 ia->data[i] = i * 1.234;
2892 // Work around memory leak warnings.
2893 free (ia);
2894
2895 // Check named initializers.
2896 struct named_init ni = {
2897 .number = 34,
2898 .name = L"Test wide string",
2899 .average = 543.34343,
2900 };
2901
2902 ni.number = 58;
2903
2904 int dynamic_array[ni.number];
2905 dynamic_array[0] = argv[0][0];
2906 dynamic_array[ni.number - 1] = 543;
2907
2908 // work around unused variable warnings
2909 ok |= (!success || bignum == 0LL || ubignum == 0uLL || newvar[0] == '\''x'\''
2910 || dynamic_array[ni.number - 1] != 543);
2911'
2912
2913# Test code for whether the C compiler supports C11 (global declarations)
2914ac_c_conftest_c11_globals='
2915/* Does the compiler advertise C11 conformance? */
2916#if !defined __STDC_VERSION__ || __STDC_VERSION__ < 201112L
2917# error "Compiler does not advertise C11 conformance"
2918#endif
2919
2920// Check _Alignas.
2921char _Alignas (double) aligned_as_double;
2922char _Alignas (0) no_special_alignment;
2923extern char aligned_as_int;
2924char _Alignas (0) _Alignas (int) aligned_as_int;
2925
2926// Check _Alignof.
2927enum
2928{
2929 int_alignment = _Alignof (int),
2930 int_array_alignment = _Alignof (int[100]),
2931 char_alignment = _Alignof (char)
2932};
2933_Static_assert (0 < -_Alignof (int), "_Alignof is signed");
2934
2935// Check _Noreturn.
2936int _Noreturn does_not_return (void) { for (;;) continue; }
2937
2938// Check _Static_assert.
2939struct test_static_assert
2940{
2941 int x;
2942 _Static_assert (sizeof (int) <= sizeof (long int),
2943 "_Static_assert does not work in struct");
2944 long int y;
2945};
2946
2947// Check UTF-8 literals.
2948#define u8 syntax error!
2949char const utf8_literal[] = u8"happens to be ASCII" "another string";
2950
2951// Check duplicate typedefs.
2952typedef long *long_ptr;
2953typedef long int *long_ptr;
2954typedef long_ptr long_ptr;
2955
2956// Anonymous structures and unions -- taken from C11 6.7.2.1 Example 1.
2957struct anonymous
2958{
2959 union {
2960 struct { int i; int j; };
2961 struct { int k; long int l; } w;
2962 };
2963 int m;
2964} v1;
2965'
2966
2967# Test code for whether the C compiler supports C11 (body of main).
2968ac_c_conftest_c11_main='
2969 _Static_assert ((offsetof (struct anonymous, i)
2970 == offsetof (struct anonymous, w.k)),
2971 "Anonymous union alignment botch");
2972 v1.i = 2;
2973 v1.w.k = 5;
2974 ok |= v1.i != 5;
2975'
2976
2977# Test code for whether the C compiler supports C11 (complete).
2978ac_c_conftest_c11_program="${ac_c_conftest_c89_globals}
2979${ac_c_conftest_c99_globals}
2980${ac_c_conftest_c11_globals}
2981
2982int
2983main (int argc, char **argv)
2984{
2985 int ok = 0;
2986 ${ac_c_conftest_c89_main}
2987 ${ac_c_conftest_c99_main}
2988 ${ac_c_conftest_c11_main}
2989 return ok;
2990}
2991"
2992
2993# Test code for whether the C compiler supports C99 (complete).
2994ac_c_conftest_c99_program="${ac_c_conftest_c89_globals}
2995${ac_c_conftest_c99_globals}
2996
2997int
2998main (int argc, char **argv)
2999{
3000 int ok = 0;
3001 ${ac_c_conftest_c89_main}
3002 ${ac_c_conftest_c99_main}
3003 return ok;
3004}
3005"
3006
3007# Test code for whether the C compiler supports C89 (complete).
3008ac_c_conftest_c89_program="${ac_c_conftest_c89_globals}
3009
3010int
3011main (int argc, char **argv)
3012{
3013 int ok = 0;
3014 ${ac_c_conftest_c89_main}
3015 return ok;
3016}
3017"
3018
3019as_fn_append ac_header_c_list " stdio.h stdio_h HAVE_STDIO_H"
3020as_fn_append ac_header_c_list " stdlib.h stdlib_h HAVE_STDLIB_H"
3021as_fn_append ac_header_c_list " string.h string_h HAVE_STRING_H"
3022as_fn_append ac_header_c_list " inttypes.h inttypes_h HAVE_INTTYPES_H"
3023as_fn_append ac_header_c_list " stdint.h stdint_h HAVE_STDINT_H"
3024as_fn_append ac_header_c_list " strings.h strings_h HAVE_STRINGS_H"
3025as_fn_append ac_header_c_list " sys/stat.h sys_stat_h HAVE_SYS_STAT_H"
3026as_fn_append ac_header_c_list " sys/types.h sys_types_h HAVE_SYS_TYPES_H"
3027as_fn_append ac_header_c_list " unistd.h unistd_h HAVE_UNISTD_H"
3028as_fn_append ac_header_c_list " wchar.h wchar_h HAVE_WCHAR_H"
3029as_fn_append ac_header_c_list " minix/config.h minix_config_h HAVE_MINIX_CONFIG_H"
3030as_fn_append ac_header_c_list " stdbool.h stdbool_h HAVE_STDBOOL_H"
3031gt_needs="$gt_needs need-ngettext"
3032as_fn_append ac_header_c_list " sys/param.h sys_param_h HAVE_SYS_PARAM_H"
3033as_fn_append ac_func_c_list " getpagesize HAVE_GETPAGESIZE"
3034as_fn_append ac_header_c_list " threads.h threads_h HAVE_THREADS_H"
3035as_fn_append ac_func_c_list " symlink HAVE_SYMLINK"
3036as_fn_append ac_func_c_list " uselocale HAVE_USELOCALE"
3037as_fn_append ac_header_c_list " xlocale.h xlocale_h HAVE_XLOCALE_H"
3038as_fn_append ac_func_c_list " vprintf HAVE_VPRINTF"
3039as_fn_append ac_header_c_list " sys/time.h sys_time_h HAVE_SYS_TIME_H"
3040as_fn_append ac_func_c_list " alarm HAVE_ALARM"
3041as_fn_append ac_func_c_list " fpurge HAVE_FPURGE"
3042as_fn_append ac_func_c_list " __fpurge HAVE___FPURGE"
3043as_fn_append ac_func_c_list " snprintf HAVE_SNPRINTF"
3044as_fn_append ac_func_c_list " vsnprintf HAVE_VSNPRINTF"
3045
3046# Auxiliary files required by this configure script.
3047ac_aux_files="config.rpath install-sh config.guess config.sub"
3048
3049# Locations in which to look for auxiliary files.
3050ac_aux_dir_candidates="${srcdir}/./support"
3051
3052# Search for a directory containing all of the required auxiliary files,
3053# $ac_aux_files, from the $PATH-style list $ac_aux_dir_candidates.
3054# If we don't find one directory that contains all the files we need,
3055# we report the set of missing files from the *first* directory in
3056# $ac_aux_dir_candidates and give up.
3057ac_missing_aux_files=""
3058ac_first_candidate=:
3059printf "%s\n" "$as_me:${as_lineno-$LINENO}: looking for aux files: $ac_aux_files" >&5
3060as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3061as_found=false
3062for as_dir in $ac_aux_dir_candidates
3063do
3064 IFS=$as_save_IFS
3065 case $as_dir in #(((
3066 '') as_dir=./ ;;
3067 */) ;;
3068 *) as_dir=$as_dir/ ;;
3069 esac
3070 as_found=:
3071
3072 printf "%s\n" "$as_me:${as_lineno-$LINENO}: trying $as_dir" >&5
3073 ac_aux_dir_found=yes
3074 ac_install_sh=
3075 for ac_aux in $ac_aux_files
3076 do
3077 # As a special case, if "install-sh" is required, that requirement
3078 # can be satisfied by any of "install-sh", "install.sh", or "shtool",
3079 # and $ac_install_sh is set appropriately for whichever one is found.
3080 if test x"$ac_aux" = x"install-sh"
3081 then
3082 if test -f "${as_dir}install-sh"; then
3083 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install-sh found" >&5
3084 ac_install_sh="${as_dir}install-sh -c"
3085 elif test -f "${as_dir}install.sh"; then
3086 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}install.sh found" >&5
3087 ac_install_sh="${as_dir}install.sh -c"
3088 elif test -f "${as_dir}shtool"; then
3089 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}shtool found" >&5
3090 ac_install_sh="${as_dir}shtool install -c"
3091 else
3092 ac_aux_dir_found=no
3093 if $ac_first_candidate; then
3094 ac_missing_aux_files="${ac_missing_aux_files} install-sh"
3095 else
3096 break
3097 fi
3098 fi
3099 else
3100 if test -f "${as_dir}${ac_aux}"; then
3101 printf "%s\n" "$as_me:${as_lineno-$LINENO}: ${as_dir}${ac_aux} found" >&5
3102 else
3103 ac_aux_dir_found=no
3104 if $ac_first_candidate; then
3105 ac_missing_aux_files="${ac_missing_aux_files} ${ac_aux}"
3106 else
3107 break
3108 fi
3109 fi
3110 fi
3111 done
3112 if test "$ac_aux_dir_found" = yes; then
3113 ac_aux_dir="$as_dir"
3114 break
3115 fi
3116 ac_first_candidate=false
3117
3118 as_found=false
3119done
3120IFS=$as_save_IFS
3121if $as_found
3122then :
3123
3124else case e in #(
3125 e) as_fn_error $? "cannot find required auxiliary files:$ac_missing_aux_files" "$LINENO" 5 ;;
3126esac
3127fi
3128
3129
3130# These three variables are undocumented and unsupported,
3131# and are intended to be withdrawn in a future Autoconf release.
3132# They can cause serious problems if a builder's source tree is in a directory
3133# whose full name contains unusual characters.
3134if test -f "${ac_aux_dir}config.guess"; then
3135 ac_config_guess="$SHELL ${ac_aux_dir}config.guess"
3136fi
3137if test -f "${ac_aux_dir}config.sub"; then
3138 ac_config_sub="$SHELL ${ac_aux_dir}config.sub"
3139fi
3140if test -f "$ac_aux_dir/configure"; then
3141 ac_configure="$SHELL ${ac_aux_dir}configure"
3142fi
3143
3144# Check that the precious variables saved in the cache have kept the same
3145# value.
3146ac_cache_corrupted=false
3147for ac_var in $ac_precious_vars; do
3148 eval ac_old_set=\$ac_cv_env_${ac_var}_set
3149 eval ac_new_set=\$ac_env_${ac_var}_set
3150 eval ac_old_val=\$ac_cv_env_${ac_var}_value
3151 eval ac_new_val=\$ac_env_${ac_var}_value
3152 case $ac_old_set,$ac_new_set in
3153 set,)
3154 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&5
3155printf "%s\n" "$as_me: error: '$ac_var' was set to '$ac_old_val' in the previous run" >&2;}
3156 ac_cache_corrupted=: ;;
3157 ,set)
3158 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' was not set in the previous run" >&5
3159printf "%s\n" "$as_me: error: '$ac_var' was not set in the previous run" >&2;}
3160 ac_cache_corrupted=: ;;
3161 ,);;
3162 *)
3163 if test "x$ac_old_val" != "x$ac_new_val"; then
3164 # differences in whitespace do not lead to failure.
3165 ac_old_val_w=`echo x $ac_old_val`
3166 ac_new_val_w=`echo x $ac_new_val`
3167 if test "$ac_old_val_w" != "$ac_new_val_w"; then
3168 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: '$ac_var' has changed since the previous run:" >&5
3169printf "%s\n" "$as_me: error: '$ac_var' has changed since the previous run:" >&2;}
3170 ac_cache_corrupted=:
3171 else
3172 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&5
3173printf "%s\n" "$as_me: warning: ignoring whitespace changes in '$ac_var' since the previous run:" >&2;}
3174 eval $ac_var=\$ac_old_val
3175 fi
3176 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: former value: '$ac_old_val'" >&5
3177printf "%s\n" "$as_me: former value: '$ac_old_val'" >&2;}
3178 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: current value: '$ac_new_val'" >&5
3179printf "%s\n" "$as_me: current value: '$ac_new_val'" >&2;}
3180 fi;;
3181 esac
3182 # Pass precious variables to config.status.
3183 if test "$ac_new_set" = set; then
3184 case $ac_new_val in
3185 *\'*) ac_arg=$ac_var=`printf "%s\n" "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
3186 *) ac_arg=$ac_var=$ac_new_val ;;
3187 esac
3188 case " $ac_configure_args " in
3189 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy.
3190 *) as_fn_append ac_configure_args " '$ac_arg'" ;;
3191 esac
3192 fi
3193done
3194if $ac_cache_corrupted; then
3195 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
3196printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
3197 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
3198printf "%s\n" "$as_me: error: changes in the environment can compromise the build" >&2;}
3199 as_fn_error $? "run '${MAKE-make} distclean' and/or 'rm $cache_file'
3200 and start over" "$LINENO" 5
3201fi
3202## -------------------- ##
3203## Main body of script. ##
3204## -------------------- ##
3205
3206ac_ext=c
3207ac_cpp='$CPP $CPPFLAGS'
3208ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3209ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3210ac_compiler_gnu=$ac_cv_c_compiler_gnu
3211
3212
3213
3214
3215
3216
3217
3218ac_config_headers="$ac_config_headers config.h buildconf.h"
3219
3220
3221BASHVERS=5.3
3222RELSTATUS=release
3223
3224case "$RELSTATUS" in
3225alp*|bet*|dev*|rc*|releng*|maint*) DEBUG='-DDEBUG' MALLOC_DEBUG='-DMALLOC_DEBUG' ;;
3226*) DEBUG= MALLOC_DEBUG= ;;
3227esac
3228
3229
3230
3231
3232 # Make sure we can run config.sub.
3233$SHELL "${ac_aux_dir}config.sub" sun4 >/dev/null 2>&1 ||
3234 as_fn_error $? "cannot run $SHELL ${ac_aux_dir}config.sub" "$LINENO" 5
3235
3236{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3237printf %s "checking build system type... " >&6; }
3238if test ${ac_cv_build+y}
3239then :
3240 printf %s "(cached) " >&6
3241else case e in #(
3242 e) ac_build_alias=$build_alias
3243test "x$ac_build_alias" = x &&
3244 ac_build_alias=`$SHELL "${ac_aux_dir}config.guess"`
3245test "x$ac_build_alias" = x &&
3246 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3247ac_cv_build=`$SHELL "${ac_aux_dir}config.sub" $ac_build_alias` ||
3248 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $ac_build_alias failed" "$LINENO" 5
3249 ;;
3250esac
3251fi
3252{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3253printf "%s\n" "$ac_cv_build" >&6; }
3254case $ac_cv_build in
3255*-*-*) ;;
3256*) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;;
3257esac
3258build=$ac_cv_build
3259ac_save_IFS=$IFS; IFS='-'
3260set x $ac_cv_build
3261shift
3262build_cpu=$1
3263build_vendor=$2
3264shift; shift
3265# Remember, the first character of IFS is used to create $*,
3266# except with old shells:
3267build_os=$*
3268IFS=$ac_save_IFS
3269case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3270
3271
3272{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3273printf %s "checking host system type... " >&6; }
3274if test ${ac_cv_host+y}
3275then :
3276 printf %s "(cached) " >&6
3277else case e in #(
3278 e) if test "x$host_alias" = x; then
3279 ac_cv_host=$ac_cv_build
3280else
3281 ac_cv_host=`$SHELL "${ac_aux_dir}config.sub" $host_alias` ||
3282 as_fn_error $? "$SHELL ${ac_aux_dir}config.sub $host_alias failed" "$LINENO" 5
3283fi
3284 ;;
3285esac
3286fi
3287{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3288printf "%s\n" "$ac_cv_host" >&6; }
3289case $ac_cv_host in
3290*-*-*) ;;
3291*) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;;
3292esac
3293host=$ac_cv_host
3294ac_save_IFS=$IFS; IFS='-'
3295set x $ac_cv_host
3296shift
3297host_cpu=$1
3298host_vendor=$2
3299shift; shift
3300# Remember, the first character of IFS is used to create $*,
3301# except with old shells:
3302host_os=$*
3303IFS=$ac_save_IFS
3304case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3305
3306
3307
3308
3309opt_bash_malloc=yes
3310opt_afs=no
3311opt_curses=no
3312opt_with_installed_readline=no
3313
3314#htmldir=
3315
3316case "${host_cpu}-${host_os}" in
3317# mostly obsolete platforms
3318alpha*-*) opt_bash_malloc=no ;; # alpha running osf/1 or linux
3319*[Cc]ray*-*) opt_bash_malloc=no ;; # Crays
3320*-osf1*) opt_bash_malloc=no ;; # other osf/1 machines
3321*-dgux*) opt_bash_malloc=no ;; # DG/UX machines
3322sparc-svr4*) opt_bash_malloc=no ;; # sparc SVR4, SVR4.2
3323m68k-sysv) opt_bash_malloc=no ;; # fixes file descriptor leak in closedir
3324*-bsdi2.1|*-bsdi3.?) opt_bash_malloc=no ; : ${CC:=shlicc2} ;; # for loadable builtins
3325*-opennt*|*-interix*) opt_bash_malloc=no ;; # Interix, now owned by Microsoft
3326*-beos*) opt_bash_malloc=no ;; # they say it's suitable
3327# These need additional investigation
3328sparc-linux*) opt_bash_malloc=no ;; # sparc running linux; requires ELF
3329*-aix*) opt_bash_malloc=no ;; # AIX machines
3330*-cygwin*|msys*) opt_bash_malloc=no ;; # Cygnus's CYGWIN environment
3331# These lack a working sbrk(2)
3332aarch64-freebsd*) opt_bash_malloc=no ;;
3333riscv*-freebsd*) opt_bash_malloc=no ;;
3334# Mach-derived systems have a ton of extra malloc functions and lack sbrk(2)
3335*-nextstep*) opt_bash_malloc=no ;; # NeXT machines running NeXTstep
3336*-openstep*) opt_bash_malloc=no ;; # i386/Sparc/HP machines running Openstep
3337*-macos*) opt_bash_malloc=no ;; # Apple MacOS X
3338*-rhapsody*) opt_bash_malloc=no ;; # Apple Rhapsody (MacOS X)
3339*-darwin*) opt_bash_malloc=no ;; # Apple Darwin (MacOS X)
3340*-machten4) opt_bash_malloc=no ;; # MachTen 4.x
3341# Niche or non-mainstream-shell-user systems
3342*-qnx*) opt_bash_malloc=no ;; # QNX 4.2, QNX [67].x
3343*-nsk*) opt_bash_malloc=no ;; # HP NonStop
3344*-haiku*) opt_bash_malloc=no ;; # Haiku OS
3345*-genode*) opt_bash_malloc=no ;; # Genode has no sbrk
3346i370-openedition*) opt_bash_malloc=no LOCAL_LIBS=-lzoslib LIBS_FOR_BUILD=-lzoslib ;; # IBM z/OS machines
3347i370-*) opt_bash_malloc=no ;; # generic (?) IBM 370 machines
3348esac
3349
3350# memory scrambling on free()
3351case "${host_os}" in
3352sco3.2v5*|sco3.2v4*) opt_memscramble=no ;;
3353*) opt_memscramble=yes ;;
3354esac
3355
3356
3357
3358
3359# Check whether --with-afs was given.
3360if test ${with_afs+y}
3361then :
3362 withval=$with_afs; opt_afs=$withval
3363fi
3364
3365
3366# Check whether --with-bash-malloc was given.
3367if test ${with_bash_malloc+y}
3368then :
3369 withval=$with_bash_malloc; opt_bash_malloc=$withval
3370fi
3371
3372
3373# Check whether --with-curses was given.
3374if test ${with_curses+y}
3375then :
3376 withval=$with_curses; opt_curses=$withval
3377fi
3378
3379
3380# Check whether --with-gnu-malloc was given.
3381if test ${with_gnu_malloc+y}
3382then :
3383 withval=$with_gnu_malloc; opt_bash_malloc=$withval
3384fi
3385
3386
3387# Check whether --with-installed-readline was given.
3388if test ${with_installed_readline+y}
3389then :
3390 withval=$with_installed_readline; opt_with_installed_readline=$withval
3391fi
3392
3393
3394if test "$opt_bash_malloc" = yes; then
3395 MALLOC_TARGET=malloc
3396 MALLOC_SRC=malloc.c
3397
3398 MALLOC_LIB='-lmalloc'
3399 MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a'
3400 MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)'
3401 MALLOC_DEP='$(MALLOC_LIBRARY)'
3402
3403 printf "%s\n" "#define USING_BASH_MALLOC 1" >>confdefs.h
3404
3405else
3406 MALLOC_LIB=
3407 MALLOC_LIBRARY=
3408 MALLOC_LDFLAGS=
3409 MALLOC_DEP=
3410fi
3411
3412if test "$opt_afs" = yes; then
3413 printf "%s\n" "#define AFS 1" >>confdefs.h
3414
3415fi
3416
3417if test "$opt_curses" = yes; then
3418 prefer_curses=yes
3419fi
3420
3421if test -z "${DEBUGGER_START_FILE}"; then
3422 DEBUGGER_START_FILE='${datadir}/bashdb/bashdb-main.inc'
3423fi
3424
3425opt_minimal_config=no
3426
3427opt_job_control=yes
3428opt_alias=yes
3429opt_readline=yes
3430opt_history=yes
3431opt_bang_history=yes
3432opt_dirstack=yes
3433opt_restricted=yes
3434opt_process_subst=yes
3435opt_prompt_decoding=yes
3436opt_select=yes
3437opt_help=yes
3438opt_array_variables=yes
3439opt_dparen_arith=yes
3440opt_extended_glob=yes
3441opt_brace_expansion=yes
3442opt_disabled_builtins=no
3443opt_command_timing=yes
3444opt_xpg_echo=no
3445opt_strict_posix=no
3446opt_cond_command=yes
3447opt_cond_regexp=yes
3448opt_coproc=yes
3449opt_arith_for_command=yes
3450opt_net_redirs=yes
3451opt_progcomp=yes
3452opt_separate_help=no
3453opt_multibyte=yes
3454opt_debugger=yes
3455opt_single_longdoc_strings=yes
3456opt_casemod_attrs=yes
3457opt_casemod_expansions=yes
3458opt_extglob_default=no
3459opt_dircomplete_expand_default=no
3460opt_globascii_default=yes
3461opt_function_import=yes
3462opt_dev_fd_stat_broken=no
3463opt_alt_array_impl=no
3464opt_translatable_strings=yes
3465opt_bash_source_fullpath_default=no
3466
3467ARRAY_O=array.o
3468
3469opt_static_link=no
3470opt_profiling=no
3471
3472# Check whether --enable-minimal-config was given.
3473if test ${enable_minimal_config+y}
3474then :
3475 enableval=$enable_minimal_config; opt_minimal_config=$enableval
3476fi
3477
3478
3479if test $opt_minimal_config = yes; then
3480 opt_job_control=no opt_alias=no opt_readline=no
3481 opt_history=no opt_bang_history=no opt_dirstack=no
3482 opt_restricted=no opt_process_subst=no opt_prompt_decoding=no
3483 opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no
3484 opt_brace_expansion=no opt_disabled_builtins=no opt_command_timing=no
3485 opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no
3486 opt_net_redirs=no opt_progcomp=no opt_separate_help=no
3487 opt_multibyte=yes opt_cond_regexp=no opt_coproc=no
3488 opt_casemod_attrs=no opt_casemod_expansions=no opt_extglob_default=no
3489 opt_translatable_strings=no
3490 opt_globascii_default=yes
3491 opt_bash_source_fullpath_default=no
3492fi
3493
3494# Check whether --enable-alias was given.
3495if test ${enable_alias+y}
3496then :
3497 enableval=$enable_alias; opt_alias=$enableval
3498fi
3499
3500# Check whether --enable-alt-array-implementation was given.
3501if test ${enable_alt_array_implementation+y}
3502then :
3503 enableval=$enable_alt_array_implementation; opt_alt_array_impl=$enableval
3504fi
3505
3506# Check whether --enable-arith-for-command was given.
3507if test ${enable_arith_for_command+y}
3508then :
3509 enableval=$enable_arith_for_command; opt_arith_for_command=$enableval
3510fi
3511
3512# Check whether --enable-array-variables was given.
3513if test ${enable_array_variables+y}
3514then :
3515 enableval=$enable_array_variables; opt_array_variables=$enableval
3516fi
3517
3518# Check whether --enable-bang-history was given.
3519if test ${enable_bang_history+y}
3520then :
3521 enableval=$enable_bang_history; opt_bang_history=$enableval
3522fi
3523
3524# Check whether --enable-bash-source-fullpath-default was given.
3525if test ${enable_bash_source_fullpath_default+y}
3526then :
3527 enableval=$enable_bash_source_fullpath_default; opt_bash_source_fullpath_default=$enableval
3528fi
3529
3530# Check whether --enable-brace-expansion was given.
3531if test ${enable_brace_expansion+y}
3532then :
3533 enableval=$enable_brace_expansion; opt_brace_expansion=$enableval
3534fi
3535
3536# Check whether --enable-casemod-attributes was given.
3537if test ${enable_casemod_attributes+y}
3538then :
3539 enableval=$enable_casemod_attributes; opt_casemod_attrs=$enableval
3540fi
3541
3542# Check whether --enable-casemod-expansions was given.
3543if test ${enable_casemod_expansions+y}
3544then :
3545 enableval=$enable_casemod_expansions; opt_casemod_expansions=$enableval
3546fi
3547
3548# Check whether --enable-command-timing was given.
3549if test ${enable_command_timing+y}
3550then :
3551 enableval=$enable_command_timing; opt_command_timing=$enableval
3552fi
3553
3554# Check whether --enable-cond-command was given.
3555if test ${enable_cond_command+y}
3556then :
3557 enableval=$enable_cond_command; opt_cond_command=$enableval
3558fi
3559
3560# Check whether --enable-cond-regexp was given.
3561if test ${enable_cond_regexp+y}
3562then :
3563 enableval=$enable_cond_regexp; opt_cond_regexp=$enableval
3564fi
3565
3566# Check whether --enable-coprocesses was given.
3567if test ${enable_coprocesses+y}
3568then :
3569 enableval=$enable_coprocesses; opt_coproc=$enableval
3570fi
3571
3572# Check whether --enable-debugger was given.
3573if test ${enable_debugger+y}
3574then :
3575 enableval=$enable_debugger; opt_debugger=$enableval
3576fi
3577
3578# Check whether --enable-dev-fd-stat-broken was given.
3579if test ${enable_dev_fd_stat_broken+y}
3580then :
3581 enableval=$enable_dev_fd_stat_broken; opt_dev_fd_stat_broken=$enableval
3582fi
3583
3584# Check whether --enable-direxpand-default was given.
3585if test ${enable_direxpand_default+y}
3586then :
3587 enableval=$enable_direxpand_default; opt_dircomplete_expand_default=$enableval
3588fi
3589
3590# Check whether --enable-directory-stack was given.
3591if test ${enable_directory_stack+y}
3592then :
3593 enableval=$enable_directory_stack; opt_dirstack=$enableval
3594fi
3595
3596# Check whether --enable-disabled-builtins was given.
3597if test ${enable_disabled_builtins+y}
3598then :
3599 enableval=$enable_disabled_builtins; opt_disabled_builtins=$enableval
3600fi
3601
3602# Check whether --enable-dparen-arithmetic was given.
3603if test ${enable_dparen_arithmetic+y}
3604then :
3605 enableval=$enable_dparen_arithmetic; opt_dparen_arith=$enableval
3606fi
3607
3608# Check whether --enable-extended-glob was given.
3609if test ${enable_extended_glob+y}
3610then :
3611 enableval=$enable_extended_glob; opt_extended_glob=$enableval
3612fi
3613
3614# Check whether --enable-extended-glob-default was given.
3615if test ${enable_extended_glob_default+y}
3616then :
3617 enableval=$enable_extended_glob_default; opt_extglob_default=$enableval
3618fi
3619
3620# Check whether --enable-function-import was given.
3621if test ${enable_function_import+y}
3622then :
3623 enableval=$enable_function_import; opt_function_import=$enableval
3624fi
3625
3626# Check whether --enable-glob-asciiranges-default was given.
3627if test ${enable_glob_asciiranges_default+y}
3628then :
3629 enableval=$enable_glob_asciiranges_default; opt_globascii_default=$enableval
3630fi
3631
3632# Check whether --enable-help-builtin was given.
3633if test ${enable_help_builtin+y}
3634then :
3635 enableval=$enable_help_builtin; opt_help=$enableval
3636fi
3637
3638# Check whether --enable-history was given.
3639if test ${enable_history+y}
3640then :
3641 enableval=$enable_history; opt_history=$enableval
3642fi
3643
3644# Check whether --enable-job-control was given.
3645if test ${enable_job_control+y}
3646then :
3647 enableval=$enable_job_control; opt_job_control=$enableval
3648fi
3649
3650# Check whether --enable-multibyte was given.
3651if test ${enable_multibyte+y}
3652then :
3653 enableval=$enable_multibyte; opt_multibyte=$enableval
3654fi
3655
3656# Check whether --enable-net-redirections was given.
3657if test ${enable_net_redirections+y}
3658then :
3659 enableval=$enable_net_redirections; opt_net_redirs=$enableval
3660fi
3661
3662# Check whether --enable-process-substitution was given.
3663if test ${enable_process_substitution+y}
3664then :
3665 enableval=$enable_process_substitution; opt_process_subst=$enableval
3666fi
3667
3668# Check whether --enable-progcomp was given.
3669if test ${enable_progcomp+y}
3670then :
3671 enableval=$enable_progcomp; opt_progcomp=$enableval
3672fi
3673
3674# Check whether --enable-prompt-string-decoding was given.
3675if test ${enable_prompt_string_decoding+y}
3676then :
3677 enableval=$enable_prompt_string_decoding; opt_prompt_decoding=$enableval
3678fi
3679
3680# Check whether --enable-readline was given.
3681if test ${enable_readline+y}
3682then :
3683 enableval=$enable_readline; opt_readline=$enableval
3684fi
3685
3686# Check whether --enable-restricted was given.
3687if test ${enable_restricted+y}
3688then :
3689 enableval=$enable_restricted; opt_restricted=$enableval
3690fi
3691
3692# Check whether --enable-select was given.
3693if test ${enable_select+y}
3694then :
3695 enableval=$enable_select; opt_select=$enableval
3696fi
3697
3698# Check whether --enable-separate-helpfiles was given.
3699if test ${enable_separate_helpfiles+y}
3700then :
3701 enableval=$enable_separate_helpfiles; opt_separate_help=$enableval
3702fi
3703
3704# Check whether --enable-single-help-strings was given.
3705if test ${enable_single_help_strings+y}
3706then :
3707 enableval=$enable_single_help_strings; opt_single_longdoc_strings=$enableval
3708fi
3709
3710# Check whether --enable-strict-posix-default was given.
3711if test ${enable_strict_posix_default+y}
3712then :
3713 enableval=$enable_strict_posix_default; opt_strict_posix=$enableval
3714fi
3715
3716# Check whether --enable-translatable-strings was given.
3717if test ${enable_translatable_strings+y}
3718then :
3719 enableval=$enable_translatable_strings; opt_translatable_strings=$enableval
3720fi
3721
3722# Check whether --enable-usg-echo-default was given.
3723if test ${enable_usg_echo_default+y}
3724then :
3725 enableval=$enable_usg_echo_default; opt_xpg_echo=$enableval
3726fi
3727
3728# Check whether --enable-xpg-echo-default was given.
3729if test ${enable_xpg_echo_default+y}
3730then :
3731 enableval=$enable_xpg_echo_default; opt_xpg_echo=$enableval
3732fi
3733
3734
3735# Check whether --enable-mem-scramble was given.
3736if test ${enable_mem_scramble+y}
3737then :
3738 enableval=$enable_mem_scramble; opt_memscramble=$enableval
3739fi
3740
3741# Check whether --enable-profiling was given.
3742if test ${enable_profiling+y}
3743then :
3744 enableval=$enable_profiling; opt_profiling=$enableval
3745fi
3746
3747# Check whether --enable-static-link was given.
3748if test ${enable_static_link+y}
3749then :
3750 enableval=$enable_static_link; opt_static_link=$enableval
3751fi
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761if test $opt_alias = yes; then
3762printf "%s\n" "#define ALIAS 1" >>confdefs.h
3763
3764fi
3765if test $opt_dirstack = yes; then
3766printf "%s\n" "#define PUSHD_AND_POPD 1" >>confdefs.h
3767
3768fi
3769if test $opt_restricted = yes; then
3770printf "%s\n" "#define RESTRICTED_SHELL 1" >>confdefs.h
3771
3772fi
3773if test $opt_process_subst = yes; then
3774printf "%s\n" "#define PROCESS_SUBSTITUTION 1" >>confdefs.h
3775
3776fi
3777if test $opt_prompt_decoding = yes; then
3778printf "%s\n" "#define PROMPT_STRING_DECODE 1" >>confdefs.h
3779
3780fi
3781if test $opt_select = yes; then
3782printf "%s\n" "#define SELECT_COMMAND 1" >>confdefs.h
3783
3784fi
3785if test $opt_help = yes; then
3786printf "%s\n" "#define HELP_BUILTIN 1" >>confdefs.h
3787
3788fi
3789if test $opt_array_variables = yes; then
3790printf "%s\n" "#define ARRAY_VARS 1" >>confdefs.h
3791
3792fi
3793if test $opt_dparen_arith = yes; then
3794printf "%s\n" "#define DPAREN_ARITHMETIC 1" >>confdefs.h
3795
3796fi
3797if test $opt_brace_expansion = yes; then
3798printf "%s\n" "#define BRACE_EXPANSION 1" >>confdefs.h
3799
3800fi
3801if test $opt_disabled_builtins = yes; then
3802printf "%s\n" "#define DISABLED_BUILTINS 1" >>confdefs.h
3803
3804fi
3805if test $opt_command_timing = yes; then
3806printf "%s\n" "#define COMMAND_TIMING 1" >>confdefs.h
3807
3808fi
3809if test $opt_xpg_echo = yes ; then
3810printf "%s\n" "#define DEFAULT_ECHO_TO_XPG 1" >>confdefs.h
3811
3812fi
3813if test $opt_strict_posix = yes; then
3814printf "%s\n" "#define STRICT_POSIX 1" >>confdefs.h
3815
3816fi
3817if test $opt_extended_glob = yes ; then
3818printf "%s\n" "#define EXTENDED_GLOB 1" >>confdefs.h
3819
3820fi
3821if test $opt_extglob_default = yes; then
3822printf "%s\n" "#define EXTGLOB_DEFAULT 1" >>confdefs.h
3823
3824else
3825printf "%s\n" "#define EXTGLOB_DEFAULT 0" >>confdefs.h
3826
3827fi
3828if test $opt_cond_command = yes ; then
3829printf "%s\n" "#define COND_COMMAND 1" >>confdefs.h
3830
3831fi
3832if test $opt_cond_regexp = yes ; then
3833printf "%s\n" "#define COND_REGEXP 1" >>confdefs.h
3834
3835fi
3836if test $opt_coproc = yes; then
3837printf "%s\n" "#define COPROCESS_SUPPORT 1" >>confdefs.h
3838
3839fi
3840if test $opt_arith_for_command = yes; then
3841printf "%s\n" "#define ARITH_FOR_COMMAND 1" >>confdefs.h
3842
3843fi
3844if test $opt_net_redirs = yes; then
3845printf "%s\n" "#define NETWORK_REDIRECTIONS 1" >>confdefs.h
3846
3847fi
3848if test $opt_progcomp = yes; then
3849printf "%s\n" "#define PROGRAMMABLE_COMPLETION 1" >>confdefs.h
3850
3851fi
3852if test $opt_multibyte = no; then
3853printf "%s\n" "#define NO_MULTIBYTE_SUPPORT 1" >>confdefs.h
3854
3855fi
3856if test $opt_debugger = yes; then
3857printf "%s\n" "#define DEBUGGER 1" >>confdefs.h
3858
3859fi
3860if test $opt_casemod_attrs = yes; then
3861printf "%s\n" "#define CASEMOD_ATTRS 1" >>confdefs.h
3862
3863fi
3864if test $opt_casemod_expansions = yes; then
3865printf "%s\n" "#define CASEMOD_EXPANSIONS 1" >>confdefs.h
3866
3867fi
3868if test $opt_dircomplete_expand_default = yes; then
3869printf "%s\n" "#define DIRCOMPLETE_EXPAND_DEFAULT 1" >>confdefs.h
3870
3871fi
3872if test $opt_globascii_default = yes; then
3873printf "%s\n" "#define GLOBASCII_DEFAULT 1" >>confdefs.h
3874
3875else
3876printf "%s\n" "#define GLOBASCII_DEFAULT 0" >>confdefs.h
3877
3878fi
3879if test $opt_function_import = yes; then
3880printf "%s\n" "#define FUNCTION_IMPORT 1" >>confdefs.h
3881
3882fi
3883if test $opt_dev_fd_stat_broken = yes; then
3884printf "%s\n" "#define DEV_FD_STAT_BROKEN 1" >>confdefs.h
3885
3886fi
3887if test $opt_alt_array_impl = yes; then
3888printf "%s\n" "#define ALT_ARRAY_IMPLEMENTATION 1" >>confdefs.h
3889
3890ARRAY_O=array2.o
3891fi
3892if test $opt_translatable_strings = yes; then
3893printf "%s\n" "#define TRANSLATABLE_STRINGS 1" >>confdefs.h
3894
3895fi
3896if test $opt_bash_source_fullpath_default = yes; then
3897printf "%s\n" "#define BASH_SOURCE_FULLPATH_DEFAULT 1" >>confdefs.h
3898
3899else
3900printf "%s\n" "#define BASH_SOURCE_FULLPATH_DEFAULT 0" >>confdefs.h
3901
3902fi
3903
3904if test $opt_memscramble = yes; then
3905printf "%s\n" "#define MEMSCRAMBLE 1" >>confdefs.h
3906
3907fi
3908
3909if test "$opt_minimal_config" = yes; then
3910 TESTSCRIPT=run-minimal
3911else
3912 TESTSCRIPT=run-all
3913fi
3914
3915HELPDIR= HELPDIRDEFINE= HELPINSTALL= HELPFILES_TARGET=
3916if test "$opt_separate_help" != no; then
3917 if test "$opt_separate_help" = "yes" ; then
3918 HELPDIR='${datadir}/bash/helpfiles'
3919 else
3920 HELPDIR=$opt_separate_help
3921 fi
3922 HELPDIRDEFINE='-H ${HELPDIR}'
3923 HELPINSTALL='install-help'
3924 HELPFILES_TARGET='helpdoc'
3925fi
3926HELPSTRINGS=
3927if test "$opt_single_longdoc_strings" != "yes"; then
3928 HELPSTRINGS='-S'
3929fi
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950if test -z "$CFLAGS"; then
3951 want_auto_cflags=1
3952fi
3953
3954echo ""
3955echo "Beginning configuration for bash-$BASHVERS-$RELSTATUS for ${host_cpu}-${host_vendor}-${host_os}"
3956echo ""
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967ac_ext=c
3968ac_cpp='$CPP $CPPFLAGS'
3969ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3970ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3971ac_compiler_gnu=$ac_cv_c_compiler_gnu
3972if test -n "$ac_tool_prefix"; then
3973 # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
3974set dummy ${ac_tool_prefix}gcc; ac_word=$2
3975{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
3976printf %s "checking for $ac_word... " >&6; }
3977if test ${ac_cv_prog_CC+y}
3978then :
3979 printf %s "(cached) " >&6
3980else case e in #(
3981 e) if test -n "$CC"; then
3982 ac_cv_prog_CC="$CC" # Let the user override the test.
3983else
3984as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3985for as_dir in $PATH
3986do
3987 IFS=$as_save_IFS
3988 case $as_dir in #(((
3989 '') as_dir=./ ;;
3990 */) ;;
3991 *) as_dir=$as_dir/ ;;
3992 esac
3993 for ac_exec_ext in '' $ac_executable_extensions; do
3994 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
3995 ac_cv_prog_CC="${ac_tool_prefix}gcc"
3996 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
3997 break 2
3998 fi
3999done
4000 done
4001IFS=$as_save_IFS
4002
4003fi ;;
4004esac
4005fi
4006CC=$ac_cv_prog_CC
4007if test -n "$CC"; then
4008 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4009printf "%s\n" "$CC" >&6; }
4010else
4011 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4012printf "%s\n" "no" >&6; }
4013fi
4014
4015
4016fi
4017if test -z "$ac_cv_prog_CC"; then
4018 ac_ct_CC=$CC
4019 # Extract the first word of "gcc", so it can be a program name with args.
4020set dummy gcc; ac_word=$2
4021{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4022printf %s "checking for $ac_word... " >&6; }
4023if test ${ac_cv_prog_ac_ct_CC+y}
4024then :
4025 printf %s "(cached) " >&6
4026else case e in #(
4027 e) if test -n "$ac_ct_CC"; then
4028 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4029else
4030as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4031for as_dir in $PATH
4032do
4033 IFS=$as_save_IFS
4034 case $as_dir in #(((
4035 '') as_dir=./ ;;
4036 */) ;;
4037 *) as_dir=$as_dir/ ;;
4038 esac
4039 for ac_exec_ext in '' $ac_executable_extensions; do
4040 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4041 ac_cv_prog_ac_ct_CC="gcc"
4042 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4043 break 2
4044 fi
4045done
4046 done
4047IFS=$as_save_IFS
4048
4049fi ;;
4050esac
4051fi
4052ac_ct_CC=$ac_cv_prog_ac_ct_CC
4053if test -n "$ac_ct_CC"; then
4054 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4055printf "%s\n" "$ac_ct_CC" >&6; }
4056else
4057 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4058printf "%s\n" "no" >&6; }
4059fi
4060
4061 if test "x$ac_ct_CC" = x; then
4062 CC=""
4063 else
4064 case $cross_compiling:$ac_tool_warned in
4065yes:)
4066{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4067printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4068ac_tool_warned=yes ;;
4069esac
4070 CC=$ac_ct_CC
4071 fi
4072else
4073 CC="$ac_cv_prog_CC"
4074fi
4075
4076if test -z "$CC"; then
4077 if test -n "$ac_tool_prefix"; then
4078 # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
4079set dummy ${ac_tool_prefix}cc; ac_word=$2
4080{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4081printf %s "checking for $ac_word... " >&6; }
4082if test ${ac_cv_prog_CC+y}
4083then :
4084 printf %s "(cached) " >&6
4085else case e in #(
4086 e) if test -n "$CC"; then
4087 ac_cv_prog_CC="$CC" # Let the user override the test.
4088else
4089as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4090for as_dir in $PATH
4091do
4092 IFS=$as_save_IFS
4093 case $as_dir in #(((
4094 '') as_dir=./ ;;
4095 */) ;;
4096 *) as_dir=$as_dir/ ;;
4097 esac
4098 for ac_exec_ext in '' $ac_executable_extensions; do
4099 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4100 ac_cv_prog_CC="${ac_tool_prefix}cc"
4101 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4102 break 2
4103 fi
4104done
4105 done
4106IFS=$as_save_IFS
4107
4108fi ;;
4109esac
4110fi
4111CC=$ac_cv_prog_CC
4112if test -n "$CC"; then
4113 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4114printf "%s\n" "$CC" >&6; }
4115else
4116 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4117printf "%s\n" "no" >&6; }
4118fi
4119
4120
4121 fi
4122fi
4123if test -z "$CC"; then
4124 # Extract the first word of "cc", so it can be a program name with args.
4125set dummy cc; ac_word=$2
4126{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4127printf %s "checking for $ac_word... " >&6; }
4128if test ${ac_cv_prog_CC+y}
4129then :
4130 printf %s "(cached) " >&6
4131else case e in #(
4132 e) if test -n "$CC"; then
4133 ac_cv_prog_CC="$CC" # Let the user override the test.
4134else
4135 ac_prog_rejected=no
4136as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4137for as_dir in $PATH
4138do
4139 IFS=$as_save_IFS
4140 case $as_dir in #(((
4141 '') as_dir=./ ;;
4142 */) ;;
4143 *) as_dir=$as_dir/ ;;
4144 esac
4145 for ac_exec_ext in '' $ac_executable_extensions; do
4146 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4147 if test "$as_dir$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
4148 ac_prog_rejected=yes
4149 continue
4150 fi
4151 ac_cv_prog_CC="cc"
4152 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4153 break 2
4154 fi
4155done
4156 done
4157IFS=$as_save_IFS
4158
4159if test $ac_prog_rejected = yes; then
4160 # We found a bogon in the path, so make sure we never use it.
4161 set dummy $ac_cv_prog_CC
4162 shift
4163 if test $# != 0; then
4164 # We chose a different compiler from the bogus one.
4165 # However, it has the same basename, so the bogon will be chosen
4166 # first if we set CC to just the basename; use the full file name.
4167 shift
4168 ac_cv_prog_CC="$as_dir$ac_word${1+' '}$@"
4169 fi
4170fi
4171fi ;;
4172esac
4173fi
4174CC=$ac_cv_prog_CC
4175if test -n "$CC"; then
4176 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4177printf "%s\n" "$CC" >&6; }
4178else
4179 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4180printf "%s\n" "no" >&6; }
4181fi
4182
4183
4184fi
4185if test -z "$CC"; then
4186 if test -n "$ac_tool_prefix"; then
4187 for ac_prog in cl.exe
4188 do
4189 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
4190set dummy $ac_tool_prefix$ac_prog; ac_word=$2
4191{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4192printf %s "checking for $ac_word... " >&6; }
4193if test ${ac_cv_prog_CC+y}
4194then :
4195 printf %s "(cached) " >&6
4196else case e in #(
4197 e) if test -n "$CC"; then
4198 ac_cv_prog_CC="$CC" # Let the user override the test.
4199else
4200as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4201for as_dir in $PATH
4202do
4203 IFS=$as_save_IFS
4204 case $as_dir in #(((
4205 '') as_dir=./ ;;
4206 */) ;;
4207 *) as_dir=$as_dir/ ;;
4208 esac
4209 for ac_exec_ext in '' $ac_executable_extensions; do
4210 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4211 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
4212 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4213 break 2
4214 fi
4215done
4216 done
4217IFS=$as_save_IFS
4218
4219fi ;;
4220esac
4221fi
4222CC=$ac_cv_prog_CC
4223if test -n "$CC"; then
4224 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4225printf "%s\n" "$CC" >&6; }
4226else
4227 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4228printf "%s\n" "no" >&6; }
4229fi
4230
4231
4232 test -n "$CC" && break
4233 done
4234fi
4235if test -z "$CC"; then
4236 ac_ct_CC=$CC
4237 for ac_prog in cl.exe
4238do
4239 # Extract the first word of "$ac_prog", so it can be a program name with args.
4240set dummy $ac_prog; ac_word=$2
4241{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4242printf %s "checking for $ac_word... " >&6; }
4243if test ${ac_cv_prog_ac_ct_CC+y}
4244then :
4245 printf %s "(cached) " >&6
4246else case e in #(
4247 e) if test -n "$ac_ct_CC"; then
4248 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4249else
4250as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4251for as_dir in $PATH
4252do
4253 IFS=$as_save_IFS
4254 case $as_dir in #(((
4255 '') as_dir=./ ;;
4256 */) ;;
4257 *) as_dir=$as_dir/ ;;
4258 esac
4259 for ac_exec_ext in '' $ac_executable_extensions; do
4260 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4261 ac_cv_prog_ac_ct_CC="$ac_prog"
4262 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4263 break 2
4264 fi
4265done
4266 done
4267IFS=$as_save_IFS
4268
4269fi ;;
4270esac
4271fi
4272ac_ct_CC=$ac_cv_prog_ac_ct_CC
4273if test -n "$ac_ct_CC"; then
4274 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4275printf "%s\n" "$ac_ct_CC" >&6; }
4276else
4277 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4278printf "%s\n" "no" >&6; }
4279fi
4280
4281
4282 test -n "$ac_ct_CC" && break
4283done
4284
4285 if test "x$ac_ct_CC" = x; then
4286 CC=""
4287 else
4288 case $cross_compiling:$ac_tool_warned in
4289yes:)
4290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4291printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4292ac_tool_warned=yes ;;
4293esac
4294 CC=$ac_ct_CC
4295 fi
4296fi
4297
4298fi
4299if test -z "$CC"; then
4300 if test -n "$ac_tool_prefix"; then
4301 # Extract the first word of "${ac_tool_prefix}clang", so it can be a program name with args.
4302set dummy ${ac_tool_prefix}clang; ac_word=$2
4303{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4304printf %s "checking for $ac_word... " >&6; }
4305if test ${ac_cv_prog_CC+y}
4306then :
4307 printf %s "(cached) " >&6
4308else case e in #(
4309 e) if test -n "$CC"; then
4310 ac_cv_prog_CC="$CC" # Let the user override the test.
4311else
4312as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4313for as_dir in $PATH
4314do
4315 IFS=$as_save_IFS
4316 case $as_dir in #(((
4317 '') as_dir=./ ;;
4318 */) ;;
4319 *) as_dir=$as_dir/ ;;
4320 esac
4321 for ac_exec_ext in '' $ac_executable_extensions; do
4322 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4323 ac_cv_prog_CC="${ac_tool_prefix}clang"
4324 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4325 break 2
4326 fi
4327done
4328 done
4329IFS=$as_save_IFS
4330
4331fi ;;
4332esac
4333fi
4334CC=$ac_cv_prog_CC
4335if test -n "$CC"; then
4336 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
4337printf "%s\n" "$CC" >&6; }
4338else
4339 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4340printf "%s\n" "no" >&6; }
4341fi
4342
4343
4344fi
4345if test -z "$ac_cv_prog_CC"; then
4346 ac_ct_CC=$CC
4347 # Extract the first word of "clang", so it can be a program name with args.
4348set dummy clang; ac_word=$2
4349{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4350printf %s "checking for $ac_word... " >&6; }
4351if test ${ac_cv_prog_ac_ct_CC+y}
4352then :
4353 printf %s "(cached) " >&6
4354else case e in #(
4355 e) if test -n "$ac_ct_CC"; then
4356 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
4357else
4358as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4359for as_dir in $PATH
4360do
4361 IFS=$as_save_IFS
4362 case $as_dir in #(((
4363 '') as_dir=./ ;;
4364 */) ;;
4365 *) as_dir=$as_dir/ ;;
4366 esac
4367 for ac_exec_ext in '' $ac_executable_extensions; do
4368 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4369 ac_cv_prog_ac_ct_CC="clang"
4370 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4371 break 2
4372 fi
4373done
4374 done
4375IFS=$as_save_IFS
4376
4377fi ;;
4378esac
4379fi
4380ac_ct_CC=$ac_cv_prog_ac_ct_CC
4381if test -n "$ac_ct_CC"; then
4382 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
4383printf "%s\n" "$ac_ct_CC" >&6; }
4384else
4385 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4386printf "%s\n" "no" >&6; }
4387fi
4388
4389 if test "x$ac_ct_CC" = x; then
4390 CC=""
4391 else
4392 case $cross_compiling:$ac_tool_warned in
4393yes:)
4394{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4395printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4396ac_tool_warned=yes ;;
4397esac
4398 CC=$ac_ct_CC
4399 fi
4400else
4401 CC="$ac_cv_prog_CC"
4402fi
4403
4404fi
4405
4406
4407test -z "$CC" && { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
4408printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
4409as_fn_error $? "no acceptable C compiler found in \$PATH
4410See 'config.log' for more details" "$LINENO" 5; }
4411
4412# Provide some information about the compiler.
4413printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
4414set X $ac_compile
4415ac_compiler=$2
4416for ac_option in --version -v -V -qversion -version; do
4417 { { ac_try="$ac_compiler $ac_option >&5"
4418case "(($ac_try" in
4419 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4420 *) ac_try_echo=$ac_try;;
4421esac
4422eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4423printf "%s\n" "$ac_try_echo"; } >&5
4424 (eval "$ac_compiler $ac_option >&5") 2>conftest.err
4425 ac_status=$?
4426 if test -s conftest.err; then
4427 sed '10a\
4428... rest of stderr output deleted ...
4429 10q' conftest.err >conftest.er1
4430 cat conftest.er1 >&5
4431 fi
4432 rm -f conftest.er1 conftest.err
4433 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4434 test $ac_status = 0; }
4435done
4436
4437cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4438/* end confdefs.h. */
4439
4440int
4441main (void)
4442{
4443
4444 ;
4445 return 0;
4446}
4447_ACEOF
4448ac_clean_files_save=$ac_clean_files
4449ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
4450# Try to create an executable without -o first, disregard a.out.
4451# It will help us diagnose broken compilers, and finding out an intuition
4452# of exeext.
4453{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
4454printf %s "checking whether the C compiler works... " >&6; }
4455ac_link_default=`printf "%s\n" "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
4456
4457# The possible output files:
4458ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
4459
4460ac_rmfiles=
4461for ac_file in $ac_files
4462do
4463 case $ac_file in
4464 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4465 * ) ac_rmfiles="$ac_rmfiles $ac_file";;
4466 esac
4467done
4468rm -f $ac_rmfiles
4469
4470if { { ac_try="$ac_link_default"
4471case "(($ac_try" in
4472 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4473 *) ac_try_echo=$ac_try;;
4474esac
4475eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4476printf "%s\n" "$ac_try_echo"; } >&5
4477 (eval "$ac_link_default") 2>&5
4478 ac_status=$?
4479 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4480 test $ac_status = 0; }
4481then :
4482 # Autoconf-2.13 could set the ac_cv_exeext variable to 'no'.
4483# So ignore a value of 'no', otherwise this would lead to 'EXEEXT = no'
4484# in a Makefile. We should not override ac_cv_exeext if it was cached,
4485# so that the user can short-circuit this test for compilers unknown to
4486# Autoconf.
4487for ac_file in $ac_files ''
4488do
4489 test -f "$ac_file" || continue
4490 case $ac_file in
4491 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
4492 ;;
4493 [ab].out )
4494 # We found the default executable, but exeext='' is most
4495 # certainly right.
4496 break;;
4497 *.* )
4498 if test ${ac_cv_exeext+y} && test "$ac_cv_exeext" != no;
4499 then :; else
4500 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4501 fi
4502 # We set ac_cv_exeext here because the later test for it is not
4503 # safe: cross compilers may not add the suffix if given an '-o'
4504 # argument, so we may need to know it at that point already.
4505 # Even if this section looks crufty: it has the advantage of
4506 # actually working.
4507 break;;
4508 * )
4509 break;;
4510 esac
4511done
4512test "$ac_cv_exeext" = no && ac_cv_exeext=
4513
4514else case e in #(
4515 e) ac_file='' ;;
4516esac
4517fi
4518if test -z "$ac_file"
4519then :
4520 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4521printf "%s\n" "no" >&6; }
4522printf "%s\n" "$as_me: failed program was:" >&5
4523sed 's/^/| /' conftest.$ac_ext >&5
4524
4525{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
4526printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
4527as_fn_error 77 "C compiler cannot create executables
4528See 'config.log' for more details" "$LINENO" 5; }
4529else case e in #(
4530 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
4531printf "%s\n" "yes" >&6; } ;;
4532esac
4533fi
4534{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
4535printf %s "checking for C compiler default output file name... " >&6; }
4536{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
4537printf "%s\n" "$ac_file" >&6; }
4538ac_exeext=$ac_cv_exeext
4539
4540rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
4541ac_clean_files=$ac_clean_files_save
4542{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
4543printf %s "checking for suffix of executables... " >&6; }
4544if { { ac_try="$ac_link"
4545case "(($ac_try" in
4546 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4547 *) ac_try_echo=$ac_try;;
4548esac
4549eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4550printf "%s\n" "$ac_try_echo"; } >&5
4551 (eval "$ac_link") 2>&5
4552 ac_status=$?
4553 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4554 test $ac_status = 0; }
4555then :
4556 # If both 'conftest.exe' and 'conftest' are 'present' (well, observable)
4557# catch 'conftest.exe'. For instance with Cygwin, 'ls conftest' will
4558# work properly (i.e., refer to 'conftest.exe'), while it won't with
4559# 'rm'.
4560for ac_file in conftest.exe conftest conftest.*; do
4561 test -f "$ac_file" || continue
4562 case $ac_file in
4563 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
4564 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
4565 break;;
4566 * ) break;;
4567 esac
4568done
4569else case e in #(
4570 e) { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
4571printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
4572as_fn_error $? "cannot compute suffix of executables: cannot compile and link
4573See 'config.log' for more details" "$LINENO" 5; } ;;
4574esac
4575fi
4576rm -f conftest conftest$ac_cv_exeext
4577{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
4578printf "%s\n" "$ac_cv_exeext" >&6; }
4579
4580rm -f conftest.$ac_ext
4581EXEEXT=$ac_cv_exeext
4582ac_exeext=$EXEEXT
4583cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4584/* end confdefs.h. */
4585#include <stdio.h>
4586int
4587main (void)
4588{
4589FILE *f = fopen ("conftest.out", "w");
4590 if (!f)
4591 return 1;
4592 return ferror (f) || fclose (f) != 0;
4593
4594 ;
4595 return 0;
4596}
4597_ACEOF
4598ac_clean_files="$ac_clean_files conftest.out"
4599# Check that the compiler produces executables we can run. If not, either
4600# the compiler is broken, or we cross compile.
4601{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
4602printf %s "checking whether we are cross compiling... " >&6; }
4603if test "$cross_compiling" != yes; then
4604 { { ac_try="$ac_link"
4605case "(($ac_try" in
4606 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4607 *) ac_try_echo=$ac_try;;
4608esac
4609eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4610printf "%s\n" "$ac_try_echo"; } >&5
4611 (eval "$ac_link") 2>&5
4612 ac_status=$?
4613 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4614 test $ac_status = 0; }
4615 if { ac_try='./conftest$ac_cv_exeext'
4616 { { case "(($ac_try" in
4617 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4618 *) ac_try_echo=$ac_try;;
4619esac
4620eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4621printf "%s\n" "$ac_try_echo"; } >&5
4622 (eval "$ac_try") 2>&5
4623 ac_status=$?
4624 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4625 test $ac_status = 0; }; }; then
4626 cross_compiling=no
4627 else
4628 if test "$cross_compiling" = maybe; then
4629 cross_compiling=yes
4630 else
4631 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
4632printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
4633as_fn_error 77 "cannot run C compiled programs.
4634If you meant to cross compile, use '--host'.
4635See 'config.log' for more details" "$LINENO" 5; }
4636 fi
4637 fi
4638fi
4639{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
4640printf "%s\n" "$cross_compiling" >&6; }
4641
4642rm -f conftest.$ac_ext conftest$ac_cv_exeext \
4643 conftest.o conftest.obj conftest.out
4644ac_clean_files=$ac_clean_files_save
4645{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
4646printf %s "checking for suffix of object files... " >&6; }
4647if test ${ac_cv_objext+y}
4648then :
4649 printf %s "(cached) " >&6
4650else case e in #(
4651 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4652/* end confdefs.h. */
4653
4654int
4655main (void)
4656{
4657
4658 ;
4659 return 0;
4660}
4661_ACEOF
4662rm -f conftest.o conftest.obj
4663if { { ac_try="$ac_compile"
4664case "(($ac_try" in
4665 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4666 *) ac_try_echo=$ac_try;;
4667esac
4668eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
4669printf "%s\n" "$ac_try_echo"; } >&5
4670 (eval "$ac_compile") 2>&5
4671 ac_status=$?
4672 printf "%s\n" "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
4673 test $ac_status = 0; }
4674then :
4675 for ac_file in conftest.o conftest.obj conftest.*; do
4676 test -f "$ac_file" || continue;
4677 case $ac_file in
4678 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
4679 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
4680 break;;
4681 esac
4682done
4683else case e in #(
4684 e) printf "%s\n" "$as_me: failed program was:" >&5
4685sed 's/^/| /' conftest.$ac_ext >&5
4686
4687{ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
4688printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
4689as_fn_error $? "cannot compute suffix of object files: cannot compile
4690See 'config.log' for more details" "$LINENO" 5; } ;;
4691esac
4692fi
4693rm -f conftest.$ac_cv_objext conftest.$ac_ext ;;
4694esac
4695fi
4696{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
4697printf "%s\n" "$ac_cv_objext" >&6; }
4698OBJEXT=$ac_cv_objext
4699ac_objext=$OBJEXT
4700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports GNU C" >&5
4701printf %s "checking whether the compiler supports GNU C... " >&6; }
4702if test ${ac_cv_c_compiler_gnu+y}
4703then :
4704 printf %s "(cached) " >&6
4705else case e in #(
4706 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4707/* end confdefs.h. */
4708
4709int
4710main (void)
4711{
4712#ifndef __GNUC__
4713 choke me
4714#endif
4715
4716 ;
4717 return 0;
4718}
4719_ACEOF
4720if ac_fn_c_try_compile "$LINENO"
4721then :
4722 ac_compiler_gnu=yes
4723else case e in #(
4724 e) ac_compiler_gnu=no ;;
4725esac
4726fi
4727rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4728ac_cv_c_compiler_gnu=$ac_compiler_gnu
4729 ;;
4730esac
4731fi
4732{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
4733printf "%s\n" "$ac_cv_c_compiler_gnu" >&6; }
4734ac_compiler_gnu=$ac_cv_c_compiler_gnu
4735
4736if test $ac_compiler_gnu = yes; then
4737 GCC=yes
4738else
4739 GCC=
4740fi
4741ac_test_CFLAGS=${CFLAGS+y}
4742ac_save_CFLAGS=$CFLAGS
4743{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
4744printf %s "checking whether $CC accepts -g... " >&6; }
4745if test ${ac_cv_prog_cc_g+y}
4746then :
4747 printf %s "(cached) " >&6
4748else case e in #(
4749 e) ac_save_c_werror_flag=$ac_c_werror_flag
4750 ac_c_werror_flag=yes
4751 ac_cv_prog_cc_g=no
4752 CFLAGS="-g"
4753 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4754/* end confdefs.h. */
4755
4756int
4757main (void)
4758{
4759
4760 ;
4761 return 0;
4762}
4763_ACEOF
4764if ac_fn_c_try_compile "$LINENO"
4765then :
4766 ac_cv_prog_cc_g=yes
4767else case e in #(
4768 e) CFLAGS=""
4769 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4770/* end confdefs.h. */
4771
4772int
4773main (void)
4774{
4775
4776 ;
4777 return 0;
4778}
4779_ACEOF
4780if ac_fn_c_try_compile "$LINENO"
4781then :
4782
4783else case e in #(
4784 e) ac_c_werror_flag=$ac_save_c_werror_flag
4785 CFLAGS="-g"
4786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4787/* end confdefs.h. */
4788
4789int
4790main (void)
4791{
4792
4793 ;
4794 return 0;
4795}
4796_ACEOF
4797if ac_fn_c_try_compile "$LINENO"
4798then :
4799 ac_cv_prog_cc_g=yes
4800fi
4801rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
4802esac
4803fi
4804rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
4805esac
4806fi
4807rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
4808 ac_c_werror_flag=$ac_save_c_werror_flag ;;
4809esac
4810fi
4811{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
4812printf "%s\n" "$ac_cv_prog_cc_g" >&6; }
4813if test $ac_test_CFLAGS; then
4814 CFLAGS=$ac_save_CFLAGS
4815elif test $ac_cv_prog_cc_g = yes; then
4816 if test "$GCC" = yes; then
4817 CFLAGS="-g -O2"
4818 else
4819 CFLAGS="-g"
4820 fi
4821else
4822 if test "$GCC" = yes; then
4823 CFLAGS="-O2"
4824 else
4825 CFLAGS=
4826 fi
4827fi
4828ac_prog_cc_stdc=no
4829if test x$ac_prog_cc_stdc = xno
4830then :
4831 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C11 features" >&5
4832printf %s "checking for $CC option to enable C11 features... " >&6; }
4833if test ${ac_cv_prog_cc_c11+y}
4834then :
4835 printf %s "(cached) " >&6
4836else case e in #(
4837 e) ac_cv_prog_cc_c11=no
4838ac_save_CC=$CC
4839cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4840/* end confdefs.h. */
4841$ac_c_conftest_c11_program
4842_ACEOF
4843for ac_arg in '' -std=gnu11
4844do
4845 CC="$ac_save_CC $ac_arg"
4846 if ac_fn_c_try_compile "$LINENO"
4847then :
4848 ac_cv_prog_cc_c11=$ac_arg
4849fi
4850rm -f core conftest.err conftest.$ac_objext conftest.beam
4851 test "x$ac_cv_prog_cc_c11" != "xno" && break
4852done
4853rm -f conftest.$ac_ext
4854CC=$ac_save_CC ;;
4855esac
4856fi
4857
4858if test "x$ac_cv_prog_cc_c11" = xno
4859then :
4860 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4861printf "%s\n" "unsupported" >&6; }
4862else case e in #(
4863 e) if test "x$ac_cv_prog_cc_c11" = x
4864then :
4865 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4866printf "%s\n" "none needed" >&6; }
4867else case e in #(
4868 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c11" >&5
4869printf "%s\n" "$ac_cv_prog_cc_c11" >&6; }
4870 CC="$CC $ac_cv_prog_cc_c11" ;;
4871esac
4872fi
4873 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c11
4874 ac_prog_cc_stdc=c11 ;;
4875esac
4876fi
4877fi
4878if test x$ac_prog_cc_stdc = xno
4879then :
4880 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C99 features" >&5
4881printf %s "checking for $CC option to enable C99 features... " >&6; }
4882if test ${ac_cv_prog_cc_c99+y}
4883then :
4884 printf %s "(cached) " >&6
4885else case e in #(
4886 e) ac_cv_prog_cc_c99=no
4887ac_save_CC=$CC
4888cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4889/* end confdefs.h. */
4890$ac_c_conftest_c99_program
4891_ACEOF
4892for ac_arg in '' -std=gnu99 -std=c99 -c99 -qlanglvl=extc1x -qlanglvl=extc99 -AC99 -D_STDC_C99=
4893do
4894 CC="$ac_save_CC $ac_arg"
4895 if ac_fn_c_try_compile "$LINENO"
4896then :
4897 ac_cv_prog_cc_c99=$ac_arg
4898fi
4899rm -f core conftest.err conftest.$ac_objext conftest.beam
4900 test "x$ac_cv_prog_cc_c99" != "xno" && break
4901done
4902rm -f conftest.$ac_ext
4903CC=$ac_save_CC ;;
4904esac
4905fi
4906
4907if test "x$ac_cv_prog_cc_c99" = xno
4908then :
4909 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4910printf "%s\n" "unsupported" >&6; }
4911else case e in #(
4912 e) if test "x$ac_cv_prog_cc_c99" = x
4913then :
4914 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4915printf "%s\n" "none needed" >&6; }
4916else case e in #(
4917 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c99" >&5
4918printf "%s\n" "$ac_cv_prog_cc_c99" >&6; }
4919 CC="$CC $ac_cv_prog_cc_c99" ;;
4920esac
4921fi
4922 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c99
4923 ac_prog_cc_stdc=c99 ;;
4924esac
4925fi
4926fi
4927if test x$ac_prog_cc_stdc = xno
4928then :
4929 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable C89 features" >&5
4930printf %s "checking for $CC option to enable C89 features... " >&6; }
4931if test ${ac_cv_prog_cc_c89+y}
4932then :
4933 printf %s "(cached) " >&6
4934else case e in #(
4935 e) ac_cv_prog_cc_c89=no
4936ac_save_CC=$CC
4937cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4938/* end confdefs.h. */
4939$ac_c_conftest_c89_program
4940_ACEOF
4941for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
4942do
4943 CC="$ac_save_CC $ac_arg"
4944 if ac_fn_c_try_compile "$LINENO"
4945then :
4946 ac_cv_prog_cc_c89=$ac_arg
4947fi
4948rm -f core conftest.err conftest.$ac_objext conftest.beam
4949 test "x$ac_cv_prog_cc_c89" != "xno" && break
4950done
4951rm -f conftest.$ac_ext
4952CC=$ac_save_CC ;;
4953esac
4954fi
4955
4956if test "x$ac_cv_prog_cc_c89" = xno
4957then :
4958 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
4959printf "%s\n" "unsupported" >&6; }
4960else case e in #(
4961 e) if test "x$ac_cv_prog_cc_c89" = x
4962then :
4963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
4964printf "%s\n" "none needed" >&6; }
4965else case e in #(
4966 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
4967printf "%s\n" "$ac_cv_prog_cc_c89" >&6; }
4968 CC="$CC $ac_cv_prog_cc_c89" ;;
4969esac
4970fi
4971 ac_cv_prog_cc_stdc=$ac_cv_prog_cc_c89
4972 ac_prog_cc_stdc=c89 ;;
4973esac
4974fi
4975fi
4976
4977ac_ext=c
4978ac_cpp='$CPP $CPPFLAGS'
4979ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4980ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4981ac_compiler_gnu=$ac_cv_c_compiler_gnu
4982
4983
4984if test -n "$want_auto_cflags"; then
4985 AUTO_CFLAGS="-g ${GCC:+-O2}"
4986 AUTO_LDFLAGS="-g ${GCC:+-O2}"
4987# STYLE_CFLAGS="${GCC:+-Wno-parentheses} ${GCC:+-Wno-format-security} ${GCC:+-Wno-tautological-constant-out-of-range-compare}"
4988 STYLE_CFLAGS="${GCC:+-Wno-parentheses} ${GCC:+-Wno-format-security}"
4989else
4990 AUTO_CFLAGS= AUTO_LDFLAGS= STYLE_CFLAGS=
4991fi
4992
4993
4994ac_header= ac_cache=
4995for ac_item in $ac_header_c_list
4996do
4997 if test $ac_cache; then
4998 ac_fn_c_check_header_compile "$LINENO" $ac_header ac_cv_header_$ac_cache "$ac_includes_default"
4999 if eval test \"x\$ac_cv_header_$ac_cache\" = xyes; then
5000 printf "%s\n" "#define $ac_item 1" >> confdefs.h
5001 fi
5002 ac_header= ac_cache=
5003 elif test $ac_header; then
5004 ac_cache=$ac_item
5005 else
5006 ac_header=$ac_item
5007 fi
5008done
5009
5010
5011
5012
5013
5014
5015
5016
5017if test $ac_cv_header_stdlib_h = yes && test $ac_cv_header_string_h = yes
5018then :
5019
5020printf "%s\n" "#define STDC_HEADERS 1" >>confdefs.h
5021
5022fi
5023
5024
5025
5026
5027
5028
5029 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5
5030printf %s "checking whether it is safe to define __EXTENSIONS__... " >&6; }
5031if test ${ac_cv_safe_to_define___extensions__+y}
5032then :
5033 printf %s "(cached) " >&6
5034else case e in #(
5035 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5036/* end confdefs.h. */
5037
5038# define __EXTENSIONS__ 1
5039 $ac_includes_default
5040int
5041main (void)
5042{
5043
5044 ;
5045 return 0;
5046}
5047_ACEOF
5048if ac_fn_c_try_compile "$LINENO"
5049then :
5050 ac_cv_safe_to_define___extensions__=yes
5051else case e in #(
5052 e) ac_cv_safe_to_define___extensions__=no ;;
5053esac
5054fi
5055rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
5056esac
5057fi
5058{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5
5059printf "%s\n" "$ac_cv_safe_to_define___extensions__" >&6; }
5060
5061 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether _XOPEN_SOURCE should be defined" >&5
5062printf %s "checking whether _XOPEN_SOURCE should be defined... " >&6; }
5063if test ${ac_cv_should_define__xopen_source+y}
5064then :
5065 printf %s "(cached) " >&6
5066else case e in #(
5067 e) ac_cv_should_define__xopen_source=no
5068 if test $ac_cv_header_wchar_h = yes
5069then :
5070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5071/* end confdefs.h. */
5072
5073 #include <wchar.h>
5074 mbstate_t x;
5075int
5076main (void)
5077{
5078
5079 ;
5080 return 0;
5081}
5082_ACEOF
5083if ac_fn_c_try_compile "$LINENO"
5084then :
5085
5086else case e in #(
5087 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5088/* end confdefs.h. */
5089
5090 #define _XOPEN_SOURCE 500
5091 #include <wchar.h>
5092 mbstate_t x;
5093int
5094main (void)
5095{
5096
5097 ;
5098 return 0;
5099}
5100_ACEOF
5101if ac_fn_c_try_compile "$LINENO"
5102then :
5103 ac_cv_should_define__xopen_source=yes
5104fi
5105rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
5106esac
5107fi
5108rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5109fi ;;
5110esac
5111fi
5112{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_should_define__xopen_source" >&5
5113printf "%s\n" "$ac_cv_should_define__xopen_source" >&6; }
5114
5115 printf "%s\n" "#define _ALL_SOURCE 1" >>confdefs.h
5116
5117 printf "%s\n" "#define _DARWIN_C_SOURCE 1" >>confdefs.h
5118
5119 printf "%s\n" "#define _GNU_SOURCE 1" >>confdefs.h
5120
5121 printf "%s\n" "#define _HPUX_ALT_XOPEN_SOCKET_API 1" >>confdefs.h
5122
5123 printf "%s\n" "#define _NETBSD_SOURCE 1" >>confdefs.h
5124
5125 printf "%s\n" "#define _OPENBSD_SOURCE 1" >>confdefs.h
5126
5127 printf "%s\n" "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h
5128
5129 printf "%s\n" "#define __STDC_WANT_IEC_60559_ATTRIBS_EXT__ 1" >>confdefs.h
5130
5131 printf "%s\n" "#define __STDC_WANT_IEC_60559_BFP_EXT__ 1" >>confdefs.h
5132
5133 printf "%s\n" "#define __STDC_WANT_IEC_60559_DFP_EXT__ 1" >>confdefs.h
5134
5135 printf "%s\n" "#define __STDC_WANT_IEC_60559_EXT__ 1" >>confdefs.h
5136
5137 printf "%s\n" "#define __STDC_WANT_IEC_60559_FUNCS_EXT__ 1" >>confdefs.h
5138
5139 printf "%s\n" "#define __STDC_WANT_IEC_60559_TYPES_EXT__ 1" >>confdefs.h
5140
5141 printf "%s\n" "#define __STDC_WANT_LIB_EXT2__ 1" >>confdefs.h
5142
5143 printf "%s\n" "#define __STDC_WANT_MATH_SPEC_FUNCS__ 1" >>confdefs.h
5144
5145 printf "%s\n" "#define _TANDEM_SOURCE 1" >>confdefs.h
5146
5147 if test $ac_cv_header_minix_config_h = yes
5148then :
5149 MINIX=yes
5150 printf "%s\n" "#define _MINIX 1" >>confdefs.h
5151
5152 printf "%s\n" "#define _POSIX_SOURCE 1" >>confdefs.h
5153
5154 printf "%s\n" "#define _POSIX_1_SOURCE 2" >>confdefs.h
5155
5156else case e in #(
5157 e) MINIX= ;;
5158esac
5159fi
5160 if test $ac_cv_safe_to_define___extensions__ = yes
5161then :
5162 printf "%s\n" "#define __EXTENSIONS__ 1" >>confdefs.h
5163
5164fi
5165 if test $ac_cv_should_define__xopen_source = yes
5166then :
5167 printf "%s\n" "#define _XOPEN_SOURCE 500" >>confdefs.h
5168
5169fi
5170
5171# Check whether --enable-largefile was given.
5172if test ${enable_largefile+y}
5173then :
5174 enableval=$enable_largefile;
5175fi
5176if test "$enable_largefile,$enable_year2038" != no,no
5177then :
5178 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option to enable large file support" >&5
5179printf %s "checking for $CC option to enable large file support... " >&6; }
5180if test ${ac_cv_sys_largefile_opts+y}
5181then :
5182 printf %s "(cached) " >&6
5183else case e in #(
5184 e) ac_save_CC="$CC"
5185 ac_opt_found=no
5186 for ac_opt in "none needed" "-D_FILE_OFFSET_BITS=64" "-D_LARGE_FILES=1" "-n32"; do
5187 if test x"$ac_opt" != x"none needed"
5188then :
5189 CC="$ac_save_CC $ac_opt"
5190fi
5191 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5192/* end confdefs.h. */
5193#include <sys/types.h>
5194#ifndef FTYPE
5195# define FTYPE off_t
5196#endif
5197 /* Check that FTYPE can represent 2**63 - 1 correctly.
5198 We can't simply define LARGE_FTYPE to be 9223372036854775807,
5199 since some C++ compilers masquerading as C compilers
5200 incorrectly reject 9223372036854775807. */
5201#define LARGE_FTYPE (((FTYPE) 1 << 31 << 31) - 1 + ((FTYPE) 1 << 31 << 31))
5202 int FTYPE_is_large[(LARGE_FTYPE % 2147483629 == 721
5203 && LARGE_FTYPE % 2147483647 == 1)
5204 ? 1 : -1];
5205int
5206main (void)
5207{
5208
5209 ;
5210 return 0;
5211}
5212_ACEOF
5213if ac_fn_c_try_compile "$LINENO"
5214then :
5215 if test x"$ac_opt" = x"none needed"
5216then :
5217 # GNU/Linux s390x and alpha need _FILE_OFFSET_BITS=64 for wide ino_t.
5218 CC="$CC -DFTYPE=ino_t"
5219 if ac_fn_c_try_compile "$LINENO"
5220then :
5221
5222else case e in #(
5223 e) CC="$CC -D_FILE_OFFSET_BITS=64"
5224 if ac_fn_c_try_compile "$LINENO"
5225then :
5226 ac_opt='-D_FILE_OFFSET_BITS=64'
5227fi
5228rm -f core conftest.err conftest.$ac_objext conftest.beam ;;
5229esac
5230fi
5231rm -f core conftest.err conftest.$ac_objext conftest.beam
5232fi
5233 ac_cv_sys_largefile_opts=$ac_opt
5234 ac_opt_found=yes
5235fi
5236rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5237 test $ac_opt_found = no || break
5238 done
5239 CC="$ac_save_CC"
5240
5241 test $ac_opt_found = yes || ac_cv_sys_largefile_opts="support not detected" ;;
5242esac
5243fi
5244{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_opts" >&5
5245printf "%s\n" "$ac_cv_sys_largefile_opts" >&6; }
5246
5247ac_have_largefile=yes
5248case $ac_cv_sys_largefile_opts in #(
5249 "none needed") :
5250 ;; #(
5251 "supported through gnulib") :
5252 ;; #(
5253 "support not detected") :
5254 ac_have_largefile=no ;; #(
5255 "-D_FILE_OFFSET_BITS=64") :
5256
5257printf "%s\n" "#define _FILE_OFFSET_BITS 64" >>confdefs.h
5258 ;; #(
5259 "-D_LARGE_FILES=1") :
5260
5261printf "%s\n" "#define _LARGE_FILES 1" >>confdefs.h
5262 ;; #(
5263 "-n32") :
5264 CC="$CC -n32" ;; #(
5265 *) :
5266 as_fn_error $? "internal error: bad value for \$ac_cv_sys_largefile_opts" "$LINENO" 5 ;;
5267esac
5268
5269if test "$enable_year2038" != no
5270then :
5271 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC option for timestamps after 2038" >&5
5272printf %s "checking for $CC option for timestamps after 2038... " >&6; }
5273if test ${ac_cv_sys_year2038_opts+y}
5274then :
5275 printf %s "(cached) " >&6
5276else case e in #(
5277 e) ac_save_CPPFLAGS="$CPPFLAGS"
5278 ac_opt_found=no
5279 for ac_opt in "none needed" "-D_TIME_BITS=64" "-D__MINGW_USE_VC2005_COMPAT" "-U_USE_32_BIT_TIME_T -D__MINGW_USE_VC2005_COMPAT"; do
5280 if test x"$ac_opt" != x"none needed"
5281then :
5282 CPPFLAGS="$ac_save_CPPFLAGS $ac_opt"
5283fi
5284 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5285/* end confdefs.h. */
5286
5287 #include <time.h>
5288 /* Check that time_t can represent 2**32 - 1 correctly. */
5289 #define LARGE_TIME_T \\
5290 ((time_t) (((time_t) 1 << 30) - 1 + 3 * ((time_t) 1 << 30)))
5291 int verify_time_t_range[(LARGE_TIME_T / 65537 == 65535
5292 && LARGE_TIME_T % 65537 == 0)
5293 ? 1 : -1];
5294
5295int
5296main (void)
5297{
5298
5299 ;
5300 return 0;
5301}
5302_ACEOF
5303if ac_fn_c_try_compile "$LINENO"
5304then :
5305 ac_cv_sys_year2038_opts="$ac_opt"
5306 ac_opt_found=yes
5307fi
5308rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
5309 test $ac_opt_found = no || break
5310 done
5311 CPPFLAGS="$ac_save_CPPFLAGS"
5312 test $ac_opt_found = yes || ac_cv_sys_year2038_opts="support not detected" ;;
5313esac
5314fi
5315{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_year2038_opts" >&5
5316printf "%s\n" "$ac_cv_sys_year2038_opts" >&6; }
5317
5318ac_have_year2038=yes
5319case $ac_cv_sys_year2038_opts in #(
5320 "none needed") :
5321 ;; #(
5322 "support not detected") :
5323 ac_have_year2038=no ;; #(
5324 "-D_TIME_BITS=64") :
5325
5326printf "%s\n" "#define _TIME_BITS 64" >>confdefs.h
5327 ;; #(
5328 "-D__MINGW_USE_VC2005_COMPAT") :
5329
5330printf "%s\n" "#define __MINGW_USE_VC2005_COMPAT 1" >>confdefs.h
5331 ;; #(
5332 "-U_USE_32_BIT_TIME_T"*) :
5333 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
5334printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
5335as_fn_error $? "the 'time_t' type is currently forced to be 32-bit. It
5336will stop working after mid-January 2038. Remove
5337_USE_32BIT_TIME_T from the compiler flags.
5338See 'config.log' for more details" "$LINENO" 5; } ;; #(
5339 *) :
5340 as_fn_error $? "internal error: bad value for \$ac_cv_sys_year2038_opts" "$LINENO" 5 ;;
5341esac
5342
5343fi
5344
5345fi
5346
5347
5348SIGNAMES_O=
5349SIGNAMES_H=lsignames.h
5350
5351
5352
5353CROSS_COMPILE=
5354if test "x$cross_compiling" = "xyes"; then
5355# case "${host}" in
5356# *-cygwin*)
5357# cross_cache=${srcdir}/cross-build/cygwin32.cache
5358# ;;
5359# *-msys*)
5360# cross_cache=${srcdir}/cross-build/msys32.cache
5361# ;;
5362# *-mingw*)
5363# cross_cache=${srcdir}/cross-build/cygwin32.cache
5364# ;;
5365# i[[3456]]86-*-beos*)
5366# cross_cache=${srcdir}/cross-build/x86-beos.cache
5367# ;;
5368# *-qnx*)
5369# cross_cache=${srcdir}/cross-build/qnx.cache
5370# ;;
5371# *) echo "configure: cross-compiling for $host is not supported" >&2
5372# ;;
5373# esac
5374# if test -n "${cross_cache}" && test -r "${cross_cache}"; then
5375# echo "loading cross-build cache file ${cross_cache}"
5376# . ${cross_cache}
5377# fi
5378# unset cross_cache
5379 SIGNAMES_O='signames.o'
5380 CROSS_COMPILE='-DCROSS_COMPILING'
5381
5382fi
5383
5384
5385
5386
5387CFLAGS=${CFLAGS-"$AUTO_CFLAGS"}
5388# LDFLAGS=${LDFLAGS="$AUTO_LDFLAGS"} # XXX
5389
5390if test "$opt_profiling" = "yes"; then
5391 PROFILE_FLAGS=-pg
5392 case "$host_os" in
5393 solaris2*|linux*|darwin*) ;;
5394 *) opt_static_link=yes ;;
5395 esac
5396 DEBUG= MALLOC_DEBUG=
5397fi
5398
5399prefer_shared=yes
5400prefer_static=no
5401
5402if test "$opt_static_link" = yes; then
5403 prefer_static=yes
5404 prefer_shared=no
5405 # if we're using gcc, add `-static' to LDFLAGS, except on Solaris >= 2
5406 if test "$GCC" = "yes"; then
5407 STATIC_LD="-static"
5408 case "$host_os" in
5409 solaris2*) ;;
5410 linux*) test "$opt_profiling" = "no" && LDFLAGS="$LDFLAGS -static" ;;
5411 *) LDFLAGS="$LDFLAGS -static" ;; # XXX experimental
5412 esac
5413 fi
5414fi
5415
5416# set the appropriate make variables for building the "build tools"
5417# modify defaults based on whether or not we are cross compiling, since the
5418# options for the target host may not be appropriate for the build host
5419if test "X$cross_compiling" = "Xno"; then
5420 CC_FOR_BUILD=${CC_FOR_BUILD-'$(CC)'}
5421 CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-"$CPPFLAGS"} # XXX - should it be '$(CPPFLAGS)'
5422 if test X"$opt_profiling" = Xyes; then
5423 LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-'$(BASE_LDFLAGS)'}
5424 else
5425 LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-'$(LDFLAGS)'}
5426 fi
5427 # CFLAGS set above to default value if not passed in environment
5428 if test -n "$want_auto_cflags" ; then
5429 CFLAGS_FOR_BUILD="${CFLAGS}"
5430 else
5431 # passed in environment
5432 CFLAGS_FOR_BUILD=${CFLAGS-'$(CFLAGS)'}
5433 fi
5434 LIBS_FOR_BUILD=${LIBS_FOR_BUILD-'$(LIBS)'}
5435else
5436 CC_FOR_BUILD=${CC_FOR_BUILD-"gcc"}
5437 CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-""}
5438 LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-""}
5439 CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD="-g"}
5440 LIBS_FOR_BUILD=${LIBS_FOR_BUILD-""}
5441fi
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457if test "$opt_readline" = yes && test "$opt_with_installed_readline" != "no"
5458then
5459 # If the user specified --with-installed-readline=PREFIX and PREFIX
5460 # is not `yes', set ac_cv_rl_prefix to PREFIX
5461 test $opt_with_installed_readline != "yes" && ac_cv_rl_prefix=$opt_with_installed_readline
5462
5463
5464if test "X$bash_cv_termcap_lib" = "X"; then
5465_bash_needmsg=yes
5466else
5467{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5
5468printf %s "checking which library has the termcap functions... " >&6; }
5469_bash_needmsg=
5470fi
5471if test ${bash_cv_termcap_lib+y}
5472then :
5473 printf %s "(cached) " >&6
5474else case e in #(
5475 e) ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent"
5476if test "x$ac_cv_func_tgetent" = xyes
5477then :
5478 bash_cv_termcap_lib=libc
5479else case e in #(
5480 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5
5481printf %s "checking for tgetent in -ltermcap... " >&6; }
5482if test ${ac_cv_lib_termcap_tgetent+y}
5483then :
5484 printf %s "(cached) " >&6
5485else case e in #(
5486 e) ac_check_lib_save_LIBS=$LIBS
5487LIBS="-ltermcap $LIBS"
5488cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5489/* end confdefs.h. */
5490
5491/* Override any GCC internal prototype to avoid an error.
5492 Use char because int might match the return type of a GCC
5493 builtin and then its argument prototype would still apply.
5494 The 'extern "C"' is for builds by C++ compilers;
5495 although this is not generally supported in C code supporting it here
5496 has little cost and some practical benefit (sr 110532). */
5497#ifdef __cplusplus
5498extern "C"
5499#endif
5500char tgetent (void);
5501int
5502main (void)
5503{
5504return tgetent ();
5505 ;
5506 return 0;
5507}
5508_ACEOF
5509if ac_fn_c_try_link "$LINENO"
5510then :
5511 ac_cv_lib_termcap_tgetent=yes
5512else case e in #(
5513 e) ac_cv_lib_termcap_tgetent=no ;;
5514esac
5515fi
5516rm -f core conftest.err conftest.$ac_objext conftest.beam \
5517 conftest$ac_exeext conftest.$ac_ext
5518LIBS=$ac_check_lib_save_LIBS ;;
5519esac
5520fi
5521{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5
5522printf "%s\n" "$ac_cv_lib_termcap_tgetent" >&6; }
5523if test "x$ac_cv_lib_termcap_tgetent" = xyes
5524then :
5525 bash_cv_termcap_lib=libtermcap
5526else case e in #(
5527 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5
5528printf %s "checking for tgetent in -ltinfo... " >&6; }
5529if test ${ac_cv_lib_tinfo_tgetent+y}
5530then :
5531 printf %s "(cached) " >&6
5532else case e in #(
5533 e) ac_check_lib_save_LIBS=$LIBS
5534LIBS="-ltinfo $LIBS"
5535cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5536/* end confdefs.h. */
5537
5538/* Override any GCC internal prototype to avoid an error.
5539 Use char because int might match the return type of a GCC
5540 builtin and then its argument prototype would still apply.
5541 The 'extern "C"' is for builds by C++ compilers;
5542 although this is not generally supported in C code supporting it here
5543 has little cost and some practical benefit (sr 110532). */
5544#ifdef __cplusplus
5545extern "C"
5546#endif
5547char tgetent (void);
5548int
5549main (void)
5550{
5551return tgetent ();
5552 ;
5553 return 0;
5554}
5555_ACEOF
5556if ac_fn_c_try_link "$LINENO"
5557then :
5558 ac_cv_lib_tinfo_tgetent=yes
5559else case e in #(
5560 e) ac_cv_lib_tinfo_tgetent=no ;;
5561esac
5562fi
5563rm -f core conftest.err conftest.$ac_objext conftest.beam \
5564 conftest$ac_exeext conftest.$ac_ext
5565LIBS=$ac_check_lib_save_LIBS ;;
5566esac
5567fi
5568{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5
5569printf "%s\n" "$ac_cv_lib_tinfo_tgetent" >&6; }
5570if test "x$ac_cv_lib_tinfo_tgetent" = xyes
5571then :
5572 bash_cv_termcap_lib=libtinfo
5573else case e in #(
5574 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5
5575printf %s "checking for tgetent in -lcurses... " >&6; }
5576if test ${ac_cv_lib_curses_tgetent+y}
5577then :
5578 printf %s "(cached) " >&6
5579else case e in #(
5580 e) ac_check_lib_save_LIBS=$LIBS
5581LIBS="-lcurses $LIBS"
5582cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5583/* end confdefs.h. */
5584
5585/* Override any GCC internal prototype to avoid an error.
5586 Use char because int might match the return type of a GCC
5587 builtin and then its argument prototype would still apply.
5588 The 'extern "C"' is for builds by C++ compilers;
5589 although this is not generally supported in C code supporting it here
5590 has little cost and some practical benefit (sr 110532). */
5591#ifdef __cplusplus
5592extern "C"
5593#endif
5594char tgetent (void);
5595int
5596main (void)
5597{
5598return tgetent ();
5599 ;
5600 return 0;
5601}
5602_ACEOF
5603if ac_fn_c_try_link "$LINENO"
5604then :
5605 ac_cv_lib_curses_tgetent=yes
5606else case e in #(
5607 e) ac_cv_lib_curses_tgetent=no ;;
5608esac
5609fi
5610rm -f core conftest.err conftest.$ac_objext conftest.beam \
5611 conftest$ac_exeext conftest.$ac_ext
5612LIBS=$ac_check_lib_save_LIBS ;;
5613esac
5614fi
5615{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5
5616printf "%s\n" "$ac_cv_lib_curses_tgetent" >&6; }
5617if test "x$ac_cv_lib_curses_tgetent" = xyes
5618then :
5619 bash_cv_termcap_lib=libcurses
5620else case e in #(
5621 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncursesw" >&5
5622printf %s "checking for tgetent in -lncursesw... " >&6; }
5623if test ${ac_cv_lib_ncursesw_tgetent+y}
5624then :
5625 printf %s "(cached) " >&6
5626else case e in #(
5627 e) ac_check_lib_save_LIBS=$LIBS
5628LIBS="-lncursesw $LIBS"
5629cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5630/* end confdefs.h. */
5631
5632/* Override any GCC internal prototype to avoid an error.
5633 Use char because int might match the return type of a GCC
5634 builtin and then its argument prototype would still apply.
5635 The 'extern "C"' is for builds by C++ compilers;
5636 although this is not generally supported in C code supporting it here
5637 has little cost and some practical benefit (sr 110532). */
5638#ifdef __cplusplus
5639extern "C"
5640#endif
5641char tgetent (void);
5642int
5643main (void)
5644{
5645return tgetent ();
5646 ;
5647 return 0;
5648}
5649_ACEOF
5650if ac_fn_c_try_link "$LINENO"
5651then :
5652 ac_cv_lib_ncursesw_tgetent=yes
5653else case e in #(
5654 e) ac_cv_lib_ncursesw_tgetent=no ;;
5655esac
5656fi
5657rm -f core conftest.err conftest.$ac_objext conftest.beam \
5658 conftest$ac_exeext conftest.$ac_ext
5659LIBS=$ac_check_lib_save_LIBS ;;
5660esac
5661fi
5662{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncursesw_tgetent" >&5
5663printf "%s\n" "$ac_cv_lib_ncursesw_tgetent" >&6; }
5664if test "x$ac_cv_lib_ncursesw_tgetent" = xyes
5665then :
5666 bash_cv_termcap_lib=libncursesw
5667else case e in #(
5668 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5
5669printf %s "checking for tgetent in -lncurses... " >&6; }
5670if test ${ac_cv_lib_ncurses_tgetent+y}
5671then :
5672 printf %s "(cached) " >&6
5673else case e in #(
5674 e) ac_check_lib_save_LIBS=$LIBS
5675LIBS="-lncurses $LIBS"
5676cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5677/* end confdefs.h. */
5678
5679/* Override any GCC internal prototype to avoid an error.
5680 Use char because int might match the return type of a GCC
5681 builtin and then its argument prototype would still apply.
5682 The 'extern "C"' is for builds by C++ compilers;
5683 although this is not generally supported in C code supporting it here
5684 has little cost and some practical benefit (sr 110532). */
5685#ifdef __cplusplus
5686extern "C"
5687#endif
5688char tgetent (void);
5689int
5690main (void)
5691{
5692return tgetent ();
5693 ;
5694 return 0;
5695}
5696_ACEOF
5697if ac_fn_c_try_link "$LINENO"
5698then :
5699 ac_cv_lib_ncurses_tgetent=yes
5700else case e in #(
5701 e) ac_cv_lib_ncurses_tgetent=no ;;
5702esac
5703fi
5704rm -f core conftest.err conftest.$ac_objext conftest.beam \
5705 conftest$ac_exeext conftest.$ac_ext
5706LIBS=$ac_check_lib_save_LIBS ;;
5707esac
5708fi
5709{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5
5710printf "%s\n" "$ac_cv_lib_ncurses_tgetent" >&6; }
5711if test "x$ac_cv_lib_ncurses_tgetent" = xyes
5712then :
5713 bash_cv_termcap_lib=libncurses
5714else case e in #(
5715 e) bash_cv_termcap_lib=gnutermcap ;;
5716esac
5717fi
5718 ;;
5719esac
5720fi
5721 ;;
5722esac
5723fi
5724 ;;
5725esac
5726fi
5727 ;;
5728esac
5729fi
5730 ;;
5731esac
5732fi
5733 ;;
5734esac
5735fi
5736
5737if test "X$_bash_needmsg" = "Xyes"; then
5738{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5
5739printf %s "checking which library has the termcap functions... " >&6; }
5740fi
5741{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5
5742printf "%s\n" "using $bash_cv_termcap_lib" >&6; }
5743if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then
5744LDFLAGS="$LDFLAGS -L./lib/termcap"
5745TERMCAP_LIB="./lib/termcap/libtermcap.a"
5746TERMCAP_DEP="./lib/termcap/libtermcap.a"
5747elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then
5748TERMCAP_LIB=-ltermcap
5749TERMCAP_DEP=
5750elif test $bash_cv_termcap_lib = libtinfo; then
5751TERMCAP_LIB=-ltinfo
5752TERMCAP_DEP=
5753elif test $bash_cv_termcap_lib = libncursesw; then
5754TERMCAP_LIB=-lncursesw
5755TERMCAP_DEP=
5756elif test $bash_cv_termcap_lib = libncurses; then
5757TERMCAP_LIB=-lncurses
5758TERMCAP_DEP=
5759elif test $bash_cv_termcap_lib = libcurses; then
5760TERMCAP_LIB=-lcurses
5761TERMCAP_DEP=
5762elif test $bash_cv_termcap_lib = libc; then
5763TERMCAP_LIB=
5764TERMCAP_DEP=
5765else
5766# we assume ncurses is installed somewhere the linker can find it
5767TERMCAP_LIB=-lncurses
5768TERMCAP_DEP=
5769fi
5770
5771
5772
5773
5774{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking version of installed readline library" >&5
5775printf %s "checking version of installed readline library... " >&6; }
5776
5777# What a pain in the ass this is.
5778
5779# save cpp and ld options
5780_save_CFLAGS="$CFLAGS"
5781_save_LDFLAGS="$LDFLAGS"
5782_save_LIBS="$LIBS"
5783
5784# Don't set ac_cv_rl_prefix if the caller has already assigned a value. This
5785# allows the caller to do something like $_rl_prefix=$withval if the user
5786# specifies --with-installed-readline=PREFIX as an argument to configure
5787
5788if test -z "$ac_cv_rl_prefix"; then
5789test "x$prefix" = xNONE && ac_cv_rl_prefix=$ac_default_prefix || ac_cv_rl_prefix=${prefix}
5790fi
5791
5792eval ac_cv_rl_includedir=${ac_cv_rl_prefix}/include
5793eval ac_cv_rl_libdir=${ac_cv_rl_prefix}/lib
5794
5795LIBS="$LIBS -lreadline ${TERMCAP_LIB}"
5796CFLAGS="$CFLAGS -I${ac_cv_rl_includedir}"
5797LDFLAGS="$LDFLAGS -L${ac_cv_rl_libdir}"
5798
5799if test ${ac_cv_rl_version+y}
5800then :
5801 printf %s "(cached) " >&6
5802else case e in #(
5803 e) if test "$cross_compiling" = yes
5804then :
5805 ac_cv_rl_version='8.0'
5806
5807else case e in #(
5808 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5809/* end confdefs.h. */
5810
5811#include <stdio.h>
5812#include <readline/readline.h>
5813#include <stdlib.h>
5814
5815extern int rl_gnu_readline_p;
5816
5817int
5818main()
5819{
5820 FILE *fp;
5821 fp = fopen("conftest.rlv", "w");
5822 if (fp == 0)
5823 exit(1);
5824 if (rl_gnu_readline_p != 1)
5825 fprintf(fp, "0.0\n");
5826 else
5827 fprintf(fp, "%s\n", rl_library_version ? rl_library_version : "0.0");
5828 fclose(fp);
5829 exit(0);
5830}
5831
5832_ACEOF
5833if ac_fn_c_try_run "$LINENO"
5834then :
5835 ac_cv_rl_version=`cat conftest.rlv`
5836else case e in #(
5837 e) ac_cv_rl_version='0.0' ;;
5838esac
5839fi
5840rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5841 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
5842esac
5843fi
5844 ;;
5845esac
5846fi
5847
5848
5849CFLAGS="$_save_CFLAGS"
5850LDFLAGS="$_save_LDFLAGS"
5851LIBS="$_save_LIBS"
5852
5853RL_MAJOR=0
5854RL_MINOR=0
5855
5856# (
5857case "$ac_cv_rl_version" in
58582*|3*|4*|5*|6*|7*|8*|9*)
5859 RL_MAJOR=`echo $ac_cv_rl_version | sed 's:\..*$::'`
5860 RL_MINOR=`echo $ac_cv_rl_version | sed -e 's:^.*\.::' -e 's:[a-zA-Z]*$::'`
5861 ;;
5862esac
5863
5864# (((
5865case $RL_MAJOR in
5866[0-9][0-9]) _RL_MAJOR=$RL_MAJOR ;;
5867[0-9]) _RL_MAJOR=0$RL_MAJOR ;;
5868*) _RL_MAJOR=00 ;;
5869esac
5870
5871# (((
5872case $RL_MINOR in
5873[0-9][0-9]) _RL_MINOR=$RL_MINOR ;;
5874[0-9]) _RL_MINOR=0$RL_MINOR ;;
5875*) _RL_MINOR=00 ;;
5876esac
5877
5878RL_VERSION="0x${_RL_MAJOR}${_RL_MINOR}"
5879
5880# Readline versions greater than 4.2 have these defines in readline.h
5881
5882if test $ac_cv_rl_version = '0.0' ; then
5883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: Could not test version of installed readline library." >&5
5884printf "%s\n" "$as_me: WARNING: Could not test version of installed readline library." >&2;}
5885elif test $RL_MAJOR -gt 4 || { test $RL_MAJOR = 4 && test $RL_MINOR -gt 2 ; } ; then
5886 # set these for use by the caller
5887 RL_PREFIX=$ac_cv_rl_prefix
5888 RL_LIBDIR=$ac_cv_rl_libdir
5889 RL_INCLUDEDIR=$ac_cv_rl_includedir
5890 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5
5891printf "%s\n" "$ac_cv_rl_version" >&6; }
5892else
5893
5894
5895printf "%s\n" "#define RL_READLINE_VERSION $RL_VERSION" >>confdefs.h
5896
5897
5898printf "%s\n" "#define RL_VERSION_MAJOR $RL_MAJOR" >>confdefs.h
5899
5900
5901printf "%s\n" "#define RL_VERSION_MINOR $RL_MINOR" >>confdefs.h
5902
5903
5904
5905
5906
5907
5908# set these for use by the caller
5909RL_PREFIX=$ac_cv_rl_prefix
5910RL_LIBDIR=$ac_cv_rl_libdir
5911RL_INCLUDEDIR=$ac_cv_rl_includedir
5912
5913{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5
5914printf "%s\n" "$ac_cv_rl_version" >&6; }
5915
5916fi
5917
5918
5919 case "$ac_cv_rl_version" in
5920 8*|9*) ;;
5921 *) opt_with_installed_readline=no
5922 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: installed readline library is too old to be linked with bash" >&5
5923printf "%s\n" "$as_me: WARNING: installed readline library is too old to be linked with bash" >&2;}
5924 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using private bash version" >&5
5925printf "%s\n" "$as_me: WARNING: using private bash version" >&2;}
5926 ;;
5927 esac
5928fi
5929
5930TILDE_LIB=-ltilde
5931if test $opt_readline = yes; then
5932 printf "%s\n" "#define READLINE 1" >>confdefs.h
5933
5934 if test "$opt_with_installed_readline" != "no" ; then
5935 case "$opt_with_installed_readline" in
5936 yes) RL_INCLUDE= ;;
5937 *) case "$RL_INCLUDEDIR" in
5938 /usr/include) ;;
5939 *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;;
5940 esac
5941 ;;
5942 esac
5943 READLINE_DEP=
5944 READLINE_LIB=-lreadline
5945 # section for OS versions that don't allow unresolved symbols
5946 # to be compiled into dynamic libraries.
5947 case "$host_os" in
5948 cygwin*|msys*) TILDE_LIB= ;;
5949 esac
5950 else
5951 RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline'
5952 READLINE_DEP='$(READLINE_LIBRARY)'
5953 # for dependencies
5954 RL_INCLUDEDIR='$(RL_LIBDIR)'
5955 # section for OS versions that ship an older/broken version of
5956 # readline as a standard dynamic library and don't allow a
5957 # static version specified as -llibname to override the
5958 # dynamic version
5959 case "${host_os}" in
5960 darwin[89]*|darwin10*) READLINE_LIB='${READLINE_LIBRARY}' ;;
5961 *) READLINE_LIB=-lreadline ;;
5962 esac
5963 fi
5964else
5965 RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline'
5966 READLINE_LIB= READLINE_DEP=
5967 RL_INCLUDEDIR=
5968fi
5969if test $opt_history = yes || test $opt_bang_history = yes; then
5970 if test $opt_history = yes; then
5971 printf "%s\n" "#define HISTORY 1" >>confdefs.h
5972
5973 fi
5974 if test $opt_bang_history = yes; then
5975 printf "%s\n" "#define BANG_HISTORY 1" >>confdefs.h
5976
5977 fi
5978 if test "$opt_with_installed_readline" != "no"; then
5979 HIST_LIBDIR=$RL_LIBDIR
5980 HISTORY_DEP=
5981 HISTORY_LIB=-lhistory
5982 case "$opt_with_installed_readline" in
5983 yes) RL_INCLUDE= ;;
5984 *) case "$RL_INCLUDEDIR" in
5985 /usr/include) ;;
5986 *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;;
5987 esac
5988 ;;
5989 esac
5990 else
5991 HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline'
5992 HISTORY_DEP='$(HISTORY_LIBRARY)'
5993 # for dependencies
5994 HIST_INCLUDEDIR='$(HIST_LIBDIR)'
5995 # section for OS versions that ship an older version of
5996 # readline as a standard dynamic library and don't allow a
5997 # static version specified as -llibname to override the
5998 # dynamic version
5999 case "${host_os}" in
6000 darwin[89]*|darwin10*) HISTORY_LIB='${HISTORY_LIBRARY}' ;;
6001 *) HISTORY_LIB=-lhistory ;;
6002 esac
6003 fi
6004else
6005 HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline'
6006 HISTORY_LIB= HISTORY_DEP=
6007 HIST_INCLUDEDIR=
6008fi
6009
6010
6011
6012
6013
6014
6015
6016
6017
6018
6019
6020
6021
6022 # Find a good install program. We prefer a C program (faster),
6023# so one script is as good as another. But avoid the broken or
6024# incompatible versions:
6025# SysV /etc/install, /usr/sbin/install
6026# SunOS /usr/etc/install
6027# IRIX /sbin/install
6028# AIX /bin/install
6029# AmigaOS /C/install, which installs bootblocks on floppy discs
6030# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
6031# AFS /usr/afsws/bin/install, which mishandles nonexistent args
6032# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
6033# OS/2's system install, which has a completely different semantic
6034# ./install, which can be erroneously created by make from ./install.sh.
6035# Reject install programs that cannot install multiple files.
6036{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
6037printf %s "checking for a BSD-compatible install... " >&6; }
6038if test -z "$INSTALL"; then
6039if test ${ac_cv_path_install+y}
6040then :
6041 printf %s "(cached) " >&6
6042else case e in #(
6043 e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6044for as_dir in $PATH
6045do
6046 IFS=$as_save_IFS
6047 case $as_dir in #(((
6048 '') as_dir=./ ;;
6049 */) ;;
6050 *) as_dir=$as_dir/ ;;
6051 esac
6052 # Account for fact that we put trailing slashes in our PATH walk.
6053case $as_dir in #((
6054 ./ | /[cC]/* | \
6055 /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
6056 ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
6057 /usr/ucb/* ) ;;
6058 *)
6059 # OSF1 and SCO ODT 3.0 have their own names for install.
6060 # Don't use installbsd from OSF since it installs stuff as root
6061 # by default.
6062 for ac_prog in ginstall scoinst install; do
6063 for ac_exec_ext in '' $ac_executable_extensions; do
6064 if as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext"; then
6065 if test $ac_prog = install &&
6066 grep dspmsg "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6067 # AIX install. It has an incompatible calling convention.
6068 :
6069 elif test $ac_prog = install &&
6070 grep pwplus "$as_dir$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
6071 # program-specific install script used by HP pwplus--don't use.
6072 :
6073 else
6074 rm -rf conftest.one conftest.two conftest.dir
6075 echo one > conftest.one
6076 echo two > conftest.two
6077 mkdir conftest.dir
6078 if "$as_dir$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir/" &&
6079 test -s conftest.one && test -s conftest.two &&
6080 test -s conftest.dir/conftest.one &&
6081 test -s conftest.dir/conftest.two
6082 then
6083 ac_cv_path_install="$as_dir$ac_prog$ac_exec_ext -c"
6084 break 3
6085 fi
6086 fi
6087 fi
6088 done
6089 done
6090 ;;
6091esac
6092
6093 done
6094IFS=$as_save_IFS
6095
6096rm -rf conftest.one conftest.two conftest.dir
6097 ;;
6098esac
6099fi
6100 if test ${ac_cv_path_install+y}; then
6101 INSTALL=$ac_cv_path_install
6102 else
6103 # As a last resort, use the slow shell script. Don't cache a
6104 # value for INSTALL within a source directory, because that will
6105 # break other packages using the cache if that directory is
6106 # removed, or if the value is a relative name.
6107 INSTALL=$ac_install_sh
6108 fi
6109fi
6110{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
6111printf "%s\n" "$INSTALL" >&6; }
6112
6113# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
6114# It thinks the first close brace ends the variable substitution.
6115test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
6116
6117test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
6118
6119test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
6120
6121if test -n "$ac_tool_prefix"; then
6122 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6123set dummy ${ac_tool_prefix}ar; ac_word=$2
6124{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6125printf %s "checking for $ac_word... " >&6; }
6126if test ${ac_cv_prog_AR+y}
6127then :
6128 printf %s "(cached) " >&6
6129else case e in #(
6130 e) if test -n "$AR"; then
6131 ac_cv_prog_AR="$AR" # Let the user override the test.
6132else
6133as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6134for as_dir in $PATH
6135do
6136 IFS=$as_save_IFS
6137 case $as_dir in #(((
6138 '') as_dir=./ ;;
6139 */) ;;
6140 *) as_dir=$as_dir/ ;;
6141 esac
6142 for ac_exec_ext in '' $ac_executable_extensions; do
6143 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6144 ac_cv_prog_AR="${ac_tool_prefix}ar"
6145 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6146 break 2
6147 fi
6148done
6149 done
6150IFS=$as_save_IFS
6151
6152fi ;;
6153esac
6154fi
6155AR=$ac_cv_prog_AR
6156if test -n "$AR"; then
6157 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
6158printf "%s\n" "$AR" >&6; }
6159else
6160 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6161printf "%s\n" "no" >&6; }
6162fi
6163
6164
6165fi
6166if test -z "$ac_cv_prog_AR"; then
6167 ac_ct_AR=$AR
6168 # Extract the first word of "ar", so it can be a program name with args.
6169set dummy ar; ac_word=$2
6170{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6171printf %s "checking for $ac_word... " >&6; }
6172if test ${ac_cv_prog_ac_ct_AR+y}
6173then :
6174 printf %s "(cached) " >&6
6175else case e in #(
6176 e) if test -n "$ac_ct_AR"; then
6177 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6178else
6179as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6180for as_dir in $PATH
6181do
6182 IFS=$as_save_IFS
6183 case $as_dir in #(((
6184 '') as_dir=./ ;;
6185 */) ;;
6186 *) as_dir=$as_dir/ ;;
6187 esac
6188 for ac_exec_ext in '' $ac_executable_extensions; do
6189 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6190 ac_cv_prog_ac_ct_AR="ar"
6191 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6192 break 2
6193 fi
6194done
6195 done
6196IFS=$as_save_IFS
6197
6198fi ;;
6199esac
6200fi
6201ac_ct_AR=$ac_cv_prog_ac_ct_AR
6202if test -n "$ac_ct_AR"; then
6203 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
6204printf "%s\n" "$ac_ct_AR" >&6; }
6205else
6206 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6207printf "%s\n" "no" >&6; }
6208fi
6209
6210 if test "x$ac_ct_AR" = x; then
6211 AR=""
6212 else
6213 case $cross_compiling:$ac_tool_warned in
6214yes:)
6215{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6216printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6217ac_tool_warned=yes ;;
6218esac
6219 AR=$ac_ct_AR
6220 fi
6221else
6222 AR="$ac_cv_prog_AR"
6223fi
6224
6225test -n "$ARFLAGS" || ARFLAGS="cr"
6226if test -n "$ac_tool_prefix"; then
6227 # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6228set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6229{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6230printf %s "checking for $ac_word... " >&6; }
6231if test ${ac_cv_prog_RANLIB+y}
6232then :
6233 printf %s "(cached) " >&6
6234else case e in #(
6235 e) if test -n "$RANLIB"; then
6236 ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6237else
6238as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6239for as_dir in $PATH
6240do
6241 IFS=$as_save_IFS
6242 case $as_dir in #(((
6243 '') as_dir=./ ;;
6244 */) ;;
6245 *) as_dir=$as_dir/ ;;
6246 esac
6247 for ac_exec_ext in '' $ac_executable_extensions; do
6248 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6249 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6250 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6251 break 2
6252 fi
6253done
6254 done
6255IFS=$as_save_IFS
6256
6257fi ;;
6258esac
6259fi
6260RANLIB=$ac_cv_prog_RANLIB
6261if test -n "$RANLIB"; then
6262 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
6263printf "%s\n" "$RANLIB" >&6; }
6264else
6265 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6266printf "%s\n" "no" >&6; }
6267fi
6268
6269
6270fi
6271if test -z "$ac_cv_prog_RANLIB"; then
6272 ac_ct_RANLIB=$RANLIB
6273 # Extract the first word of "ranlib", so it can be a program name with args.
6274set dummy ranlib; ac_word=$2
6275{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6276printf %s "checking for $ac_word... " >&6; }
6277if test ${ac_cv_prog_ac_ct_RANLIB+y}
6278then :
6279 printf %s "(cached) " >&6
6280else case e in #(
6281 e) if test -n "$ac_ct_RANLIB"; then
6282 ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6283else
6284as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6285for as_dir in $PATH
6286do
6287 IFS=$as_save_IFS
6288 case $as_dir in #(((
6289 '') as_dir=./ ;;
6290 */) ;;
6291 *) as_dir=$as_dir/ ;;
6292 esac
6293 for ac_exec_ext in '' $ac_executable_extensions; do
6294 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6295 ac_cv_prog_ac_ct_RANLIB="ranlib"
6296 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6297 break 2
6298 fi
6299done
6300 done
6301IFS=$as_save_IFS
6302
6303fi ;;
6304esac
6305fi
6306ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6307if test -n "$ac_ct_RANLIB"; then
6308 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
6309printf "%s\n" "$ac_ct_RANLIB" >&6; }
6310else
6311 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6312printf "%s\n" "no" >&6; }
6313fi
6314
6315 if test "x$ac_ct_RANLIB" = x; then
6316 RANLIB=":"
6317 else
6318 case $cross_compiling:$ac_tool_warned in
6319yes:)
6320{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6321printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6322ac_tool_warned=yes ;;
6323esac
6324 RANLIB=$ac_ct_RANLIB
6325 fi
6326else
6327 RANLIB="$ac_cv_prog_RANLIB"
6328fi
6329
6330for ac_prog in 'bison -y' byacc
6331do
6332 # Extract the first word of "$ac_prog", so it can be a program name with args.
6333set dummy $ac_prog; ac_word=$2
6334{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6335printf %s "checking for $ac_word... " >&6; }
6336if test ${ac_cv_prog_YACC+y}
6337then :
6338 printf %s "(cached) " >&6
6339else case e in #(
6340 e) if test -n "$YACC"; then
6341 ac_cv_prog_YACC="$YACC" # Let the user override the test.
6342else
6343as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6344for as_dir in $PATH
6345do
6346 IFS=$as_save_IFS
6347 case $as_dir in #(((
6348 '') as_dir=./ ;;
6349 */) ;;
6350 *) as_dir=$as_dir/ ;;
6351 esac
6352 for ac_exec_ext in '' $ac_executable_extensions; do
6353 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6354 ac_cv_prog_YACC="$ac_prog"
6355 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6356 break 2
6357 fi
6358done
6359 done
6360IFS=$as_save_IFS
6361
6362fi ;;
6363esac
6364fi
6365YACC=$ac_cv_prog_YACC
6366if test -n "$YACC"; then
6367 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5
6368printf "%s\n" "$YACC" >&6; }
6369else
6370 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6371printf "%s\n" "no" >&6; }
6372fi
6373
6374
6375 test -n "$YACC" && break
6376done
6377test -n "$YACC" || YACC="yacc"
6378
6379{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5
6380printf %s "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; }
6381set x ${MAKE-make}
6382ac_make=`printf "%s\n" "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'`
6383if eval test \${ac_cv_prog_make_${ac_make}_set+y}
6384then :
6385 printf %s "(cached) " >&6
6386else case e in #(
6387 e) cat >conftest.make <<\_ACEOF
6388SHELL = /bin/sh
6389all:
6390 @echo '@@@%%%=$(MAKE)=@@@%%%'
6391_ACEOF
6392# GNU make sometimes prints "make[1]: Entering ...", which would confuse us.
6393case `${MAKE-make} -f conftest.make 2>/dev/null` in
6394 *@@@%%%=?*=@@@%%%*)
6395 eval ac_cv_prog_make_${ac_make}_set=yes;;
6396 *)
6397 eval ac_cv_prog_make_${ac_make}_set=no;;
6398esac
6399rm -f conftest.make ;;
6400esac
6401fi
6402if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then
6403 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6404printf "%s\n" "yes" >&6; }
6405 SET_MAKE=
6406else
6407 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6408printf "%s\n" "no" >&6; }
6409 SET_MAKE="MAKE=${MAKE-make}"
6410fi
6411
6412
6413
6414# Expand $ac_aux_dir to an absolute path.
6415am_aux_dir=`cd "$ac_aux_dir" && pwd`
6416
6417if test x"${install_sh+set}" != xset; then
6418 case $am_aux_dir in
6419 *\ * | *\ *)
6420 install_sh="\${SHELL} '$am_aux_dir/install-sh'" ;;
6421 *)
6422 install_sh="\${SHELL} $am_aux_dir/install-sh"
6423 esac
6424fi
6425
6426# Installed binaries are usually stripped using 'strip' when the user
6427# run "make install-strip". However 'strip' might not be the right
6428# tool to use in cross-compilation environments, therefore Automake
6429# will honor the 'STRIP' environment variable to overrule this program.
6430#if test "$cross_compiling" != no; then
6431 if test -n "$ac_tool_prefix"; then
6432 # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6433set dummy ${ac_tool_prefix}strip; ac_word=$2
6434{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6435printf %s "checking for $ac_word... " >&6; }
6436if test ${ac_cv_prog_STRIP+y}
6437then :
6438 printf %s "(cached) " >&6
6439else case e in #(
6440 e) if test -n "$STRIP"; then
6441 ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6442else
6443as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6444for as_dir in $PATH
6445do
6446 IFS=$as_save_IFS
6447 case $as_dir in #(((
6448 '') as_dir=./ ;;
6449 */) ;;
6450 *) as_dir=$as_dir/ ;;
6451 esac
6452 for ac_exec_ext in '' $ac_executable_extensions; do
6453 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6454 ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6455 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6456 break 2
6457 fi
6458done
6459 done
6460IFS=$as_save_IFS
6461
6462fi ;;
6463esac
6464fi
6465STRIP=$ac_cv_prog_STRIP
6466if test -n "$STRIP"; then
6467 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5
6468printf "%s\n" "$STRIP" >&6; }
6469else
6470 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6471printf "%s\n" "no" >&6; }
6472fi
6473
6474
6475fi
6476if test -z "$ac_cv_prog_STRIP"; then
6477 ac_ct_STRIP=$STRIP
6478 # Extract the first word of "strip", so it can be a program name with args.
6479set dummy strip; ac_word=$2
6480{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
6481printf %s "checking for $ac_word... " >&6; }
6482if test ${ac_cv_prog_ac_ct_STRIP+y}
6483then :
6484 printf %s "(cached) " >&6
6485else case e in #(
6486 e) if test -n "$ac_ct_STRIP"; then
6487 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6488else
6489as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6490for as_dir in $PATH
6491do
6492 IFS=$as_save_IFS
6493 case $as_dir in #(((
6494 '') as_dir=./ ;;
6495 */) ;;
6496 *) as_dir=$as_dir/ ;;
6497 esac
6498 for ac_exec_ext in '' $ac_executable_extensions; do
6499 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
6500 ac_cv_prog_ac_ct_STRIP="strip"
6501 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
6502 break 2
6503 fi
6504done
6505 done
6506IFS=$as_save_IFS
6507
6508fi ;;
6509esac
6510fi
6511ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6512if test -n "$ac_ct_STRIP"; then
6513 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5
6514printf "%s\n" "$ac_ct_STRIP" >&6; }
6515else
6516 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
6517printf "%s\n" "no" >&6; }
6518fi
6519
6520 if test "x$ac_ct_STRIP" = x; then
6521 STRIP=":"
6522 else
6523 case $cross_compiling:$ac_tool_warned in
6524yes:)
6525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
6526printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6527ac_tool_warned=yes ;;
6528esac
6529 STRIP=$ac_ct_STRIP
6530 fi
6531else
6532 STRIP="$ac_cv_prog_STRIP"
6533fi
6534
6535#fi
6536INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
6537
6538
6539case "$ac_cv_prog_YACC" in
6540*bison*) ;;
6541*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: bison not available; needed to process parse.y" >&5
6542printf "%s\n" "$as_me: WARNING: bison not available; needed to process parse.y" >&2;} ;;
6543esac
6544
6545case "$host_os" in
6546opennt*|interix*) MAKE_SHELL="$INTERIX_ROOT/bin/sh" ;;
6547*) MAKE_SHELL=/bin/sh ;;
6548esac
6549
6550
6551if test x$SIZE = x; then
6552 if test x$ac_tool_prefix = x; then
6553 SIZE=size
6554 else
6555 SIZE=${ac_tool_prefix}size
6556 save_IFS=$IFS ; IFS=:
6557 size_found=0
6558 for dir in $PATH; do
6559 if test -x $dir/$SIZE ; then
6560 size_found=1
6561 break
6562 fi
6563 done
6564 if test $size_found -eq 0; then
6565 SIZE=:
6566 fi
6567 IFS=$save_IFS
6568 fi
6569fi
6570
6571
6572# Checks for stat-related time functions.
6573
6574# Copyright (C) 1998-1999, 2001, 2003, 2005-2007, 2009-2012 Free Software
6575# Foundation, Inc.
6576
6577# This file is free software; the Free Software Foundation
6578# gives unlimited permission to copy and/or distribute it,
6579# with or without modifications, as long as this notice is preserved.
6580
6581
6582# st_atim.tv_nsec - Linux, Solaris, Cygwin
6583# st_atimespec.tv_nsec - FreeBSD, NetBSD, if ! defined _POSIX_SOURCE
6584# st_atimensec - FreeBSD, NetBSD, if defined _POSIX_SOURCE
6585# st_atim.st__tim.tv_nsec - UnixWare (at least 2.1.2 through 7.1)
6586
6587# st_birthtimespec - FreeBSD, NetBSD (hidden on OpenBSD 3.9, anyway)
6588# st_birthtim - Cygwin 1.7.0+
6589
6590
6591
6592# Configure checks for struct timespec
6593
6594# Copyright (C) 2000-2001, 2003-2007, 2009-2011, 2012 Free Software Foundation, Inc.
6595
6596# This file is free software; the Free Software Foundation
6597# gives unlimited permission to copy and/or distribute it,
6598# with or without modifications, as long as this notice is preserved.
6599
6600# Original written by Paul Eggert and Jim Meyering.
6601# Modified by Chet Ramey for bash
6602
6603
6604
6605
6606
6607
6608
6609
6610
6611# unlocked-io.m4 serial 16
6612
6613# Copyright (C) 1998-2006, 2009-2024 Free Software Foundation, Inc.
6614#
6615# This file is free software; the Free Software Foundation
6616# gives unlimited permission to copy and/or distribute it,
6617# with or without modifications, as long as this notice is preserved.
6618
6619
6620
6621
6622
6623# codeset.m4 serial 5 (gettext-0.18.2)
6624
6625
6626
6627
6628
6629
6630
6631
6632
6633# serial 10
6634
6635# Copyright (C) 2002-2006, 2008-2022 Free Software Foundation, Inc.
6636# This file is free software; the Free Software Foundation
6637# gives unlimited permission to copy and/or distribute it,
6638# with or without modifications, as long as this notice is preserved.
6639
6640# There are two types of parser skeletons:
6641#
6642# * Those that can be used with any Yacc implementation, including bison.
6643# For these, in the configure.ac, up to Autoconf 2.69, you could use
6644# AC_PROG_YACC
6645# In newer Autoconf versions, however, this macro is broken. See
6646# https://lists.gnu.org/archive/html/autoconf-patches/2013-03/msg00000.html
6647# https://lists.gnu.org/archive/html/bug-autoconf/2018-12/msg00001.html
6648# In the Makefile.am you could use
6649# $(SHELL) $(YLWRAP) $(srcdir)/foo.y \
6650# y.tab.c foo.c \
6651# y.tab.h foo.h \
6652# y.output foo.output \
6653# -- $(YACC) $(YFLAGS) $(AM_YFLAGS)
6654# or similar.
6655#
6656# * Those that make use of Bison extensions. For example,
6657# - %define api.pure requires bison 2.7 or newer,
6658# - %precedence requires bison 3.0 or newer.
6659# For these, in the configure.ac you will need an invocation of
6660# gl_PROG_BISON([VARIABLE], [MIN_BISON_VERSION])
6661# Example:
6662# gl_PROG_BISON([PARSE_DATETIME_BISON], [2.4])
6663# With this preparation, in the Makefile.am there are two ways to formulate
6664# the invocation. Both are direct, without use of 'ylwrap'.
6665# (a) You can invoke
6666# $(VARIABLE) -d $(SOME_BISON_OPTIONS) --output foo.c $(srcdir)/foo.y
6667# or similar.
6668# (b) If you want the invocation to honor an YFLAGS=... parameter passed to
6669# 'configure' or an YFLAGS environment variable present at 'configure'
6670# time, add an invocation of gl_BISON to the configure.ac, and write
6671# $(VARIABLE) -d $(YFLAGS) $(AM_YFLAGS) $(srcdir)/foo.y
6672# or similar.
6673
6674# This macro defines the autoconf variable VARIABLE to 'bison' if the specified
6675# minimum version of bison is found in $PATH, or to ':' otherwise.
6676
6677
6678# This macro sets the autoconf variables YACC (for old-style yacc Makefile
6679# rules) and YFLAGS (to allow options to be passed as 'configure' time).
6680
6681
6682# fcntl-o.m4 serial 7
6683
6684
6685
6686
6687# Test whether the flags O_NOATIME and O_NOFOLLOW actually work.
6688# Define HAVE_WORKING_O_NOATIME to 1 if O_NOATIME works, or to 0 otherwise.
6689# Define HAVE_WORKING_O_NOFOLLOW to 1 if O_NOFOLLOW works, or to 0 otherwise.
6690
6691
6692# serial 5
6693# Check for flexible array member support.
6694
6695# Copyright (C) 2006, 2009-2022 Free Software Foundation, Inc.
6696# This file is free software; the Free Software Foundation
6697# gives unlimited permission to copy and/or distribute it,
6698# with or without modifications, as long as this notice is preserved.
6699
6700# Written by Paul Eggert.
6701
6702
6703
6704# gettext.m4 serial 72 (gettext-0.21.1)
6705
6706
6707
6708
6709
6710
6711
6712
6713
6714
6715
6716
6717
6718
6719
6720
6721
6722
6723# glibc2.m4 serial 3
6724
6725# Test for the GNU C Library, version 2.0 or newer.
6726# From Bruno Haible.
6727
6728
6729
6730# iconv.m4 serial 24
6731
6732
6733
6734
6735
6736
6737
6738
6739
6740
6741
6742# intdiv0.m4 serial 9 (gettext-0.21.1)
6743
6744
6745
6746
6747# intl.m4 serial 51 (gettext-0.21.1)
6748
6749
6750
6751
6752
6753
6754
6755
6756
6757
6758
6759# intlmacosx.m4 serial 8 (gettext-0.20.2)
6760
6761
6762
6763# intl-thread-locale.m4 serial 9
6764
6765
6766
6767
6768
6769# intmax.m4 serial 6 (gettext-0.18.2)
6770
6771
6772
6773
6774# inttypes-pri.m4 serial 7 (gettext-0.18.2)
6775
6776
6777
6778
6779# Define PRI_MACROS_BROKEN if <inttypes.h> exists and defines the PRI*
6780# macros to non-string values. This is the case on AIX 4.3.3.
6781
6782
6783
6784# inttypes.m4 serial 36
6785
6786
6787
6788
6789
6790
6791# Ensure that the PRI* and SCN* macros are defined appropriately.
6792
6793
6794# Define the symbol $1 to be 1 if the condition is true, 0 otherwise.
6795# If $2 is true, the condition is $3; otherwise if long long int is supported
6796# approximate the condition with $4; otherwise, assume the condition is false.
6797# The condition should work on all C99 platforms; the approximations should be
6798# good enough to work on all practical pre-C99 platforms.
6799# $2 is evaluated by the C preprocessor, $3 and $4 as compile-time constants.
6800
6801
6802# gl_INTTYPES_MODULE_INDICATOR([modulename])
6803# sets the shell variable that indicates the presence of the given module
6804# to a C preprocessor expression that will evaluate to 1.
6805# This macro invocation must not occur in macros that are AC_REQUIREd.
6806
6807
6808# Initializes the default values for AC_SUBSTed shell variables.
6809# This macro must not be AC_REQUIREd. It must only be invoked, and only
6810# outside of macros or in macros that are not AC_REQUIREd.
6811
6812
6813
6814
6815# inttypes_h.m4 serial 10
6816
6817
6818# Define HAVE_INTTYPES_H_WITH_UINTMAX if <inttypes.h> exists,
6819# doesn't clash with <sys/types.h>, and declares uintmax_t.
6820
6821
6822
6823# lcmessage.m4 serial 8
6824
6825
6826# Check whether LC_MESSAGES is available in <locale.h>.
6827
6828
6829
6830# lib-ld.m4 serial 10
6831
6832
6833
6834
6835
6836
6837# lib-link.m4 serial 33
6838
6839
6840
6841
6842
6843
6844
6845
6846
6847
6848
6849
6850
6851
6852
6853
6854
6855
6856# lib-prefix.m4 serial 20
6857
6858
6859
6860
6861
6862
6863
6864
6865
6866
6867# locale_h.m4 serial 28
6868
6869
6870
6871
6872
6873# gl_LOCALE_MODULE_INDICATOR([modulename])
6874# sets the shell variable that indicates the presence of the given module
6875# to a C preprocessor expression that will evaluate to 1.
6876# This macro invocation must not occur in macros that are AC_REQUIREd.
6877
6878
6879# Initializes the default values for AC_SUBSTed shell variables.
6880# This macro must not be AC_REQUIREd. It must only be invoked, and only
6881# outside of macros or in macros that are not AC_REQUIREd.
6882
6883
6884
6885
6886# lock.m4 serial 14
6887
6888
6889
6890
6891# Prerequisites of lib/glthread/lock.c.
6892
6893
6894# nls.m4 serial 6 (gettext-0.20.2)
6895
6896
6897
6898
6899
6900
6901# po.m4 serial 32 (gettext-0.21.1)
6902
6903
6904
6905
6906
6907
6908
6909
6910
6911
6912
6913
6914# printf-posix.m4 serial 7 (gettext-0.21.1)
6915
6916
6917
6918
6919# progtest.m4 serial 9 (gettext-0.21.1)
6920
6921
6922
6923
6924# Search path for a program which passes the given test.
6925
6926
6927
6928# pthread_rwlock_rdlock.m4 serial 4
6929
6930
6931
6932
6933# size_max.m4 serial 12
6934
6935
6936
6937
6938
6939
6940# stdint_h.m4 serial 9
6941
6942
6943# Define HAVE_STDINT_H_WITH_UINTMAX if <stdint.h> exists,
6944# doesn't clash with <sys/types.h>, and declares uintmax_t.
6945
6946
6947
6948# threadlib.m4 serial 32
6949
6950
6951
6952
6953
6954
6955
6956
6957
6958
6959
6960
6961
6962
6963
6964
6965
6966
6967
6968
6969
6970
6971
6972
6973
6974
6975
6976
6977
6978
6979
6980
6981
6982
6983
6984
6985
6986
6987
6988
6989
6990
6991
6992
6993
6994
6995
6996
6997
6998# uintmax_t.m4 serial 12
6999
7000
7001
7002
7003# Define uintmax_t to 'unsigned long' or 'unsigned long long'
7004# if it is not already defined in <stdint.h> or <inttypes.h>.
7005
7006
7007
7008# ulonglong.m4 serial 10
7009
7010# visibility.m4 serial 6
7011
7012
7013
7014
7015
7016# wchar_t.m4 serial 4 (gettext-0.18.2)
7017
7018
7019
7020
7021# wint_t.m4 serial 11
7022
7023
7024
7025
7026
7027
7028# xsize.m4 serial 5
7029
7030
7031
7032
7033# glibc21.m4 serial 5
7034
7035# Test for the GNU C Library, version 2.1 or newer, or uClibc.
7036# From Bruno Haible.
7037
7038
7039
7040# host-cpu-c-abi.m4 serial 15
7041
7042
7043
7044
7045
7046
7047
7048
7049# Check for bool that conforms to C2023.
7050
7051
7052
7053
7054# d-type.m4
7055# serial 12
7056
7057
7058
7059
7060
7061{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5
7062printf %s "checking for an ANSI C-conforming const... " >&6; }
7063if test ${ac_cv_c_const+y}
7064then :
7065 printf %s "(cached) " >&6
7066else case e in #(
7067 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7068/* end confdefs.h. */
7069
7070int
7071main (void)
7072{
7073
7074#ifndef __cplusplus
7075 /* Ultrix mips cc rejects this sort of thing. */
7076 typedef int charset[2];
7077 const charset cs = { 0, 0 };
7078 /* SunOS 4.1.1 cc rejects this. */
7079 char const *const *pcpcc;
7080 char **ppc;
7081 /* NEC SVR4.0.2 mips cc rejects this. */
7082 struct point {int x, y;};
7083 static struct point const zero = {0,0};
7084 /* IBM XL C 1.02.0.0 rejects this.
7085 It does not let you subtract one const X* pointer from another in
7086 an arm of an if-expression whose if-part is not a constant
7087 expression */
7088 const char *g = "string";
7089 pcpcc = &g + (g ? g-g : 0);
7090 /* HPUX 7.0 cc rejects these. */
7091 ++pcpcc;
7092 ppc = (char**) pcpcc;
7093 pcpcc = (char const *const *) ppc;
7094 { /* SCO 3.2v4 cc rejects this sort of thing. */
7095 char tx;
7096 char *t = &tx;
7097 char const *s = 0 ? (char *) 0 : (char const *) 0;
7098
7099 *t++ = 0;
7100 if (s) return 0;
7101 }
7102 { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */
7103 int x[] = {25, 17};
7104 const int *foo = &x[0];
7105 ++foo;
7106 }
7107 { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
7108 typedef const int *iptr;
7109 iptr p = 0;
7110 ++p;
7111 }
7112 { /* IBM XL C 1.02.0.0 rejects this sort of thing, saying
7113 "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
7114 struct s { int j; const int *ap[3]; } bx;
7115 struct s *b = &bx; b->j = 5;
7116 }
7117 { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
7118 const int foo = 10;
7119 if (!foo) return 0;
7120 }
7121 return !cs[0] && !zero.x;
7122#endif
7123
7124 ;
7125 return 0;
7126}
7127_ACEOF
7128if ac_fn_c_try_compile "$LINENO"
7129then :
7130 ac_cv_c_const=yes
7131else case e in #(
7132 e) ac_cv_c_const=no ;;
7133esac
7134fi
7135rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
7136esac
7137fi
7138{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5
7139printf "%s\n" "$ac_cv_c_const" >&6; }
7140if test $ac_cv_c_const = no; then
7141
7142printf "%s\n" "#define const /**/" >>confdefs.h
7143
7144fi
7145
7146{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
7147printf %s "checking for inline... " >&6; }
7148if test ${ac_cv_c_inline+y}
7149then :
7150 printf %s "(cached) " >&6
7151else case e in #(
7152 e) ac_cv_c_inline=no
7153for ac_kw in inline __inline__ __inline; do
7154 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7155/* end confdefs.h. */
7156#ifndef __cplusplus
7157typedef int foo_t;
7158static $ac_kw foo_t static_foo (void) {return 0; }
7159$ac_kw foo_t foo (void) {return 0; }
7160#endif
7161
7162_ACEOF
7163if ac_fn_c_try_compile "$LINENO"
7164then :
7165 ac_cv_c_inline=$ac_kw
7166fi
7167rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7168 test "$ac_cv_c_inline" != no && break
7169done
7170 ;;
7171esac
7172fi
7173{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
7174printf "%s\n" "$ac_cv_c_inline" >&6; }
7175
7176case $ac_cv_c_inline in
7177 inline | yes) ;;
7178 *)
7179 case $ac_cv_c_inline in
7180 no) ac_val=;;
7181 *) ac_val=$ac_cv_c_inline;;
7182 esac
7183 cat >>confdefs.h <<_ACEOF
7184#ifndef __cplusplus
7185#define inline $ac_val
7186#endif
7187_ACEOF
7188 ;;
7189esac
7190
7191 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
7192printf %s "checking whether byte ordering is bigendian... " >&6; }
7193if test ${ac_cv_c_bigendian+y}
7194then :
7195 printf %s "(cached) " >&6
7196else case e in #(
7197 e) ac_cv_c_bigendian=unknown
7198 # See if we're dealing with a universal compiler.
7199 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7200/* end confdefs.h. */
7201#ifndef __APPLE_CC__
7202 not a universal capable compiler
7203 #endif
7204 typedef int dummy;
7205
7206_ACEOF
7207if ac_fn_c_try_compile "$LINENO"
7208then :
7209
7210 # Check for potential -arch flags. It is not universal unless
7211 # there are at least two -arch flags with different values.
7212 ac_arch=
7213 ac_prev=
7214 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
7215 if test -n "$ac_prev"; then
7216 case $ac_word in
7217 i?86 | x86_64 | ppc | ppc64)
7218 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
7219 ac_arch=$ac_word
7220 else
7221 ac_cv_c_bigendian=universal
7222 break
7223 fi
7224 ;;
7225 esac
7226 ac_prev=
7227 elif test "x$ac_word" = "x-arch"; then
7228 ac_prev=arch
7229 fi
7230 done
7231fi
7232rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7233 if test $ac_cv_c_bigendian = unknown; then
7234 # See if sys/param.h defines the BYTE_ORDER macro.
7235 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7236/* end confdefs.h. */
7237#include <sys/types.h>
7238 #include <sys/param.h>
7239
7240int
7241main (void)
7242{
7243#if ! (defined BYTE_ORDER && defined BIG_ENDIAN \\
7244 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \\
7245 && LITTLE_ENDIAN)
7246 bogus endian macros
7247 #endif
7248
7249 ;
7250 return 0;
7251}
7252_ACEOF
7253if ac_fn_c_try_compile "$LINENO"
7254then :
7255 # It does; now see whether it defined to BIG_ENDIAN or not.
7256 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7257/* end confdefs.h. */
7258#include <sys/types.h>
7259 #include <sys/param.h>
7260
7261int
7262main (void)
7263{
7264#if BYTE_ORDER != BIG_ENDIAN
7265 not big endian
7266 #endif
7267
7268 ;
7269 return 0;
7270}
7271_ACEOF
7272if ac_fn_c_try_compile "$LINENO"
7273then :
7274 ac_cv_c_bigendian=yes
7275else case e in #(
7276 e) ac_cv_c_bigendian=no ;;
7277esac
7278fi
7279rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7280fi
7281rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7282 fi
7283 if test $ac_cv_c_bigendian = unknown; then
7284 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
7285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7286/* end confdefs.h. */
7287#include <limits.h>
7288
7289int
7290main (void)
7291{
7292#if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
7293 bogus endian macros
7294 #endif
7295
7296 ;
7297 return 0;
7298}
7299_ACEOF
7300if ac_fn_c_try_compile "$LINENO"
7301then :
7302 # It does; now see whether it defined to _BIG_ENDIAN or not.
7303 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7304/* end confdefs.h. */
7305#include <limits.h>
7306
7307int
7308main (void)
7309{
7310#ifndef _BIG_ENDIAN
7311 not big endian
7312 #endif
7313
7314 ;
7315 return 0;
7316}
7317_ACEOF
7318if ac_fn_c_try_compile "$LINENO"
7319then :
7320 ac_cv_c_bigendian=yes
7321else case e in #(
7322 e) ac_cv_c_bigendian=no ;;
7323esac
7324fi
7325rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7326fi
7327rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7328 fi
7329 if test $ac_cv_c_bigendian = unknown; then
7330 # Compile a test program.
7331 if test "$cross_compiling" = yes
7332then :
7333 # Try to guess by grepping values from an object file.
7334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7335/* end confdefs.h. */
7336unsigned short int ascii_mm[] =
7337 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
7338 unsigned short int ascii_ii[] =
7339 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
7340 int use_ascii (int i) {
7341 return ascii_mm[i] + ascii_ii[i];
7342 }
7343 unsigned short int ebcdic_ii[] =
7344 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
7345 unsigned short int ebcdic_mm[] =
7346 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
7347 int use_ebcdic (int i) {
7348 return ebcdic_mm[i] + ebcdic_ii[i];
7349 }
7350 int
7351 main (int argc, char **argv)
7352 {
7353 /* Intimidate the compiler so that it does not
7354 optimize the arrays away. */
7355 char *p = argv[0];
7356 ascii_mm[1] = *p++; ebcdic_mm[1] = *p++;
7357 ascii_ii[1] = *p++; ebcdic_ii[1] = *p++;
7358 return use_ascii (argc) == use_ebcdic (*p);
7359 }
7360_ACEOF
7361if ac_fn_c_try_link "$LINENO"
7362then :
7363 if grep BIGenDianSyS conftest$ac_exeext >/dev/null; then
7364 ac_cv_c_bigendian=yes
7365 fi
7366 if grep LiTTleEnDian conftest$ac_exeext >/dev/null ; then
7367 if test "$ac_cv_c_bigendian" = unknown; then
7368 ac_cv_c_bigendian=no
7369 else
7370 # finding both strings is unlikely to happen, but who knows?
7371 ac_cv_c_bigendian=unknown
7372 fi
7373 fi
7374fi
7375rm -f core conftest.err conftest.$ac_objext conftest.beam \
7376 conftest$ac_exeext conftest.$ac_ext
7377else case e in #(
7378 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7379/* end confdefs.h. */
7380$ac_includes_default
7381int
7382main (void)
7383{
7384
7385 /* Are we little or big endian? From Harbison&Steele. */
7386 union
7387 {
7388 long int l;
7389 char c[sizeof (long int)];
7390 } u;
7391 u.l = 1;
7392 return u.c[sizeof (long int) - 1] == 1;
7393
7394 ;
7395 return 0;
7396}
7397_ACEOF
7398if ac_fn_c_try_run "$LINENO"
7399then :
7400 ac_cv_c_bigendian=no
7401else case e in #(
7402 e) ac_cv_c_bigendian=yes ;;
7403esac
7404fi
7405rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7406 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
7407esac
7408fi
7409
7410 fi ;;
7411esac
7412fi
7413{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
7414printf "%s\n" "$ac_cv_c_bigendian" >&6; }
7415 case $ac_cv_c_bigendian in #(
7416 yes)
7417 printf "%s\n" "#define WORDS_BIGENDIAN 1" >>confdefs.h
7418;; #(
7419 no)
7420 ;; #(
7421 universal)
7422
7423printf "%s\n" "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
7424
7425 ;; #(
7426 *)
7427 as_fn_error $? "unknown endianness
7428 presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;;
7429 esac
7430
7431
7432if test "$ac_prog_cc_stdc" != no; then
7433
7434printf "%s\n" "#define HAVE_STRINGIZE 1" >>confdefs.h
7435
7436fi
7437
7438
7439 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for long double" >&5
7440printf %s "checking for long double... " >&6; }
7441if test ${ac_cv_type_long_double+y}
7442then :
7443 printf %s "(cached) " >&6
7444else case e in #(
7445 e) if test "$GCC" = yes; then
7446 ac_cv_type_long_double=yes
7447 else
7448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7449/* end confdefs.h. */
7450/* The Stardent Vistra knows sizeof (long double), but does
7451 not support it. */
7452 long double foo = 0.0L;
7453int
7454main (void)
7455{
7456static int test_array [1 - 2 * !(/* On Ultrix 4.3 cc, long double is 4 and double is 8. */
7457 sizeof (double) <= sizeof (long double))];
7458test_array [0] = 0;
7459return test_array [0];
7460
7461 ;
7462 return 0;
7463}
7464_ACEOF
7465if ac_fn_c_try_compile "$LINENO"
7466then :
7467 ac_cv_type_long_double=yes
7468else case e in #(
7469 e) ac_cv_type_long_double=no ;;
7470esac
7471fi
7472rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7473 fi ;;
7474esac
7475fi
7476{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double" >&5
7477printf "%s\n" "$ac_cv_type_long_double" >&6; }
7478 if test $ac_cv_type_long_double = yes; then
7479
7480printf "%s\n" "#define HAVE_LONG_DOUBLE 1" >>confdefs.h
7481
7482 fi
7483
7484{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5
7485printf %s "checking whether char is unsigned... " >&6; }
7486if test ${ac_cv_c_char_unsigned+y}
7487then :
7488 printf %s "(cached) " >&6
7489else case e in #(
7490 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7491/* end confdefs.h. */
7492$ac_includes_default
7493int
7494main (void)
7495{
7496static int test_array [1 - 2 * !(((char) -1) < 0)];
7497test_array [0] = 0;
7498return test_array [0];
7499
7500 ;
7501 return 0;
7502}
7503_ACEOF
7504if ac_fn_c_try_compile "$LINENO"
7505then :
7506 ac_cv_c_char_unsigned=no
7507else case e in #(
7508 e) ac_cv_c_char_unsigned=yes ;;
7509esac
7510fi
7511rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
7512esac
7513fi
7514{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5
7515printf "%s\n" "$ac_cv_c_char_unsigned" >&6; }
7516if test $ac_cv_c_char_unsigned = yes; then
7517 printf "%s\n" "#define __CHAR_UNSIGNED__ 1" >>confdefs.h
7518
7519fi
7520
7521{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5
7522printf %s "checking for working volatile... " >&6; }
7523if test ${ac_cv_c_volatile+y}
7524then :
7525 printf %s "(cached) " >&6
7526else case e in #(
7527 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7528/* end confdefs.h. */
7529
7530int
7531main (void)
7532{
7533
7534volatile int x;
7535int * volatile y = (int *) 0;
7536return !x && !y;
7537 ;
7538 return 0;
7539}
7540_ACEOF
7541if ac_fn_c_try_compile "$LINENO"
7542then :
7543 ac_cv_c_volatile=yes
7544else case e in #(
7545 e) ac_cv_c_volatile=no ;;
7546esac
7547fi
7548rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
7549esac
7550fi
7551{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5
7552printf "%s\n" "$ac_cv_c_volatile" >&6; }
7553if test $ac_cv_c_volatile = no; then
7554
7555printf "%s\n" "#define volatile /**/" >>confdefs.h
7556
7557fi
7558
7559{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5
7560printf %s "checking for C/C++ restrict keyword... " >&6; }
7561if test ${ac_cv_c_restrict+y}
7562then :
7563 printf %s "(cached) " >&6
7564else case e in #(
7565 e) ac_cv_c_restrict=no
7566 # Put '__restrict__' first, to avoid problems with glibc and non-GCC; see:
7567 # https://lists.gnu.org/archive/html/bug-autoconf/2016-02/msg00006.html
7568 # Put 'restrict' last, because C++ lacks it.
7569 for ac_kw in __restrict__ __restrict _Restrict restrict; do
7570 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7571/* end confdefs.h. */
7572typedef int *int_ptr;
7573 int foo (int_ptr $ac_kw ip) { return ip[0]; }
7574 int bar (int [$ac_kw]); /* Catch GCC bug 14050. */
7575 int bar (int ip[$ac_kw]) { return ip[0]; }
7576
7577int
7578main (void)
7579{
7580int s[1];
7581 int *$ac_kw t = s;
7582 t[0] = 0;
7583 return foo (t) + bar (t);
7584
7585 ;
7586 return 0;
7587}
7588_ACEOF
7589if ac_fn_c_try_compile "$LINENO"
7590then :
7591 ac_cv_c_restrict=$ac_kw
7592fi
7593rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
7594 test "$ac_cv_c_restrict" != no && break
7595 done
7596 ;;
7597esac
7598fi
7599{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5
7600printf "%s\n" "$ac_cv_c_restrict" >&6; }
7601
7602 case $ac_cv_c_restrict in
7603 restrict) ;;
7604 no) printf "%s\n" "#define restrict /**/" >>confdefs.h
7605 ;;
7606 *) printf "%s\n" "#define restrict $ac_cv_c_restrict" >>confdefs.h
7607 ;;
7608 esac
7609
7610
7611
7612
7613 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bool, true, false" >&5
7614printf %s "checking for bool, true, false... " >&6; }
7615if test ${gl_cv_c_bool+y}
7616then :
7617 printf %s "(cached) " >&6
7618else case e in #(
7619 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7620/* end confdefs.h. */
7621
7622 #if true == false
7623 #error "true == false"
7624 #endif
7625 extern bool b;
7626 bool b = true == false;
7627_ACEOF
7628if ac_fn_c_try_compile "$LINENO"
7629then :
7630 gl_cv_c_bool=yes
7631else case e in #(
7632 e) gl_cv_c_bool=no ;;
7633esac
7634fi
7635rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
7636esac
7637fi
7638{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_c_bool" >&5
7639printf "%s\n" "$gl_cv_c_bool" >&6; }
7640 if test "$gl_cv_c_bool" = yes; then
7641
7642printf "%s\n" "#define HAVE_C_BOOL 1" >>confdefs.h
7643
7644 fi
7645
7646
7647
7648
7649
7650
7651 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a race-free mkdir -p" >&5
7652printf %s "checking for a race-free mkdir -p... " >&6; }
7653if test -z "$MKDIR_P"; then
7654 if test ${ac_cv_path_mkdir+y}
7655then :
7656 printf %s "(cached) " >&6
7657else case e in #(
7658 e) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7659for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
7660do
7661 IFS=$as_save_IFS
7662 case $as_dir in #(((
7663 '') as_dir=./ ;;
7664 */) ;;
7665 *) as_dir=$as_dir/ ;;
7666 esac
7667 for ac_prog in mkdir gmkdir; do
7668 for ac_exec_ext in '' $ac_executable_extensions; do
7669 as_fn_executable_p "$as_dir$ac_prog$ac_exec_ext" || continue
7670 case `"$as_dir$ac_prog$ac_exec_ext" --version 2>&1` in #(
7671 'mkdir ('*'coreutils) '* | \
7672 *'BusyBox '* | \
7673 'mkdir (fileutils) '4.1*)
7674 ac_cv_path_mkdir=$as_dir$ac_prog$ac_exec_ext
7675 break 3;;
7676 esac
7677 done
7678 done
7679 done
7680IFS=$as_save_IFS
7681 ;;
7682esac
7683fi
7684
7685 test -d ./--version && rmdir ./--version
7686 if test ${ac_cv_path_mkdir+y}; then
7687 MKDIR_P="$ac_cv_path_mkdir -p"
7688 else
7689 # As a last resort, use plain mkdir -p,
7690 # in the hope it doesn't have the bugs of ancient mkdir.
7691 MKDIR_P='mkdir -p'
7692 fi
7693fi
7694{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MKDIR_P" >&5
7695printf "%s\n" "$MKDIR_P" >&6; }
7696
7697{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5
7698printf %s "checking for a sed that does not truncate output... " >&6; }
7699if test ${ac_cv_path_SED+y}
7700then :
7701 printf %s "(cached) " >&6
7702else case e in #(
7703 e) ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/
7704 for ac_i in 1 2 3 4 5 6 7; do
7705 ac_script="$ac_script$as_nl$ac_script"
7706 done
7707 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed
7708 { ac_script=; unset ac_script;}
7709 if test -z "$SED"; then
7710 ac_path_SED_found=false
7711 # Loop through the user's path and test for each of PROGNAME-LIST
7712 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7713for as_dir in $PATH
7714do
7715 IFS=$as_save_IFS
7716 case $as_dir in #(((
7717 '') as_dir=./ ;;
7718 */) ;;
7719 *) as_dir=$as_dir/ ;;
7720 esac
7721 for ac_prog in sed gsed
7722 do
7723 for ac_exec_ext in '' $ac_executable_extensions; do
7724 ac_path_SED="$as_dir$ac_prog$ac_exec_ext"
7725 as_fn_executable_p "$ac_path_SED" || continue
7726# Check for GNU ac_path_SED and select it if it is found.
7727 # Check for GNU $ac_path_SED
7728case `"$ac_path_SED" --version 2>&1` in #(
7729*GNU*)
7730 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;;
7731#(
7732*)
7733 ac_count=0
7734 printf %s 0123456789 >"conftest.in"
7735 while :
7736 do
7737 cat "conftest.in" "conftest.in" >"conftest.tmp"
7738 mv "conftest.tmp" "conftest.in"
7739 cp "conftest.in" "conftest.nl"
7740 printf "%s\n" '' >> "conftest.nl"
7741 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break
7742 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
7743 as_fn_arith $ac_count + 1 && ac_count=$as_val
7744 if test $ac_count -gt ${ac_path_SED_max-0}; then
7745 # Best one so far, save it but keep looking for a better one
7746 ac_cv_path_SED="$ac_path_SED"
7747 ac_path_SED_max=$ac_count
7748 fi
7749 # 10*(2^10) chars as input seems more than enough
7750 test $ac_count -gt 10 && break
7751 done
7752 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
7753esac
7754
7755 $ac_path_SED_found && break 3
7756 done
7757 done
7758 done
7759IFS=$as_save_IFS
7760 if test -z "$ac_cv_path_SED"; then
7761 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5
7762 fi
7763else
7764 ac_cv_path_SED=$SED
7765fi
7766 ;;
7767esac
7768fi
7769{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5
7770printf "%s\n" "$ac_cv_path_SED" >&6; }
7771 SED="$ac_cv_path_SED"
7772 rm -f conftest.sed
7773
7774
7775 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5
7776printf %s "checking whether NLS is requested... " >&6; }
7777 # Check whether --enable-nls was given.
7778if test ${enable_nls+y}
7779then :
7780 enableval=$enable_nls; USE_NLS=$enableval
7781else case e in #(
7782 e) USE_NLS=yes ;;
7783esac
7784fi
7785
7786 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
7787printf "%s\n" "$USE_NLS" >&6; }
7788
7789
7790
7791
7792 GETTEXT_MACRO_VERSION=0.20
7793
7794
7795
7796
7797# Prepare PATH_SEPARATOR.
7798# The user is always right.
7799if test "${PATH_SEPARATOR+set}" != set; then
7800 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
7801 # contains only /bin. Note that ksh looks also at the FPATH variable,
7802 # so we have to set that as well for the test.
7803 PATH_SEPARATOR=:
7804 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
7805 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
7806 || PATH_SEPARATOR=';'
7807 }
7808fi
7809
7810# Find out how to test for executable files. Don't use a zero-byte file,
7811# as systems may use methods other than mode bits to determine executability.
7812cat >conf$$.file <<_ASEOF
7813#! /bin/sh
7814exit 0
7815_ASEOF
7816chmod +x conf$$.file
7817if test -x conf$$.file >/dev/null 2>&1; then
7818 ac_executable_p="test -x"
7819else
7820 ac_executable_p="test -f"
7821fi
7822rm -f conf$$.file
7823
7824# Extract the first word of "msgfmt", so it can be a program name with args.
7825set dummy msgfmt; ac_word=$2
7826{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7827printf %s "checking for $ac_word... " >&6; }
7828if test ${ac_cv_path_MSGFMT+y}
7829then :
7830 printf %s "(cached) " >&6
7831else case e in #(
7832 e) case "$MSGFMT" in
7833 [\\/]* | ?:[\\/]*)
7834 ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path.
7835 ;;
7836 *)
7837 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
7838 for ac_dir in $PATH; do
7839 IFS="$ac_save_IFS"
7840 test -z "$ac_dir" && ac_dir=.
7841 for ac_exec_ext in '' $ac_executable_extensions; do
7842 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
7843 echo "$as_me: trying $ac_dir/$ac_word..." >&5
7844 if $ac_dir/$ac_word --statistics /dev/null >&5 2>&1 &&
7845 (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
7846 ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext"
7847 break 2
7848 fi
7849 fi
7850 done
7851 done
7852 IFS="$ac_save_IFS"
7853 test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":"
7854 ;;
7855esac ;;
7856esac
7857fi
7858MSGFMT="$ac_cv_path_MSGFMT"
7859if test "$MSGFMT" != ":"; then
7860 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5
7861printf "%s\n" "$MSGFMT" >&6; }
7862else
7863 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7864printf "%s\n" "no" >&6; }
7865fi
7866
7867 # Extract the first word of "gmsgfmt", so it can be a program name with args.
7868set dummy gmsgfmt; ac_word=$2
7869{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7870printf %s "checking for $ac_word... " >&6; }
7871if test ${ac_cv_path_GMSGFMT+y}
7872then :
7873 printf %s "(cached) " >&6
7874else case e in #(
7875 e) case $GMSGFMT in
7876 [\\/]* | ?:[\\/]*)
7877 ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path.
7878 ;;
7879 *)
7880 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7881for as_dir in $PATH
7882do
7883 IFS=$as_save_IFS
7884 case $as_dir in #(((
7885 '') as_dir=./ ;;
7886 */) ;;
7887 *) as_dir=$as_dir/ ;;
7888 esac
7889 for ac_exec_ext in '' $ac_executable_extensions; do
7890 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
7891 ac_cv_path_GMSGFMT="$as_dir$ac_word$ac_exec_ext"
7892 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
7893 break 2
7894 fi
7895done
7896 done
7897IFS=$as_save_IFS
7898
7899 test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT"
7900 ;;
7901esac ;;
7902esac
7903fi
7904GMSGFMT=$ac_cv_path_GMSGFMT
7905if test -n "$GMSGFMT"; then
7906 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5
7907printf "%s\n" "$GMSGFMT" >&6; }
7908else
7909 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7910printf "%s\n" "no" >&6; }
7911fi
7912
7913
7914
7915 case `$GMSGFMT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
7916 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) GMSGFMT_015=: ;;
7917 *) GMSGFMT_015=$GMSGFMT ;;
7918 esac
7919
7920
7921
7922# Prepare PATH_SEPARATOR.
7923# The user is always right.
7924if test "${PATH_SEPARATOR+set}" != set; then
7925 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
7926 # contains only /bin. Note that ksh looks also at the FPATH variable,
7927 # so we have to set that as well for the test.
7928 PATH_SEPARATOR=:
7929 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
7930 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
7931 || PATH_SEPARATOR=';'
7932 }
7933fi
7934
7935# Find out how to test for executable files. Don't use a zero-byte file,
7936# as systems may use methods other than mode bits to determine executability.
7937cat >conf$$.file <<_ASEOF
7938#! /bin/sh
7939exit 0
7940_ASEOF
7941chmod +x conf$$.file
7942if test -x conf$$.file >/dev/null 2>&1; then
7943 ac_executable_p="test -x"
7944else
7945 ac_executable_p="test -f"
7946fi
7947rm -f conf$$.file
7948
7949# Extract the first word of "xgettext", so it can be a program name with args.
7950set dummy xgettext; ac_word=$2
7951{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
7952printf %s "checking for $ac_word... " >&6; }
7953if test ${ac_cv_path_XGETTEXT+y}
7954then :
7955 printf %s "(cached) " >&6
7956else case e in #(
7957 e) case "$XGETTEXT" in
7958 [\\/]* | ?:[\\/]*)
7959 ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path.
7960 ;;
7961 *)
7962 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
7963 for ac_dir in $PATH; do
7964 IFS="$ac_save_IFS"
7965 test -z "$ac_dir" && ac_dir=.
7966 for ac_exec_ext in '' $ac_executable_extensions; do
7967 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
7968 echo "$as_me: trying $ac_dir/$ac_word..." >&5
7969 if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >&5 2>&1 &&
7970 (if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then
7971 ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext"
7972 break 2
7973 fi
7974 fi
7975 done
7976 done
7977 IFS="$ac_save_IFS"
7978 test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":"
7979 ;;
7980esac ;;
7981esac
7982fi
7983XGETTEXT="$ac_cv_path_XGETTEXT"
7984if test "$XGETTEXT" != ":"; then
7985 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5
7986printf "%s\n" "$XGETTEXT" >&6; }
7987else
7988 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
7989printf "%s\n" "no" >&6; }
7990fi
7991
7992 rm -f messages.po
7993
7994 case `$XGETTEXT --version | sed 1q | sed -e 's,^[^0-9]*,,'` in
7995 '' | 0.[0-9] | 0.[0-9].* | 0.1[0-4] | 0.1[0-4].*) XGETTEXT_015=: ;;
7996 *) XGETTEXT_015=$XGETTEXT ;;
7997 esac
7998
7999
8000
8001# Prepare PATH_SEPARATOR.
8002# The user is always right.
8003if test "${PATH_SEPARATOR+set}" != set; then
8004 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
8005 # contains only /bin. Note that ksh looks also at the FPATH variable,
8006 # so we have to set that as well for the test.
8007 PATH_SEPARATOR=:
8008 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8009 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
8010 || PATH_SEPARATOR=';'
8011 }
8012fi
8013
8014# Find out how to test for executable files. Don't use a zero-byte file,
8015# as systems may use methods other than mode bits to determine executability.
8016cat >conf$$.file <<_ASEOF
8017#! /bin/sh
8018exit 0
8019_ASEOF
8020chmod +x conf$$.file
8021if test -x conf$$.file >/dev/null 2>&1; then
8022 ac_executable_p="test -x"
8023else
8024 ac_executable_p="test -f"
8025fi
8026rm -f conf$$.file
8027
8028# Extract the first word of "msgmerge", so it can be a program name with args.
8029set dummy msgmerge; ac_word=$2
8030{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8031printf %s "checking for $ac_word... " >&6; }
8032if test ${ac_cv_path_MSGMERGE+y}
8033then :
8034 printf %s "(cached) " >&6
8035else case e in #(
8036 e) case "$MSGMERGE" in
8037 [\\/]* | ?:[\\/]*)
8038 ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path.
8039 ;;
8040 *)
8041 ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR
8042 for ac_dir in $PATH; do
8043 IFS="$ac_save_IFS"
8044 test -z "$ac_dir" && ac_dir=.
8045 for ac_exec_ext in '' $ac_executable_extensions; do
8046 if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then
8047 echo "$as_me: trying $ac_dir/$ac_word..." >&5
8048 if $ac_dir/$ac_word --update -q /dev/null /dev/null >&5 2>&1; then
8049 ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext"
8050 break 2
8051 fi
8052 fi
8053 done
8054 done
8055 IFS="$ac_save_IFS"
8056 test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":"
8057 ;;
8058esac ;;
8059esac
8060fi
8061MSGMERGE="$ac_cv_path_MSGMERGE"
8062if test "$MSGMERGE" != ":"; then
8063 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5
8064printf "%s\n" "$MSGMERGE" >&6; }
8065else
8066 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
8067printf "%s\n" "no" >&6; }
8068fi
8069
8070
8071 if LC_ALL=C $MSGMERGE --help | grep ' --for-msgfmt ' >/dev/null; then
8072 MSGMERGE_FOR_MSGFMT_OPTION='--for-msgfmt'
8073 else
8074 if LC_ALL=C $MSGMERGE --help | grep ' --no-fuzzy-matching ' >/dev/null; then
8075 MSGMERGE_FOR_MSGFMT_OPTION='--no-fuzzy-matching --no-location --quiet'
8076 else
8077 MSGMERGE_FOR_MSGFMT_OPTION='--no-location --quiet'
8078 fi
8079 fi
8080
8081
8082 test -n "${XGETTEXT_EXTRA_OPTIONS+set}" || XGETTEXT_EXTRA_OPTIONS=
8083
8084
8085 ac_config_commands="$ac_config_commands po-directories"
8086
8087
8088ac_ext=c
8089ac_cpp='$CPP $CPPFLAGS'
8090ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8091ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8092ac_compiler_gnu=$ac_cv_c_compiler_gnu
8093{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
8094printf %s "checking how to run the C preprocessor... " >&6; }
8095# On Suns, sometimes $CPP names a directory.
8096if test -n "$CPP" && test -d "$CPP"; then
8097 CPP=
8098fi
8099if test -z "$CPP"; then
8100 if test ${ac_cv_prog_CPP+y}
8101then :
8102 printf %s "(cached) " >&6
8103else case e in #(
8104 e) # Double quotes because $CC needs to be expanded
8105 for CPP in "$CC -E" "$CC -E -traditional-cpp" cpp /lib/cpp
8106 do
8107 ac_preproc_ok=false
8108for ac_c_preproc_warn_flag in '' yes
8109do
8110 # Use a header file that comes with gcc, so configuring glibc
8111 # with a fresh cross-compiler works.
8112 # On the NeXT, cc -E runs the code through the compiler's parser,
8113 # not just through cpp. "Syntax error" is here to catch this case.
8114 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8115/* end confdefs.h. */
8116#include <limits.h>
8117 Syntax error
8118_ACEOF
8119if ac_fn_c_try_cpp "$LINENO"
8120then :
8121
8122else case e in #(
8123 e) # Broken: fails on valid input.
8124continue ;;
8125esac
8126fi
8127rm -f conftest.err conftest.i conftest.$ac_ext
8128
8129 # OK, works on sane cases. Now check whether nonexistent headers
8130 # can be detected and how.
8131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8132/* end confdefs.h. */
8133#include <ac_nonexistent.h>
8134_ACEOF
8135if ac_fn_c_try_cpp "$LINENO"
8136then :
8137 # Broken: success on invalid input.
8138continue
8139else case e in #(
8140 e) # Passes both tests.
8141ac_preproc_ok=:
8142break ;;
8143esac
8144fi
8145rm -f conftest.err conftest.i conftest.$ac_ext
8146
8147done
8148# Because of 'break', _AC_PREPROC_IFELSE's cleaning code was skipped.
8149rm -f conftest.i conftest.err conftest.$ac_ext
8150if $ac_preproc_ok
8151then :
8152 break
8153fi
8154
8155 done
8156 ac_cv_prog_CPP=$CPP
8157 ;;
8158esac
8159fi
8160 CPP=$ac_cv_prog_CPP
8161else
8162 ac_cv_prog_CPP=$CPP
8163fi
8164{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
8165printf "%s\n" "$CPP" >&6; }
8166ac_preproc_ok=false
8167for ac_c_preproc_warn_flag in '' yes
8168do
8169 # Use a header file that comes with gcc, so configuring glibc
8170 # with a fresh cross-compiler works.
8171 # On the NeXT, cc -E runs the code through the compiler's parser,
8172 # not just through cpp. "Syntax error" is here to catch this case.
8173 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8174/* end confdefs.h. */
8175#include <limits.h>
8176 Syntax error
8177_ACEOF
8178if ac_fn_c_try_cpp "$LINENO"
8179then :
8180
8181else case e in #(
8182 e) # Broken: fails on valid input.
8183continue ;;
8184esac
8185fi
8186rm -f conftest.err conftest.i conftest.$ac_ext
8187
8188 # OK, works on sane cases. Now check whether nonexistent headers
8189 # can be detected and how.
8190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8191/* end confdefs.h. */
8192#include <ac_nonexistent.h>
8193_ACEOF
8194if ac_fn_c_try_cpp "$LINENO"
8195then :
8196 # Broken: success on invalid input.
8197continue
8198else case e in #(
8199 e) # Passes both tests.
8200ac_preproc_ok=:
8201break ;;
8202esac
8203fi
8204rm -f conftest.err conftest.i conftest.$ac_ext
8205
8206done
8207# Because of 'break', _AC_PREPROC_IFELSE's cleaning code was skipped.
8208rm -f conftest.i conftest.err conftest.$ac_ext
8209if $ac_preproc_ok
8210then :
8211
8212else case e in #(
8213 e) { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
8214printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
8215as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
8216See 'config.log' for more details" "$LINENO" 5; } ;;
8217esac
8218fi
8219
8220ac_ext=c
8221ac_cpp='$CPP $CPPFLAGS'
8222ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
8223ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
8224ac_compiler_gnu=$ac_cv_c_compiler_gnu
8225
8226
8227{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for egrep -e" >&5
8228printf %s "checking for egrep -e... " >&6; }
8229if test ${ac_cv_path_EGREP_TRADITIONAL+y}
8230then :
8231 printf %s "(cached) " >&6
8232else case e in #(
8233 e) if test -z "$EGREP_TRADITIONAL"; then
8234 ac_path_EGREP_TRADITIONAL_found=false
8235 # Loop through the user's path and test for each of PROGNAME-LIST
8236 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8237for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8238do
8239 IFS=$as_save_IFS
8240 case $as_dir in #(((
8241 '') as_dir=./ ;;
8242 */) ;;
8243 *) as_dir=$as_dir/ ;;
8244 esac
8245 for ac_prog in grep ggrep
8246 do
8247 for ac_exec_ext in '' $ac_executable_extensions; do
8248 ac_path_EGREP_TRADITIONAL="$as_dir$ac_prog$ac_exec_ext"
8249 as_fn_executable_p "$ac_path_EGREP_TRADITIONAL" || continue
8250# Check for GNU ac_path_EGREP_TRADITIONAL and select it if it is found.
8251 # Check for GNU $ac_path_EGREP_TRADITIONAL
8252case `"$ac_path_EGREP_TRADITIONAL" --version 2>&1` in #(
8253*GNU*)
8254 ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" ac_path_EGREP_TRADITIONAL_found=:;;
8255#(
8256*)
8257 ac_count=0
8258 printf %s 0123456789 >"conftest.in"
8259 while :
8260 do
8261 cat "conftest.in" "conftest.in" >"conftest.tmp"
8262 mv "conftest.tmp" "conftest.in"
8263 cp "conftest.in" "conftest.nl"
8264 printf "%s\n" 'EGREP_TRADITIONAL' >> "conftest.nl"
8265 "$ac_path_EGREP_TRADITIONAL" -E 'EGR(EP|AC)_TRADITIONAL$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8266 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8267 as_fn_arith $ac_count + 1 && ac_count=$as_val
8268 if test $ac_count -gt ${ac_path_EGREP_TRADITIONAL_max-0}; then
8269 # Best one so far, save it but keep looking for a better one
8270 ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL"
8271 ac_path_EGREP_TRADITIONAL_max=$ac_count
8272 fi
8273 # 10*(2^10) chars as input seems more than enough
8274 test $ac_count -gt 10 && break
8275 done
8276 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8277esac
8278
8279 $ac_path_EGREP_TRADITIONAL_found && break 3
8280 done
8281 done
8282 done
8283IFS=$as_save_IFS
8284 if test -z "$ac_cv_path_EGREP_TRADITIONAL"; then
8285 :
8286 fi
8287else
8288 ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL
8289fi
8290
8291 if test "$ac_cv_path_EGREP_TRADITIONAL"
8292then :
8293 ac_cv_path_EGREP_TRADITIONAL="$ac_cv_path_EGREP_TRADITIONAL -E"
8294else case e in #(
8295 e) if test -z "$EGREP_TRADITIONAL"; then
8296 ac_path_EGREP_TRADITIONAL_found=false
8297 # Loop through the user's path and test for each of PROGNAME-LIST
8298 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8299for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
8300do
8301 IFS=$as_save_IFS
8302 case $as_dir in #(((
8303 '') as_dir=./ ;;
8304 */) ;;
8305 *) as_dir=$as_dir/ ;;
8306 esac
8307 for ac_prog in egrep
8308 do
8309 for ac_exec_ext in '' $ac_executable_extensions; do
8310 ac_path_EGREP_TRADITIONAL="$as_dir$ac_prog$ac_exec_ext"
8311 as_fn_executable_p "$ac_path_EGREP_TRADITIONAL" || continue
8312# Check for GNU ac_path_EGREP_TRADITIONAL and select it if it is found.
8313 # Check for GNU $ac_path_EGREP_TRADITIONAL
8314case `"$ac_path_EGREP_TRADITIONAL" --version 2>&1` in #(
8315*GNU*)
8316 ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL" ac_path_EGREP_TRADITIONAL_found=:;;
8317#(
8318*)
8319 ac_count=0
8320 printf %s 0123456789 >"conftest.in"
8321 while :
8322 do
8323 cat "conftest.in" "conftest.in" >"conftest.tmp"
8324 mv "conftest.tmp" "conftest.in"
8325 cp "conftest.in" "conftest.nl"
8326 printf "%s\n" 'EGREP_TRADITIONAL' >> "conftest.nl"
8327 "$ac_path_EGREP_TRADITIONAL" 'EGR(EP|AC)_TRADITIONAL$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
8328 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
8329 as_fn_arith $ac_count + 1 && ac_count=$as_val
8330 if test $ac_count -gt ${ac_path_EGREP_TRADITIONAL_max-0}; then
8331 # Best one so far, save it but keep looking for a better one
8332 ac_cv_path_EGREP_TRADITIONAL="$ac_path_EGREP_TRADITIONAL"
8333 ac_path_EGREP_TRADITIONAL_max=$ac_count
8334 fi
8335 # 10*(2^10) chars as input seems more than enough
8336 test $ac_count -gt 10 && break
8337 done
8338 rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
8339esac
8340
8341 $ac_path_EGREP_TRADITIONAL_found && break 3
8342 done
8343 done
8344 done
8345IFS=$as_save_IFS
8346 if test -z "$ac_cv_path_EGREP_TRADITIONAL"; then
8347 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
8348 fi
8349else
8350 ac_cv_path_EGREP_TRADITIONAL=$EGREP_TRADITIONAL
8351fi
8352 ;;
8353esac
8354fi ;;
8355esac
8356fi
8357{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP_TRADITIONAL" >&5
8358printf "%s\n" "$ac_cv_path_EGREP_TRADITIONAL" >&6; }
8359 EGREP_TRADITIONAL=$ac_cv_path_EGREP_TRADITIONAL
8360
8361
8362 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2 or newer" >&5
8363printf %s "checking whether we are using the GNU C Library 2 or newer... " >&6; }
8364if test ${ac_cv_gnu_library_2+y}
8365then :
8366 printf %s "(cached) " >&6
8367else case e in #(
8368 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8369/* end confdefs.h. */
8370
8371#include <features.h>
8372#ifdef __GNU_LIBRARY__
8373 #if (__GLIBC__ >= 2) && !defined __UCLIBC__
8374 Lucky GNU user
8375 #endif
8376#endif
8377
8378_ACEOF
8379if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8380 $EGREP_TRADITIONAL "Lucky GNU user" >/dev/null 2>&1
8381then :
8382 ac_cv_gnu_library_2=yes
8383else case e in #(
8384 e) ac_cv_gnu_library_2=no ;;
8385esac
8386fi
8387rm -rf conftest*
8388
8389
8390 ;;
8391esac
8392fi
8393{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2" >&5
8394printf "%s\n" "$ac_cv_gnu_library_2" >&6; }
8395
8396 GLIBC2="$ac_cv_gnu_library_2"
8397
8398
8399
8400
8401 CFLAG_VISIBILITY=
8402 HAVE_VISIBILITY=0
8403 if test -n "$GCC"; then
8404 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the -Werror option is usable" >&5
8405printf %s "checking whether the -Werror option is usable... " >&6; }
8406if test ${gl_cv_cc_vis_werror+y}
8407then :
8408 printf %s "(cached) " >&6
8409else case e in #(
8410 e) gl_save_CFLAGS="$CFLAGS"
8411 CFLAGS="$CFLAGS -Werror"
8412 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8413/* end confdefs.h. */
8414
8415int
8416main (void)
8417{
8418
8419 ;
8420 return 0;
8421}
8422_ACEOF
8423if ac_fn_c_try_compile "$LINENO"
8424then :
8425 gl_cv_cc_vis_werror=yes
8426else case e in #(
8427 e) gl_cv_cc_vis_werror=no ;;
8428esac
8429fi
8430rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8431 CFLAGS="$gl_save_CFLAGS"
8432 ;;
8433esac
8434fi
8435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_vis_werror" >&5
8436printf "%s\n" "$gl_cv_cc_vis_werror" >&6; }
8437 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for simple visibility declarations" >&5
8438printf %s "checking for simple visibility declarations... " >&6; }
8439if test ${gl_cv_cc_visibility+y}
8440then :
8441 printf %s "(cached) " >&6
8442else case e in #(
8443 e) gl_save_CFLAGS="$CFLAGS"
8444 CFLAGS="$CFLAGS -fvisibility=hidden"
8445 if test $gl_cv_cc_vis_werror = yes; then
8446 CFLAGS="$CFLAGS -Werror"
8447 fi
8448 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8449/* end confdefs.h. */
8450extern __attribute__((__visibility__("hidden"))) int hiddenvar;
8451 extern __attribute__((__visibility__("default"))) int exportedvar;
8452 extern __attribute__((__visibility__("hidden"))) int hiddenfunc (void);
8453 extern __attribute__((__visibility__("default"))) int exportedfunc (void);
8454 void dummyfunc (void) {}
8455
8456int
8457main (void)
8458{
8459
8460 ;
8461 return 0;
8462}
8463_ACEOF
8464if ac_fn_c_try_compile "$LINENO"
8465then :
8466 gl_cv_cc_visibility=yes
8467else case e in #(
8468 e) gl_cv_cc_visibility=no ;;
8469esac
8470fi
8471rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
8472 CFLAGS="$gl_save_CFLAGS"
8473 ;;
8474esac
8475fi
8476{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_cc_visibility" >&5
8477printf "%s\n" "$gl_cv_cc_visibility" >&6; }
8478 if test $gl_cv_cc_visibility = yes; then
8479 CFLAG_VISIBILITY="-fvisibility=hidden"
8480 HAVE_VISIBILITY=1
8481 fi
8482 fi
8483
8484
8485
8486printf "%s\n" "#define HAVE_VISIBILITY $HAVE_VISIBILITY" >>confdefs.h
8487
8488
8489ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
8490if test "x$ac_cv_type_size_t" = xyes
8491then :
8492
8493else case e in #(
8494 e)
8495printf "%s\n" "#define size_t unsigned int" >>confdefs.h
8496 ;;
8497esac
8498fi
8499
8500
8501 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5
8502printf %s "checking for stdint.h... " >&6; }
8503if test ${gl_cv_header_stdint_h+y}
8504then :
8505 printf %s "(cached) " >&6
8506else case e in #(
8507 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8508/* end confdefs.h. */
8509#include <sys/types.h>
8510 #include <stdint.h>
8511int
8512main (void)
8513{
8514uintmax_t i = (uintmax_t) -1; return !i;
8515 ;
8516 return 0;
8517}
8518_ACEOF
8519if ac_fn_c_try_compile "$LINENO"
8520then :
8521 gl_cv_header_stdint_h=yes
8522else case e in #(
8523 e) gl_cv_header_stdint_h=no ;;
8524esac
8525fi
8526rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
8527esac
8528fi
8529{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_stdint_h" >&5
8530printf "%s\n" "$gl_cv_header_stdint_h" >&6; }
8531 if test $gl_cv_header_stdint_h = yes; then
8532
8533printf "%s\n" "#define HAVE_STDINT_H_WITH_UINTMAX 1" >>confdefs.h
8534
8535 fi
8536
8537# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
8538# for constant arguments. Useless!
8539{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
8540printf %s "checking for working alloca.h... " >&6; }
8541if test ${ac_cv_working_alloca_h+y}
8542then :
8543 printf %s "(cached) " >&6
8544else case e in #(
8545 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8546/* end confdefs.h. */
8547#include <alloca.h>
8548int
8549main (void)
8550{
8551char *p = (char *) alloca (2 * sizeof (int));
8552 if (p) return 0;
8553 ;
8554 return 0;
8555}
8556_ACEOF
8557if ac_fn_c_try_link "$LINENO"
8558then :
8559 ac_cv_working_alloca_h=yes
8560else case e in #(
8561 e) ac_cv_working_alloca_h=no ;;
8562esac
8563fi
8564rm -f core conftest.err conftest.$ac_objext conftest.beam \
8565 conftest$ac_exeext conftest.$ac_ext ;;
8566esac
8567fi
8568{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
8569printf "%s\n" "$ac_cv_working_alloca_h" >&6; }
8570if test $ac_cv_working_alloca_h = yes; then
8571
8572printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
8573
8574fi
8575
8576{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
8577printf %s "checking for alloca... " >&6; }
8578if test ${ac_cv_func_alloca_works+y}
8579then :
8580 printf %s "(cached) " >&6
8581else case e in #(
8582 e) ac_cv_func_alloca_works=$ac_cv_working_alloca_h
8583if test "$ac_cv_func_alloca_works" != yes
8584then :
8585 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8586/* end confdefs.h. */
8587#include <stdlib.h>
8588#include <stddef.h>
8589#ifndef alloca
8590# ifdef __GNUC__
8591# define alloca __builtin_alloca
8592# elif defined _MSC_VER
8593# include <malloc.h>
8594# define alloca _alloca
8595# else
8596# ifdef __cplusplus
8597extern "C"
8598# endif
8599void *alloca (size_t);
8600# endif
8601#endif
8602
8603int
8604main (void)
8605{
8606char *p = (char *) alloca (1);
8607 if (p) return 0;
8608 ;
8609 return 0;
8610}
8611_ACEOF
8612if ac_fn_c_try_link "$LINENO"
8613then :
8614 ac_cv_func_alloca_works=yes
8615fi
8616rm -f core conftest.err conftest.$ac_objext conftest.beam \
8617 conftest$ac_exeext conftest.$ac_ext
8618fi ;;
8619esac
8620fi
8621{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
8622printf "%s\n" "$ac_cv_func_alloca_works" >&6; }
8623
8624if test $ac_cv_func_alloca_works = yes; then
8625
8626printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h
8627
8628else
8629 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
8630# that cause trouble. Some versions do not even contain alloca or
8631# contain a buggy version. If you still want to use their alloca,
8632# use ar to extract alloca.o from them instead of compiling alloca.c.
8633
8634ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
8635
8636printf "%s\n" "#define C_ALLOCA 1" >>confdefs.h
8637
8638
8639{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
8640printf %s "checking stack direction for C alloca... " >&6; }
8641if test ${ac_cv_c_stack_direction+y}
8642then :
8643 printf %s "(cached) " >&6
8644else case e in #(
8645 e) if test "$cross_compiling" = yes
8646then :
8647 ac_cv_c_stack_direction=0
8648else case e in #(
8649 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8650/* end confdefs.h. */
8651$ac_includes_default
8652int
8653find_stack_direction (int *addr, int depth)
8654{
8655 int dir, dummy = 0;
8656 if (! addr)
8657 addr = &dummy;
8658 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
8659 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
8660 return dir + dummy;
8661}
8662
8663int
8664main (int argc, char **argv)
8665{
8666 return find_stack_direction (0, argc + !argv + 20) < 0;
8667}
8668_ACEOF
8669if ac_fn_c_try_run "$LINENO"
8670then :
8671 ac_cv_c_stack_direction=1
8672else case e in #(
8673 e) ac_cv_c_stack_direction=-1 ;;
8674esac
8675fi
8676rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8677 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
8678esac
8679fi
8680 ;;
8681esac
8682fi
8683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
8684printf "%s\n" "$ac_cv_c_stack_direction" >&6; }
8685printf "%s\n" "#define STACK_DIRECTION $ac_cv_c_stack_direction" >>confdefs.h
8686
8687
8688fi
8689
8690
8691ac_func=
8692for ac_item in $ac_func_c_list
8693do
8694 if test $ac_func; then
8695 ac_fn_c_check_func "$LINENO" $ac_func ac_cv_func_$ac_func
8696 if eval test \"x\$ac_cv_func_$ac_func\" = xyes; then
8697 echo "#define $ac_item 1" >> confdefs.h
8698 fi
8699 ac_func=
8700 else
8701 ac_func=$ac_item
8702 fi
8703done
8704
8705
8706{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
8707printf %s "checking for working mmap... " >&6; }
8708if test ${ac_cv_func_mmap_fixed_mapped+y}
8709then :
8710 printf %s "(cached) " >&6
8711else case e in #(
8712 e) if test "$cross_compiling" = yes
8713then :
8714 case "$host_os" in # ((
8715 # Guess yes on platforms where we know the result.
8716 linux*) ac_cv_func_mmap_fixed_mapped=yes ;;
8717 # If we don't know, assume the worst.
8718 *) ac_cv_func_mmap_fixed_mapped=no ;;
8719 esac
8720else case e in #(
8721 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8722/* end confdefs.h. */
8723$ac_includes_default
8724/* malloc might have been renamed as rpl_malloc. */
8725#undef malloc
8726
8727/* Thanks to Mike Haertel and Jim Avera for this test.
8728 Here is a matrix of mmap possibilities:
8729 mmap private not fixed
8730 mmap private fixed at somewhere currently unmapped
8731 mmap private fixed at somewhere already mapped
8732 mmap shared not fixed
8733 mmap shared fixed at somewhere currently unmapped
8734 mmap shared fixed at somewhere already mapped
8735 For private mappings, we should verify that changes cannot be read()
8736 back from the file, nor mmap's back from the file at a different
8737 address. (There have been systems where private was not correctly
8738 implemented like the infamous i386 svr4.0, and systems where the
8739 VM page cache was not coherent with the file system buffer cache
8740 like early versions of FreeBSD and possibly contemporary NetBSD.)
8741 For shared mappings, we should conversely verify that changes get
8742 propagated back to all the places they're supposed to be. */
8743
8744#include <fcntl.h>
8745#include <sys/mman.h>
8746
8747#ifndef getpagesize
8748/* Prefer sysconf to the legacy getpagesize function, as getpagesize has
8749 been removed from POSIX and is limited to page sizes that fit in 'int'. */
8750# ifdef _SC_PAGESIZE
8751# define getpagesize() sysconf (_SC_PAGESIZE)
8752# elif defined _SC_PAGE_SIZE
8753# define getpagesize() sysconf (_SC_PAGE_SIZE)
8754# elif HAVE_GETPAGESIZE
8755int getpagesize ();
8756# else
8757# ifdef HAVE_SYS_PARAM_H
8758# include <sys/param.h>
8759# ifdef EXEC_PAGESIZE
8760# define getpagesize() EXEC_PAGESIZE
8761# else /* no EXEC_PAGESIZE */
8762# ifdef NBPG
8763# define getpagesize() NBPG * CLSIZE
8764# ifndef CLSIZE
8765# define CLSIZE 1
8766# endif /* no CLSIZE */
8767# else /* no NBPG */
8768# ifdef NBPC
8769# define getpagesize() NBPC
8770# else /* no NBPC */
8771# ifdef PAGESIZE
8772# define getpagesize() PAGESIZE
8773# endif /* PAGESIZE */
8774# endif /* no NBPC */
8775# endif /* no NBPG */
8776# endif /* no EXEC_PAGESIZE */
8777# else /* no HAVE_SYS_PARAM_H */
8778# define getpagesize() 8192 /* punt totally */
8779# endif /* no HAVE_SYS_PARAM_H */
8780# endif
8781#endif
8782
8783int
8784main (void)
8785{
8786 char *data, *data2, *data3;
8787 const char *cdata2;
8788 long i, pagesize;
8789 int fd, fd2;
8790
8791 pagesize = getpagesize ();
8792
8793 /* First, make a file with some known garbage in it. */
8794 data = (char *) malloc (pagesize);
8795 if (!data)
8796 return 1;
8797 for (i = 0; i < pagesize; ++i)
8798 *(data + i) = rand ();
8799 umask (0);
8800 fd = creat ("conftest.mmap", 0600);
8801 if (fd < 0)
8802 return 2;
8803 if (write (fd, data, pagesize) != pagesize)
8804 return 3;
8805 close (fd);
8806
8807 /* Next, check that the tail of a page is zero-filled. File must have
8808 non-zero length, otherwise we risk SIGBUS for entire page. */
8809 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
8810 if (fd2 < 0)
8811 return 4;
8812 cdata2 = "";
8813 if (write (fd2, cdata2, 1) != 1)
8814 return 5;
8815 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
8816 if (data2 == MAP_FAILED)
8817 return 6;
8818 for (i = 0; i < pagesize; ++i)
8819 if (*(data2 + i))
8820 return 7;
8821 close (fd2);
8822 /* 'return 8;' not currently used. */
8823
8824 /* Next, try to mmap the file at a fixed address which already has
8825 something else allocated at it. If we can, also make sure that
8826 we see the same garbage. */
8827 fd = open ("conftest.mmap", O_RDWR);
8828 if (fd < 0)
8829 return 9;
8830 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
8831 MAP_PRIVATE | MAP_FIXED, fd, 0L))
8832 return 10;
8833 for (i = 0; i < pagesize; ++i)
8834 if (*(data + i) != *(data2 + i))
8835 return 11;
8836
8837 /* Finally, make sure that changes to the mapped area do not
8838 percolate back to the file as seen by read(). (This is a bug on
8839 some variants of i386 svr4.0.) */
8840 for (i = 0; i < pagesize; ++i)
8841 *(data2 + i) = *(data2 + i) + 1;
8842 data3 = (char *) malloc (pagesize);
8843 if (!data3)
8844 return 12;
8845 if (read (fd, data3, pagesize) != pagesize)
8846 return 13;
8847 for (i = 0; i < pagesize; ++i)
8848 if (*(data + i) != *(data3 + i))
8849 return 14;
8850 close (fd);
8851 free (data);
8852 free (data3);
8853 return 0;
8854}
8855_ACEOF
8856if ac_fn_c_try_run "$LINENO"
8857then :
8858 ac_cv_func_mmap_fixed_mapped=yes
8859else case e in #(
8860 e) ac_cv_func_mmap_fixed_mapped=no ;;
8861esac
8862fi
8863rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8864 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
8865esac
8866fi
8867 ;;
8868esac
8869fi
8870{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
8871printf "%s\n" "$ac_cv_func_mmap_fixed_mapped" >&6; }
8872if test $ac_cv_func_mmap_fixed_mapped = yes; then
8873
8874printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h
8875
8876fi
8877rm -f conftest.mmap conftest.txt
8878
8879
8880
8881 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether integer division by zero raises SIGFPE" >&5
8882printf %s "checking whether integer division by zero raises SIGFPE... " >&6; }
8883if test ${gt_cv_int_divbyzero_sigfpe+y}
8884then :
8885 printf %s "(cached) " >&6
8886else case e in #(
8887 e)
8888 gt_cv_int_divbyzero_sigfpe=
8889 case "$host_os" in
8890 macos* | darwin[6-9]* | darwin[1-9][0-9]*)
8891 # On Mac OS X 10.2 or newer, just assume the same as when cross-
8892 # compiling. If we were to perform the real test, 1 Crash Report
8893 # dialog window would pop up.
8894 case "$host_cpu" in
8895 i[34567]86 | x86_64)
8896 gt_cv_int_divbyzero_sigfpe="guessing yes" ;;
8897 esac
8898 ;;
8899 esac
8900 if test -z "$gt_cv_int_divbyzero_sigfpe"; then
8901 if test "$cross_compiling" = yes
8902then :
8903
8904 # Guess based on the CPU.
8905 case "$host_cpu" in
8906 alpha* | i[34567]86 | x86_64 | m68k | s390*)
8907 gt_cv_int_divbyzero_sigfpe="guessing yes";;
8908 *)
8909 gt_cv_int_divbyzero_sigfpe="guessing no";;
8910 esac
8911
8912else case e in #(
8913 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8914/* end confdefs.h. */
8915
8916#include <stdlib.h> /* for exit() */
8917#include <signal.h>
8918#if !(defined _WIN32 && !defined __CYGWIN__)
8919#include <unistd.h> /* for _exit() */
8920#endif
8921
8922static void
8923sigfpe_handler (int sig)
8924{
8925 /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */
8926 _exit (sig != SIGFPE);
8927}
8928
8929int x = 1;
8930int y = 0;
8931int z;
8932int inan;
8933
8934int main ()
8935{
8936 signal (SIGFPE, sigfpe_handler);
8937/* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */
8938#if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP)
8939 signal (SIGTRAP, sigfpe_handler);
8940#endif
8941/* Linux/SPARC yields signal SIGILL. */
8942#if defined (__sparc__) && defined (__linux__)
8943 signal (SIGILL, sigfpe_handler);
8944#endif
8945
8946 z = x / y;
8947 inan = y / y;
8948 exit (2);
8949}
8950
8951_ACEOF
8952if ac_fn_c_try_run "$LINENO"
8953then :
8954 gt_cv_int_divbyzero_sigfpe=yes
8955else case e in #(
8956 e) gt_cv_int_divbyzero_sigfpe=no ;;
8957esac
8958fi
8959rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8960 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
8961esac
8962fi
8963
8964 fi
8965 ;;
8966esac
8967fi
8968{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_int_divbyzero_sigfpe" >&5
8969printf "%s\n" "$gt_cv_int_divbyzero_sigfpe" >&6; }
8970 case "$gt_cv_int_divbyzero_sigfpe" in
8971 *yes) value=1 ;;
8972 *) value=0 ;;
8973 esac
8974
8975printf "%s\n" "#define INTDIV0_RAISES_SIGFPE $value" >>confdefs.h
8976
8977
8978
8979 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5
8980printf %s "checking for inttypes.h... " >&6; }
8981if test ${gl_cv_header_inttypes_h+y}
8982then :
8983 printf %s "(cached) " >&6
8984else case e in #(
8985 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8986/* end confdefs.h. */
8987
8988#include <sys/types.h>
8989#include <inttypes.h>
8990
8991int
8992main (void)
8993{
8994uintmax_t i = (uintmax_t) -1; return !i;
8995 ;
8996 return 0;
8997}
8998_ACEOF
8999if ac_fn_c_try_compile "$LINENO"
9000then :
9001 gl_cv_header_inttypes_h=yes
9002else case e in #(
9003 e) gl_cv_header_inttypes_h=no ;;
9004esac
9005fi
9006rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
9007esac
9008fi
9009{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_inttypes_h" >&5
9010printf "%s\n" "$gl_cv_header_inttypes_h" >&6; }
9011 if test $gl_cv_header_inttypes_h = yes; then
9012
9013printf "%s\n" "#define HAVE_INTTYPES_H_WITH_UINTMAX 1" >>confdefs.h
9014
9015 fi
9016
9017
9018 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
9019printf %s "checking for unsigned long long int... " >&6; }
9020if test ${ac_cv_type_unsigned_long_long_int+y}
9021then :
9022 printf %s "(cached) " >&6
9023else case e in #(
9024 e) ac_cv_type_unsigned_long_long_int=yes
9025 case $ac_prog_cc_stdc in
9026 no | c89) ;;
9027 *)
9028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9029/* end confdefs.h. */
9030
9031 /* For now, do not test the preprocessor; as of 2007 there are too many
9032 implementations with broken preprocessors. Perhaps this can
9033 be revisited in 2012. In the meantime, code should not expect
9034 #if to work with literals wider than 32 bits. */
9035 /* Test literals. */
9036 long long int ll = 9223372036854775807ll;
9037 long long int nll = -9223372036854775807LL;
9038 unsigned long long int ull = 18446744073709551615ULL;
9039 /* Test constant expressions. */
9040 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
9041 ? 1 : -1)];
9042 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
9043 ? 1 : -1)];
9044 int i = 63;
9045int
9046main (void)
9047{
9048/* Test availability of runtime routines for shift and division. */
9049 long long int llmax = 9223372036854775807ll;
9050 unsigned long long int ullmax = 18446744073709551615ull;
9051 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
9052 | (llmax / ll) | (llmax % ll)
9053 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
9054 | (ullmax / ull) | (ullmax % ull));
9055 ;
9056 return 0;
9057}
9058
9059_ACEOF
9060if ac_fn_c_try_link "$LINENO"
9061then :
9062
9063else case e in #(
9064 e) ac_cv_type_unsigned_long_long_int=no ;;
9065esac
9066fi
9067rm -f core conftest.err conftest.$ac_objext conftest.beam \
9068 conftest$ac_exeext conftest.$ac_ext;;
9069 esac ;;
9070esac
9071fi
9072{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
9073printf "%s\n" "$ac_cv_type_unsigned_long_long_int" >&6; }
9074 if test $ac_cv_type_unsigned_long_long_int = yes; then
9075
9076printf "%s\n" "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
9077
9078 fi
9079
9080
9081
9082
9083 if test $gl_cv_header_inttypes_h = no && test $gl_cv_header_stdint_h = no; then
9084
9085 test $ac_cv_type_unsigned_long_long_int = yes \
9086 && ac_type='unsigned long long' \
9087 || ac_type='unsigned long'
9088
9089printf "%s\n" "#define uintmax_t $ac_type" >>confdefs.h
9090
9091 else
9092
9093printf "%s\n" "#define HAVE_UINTMAX_T 1" >>confdefs.h
9094
9095 fi
9096
9097
9098
9099
9100
9101
9102
9103 # Check whether --enable-threads was given.
9104if test ${enable_threads+y}
9105then :
9106 enableval=$enable_threads; gl_use_threads=$enableval
9107else case e in #(
9108 e) if test -n "$gl_use_threads_default"; then
9109 gl_use_threads="$gl_use_threads_default"
9110 else
9111 case "$host_os" in
9112 osf*) gl_use_threads=no ;;
9113 cygwin*)
9114 case `uname -r` in
9115 1.[0-5].*) gl_use_threads=no ;;
9116 *) gl_use_threads=yes ;;
9117 esac
9118 ;;
9119 mingw*)
9120 case "$gl_use_winpthreads_default" in
9121 yes) gl_use_threads=posix ;;
9122 no) gl_use_threads=windows ;;
9123 *) gl_use_threads=yes ;;
9124 esac
9125 ;;
9126 *) gl_use_threads=yes ;;
9127 esac
9128 fi
9129 ;;
9130esac
9131fi
9132
9133 if test "$gl_use_threads" = yes \
9134 || test "$gl_use_threads" = isoc \
9135 || test "$gl_use_threads" = posix \
9136 || test "$gl_use_threads" = isoc+posix; then
9137 # For using <threads.h> or <pthread.h>:
9138
9139
9140 if test -z "$gl_anythreadlib_early_done"; then
9141 case "$host_os" in
9142 osf*)
9143 # On OSF/1, the compiler needs the flag -D_REENTRANT so that it
9144 # groks <pthread.h>. cc also understands the flag -pthread, but
9145 # we don't use it because 1. gcc-2.95 doesn't understand -pthread,
9146 # 2. putting a flag into CPPFLAGS that has an effect on the linker
9147 # causes the AC_LINK_IFELSE test below to succeed unexpectedly,
9148 # leading to wrong values of LIBTHREAD and LTLIBTHREAD.
9149 CPPFLAGS="$CPPFLAGS -D_REENTRANT"
9150 ;;
9151 esac
9152 # Some systems optimize for single-threaded programs by default, and
9153 # need special flags to disable these optimizations. For example, the
9154 # definition of 'errno' in <errno.h>.
9155 case "$host_os" in
9156 aix* | freebsd*) CPPFLAGS="$CPPFLAGS -D_THREAD_SAFE" ;;
9157 solaris*) CPPFLAGS="$CPPFLAGS -D_REENTRANT" ;;
9158 esac
9159 gl_anythreadlib_early_done=done
9160 fi
9161
9162 fi
9163
9164
9165
9166
9167
9168
9169
9170 gl_threads_api=none
9171 LIBTHREAD=
9172 LTLIBTHREAD=
9173 LIBMULTITHREAD=
9174 LTLIBMULTITHREAD=
9175 if test "$gl_use_threads" != no; then
9176
9177
9178 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether imported symbols can be declared weak" >&5
9179printf %s "checking whether imported symbols can be declared weak... " >&6; }
9180if test ${gl_cv_have_weak+y}
9181then :
9182 printf %s "(cached) " >&6
9183else case e in #(
9184 e) case "$host_os" in
9185 cygwin*)
9186 gl_cv_have_weak="guessing no"
9187 ;;
9188 *)
9189 gl_cv_have_weak=no
9190 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9191/* end confdefs.h. */
9192extern void xyzzy ();
9193#pragma weak xyzzy
9194int
9195main (void)
9196{
9197xyzzy();
9198 ;
9199 return 0;
9200}
9201_ACEOF
9202if ac_fn_c_try_link "$LINENO"
9203then :
9204 gl_cv_have_weak=maybe
9205fi
9206rm -f core conftest.err conftest.$ac_objext conftest.beam \
9207 conftest$ac_exeext conftest.$ac_ext
9208 if test $gl_cv_have_weak = maybe; then
9209 if test "$cross_compiling" = yes
9210then :
9211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9212/* end confdefs.h. */
9213#ifdef __ELF__
9214 Extensible Linking Format
9215 #endif
9216
9217_ACEOF
9218if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9219 $EGREP_TRADITIONAL "Extensible Linking Format" >/dev/null 2>&1
9220then :
9221 gl_cv_have_weak="guessing yes"
9222else case e in #(
9223 e) gl_cv_have_weak="guessing no" ;;
9224esac
9225fi
9226rm -rf conftest*
9227
9228
9229else case e in #(
9230 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9231/* end confdefs.h. */
9232
9233#include <stdio.h>
9234#pragma weak fputs
9235int main ()
9236{
9237 return (fputs == NULL);
9238}
9239_ACEOF
9240if ac_fn_c_try_run "$LINENO"
9241then :
9242 gl_cv_have_weak=yes
9243else case e in #(
9244 e) gl_cv_have_weak=no ;;
9245esac
9246fi
9247rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9248 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
9249esac
9250fi
9251
9252 fi
9253 ;;
9254 esac
9255 case " $LDFLAGS " in
9256 *" -static "*) gl_cv_have_weak=no ;;
9257 esac
9258 case "$gl_cv_have_weak" in
9259 *yes)
9260 case "$host_os" in
9261 freebsd* | dragonfly* | midnightbsd*)
9262 : > conftest1.c
9263 $CC $CPPFLAGS $CFLAGS $LDFLAGS -fPIC -shared -o libempty.so conftest1.c -lpthread >&5 2>&1
9264 cat <<EOF > conftest2.c
9265#include <pthread.h>
9266#pragma weak pthread_mutexattr_gettype
9267int main ()
9268{
9269 return (pthread_mutexattr_gettype != NULL);
9270}
9271EOF
9272 $CC $CPPFLAGS $CFLAGS $LDFLAGS -o conftest conftest2.c libempty.so >&5 2>&1 \
9273 || gl_cv_have_weak=no
9274 rm -f conftest1.c libempty.so conftest2.c conftest
9275 ;;
9276 esac
9277 ;;
9278 esac
9279 ;;
9280esac
9281fi
9282{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_have_weak" >&5
9283printf "%s\n" "$gl_cv_have_weak" >&6; }
9284 case "$gl_cv_have_weak" in
9285 *yes)
9286
9287printf "%s\n" "#define HAVE_WEAK_SYMBOLS 1" >>confdefs.h
9288
9289 ;;
9290 esac
9291
9292 if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then
9293
9294 :
9295 fi
9296 if test "$gl_use_threads" = isoc || test "$gl_use_threads" = isoc+posix; then
9297
9298 gl_have_isoc_threads="$ac_cv_header_threads_h"
9299 fi
9300 if test "$gl_use_threads" = yes \
9301 || test "$gl_use_threads" = posix \
9302 || test "$gl_use_threads" = isoc+posix; then
9303
9304
9305 if test -z "$gl_pthreadlib_body_done"; then
9306 gl_pthread_api=no
9307 LIBPTHREAD=
9308 LIBPMULTITHREAD=
9309 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
9310 # it groks <pthread.h>. It's added above, in gl_ANYTHREADLIB_EARLY.
9311 ac_fn_c_check_header_compile "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
9312if test "x$ac_cv_header_pthread_h" = xyes
9313then :
9314 gl_have_pthread_h=yes
9315else case e in #(
9316 e) gl_have_pthread_h=no ;;
9317esac
9318fi
9319
9320 if test "$gl_have_pthread_h" = yes; then
9321 # Other possible tests:
9322 # -lpthreads (FSU threads, PCthreads)
9323 # -lgthreads
9324 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
9325 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
9326 # the second one only in libpthread, and lock.c needs it.
9327 #
9328 # If -pthread works, prefer it to -lpthread, since Ubuntu 14.04
9329 # needs -pthread for some reason. See:
9330 # https://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
9331 save_LIBS=$LIBS
9332 for gl_pthread in '' '-pthread'; do
9333 LIBS="$LIBS $gl_pthread"
9334 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9335/* end confdefs.h. */
9336#include <pthread.h>
9337 pthread_mutex_t m;
9338 pthread_mutexattr_t ma;
9339
9340int
9341main (void)
9342{
9343pthread_mutex_lock (&m);
9344 pthread_mutexattr_init (&ma);
9345 ;
9346 return 0;
9347}
9348_ACEOF
9349if ac_fn_c_try_link "$LINENO"
9350then :
9351 gl_pthread_api=yes
9352 LIBPTHREAD=$gl_pthread
9353 LIBPMULTITHREAD=$gl_pthread
9354fi
9355rm -f core conftest.err conftest.$ac_objext conftest.beam \
9356 conftest$ac_exeext conftest.$ac_ext
9357 LIBS=$save_LIBS
9358 test $gl_pthread_api = yes && break
9359 done
9360 echo "$as_me:9360: gl_pthread_api=$gl_pthread_api" >&5
9361 echo "$as_me:9361: LIBPTHREAD=$LIBPTHREAD" >&5
9362
9363 gl_pthread_in_glibc=no
9364 # On Linux with glibc >= 2.34, libc contains the fully functional
9365 # pthread functions.
9366 case "$host_os" in
9367 linux*)
9368 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9369/* end confdefs.h. */
9370#include <features.h>
9371 #ifdef __GNU_LIBRARY__
9372 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 34) || (__GLIBC__ > 2)
9373 Lucky user
9374 #endif
9375 #endif
9376
9377_ACEOF
9378if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9379 $EGREP_TRADITIONAL "Lucky user" >/dev/null 2>&1
9380then :
9381 gl_pthread_in_glibc=yes
9382fi
9383rm -rf conftest*
9384
9385 ;;
9386 esac
9387 echo "$as_me:9387: gl_pthread_in_glibc=$gl_pthread_in_glibc" >&5
9388
9389 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
9390 # since it is defined as a macro on OSF/1.)
9391 if test $gl_pthread_api = yes && test -z "$LIBPTHREAD"; then
9392 # The program links fine without libpthread. But it may actually
9393 # need to link with libpthread in order to create multiple threads.
9394 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
9395printf %s "checking for pthread_kill in -lpthread... " >&6; }
9396if test ${ac_cv_lib_pthread_pthread_kill+y}
9397then :
9398 printf %s "(cached) " >&6
9399else case e in #(
9400 e) ac_check_lib_save_LIBS=$LIBS
9401LIBS="-lpthread $LIBS"
9402cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9403/* end confdefs.h. */
9404
9405/* Override any GCC internal prototype to avoid an error.
9406 Use char because int might match the return type of a GCC
9407 builtin and then its argument prototype would still apply.
9408 The 'extern "C"' is for builds by C++ compilers;
9409 although this is not generally supported in C code supporting it here
9410 has little cost and some practical benefit (sr 110532). */
9411#ifdef __cplusplus
9412extern "C"
9413#endif
9414char pthread_kill (void);
9415int
9416main (void)
9417{
9418return pthread_kill ();
9419 ;
9420 return 0;
9421}
9422_ACEOF
9423if ac_fn_c_try_link "$LINENO"
9424then :
9425 ac_cv_lib_pthread_pthread_kill=yes
9426else case e in #(
9427 e) ac_cv_lib_pthread_pthread_kill=no ;;
9428esac
9429fi
9430rm -f core conftest.err conftest.$ac_objext conftest.beam \
9431 conftest$ac_exeext conftest.$ac_ext
9432LIBS=$ac_check_lib_save_LIBS ;;
9433esac
9434fi
9435{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
9436printf "%s\n" "$ac_cv_lib_pthread_pthread_kill" >&6; }
9437if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
9438then :
9439 if test $gl_pthread_in_glibc = yes; then
9440 LIBPMULTITHREAD=
9441 else
9442 LIBPMULTITHREAD=-lpthread
9443 # On Solaris and HP-UX, most pthread functions exist also in libc.
9444 # Therefore pthread_in_use() needs to actually try to create a
9445 # thread: pthread_create from libc will fail, whereas
9446 # pthread_create will actually create a thread.
9447 # On Solaris 10 or newer, this test is no longer needed, because
9448 # libc contains the fully functional pthread functions.
9449 case "$host_os" in
9450 solaris | solaris2.1-9 | solaris2.1-9.* | hpux*)
9451
9452printf "%s\n" "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
9453
9454 esac
9455 fi
9456
9457fi
9458
9459 elif test $gl_pthread_api != yes; then
9460 # Some library is needed. Try libpthread and libc_r.
9461 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
9462printf %s "checking for pthread_kill in -lpthread... " >&6; }
9463if test ${ac_cv_lib_pthread_pthread_kill+y}
9464then :
9465 printf %s "(cached) " >&6
9466else case e in #(
9467 e) ac_check_lib_save_LIBS=$LIBS
9468LIBS="-lpthread $LIBS"
9469cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9470/* end confdefs.h. */
9471
9472/* Override any GCC internal prototype to avoid an error.
9473 Use char because int might match the return type of a GCC
9474 builtin and then its argument prototype would still apply.
9475 The 'extern "C"' is for builds by C++ compilers;
9476 although this is not generally supported in C code supporting it here
9477 has little cost and some practical benefit (sr 110532). */
9478#ifdef __cplusplus
9479extern "C"
9480#endif
9481char pthread_kill (void);
9482int
9483main (void)
9484{
9485return pthread_kill ();
9486 ;
9487 return 0;
9488}
9489_ACEOF
9490if ac_fn_c_try_link "$LINENO"
9491then :
9492 ac_cv_lib_pthread_pthread_kill=yes
9493else case e in #(
9494 e) ac_cv_lib_pthread_pthread_kill=no ;;
9495esac
9496fi
9497rm -f core conftest.err conftest.$ac_objext conftest.beam \
9498 conftest$ac_exeext conftest.$ac_ext
9499LIBS=$ac_check_lib_save_LIBS ;;
9500esac
9501fi
9502{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
9503printf "%s\n" "$ac_cv_lib_pthread_pthread_kill" >&6; }
9504if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
9505then :
9506 gl_pthread_api=yes
9507 LIBPTHREAD=-lpthread
9508 LIBPMULTITHREAD=-lpthread
9509fi
9510
9511 if test $gl_pthread_api != yes; then
9512 # For FreeBSD 4.
9513 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
9514printf %s "checking for pthread_kill in -lc_r... " >&6; }
9515if test ${ac_cv_lib_c_r_pthread_kill+y}
9516then :
9517 printf %s "(cached) " >&6
9518else case e in #(
9519 e) ac_check_lib_save_LIBS=$LIBS
9520LIBS="-lc_r $LIBS"
9521cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9522/* end confdefs.h. */
9523
9524/* Override any GCC internal prototype to avoid an error.
9525 Use char because int might match the return type of a GCC
9526 builtin and then its argument prototype would still apply.
9527 The 'extern "C"' is for builds by C++ compilers;
9528 although this is not generally supported in C code supporting it here
9529 has little cost and some practical benefit (sr 110532). */
9530#ifdef __cplusplus
9531extern "C"
9532#endif
9533char pthread_kill (void);
9534int
9535main (void)
9536{
9537return pthread_kill ();
9538 ;
9539 return 0;
9540}
9541_ACEOF
9542if ac_fn_c_try_link "$LINENO"
9543then :
9544 ac_cv_lib_c_r_pthread_kill=yes
9545else case e in #(
9546 e) ac_cv_lib_c_r_pthread_kill=no ;;
9547esac
9548fi
9549rm -f core conftest.err conftest.$ac_objext conftest.beam \
9550 conftest$ac_exeext conftest.$ac_ext
9551LIBS=$ac_check_lib_save_LIBS ;;
9552esac
9553fi
9554{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
9555printf "%s\n" "$ac_cv_lib_c_r_pthread_kill" >&6; }
9556if test "x$ac_cv_lib_c_r_pthread_kill" = xyes
9557then :
9558 gl_pthread_api=yes
9559 LIBPTHREAD=-lc_r
9560 LIBPMULTITHREAD=-lc_r
9561fi
9562
9563 fi
9564 fi
9565 echo "$as_me:9565: LIBPMULTITHREAD=$LIBPMULTITHREAD" >&5
9566 fi
9567 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether POSIX threads API is available" >&5
9568printf %s "checking whether POSIX threads API is available... " >&6; }
9569 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_pthread_api" >&5
9570printf "%s\n" "$gl_pthread_api" >&6; }
9571
9572
9573 if test $gl_pthread_api = yes; then
9574
9575printf "%s\n" "#define HAVE_PTHREAD_API 1" >>confdefs.h
9576
9577 fi
9578
9579 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9580/* end confdefs.h. */
9581#include <sched.h>
9582int
9583main (void)
9584{
9585sched_yield ();
9586 ;
9587 return 0;
9588}
9589_ACEOF
9590if ac_fn_c_try_link "$LINENO"
9591then :
9592 LIB_SCHED_YIELD=
9593
9594else case e in #(
9595 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
9596printf %s "checking for sched_yield in -lrt... " >&6; }
9597if test ${ac_cv_lib_rt_sched_yield+y}
9598then :
9599 printf %s "(cached) " >&6
9600else case e in #(
9601 e) ac_check_lib_save_LIBS=$LIBS
9602LIBS="-lrt $LIBS"
9603cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9604/* end confdefs.h. */
9605
9606/* Override any GCC internal prototype to avoid an error.
9607 Use char because int might match the return type of a GCC
9608 builtin and then its argument prototype would still apply.
9609 The 'extern "C"' is for builds by C++ compilers;
9610 although this is not generally supported in C code supporting it here
9611 has little cost and some practical benefit (sr 110532). */
9612#ifdef __cplusplus
9613extern "C"
9614#endif
9615char sched_yield (void);
9616int
9617main (void)
9618{
9619return sched_yield ();
9620 ;
9621 return 0;
9622}
9623_ACEOF
9624if ac_fn_c_try_link "$LINENO"
9625then :
9626 ac_cv_lib_rt_sched_yield=yes
9627else case e in #(
9628 e) ac_cv_lib_rt_sched_yield=no ;;
9629esac
9630fi
9631rm -f core conftest.err conftest.$ac_objext conftest.beam \
9632 conftest$ac_exeext conftest.$ac_ext
9633LIBS=$ac_check_lib_save_LIBS ;;
9634esac
9635fi
9636{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
9637printf "%s\n" "$ac_cv_lib_rt_sched_yield" >&6; }
9638if test "x$ac_cv_lib_rt_sched_yield" = xyes
9639then :
9640 LIB_SCHED_YIELD=-lrt
9641else case e in #(
9642 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lposix4" >&5
9643printf %s "checking for sched_yield in -lposix4... " >&6; }
9644if test ${ac_cv_lib_posix4_sched_yield+y}
9645then :
9646 printf %s "(cached) " >&6
9647else case e in #(
9648 e) ac_check_lib_save_LIBS=$LIBS
9649LIBS="-lposix4 $LIBS"
9650cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9651/* end confdefs.h. */
9652
9653/* Override any GCC internal prototype to avoid an error.
9654 Use char because int might match the return type of a GCC
9655 builtin and then its argument prototype would still apply.
9656 The 'extern "C"' is for builds by C++ compilers;
9657 although this is not generally supported in C code supporting it here
9658 has little cost and some practical benefit (sr 110532). */
9659#ifdef __cplusplus
9660extern "C"
9661#endif
9662char sched_yield (void);
9663int
9664main (void)
9665{
9666return sched_yield ();
9667 ;
9668 return 0;
9669}
9670_ACEOF
9671if ac_fn_c_try_link "$LINENO"
9672then :
9673 ac_cv_lib_posix4_sched_yield=yes
9674else case e in #(
9675 e) ac_cv_lib_posix4_sched_yield=no ;;
9676esac
9677fi
9678rm -f core conftest.err conftest.$ac_objext conftest.beam \
9679 conftest$ac_exeext conftest.$ac_ext
9680LIBS=$ac_check_lib_save_LIBS ;;
9681esac
9682fi
9683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_yield" >&5
9684printf "%s\n" "$ac_cv_lib_posix4_sched_yield" >&6; }
9685if test "x$ac_cv_lib_posix4_sched_yield" = xyes
9686then :
9687 LIB_SCHED_YIELD=-lposix4
9688fi
9689 ;;
9690esac
9691fi
9692
9693 ;;
9694esac
9695fi
9696rm -f core conftest.err conftest.$ac_objext conftest.beam \
9697 conftest$ac_exeext conftest.$ac_ext
9698
9699
9700 gl_pthreadlib_body_done=done
9701 fi
9702
9703 LIBTHREAD=$LIBPTHREAD LTLIBTHREAD=$LIBPTHREAD
9704 LIBMULTITHREAD=$LIBPMULTITHREAD LTLIBMULTITHREAD=$LIBPMULTITHREAD
9705 if test $gl_pthread_api = yes; then
9706 if test "$gl_use_threads" = isoc+posix && test "$gl_have_isoc_threads" = yes; then
9707 gl_threads_api='isoc+posix'
9708
9709printf "%s\n" "#define USE_ISOC_AND_POSIX_THREADS 1" >>confdefs.h
9710
9711 LIBTHREAD= LTLIBTHREAD=
9712 else
9713 gl_threads_api=posix
9714
9715printf "%s\n" "#define USE_POSIX_THREADS 1" >>confdefs.h
9716
9717 if test -z "$LIBMULTITHREAD" && test -z "$LTLIBMULTITHREAD"; then
9718
9719printf "%s\n" "#define USE_POSIX_THREADS_FROM_LIBC 1" >>confdefs.h
9720
9721 else
9722 if case "$gl_cv_have_weak" in *yes) true;; *) false;; esac; then
9723
9724printf "%s\n" "#define USE_POSIX_THREADS_WEAK 1" >>confdefs.h
9725
9726 LIBTHREAD= LTLIBTHREAD=
9727 else
9728 case "$host_os" in
9729 freebsd* | dragonfly* | midnightbsd*)
9730 if test "x$LIBTHREAD" != "x$LIBMULTITHREAD"; then
9731
9732printf "%s\n" "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
9733
9734 fi
9735 ;;
9736 esac
9737 fi
9738 fi
9739 fi
9740 fi
9741 fi
9742 if test $gl_threads_api = none; then
9743 if test "$gl_use_threads" = isoc && test "$gl_have_isoc_threads" = yes; then
9744
9745
9746
9747 if test -z "$gl_stdthreadlib_body_done"; then
9748
9749
9750 case "$host_os" in
9751 mingw*)
9752 LIBSTDTHREAD=
9753 ;;
9754 *)
9755
9756
9757 if test -z "$gl_pthreadlib_body_done"; then
9758 gl_pthread_api=no
9759 LIBPTHREAD=
9760 LIBPMULTITHREAD=
9761 # On OSF/1, the compiler needs the flag -pthread or -D_REENTRANT so that
9762 # it groks <pthread.h>. It's added above, in gl_ANYTHREADLIB_EARLY.
9763 ac_fn_c_check_header_compile "$LINENO" "pthread.h" "ac_cv_header_pthread_h" "$ac_includes_default"
9764if test "x$ac_cv_header_pthread_h" = xyes
9765then :
9766 gl_have_pthread_h=yes
9767else case e in #(
9768 e) gl_have_pthread_h=no ;;
9769esac
9770fi
9771
9772 if test "$gl_have_pthread_h" = yes; then
9773 # Other possible tests:
9774 # -lpthreads (FSU threads, PCthreads)
9775 # -lgthreads
9776 # Test whether both pthread_mutex_lock and pthread_mutexattr_init exist
9777 # in libc. IRIX 6.5 has the first one in both libc and libpthread, but
9778 # the second one only in libpthread, and lock.c needs it.
9779 #
9780 # If -pthread works, prefer it to -lpthread, since Ubuntu 14.04
9781 # needs -pthread for some reason. See:
9782 # https://lists.gnu.org/r/bug-gnulib/2014-09/msg00023.html
9783 save_LIBS=$LIBS
9784 for gl_pthread in '' '-pthread'; do
9785 LIBS="$LIBS $gl_pthread"
9786 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9787/* end confdefs.h. */
9788#include <pthread.h>
9789 pthread_mutex_t m;
9790 pthread_mutexattr_t ma;
9791
9792int
9793main (void)
9794{
9795pthread_mutex_lock (&m);
9796 pthread_mutexattr_init (&ma);
9797 ;
9798 return 0;
9799}
9800_ACEOF
9801if ac_fn_c_try_link "$LINENO"
9802then :
9803 gl_pthread_api=yes
9804 LIBPTHREAD=$gl_pthread
9805 LIBPMULTITHREAD=$gl_pthread
9806fi
9807rm -f core conftest.err conftest.$ac_objext conftest.beam \
9808 conftest$ac_exeext conftest.$ac_ext
9809 LIBS=$save_LIBS
9810 test $gl_pthread_api = yes && break
9811 done
9812 echo "$as_me:9812: gl_pthread_api=$gl_pthread_api" >&5
9813 echo "$as_me:9813: LIBPTHREAD=$LIBPTHREAD" >&5
9814
9815 gl_pthread_in_glibc=no
9816 # On Linux with glibc >= 2.34, libc contains the fully functional
9817 # pthread functions.
9818 case "$host_os" in
9819 linux*)
9820 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9821/* end confdefs.h. */
9822#include <features.h>
9823 #ifdef __GNU_LIBRARY__
9824 #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 34) || (__GLIBC__ > 2)
9825 Lucky user
9826 #endif
9827 #endif
9828
9829_ACEOF
9830if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9831 $EGREP_TRADITIONAL "Lucky user" >/dev/null 2>&1
9832then :
9833 gl_pthread_in_glibc=yes
9834fi
9835rm -rf conftest*
9836
9837 ;;
9838 esac
9839 echo "$as_me:9839: gl_pthread_in_glibc=$gl_pthread_in_glibc" >&5
9840
9841 # Test for libpthread by looking for pthread_kill. (Not pthread_self,
9842 # since it is defined as a macro on OSF/1.)
9843 if test $gl_pthread_api = yes && test -z "$LIBPTHREAD"; then
9844 # The program links fine without libpthread. But it may actually
9845 # need to link with libpthread in order to create multiple threads.
9846 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
9847printf %s "checking for pthread_kill in -lpthread... " >&6; }
9848if test ${ac_cv_lib_pthread_pthread_kill+y}
9849then :
9850 printf %s "(cached) " >&6
9851else case e in #(
9852 e) ac_check_lib_save_LIBS=$LIBS
9853LIBS="-lpthread $LIBS"
9854cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9855/* end confdefs.h. */
9856
9857/* Override any GCC internal prototype to avoid an error.
9858 Use char because int might match the return type of a GCC
9859 builtin and then its argument prototype would still apply.
9860 The 'extern "C"' is for builds by C++ compilers;
9861 although this is not generally supported in C code supporting it here
9862 has little cost and some practical benefit (sr 110532). */
9863#ifdef __cplusplus
9864extern "C"
9865#endif
9866char pthread_kill (void);
9867int
9868main (void)
9869{
9870return pthread_kill ();
9871 ;
9872 return 0;
9873}
9874_ACEOF
9875if ac_fn_c_try_link "$LINENO"
9876then :
9877 ac_cv_lib_pthread_pthread_kill=yes
9878else case e in #(
9879 e) ac_cv_lib_pthread_pthread_kill=no ;;
9880esac
9881fi
9882rm -f core conftest.err conftest.$ac_objext conftest.beam \
9883 conftest$ac_exeext conftest.$ac_ext
9884LIBS=$ac_check_lib_save_LIBS ;;
9885esac
9886fi
9887{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
9888printf "%s\n" "$ac_cv_lib_pthread_pthread_kill" >&6; }
9889if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
9890then :
9891 if test $gl_pthread_in_glibc = yes; then
9892 LIBPMULTITHREAD=
9893 else
9894 LIBPMULTITHREAD=-lpthread
9895 # On Solaris and HP-UX, most pthread functions exist also in libc.
9896 # Therefore pthread_in_use() needs to actually try to create a
9897 # thread: pthread_create from libc will fail, whereas
9898 # pthread_create will actually create a thread.
9899 # On Solaris 10 or newer, this test is no longer needed, because
9900 # libc contains the fully functional pthread functions.
9901 case "$host_os" in
9902 solaris | solaris2.1-9 | solaris2.1-9.* | hpux*)
9903
9904printf "%s\n" "#define PTHREAD_IN_USE_DETECTION_HARD 1" >>confdefs.h
9905
9906 esac
9907 fi
9908
9909fi
9910
9911 elif test $gl_pthread_api != yes; then
9912 # Some library is needed. Try libpthread and libc_r.
9913 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lpthread" >&5
9914printf %s "checking for pthread_kill in -lpthread... " >&6; }
9915if test ${ac_cv_lib_pthread_pthread_kill+y}
9916then :
9917 printf %s "(cached) " >&6
9918else case e in #(
9919 e) ac_check_lib_save_LIBS=$LIBS
9920LIBS="-lpthread $LIBS"
9921cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9922/* end confdefs.h. */
9923
9924/* Override any GCC internal prototype to avoid an error.
9925 Use char because int might match the return type of a GCC
9926 builtin and then its argument prototype would still apply.
9927 The 'extern "C"' is for builds by C++ compilers;
9928 although this is not generally supported in C code supporting it here
9929 has little cost and some practical benefit (sr 110532). */
9930#ifdef __cplusplus
9931extern "C"
9932#endif
9933char pthread_kill (void);
9934int
9935main (void)
9936{
9937return pthread_kill ();
9938 ;
9939 return 0;
9940}
9941_ACEOF
9942if ac_fn_c_try_link "$LINENO"
9943then :
9944 ac_cv_lib_pthread_pthread_kill=yes
9945else case e in #(
9946 e) ac_cv_lib_pthread_pthread_kill=no ;;
9947esac
9948fi
9949rm -f core conftest.err conftest.$ac_objext conftest.beam \
9950 conftest$ac_exeext conftest.$ac_ext
9951LIBS=$ac_check_lib_save_LIBS ;;
9952esac
9953fi
9954{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pthread_pthread_kill" >&5
9955printf "%s\n" "$ac_cv_lib_pthread_pthread_kill" >&6; }
9956if test "x$ac_cv_lib_pthread_pthread_kill" = xyes
9957then :
9958 gl_pthread_api=yes
9959 LIBPTHREAD=-lpthread
9960 LIBPMULTITHREAD=-lpthread
9961fi
9962
9963 if test $gl_pthread_api != yes; then
9964 # For FreeBSD 4.
9965 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for pthread_kill in -lc_r" >&5
9966printf %s "checking for pthread_kill in -lc_r... " >&6; }
9967if test ${ac_cv_lib_c_r_pthread_kill+y}
9968then :
9969 printf %s "(cached) " >&6
9970else case e in #(
9971 e) ac_check_lib_save_LIBS=$LIBS
9972LIBS="-lc_r $LIBS"
9973cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9974/* end confdefs.h. */
9975
9976/* Override any GCC internal prototype to avoid an error.
9977 Use char because int might match the return type of a GCC
9978 builtin and then its argument prototype would still apply.
9979 The 'extern "C"' is for builds by C++ compilers;
9980 although this is not generally supported in C code supporting it here
9981 has little cost and some practical benefit (sr 110532). */
9982#ifdef __cplusplus
9983extern "C"
9984#endif
9985char pthread_kill (void);
9986int
9987main (void)
9988{
9989return pthread_kill ();
9990 ;
9991 return 0;
9992}
9993_ACEOF
9994if ac_fn_c_try_link "$LINENO"
9995then :
9996 ac_cv_lib_c_r_pthread_kill=yes
9997else case e in #(
9998 e) ac_cv_lib_c_r_pthread_kill=no ;;
9999esac
10000fi
10001rm -f core conftest.err conftest.$ac_objext conftest.beam \
10002 conftest$ac_exeext conftest.$ac_ext
10003LIBS=$ac_check_lib_save_LIBS ;;
10004esac
10005fi
10006{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c_r_pthread_kill" >&5
10007printf "%s\n" "$ac_cv_lib_c_r_pthread_kill" >&6; }
10008if test "x$ac_cv_lib_c_r_pthread_kill" = xyes
10009then :
10010 gl_pthread_api=yes
10011 LIBPTHREAD=-lc_r
10012 LIBPMULTITHREAD=-lc_r
10013fi
10014
10015 fi
10016 fi
10017 echo "$as_me:10017: LIBPMULTITHREAD=$LIBPMULTITHREAD" >&5
10018 fi
10019 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether POSIX threads API is available" >&5
10020printf %s "checking whether POSIX threads API is available... " >&6; }
10021 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_pthread_api" >&5
10022printf "%s\n" "$gl_pthread_api" >&6; }
10023
10024
10025 if test $gl_pthread_api = yes; then
10026
10027printf "%s\n" "#define HAVE_PTHREAD_API 1" >>confdefs.h
10028
10029 fi
10030
10031 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10032/* end confdefs.h. */
10033#include <sched.h>
10034int
10035main (void)
10036{
10037sched_yield ();
10038 ;
10039 return 0;
10040}
10041_ACEOF
10042if ac_fn_c_try_link "$LINENO"
10043then :
10044 LIB_SCHED_YIELD=
10045
10046else case e in #(
10047 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lrt" >&5
10048printf %s "checking for sched_yield in -lrt... " >&6; }
10049if test ${ac_cv_lib_rt_sched_yield+y}
10050then :
10051 printf %s "(cached) " >&6
10052else case e in #(
10053 e) ac_check_lib_save_LIBS=$LIBS
10054LIBS="-lrt $LIBS"
10055cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10056/* end confdefs.h. */
10057
10058/* Override any GCC internal prototype to avoid an error.
10059 Use char because int might match the return type of a GCC
10060 builtin and then its argument prototype would still apply.
10061 The 'extern "C"' is for builds by C++ compilers;
10062 although this is not generally supported in C code supporting it here
10063 has little cost and some practical benefit (sr 110532). */
10064#ifdef __cplusplus
10065extern "C"
10066#endif
10067char sched_yield (void);
10068int
10069main (void)
10070{
10071return sched_yield ();
10072 ;
10073 return 0;
10074}
10075_ACEOF
10076if ac_fn_c_try_link "$LINENO"
10077then :
10078 ac_cv_lib_rt_sched_yield=yes
10079else case e in #(
10080 e) ac_cv_lib_rt_sched_yield=no ;;
10081esac
10082fi
10083rm -f core conftest.err conftest.$ac_objext conftest.beam \
10084 conftest$ac_exeext conftest.$ac_ext
10085LIBS=$ac_check_lib_save_LIBS ;;
10086esac
10087fi
10088{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_rt_sched_yield" >&5
10089printf "%s\n" "$ac_cv_lib_rt_sched_yield" >&6; }
10090if test "x$ac_cv_lib_rt_sched_yield" = xyes
10091then :
10092 LIB_SCHED_YIELD=-lrt
10093else case e in #(
10094 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sched_yield in -lposix4" >&5
10095printf %s "checking for sched_yield in -lposix4... " >&6; }
10096if test ${ac_cv_lib_posix4_sched_yield+y}
10097then :
10098 printf %s "(cached) " >&6
10099else case e in #(
10100 e) ac_check_lib_save_LIBS=$LIBS
10101LIBS="-lposix4 $LIBS"
10102cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10103/* end confdefs.h. */
10104
10105/* Override any GCC internal prototype to avoid an error.
10106 Use char because int might match the return type of a GCC
10107 builtin and then its argument prototype would still apply.
10108 The 'extern "C"' is for builds by C++ compilers;
10109 although this is not generally supported in C code supporting it here
10110 has little cost and some practical benefit (sr 110532). */
10111#ifdef __cplusplus
10112extern "C"
10113#endif
10114char sched_yield (void);
10115int
10116main (void)
10117{
10118return sched_yield ();
10119 ;
10120 return 0;
10121}
10122_ACEOF
10123if ac_fn_c_try_link "$LINENO"
10124then :
10125 ac_cv_lib_posix4_sched_yield=yes
10126else case e in #(
10127 e) ac_cv_lib_posix4_sched_yield=no ;;
10128esac
10129fi
10130rm -f core conftest.err conftest.$ac_objext conftest.beam \
10131 conftest$ac_exeext conftest.$ac_ext
10132LIBS=$ac_check_lib_save_LIBS ;;
10133esac
10134fi
10135{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix4_sched_yield" >&5
10136printf "%s\n" "$ac_cv_lib_posix4_sched_yield" >&6; }
10137if test "x$ac_cv_lib_posix4_sched_yield" = xyes
10138then :
10139 LIB_SCHED_YIELD=-lposix4
10140fi
10141 ;;
10142esac
10143fi
10144
10145 ;;
10146esac
10147fi
10148rm -f core conftest.err conftest.$ac_objext conftest.beam \
10149 conftest$ac_exeext conftest.$ac_ext
10150
10151
10152 gl_pthreadlib_body_done=done
10153 fi
10154
10155 if test $ac_cv_header_threads_h = yes; then
10156 ac_fn_c_check_func "$LINENO" "thrd_create" "ac_cv_func_thrd_create"
10157if test "x$ac_cv_func_thrd_create" = xyes
10158then :
10159 printf "%s\n" "#define HAVE_THRD_CREATE 1" >>confdefs.h
10160
10161fi
10162
10163 if test $ac_cv_func_thrd_create = yes; then
10164 LIBSTDTHREAD=
10165 else
10166 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for thrd_create in -lstdthreads" >&5
10167printf %s "checking for thrd_create in -lstdthreads... " >&6; }
10168if test ${ac_cv_lib_stdthreads_thrd_create+y}
10169then :
10170 printf %s "(cached) " >&6
10171else case e in #(
10172 e) ac_check_lib_save_LIBS=$LIBS
10173LIBS="-lstdthreads $LIBS"
10174cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10175/* end confdefs.h. */
10176
10177/* Override any GCC internal prototype to avoid an error.
10178 Use char because int might match the return type of a GCC
10179 builtin and then its argument prototype would still apply.
10180 The 'extern "C"' is for builds by C++ compilers;
10181 although this is not generally supported in C code supporting it here
10182 has little cost and some practical benefit (sr 110532). */
10183#ifdef __cplusplus
10184extern "C"
10185#endif
10186char thrd_create (void);
10187int
10188main (void)
10189{
10190return thrd_create ();
10191 ;
10192 return 0;
10193}
10194_ACEOF
10195if ac_fn_c_try_link "$LINENO"
10196then :
10197 ac_cv_lib_stdthreads_thrd_create=yes
10198else case e in #(
10199 e) ac_cv_lib_stdthreads_thrd_create=no ;;
10200esac
10201fi
10202rm -f core conftest.err conftest.$ac_objext conftest.beam \
10203 conftest$ac_exeext conftest.$ac_ext
10204LIBS=$ac_check_lib_save_LIBS ;;
10205esac
10206fi
10207{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_stdthreads_thrd_create" >&5
10208printf "%s\n" "$ac_cv_lib_stdthreads_thrd_create" >&6; }
10209if test "x$ac_cv_lib_stdthreads_thrd_create" = xyes
10210then :
10211
10212 LIBSTDTHREAD='-lstdthreads -lpthread'
10213
10214else case e in #(
10215 e)
10216 LIBSTDTHREAD="$LIBPMULTITHREAD"
10217 ;;
10218esac
10219fi
10220
10221 fi
10222 else
10223 LIBSTDTHREAD="$LIBPMULTITHREAD $LIB_SCHED_YIELD"
10224 fi
10225 ;;
10226 esac
10227
10228
10229 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ISO C threads API is available" >&5
10230printf %s "checking whether ISO C threads API is available... " >&6; }
10231 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_threads_h" >&5
10232printf "%s\n" "$ac_cv_header_threads_h" >&6; }
10233 gl_stdthreadlib_body_done=done
10234 fi
10235
10236 LIBTHREAD=$LIBSTDTHREAD LTLIBTHREAD=$LIBSTDTHREAD
10237 LIBMULTITHREAD=$LIBSTDTHREAD LTLIBMULTITHREAD=$LIBSTDTHREAD
10238 gl_threads_api=isoc
10239
10240printf "%s\n" "#define USE_ISOC_THREADS 1" >>confdefs.h
10241
10242 fi
10243 fi
10244 if test $gl_threads_api = none; then
10245 case "$gl_use_threads" in
10246 yes | windows | win32) # The 'win32' is for backward compatibility.
10247 if { case "$host_os" in
10248 mingw*) true;;
10249 *) false;;
10250 esac
10251 }; then
10252 gl_threads_api=windows
10253
10254printf "%s\n" "#define USE_WINDOWS_THREADS 1" >>confdefs.h
10255
10256 fi
10257 ;;
10258 esac
10259 fi
10260 fi
10261 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for multithread API to use" >&5
10262printf %s "checking for multithread API to use... " >&6; }
10263 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_threads_api" >&5
10264printf "%s\n" "$gl_threads_api" >&6; }
10265
10266
10267
10268
10269
10270
10271
10272
10273
10274
10275
10276 if test "$gl_threads_api" = posix; then
10277 # OSF/1 4.0 and Mac OS X 10.1 lack the pthread_rwlock_t type and the
10278 # pthread_rwlock_* functions.
10279 has_rwlock=false
10280 ac_fn_c_check_type "$LINENO" "pthread_rwlock_t" "ac_cv_type_pthread_rwlock_t" "#include <pthread.h>
10281"
10282if test "x$ac_cv_type_pthread_rwlock_t" = xyes
10283then :
10284 has_rwlock=true
10285
10286printf "%s\n" "#define HAVE_PTHREAD_RWLOCK 1" >>confdefs.h
10287
10288fi
10289
10290 if $has_rwlock; then
10291
10292
10293 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pthread_rwlock_rdlock prefers a writer to a reader" >&5
10294printf %s "checking whether pthread_rwlock_rdlock prefers a writer to a reader... " >&6; }
10295if test ${gl_cv_pthread_rwlock_rdlock_prefer_writer+y}
10296then :
10297 printf %s "(cached) " >&6
10298else case e in #(
10299 e) save_LIBS="$LIBS"
10300 LIBS="$LIBS $LIBMULTITHREAD"
10301 if test "$cross_compiling" = yes
10302then :
10303 case "$host_os" in
10304 # Guess no on glibc systems.
10305 *-gnu* | gnu*) gl_cv_pthread_rwlock_rdlock_prefer_writer="guessing no" ;;
10306 # Guess no on musl systems.
10307 *-musl*) gl_cv_pthread_rwlock_rdlock_prefer_writer="guessing no" ;;
10308 # Guess no on bionic systems.
10309 *-android*) gl_cv_pthread_rwlock_rdlock_prefer_writer="guessing no" ;;
10310 # Guess yes on native Windows with the mingw-w64 winpthreads library.
10311 # Guess no on native Windows with the gnulib windows-rwlock module.
10312 mingw*) if test "$gl_use_threads" = yes || test "$gl_use_threads" = posix; then
10313 gl_cv_pthread_rwlock_rdlock_prefer_writer="guessing yes"
10314 else
10315 gl_cv_pthread_rwlock_rdlock_prefer_writer="guessing no"
10316 fi
10317 ;;
10318 # If we don't know, obey --enable-cross-guesses.
10319 *) gl_cv_pthread_rwlock_rdlock_prefer_writer="$gl_cross_guess_normal" ;;
10320 esac
10321
10322else case e in #(
10323 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10324/* end confdefs.h. */
10325
10326#include <errno.h>
10327#include <pthread.h>
10328#include <stdlib.h>
10329#include <unistd.h>
10330
10331#define SUCCEED() exit (0)
10332#define FAILURE() exit (1)
10333#define UNEXPECTED(n) (exit (10 + (n)))
10334
10335/* The main thread creates the waiting writer and the requesting reader threads
10336 in the default way; this guarantees that they have the same priority.
10337 We can reuse the main thread as first reader thread. */
10338
10339static pthread_rwlock_t lock;
10340static pthread_t reader1;
10341static pthread_t writer;
10342static pthread_t reader2;
10343static pthread_t timer;
10344/* Used to pass control from writer to reader2 and from reader2 to timer,
10345 as in a relay race.
10346 Passing control from one running thread to another running thread
10347 is most likely faster than to create the second thread. */
10348static pthread_mutex_t baton;
10349
10350static void *
10351timer_func (void *ignored)
10352{
10353 /* Step 13 (can be before or after step 12):
10354 The timer thread takes the baton, then waits a moment to make sure
10355 it can tell whether the second reader thread is blocked at step 12. */
10356 if (pthread_mutex_lock (&baton))
10357 UNEXPECTED (13);
10358 usleep (100000);
10359 /* By the time we get here, it's clear that the second reader thread is
10360 blocked at step 12. This is the desired behaviour. */
10361 SUCCEED ();
10362}
10363
10364static void *
10365reader2_func (void *ignored)
10366{
10367 int err;
10368
10369 /* Step 8 (can be before or after step 7):
10370 The second reader thread takes the baton, then waits a moment to make sure
10371 the writer thread has reached step 7. */
10372 if (pthread_mutex_lock (&baton))
10373 UNEXPECTED (8);
10374 usleep (100000);
10375 /* Step 9: The second reader thread requests the lock. */
10376 err = pthread_rwlock_tryrdlock (&lock);
10377 if (err == 0)
10378 FAILURE ();
10379 else if (err != EBUSY)
10380 UNEXPECTED (9);
10381 /* Step 10: Launch a timer, to test whether the next call blocks. */
10382 if (pthread_create (&timer, NULL, timer_func, NULL))
10383 UNEXPECTED (10);
10384 /* Step 11: Release the baton. */
10385 if (pthread_mutex_unlock (&baton))
10386 UNEXPECTED (11);
10387 /* Step 12: The second reader thread requests the lock. */
10388 err = pthread_rwlock_rdlock (&lock);
10389 if (err == 0)
10390 FAILURE ();
10391 else
10392 UNEXPECTED (12);
10393}
10394
10395static void *
10396writer_func (void *ignored)
10397{
10398 /* Step 4: Take the baton, so that the second reader thread does not go ahead
10399 too early. */
10400 if (pthread_mutex_lock (&baton))
10401 UNEXPECTED (4);
10402 /* Step 5: Create the second reader thread. */
10403 if (pthread_create (&reader2, NULL, reader2_func, NULL))
10404 UNEXPECTED (5);
10405 /* Step 6: Release the baton. */
10406 if (pthread_mutex_unlock (&baton))
10407 UNEXPECTED (6);
10408 /* Step 7: The writer thread requests the lock. */
10409 if (pthread_rwlock_wrlock (&lock))
10410 UNEXPECTED (7);
10411 return NULL;
10412}
10413
10414int
10415main ()
10416{
10417 reader1 = pthread_self ();
10418
10419 /* Step 1: The main thread initializes the lock and the baton. */
10420 if (pthread_rwlock_init (&lock, NULL))
10421 UNEXPECTED (1);
10422 if (pthread_mutex_init (&baton, NULL))
10423 UNEXPECTED (1);
10424 /* Step 2: The main thread acquires the lock as a reader. */
10425 if (pthread_rwlock_rdlock (&lock))
10426 UNEXPECTED (2);
10427 /* Step 3: Create the writer thread. */
10428 if (pthread_create (&writer, NULL, writer_func, NULL))
10429 UNEXPECTED (3);
10430 /* Job done. Go to sleep. */
10431 for (;;)
10432 {
10433 sleep (1);
10434 }
10435}
10436
10437_ACEOF
10438if ac_fn_c_try_run "$LINENO"
10439then :
10440 gl_cv_pthread_rwlock_rdlock_prefer_writer=yes
10441else case e in #(
10442 e) gl_cv_pthread_rwlock_rdlock_prefer_writer=no ;;
10443esac
10444fi
10445rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10446 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
10447esac
10448fi
10449
10450 LIBS="$save_LIBS"
10451 ;;
10452esac
10453fi
10454{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_pthread_rwlock_rdlock_prefer_writer" >&5
10455printf "%s\n" "$gl_cv_pthread_rwlock_rdlock_prefer_writer" >&6; }
10456 case "$gl_cv_pthread_rwlock_rdlock_prefer_writer" in
10457 *yes)
10458
10459printf "%s\n" "#define HAVE_PTHREAD_RWLOCK_RDLOCK_PREFER_WRITER 1" >>confdefs.h
10460
10461 ;;
10462 esac
10463
10464 fi
10465 # glibc defines PTHREAD_MUTEX_RECURSIVE as enum, not as a macro.
10466 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10467/* end confdefs.h. */
10468
10469 #include <pthread.h>
10470int
10471main (void)
10472{
10473
10474#if __FreeBSD__ == 4
10475error "No, in FreeBSD 4.0 recursive mutexes actually don't work."
10476#elif (defined __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ \
10477 && __ENVIRONMENT_MAC_OS_X_VERSION_MIN_REQUIRED__ < 1070)
10478error "No, in Mac OS X < 10.7 recursive mutexes actually don't work."
10479#else
10480int x = (int)PTHREAD_MUTEX_RECURSIVE;
10481return !x;
10482#endif
10483
10484 ;
10485 return 0;
10486}
10487_ACEOF
10488if ac_fn_c_try_compile "$LINENO"
10489then :
10490
10491printf "%s\n" "#define HAVE_PTHREAD_MUTEX_RECURSIVE 1" >>confdefs.h
10492
10493fi
10494rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10495 fi
10496 :
10497
10498{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $CC options needed to detect all undeclared functions" >&5
10499printf %s "checking for $CC options needed to detect all undeclared functions... " >&6; }
10500if test ${ac_cv_c_undeclared_builtin_options+y}
10501then :
10502 printf %s "(cached) " >&6
10503else case e in #(
10504 e) ac_save_CFLAGS=$CFLAGS
10505 ac_cv_c_undeclared_builtin_options='cannot detect'
10506 for ac_arg in '' -fno-builtin; do
10507 CFLAGS="$ac_save_CFLAGS $ac_arg"
10508 # This test program should *not* compile successfully.
10509 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10510/* end confdefs.h. */
10511
10512int
10513main (void)
10514{
10515(void) strchr;
10516 ;
10517 return 0;
10518}
10519_ACEOF
10520if ac_fn_c_try_compile "$LINENO"
10521then :
10522
10523else case e in #(
10524 e) # This test program should compile successfully.
10525 # No library function is consistently available on
10526 # freestanding implementations, so test against a dummy
10527 # declaration. Include always-available headers on the
10528 # off chance that they somehow elicit warnings.
10529 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10530/* end confdefs.h. */
10531#include <float.h>
10532#include <limits.h>
10533#include <stdarg.h>
10534#include <stddef.h>
10535extern void ac_decl (int, char *);
10536
10537int
10538main (void)
10539{
10540(void) ac_decl (0, (char *) 0);
10541 (void) ac_decl;
10542
10543 ;
10544 return 0;
10545}
10546_ACEOF
10547if ac_fn_c_try_compile "$LINENO"
10548then :
10549 if test x"$ac_arg" = x
10550then :
10551 ac_cv_c_undeclared_builtin_options='none needed'
10552else case e in #(
10553 e) ac_cv_c_undeclared_builtin_options=$ac_arg ;;
10554esac
10555fi
10556 break
10557fi
10558rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
10559esac
10560fi
10561rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10562 done
10563 CFLAGS=$ac_save_CFLAGS
10564 ;;
10565esac
10566fi
10567{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_undeclared_builtin_options" >&5
10568printf "%s\n" "$ac_cv_c_undeclared_builtin_options" >&6; }
10569 case $ac_cv_c_undeclared_builtin_options in #(
10570 'cannot detect') :
10571 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
10572printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
10573as_fn_error $? "cannot make $CC report undeclared builtins
10574See 'config.log' for more details" "$LINENO" 5; } ;; #(
10575 'none needed') :
10576 ac_c_undeclared_builtin_options='' ;; #(
10577 *) :
10578 ac_c_undeclared_builtin_options=$ac_cv_c_undeclared_builtin_options ;;
10579esac
10580
10581
10582 if test "X$prefix" = "XNONE"; then
10583 acl_final_prefix="$ac_default_prefix"
10584 else
10585 acl_final_prefix="$prefix"
10586 fi
10587 if test "X$exec_prefix" = "XNONE"; then
10588 acl_final_exec_prefix='${prefix}'
10589 else
10590 acl_final_exec_prefix="$exec_prefix"
10591 fi
10592 acl_save_prefix="$prefix"
10593 prefix="$acl_final_prefix"
10594 eval acl_final_exec_prefix=\"$acl_final_exec_prefix\"
10595 prefix="$acl_save_prefix"
10596
10597
10598
10599# Check whether --with-gnu-ld was given.
10600if test ${with_gnu_ld+y}
10601then :
10602 withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
10603else case e in #(
10604 e) with_gnu_ld=no ;;
10605esac
10606fi
10607
10608# Prepare PATH_SEPARATOR.
10609# The user is always right.
10610if test "${PATH_SEPARATOR+set}" != set; then
10611 # Determine PATH_SEPARATOR by trying to find /bin/sh in a PATH which
10612 # contains only /bin. Note that ksh looks also at the FPATH variable,
10613 # so we have to set that as well for the test.
10614 PATH_SEPARATOR=:
10615 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
10616 && { (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 \
10617 || PATH_SEPARATOR=';'
10618 }
10619fi
10620
10621if test -n "$LD"; then
10622 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld" >&5
10623printf %s "checking for ld... " >&6; }
10624elif test "$GCC" = yes; then
10625 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5
10626printf %s "checking for ld used by $CC... " >&6; }
10627elif test "$with_gnu_ld" = yes; then
10628 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5
10629printf %s "checking for GNU ld... " >&6; }
10630else
10631 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5
10632printf %s "checking for non-GNU ld... " >&6; }
10633fi
10634if test -n "$LD"; then
10635 # Let the user override the test with a path.
10636 :
10637else
10638 if test ${acl_cv_path_LD+y}
10639then :
10640 printf %s "(cached) " >&6
10641else case e in #(
10642 e)
10643 acl_cv_path_LD= # Final result of this test
10644 ac_prog=ld # Program to search in $PATH
10645 if test "$GCC" = yes; then
10646 # Check if gcc -print-prog-name=ld gives a path.
10647 case $host in
10648 *-*-mingw*)
10649 # gcc leaves a trailing carriage return which upsets mingw
10650 acl_output=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
10651 *)
10652 acl_output=`($CC -print-prog-name=ld) 2>&5` ;;
10653 esac
10654 case $acl_output in
10655 # Accept absolute paths.
10656 [\\/]* | ?:[\\/]*)
10657 re_direlt='/[^/][^/]*/\.\./'
10658 # Canonicalize the pathname of ld
10659 acl_output=`echo "$acl_output" | sed 's%\\\\%/%g'`
10660 while echo "$acl_output" | grep "$re_direlt" > /dev/null 2>&1; do
10661 acl_output=`echo $acl_output | sed "s%$re_direlt%/%"`
10662 done
10663 # Got the pathname. No search in PATH is needed.
10664 acl_cv_path_LD="$acl_output"
10665 ac_prog=
10666 ;;
10667 "")
10668 # If it fails, then pretend we aren't using GCC.
10669 ;;
10670 *)
10671 # If it is relative, then search for the first ld in PATH.
10672 with_gnu_ld=unknown
10673 ;;
10674 esac
10675 fi
10676 if test -n "$ac_prog"; then
10677 # Search for $ac_prog in $PATH.
10678 acl_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
10679 for ac_dir in $PATH; do
10680 IFS="$acl_save_ifs"
10681 test -z "$ac_dir" && ac_dir=.
10682 if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
10683 acl_cv_path_LD="$ac_dir/$ac_prog"
10684 # Check to see if the program is GNU ld. I'd rather use --version,
10685 # but apparently some variants of GNU ld only accept -v.
10686 # Break only if it was the GNU/non-GNU ld that we prefer.
10687 case `"$acl_cv_path_LD" -v 2>&1 </dev/null` in
10688 *GNU* | *'with BFD'*)
10689 test "$with_gnu_ld" != no && break
10690 ;;
10691 *)
10692 test "$with_gnu_ld" != yes && break
10693 ;;
10694 esac
10695 fi
10696 done
10697 IFS="$acl_save_ifs"
10698 fi
10699 case $host in
10700 *-*-aix*)
10701 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10702/* end confdefs.h. */
10703#if defined __powerpc64__ || defined __LP64__
10704 int ok;
10705 #else
10706 error fail
10707 #endif
10708
10709_ACEOF
10710if ac_fn_c_try_compile "$LINENO"
10711then :
10712 # The compiler produces 64-bit code. Add option '-b64' so that the
10713 # linker groks 64-bit object files.
10714 case "$acl_cv_path_LD " in
10715 *" -b64 "*) ;;
10716 *) acl_cv_path_LD="$acl_cv_path_LD -b64" ;;
10717 esac
10718
10719fi
10720rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10721 ;;
10722 sparc64-*-netbsd*)
10723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10724/* end confdefs.h. */
10725#if defined __sparcv9 || defined __arch64__
10726 int ok;
10727 #else
10728 error fail
10729 #endif
10730
10731_ACEOF
10732if ac_fn_c_try_compile "$LINENO"
10733then :
10734
10735else case e in #(
10736 e) # The compiler produces 32-bit code. Add option '-m elf32_sparc'
10737 # so that the linker groks 32-bit object files.
10738 case "$acl_cv_path_LD " in
10739 *" -m elf32_sparc "*) ;;
10740 *) acl_cv_path_LD="$acl_cv_path_LD -m elf32_sparc" ;;
10741 esac
10742 ;;
10743esac
10744fi
10745rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10746 ;;
10747 esac
10748 ;;
10749esac
10750fi
10751
10752 LD="$acl_cv_path_LD"
10753fi
10754if test -n "$LD"; then
10755 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LD" >&5
10756printf "%s\n" "$LD" >&6; }
10757else
10758 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10759printf "%s\n" "no" >&6; }
10760 as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5
10761fi
10762{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5
10763printf %s "checking if the linker ($LD) is GNU ld... " >&6; }
10764if test ${acl_cv_prog_gnu_ld+y}
10765then :
10766 printf %s "(cached) " >&6
10767else case e in #(
10768 e) # I'd rather use --version here, but apparently some GNU lds only accept -v.
10769case `$LD -v 2>&1 </dev/null` in
10770*GNU* | *'with BFD'*)
10771 acl_cv_prog_gnu_ld=yes
10772 ;;
10773*)
10774 acl_cv_prog_gnu_ld=no
10775 ;;
10776esac ;;
10777esac
10778fi
10779{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5
10780printf "%s\n" "$acl_cv_prog_gnu_ld" >&6; }
10781with_gnu_ld=$acl_cv_prog_gnu_ld
10782
10783
10784
10785
10786
10787 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5
10788printf %s "checking for shared library run path origin... " >&6; }
10789if test ${acl_cv_rpath+y}
10790then :
10791 printf %s "(cached) " >&6
10792else case e in #(
10793 e)
10794 CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \
10795 ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh
10796 . ./conftest.sh
10797 rm -f ./conftest.sh
10798 acl_cv_rpath=done
10799 ;;
10800esac
10801fi
10802{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5
10803printf "%s\n" "$acl_cv_rpath" >&6; }
10804 wl="$acl_cv_wl"
10805 acl_libext="$acl_cv_libext"
10806 acl_shlibext="$acl_cv_shlibext"
10807 acl_libname_spec="$acl_cv_libname_spec"
10808 acl_library_names_spec="$acl_cv_library_names_spec"
10809 acl_hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec"
10810 acl_hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator"
10811 acl_hardcode_direct="$acl_cv_hardcode_direct"
10812 acl_hardcode_minus_L="$acl_cv_hardcode_minus_L"
10813 # Check whether --enable-rpath was given.
10814if test ${enable_rpath+y}
10815then :
10816 enableval=$enable_rpath; :
10817else case e in #(
10818 e) enable_rpath=yes ;;
10819esac
10820fi
10821
10822
10823
10824
10825 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking 32-bit host C ABI" >&5
10826printf %s "checking 32-bit host C ABI... " >&6; }
10827if test ${gl_cv_host_cpu_c_abi_32bit+y}
10828then :
10829 printf %s "(cached) " >&6
10830else case e in #(
10831 e) if test -n "$gl_cv_host_cpu_c_abi"; then
10832 case "$gl_cv_host_cpu_c_abi" in
10833 i386 | x86_64-x32 | arm | armhf | arm64-ilp32 | hppa | ia64-ilp32 | mips | mipsn32 | powerpc | riscv*-ilp32* | s390 | sparc)
10834 gl_cv_host_cpu_c_abi_32bit=yes ;;
10835 x86_64 | alpha | arm64 | hppa64 | ia64 | mips64 | powerpc64 | powerpc64-elfv2 | riscv*-lp64* | s390x | sparc64 )
10836 gl_cv_host_cpu_c_abi_32bit=no ;;
10837 *)
10838 gl_cv_host_cpu_c_abi_32bit=unknown ;;
10839 esac
10840 else
10841 case "$host_cpu" in
10842
10843 # CPUs that only support a 32-bit ABI.
10844 arc \
10845 | bfin \
10846 | cris* \
10847 | csky \
10848 | epiphany \
10849 | ft32 \
10850 | h8300 \
10851 | m68k \
10852 | microblaze | microblazeel \
10853 | nds32 | nds32le | nds32be \
10854 | nios2 | nios2eb | nios2el \
10855 | or1k* \
10856 | or32 \
10857 | sh | sh1234 | sh1234elb \
10858 | tic6x \
10859 | xtensa* )
10860 gl_cv_host_cpu_c_abi_32bit=yes
10861 ;;
10862
10863 # CPUs that only support a 64-bit ABI.
10864 alpha | alphaev[4-8] | alphaev56 | alphapca5[67] | alphaev6[78] \
10865 | mmix )
10866 gl_cv_host_cpu_c_abi_32bit=no
10867 ;;
10868
10869 i[34567]86 )
10870 gl_cv_host_cpu_c_abi_32bit=yes
10871 ;;
10872
10873 x86_64 )
10874 # On x86_64 systems, the C compiler may be generating code in one of
10875 # these ABIs:
10876 # - 64-bit instruction set, 64-bit pointers, 64-bit 'long': x86_64.
10877 # - 64-bit instruction set, 64-bit pointers, 32-bit 'long': x86_64
10878 # with native Windows (mingw, MSVC).
10879 # - 64-bit instruction set, 32-bit pointers, 32-bit 'long': x86_64-x32.
10880 # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': i386.
10881 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10882/* end confdefs.h. */
10883#if (defined __x86_64__ || defined __amd64__ \
10884 || defined _M_X64 || defined _M_AMD64) \
10885 && !(defined __ILP32__ || defined _ILP32)
10886 int ok;
10887 #else
10888 error fail
10889 #endif
10890
10891_ACEOF
10892if ac_fn_c_try_compile "$LINENO"
10893then :
10894 gl_cv_host_cpu_c_abi_32bit=no
10895else case e in #(
10896 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
10897esac
10898fi
10899rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10900 ;;
10901
10902 arm* | aarch64 )
10903 # Assume arm with EABI.
10904 # On arm64 systems, the C compiler may be generating code in one of
10905 # these ABIs:
10906 # - aarch64 instruction set, 64-bit pointers, 64-bit 'long': arm64.
10907 # - aarch64 instruction set, 32-bit pointers, 32-bit 'long': arm64-ilp32.
10908 # - 32-bit instruction set, 32-bit pointers, 32-bit 'long': arm or armhf.
10909 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10910/* end confdefs.h. */
10911#if defined __aarch64__ && !(defined __ILP32__ || defined _ILP32)
10912 int ok;
10913 #else
10914 error fail
10915 #endif
10916
10917_ACEOF
10918if ac_fn_c_try_compile "$LINENO"
10919then :
10920 gl_cv_host_cpu_c_abi_32bit=no
10921else case e in #(
10922 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
10923esac
10924fi
10925rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10926 ;;
10927
10928 hppa1.0 | hppa1.1 | hppa2.0* | hppa64 )
10929 # On hppa, the C compiler may be generating 32-bit code or 64-bit
10930 # code. In the latter case, it defines _LP64 and __LP64__.
10931 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10932/* end confdefs.h. */
10933#ifdef __LP64__
10934 int ok;
10935 #else
10936 error fail
10937 #endif
10938
10939_ACEOF
10940if ac_fn_c_try_compile "$LINENO"
10941then :
10942 gl_cv_host_cpu_c_abi_32bit=no
10943else case e in #(
10944 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
10945esac
10946fi
10947rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10948 ;;
10949
10950 ia64* )
10951 # On ia64 on HP-UX, the C compiler may be generating 64-bit code or
10952 # 32-bit code. In the latter case, it defines _ILP32.
10953 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10954/* end confdefs.h. */
10955#ifdef _ILP32
10956 int ok;
10957 #else
10958 error fail
10959 #endif
10960
10961_ACEOF
10962if ac_fn_c_try_compile "$LINENO"
10963then :
10964 gl_cv_host_cpu_c_abi_32bit=yes
10965else case e in #(
10966 e) gl_cv_host_cpu_c_abi_32bit=no ;;
10967esac
10968fi
10969rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10970 ;;
10971
10972 mips* )
10973 # We should also check for (_MIPS_SZPTR == 64), but gcc keeps this
10974 # at 32.
10975 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10976/* end confdefs.h. */
10977#if defined _MIPS_SZLONG && (_MIPS_SZLONG == 64)
10978 int ok;
10979 #else
10980 error fail
10981 #endif
10982
10983_ACEOF
10984if ac_fn_c_try_compile "$LINENO"
10985then :
10986 gl_cv_host_cpu_c_abi_32bit=no
10987else case e in #(
10988 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
10989esac
10990fi
10991rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
10992 ;;
10993
10994 powerpc* )
10995 # Different ABIs are in use on AIX vs. Mac OS X vs. Linux,*BSD.
10996 # No need to distinguish them here; the caller may distinguish
10997 # them based on the OS.
10998 # On powerpc64 systems, the C compiler may still be generating
10999 # 32-bit code. And on powerpc-ibm-aix systems, the C compiler may
11000 # be generating 64-bit code.
11001 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11002/* end confdefs.h. */
11003#if defined __powerpc64__ || defined __LP64__
11004 int ok;
11005 #else
11006 error fail
11007 #endif
11008
11009_ACEOF
11010if ac_fn_c_try_compile "$LINENO"
11011then :
11012 gl_cv_host_cpu_c_abi_32bit=no
11013else case e in #(
11014 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
11015esac
11016fi
11017rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
11018 ;;
11019
11020 rs6000 )
11021 gl_cv_host_cpu_c_abi_32bit=yes
11022 ;;
11023
11024 riscv32 | riscv64 )
11025 # There are 6 ABIs: ilp32, ilp32f, ilp32d, lp64, lp64f, lp64d.
11026 # Size of 'long' and 'void *':
11027 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11028/* end confdefs.h. */
11029#if defined __LP64__
11030 int ok;
11031 #else
11032 error fail
11033 #endif
11034
11035_ACEOF
11036if ac_fn_c_try_compile "$LINENO"
11037then :
11038 gl_cv_host_cpu_c_abi_32bit=no
11039else case e in #(
11040 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
11041esac
11042fi
11043rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
11044 ;;
11045
11046 s390* )
11047 # On s390x, the C compiler may be generating 64-bit (= s390x) code
11048 # or 31-bit (= s390) code.
11049 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11050/* end confdefs.h. */
11051#if defined __LP64__ || defined __s390x__
11052 int ok;
11053 #else
11054 error fail
11055 #endif
11056
11057_ACEOF
11058if ac_fn_c_try_compile "$LINENO"
11059then :
11060 gl_cv_host_cpu_c_abi_32bit=no
11061else case e in #(
11062 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
11063esac
11064fi
11065rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
11066 ;;
11067
11068 sparc | sparc64 )
11069 # UltraSPARCs running Linux have `uname -m` = "sparc64", but the
11070 # C compiler still generates 32-bit code.
11071 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11072/* end confdefs.h. */
11073#if defined __sparcv9 || defined __arch64__
11074 int ok;
11075 #else
11076 error fail
11077 #endif
11078
11079_ACEOF
11080if ac_fn_c_try_compile "$LINENO"
11081then :
11082 gl_cv_host_cpu_c_abi_32bit=no
11083else case e in #(
11084 e) gl_cv_host_cpu_c_abi_32bit=yes ;;
11085esac
11086fi
11087rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
11088 ;;
11089
11090 *)
11091 gl_cv_host_cpu_c_abi_32bit=unknown
11092 ;;
11093 esac
11094 fi
11095 ;;
11096esac
11097fi
11098{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_host_cpu_c_abi_32bit" >&5
11099printf "%s\n" "$gl_cv_host_cpu_c_abi_32bit" >&6; }
11100
11101 HOST_CPU_C_ABI_32BIT="$gl_cv_host_cpu_c_abi_32bit"
11102
11103
11104
11105
11106
11107 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for ELF binary format" >&5
11108printf %s "checking for ELF binary format... " >&6; }
11109if test ${gl_cv_elf+y}
11110then :
11111 printf %s "(cached) " >&6
11112else case e in #(
11113 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11114/* end confdefs.h. */
11115#if defined __ELF__ || (defined __linux__ && defined __EDG__)
11116 Extensible Linking Format
11117 #endif
11118
11119_ACEOF
11120if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
11121 $EGREP_TRADITIONAL "Extensible Linking Format" >/dev/null 2>&1
11122then :
11123 gl_cv_elf=yes
11124else case e in #(
11125 e) gl_cv_elf=no ;;
11126esac
11127fi
11128rm -rf conftest*
11129
11130 ;;
11131esac
11132fi
11133{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_elf" >&5
11134printf "%s\n" "$gl_cv_elf" >&6; }
11135 if test $gl_cv_elf = yes; then
11136 # Extract the ELF class of a file (5th byte) in decimal.
11137 # Cf. https://en.wikipedia.org/wiki/Executable_and_Linkable_Format#File_header
11138 if od -A x < /dev/null >/dev/null 2>/dev/null; then
11139 # Use POSIX od.
11140 func_elfclass ()
11141 {
11142 od -A n -t d1 -j 4 -N 1
11143 }
11144 else
11145 # Use BSD hexdump.
11146 func_elfclass ()
11147 {
11148 dd bs=1 count=1 skip=4 2>/dev/null | hexdump -e '1/1 "%3d "'
11149 echo
11150 }
11151 fi
11152 # Use 'expr', not 'test', to compare the values of func_elfclass, because on
11153 # Solaris 11 OpenIndiana and Solaris 11 OmniOS, the result is 001 or 002,
11154 # not 1 or 2.
11155 case $HOST_CPU_C_ABI_32BIT in
11156 yes)
11157 # 32-bit ABI.
11158 acl_is_expected_elfclass ()
11159 {
11160 expr "`func_elfclass | sed -e 's/[ ]//g'`" = 1 > /dev/null
11161 }
11162 ;;
11163 no)
11164 # 64-bit ABI.
11165 acl_is_expected_elfclass ()
11166 {
11167 expr "`func_elfclass | sed -e 's/[ ]//g'`" = 2 > /dev/null
11168 }
11169 ;;
11170 *)
11171 # Unknown.
11172 acl_is_expected_elfclass ()
11173 {
11174 :
11175 }
11176 ;;
11177 esac
11178 else
11179 acl_is_expected_elfclass ()
11180 {
11181 :
11182 }
11183 fi
11184
11185 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the common suffixes of directories in the library search path" >&5
11186printf %s "checking for the common suffixes of directories in the library search path... " >&6; }
11187if test ${acl_cv_libdirstems+y}
11188then :
11189 printf %s "(cached) " >&6
11190else case e in #(
11191 e) acl_libdirstem=lib
11192 acl_libdirstem2=
11193 acl_libdirstem3=
11194 case "$host_os" in
11195 solaris*)
11196 if test $HOST_CPU_C_ABI_32BIT = no; then
11197 acl_libdirstem2=lib/64
11198 case "$host_cpu" in
11199 sparc*) acl_libdirstem3=lib/sparcv9 ;;
11200 i*86 | x86_64) acl_libdirstem3=lib/amd64 ;;
11201 esac
11202 fi
11203 ;;
11204 *)
11205 searchpath=`(LC_ALL=C $CC $CPPFLAGS $CFLAGS -print-search-dirs) 2>/dev/null \
11206 | sed -n -e 's,^libraries: ,,p' | sed -e 's,^=,,'`
11207 if test $HOST_CPU_C_ABI_32BIT != no; then
11208 # 32-bit or unknown ABI.
11209 if test -d /usr/lib32; then
11210 acl_libdirstem2=lib32
11211 fi
11212 fi
11213 if test $HOST_CPU_C_ABI_32BIT != yes; then
11214 # 64-bit or unknown ABI.
11215 if test -d /usr/lib64; then
11216 acl_libdirstem3=lib64
11217 fi
11218 fi
11219 if test -n "$searchpath"; then
11220 acl_save_IFS="${IFS= }"; IFS=":"
11221 for searchdir in $searchpath; do
11222 if test -d "$searchdir"; then
11223 case "$searchdir" in
11224 */lib32/ | */lib32 ) acl_libdirstem2=lib32 ;;
11225 */lib64/ | */lib64 ) acl_libdirstem3=lib64 ;;
11226 */../ | */.. )
11227 # Better ignore directories of this form. They are misleading.
11228 ;;
11229 *) searchdir=`cd "$searchdir" && pwd`
11230 case "$searchdir" in
11231 */lib32 ) acl_libdirstem2=lib32 ;;
11232 */lib64 ) acl_libdirstem3=lib64 ;;
11233 esac ;;
11234 esac
11235 fi
11236 done
11237 IFS="$acl_save_IFS"
11238 if test $HOST_CPU_C_ABI_32BIT = yes; then
11239 # 32-bit ABI.
11240 acl_libdirstem3=
11241 fi
11242 if test $HOST_CPU_C_ABI_32BIT = no; then
11243 # 64-bit ABI.
11244 acl_libdirstem2=
11245 fi
11246 fi
11247 ;;
11248 esac
11249 test -n "$acl_libdirstem2" || acl_libdirstem2="$acl_libdirstem"
11250 test -n "$acl_libdirstem3" || acl_libdirstem3="$acl_libdirstem"
11251 acl_cv_libdirstems="$acl_libdirstem,$acl_libdirstem2,$acl_libdirstem3"
11252 ;;
11253esac
11254fi
11255{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $acl_cv_libdirstems" >&5
11256printf "%s\n" "$acl_cv_libdirstems" >&6; }
11257 acl_libdirstem=`echo "$acl_cv_libdirstems" | sed -e 's/,.*//'`
11258 acl_libdirstem2=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,//' -e 's/,.*//'`
11259 acl_libdirstem3=`echo "$acl_cv_libdirstems" | sed -e 's/^[^,]*,[^,]*,//' -e 's/,.*//'`
11260
11261
11262
11263
11264
11265
11266
11267
11268
11269
11270
11271 use_additional=yes
11272
11273 acl_save_prefix="$prefix"
11274 prefix="$acl_final_prefix"
11275 acl_save_exec_prefix="$exec_prefix"
11276 exec_prefix="$acl_final_exec_prefix"
11277
11278 eval additional_includedir=\"$includedir\"
11279 eval additional_libdir=\"$libdir\"
11280 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
11281 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
11282
11283 exec_prefix="$acl_save_exec_prefix"
11284 prefix="$acl_save_prefix"
11285
11286
11287# Check whether --with-libiconv-prefix was given.
11288if test ${with_libiconv_prefix+y}
11289then :
11290 withval=$with_libiconv_prefix;
11291 if test "X$withval" = "Xno"; then
11292 use_additional=no
11293 else
11294 if test "X$withval" = "X"; then
11295
11296 acl_save_prefix="$prefix"
11297 prefix="$acl_final_prefix"
11298 acl_save_exec_prefix="$exec_prefix"
11299 exec_prefix="$acl_final_exec_prefix"
11300
11301 eval additional_includedir=\"$includedir\"
11302 eval additional_libdir=\"$libdir\"
11303 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
11304 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
11305
11306 exec_prefix="$acl_save_exec_prefix"
11307 prefix="$acl_save_prefix"
11308
11309 else
11310 additional_includedir="$withval/include"
11311 additional_libdir="$withval/$acl_libdirstem"
11312 additional_libdir2="$withval/$acl_libdirstem2"
11313 additional_libdir3="$withval/$acl_libdirstem3"
11314 fi
11315 fi
11316
11317fi
11318
11319 if test "X$additional_libdir2" = "X$additional_libdir"; then
11320 additional_libdir2=
11321 fi
11322 if test "X$additional_libdir3" = "X$additional_libdir"; then
11323 additional_libdir3=
11324 fi
11325 LIBICONV=
11326 LTLIBICONV=
11327 INCICONV=
11328 LIBICONV_PREFIX=
11329 HAVE_LIBICONV=
11330 rpathdirs=
11331 ltrpathdirs=
11332 names_already_handled=
11333 names_next_round='iconv '
11334 while test -n "$names_next_round"; do
11335 names_this_round="$names_next_round"
11336 names_next_round=
11337 for name in $names_this_round; do
11338 already_handled=
11339 for n in $names_already_handled; do
11340 if test "$n" = "$name"; then
11341 already_handled=yes
11342 break
11343 fi
11344 done
11345 if test -z "$already_handled"; then
11346 names_already_handled="$names_already_handled $name"
11347 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
11348 eval value=\"\$HAVE_LIB$uppername\"
11349 if test -n "$value"; then
11350 if test "$value" = yes; then
11351 eval value=\"\$LIB$uppername\"
11352 test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value"
11353 eval value=\"\$LTLIB$uppername\"
11354 test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value"
11355 else
11356 :
11357 fi
11358 else
11359 found_dir=
11360 found_la=
11361 found_so=
11362 found_a=
11363 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
11364 if test -n "$acl_shlibext"; then
11365 shrext=".$acl_shlibext" # typically: shrext=.so
11366 else
11367 shrext=
11368 fi
11369 if test $use_additional = yes; then
11370 for additional_libdir_variable in additional_libdir additional_libdir2 additional_libdir3; do
11371 if test "X$found_dir" = "X"; then
11372 eval dir=\$$additional_libdir_variable
11373 if test -n "$dir"; then
11374 if test -n "$acl_shlibext"; then
11375 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
11376 found_dir="$dir"
11377 found_so="$dir/$libname$shrext"
11378 else
11379 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
11380 ver=`(cd "$dir" && \
11381 for f in "$libname$shrext".*; do echo "$f"; done \
11382 | sed -e "s,^$libname$shrext\\\\.,," \
11383 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
11384 | sed 1q ) 2>/dev/null`
11385 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
11386 found_dir="$dir"
11387 found_so="$dir/$libname$shrext.$ver"
11388 fi
11389 else
11390 eval library_names=\"$acl_library_names_spec\"
11391 for f in $library_names; do
11392 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
11393 found_dir="$dir"
11394 found_so="$dir/$f"
11395 break
11396 fi
11397 done
11398 fi
11399 fi
11400 fi
11401 if test "X$found_dir" = "X"; then
11402 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
11403 found_dir="$dir"
11404 found_a="$dir/$libname.$acl_libext"
11405 fi
11406 fi
11407 if test "X$found_dir" != "X"; then
11408 if test -f "$dir/$libname.la"; then
11409 found_la="$dir/$libname.la"
11410 fi
11411 fi
11412 fi
11413 fi
11414 done
11415 fi
11416 if test "X$found_dir" = "X"; then
11417 for x in $LDFLAGS $LTLIBICONV; do
11418
11419 acl_save_prefix="$prefix"
11420 prefix="$acl_final_prefix"
11421 acl_save_exec_prefix="$exec_prefix"
11422 exec_prefix="$acl_final_exec_prefix"
11423 eval x=\"$x\"
11424 exec_prefix="$acl_save_exec_prefix"
11425 prefix="$acl_save_prefix"
11426
11427 case "$x" in
11428 -L*)
11429 dir=`echo "X$x" | sed -e 's/^X-L//'`
11430 if test -n "$acl_shlibext"; then
11431 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
11432 found_dir="$dir"
11433 found_so="$dir/$libname$shrext"
11434 else
11435 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
11436 ver=`(cd "$dir" && \
11437 for f in "$libname$shrext".*; do echo "$f"; done \
11438 | sed -e "s,^$libname$shrext\\\\.,," \
11439 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
11440 | sed 1q ) 2>/dev/null`
11441 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
11442 found_dir="$dir"
11443 found_so="$dir/$libname$shrext.$ver"
11444 fi
11445 else
11446 eval library_names=\"$acl_library_names_spec\"
11447 for f in $library_names; do
11448 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
11449 found_dir="$dir"
11450 found_so="$dir/$f"
11451 break
11452 fi
11453 done
11454 fi
11455 fi
11456 fi
11457 if test "X$found_dir" = "X"; then
11458 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
11459 found_dir="$dir"
11460 found_a="$dir/$libname.$acl_libext"
11461 fi
11462 fi
11463 if test "X$found_dir" != "X"; then
11464 if test -f "$dir/$libname.la"; then
11465 found_la="$dir/$libname.la"
11466 fi
11467 fi
11468 ;;
11469 esac
11470 if test "X$found_dir" != "X"; then
11471 break
11472 fi
11473 done
11474 fi
11475 if test "X$found_dir" != "X"; then
11476 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name"
11477 if test "X$found_so" != "X"; then
11478 if test "$enable_rpath" = no \
11479 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
11480 || test "X$found_dir" = "X/usr/$acl_libdirstem2" \
11481 || test "X$found_dir" = "X/usr/$acl_libdirstem3"; then
11482 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11483 else
11484 haveit=
11485 for x in $ltrpathdirs; do
11486 if test "X$x" = "X$found_dir"; then
11487 haveit=yes
11488 break
11489 fi
11490 done
11491 if test -z "$haveit"; then
11492 ltrpathdirs="$ltrpathdirs $found_dir"
11493 fi
11494 if test "$acl_hardcode_direct" = yes; then
11495 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11496 else
11497 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
11498 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11499 haveit=
11500 for x in $rpathdirs; do
11501 if test "X$x" = "X$found_dir"; then
11502 haveit=yes
11503 break
11504 fi
11505 done
11506 if test -z "$haveit"; then
11507 rpathdirs="$rpathdirs $found_dir"
11508 fi
11509 else
11510 haveit=
11511 for x in $LDFLAGS $LIBICONV; do
11512
11513 acl_save_prefix="$prefix"
11514 prefix="$acl_final_prefix"
11515 acl_save_exec_prefix="$exec_prefix"
11516 exec_prefix="$acl_final_exec_prefix"
11517 eval x=\"$x\"
11518 exec_prefix="$acl_save_exec_prefix"
11519 prefix="$acl_save_prefix"
11520
11521 if test "X$x" = "X-L$found_dir"; then
11522 haveit=yes
11523 break
11524 fi
11525 done
11526 if test -z "$haveit"; then
11527 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir"
11528 fi
11529 if test "$acl_hardcode_minus_L" != no; then
11530 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so"
11531 else
11532 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11533 fi
11534 fi
11535 fi
11536 fi
11537 else
11538 if test "X$found_a" != "X"; then
11539 LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a"
11540 else
11541 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name"
11542 fi
11543 fi
11544 additional_includedir=
11545 case "$found_dir" in
11546 */$acl_libdirstem | */$acl_libdirstem/)
11547 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
11548 if test "$name" = 'iconv'; then
11549 LIBICONV_PREFIX="$basedir"
11550 fi
11551 additional_includedir="$basedir/include"
11552 ;;
11553 */$acl_libdirstem2 | */$acl_libdirstem2/)
11554 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
11555 if test "$name" = 'iconv'; then
11556 LIBICONV_PREFIX="$basedir"
11557 fi
11558 additional_includedir="$basedir/include"
11559 ;;
11560 */$acl_libdirstem3 | */$acl_libdirstem3/)
11561 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem3/"'*$,,'`
11562 if test "$name" = 'iconv'; then
11563 LIBICONV_PREFIX="$basedir"
11564 fi
11565 additional_includedir="$basedir/include"
11566 ;;
11567 esac
11568 if test "X$additional_includedir" != "X"; then
11569 if test "X$additional_includedir" != "X/usr/include"; then
11570 haveit=
11571 if test "X$additional_includedir" = "X/usr/local/include"; then
11572 if test -n "$GCC"; then
11573 case $host_os in
11574 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
11575 esac
11576 fi
11577 fi
11578 if test -z "$haveit"; then
11579 for x in $CPPFLAGS $INCICONV; do
11580
11581 acl_save_prefix="$prefix"
11582 prefix="$acl_final_prefix"
11583 acl_save_exec_prefix="$exec_prefix"
11584 exec_prefix="$acl_final_exec_prefix"
11585 eval x=\"$x\"
11586 exec_prefix="$acl_save_exec_prefix"
11587 prefix="$acl_save_prefix"
11588
11589 if test "X$x" = "X-I$additional_includedir"; then
11590 haveit=yes
11591 break
11592 fi
11593 done
11594 if test -z "$haveit"; then
11595 if test -d "$additional_includedir"; then
11596 INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir"
11597 fi
11598 fi
11599 fi
11600 fi
11601 fi
11602 if test -n "$found_la"; then
11603 save_libdir="$libdir"
11604 case "$found_la" in
11605 */* | *\\*) . "$found_la" ;;
11606 *) . "./$found_la" ;;
11607 esac
11608 libdir="$save_libdir"
11609 for dep in $dependency_libs; do
11610 case "$dep" in
11611 -L*)
11612 dependency_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
11613 if test "X$dependency_libdir" != "X/usr/$acl_libdirstem" \
11614 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem2" \
11615 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem3"; then
11616 haveit=
11617 if test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem" \
11618 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem2" \
11619 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem3"; then
11620 if test -n "$GCC"; then
11621 case $host_os in
11622 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
11623 esac
11624 fi
11625 fi
11626 if test -z "$haveit"; then
11627 haveit=
11628 for x in $LDFLAGS $LIBICONV; do
11629
11630 acl_save_prefix="$prefix"
11631 prefix="$acl_final_prefix"
11632 acl_save_exec_prefix="$exec_prefix"
11633 exec_prefix="$acl_final_exec_prefix"
11634 eval x=\"$x\"
11635 exec_prefix="$acl_save_exec_prefix"
11636 prefix="$acl_save_prefix"
11637
11638 if test "X$x" = "X-L$dependency_libdir"; then
11639 haveit=yes
11640 break
11641 fi
11642 done
11643 if test -z "$haveit"; then
11644 if test -d "$dependency_libdir"; then
11645 LIBICONV="${LIBICONV}${LIBICONV:+ }-L$dependency_libdir"
11646 fi
11647 fi
11648 haveit=
11649 for x in $LDFLAGS $LTLIBICONV; do
11650
11651 acl_save_prefix="$prefix"
11652 prefix="$acl_final_prefix"
11653 acl_save_exec_prefix="$exec_prefix"
11654 exec_prefix="$acl_final_exec_prefix"
11655 eval x=\"$x\"
11656 exec_prefix="$acl_save_exec_prefix"
11657 prefix="$acl_save_prefix"
11658
11659 if test "X$x" = "X-L$dependency_libdir"; then
11660 haveit=yes
11661 break
11662 fi
11663 done
11664 if test -z "$haveit"; then
11665 if test -d "$dependency_libdir"; then
11666 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$dependency_libdir"
11667 fi
11668 fi
11669 fi
11670 fi
11671 ;;
11672 -R*)
11673 dir=`echo "X$dep" | sed -e 's/^X-R//'`
11674 if test "$enable_rpath" != no; then
11675 haveit=
11676 for x in $rpathdirs; do
11677 if test "X$x" = "X$dir"; then
11678 haveit=yes
11679 break
11680 fi
11681 done
11682 if test -z "$haveit"; then
11683 rpathdirs="$rpathdirs $dir"
11684 fi
11685 haveit=
11686 for x in $ltrpathdirs; do
11687 if test "X$x" = "X$dir"; then
11688 haveit=yes
11689 break
11690 fi
11691 done
11692 if test -z "$haveit"; then
11693 ltrpathdirs="$ltrpathdirs $dir"
11694 fi
11695 fi
11696 ;;
11697 -l*)
11698 dep=`echo "X$dep" | sed -e 's/^X-l//'`
11699 if test "X$dep" != Xc \
11700 || case $host_os in
11701 linux* | gnu* | k*bsd*-gnu) false ;;
11702 *) true ;;
11703 esac; then
11704 names_next_round="$names_next_round $dep"
11705 fi
11706 ;;
11707 *.la)
11708 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
11709 ;;
11710 *)
11711 LIBICONV="${LIBICONV}${LIBICONV:+ }$dep"
11712 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep"
11713 ;;
11714 esac
11715 done
11716 fi
11717 else
11718 LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name"
11719 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name"
11720 fi
11721 fi
11722 fi
11723 done
11724 done
11725 if test "X$rpathdirs" != "X"; then
11726 if test -n "$acl_hardcode_libdir_separator"; then
11727 alldirs=
11728 for found_dir in $rpathdirs; do
11729 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
11730 done
11731 acl_save_libdir="$libdir"
11732 libdir="$alldirs"
11733 eval flag=\"$acl_hardcode_libdir_flag_spec\"
11734 libdir="$acl_save_libdir"
11735 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11736 else
11737 for found_dir in $rpathdirs; do
11738 acl_save_libdir="$libdir"
11739 libdir="$found_dir"
11740 eval flag=\"$acl_hardcode_libdir_flag_spec\"
11741 libdir="$acl_save_libdir"
11742 LIBICONV="${LIBICONV}${LIBICONV:+ }$flag"
11743 done
11744 fi
11745 fi
11746 if test "X$ltrpathdirs" != "X"; then
11747 for found_dir in $ltrpathdirs; do
11748 LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir"
11749 done
11750 fi
11751
11752
11753
11754
11755
11756
11757
11758
11759
11760
11761
11762 am_save_CPPFLAGS="$CPPFLAGS"
11763
11764 for element in $INCICONV; do
11765 haveit=
11766 for x in $CPPFLAGS; do
11767
11768 acl_save_prefix="$prefix"
11769 prefix="$acl_final_prefix"
11770 acl_save_exec_prefix="$exec_prefix"
11771 exec_prefix="$acl_final_exec_prefix"
11772 eval x=\"$x\"
11773 exec_prefix="$acl_save_exec_prefix"
11774 prefix="$acl_save_prefix"
11775
11776 if test "X$x" = "X$element"; then
11777 haveit=yes
11778 break
11779 fi
11780 done
11781 if test -z "$haveit"; then
11782 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
11783 fi
11784 done
11785
11786
11787 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5
11788printf %s "checking for iconv... " >&6; }
11789if test ${am_cv_func_iconv+y}
11790then :
11791 printf %s "(cached) " >&6
11792else case e in #(
11793 e)
11794 am_cv_func_iconv="no, consider installing GNU libiconv"
11795 am_cv_lib_iconv=no
11796 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11797/* end confdefs.h. */
11798
11799#include <stdlib.h>
11800#include <iconv.h>
11801
11802int
11803main (void)
11804{
11805iconv_t cd = iconv_open("","");
11806 iconv(cd,NULL,NULL,NULL,NULL);
11807 iconv_close(cd);
11808 ;
11809 return 0;
11810}
11811_ACEOF
11812if ac_fn_c_try_link "$LINENO"
11813then :
11814 am_cv_func_iconv=yes
11815fi
11816rm -f core conftest.err conftest.$ac_objext conftest.beam \
11817 conftest$ac_exeext conftest.$ac_ext
11818 if test "$am_cv_func_iconv" != yes; then
11819 am_save_LIBS="$LIBS"
11820 LIBS="$LIBS $LIBICONV"
11821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11822/* end confdefs.h. */
11823
11824#include <stdlib.h>
11825#include <iconv.h>
11826
11827int
11828main (void)
11829{
11830iconv_t cd = iconv_open("","");
11831 iconv(cd,NULL,NULL,NULL,NULL);
11832 iconv_close(cd);
11833 ;
11834 return 0;
11835}
11836_ACEOF
11837if ac_fn_c_try_link "$LINENO"
11838then :
11839 am_cv_lib_iconv=yes
11840 am_cv_func_iconv=yes
11841fi
11842rm -f core conftest.err conftest.$ac_objext conftest.beam \
11843 conftest$ac_exeext conftest.$ac_ext
11844 LIBS="$am_save_LIBS"
11845 fi
11846 ;;
11847esac
11848fi
11849{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5
11850printf "%s\n" "$am_cv_func_iconv" >&6; }
11851 if test "$am_cv_func_iconv" = yes; then
11852 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working iconv" >&5
11853printf %s "checking for working iconv... " >&6; }
11854if test ${am_cv_func_iconv_works+y}
11855then :
11856 printf %s "(cached) " >&6
11857else case e in #(
11858 e)
11859 am_save_LIBS="$LIBS"
11860 if test $am_cv_lib_iconv = yes; then
11861 LIBS="$LIBS $LIBICONV"
11862 fi
11863 am_cv_func_iconv_works=no
11864 for ac_iconv_const in '' 'const'; do
11865 if test "$cross_compiling" = yes
11866then :
11867 case "$host_os" in
11868 aix* | hpux*) am_cv_func_iconv_works="guessing no" ;;
11869 *) am_cv_func_iconv_works="guessing yes" ;;
11870 esac
11871else case e in #(
11872 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11873/* end confdefs.h. */
11874
11875#include <iconv.h>
11876#include <string.h>
11877
11878#ifndef ICONV_CONST
11879# define ICONV_CONST $ac_iconv_const
11880#endif
11881
11882int
11883main (void)
11884{
11885int result = 0;
11886 /* Test against AIX 5.1...7.2 bug: Failures are not distinguishable from
11887 successful returns. This is even documented in
11888 <https://www.ibm.com/support/knowledgecenter/ssw_aix_72/i_bostechref/iconv.html> */
11889 {
11890 iconv_t cd_utf8_to_88591 = iconv_open ("ISO8859-1", "UTF-8");
11891 if (cd_utf8_to_88591 != (iconv_t)(-1))
11892 {
11893 static ICONV_CONST char input[] = "\342\202\254"; /* EURO SIGN */
11894 char buf[10];
11895 ICONV_CONST char *inptr = input;
11896 size_t inbytesleft = strlen (input);
11897 char *outptr = buf;
11898 size_t outbytesleft = sizeof (buf);
11899 size_t res = iconv (cd_utf8_to_88591,
11900 &inptr, &inbytesleft,
11901 &outptr, &outbytesleft);
11902 if (res == 0)
11903 result |= 1;
11904 iconv_close (cd_utf8_to_88591);
11905 }
11906 }
11907 /* Test against Solaris 10 bug: Failures are not distinguishable from
11908 successful returns. */
11909 {
11910 iconv_t cd_ascii_to_88591 = iconv_open ("ISO8859-1", "646");
11911 if (cd_ascii_to_88591 != (iconv_t)(-1))
11912 {
11913 static ICONV_CONST char input[] = "\263";
11914 char buf[10];
11915 ICONV_CONST char *inptr = input;
11916 size_t inbytesleft = strlen (input);
11917 char *outptr = buf;
11918 size_t outbytesleft = sizeof (buf);
11919 size_t res = iconv (cd_ascii_to_88591,
11920 &inptr, &inbytesleft,
11921 &outptr, &outbytesleft);
11922 if (res == 0)
11923 result |= 2;
11924 iconv_close (cd_ascii_to_88591);
11925 }
11926 }
11927 /* Test against AIX 6.1..7.1 bug: Buffer overrun. */
11928 {
11929 iconv_t cd_88591_to_utf8 = iconv_open ("UTF-8", "ISO-8859-1");
11930 if (cd_88591_to_utf8 != (iconv_t)(-1))
11931 {
11932 static ICONV_CONST char input[] = "\304";
11933 static char buf[2] = { (char)0xDE, (char)0xAD };
11934 ICONV_CONST char *inptr = input;
11935 size_t inbytesleft = 1;
11936 char *outptr = buf;
11937 size_t outbytesleft = 1;
11938 size_t res = iconv (cd_88591_to_utf8,
11939 &inptr, &inbytesleft,
11940 &outptr, &outbytesleft);
11941 if (res != (size_t)(-1) || outptr - buf > 1 || buf[1] != (char)0xAD)
11942 result |= 4;
11943 iconv_close (cd_88591_to_utf8);
11944 }
11945 }
11946#if 0 /* This bug could be worked around by the caller. */
11947 /* Test against HP-UX 11.11 bug: Positive return value instead of 0. */
11948 {
11949 iconv_t cd_88591_to_utf8 = iconv_open ("utf8", "iso88591");
11950 if (cd_88591_to_utf8 != (iconv_t)(-1))
11951 {
11952 static ICONV_CONST char input[] = "\304rger mit b\366sen B\374bchen ohne Augenma\337";
11953 char buf[50];
11954 ICONV_CONST char *inptr = input;
11955 size_t inbytesleft = strlen (input);
11956 char *outptr = buf;
11957 size_t outbytesleft = sizeof (buf);
11958 size_t res = iconv (cd_88591_to_utf8,
11959 &inptr, &inbytesleft,
11960 &outptr, &outbytesleft);
11961 if ((int)res > 0)
11962 result |= 8;
11963 iconv_close (cd_88591_to_utf8);
11964 }
11965 }
11966#endif
11967 /* Test against HP-UX 11.11 bug: No converter from EUC-JP to UTF-8 is
11968 provided. */
11969 {
11970 /* Try standardized names. */
11971 iconv_t cd1 = iconv_open ("UTF-8", "EUC-JP");
11972 /* Try IRIX, OSF/1 names. */
11973 iconv_t cd2 = iconv_open ("UTF-8", "eucJP");
11974 /* Try AIX names. */
11975 iconv_t cd3 = iconv_open ("UTF-8", "IBM-eucJP");
11976 /* Try HP-UX names. */
11977 iconv_t cd4 = iconv_open ("utf8", "eucJP");
11978 if (cd1 == (iconv_t)(-1) && cd2 == (iconv_t)(-1)
11979 && cd3 == (iconv_t)(-1) && cd4 == (iconv_t)(-1))
11980 result |= 16;
11981 if (cd1 != (iconv_t)(-1))
11982 iconv_close (cd1);
11983 if (cd2 != (iconv_t)(-1))
11984 iconv_close (cd2);
11985 if (cd3 != (iconv_t)(-1))
11986 iconv_close (cd3);
11987 if (cd4 != (iconv_t)(-1))
11988 iconv_close (cd4);
11989 }
11990 return result;
11991
11992 ;
11993 return 0;
11994}
11995_ACEOF
11996if ac_fn_c_try_run "$LINENO"
11997then :
11998 am_cv_func_iconv_works=yes
11999fi
12000rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12001 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12002esac
12003fi
12004
12005 test "$am_cv_func_iconv_works" = no || break
12006 done
12007 LIBS="$am_save_LIBS"
12008 ;;
12009esac
12010fi
12011{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv_works" >&5
12012printf "%s\n" "$am_cv_func_iconv_works" >&6; }
12013 case "$am_cv_func_iconv_works" in
12014 *no) am_func_iconv=no am_cv_lib_iconv=no ;;
12015 *) am_func_iconv=yes ;;
12016 esac
12017 else
12018 am_func_iconv=no am_cv_lib_iconv=no
12019 fi
12020 if test "$am_func_iconv" = yes; then
12021
12022printf "%s\n" "#define HAVE_ICONV 1" >>confdefs.h
12023
12024 fi
12025 if test "$am_cv_lib_iconv" = yes; then
12026 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5
12027printf %s "checking how to link with libiconv... " >&6; }
12028 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5
12029printf "%s\n" "$LIBICONV" >&6; }
12030 else
12031 CPPFLAGS="$am_save_CPPFLAGS"
12032 LIBICONV=
12033 LTLIBICONV=
12034 fi
12035
12036
12037
12038 if test "$am_cv_func_iconv" = yes; then
12039 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether iconv is compatible with its POSIX signature" >&5
12040printf %s "checking whether iconv is compatible with its POSIX signature... " >&6; }
12041if test ${gl_cv_iconv_nonconst+y}
12042then :
12043 printf %s "(cached) " >&6
12044else case e in #(
12045 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12046/* end confdefs.h. */
12047
12048#include <stdlib.h>
12049#include <iconv.h>
12050extern
12051#ifdef __cplusplus
12052"C"
12053#endif
12054size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
12055
12056int
12057main (void)
12058{
12059
12060 ;
12061 return 0;
12062}
12063_ACEOF
12064if ac_fn_c_try_compile "$LINENO"
12065then :
12066 gl_cv_iconv_nonconst=yes
12067else case e in #(
12068 e) gl_cv_iconv_nonconst=no ;;
12069esac
12070fi
12071rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12072 ;;
12073esac
12074fi
12075{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_iconv_nonconst" >&5
12076printf "%s\n" "$gl_cv_iconv_nonconst" >&6; }
12077 else
12078 gl_cv_iconv_nonconst=yes
12079 fi
12080 if test $gl_cv_iconv_nonconst = yes; then
12081 iconv_arg1=""
12082 else
12083 iconv_arg1="const"
12084 fi
12085
12086printf "%s\n" "#define ICONV_CONST $iconv_arg1" >>confdefs.h
12087
12088
12089
12090
12091
12092
12093 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12094/* end confdefs.h. */
12095int foo (int a) { a = __builtin_expect (a, 10); return a == 10 ? 0 : 1; }
12096int
12097main (void)
12098{
12099
12100 ;
12101 return 0;
12102}
12103_ACEOF
12104if ac_fn_c_try_link "$LINENO"
12105then :
12106
12107printf "%s\n" "#define HAVE_BUILTIN_EXPECT 1" >>confdefs.h
12108
12109fi
12110rm -f core conftest.err conftest.$ac_objext conftest.beam \
12111 conftest$ac_exeext conftest.$ac_ext
12112
12113 ac_fn_c_check_header_compile "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
12114if test "x$ac_cv_header_inttypes_h" = xyes
12115then :
12116 printf "%s\n" "#define HAVE_INTTYPES_H 1" >>confdefs.h
12117
12118fi
12119ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
12120if test "x$ac_cv_header_unistd_h" = xyes
12121then :
12122 printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
12123
12124fi
12125ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
12126if test "x$ac_cv_header_sys_param_h" = xyes
12127then :
12128 printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h
12129
12130fi
12131
12132 ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd"
12133if test "x$ac_cv_func_getcwd" = xyes
12134then :
12135 printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h
12136
12137fi
12138ac_fn_c_check_func "$LINENO" "getegid" "ac_cv_func_getegid"
12139if test "x$ac_cv_func_getegid" = xyes
12140then :
12141 printf "%s\n" "#define HAVE_GETEGID 1" >>confdefs.h
12142
12143fi
12144ac_fn_c_check_func "$LINENO" "geteuid" "ac_cv_func_geteuid"
12145if test "x$ac_cv_func_geteuid" = xyes
12146then :
12147 printf "%s\n" "#define HAVE_GETEUID 1" >>confdefs.h
12148
12149fi
12150ac_fn_c_check_func "$LINENO" "getgid" "ac_cv_func_getgid"
12151if test "x$ac_cv_func_getgid" = xyes
12152then :
12153 printf "%s\n" "#define HAVE_GETGID 1" >>confdefs.h
12154
12155fi
12156ac_fn_c_check_func "$LINENO" "getuid" "ac_cv_func_getuid"
12157if test "x$ac_cv_func_getuid" = xyes
12158then :
12159 printf "%s\n" "#define HAVE_GETUID 1" >>confdefs.h
12160
12161fi
12162ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
12163if test "x$ac_cv_func_mempcpy" = xyes
12164then :
12165 printf "%s\n" "#define HAVE_MEMPCPY 1" >>confdefs.h
12166
12167fi
12168ac_fn_c_check_func "$LINENO" "munmap" "ac_cv_func_munmap"
12169if test "x$ac_cv_func_munmap" = xyes
12170then :
12171 printf "%s\n" "#define HAVE_MUNMAP 1" >>confdefs.h
12172
12173fi
12174ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
12175if test "x$ac_cv_func_stpcpy" = xyes
12176then :
12177 printf "%s\n" "#define HAVE_STPCPY 1" >>confdefs.h
12178
12179fi
12180ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
12181if test "x$ac_cv_func_strcasecmp" = xyes
12182then :
12183 printf "%s\n" "#define HAVE_STRCASECMP 1" >>confdefs.h
12184
12185fi
12186ac_fn_c_check_func "$LINENO" "tsearch" "ac_cv_func_tsearch"
12187if test "x$ac_cv_func_tsearch" = xyes
12188then :
12189 printf "%s\n" "#define HAVE_TSEARCH 1" >>confdefs.h
12190
12191fi
12192ac_fn_c_check_func "$LINENO" "__fsetlocking" "ac_cv_func___fsetlocking"
12193if test "x$ac_cv_func___fsetlocking" = xyes
12194then :
12195 printf "%s\n" "#define HAVE___FSETLOCKING 1" >>confdefs.h
12196
12197fi
12198
12199
12200 ac_fn_check_decl "$LINENO" "feof_unlocked" "ac_cv_have_decl_feof_unlocked" "#include <stdio.h>
12201" "$ac_c_undeclared_builtin_options" "CFLAGS"
12202if test "x$ac_cv_have_decl_feof_unlocked" = xyes
12203then :
12204 ac_have_decl=1
12205else case e in #(
12206 e) ac_have_decl=0 ;;
12207esac
12208fi
12209printf "%s\n" "#define HAVE_DECL_FEOF_UNLOCKED $ac_have_decl" >>confdefs.h
12210ac_fn_check_decl "$LINENO" "fgets_unlocked" "ac_cv_have_decl_fgets_unlocked" "#include <stdio.h>
12211" "$ac_c_undeclared_builtin_options" "CFLAGS"
12212if test "x$ac_cv_have_decl_fgets_unlocked" = xyes
12213then :
12214 ac_have_decl=1
12215else case e in #(
12216 e) ac_have_decl=0 ;;
12217esac
12218fi
12219printf "%s\n" "#define HAVE_DECL_FGETS_UNLOCKED $ac_have_decl" >>confdefs.h
12220
12221
12222
12223
12224 ac_fn_c_check_func "$LINENO" "localeconv" "ac_cv_func_localeconv"
12225if test "x$ac_cv_func_localeconv" = xyes
12226then :
12227 printf "%s\n" "#define HAVE_LOCALECONV 1" >>confdefs.h
12228
12229fi
12230
12231
12232
12233 for ac_prog in bison
12234do
12235 # Extract the first word of "$ac_prog", so it can be a program name with args.
12236set dummy $ac_prog; ac_word=$2
12237{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
12238printf %s "checking for $ac_word... " >&6; }
12239if test ${ac_cv_prog_INTLBISON+y}
12240then :
12241 printf %s "(cached) " >&6
12242else case e in #(
12243 e) if test -n "$INTLBISON"; then
12244 ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test.
12245else
12246as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
12247for as_dir in $PATH
12248do
12249 IFS=$as_save_IFS
12250 case $as_dir in #(((
12251 '') as_dir=./ ;;
12252 */) ;;
12253 *) as_dir=$as_dir/ ;;
12254 esac
12255 for ac_exec_ext in '' $ac_executable_extensions; do
12256 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
12257 ac_cv_prog_INTLBISON="$ac_prog"
12258 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
12259 break 2
12260 fi
12261done
12262 done
12263IFS=$as_save_IFS
12264
12265fi ;;
12266esac
12267fi
12268INTLBISON=$ac_cv_prog_INTLBISON
12269if test -n "$INTLBISON"; then
12270 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $INTLBISON" >&5
12271printf "%s\n" "$INTLBISON" >&6; }
12272else
12273 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
12274printf "%s\n" "no" >&6; }
12275fi
12276
12277
12278 test -n "$INTLBISON" && break
12279done
12280
12281 if test -z "$INTLBISON"; then
12282 ac_verc_fail=yes
12283 else
12284 cat >conftest.y <<_ACEOF
12285%require "3.0"
12286%%
12287exp:
12288_ACEOF
12289 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for bison 3.0 or newer" >&5
12290printf %s "checking for bison 3.0 or newer... " >&6; }
12291 ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'`
12292 : ${ac_prog_version:='v. ?.??'}
12293 if $INTLBISON conftest.y -o conftest.c 2>/dev/null; then
12294 ac_prog_version="$ac_prog_version, ok"
12295 ac_verc_fail=no
12296 else
12297 ac_prog_version="$ac_prog_version, bad"
12298 ac_verc_fail=yes
12299 fi
12300 rm -f conftest.y conftest.c
12301 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5
12302printf "%s\n" "$ac_prog_version" >&6; }
12303 fi
12304 if test $ac_verc_fail = yes; then
12305 INTLBISON=:
12306 fi
12307
12308
12309
12310
12311
12312
12313 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
12314printf %s "checking for long long int... " >&6; }
12315if test ${ac_cv_type_long_long_int+y}
12316then :
12317 printf %s "(cached) " >&6
12318else case e in #(
12319 e) ac_cv_type_long_long_int=yes
12320 case $ac_prog_cc_stdc in
12321 no | c89) ;;
12322 *)
12323 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
12324 if test $ac_cv_type_long_long_int = yes; then
12325 if test "$cross_compiling" = yes
12326then :
12327 :
12328else case e in #(
12329 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12330/* end confdefs.h. */
12331#include <limits.h>
12332 #ifndef LLONG_MAX
12333 # define HALF \\
12334 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
12335 # define LLONG_MAX (HALF - 1 + HALF)
12336 #endif
12337int
12338main (void)
12339{
12340long long int n = 1;
12341 int i;
12342 for (i = 0; ; i++)
12343 {
12344 long long int m = n << i;
12345 if (m >> i != n)
12346 return 1;
12347 if (LLONG_MAX / 2 < m)
12348 break;
12349 }
12350 return 0;
12351 ;
12352 return 0;
12353}
12354_ACEOF
12355if ac_fn_c_try_run "$LINENO"
12356then :
12357
12358else case e in #(
12359 e) ac_cv_type_long_long_int=no ;;
12360esac
12361fi
12362rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12363 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12364esac
12365fi
12366
12367 fi;;
12368 esac ;;
12369esac
12370fi
12371{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
12372printf "%s\n" "$ac_cv_type_long_long_int" >&6; }
12373 if test $ac_cv_type_long_long_int = yes; then
12374
12375printf "%s\n" "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
12376
12377 fi
12378
12379
12380 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wchar_t" >&5
12381printf %s "checking for wchar_t... " >&6; }
12382if test ${gt_cv_c_wchar_t+y}
12383then :
12384 printf %s "(cached) " >&6
12385else case e in #(
12386 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12387/* end confdefs.h. */
12388#include <stddef.h>
12389 wchar_t foo = (wchar_t)'\0';
12390int
12391main (void)
12392{
12393
12394 ;
12395 return 0;
12396}
12397_ACEOF
12398if ac_fn_c_try_compile "$LINENO"
12399then :
12400 gt_cv_c_wchar_t=yes
12401else case e in #(
12402 e) gt_cv_c_wchar_t=no ;;
12403esac
12404fi
12405rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12406esac
12407fi
12408{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wchar_t" >&5
12409printf "%s\n" "$gt_cv_c_wchar_t" >&6; }
12410 if test $gt_cv_c_wchar_t = yes; then
12411
12412printf "%s\n" "#define HAVE_WCHAR_T 1" >>confdefs.h
12413
12414 fi
12415
12416
12417 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wint_t" >&5
12418printf %s "checking for wint_t... " >&6; }
12419if test ${gt_cv_c_wint_t+y}
12420then :
12421 printf %s "(cached) " >&6
12422else case e in #(
12423 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12424/* end confdefs.h. */
12425#include <wchar.h>
12426 wint_t foo = (wchar_t)'\0';
12427int
12428main (void)
12429{
12430
12431 ;
12432 return 0;
12433}
12434_ACEOF
12435if ac_fn_c_try_compile "$LINENO"
12436then :
12437 gt_cv_c_wint_t=yes
12438else case e in #(
12439 e) gt_cv_c_wint_t=no ;;
12440esac
12441fi
12442rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12443esac
12444fi
12445{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_wint_t" >&5
12446printf "%s\n" "$gt_cv_c_wint_t" >&6; }
12447 if test $gt_cv_c_wint_t = yes; then
12448
12449printf "%s\n" "#define HAVE_WINT_T 1" >>confdefs.h
12450
12451
12452 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether wint_t is large enough" >&5
12453printf %s "checking whether wint_t is large enough... " >&6; }
12454if test ${gl_cv_type_wint_t_large_enough+y}
12455then :
12456 printf %s "(cached) " >&6
12457else case e in #(
12458 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12459/* end confdefs.h. */
12460#include <wchar.h>
12461 int verify[sizeof (wint_t) < sizeof (int) ? -1 : 1];
12462
12463int
12464main (void)
12465{
12466
12467 ;
12468 return 0;
12469}
12470_ACEOF
12471if ac_fn_c_try_compile "$LINENO"
12472then :
12473 gl_cv_type_wint_t_large_enough=yes
12474else case e in #(
12475 e) gl_cv_type_wint_t_large_enough=no ;;
12476esac
12477fi
12478rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12479esac
12480fi
12481{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_type_wint_t_large_enough" >&5
12482printf "%s\n" "$gl_cv_type_wint_t_large_enough" >&6; }
12483 if test $gl_cv_type_wint_t_large_enough = no; then
12484 GNULIBHEADERS_OVERRIDE_WINT_T=1
12485 else
12486 GNULIBHEADERS_OVERRIDE_WINT_T=0
12487 fi
12488 else
12489 GNULIBHEADERS_OVERRIDE_WINT_T=0
12490 fi
12491
12492
12493
12494
12495
12496 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5
12497printf %s "checking for intmax_t... " >&6; }
12498if test ${gt_cv_c_intmax_t+y}
12499then :
12500 printf %s "(cached) " >&6
12501else case e in #(
12502 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12503/* end confdefs.h. */
12504
12505#include <stddef.h>
12506#include <stdlib.h>
12507#if HAVE_STDINT_H_WITH_UINTMAX
12508#include <stdint.h>
12509#endif
12510#if HAVE_INTTYPES_H_WITH_UINTMAX
12511#include <inttypes.h>
12512#endif
12513
12514int
12515main (void)
12516{
12517intmax_t x = -1;
12518 return !x;
12519 ;
12520 return 0;
12521}
12522_ACEOF
12523if ac_fn_c_try_compile "$LINENO"
12524then :
12525 gt_cv_c_intmax_t=yes
12526else case e in #(
12527 e) gt_cv_c_intmax_t=no ;;
12528esac
12529fi
12530rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12531esac
12532fi
12533{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_c_intmax_t" >&5
12534printf "%s\n" "$gt_cv_c_intmax_t" >&6; }
12535 if test $gt_cv_c_intmax_t = yes; then
12536
12537printf "%s\n" "#define HAVE_INTMAX_T 1" >>confdefs.h
12538
12539 fi
12540
12541
12542
12543 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether printf() supports POSIX/XSI format strings" >&5
12544printf %s "checking whether printf() supports POSIX/XSI format strings... " >&6; }
12545if test ${gt_cv_func_printf_posix+y}
12546then :
12547 printf %s "(cached) " >&6
12548else case e in #(
12549 e)
12550 if test "$cross_compiling" = yes
12551then :
12552
12553 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12554/* end confdefs.h. */
12555
12556#if defined __NetBSD__ || defined __BEOS__ || defined _MSC_VER || defined __MINGW32__ || defined __CYGWIN__
12557 notposix
12558#endif
12559
12560_ACEOF
12561if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12562 $EGREP_TRADITIONAL "notposix" >/dev/null 2>&1
12563then :
12564 gt_cv_func_printf_posix="guessing no"
12565else case e in #(
12566 e) gt_cv_func_printf_posix="guessing yes" ;;
12567esac
12568fi
12569rm -rf conftest*
12570
12571
12572else case e in #(
12573 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12574/* end confdefs.h. */
12575
12576#include <stdio.h>
12577#include <string.h>
12578/* The string "%2$d %1$d", with dollar characters protected from the shell's
12579 dollar expansion (possibly an autoconf bug). */
12580static char format[] = { '%', '2', '$', 'd', ' ', '%', '1', '$', 'd', '\0' };
12581static char buf[100];
12582int main ()
12583{
12584 sprintf (buf, format, 33, 55);
12585 return (strcmp (buf, "55 33") != 0);
12586}
12587_ACEOF
12588if ac_fn_c_try_run "$LINENO"
12589then :
12590 gt_cv_func_printf_posix=yes
12591else case e in #(
12592 e) gt_cv_func_printf_posix=no ;;
12593esac
12594fi
12595rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12596 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12597esac
12598fi
12599
12600 ;;
12601esac
12602fi
12603{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_printf_posix" >&5
12604printf "%s\n" "$gt_cv_func_printf_posix" >&6; }
12605 case $gt_cv_func_printf_posix in
12606 *yes)
12607
12608printf "%s\n" "#define HAVE_POSIX_PRINTF 1" >>confdefs.h
12609
12610 ;;
12611 esac
12612
12613
12614 ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
12615if test "x$ac_cv_header_stdint_h" = xyes
12616then :
12617 printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
12618
12619fi
12620
12621 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for SIZE_MAX" >&5
12622printf %s "checking for SIZE_MAX... " >&6; }
12623if test ${gl_cv_size_max+y}
12624then :
12625 printf %s "(cached) " >&6
12626else case e in #(
12627 e)
12628 gl_cv_size_max=no
12629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12630/* end confdefs.h. */
12631
12632#include <limits.h>
12633#if HAVE_STDINT_H
12634#include <stdint.h>
12635#endif
12636#ifdef SIZE_MAX
12637Found it
12638#endif
12639
12640_ACEOF
12641if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12642 $EGREP_TRADITIONAL "Found it" >/dev/null 2>&1
12643then :
12644 gl_cv_size_max=yes
12645fi
12646rm -rf conftest*
12647
12648 if test $gl_cv_size_max != yes; then
12649 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) * CHAR_BIT - 1" "size_t_bits_minus_1" "#include <stddef.h>
12650#include <limits.h>"
12651then :
12652
12653else case e in #(
12654 e) size_t_bits_minus_1= ;;
12655esac
12656fi
12657
12658 if ac_fn_c_compute_int "$LINENO" "sizeof (size_t) <= sizeof (unsigned int)" "fits_in_uint" "#include <stddef.h>"
12659then :
12660
12661else case e in #(
12662 e) fits_in_uint= ;;
12663esac
12664fi
12665
12666 if test -n "$size_t_bits_minus_1" && test -n "$fits_in_uint"; then
12667 if test $fits_in_uint = 1; then
12668 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12669/* end confdefs.h. */
12670#include <stddef.h>
12671 extern size_t foo;
12672 extern unsigned long foo;
12673
12674int
12675main (void)
12676{
12677
12678 ;
12679 return 0;
12680}
12681_ACEOF
12682if ac_fn_c_try_compile "$LINENO"
12683then :
12684 fits_in_uint=0
12685fi
12686rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
12687 fi
12688 if test $fits_in_uint = 1; then
12689 gl_cv_size_max="(((1U << $size_t_bits_minus_1) - 1) * 2 + 1)"
12690 else
12691 gl_cv_size_max="(((1UL << $size_t_bits_minus_1) - 1) * 2 + 1)"
12692 fi
12693 else
12694 gl_cv_size_max='((size_t)~(size_t)0)'
12695 fi
12696 fi
12697 ;;
12698esac
12699fi
12700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_size_max" >&5
12701printf "%s\n" "$gl_cv_size_max" >&6; }
12702 if test "$gl_cv_size_max" != yes; then
12703
12704printf "%s\n" "#define SIZE_MAX $gl_cv_size_max" >>confdefs.h
12705
12706 fi
12707
12708
12709
12710
12711 ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
12712if test "x$ac_cv_header_stdint_h" = xyes
12713then :
12714 printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
12715
12716fi
12717
12718
12719
12720
12721
12722
12723
12724
12725 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working fcntl.h" >&5
12726printf %s "checking for working fcntl.h... " >&6; }
12727if test ${gl_cv_header_working_fcntl_h+y}
12728then :
12729 printf %s "(cached) " >&6
12730else case e in #(
12731 e) if test "$cross_compiling" = yes
12732then :
12733 case "$host_os" in
12734 # Guess 'no' on native Windows.
12735 mingw*) gl_cv_header_working_fcntl_h='no' ;;
12736 *) gl_cv_header_working_fcntl_h=cross-compiling ;;
12737 esac
12738
12739else case e in #(
12740 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12741/* end confdefs.h. */
12742#include <sys/types.h>
12743 #include <sys/stat.h>
12744 #if HAVE_UNISTD_H
12745 # include <unistd.h>
12746 #else /* on Windows with MSVC */
12747 # include <io.h>
12748 # include <stdlib.h>
12749 # defined sleep(n) _sleep ((n) * 1000)
12750 #endif
12751 #include <fcntl.h>
12752 GL_MDA_DEFINES
12753 #ifndef O_NOATIME
12754 #define O_NOATIME 0
12755 #endif
12756 #ifndef O_NOFOLLOW
12757 #define O_NOFOLLOW 0
12758 #endif
12759 static int const constants[] =
12760 {
12761 O_CREAT, O_EXCL, O_NOCTTY, O_TRUNC, O_APPEND,
12762 O_NONBLOCK, O_SYNC, O_ACCMODE, O_RDONLY, O_RDWR, O_WRONLY
12763 };
12764
12765int
12766main (void)
12767{
12768
12769 int result = !constants;
12770 #if HAVE_SYMLINK
12771 {
12772 static char const sym[] = "conftest.sym";
12773 if (symlink ("/dev/null", sym) != 0)
12774 result |= 2;
12775 else
12776 {
12777 int fd = open (sym, O_WRONLY | O_NOFOLLOW | O_CREAT, 0);
12778 if (fd >= 0)
12779 {
12780 close (fd);
12781 result |= 4;
12782 }
12783 }
12784 if (unlink (sym) != 0 || symlink (".", sym) != 0)
12785 result |= 2;
12786 else
12787 {
12788 int fd = open (sym, O_RDONLY | O_NOFOLLOW);
12789 if (fd >= 0)
12790 {
12791 close (fd);
12792 result |= 4;
12793 }
12794 }
12795 unlink (sym);
12796 }
12797 #endif
12798 {
12799 static char const file[] = "confdefs.h";
12800 int fd = open (file, O_RDONLY | O_NOATIME);
12801 if (fd < 0)
12802 result |= 8;
12803 else
12804 {
12805 struct stat st0;
12806 if (fstat (fd, &st0) != 0)
12807 result |= 16;
12808 else
12809 {
12810 char c;
12811 sleep (1);
12812 if (read (fd, &c, 1) != 1)
12813 result |= 24;
12814 else
12815 {
12816 if (close (fd) != 0)
12817 result |= 32;
12818 else
12819 {
12820 struct stat st1;
12821 if (stat (file, &st1) != 0)
12822 result |= 40;
12823 else
12824 if (st0.st_atime != st1.st_atime)
12825 result |= 64;
12826 }
12827 }
12828 }
12829 }
12830 }
12831 return result;
12832 ;
12833 return 0;
12834}
12835_ACEOF
12836if ac_fn_c_try_run "$LINENO"
12837then :
12838 gl_cv_header_working_fcntl_h=yes
12839else case e in #(
12840 e) case $? in #(
12841 4) gl_cv_header_working_fcntl_h='no (bad O_NOFOLLOW)';; #(
12842 64) gl_cv_header_working_fcntl_h='no (bad O_NOATIME)';; #(
12843 68) gl_cv_header_working_fcntl_h='no (bad O_NOATIME, O_NOFOLLOW)';; #(
12844 *) gl_cv_header_working_fcntl_h='no';;
12845 esac ;;
12846esac
12847fi
12848rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12849 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12850esac
12851fi
12852
12853 ;;
12854esac
12855fi
12856{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_header_working_fcntl_h" >&5
12857printf "%s\n" "$gl_cv_header_working_fcntl_h" >&6; }
12858
12859 case $gl_cv_header_working_fcntl_h in #(
12860 *O_NOATIME* | no | cross-compiling) ac_val=0;; #(
12861 *) ac_val=1;;
12862 esac
12863
12864printf "%s\n" "#define HAVE_WORKING_O_NOATIME $ac_val" >>confdefs.h
12865
12866
12867 case $gl_cv_header_working_fcntl_h in #(
12868 *O_NOFOLLOW* | no | cross-compiling) ac_val=0;; #(
12869 *) ac_val=1;;
12870 esac
12871
12872printf "%s\n" "#define HAVE_WORKING_O_NOFOLLOW $ac_val" >>confdefs.h
12873
12874
12875
12876 HAVE_NEWLOCALE=1;
12877 HAVE_DUPLOCALE=1;
12878 HAVE_FREELOCALE=1;
12879 REPLACE_LOCALECONV=0;
12880 REPLACE_SETLOCALE=0;
12881 REPLACE_NEWLOCALE=0;
12882 REPLACE_DUPLOCALE=0;
12883 REPLACE_FREELOCALE=0;
12884 REPLACE_STRUCT_LCONV=0;
12885 LOCALENAME_ENHANCE_LOCALE_FUNCS=0;
12886
12887
12888
12889
12890
12891
12892
12893
12894
12895
12896
12897
12898
12899
12900 if test $ac_cv_func_uselocale = yes; then
12901
12902 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether uselocale works" >&5
12903printf %s "checking whether uselocale works... " >&6; }
12904if test ${gt_cv_func_uselocale_works+y}
12905then :
12906 printf %s "(cached) " >&6
12907else case e in #(
12908 e) if test "$cross_compiling" = yes
12909then :
12910 # Guess no on AIX and z/OS, yes otherwise.
12911 case "$host_os" in
12912 aix* | openedition*) gt_cv_func_uselocale_works="guessing no" ;;
12913 *) gt_cv_func_uselocale_works="guessing yes" ;;
12914 esac
12915
12916else case e in #(
12917 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12918/* end confdefs.h. */
12919
12920#include <locale.h>
12921#if HAVE_XLOCALE_H
12922# include <xlocale.h>
12923#endif
12924locale_t loc1;
12925int main ()
12926{
12927 uselocale (NULL);
12928 setlocale (LC_ALL, "en_US.UTF-8");
12929 return 0;
12930}
12931_ACEOF
12932if ac_fn_c_try_run "$LINENO"
12933then :
12934 gt_cv_func_uselocale_works=yes
12935else case e in #(
12936 e) gt_cv_func_uselocale_works=no ;;
12937esac
12938fi
12939rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12940 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
12941esac
12942fi
12943
12944 ;;
12945esac
12946fi
12947{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_uselocale_works" >&5
12948printf "%s\n" "$gt_cv_func_uselocale_works" >&6; }
12949 else
12950 gt_cv_func_uselocale_works=no
12951 fi
12952 case "$gt_cv_func_uselocale_works" in
12953 *yes)
12954 gt_working_uselocale=yes
12955
12956printf "%s\n" "#define HAVE_WORKING_USELOCALE 1" >>confdefs.h
12957
12958 ;;
12959 *)
12960 gt_working_uselocale=no
12961 ;;
12962 esac
12963
12964
12965 case "$gt_cv_func_uselocale_works" in
12966 *yes)
12967
12968 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for fake locale system (OpenBSD)" >&5
12969printf %s "checking for fake locale system (OpenBSD)... " >&6; }
12970if test ${gt_cv_locale_fake+y}
12971then :
12972 printf %s "(cached) " >&6
12973else case e in #(
12974 e) if test "$cross_compiling" = yes
12975then :
12976 case "$host_os" in
12977 openbsd*) gt_cv_locale_fake="guessing yes" ;;
12978 *) gt_cv_locale_fake="guessing no" ;;
12979 esac
12980
12981else case e in #(
12982 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12983/* end confdefs.h. */
12984
12985#include <locale.h>
12986#if HAVE_XLOCALE_H
12987# include <xlocale.h>
12988#endif
12989int main ()
12990{
12991 locale_t loc1, loc2;
12992 if (setlocale (LC_ALL, "de_DE.UTF-8") == NULL) return 1;
12993 if (setlocale (LC_ALL, "fr_FR.UTF-8") == NULL) return 1;
12994 loc1 = newlocale (LC_ALL_MASK, "de_DE.UTF-8", (locale_t)0);
12995 loc2 = newlocale (LC_ALL_MASK, "fr_FR.UTF-8", (locale_t)0);
12996 return !(loc1 == loc2);
12997}
12998_ACEOF
12999if ac_fn_c_try_run "$LINENO"
13000then :
13001 gt_cv_locale_fake=yes
13002else case e in #(
13003 e) gt_cv_locale_fake=no ;;
13004esac
13005fi
13006rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
13007 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
13008esac
13009fi
13010
13011 ;;
13012esac
13013fi
13014{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_fake" >&5
13015printf "%s\n" "$gt_cv_locale_fake" >&6; }
13016 ;;
13017 *) gt_cv_locale_fake=no ;;
13018 esac
13019 case "$gt_cv_locale_fake" in
13020 *yes)
13021 gt_fake_locales=yes
13022
13023printf "%s\n" "#define HAVE_FAKE_LOCALES 1" >>confdefs.h
13024
13025 ;;
13026 *)
13027 gt_fake_locales=no
13028 ;;
13029 esac
13030
13031 case "$gt_cv_func_uselocale_works" in
13032 *yes)
13033 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for Solaris 11.4 locale system" >&5
13034printf %s "checking for Solaris 11.4 locale system... " >&6; }
13035if test ${gt_cv_locale_solaris114+y}
13036then :
13037 printf %s "(cached) " >&6
13038else case e in #(
13039 e) case "$host_os" in
13040 solaris*)
13041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13042/* end confdefs.h. */
13043
13044 #include <locale.h>
13045 struct _LC_locale_t *x;
13046 locale_t y;
13047
13048int
13049main (void)
13050{
13051*y = x;
13052 ;
13053 return 0;
13054}
13055_ACEOF
13056if ac_fn_c_try_compile "$LINENO"
13057then :
13058 gt_cv_locale_solaris114=yes
13059else case e in #(
13060 e) gt_cv_locale_solaris114=no ;;
13061esac
13062fi
13063rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
13064 ;;
13065 *) gt_cv_locale_solaris114=no ;;
13066 esac
13067 ;;
13068esac
13069fi
13070{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_locale_solaris114" >&5
13071printf "%s\n" "$gt_cv_locale_solaris114" >&6; }
13072 ;;
13073 *) gt_cv_locale_solaris114=no ;;
13074 esac
13075 if test $gt_cv_locale_solaris114 = yes; then
13076
13077printf "%s\n" "#define HAVE_SOLARIS114_LOCALES 1" >>confdefs.h
13078
13079 fi
13080
13081 case "$gt_cv_func_uselocale_works" in
13082 *yes)
13083 ac_fn_c_check_func "$LINENO" "getlocalename_l" "ac_cv_func_getlocalename_l"
13084if test "x$ac_cv_func_getlocalename_l" = xyes
13085then :
13086 printf "%s\n" "#define HAVE_GETLOCALENAME_L 1" >>confdefs.h
13087
13088fi
13089
13090 ;;
13091 esac
13092
13093 gt_nameless_locales=no
13094 case "$host_os" in
13095 aix*)
13096 gt_nameless_locales=yes
13097
13098printf "%s\n" "#define HAVE_NAMELESS_LOCALES 1" >>confdefs.h
13099
13100 ;;
13101 esac
13102
13103 if test $gt_working_uselocale = yes && test $gt_fake_locales = no; then
13104 gt_good_uselocale=yes
13105
13106printf "%s\n" "#define HAVE_GOOD_USELOCALE 1" >>confdefs.h
13107
13108 else
13109 gt_good_uselocale=no
13110 fi
13111
13112 if test $gt_good_uselocale = yes && test $gt_nameless_locales = yes; then
13113 gt_localename_enhances_locale_funcs=yes
13114 LOCALENAME_ENHANCE_LOCALE_FUNCS=1
13115
13116printf "%s\n" "#define LOCALENAME_ENHANCE_LOCALE_FUNCS 1" >>confdefs.h
13117
13118 else
13119 gt_localename_enhances_locale_funcs=no
13120 fi
13121
13122
13123 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
13124printf %s "checking for CFPreferencesCopyAppValue... " >&6; }
13125if test ${gt_cv_func_CFPreferencesCopyAppValue+y}
13126then :
13127 printf %s "(cached) " >&6
13128else case e in #(
13129 e) gt_save_LIBS="$LIBS"
13130 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
13131 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13132/* end confdefs.h. */
13133#include <CoreFoundation/CFPreferences.h>
13134int
13135main (void)
13136{
13137CFPreferencesCopyAppValue(NULL, NULL)
13138 ;
13139 return 0;
13140}
13141_ACEOF
13142if ac_fn_c_try_link "$LINENO"
13143then :
13144 gt_cv_func_CFPreferencesCopyAppValue=yes
13145else case e in #(
13146 e) gt_cv_func_CFPreferencesCopyAppValue=no ;;
13147esac
13148fi
13149rm -f core conftest.err conftest.$ac_objext conftest.beam \
13150 conftest$ac_exeext conftest.$ac_ext
13151 LIBS="$gt_save_LIBS" ;;
13152esac
13153fi
13154{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
13155printf "%s\n" "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
13156 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
13157
13158printf "%s\n" "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
13159
13160 fi
13161 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
13162printf %s "checking for CFLocaleCopyPreferredLanguages... " >&6; }
13163if test ${gt_cv_func_CFLocaleCopyPreferredLanguages+y}
13164then :
13165 printf %s "(cached) " >&6
13166else case e in #(
13167 e) gt_save_LIBS="$LIBS"
13168 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
13169 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13170/* end confdefs.h. */
13171#include <CoreFoundation/CFLocale.h>
13172int
13173main (void)
13174{
13175CFLocaleCopyPreferredLanguages();
13176 ;
13177 return 0;
13178}
13179_ACEOF
13180if ac_fn_c_try_link "$LINENO"
13181then :
13182 gt_cv_func_CFLocaleCopyPreferredLanguages=yes
13183else case e in #(
13184 e) gt_cv_func_CFLocaleCopyPreferredLanguages=no ;;
13185esac
13186fi
13187rm -f core conftest.err conftest.$ac_objext conftest.beam \
13188 conftest$ac_exeext conftest.$ac_ext
13189 LIBS="$gt_save_LIBS" ;;
13190esac
13191fi
13192{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
13193printf "%s\n" "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
13194 if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
13195
13196printf "%s\n" "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
13197
13198 fi
13199 INTL_MACOSX_LIBS=
13200 if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
13201 || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
13202 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
13203 fi
13204
13205
13206
13207
13208
13209
13210
13211
13212 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for flexible array member" >&5
13213printf %s "checking for flexible array member... " >&6; }
13214if test ${ac_cv_c_flexmember+y}
13215then :
13216 printf %s "(cached) " >&6
13217else case e in #(
13218 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13219/* end confdefs.h. */
13220#include <stdlib.h>
13221 #include <stdio.h>
13222 #include <stddef.h>
13223 struct m { struct m *next, **list; char name[]; };
13224 struct s { struct s *p; struct m *m; int n; double d[]; };
13225int
13226main (void)
13227{
13228int m = getchar ();
13229 size_t nbytes = offsetof (struct s, d) + m * sizeof (double);
13230 nbytes += sizeof (struct s) - 1;
13231 nbytes -= nbytes % sizeof (struct s);
13232 struct s *p = malloc (nbytes);
13233 p->p = p;
13234 p->m = NULL;
13235 p->d[0] = 0.0;
13236 return p->d != (double *) NULL;
13237 ;
13238 return 0;
13239}
13240_ACEOF
13241if ac_fn_c_try_compile "$LINENO"
13242then :
13243 ac_cv_c_flexmember=yes
13244else case e in #(
13245 e) ac_cv_c_flexmember=no ;;
13246esac
13247fi
13248rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
13249esac
13250fi
13251{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_flexmember" >&5
13252printf "%s\n" "$ac_cv_c_flexmember" >&6; }
13253 if test $ac_cv_c_flexmember = yes; then
13254
13255printf "%s\n" "#define FLEXIBLE_ARRAY_MEMBER /**/" >>confdefs.h
13256
13257 else
13258 printf "%s\n" "#define FLEXIBLE_ARRAY_MEMBER 1" >>confdefs.h
13259
13260 fi
13261
13262
13263
13264
13265
13266
13267
13268
13269
13270
13271
13272 if test -n "$ac_tool_prefix"; then
13273 # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
13274set dummy ${ac_tool_prefix}ar; ac_word=$2
13275{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13276printf %s "checking for $ac_word... " >&6; }
13277if test ${ac_cv_prog_AR+y}
13278then :
13279 printf %s "(cached) " >&6
13280else case e in #(
13281 e) if test -n "$AR"; then
13282 ac_cv_prog_AR="$AR" # Let the user override the test.
13283else
13284as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13285for as_dir in $PATH
13286do
13287 IFS=$as_save_IFS
13288 case $as_dir in #(((
13289 '') as_dir=./ ;;
13290 */) ;;
13291 *) as_dir=$as_dir/ ;;
13292 esac
13293 for ac_exec_ext in '' $ac_executable_extensions; do
13294 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
13295 ac_cv_prog_AR="${ac_tool_prefix}ar"
13296 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
13297 break 2
13298 fi
13299done
13300 done
13301IFS=$as_save_IFS
13302
13303fi ;;
13304esac
13305fi
13306AR=$ac_cv_prog_AR
13307if test -n "$AR"; then
13308 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
13309printf "%s\n" "$AR" >&6; }
13310else
13311 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
13312printf "%s\n" "no" >&6; }
13313fi
13314
13315
13316fi
13317if test -z "$ac_cv_prog_AR"; then
13318 ac_ct_AR=$AR
13319 # Extract the first word of "ar", so it can be a program name with args.
13320set dummy ar; ac_word=$2
13321{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13322printf %s "checking for $ac_word... " >&6; }
13323if test ${ac_cv_prog_ac_ct_AR+y}
13324then :
13325 printf %s "(cached) " >&6
13326else case e in #(
13327 e) if test -n "$ac_ct_AR"; then
13328 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
13329else
13330as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13331for as_dir in $PATH
13332do
13333 IFS=$as_save_IFS
13334 case $as_dir in #(((
13335 '') as_dir=./ ;;
13336 */) ;;
13337 *) as_dir=$as_dir/ ;;
13338 esac
13339 for ac_exec_ext in '' $ac_executable_extensions; do
13340 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
13341 ac_cv_prog_ac_ct_AR="ar"
13342 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
13343 break 2
13344 fi
13345done
13346 done
13347IFS=$as_save_IFS
13348
13349fi ;;
13350esac
13351fi
13352ac_ct_AR=$ac_cv_prog_ac_ct_AR
13353if test -n "$ac_ct_AR"; then
13354 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5
13355printf "%s\n" "$ac_ct_AR" >&6; }
13356else
13357 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
13358printf "%s\n" "no" >&6; }
13359fi
13360
13361 if test "x$ac_ct_AR" = x; then
13362 AR="ar"
13363 else
13364 case $cross_compiling:$ac_tool_warned in
13365yes:)
13366{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
13367printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
13368ac_tool_warned=yes ;;
13369esac
13370 AR=$ac_ct_AR
13371 fi
13372else
13373 AR="$ac_cv_prog_AR"
13374fi
13375
13376 if test -z "$ARFLAGS"; then
13377 ARFLAGS='cr'
13378 fi
13379
13380
13381
13382
13383 case "$enable_silent_rules" in
13384 yes) INTL_DEFAULT_VERBOSITY=0;;
13385 no) INTL_DEFAULT_VERBOSITY=1;;
13386 *) INTL_DEFAULT_VERBOSITY=1;;
13387 esac
13388
13389
13390 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
13391if test "x$ac_cv_type_ptrdiff_t" = xyes
13392then :
13393
13394else case e in #(
13395 e)
13396printf "%s\n" "#define ptrdiff_t long" >>confdefs.h
13397
13398 ;;
13399esac
13400fi
13401
13402 ac_fn_c_check_header_compile "$LINENO" "features.h" "ac_cv_header_features_h" "$ac_includes_default"
13403if test "x$ac_cv_header_features_h" = xyes
13404then :
13405 printf "%s\n" "#define HAVE_FEATURES_H 1" >>confdefs.h
13406
13407fi
13408ac_fn_c_check_header_compile "$LINENO" "stddef.h" "ac_cv_header_stddef_h" "$ac_includes_default"
13409if test "x$ac_cv_header_stddef_h" = xyes
13410then :
13411 printf "%s\n" "#define HAVE_STDDEF_H 1" >>confdefs.h
13412
13413fi
13414ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
13415if test "x$ac_cv_header_stdlib_h" = xyes
13416then :
13417 printf "%s\n" "#define HAVE_STDLIB_H 1" >>confdefs.h
13418
13419fi
13420ac_fn_c_check_header_compile "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default"
13421if test "x$ac_cv_header_string_h" = xyes
13422then :
13423 printf "%s\n" "#define HAVE_STRING_H 1" >>confdefs.h
13424
13425fi
13426
13427 ac_fn_c_check_func "$LINENO" "asprintf" "ac_cv_func_asprintf"
13428if test "x$ac_cv_func_asprintf" = xyes
13429then :
13430 printf "%s\n" "#define HAVE_ASPRINTF 1" >>confdefs.h
13431
13432fi
13433ac_fn_c_check_func "$LINENO" "wprintf" "ac_cv_func_wprintf"
13434if test "x$ac_cv_func_wprintf" = xyes
13435then :
13436 printf "%s\n" "#define HAVE_WPRINTF 1" >>confdefs.h
13437
13438fi
13439ac_fn_c_check_func "$LINENO" "newlocale" "ac_cv_func_newlocale"
13440if test "x$ac_cv_func_newlocale" = xyes
13441then :
13442 printf "%s\n" "#define HAVE_NEWLOCALE 1" >>confdefs.h
13443
13444fi
13445ac_fn_c_check_func "$LINENO" "putenv" "ac_cv_func_putenv"
13446if test "x$ac_cv_func_putenv" = xyes
13447then :
13448 printf "%s\n" "#define HAVE_PUTENV 1" >>confdefs.h
13449
13450fi
13451ac_fn_c_check_func "$LINENO" "setenv" "ac_cv_func_setenv"
13452if test "x$ac_cv_func_setenv" = xyes
13453then :
13454 printf "%s\n" "#define HAVE_SETENV 1" >>confdefs.h
13455
13456fi
13457ac_fn_c_check_func "$LINENO" "snprintf" "ac_cv_func_snprintf"
13458if test "x$ac_cv_func_snprintf" = xyes
13459then :
13460 printf "%s\n" "#define HAVE_SNPRINTF 1" >>confdefs.h
13461
13462fi
13463ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
13464if test "x$ac_cv_func_strnlen" = xyes
13465then :
13466 printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h
13467
13468fi
13469ac_fn_c_check_func "$LINENO" "uselocale" "ac_cv_func_uselocale"
13470if test "x$ac_cv_func_uselocale" = xyes
13471then :
13472 printf "%s\n" "#define HAVE_USELOCALE 1" >>confdefs.h
13473
13474fi
13475ac_fn_c_check_func "$LINENO" "wcslen" "ac_cv_func_wcslen"
13476if test "x$ac_cv_func_wcslen" = xyes
13477then :
13478 printf "%s\n" "#define HAVE_WCSLEN 1" >>confdefs.h
13479
13480fi
13481ac_fn_c_check_func "$LINENO" "wcsnlen" "ac_cv_func_wcsnlen"
13482if test "x$ac_cv_func_wcsnlen" = xyes
13483then :
13484 printf "%s\n" "#define HAVE_WCSNLEN 1" >>confdefs.h
13485
13486fi
13487ac_fn_c_check_func "$LINENO" "mbrtowc" "ac_cv_func_mbrtowc"
13488if test "x$ac_cv_func_mbrtowc" = xyes
13489then :
13490 printf "%s\n" "#define HAVE_MBRTOWC 1" >>confdefs.h
13491
13492fi
13493ac_fn_c_check_func "$LINENO" "wcrtomb" "ac_cv_func_wcrtomb"
13494if test "x$ac_cv_func_wcrtomb" = xyes
13495then :
13496 printf "%s\n" "#define HAVE_WCRTOMB 1" >>confdefs.h
13497
13498fi
13499
13500
13501 ac_fn_check_decl "$LINENO" "_snprintf" "ac_cv_have_decl__snprintf" "#include <stdio.h>
13502" "$ac_c_undeclared_builtin_options" "CFLAGS"
13503if test "x$ac_cv_have_decl__snprintf" = xyes
13504then :
13505 ac_have_decl=1
13506else case e in #(
13507 e) ac_have_decl=0 ;;
13508esac
13509fi
13510printf "%s\n" "#define HAVE_DECL__SNPRINTF $ac_have_decl" >>confdefs.h
13511ac_fn_check_decl "$LINENO" "_snwprintf" "ac_cv_have_decl__snwprintf" "#include <stdio.h>
13512" "$ac_c_undeclared_builtin_options" "CFLAGS"
13513if test "x$ac_cv_have_decl__snwprintf" = xyes
13514then :
13515 ac_have_decl=1
13516else case e in #(
13517 e) ac_have_decl=0 ;;
13518esac
13519fi
13520printf "%s\n" "#define HAVE_DECL__SNWPRINTF $ac_have_decl" >>confdefs.h
13521
13522
13523 ac_fn_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "#include <stdio.h>
13524" "$ac_c_undeclared_builtin_options" "CFLAGS"
13525if test "x$ac_cv_have_decl_getc_unlocked" = xyes
13526then :
13527 ac_have_decl=1
13528else case e in #(
13529 e) ac_have_decl=0 ;;
13530esac
13531fi
13532printf "%s\n" "#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl" >>confdefs.h
13533
13534
13535 case $gt_cv_func_printf_posix in
13536 *yes) HAVE_POSIX_PRINTF=1 ;;
13537 *) HAVE_POSIX_PRINTF=0 ;;
13538 esac
13539
13540 if test "$ac_cv_func_asprintf" = yes; then
13541 HAVE_ASPRINTF=1
13542 else
13543 HAVE_ASPRINTF=0
13544 fi
13545
13546 if test "$ac_cv_func_snprintf" = yes; then
13547 HAVE_SNPRINTF=1
13548 else
13549 HAVE_SNPRINTF=0
13550 fi
13551
13552 if test "$ac_cv_func_newlocale" = yes; then
13553 HAVE_NEWLOCALE=1
13554 else
13555 HAVE_NEWLOCALE=0
13556 fi
13557
13558 if test "$ac_cv_func_wprintf" = yes; then
13559 HAVE_WPRINTF=1
13560 else
13561 HAVE_WPRINTF=0
13562 fi
13563
13564
13565
13566 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5
13567printf %s "checking for nl_langinfo and CODESET... " >&6; }
13568if test ${am_cv_langinfo_codeset+y}
13569then :
13570 printf %s "(cached) " >&6
13571else case e in #(
13572 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13573/* end confdefs.h. */
13574#include <langinfo.h>
13575int
13576main (void)
13577{
13578char* cs = nl_langinfo(CODESET); return !cs;
13579 ;
13580 return 0;
13581}
13582_ACEOF
13583if ac_fn_c_try_link "$LINENO"
13584then :
13585 am_cv_langinfo_codeset=yes
13586else case e in #(
13587 e) am_cv_langinfo_codeset=no ;;
13588esac
13589fi
13590rm -f core conftest.err conftest.$ac_objext conftest.beam \
13591 conftest$ac_exeext conftest.$ac_ext
13592 ;;
13593esac
13594fi
13595{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5
13596printf "%s\n" "$am_cv_langinfo_codeset" >&6; }
13597 if test $am_cv_langinfo_codeset = yes; then
13598 printf "%s\n" "#define HAVE_NL_LANGINFO 1" >>confdefs.h
13599
13600
13601printf "%s\n" "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h
13602
13603 fi
13604
13605
13606 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5
13607printf %s "checking for LC_MESSAGES... " >&6; }
13608if test ${gt_cv_val_LC_MESSAGES+y}
13609then :
13610 printf %s "(cached) " >&6
13611else case e in #(
13612 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13613/* end confdefs.h. */
13614#include <locale.h>
13615int
13616main (void)
13617{
13618return LC_MESSAGES
13619 ;
13620 return 0;
13621}
13622_ACEOF
13623if ac_fn_c_try_link "$LINENO"
13624then :
13625 gt_cv_val_LC_MESSAGES=yes
13626else case e in #(
13627 e) gt_cv_val_LC_MESSAGES=no ;;
13628esac
13629fi
13630rm -f core conftest.err conftest.$ac_objext conftest.beam \
13631 conftest$ac_exeext conftest.$ac_ext ;;
13632esac
13633fi
13634{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_val_LC_MESSAGES" >&5
13635printf "%s\n" "$gt_cv_val_LC_MESSAGES" >&6; }
13636 if test $gt_cv_val_LC_MESSAGES = yes; then
13637
13638printf "%s\n" "#define HAVE_LC_MESSAGES 1" >>confdefs.h
13639
13640 fi
13641
13642
13643 if test $gt_localename_enhances_locale_funcs = yes; then
13644 ENHANCE_LOCALE_FUNCS=1
13645 else
13646 ENHANCE_LOCALE_FUNCS=0
13647 fi
13648
13649
13650 if test "$enable_shared" = yes; then
13651 case "$host_os" in
13652 mingw* | cygwin*) is_woe32dll=yes ;;
13653 *) is_woe32dll=no ;;
13654 esac
13655 else
13656 is_woe32dll=no
13657 fi
13658 WOE32DLL=$is_woe32dll
13659
13660
13661 case "$host_os" in
13662 mingw* | cygwin*) is_woe32=yes ;;
13663 *) is_woe32=no ;;
13664 esac
13665 WOE32=$is_woe32
13666
13667 if test $WOE32 = yes; then
13668 if test -n "$ac_tool_prefix"; then
13669 # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
13670set dummy ${ac_tool_prefix}windres; ac_word=$2
13671{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13672printf %s "checking for $ac_word... " >&6; }
13673if test ${ac_cv_prog_WINDRES+y}
13674then :
13675 printf %s "(cached) " >&6
13676else case e in #(
13677 e) if test -n "$WINDRES"; then
13678 ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
13679else
13680as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13681for as_dir in $PATH
13682do
13683 IFS=$as_save_IFS
13684 case $as_dir in #(((
13685 '') as_dir=./ ;;
13686 */) ;;
13687 *) as_dir=$as_dir/ ;;
13688 esac
13689 for ac_exec_ext in '' $ac_executable_extensions; do
13690 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
13691 ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
13692 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
13693 break 2
13694 fi
13695done
13696 done
13697IFS=$as_save_IFS
13698
13699fi ;;
13700esac
13701fi
13702WINDRES=$ac_cv_prog_WINDRES
13703if test -n "$WINDRES"; then
13704 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $WINDRES" >&5
13705printf "%s\n" "$WINDRES" >&6; }
13706else
13707 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
13708printf "%s\n" "no" >&6; }
13709fi
13710
13711
13712fi
13713if test -z "$ac_cv_prog_WINDRES"; then
13714 ac_ct_WINDRES=$WINDRES
13715 # Extract the first word of "windres", so it can be a program name with args.
13716set dummy windres; ac_word=$2
13717{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
13718printf %s "checking for $ac_word... " >&6; }
13719if test ${ac_cv_prog_ac_ct_WINDRES+y}
13720then :
13721 printf %s "(cached) " >&6
13722else case e in #(
13723 e) if test -n "$ac_ct_WINDRES"; then
13724 ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
13725else
13726as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
13727for as_dir in $PATH
13728do
13729 IFS=$as_save_IFS
13730 case $as_dir in #(((
13731 '') as_dir=./ ;;
13732 */) ;;
13733 *) as_dir=$as_dir/ ;;
13734 esac
13735 for ac_exec_ext in '' $ac_executable_extensions; do
13736 if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
13737 ac_cv_prog_ac_ct_WINDRES="windres"
13738 printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
13739 break 2
13740 fi
13741done
13742 done
13743IFS=$as_save_IFS
13744
13745fi ;;
13746esac
13747fi
13748ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
13749if test -n "$ac_ct_WINDRES"; then
13750 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_ct_WINDRES" >&5
13751printf "%s\n" "$ac_ct_WINDRES" >&6; }
13752else
13753 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
13754printf "%s\n" "no" >&6; }
13755fi
13756
13757 if test "x$ac_ct_WINDRES" = x; then
13758 WINDRES=""
13759 else
13760 case $cross_compiling:$ac_tool_warned in
13761yes:)
13762{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
13763printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
13764ac_tool_warned=yes ;;
13765esac
13766 WINDRES=$ac_ct_WINDRES
13767 fi
13768else
13769 WINDRES="$ac_cv_prog_WINDRES"
13770fi
13771
13772 fi
13773
13774
13775
13776
13777
13778
13779
13780
13781
13782
13783
13784
13785
13786
13787
13788
13789
13790
13791
13792
13793
13794
13795
13796
13797
13798 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFPreferencesCopyAppValue" >&5
13799printf %s "checking for CFPreferencesCopyAppValue... " >&6; }
13800if test ${gt_cv_func_CFPreferencesCopyAppValue+y}
13801then :
13802 printf %s "(cached) " >&6
13803else case e in #(
13804 e) gt_save_LIBS="$LIBS"
13805 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
13806 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13807/* end confdefs.h. */
13808#include <CoreFoundation/CFPreferences.h>
13809int
13810main (void)
13811{
13812CFPreferencesCopyAppValue(NULL, NULL)
13813 ;
13814 return 0;
13815}
13816_ACEOF
13817if ac_fn_c_try_link "$LINENO"
13818then :
13819 gt_cv_func_CFPreferencesCopyAppValue=yes
13820else case e in #(
13821 e) gt_cv_func_CFPreferencesCopyAppValue=no ;;
13822esac
13823fi
13824rm -f core conftest.err conftest.$ac_objext conftest.beam \
13825 conftest$ac_exeext conftest.$ac_ext
13826 LIBS="$gt_save_LIBS" ;;
13827esac
13828fi
13829{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFPreferencesCopyAppValue" >&5
13830printf "%s\n" "$gt_cv_func_CFPreferencesCopyAppValue" >&6; }
13831 if test $gt_cv_func_CFPreferencesCopyAppValue = yes; then
13832
13833printf "%s\n" "#define HAVE_CFPREFERENCESCOPYAPPVALUE 1" >>confdefs.h
13834
13835 fi
13836 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for CFLocaleCopyPreferredLanguages" >&5
13837printf %s "checking for CFLocaleCopyPreferredLanguages... " >&6; }
13838if test ${gt_cv_func_CFLocaleCopyPreferredLanguages+y}
13839then :
13840 printf %s "(cached) " >&6
13841else case e in #(
13842 e) gt_save_LIBS="$LIBS"
13843 LIBS="$LIBS -Wl,-framework -Wl,CoreFoundation"
13844 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13845/* end confdefs.h. */
13846#include <CoreFoundation/CFLocale.h>
13847int
13848main (void)
13849{
13850CFLocaleCopyPreferredLanguages();
13851 ;
13852 return 0;
13853}
13854_ACEOF
13855if ac_fn_c_try_link "$LINENO"
13856then :
13857 gt_cv_func_CFLocaleCopyPreferredLanguages=yes
13858else case e in #(
13859 e) gt_cv_func_CFLocaleCopyPreferredLanguages=no ;;
13860esac
13861fi
13862rm -f core conftest.err conftest.$ac_objext conftest.beam \
13863 conftest$ac_exeext conftest.$ac_ext
13864 LIBS="$gt_save_LIBS" ;;
13865esac
13866fi
13867{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_CFLocaleCopyPreferredLanguages" >&5
13868printf "%s\n" "$gt_cv_func_CFLocaleCopyPreferredLanguages" >&6; }
13869 if test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
13870
13871printf "%s\n" "#define HAVE_CFLOCALECOPYPREFERREDLANGUAGES 1" >>confdefs.h
13872
13873 fi
13874 INTL_MACOSX_LIBS=
13875 if test $gt_cv_func_CFPreferencesCopyAppValue = yes \
13876 || test $gt_cv_func_CFLocaleCopyPreferredLanguages = yes; then
13877 INTL_MACOSX_LIBS="-Wl,-framework -Wl,CoreFoundation"
13878 fi
13879
13880
13881
13882
13883
13884
13885 BUILD_INCLUDED_LIBINTL=no
13886 USE_INCLUDED_LIBINTL=no
13887
13888 LIBINTL=
13889 LTLIBINTL=
13890 POSUB=
13891
13892 case " $gt_needs " in
13893 *" need-formatstring-macros "*) gt_api_version=3 ;;
13894 *" need-ngettext "*) gt_api_version=2 ;;
13895 *) gt_api_version=1 ;;
13896 esac
13897 gt_func_gnugettext_libc="gt_cv_func_gnugettext${gt_api_version}_libc"
13898 gt_func_gnugettext_libintl="gt_cv_func_gnugettext${gt_api_version}_libintl"
13899
13900 if test "$USE_NLS" = "yes"; then
13901 gt_use_preinstalled_gnugettext=no
13902
13903 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether included gettext is requested" >&5
13904printf %s "checking whether included gettext is requested... " >&6; }
13905
13906# Check whether --with-included-gettext was given.
13907if test ${with_included_gettext+y}
13908then :
13909 withval=$with_included_gettext; nls_cv_force_use_gnu_gettext=$withval
13910else case e in #(
13911 e) nls_cv_force_use_gnu_gettext=no ;;
13912esac
13913fi
13914
13915 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $nls_cv_force_use_gnu_gettext" >&5
13916printf "%s\n" "$nls_cv_force_use_gnu_gettext" >&6; }
13917
13918 nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
13919 if test "$nls_cv_force_use_gnu_gettext" != "yes"; then
13920
13921
13922 if test $gt_api_version -ge 3; then
13923 gt_revision_test_code='
13924#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
13925#define __GNU_GETTEXT_SUPPORTED_REVISION(major) ((major) == 0 ? 0 : -1)
13926#endif
13927typedef int array [2 * (__GNU_GETTEXT_SUPPORTED_REVISION(0) >= 1) - 1];
13928'
13929 else
13930 gt_revision_test_code=
13931 fi
13932 if test $gt_api_version -ge 2; then
13933 gt_expression_test_code=' + * ngettext ("", "", 0)'
13934 else
13935 gt_expression_test_code=
13936 fi
13937
13938 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5
13939printf %s "checking for GNU gettext in libc... " >&6; }
13940if eval test \${$gt_func_gnugettext_libc+y}
13941then :
13942 printf %s "(cached) " >&6
13943else case e in #(
13944 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13945/* end confdefs.h. */
13946
13947#include <libintl.h>
13948#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
13949extern int _nl_msg_cat_cntr;
13950extern int *_nl_domain_bindings;
13951#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_domain_bindings)
13952#else
13953#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
13954#endif
13955$gt_revision_test_code
13956
13957int
13958main (void)
13959{
13960
13961bindtextdomain ("", "");
13962return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
13963
13964 ;
13965 return 0;
13966}
13967_ACEOF
13968if ac_fn_c_try_link "$LINENO"
13969then :
13970 eval "$gt_func_gnugettext_libc=yes"
13971else case e in #(
13972 e) eval "$gt_func_gnugettext_libc=no" ;;
13973esac
13974fi
13975rm -f core conftest.err conftest.$ac_objext conftest.beam \
13976 conftest$ac_exeext conftest.$ac_ext ;;
13977esac
13978fi
13979eval ac_res=\$$gt_func_gnugettext_libc
13980 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
13981printf "%s\n" "$ac_res" >&6; }
13982
13983 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" != "yes"; }; then
13984
13985
13986
13987
13988
13989
13990
13991 use_additional=yes
13992
13993 acl_save_prefix="$prefix"
13994 prefix="$acl_final_prefix"
13995 acl_save_exec_prefix="$exec_prefix"
13996 exec_prefix="$acl_final_exec_prefix"
13997
13998 eval additional_includedir=\"$includedir\"
13999 eval additional_libdir=\"$libdir\"
14000 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
14001 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
14002
14003 exec_prefix="$acl_save_exec_prefix"
14004 prefix="$acl_save_prefix"
14005
14006
14007# Check whether --with-libintl-prefix was given.
14008if test ${with_libintl_prefix+y}
14009then :
14010 withval=$with_libintl_prefix;
14011 if test "X$withval" = "Xno"; then
14012 use_additional=no
14013 else
14014 if test "X$withval" = "X"; then
14015
14016 acl_save_prefix="$prefix"
14017 prefix="$acl_final_prefix"
14018 acl_save_exec_prefix="$exec_prefix"
14019 exec_prefix="$acl_final_exec_prefix"
14020
14021 eval additional_includedir=\"$includedir\"
14022 eval additional_libdir=\"$libdir\"
14023 eval additional_libdir2=\"$exec_prefix/$acl_libdirstem2\"
14024 eval additional_libdir3=\"$exec_prefix/$acl_libdirstem3\"
14025
14026 exec_prefix="$acl_save_exec_prefix"
14027 prefix="$acl_save_prefix"
14028
14029 else
14030 additional_includedir="$withval/include"
14031 additional_libdir="$withval/$acl_libdirstem"
14032 additional_libdir2="$withval/$acl_libdirstem2"
14033 additional_libdir3="$withval/$acl_libdirstem3"
14034 fi
14035 fi
14036
14037fi
14038
14039 if test "X$additional_libdir2" = "X$additional_libdir"; then
14040 additional_libdir2=
14041 fi
14042 if test "X$additional_libdir3" = "X$additional_libdir"; then
14043 additional_libdir3=
14044 fi
14045 LIBINTL=
14046 LTLIBINTL=
14047 INCINTL=
14048 LIBINTL_PREFIX=
14049 HAVE_LIBINTL=
14050 rpathdirs=
14051 ltrpathdirs=
14052 names_already_handled=
14053 names_next_round='intl '
14054 while test -n "$names_next_round"; do
14055 names_this_round="$names_next_round"
14056 names_next_round=
14057 for name in $names_this_round; do
14058 already_handled=
14059 for n in $names_already_handled; do
14060 if test "$n" = "$name"; then
14061 already_handled=yes
14062 break
14063 fi
14064 done
14065 if test -z "$already_handled"; then
14066 names_already_handled="$names_already_handled $name"
14067 uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./+-|ABCDEFGHIJKLMNOPQRSTUVWXYZ____|'`
14068 eval value=\"\$HAVE_LIB$uppername\"
14069 if test -n "$value"; then
14070 if test "$value" = yes; then
14071 eval value=\"\$LIB$uppername\"
14072 test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value"
14073 eval value=\"\$LTLIB$uppername\"
14074 test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value"
14075 else
14076 :
14077 fi
14078 else
14079 found_dir=
14080 found_la=
14081 found_so=
14082 found_a=
14083 eval libname=\"$acl_libname_spec\" # typically: libname=lib$name
14084 if test -n "$acl_shlibext"; then
14085 shrext=".$acl_shlibext" # typically: shrext=.so
14086 else
14087 shrext=
14088 fi
14089 if test $use_additional = yes; then
14090 for additional_libdir_variable in additional_libdir additional_libdir2 additional_libdir3; do
14091 if test "X$found_dir" = "X"; then
14092 eval dir=\$$additional_libdir_variable
14093 if test -n "$dir"; then
14094 if test -n "$acl_shlibext"; then
14095 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
14096 found_dir="$dir"
14097 found_so="$dir/$libname$shrext"
14098 else
14099 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
14100 ver=`(cd "$dir" && \
14101 for f in "$libname$shrext".*; do echo "$f"; done \
14102 | sed -e "s,^$libname$shrext\\\\.,," \
14103 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
14104 | sed 1q ) 2>/dev/null`
14105 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
14106 found_dir="$dir"
14107 found_so="$dir/$libname$shrext.$ver"
14108 fi
14109 else
14110 eval library_names=\"$acl_library_names_spec\"
14111 for f in $library_names; do
14112 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
14113 found_dir="$dir"
14114 found_so="$dir/$f"
14115 break
14116 fi
14117 done
14118 fi
14119 fi
14120 fi
14121 if test "X$found_dir" = "X"; then
14122 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
14123 found_dir="$dir"
14124 found_a="$dir/$libname.$acl_libext"
14125 fi
14126 fi
14127 if test "X$found_dir" != "X"; then
14128 if test -f "$dir/$libname.la"; then
14129 found_la="$dir/$libname.la"
14130 fi
14131 fi
14132 fi
14133 fi
14134 done
14135 fi
14136 if test "X$found_dir" = "X"; then
14137 for x in $LDFLAGS $LTLIBINTL; do
14138
14139 acl_save_prefix="$prefix"
14140 prefix="$acl_final_prefix"
14141 acl_save_exec_prefix="$exec_prefix"
14142 exec_prefix="$acl_final_exec_prefix"
14143 eval x=\"$x\"
14144 exec_prefix="$acl_save_exec_prefix"
14145 prefix="$acl_save_prefix"
14146
14147 case "$x" in
14148 -L*)
14149 dir=`echo "X$x" | sed -e 's/^X-L//'`
14150 if test -n "$acl_shlibext"; then
14151 if test -f "$dir/$libname$shrext" && acl_is_expected_elfclass < "$dir/$libname$shrext"; then
14152 found_dir="$dir"
14153 found_so="$dir/$libname$shrext"
14154 else
14155 if test "$acl_library_names_spec" = '$libname$shrext$versuffix'; then
14156 ver=`(cd "$dir" && \
14157 for f in "$libname$shrext".*; do echo "$f"; done \
14158 | sed -e "s,^$libname$shrext\\\\.,," \
14159 | sort -t '.' -n -r -k1,1 -k2,2 -k3,3 -k4,4 -k5,5 \
14160 | sed 1q ) 2>/dev/null`
14161 if test -n "$ver" && test -f "$dir/$libname$shrext.$ver" && acl_is_expected_elfclass < "$dir/$libname$shrext.$ver"; then
14162 found_dir="$dir"
14163 found_so="$dir/$libname$shrext.$ver"
14164 fi
14165 else
14166 eval library_names=\"$acl_library_names_spec\"
14167 for f in $library_names; do
14168 if test -f "$dir/$f" && acl_is_expected_elfclass < "$dir/$f"; then
14169 found_dir="$dir"
14170 found_so="$dir/$f"
14171 break
14172 fi
14173 done
14174 fi
14175 fi
14176 fi
14177 if test "X$found_dir" = "X"; then
14178 if test -f "$dir/$libname.$acl_libext" && ${AR-ar} -p "$dir/$libname.$acl_libext" | acl_is_expected_elfclass; then
14179 found_dir="$dir"
14180 found_a="$dir/$libname.$acl_libext"
14181 fi
14182 fi
14183 if test "X$found_dir" != "X"; then
14184 if test -f "$dir/$libname.la"; then
14185 found_la="$dir/$libname.la"
14186 fi
14187 fi
14188 ;;
14189 esac
14190 if test "X$found_dir" != "X"; then
14191 break
14192 fi
14193 done
14194 fi
14195 if test "X$found_dir" != "X"; then
14196 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name"
14197 if test "X$found_so" != "X"; then
14198 if test "$enable_rpath" = no \
14199 || test "X$found_dir" = "X/usr/$acl_libdirstem" \
14200 || test "X$found_dir" = "X/usr/$acl_libdirstem2" \
14201 || test "X$found_dir" = "X/usr/$acl_libdirstem3"; then
14202 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
14203 else
14204 haveit=
14205 for x in $ltrpathdirs; do
14206 if test "X$x" = "X$found_dir"; then
14207 haveit=yes
14208 break
14209 fi
14210 done
14211 if test -z "$haveit"; then
14212 ltrpathdirs="$ltrpathdirs $found_dir"
14213 fi
14214 if test "$acl_hardcode_direct" = yes; then
14215 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
14216 else
14217 if test -n "$acl_hardcode_libdir_flag_spec" && test "$acl_hardcode_minus_L" = no; then
14218 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
14219 haveit=
14220 for x in $rpathdirs; do
14221 if test "X$x" = "X$found_dir"; then
14222 haveit=yes
14223 break
14224 fi
14225 done
14226 if test -z "$haveit"; then
14227 rpathdirs="$rpathdirs $found_dir"
14228 fi
14229 else
14230 haveit=
14231 for x in $LDFLAGS $LIBINTL; do
14232
14233 acl_save_prefix="$prefix"
14234 prefix="$acl_final_prefix"
14235 acl_save_exec_prefix="$exec_prefix"
14236 exec_prefix="$acl_final_exec_prefix"
14237 eval x=\"$x\"
14238 exec_prefix="$acl_save_exec_prefix"
14239 prefix="$acl_save_prefix"
14240
14241 if test "X$x" = "X-L$found_dir"; then
14242 haveit=yes
14243 break
14244 fi
14245 done
14246 if test -z "$haveit"; then
14247 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir"
14248 fi
14249 if test "$acl_hardcode_minus_L" != no; then
14250 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so"
14251 else
14252 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
14253 fi
14254 fi
14255 fi
14256 fi
14257 else
14258 if test "X$found_a" != "X"; then
14259 LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a"
14260 else
14261 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name"
14262 fi
14263 fi
14264 additional_includedir=
14265 case "$found_dir" in
14266 */$acl_libdirstem | */$acl_libdirstem/)
14267 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem/"'*$,,'`
14268 if test "$name" = 'intl'; then
14269 LIBINTL_PREFIX="$basedir"
14270 fi
14271 additional_includedir="$basedir/include"
14272 ;;
14273 */$acl_libdirstem2 | */$acl_libdirstem2/)
14274 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem2/"'*$,,'`
14275 if test "$name" = 'intl'; then
14276 LIBINTL_PREFIX="$basedir"
14277 fi
14278 additional_includedir="$basedir/include"
14279 ;;
14280 */$acl_libdirstem3 | */$acl_libdirstem3/)
14281 basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e "s,/$acl_libdirstem3/"'*$,,'`
14282 if test "$name" = 'intl'; then
14283 LIBINTL_PREFIX="$basedir"
14284 fi
14285 additional_includedir="$basedir/include"
14286 ;;
14287 esac
14288 if test "X$additional_includedir" != "X"; then
14289 if test "X$additional_includedir" != "X/usr/include"; then
14290 haveit=
14291 if test "X$additional_includedir" = "X/usr/local/include"; then
14292 if test -n "$GCC"; then
14293 case $host_os in
14294 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
14295 esac
14296 fi
14297 fi
14298 if test -z "$haveit"; then
14299 for x in $CPPFLAGS $INCINTL; do
14300
14301 acl_save_prefix="$prefix"
14302 prefix="$acl_final_prefix"
14303 acl_save_exec_prefix="$exec_prefix"
14304 exec_prefix="$acl_final_exec_prefix"
14305 eval x=\"$x\"
14306 exec_prefix="$acl_save_exec_prefix"
14307 prefix="$acl_save_prefix"
14308
14309 if test "X$x" = "X-I$additional_includedir"; then
14310 haveit=yes
14311 break
14312 fi
14313 done
14314 if test -z "$haveit"; then
14315 if test -d "$additional_includedir"; then
14316 INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir"
14317 fi
14318 fi
14319 fi
14320 fi
14321 fi
14322 if test -n "$found_la"; then
14323 save_libdir="$libdir"
14324 case "$found_la" in
14325 */* | *\\*) . "$found_la" ;;
14326 *) . "./$found_la" ;;
14327 esac
14328 libdir="$save_libdir"
14329 for dep in $dependency_libs; do
14330 case "$dep" in
14331 -L*)
14332 dependency_libdir=`echo "X$dep" | sed -e 's/^X-L//'`
14333 if test "X$dependency_libdir" != "X/usr/$acl_libdirstem" \
14334 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem2" \
14335 && test "X$dependency_libdir" != "X/usr/$acl_libdirstem3"; then
14336 haveit=
14337 if test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem" \
14338 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem2" \
14339 || test "X$dependency_libdir" = "X/usr/local/$acl_libdirstem3"; then
14340 if test -n "$GCC"; then
14341 case $host_os in
14342 linux* | gnu* | k*bsd*-gnu) haveit=yes;;
14343 esac
14344 fi
14345 fi
14346 if test -z "$haveit"; then
14347 haveit=
14348 for x in $LDFLAGS $LIBINTL; do
14349
14350 acl_save_prefix="$prefix"
14351 prefix="$acl_final_prefix"
14352 acl_save_exec_prefix="$exec_prefix"
14353 exec_prefix="$acl_final_exec_prefix"
14354 eval x=\"$x\"
14355 exec_prefix="$acl_save_exec_prefix"
14356 prefix="$acl_save_prefix"
14357
14358 if test "X$x" = "X-L$dependency_libdir"; then
14359 haveit=yes
14360 break
14361 fi
14362 done
14363 if test -z "$haveit"; then
14364 if test -d "$dependency_libdir"; then
14365 LIBINTL="${LIBINTL}${LIBINTL:+ }-L$dependency_libdir"
14366 fi
14367 fi
14368 haveit=
14369 for x in $LDFLAGS $LTLIBINTL; do
14370
14371 acl_save_prefix="$prefix"
14372 prefix="$acl_final_prefix"
14373 acl_save_exec_prefix="$exec_prefix"
14374 exec_prefix="$acl_final_exec_prefix"
14375 eval x=\"$x\"
14376 exec_prefix="$acl_save_exec_prefix"
14377 prefix="$acl_save_prefix"
14378
14379 if test "X$x" = "X-L$dependency_libdir"; then
14380 haveit=yes
14381 break
14382 fi
14383 done
14384 if test -z "$haveit"; then
14385 if test -d "$dependency_libdir"; then
14386 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$dependency_libdir"
14387 fi
14388 fi
14389 fi
14390 fi
14391 ;;
14392 -R*)
14393 dir=`echo "X$dep" | sed -e 's/^X-R//'`
14394 if test "$enable_rpath" != no; then
14395 haveit=
14396 for x in $rpathdirs; do
14397 if test "X$x" = "X$dir"; then
14398 haveit=yes
14399 break
14400 fi
14401 done
14402 if test -z "$haveit"; then
14403 rpathdirs="$rpathdirs $dir"
14404 fi
14405 haveit=
14406 for x in $ltrpathdirs; do
14407 if test "X$x" = "X$dir"; then
14408 haveit=yes
14409 break
14410 fi
14411 done
14412 if test -z "$haveit"; then
14413 ltrpathdirs="$ltrpathdirs $dir"
14414 fi
14415 fi
14416 ;;
14417 -l*)
14418 dep=`echo "X$dep" | sed -e 's/^X-l//'`
14419 if test "X$dep" != Xc \
14420 || case $host_os in
14421 linux* | gnu* | k*bsd*-gnu) false ;;
14422 *) true ;;
14423 esac; then
14424 names_next_round="$names_next_round $dep"
14425 fi
14426 ;;
14427 *.la)
14428 names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'`
14429 ;;
14430 *)
14431 LIBINTL="${LIBINTL}${LIBINTL:+ }$dep"
14432 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep"
14433 ;;
14434 esac
14435 done
14436 fi
14437 else
14438 LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name"
14439 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name"
14440 fi
14441 fi
14442 fi
14443 done
14444 done
14445 if test "X$rpathdirs" != "X"; then
14446 if test -n "$acl_hardcode_libdir_separator"; then
14447 alldirs=
14448 for found_dir in $rpathdirs; do
14449 alldirs="${alldirs}${alldirs:+$acl_hardcode_libdir_separator}$found_dir"
14450 done
14451 acl_save_libdir="$libdir"
14452 libdir="$alldirs"
14453 eval flag=\"$acl_hardcode_libdir_flag_spec\"
14454 libdir="$acl_save_libdir"
14455 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
14456 else
14457 for found_dir in $rpathdirs; do
14458 acl_save_libdir="$libdir"
14459 libdir="$found_dir"
14460 eval flag=\"$acl_hardcode_libdir_flag_spec\"
14461 libdir="$acl_save_libdir"
14462 LIBINTL="${LIBINTL}${LIBINTL:+ }$flag"
14463 done
14464 fi
14465 fi
14466 if test "X$ltrpathdirs" != "X"; then
14467 for found_dir in $ltrpathdirs; do
14468 LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir"
14469 done
14470 fi
14471
14472
14473
14474
14475
14476 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5
14477printf %s "checking for GNU gettext in libintl... " >&6; }
14478if eval test \${$gt_func_gnugettext_libintl+y}
14479then :
14480 printf %s "(cached) " >&6
14481else case e in #(
14482 e) gt_save_CPPFLAGS="$CPPFLAGS"
14483 CPPFLAGS="$CPPFLAGS $INCINTL"
14484 gt_save_LIBS="$LIBS"
14485 LIBS="$LIBS $LIBINTL"
14486 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14487/* end confdefs.h. */
14488
14489#include <libintl.h>
14490#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
14491extern int _nl_msg_cat_cntr;
14492extern
14493#ifdef __cplusplus
14494"C"
14495#endif
14496const char *_nl_expand_alias (const char *);
14497#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
14498#else
14499#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
14500#endif
14501$gt_revision_test_code
14502
14503int
14504main (void)
14505{
14506
14507bindtextdomain ("", "");
14508return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
14509
14510 ;
14511 return 0;
14512}
14513_ACEOF
14514if ac_fn_c_try_link "$LINENO"
14515then :
14516 eval "$gt_func_gnugettext_libintl=yes"
14517else case e in #(
14518 e) eval "$gt_func_gnugettext_libintl=no" ;;
14519esac
14520fi
14521rm -f core conftest.err conftest.$ac_objext conftest.beam \
14522 conftest$ac_exeext conftest.$ac_ext
14523 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" != yes; } && test -n "$LIBICONV"; then
14524 LIBS="$LIBS $LIBICONV"
14525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14526/* end confdefs.h. */
14527
14528#include <libintl.h>
14529#ifndef __GNU_GETTEXT_SUPPORTED_REVISION
14530extern int _nl_msg_cat_cntr;
14531extern
14532#ifdef __cplusplus
14533"C"
14534#endif
14535const char *_nl_expand_alias (const char *);
14536#define __GNU_GETTEXT_SYMBOL_EXPRESSION (_nl_msg_cat_cntr + *_nl_expand_alias (""))
14537#else
14538#define __GNU_GETTEXT_SYMBOL_EXPRESSION 0
14539#endif
14540$gt_revision_test_code
14541
14542int
14543main (void)
14544{
14545
14546bindtextdomain ("", "");
14547return * gettext ("")$gt_expression_test_code + __GNU_GETTEXT_SYMBOL_EXPRESSION
14548
14549 ;
14550 return 0;
14551}
14552_ACEOF
14553if ac_fn_c_try_link "$LINENO"
14554then :
14555 LIBINTL="$LIBINTL $LIBICONV"
14556 LTLIBINTL="$LTLIBINTL $LTLIBICONV"
14557 eval "$gt_func_gnugettext_libintl=yes"
14558
14559fi
14560rm -f core conftest.err conftest.$ac_objext conftest.beam \
14561 conftest$ac_exeext conftest.$ac_ext
14562 fi
14563 CPPFLAGS="$gt_save_CPPFLAGS"
14564 LIBS="$gt_save_LIBS" ;;
14565esac
14566fi
14567eval ac_res=\$$gt_func_gnugettext_libintl
14568 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14569printf "%s\n" "$ac_res" >&6; }
14570 fi
14571
14572 if { eval "gt_val=\$$gt_func_gnugettext_libc"; test "$gt_val" = "yes"; } \
14573 || { { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; } \
14574 && test "$PACKAGE" != gettext-runtime \
14575 && test "$PACKAGE" != gettext-tools; }; then
14576 gt_use_preinstalled_gnugettext=yes
14577 else
14578 LIBINTL=
14579 LTLIBINTL=
14580 INCINTL=
14581 fi
14582
14583
14584 if test "$gt_use_preinstalled_gnugettext" != "yes"; then
14585 nls_cv_use_gnu_gettext=yes
14586 fi
14587 fi
14588
14589 if test "$nls_cv_use_gnu_gettext" = "yes"; then
14590 BUILD_INCLUDED_LIBINTL=yes
14591 USE_INCLUDED_LIBINTL=yes
14592# LIBINTL="m4_if([lib/intl],[],\${top_builddir}/intl,[lib/intl])/libintl.la $LIBICONV $LIBTHREAD"
14593 # we don't build with libtool
14594 LIBINTL="lib/intl/libintl.a $LIBICONV $LIBTHREAD"
14595 LTLIBINTL="lib/intl/libintl.la $LTLIBICONV $LTLIBTHREAD"
14596 LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'`
14597 fi
14598
14599 CATOBJEXT=
14600 if test "$gt_use_preinstalled_gnugettext" = "yes" \
14601 || test "$nls_cv_use_gnu_gettext" = "yes"; then
14602 CATOBJEXT=.gmo
14603 fi
14604
14605
14606 if test -n "$INTL_MACOSX_LIBS"; then
14607 if test "$gt_use_preinstalled_gnugettext" = "yes" \
14608 || test "$nls_cv_use_gnu_gettext" = "yes"; then
14609 LIBINTL="$LIBINTL $INTL_MACOSX_LIBS"
14610 LTLIBINTL="$LTLIBINTL $INTL_MACOSX_LIBS"
14611 fi
14612 fi
14613
14614 if test "$gt_use_preinstalled_gnugettext" = "yes" \
14615 || test "$nls_cv_use_gnu_gettext" = "yes"; then
14616
14617printf "%s\n" "#define ENABLE_NLS 1" >>confdefs.h
14618
14619 else
14620 USE_NLS=no
14621 fi
14622 fi
14623
14624 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5
14625printf %s "checking whether to use NLS... " >&6; }
14626 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5
14627printf "%s\n" "$USE_NLS" >&6; }
14628 if test "$USE_NLS" = "yes"; then
14629 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5
14630printf %s "checking where the gettext function comes from... " >&6; }
14631 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
14632 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
14633 gt_source="external libintl"
14634 else
14635 gt_source="libc"
14636 fi
14637 else
14638 gt_source="included intl directory"
14639 fi
14640 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5
14641printf "%s\n" "$gt_source" >&6; }
14642 fi
14643
14644 if test "$USE_NLS" = "yes"; then
14645
14646 if test "$gt_use_preinstalled_gnugettext" = "yes"; then
14647 if { eval "gt_val=\$$gt_func_gnugettext_libintl"; test "$gt_val" = "yes"; }; then
14648 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5
14649printf %s "checking how to link with libintl... " >&6; }
14650 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5
14651printf "%s\n" "$LIBINTL" >&6; }
14652
14653 for element in $INCINTL; do
14654 haveit=
14655 for x in $CPPFLAGS; do
14656
14657 acl_save_prefix="$prefix"
14658 prefix="$acl_final_prefix"
14659 acl_save_exec_prefix="$exec_prefix"
14660 exec_prefix="$acl_final_exec_prefix"
14661 eval x=\"$x\"
14662 exec_prefix="$acl_save_exec_prefix"
14663 prefix="$acl_save_prefix"
14664
14665 if test "X$x" = "X$element"; then
14666 haveit=yes
14667 break
14668 fi
14669 done
14670 if test -z "$haveit"; then
14671 CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element"
14672 fi
14673 done
14674
14675 fi
14676
14677
14678printf "%s\n" "#define HAVE_GETTEXT 1" >>confdefs.h
14679
14680
14681printf "%s\n" "#define HAVE_DCGETTEXT 1" >>confdefs.h
14682
14683 fi
14684
14685 POSUB=po
14686 fi
14687
14688
14689 BUILD_INCLUDED_LIBINTL=yes
14690
14691
14692
14693
14694
14695
14696 INTLLIBS="$LIBINTL"
14697
14698
14699
14700
14701
14702
14703
14704ac_header_dirent=no
14705for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
14706 as_ac_Header=`printf "%s\n" "ac_cv_header_dirent_$ac_hdr" | sed "$as_sed_sh"`
14707{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5
14708printf %s "checking for $ac_hdr that defines DIR... " >&6; }
14709if eval test \${$as_ac_Header+y}
14710then :
14711 printf %s "(cached) " >&6
14712else case e in #(
14713 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14714/* end confdefs.h. */
14715#include <sys/types.h>
14716#include <$ac_hdr>
14717
14718int
14719main (void)
14720{
14721if ((DIR *) 0)
14722return 0;
14723 ;
14724 return 0;
14725}
14726_ACEOF
14727if ac_fn_c_try_compile "$LINENO"
14728then :
14729 eval "$as_ac_Header=yes"
14730else case e in #(
14731 e) eval "$as_ac_Header=no" ;;
14732esac
14733fi
14734rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
14735esac
14736fi
14737eval ac_res=\$$as_ac_Header
14738 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
14739printf "%s\n" "$ac_res" >&6; }
14740if eval test \"x\$"$as_ac_Header"\" = x"yes"
14741then :
14742 cat >>confdefs.h <<_ACEOF
14743#define `printf "%s\n" "HAVE_$ac_hdr" | sed "$as_sed_cpp"` 1
14744_ACEOF
14745
14746ac_header_dirent=$ac_hdr; break
14747fi
14748
14749done
14750# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
14751if test $ac_header_dirent = dirent.h; then
14752 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
14753printf %s "checking for library containing opendir... " >&6; }
14754if test ${ac_cv_search_opendir+y}
14755then :
14756 printf %s "(cached) " >&6
14757else case e in #(
14758 e) ac_func_search_save_LIBS=$LIBS
14759cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14760/* end confdefs.h. */
14761
14762/* Override any GCC internal prototype to avoid an error.
14763 Use char because int might match the return type of a GCC
14764 builtin and then its argument prototype would still apply.
14765 The 'extern "C"' is for builds by C++ compilers;
14766 although this is not generally supported in C code supporting it here
14767 has little cost and some practical benefit (sr 110532). */
14768#ifdef __cplusplus
14769extern "C"
14770#endif
14771char opendir (void);
14772int
14773main (void)
14774{
14775return opendir ();
14776 ;
14777 return 0;
14778}
14779_ACEOF
14780for ac_lib in '' dir
14781do
14782 if test -z "$ac_lib"; then
14783 ac_res="none required"
14784 else
14785 ac_res=-l$ac_lib
14786 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
14787 fi
14788 if ac_fn_c_try_link "$LINENO"
14789then :
14790 ac_cv_search_opendir=$ac_res
14791fi
14792rm -f core conftest.err conftest.$ac_objext conftest.beam \
14793 conftest$ac_exeext
14794 if test ${ac_cv_search_opendir+y}
14795then :
14796 break
14797fi
14798done
14799if test ${ac_cv_search_opendir+y}
14800then :
14801
14802else case e in #(
14803 e) ac_cv_search_opendir=no ;;
14804esac
14805fi
14806rm conftest.$ac_ext
14807LIBS=$ac_func_search_save_LIBS ;;
14808esac
14809fi
14810{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
14811printf "%s\n" "$ac_cv_search_opendir" >&6; }
14812ac_res=$ac_cv_search_opendir
14813if test "$ac_res" != no
14814then :
14815 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14816
14817fi
14818
14819else
14820 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5
14821printf %s "checking for library containing opendir... " >&6; }
14822if test ${ac_cv_search_opendir+y}
14823then :
14824 printf %s "(cached) " >&6
14825else case e in #(
14826 e) ac_func_search_save_LIBS=$LIBS
14827cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14828/* end confdefs.h. */
14829
14830/* Override any GCC internal prototype to avoid an error.
14831 Use char because int might match the return type of a GCC
14832 builtin and then its argument prototype would still apply.
14833 The 'extern "C"' is for builds by C++ compilers;
14834 although this is not generally supported in C code supporting it here
14835 has little cost and some practical benefit (sr 110532). */
14836#ifdef __cplusplus
14837extern "C"
14838#endif
14839char opendir (void);
14840int
14841main (void)
14842{
14843return opendir ();
14844 ;
14845 return 0;
14846}
14847_ACEOF
14848for ac_lib in '' x
14849do
14850 if test -z "$ac_lib"; then
14851 ac_res="none required"
14852 else
14853 ac_res=-l$ac_lib
14854 LIBS="-l$ac_lib $ac_func_search_save_LIBS"
14855 fi
14856 if ac_fn_c_try_link "$LINENO"
14857then :
14858 ac_cv_search_opendir=$ac_res
14859fi
14860rm -f core conftest.err conftest.$ac_objext conftest.beam \
14861 conftest$ac_exeext
14862 if test ${ac_cv_search_opendir+y}
14863then :
14864 break
14865fi
14866done
14867if test ${ac_cv_search_opendir+y}
14868then :
14869
14870else case e in #(
14871 e) ac_cv_search_opendir=no ;;
14872esac
14873fi
14874rm conftest.$ac_ext
14875LIBS=$ac_func_search_save_LIBS ;;
14876esac
14877fi
14878{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5
14879printf "%s\n" "$ac_cv_search_opendir" >&6; }
14880ac_res=$ac_cv_search_opendir
14881if test "$ac_res" != no
14882then :
14883 test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14884
14885fi
14886
14887fi
14888
14889
14890ac_fn_c_check_header_compile "$LINENO" "sys/mkdev.h" "ac_cv_header_sys_mkdev_h" "$ac_includes_default"
14891if test "x$ac_cv_header_sys_mkdev_h" = xyes
14892then :
14893
14894printf "%s\n" "#define MAJOR_IN_MKDEV 1" >>confdefs.h
14895
14896fi
14897
14898if test $ac_cv_header_sys_mkdev_h = no; then
14899 ac_fn_c_check_header_compile "$LINENO" "sys/sysmacros.h" "ac_cv_header_sys_sysmacros_h" "$ac_includes_default"
14900if test "x$ac_cv_header_sys_sysmacros_h" = xyes
14901then :
14902
14903printf "%s\n" "#define MAJOR_IN_SYSMACROS 1" >>confdefs.h
14904
14905fi
14906
14907fi
14908
14909
14910
14911 ac_fn_c_check_header_compile "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default"
14912if test "x$ac_cv_header_inttypes_h" = xyes
14913then :
14914 printf "%s\n" "#define HAVE_INTTYPES_H 1" >>confdefs.h
14915
14916fi
14917
14918
14919
14920ac_fn_c_check_header_compile "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default"
14921if test "x$ac_cv_header_unistd_h" = xyes
14922then :
14923 printf "%s\n" "#define HAVE_UNISTD_H 1" >>confdefs.h
14924
14925fi
14926ac_fn_c_check_header_compile "$LINENO" "stdlib.h" "ac_cv_header_stdlib_h" "$ac_includes_default"
14927if test "x$ac_cv_header_stdlib_h" = xyes
14928then :
14929 printf "%s\n" "#define HAVE_STDLIB_H 1" >>confdefs.h
14930
14931fi
14932ac_fn_c_check_header_compile "$LINENO" "varargs.h" "ac_cv_header_varargs_h" "$ac_includes_default"
14933if test "x$ac_cv_header_varargs_h" = xyes
14934then :
14935 printf "%s\n" "#define HAVE_VARARGS_H 1" >>confdefs.h
14936
14937fi
14938ac_fn_c_check_header_compile "$LINENO" "limits.h" "ac_cv_header_limits_h" "$ac_includes_default"
14939if test "x$ac_cv_header_limits_h" = xyes
14940then :
14941 printf "%s\n" "#define HAVE_LIMITS_H 1" >>confdefs.h
14942
14943fi
14944ac_fn_c_check_header_compile "$LINENO" "string.h" "ac_cv_header_string_h" "$ac_includes_default"
14945if test "x$ac_cv_header_string_h" = xyes
14946then :
14947 printf "%s\n" "#define HAVE_STRING_H 1" >>confdefs.h
14948
14949fi
14950ac_fn_c_check_header_compile "$LINENO" "memory.h" "ac_cv_header_memory_h" "$ac_includes_default"
14951if test "x$ac_cv_header_memory_h" = xyes
14952then :
14953 printf "%s\n" "#define HAVE_MEMORY_H 1" >>confdefs.h
14954
14955fi
14956ac_fn_c_check_header_compile "$LINENO" "locale.h" "ac_cv_header_locale_h" "$ac_includes_default"
14957if test "x$ac_cv_header_locale_h" = xyes
14958then :
14959 printf "%s\n" "#define HAVE_LOCALE_H 1" >>confdefs.h
14960
14961fi
14962ac_fn_c_check_header_compile "$LINENO" "termcap.h" "ac_cv_header_termcap_h" "$ac_includes_default"
14963if test "x$ac_cv_header_termcap_h" = xyes
14964then :
14965 printf "%s\n" "#define HAVE_TERMCAP_H 1" >>confdefs.h
14966
14967fi
14968ac_fn_c_check_header_compile "$LINENO" "termio.h" "ac_cv_header_termio_h" "$ac_includes_default"
14969if test "x$ac_cv_header_termio_h" = xyes
14970then :
14971 printf "%s\n" "#define HAVE_TERMIO_H 1" >>confdefs.h
14972
14973fi
14974ac_fn_c_check_header_compile "$LINENO" "termios.h" "ac_cv_header_termios_h" "$ac_includes_default"
14975if test "x$ac_cv_header_termios_h" = xyes
14976then :
14977 printf "%s\n" "#define HAVE_TERMIOS_H 1" >>confdefs.h
14978
14979fi
14980ac_fn_c_check_header_compile "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" "$ac_includes_default"
14981if test "x$ac_cv_header_dlfcn_h" = xyes
14982then :
14983 printf "%s\n" "#define HAVE_DLFCN_H 1" >>confdefs.h
14984
14985fi
14986ac_fn_c_check_header_compile "$LINENO" "stddef.h" "ac_cv_header_stddef_h" "$ac_includes_default"
14987if test "x$ac_cv_header_stddef_h" = xyes
14988then :
14989 printf "%s\n" "#define HAVE_STDDEF_H 1" >>confdefs.h
14990
14991fi
14992ac_fn_c_check_header_compile "$LINENO" "stdint.h" "ac_cv_header_stdint_h" "$ac_includes_default"
14993if test "x$ac_cv_header_stdint_h" = xyes
14994then :
14995 printf "%s\n" "#define HAVE_STDINT_H 1" >>confdefs.h
14996
14997fi
14998ac_fn_c_check_header_compile "$LINENO" "netdb.h" "ac_cv_header_netdb_h" "$ac_includes_default"
14999if test "x$ac_cv_header_netdb_h" = xyes
15000then :
15001 printf "%s\n" "#define HAVE_NETDB_H 1" >>confdefs.h
15002
15003fi
15004ac_fn_c_check_header_compile "$LINENO" "pwd.h" "ac_cv_header_pwd_h" "$ac_includes_default"
15005if test "x$ac_cv_header_pwd_h" = xyes
15006then :
15007 printf "%s\n" "#define HAVE_PWD_H 1" >>confdefs.h
15008
15009fi
15010ac_fn_c_check_header_compile "$LINENO" "grp.h" "ac_cv_header_grp_h" "$ac_includes_default"
15011if test "x$ac_cv_header_grp_h" = xyes
15012then :
15013 printf "%s\n" "#define HAVE_GRP_H 1" >>confdefs.h
15014
15015fi
15016ac_fn_c_check_header_compile "$LINENO" "strings.h" "ac_cv_header_strings_h" "$ac_includes_default"
15017if test "x$ac_cv_header_strings_h" = xyes
15018then :
15019 printf "%s\n" "#define HAVE_STRINGS_H 1" >>confdefs.h
15020
15021fi
15022ac_fn_c_check_header_compile "$LINENO" "stdckdint.h" "ac_cv_header_stdckdint_h" "$ac_includes_default"
15023if test "x$ac_cv_header_stdckdint_h" = xyes
15024then :
15025 printf "%s\n" "#define HAVE_STDCKDINT_H 1" >>confdefs.h
15026
15027fi
15028ac_fn_c_check_header_compile "$LINENO" "regex.h" "ac_cv_header_regex_h" "$ac_includes_default"
15029if test "x$ac_cv_header_regex_h" = xyes
15030then :
15031 printf "%s\n" "#define HAVE_REGEX_H 1" >>confdefs.h
15032
15033fi
15034ac_fn_c_check_header_compile "$LINENO" "syslog.h" "ac_cv_header_syslog_h" "$ac_includes_default"
15035if test "x$ac_cv_header_syslog_h" = xyes
15036then :
15037 printf "%s\n" "#define HAVE_SYSLOG_H 1" >>confdefs.h
15038
15039fi
15040ac_fn_c_check_header_compile "$LINENO" "ulimit.h" "ac_cv_header_ulimit_h" "$ac_includes_default"
15041if test "x$ac_cv_header_ulimit_h" = xyes
15042then :
15043 printf "%s\n" "#define HAVE_ULIMIT_H 1" >>confdefs.h
15044
15045fi
15046
15047ac_fn_c_check_header_compile "$LINENO" "sys/pte.h" "ac_cv_header_sys_pte_h" "$ac_includes_default"
15048if test "x$ac_cv_header_sys_pte_h" = xyes
15049then :
15050 printf "%s\n" "#define HAVE_SYS_PTE_H 1" >>confdefs.h
15051
15052fi
15053ac_fn_c_check_header_compile "$LINENO" "sys/stream.h" "ac_cv_header_sys_stream_h" "$ac_includes_default"
15054if test "x$ac_cv_header_sys_stream_h" = xyes
15055then :
15056 printf "%s\n" "#define HAVE_SYS_STREAM_H 1" >>confdefs.h
15057
15058fi
15059ac_fn_c_check_header_compile "$LINENO" "sys/select.h" "ac_cv_header_sys_select_h" "$ac_includes_default"
15060if test "x$ac_cv_header_sys_select_h" = xyes
15061then :
15062 printf "%s\n" "#define HAVE_SYS_SELECT_H 1" >>confdefs.h
15063
15064fi
15065ac_fn_c_check_header_compile "$LINENO" "sys/file.h" "ac_cv_header_sys_file_h" "$ac_includes_default"
15066if test "x$ac_cv_header_sys_file_h" = xyes
15067then :
15068 printf "%s\n" "#define HAVE_SYS_FILE_H 1" >>confdefs.h
15069
15070fi
15071ac_fn_c_check_header_compile "$LINENO" "sys/ioctl.h" "ac_cv_header_sys_ioctl_h" "$ac_includes_default"
15072if test "x$ac_cv_header_sys_ioctl_h" = xyes
15073then :
15074 printf "%s\n" "#define HAVE_SYS_IOCTL_H 1" >>confdefs.h
15075
15076fi
15077ac_fn_c_check_header_compile "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" "$ac_includes_default"
15078if test "x$ac_cv_header_sys_mman_h" = xyes
15079then :
15080 printf "%s\n" "#define HAVE_SYS_MMAN_H 1" >>confdefs.h
15081
15082fi
15083ac_fn_c_check_header_compile "$LINENO" "sys/param.h" "ac_cv_header_sys_param_h" "$ac_includes_default"
15084if test "x$ac_cv_header_sys_param_h" = xyes
15085then :
15086 printf "%s\n" "#define HAVE_SYS_PARAM_H 1" >>confdefs.h
15087
15088fi
15089ac_fn_c_check_header_compile "$LINENO" "sys/random.h" "ac_cv_header_sys_random_h" "$ac_includes_default"
15090if test "x$ac_cv_header_sys_random_h" = xyes
15091then :
15092 printf "%s\n" "#define HAVE_SYS_RANDOM_H 1" >>confdefs.h
15093
15094fi
15095ac_fn_c_check_header_compile "$LINENO" "sys/socket.h" "ac_cv_header_sys_socket_h" "$ac_includes_default"
15096if test "x$ac_cv_header_sys_socket_h" = xyes
15097then :
15098 printf "%s\n" "#define HAVE_SYS_SOCKET_H 1" >>confdefs.h
15099
15100fi
15101ac_fn_c_check_header_compile "$LINENO" "sys/stat.h" "ac_cv_header_sys_stat_h" "$ac_includes_default"
15102if test "x$ac_cv_header_sys_stat_h" = xyes
15103then :
15104 printf "%s\n" "#define HAVE_SYS_STAT_H 1" >>confdefs.h
15105
15106fi
15107ac_fn_c_check_header_compile "$LINENO" "sys/time.h" "ac_cv_header_sys_time_h" "$ac_includes_default"
15108if test "x$ac_cv_header_sys_time_h" = xyes
15109then :
15110 printf "%s\n" "#define HAVE_SYS_TIME_H 1" >>confdefs.h
15111
15112fi
15113ac_fn_c_check_header_compile "$LINENO" "sys/times.h" "ac_cv_header_sys_times_h" "$ac_includes_default"
15114if test "x$ac_cv_header_sys_times_h" = xyes
15115then :
15116 printf "%s\n" "#define HAVE_SYS_TIMES_H 1" >>confdefs.h
15117
15118fi
15119ac_fn_c_check_header_compile "$LINENO" "sys/types.h" "ac_cv_header_sys_types_h" "$ac_includes_default"
15120if test "x$ac_cv_header_sys_types_h" = xyes
15121then :
15122 printf "%s\n" "#define HAVE_SYS_TYPES_H 1" >>confdefs.h
15123
15124fi
15125ac_fn_c_check_header_compile "$LINENO" "sys/wait.h" "ac_cv_header_sys_wait_h" "$ac_includes_default"
15126if test "x$ac_cv_header_sys_wait_h" = xyes
15127then :
15128 printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
15129
15130fi
15131
15132ac_fn_c_check_header_compile "$LINENO" "netinet/in.h" "ac_cv_header_netinet_in_h" "$ac_includes_default"
15133if test "x$ac_cv_header_netinet_in_h" = xyes
15134then :
15135 printf "%s\n" "#define HAVE_NETINET_IN_H 1" >>confdefs.h
15136
15137fi
15138ac_fn_c_check_header_compile "$LINENO" "arpa/inet.h" "ac_cv_header_arpa_inet_h" "$ac_includes_default"
15139if test "x$ac_cv_header_arpa_inet_h" = xyes
15140then :
15141 printf "%s\n" "#define HAVE_ARPA_INET_H 1" >>confdefs.h
15142
15143fi
15144
15145
15146ac_fn_c_check_header_compile "$LINENO" "sys/ptem.h" "ac_cv_header_sys_ptem_h" "
15147#if HAVE_SYS_STREAM_H
15148# include <sys/stream.h>
15149#endif
15150
15151"
15152if test "x$ac_cv_header_sys_ptem_h" = xyes
15153then :
15154
15155fi
15156
15157
15158ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" "
15159#if HAVE_SYS_TIME_H
15160# include <sys/time.h>
15161#endif
15162
15163"
15164if test "x$ac_cv_header_sys_resource_h" = xyes
15165then :
15166 printf "%s\n" "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h
15167
15168fi
15169
15170
15171# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
15172# for constant arguments. Useless!
15173{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5
15174printf %s "checking for working alloca.h... " >&6; }
15175if test ${ac_cv_working_alloca_h+y}
15176then :
15177 printf %s "(cached) " >&6
15178else case e in #(
15179 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15180/* end confdefs.h. */
15181#include <alloca.h>
15182int
15183main (void)
15184{
15185char *p = (char *) alloca (2 * sizeof (int));
15186 if (p) return 0;
15187 ;
15188 return 0;
15189}
15190_ACEOF
15191if ac_fn_c_try_link "$LINENO"
15192then :
15193 ac_cv_working_alloca_h=yes
15194else case e in #(
15195 e) ac_cv_working_alloca_h=no ;;
15196esac
15197fi
15198rm -f core conftest.err conftest.$ac_objext conftest.beam \
15199 conftest$ac_exeext conftest.$ac_ext ;;
15200esac
15201fi
15202{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5
15203printf "%s\n" "$ac_cv_working_alloca_h" >&6; }
15204if test $ac_cv_working_alloca_h = yes; then
15205
15206printf "%s\n" "#define HAVE_ALLOCA_H 1" >>confdefs.h
15207
15208fi
15209
15210{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5
15211printf %s "checking for alloca... " >&6; }
15212if test ${ac_cv_func_alloca_works+y}
15213then :
15214 printf %s "(cached) " >&6
15215else case e in #(
15216 e) ac_cv_func_alloca_works=$ac_cv_working_alloca_h
15217if test "$ac_cv_func_alloca_works" != yes
15218then :
15219 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15220/* end confdefs.h. */
15221#include <stdlib.h>
15222#include <stddef.h>
15223#ifndef alloca
15224# ifdef __GNUC__
15225# define alloca __builtin_alloca
15226# elif defined _MSC_VER
15227# include <malloc.h>
15228# define alloca _alloca
15229# else
15230# ifdef __cplusplus
15231extern "C"
15232# endif
15233void *alloca (size_t);
15234# endif
15235#endif
15236
15237int
15238main (void)
15239{
15240char *p = (char *) alloca (1);
15241 if (p) return 0;
15242 ;
15243 return 0;
15244}
15245_ACEOF
15246if ac_fn_c_try_link "$LINENO"
15247then :
15248 ac_cv_func_alloca_works=yes
15249fi
15250rm -f core conftest.err conftest.$ac_objext conftest.beam \
15251 conftest$ac_exeext conftest.$ac_ext
15252fi ;;
15253esac
15254fi
15255{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5
15256printf "%s\n" "$ac_cv_func_alloca_works" >&6; }
15257
15258if test $ac_cv_func_alloca_works = yes; then
15259
15260printf "%s\n" "#define HAVE_ALLOCA 1" >>confdefs.h
15261
15262else
15263 # The SVR3 libPW and SVR4 libucb both contain incompatible functions
15264# that cause trouble. Some versions do not even contain alloca or
15265# contain a buggy version. If you still want to use their alloca,
15266# use ar to extract alloca.o from them instead of compiling alloca.c.
15267
15268ALLOCA=\${LIBOBJDIR}alloca.$ac_objext
15269
15270printf "%s\n" "#define C_ALLOCA 1" >>confdefs.h
15271
15272
15273{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5
15274printf %s "checking stack direction for C alloca... " >&6; }
15275if test ${ac_cv_c_stack_direction+y}
15276then :
15277 printf %s "(cached) " >&6
15278else case e in #(
15279 e) if test "$cross_compiling" = yes
15280then :
15281 ac_cv_c_stack_direction=0
15282else case e in #(
15283 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15284/* end confdefs.h. */
15285$ac_includes_default
15286int
15287find_stack_direction (int *addr, int depth)
15288{
15289 int dir, dummy = 0;
15290 if (! addr)
15291 addr = &dummy;
15292 *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1;
15293 dir = depth ? find_stack_direction (addr, depth - 1) : 0;
15294 return dir + dummy;
15295}
15296
15297int
15298main (int argc, char **argv)
15299{
15300 return find_stack_direction (0, argc + !argv + 20) < 0;
15301}
15302_ACEOF
15303if ac_fn_c_try_run "$LINENO"
15304then :
15305 ac_cv_c_stack_direction=1
15306else case e in #(
15307 e) ac_cv_c_stack_direction=-1 ;;
15308esac
15309fi
15310rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15311 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
15312esac
15313fi
15314 ;;
15315esac
15316fi
15317{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5
15318printf "%s\n" "$ac_cv_c_stack_direction" >&6; }
15319printf "%s\n" "#define STACK_DIRECTION $ac_cv_c_stack_direction" >>confdefs.h
15320
15321
15322fi
15323
15324ac_fn_c_check_type "$LINENO" "uid_t" "ac_cv_type_uid_t" "$ac_includes_default"
15325if test "x$ac_cv_type_uid_t" = xyes
15326then :
15327
15328else case e in #(
15329 e)
15330printf "%s\n" "#define uid_t int" >>confdefs.h
15331 ;;
15332esac
15333fi
15334
15335ac_fn_c_check_type "$LINENO" "gid_t" "ac_cv_type_gid_t" "$ac_includes_default"
15336if test "x$ac_cv_type_gid_t" = xyes
15337then :
15338
15339else case e in #(
15340 e)
15341printf "%s\n" "#define gid_t int" >>confdefs.h
15342 ;;
15343esac
15344fi
15345
15346{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5
15347printf %s "checking for working chown... " >&6; }
15348if test ${ac_cv_func_chown_works+y}
15349then :
15350 printf %s "(cached) " >&6
15351else case e in #(
15352 e) if test "$cross_compiling" = yes
15353then :
15354 case "$host_os" in # ((
15355 # Guess yes on glibc systems.
15356 *-gnu*) ac_cv_func_chown_works=yes ;;
15357 # If we don't know, assume the worst.
15358 *) ac_cv_func_chown_works=no ;;
15359 esac
15360else case e in #(
15361 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15362/* end confdefs.h. */
15363$ac_includes_default
15364#include <fcntl.h>
15365
15366int
15367main (void)
15368{
15369 char *f = "conftest.chown";
15370 struct stat before, after;
15371
15372 if (creat (f, 0600) < 0)
15373 return 1;
15374 if (stat (f, &before) < 0)
15375 return 1;
15376 if (chown (f, (uid_t) -1, (gid_t) -1) == -1)
15377 return 1;
15378 if (stat (f, &after) < 0)
15379 return 1;
15380 return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid);
15381
15382 ;
15383 return 0;
15384}
15385_ACEOF
15386if ac_fn_c_try_run "$LINENO"
15387then :
15388 ac_cv_func_chown_works=yes
15389else case e in #(
15390 e) ac_cv_func_chown_works=no ;;
15391esac
15392fi
15393rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15394 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
15395esac
15396fi
15397
15398rm -f conftest.chown
15399 ;;
15400esac
15401fi
15402{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5
15403printf "%s\n" "$ac_cv_func_chown_works" >&6; }
15404if test $ac_cv_func_chown_works = yes; then
15405
15406printf "%s\n" "#define HAVE_CHOWN 1" >>confdefs.h
15407
15408fi
15409
15410{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
15411printf %s "checking whether getpgrp requires zero arguments... " >&6; }
15412if test ${ac_cv_func_getpgrp_void+y}
15413then :
15414 printf %s "(cached) " >&6
15415else case e in #(
15416 e) # Use it with a single arg.
15417cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15418/* end confdefs.h. */
15419$ac_includes_default
15420int
15421main (void)
15422{
15423getpgrp (0);
15424 ;
15425 return 0;
15426}
15427_ACEOF
15428if ac_fn_c_try_compile "$LINENO"
15429then :
15430 ac_cv_func_getpgrp_void=no
15431else case e in #(
15432 e) ac_cv_func_getpgrp_void=yes ;;
15433esac
15434fi
15435rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
15436 ;;
15437esac
15438fi
15439{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
15440printf "%s\n" "$ac_cv_func_getpgrp_void" >&6; }
15441if test $ac_cv_func_getpgrp_void = yes; then
15442
15443printf "%s\n" "#define GETPGRP_VOID 1" >>confdefs.h
15444
15445fi
15446
15447
15448
15449if test "x$ac_cv_func_vprintf" = xno
15450then :
15451 ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt"
15452if test "x$ac_cv_func__doprnt" = xyes
15453then :
15454
15455printf "%s\n" "#define HAVE_DOPRNT 1" >>confdefs.h
15456
15457fi
15458
15459fi
15460{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5
15461printf %s "checking for working strcoll... " >&6; }
15462if test ${ac_cv_func_strcoll_works+y}
15463then :
15464 printf %s "(cached) " >&6
15465else case e in #(
15466 e) if test "$cross_compiling" = yes
15467then :
15468 case "$host_os" in # ((
15469 # Guess yes on glibc systems.
15470 *-gnu*) ac_cv_func_strcoll_works=yes ;;
15471 # If we don't know, assume the worst.
15472 *) ac_cv_func_strcoll_works=no ;;
15473 esac
15474else case e in #(
15475 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15476/* end confdefs.h. */
15477$ac_includes_default
15478int
15479main (void)
15480{
15481return (strcoll ("abc", "def") >= 0 ||
15482 strcoll ("ABC", "DEF") >= 0 ||
15483 strcoll ("123", "456") >= 0)
15484 ;
15485 return 0;
15486}
15487_ACEOF
15488if ac_fn_c_try_run "$LINENO"
15489then :
15490 ac_cv_func_strcoll_works=yes
15491else case e in #(
15492 e) ac_cv_func_strcoll_works=no ;;
15493esac
15494fi
15495rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15496 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
15497esac
15498fi
15499 ;;
15500esac
15501fi
15502{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5
15503printf "%s\n" "$ac_cv_func_strcoll_works" >&6; }
15504if test $ac_cv_func_strcoll_works = yes; then
15505
15506printf "%s\n" "#define HAVE_STRCOLL 1" >>confdefs.h
15507
15508fi
15509
15510
15511
15512if test "$ac_cv_func_alloca_works" = "no" && test "$opt_bash_malloc" = "no"; then
15513 MALLOC_TARGET=alloca
15514 MALLOC_SRC=alloca.c
15515
15516 MALLOC_LIB='-lmalloc'
15517 MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a'
15518 MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)'
15519 MALLOC_DEP='$(MALLOC_LIBRARY)'
15520fi
15521
15522if test "$ac_cv_func_vprintf" = no; then
15523 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for declaration of vprintf in stdio.h" >&5
15524printf %s "checking for declaration of vprintf in stdio.h... " >&6; }
15525 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15526/* end confdefs.h. */
15527#include <stdio.h>
15528
15529_ACEOF
15530if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
15531 $EGREP_TRADITIONAL "[int[ ]*vprintf[^a-zA-Z0-9]]" >/dev/null 2>&1
15532then :
15533 ac_cv_func_vprintf=yes
15534fi
15535rm -rf conftest*
15536
15537 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vprintf" >&5
15538printf "%s\n" "$ac_cv_func_vprintf" >&6; }
15539 if test $ac_cv_func_vprintf = yes; then
15540 printf "%s\n" "#define HAVE_VPRINTF 1" >>confdefs.h
15541
15542 fi
15543fi
15544
15545if test "$ac_cv_func_vprintf" = no && test "$ac_cv_func__doprnt" = "yes"; then
15546 case " $LIBOBJS " in
15547 *" vprint.$ac_objext "* ) ;;
15548 *) LIBOBJS="$LIBOBJS vprint.$ac_objext"
15549 ;;
15550esac
15551
15552fi
15553
15554ac_fn_c_check_func "$LINENO" "__setostype" "ac_cv_func___setostype"
15555if test "x$ac_cv_func___setostype" = xyes
15556then :
15557 printf "%s\n" "#define HAVE_SETOSTYPE 1" >>confdefs.h
15558
15559fi
15560
15561ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3"
15562if test "x$ac_cv_func_wait3" = xyes
15563then :
15564 printf "%s\n" "#define HAVE_WAIT3 1" >>confdefs.h
15565
15566fi
15567
15568
15569ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo"
15570if test "x$ac_cv_func_mkfifo" = xyes
15571then :
15572 printf "%s\n" "#define HAVE_MKFIFO 1" >>confdefs.h
15573
15574else case e in #(
15575 e) printf "%s\n" "#define MKFIFO_MISSING 1" >>confdefs.h
15576 ;;
15577esac
15578fi
15579
15580
15581ac_fn_c_check_func "$LINENO" "dup2" "ac_cv_func_dup2"
15582if test "x$ac_cv_func_dup2" = xyes
15583then :
15584 printf "%s\n" "#define HAVE_DUP2 1" >>confdefs.h
15585
15586fi
15587ac_fn_c_check_func "$LINENO" "eaccess" "ac_cv_func_eaccess"
15588if test "x$ac_cv_func_eaccess" = xyes
15589then :
15590 printf "%s\n" "#define HAVE_EACCESS 1" >>confdefs.h
15591
15592fi
15593ac_fn_c_check_func "$LINENO" "fcntl" "ac_cv_func_fcntl"
15594if test "x$ac_cv_func_fcntl" = xyes
15595then :
15596 printf "%s\n" "#define HAVE_FCNTL 1" >>confdefs.h
15597
15598fi
15599ac_fn_c_check_func "$LINENO" "getdtablesize" "ac_cv_func_getdtablesize"
15600if test "x$ac_cv_func_getdtablesize" = xyes
15601then :
15602 printf "%s\n" "#define HAVE_GETDTABLESIZE 1" >>confdefs.h
15603
15604fi
15605ac_fn_c_check_func "$LINENO" "getentropy" "ac_cv_func_getentropy"
15606if test "x$ac_cv_func_getentropy" = xyes
15607then :
15608 printf "%s\n" "#define HAVE_GETENTROPY 1" >>confdefs.h
15609
15610fi
15611ac_fn_c_check_func "$LINENO" "getgroups" "ac_cv_func_getgroups"
15612if test "x$ac_cv_func_getgroups" = xyes
15613then :
15614 printf "%s\n" "#define HAVE_GETGROUPS 1" >>confdefs.h
15615
15616fi
15617ac_fn_c_check_func "$LINENO" "gethostname" "ac_cv_func_gethostname"
15618if test "x$ac_cv_func_gethostname" = xyes
15619then :
15620 printf "%s\n" "#define HAVE_GETHOSTNAME 1" >>confdefs.h
15621
15622fi
15623ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
15624if test "x$ac_cv_func_getpagesize" = xyes
15625then :
15626 printf "%s\n" "#define HAVE_GETPAGESIZE 1" >>confdefs.h
15627
15628fi
15629ac_fn_c_check_func "$LINENO" "getpeername" "ac_cv_func_getpeername"
15630if test "x$ac_cv_func_getpeername" = xyes
15631then :
15632 printf "%s\n" "#define HAVE_GETPEERNAME 1" >>confdefs.h
15633
15634fi
15635ac_fn_c_check_func "$LINENO" "getrandom" "ac_cv_func_getrandom"
15636if test "x$ac_cv_func_getrandom" = xyes
15637then :
15638 printf "%s\n" "#define HAVE_GETRANDOM 1" >>confdefs.h
15639
15640fi
15641ac_fn_c_check_func "$LINENO" "getrlimit" "ac_cv_func_getrlimit"
15642if test "x$ac_cv_func_getrlimit" = xyes
15643then :
15644 printf "%s\n" "#define HAVE_GETRLIMIT 1" >>confdefs.h
15645
15646fi
15647ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
15648if test "x$ac_cv_func_getrusage" = xyes
15649then :
15650 printf "%s\n" "#define HAVE_GETRUSAGE 1" >>confdefs.h
15651
15652fi
15653ac_fn_c_check_func "$LINENO" "gettimeofday" "ac_cv_func_gettimeofday"
15654if test "x$ac_cv_func_gettimeofday" = xyes
15655then :
15656 printf "%s\n" "#define HAVE_GETTIMEOFDAY 1" >>confdefs.h
15657
15658fi
15659ac_fn_c_check_func "$LINENO" "kill" "ac_cv_func_kill"
15660if test "x$ac_cv_func_kill" = xyes
15661then :
15662 printf "%s\n" "#define HAVE_KILL 1" >>confdefs.h
15663
15664fi
15665ac_fn_c_check_func "$LINENO" "killpg" "ac_cv_func_killpg"
15666if test "x$ac_cv_func_killpg" = xyes
15667then :
15668 printf "%s\n" "#define HAVE_KILLPG 1" >>confdefs.h
15669
15670fi
15671ac_fn_c_check_func "$LINENO" "lstat" "ac_cv_func_lstat"
15672if test "x$ac_cv_func_lstat" = xyes
15673then :
15674 printf "%s\n" "#define HAVE_LSTAT 1" >>confdefs.h
15675
15676fi
15677ac_fn_c_check_func "$LINENO" "nanosleep" "ac_cv_func_nanosleep"
15678if test "x$ac_cv_func_nanosleep" = xyes
15679then :
15680 printf "%s\n" "#define HAVE_NANOSLEEP 1" >>confdefs.h
15681
15682fi
15683ac_fn_c_check_func "$LINENO" "pselect" "ac_cv_func_pselect"
15684if test "x$ac_cv_func_pselect" = xyes
15685then :
15686 printf "%s\n" "#define HAVE_PSELECT 1" >>confdefs.h
15687
15688fi
15689ac_fn_c_check_func "$LINENO" "readlink" "ac_cv_func_readlink"
15690if test "x$ac_cv_func_readlink" = xyes
15691then :
15692 printf "%s\n" "#define HAVE_READLINK 1" >>confdefs.h
15693
15694fi
15695ac_fn_c_check_func "$LINENO" "select" "ac_cv_func_select"
15696if test "x$ac_cv_func_select" = xyes
15697then :
15698 printf "%s\n" "#define HAVE_SELECT 1" >>confdefs.h
15699
15700fi
15701ac_fn_c_check_func "$LINENO" "setdtablesize" "ac_cv_func_setdtablesize"
15702if test "x$ac_cv_func_setdtablesize" = xyes
15703then :
15704 printf "%s\n" "#define HAVE_SETDTABLESIZE 1" >>confdefs.h
15705
15706fi
15707ac_fn_c_check_func "$LINENO" "setitimer" "ac_cv_func_setitimer"
15708if test "x$ac_cv_func_setitimer" = xyes
15709then :
15710 printf "%s\n" "#define HAVE_SETITIMER 1" >>confdefs.h
15711
15712fi
15713ac_fn_c_check_func "$LINENO" "statfs" "ac_cv_func_statfs"
15714if test "x$ac_cv_func_statfs" = xyes
15715then :
15716 printf "%s\n" "#define HAVE_STATFS 1" >>confdefs.h
15717
15718fi
15719ac_fn_c_check_func "$LINENO" "tcgetpgrp" "ac_cv_func_tcgetpgrp"
15720if test "x$ac_cv_func_tcgetpgrp" = xyes
15721then :
15722 printf "%s\n" "#define HAVE_TCGETPGRP 1" >>confdefs.h
15723
15724fi
15725ac_fn_c_check_func "$LINENO" "uname" "ac_cv_func_uname"
15726if test "x$ac_cv_func_uname" = xyes
15727then :
15728 printf "%s\n" "#define HAVE_UNAME 1" >>confdefs.h
15729
15730fi
15731ac_fn_c_check_func "$LINENO" "ulimit" "ac_cv_func_ulimit"
15732if test "x$ac_cv_func_ulimit" = xyes
15733then :
15734 printf "%s\n" "#define HAVE_ULIMIT 1" >>confdefs.h
15735
15736fi
15737ac_fn_c_check_func "$LINENO" "waitpid" "ac_cv_func_waitpid"
15738if test "x$ac_cv_func_waitpid" = xyes
15739then :
15740 printf "%s\n" "#define HAVE_WAITPID 1" >>confdefs.h
15741
15742fi
15743
15744ac_fn_c_check_func "$LINENO" "rename" "ac_cv_func_rename"
15745if test "x$ac_cv_func_rename" = xyes
15746then :
15747 printf "%s\n" "#define HAVE_RENAME 1" >>confdefs.h
15748
15749else case e in #(
15750 e) case " $LIBOBJS " in
15751 *" rename.$ac_objext "* ) ;;
15752 *) LIBOBJS="$LIBOBJS rename.$ac_objext"
15753 ;;
15754esac
15755 ;;
15756esac
15757fi
15758
15759
15760ac_fn_c_check_func "$LINENO" "bcopy" "ac_cv_func_bcopy"
15761if test "x$ac_cv_func_bcopy" = xyes
15762then :
15763 printf "%s\n" "#define HAVE_BCOPY 1" >>confdefs.h
15764
15765fi
15766ac_fn_c_check_func "$LINENO" "bzero" "ac_cv_func_bzero"
15767if test "x$ac_cv_func_bzero" = xyes
15768then :
15769 printf "%s\n" "#define HAVE_BZERO 1" >>confdefs.h
15770
15771fi
15772ac_fn_c_check_func "$LINENO" "clock_gettime" "ac_cv_func_clock_gettime"
15773if test "x$ac_cv_func_clock_gettime" = xyes
15774then :
15775 printf "%s\n" "#define HAVE_CLOCK_GETTIME 1" >>confdefs.h
15776
15777fi
15778ac_fn_c_check_func "$LINENO" "confstr" "ac_cv_func_confstr"
15779if test "x$ac_cv_func_confstr" = xyes
15780then :
15781 printf "%s\n" "#define HAVE_CONFSTR 1" >>confdefs.h
15782
15783fi
15784ac_fn_c_check_func "$LINENO" "faccessat" "ac_cv_func_faccessat"
15785if test "x$ac_cv_func_faccessat" = xyes
15786then :
15787 printf "%s\n" "#define HAVE_FACCESSAT 1" >>confdefs.h
15788
15789fi
15790ac_fn_c_check_func "$LINENO" "fnmatch" "ac_cv_func_fnmatch"
15791if test "x$ac_cv_func_fnmatch" = xyes
15792then :
15793 printf "%s\n" "#define HAVE_FNMATCH 1" >>confdefs.h
15794
15795fi
15796ac_fn_c_check_func "$LINENO" "getaddrinfo" "ac_cv_func_getaddrinfo"
15797if test "x$ac_cv_func_getaddrinfo" = xyes
15798then :
15799 printf "%s\n" "#define HAVE_GETADDRINFO 1" >>confdefs.h
15800
15801fi
15802ac_fn_c_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname"
15803if test "x$ac_cv_func_gethostbyname" = xyes
15804then :
15805 printf "%s\n" "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h
15806
15807fi
15808ac_fn_c_check_func "$LINENO" "getservbyname" "ac_cv_func_getservbyname"
15809if test "x$ac_cv_func_getservbyname" = xyes
15810then :
15811 printf "%s\n" "#define HAVE_GETSERVBYNAME 1" >>confdefs.h
15812
15813fi
15814ac_fn_c_check_func "$LINENO" "getservent" "ac_cv_func_getservent"
15815if test "x$ac_cv_func_getservent" = xyes
15816then :
15817 printf "%s\n" "#define HAVE_GETSERVENT 1" >>confdefs.h
15818
15819fi
15820ac_fn_c_check_func "$LINENO" "inet_aton" "ac_cv_func_inet_aton"
15821if test "x$ac_cv_func_inet_aton" = xyes
15822then :
15823 printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
15824
15825fi
15826ac_fn_c_check_func "$LINENO" "imaxdiv" "ac_cv_func_imaxdiv"
15827if test "x$ac_cv_func_imaxdiv" = xyes
15828then :
15829 printf "%s\n" "#define HAVE_IMAXDIV 1" >>confdefs.h
15830
15831fi
15832ac_fn_c_check_func "$LINENO" "memmove" "ac_cv_func_memmove"
15833if test "x$ac_cv_func_memmove" = xyes
15834then :
15835 printf "%s\n" "#define HAVE_MEMMOVE 1" >>confdefs.h
15836
15837fi
15838ac_fn_c_check_func "$LINENO" "pathconf" "ac_cv_func_pathconf"
15839if test "x$ac_cv_func_pathconf" = xyes
15840then :
15841 printf "%s\n" "#define HAVE_PATHCONF 1" >>confdefs.h
15842
15843fi
15844ac_fn_c_check_func "$LINENO" "putenv" "ac_cv_func_putenv"
15845if test "x$ac_cv_func_putenv" = xyes
15846then :
15847 printf "%s\n" "#define HAVE_PUTENV 1" >>confdefs.h
15848
15849fi
15850ac_fn_c_check_func "$LINENO" "raise" "ac_cv_func_raise"
15851if test "x$ac_cv_func_raise" = xyes
15852then :
15853 printf "%s\n" "#define HAVE_RAISE 1" >>confdefs.h
15854
15855fi
15856ac_fn_c_check_func "$LINENO" "random" "ac_cv_func_random"
15857if test "x$ac_cv_func_random" = xyes
15858then :
15859 printf "%s\n" "#define HAVE_RANDOM 1" >>confdefs.h
15860
15861fi
15862ac_fn_c_check_func "$LINENO" "regcomp" "ac_cv_func_regcomp"
15863if test "x$ac_cv_func_regcomp" = xyes
15864then :
15865 printf "%s\n" "#define HAVE_REGCOMP 1" >>confdefs.h
15866
15867fi
15868ac_fn_c_check_func "$LINENO" "regexec" "ac_cv_func_regexec"
15869if test "x$ac_cv_func_regexec" = xyes
15870then :
15871 printf "%s\n" "#define HAVE_REGEXEC 1" >>confdefs.h
15872
15873fi
15874ac_fn_c_check_func "$LINENO" "setenv" "ac_cv_func_setenv"
15875if test "x$ac_cv_func_setenv" = xyes
15876then :
15877 printf "%s\n" "#define HAVE_SETENV 1" >>confdefs.h
15878
15879fi
15880ac_fn_c_check_func "$LINENO" "setlinebuf" "ac_cv_func_setlinebuf"
15881if test "x$ac_cv_func_setlinebuf" = xyes
15882then :
15883 printf "%s\n" "#define HAVE_SETLINEBUF 1" >>confdefs.h
15884
15885fi
15886ac_fn_c_check_func "$LINENO" "setlocale" "ac_cv_func_setlocale"
15887if test "x$ac_cv_func_setlocale" = xyes
15888then :
15889 printf "%s\n" "#define HAVE_SETLOCALE 1" >>confdefs.h
15890
15891fi
15892ac_fn_c_check_func "$LINENO" "setvbuf" "ac_cv_func_setvbuf"
15893if test "x$ac_cv_func_setvbuf" = xyes
15894then :
15895 printf "%s\n" "#define HAVE_SETVBUF 1" >>confdefs.h
15896
15897fi
15898ac_fn_c_check_func "$LINENO" "siginterrupt" "ac_cv_func_siginterrupt"
15899if test "x$ac_cv_func_siginterrupt" = xyes
15900then :
15901 printf "%s\n" "#define HAVE_SIGINTERRUPT 1" >>confdefs.h
15902
15903fi
15904ac_fn_c_check_func "$LINENO" "strchr" "ac_cv_func_strchr"
15905if test "x$ac_cv_func_strchr" = xyes
15906then :
15907 printf "%s\n" "#define HAVE_STRCHR 1" >>confdefs.h
15908
15909fi
15910ac_fn_c_check_func "$LINENO" "sysconf" "ac_cv_func_sysconf"
15911if test "x$ac_cv_func_sysconf" = xyes
15912then :
15913 printf "%s\n" "#define HAVE_SYSCONF 1" >>confdefs.h
15914
15915fi
15916ac_fn_c_check_func "$LINENO" "syslog" "ac_cv_func_syslog"
15917if test "x$ac_cv_func_syslog" = xyes
15918then :
15919 printf "%s\n" "#define HAVE_SYSLOG 1" >>confdefs.h
15920
15921fi
15922ac_fn_c_check_func "$LINENO" "tcgetattr" "ac_cv_func_tcgetattr"
15923if test "x$ac_cv_func_tcgetattr" = xyes
15924then :
15925 printf "%s\n" "#define HAVE_TCGETATTR 1" >>confdefs.h
15926
15927fi
15928ac_fn_c_check_func "$LINENO" "tcgetwinsize" "ac_cv_func_tcgetwinsize"
15929if test "x$ac_cv_func_tcgetwinsize" = xyes
15930then :
15931 printf "%s\n" "#define HAVE_TCGETWINSIZE 1" >>confdefs.h
15932
15933fi
15934ac_fn_c_check_func "$LINENO" "tcsetwinsize" "ac_cv_func_tcsetwinsize"
15935if test "x$ac_cv_func_tcsetwinsize" = xyes
15936then :
15937 printf "%s\n" "#define HAVE_TCSETWINSIZE 1" >>confdefs.h
15938
15939fi
15940ac_fn_c_check_func "$LINENO" "times" "ac_cv_func_times"
15941if test "x$ac_cv_func_times" = xyes
15942then :
15943 printf "%s\n" "#define HAVE_TIMES 1" >>confdefs.h
15944
15945fi
15946ac_fn_c_check_func "$LINENO" "ttyname" "ac_cv_func_ttyname"
15947if test "x$ac_cv_func_ttyname" = xyes
15948then :
15949 printf "%s\n" "#define HAVE_TTYNAME 1" >>confdefs.h
15950
15951fi
15952ac_fn_c_check_func "$LINENO" "tzset" "ac_cv_func_tzset"
15953if test "x$ac_cv_func_tzset" = xyes
15954then :
15955 printf "%s\n" "#define HAVE_TZSET 1" >>confdefs.h
15956
15957fi
15958ac_fn_c_check_func "$LINENO" "unsetenv" "ac_cv_func_unsetenv"
15959if test "x$ac_cv_func_unsetenv" = xyes
15960then :
15961 printf "%s\n" "#define HAVE_UNSETENV 1" >>confdefs.h
15962
15963fi
15964
15965
15966ac_fn_c_check_func "$LINENO" "vasprintf" "ac_cv_func_vasprintf"
15967if test "x$ac_cv_func_vasprintf" = xyes
15968then :
15969 printf "%s\n" "#define HAVE_VASPRINTF 1" >>confdefs.h
15970
15971fi
15972ac_fn_c_check_func "$LINENO" "asprintf" "ac_cv_func_asprintf"
15973if test "x$ac_cv_func_asprintf" = xyes
15974then :
15975 printf "%s\n" "#define HAVE_ASPRINTF 1" >>confdefs.h
15976
15977fi
15978
15979ac_fn_c_check_func "$LINENO" "isascii" "ac_cv_func_isascii"
15980if test "x$ac_cv_func_isascii" = xyes
15981then :
15982 printf "%s\n" "#define HAVE_ISASCII 1" >>confdefs.h
15983
15984fi
15985ac_fn_c_check_func "$LINENO" "isblank" "ac_cv_func_isblank"
15986if test "x$ac_cv_func_isblank" = xyes
15987then :
15988 printf "%s\n" "#define HAVE_ISBLANK 1" >>confdefs.h
15989
15990fi
15991ac_fn_c_check_func "$LINENO" "isgraph" "ac_cv_func_isgraph"
15992if test "x$ac_cv_func_isgraph" = xyes
15993then :
15994 printf "%s\n" "#define HAVE_ISGRAPH 1" >>confdefs.h
15995
15996fi
15997ac_fn_c_check_func "$LINENO" "isprint" "ac_cv_func_isprint"
15998if test "x$ac_cv_func_isprint" = xyes
15999then :
16000 printf "%s\n" "#define HAVE_ISPRINT 1" >>confdefs.h
16001
16002fi
16003ac_fn_c_check_func "$LINENO" "isspace" "ac_cv_func_isspace"
16004if test "x$ac_cv_func_isspace" = xyes
16005then :
16006 printf "%s\n" "#define HAVE_ISSPACE 1" >>confdefs.h
16007
16008fi
16009ac_fn_c_check_func "$LINENO" "isxdigit" "ac_cv_func_isxdigit"
16010if test "x$ac_cv_func_isxdigit" = xyes
16011then :
16012 printf "%s\n" "#define HAVE_ISXDIGIT 1" >>confdefs.h
16013
16014fi
16015
16016ac_fn_c_check_func "$LINENO" "getpwent" "ac_cv_func_getpwent"
16017if test "x$ac_cv_func_getpwent" = xyes
16018then :
16019 printf "%s\n" "#define HAVE_GETPWENT 1" >>confdefs.h
16020
16021fi
16022ac_fn_c_check_func "$LINENO" "getpwnam" "ac_cv_func_getpwnam"
16023if test "x$ac_cv_func_getpwnam" = xyes
16024then :
16025 printf "%s\n" "#define HAVE_GETPWNAM 1" >>confdefs.h
16026
16027fi
16028ac_fn_c_check_func "$LINENO" "getpwuid" "ac_cv_func_getpwuid"
16029if test "x$ac_cv_func_getpwuid" = xyes
16030then :
16031 printf "%s\n" "#define HAVE_GETPWUID 1" >>confdefs.h
16032
16033fi
16034
16035ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp"
16036if test "x$ac_cv_func_mkstemp" = xyes
16037then :
16038 printf "%s\n" "#define HAVE_MKSTEMP 1" >>confdefs.h
16039
16040fi
16041ac_fn_c_check_func "$LINENO" "mkdtemp" "ac_cv_func_mkdtemp"
16042if test "x$ac_cv_func_mkdtemp" = xyes
16043then :
16044 printf "%s\n" "#define HAVE_MKDTEMP 1" >>confdefs.h
16045
16046fi
16047
16048ac_fn_c_check_func "$LINENO" "arc4random" "ac_cv_func_arc4random"
16049if test "x$ac_cv_func_arc4random" = xyes
16050then :
16051 printf "%s\n" "#define HAVE_ARC4RANDOM 1" >>confdefs.h
16052
16053fi
16054
16055ac_fn_c_check_func "$LINENO" "strlcat" "ac_cv_func_strlcat"
16056if test "x$ac_cv_func_strlcat" = xyes
16057then :
16058 printf "%s\n" "#define HAVE_STRLCAT 1" >>confdefs.h
16059
16060fi
16061
16062
16063ac_fn_c_check_func "$LINENO" "memfd_create" "ac_cv_func_memfd_create"
16064if test "x$ac_cv_func_memfd_create" = xyes
16065then :
16066 printf "%s\n" "#define HAVE_MEMFD_CREATE 1" >>confdefs.h
16067
16068fi
16069ac_fn_c_check_func "$LINENO" "shm_open" "ac_cv_func_shm_open"
16070if test "x$ac_cv_func_shm_open" = xyes
16071then :
16072 printf "%s\n" "#define HAVE_SHM_OPEN 1" >>confdefs.h
16073
16074fi
16075ac_fn_c_check_func "$LINENO" "shm_mkstemp" "ac_cv_func_shm_mkstemp"
16076if test "x$ac_cv_func_shm_mkstemp" = xyes
16077then :
16078 printf "%s\n" "#define HAVE_SHM_MKSTEMP 1" >>confdefs.h
16079
16080fi
16081
16082
16083ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd"
16084if test "x$ac_cv_func_getcwd" = xyes
16085then :
16086 printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h
16087
16088else case e in #(
16089 e) case " $LIBOBJS " in
16090 *" getcwd.$ac_objext "* ) ;;
16091 *) LIBOBJS="$LIBOBJS getcwd.$ac_objext"
16092 ;;
16093esac
16094 ;;
16095esac
16096fi
16097ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset"
16098if test "x$ac_cv_func_memset" = xyes
16099then :
16100 printf "%s\n" "#define HAVE_MEMSET 1" >>confdefs.h
16101
16102else case e in #(
16103 e) case " $LIBOBJS " in
16104 *" memset.$ac_objext "* ) ;;
16105 *) LIBOBJS="$LIBOBJS memset.$ac_objext"
16106 ;;
16107esac
16108 ;;
16109esac
16110fi
16111
16112ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
16113if test "x$ac_cv_func_strcasecmp" = xyes
16114then :
16115 printf "%s\n" "#define HAVE_STRCASECMP 1" >>confdefs.h
16116
16117else case e in #(
16118 e) case " $LIBOBJS " in
16119 *" strcasecmp.$ac_objext "* ) ;;
16120 *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext"
16121 ;;
16122esac
16123 ;;
16124esac
16125fi
16126ac_fn_c_check_func "$LINENO" "strcasestr" "ac_cv_func_strcasestr"
16127if test "x$ac_cv_func_strcasestr" = xyes
16128then :
16129 printf "%s\n" "#define HAVE_STRCASESTR 1" >>confdefs.h
16130
16131else case e in #(
16132 e) case " $LIBOBJS " in
16133 *" strcasestr.$ac_objext "* ) ;;
16134 *) LIBOBJS="$LIBOBJS strcasestr.$ac_objext"
16135 ;;
16136esac
16137 ;;
16138esac
16139fi
16140ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror"
16141if test "x$ac_cv_func_strerror" = xyes
16142then :
16143 printf "%s\n" "#define HAVE_STRERROR 1" >>confdefs.h
16144
16145else case e in #(
16146 e) case " $LIBOBJS " in
16147 *" strerror.$ac_objext "* ) ;;
16148 *) LIBOBJS="$LIBOBJS strerror.$ac_objext"
16149 ;;
16150esac
16151 ;;
16152esac
16153fi
16154ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
16155if test "x$ac_cv_func_strftime" = xyes
16156then :
16157 printf "%s\n" "#define HAVE_STRFTIME 1" >>confdefs.h
16158
16159else case e in #(
16160 e) case " $LIBOBJS " in
16161 *" strftime.$ac_objext "* ) ;;
16162 *) LIBOBJS="$LIBOBJS strftime.$ac_objext"
16163 ;;
16164esac
16165 ;;
16166esac
16167fi
16168ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen"
16169if test "x$ac_cv_func_strnlen" = xyes
16170then :
16171 printf "%s\n" "#define HAVE_STRNLEN 1" >>confdefs.h
16172
16173else case e in #(
16174 e) case " $LIBOBJS " in
16175 *" strnlen.$ac_objext "* ) ;;
16176 *) LIBOBJS="$LIBOBJS strnlen.$ac_objext"
16177 ;;
16178esac
16179 ;;
16180esac
16181fi
16182ac_fn_c_check_func "$LINENO" "strpbrk" "ac_cv_func_strpbrk"
16183if test "x$ac_cv_func_strpbrk" = xyes
16184then :
16185 printf "%s\n" "#define HAVE_STRPBRK 1" >>confdefs.h
16186
16187else case e in #(
16188 e) case " $LIBOBJS " in
16189 *" strpbrk.$ac_objext "* ) ;;
16190 *) LIBOBJS="$LIBOBJS strpbrk.$ac_objext"
16191 ;;
16192esac
16193 ;;
16194esac
16195fi
16196ac_fn_c_check_func "$LINENO" "strstr" "ac_cv_func_strstr"
16197if test "x$ac_cv_func_strstr" = xyes
16198then :
16199 printf "%s\n" "#define HAVE_STRSTR 1" >>confdefs.h
16200
16201else case e in #(
16202 e) case " $LIBOBJS " in
16203 *" strstr.$ac_objext "* ) ;;
16204 *) LIBOBJS="$LIBOBJS strstr.$ac_objext"
16205 ;;
16206esac
16207 ;;
16208esac
16209fi
16210
16211ac_fn_c_check_func "$LINENO" "strtod" "ac_cv_func_strtod"
16212if test "x$ac_cv_func_strtod" = xyes
16213then :
16214 printf "%s\n" "#define HAVE_STRTOD 1" >>confdefs.h
16215
16216else case e in #(
16217 e) case " $LIBOBJS " in
16218 *" strtod.$ac_objext "* ) ;;
16219 *) LIBOBJS="$LIBOBJS strtod.$ac_objext"
16220 ;;
16221esac
16222 ;;
16223esac
16224fi
16225ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol"
16226if test "x$ac_cv_func_strtol" = xyes
16227then :
16228 printf "%s\n" "#define HAVE_STRTOL 1" >>confdefs.h
16229
16230else case e in #(
16231 e) case " $LIBOBJS " in
16232 *" strtol.$ac_objext "* ) ;;
16233 *) LIBOBJS="$LIBOBJS strtol.$ac_objext"
16234 ;;
16235esac
16236 ;;
16237esac
16238fi
16239ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul"
16240if test "x$ac_cv_func_strtoul" = xyes
16241then :
16242 printf "%s\n" "#define HAVE_STRTOUL 1" >>confdefs.h
16243
16244else case e in #(
16245 e) case " $LIBOBJS " in
16246 *" strtoul.$ac_objext "* ) ;;
16247 *) LIBOBJS="$LIBOBJS strtoul.$ac_objext"
16248 ;;
16249esac
16250 ;;
16251esac
16252fi
16253ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll"
16254if test "x$ac_cv_func_strtoll" = xyes
16255then :
16256 printf "%s\n" "#define HAVE_STRTOLL 1" >>confdefs.h
16257
16258else case e in #(
16259 e) case " $LIBOBJS " in
16260 *" strtoll.$ac_objext "* ) ;;
16261 *) LIBOBJS="$LIBOBJS strtoll.$ac_objext"
16262 ;;
16263esac
16264 ;;
16265esac
16266fi
16267ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull"
16268if test "x$ac_cv_func_strtoull" = xyes
16269then :
16270 printf "%s\n" "#define HAVE_STRTOULL 1" >>confdefs.h
16271
16272else case e in #(
16273 e) case " $LIBOBJS " in
16274 *" strtoull.$ac_objext "* ) ;;
16275 *) LIBOBJS="$LIBOBJS strtoull.$ac_objext"
16276 ;;
16277esac
16278 ;;
16279esac
16280fi
16281ac_fn_c_check_func "$LINENO" "strtoumax" "ac_cv_func_strtoumax"
16282if test "x$ac_cv_func_strtoumax" = xyes
16283then :
16284 printf "%s\n" "#define HAVE_STRTOUMAX 1" >>confdefs.h
16285
16286else case e in #(
16287 e) case " $LIBOBJS " in
16288 *" strtoumax.$ac_objext "* ) ;;
16289 *) LIBOBJS="$LIBOBJS strtoumax.$ac_objext"
16290 ;;
16291esac
16292 ;;
16293esac
16294fi
16295
16296ac_fn_c_check_func "$LINENO" "dprintf" "ac_cv_func_dprintf"
16297if test "x$ac_cv_func_dprintf" = xyes
16298then :
16299 printf "%s\n" "#define HAVE_DPRINTF 1" >>confdefs.h
16300
16301else case e in #(
16302 e) case " $LIBOBJS " in
16303 *" dprintf.$ac_objext "* ) ;;
16304 *) LIBOBJS="$LIBOBJS dprintf.$ac_objext"
16305 ;;
16306esac
16307 ;;
16308esac
16309fi
16310
16311ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup"
16312if test "x$ac_cv_func_strdup" = xyes
16313then :
16314 printf "%s\n" "#define HAVE_STRDUP 1" >>confdefs.h
16315
16316else case e in #(
16317 e) case " $LIBOBJS " in
16318 *" strdup.$ac_objext "* ) ;;
16319 *) LIBOBJS="$LIBOBJS strdup.$ac_objext"
16320 ;;
16321esac
16322 ;;
16323esac
16324fi
16325
16326ac_fn_c_check_func "$LINENO" "strlcpy" "ac_cv_func_strlcpy"
16327if test "x$ac_cv_func_strlcpy" = xyes
16328then :
16329 printf "%s\n" "#define HAVE_STRLCPY 1" >>confdefs.h
16330
16331else case e in #(
16332 e) case " $LIBOBJS " in
16333 *" strlcpy.$ac_objext "* ) ;;
16334 *) LIBOBJS="$LIBOBJS strlcpy.$ac_objext"
16335 ;;
16336esac
16337 ;;
16338esac
16339fi
16340
16341ac_fn_c_check_func "$LINENO" "reallocarray" "ac_cv_func_reallocarray"
16342if test "x$ac_cv_func_reallocarray" = xyes
16343then :
16344 printf "%s\n" "#define HAVE_REALLOCARRAY 1" >>confdefs.h
16345
16346else case e in #(
16347 e) case " $LIBOBJS " in
16348 *" reallocarray.$ac_objext "* ) ;;
16349 *) LIBOBJS="$LIBOBJS reallocarray.$ac_objext"
16350 ;;
16351esac
16352 ;;
16353esac
16354fi
16355
16356
16357ac_fn_c_check_header_compile "$LINENO" "libaudit.h" "ac_cv_header_libaudit_h" "$ac_includes_default"
16358if test "x$ac_cv_header_libaudit_h" = xyes
16359then :
16360 printf "%s\n" "#define HAVE_LIBAUDIT_H 1" >>confdefs.h
16361
16362fi
16363
16364ac_fn_check_decl "$LINENO" "AUDIT_USER_TTY" "ac_cv_have_decl_AUDIT_USER_TTY" "#include <linux/audit.h>
16365" "$ac_c_undeclared_builtin_options" "CFLAGS"
16366if test "x$ac_cv_have_decl_AUDIT_USER_TTY" = xyes
16367then :
16368 ac_have_decl=1
16369else case e in #(
16370 e) ac_have_decl=0 ;;
16371esac
16372fi
16373printf "%s\n" "#define HAVE_DECL_AUDIT_USER_TTY $ac_have_decl" >>confdefs.h
16374
16375
16376ac_fn_check_decl "$LINENO" "confstr" "ac_cv_have_decl_confstr" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16377if test "x$ac_cv_have_decl_confstr" = xyes
16378then :
16379 ac_have_decl=1
16380else case e in #(
16381 e) ac_have_decl=0 ;;
16382esac
16383fi
16384printf "%s\n" "#define HAVE_DECL_CONFSTR $ac_have_decl" >>confdefs.h
16385
16386ac_fn_check_decl "$LINENO" "printf" "ac_cv_have_decl_printf" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16387if test "x$ac_cv_have_decl_printf" = xyes
16388then :
16389 ac_have_decl=1
16390else case e in #(
16391 e) ac_have_decl=0 ;;
16392esac
16393fi
16394printf "%s\n" "#define HAVE_DECL_PRINTF $ac_have_decl" >>confdefs.h
16395
16396ac_fn_check_decl "$LINENO" "brk" "ac_cv_have_decl_brk" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16397if test "x$ac_cv_have_decl_brk" = xyes
16398then :
16399 ac_have_decl=1
16400else case e in #(
16401 e) ac_have_decl=0 ;;
16402esac
16403fi
16404printf "%s\n" "#define HAVE_DECL_BRK $ac_have_decl" >>confdefs.h
16405
16406ac_fn_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16407if test "x$ac_cv_have_decl_sbrk" = xyes
16408then :
16409 ac_have_decl=1
16410else case e in #(
16411 e) ac_have_decl=0 ;;
16412esac
16413fi
16414printf "%s\n" "#define HAVE_DECL_SBRK $ac_have_decl" >>confdefs.h
16415
16416ac_fn_check_decl "$LINENO" "setregid" "ac_cv_have_decl_setregid" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16417if test "x$ac_cv_have_decl_setregid" = xyes
16418then :
16419 ac_have_decl=1
16420else case e in #(
16421 e) ac_have_decl=0 ;;
16422esac
16423fi
16424printf "%s\n" "#define HAVE_DECL_SETREGID $ac_have_decl" >>confdefs.h
16425
16426ac_fn_check_decl "$LINENO" "strcpy" "ac_cv_have_decl_strcpy" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16427if test "x$ac_cv_have_decl_strcpy" = xyes
16428then :
16429 ac_have_decl=1
16430else case e in #(
16431 e) ac_have_decl=0 ;;
16432esac
16433fi
16434printf "%s\n" "#define HAVE_DECL_STRCPY $ac_have_decl" >>confdefs.h
16435
16436ac_fn_check_decl "$LINENO" "strsignal" "ac_cv_have_decl_strsignal" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16437if test "x$ac_cv_have_decl_strsignal" = xyes
16438then :
16439 ac_have_decl=1
16440else case e in #(
16441 e) ac_have_decl=0 ;;
16442esac
16443fi
16444printf "%s\n" "#define HAVE_DECL_STRSIGNAL $ac_have_decl" >>confdefs.h
16445
16446
16447ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
16448if test "x$ac_cv_func_setresuid" = xyes
16449then :
16450 printf "%s\n" "#define HAVE_SETRESUID 1" >>confdefs.h
16451
16452fi
16453ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
16454if test "x$ac_cv_func_setresgid" = xyes
16455then :
16456 printf "%s\n" "#define HAVE_SETRESGID 1" >>confdefs.h
16457
16458fi
16459
16460
16461ac_fn_check_decl "$LINENO" "strtold" "ac_cv_have_decl_strtold" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16462if test "x$ac_cv_have_decl_strtold" = xyes
16463then :
16464 ac_have_decl=1
16465else case e in #(
16466 e) ac_have_decl=0 ;;
16467esac
16468fi
16469printf "%s\n" "#define HAVE_DECL_STRTOLD $ac_have_decl" >>confdefs.h
16470if test $ac_have_decl = 1
16471then :
16472
16473 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for broken strtold" >&5
16474printf %s "checking for broken strtold... " >&6; }
16475 if test ${bash_cv_strtold_broken+y}
16476then :
16477 printf %s "(cached) " >&6
16478else case e in #(
16479 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16480/* end confdefs.h. */
16481#include <stdlib.h>
16482int
16483main (void)
16484{
16485long double r; char *foo, *bar; r = strtold(foo, &bar);
16486
16487 ;
16488 return 0;
16489}
16490_ACEOF
16491if ac_fn_c_try_compile "$LINENO"
16492then :
16493 bash_cv_strtold_broken=no
16494else case e in #(
16495 e) bash_cv_strtold_broken=yes ;;
16496esac
16497fi
16498rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
16499
16500 ;;
16501esac
16502fi
16503
16504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_strtold_broken" >&5
16505printf "%s\n" "$bash_cv_strtold_broken" >&6; }
16506 if test "$bash_cv_strtold_broken" = "yes" ; then
16507 printf "%s\n" "#define STRTOLD_BROKEN 1" >>confdefs.h
16508
16509 fi
16510
16511fi
16512
16513
16514ac_fn_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16515if test "x$ac_cv_have_decl_strtol" = xyes
16516then :
16517 ac_have_decl=1
16518else case e in #(
16519 e) ac_have_decl=0 ;;
16520esac
16521fi
16522printf "%s\n" "#define HAVE_DECL_STRTOL $ac_have_decl" >>confdefs.h
16523
16524ac_fn_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16525if test "x$ac_cv_have_decl_strtoll" = xyes
16526then :
16527 ac_have_decl=1
16528else case e in #(
16529 e) ac_have_decl=0 ;;
16530esac
16531fi
16532printf "%s\n" "#define HAVE_DECL_STRTOLL $ac_have_decl" >>confdefs.h
16533
16534ac_fn_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16535if test "x$ac_cv_have_decl_strtoul" = xyes
16536then :
16537 ac_have_decl=1
16538else case e in #(
16539 e) ac_have_decl=0 ;;
16540esac
16541fi
16542printf "%s\n" "#define HAVE_DECL_STRTOUL $ac_have_decl" >>confdefs.h
16543
16544ac_fn_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16545if test "x$ac_cv_have_decl_strtoull" = xyes
16546then :
16547 ac_have_decl=1
16548else case e in #(
16549 e) ac_have_decl=0 ;;
16550esac
16551fi
16552printf "%s\n" "#define HAVE_DECL_STRTOULL $ac_have_decl" >>confdefs.h
16553
16554ac_fn_check_decl "$LINENO" "strtoumax" "ac_cv_have_decl_strtoumax" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
16555if test "x$ac_cv_have_decl_strtoumax" = xyes
16556then :
16557 ac_have_decl=1
16558else case e in #(
16559 e) ac_have_decl=0 ;;
16560esac
16561fi
16562printf "%s\n" "#define HAVE_DECL_STRTOUMAX $ac_have_decl" >>confdefs.h
16563
16564
16565
16566
16567
16568
16569{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5
16570printf %s "checking for working mktime... " >&6; }
16571if test ${ac_cv_func_working_mktime+y}
16572then :
16573 printf %s "(cached) " >&6
16574else case e in #(
16575 e) if test "$cross_compiling" = yes
16576then :
16577 ac_cv_func_working_mktime=no
16578else case e in #(
16579 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16580/* end confdefs.h. */
16581/* Test program from Paul Eggert and Tony Leneis. */
16582#include <time.h>
16583#ifdef HAVE_SYS_TIME_H
16584# include <sys/time.h>
16585#endif
16586
16587#include <limits.h>
16588#include <stdlib.h>
16589
16590#ifdef HAVE_UNISTD_H
16591# include <unistd.h>
16592#endif
16593
16594#ifndef HAVE_ALARM
16595# define alarm(X) /* empty */
16596#endif
16597
16598/* Work around redefinition to rpl_putenv by other config tests. */
16599#undef putenv
16600
16601static time_t time_t_max;
16602static time_t time_t_min;
16603
16604/* Values we'll use to set the TZ environment variable. */
16605static const char *tz_strings[] = {
16606 (const char *) 0, "TZ=GMT0", "TZ=JST-9",
16607 "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00"
16608};
16609#define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0]))
16610
16611/* Return 0 if mktime fails to convert a date in the spring-forward gap.
16612 Based on a problem report from Andreas Jaeger. */
16613static int
16614spring_forward_gap (void)
16615{
16616 /* glibc (up to about 1998-10-07) failed this test. */
16617 struct tm tm;
16618
16619 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
16620 instead of "TZ=America/Vancouver" in order to detect the bug even
16621 on systems that don't support the Olson extension, or don't have the
16622 full zoneinfo tables installed. */
16623 putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0");
16624
16625 tm.tm_year = 98;
16626 tm.tm_mon = 3;
16627 tm.tm_mday = 5;
16628 tm.tm_hour = 2;
16629 tm.tm_min = 0;
16630 tm.tm_sec = 0;
16631 tm.tm_isdst = -1;
16632 return mktime (&tm) != (time_t) -1;
16633}
16634
16635static int
16636mktime_test1 (time_t now)
16637{
16638 struct tm *lt;
16639 return ! (lt = localtime (&now)) || mktime (lt) == now;
16640}
16641
16642static int
16643mktime_test (time_t now)
16644{
16645 return (mktime_test1 (now)
16646 && mktime_test1 ((time_t) (time_t_max - now))
16647 && mktime_test1 ((time_t) (time_t_min + now)));
16648}
16649
16650static int
16651irix_6_4_bug (void)
16652{
16653 /* Based on code from Ariel Faigon. */
16654 struct tm tm;
16655 tm.tm_year = 96;
16656 tm.tm_mon = 3;
16657 tm.tm_mday = 0;
16658 tm.tm_hour = 0;
16659 tm.tm_min = 0;
16660 tm.tm_sec = 0;
16661 tm.tm_isdst = -1;
16662 mktime (&tm);
16663 return tm.tm_mon == 2 && tm.tm_mday == 31;
16664}
16665
16666static int
16667bigtime_test (int j)
16668{
16669 struct tm tm;
16670 time_t now;
16671 tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j;
16672 now = mktime (&tm);
16673 if (now != (time_t) -1)
16674 {
16675 struct tm *lt = localtime (&now);
16676 if (! (lt
16677 && lt->tm_year == tm.tm_year
16678 && lt->tm_mon == tm.tm_mon
16679 && lt->tm_mday == tm.tm_mday
16680 && lt->tm_hour == tm.tm_hour
16681 && lt->tm_min == tm.tm_min
16682 && lt->tm_sec == tm.tm_sec
16683 && lt->tm_yday == tm.tm_yday
16684 && lt->tm_wday == tm.tm_wday
16685 && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst)
16686 == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst))))
16687 return 0;
16688 }
16689 return 1;
16690}
16691
16692static int
16693year_2050_test (void)
16694{
16695 /* The correct answer for 2050-02-01 00:00:00 in Pacific time,
16696 ignoring leap seconds. */
16697 unsigned long int answer = 2527315200UL;
16698
16699 struct tm tm;
16700 time_t t;
16701 tm.tm_year = 2050 - 1900;
16702 tm.tm_mon = 2 - 1;
16703 tm.tm_mday = 1;
16704 tm.tm_hour = tm.tm_min = tm.tm_sec = 0;
16705 tm.tm_isdst = -1;
16706
16707 /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0"
16708 instead of "TZ=America/Vancouver" in order to detect the bug even
16709 on systems that don't support the Olson extension, or don't have the
16710 full zoneinfo tables installed. */
16711 putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0");
16712
16713 t = mktime (&tm);
16714
16715 /* Check that the result is either a failure, or close enough
16716 to the correct answer that we can assume the discrepancy is
16717 due to leap seconds. */
16718 return (t == (time_t) -1
16719 || (0 < t && answer - 120 <= t && t <= answer + 120));
16720}
16721
16722int
16723main (void)
16724{
16725 time_t t, delta;
16726 int i, j;
16727
16728 /* This test makes some buggy mktime implementations loop.
16729 Give up after 60 seconds; a mktime slower than that
16730 isn't worth using anyway. */
16731 alarm (60);
16732
16733 for (;;)
16734 {
16735 t = (time_t_max << 1) + 1;
16736 if (t <= time_t_max)
16737 break;
16738 time_t_max = t;
16739 }
16740 time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max;
16741
16742 delta = time_t_max / 997; /* a suitable prime number */
16743 for (i = 0; i < N_STRINGS; i++)
16744 {
16745 if (tz_strings[i])
16746 putenv ((char*) tz_strings[i]);
16747
16748 for (t = 0; t <= time_t_max - delta; t += delta)
16749 if (! mktime_test (t))
16750 return 1;
16751 if (! (mktime_test ((time_t) 1)
16752 && mktime_test ((time_t) (60 * 60))
16753 && mktime_test ((time_t) (60 * 60 * 24))))
16754 return 1;
16755
16756 for (j = 1; ; j <<= 1)
16757 if (! bigtime_test (j))
16758 return 1;
16759 else if (INT_MAX / 2 < j)
16760 break;
16761 if (! bigtime_test (INT_MAX))
16762 return 1;
16763 }
16764 return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ());
16765}
16766_ACEOF
16767if ac_fn_c_try_run "$LINENO"
16768then :
16769 ac_cv_func_working_mktime=yes
16770else case e in #(
16771 e) ac_cv_func_working_mktime=no ;;
16772esac
16773fi
16774rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16775 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
16776esac
16777fi
16778 ;;
16779esac
16780fi
16781{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5
16782printf "%s\n" "$ac_cv_func_working_mktime" >&6; }
16783if test $ac_cv_func_working_mktime = no; then
16784 case " $LIBOBJS " in
16785 *" mktime.$ac_objext "* ) ;;
16786 *) LIBOBJS="$LIBOBJS mktime.$ac_objext"
16787 ;;
16788esac
16789
16790fi
16791
16792
16793
16794ac_fn_c_check_header_compile "$LINENO" "argz.h" "ac_cv_header_argz_h" "$ac_includes_default"
16795if test "x$ac_cv_header_argz_h" = xyes
16796then :
16797 printf "%s\n" "#define HAVE_ARGZ_H 1" >>confdefs.h
16798
16799fi
16800ac_fn_c_check_header_compile "$LINENO" "errno.h" "ac_cv_header_errno_h" "$ac_includes_default"
16801if test "x$ac_cv_header_errno_h" = xyes
16802then :
16803 printf "%s\n" "#define HAVE_ERRNO_H 1" >>confdefs.h
16804
16805fi
16806ac_fn_c_check_header_compile "$LINENO" "fcntl.h" "ac_cv_header_fcntl_h" "$ac_includes_default"
16807if test "x$ac_cv_header_fcntl_h" = xyes
16808then :
16809 printf "%s\n" "#define HAVE_FCNTL_H 1" >>confdefs.h
16810
16811fi
16812ac_fn_c_check_header_compile "$LINENO" "malloc.h" "ac_cv_header_malloc_h" "$ac_includes_default"
16813if test "x$ac_cv_header_malloc_h" = xyes
16814then :
16815 printf "%s\n" "#define HAVE_MALLOC_H 1" >>confdefs.h
16816
16817fi
16818ac_fn_c_check_header_compile "$LINENO" "stdio_ext.h" "ac_cv_header_stdio_ext_h" "$ac_includes_default"
16819if test "x$ac_cv_header_stdio_ext_h" = xyes
16820then :
16821 printf "%s\n" "#define HAVE_STDIO_EXT_H 1" >>confdefs.h
16822
16823fi
16824
16825
16826printf "%s\n" "#define HAVE_MALLOC 1" >>confdefs.h
16827
16828
16829
16830{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5
16831printf %s "checking for working mmap... " >&6; }
16832if test ${ac_cv_func_mmap_fixed_mapped+y}
16833then :
16834 printf %s "(cached) " >&6
16835else case e in #(
16836 e) if test "$cross_compiling" = yes
16837then :
16838 case "$host_os" in # ((
16839 # Guess yes on platforms where we know the result.
16840 linux*) ac_cv_func_mmap_fixed_mapped=yes ;;
16841 # If we don't know, assume the worst.
16842 *) ac_cv_func_mmap_fixed_mapped=no ;;
16843 esac
16844else case e in #(
16845 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16846/* end confdefs.h. */
16847$ac_includes_default
16848/* malloc might have been renamed as rpl_malloc. */
16849#undef malloc
16850
16851/* Thanks to Mike Haertel and Jim Avera for this test.
16852 Here is a matrix of mmap possibilities:
16853 mmap private not fixed
16854 mmap private fixed at somewhere currently unmapped
16855 mmap private fixed at somewhere already mapped
16856 mmap shared not fixed
16857 mmap shared fixed at somewhere currently unmapped
16858 mmap shared fixed at somewhere already mapped
16859 For private mappings, we should verify that changes cannot be read()
16860 back from the file, nor mmap's back from the file at a different
16861 address. (There have been systems where private was not correctly
16862 implemented like the infamous i386 svr4.0, and systems where the
16863 VM page cache was not coherent with the file system buffer cache
16864 like early versions of FreeBSD and possibly contemporary NetBSD.)
16865 For shared mappings, we should conversely verify that changes get
16866 propagated back to all the places they're supposed to be. */
16867
16868#include <fcntl.h>
16869#include <sys/mman.h>
16870
16871#ifndef getpagesize
16872/* Prefer sysconf to the legacy getpagesize function, as getpagesize has
16873 been removed from POSIX and is limited to page sizes that fit in 'int'. */
16874# ifdef _SC_PAGESIZE
16875# define getpagesize() sysconf (_SC_PAGESIZE)
16876# elif defined _SC_PAGE_SIZE
16877# define getpagesize() sysconf (_SC_PAGE_SIZE)
16878# elif HAVE_GETPAGESIZE
16879int getpagesize ();
16880# else
16881# ifdef HAVE_SYS_PARAM_H
16882# include <sys/param.h>
16883# ifdef EXEC_PAGESIZE
16884# define getpagesize() EXEC_PAGESIZE
16885# else /* no EXEC_PAGESIZE */
16886# ifdef NBPG
16887# define getpagesize() NBPG * CLSIZE
16888# ifndef CLSIZE
16889# define CLSIZE 1
16890# endif /* no CLSIZE */
16891# else /* no NBPG */
16892# ifdef NBPC
16893# define getpagesize() NBPC
16894# else /* no NBPC */
16895# ifdef PAGESIZE
16896# define getpagesize() PAGESIZE
16897# endif /* PAGESIZE */
16898# endif /* no NBPC */
16899# endif /* no NBPG */
16900# endif /* no EXEC_PAGESIZE */
16901# else /* no HAVE_SYS_PARAM_H */
16902# define getpagesize() 8192 /* punt totally */
16903# endif /* no HAVE_SYS_PARAM_H */
16904# endif
16905#endif
16906
16907int
16908main (void)
16909{
16910 char *data, *data2, *data3;
16911 const char *cdata2;
16912 long i, pagesize;
16913 int fd, fd2;
16914
16915 pagesize = getpagesize ();
16916
16917 /* First, make a file with some known garbage in it. */
16918 data = (char *) malloc (pagesize);
16919 if (!data)
16920 return 1;
16921 for (i = 0; i < pagesize; ++i)
16922 *(data + i) = rand ();
16923 umask (0);
16924 fd = creat ("conftest.mmap", 0600);
16925 if (fd < 0)
16926 return 2;
16927 if (write (fd, data, pagesize) != pagesize)
16928 return 3;
16929 close (fd);
16930
16931 /* Next, check that the tail of a page is zero-filled. File must have
16932 non-zero length, otherwise we risk SIGBUS for entire page. */
16933 fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600);
16934 if (fd2 < 0)
16935 return 4;
16936 cdata2 = "";
16937 if (write (fd2, cdata2, 1) != 1)
16938 return 5;
16939 data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L);
16940 if (data2 == MAP_FAILED)
16941 return 6;
16942 for (i = 0; i < pagesize; ++i)
16943 if (*(data2 + i))
16944 return 7;
16945 close (fd2);
16946 /* 'return 8;' not currently used. */
16947
16948 /* Next, try to mmap the file at a fixed address which already has
16949 something else allocated at it. If we can, also make sure that
16950 we see the same garbage. */
16951 fd = open ("conftest.mmap", O_RDWR);
16952 if (fd < 0)
16953 return 9;
16954 if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE,
16955 MAP_PRIVATE | MAP_FIXED, fd, 0L))
16956 return 10;
16957 for (i = 0; i < pagesize; ++i)
16958 if (*(data + i) != *(data2 + i))
16959 return 11;
16960
16961 /* Finally, make sure that changes to the mapped area do not
16962 percolate back to the file as seen by read(). (This is a bug on
16963 some variants of i386 svr4.0.) */
16964 for (i = 0; i < pagesize; ++i)
16965 *(data2 + i) = *(data2 + i) + 1;
16966 data3 = (char *) malloc (pagesize);
16967 if (!data3)
16968 return 12;
16969 if (read (fd, data3, pagesize) != pagesize)
16970 return 13;
16971 for (i = 0; i < pagesize; ++i)
16972 if (*(data + i) != *(data3 + i))
16973 return 14;
16974 close (fd);
16975 free (data);
16976 free (data3);
16977 return 0;
16978}
16979_ACEOF
16980if ac_fn_c_try_run "$LINENO"
16981then :
16982 ac_cv_func_mmap_fixed_mapped=yes
16983else case e in #(
16984 e) ac_cv_func_mmap_fixed_mapped=no ;;
16985esac
16986fi
16987rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
16988 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
16989esac
16990fi
16991 ;;
16992esac
16993fi
16994{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5
16995printf "%s\n" "$ac_cv_func_mmap_fixed_mapped" >&6; }
16996if test $ac_cv_func_mmap_fixed_mapped = yes; then
16997
16998printf "%s\n" "#define HAVE_MMAP 1" >>confdefs.h
16999
17000fi
17001rm -f conftest.mmap conftest.txt
17002
17003ac_fn_c_check_func "$LINENO" "__argz_count" "ac_cv_func___argz_count"
17004if test "x$ac_cv_func___argz_count" = xyes
17005then :
17006 printf "%s\n" "#define HAVE___ARGZ_COUNT 1" >>confdefs.h
17007
17008fi
17009ac_fn_c_check_func "$LINENO" "__argz_next" "ac_cv_func___argz_next"
17010if test "x$ac_cv_func___argz_next" = xyes
17011then :
17012 printf "%s\n" "#define HAVE___ARGZ_NEXT 1" >>confdefs.h
17013
17014fi
17015ac_fn_c_check_func "$LINENO" "__argz_stringify" "ac_cv_func___argz_stringify"
17016if test "x$ac_cv_func___argz_stringify" = xyes
17017then :
17018 printf "%s\n" "#define HAVE___ARGZ_STRINGIFY 1" >>confdefs.h
17019
17020fi
17021ac_fn_c_check_func "$LINENO" "dcgettext" "ac_cv_func_dcgettext"
17022if test "x$ac_cv_func_dcgettext" = xyes
17023then :
17024 printf "%s\n" "#define HAVE_DCGETTEXT 1" >>confdefs.h
17025
17026fi
17027ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset"
17028if test "x$ac_cv_func_locale_charset" = xyes
17029then :
17030 printf "%s\n" "#define HAVE_LOCALE_CHARSET 1" >>confdefs.h
17031
17032fi
17033ac_fn_c_check_func "$LINENO" "mempcpy" "ac_cv_func_mempcpy"
17034if test "x$ac_cv_func_mempcpy" = xyes
17035then :
17036 printf "%s\n" "#define HAVE_MEMPCPY 1" >>confdefs.h
17037
17038fi
17039ac_fn_c_check_func "$LINENO" "munmap" "ac_cv_func_munmap"
17040if test "x$ac_cv_func_munmap" = xyes
17041then :
17042 printf "%s\n" "#define HAVE_MUNMAP 1" >>confdefs.h
17043
17044fi
17045ac_fn_c_check_func "$LINENO" "mremap" "ac_cv_func_mremap"
17046if test "x$ac_cv_func_mremap" = xyes
17047then :
17048 printf "%s\n" "#define HAVE_MREMAP 1" >>confdefs.h
17049
17050fi
17051ac_fn_c_check_func "$LINENO" "stpcpy" "ac_cv_func_stpcpy"
17052if test "x$ac_cv_func_stpcpy" = xyes
17053then :
17054 printf "%s\n" "#define HAVE_STPCPY 1" >>confdefs.h
17055
17056fi
17057ac_fn_c_check_func "$LINENO" "strcspn" "ac_cv_func_strcspn"
17058if test "x$ac_cv_func_strcspn" = xyes
17059then :
17060 printf "%s\n" "#define HAVE_STRCSPN 1" >>confdefs.h
17061
17062fi
17063
17064
17065INTL_DEP= INTL_INC= LIBINTL_H=
17066if test "x$USE_INCLUDED_LIBINTL" = "xyes"; then
17067 INTL_DEP='${INTL_LIBDIR}/libintl.a'
17068 INTL_INC='-I${INTL_LIBSRC} -I${INTL_BUILDDIR}'
17069 LIBINTL_H='${INTL_BUILDDIR}/libintl.h'
17070
17071 printf "%s\n" "#define HAVE_LOCALE_CHARSET 1" >>confdefs.h
17072
17073fi
17074
17075
17076
17077
17078
17079
17080ac_fn_c_check_header_compile "$LINENO" "wctype.h" "ac_cv_header_wctype_h" "$ac_includes_default"
17081if test "x$ac_cv_header_wctype_h" = xyes
17082then :
17083 printf "%s\n" "#define HAVE_WCTYPE_H 1" >>confdefs.h
17084
17085fi
17086
17087ac_fn_c_check_header_compile "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default"
17088if test "x$ac_cv_header_wchar_h" = xyes
17089then :
17090 printf "%s\n" "#define HAVE_WCHAR_H 1" >>confdefs.h
17091
17092fi
17093
17094ac_fn_c_check_header_compile "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default"
17095if test "x$ac_cv_header_langinfo_h" = xyes
17096then :
17097 printf "%s\n" "#define HAVE_LANGINFO_H 1" >>confdefs.h
17098
17099fi
17100
17101
17102ac_fn_c_check_header_compile "$LINENO" "mbstr.h" "ac_cv_header_mbstr_h" "$ac_includes_default"
17103if test "x$ac_cv_header_mbstr_h" = xyes
17104then :
17105 printf "%s\n" "#define HAVE_MBSTR_H 1" >>confdefs.h
17106
17107fi
17108
17109
17110ac_fn_c_check_func "$LINENO" "mbrlen" "ac_cv_func_mbrlen"
17111if test "x$ac_cv_func_mbrlen" = xyes
17112then :
17113 printf "%s\n" "#define HAVE_MBRLEN 1" >>confdefs.h
17114
17115fi
17116
17117ac_fn_c_check_func "$LINENO" "mbscasecmp" "ac_cv_func_mbscasecmp"
17118if test "x$ac_cv_func_mbscasecmp" = xyes
17119then :
17120 printf "%s\n" "#define HAVE_MBSCASECMP 1" >>confdefs.h
17121
17122fi
17123
17124ac_fn_c_check_func "$LINENO" "mbscmp" "ac_cv_func_mbscmp"
17125if test "x$ac_cv_func_mbscmp" = xyes
17126then :
17127 printf "%s\n" "#define HAVE_MBSCMP 1" >>confdefs.h
17128
17129fi
17130
17131ac_fn_c_check_func "$LINENO" "mbsncmp" "ac_cv_func_mbsncmp"
17132if test "x$ac_cv_func_mbsncmp" = xyes
17133then :
17134 printf "%s\n" "#define HAVE_MBSNCMP 1" >>confdefs.h
17135
17136fi
17137
17138ac_fn_c_check_func "$LINENO" "mbsnrtowcs" "ac_cv_func_mbsnrtowcs"
17139if test "x$ac_cv_func_mbsnrtowcs" = xyes
17140then :
17141 printf "%s\n" "#define HAVE_MBSNRTOWCS 1" >>confdefs.h
17142
17143fi
17144
17145ac_fn_c_check_func "$LINENO" "mbsrtowcs" "ac_cv_func_mbsrtowcs"
17146if test "x$ac_cv_func_mbsrtowcs" = xyes
17147then :
17148 printf "%s\n" "#define HAVE_MBSRTOWCS 1" >>confdefs.h
17149
17150fi
17151
17152
17153ac_fn_c_check_func "$LINENO" "mbschr" "ac_cv_func_mbschr"
17154if test "x$ac_cv_func_mbschr" = xyes
17155then :
17156 printf "%s\n" "#define HAVE_MBSCHR 1" >>confdefs.h
17157
17158else case e in #(
17159 e) case " $LIBOBJS " in
17160 *" mbschr.$ac_objext "* ) ;;
17161 *) LIBOBJS="$LIBOBJS mbschr.$ac_objext"
17162 ;;
17163esac
17164 ;;
17165esac
17166fi
17167
17168
17169ac_fn_c_check_func "$LINENO" "wcrtomb" "ac_cv_func_wcrtomb"
17170if test "x$ac_cv_func_wcrtomb" = xyes
17171then :
17172 printf "%s\n" "#define HAVE_WCRTOMB 1" >>confdefs.h
17173
17174fi
17175
17176ac_fn_c_check_func "$LINENO" "wcscoll" "ac_cv_func_wcscoll"
17177if test "x$ac_cv_func_wcscoll" = xyes
17178then :
17179 printf "%s\n" "#define HAVE_WCSCOLL 1" >>confdefs.h
17180
17181fi
17182
17183ac_fn_c_check_func "$LINENO" "wcsdup" "ac_cv_func_wcsdup"
17184if test "x$ac_cv_func_wcsdup" = xyes
17185then :
17186 printf "%s\n" "#define HAVE_WCSDUP 1" >>confdefs.h
17187
17188fi
17189
17190ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth"
17191if test "x$ac_cv_func_wcwidth" = xyes
17192then :
17193 printf "%s\n" "#define HAVE_WCWIDTH 1" >>confdefs.h
17194
17195fi
17196
17197ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype"
17198if test "x$ac_cv_func_wctype" = xyes
17199then :
17200 printf "%s\n" "#define HAVE_WCTYPE 1" >>confdefs.h
17201
17202fi
17203
17204ac_fn_c_check_func "$LINENO" "wcsnrtombs" "ac_cv_func_wcsnrtombs"
17205if test "x$ac_cv_func_wcsnrtombs" = xyes
17206then :
17207 printf "%s\n" "#define HAVE_WCSNRTOMBS 1" >>confdefs.h
17208
17209fi
17210
17211
17212ac_fn_c_check_func "$LINENO" "wcswidth" "ac_cv_func_wcswidth"
17213if test "x$ac_cv_func_wcswidth" = xyes
17214then :
17215 printf "%s\n" "#define HAVE_WCSWIDTH 1" >>confdefs.h
17216
17217else case e in #(
17218 e) case " $LIBOBJS " in
17219 *" wcswidth.$ac_objext "* ) ;;
17220 *) LIBOBJS="$LIBOBJS wcswidth.$ac_objext"
17221 ;;
17222esac
17223 ;;
17224esac
17225fi
17226
17227
17228
17229 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc and mbstate_t are properly declared" >&5
17230printf %s "checking whether mbrtowc and mbstate_t are properly declared... " >&6; }
17231if test ${ac_cv_func_mbrtowc+y}
17232then :
17233 printf %s "(cached) " >&6
17234else case e in #(
17235 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17236/* end confdefs.h. */
17237#include <wchar.h>
17238int
17239main (void)
17240{
17241wchar_t wc;
17242 char const s[] = "";
17243 size_t n = 1;
17244 mbstate_t state;
17245 return ! (sizeof state && (mbrtowc) (&wc, s, n, &state));
17246 ;
17247 return 0;
17248}
17249_ACEOF
17250if ac_fn_c_try_link "$LINENO"
17251then :
17252 ac_cv_func_mbrtowc=yes
17253else case e in #(
17254 e) ac_cv_func_mbrtowc=no ;;
17255esac
17256fi
17257rm -f core conftest.err conftest.$ac_objext conftest.beam \
17258 conftest$ac_exeext conftest.$ac_ext ;;
17259esac
17260fi
17261{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mbrtowc" >&5
17262printf "%s\n" "$ac_cv_func_mbrtowc" >&6; }
17263 if test $ac_cv_func_mbrtowc = yes; then
17264
17265printf "%s\n" "#define HAVE_MBRTOWC 1" >>confdefs.h
17266
17267 fi
17268
17269if test $ac_cv_func_mbrtowc = yes; then
17270 printf "%s\n" "#define HAVE_MBSTATE_T 1" >>confdefs.h
17271
17272fi
17273
17274ac_fn_c_check_func "$LINENO" "iswlower" "ac_cv_func_iswlower"
17275if test "x$ac_cv_func_iswlower" = xyes
17276then :
17277 printf "%s\n" "#define HAVE_ISWLOWER 1" >>confdefs.h
17278
17279fi
17280ac_fn_c_check_func "$LINENO" "iswupper" "ac_cv_func_iswupper"
17281if test "x$ac_cv_func_iswupper" = xyes
17282then :
17283 printf "%s\n" "#define HAVE_ISWUPPER 1" >>confdefs.h
17284
17285fi
17286ac_fn_c_check_func "$LINENO" "towlower" "ac_cv_func_towlower"
17287if test "x$ac_cv_func_towlower" = xyes
17288then :
17289 printf "%s\n" "#define HAVE_TOWLOWER 1" >>confdefs.h
17290
17291fi
17292ac_fn_c_check_func "$LINENO" "towupper" "ac_cv_func_towupper"
17293if test "x$ac_cv_func_towupper" = xyes
17294then :
17295 printf "%s\n" "#define HAVE_TOWUPPER 1" >>confdefs.h
17296
17297fi
17298ac_fn_c_check_func "$LINENO" "iswctype" "ac_cv_func_iswctype"
17299if test "x$ac_cv_func_iswctype" = xyes
17300then :
17301 printf "%s\n" "#define HAVE_ISWCTYPE 1" >>confdefs.h
17302
17303fi
17304
17305
17306
17307
17308{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wchar_t in wchar.h" >&5
17309printf %s "checking for wchar_t in wchar.h... " >&6; }
17310if test ${bash_cv_type_wchar_t+y}
17311then :
17312 printf %s "(cached) " >&6
17313else case e in #(
17314 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17315/* end confdefs.h. */
17316
17317#include <wchar.h>
17318int
17319main (void)
17320{
17321
17322 wchar_t foo;
17323 foo = 0;
17324
17325 ;
17326 return 0;
17327}
17328_ACEOF
17329if ac_fn_c_try_compile "$LINENO"
17330then :
17331 bash_cv_type_wchar_t=yes
17332else case e in #(
17333 e) bash_cv_type_wchar_t=no
17334 ;;
17335esac
17336fi
17337rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
17338esac
17339fi
17340{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wchar_t" >&5
17341printf "%s\n" "$bash_cv_type_wchar_t" >&6; }
17342if test $bash_cv_type_wchar_t = yes; then
17343
17344printf "%s\n" "#define HAVE_WCHAR_T 1" >>confdefs.h
17345
17346fi
17347
17348{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wctype_t in wctype.h" >&5
17349printf %s "checking for wctype_t in wctype.h... " >&6; }
17350if test ${bash_cv_type_wctype_t+y}
17351then :
17352 printf %s "(cached) " >&6
17353else case e in #(
17354 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17355/* end confdefs.h. */
17356
17357#include <wctype.h>
17358int
17359main (void)
17360{
17361
17362 wctype_t foo;
17363 foo = 0;
17364
17365 ;
17366 return 0;
17367}
17368_ACEOF
17369if ac_fn_c_try_compile "$LINENO"
17370then :
17371 bash_cv_type_wctype_t=yes
17372else case e in #(
17373 e) bash_cv_type_wctype_t=no
17374 ;;
17375esac
17376fi
17377rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
17378esac
17379fi
17380{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wctype_t" >&5
17381printf "%s\n" "$bash_cv_type_wctype_t" >&6; }
17382if test $bash_cv_type_wctype_t = yes; then
17383
17384printf "%s\n" "#define HAVE_WCTYPE_T 1" >>confdefs.h
17385
17386fi
17387
17388{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wint_t in wctype.h" >&5
17389printf %s "checking for wint_t in wctype.h... " >&6; }
17390if test ${bash_cv_type_wint_t+y}
17391then :
17392 printf %s "(cached) " >&6
17393else case e in #(
17394 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17395/* end confdefs.h. */
17396
17397#include <wctype.h>
17398int
17399main (void)
17400{
17401
17402 wint_t foo;
17403 foo = 0;
17404
17405 ;
17406 return 0;
17407}
17408_ACEOF
17409if ac_fn_c_try_compile "$LINENO"
17410then :
17411 bash_cv_type_wint_t=yes
17412else case e in #(
17413 e) bash_cv_type_wint_t=no
17414 ;;
17415esac
17416fi
17417rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
17418esac
17419fi
17420{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wint_t" >&5
17421printf "%s\n" "$bash_cv_type_wint_t" >&6; }
17422if test $bash_cv_type_wint_t = yes; then
17423
17424printf "%s\n" "#define HAVE_WINT_T 1" >>confdefs.h
17425
17426fi
17427
17428{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for wcwidth broken with unicode combining characters" >&5
17429printf %s "checking for wcwidth broken with unicode combining characters... " >&6; }
17430if test ${bash_cv_wcwidth_broken+y}
17431then :
17432 printf %s "(cached) " >&6
17433else case e in #(
17434 e) if test "$cross_compiling" = yes
17435then :
17436 bash_cv_wcwidth_broken=no
17437
17438else case e in #(
17439 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17440/* end confdefs.h. */
17441
17442#include <unistd.h>
17443#include <stdlib.h>
17444#include <stdio.h>
17445
17446#include <locale.h>
17447#include <wchar.h>
17448
17449int
17450main(int c, char **v)
17451{
17452 int w;
17453
17454 setlocale(LC_ALL, "en_US.UTF-8");
17455 w = wcwidth (0x0301);
17456 if (w != 0)
17457 exit (0);
17458 w = wcwidth (0x200b);
17459 exit (w == 0); /* exit 0 if wcwidth broken */
17460}
17461
17462_ACEOF
17463if ac_fn_c_try_run "$LINENO"
17464then :
17465 bash_cv_wcwidth_broken=yes
17466else case e in #(
17467 e) bash_cv_wcwidth_broken=no ;;
17468esac
17469fi
17470rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
17471 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
17472esac
17473fi
17474 ;;
17475esac
17476fi
17477{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcwidth_broken" >&5
17478printf "%s\n" "$bash_cv_wcwidth_broken" >&6; }
17479if test "$bash_cv_wcwidth_broken" = yes; then
17480
17481printf "%s\n" "#define WCWIDTH_BROKEN 1" >>confdefs.h
17482
17483fi
17484
17485if test "$am_cv_func_iconv" = yes; then
17486 OLDLIBS="$LIBS"
17487 LIBS="$LIBS $LIBINTL $LIBICONV"
17488 ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset"
17489if test "x$ac_cv_func_locale_charset" = xyes
17490then :
17491 printf "%s\n" "#define HAVE_LOCALE_CHARSET 1" >>confdefs.h
17492
17493fi
17494
17495 LIBS="$OLDLIBS"
17496fi
17497
17498# The cast to long int works around a bug in the HP C Compiler
17499# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
17500# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
17501# This bug is HP SR number 8606223364.
17502{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of wchar_t" >&5
17503printf %s "checking size of wchar_t... " >&6; }
17504if test ${ac_cv_sizeof_wchar_t+y}
17505then :
17506 printf %s "(cached) " >&6
17507else case e in #(
17508 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (wchar_t))" "ac_cv_sizeof_wchar_t" "$ac_includes_default"
17509then :
17510
17511else case e in #(
17512 e) if test "$ac_cv_type_wchar_t" = yes; then
17513 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
17514printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
17515as_fn_error 77 "cannot compute sizeof (wchar_t)
17516See 'config.log' for more details" "$LINENO" 5; }
17517 else
17518 ac_cv_sizeof_wchar_t=0
17519 fi ;;
17520esac
17521fi
17522 ;;
17523esac
17524fi
17525{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_wchar_t" >&5
17526printf "%s\n" "$ac_cv_sizeof_wchar_t" >&6; }
17527
17528
17529
17530printf "%s\n" "#define SIZEOF_WCHAR_T $ac_cv_sizeof_wchar_t" >>confdefs.h
17531
17532
17533
17534
17535
17536if test "$opt_static_link" != yes; then
17537{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
17538printf %s "checking for dlopen in -ldl... " >&6; }
17539if test ${ac_cv_lib_dl_dlopen+y}
17540then :
17541 printf %s "(cached) " >&6
17542else case e in #(
17543 e) ac_check_lib_save_LIBS=$LIBS
17544LIBS="-ldl $LIBS"
17545cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17546/* end confdefs.h. */
17547
17548/* Override any GCC internal prototype to avoid an error.
17549 Use char because int might match the return type of a GCC
17550 builtin and then its argument prototype would still apply.
17551 The 'extern "C"' is for builds by C++ compilers;
17552 although this is not generally supported in C code supporting it here
17553 has little cost and some practical benefit (sr 110532). */
17554#ifdef __cplusplus
17555extern "C"
17556#endif
17557char dlopen (void);
17558int
17559main (void)
17560{
17561return dlopen ();
17562 ;
17563 return 0;
17564}
17565_ACEOF
17566if ac_fn_c_try_link "$LINENO"
17567then :
17568 ac_cv_lib_dl_dlopen=yes
17569else case e in #(
17570 e) ac_cv_lib_dl_dlopen=no ;;
17571esac
17572fi
17573rm -f core conftest.err conftest.$ac_objext conftest.beam \
17574 conftest$ac_exeext conftest.$ac_ext
17575LIBS=$ac_check_lib_save_LIBS ;;
17576esac
17577fi
17578{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
17579printf "%s\n" "$ac_cv_lib_dl_dlopen" >&6; }
17580if test "x$ac_cv_lib_dl_dlopen" = xyes
17581then :
17582 printf "%s\n" "#define HAVE_LIBDL 1" >>confdefs.h
17583
17584 LIBS="-ldl $LIBS"
17585
17586fi
17587
17588ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen"
17589if test "x$ac_cv_func_dlopen" = xyes
17590then :
17591 printf "%s\n" "#define HAVE_DLOPEN 1" >>confdefs.h
17592
17593fi
17594ac_fn_c_check_func "$LINENO" "dlclose" "ac_cv_func_dlclose"
17595if test "x$ac_cv_func_dlclose" = xyes
17596then :
17597 printf "%s\n" "#define HAVE_DLCLOSE 1" >>confdefs.h
17598
17599fi
17600ac_fn_c_check_func "$LINENO" "dlsym" "ac_cv_func_dlsym"
17601if test "x$ac_cv_func_dlsym" = xyes
17602then :
17603 printf "%s\n" "#define HAVE_DLSYM 1" >>confdefs.h
17604
17605fi
17606
17607fi
17608
17609if test "$ac_cv_func_inet_aton" != 'yes'; then
17610
17611{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5
17612printf %s "checking for inet_aton... " >&6; }
17613if test ${bash_cv_func_inet_aton+y}
17614then :
17615 printf %s "(cached) " >&6
17616else case e in #(
17617 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17618/* end confdefs.h. */
17619
17620#include <sys/types.h>
17621#include <netinet/in.h>
17622#include <arpa/inet.h>
17623struct in_addr ap;
17624int
17625main (void)
17626{
17627 inet_aton("127.0.0.1", &ap);
17628 ;
17629 return 0;
17630}
17631_ACEOF
17632if ac_fn_c_try_link "$LINENO"
17633then :
17634 bash_cv_func_inet_aton=yes
17635else case e in #(
17636 e) bash_cv_func_inet_aton=no ;;
17637esac
17638fi
17639rm -f core conftest.err conftest.$ac_objext conftest.beam \
17640 conftest$ac_exeext conftest.$ac_ext ;;
17641esac
17642fi
17643{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_inet_aton" >&5
17644printf "%s\n" "$bash_cv_func_inet_aton" >&6; }
17645if test $bash_cv_func_inet_aton = yes; then
17646 printf "%s\n" "#define HAVE_INET_ATON 1" >>confdefs.h
17647
17648else
17649 case " $LIBOBJS " in
17650 *" inet_aton.$ac_objext "* ) ;;
17651 *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext"
17652 ;;
17653esac
17654
17655fi
17656
17657fi
17658
17659case "$host_os" in
17660irix4*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getpwent in -lsun" >&5
17661printf %s "checking for getpwent in -lsun... " >&6; }
17662if test ${ac_cv_lib_sun_getpwent+y}
17663then :
17664 printf %s "(cached) " >&6
17665else case e in #(
17666 e) ac_check_lib_save_LIBS=$LIBS
17667LIBS="-lsun $LIBS"
17668cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17669/* end confdefs.h. */
17670
17671/* Override any GCC internal prototype to avoid an error.
17672 Use char because int might match the return type of a GCC
17673 builtin and then its argument prototype would still apply.
17674 The 'extern "C"' is for builds by C++ compilers;
17675 although this is not generally supported in C code supporting it here
17676 has little cost and some practical benefit (sr 110532). */
17677#ifdef __cplusplus
17678extern "C"
17679#endif
17680char getpwent (void);
17681int
17682main (void)
17683{
17684return getpwent ();
17685 ;
17686 return 0;
17687}
17688_ACEOF
17689if ac_fn_c_try_link "$LINENO"
17690then :
17691 ac_cv_lib_sun_getpwent=yes
17692else case e in #(
17693 e) ac_cv_lib_sun_getpwent=no ;;
17694esac
17695fi
17696rm -f core conftest.err conftest.$ac_objext conftest.beam \
17697 conftest$ac_exeext conftest.$ac_ext
17698LIBS=$ac_check_lib_save_LIBS ;;
17699esac
17700fi
17701{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sun_getpwent" >&5
17702printf "%s\n" "$ac_cv_lib_sun_getpwent" >&6; }
17703if test "x$ac_cv_lib_sun_getpwent" = xyes
17704then :
17705 printf "%s\n" "#define HAVE_LIBSUN 1" >>confdefs.h
17706
17707 LIBS="-lsun $LIBS"
17708
17709fi
17710 ;;
17711esac
17712
17713if test "$ac_cv_func_getpeername" = no; then
17714
17715if test "X$bash_cv_have_socklib" = "X"; then
17716_bash_needmsg=
17717else
17718{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socket library" >&5
17719printf %s "checking for socket library... " >&6; }
17720_bash_needmsg=yes
17721fi
17722if test ${bash_cv_have_socklib+y}
17723then :
17724 printf %s "(cached) " >&6
17725else case e in #(
17726 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for getpeername in -lsocket" >&5
17727printf %s "checking for getpeername in -lsocket... " >&6; }
17728if test ${ac_cv_lib_socket_getpeername+y}
17729then :
17730 printf %s "(cached) " >&6
17731else case e in #(
17732 e) ac_check_lib_save_LIBS=$LIBS
17733LIBS="-lsocket -lnsl $LIBS"
17734cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17735/* end confdefs.h. */
17736
17737/* Override any GCC internal prototype to avoid an error.
17738 Use char because int might match the return type of a GCC
17739 builtin and then its argument prototype would still apply.
17740 The 'extern "C"' is for builds by C++ compilers;
17741 although this is not generally supported in C code supporting it here
17742 has little cost and some practical benefit (sr 110532). */
17743#ifdef __cplusplus
17744extern "C"
17745#endif
17746char getpeername (void);
17747int
17748main (void)
17749{
17750return getpeername ();
17751 ;
17752 return 0;
17753}
17754_ACEOF
17755if ac_fn_c_try_link "$LINENO"
17756then :
17757 ac_cv_lib_socket_getpeername=yes
17758else case e in #(
17759 e) ac_cv_lib_socket_getpeername=no ;;
17760esac
17761fi
17762rm -f core conftest.err conftest.$ac_objext conftest.beam \
17763 conftest$ac_exeext conftest.$ac_ext
17764LIBS=$ac_check_lib_save_LIBS ;;
17765esac
17766fi
17767{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getpeername" >&5
17768printf "%s\n" "$ac_cv_lib_socket_getpeername" >&6; }
17769if test "x$ac_cv_lib_socket_getpeername" = xyes
17770then :
17771 bash_cv_have_socklib=yes
17772else case e in #(
17773 e) bash_cv_have_socklib=no ;;
17774esac
17775fi
17776 ;;
17777esac
17778fi
17779
17780if test "X$_bash_needmsg" = Xyes; then
17781 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_socklib" >&5
17782printf "%s\n" "$bash_cv_have_socklib" >&6; }
17783 _bash_needmsg=
17784fi
17785if test $bash_cv_have_socklib = yes; then
17786 # check for libnsl, add it to LIBS if present
17787 if test "X$bash_cv_have_libnsl" = "X"; then
17788 _bash_needmsg=
17789 else
17790 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for libnsl" >&5
17791printf %s "checking for libnsl... " >&6; }
17792 _bash_needmsg=yes
17793 fi
17794 if test ${bash_cv_have_libnsl+y}
17795then :
17796 printf %s "(cached) " >&6
17797else case e in #(
17798 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5
17799printf %s "checking for t_open in -lnsl... " >&6; }
17800if test ${ac_cv_lib_nsl_t_open+y}
17801then :
17802 printf %s "(cached) " >&6
17803else case e in #(
17804 e) ac_check_lib_save_LIBS=$LIBS
17805LIBS="-lnsl $LIBS"
17806cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17807/* end confdefs.h. */
17808
17809/* Override any GCC internal prototype to avoid an error.
17810 Use char because int might match the return type of a GCC
17811 builtin and then its argument prototype would still apply.
17812 The 'extern "C"' is for builds by C++ compilers;
17813 although this is not generally supported in C code supporting it here
17814 has little cost and some practical benefit (sr 110532). */
17815#ifdef __cplusplus
17816extern "C"
17817#endif
17818char t_open (void);
17819int
17820main (void)
17821{
17822return t_open ();
17823 ;
17824 return 0;
17825}
17826_ACEOF
17827if ac_fn_c_try_link "$LINENO"
17828then :
17829 ac_cv_lib_nsl_t_open=yes
17830else case e in #(
17831 e) ac_cv_lib_nsl_t_open=no ;;
17832esac
17833fi
17834rm -f core conftest.err conftest.$ac_objext conftest.beam \
17835 conftest$ac_exeext conftest.$ac_ext
17836LIBS=$ac_check_lib_save_LIBS ;;
17837esac
17838fi
17839{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5
17840printf "%s\n" "$ac_cv_lib_nsl_t_open" >&6; }
17841if test "x$ac_cv_lib_nsl_t_open" = xyes
17842then :
17843 bash_cv_have_libnsl=yes
17844else case e in #(
17845 e) bash_cv_have_libnsl=no ;;
17846esac
17847fi
17848 ;;
17849esac
17850fi
17851
17852 if test "X$_bash_needmsg" = Xyes; then
17853 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_libnsl" >&5
17854printf "%s\n" "$bash_cv_have_libnsl" >&6; }
17855 _bash_needmsg=
17856 fi
17857 if test $bash_cv_have_libnsl = yes; then
17858 LIBS="-lsocket -lnsl $LIBS"
17859 else
17860 LIBS="-lsocket $LIBS"
17861 fi
17862 printf "%s\n" "#define HAVE_LIBSOCKET 1" >>confdefs.h
17863
17864 printf "%s\n" "#define HAVE_GETPEERNAME 1" >>confdefs.h
17865
17866fi
17867
17868fi
17869if test "$ac_cv_func_gethostbyname" = no; then
17870 if test "X$bash_cv_have_gethostbyname" = "X"; then
17871_bash_needmsg=yes
17872else
17873{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5
17874printf %s "checking for gethostbyname in socket library... " >&6; }
17875_bash_needmsg=
17876fi
17877if test ${bash_cv_have_gethostbyname+y}
17878then :
17879 printf %s "(cached) " >&6
17880else case e in #(
17881 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17882/* end confdefs.h. */
17883
17884#include <netdb.h>
17885
17886int
17887main (void)
17888{
17889
17890struct hostent *hp;
17891hp = gethostbyname("localhost");
17892
17893 ;
17894 return 0;
17895}
17896_ACEOF
17897if ac_fn_c_try_link "$LINENO"
17898then :
17899 bash_cv_have_gethostbyname=yes
17900else case e in #(
17901 e) bash_cv_have_gethostbyname=no
17902 ;;
17903esac
17904fi
17905rm -f core conftest.err conftest.$ac_objext conftest.beam \
17906 conftest$ac_exeext conftest.$ac_ext ;;
17907esac
17908fi
17909
17910if test "X$_bash_needmsg" = Xyes; then
17911 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5
17912printf %s "checking for gethostbyname in socket library... " >&6; }
17913fi
17914{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_gethostbyname" >&5
17915printf "%s\n" "$bash_cv_have_gethostbyname" >&6; }
17916if test "$bash_cv_have_gethostbyname" = yes; then
17917printf "%s\n" "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h
17918
17919fi
17920
17921fi
17922
17923{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5
17924printf %s "checking type of array argument to getgroups... " >&6; }
17925if test ${ac_cv_type_getgroups+y}
17926then :
17927 printf %s "(cached) " >&6
17928else case e in #(
17929 e) # If AC_TYPE_UID_T says there isn't any gid_t typedef, then we can skip
17930# everything below.
17931if test $ac_cv_type_gid_t = no
17932then :
17933 ac_cv_type_getgroups=int
17934else case e in #(
17935 e) # Test programs below rely on strict type checking of extern declarations:
17936 # 'extern int getgroups(int, int *); extern int getgroups(int, pid_t *);'
17937 # is valid in C89 if and only if pid_t is a typedef for int. Unlike
17938 # anything involving either an assignment or a function call, compilers
17939 # tend to make this kind of type mismatch a hard error, not just an
17940 # "incompatible pointer types" warning.
17941 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17942/* end confdefs.h. */
17943$ac_includes_default
17944extern int getgroups(int, gid_t *);
17945int
17946main (void)
17947{
17948return !(getgroups(0, 0) >= 0);
17949 ;
17950 return 0;
17951}
17952_ACEOF
17953if ac_fn_c_try_compile "$LINENO"
17954then :
17955 ac_getgroups_gidarray=yes
17956else case e in #(
17957 e) ac_getgroups_gidarray=no ;;
17958esac
17959fi
17960rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17961 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17962/* end confdefs.h. */
17963$ac_includes_default
17964extern int getgroups(int, int *);
17965int
17966main (void)
17967{
17968return !(getgroups(0, 0) >= 0);
17969 ;
17970 return 0;
17971}
17972_ACEOF
17973if ac_fn_c_try_compile "$LINENO"
17974then :
17975 ac_getgroups_intarray=yes
17976else case e in #(
17977 e) ac_getgroups_intarray=no ;;
17978esac
17979fi
17980rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
17981
17982 case int:$ac_getgroups_intarray,gid:$ac_getgroups_gidarray in #(
17983 int:yes,gid:no) :
17984 ac_cv_type_getgroups=int ;; #(
17985 int:no,gid:yes) :
17986 ac_cv_type_getgroups=gid_t ;; #(
17987 int:yes,gid:yes) :
17988
17989 # Both programs compiled - this means *either* that getgroups
17990 # was declared with no prototype, in which case we should use int,
17991 # or that it was declared prototyped but gid_t is a typedef for int,
17992 # in which case we should use gid_t. Distinguish the two cases
17993 # by testing if the compiler catches a blatantly incorrect function
17994 # signature for getgroups.
17995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
17996/* end confdefs.h. */
17997$ac_includes_default
17998extern int getgroups(int, float);
17999int
18000main (void)
18001{
18002return !(getgroups(0, 0) >= 0);
18003 ;
18004 return 0;
18005}
18006_ACEOF
18007if ac_fn_c_try_compile "$LINENO"
18008then :
18009
18010 # Compiler did not catch incorrect argument list;
18011 # getgroups is unprototyped.
18012 ac_cv_type_getgroups=int
18013
18014else case e in #(
18015 e)
18016 # Compiler caught incorrect argument list;
18017 # gid_t is a typedef for int.
18018 ac_cv_type_getgroups=gid_t
18019 ;;
18020esac
18021fi
18022rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18023 ;; #(
18024 *) :
18025
18026 # Both programs failed to compile - this probably means getgroups
18027 # wasn't declared at all. Use 'int', as this is probably a very
18028 # old system where the type _would have been_ int.
18029 ac_cv_type_getgroups=int
18030 ;;
18031esac
18032 ;;
18033esac
18034fi
18035 ;;
18036esac
18037fi
18038{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5
18039printf "%s\n" "$ac_cv_type_getgroups" >&6; }
18040printf "%s\n" "#define GETGROUPS_T $ac_cv_type_getgroups" >>confdefs.h
18041
18042
18043ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default"
18044if test "x$ac_cv_type_off_t" = xyes
18045then :
18046
18047else case e in #(
18048 e)
18049printf "%s\n" "#define off_t long int" >>confdefs.h
18050 ;;
18051esac
18052fi
18053
18054ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default"
18055if test "x$ac_cv_type_mode_t" = xyes
18056then :
18057
18058else case e in #(
18059 e)
18060printf "%s\n" "#define mode_t int" >>confdefs.h
18061 ;;
18062esac
18063fi
18064
18065ac_fn_c_check_type "$LINENO" "uid_t" "ac_cv_type_uid_t" "$ac_includes_default"
18066if test "x$ac_cv_type_uid_t" = xyes
18067then :
18068
18069else case e in #(
18070 e)
18071printf "%s\n" "#define uid_t int" >>confdefs.h
18072 ;;
18073esac
18074fi
18075
18076ac_fn_c_check_type "$LINENO" "gid_t" "ac_cv_type_gid_t" "$ac_includes_default"
18077if test "x$ac_cv_type_gid_t" = xyes
18078then :
18079
18080else case e in #(
18081 e)
18082printf "%s\n" "#define gid_t int" >>confdefs.h
18083 ;;
18084esac
18085fi
18086
18087
18088 ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default
18089"
18090if test "x$ac_cv_type_pid_t" = xyes
18091then :
18092
18093else case e in #(
18094 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18095/* end confdefs.h. */
18096
18097 #if defined _WIN64 && !defined __CYGWIN__
18098 LLP64
18099 #endif
18100
18101int
18102main (void)
18103{
18104
18105 ;
18106 return 0;
18107}
18108
18109_ACEOF
18110if ac_fn_c_try_compile "$LINENO"
18111then :
18112 ac_pid_type='int'
18113else case e in #(
18114 e) ac_pid_type='__int64' ;;
18115esac
18116fi
18117rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18118
18119printf "%s\n" "#define pid_t $ac_pid_type" >>confdefs.h
18120
18121 ;;
18122esac
18123fi
18124
18125
18126ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default"
18127if test "x$ac_cv_type_size_t" = xyes
18128then :
18129
18130else case e in #(
18131 e)
18132printf "%s\n" "#define size_t unsigned int" >>confdefs.h
18133 ;;
18134esac
18135fi
18136
18137
18138 ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default"
18139if test "x$ac_cv_type_intptr_t" = xyes
18140then :
18141
18142printf "%s\n" "#define HAVE_INTPTR_T 1" >>confdefs.h
18143
18144else case e in #(
18145 e) for ac_type in 'int' 'long int' 'long long int'; do
18146 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18147/* end confdefs.h. */
18148$ac_includes_default
18149int
18150main (void)
18151{
18152static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
18153test_array [0] = 0;
18154return test_array [0];
18155
18156 ;
18157 return 0;
18158}
18159_ACEOF
18160if ac_fn_c_try_compile "$LINENO"
18161then :
18162
18163printf "%s\n" "#define intptr_t $ac_type" >>confdefs.h
18164
18165 ac_type=
18166fi
18167rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18168 test -z "$ac_type" && break
18169 done ;;
18170esac
18171fi
18172
18173
18174
18175 ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default"
18176if test "x$ac_cv_type_uintptr_t" = xyes
18177then :
18178
18179printf "%s\n" "#define HAVE_UINTPTR_T 1" >>confdefs.h
18180
18181else case e in #(
18182 e) for ac_type in 'unsigned int' 'unsigned long int' \
18183 'unsigned long long int'; do
18184 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18185/* end confdefs.h. */
18186$ac_includes_default
18187int
18188main (void)
18189{
18190static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
18191test_array [0] = 0;
18192return test_array [0];
18193
18194 ;
18195 return 0;
18196}
18197_ACEOF
18198if ac_fn_c_try_compile "$LINENO"
18199then :
18200
18201printf "%s\n" "#define uintptr_t $ac_type" >>confdefs.h
18202
18203 ac_type=
18204fi
18205rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
18206 test -z "$ac_type" && break
18207 done ;;
18208esac
18209fi
18210
18211
18212
18213ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default"
18214if test "x$ac_cv_type_ssize_t" = xyes
18215then :
18216
18217else case e in #(
18218 e)
18219printf "%s\n" "#define ssize_t int" >>confdefs.h
18220 ;;
18221esac
18222fi
18223
18224ac_fn_c_check_type "$LINENO" "time_t" "ac_cv_type_time_t" "$ac_includes_default"
18225if test "x$ac_cv_type_time_t" = xyes
18226then :
18227
18228else case e in #(
18229 e)
18230printf "%s\n" "#define time_t long" >>confdefs.h
18231 ;;
18232esac
18233fi
18234
18235
18236
18237
18238 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5
18239printf %s "checking for long long int... " >&6; }
18240if test ${ac_cv_type_long_long_int+y}
18241then :
18242 printf %s "(cached) " >&6
18243else case e in #(
18244 e) ac_cv_type_long_long_int=yes
18245 case $ac_prog_cc_stdc in
18246 no | c89) ;;
18247 *)
18248 ac_cv_type_long_long_int=$ac_cv_type_unsigned_long_long_int
18249 if test $ac_cv_type_long_long_int = yes; then
18250 if test "$cross_compiling" = yes
18251then :
18252 :
18253else case e in #(
18254 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18255/* end confdefs.h. */
18256#include <limits.h>
18257 #ifndef LLONG_MAX
18258 # define HALF \\
18259 (1LL << (sizeof (long long int) * CHAR_BIT - 2))
18260 # define LLONG_MAX (HALF - 1 + HALF)
18261 #endif
18262int
18263main (void)
18264{
18265long long int n = 1;
18266 int i;
18267 for (i = 0; ; i++)
18268 {
18269 long long int m = n << i;
18270 if (m >> i != n)
18271 return 1;
18272 if (LLONG_MAX / 2 < m)
18273 break;
18274 }
18275 return 0;
18276 ;
18277 return 0;
18278}
18279_ACEOF
18280if ac_fn_c_try_run "$LINENO"
18281then :
18282
18283else case e in #(
18284 e) ac_cv_type_long_long_int=no ;;
18285esac
18286fi
18287rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
18288 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
18289esac
18290fi
18291
18292 fi;;
18293 esac ;;
18294esac
18295fi
18296{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5
18297printf "%s\n" "$ac_cv_type_long_long_int" >&6; }
18298 if test $ac_cv_type_long_long_int = yes; then
18299
18300printf "%s\n" "#define HAVE_LONG_LONG_INT 1" >>confdefs.h
18301
18302 fi
18303
18304
18305 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5
18306printf %s "checking for unsigned long long int... " >&6; }
18307if test ${ac_cv_type_unsigned_long_long_int+y}
18308then :
18309 printf %s "(cached) " >&6
18310else case e in #(
18311 e) ac_cv_type_unsigned_long_long_int=yes
18312 case $ac_prog_cc_stdc in
18313 no | c89) ;;
18314 *)
18315 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18316/* end confdefs.h. */
18317
18318 /* For now, do not test the preprocessor; as of 2007 there are too many
18319 implementations with broken preprocessors. Perhaps this can
18320 be revisited in 2012. In the meantime, code should not expect
18321 #if to work with literals wider than 32 bits. */
18322 /* Test literals. */
18323 long long int ll = 9223372036854775807ll;
18324 long long int nll = -9223372036854775807LL;
18325 unsigned long long int ull = 18446744073709551615ULL;
18326 /* Test constant expressions. */
18327 typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
18328 ? 1 : -1)];
18329 typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
18330 ? 1 : -1)];
18331 int i = 63;
18332int
18333main (void)
18334{
18335/* Test availability of runtime routines for shift and division. */
18336 long long int llmax = 9223372036854775807ll;
18337 unsigned long long int ullmax = 18446744073709551615ull;
18338 return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
18339 | (llmax / ll) | (llmax % ll)
18340 | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
18341 | (ullmax / ull) | (ullmax % ull));
18342 ;
18343 return 0;
18344}
18345
18346_ACEOF
18347if ac_fn_c_try_link "$LINENO"
18348then :
18349
18350else case e in #(
18351 e) ac_cv_type_unsigned_long_long_int=no ;;
18352esac
18353fi
18354rm -f core conftest.err conftest.$ac_objext conftest.beam \
18355 conftest$ac_exeext conftest.$ac_ext;;
18356 esac ;;
18357esac
18358fi
18359{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5
18360printf "%s\n" "$ac_cv_type_unsigned_long_long_int" >&6; }
18361 if test $ac_cv_type_unsigned_long_long_int = yes; then
18362
18363printf "%s\n" "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h
18364
18365 fi
18366
18367
18368{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t in signal.h" >&5
18369printf %s "checking for sig_atomic_t in signal.h... " >&6; }
18370if test ${ac_cv_have_sig_atomic_t+y}
18371then :
18372 printf %s "(cached) " >&6
18373else case e in #(
18374 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18375/* end confdefs.h. */
18376 #include <signal.h>
18377int
18378main (void)
18379{
18380 sig_atomic_t x;
18381 ;
18382 return 0;
18383}
18384_ACEOF
18385if ac_fn_c_try_link "$LINENO"
18386then :
18387 ac_cv_have_sig_atomic_t=yes
18388else case e in #(
18389 e) ac_cv_have_sig_atomic_t=no ;;
18390esac
18391fi
18392rm -f core conftest.err conftest.$ac_objext conftest.beam \
18393 conftest$ac_exeext conftest.$ac_ext ;;
18394esac
18395fi
18396{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sig_atomic_t" >&5
18397printf "%s\n" "$ac_cv_have_sig_atomic_t" >&6; }
18398if test "$ac_cv_have_sig_atomic_t" = "no"
18399then
18400
18401
18402{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t" >&5
18403printf %s "checking for sig_atomic_t... " >&6; }
18404if test ${bash_cv_type_sig_atomic_t+y}
18405then :
18406 printf %s "(cached) " >&6
18407else case e in #(
18408 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
18409/* end confdefs.h. */
18410#include <sys/types.h>
18411#if HAVE_STDLIB_H
18412#include <stdlib.h>
18413#endif
18414#if HAVE_STDDEF_H
18415#include <stddef.h>
18416#endif
18417#if HAVE_INTTYPES_H
18418#include <inttypes.h>
18419#endif
18420#if HAVE_STDINT_H
18421#include <stdint.h>
18422#endif
18423#include <signal.h>
18424
18425_ACEOF
18426if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
18427 $EGREP_TRADITIONAL "sig_atomic_t" >/dev/null 2>&1
18428then :
18429 bash_cv_type_sig_atomic_t=yes
18430else case e in #(
18431 e) bash_cv_type_sig_atomic_t=no ;;
18432esac
18433fi
18434rm -rf conftest*
18435 ;;
18436esac
18437fi
18438
18439{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sig_atomic_t" >&5
18440printf "%s\n" "$bash_cv_type_sig_atomic_t" >&6; }
18441
18442if test $bash_cv_type_sig_atomic_t = no; then
18443 printf "%s\n" "#define sig_atomic_t int" >>confdefs.h
18444
18445fi
18446
18447fi
18448
18449
18450# The cast to long int works around a bug in the HP C Compiler
18451# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18452# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18453# This bug is HP SR number 8606223364.
18454{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of char" >&5
18455printf %s "checking size of char... " >&6; }
18456if test ${ac_cv_sizeof_char+y}
18457then :
18458 printf %s "(cached) " >&6
18459else case e in #(
18460 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char))" "ac_cv_sizeof_char" "$ac_includes_default"
18461then :
18462
18463else case e in #(
18464 e) if test "$ac_cv_type_char" = yes; then
18465 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18466printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18467as_fn_error 77 "cannot compute sizeof (char)
18468See 'config.log' for more details" "$LINENO" 5; }
18469 else
18470 ac_cv_sizeof_char=0
18471 fi ;;
18472esac
18473fi
18474 ;;
18475esac
18476fi
18477{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char" >&5
18478printf "%s\n" "$ac_cv_sizeof_char" >&6; }
18479
18480
18481
18482printf "%s\n" "#define SIZEOF_CHAR $ac_cv_sizeof_char" >>confdefs.h
18483
18484
18485# The cast to long int works around a bug in the HP C Compiler
18486# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18487# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18488# This bug is HP SR number 8606223364.
18489{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of short" >&5
18490printf %s "checking size of short... " >&6; }
18491if test ${ac_cv_sizeof_short+y}
18492then :
18493 printf %s "(cached) " >&6
18494else case e in #(
18495 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"
18496then :
18497
18498else case e in #(
18499 e) if test "$ac_cv_type_short" = yes; then
18500 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18501printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18502as_fn_error 77 "cannot compute sizeof (short)
18503See 'config.log' for more details" "$LINENO" 5; }
18504 else
18505 ac_cv_sizeof_short=0
18506 fi ;;
18507esac
18508fi
18509 ;;
18510esac
18511fi
18512{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5
18513printf "%s\n" "$ac_cv_sizeof_short" >&6; }
18514
18515
18516
18517printf "%s\n" "#define SIZEOF_SHORT $ac_cv_sizeof_short" >>confdefs.h
18518
18519
18520# The cast to long int works around a bug in the HP C Compiler
18521# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18522# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18523# This bug is HP SR number 8606223364.
18524{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
18525printf %s "checking size of int... " >&6; }
18526if test ${ac_cv_sizeof_int+y}
18527then :
18528 printf %s "(cached) " >&6
18529else case e in #(
18530 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"
18531then :
18532
18533else case e in #(
18534 e) if test "$ac_cv_type_int" = yes; then
18535 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18536printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18537as_fn_error 77 "cannot compute sizeof (int)
18538See 'config.log' for more details" "$LINENO" 5; }
18539 else
18540 ac_cv_sizeof_int=0
18541 fi ;;
18542esac
18543fi
18544 ;;
18545esac
18546fi
18547{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
18548printf "%s\n" "$ac_cv_sizeof_int" >&6; }
18549
18550
18551
18552printf "%s\n" "#define SIZEOF_INT $ac_cv_sizeof_int" >>confdefs.h
18553
18554
18555# The cast to long int works around a bug in the HP C Compiler
18556# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18557# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18558# This bug is HP SR number 8606223364.
18559{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long" >&5
18560printf %s "checking size of long... " >&6; }
18561if test ${ac_cv_sizeof_long+y}
18562then :
18563 printf %s "(cached) " >&6
18564else case e in #(
18565 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"
18566then :
18567
18568else case e in #(
18569 e) if test "$ac_cv_type_long" = yes; then
18570 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18571printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18572as_fn_error 77 "cannot compute sizeof (long)
18573See 'config.log' for more details" "$LINENO" 5; }
18574 else
18575 ac_cv_sizeof_long=0
18576 fi ;;
18577esac
18578fi
18579 ;;
18580esac
18581fi
18582{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5
18583printf "%s\n" "$ac_cv_sizeof_long" >&6; }
18584
18585
18586
18587printf "%s\n" "#define SIZEOF_LONG $ac_cv_sizeof_long" >>confdefs.h
18588
18589
18590# The cast to long int works around a bug in the HP C Compiler
18591# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18592# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18593# This bug is HP SR number 8606223364.
18594{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5
18595printf %s "checking size of char *... " >&6; }
18596if test ${ac_cv_sizeof_char_p+y}
18597then :
18598 printf %s "(cached) " >&6
18599else case e in #(
18600 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"
18601then :
18602
18603else case e in #(
18604 e) if test "$ac_cv_type_char_p" = yes; then
18605 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18606printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18607as_fn_error 77 "cannot compute sizeof (char *)
18608See 'config.log' for more details" "$LINENO" 5; }
18609 else
18610 ac_cv_sizeof_char_p=0
18611 fi ;;
18612esac
18613fi
18614 ;;
18615esac
18616fi
18617{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5
18618printf "%s\n" "$ac_cv_sizeof_char_p" >&6; }
18619
18620
18621
18622printf "%s\n" "#define SIZEOF_CHAR_P $ac_cv_sizeof_char_p" >>confdefs.h
18623
18624
18625# The cast to long int works around a bug in the HP C Compiler
18626# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18627# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18628# This bug is HP SR number 8606223364.
18629{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5
18630printf %s "checking size of size_t... " >&6; }
18631if test ${ac_cv_sizeof_size_t+y}
18632then :
18633 printf %s "(cached) " >&6
18634else case e in #(
18635 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"
18636then :
18637
18638else case e in #(
18639 e) if test "$ac_cv_type_size_t" = yes; then
18640 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18641printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18642as_fn_error 77 "cannot compute sizeof (size_t)
18643See 'config.log' for more details" "$LINENO" 5; }
18644 else
18645 ac_cv_sizeof_size_t=0
18646 fi ;;
18647esac
18648fi
18649 ;;
18650esac
18651fi
18652{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5
18653printf "%s\n" "$ac_cv_sizeof_size_t" >&6; }
18654
18655
18656
18657printf "%s\n" "#define SIZEOF_SIZE_T $ac_cv_sizeof_size_t" >>confdefs.h
18658
18659
18660# The cast to long int works around a bug in the HP C Compiler
18661# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18662# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18663# This bug is HP SR number 8606223364.
18664{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of double" >&5
18665printf %s "checking size of double... " >&6; }
18666if test ${ac_cv_sizeof_double+y}
18667then :
18668 printf %s "(cached) " >&6
18669else case e in #(
18670 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"
18671then :
18672
18673else case e in #(
18674 e) if test "$ac_cv_type_double" = yes; then
18675 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18676printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18677as_fn_error 77 "cannot compute sizeof (double)
18678See 'config.log' for more details" "$LINENO" 5; }
18679 else
18680 ac_cv_sizeof_double=0
18681 fi ;;
18682esac
18683fi
18684 ;;
18685esac
18686fi
18687{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5
18688printf "%s\n" "$ac_cv_sizeof_double" >&6; }
18689
18690
18691
18692printf "%s\n" "#define SIZEOF_DOUBLE $ac_cv_sizeof_double" >>confdefs.h
18693
18694
18695# The cast to long int works around a bug in the HP C Compiler
18696# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18697# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
18698# This bug is HP SR number 8606223364.
18699{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5
18700printf %s "checking size of long long... " >&6; }
18701if test ${ac_cv_sizeof_long_long+y}
18702then :
18703 printf %s "(cached) " >&6
18704else case e in #(
18705 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"
18706then :
18707
18708else case e in #(
18709 e) if test "$ac_cv_type_long_long" = yes; then
18710 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
18711printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
18712as_fn_error 77 "cannot compute sizeof (long long)
18713See 'config.log' for more details" "$LINENO" 5; }
18714 else
18715 ac_cv_sizeof_long_long=0
18716 fi ;;
18717esac
18718fi
18719 ;;
18720esac
18721fi
18722{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5
18723printf "%s\n" "$ac_cv_sizeof_long_long" >&6; }
18724
18725
18726
18727printf "%s\n" "#define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long" >>confdefs.h
18728
18729
18730
18731
18732if test "$ac_cv_sizeof_short" = 2; then
18733 ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default"
18734if test "x$ac_cv_type_bits16_t" = xyes
18735then :
18736
18737else case e in #(
18738 e)
18739printf "%s\n" "#define bits16_t short" >>confdefs.h
18740 ;;
18741esac
18742fi
18743
18744elif test "$ac_cv_sizeof_char" = 2; then
18745 ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default"
18746if test "x$ac_cv_type_bits16_t" = xyes
18747then :
18748
18749else case e in #(
18750 e)
18751printf "%s\n" "#define bits16_t char" >>confdefs.h
18752 ;;
18753esac
18754fi
18755
18756else
18757 ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default"
18758if test "x$ac_cv_type_bits16_t" = xyes
18759then :
18760
18761else case e in #(
18762 e)
18763printf "%s\n" "#define bits16_t short" >>confdefs.h
18764 ;;
18765esac
18766fi
18767
18768fi
18769
18770
18771if test "$ac_cv_sizeof_short" = 2; then
18772 ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default"
18773if test "x$ac_cv_type_u_bits16_t" = xyes
18774then :
18775
18776else case e in #(
18777 e)
18778printf "%s\n" "#define u_bits16_t unsigned short" >>confdefs.h
18779 ;;
18780esac
18781fi
18782
18783elif test "$ac_cv_sizeof_char" = 2; then
18784 ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default"
18785if test "x$ac_cv_type_u_bits16_t" = xyes
18786then :
18787
18788else case e in #(
18789 e)
18790printf "%s\n" "#define u_bits16_t unsigned char" >>confdefs.h
18791 ;;
18792esac
18793fi
18794
18795else
18796 ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default"
18797if test "x$ac_cv_type_u_bits16_t" = xyes
18798then :
18799
18800else case e in #(
18801 e)
18802printf "%s\n" "#define u_bits16_t unsigned short" >>confdefs.h
18803 ;;
18804esac
18805fi
18806
18807fi
18808
18809
18810if test "$ac_cv_sizeof_int" = 4; then
18811 ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default"
18812if test "x$ac_cv_type_bits32_t" = xyes
18813then :
18814
18815else case e in #(
18816 e)
18817printf "%s\n" "#define bits32_t int" >>confdefs.h
18818 ;;
18819esac
18820fi
18821
18822elif test "$ac_cv_sizeof_long" = 4; then
18823 ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default"
18824if test "x$ac_cv_type_bits32_t" = xyes
18825then :
18826
18827else case e in #(
18828 e)
18829printf "%s\n" "#define bits32_t long" >>confdefs.h
18830 ;;
18831esac
18832fi
18833
18834else
18835 ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default"
18836if test "x$ac_cv_type_bits32_t" = xyes
18837then :
18838
18839else case e in #(
18840 e)
18841printf "%s\n" "#define bits32_t int" >>confdefs.h
18842 ;;
18843esac
18844fi
18845
18846fi
18847
18848
18849if test "$ac_cv_sizeof_int" = 4; then
18850 ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default"
18851if test "x$ac_cv_type_u_bits32_t" = xyes
18852then :
18853
18854else case e in #(
18855 e)
18856printf "%s\n" "#define u_bits32_t unsigned int" >>confdefs.h
18857 ;;
18858esac
18859fi
18860
18861elif test "$ac_cv_sizeof_long" = 4; then
18862 ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default"
18863if test "x$ac_cv_type_u_bits32_t" = xyes
18864then :
18865
18866else case e in #(
18867 e)
18868printf "%s\n" "#define u_bits32_t unsigned long" >>confdefs.h
18869 ;;
18870esac
18871fi
18872
18873else
18874 ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default"
18875if test "x$ac_cv_type_u_bits32_t" = xyes
18876then :
18877
18878else case e in #(
18879 e)
18880printf "%s\n" "#define u_bits32_t unsigned int" >>confdefs.h
18881 ;;
18882esac
18883fi
18884
18885fi
18886
18887
18888if test "$ac_cv_sizeof_char_p" = 8; then
18889 ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default"
18890if test "x$ac_cv_type_bits64_t" = xyes
18891then :
18892
18893else case e in #(
18894 e)
18895printf "%s\n" "#define bits64_t char *" >>confdefs.h
18896 ;;
18897esac
18898fi
18899
18900elif test "$ac_cv_sizeof_double" = 8; then
18901 ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default"
18902if test "x$ac_cv_type_bits64_t" = xyes
18903then :
18904
18905else case e in #(
18906 e)
18907printf "%s\n" "#define bits64_t double" >>confdefs.h
18908 ;;
18909esac
18910fi
18911
18912elif test -n "$ac_cv_type_long_long" && test "$ac_cv_sizeof_long_long" = 8; then
18913 ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default"
18914if test "x$ac_cv_type_bits64_t" = xyes
18915then :
18916
18917else case e in #(
18918 e)
18919printf "%s\n" "#define bits64_t long long" >>confdefs.h
18920 ;;
18921esac
18922fi
18923
18924elif test "$ac_cv_sizeof_long" = 8; then
18925 ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default"
18926if test "x$ac_cv_type_bits64_t" = xyes
18927then :
18928
18929else case e in #(
18930 e)
18931printf "%s\n" "#define bits64_t long" >>confdefs.h
18932 ;;
18933esac
18934fi
18935
18936else
18937 ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default"
18938if test "x$ac_cv_type_bits64_t" = xyes
18939then :
18940
18941else case e in #(
18942 e)
18943printf "%s\n" "#define bits64_t double" >>confdefs.h
18944 ;;
18945esac
18946fi
18947
18948fi
18949
18950
18951
18952if test "$ac_cv_sizeof_int" = "$ac_cv_sizeof_char_p"; then
18953 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
18954if test "x$ac_cv_type_ptrdiff_t" = xyes
18955then :
18956
18957else case e in #(
18958 e)
18959printf "%s\n" "#define ptrdiff_t int" >>confdefs.h
18960 ;;
18961esac
18962fi
18963
18964elif test "$ac_cv_sizeof_long" = "$ac_cv_sizeof_char_p"; then
18965 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
18966if test "x$ac_cv_type_ptrdiff_t" = xyes
18967then :
18968
18969else case e in #(
18970 e)
18971printf "%s\n" "#define ptrdiff_t long" >>confdefs.h
18972 ;;
18973esac
18974fi
18975
18976elif test "$ac_cv_type_long_long" = yes && test "$ac_cv_sizeof_long_long" = "$ac_cv_sizeof_char_p"; then
18977 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
18978if test "x$ac_cv_type_ptrdiff_t" = xyes
18979then :
18980
18981else case e in #(
18982 e)
18983printf "%s\n" "#define ptrdiff_t long long" >>confdefs.h
18984 ;;
18985esac
18986fi
18987
18988else
18989 ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default"
18990if test "x$ac_cv_type_ptrdiff_t" = xyes
18991then :
18992
18993else case e in #(
18994 e)
18995printf "%s\n" "#define ptrdiff_t int" >>confdefs.h
18996 ;;
18997esac
18998fi
18999
19000fi
19001
19002
19003{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5
19004printf %s "checking whether stat file-mode macros are broken... " >&6; }
19005if test ${ac_cv_header_stat_broken+y}
19006then :
19007 printf %s "(cached) " >&6
19008else case e in #(
19009 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19010/* end confdefs.h. */
19011#include <sys/types.h>
19012#include <sys/stat.h>
19013
19014#if defined S_ISBLK && defined S_IFDIR
19015extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1];
19016#endif
19017
19018#if defined S_ISBLK && defined S_IFCHR
19019extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1];
19020#endif
19021
19022#if defined S_ISLNK && defined S_IFREG
19023extern char c3[S_ISLNK (S_IFREG) ? -1 : 1];
19024#endif
19025
19026#if defined S_ISSOCK && defined S_IFREG
19027extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1];
19028#endif
19029
19030_ACEOF
19031if ac_fn_c_try_compile "$LINENO"
19032then :
19033 ac_cv_header_stat_broken=no
19034else case e in #(
19035 e) ac_cv_header_stat_broken=yes ;;
19036esac
19037fi
19038rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19039esac
19040fi
19041{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5
19042printf "%s\n" "$ac_cv_header_stat_broken" >&6; }
19043if test $ac_cv_header_stat_broken = yes; then
19044
19045printf "%s\n" "#define STAT_MACROS_BROKEN 1" >>confdefs.h
19046
19047fi
19048
19049
19050{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether #! works in shell scripts" >&5
19051printf %s "checking whether #! works in shell scripts... " >&6; }
19052if test ${ac_cv_sys_interpreter+y}
19053then :
19054 printf %s "(cached) " >&6
19055else case e in #(
19056 e) echo '#! /bin/cat
19057exit 69
19058' >conftest
19059chmod u+x conftest
19060(SHELL=/bin/sh; export SHELL; ./conftest >/dev/null 2>&1)
19061if test $? -ne 69; then
19062 ac_cv_sys_interpreter=yes
19063else
19064 ac_cv_sys_interpreter=no
19065fi
19066rm -f conftest ;;
19067esac
19068fi
19069{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_interpreter" >&5
19070printf "%s\n" "$ac_cv_sys_interpreter" >&6; }
19071interpval=$ac_cv_sys_interpreter
19072
19073if test $ac_cv_sys_interpreter = yes; then
19074printf "%s\n" "#define HAVE_HASH_BANG_EXEC 1" >>confdefs.h
19075
19076fi
19077
19078if test "$ac_cv_func_lstat" = "no"; then
19079{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for lstat" >&5
19080printf %s "checking for lstat... " >&6; }
19081if test ${bash_cv_func_lstat+y}
19082then :
19083 printf %s "(cached) " >&6
19084else case e in #(
19085 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19086/* end confdefs.h. */
19087
19088 #include <sys/types.h>
19089 #include <sys/stat.h>
19090
19091int
19092main (void)
19093{
19094 lstat(".",(struct stat *)0);
19095 ;
19096 return 0;
19097}
19098_ACEOF
19099if ac_fn_c_try_link "$LINENO"
19100then :
19101 bash_cv_func_lstat=yes
19102else case e in #(
19103 e) bash_cv_func_lstat=no ;;
19104esac
19105fi
19106rm -f core conftest.err conftest.$ac_objext conftest.beam \
19107 conftest$ac_exeext conftest.$ac_ext ;;
19108esac
19109fi
19110{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_lstat" >&5
19111printf "%s\n" "$bash_cv_func_lstat" >&6; }
19112if test $bash_cv_func_lstat = yes; then
19113 printf "%s\n" "#define HAVE_LSTAT 1" >>confdefs.h
19114
19115fi
19116
19117fi
19118
19119
19120
19121 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether strchrnul works" >&5
19122printf %s "checking whether strchrnul works... " >&6; }
19123if test ${bash_cv_func_strchrnul_works+y}
19124then :
19125 printf %s "(cached) " >&6
19126else case e in #(
19127 e) if test "$cross_compiling" = yes
19128then :
19129 bash_cv_func_strchrnul_works=no
19130
19131else case e in #(
19132 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19133/* end confdefs.h. */
19134
19135#include <string.h>
19136
19137int
19138main (void)
19139{
19140const char *buf = "abc";
19141 return strchrnul (buf, 'd') != buf + 3;
19142
19143
19144 ;
19145 return 0;
19146}
19147_ACEOF
19148if ac_fn_c_try_run "$LINENO"
19149then :
19150 bash_cv_func_strchrnul_works=yes
19151else case e in #(
19152 e) bash_cv_func_strchrnul_works=no ;;
19153esac
19154fi
19155rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19156 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19157esac
19158fi
19159 ;;
19160esac
19161fi
19162{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_strchrnul_works" >&5
19163printf "%s\n" "$bash_cv_func_strchrnul_works" >&6; }
19164
19165if test "$bash_cv_func_strchrnul_works" = "no"; then
19166case " $LIBOBJS " in
19167 *" strchrnul.$ac_objext "* ) ;;
19168 *) LIBOBJS="$LIBOBJS strchrnul.$ac_objext"
19169 ;;
19170esac
19171
19172fi
19173
19174
19175{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if dup2 fails to clear the close-on-exec flag" >&5
19176printf %s "checking if dup2 fails to clear the close-on-exec flag... " >&6; }
19177if test ${bash_cv_dup2_broken+y}
19178then :
19179 printf %s "(cached) " >&6
19180else case e in #(
19181 e) if test "$cross_compiling" = yes
19182then :
19183 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&5
19184printf "%s\n" "$as_me: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&2;}
19185 bash_cv_dup2_broken=no
19186
19187else case e in #(
19188 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19189/* end confdefs.h. */
19190
19191#include <sys/types.h>
19192#include <fcntl.h>
19193#include <stdlib.h>
19194#ifdef HAVE_UNISTD_H
19195# include <unistd.h>
19196#endif /* HAVE_UNISTD_H */
19197int
19198main()
19199{
19200 int fd1, fd2, fl;
19201 fd1 = open("/dev/null", 2);
19202 if (fcntl(fd1, 2, 1) < 0)
19203 exit(1);
19204 fd2 = dup2(fd1, 1);
19205 if (fd2 < 0)
19206 exit(2);
19207 fl = fcntl(fd2, 1, 0);
19208 /* fl will be 1 if dup2 did not reset the close-on-exec flag. */
19209 exit(fl != 1);
19210}
19211
19212_ACEOF
19213if ac_fn_c_try_run "$LINENO"
19214then :
19215 bash_cv_dup2_broken=yes
19216else case e in #(
19217 e) bash_cv_dup2_broken=no ;;
19218esac
19219fi
19220rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19221 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19222esac
19223fi
19224 ;;
19225esac
19226fi
19227
19228{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dup2_broken" >&5
19229printf "%s\n" "$bash_cv_dup2_broken" >&6; }
19230if test $bash_cv_dup2_broken = yes; then
19231printf "%s\n" "#define DUP2_BROKEN 1" >>confdefs.h
19232
19233fi
19234
19235
19236{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether pgrps need synchronization" >&5
19237printf %s "checking whether pgrps need synchronization... " >&6; }
19238if test ${bash_cv_pgrp_pipe+y}
19239then :
19240 printf %s "(cached) " >&6
19241else case e in #(
19242 e) if test "$cross_compiling" = yes
19243then :
19244 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&5
19245printf "%s\n" "$as_me: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&2;}
19246 bash_cv_pgrp_pipe=no
19247
19248else case e in #(
19249 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19250/* end confdefs.h. */
19251
19252#ifdef HAVE_UNISTD_H
19253# include <unistd.h>
19254#endif
19255#ifdef HAVE_SYS_WAIT_H
19256# include <sys/wait.h>
19257#endif
19258#include <stdlib.h>
19259int
19260main()
19261{
19262# ifdef GETPGRP_VOID
19263# define getpgID() getpgrp()
19264# else
19265# define getpgID() getpgrp(0)
19266# define setpgid(x,y) setpgrp(x,y)
19267# endif
19268 int pid1, pid2, fds[2];
19269 int status;
19270 char ok;
19271
19272 switch (pid1 = fork()) {
19273 case -1:
19274 exit(1);
19275 case 0:
19276 setpgid(0, getpid());
19277 exit(0);
19278 }
19279 setpgid(pid1, pid1);
19280
19281 sleep(2); /* let first child die */
19282
19283 if (pipe(fds) < 0)
19284 exit(2);
19285
19286 switch (pid2 = fork()) {
19287 case -1:
19288 exit(3);
19289 case 0:
19290 setpgid(0, pid1);
19291 ok = getpgID() == pid1;
19292 write(fds[1], &ok, 1);
19293 exit(0);
19294 }
19295 setpgid(pid2, pid1);
19296
19297 close(fds[1]);
19298 if (read(fds[0], &ok, 1) != 1)
19299 exit(4);
19300 wait(&status);
19301 wait(&status);
19302 exit(ok ? 0 : 5);
19303}
19304
19305_ACEOF
19306if ac_fn_c_try_run "$LINENO"
19307then :
19308 bash_cv_pgrp_pipe=no
19309else case e in #(
19310 e) bash_cv_pgrp_pipe=yes ;;
19311esac
19312fi
19313rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19314 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19315esac
19316fi
19317 ;;
19318esac
19319fi
19320
19321{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_pgrp_pipe" >&5
19322printf "%s\n" "$bash_cv_pgrp_pipe" >&6; }
19323if test $bash_cv_pgrp_pipe = yes; then
19324printf "%s\n" "#define PGRP_PIPE 1" >>confdefs.h
19325
19326fi
19327
19328{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for type of signal functions" >&5
19329printf %s "checking for type of signal functions... " >&6; }
19330if test ${bash_cv_signal_vintage+y}
19331then :
19332 printf %s "(cached) " >&6
19333else case e in #(
19334 e)
19335if test ${bash_cv_posix_signals+y}
19336then :
19337 printf %s "(cached) " >&6
19338else case e in #(
19339 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19340/* end confdefs.h. */
19341
19342#include <signal.h>
19343
19344int
19345main (void)
19346{
19347
19348 sigset_t ss;
19349 struct sigaction sa;
19350 sigemptyset(&ss); sigsuspend(&ss);
19351 sigaction(SIGINT, &sa, (struct sigaction *) 0);
19352 sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0);
19353
19354 ;
19355 return 0;
19356}
19357_ACEOF
19358if ac_fn_c_try_link "$LINENO"
19359then :
19360 bash_cv_posix_signals=yes
19361else case e in #(
19362 e) bash_cv_posix_signals=no
19363 ;;
19364esac
19365fi
19366rm -f core conftest.err conftest.$ac_objext conftest.beam \
19367 conftest$ac_exeext conftest.$ac_ext ;;
19368esac
19369fi
19370
19371
19372if test $bash_cv_posix_signals = yes; then
19373 bash_cv_signal_vintage=posix
19374else
19375 if test ${bash_cv_bsd_signals+y}
19376then :
19377 printf %s "(cached) " >&6
19378else case e in #(
19379 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19380/* end confdefs.h. */
19381
19382#include <signal.h>
19383
19384int
19385main (void)
19386{
19387
19388int mask = sigmask(SIGINT);
19389sigsetmask(mask); sigblock(mask); sigpause(mask);
19390
19391 ;
19392 return 0;
19393}
19394_ACEOF
19395if ac_fn_c_try_link "$LINENO"
19396then :
19397 bash_cv_bsd_signals=yes
19398else case e in #(
19399 e) bash_cv_bsd_signals=no
19400 ;;
19401esac
19402fi
19403rm -f core conftest.err conftest.$ac_objext conftest.beam \
19404 conftest$ac_exeext conftest.$ac_ext ;;
19405esac
19406fi
19407
19408
19409 if test $bash_cv_bsd_signals = yes; then
19410 bash_cv_signal_vintage=4.2bsd
19411 else
19412 if test ${bash_cv_sysv_signals+y}
19413then :
19414 printf %s "(cached) " >&6
19415else case e in #(
19416 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19417/* end confdefs.h. */
19418
19419#include <signal.h>
19420void foo() { }
19421
19422int
19423main (void)
19424{
19425
19426int mask = sigmask(SIGINT);
19427sigset(SIGINT, foo); sigrelse(SIGINT);
19428sighold(SIGINT); sigpause(SIGINT);
19429
19430 ;
19431 return 0;
19432}
19433_ACEOF
19434if ac_fn_c_try_link "$LINENO"
19435then :
19436 bash_cv_sysv_signals=yes
19437else case e in #(
19438 e) bash_cv_sysv_signals=no
19439 ;;
19440esac
19441fi
19442rm -f core conftest.err conftest.$ac_objext conftest.beam \
19443 conftest$ac_exeext conftest.$ac_ext ;;
19444esac
19445fi
19446
19447
19448 if test $bash_cv_sysv_signals = yes; then
19449 bash_cv_signal_vintage=svr3
19450 else
19451 bash_cv_signal_vintage=v7
19452 fi
19453 fi
19454fi
19455 ;;
19456esac
19457fi
19458
19459{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_signal_vintage" >&5
19460printf "%s\n" "$bash_cv_signal_vintage" >&6; }
19461if test "$bash_cv_signal_vintage" = posix; then
19462printf "%s\n" "#define HAVE_POSIX_SIGNALS 1" >>confdefs.h
19463
19464elif test "$bash_cv_signal_vintage" = "4.2bsd"; then
19465printf "%s\n" "#define HAVE_BSD_SIGNALS 1" >>confdefs.h
19466
19467elif test "$bash_cv_signal_vintage" = svr3; then
19468printf "%s\n" "#define HAVE_USG_SIGHOLD 1" >>confdefs.h
19469
19470fi
19471
19472
19473{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sys_errlist and sys_nerr" >&5
19474printf %s "checking for sys_errlist and sys_nerr... " >&6; }
19475if test ${bash_cv_sys_errlist+y}
19476then :
19477 printf %s "(cached) " >&6
19478else case e in #(
19479 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19480/* end confdefs.h. */
19481
19482#include <errno.h>
19483
19484int
19485main (void)
19486{
19487
19488extern char *sys_errlist[];
19489extern int sys_nerr;
19490char *msg = sys_errlist[sys_nerr - 1];
19491
19492 ;
19493 return 0;
19494}
19495_ACEOF
19496if ac_fn_c_try_link "$LINENO"
19497then :
19498 bash_cv_sys_errlist=yes
19499else case e in #(
19500 e) bash_cv_sys_errlist=no
19501 ;;
19502esac
19503fi
19504rm -f core conftest.err conftest.$ac_objext conftest.beam \
19505 conftest$ac_exeext conftest.$ac_ext ;;
19506esac
19507fi
19508
19509{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_errlist" >&5
19510printf "%s\n" "$bash_cv_sys_errlist" >&6; }
19511if test $bash_cv_sys_errlist = yes; then
19512printf "%s\n" "#define HAVE_SYS_ERRLIST 1" >>confdefs.h
19513
19514fi
19515
19516ac_fn_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h>
19517/* NetBSD declares sys_siglist in unistd.h. */
19518#ifdef HAVE_UNISTD_H
19519# include <unistd.h>
19520#endif
19521
19522" "$ac_c_undeclared_builtin_options" "CFLAGS"
19523if test "x$ac_cv_have_decl_sys_siglist" = xyes
19524then :
19525 ac_have_decl=1
19526else case e in #(
19527 e) ac_have_decl=0 ;;
19528esac
19529fi
19530printf "%s\n" "#define HAVE_DECL_SYS_SIGLIST $ac_have_decl" >>confdefs.h
19531
19532
19533
19534{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sys_siglist in system C library" >&5
19535printf %s "checking for sys_siglist in system C library... " >&6; }
19536if test ${bash_cv_sys_siglist+y}
19537then :
19538 printf %s "(cached) " >&6
19539else case e in #(
19540 e) if test "$cross_compiling" = yes
19541then :
19542 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&5
19543printf "%s\n" "$as_me: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&2;}
19544 bash_cv_sys_siglist=no
19545
19546else case e in #(
19547 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19548/* end confdefs.h. */
19549
19550#include <sys/types.h>
19551#include <signal.h>
19552#ifdef HAVE_UNISTD_H
19553#include <unistd.h>
19554#endif
19555#include <stdlib.h>
19556#if !HAVE_DECL_SYS_SIGLIST
19557extern char *sys_siglist[];
19558#endif
19559int
19560main()
19561{
19562char *msg = sys_siglist[2];
19563exit(msg == 0);
19564}
19565
19566_ACEOF
19567if ac_fn_c_try_run "$LINENO"
19568then :
19569 bash_cv_sys_siglist=yes
19570else case e in #(
19571 e) bash_cv_sys_siglist=no ;;
19572esac
19573fi
19574rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19575 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19576esac
19577fi
19578 ;;
19579esac
19580fi
19581
19582{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_siglist" >&5
19583printf "%s\n" "$bash_cv_sys_siglist" >&6; }
19584if test $bash_cv_sys_siglist = yes; then
19585printf "%s\n" "#define HAVE_SYS_SIGLIST 1" >>confdefs.h
19586
19587fi
19588
19589{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in signal.h or unistd.h" >&5
19590printf %s "checking for _sys_siglist in signal.h or unistd.h... " >&6; }
19591if test ${bash_cv_decl_under_sys_siglist+y}
19592then :
19593 printf %s "(cached) " >&6
19594else case e in #(
19595 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19596/* end confdefs.h. */
19597
19598#include <sys/types.h>
19599#include <signal.h>
19600#ifdef HAVE_UNISTD_H
19601#include <unistd.h>
19602#endif
19603int
19604main (void)
19605{
19606 char *msg = _sys_siglist[2];
19607 ;
19608 return 0;
19609}
19610_ACEOF
19611if ac_fn_c_try_compile "$LINENO"
19612then :
19613 bash_cv_decl_under_sys_siglist=yes
19614else case e in #(
19615 e) bash_cv_decl_under_sys_siglist=no ;;
19616esac
19617fi
19618rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19619esac
19620fi
19621{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_under_sys_siglist" >&5
19622printf "%s\n" "$bash_cv_decl_under_sys_siglist" >&6; }
19623if test $bash_cv_decl_under_sys_siglist = yes; then
19624printf "%s\n" "#define UNDER_SYS_SIGLIST_DECLARED 1" >>confdefs.h
19625
19626fi
19627
19628
19629{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in system C library" >&5
19630printf %s "checking for _sys_siglist in system C library... " >&6; }
19631if test ${bash_cv_under_sys_siglist+y}
19632then :
19633 printf %s "(cached) " >&6
19634else case e in #(
19635 e) if test "$cross_compiling" = yes
19636then :
19637 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&5
19638printf "%s\n" "$as_me: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&2;}
19639 bash_cv_under_sys_siglist=no
19640
19641else case e in #(
19642 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19643/* end confdefs.h. */
19644
19645#include <sys/types.h>
19646#include <signal.h>
19647#ifdef HAVE_UNISTD_H
19648#include <unistd.h>
19649#endif
19650#include <stdlib.h>
19651#ifndef UNDER_SYS_SIGLIST_DECLARED
19652extern char *_sys_siglist[];
19653#endif
19654int
19655main()
19656{
19657char *msg = (char *)_sys_siglist[2];
19658exit(msg == 0);
19659}
19660
19661_ACEOF
19662if ac_fn_c_try_run "$LINENO"
19663then :
19664 bash_cv_under_sys_siglist=yes
19665else case e in #(
19666 e) bash_cv_under_sys_siglist=no ;;
19667esac
19668fi
19669rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19670 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19671esac
19672fi
19673 ;;
19674esac
19675fi
19676
19677{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_under_sys_siglist" >&5
19678printf "%s\n" "$bash_cv_under_sys_siglist" >&6; }
19679if test $bash_cv_under_sys_siglist = yes; then
19680printf "%s\n" "#define HAVE_UNDER_SYS_SIGLIST 1" >>confdefs.h
19681
19682fi
19683
19684
19685
19686
19687{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5
19688printf %s "checking for clock_t... " >&6; }
19689if test ${bash_cv_type_clock_t+y}
19690then :
19691 printf %s "(cached) " >&6
19692else case e in #(
19693 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19694/* end confdefs.h. */
19695#include <sys/types.h>
19696#if HAVE_STDLIB_H
19697#include <stdlib.h>
19698#endif
19699#if HAVE_STDDEF_H
19700#include <stddef.h>
19701#endif
19702#if HAVE_INTTYPES_H
19703#include <inttypes.h>
19704#endif
19705#if HAVE_STDINT_H
19706#include <stdint.h>
19707#endif
19708#include <sys/times.h>
19709
19710_ACEOF
19711if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19712 $EGREP_TRADITIONAL "clock_t" >/dev/null 2>&1
19713then :
19714 bash_cv_type_clock_t=yes
19715else case e in #(
19716 e) bash_cv_type_clock_t=no ;;
19717esac
19718fi
19719rm -rf conftest*
19720 ;;
19721esac
19722fi
19723
19724{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_clock_t" >&5
19725printf "%s\n" "$bash_cv_type_clock_t" >&6; }
19726
19727if test $bash_cv_type_clock_t = no; then
19728 printf "%s\n" "#define clock_t long" >>confdefs.h
19729
19730fi
19731
19732
19733
19734{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sigset_t" >&5
19735printf %s "checking for sigset_t... " >&6; }
19736if test ${bash_cv_type_sigset_t+y}
19737then :
19738 printf %s "(cached) " >&6
19739else case e in #(
19740 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19741/* end confdefs.h. */
19742#include <sys/types.h>
19743#if HAVE_STDLIB_H
19744#include <stdlib.h>
19745#endif
19746#if HAVE_STDDEF_H
19747#include <stddef.h>
19748#endif
19749#if HAVE_INTTYPES_H
19750#include <inttypes.h>
19751#endif
19752#if HAVE_STDINT_H
19753#include <stdint.h>
19754#endif
19755#include <signal.h>
19756
19757_ACEOF
19758if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19759 $EGREP_TRADITIONAL "sigset_t" >/dev/null 2>&1
19760then :
19761 bash_cv_type_sigset_t=yes
19762else case e in #(
19763 e) bash_cv_type_sigset_t=no ;;
19764esac
19765fi
19766rm -rf conftest*
19767 ;;
19768esac
19769fi
19770
19771{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sigset_t" >&5
19772printf "%s\n" "$bash_cv_type_sigset_t" >&6; }
19773
19774if test $bash_cv_type_sigset_t = no; then
19775 printf "%s\n" "#define sigset_t int" >>confdefs.h
19776
19777fi
19778
19779if test "$ac_cv_header_sys_socket_h" = "yes"; then
19780
19781
19782{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5
19783printf %s "checking for socklen_t... " >&6; }
19784if test ${bash_cv_type_socklen_t+y}
19785then :
19786 printf %s "(cached) " >&6
19787else case e in #(
19788 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19789/* end confdefs.h. */
19790#include <sys/types.h>
19791#if HAVE_STDLIB_H
19792#include <stdlib.h>
19793#endif
19794#if HAVE_STDDEF_H
19795#include <stddef.h>
19796#endif
19797#if HAVE_INTTYPES_H
19798#include <inttypes.h>
19799#endif
19800#if HAVE_STDINT_H
19801#include <stdint.h>
19802#endif
19803#include <sys/socket.h>
19804
19805_ACEOF
19806if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
19807 $EGREP_TRADITIONAL "socklen_t" >/dev/null 2>&1
19808then :
19809 bash_cv_type_socklen_t=yes
19810else case e in #(
19811 e) bash_cv_type_socklen_t=no ;;
19812esac
19813fi
19814rm -rf conftest*
19815 ;;
19816esac
19817fi
19818
19819{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_socklen_t" >&5
19820printf "%s\n" "$bash_cv_type_socklen_t" >&6; }
19821if test $bash_cv_type_socklen_t = yes; then
19822 printf "%s\n" "#define HAVE_SOCKLEN_T 1" >>confdefs.h
19823
19824 fi
19825if test $bash_cv_type_socklen_t = no; then
19826 printf "%s\n" "#define socklen_t unsigned int" >>confdefs.h
19827
19828fi
19829
19830fi
19831
19832ac_fn_c_check_type "$LINENO" "quad_t" "ac_cv_type_quad_t" "$ac_includes_default"
19833if test "x$ac_cv_type_quad_t" = xyes
19834then :
19835 printf "%s\n" "#define HAVE_QUAD_T 1" >>confdefs.h
19836
19837fi
19838
19839{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for type of struct rlimit fields" >&5
19840printf %s "checking for type of struct rlimit fields... " >&6; }
19841if test ${bash_cv_type_rlimit+y}
19842then :
19843 printf %s "(cached) " >&6
19844else case e in #(
19845 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19846/* end confdefs.h. */
19847
19848#include <sys/types.h>
19849#include <sys/resource.h>
19850int
19851main (void)
19852{
19853rlim_t xxx;
19854
19855 ;
19856 return 0;
19857}
19858_ACEOF
19859if ac_fn_c_try_compile "$LINENO"
19860then :
19861 bash_cv_type_rlimit=rlim_t
19862else case e in #(
19863 e)
19864{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for size of struct rlimit fields" >&5
19865printf %s "checking for size of struct rlimit fields... " >&6; }
19866if test ${bash_cv_sizeof_rlim_cur+y}
19867then :
19868 printf %s "(cached) " >&6
19869else case e in #(
19870 e) if test "$cross_compiling" = yes
19871then :
19872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check size of rlimit fields if cross compiling -- defaulting to long" >&5
19873printf "%s\n" "$as_me: WARNING: cannot check size of rlimit fields if cross compiling -- defaulting to long" >&2;}
19874 bash_cv_sizeof_rlim_cur=$ac_cv_sizeof_long
19875
19876else case e in #(
19877 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19878/* end confdefs.h. */
19879
19880#ifdef HAVE_SYS_TIME_H
19881#include <sys/time.h>
19882#endif
19883#include <stdlib.h>
19884#include <sys/resource.h>
19885int
19886main()
19887{
19888struct rlimit r;
19889exit(sizeof (r.rlim_cur));
19890}
19891
19892_ACEOF
19893if ac_fn_c_try_run "$LINENO"
19894then :
19895 bash_cv_sizeof_rlim_cur=$?
19896else case e in #(
19897 e) bash_cv_sizeof_rlim_cur=$? ;;
19898esac
19899fi
19900rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19901 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19902esac
19903fi
19904 ;;
19905esac
19906fi
19907
19908{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sizeof_rlim_cur" >&5
19909printf "%s\n" "$bash_cv_sizeof_rlim_cur" >&6; }
19910
19911{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for size of quad_t" >&5
19912printf %s "checking for size of quad_t... " >&6; }
19913if test ${bash_cv_sizeof_quad_t+y}
19914then :
19915 printf %s "(cached) " >&6
19916else case e in #(
19917 e) if test "$cross_compiling" = yes
19918then :
19919 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check size of quad_t if cross compiling -- defaulting to 0" >&5
19920printf "%s\n" "$as_me: WARNING: cannot check size of quad_t if cross compiling -- defaulting to 0" >&2;}
19921 bash_cv_sizeof_quad_t=0
19922
19923else case e in #(
19924 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
19925/* end confdefs.h. */
19926
19927#include <sys/types.h>
19928#include <stdlib.h>
19929#if HAVE_INTTYPES_H
19930#include <inttypes.h>
19931#endif
19932#if HAVE_STDINT_H
19933#include <stdint.h>
19934#endif
19935
19936int
19937main()
19938{
19939#if HAVE_QUAD_T
19940quad_t x;
19941exit(sizeof (x));
19942#else
19943exit (0);
19944#endif
19945}
19946
19947_ACEOF
19948if ac_fn_c_try_run "$LINENO"
19949then :
19950 bash_cv_sizeof_quad_t=$?
19951else case e in #(
19952 e) bash_cv_sizeof_quad_t=$? ;;
19953esac
19954fi
19955rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
19956 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19957esac
19958fi
19959 ;;
19960esac
19961fi
19962
19963{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sizeof_quad_t" >&5
19964printf "%s\n" "$bash_cv_sizeof_quad_t" >&6; }
19965
19966if test $bash_cv_sizeof_rlim_cur = $ac_cv_sizeof_long; then
19967 bash_cv_type_rlimit='unsigned long'
19968elif test $bash_cv_sizeof_rlim_cur = $ac_cv_sizeof_long_long; then
19969 bash_cv_type_rlimit='unsigned long long'
19970elif test $bash_cv_sizeof_rlim_cur = $ac_cv_sizeof_int; then
19971 bash_cv_type_rlimit='unsigned int'
19972elif test $bash_cv_sizeof_rlim_cur = $bash_cv_sizeof_quad_t; then
19973 bash_cv_type_rlimit='quad_t'
19974else
19975 bash_cv_type_rlimit='unsigned long'
19976fi
19977
19978 ;;
19979esac
19980fi
19981rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
19982esac
19983fi
19984
19985{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_rlimit" >&5
19986printf "%s\n" "$bash_cv_type_rlimit" >&6; }
19987printf "%s\n" "#define RLIMTYPE $bash_cv_type_rlimit" >>confdefs.h
19988
19989
19990
19991
19992
19993 ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default"
19994if test "x$ac_cv_type_intmax_t" = xyes
19995then :
19996
19997printf "%s\n" "#define HAVE_INTMAX_T 1" >>confdefs.h
19998
19999else case e in #(
20000 e) test $ac_cv_type_long_long_int = yes \
20001 && ac_type='long long int' \
20002 || ac_type='long int'
20003
20004printf "%s\n" "#define intmax_t $ac_type" >>confdefs.h
20005 ;;
20006esac
20007fi
20008
20009
20010
20011
20012 ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default"
20013if test "x$ac_cv_type_uintmax_t" = xyes
20014then :
20015
20016printf "%s\n" "#define HAVE_UINTMAX_T 1" >>confdefs.h
20017
20018else case e in #(
20019 e) test $ac_cv_type_unsigned_long_long_int = yes \
20020 && ac_type='unsigned long long int' \
20021 || ac_type='unsigned long int'
20022
20023printf "%s\n" "#define uintmax_t $ac_type" >>confdefs.h
20024 ;;
20025esac
20026fi
20027
20028
20029
20030# The cast to long int works around a bug in the HP C Compiler
20031# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
20032# declarations like 'int a3[[(sizeof (unsigned char)) >= 0]];'.
20033# This bug is HP SR number 8606223364.
20034{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5
20035printf %s "checking size of intmax_t... " >&6; }
20036if test ${ac_cv_sizeof_intmax_t+y}
20037then :
20038 printf %s "(cached) " >&6
20039else case e in #(
20040 e) if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"
20041then :
20042
20043else case e in #(
20044 e) if test "$ac_cv_type_intmax_t" = yes; then
20045 { { printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: in '$ac_pwd':" >&5
20046printf "%s\n" "$as_me: error: in '$ac_pwd':" >&2;}
20047as_fn_error 77 "cannot compute sizeof (intmax_t)
20048See 'config.log' for more details" "$LINENO" 5; }
20049 else
20050 ac_cv_sizeof_intmax_t=0
20051 fi ;;
20052esac
20053fi
20054 ;;
20055esac
20056fi
20057{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5
20058printf "%s\n" "$ac_cv_sizeof_intmax_t" >&6; }
20059
20060
20061
20062printf "%s\n" "#define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t" >>confdefs.h
20063
20064
20065
20066
20067ac_fn_c_check_member "$LINENO" "struct termios" "c_line" "ac_cv_member_struct_termios_c_line" "
20068#include <sys/types.h>
20069#include <termios.h>
20070
20071"
20072if test "x$ac_cv_member_struct_termios_c_line" = xyes
20073then :
20074 printf "%s\n" "#define TERMIOS_LDISC 1" >>confdefs.h
20075
20076fi
20077
20078
20079
20080ac_fn_c_check_member "$LINENO" "struct termio" "c_line" "ac_cv_member_struct_termio_c_line" "
20081#include <sys/types.h>
20082#include <termio.h>
20083
20084"
20085if test "x$ac_cv_member_struct_termio_c_line" = xyes
20086then :
20087 printf "%s\n" "#define TERMIO_LDISC 1" >>confdefs.h
20088
20089fi
20090
20091
20092
20093
20094ac_fn_c_check_member "$LINENO" "struct dirent" "d_ino" "ac_cv_member_struct_dirent_d_ino" "
20095#include <stdio.h>
20096#include <sys/types.h>
20097#ifdef HAVE_UNISTD_H
20098# include <unistd.h>
20099#endif /* HAVE_UNISTD_H */
20100#if defined(HAVE_DIRENT_H)
20101# include <dirent.h>
20102#else
20103# define dirent direct
20104# ifdef HAVE_SYS_NDIR_H
20105# include <sys/ndir.h>
20106# endif /* SYSNDIR */
20107# ifdef HAVE_SYS_DIR_H
20108# include <sys/dir.h>
20109# endif /* SYSDIR */
20110# ifdef HAVE_NDIR_H
20111# include <ndir.h>
20112# endif
20113#endif /* HAVE_DIRENT_H */
20114
20115"
20116if test "x$ac_cv_member_struct_dirent_d_ino" = xyes
20117then :
20118
20119printf "%s\n" "#define HAVE_STRUCT_DIRENT_D_INO 1" >>confdefs.h
20120
20121
20122fi
20123
20124
20125
20126
20127ac_fn_c_check_member "$LINENO" "struct dirent" "d_fileno" "ac_cv_member_struct_dirent_d_fileno" "
20128#include <stdio.h>
20129#include <sys/types.h>
20130#ifdef HAVE_UNISTD_H
20131# include <unistd.h>
20132#endif /* HAVE_UNISTD_H */
20133#if defined(HAVE_DIRENT_H)
20134# include <dirent.h>
20135#else
20136# define dirent direct
20137# ifdef HAVE_SYS_NDIR_H
20138# include <sys/ndir.h>
20139# endif /* SYSNDIR */
20140# ifdef HAVE_SYS_DIR_H
20141# include <sys/dir.h>
20142# endif /* SYSDIR */
20143# ifdef HAVE_NDIR_H
20144# include <ndir.h>
20145# endif
20146#endif /* HAVE_DIRENT_H */
20147
20148"
20149if test "x$ac_cv_member_struct_dirent_d_fileno" = xyes
20150then :
20151
20152printf "%s\n" "#define HAVE_STRUCT_DIRENT_D_FILENO 1" >>confdefs.h
20153
20154
20155fi
20156
20157
20158
20159
20160ac_fn_c_check_member "$LINENO" "struct dirent" "d_namlen" "ac_cv_member_struct_dirent_d_namlen" "
20161#include <stdio.h>
20162#include <sys/types.h>
20163#ifdef HAVE_UNISTD_H
20164# include <unistd.h>
20165#endif /* HAVE_UNISTD_H */
20166#if defined(HAVE_DIRENT_H)
20167# include <dirent.h>
20168#else
20169# define dirent direct
20170# ifdef HAVE_SYS_NDIR_H
20171# include <sys/ndir.h>
20172# endif /* SYSNDIR */
20173# ifdef HAVE_SYS_DIR_H
20174# include <sys/dir.h>
20175# endif /* SYSDIR */
20176# ifdef HAVE_NDIR_H
20177# include <ndir.h>
20178# endif
20179#endif /* HAVE_DIRENT_H */
20180
20181"
20182if test "x$ac_cv_member_struct_dirent_d_namlen" = xyes
20183then :
20184
20185printf "%s\n" "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" >>confdefs.h
20186
20187
20188fi
20189
20190
20191{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for d_type member in directory struct" >&5
20192printf %s "checking for d_type member in directory struct... " >&6; }
20193if test ${gl_cv_struct_dirent_d_type+y}
20194then :
20195 printf %s "(cached) " >&6
20196else case e in #(
20197 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20198/* end confdefs.h. */
20199
20200#include <sys/types.h>
20201#include <dirent.h>
20202
20203int
20204main (void)
20205{
20206struct dirent dp; dp.d_type = 0;
20207 ;
20208 return 0;
20209}
20210_ACEOF
20211if ac_fn_c_try_link "$LINENO"
20212then :
20213 gl_cv_struct_dirent_d_type=yes
20214else case e in #(
20215 e) gl_cv_struct_dirent_d_type=no ;;
20216esac
20217fi
20218rm -f core conftest.err conftest.$ac_objext conftest.beam \
20219 conftest$ac_exeext conftest.$ac_ext
20220
20221 ;;
20222esac
20223fi
20224{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $gl_cv_struct_dirent_d_type" >&5
20225printf "%s\n" "$gl_cv_struct_dirent_d_type" >&6; }
20226 if test $gl_cv_struct_dirent_d_type = yes; then
20227
20228printf "%s\n" "#define HAVE_STRUCT_DIRENT_D_TYPE 1" >>confdefs.h
20229
20230 fi
20231
20232
20233{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct winsize in sys/ioctl.h and termios.h" >&5
20234printf %s "checking for struct winsize in sys/ioctl.h and termios.h... " >&6; }
20235if test ${bash_cv_struct_winsize_header+y}
20236then :
20237 printf %s "(cached) " >&6
20238else case e in #(
20239 e)
20240if test ${bash_cv_struct_winsize_ioctl+y}
20241then :
20242 printf %s "(cached) " >&6
20243else case e in #(
20244 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20245/* end confdefs.h. */
20246
20247#include <sys/types.h>
20248#include <sys/ioctl.h>
20249
20250int
20251main (void)
20252{
20253
20254struct winsize x;
20255if (sizeof (x) > 0) return (0);
20256
20257 ;
20258 return 0;
20259}
20260_ACEOF
20261if ac_fn_c_try_compile "$LINENO"
20262then :
20263 bash_cv_struct_winsize_ioctl=yes
20264else case e in #(
20265 e) bash_cv_struct_winsize_ioctl=no ;;
20266esac
20267fi
20268rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
20269 ;;
20270esac
20271fi
20272
20273
20274if test ${bash_cv_struct_winsize_termios+y}
20275then :
20276 printf %s "(cached) " >&6
20277else case e in #(
20278 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20279/* end confdefs.h. */
20280
20281#include <sys/types.h>
20282#include <sys/termios.h>
20283
20284int
20285main (void)
20286{
20287
20288struct winsize x;
20289if (sizeof (x) > 0) return (0);
20290
20291 ;
20292 return 0;
20293}
20294_ACEOF
20295if ac_fn_c_try_compile "$LINENO"
20296then :
20297 bash_cv_struct_winsize_termios=yes
20298else case e in #(
20299 e) bash_cv_struct_winsize_termios=no ;;
20300esac
20301fi
20302rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
20303 ;;
20304esac
20305fi
20306
20307
20308
20309if test $bash_cv_struct_winsize_ioctl = yes; then
20310 bash_cv_struct_winsize_header=ioctl_h
20311elif test $bash_cv_struct_winsize_termios = yes; then
20312 bash_cv_struct_winsize_header=termios_h
20313else
20314 bash_cv_struct_winsize_header=other
20315fi
20316 ;;
20317esac
20318fi
20319
20320if test $bash_cv_struct_winsize_header = ioctl_h; then
20321 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: sys/ioctl.h" >&5
20322printf "%s\n" "sys/ioctl.h" >&6; }
20323 printf "%s\n" "#define STRUCT_WINSIZE_IN_SYS_IOCTL 1" >>confdefs.h
20324
20325elif test $bash_cv_struct_winsize_header = termios_h; then
20326 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: termios.h" >&5
20327printf "%s\n" "termios.h" >&6; }
20328 printf "%s\n" "#define STRUCT_WINSIZE_IN_TERMIOS 1" >>confdefs.h
20329
20330else
20331 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: not found" >&5
20332printf "%s\n" "not found" >&6; }
20333fi
20334
20335{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timeval in sys/time.h and time.h" >&5
20336printf %s "checking for struct timeval in sys/time.h and time.h... " >&6; }
20337if test ${bash_cv_struct_timeval+y}
20338then :
20339 printf %s "(cached) " >&6
20340else case e in #(
20341 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20342/* end confdefs.h. */
20343#if HAVE_SYS_TIME_H
20344 #include <sys/time.h>
20345 #endif
20346 #include <time.h>
20347
20348int
20349main (void)
20350{
20351static struct timeval x; x.tv_sec = x.tv_usec;
20352
20353 ;
20354 return 0;
20355}
20356_ACEOF
20357if ac_fn_c_try_compile "$LINENO"
20358then :
20359 bash_cv_struct_timeval=yes
20360else case e in #(
20361 e) bash_cv_struct_timeval=no ;;
20362esac
20363fi
20364rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
20365 ;;
20366esac
20367fi
20368
20369{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timeval" >&5
20370printf "%s\n" "$bash_cv_struct_timeval" >&6; }
20371if test $bash_cv_struct_timeval = yes; then
20372 printf "%s\n" "#define HAVE_TIMEVAL 1" >>confdefs.h
20373
20374fi
20375
20376ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default"
20377if test "x$ac_cv_member_struct_stat_st_blocks" = xyes
20378then :
20379
20380printf "%s\n" "#define HAVE_STRUCT_STAT_ST_BLOCKS 1" >>confdefs.h
20381
20382
20383fi
20384
20385{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5
20386printf %s "checking whether struct tm is in sys/time.h or time.h... " >&6; }
20387if test ${ac_cv_struct_tm+y}
20388then :
20389 printf %s "(cached) " >&6
20390else case e in #(
20391 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20392/* end confdefs.h. */
20393#include <sys/types.h>
20394#include <time.h>
20395
20396int
20397main (void)
20398{
20399struct tm tm;
20400 int *p = &tm.tm_sec;
20401 return !p;
20402 ;
20403 return 0;
20404}
20405_ACEOF
20406if ac_fn_c_try_compile "$LINENO"
20407then :
20408 ac_cv_struct_tm=time.h
20409else case e in #(
20410 e) ac_cv_struct_tm=sys/time.h ;;
20411esac
20412fi
20413rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20414esac
20415fi
20416{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5
20417printf "%s\n" "$ac_cv_struct_tm" >&6; }
20418if test $ac_cv_struct_tm = sys/time.h; then
20419
20420printf "%s\n" "#define TM_IN_SYS_TIME 1" >>confdefs.h
20421
20422fi
20423
20424ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h>
20425#include <$ac_cv_struct_tm>
20426
20427"
20428if test "x$ac_cv_member_struct_tm_tm_zone" = xyes
20429then :
20430
20431printf "%s\n" "#define HAVE_STRUCT_TM_TM_ZONE 1" >>confdefs.h
20432
20433
20434fi
20435
20436if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
20437
20438printf "%s\n" "#define HAVE_TM_ZONE 1" >>confdefs.h
20439
20440else
20441 ac_fn_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h>
20442" "$ac_c_undeclared_builtin_options" "CFLAGS"
20443if test "x$ac_cv_have_decl_tzname" = xyes
20444then :
20445 ac_have_decl=1
20446else case e in #(
20447 e) ac_have_decl=0 ;;
20448esac
20449fi
20450printf "%s\n" "#define HAVE_DECL_TZNAME $ac_have_decl" >>confdefs.h
20451
20452 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5
20453printf %s "checking for tzname... " >&6; }
20454if test ${ac_cv_var_tzname+y}
20455then :
20456 printf %s "(cached) " >&6
20457else case e in #(
20458 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20459/* end confdefs.h. */
20460#include <time.h>
20461#if !HAVE_DECL_TZNAME
20462extern char *tzname[];
20463#endif
20464
20465int
20466main (void)
20467{
20468return tzname[0][0];
20469 ;
20470 return 0;
20471}
20472_ACEOF
20473if ac_fn_c_try_link "$LINENO"
20474then :
20475 ac_cv_var_tzname=yes
20476else case e in #(
20477 e) ac_cv_var_tzname=no ;;
20478esac
20479fi
20480rm -f core conftest.err conftest.$ac_objext conftest.beam \
20481 conftest$ac_exeext conftest.$ac_ext ;;
20482esac
20483fi
20484{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5
20485printf "%s\n" "$ac_cv_var_tzname" >&6; }
20486 if test $ac_cv_var_tzname = yes; then
20487
20488printf "%s\n" "#define HAVE_TZNAME 1" >>confdefs.h
20489
20490 fi
20491fi
20492
20493{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timezone in sys/time.h and time.h" >&5
20494printf %s "checking for struct timezone in sys/time.h and time.h... " >&6; }
20495if test ${bash_cv_struct_timezone+y}
20496then :
20497 printf %s "(cached) " >&6
20498else case e in #(
20499 e)
20500cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20501/* end confdefs.h. */
20502#include <sys/time.h>
20503
20504_ACEOF
20505if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20506 $EGREP_TRADITIONAL "struct timezone" >/dev/null 2>&1
20507then :
20508 bash_cv_struct_timezone=yes
20509else case e in #(
20510 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20511/* end confdefs.h. */
20512#include <time.h>
20513
20514_ACEOF
20515if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
20516 $EGREP_TRADITIONAL "struct timezone" >/dev/null 2>&1
20517then :
20518 bash_cv_struct_timezone=yes
20519else case e in #(
20520 e) bash_cv_struct_timezone=no ;;
20521esac
20522fi
20523rm -rf conftest*
20524 ;;
20525esac
20526fi
20527rm -rf conftest*
20528
20529 ;;
20530esac
20531fi
20532
20533{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timezone" >&5
20534printf "%s\n" "$bash_cv_struct_timezone" >&6; }
20535if test $bash_cv_struct_timezone = yes; then
20536 printf "%s\n" "#define HAVE_STRUCT_TIMEZONE 1" >>confdefs.h
20537
20538fi
20539
20540
20541{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for offset of exit status in return status from wait" >&5
20542printf %s "checking for offset of exit status in return status from wait... " >&6; }
20543if test ${bash_cv_wexitstatus_offset+y}
20544then :
20545 printf %s "(cached) " >&6
20546else case e in #(
20547 e) if test "$cross_compiling" = yes
20548then :
20549 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&5
20550printf "%s\n" "$as_me: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&2;}
20551 bash_cv_wexitstatus_offset=0
20552
20553else case e in #(
20554 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20555/* end confdefs.h. */
20556
20557#include <stdlib.h>
20558#include <unistd.h>
20559
20560#include <sys/wait.h>
20561
20562int
20563main(int c, char **v)
20564{
20565 pid_t pid, p;
20566 int s, i, n;
20567
20568 s = 0;
20569 pid = fork();
20570 if (pid == 0)
20571 exit (42);
20572
20573 /* wait for the process */
20574 p = wait(&s);
20575 if (p != pid)
20576 exit (255);
20577
20578 /* crack s */
20579 for (i = 0; i < (sizeof(s) * 8); i++)
20580 {
20581 n = (s >> i) & 0xff;
20582 if (n == 42)
20583 exit (i);
20584 }
20585
20586 exit (254);
20587}
20588
20589_ACEOF
20590if ac_fn_c_try_run "$LINENO"
20591then :
20592 bash_cv_wexitstatus_offset=0
20593else case e in #(
20594 e) bash_cv_wexitstatus_offset=$? ;;
20595esac
20596fi
20597rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20598 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20599esac
20600fi
20601 ;;
20602esac
20603fi
20604
20605if test "$bash_cv_wexitstatus_offset" -gt 32 ; then
20606 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: bad exit status from test program -- defaulting to 0" >&5
20607printf "%s\n" "$as_me: WARNING: bad exit status from test program -- defaulting to 0" >&2;}
20608 bash_cv_wexitstatus_offset=0
20609fi
20610{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wexitstatus_offset" >&5
20611printf "%s\n" "$bash_cv_wexitstatus_offset" >&6; }
20612
20613printf "%s\n" "#define WEXITSTATUS_OFFSET $bash_cv_wexitstatus_offset" >>confdefs.h
20614
20615
20616
20617
20618
20619 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5
20620printf %s "checking for struct timespec in <time.h>... " >&6; }
20621if test ${bash_cv_sys_struct_timespec_in_time_h+y}
20622then :
20623 printf %s "(cached) " >&6
20624else case e in #(
20625 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20626/* end confdefs.h. */
20627#include <time.h>
20628
20629int
20630main (void)
20631{
20632static struct timespec x; x.tv_sec = x.tv_nsec;
20633 ;
20634 return 0;
20635}
20636_ACEOF
20637if ac_fn_c_try_compile "$LINENO"
20638then :
20639 bash_cv_sys_struct_timespec_in_time_h=yes
20640else case e in #(
20641 e) bash_cv_sys_struct_timespec_in_time_h=no ;;
20642esac
20643fi
20644rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20645esac
20646fi
20647{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_time_h" >&5
20648printf "%s\n" "$bash_cv_sys_struct_timespec_in_time_h" >&6; }
20649
20650 HAVE_STRUCT_TIMESPEC=0
20651 TIME_H_DEFINES_STRUCT_TIMESPEC=0
20652 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0
20653 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0
20654 if test $bash_cv_sys_struct_timespec_in_time_h = yes; then
20655 printf "%s\n" "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
20656
20657 printf "%s\n" "#define TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h
20658
20659 TIME_H_DEFINES_STRUCT_TIMESPEC=1
20660 else
20661 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5
20662printf %s "checking for struct timespec in <sys/time.h>... " >&6; }
20663if test ${bash_cv_sys_struct_timespec_in_sys_time_h+y}
20664then :
20665 printf %s "(cached) " >&6
20666else case e in #(
20667 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20668/* end confdefs.h. */
20669#include <sys/time.h>
20670
20671int
20672main (void)
20673{
20674static struct timespec x; x.tv_sec = x.tv_nsec;
20675 ;
20676 return 0;
20677}
20678_ACEOF
20679if ac_fn_c_try_compile "$LINENO"
20680then :
20681 bash_cv_sys_struct_timespec_in_sys_time_h=yes
20682else case e in #(
20683 e) bash_cv_sys_struct_timespec_in_sys_time_h=no ;;
20684esac
20685fi
20686rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20687esac
20688fi
20689{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_sys_time_h" >&5
20690printf "%s\n" "$bash_cv_sys_struct_timespec_in_sys_time_h" >&6; }
20691 if test $bash_cv_sys_struct_timespec_in_sys_time_h = yes; then
20692 SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1
20693 printf "%s\n" "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
20694
20695 printf "%s\n" "#define SYS_TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h
20696
20697 else
20698 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5
20699printf %s "checking for struct timespec in <pthread.h>... " >&6; }
20700if test ${bash_cv_sys_struct_timespec_in_pthread_h+y}
20701then :
20702 printf %s "(cached) " >&6
20703else case e in #(
20704 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20705/* end confdefs.h. */
20706#include <pthread.h>
20707
20708int
20709main (void)
20710{
20711static struct timespec x; x.tv_sec = x.tv_nsec;
20712 ;
20713 return 0;
20714}
20715_ACEOF
20716if ac_fn_c_try_compile "$LINENO"
20717then :
20718 bash_cv_sys_struct_timespec_in_pthread_h=yes
20719else case e in #(
20720 e) bash_cv_sys_struct_timespec_in_pthread_h=no ;;
20721esac
20722fi
20723rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20724esac
20725fi
20726{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_pthread_h" >&5
20727printf "%s\n" "$bash_cv_sys_struct_timespec_in_pthread_h" >&6; }
20728 if test $bash_cv_sys_struct_timespec_in_pthread_h = yes; then
20729 PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1
20730 printf "%s\n" "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h
20731
20732 printf "%s\n" "#define PTHREAD_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h
20733
20734 fi
20735 fi
20736 fi
20737
20738
20739
20740
20741
20742
20743
20744
20745
20746 ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.tv_nsec" "ac_cv_member_struct_stat_st_atim_tv_nsec" "#include <sys/types.h>
20747 #include <sys/stat.h>
20748"
20749if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes
20750then :
20751
20752printf "%s\n" "#define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1" >>confdefs.h
20753
20754{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5
20755printf %s "checking whether struct stat.st_atim is of type struct timespec... " >&6; }
20756if test ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+y}
20757then :
20758 printf %s "(cached) " >&6
20759else case e in #(
20760 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20761/* end confdefs.h. */
20762
20763 #include <sys/types.h>
20764 #include <sys/stat.h>
20765 #if HAVE_SYS_TIME_H
20766 # include <sys/time.h>
20767 #endif
20768 #include <time.h>
20769 struct timespec ts;
20770 struct stat st;
20771
20772int
20773main (void)
20774{
20775
20776 st.st_atim = ts;
20777
20778 ;
20779 return 0;
20780}
20781_ACEOF
20782if ac_fn_c_try_compile "$LINENO"
20783then :
20784 ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes
20785else case e in #(
20786 e) ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no ;;
20787esac
20788fi
20789rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20790esac
20791fi
20792{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5
20793printf "%s\n" "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; }
20794 if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then
20795
20796printf "%s\n" "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h
20797
20798 fi
20799else case e in #(
20800 e) ac_fn_c_check_member "$LINENO" "struct stat" "st_atimespec.tv_nsec" "ac_cv_member_struct_stat_st_atimespec_tv_nsec" "#include <sys/types.h>
20801 #include <sys/stat.h>
20802"
20803if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes
20804then :
20805
20806printf "%s\n" "#define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1" >>confdefs.h
20807
20808
20809else case e in #(
20810 e) ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h>
20811 #include <sys/stat.h>
20812"
20813if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes
20814then :
20815
20816printf "%s\n" "#define HAVE_STRUCT_STAT_ST_ATIMENSEC 1" >>confdefs.h
20817
20818
20819else case e in #(
20820 e) ac_fn_c_check_member "$LINENO" "struct stat" "st_atim.st__tim.tv_nsec" "ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" "#include <sys/types.h>
20821 #include <sys/stat.h>
20822"
20823if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes
20824then :
20825
20826printf "%s\n" "#define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1" >>confdefs.h
20827
20828
20829fi
20830 ;;
20831esac
20832fi
20833 ;;
20834esac
20835fi
20836 ;;
20837esac
20838fi
20839
20840
20841
20842
20843 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for sbrk" >&5
20844printf %s "checking for sbrk... " >&6; }
20845 if test ${ac_cv_func_sbrk+y}
20846then :
20847 printf %s "(cached) " >&6
20848else case e in #(
20849 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20850/* end confdefs.h. */
20851#include <unistd.h>
20852int
20853main (void)
20854{
20855 void *x = sbrk (4096);
20856 ;
20857 return 0;
20858}
20859_ACEOF
20860if ac_fn_c_try_link "$LINENO"
20861then :
20862 ac_cv_func_sbrk=yes
20863else case e in #(
20864 e) ac_cv_func_sbrk=no ;;
20865esac
20866fi
20867rm -f core conftest.err conftest.$ac_objext conftest.beam \
20868 conftest$ac_exeext conftest.$ac_ext ;;
20869esac
20870fi
20871
20872 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_sbrk" >&5
20873printf "%s\n" "$ac_cv_func_sbrk" >&6; }
20874 if test X$ac_cv_func_sbrk = Xyes; then
20875 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working sbrk" >&5
20876printf %s "checking for working sbrk... " >&6; }
20877if test ${bash_cv_func_sbrk+y}
20878then :
20879 printf %s "(cached) " >&6
20880else case e in #(
20881 e) if test "$cross_compiling" = yes
20882then :
20883 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check working sbrk if cross-compiling" >&5
20884printf "%s\n" "$as_me: WARNING: cannot check working sbrk if cross-compiling" >&2;}
20885 bash_cv_func_sbrk=yes
20886
20887else case e in #(
20888 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20889/* end confdefs.h. */
20890
20891#include <stdlib.h>
20892#include <unistd.h>
20893
20894int
20895main(int c, char **v)
20896{
20897 void *x;
20898
20899 x = sbrk (4096);
20900 exit ((x == (void *)-1) ? 1 : 0);
20901}
20902
20903_ACEOF
20904if ac_fn_c_try_run "$LINENO"
20905then :
20906 bash_cv_func_sbrk=yes
20907else case e in #(
20908 e) bash_cv_func_sbrk=no ;;
20909esac
20910fi
20911rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
20912 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
20913esac
20914fi
20915 ;;
20916esac
20917fi
20918{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_sbrk" >&5
20919printf "%s\n" "$bash_cv_func_sbrk" >&6; }
20920 if test $bash_cv_func_sbrk = no; then
20921 ac_cv_func_sbrk=no
20922 fi
20923 fi
20924 if test $ac_cv_func_sbrk = yes; then
20925
20926printf "%s\n" "#define HAVE_SBRK 1" >>confdefs.h
20927
20928 fi
20929
20930
20931 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for brk" >&5
20932printf %s "checking for brk... " >&6; }
20933 if test ${ac_cv_func_brk+y}
20934then :
20935 printf %s "(cached) " >&6
20936else case e in #(
20937 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20938/* end confdefs.h. */
20939#include <unistd.h>
20940int
20941main (void)
20942{
20943 void *x = brk (0);
20944 ;
20945 return 0;
20946}
20947_ACEOF
20948if ac_fn_c_try_link "$LINENO"
20949then :
20950 ac_cv_func_brk=yes
20951else case e in #(
20952 e) ac_cv_func_brk=no ;;
20953esac
20954fi
20955rm -f core conftest.err conftest.$ac_objext conftest.beam \
20956 conftest$ac_exeext conftest.$ac_ext ;;
20957esac
20958fi
20959
20960 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_brk" >&5
20961printf "%s\n" "$ac_cv_func_brk" >&6; }
20962 if test X$ac_cv_func_brk = Xyes; then
20963 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for working brk" >&5
20964printf %s "checking for working brk... " >&6; }
20965if test ${bash_cv_func_brk+y}
20966then :
20967 printf %s "(cached) " >&6
20968else case e in #(
20969 e) if test "$cross_compiling" = yes
20970then :
20971 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check working brk if cross-compiling" >&5
20972printf "%s\n" "$as_me: WARNING: cannot check working brk if cross-compiling" >&2;}
20973 bash_cv_func_brk=yes
20974
20975else case e in #(
20976 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
20977/* end confdefs.h. */
20978
20979#include <stdlib.h>
20980#include <unistd.h>
20981
20982int
20983main(int c, char **v)
20984{
20985 void *x;
20986
20987 x = brk (0);
20988 exit ((x == (void *)-1) ? 1 : 0);
20989}
20990
20991_ACEOF
20992if ac_fn_c_try_run "$LINENO"
20993then :
20994 bash_cv_func_brk=yes
20995else case e in #(
20996 e) bash_cv_func_brk=no ;;
20997esac
20998fi
20999rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21000 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21001esac
21002fi
21003 ;;
21004esac
21005fi
21006{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_brk" >&5
21007printf "%s\n" "$bash_cv_func_brk" >&6; }
21008 if test $bash_cv_func_brk = no; then
21009 ac_cv_func_brk=no
21010 fi
21011 fi
21012 if test $ac_cv_func_brk = yes; then
21013
21014printf "%s\n" "#define HAVE_BRK 1" >>confdefs.h
21015
21016 fi
21017
21018
21019{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for the existence of strsignal" >&5
21020printf %s "checking for the existence of strsignal... " >&6; }
21021if test ${bash_cv_have_strsignal+y}
21022then :
21023 printf %s "(cached) " >&6
21024else case e in #(
21025 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21026/* end confdefs.h. */
21027#include <sys/types.h>
21028#include <signal.h>
21029#include <string.h>
21030int
21031main (void)
21032{
21033char *s = (char *)strsignal(2);
21034 ;
21035 return 0;
21036}
21037_ACEOF
21038if ac_fn_c_try_link "$LINENO"
21039then :
21040 bash_cv_have_strsignal=yes
21041else case e in #(
21042 e) bash_cv_have_strsignal=no ;;
21043esac
21044fi
21045rm -f core conftest.err conftest.$ac_objext conftest.beam \
21046 conftest$ac_exeext conftest.$ac_ext ;;
21047esac
21048fi
21049
21050{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_strsignal" >&5
21051printf "%s\n" "$bash_cv_have_strsignal" >&6; }
21052if test $bash_cv_have_strsignal = yes; then
21053printf "%s\n" "#define HAVE_STRSIGNAL 1" >>confdefs.h
21054
21055fi
21056
21057{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if opendir() opens non-directories" >&5
21058printf %s "checking if opendir() opens non-directories... " >&6; }
21059if test ${bash_cv_opendir_not_robust+y}
21060then :
21061 printf %s "(cached) " >&6
21062else case e in #(
21063 e) if test "$cross_compiling" = yes
21064then :
21065 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&5
21066printf "%s\n" "$as_me: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&2;}
21067 bash_cv_opendir_not_robust=no
21068
21069else case e in #(
21070 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21071/* end confdefs.h. */
21072
21073#include <stdio.h>
21074#include <sys/types.h>
21075#include <fcntl.h>
21076#ifdef HAVE_UNISTD_H
21077# include <unistd.h>
21078#endif /* HAVE_UNISTD_H */
21079#ifdef HAVE_SYS_STAT_H
21080#include <sys/stat.h>
21081#endif
21082#if defined(HAVE_DIRENT_H)
21083# include <dirent.h>
21084#else
21085# define dirent direct
21086# ifdef HAVE_SYS_NDIR_H
21087# include <sys/ndir.h>
21088# endif /* SYSNDIR */
21089# ifdef HAVE_SYS_DIR_H
21090# include <sys/dir.h>
21091# endif /* SYSDIR */
21092# ifdef HAVE_NDIR_H
21093# include <ndir.h>
21094# endif
21095#endif /* HAVE_DIRENT_H */
21096#include <stdlib.h>
21097int
21098main()
21099{
21100DIR *dir;
21101int fd, err;
21102err = mkdir("bash-aclocal", 0700);
21103if (err < 0) {
21104 perror("mkdir");
21105 exit(1);
21106}
21107unlink("bash-aclocal/not_a_directory");
21108fd = open("bash-aclocal/not_a_directory", O_WRONLY|O_CREAT|O_EXCL, 0666);
21109write(fd, "\n", 1);
21110close(fd);
21111dir = opendir("bash-aclocal/not_a_directory");
21112unlink("bash-aclocal/not_a_directory");
21113rmdir("bash-aclocal");
21114exit (dir == 0);
21115}
21116
21117_ACEOF
21118if ac_fn_c_try_run "$LINENO"
21119then :
21120 bash_cv_opendir_not_robust=yes
21121else case e in #(
21122 e) bash_cv_opendir_not_robust=no ;;
21123esac
21124fi
21125rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21126 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21127esac
21128fi
21129 ;;
21130esac
21131fi
21132
21133{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_opendir_not_robust" >&5
21134printf "%s\n" "$bash_cv_opendir_not_robust" >&6; }
21135if test $bash_cv_opendir_not_robust = yes; then
21136printf "%s\n" "#define OPENDIR_NOT_ROBUST 1" >>confdefs.h
21137
21138fi
21139
21140{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether ulimit can substitute for getdtablesize" >&5
21141printf %s "checking whether ulimit can substitute for getdtablesize... " >&6; }
21142if test ${bash_cv_ulimit_maxfds+y}
21143then :
21144 printf %s "(cached) " >&6
21145else case e in #(
21146 e) if test "$cross_compiling" = yes
21147then :
21148 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&5
21149printf "%s\n" "$as_me: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&2;}
21150 bash_cv_ulimit_maxfds=no
21151
21152else case e in #(
21153 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21154/* end confdefs.h. */
21155
21156#include <stdlib.h>
21157#ifdef HAVE_ULIMIT_H
21158#include <ulimit.h>
21159#endif
21160int
21161main()
21162{
21163long maxfds = ulimit(4, 0L);
21164exit (maxfds == -1L);
21165}
21166
21167_ACEOF
21168if ac_fn_c_try_run "$LINENO"
21169then :
21170 bash_cv_ulimit_maxfds=yes
21171else case e in #(
21172 e) bash_cv_ulimit_maxfds=no ;;
21173esac
21174fi
21175rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21176 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21177esac
21178fi
21179 ;;
21180esac
21181fi
21182
21183{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_ulimit_maxfds" >&5
21184printf "%s\n" "$bash_cv_ulimit_maxfds" >&6; }
21185if test $bash_cv_ulimit_maxfds = yes; then
21186printf "%s\n" "#define ULIMIT_MAXFDS 1" >>confdefs.h
21187
21188fi
21189
21190
21191
21192
21193
21194
21195 ac_fn_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h>
21196" "$ac_c_undeclared_builtin_options" "CFLAGS"
21197if test "x$ac_cv_have_decl_fpurge" = xyes
21198then :
21199 ac_have_decl=1
21200else case e in #(
21201 e) ac_have_decl=0 ;;
21202esac
21203fi
21204printf "%s\n" "#define HAVE_DECL_FPURGE $ac_have_decl" >>confdefs.h
21205
21206
21207{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking to see if getenv can be redefined" >&5
21208printf %s "checking to see if getenv can be redefined... " >&6; }
21209if test ${bash_cv_getenv_redef+y}
21210then :
21211 printf %s "(cached) " >&6
21212else case e in #(
21213 e) if test "$cross_compiling" = yes
21214then :
21215 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&5
21216printf "%s\n" "$as_me: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&2;}
21217 bash_cv_getenv_redef=yes
21218
21219else case e in #(
21220 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21221/* end confdefs.h. */
21222
21223#ifdef HAVE_UNISTD_H
21224# include <unistd.h>
21225#endif
21226#include <stdlib.h>
21227char *
21228getenv (const char *name)
21229{
21230return "42";
21231}
21232int
21233main()
21234{
21235char *s;
21236/* The next allows this program to run, but does not allow bash to link
21237 when it redefines getenv. I'm not really interested in figuring out
21238 why not. */
21239#if defined (NeXT)
21240exit(1);
21241#endif
21242s = getenv("ABCDE");
21243exit(s == 0); /* force optimizer to leave getenv in */
21244}
21245
21246_ACEOF
21247if ac_fn_c_try_run "$LINENO"
21248then :
21249 bash_cv_getenv_redef=yes
21250else case e in #(
21251 e) bash_cv_getenv_redef=no ;;
21252esac
21253fi
21254rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21255 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21256esac
21257fi
21258 ;;
21259esac
21260fi
21261
21262{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getenv_redef" >&5
21263printf "%s\n" "$bash_cv_getenv_redef" >&6; }
21264if test $bash_cv_getenv_redef = yes; then
21265printf "%s\n" "#define CAN_REDEFINE_GETENV 1" >>confdefs.h
21266
21267fi
21268
21269if test "$ac_cv_func_getcwd" = "yes"; then
21270{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if getcwd() will dynamically allocate memory with 0 size" >&5
21271printf %s "checking if getcwd() will dynamically allocate memory with 0 size... " >&6; }
21272if test ${bash_cv_getcwd_malloc+y}
21273then :
21274 printf %s "(cached) " >&6
21275else case e in #(
21276 e) if test "$cross_compiling" = yes
21277then :
21278 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&5
21279printf "%s\n" "$as_me: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&2;}
21280 bash_cv_getcwd_malloc=no
21281
21282else case e in #(
21283 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21284/* end confdefs.h. */
21285
21286#include <stdio.h>
21287#ifdef HAVE_UNISTD_H
21288#include <unistd.h>
21289#endif
21290#include <stdlib.h>
21291
21292int
21293main()
21294{
21295 char *xpwd;
21296 xpwd = getcwd(0, 0);
21297 exit (xpwd == 0);
21298}
21299
21300_ACEOF
21301if ac_fn_c_try_run "$LINENO"
21302then :
21303 bash_cv_getcwd_malloc=yes
21304else case e in #(
21305 e) bash_cv_getcwd_malloc=no ;;
21306esac
21307fi
21308rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21309 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21310esac
21311fi
21312 ;;
21313esac
21314fi
21315
21316{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getcwd_malloc" >&5
21317printf "%s\n" "$bash_cv_getcwd_malloc" >&6; }
21318if test $bash_cv_getcwd_malloc = no; then
21319printf "%s\n" "#define GETCWD_BROKEN 1" >>confdefs.h
21320
21321case " $LIBOBJS " in
21322 *" getcwd.$ac_objext "* ) ;;
21323 *) LIBOBJS="$LIBOBJS getcwd.$ac_objext"
21324 ;;
21325esac
21326
21327fi
21328
21329fi
21330printf "%s\n" "#define HAVE_GETCWD 1" >>confdefs.h
21331
21332
21333{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5
21334printf %s "checking for presence of POSIX-style sigsetjmp/siglongjmp... " >&6; }
21335if test ${bash_cv_func_sigsetjmp+y}
21336then :
21337 printf %s "(cached) " >&6
21338else case e in #(
21339 e) if test "$cross_compiling" = yes
21340then :
21341 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to $bash_cv_posix_signals" >&5
21342printf "%s\n" "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to $bash_cv_posix_signals" >&2;}
21343 if test "$bash_cv_posix_signals" = "yes" ; then
21344 bash_cv_func_sigsetjmp=present
21345 else
21346 bash_cv_func_sigsetjmp=missing
21347 fi
21348
21349else case e in #(
21350 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21351/* end confdefs.h. */
21352
21353#ifdef HAVE_UNISTD_H
21354#include <unistd.h>
21355#endif
21356#include <sys/types.h>
21357#include <signal.h>
21358#include <setjmp.h>
21359#include <stdlib.h>
21360
21361int
21362main()
21363{
21364#if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS)
21365exit (1);
21366#else
21367
21368int code;
21369sigset_t set, oset, nset;
21370sigjmp_buf xx;
21371
21372/* get the mask */
21373sigemptyset(&set);
21374sigemptyset(&oset);
21375
21376sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset);
21377/* paranoia -- make sure SIGINT is not blocked */
21378sigdelset (&oset, SIGINT);
21379sigprocmask (SIG_SETMASK, &oset, (sigset_t *)NULL);
21380
21381/* save it */
21382code = sigsetjmp(xx, 1);
21383if (code)
21384{
21385 sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &nset);
21386 /* could compare nset to oset here, but we just look for SIGINT */
21387 if (sigismember (&nset, SIGINT))
21388 exit(1);
21389 exit(0);
21390}
21391
21392/* change it so that SIGINT is blocked */
21393sigaddset(&set, SIGINT);
21394sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL);
21395
21396/* and siglongjmp */
21397siglongjmp(xx, 10);
21398exit(1);
21399#endif
21400}
21401
21402_ACEOF
21403if ac_fn_c_try_run "$LINENO"
21404then :
21405 bash_cv_func_sigsetjmp=present
21406else case e in #(
21407 e) bash_cv_func_sigsetjmp=missing ;;
21408esac
21409fi
21410rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21411 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21412esac
21413fi
21414 ;;
21415esac
21416fi
21417
21418{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_sigsetjmp" >&5
21419printf "%s\n" "$bash_cv_func_sigsetjmp" >&6; }
21420if test $bash_cv_func_sigsetjmp = present; then
21421printf "%s\n" "#define HAVE_POSIX_SIGSETJMP 1" >>confdefs.h
21422
21423fi
21424
21425{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether or not strcoll and strcmp differ" >&5
21426printf %s "checking whether or not strcoll and strcmp differ... " >&6; }
21427if test ${bash_cv_func_strcoll_broken+y}
21428then :
21429 printf %s "(cached) " >&6
21430else case e in #(
21431 e) if test "$cross_compiling" = yes
21432then :
21433 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5
21434printf "%s\n" "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;}
21435 bash_cv_func_strcoll_broken=no
21436
21437else case e in #(
21438 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21439/* end confdefs.h. */
21440
21441#include <stdio.h>
21442#if defined (HAVE_LOCALE_H)
21443#include <locale.h>
21444#endif
21445#include <string.h>
21446#include <stdlib.h>
21447
21448int
21449main(int c, char **v)
21450{
21451 int r1, r2;
21452 char *deflocale, *defcoll;
21453
21454#ifdef HAVE_SETLOCALE
21455 deflocale = setlocale(LC_ALL, "");
21456 defcoll = setlocale(LC_COLLATE, "");
21457#endif
21458
21459#ifdef HAVE_STRCOLL
21460 /* These two values are taken from tests/glob-test. */
21461 r1 = strcoll("abd", "aXd");
21462#else
21463 r1 = 0;
21464#endif
21465 r2 = strcmp("abd", "aXd");
21466
21467 /* These two should both be greater than 0. It is permissible for
21468 a system to return different values, as long as the sign is the
21469 same. */
21470
21471 /* Exit with 1 (failure) if these two values are both > 0, since
21472 this tests whether strcoll(3) is broken with respect to strcmp(3)
21473 in the default locale. */
21474 exit (r1 > 0 && r2 > 0);
21475}
21476
21477_ACEOF
21478if ac_fn_c_try_run "$LINENO"
21479then :
21480 bash_cv_func_strcoll_broken=yes
21481else case e in #(
21482 e) bash_cv_func_strcoll_broken=no ;;
21483esac
21484fi
21485rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21486 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21487esac
21488fi
21489 ;;
21490esac
21491fi
21492
21493{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_strcoll_broken" >&5
21494printf "%s\n" "$bash_cv_func_strcoll_broken" >&6; }
21495if test $bash_cv_func_strcoll_broken = yes; then
21496printf "%s\n" "#define STRCOLL_BROKEN 1" >>confdefs.h
21497
21498fi
21499
21500
21501
21502
21503 if test X$ac_cv_func_snprintf = Xyes; then
21504 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for standard-conformant snprintf" >&5
21505printf %s "checking for standard-conformant snprintf... " >&6; }
21506if test ${bash_cv_func_snprintf+y}
21507then :
21508 printf %s "(cached) " >&6
21509else case e in #(
21510 e) if test "$cross_compiling" = yes
21511then :
21512 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard snprintf if cross-compiling" >&5
21513printf "%s\n" "$as_me: WARNING: cannot check standard snprintf if cross-compiling" >&2;}
21514 bash_cv_func_snprintf=yes
21515
21516else case e in #(
21517 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21518/* end confdefs.h. */
21519
21520#include <stdio.h>
21521#include <stdlib.h>
21522
21523int
21524main()
21525{
21526 int n;
21527 n = snprintf (0, 0, "%s", "0123456");
21528 exit(n != 7);
21529}
21530
21531_ACEOF
21532if ac_fn_c_try_run "$LINENO"
21533then :
21534 bash_cv_func_snprintf=yes
21535else case e in #(
21536 e) bash_cv_func_snprintf=no ;;
21537esac
21538fi
21539rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21540 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21541esac
21542fi
21543 ;;
21544esac
21545fi
21546{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_snprintf" >&5
21547printf "%s\n" "$bash_cv_func_snprintf" >&6; }
21548 if test $bash_cv_func_snprintf = no; then
21549 ac_cv_func_snprintf=no
21550 fi
21551 fi
21552 if test $ac_cv_func_snprintf = no; then
21553
21554printf "%s\n" "#define HAVE_SNPRINTF 0" >>confdefs.h
21555
21556 fi
21557
21558
21559
21560
21561 if test X$ac_cv_func_vsnprintf = Xyes; then
21562 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for standard-conformant vsnprintf" >&5
21563printf %s "checking for standard-conformant vsnprintf... " >&6; }
21564if test ${bash_cv_func_vsnprintf+y}
21565then :
21566 printf %s "(cached) " >&6
21567else case e in #(
21568 e) if test "$cross_compiling" = yes
21569then :
21570 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard vsnprintf if cross-compiling" >&5
21571printf "%s\n" "$as_me: WARNING: cannot check standard vsnprintf if cross-compiling" >&2;}
21572 bash_cv_func_vsnprintf=yes
21573
21574else case e in #(
21575 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21576/* end confdefs.h. */
21577
21578#include <stdarg.h>
21579#include <stdio.h>
21580#include <stdlib.h>
21581
21582static int
21583foo(const char *fmt, ...)
21584{
21585 va_list args;
21586 int n;
21587
21588 va_start(args, fmt);
21589 n = vsnprintf(0, 0, fmt, args);
21590 va_end (args);
21591 return n;
21592}
21593
21594int
21595main()
21596{
21597 int n;
21598 n = foo("%s", "0123456");
21599 exit(n != 7);
21600}
21601
21602_ACEOF
21603if ac_fn_c_try_run "$LINENO"
21604then :
21605 bash_cv_func_vsnprintf=yes
21606else case e in #(
21607 e) bash_cv_func_vsnprintf=no ;;
21608esac
21609fi
21610rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21611 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21612esac
21613fi
21614 ;;
21615esac
21616fi
21617{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_vsnprintf" >&5
21618printf "%s\n" "$bash_cv_func_vsnprintf" >&6; }
21619 if test $bash_cv_func_vsnprintf = no; then
21620 ac_cv_func_vsnprintf=no
21621 fi
21622 fi
21623 if test $ac_cv_func_vsnprintf = no; then
21624
21625printf "%s\n" "#define HAVE_VSNPRINTF 0" >>confdefs.h
21626
21627 fi
21628
21629
21630
21631 ac_fn_c_check_func "$LINENO" "strtoimax" "ac_cv_func_strtoimax"
21632if test "x$ac_cv_func_strtoimax" = xyes
21633then :
21634 printf "%s\n" "#define HAVE_STRTOIMAX 1" >>confdefs.h
21635
21636fi
21637
21638 ac_fn_check_decl "$LINENO" "strtoimax" "ac_cv_have_decl_strtoimax" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21639if test "x$ac_cv_have_decl_strtoimax" = xyes
21640then :
21641 ac_have_decl=1
21642else case e in #(
21643 e) ac_have_decl=0 ;;
21644esac
21645fi
21646printf "%s\n" "#define HAVE_DECL_STRTOIMAX $ac_have_decl" >>confdefs.h
21647
21648
21649 if test "$ac_cv_func_strtoimax" != "yes" ; then
21650 case " $LIBOBJS " in
21651 *" strtoimax.$ac_objext "* ) ;;
21652 *) LIBOBJS="$LIBOBJS strtoimax.$ac_objext"
21653 ;;
21654esac
21655
21656 fi
21657
21658ac_fn_check_decl "$LINENO" "clearerr_unlocked" "ac_cv_have_decl_clearerr_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21659if test "x$ac_cv_have_decl_clearerr_unlocked" = xyes
21660then :
21661 ac_have_decl=1
21662else case e in #(
21663 e) ac_have_decl=0 ;;
21664esac
21665fi
21666printf "%s\n" "#define HAVE_DECL_CLEARERR_UNLOCKED $ac_have_decl" >>confdefs.h
21667
21668ac_fn_check_decl "$LINENO" "feof_unlocked" "ac_cv_have_decl_feof_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21669if test "x$ac_cv_have_decl_feof_unlocked" = xyes
21670then :
21671 ac_have_decl=1
21672else case e in #(
21673 e) ac_have_decl=0 ;;
21674esac
21675fi
21676printf "%s\n" "#define HAVE_DECL_FEOF_UNLOCKED $ac_have_decl" >>confdefs.h
21677
21678ac_fn_check_decl "$LINENO" "ferror_unlocked" "ac_cv_have_decl_ferror_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21679if test "x$ac_cv_have_decl_ferror_unlocked" = xyes
21680then :
21681 ac_have_decl=1
21682else case e in #(
21683 e) ac_have_decl=0 ;;
21684esac
21685fi
21686printf "%s\n" "#define HAVE_DECL_FERROR_UNLOCKED $ac_have_decl" >>confdefs.h
21687
21688ac_fn_check_decl "$LINENO" "fflush_unlocked" "ac_cv_have_decl_fflush_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21689if test "x$ac_cv_have_decl_fflush_unlocked" = xyes
21690then :
21691 ac_have_decl=1
21692else case e in #(
21693 e) ac_have_decl=0 ;;
21694esac
21695fi
21696printf "%s\n" "#define HAVE_DECL_FFLUSH_UNLOCKED $ac_have_decl" >>confdefs.h
21697
21698ac_fn_check_decl "$LINENO" "fgets_unlocked" "ac_cv_have_decl_fgets_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21699if test "x$ac_cv_have_decl_fgets_unlocked" = xyes
21700then :
21701 ac_have_decl=1
21702else case e in #(
21703 e) ac_have_decl=0 ;;
21704esac
21705fi
21706printf "%s\n" "#define HAVE_DECL_FGETS_UNLOCKED $ac_have_decl" >>confdefs.h
21707
21708ac_fn_check_decl "$LINENO" "fputc_unlocked" "ac_cv_have_decl_fputc_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21709if test "x$ac_cv_have_decl_fputc_unlocked" = xyes
21710then :
21711 ac_have_decl=1
21712else case e in #(
21713 e) ac_have_decl=0 ;;
21714esac
21715fi
21716printf "%s\n" "#define HAVE_DECL_FPUTC_UNLOCKED $ac_have_decl" >>confdefs.h
21717
21718ac_fn_check_decl "$LINENO" "fputs_unlocked" "ac_cv_have_decl_fputs_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21719if test "x$ac_cv_have_decl_fputs_unlocked" = xyes
21720then :
21721 ac_have_decl=1
21722else case e in #(
21723 e) ac_have_decl=0 ;;
21724esac
21725fi
21726printf "%s\n" "#define HAVE_DECL_FPUTS_UNLOCKED $ac_have_decl" >>confdefs.h
21727
21728ac_fn_check_decl "$LINENO" "fread_unlocked" "ac_cv_have_decl_fread_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21729if test "x$ac_cv_have_decl_fread_unlocked" = xyes
21730then :
21731 ac_have_decl=1
21732else case e in #(
21733 e) ac_have_decl=0 ;;
21734esac
21735fi
21736printf "%s\n" "#define HAVE_DECL_FREAD_UNLOCKED $ac_have_decl" >>confdefs.h
21737
21738ac_fn_check_decl "$LINENO" "fwrite_unlocked" "ac_cv_have_decl_fwrite_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21739if test "x$ac_cv_have_decl_fwrite_unlocked" = xyes
21740then :
21741 ac_have_decl=1
21742else case e in #(
21743 e) ac_have_decl=0 ;;
21744esac
21745fi
21746printf "%s\n" "#define HAVE_DECL_FWRITE_UNLOCKED $ac_have_decl" >>confdefs.h
21747
21748ac_fn_check_decl "$LINENO" "getc_unlocked" "ac_cv_have_decl_getc_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21749if test "x$ac_cv_have_decl_getc_unlocked" = xyes
21750then :
21751 ac_have_decl=1
21752else case e in #(
21753 e) ac_have_decl=0 ;;
21754esac
21755fi
21756printf "%s\n" "#define HAVE_DECL_GETC_UNLOCKED $ac_have_decl" >>confdefs.h
21757
21758ac_fn_check_decl "$LINENO" "getchar_unlocked" "ac_cv_have_decl_getchar_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21759if test "x$ac_cv_have_decl_getchar_unlocked" = xyes
21760then :
21761 ac_have_decl=1
21762else case e in #(
21763 e) ac_have_decl=0 ;;
21764esac
21765fi
21766printf "%s\n" "#define HAVE_DECL_GETCHAR_UNLOCKED $ac_have_decl" >>confdefs.h
21767
21768ac_fn_check_decl "$LINENO" "putc_unlocked" "ac_cv_have_decl_putc_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21769if test "x$ac_cv_have_decl_putc_unlocked" = xyes
21770then :
21771 ac_have_decl=1
21772else case e in #(
21773 e) ac_have_decl=0 ;;
21774esac
21775fi
21776printf "%s\n" "#define HAVE_DECL_PUTC_UNLOCKED $ac_have_decl" >>confdefs.h
21777
21778ac_fn_check_decl "$LINENO" "putchar_unlocked" "ac_cv_have_decl_putchar_unlocked" "$ac_includes_default" "$ac_c_undeclared_builtin_options" "CFLAGS"
21779if test "x$ac_cv_have_decl_putchar_unlocked" = xyes
21780then :
21781 ac_have_decl=1
21782else case e in #(
21783 e) ac_have_decl=0 ;;
21784esac
21785fi
21786printf "%s\n" "#define HAVE_DECL_PUTCHAR_UNLOCKED $ac_have_decl" >>confdefs.h
21787
21788
21789
21790
21791
21792
21793
21794
21795
21796
21797
21798
21799
21800
21801
21802
21803
21804
21805
21806
21807if test "$ac_cv_func_putenv" = "yes"; then
21808
21809{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for standard-conformant putenv declaration" >&5
21810printf %s "checking for standard-conformant putenv declaration... " >&6; }
21811if test ${bash_cv_std_putenv+y}
21812then :
21813 printf %s "(cached) " >&6
21814else case e in #(
21815 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21816/* end confdefs.h. */
21817
21818#if HAVE_STDLIB_H
21819#include <stdlib.h>
21820#endif
21821#if HAVE_STDDEF_H
21822#include <stddef.h>
21823#endif
21824extern int putenv (char *);
21825
21826int
21827main (void)
21828{
21829return (putenv == 0);
21830 ;
21831 return 0;
21832}
21833_ACEOF
21834if ac_fn_c_try_link "$LINENO"
21835then :
21836 bash_cv_std_putenv=yes
21837else case e in #(
21838 e) bash_cv_std_putenv=no
21839 ;;
21840esac
21841fi
21842rm -f core conftest.err conftest.$ac_objext conftest.beam \
21843 conftest$ac_exeext conftest.$ac_ext ;;
21844esac
21845fi
21846{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_putenv" >&5
21847printf "%s\n" "$bash_cv_std_putenv" >&6; }
21848if test $bash_cv_std_putenv = yes; then
21849printf "%s\n" "#define HAVE_STD_PUTENV 1" >>confdefs.h
21850
21851fi
21852
21853else
21854printf "%s\n" "#define HAVE_STD_PUTENV 1" >>confdefs.h
21855
21856fi
21857if test "$ac_cv_func_unsetenv" = "yes"; then
21858
21859{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for standard-conformant unsetenv declaration" >&5
21860printf %s "checking for standard-conformant unsetenv declaration... " >&6; }
21861if test ${bash_cv_std_unsetenv+y}
21862then :
21863 printf %s "(cached) " >&6
21864else case e in #(
21865 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21866/* end confdefs.h. */
21867
21868#if HAVE_STDLIB_H
21869#include <stdlib.h>
21870#endif
21871#if HAVE_STDDEF_H
21872#include <stddef.h>
21873#endif
21874extern int unsetenv (const char *);
21875
21876int
21877main (void)
21878{
21879return (unsetenv == 0);
21880 ;
21881 return 0;
21882}
21883_ACEOF
21884if ac_fn_c_try_link "$LINENO"
21885then :
21886 bash_cv_std_unsetenv=yes
21887else case e in #(
21888 e) bash_cv_std_unsetenv=no
21889 ;;
21890esac
21891fi
21892rm -f core conftest.err conftest.$ac_objext conftest.beam \
21893 conftest$ac_exeext conftest.$ac_ext ;;
21894esac
21895fi
21896{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_unsetenv" >&5
21897printf "%s\n" "$bash_cv_std_unsetenv" >&6; }
21898if test $bash_cv_std_unsetenv = yes; then
21899printf "%s\n" "#define HAVE_STD_UNSETENV 1" >>confdefs.h
21900
21901fi
21902
21903else
21904printf "%s\n" "#define HAVE_STD_UNSETENV 1" >>confdefs.h
21905
21906fi
21907
21908{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for printf floating point output in hex notation" >&5
21909printf %s "checking for printf floating point output in hex notation... " >&6; }
21910if test ${bash_cv_printf_a_format+y}
21911then :
21912 printf %s "(cached) " >&6
21913else case e in #(
21914 e) if test "$cross_compiling" = yes
21915then :
21916 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check printf if cross compiling -- defaulting to no" >&5
21917printf "%s\n" "$as_me: WARNING: cannot check printf if cross compiling -- defaulting to no" >&2;}
21918 bash_cv_printf_a_format=no
21919
21920else case e in #(
21921 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21922/* end confdefs.h. */
21923
21924#include <stdio.h>
21925#include <string.h>
21926#include <stdlib.h>
21927
21928int
21929main()
21930{
21931 double y = 0.0;
21932 char abuf[1024];
21933
21934 sprintf(abuf, "%A", y);
21935 exit(strchr(abuf, 'P') == (char *)0);
21936}
21937
21938_ACEOF
21939if ac_fn_c_try_run "$LINENO"
21940then :
21941 bash_cv_printf_a_format=yes
21942else case e in #(
21943 e) bash_cv_printf_a_format=no ;;
21944esac
21945fi
21946rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
21947 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
21948esac
21949fi
21950 ;;
21951esac
21952fi
21953
21954{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_printf_a_format" >&5
21955printf "%s\n" "$bash_cv_printf_a_format" >&6; }
21956if test $bash_cv_printf_a_format = yes; then
21957printf "%s\n" "#define HAVE_PRINTF_A_FORMAT 1" >>confdefs.h
21958
21959fi
21960
21961
21962{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether fnmatch can be used to check bracket equivalence classes" >&5
21963printf %s "checking whether fnmatch can be used to check bracket equivalence classes... " >&6; }
21964if test ${bash_cv_fnmatch_equiv_fallback+y}
21965then :
21966 printf %s "(cached) " >&6
21967else case e in #(
21968 e) if test "$cross_compiling" = yes
21969then :
21970 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check fnmatch if cross compiling -- defaulting to no" >&5
21971printf "%s\n" "$as_me: WARNING: cannot check fnmatch if cross compiling -- defaulting to no" >&2;}
21972 bash_cv_fnmatch_equiv_fallback=no
21973
21974else case e in #(
21975 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
21976/* end confdefs.h. */
21977
21978#include <stdlib.h>
21979#include <unistd.h>
21980#include <stdio.h>
21981#include <fnmatch.h>
21982#include <locale.h>
21983
21984char *pattern = "[[=a=]]";
21985
21986/* char *string = "ä"; */
21987unsigned char string[4] = { '\xc3', '\xa4', '\0' };
21988
21989int
21990main (int c, char **v)
21991{
21992 setlocale (LC_ALL, "en_US.UTF-8");
21993 if (fnmatch (pattern, (const char *)string, 0) != FNM_NOMATCH)
21994 exit (0);
21995 exit (1);
21996}
21997
21998_ACEOF
21999if ac_fn_c_try_run "$LINENO"
22000then :
22001 bash_cv_fnmatch_equiv_fallback=yes
22002else case e in #(
22003 e) bash_cv_fnmatch_equiv_fallback=no ;;
22004esac
22005fi
22006rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22007 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22008esac
22009fi
22010 ;;
22011esac
22012fi
22013
22014{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_fnmatch_equiv_fallback" >&5
22015printf "%s\n" "$bash_cv_fnmatch_equiv_fallback" >&6; }
22016if test "$bash_cv_fnmatch_equiv_fallback" = "yes" ; then
22017 bash_cv_fnmatch_equiv_value=1
22018else
22019 bash_cv_fnmatch_equiv_value=0
22020fi
22021
22022printf "%s\n" "#define FNMATCH_EQUIV_FALLBACK $bash_cv_fnmatch_equiv_value" >>confdefs.h
22023
22024
22025
22026
22027{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking if signal handlers must be reinstalled when invoked" >&5
22028printf %s "checking if signal handlers must be reinstalled when invoked... " >&6; }
22029if test ${bash_cv_must_reinstall_sighandlers+y}
22030then :
22031 printf %s "(cached) " >&6
22032else case e in #(
22033 e) if test "$cross_compiling" = yes
22034then :
22035 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5
22036printf "%s\n" "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;}
22037 bash_cv_must_reinstall_sighandlers=no
22038
22039else case e in #(
22040 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22041/* end confdefs.h. */
22042
22043#include <signal.h>
22044#ifdef HAVE_UNISTD_H
22045#include <unistd.h>
22046#endif
22047#include <stdlib.h>
22048
22049typedef void sigfunc(int);
22050
22051volatile int nsigint;
22052
22053#ifdef HAVE_POSIX_SIGNALS
22054sigfunc *
22055set_signal_handler(int sig, sigfunc *handler)
22056{
22057 struct sigaction act, oact;
22058 act.sa_handler = handler;
22059 act.sa_flags = 0;
22060 sigemptyset (&act.sa_mask);
22061 sigemptyset (&oact.sa_mask);
22062 sigaction (sig, &act, &oact);
22063 return (oact.sa_handler);
22064}
22065#else
22066#define set_signal_handler(s, h) signal(s, h)
22067#endif
22068
22069void
22070sigint(int s)
22071{
22072 nsigint++;
22073}
22074
22075int
22076main()
22077{
22078 nsigint = 0;
22079 set_signal_handler(SIGINT, sigint);
22080 kill((int)getpid(), SIGINT);
22081 kill((int)getpid(), SIGINT);
22082 exit(nsigint != 2);
22083}
22084
22085_ACEOF
22086if ac_fn_c_try_run "$LINENO"
22087then :
22088 bash_cv_must_reinstall_sighandlers=no
22089else case e in #(
22090 e) bash_cv_must_reinstall_sighandlers=yes ;;
22091esac
22092fi
22093rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22094 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22095esac
22096fi
22097 ;;
22098esac
22099fi
22100
22101{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_must_reinstall_sighandlers" >&5
22102printf "%s\n" "$bash_cv_must_reinstall_sighandlers" >&6; }
22103if test $bash_cv_must_reinstall_sighandlers = yes; then
22104printf "%s\n" "#define MUST_REINSTALL_SIGHANDLERS 1" >>confdefs.h
22105
22106fi
22107
22108
22109{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for presence of necessary job control definitions" >&5
22110printf %s "checking for presence of necessary job control definitions... " >&6; }
22111if test ${bash_cv_job_control_missing+y}
22112then :
22113 printf %s "(cached) " >&6
22114else case e in #(
22115 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22116/* end confdefs.h. */
22117
22118#include <sys/types.h>
22119#ifdef HAVE_SYS_WAIT_H
22120#include <sys/wait.h>
22121#endif
22122#ifdef HAVE_UNISTD_H
22123#include <unistd.h>
22124#endif
22125#include <signal.h>
22126
22127/* add more tests in here as appropriate */
22128
22129/* signal type */
22130#if !defined (HAVE_POSIX_SIGNALS) && !defined (HAVE_BSD_SIGNALS)
22131#error
22132#endif
22133
22134/* signals and tty control. */
22135#if !defined (SIGTSTP) || !defined (SIGSTOP) || !defined (SIGCONT)
22136#error
22137#endif
22138
22139/* process control */
22140#if !defined (WNOHANG) || !defined (WUNTRACED)
22141#error
22142#endif
22143
22144/* Posix systems have tcgetpgrp and waitpid. */
22145#if defined (_POSIX_VERSION) && !defined (HAVE_TCGETPGRP)
22146#error
22147#endif
22148
22149#if defined (_POSIX_VERSION) && !defined (HAVE_WAITPID)
22150#error
22151#endif
22152
22153/* Other systems have TIOCSPGRP/TIOCGPRGP and wait3. */
22154#if !defined (_POSIX_VERSION) && !defined (HAVE_WAIT3)
22155#error
22156#endif
22157
22158
22159int
22160main (void)
22161{
22162 int x;
22163 ;
22164 return 0;
22165}
22166_ACEOF
22167if ac_fn_c_try_compile "$LINENO"
22168then :
22169 bash_cv_job_control_missing=present
22170else case e in #(
22171 e) bash_cv_job_control_missing=missing
22172 ;;
22173esac
22174fi
22175rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22176esac
22177fi
22178
22179{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_job_control_missing" >&5
22180printf "%s\n" "$bash_cv_job_control_missing" >&6; }
22181if test $bash_cv_job_control_missing = missing; then
22182printf "%s\n" "#define JOB_CONTROL_MISSING 1" >>confdefs.h
22183
22184fi
22185
22186{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for presence of named pipes" >&5
22187printf %s "checking for presence of named pipes... " >&6; }
22188if test ${bash_cv_sys_named_pipes+y}
22189then :
22190 printf %s "(cached) " >&6
22191else case e in #(
22192 e) if test "$cross_compiling" = yes
22193then :
22194 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&5
22195printf "%s\n" "$as_me: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&2;}
22196 bash_cv_sys_named_pipes=missing
22197
22198else case e in #(
22199 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22200/* end confdefs.h. */
22201
22202#include <sys/types.h>
22203#include <sys/stat.h>
22204#ifdef HAVE_UNISTD_H
22205#include <unistd.h>
22206#endif
22207#include <stdio.h>
22208#include <stdlib.h>
22209
22210/* Add more tests in here as appropriate. */
22211int
22212main()
22213{
22214int fd, err;
22215
22216#if defined (HAVE_MKFIFO)
22217exit (0);
22218#endif
22219
22220#if !defined (S_IFIFO) && (defined (_POSIX_VERSION) && !defined (S_ISFIFO))
22221exit (1);
22222#endif
22223
22224#if defined (NeXT)
22225exit (1);
22226#endif
22227err = mkdir("bash-aclocal", 0700);
22228if (err < 0) {
22229 perror ("mkdir");
22230 exit(1);
22231}
22232fd = mknod ("bash-aclocal/sh-np-autoconf", 0666 | S_IFIFO, 0);
22233if (fd == -1) {
22234 rmdir ("bash-aclocal");
22235 exit (1);
22236}
22237close(fd);
22238unlink ("bash-aclocal/sh-np-autoconf");
22239rmdir ("bash-aclocal");
22240exit(0);
22241}
22242
22243_ACEOF
22244if ac_fn_c_try_run "$LINENO"
22245then :
22246 bash_cv_sys_named_pipes=present
22247else case e in #(
22248 e) bash_cv_sys_named_pipes=missing ;;
22249esac
22250fi
22251rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22252 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22253esac
22254fi
22255 ;;
22256esac
22257fi
22258
22259{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_named_pipes" >&5
22260printf "%s\n" "$bash_cv_sys_named_pipes" >&6; }
22261if test $bash_cv_sys_named_pipes = missing; then
22262printf "%s\n" "#define NAMED_PIPES_MISSING 1" >>confdefs.h
22263
22264fi
22265
22266
22267{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether termios.h defines TIOCGWINSZ" >&5
22268printf %s "checking whether termios.h defines TIOCGWINSZ... " >&6; }
22269if test ${ac_cv_sys_tiocgwinsz_in_termios_h+y}
22270then :
22271 printf %s "(cached) " >&6
22272else case e in #(
22273 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22274/* end confdefs.h. */
22275$ac_includes_default
22276#include <termios.h>
22277const int tiocgwinsz = TIOCGWINSZ;
22278
22279_ACEOF
22280if ac_fn_c_try_compile "$LINENO"
22281then :
22282 ac_cv_sys_tiocgwinsz_in_termios_h=yes
22283else case e in #(
22284 e) ac_cv_sys_tiocgwinsz_in_termios_h=no ;;
22285esac
22286fi
22287rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22288esac
22289fi
22290{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5
22291printf "%s\n" "$ac_cv_sys_tiocgwinsz_in_termios_h" >&6; }
22292
22293if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then
22294 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5
22295printf %s "checking whether sys/ioctl.h defines TIOCGWINSZ... " >&6; }
22296if test ${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+y}
22297then :
22298 printf %s "(cached) " >&6
22299else case e in #(
22300 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22301/* end confdefs.h. */
22302$ac_includes_default
22303#include <sys/ioctl.h>
22304const int tiocgwinsz = TIOCGWINSZ;
22305
22306_ACEOF
22307if ac_fn_c_try_compile "$LINENO"
22308then :
22309 ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes
22310else case e in #(
22311 e) ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no ;;
22312esac
22313fi
22314rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22315esac
22316fi
22317{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5
22318printf "%s\n" "$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6; }
22319
22320 if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then
22321
22322printf "%s\n" "#define GWINSZ_IN_SYS_IOCTL 1" >>confdefs.h
22323
22324 fi
22325fi
22326
22327{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for TIOCSTAT in sys/ioctl.h" >&5
22328printf %s "checking for TIOCSTAT in sys/ioctl.h... " >&6; }
22329if test ${bash_cv_tiocstat_in_ioctl+y}
22330then :
22331 printf %s "(cached) " >&6
22332else case e in #(
22333 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22334/* end confdefs.h. */
22335
22336#include <sys/types.h>
22337#include <sys/ioctl.h>
22338int
22339main (void)
22340{
22341int x = TIOCSTAT;
22342 ;
22343 return 0;
22344}
22345_ACEOF
22346if ac_fn_c_try_compile "$LINENO"
22347then :
22348 bash_cv_tiocstat_in_ioctl=yes
22349else case e in #(
22350 e) bash_cv_tiocstat_in_ioctl=no
22351 ;;
22352esac
22353fi
22354rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22355esac
22356fi
22357
22358{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_tiocstat_in_ioctl" >&5
22359printf "%s\n" "$bash_cv_tiocstat_in_ioctl" >&6; }
22360if test $bash_cv_tiocstat_in_ioctl = yes; then
22361printf "%s\n" "#define TIOCSTAT_IN_SYS_IOCTL 1" >>confdefs.h
22362
22363fi
22364
22365{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for FIONREAD in sys/ioctl.h" >&5
22366printf %s "checking for FIONREAD in sys/ioctl.h... " >&6; }
22367if test ${bash_cv_fionread_in_ioctl+y}
22368then :
22369 printf %s "(cached) " >&6
22370else case e in #(
22371 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22372/* end confdefs.h. */
22373
22374#include <sys/types.h>
22375#include <sys/ioctl.h>
22376int
22377main (void)
22378{
22379int x = FIONREAD;
22380 ;
22381 return 0;
22382}
22383_ACEOF
22384if ac_fn_c_try_compile "$LINENO"
22385then :
22386 bash_cv_fionread_in_ioctl=yes
22387else case e in #(
22388 e) bash_cv_fionread_in_ioctl=no
22389 ;;
22390esac
22391fi
22392rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22393esac
22394fi
22395
22396{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_fionread_in_ioctl" >&5
22397printf "%s\n" "$bash_cv_fionread_in_ioctl" >&6; }
22398if test $bash_cv_fionread_in_ioctl = yes; then
22399printf "%s\n" "#define FIONREAD_IN_SYS_IOCTL 1" >>confdefs.h
22400
22401fi
22402
22403
22404
22405{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether WCONTINUED flag to waitpid is unavailable or available but broken" >&5
22406printf %s "checking whether WCONTINUED flag to waitpid is unavailable or available but broken... " >&6; }
22407if test ${bash_cv_wcontinued_broken+y}
22408then :
22409 printf %s "(cached) " >&6
22410else case e in #(
22411 e) if test "$cross_compiling" = yes
22412then :
22413 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&5
22414printf "%s\n" "$as_me: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&2;}
22415 bash_cv_wcontinued_broken=no
22416
22417else case e in #(
22418 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22419/* end confdefs.h. */
22420
22421#include <sys/types.h>
22422#include <sys/wait.h>
22423#include <unistd.h>
22424#include <errno.h>
22425#include <stdlib.h>
22426
22427#ifndef errno
22428extern int errno;
22429#endif
22430int
22431main()
22432{
22433 int x;
22434
22435 x = waitpid(-1, (int *)0, WNOHANG|WCONTINUED);
22436 if (x == -1 && errno == EINVAL)
22437 exit (1);
22438 else
22439 exit (0);
22440}
22441
22442_ACEOF
22443if ac_fn_c_try_run "$LINENO"
22444then :
22445 bash_cv_wcontinued_broken=no
22446else case e in #(
22447 e) bash_cv_wcontinued_broken=yes ;;
22448esac
22449fi
22450rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22451 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22452esac
22453fi
22454 ;;
22455esac
22456fi
22457
22458{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcontinued_broken" >&5
22459printf "%s\n" "$bash_cv_wcontinued_broken" >&6; }
22460if test $bash_cv_wcontinued_broken = yes; then
22461printf "%s\n" "#define WCONTINUED_BROKEN 1" >>confdefs.h
22462
22463fi
22464
22465
22466{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for speed_t in sys/types.h" >&5
22467printf %s "checking for speed_t in sys/types.h... " >&6; }
22468if test ${bash_cv_speed_t_in_sys_types+y}
22469then :
22470 printf %s "(cached) " >&6
22471else case e in #(
22472 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22473/* end confdefs.h. */
22474#include <sys/types.h>
22475int
22476main (void)
22477{
22478speed_t x;
22479 ;
22480 return 0;
22481}
22482_ACEOF
22483if ac_fn_c_try_compile "$LINENO"
22484then :
22485 bash_cv_speed_t_in_sys_types=yes
22486else case e in #(
22487 e) bash_cv_speed_t_in_sys_types=no ;;
22488esac
22489fi
22490rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22491esac
22492fi
22493
22494{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_speed_t_in_sys_types" >&5
22495printf "%s\n" "$bash_cv_speed_t_in_sys_types" >&6; }
22496if test $bash_cv_speed_t_in_sys_types = yes; then
22497printf "%s\n" "#define SPEED_T_IN_SYS_TYPES 1" >>confdefs.h
22498
22499fi
22500
22501{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether getpw functions are declared in pwd.h" >&5
22502printf %s "checking whether getpw functions are declared in pwd.h... " >&6; }
22503if test ${bash_cv_getpw_declared+y}
22504then :
22505 printf %s "(cached) " >&6
22506else case e in #(
22507 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22508/* end confdefs.h. */
22509
22510#include <sys/types.h>
22511#ifdef HAVE_UNISTD_H
22512# include <unistd.h>
22513#endif
22514#include <pwd.h>
22515
22516_ACEOF
22517if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
22518 $EGREP_TRADITIONAL "getpwuid" >/dev/null 2>&1
22519then :
22520 bash_cv_getpw_declared=yes
22521else case e in #(
22522 e) bash_cv_getpw_declared=no ;;
22523esac
22524fi
22525rm -rf conftest*
22526 ;;
22527esac
22528fi
22529
22530{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getpw_declared" >&5
22531printf "%s\n" "$bash_cv_getpw_declared" >&6; }
22532if test $bash_cv_getpw_declared = yes; then
22533printf "%s\n" "#define HAVE_GETPW_DECLS 1" >>confdefs.h
22534
22535fi
22536
22537{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for unusable real-time signals due to large values" >&5
22538printf %s "checking for unusable real-time signals due to large values... " >&6; }
22539if test ${bash_cv_unusable_rtsigs+y}
22540then :
22541 printf %s "(cached) " >&6
22542else case e in #(
22543 e) if test "$cross_compiling" = yes
22544then :
22545 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&5
22546printf "%s\n" "$as_me: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&2;}
22547 bash_cv_unusable_rtsigs=yes
22548
22549else case e in #(
22550 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22551/* end confdefs.h. */
22552
22553#include <sys/types.h>
22554#include <signal.h>
22555#include <stdlib.h>
22556
22557#ifndef NSIG
22558# define NSIG 64
22559#endif
22560
22561int
22562main ()
22563{
22564 int n_sigs = 2 * NSIG;
22565#ifdef SIGRTMIN
22566 int rtmin = SIGRTMIN;
22567#else
22568 int rtmin = 0;
22569#endif
22570
22571 exit(rtmin < n_sigs);
22572}
22573
22574_ACEOF
22575if ac_fn_c_try_run "$LINENO"
22576then :
22577 bash_cv_unusable_rtsigs=yes
22578else case e in #(
22579 e) bash_cv_unusable_rtsigs=no ;;
22580esac
22581fi
22582rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
22583 conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22584esac
22585fi
22586 ;;
22587esac
22588fi
22589
22590{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_unusable_rtsigs" >&5
22591printf "%s\n" "$bash_cv_unusable_rtsigs" >&6; }
22592if test $bash_cv_unusable_rtsigs = yes; then
22593printf "%s\n" "#define UNUSABLE_RT_SIGNALS 1" >>confdefs.h
22594
22595fi
22596
22597
22598
22599
22600
22601if test "$bash_cv_sys_siglist" = no && test "$bash_cv_under_sys_siglist" = no && test "$bash_cv_have_strsignal" = no; then
22602 SIGLIST_O=siglist.o
22603else
22604 SIGLIST_O=
22605fi
22606
22607
22608
22609case "$host_os" in
22610hpux*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether $host_os needs _KERNEL for RLIMIT defines" >&5
22611printf %s "checking whether $host_os needs _KERNEL for RLIMIT defines... " >&6; }
22612if test ${bash_cv_kernel_rlimit+y}
22613then :
22614 printf %s "(cached) " >&6
22615else case e in #(
22616 e) if test ${bash_cv_rlimit+y}
22617then :
22618 printf %s "(cached) " >&6
22619else case e in #(
22620 e) cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22621/* end confdefs.h. */
22622
22623#include <sys/types.h>
22624#include <sys/resource.h>
22625
22626int
22627main (void)
22628{
22629
22630 int f;
22631 f = RLIMIT_DATA;
22632
22633 ;
22634 return 0;
22635}
22636_ACEOF
22637if ac_fn_c_try_compile "$LINENO"
22638then :
22639 bash_cv_rlimit=yes
22640else case e in #(
22641 e) bash_cv_rlimit=no
22642 ;;
22643esac
22644fi
22645rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext ;;
22646esac
22647fi
22648
22649
22650if test $bash_cv_rlimit = no; then
22651cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22652/* end confdefs.h. */
22653
22654#include <sys/types.h>
22655#define _KERNEL
22656#include <sys/resource.h>
22657#undef _KERNEL
22658
22659int
22660main (void)
22661{
22662
22663 int f;
22664 f = RLIMIT_DATA;
22665
22666 ;
22667 return 0;
22668}
22669_ACEOF
22670if ac_fn_c_try_compile "$LINENO"
22671then :
22672 bash_cv_kernel_rlimit=yes
22673else case e in #(
22674 e) bash_cv_kernel_rlimit=no ;;
22675esac
22676fi
22677rm -f core conftest.err conftest.$ac_objext conftest.beam conftest.$ac_ext
22678fi
22679 ;;
22680esac
22681fi
22682
22683{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_kernel_rlimit" >&5
22684printf "%s\n" "$bash_cv_kernel_rlimit" >&6; }
22685if test $bash_cv_kernel_rlimit = yes; then
22686printf "%s\n" "#define RLIMIT_NEEDS_KERNEL 1" >>confdefs.h
22687
22688fi
22689 ;;
22690esac
22691
22692if test "$opt_readline" = yes; then
22693case "$host_os" in
22694aix*) prefer_curses=yes ;;
22695esac
22696
22697if test "X$bash_cv_termcap_lib" = "X"; then
22698_bash_needmsg=yes
22699else
22700{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5
22701printf %s "checking which library has the termcap functions... " >&6; }
22702_bash_needmsg=
22703fi
22704if test ${bash_cv_termcap_lib+y}
22705then :
22706 printf %s "(cached) " >&6
22707else case e in #(
22708 e) ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent"
22709if test "x$ac_cv_func_tgetent" = xyes
22710then :
22711 bash_cv_termcap_lib=libc
22712else case e in #(
22713 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5
22714printf %s "checking for tgetent in -ltermcap... " >&6; }
22715if test ${ac_cv_lib_termcap_tgetent+y}
22716then :
22717 printf %s "(cached) " >&6
22718else case e in #(
22719 e) ac_check_lib_save_LIBS=$LIBS
22720LIBS="-ltermcap $LIBS"
22721cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22722/* end confdefs.h. */
22723
22724/* Override any GCC internal prototype to avoid an error.
22725 Use char because int might match the return type of a GCC
22726 builtin and then its argument prototype would still apply.
22727 The 'extern "C"' is for builds by C++ compilers;
22728 although this is not generally supported in C code supporting it here
22729 has little cost and some practical benefit (sr 110532). */
22730#ifdef __cplusplus
22731extern "C"
22732#endif
22733char tgetent (void);
22734int
22735main (void)
22736{
22737return tgetent ();
22738 ;
22739 return 0;
22740}
22741_ACEOF
22742if ac_fn_c_try_link "$LINENO"
22743then :
22744 ac_cv_lib_termcap_tgetent=yes
22745else case e in #(
22746 e) ac_cv_lib_termcap_tgetent=no ;;
22747esac
22748fi
22749rm -f core conftest.err conftest.$ac_objext conftest.beam \
22750 conftest$ac_exeext conftest.$ac_ext
22751LIBS=$ac_check_lib_save_LIBS ;;
22752esac
22753fi
22754{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5
22755printf "%s\n" "$ac_cv_lib_termcap_tgetent" >&6; }
22756if test "x$ac_cv_lib_termcap_tgetent" = xyes
22757then :
22758 bash_cv_termcap_lib=libtermcap
22759else case e in #(
22760 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5
22761printf %s "checking for tgetent in -ltinfo... " >&6; }
22762if test ${ac_cv_lib_tinfo_tgetent+y}
22763then :
22764 printf %s "(cached) " >&6
22765else case e in #(
22766 e) ac_check_lib_save_LIBS=$LIBS
22767LIBS="-ltinfo $LIBS"
22768cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22769/* end confdefs.h. */
22770
22771/* Override any GCC internal prototype to avoid an error.
22772 Use char because int might match the return type of a GCC
22773 builtin and then its argument prototype would still apply.
22774 The 'extern "C"' is for builds by C++ compilers;
22775 although this is not generally supported in C code supporting it here
22776 has little cost and some practical benefit (sr 110532). */
22777#ifdef __cplusplus
22778extern "C"
22779#endif
22780char tgetent (void);
22781int
22782main (void)
22783{
22784return tgetent ();
22785 ;
22786 return 0;
22787}
22788_ACEOF
22789if ac_fn_c_try_link "$LINENO"
22790then :
22791 ac_cv_lib_tinfo_tgetent=yes
22792else case e in #(
22793 e) ac_cv_lib_tinfo_tgetent=no ;;
22794esac
22795fi
22796rm -f core conftest.err conftest.$ac_objext conftest.beam \
22797 conftest$ac_exeext conftest.$ac_ext
22798LIBS=$ac_check_lib_save_LIBS ;;
22799esac
22800fi
22801{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5
22802printf "%s\n" "$ac_cv_lib_tinfo_tgetent" >&6; }
22803if test "x$ac_cv_lib_tinfo_tgetent" = xyes
22804then :
22805 bash_cv_termcap_lib=libtinfo
22806else case e in #(
22807 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5
22808printf %s "checking for tgetent in -lcurses... " >&6; }
22809if test ${ac_cv_lib_curses_tgetent+y}
22810then :
22811 printf %s "(cached) " >&6
22812else case e in #(
22813 e) ac_check_lib_save_LIBS=$LIBS
22814LIBS="-lcurses $LIBS"
22815cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22816/* end confdefs.h. */
22817
22818/* Override any GCC internal prototype to avoid an error.
22819 Use char because int might match the return type of a GCC
22820 builtin and then its argument prototype would still apply.
22821 The 'extern "C"' is for builds by C++ compilers;
22822 although this is not generally supported in C code supporting it here
22823 has little cost and some practical benefit (sr 110532). */
22824#ifdef __cplusplus
22825extern "C"
22826#endif
22827char tgetent (void);
22828int
22829main (void)
22830{
22831return tgetent ();
22832 ;
22833 return 0;
22834}
22835_ACEOF
22836if ac_fn_c_try_link "$LINENO"
22837then :
22838 ac_cv_lib_curses_tgetent=yes
22839else case e in #(
22840 e) ac_cv_lib_curses_tgetent=no ;;
22841esac
22842fi
22843rm -f core conftest.err conftest.$ac_objext conftest.beam \
22844 conftest$ac_exeext conftest.$ac_ext
22845LIBS=$ac_check_lib_save_LIBS ;;
22846esac
22847fi
22848{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5
22849printf "%s\n" "$ac_cv_lib_curses_tgetent" >&6; }
22850if test "x$ac_cv_lib_curses_tgetent" = xyes
22851then :
22852 bash_cv_termcap_lib=libcurses
22853else case e in #(
22854 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncursesw" >&5
22855printf %s "checking for tgetent in -lncursesw... " >&6; }
22856if test ${ac_cv_lib_ncursesw_tgetent+y}
22857then :
22858 printf %s "(cached) " >&6
22859else case e in #(
22860 e) ac_check_lib_save_LIBS=$LIBS
22861LIBS="-lncursesw $LIBS"
22862cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22863/* end confdefs.h. */
22864
22865/* Override any GCC internal prototype to avoid an error.
22866 Use char because int might match the return type of a GCC
22867 builtin and then its argument prototype would still apply.
22868 The 'extern "C"' is for builds by C++ compilers;
22869 although this is not generally supported in C code supporting it here
22870 has little cost and some practical benefit (sr 110532). */
22871#ifdef __cplusplus
22872extern "C"
22873#endif
22874char tgetent (void);
22875int
22876main (void)
22877{
22878return tgetent ();
22879 ;
22880 return 0;
22881}
22882_ACEOF
22883if ac_fn_c_try_link "$LINENO"
22884then :
22885 ac_cv_lib_ncursesw_tgetent=yes
22886else case e in #(
22887 e) ac_cv_lib_ncursesw_tgetent=no ;;
22888esac
22889fi
22890rm -f core conftest.err conftest.$ac_objext conftest.beam \
22891 conftest$ac_exeext conftest.$ac_ext
22892LIBS=$ac_check_lib_save_LIBS ;;
22893esac
22894fi
22895{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncursesw_tgetent" >&5
22896printf "%s\n" "$ac_cv_lib_ncursesw_tgetent" >&6; }
22897if test "x$ac_cv_lib_ncursesw_tgetent" = xyes
22898then :
22899 bash_cv_termcap_lib=libncursesw
22900else case e in #(
22901 e) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5
22902printf %s "checking for tgetent in -lncurses... " >&6; }
22903if test ${ac_cv_lib_ncurses_tgetent+y}
22904then :
22905 printf %s "(cached) " >&6
22906else case e in #(
22907 e) ac_check_lib_save_LIBS=$LIBS
22908LIBS="-lncurses $LIBS"
22909cat confdefs.h - <<_ACEOF >conftest.$ac_ext
22910/* end confdefs.h. */
22911
22912/* Override any GCC internal prototype to avoid an error.
22913 Use char because int might match the return type of a GCC
22914 builtin and then its argument prototype would still apply.
22915 The 'extern "C"' is for builds by C++ compilers;
22916 although this is not generally supported in C code supporting it here
22917 has little cost and some practical benefit (sr 110532). */
22918#ifdef __cplusplus
22919extern "C"
22920#endif
22921char tgetent (void);
22922int
22923main (void)
22924{
22925return tgetent ();
22926 ;
22927 return 0;
22928}
22929_ACEOF
22930if ac_fn_c_try_link "$LINENO"
22931then :
22932 ac_cv_lib_ncurses_tgetent=yes
22933else case e in #(
22934 e) ac_cv_lib_ncurses_tgetent=no ;;
22935esac
22936fi
22937rm -f core conftest.err conftest.$ac_objext conftest.beam \
22938 conftest$ac_exeext conftest.$ac_ext
22939LIBS=$ac_check_lib_save_LIBS ;;
22940esac
22941fi
22942{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5
22943printf "%s\n" "$ac_cv_lib_ncurses_tgetent" >&6; }
22944if test "x$ac_cv_lib_ncurses_tgetent" = xyes
22945then :
22946 bash_cv_termcap_lib=libncurses
22947else case e in #(
22948 e) bash_cv_termcap_lib=gnutermcap ;;
22949esac
22950fi
22951 ;;
22952esac
22953fi
22954 ;;
22955esac
22956fi
22957 ;;
22958esac
22959fi
22960 ;;
22961esac
22962fi
22963 ;;
22964esac
22965fi
22966 ;;
22967esac
22968fi
22969
22970if test "X$_bash_needmsg" = "Xyes"; then
22971{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5
22972printf %s "checking which library has the termcap functions... " >&6; }
22973fi
22974{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5
22975printf "%s\n" "using $bash_cv_termcap_lib" >&6; }
22976if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then
22977LDFLAGS="$LDFLAGS -L./lib/termcap"
22978TERMCAP_LIB="./lib/termcap/libtermcap.a"
22979TERMCAP_DEP="./lib/termcap/libtermcap.a"
22980elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then
22981TERMCAP_LIB=-ltermcap
22982TERMCAP_DEP=
22983elif test $bash_cv_termcap_lib = libtinfo; then
22984TERMCAP_LIB=-ltinfo
22985TERMCAP_DEP=
22986elif test $bash_cv_termcap_lib = libncursesw; then
22987TERMCAP_LIB=-lncursesw
22988TERMCAP_DEP=
22989elif test $bash_cv_termcap_lib = libncurses; then
22990TERMCAP_LIB=-lncurses
22991TERMCAP_DEP=
22992elif test $bash_cv_termcap_lib = libcurses; then
22993TERMCAP_LIB=-lcurses
22994TERMCAP_DEP=
22995elif test $bash_cv_termcap_lib = libc; then
22996TERMCAP_LIB=
22997TERMCAP_DEP=
22998else
22999# we assume ncurses is installed somewhere the linker can find it
23000TERMCAP_LIB=-lncurses
23001TERMCAP_DEP=
23002fi
23003
23004fi
23005
23006
23007
23008{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether /dev/fd is available" >&5
23009printf %s "checking whether /dev/fd is available... " >&6; }
23010if test ${bash_cv_dev_fd+y}
23011then :
23012 printf %s "(cached) " >&6
23013else case e in #(
23014 e) bash_cv_dev_fd=""
23015if test -d /dev/fd && (exec test -r /dev/fd/0 < /dev/null) ; then
23016# check for systems like FreeBSD 5 that only provide /dev/fd/[012]
23017 if (exec test -r /dev/fd/3 3</dev/null) ; then
23018 bash_cv_dev_fd=standard
23019 else
23020 bash_cv_dev_fd=absent
23021 fi
23022elif test "$host_os" = "openedition" && (exec test -r /dev/fd0 < /dev/null); then
23023 bash_cv_dev_fd=nodir # /dev/fdN via character device
23024fi
23025if test -z "$bash_cv_dev_fd" ; then
23026 if test -d /proc/self/fd && (exec test -r /proc/self/fd/0 < /dev/null) ; then
23027 bash_cv_dev_fd=whacky
23028 else
23029 bash_cv_dev_fd=absent
23030 fi
23031fi
23032 ;;
23033esac
23034fi
23035
23036{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_fd" >&5
23037printf "%s\n" "$bash_cv_dev_fd" >&6; }
23038if test $bash_cv_dev_fd = "standard"; then
23039 printf "%s\n" "#define HAVE_DEV_FD 1" >>confdefs.h
23040
23041 printf "%s\n" "#define DEV_FD_PREFIX \"/dev/fd/\"" >>confdefs.h
23042
23043elif test $bash_cv_dev_fd = "whacky"; then
23044 printf "%s\n" "#define HAVE_DEV_FD 1" >>confdefs.h
23045
23046 printf "%s\n" "#define DEV_FD_PREFIX \"/proc/self/fd/\"" >>confdefs.h
23047
23048elif test $bash_cv_dev_fd = "nodir"; then
23049 printf "%s\n" "#define HAVE_DEV_FD 1" >>confdefs.h
23050
23051 printf "%s\n" "#define DEV_FD_PREFIX \"/dev/fd\"" >>confdefs.h
23052
23053fi
23054
23055{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether /dev/stdin stdout stderr are available" >&5
23056printf %s "checking whether /dev/stdin stdout stderr are available... " >&6; }
23057if test ${bash_cv_dev_stdin+y}
23058then :
23059 printf %s "(cached) " >&6
23060else case e in #(
23061 e) if (exec test -r /dev/stdin < /dev/null) ; then
23062 bash_cv_dev_stdin=present
23063 else
23064 bash_cv_dev_stdin=absent
23065 fi
23066 ;;
23067esac
23068fi
23069
23070{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_stdin" >&5
23071printf "%s\n" "$bash_cv_dev_stdin" >&6; }
23072if test $bash_cv_dev_stdin = "present"; then
23073 printf "%s\n" "#define HAVE_DEV_STDIN 1" >>confdefs.h
23074
23075fi
23076
23077{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for default mail directory" >&5
23078printf %s "checking for default mail directory... " >&6; }
23079if test ${bash_cv_mail_dir+y}
23080then :
23081 printf %s "(cached) " >&6
23082else case e in #(
23083 e) if test -d /var/mail; then
23084 bash_cv_mail_dir=/var/mail
23085 elif test -d /var/spool/mail; then
23086 bash_cv_mail_dir=/var/spool/mail
23087 elif test -d /usr/mail; then
23088 bash_cv_mail_dir=/usr/mail
23089 elif test -d /usr/spool/mail; then
23090 bash_cv_mail_dir=/usr/spool/mail
23091 else
23092 bash_cv_mail_dir=unknown
23093 fi
23094 ;;
23095esac
23096fi
23097
23098{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $bash_cv_mail_dir" >&5
23099printf "%s\n" "$bash_cv_mail_dir" >&6; }
23100printf "%s\n" "#define DEFAULT_MAIL_DIRECTORY \"$bash_cv_mail_dir\"" >>confdefs.h
23101
23102
23103
23104if test "$bash_cv_job_control_missing" = missing; then
23105 opt_job_control=no
23106fi
23107
23108if test "$opt_job_control" = yes; then
23109printf "%s\n" "#define JOB_CONTROL 1" >>confdefs.h
23110
23111JOBS_O=jobs.o
23112else
23113JOBS_O=nojobs.o
23114fi
23115
23116
23117
23118
23119LOCAL_DEFS=-DSHELL
23120
23121
23122case "${host_os}" in
23123sysv4.2*) printf "%s\n" "#define SVR4_2 1" >>confdefs.h
23124
23125 printf "%s\n" "#define SVR4 1" >>confdefs.h
23126 ;;
23127sysv4*) printf "%s\n" "#define SVR4 1" >>confdefs.h
23128 ;;
23129sysv5*) printf "%s\n" "#define SVR5 1" >>confdefs.h
23130 ;;
23131hpux9*) LOCAL_CFLAGS="-DHPUX9 -DHPUX -DTGETENT_BROKEN -DTGETFLAG_BROKEN" ;;
23132hpux*) LOCAL_CFLAGS="-DHPUX -DTGETENT_BROKEN -DTGETFLAG_BROKEN" ;;
23133dgux*) LOCAL_CFLAGS=-D_DGUX_SOURCE; LOCAL_LIBS=-ldgc ;;
23134isc*) LOCAL_CFLAGS=-Disc386 ;;
23135rhapsody*) LOCAL_CFLAGS=-DRHAPSODY ;;
23136darwin*) LOCAL_CFLAGS=-DMACOSX ;;
23137sco3.2v5*) LOCAL_CFLAGS="-b elf -DWAITPID_BROKEN -DPATH_MAX=1024" ;;
23138sco3.2v4*) LOCAL_CFLAGS="-DMUST_UNBLOCK_CHLD -DPATH_MAX=1024" ;;
23139sco3.2*) LOCAL_CFLAGS=-DMUST_UNBLOCK_CHLD ;;
23140sunos4*) LOCAL_CFLAGS=-DSunOS4 ;;
23141solaris2.5*) LOCAL_CFLAGS="-DSunOS5 -DSOLARIS" ;;
23142solaris2.8*) LOCAL_CFLAGS=-DSOLARIS ;;
23143solaris2.9*) LOCAL_CFLAGS=-DSOLARIS ;;
23144solaris2.10*) LOCAL_CFLAGS=-DSOLARIS ;;
23145solaris2*) LOCAL_CFLAGS=-DSOLARIS ;;
23146lynxos*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;;
23147linux*) LOCAL_LDFLAGS=-rdynamic # allow dynamic loading
23148 case "`uname -r`" in
23149 1.*|2.[0123]*) : ;;
23150 *) printf "%s\n" "#define PGRP_PIPE 1" >>confdefs.h
23151 ;;
23152 esac ;;
23153netbsd*|openbsd*) LOCAL_CFLAGS="-DDEV_FD_STAT_BROKEN" ;;
23154freebsd*|midnightbsd*) LOCAL_CFLAGS='-DHEREDOC_PIPESIZE=4096' ;;
23155*qnx[67]*) LOCAL_LIBS="-lncurses" ;;
23156*qnx*) LOCAL_CFLAGS="-Dqnx -F -3s" LOCAL_LDFLAGS="-3s" LOCAL_LIBS="-lunix -lncurses" ;;
23157powerux*) LOCAL_LIBS="-lgen" ;;
23158cygwin*|msys*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;;
23159opennt*|interix*) LOCAL_CFLAGS="-DNO_MAIN_ENV_ARG -DBROKEN_DIRENT_D_INO -D_POSIX_SOURCE -D_ALL_SOURCE -DRECYCLES_PIDS" ;;
23160*openstep*) LOCAL_CFLAGS="-D__APPLE_CC__" ;;
23161esac
23162
23163case "${host_os}-${CC}" in
23164aix4.2*-*gcc*) LOCAL_LDFLAGS="-Xlinker -bexpall -Xlinker -brtl" ;;
23165aix4.2*) LOCAL_LDFLAGS="-bexpall -brtl" ;;
23166bsdi4*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux
23167bsdi5*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux
23168hpux11*-gcc*) LOCAL_LDFLAGS="-Wl,-E" ;; # allow dynamic loading
23169esac
23170
23171case "${host_os}" in
23172freebsd[3-9]*)
23173 if test -x /usr/bin/objformat && test "`/usr/bin/objformat`" = "elf" ; then
23174 LOCAL_LDFLAGS=-rdynamic # allow dynamic loading
23175 fi ;;
23176freebsd*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading
23177openbsd*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading
23178netbsd*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading
23179dragonfly*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading
23180midnightbsd*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading
23181esac
23182
23183case "$host_cpu" in
23184*cray*) LOCAL_CFLAGS="-DCRAY" ;; # shell var so config.h can use it
23185esac
23186
23187case "$host_cpu-$host_os" in
23188ibmrt-*bsd4*) LOCAL_CFLAGS="-ma -U__STDC__" ;;
23189esac
23190
23191case "$host_cpu-$host_vendor-$host_os" in
23192m88k-motorola-sysv3) LOCAL_CFLAGS=-DWAITPID_BROKEN ;;
23193mips-pyramid-sysv4) LOCAL_CFLAGS=-Xa ;;
23194esac
23195
23196# turn off paren warnings in gcc
23197#CFLAGS="$CFLAGS ${STYLE_CFLAGS}"
23198
23199#
23200# Shared object configuration section. These values are generated by
23201# ${srcdir}/support/shobj-conf
23202#
23203if test "$ac_cv_func_dlopen" = "yes" && test -f ${srcdir}/support/shobj-conf
23204then
23205 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking shared object configuration for loadable builtins" >&5
23206printf %s "checking shared object configuration for loadable builtins... " >&6; }
23207 eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c "${host_cpu}" -o "${host_os}" -v "${host_vendor}"`
23208
23209
23210
23211
23212
23213
23214
23215 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $SHOBJ_STATUS" >&5
23216printf "%s\n" "$SHOBJ_STATUS" >&6; }
23217else
23218 SHOBJ_STATUS=unsupported
23219
23220fi
23221
23222# try to create a directory tree if the source is elsewhere
23223# this should be packaged into a script accessible via ${srcdir}/support
23224case "$srcdir" in
23225.) ;;
23226*) for d in doc tests support lib examples; do # dirs
23227 test -d $d || mkdir $d
23228 done
23229 for ld in readline glob tilde malloc sh termcap; do # libdirs
23230 test -d lib/$ld || mkdir lib/$ld
23231 done
23232 test -d examples/loadables || mkdir examples/loadables # loadable builtins
23233 test -d examples/loadables/perl || mkdir examples/loadables/perl
23234 ;;
23235esac
23236
23237BUILD_DIR=`pwd`
23238case "$BUILD_DIR" in
23239*\ *) BUILD_DIR=`echo "$BUILD_DIR" | sed 's: :\\\\ :g'` ;;
23240*) ;;
23241esac
23242
23243if test -z "$localedir"; then
23244 localedir='${datarootdir}/locale'
23245fi
23246if test -z "$datarootdir"; then
23247 datarootdir='${prefix}/share'
23248fi
23249
23250
23251
23252
23253
23254
23255# Some versions of autoconf don't substitute these automatically
23256
23257
23258
23259# directory where we install dynamically loadable builtins
23260if test -z "$loadablesdir"; then
23261 loadablesdir='${libdir}/bash'
23262fi
23263
23264if test -z "$headersdir"; then
23265 headersdir='$(includedir)/$(PACKAGE_NAME)'
23266fi
23267
23268
23269
23270
23271
23272
23273
23274
23275
23276
23277
23278
23279
23280
23281
23282
23283
23284
23285
23286
23287#AC_SUBST(ALLOCA_SOURCE)
23288#AC_SUBST(ALLOCA_OBJECT)
23289
23290ac_config_files="$ac_config_files Makefile builtins/Makefile lib/readline/Makefile lib/glob/Makefile lib/intl/Makefile lib/malloc/Makefile lib/sh/Makefile lib/termcap/Makefile lib/tilde/Makefile doc/Makefile support/Makefile po/Makefile.in examples/loadables/Makefile examples/loadables/Makefile.inc examples/loadables/Makefile.sample examples/loadables/perl/Makefile support/bash.pc support/bashbug.sh"
23291
23292
23293ac_config_commands="$ac_config_commands stamp-h"
23294
23295
23296if test "$ac_cv_header_stdckdint_h" = yes; then
23297 rm -f stdckdint.h
23298 STDCKDINT_H=
23299elif cmp ${srcdir}/include/stdckdint.in.h stdckdint.h 2>/dev/null; then
23300 :
23301 STDCKDINT_H='${BUILD_DIR}/stdckdint.h'
23302else
23303 cp ${srcdir}/include/stdckdint.in.h stdckdint.h
23304 STDCKDINT_H='${BUILD_DIR}/stdckdint.h'
23305fi
23306
23307
23308cat >confcache <<\_ACEOF
23309# This file is a shell script that caches the results of configure
23310# tests run on this system so they can be shared between configure
23311# scripts and configure runs, see configure's option --config-cache.
23312# It is not useful on other systems. If it contains results you don't
23313# want to keep, you may remove or edit it.
23314#
23315# config.status only pays attention to the cache file if you give it
23316# the --recheck option to rerun configure.
23317#
23318# 'ac_cv_env_foo' variables (set or unset) will be overridden when
23319# loading this file, other *unset* 'ac_cv_foo' will be assigned the
23320# following values.
23321
23322_ACEOF
23323
23324# The following way of writing the cache mishandles newlines in values,
23325# but we know of no workaround that is simple, portable, and efficient.
23326# So, we kill variables containing newlines.
23327# Ultrix sh set writes to stderr and can't be redirected directly,
23328# and sets the high bit in the cache file unless we assign to the vars.
23329(
23330 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
23331 eval ac_val=\$$ac_var
23332 case $ac_val in #(
23333 *${as_nl}*)
23334 case $ac_var in #(
23335 *_cv_*) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
23336printf "%s\n" "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
23337 esac
23338 case $ac_var in #(
23339 _ | IFS | as_nl) ;; #(
23340 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
23341 *) { eval $ac_var=; unset $ac_var;} ;;
23342 esac ;;
23343 esac
23344 done
23345
23346 (set) 2>&1 |
23347 case $as_nl`(ac_space=' '; set) 2>&1` in #(
23348 *${as_nl}ac_space=\ *)
23349 # 'set' does not quote correctly, so add quotes: double-quote
23350 # substitution turns \\\\ into \\, and sed turns \\ into \.
23351 sed -n \
23352 "s/'/'\\\\''/g;
23353 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
23354 ;; #(
23355 *)
23356 # 'set' quotes correctly as required by POSIX, so do not add quotes.
23357 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
23358 ;;
23359 esac |
23360 sort
23361) |
23362 sed '
23363 /^ac_cv_env_/b end
23364 t clear
23365 :clear
23366 s/^\([^=]*\)=\(.*[{}].*\)$/test ${\1+y} || &/
23367 t end
23368 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
23369 :end' >>confcache
23370if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
23371 if test -w "$cache_file"; then
23372 if test "x$cache_file" != "x/dev/null"; then
23373 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
23374printf "%s\n" "$as_me: updating cache $cache_file" >&6;}
23375 if test ! -f "$cache_file" || test -h "$cache_file"; then
23376 cat confcache >"$cache_file"
23377 else
23378 case $cache_file in #(
23379 */* | ?:*)
23380 mv -f confcache "$cache_file"$$ &&
23381 mv -f "$cache_file"$$ "$cache_file" ;; #(
23382 *)
23383 mv -f confcache "$cache_file" ;;
23384 esac
23385 fi
23386 fi
23387 else
23388 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
23389printf "%s\n" "$as_me: not updating unwritable cache $cache_file" >&6;}
23390 fi
23391fi
23392rm -f confcache
23393
23394test "x$prefix" = xNONE && prefix=$ac_default_prefix
23395# Let make expand exec_prefix.
23396test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
23397
23398DEFS=-DHAVE_CONFIG_H
23399
23400ac_libobjs=
23401ac_ltlibobjs=
23402U=
23403for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
23404 # 1. Remove the extension, and $U if already installed.
23405 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
23406 ac_i=`printf "%s\n" "$ac_i" | sed "$ac_script"`
23407 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR
23408 # will be set to the directory where LIBOBJS objects are built.
23409 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
23410 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
23411done
23412LIBOBJS=$ac_libobjs
23413
23414LTLIBOBJS=$ac_ltlibobjs
23415
23416
23417# Check whether --enable-year2038 was given.
23418if test ${enable_year2038+y}
23419then :
23420 enableval=$enable_year2038;
23421fi
23422
23423
23424
23425: "${CONFIG_STATUS=./config.status}"
23426ac_write_fail=0
23427ac_clean_files_save=$ac_clean_files
23428ac_clean_files="$ac_clean_files $CONFIG_STATUS"
23429{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
23430printf "%s\n" "$as_me: creating $CONFIG_STATUS" >&6;}
23431as_write_fail=0
23432cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
23433#! $SHELL
23434# Generated by $as_me.
23435# Run this file to recreate the current configuration.
23436# Compiler output produced by configure, useful for debugging
23437# configure, is in config.log if it exists.
23438
23439debug=false
23440ac_cs_recheck=false
23441ac_cs_silent=false
23442
23443SHELL=\${CONFIG_SHELL-$SHELL}
23444export SHELL
23445_ASEOF
23446cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
23447## -------------------- ##
23448## M4sh Initialization. ##
23449## -------------------- ##
23450
23451# Be more Bourne compatible
23452DUALCASE=1; export DUALCASE # for MKS sh
23453if test ${ZSH_VERSION+y} && (emulate sh) >/dev/null 2>&1
23454then :
23455 emulate sh
23456 NULLCMD=:
23457 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23458 # is contrary to our usage. Disable this feature.
23459 alias -g '${1+"$@"}'='"$@"'
23460 setopt NO_GLOB_SUBST
23461else case e in #(
23462 e) case `(set -o) 2>/dev/null` in #(
23463 *posix*) :
23464 set -o posix ;; #(
23465 *) :
23466 ;;
23467esac ;;
23468esac
23469fi
23470
23471
23472
23473# Reset variables that may have inherited troublesome values from
23474# the environment.
23475
23476# IFS needs to be set, to space, tab, and newline, in precisely that order.
23477# (If _AS_PATH_WALK were called with IFS unset, it would have the
23478# side effect of setting IFS to empty, thus disabling word splitting.)
23479# Quoting is to prevent editors from complaining about space-tab.
23480as_nl='
23481'
23482export as_nl
23483IFS=" "" $as_nl"
23484
23485PS1='$ '
23486PS2='> '
23487PS4='+ '
23488
23489# Ensure predictable behavior from utilities with locale-dependent output.
23490LC_ALL=C
23491export LC_ALL
23492LANGUAGE=C
23493export LANGUAGE
23494
23495# We cannot yet rely on "unset" to work, but we need these variables
23496# to be unset--not just set to an empty or harmless value--now, to
23497# avoid bugs in old shells (e.g. pre-3.0 UWIN ksh). This construct
23498# also avoids known problems related to "unset" and subshell syntax
23499# in other old shells (e.g. bash 2.01 and pdksh 5.2.14).
23500for as_var in BASH_ENV ENV MAIL MAILPATH CDPATH
23501do eval test \${$as_var+y} \
23502 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
23503done
23504
23505# Ensure that fds 0, 1, and 2 are open.
23506if (exec 3>&0) 2>/dev/null; then :; else exec 0</dev/null; fi
23507if (exec 3>&1) 2>/dev/null; then :; else exec 1>/dev/null; fi
23508if (exec 3>&2) ; then :; else exec 2>/dev/null; fi
23509
23510# The user is always right.
23511if ${PATH_SEPARATOR+false} :; then
23512 PATH_SEPARATOR=:
23513 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
23514 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
23515 PATH_SEPARATOR=';'
23516 }
23517fi
23518
23519
23520# Find who we are. Look in the path if we contain no directory separator.
23521as_myself=
23522case $0 in #((
23523 *[\\/]* ) as_myself=$0 ;;
23524 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
23525for as_dir in $PATH
23526do
23527 IFS=$as_save_IFS
23528 case $as_dir in #(((
23529 '') as_dir=./ ;;
23530 */) ;;
23531 *) as_dir=$as_dir/ ;;
23532 esac
23533 test -r "$as_dir$0" && as_myself=$as_dir$0 && break
23534 done
23535IFS=$as_save_IFS
23536
23537 ;;
23538esac
23539# We did not find ourselves, most probably we were run as 'sh COMMAND'
23540# in which case we are not to be found in the path.
23541if test "x$as_myself" = x; then
23542 as_myself=$0
23543fi
23544if test ! -f "$as_myself"; then
23545 printf "%s\n" "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
23546 exit 1
23547fi
23548
23549
23550
23551# as_fn_error STATUS ERROR [LINENO LOG_FD]
23552# ----------------------------------------
23553# Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
23554# provided, also output the error to LOG_FD, referencing LINENO. Then exit the
23555# script with STATUS, using 1 if that was 0.
23556as_fn_error ()
23557{
23558 as_status=$1; test $as_status -eq 0 && as_status=1
23559 if test "$4"; then
23560 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
23561 printf "%s\n" "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
23562 fi
23563 printf "%s\n" "$as_me: error: $2" >&2
23564 as_fn_exit $as_status
23565} # as_fn_error
23566
23567
23568# as_fn_set_status STATUS
23569# -----------------------
23570# Set $? to STATUS, without forking.
23571as_fn_set_status ()
23572{
23573 return $1
23574} # as_fn_set_status
23575
23576# as_fn_exit STATUS
23577# -----------------
23578# Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
23579as_fn_exit ()
23580{
23581 set +e
23582 as_fn_set_status $1
23583 exit $1
23584} # as_fn_exit
23585
23586# as_fn_unset VAR
23587# ---------------
23588# Portably unset VAR.
23589as_fn_unset ()
23590{
23591 { eval $1=; unset $1;}
23592}
23593as_unset=as_fn_unset
23594
23595# as_fn_append VAR VALUE
23596# ----------------------
23597# Append the text in VALUE to the end of the definition contained in VAR. Take
23598# advantage of any shell optimizations that allow amortized linear growth over
23599# repeated appends, instead of the typical quadratic growth present in naive
23600# implementations.
23601if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null
23602then :
23603 eval 'as_fn_append ()
23604 {
23605 eval $1+=\$2
23606 }'
23607else case e in #(
23608 e) as_fn_append ()
23609 {
23610 eval $1=\$$1\$2
23611 } ;;
23612esac
23613fi # as_fn_append
23614
23615# as_fn_arith ARG...
23616# ------------------
23617# Perform arithmetic evaluation on the ARGs, and store the result in the
23618# global $as_val. Take advantage of shells that can avoid forks. The arguments
23619# must be portable across $(()) and expr.
23620if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null
23621then :
23622 eval 'as_fn_arith ()
23623 {
23624 as_val=$(( $* ))
23625 }'
23626else case e in #(
23627 e) as_fn_arith ()
23628 {
23629 as_val=`expr "$@" || test $? -eq 1`
23630 } ;;
23631esac
23632fi # as_fn_arith
23633
23634
23635if expr a : '\(a\)' >/dev/null 2>&1 &&
23636 test "X`expr 00001 : '.*\(...\)'`" = X001; then
23637 as_expr=expr
23638else
23639 as_expr=false
23640fi
23641
23642if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
23643 as_basename=basename
23644else
23645 as_basename=false
23646fi
23647
23648if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
23649 as_dirname=dirname
23650else
23651 as_dirname=false
23652fi
23653
23654as_me=`$as_basename -- "$0" ||
23655$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
23656 X"$0" : 'X\(//\)$' \| \
23657 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
23658printf "%s\n" X/"$0" |
23659 sed '/^.*\/\([^/][^/]*\)\/*$/{
23660 s//\1/
23661 q
23662 }
23663 /^X\/\(\/\/\)$/{
23664 s//\1/
23665 q
23666 }
23667 /^X\/\(\/\).*/{
23668 s//\1/
23669 q
23670 }
23671 s/.*/./; q'`
23672
23673# Avoid depending upon Character Ranges.
23674as_cr_letters='abcdefghijklmnopqrstuvwxyz'
23675as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
23676as_cr_Letters=$as_cr_letters$as_cr_LETTERS
23677as_cr_digits='0123456789'
23678as_cr_alnum=$as_cr_Letters$as_cr_digits
23679
23680
23681# Determine whether it's possible to make 'echo' print without a newline.
23682# These variables are no longer used directly by Autoconf, but are AC_SUBSTed
23683# for compatibility with existing Makefiles.
23684ECHO_C= ECHO_N= ECHO_T=
23685case `echo -n x` in #(((((
23686-n*)
23687 case `echo 'xy\c'` in
23688 *c*) ECHO_T=' ';; # ECHO_T is single tab character.
23689 xy) ECHO_C='\c';;
23690 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null
23691 ECHO_T=' ';;
23692 esac;;
23693*)
23694 ECHO_N='-n';;
23695esac
23696
23697# For backward compatibility with old third-party macros, we provide
23698# the shell variables $as_echo and $as_echo_n. New code should use
23699# AS_ECHO(["message"]) and AS_ECHO_N(["message"]), respectively.
23700as_echo='printf %s\n'
23701as_echo_n='printf %s'
23702
23703rm -f conf$$ conf$$.exe conf$$.file
23704if test -d conf$$.dir; then
23705 rm -f conf$$.dir/conf$$.file
23706else
23707 rm -f conf$$.dir
23708 mkdir conf$$.dir 2>/dev/null
23709fi
23710if (echo >conf$$.file) 2>/dev/null; then
23711 if ln -s conf$$.file conf$$ 2>/dev/null; then
23712 as_ln_s='ln -s'
23713 # ... but there are two gotchas:
23714 # 1) On MSYS, both 'ln -s file dir' and 'ln file dir' fail.
23715 # 2) DJGPP < 2.04 has no symlinks; 'ln -s' creates a wrapper executable.
23716 # In both cases, we have to default to 'cp -pR'.
23717 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
23718 as_ln_s='cp -pR'
23719 elif ln conf$$.file conf$$ 2>/dev/null; then
23720 as_ln_s=ln
23721 else
23722 as_ln_s='cp -pR'
23723 fi
23724else
23725 as_ln_s='cp -pR'
23726fi
23727rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
23728rmdir conf$$.dir 2>/dev/null
23729
23730
23731# as_fn_mkdir_p
23732# -------------
23733# Create "$as_dir" as a directory, including parents if necessary.
23734as_fn_mkdir_p ()
23735{
23736
23737 case $as_dir in #(
23738 -*) as_dir=./$as_dir;;
23739 esac
23740 test -d "$as_dir" || eval $as_mkdir_p || {
23741 as_dirs=
23742 while :; do
23743 case $as_dir in #(
23744 *\'*) as_qdir=`printf "%s\n" "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
23745 *) as_qdir=$as_dir;;
23746 esac
23747 as_dirs="'$as_qdir' $as_dirs"
23748 as_dir=`$as_dirname -- "$as_dir" ||
23749$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
23750 X"$as_dir" : 'X\(//\)[^/]' \| \
23751 X"$as_dir" : 'X\(//\)$' \| \
23752 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
23753printf "%s\n" X"$as_dir" |
23754 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
23755 s//\1/
23756 q
23757 }
23758 /^X\(\/\/\)[^/].*/{
23759 s//\1/
23760 q
23761 }
23762 /^X\(\/\/\)$/{
23763 s//\1/
23764 q
23765 }
23766 /^X\(\/\).*/{
23767 s//\1/
23768 q
23769 }
23770 s/.*/./; q'`
23771 test -d "$as_dir" && break
23772 done
23773 test -z "$as_dirs" || eval "mkdir $as_dirs"
23774 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
23775
23776
23777} # as_fn_mkdir_p
23778if mkdir -p . 2>/dev/null; then
23779 as_mkdir_p='mkdir -p "$as_dir"'
23780else
23781 test -d ./-p && rmdir ./-p
23782 as_mkdir_p=false
23783fi
23784
23785
23786# as_fn_executable_p FILE
23787# -----------------------
23788# Test if FILE is an executable regular file.
23789as_fn_executable_p ()
23790{
23791 test -f "$1" && test -x "$1"
23792} # as_fn_executable_p
23793as_test_x='test -x'
23794as_executable_p=as_fn_executable_p
23795
23796# Sed expression to map a string onto a valid CPP name.
23797as_sed_cpp="y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g"
23798as_tr_cpp="eval sed '$as_sed_cpp'" # deprecated
23799
23800# Sed expression to map a string onto a valid variable name.
23801as_sed_sh="y%*+%pp%;s%[^_$as_cr_alnum]%_%g"
23802as_tr_sh="eval sed '$as_sed_sh'" # deprecated
23803
23804
23805exec 6>&1
23806## ----------------------------------- ##
23807## Main body of $CONFIG_STATUS script. ##
23808## ----------------------------------- ##
23809_ASEOF
23810test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
23811
23812cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23813# Save the log message, to keep $0 and so on meaningful, and to
23814# report actual input values of CONFIG_FILES etc. instead of their
23815# values after options handling.
23816ac_log="
23817This file was extended by bash $as_me 5.3-release, which was
23818generated by GNU Autoconf 2.72. Invocation command line was
23819
23820 CONFIG_FILES = $CONFIG_FILES
23821 CONFIG_HEADERS = $CONFIG_HEADERS
23822 CONFIG_LINKS = $CONFIG_LINKS
23823 CONFIG_COMMANDS = $CONFIG_COMMANDS
23824 $ $0 $@
23825
23826on `(hostname || uname -n) 2>/dev/null | sed 1q`
23827"
23828
23829_ACEOF
23830
23831case $ac_config_files in *"
23832"*) set x $ac_config_files; shift; ac_config_files=$*;;
23833esac
23834
23835case $ac_config_headers in *"
23836"*) set x $ac_config_headers; shift; ac_config_headers=$*;;
23837esac
23838
23839
23840cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23841# Files that config.status was made for.
23842config_files="$ac_config_files"
23843config_headers="$ac_config_headers"
23844config_commands="$ac_config_commands"
23845
23846_ACEOF
23847
23848cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23849ac_cs_usage="\
23850'$as_me' instantiates files and other configuration actions
23851from templates according to the current configuration. Unless the files
23852and actions are specified as TAGs, all are instantiated by default.
23853
23854Usage: $0 [OPTION]... [TAG]...
23855
23856 -h, --help print this help, then exit
23857 -V, --version print version number and configuration settings, then exit
23858 --config print configuration, then exit
23859 -q, --quiet, --silent
23860 do not print progress messages
23861 -d, --debug don't remove temporary files
23862 --recheck update $as_me by reconfiguring in the same conditions
23863 --file=FILE[:TEMPLATE]
23864 instantiate the configuration file FILE
23865 --header=FILE[:TEMPLATE]
23866 instantiate the configuration header FILE
23867
23868Configuration files:
23869$config_files
23870
23871Configuration headers:
23872$config_headers
23873
23874Configuration commands:
23875$config_commands
23876
23877Report bugs to <bug-bash@gnu.org>."
23878
23879_ACEOF
23880ac_cs_config=`printf "%s\n" "$ac_configure_args" | sed "$ac_safe_unquote"`
23881ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\''/g"`
23882cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23883ac_cs_config='$ac_cs_config_escaped'
23884ac_cs_version="\\
23885bash config.status 5.3-release
23886configured by $0, generated by GNU Autoconf 2.72,
23887 with options \\"\$ac_cs_config\\"
23888
23889Copyright (C) 2023 Free Software Foundation, Inc.
23890This config.status script is free software; the Free Software Foundation
23891gives unlimited permission to copy, distribute and modify it."
23892
23893ac_pwd='$ac_pwd'
23894srcdir='$srcdir'
23895INSTALL='$INSTALL'
23896MKDIR_P='$MKDIR_P'
23897test -n "\$AWK" || AWK=awk
23898_ACEOF
23899
23900cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23901# The default lists apply if the user does not specify any file.
23902ac_need_defaults=:
23903while test $# != 0
23904do
23905 case $1 in
23906 --*=?*)
23907 ac_option=`expr "X$1" : 'X\([^=]*\)='`
23908 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
23909 ac_shift=:
23910 ;;
23911 --*=)
23912 ac_option=`expr "X$1" : 'X\([^=]*\)='`
23913 ac_optarg=
23914 ac_shift=:
23915 ;;
23916 *)
23917 ac_option=$1
23918 ac_optarg=$2
23919 ac_shift=shift
23920 ;;
23921 esac
23922
23923 case $ac_option in
23924 # Handling of the options.
23925 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
23926 ac_cs_recheck=: ;;
23927 --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
23928 printf "%s\n" "$ac_cs_version"; exit ;;
23929 --config | --confi | --conf | --con | --co | --c )
23930 printf "%s\n" "$ac_cs_config"; exit ;;
23931 --debug | --debu | --deb | --de | --d | -d )
23932 debug=: ;;
23933 --file | --fil | --fi | --f )
23934 $ac_shift
23935 case $ac_optarg in
23936 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23937 '') as_fn_error $? "missing file argument" ;;
23938 esac
23939 as_fn_append CONFIG_FILES " '$ac_optarg'"
23940 ac_need_defaults=false;;
23941 --header | --heade | --head | --hea )
23942 $ac_shift
23943 case $ac_optarg in
23944 *\'*) ac_optarg=`printf "%s\n" "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
23945 esac
23946 as_fn_append CONFIG_HEADERS " '$ac_optarg'"
23947 ac_need_defaults=false;;
23948 --he | --h)
23949 # Conflict between --help and --header
23950 as_fn_error $? "ambiguous option: '$1'
23951Try '$0 --help' for more information.";;
23952 --help | --hel | -h )
23953 printf "%s\n" "$ac_cs_usage"; exit ;;
23954 -q | -quiet | --quiet | --quie | --qui | --qu | --q \
23955 | -silent | --silent | --silen | --sile | --sil | --si | --s)
23956 ac_cs_silent=: ;;
23957
23958 # This is an error.
23959 -*) as_fn_error $? "unrecognized option: '$1'
23960Try '$0 --help' for more information." ;;
23961
23962 *) as_fn_append ac_config_targets " $1"
23963 ac_need_defaults=false ;;
23964
23965 esac
23966 shift
23967done
23968
23969ac_configure_extra_args=
23970
23971if $ac_cs_silent; then
23972 exec 6>/dev/null
23973 ac_configure_extra_args="$ac_configure_extra_args --silent"
23974fi
23975
23976_ACEOF
23977cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
23978if \$ac_cs_recheck; then
23979 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
23980 shift
23981 \printf "%s\n" "running CONFIG_SHELL=$SHELL \$*" >&6
23982 CONFIG_SHELL='$SHELL'
23983 export CONFIG_SHELL
23984 exec "\$@"
23985fi
23986
23987_ACEOF
23988cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
23989exec 5>>config.log
23990{
23991 echo
23992 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
23993## Running $as_me. ##
23994_ASBOX
23995 printf "%s\n" "$ac_log"
23996} >&5
23997
23998_ACEOF
23999cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24000#
24001# INIT-COMMANDS
24002#
24003# Capture the value of obsolete ALL_LINGUAS because we need it to compute
24004 # POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES, CATALOGS.
24005 OBSOLETE_ALL_LINGUAS="$ALL_LINGUAS"
24006 # Capture the value of LINGUAS because we need it to compute CATALOGS.
24007 LINGUAS="${LINGUAS-%UNSET%}"
24008
24009
24010_ACEOF
24011
24012cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24013
24014# Handling of arguments.
24015for ac_config_target in $ac_config_targets
24016do
24017 case $ac_config_target in
24018 "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
24019 "buildconf.h") CONFIG_HEADERS="$CONFIG_HEADERS buildconf.h" ;;
24020 "po-directories") CONFIG_COMMANDS="$CONFIG_COMMANDS po-directories" ;;
24021 "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
24022 "builtins/Makefile") CONFIG_FILES="$CONFIG_FILES builtins/Makefile" ;;
24023 "lib/readline/Makefile") CONFIG_FILES="$CONFIG_FILES lib/readline/Makefile" ;;
24024 "lib/glob/Makefile") CONFIG_FILES="$CONFIG_FILES lib/glob/Makefile" ;;
24025 "lib/intl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/intl/Makefile" ;;
24026 "lib/malloc/Makefile") CONFIG_FILES="$CONFIG_FILES lib/malloc/Makefile" ;;
24027 "lib/sh/Makefile") CONFIG_FILES="$CONFIG_FILES lib/sh/Makefile" ;;
24028 "lib/termcap/Makefile") CONFIG_FILES="$CONFIG_FILES lib/termcap/Makefile" ;;
24029 "lib/tilde/Makefile") CONFIG_FILES="$CONFIG_FILES lib/tilde/Makefile" ;;
24030 "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;;
24031 "support/Makefile") CONFIG_FILES="$CONFIG_FILES support/Makefile" ;;
24032 "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;;
24033 "examples/loadables/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile" ;;
24034 "examples/loadables/Makefile.inc") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile.inc" ;;
24035 "examples/loadables/Makefile.sample") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile.sample" ;;
24036 "examples/loadables/perl/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/perl/Makefile" ;;
24037 "support/bash.pc") CONFIG_FILES="$CONFIG_FILES support/bash.pc" ;;
24038 "support/bashbug.sh") CONFIG_FILES="$CONFIG_FILES support/bashbug.sh" ;;
24039 "stamp-h") CONFIG_COMMANDS="$CONFIG_COMMANDS stamp-h" ;;
24040
24041 *) as_fn_error $? "invalid argument: '$ac_config_target'" "$LINENO" 5;;
24042 esac
24043done
24044
24045
24046# If the user did not use the arguments to specify the items to instantiate,
24047# then the envvar interface is used. Set only those that are not.
24048# We use the long form for the default assignment because of an extremely
24049# bizarre bug on SunOS 4.1.3.
24050if $ac_need_defaults; then
24051 test ${CONFIG_FILES+y} || CONFIG_FILES=$config_files
24052 test ${CONFIG_HEADERS+y} || CONFIG_HEADERS=$config_headers
24053 test ${CONFIG_COMMANDS+y} || CONFIG_COMMANDS=$config_commands
24054fi
24055
24056# Have a temporary directory for convenience. Make it in the build tree
24057# simply because there is no reason against having it here, and in addition,
24058# creating and moving files from /tmp can sometimes cause problems.
24059# Hook for its removal unless debugging.
24060# Note that there is a small window in which the directory will not be cleaned:
24061# after its creation but before its name has been assigned to '$tmp'.
24062$debug ||
24063{
24064 tmp= ac_tmp=
24065 trap 'exit_status=$?
24066 : "${ac_tmp:=$tmp}"
24067 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status
24068' 0
24069 trap 'as_fn_exit 1' 1 2 13 15
24070}
24071# Create a (secure) tmp directory for tmp files.
24072
24073{
24074 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
24075 test -d "$tmp"
24076} ||
24077{
24078 tmp=./conf$$-$RANDOM
24079 (umask 077 && mkdir "$tmp")
24080} || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
24081ac_tmp=$tmp
24082
24083# Set up the scripts for CONFIG_FILES section.
24084# No need to generate them if there are no CONFIG_FILES.
24085# This happens for instance with './config.status config.h'.
24086if test -n "$CONFIG_FILES"; then
24087
24088
24089ac_cr=`echo X | tr X '\015'`
24090# On cygwin, bash can eat \r inside `` if the user requested igncr.
24091# But we know of no other shell where ac_cr would be empty at this
24092# point, so we can use a bashism as a fallback.
24093if test "x$ac_cr" = x; then
24094 eval ac_cr=\$\'\\r\'
24095fi
24096ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
24097if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
24098 ac_cs_awk_cr='\\r'
24099else
24100 ac_cs_awk_cr=$ac_cr
24101fi
24102
24103echo 'BEGIN {' >"$ac_tmp/subs1.awk" &&
24104_ACEOF
24105
24106
24107{
24108 echo "cat >conf$$subs.awk <<_ACEOF" &&
24109 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
24110 echo "_ACEOF"
24111} >conf$$subs.sh ||
24112 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
24113ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
24114ac_delim='%!_!# '
24115for ac_last_try in false false false false false :; do
24116 . ./conf$$subs.sh ||
24117 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
24118
24119 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
24120 if test $ac_delim_n = $ac_delim_num; then
24121 break
24122 elif $ac_last_try; then
24123 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
24124 else
24125 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
24126 fi
24127done
24128rm -f conf$$subs.sh
24129
24130cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24131cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&
24132_ACEOF
24133sed -n '
24134h
24135s/^/S["/; s/!.*/"]=/
24136p
24137g
24138s/^[^!]*!//
24139:repl
24140t repl
24141s/'"$ac_delim"'$//
24142t delim
24143:nl
24144h
24145s/\(.\{148\}\)..*/\1/
24146t more1
24147s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
24148p
24149n
24150b repl
24151:more1
24152s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24153p
24154g
24155s/.\{148\}//
24156t nl
24157:delim
24158h
24159s/\(.\{148\}\)..*/\1/
24160t more2
24161s/["\\]/\\&/g; s/^/"/; s/$/"/
24162p
24163b
24164:more2
24165s/["\\]/\\&/g; s/^/"/; s/$/"\\/
24166p
24167g
24168s/.\{148\}//
24169t delim
24170' <conf$$subs.awk | sed '
24171/^[^""]/{
24172 N
24173 s/\n//
24174}
24175' >>$CONFIG_STATUS || ac_write_fail=1
24176rm -f conf$$subs.awk
24177cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24178_ACAWK
24179cat >>"\$ac_tmp/subs1.awk" <<_ACAWK &&
24180 for (key in S) S_is_set[key] = 1
24181 FS = "\a"
24182
24183}
24184{
24185 line = $ 0
24186 nfields = split(line, field, "@")
24187 substed = 0
24188 len = length(field[1])
24189 for (i = 2; i < nfields; i++) {
24190 key = field[i]
24191 keylen = length(key)
24192 if (S_is_set[key]) {
24193 value = S[key]
24194 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
24195 len += length(value) + length(field[++i])
24196 substed = 1
24197 } else
24198 len += 1 + keylen
24199 }
24200
24201 print line
24202}
24203
24204_ACAWK
24205_ACEOF
24206cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24207if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
24208 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
24209else
24210 cat
24211fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \
24212 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
24213_ACEOF
24214
24215# VPATH may cause trouble with some makes, so we remove sole $(srcdir),
24216# ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
24217# trailing colons and then remove the whole line if VPATH becomes empty
24218# (actually we leave an empty line to preserve line numbers).
24219if test "x$srcdir" = x.; then
24220 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{
24221h
24222s///
24223s/^/:/
24224s/[ ]*$/:/
24225s/:\$(srcdir):/:/g
24226s/:\${srcdir}:/:/g
24227s/:@srcdir@:/:/g
24228s/^:*//
24229s/:*$//
24230x
24231s/\(=[ ]*\).*/\1/
24232G
24233s/\n//
24234s/^[^=]*=[ ]*$//
24235}'
24236fi
24237
24238cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24239fi # test -n "$CONFIG_FILES"
24240
24241# Set up the scripts for CONFIG_HEADERS section.
24242# No need to generate them if there are no CONFIG_HEADERS.
24243# This happens for instance with './config.status Makefile'.
24244if test -n "$CONFIG_HEADERS"; then
24245cat >"$ac_tmp/defines.awk" <<\_ACAWK ||
24246BEGIN {
24247_ACEOF
24248
24249# Transform confdefs.h into an awk script 'defines.awk', embedded as
24250# here-document in config.status, that substitutes the proper values into
24251# config.h.in to produce config.h.
24252
24253# Create a delimiter string that does not exist in confdefs.h, to ease
24254# handling of long lines.
24255ac_delim='%!_!# '
24256for ac_last_try in false false :; do
24257 ac_tt=`sed -n "/$ac_delim/p" confdefs.h`
24258 if test -z "$ac_tt"; then
24259 break
24260 elif $ac_last_try; then
24261 as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
24262 else
24263 ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
24264 fi
24265done
24266
24267# For the awk script, D is an array of macro values keyed by name,
24268# likewise P contains macro parameters if any. Preserve backslash
24269# newline sequences.
24270
24271ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
24272sed -n '
24273s/.\{148\}/&'"$ac_delim"'/g
24274t rset
24275:rset
24276s/^[ ]*#[ ]*define[ ][ ]*/ /
24277t def
24278d
24279:def
24280s/\\$//
24281t bsnl
24282s/["\\]/\\&/g
24283s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
24284D["\1"]=" \3"/p
24285s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p
24286d
24287:bsnl
24288s/["\\]/\\&/g
24289s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\
24290D["\1"]=" \3\\\\\\n"\\/p
24291t cont
24292s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
24293t cont
24294d
24295:cont
24296n
24297s/.\{148\}/&'"$ac_delim"'/g
24298t clear
24299:clear
24300s/\\$//
24301t bsnlc
24302s/["\\]/\\&/g; s/^/"/; s/$/"/p
24303d
24304:bsnlc
24305s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
24306b cont
24307' <confdefs.h | sed '
24308s/'"$ac_delim"'/"\\\
24309"/g' >>$CONFIG_STATUS || ac_write_fail=1
24310
24311cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24312 for (key in D) D_is_set[key] = 1
24313 FS = "\a"
24314}
24315/^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
24316 line = \$ 0
24317 split(line, arg, " ")
24318 if (arg[1] == "#") {
24319 defundef = arg[2]
24320 mac1 = arg[3]
24321 } else {
24322 defundef = substr(arg[1], 2)
24323 mac1 = arg[2]
24324 }
24325 split(mac1, mac2, "(") #)
24326 macro = mac2[1]
24327 prefix = substr(line, 1, index(line, defundef) - 1)
24328 if (D_is_set[macro]) {
24329 # Preserve the white space surrounding the "#".
24330 print prefix "define", macro P[macro] D[macro]
24331 next
24332 } else {
24333 # Replace #undef with comments. This is necessary, for example,
24334 # in the case of _POSIX_SOURCE, which is predefined and required
24335 # on some systems where configure will not decide to define it.
24336 if (defundef == "undef") {
24337 print "/*", prefix defundef, macro, "*/"
24338 next
24339 }
24340 }
24341}
24342{ print }
24343_ACAWK
24344_ACEOF
24345cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24346 as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
24347fi # test -n "$CONFIG_HEADERS"
24348
24349
24350eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS"
24351shift
24352for ac_tag
24353do
24354 case $ac_tag in
24355 :[FHLC]) ac_mode=$ac_tag; continue;;
24356 esac
24357 case $ac_mode$ac_tag in
24358 :[FHL]*:*);;
24359 :L* | :C*:*) as_fn_error $? "invalid tag '$ac_tag'" "$LINENO" 5;;
24360 :[FH]-) ac_tag=-:-;;
24361 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
24362 esac
24363 ac_save_IFS=$IFS
24364 IFS=:
24365 set x $ac_tag
24366 IFS=$ac_save_IFS
24367 shift
24368 ac_file=$1
24369 shift
24370
24371 case $ac_mode in
24372 :L) ac_source=$1;;
24373 :[FH])
24374 ac_file_inputs=
24375 for ac_f
24376 do
24377 case $ac_f in
24378 -) ac_f="$ac_tmp/stdin";;
24379 *) # Look for the file first in the build tree, then in the source tree
24380 # (if the path is not absolute). The absolute path cannot be DOS-style,
24381 # because $ac_f cannot contain ':'.
24382 test -f "$ac_f" ||
24383 case $ac_f in
24384 [\\/$]*) false;;
24385 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
24386 esac ||
24387 as_fn_error 1 "cannot find input file: '$ac_f'" "$LINENO" 5;;
24388 esac
24389 case $ac_f in *\'*) ac_f=`printf "%s\n" "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
24390 as_fn_append ac_file_inputs " '$ac_f'"
24391 done
24392
24393 # Let's still pretend it is 'configure' which instantiates (i.e., don't
24394 # use $as_me), people would be surprised to read:
24395 # /* config.h. Generated by config.status. */
24396 configure_input='Generated from '`
24397 printf "%s\n" "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
24398 `' by configure.'
24399 if test x"$ac_file" != x-; then
24400 configure_input="$ac_file. $configure_input"
24401 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
24402printf "%s\n" "$as_me: creating $ac_file" >&6;}
24403 fi
24404 # Neutralize special characters interpreted by sed in replacement strings.
24405 case $configure_input in #(
24406 *\&* | *\|* | *\\* )
24407 ac_sed_conf_input=`printf "%s\n" "$configure_input" |
24408 sed 's/[\\\\&|]/\\\\&/g'`;; #(
24409 *) ac_sed_conf_input=$configure_input;;
24410 esac
24411
24412 case $ac_tag in
24413 *:-:* | *:-) cat >"$ac_tmp/stdin" \
24414 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;;
24415 esac
24416 ;;
24417 esac
24418
24419 ac_dir=`$as_dirname -- "$ac_file" ||
24420$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
24421 X"$ac_file" : 'X\(//\)[^/]' \| \
24422 X"$ac_file" : 'X\(//\)$' \| \
24423 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
24424printf "%s\n" X"$ac_file" |
24425 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
24426 s//\1/
24427 q
24428 }
24429 /^X\(\/\/\)[^/].*/{
24430 s//\1/
24431 q
24432 }
24433 /^X\(\/\/\)$/{
24434 s//\1/
24435 q
24436 }
24437 /^X\(\/\).*/{
24438 s//\1/
24439 q
24440 }
24441 s/.*/./; q'`
24442 as_dir="$ac_dir"; as_fn_mkdir_p
24443 ac_builddir=.
24444
24445case "$ac_dir" in
24446.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
24447*)
24448 ac_dir_suffix=/`printf "%s\n" "$ac_dir" | sed 's|^\.[\\/]||'`
24449 # A ".." for each directory in $ac_dir_suffix.
24450 ac_top_builddir_sub=`printf "%s\n" "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
24451 case $ac_top_builddir_sub in
24452 "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
24453 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;;
24454 esac ;;
24455esac
24456ac_abs_top_builddir=$ac_pwd
24457ac_abs_builddir=$ac_pwd$ac_dir_suffix
24458# for backward compatibility:
24459ac_top_builddir=$ac_top_build_prefix
24460
24461case $srcdir in
24462 .) # We are building in place.
24463 ac_srcdir=.
24464 ac_top_srcdir=$ac_top_builddir_sub
24465 ac_abs_top_srcdir=$ac_pwd ;;
24466 [\\/]* | ?:[\\/]* ) # Absolute name.
24467 ac_srcdir=$srcdir$ac_dir_suffix;
24468 ac_top_srcdir=$srcdir
24469 ac_abs_top_srcdir=$srcdir ;;
24470 *) # Relative name.
24471 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
24472 ac_top_srcdir=$ac_top_build_prefix$srcdir
24473 ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
24474esac
24475ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
24476
24477
24478 case $ac_mode in
24479 :F)
24480 #
24481 # CONFIG_FILE
24482 #
24483
24484 case $INSTALL in
24485 [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
24486 *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
24487 esac
24488 ac_MKDIR_P=$MKDIR_P
24489 case $MKDIR_P in
24490 [\\/$]* | ?:[\\/]* ) ;;
24491 */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
24492 esac
24493_ACEOF
24494
24495cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24496# If the template does not know about datarootdir, expand it.
24497# FIXME: This hack should be removed a few years after 2.60.
24498ac_datarootdir_hack=; ac_datarootdir_seen=
24499ac_sed_dataroot='
24500/datarootdir/ {
24501 p
24502 q
24503}
24504/@datadir@/p
24505/@docdir@/p
24506/@infodir@/p
24507/@localedir@/p
24508/@mandir@/p'
24509case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
24510*datarootdir*) ac_datarootdir_seen=yes;;
24511*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
24512 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
24513printf "%s\n" "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
24514_ACEOF
24515cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24516 ac_datarootdir_hack='
24517 s&@datadir@&$datadir&g
24518 s&@docdir@&$docdir&g
24519 s&@infodir@&$infodir&g
24520 s&@localedir@&$localedir&g
24521 s&@mandir@&$mandir&g
24522 s&\\\${datarootdir}&$datarootdir&g' ;;
24523esac
24524_ACEOF
24525
24526# Neutralize VPATH when '$srcdir' = '.'.
24527# Shell code in configure.ac might set extrasub.
24528# FIXME: do we really want to maintain this feature?
24529cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
24530ac_sed_extra="$ac_vpsub
24531$extrasub
24532_ACEOF
24533cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
24534:t
24535/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
24536s|@configure_input@|$ac_sed_conf_input|;t t
24537s&@top_builddir@&$ac_top_builddir_sub&;t t
24538s&@top_build_prefix@&$ac_top_build_prefix&;t t
24539s&@srcdir@&$ac_srcdir&;t t
24540s&@abs_srcdir@&$ac_abs_srcdir&;t t
24541s&@top_srcdir@&$ac_top_srcdir&;t t
24542s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
24543s&@builddir@&$ac_builddir&;t t
24544s&@abs_builddir@&$ac_abs_builddir&;t t
24545s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
24546s&@INSTALL@&$ac_INSTALL&;t t
24547s&@MKDIR_P@&$ac_MKDIR_P&;t t
24548$ac_datarootdir_hack
24549"
24550eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \
24551 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5
24552
24553test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
24554 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } &&
24555 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \
24556 "$ac_tmp/out"`; test -z "$ac_out"; } &&
24557 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable 'datarootdir'
24558which seems to be undefined. Please make sure it is defined" >&5
24559printf "%s\n" "$as_me: WARNING: $ac_file contains a reference to the variable 'datarootdir'
24560which seems to be undefined. Please make sure it is defined" >&2;}
24561
24562 rm -f "$ac_tmp/stdin"
24563 case $ac_file in
24564 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";;
24565 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";;
24566 esac \
24567 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
24568 ;;
24569 :H)
24570 #
24571 # CONFIG_HEADER
24572 #
24573 if test x"$ac_file" != x-; then
24574 {
24575 printf "%s\n" "/* $configure_input */" >&1 \
24576 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs"
24577 } >"$ac_tmp/config.h" \
24578 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
24579 if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then
24580 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
24581printf "%s\n" "$as_me: $ac_file is unchanged" >&6;}
24582 else
24583 rm -f "$ac_file"
24584 mv "$ac_tmp/config.h" "$ac_file" \
24585 || as_fn_error $? "could not create $ac_file" "$LINENO" 5
24586 fi
24587 else
24588 printf "%s\n" "/* $configure_input */" >&1 \
24589 && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \
24590 || as_fn_error $? "could not create -" "$LINENO" 5
24591 fi
24592 ;;
24593
24594 :C) { printf "%s\n" "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5
24595printf "%s\n" "$as_me: executing $ac_file commands" >&6;}
24596 ;;
24597 esac
24598
24599
24600 case $ac_file$ac_mode in
24601 "po-directories":C)
24602 for ac_file in $CONFIG_FILES; do
24603 # Support "outfile[:infile[:infile...]]"
24604 case "$ac_file" in
24605 *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
24606 esac
24607 # PO directories have a Makefile.in generated from Makefile.in.in.
24608 case "$ac_file" in */Makefile.in)
24609 # Adjust a relative srcdir.
24610 ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'`
24611 ac_dir_suffix=/`echo "$ac_dir"|sed 's%^\./%%'`
24612 ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'`
24613 # In autoconf-2.13 it is called $ac_given_srcdir.
24614 # In autoconf-2.50 it is called $srcdir.
24615 test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir"
24616 case "$ac_given_srcdir" in
24617 .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;;
24618 /*) top_srcdir="$ac_given_srcdir" ;;
24619 *) top_srcdir="$ac_dots$ac_given_srcdir" ;;
24620 esac
24621 # Treat a directory as a PO directory if and only if it has a
24622 # POTFILES.in file. This allows packages to have multiple PO
24623 # directories under different names or in different locations.
24624 if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then
24625 rm -f "$ac_dir/POTFILES"
24626 test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES"
24627 gt_tab=`printf '\t'`
24628 cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ${gt_tab}]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES"
24629 POMAKEFILEDEPS="POTFILES.in"
24630 # ALL_LINGUAS, POFILES, UPDATEPOFILES, DUMMYPOFILES, GMOFILES depend
24631 # on $ac_dir but don't depend on user-specified configuration
24632 # parameters.
24633 if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then
24634 # The LINGUAS file contains the set of available languages.
24635 if test -n "$OBSOLETE_ALL_LINGUAS"; then
24636 test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete"
24637 fi
24638 ALL_LINGUAS=`sed -e "/^#/d" -e "s/#.*//" "$ac_given_srcdir/$ac_dir/LINGUAS"`
24639 POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS"
24640 else
24641 # The set of available languages was given in configure.in.
24642 ALL_LINGUAS=$OBSOLETE_ALL_LINGUAS
24643 fi
24644 # Compute POFILES
24645 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).po)
24646 # Compute UPDATEPOFILES
24647 # as $(foreach lang, $(ALL_LINGUAS), $(lang).po-update)
24648 # Compute DUMMYPOFILES
24649 # as $(foreach lang, $(ALL_LINGUAS), $(lang).nop)
24650 # Compute GMOFILES
24651 # as $(foreach lang, $(ALL_LINGUAS), $(srcdir)/$(lang).gmo)
24652 case "$ac_given_srcdir" in
24653 .) srcdirpre= ;;
24654 *) srcdirpre='$(srcdir)/' ;;
24655 esac
24656 POFILES=
24657 UPDATEPOFILES=
24658 DUMMYPOFILES=
24659 GMOFILES=
24660 for lang in $ALL_LINGUAS; do
24661 POFILES="$POFILES $srcdirpre$lang.po"
24662 UPDATEPOFILES="$UPDATEPOFILES $lang.po-update"
24663 DUMMYPOFILES="$DUMMYPOFILES $lang.nop"
24664 GMOFILES="$GMOFILES $srcdirpre$lang.gmo"
24665 done
24666 # CATALOGS depends on both $ac_dir and the user's LINGUAS
24667 # environment variable.
24668 INST_LINGUAS=
24669 if test -n "$ALL_LINGUAS"; then
24670 for presentlang in $ALL_LINGUAS; do
24671 useit=no
24672 if test "%UNSET%" != "$LINGUAS"; then
24673 desiredlanguages="$LINGUAS"
24674 else
24675 desiredlanguages="$ALL_LINGUAS"
24676 fi
24677 for desiredlang in $desiredlanguages; do
24678 # Use the presentlang catalog if desiredlang is
24679 # a. equal to presentlang, or
24680 # b. a variant of presentlang (because in this case,
24681 # presentlang can be used as a fallback for messages
24682 # which are not translated in the desiredlang catalog).
24683 case "$desiredlang" in
24684 "$presentlang" | "$presentlang"_* | "$presentlang".* | "$presentlang"@*)
24685 useit=yes
24686 ;;
24687 esac
24688 done
24689 if test $useit = yes; then
24690 INST_LINGUAS="$INST_LINGUAS $presentlang"
24691 fi
24692 done
24693 fi
24694 CATALOGS=
24695 if test -n "$INST_LINGUAS"; then
24696 for lang in $INST_LINGUAS; do
24697 CATALOGS="$CATALOGS $lang.gmo"
24698 done
24699 fi
24700 test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile"
24701 sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile"
24702 for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do
24703 if test -f "$f"; then
24704 case "$f" in
24705 *.orig | *.bak | *~) ;;
24706 *) cat "$f" >> "$ac_dir/Makefile" ;;
24707 esac
24708 fi
24709 done
24710 fi
24711 ;;
24712 esac
24713 done ;;
24714 "stamp-h":C) echo timestamp > stamp-h ;;
24715
24716 esac
24717done # for ac_tag
24718
24719
24720as_fn_exit 0
24721_ACEOF
24722ac_clean_files=$ac_clean_files_save
24723
24724test $ac_write_fail = 0 ||
24725 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
24726
24727
24728# configure is writing to config.log, and then calls config.status.
24729# config.status does its own redirection, appending to config.log.
24730# Unfortunately, on DOS this fails, as config.log is still kept open
24731# by configure, so config.status won't be able to write to it; its
24732# output is simply discarded. So we exec the FD to /dev/null,
24733# effectively closing config.log, so it can be properly (re)opened and
24734# appended to by config.status. When coming back to configure, we
24735# need to make the FD available again.
24736if test "$no_create" != yes; then
24737 ac_cs_success=:
24738 ac_config_status_args=
24739 test "$silent" = yes &&
24740 ac_config_status_args="$ac_config_status_args --quiet"
24741 exec 5>/dev/null
24742 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
24743 exec 5>>config.log
24744 # Use ||, not &&, to avoid exiting from the if with $? = 1, which
24745 # would make configure fail if this is the last instruction.
24746 $ac_cs_success || as_fn_exit 1
24747fi
24748if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
24749 { printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
24750printf "%s\n" "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
24751fi
24752
24753