]>
Commit | Line | Data |
---|---|---|
ccc6cda3 | 1 | #! /bin/sh |
a0c0a00f | 2 | # From configure.ac for Bash 4.4, version 4.082. |
f73dda09 | 3 | # Guess values for system-dependent variables and create Makefiles. |
a0c0a00f | 4 | # Generated by GNU Autoconf 2.69 for bash 4.4-release. |
f73dda09 JA |
5 | # |
6 | # Report bugs to <bug-bash@gnu.org>. | |
7 | # | |
ac50fbac CR |
8 | # |
9 | # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. | |
10 | # | |
11 | # | |
f73dda09 JA |
12 | # This configure script is free software; the Free Software Foundation |
13 | # gives unlimited permission to copy, distribute and modify it. | |
ac50fbac CR |
14 | ## -------------------- ## |
15 | ## M4sh Initialization. ## | |
16 | ## -------------------- ## | |
ccc6cda3 | 17 | |
3185942a JA |
18 | # Be more Bourne compatible |
19 | DUALCASE=1; export DUALCASE # for MKS sh | |
ac50fbac | 20 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
b80f6443 JA |
21 | emulate sh |
22 | NULLCMD=: | |
3185942a | 23 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
0628567a JA |
24 | # is contrary to our usage. Disable this feature. |
25 | alias -g '${1+"$@"}'='"$@"' | |
3185942a JA |
26 | setopt NO_GLOB_SUBST |
27 | else | |
ac50fbac CR |
28 | case `(set -o) 2>/dev/null` in #( |
29 | *posix*) : | |
30 | set -o posix ;; #( | |
31 | *) : | |
32 | ;; | |
3185942a | 33 | esac |
3185942a JA |
34 | fi |
35 | ||
36 | ||
3185942a JA |
37 | as_nl=' |
38 | ' | |
39 | export as_nl | |
40 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
41 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
42 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
43 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
ac50fbac CR |
44 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
45 | # but without wasting forks for bash or zsh. | |
46 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
47 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
48 | as_echo='print -r --' | |
49 | as_echo_n='print -rn --' | |
50 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
3185942a JA |
51 | as_echo='printf %s\n' |
52 | as_echo_n='printf %s' | |
53 | else | |
54 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
55 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
56 | as_echo_n='/usr/ucb/echo -n' | |
57 | else | |
58 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
59 | as_echo_n_body='eval | |
60 | arg=$1; | |
ac50fbac | 61 | case $arg in #( |
3185942a JA |
62 | *"$as_nl"*) |
63 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
64 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
65 | esac; | |
66 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
67 | ' | |
68 | export as_echo_n_body | |
69 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
70 | fi | |
71 | export as_echo_body | |
72 | as_echo='sh -c $as_echo_body as_echo' | |
73 | fi | |
74 | ||
75 | # The user is always right. | |
76 | if test "${PATH_SEPARATOR+set}" != set; then | |
77 | PATH_SEPARATOR=: | |
78 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
79 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
80 | PATH_SEPARATOR=';' | |
81 | } | |
b80f6443 JA |
82 | fi |
83 | ||
0628567a | 84 | |
3185942a JA |
85 | # IFS |
86 | # We need space, tab and new line, in precisely that order. Quoting is | |
87 | # there to prevent editors from complaining about space-tab. | |
88 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
89 | # splitting by setting IFS to empty value.) | |
90 | IFS=" "" $as_nl" | |
91 | ||
92 | # Find who we are. Look in the path if we contain no directory separator. | |
ac50fbac CR |
93 | as_myself= |
94 | case $0 in #(( | |
3185942a JA |
95 | *[\\/]* ) as_myself=$0 ;; |
96 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
97 | for as_dir in $PATH | |
98 | do | |
99 | IFS=$as_save_IFS | |
100 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
101 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
102 | done | |
3185942a JA |
103 | IFS=$as_save_IFS |
104 | ||
105 | ;; | |
106 | esac | |
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. | |
109 | if test "x$as_myself" = x; then | |
110 | as_myself=$0 | |
111 | fi | |
112 | if test ! -f "$as_myself"; then | |
113 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
ac50fbac | 114 | exit 1 |
3185942a JA |
115 | fi |
116 | ||
ac50fbac CR |
117 | # Unset variables that we do not need and which cause bugs (e.g. in |
118 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
119 | # suppresses any "Segmentation fault" message there. '((' could | |
120 | # trigger a bug in pdksh 5.2.14. | |
121 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
122 | do eval test x\${$as_var+set} = xset \ | |
123 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
3185942a | 124 | done |
0628567a JA |
125 | PS1='$ ' |
126 | PS2='> ' | |
127 | PS4='+ ' | |
128 | ||
129 | # NLS nuisances. | |
3185942a JA |
130 | LC_ALL=C |
131 | export LC_ALL | |
132 | LANGUAGE=C | |
133 | export LANGUAGE | |
0628567a | 134 | |
ac50fbac CR |
135 | # CDPATH. |
136 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
137 | ||
138 | # Use a proper internal environment variable to ensure we don't fall | |
139 | # into an infinite loop, continuously re-executing ourselves. | |
140 | if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then | |
141 | _as_can_reexec=no; export _as_can_reexec; | |
142 | # We cannot yet assume a decent shell, so we have to provide a | |
143 | # neutralization value for shells without unset; and this also | |
144 | # works around shells that cannot unset nonexistent variables. | |
145 | # Preserve -v and -x to the replacement shell. | |
146 | BASH_ENV=/dev/null | |
147 | ENV=/dev/null | |
148 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
149 | case $- in # (((( | |
150 | *v*x* | *x*v* ) as_opts=-vx ;; | |
151 | *v* ) as_opts=-v ;; | |
152 | *x* ) as_opts=-x ;; | |
153 | * ) as_opts= ;; | |
154 | esac | |
155 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} | |
156 | # Admittedly, this is quite paranoid, since all the known shells bail | |
157 | # out after a failed `exec'. | |
158 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 | |
159 | as_fn_exit 255 | |
160 | fi | |
161 | # We don't want this to propagate to other subprocesses. | |
162 | { _as_can_reexec=; unset _as_can_reexec;} | |
163 | if test "x$CONFIG_SHELL" = x; then | |
164 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
165 | emulate sh | |
166 | NULLCMD=: | |
167 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
168 | # is contrary to our usage. Disable this feature. | |
169 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
170 | setopt NO_GLOB_SUBST | |
171 | else | |
172 | case \`(set -o) 2>/dev/null\` in #( | |
173 | *posix*) : | |
174 | set -o posix ;; #( | |
175 | *) : | |
176 | ;; | |
177 | esac | |
178 | fi | |
179 | " | |
180 | as_required="as_fn_return () { (exit \$1); } | |
181 | as_fn_success () { as_fn_return 0; } | |
182 | as_fn_failure () { as_fn_return 1; } | |
183 | as_fn_ret_success () { return 0; } | |
184 | as_fn_ret_failure () { return 1; } | |
185 | ||
186 | exitcode=0 | |
187 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
188 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
189 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
190 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
191 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
192 | ||
193 | else | |
194 | exitcode=1; echo positional parameters were not saved. | |
195 | fi | |
196 | test x\$exitcode = x0 || exit 1 | |
197 | test -x / || exit 1" | |
198 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO | |
199 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
200 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
201 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
202 | test \$(( 1 + 1 )) = 2 || exit 1" | |
203 | if (eval "$as_required") 2>/dev/null; then : | |
204 | as_have_required=yes | |
205 | else | |
206 | as_have_required=no | |
207 | fi | |
208 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
209 | ||
210 | else | |
211 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
212 | as_found=false | |
213 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
214 | do | |
215 | IFS=$as_save_IFS | |
216 | test -z "$as_dir" && as_dir=. | |
217 | as_found=: | |
218 | case $as_dir in #( | |
219 | /*) | |
220 | for as_base in sh bash ksh sh5; do | |
221 | # Try only shells that exist, to save several forks. | |
222 | as_shell=$as_dir/$as_base | |
223 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
224 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
225 | CONFIG_SHELL=$as_shell as_have_required=yes | |
226 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
227 | break 2 | |
228 | fi | |
229 | fi | |
230 | done;; | |
231 | esac | |
232 | as_found=false | |
233 | done | |
234 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
235 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
236 | CONFIG_SHELL=$SHELL as_have_required=yes | |
237 | fi; } | |
238 | IFS=$as_save_IFS | |
239 | ||
240 | ||
241 | if test "x$CONFIG_SHELL" != x; then : | |
242 | export CONFIG_SHELL | |
243 | # We cannot yet assume a decent shell, so we have to provide a | |
244 | # neutralization value for shells without unset; and this also | |
245 | # works around shells that cannot unset nonexistent variables. | |
246 | # Preserve -v and -x to the replacement shell. | |
247 | BASH_ENV=/dev/null | |
248 | ENV=/dev/null | |
249 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
250 | case $- in # (((( | |
251 | *v*x* | *x*v* ) as_opts=-vx ;; | |
252 | *v* ) as_opts=-v ;; | |
253 | *x* ) as_opts=-x ;; | |
254 | * ) as_opts= ;; | |
255 | esac | |
256 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} | |
257 | # Admittedly, this is quite paranoid, since all the known shells bail | |
258 | # out after a failed `exec'. | |
259 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 | |
260 | exit 255 | |
261 | fi | |
262 | ||
263 | if test x$as_have_required = xno; then : | |
264 | $as_echo "$0: This script requires a shell more modern than all" | |
265 | $as_echo "$0: the shells that I found on your system." | |
266 | if test x${ZSH_VERSION+set} = xset ; then | |
267 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
268 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
269 | else | |
270 | $as_echo "$0: Please tell bug-autoconf@gnu.org and bug-bash@gnu.org | |
271 | $0: about your system, including any error possibly output | |
272 | $0: before this message. Then install a modern shell, or | |
273 | $0: manually run the script under such a shell if you do | |
274 | $0: have one." | |
275 | fi | |
276 | exit 1 | |
277 | fi | |
278 | fi | |
279 | fi | |
280 | SHELL=${CONFIG_SHELL-/bin/sh} | |
281 | export SHELL | |
282 | # Unset more variables known to interfere with behavior of common tools. | |
283 | CLICOLOR_FORCE= GREP_OPTIONS= | |
284 | unset CLICOLOR_FORCE GREP_OPTIONS | |
285 | ||
286 | ## --------------------- ## | |
287 | ## M4sh Shell Functions. ## | |
288 | ## --------------------- ## | |
289 | # as_fn_unset VAR | |
290 | # --------------- | |
291 | # Portably unset VAR. | |
292 | as_fn_unset () | |
293 | { | |
294 | { eval $1=; unset $1;} | |
295 | } | |
296 | as_unset=as_fn_unset | |
297 | ||
298 | # as_fn_set_status STATUS | |
299 | # ----------------------- | |
300 | # Set $? to STATUS, without forking. | |
301 | as_fn_set_status () | |
302 | { | |
303 | return $1 | |
304 | } # as_fn_set_status | |
305 | ||
306 | # as_fn_exit STATUS | |
307 | # ----------------- | |
308 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
309 | as_fn_exit () | |
310 | { | |
311 | set +e | |
312 | as_fn_set_status $1 | |
313 | exit $1 | |
314 | } # as_fn_exit | |
315 | ||
316 | # as_fn_mkdir_p | |
317 | # ------------- | |
318 | # Create "$as_dir" as a directory, including parents if necessary. | |
319 | as_fn_mkdir_p () | |
320 | { | |
321 | ||
322 | case $as_dir in #( | |
323 | -*) as_dir=./$as_dir;; | |
324 | esac | |
325 | test -d "$as_dir" || eval $as_mkdir_p || { | |
326 | as_dirs= | |
327 | while :; do | |
328 | case $as_dir in #( | |
329 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
330 | *) as_qdir=$as_dir;; | |
331 | esac | |
332 | as_dirs="'$as_qdir' $as_dirs" | |
333 | as_dir=`$as_dirname -- "$as_dir" || | |
334 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
335 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
336 | X"$as_dir" : 'X\(//\)$' \| \ | |
337 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
338 | $as_echo X"$as_dir" | | |
339 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
340 | s//\1/ | |
341 | q | |
342 | } | |
343 | /^X\(\/\/\)[^/].*/{ | |
344 | s//\1/ | |
345 | q | |
346 | } | |
347 | /^X\(\/\/\)$/{ | |
348 | s//\1/ | |
349 | q | |
350 | } | |
351 | /^X\(\/\).*/{ | |
352 | s//\1/ | |
353 | q | |
354 | } | |
355 | s/.*/./; q'` | |
356 | test -d "$as_dir" && break | |
357 | done | |
358 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
359 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
360 | ||
361 | ||
362 | } # as_fn_mkdir_p | |
363 | ||
364 | # as_fn_executable_p FILE | |
365 | # ----------------------- | |
366 | # Test if FILE is an executable regular file. | |
367 | as_fn_executable_p () | |
368 | { | |
369 | test -f "$1" && test -x "$1" | |
370 | } # as_fn_executable_p | |
371 | # as_fn_append VAR VALUE | |
372 | # ---------------------- | |
373 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
374 | # advantage of any shell optimizations that allow amortized linear growth over | |
375 | # repeated appends, instead of the typical quadratic growth present in naive | |
376 | # implementations. | |
377 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
378 | eval 'as_fn_append () | |
379 | { | |
380 | eval $1+=\$2 | |
381 | }' | |
382 | else | |
383 | as_fn_append () | |
384 | { | |
385 | eval $1=\$$1\$2 | |
386 | } | |
387 | fi # as_fn_append | |
388 | ||
389 | # as_fn_arith ARG... | |
390 | # ------------------ | |
391 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
392 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
393 | # must be portable across $(()) and expr. | |
394 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
395 | eval 'as_fn_arith () | |
396 | { | |
397 | as_val=$(( $* )) | |
398 | }' | |
399 | else | |
400 | as_fn_arith () | |
401 | { | |
402 | as_val=`expr "$@" || test $? -eq 1` | |
403 | } | |
404 | fi # as_fn_arith | |
405 | ||
406 | ||
407 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
408 | # ---------------------------------------- | |
409 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
410 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
411 | # script with STATUS, using 1 if that was 0. | |
412 | as_fn_error () | |
413 | { | |
414 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
415 | if test "$4"; then | |
416 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
417 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
418 | fi | |
419 | $as_echo "$as_me: error: $2" >&2 | |
420 | as_fn_exit $as_status | |
421 | } # as_fn_error | |
422 | ||
3185942a JA |
423 | if expr a : '\(a\)' >/dev/null 2>&1 && |
424 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
0628567a JA |
425 | as_expr=expr |
426 | else | |
427 | as_expr=false | |
428 | fi | |
429 | ||
3185942a | 430 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
0628567a JA |
431 | as_basename=basename |
432 | else | |
433 | as_basename=false | |
434 | fi | |
b80f6443 | 435 | |
ac50fbac CR |
436 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
437 | as_dirname=dirname | |
438 | else | |
439 | as_dirname=false | |
440 | fi | |
b80f6443 | 441 | |
3185942a | 442 | as_me=`$as_basename -- "$0" || |
b80f6443 JA |
443 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
444 | X"$0" : 'X\(//\)$' \| \ | |
3185942a JA |
445 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
446 | $as_echo X/"$0" | | |
447 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
448 | s//\1/ | |
449 | q | |
450 | } | |
451 | /^X\/\(\/\/\)$/{ | |
452 | s//\1/ | |
453 | q | |
454 | } | |
455 | /^X\/\(\/\).*/{ | |
456 | s//\1/ | |
457 | q | |
458 | } | |
459 | s/.*/./; q'` | |
b80f6443 | 460 | |
ac50fbac CR |
461 | # Avoid depending upon Character Ranges. |
462 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
463 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
464 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
465 | as_cr_digits='0123456789' | |
466 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
0628567a | 467 | |
ccc6cda3 | 468 | |
ac50fbac CR |
469 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
470 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
471 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
472 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
473 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
474 | sed -n ' | |
475 | p | |
476 | /[$]LINENO/= | |
477 | ' <$as_myself | | |
478 | sed ' | |
479 | s/[$]LINENO.*/&-/ | |
480 | t lineno | |
481 | b | |
482 | :lineno | |
483 | N | |
484 | :loop | |
485 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
486 | t loop | |
487 | s/-\n.*// | |
488 | ' >$as_me.lineno && | |
489 | chmod +x "$as_me.lineno" || | |
490 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
ccc6cda3 | 491 | |
ac50fbac CR |
492 | # If we had to re-execute with $CONFIG_SHELL, we're ensured to have |
493 | # already done that, so ensure we don't try to do so again and fall | |
494 | # in an infinite loop. This has already happened in practice. | |
495 | _as_can_reexec=no; export _as_can_reexec | |
496 | # Don't try to exec as it changes $[0], causing all sort of problems | |
497 | # (the dirname of $[0] is not the place where we might find the | |
498 | # original and so on. Autoconf is especially sensitive to this). | |
499 | . "./$as_me.lineno" | |
500 | # Exit status is that of the last command. | |
501 | exit | |
3185942a | 502 | } |
ccc6cda3 | 503 | |
ac50fbac CR |
504 | ECHO_C= ECHO_N= ECHO_T= |
505 | case `echo -n x` in #((((( | |
506 | -n*) | |
507 | case `echo 'xy\c'` in | |
508 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
509 | xy) ECHO_C='\c';; | |
510 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
511 | ECHO_T=' ';; | |
512 | esac;; | |
513 | *) | |
514 | ECHO_N='-n';; | |
515 | esac | |
3185942a | 516 | |
ac50fbac CR |
517 | rm -f conf$$ conf$$.exe conf$$.file |
518 | if test -d conf$$.dir; then | |
519 | rm -f conf$$.dir/conf$$.file | |
3185942a | 520 | else |
ac50fbac CR |
521 | rm -f conf$$.dir |
522 | mkdir conf$$.dir 2>/dev/null | |
3185942a | 523 | fi |
ac50fbac CR |
524 | if (echo >conf$$.file) 2>/dev/null; then |
525 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
526 | as_ln_s='ln -s' | |
527 | # ... but there are two gotchas: | |
528 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
529 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
530 | # In both cases, we have to default to `cp -pR'. | |
531 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
532 | as_ln_s='cp -pR' | |
533 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
534 | as_ln_s=ln | |
535 | else | |
536 | as_ln_s='cp -pR' | |
537 | fi | |
538 | else | |
539 | as_ln_s='cp -pR' | |
3185942a | 540 | fi |
ac50fbac CR |
541 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
542 | rmdir conf$$.dir 2>/dev/null | |
3185942a | 543 | |
ac50fbac CR |
544 | if mkdir -p . 2>/dev/null; then |
545 | as_mkdir_p='mkdir -p "$as_dir"' | |
3185942a | 546 | else |
ac50fbac CR |
547 | test -d ./-p && rmdir ./-p |
548 | as_mkdir_p=false | |
3185942a JA |
549 | fi |
550 | ||
ac50fbac CR |
551 | as_test_x='test -x' |
552 | as_executable_p=as_fn_executable_p | |
3185942a | 553 | |
ac50fbac CR |
554 | # Sed expression to map a string onto a valid CPP name. |
555 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
3185942a | 556 | |
ac50fbac CR |
557 | # Sed expression to map a string onto a valid variable name. |
558 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
3185942a | 559 | |
3185942a | 560 | |
ac50fbac CR |
561 | test -n "$DJDIR" || exec 7<&0 </dev/null |
562 | exec 6>&1 | |
3185942a | 563 | |
ac50fbac CR |
564 | # Name of the host. |
565 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, | |
566 | # so uname gets run too. | |
567 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
3185942a | 568 | |
ac50fbac CR |
569 | # |
570 | # Initializations. | |
571 | # | |
572 | ac_default_prefix=/usr/local | |
573 | ac_clean_files= | |
574 | ac_config_libobj_dir=. | |
575 | LIBOBJS= | |
576 | cross_compiling=no | |
577 | subdirs= | |
578 | MFLAGS= | |
579 | MAKEFLAGS= | |
f73dda09 | 580 | |
b80f6443 JA |
581 | # Identity of this package. |
582 | PACKAGE_NAME='bash' | |
583 | PACKAGE_TARNAME='bash' | |
a0c0a00f CR |
584 | PACKAGE_VERSION='4.4-release' |
585 | PACKAGE_STRING='bash 4.4-release' | |
b80f6443 | 586 | PACKAGE_BUGREPORT='bug-bash@gnu.org' |
ac50fbac | 587 | PACKAGE_URL='' |
b80f6443 | 588 | |
f73dda09 JA |
589 | ac_unique_file="shell.h" |
590 | # Factoring default headers for most tests. | |
591 | ac_includes_default="\ | |
592 | #include <stdio.h> | |
3185942a | 593 | #ifdef HAVE_SYS_TYPES_H |
f73dda09 JA |
594 | # include <sys/types.h> |
595 | #endif | |
3185942a | 596 | #ifdef HAVE_SYS_STAT_H |
f73dda09 JA |
597 | # include <sys/stat.h> |
598 | #endif | |
3185942a | 599 | #ifdef STDC_HEADERS |
f73dda09 JA |
600 | # include <stdlib.h> |
601 | # include <stddef.h> | |
602 | #else | |
3185942a | 603 | # ifdef HAVE_STDLIB_H |
f73dda09 JA |
604 | # include <stdlib.h> |
605 | # endif | |
606 | #endif | |
3185942a JA |
607 | #ifdef HAVE_STRING_H |
608 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
f73dda09 JA |
609 | # include <memory.h> |
610 | # endif | |
611 | # include <string.h> | |
612 | #endif | |
3185942a | 613 | #ifdef HAVE_STRINGS_H |
f73dda09 JA |
614 | # include <strings.h> |
615 | #endif | |
3185942a | 616 | #ifdef HAVE_INTTYPES_H |
f73dda09 | 617 | # include <inttypes.h> |
f73dda09 | 618 | #endif |
3185942a JA |
619 | #ifdef HAVE_STDINT_H |
620 | # include <stdint.h> | |
621 | #endif | |
622 | #ifdef HAVE_UNISTD_H | |
f73dda09 JA |
623 | # include <unistd.h> |
624 | #endif" | |
ccc6cda3 | 625 | |
3185942a JA |
626 | ac_header_list= |
627 | ac_func_list= | |
628 | ac_subst_vars='LTLIBOBJS | |
629 | LOCAL_DEFS | |
630 | LOCAL_LDFLAGS | |
631 | LOCAL_CFLAGS | |
632 | LOCAL_LIBS | |
633 | MALLOC_DEBUG | |
634 | DEBUG | |
635 | RELSTATUS | |
636 | BASHVERS | |
637 | ARFLAGS | |
a0c0a00f CR |
638 | headersdir |
639 | loadablesdir | |
3185942a JA |
640 | BUILD_DIR |
641 | incdir | |
642 | PROFILE_FLAGS | |
643 | SHOBJ_STATUS | |
644 | SHOBJ_LIBS | |
645 | SHOBJ_XLDFLAGS | |
646 | SHOBJ_LDFLAGS | |
647 | SHOBJ_LD | |
648 | SHOBJ_CFLAGS | |
649 | SHOBJ_CC | |
650 | JOBS_O | |
651 | TERMCAP_DEP | |
652 | TERMCAP_LIB | |
653 | SIGLIST_O | |
ac50fbac CR |
654 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC |
655 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC | |
656 | TIME_H_DEFINES_STRUCT_TIMESPEC | |
3185942a JA |
657 | LIBINTL_H |
658 | INTL_INC | |
659 | INTL_DEP | |
660 | LIBOBJS | |
661 | POSUB | |
662 | LTLIBINTL | |
663 | LIBINTL | |
664 | INTLLIBS | |
665 | INTL_LIBTOOL_SUFFIX_PREFIX | |
666 | INTLOBJS | |
667 | GENCAT | |
668 | INSTOBJEXT | |
669 | DATADIRNAME | |
670 | CATOBJEXT | |
671 | USE_INCLUDED_LIBINTL | |
672 | BUILD_INCLUDED_LIBINTL | |
673 | INTLBISON | |
674 | LTLIBICONV | |
675 | LIBICONV | |
676 | GLIBC21 | |
677 | ALLOCA | |
678 | MSGMERGE | |
679 | XGETTEXT | |
680 | GMSGFMT | |
681 | MSGFMT | |
682 | USE_NLS | |
683 | MKINSTALLDIRS | |
684 | SIZE | |
685 | MAKE_SHELL | |
686 | SET_MAKE | |
687 | YFLAGS | |
688 | YACC | |
689 | RANLIB | |
690 | AR | |
691 | INSTALL_DATA | |
692 | INSTALL_SCRIPT | |
693 | INSTALL_PROGRAM | |
694 | TILDE_LIB | |
695 | HIST_LIBDIR | |
696 | HISTORY_DEP | |
697 | HISTORY_LIB | |
698 | RL_INCLUDE | |
699 | RL_INCLUDEDIR | |
700 | RL_LIBDIR | |
701 | READLINE_DEP | |
702 | READLINE_LIB | |
703 | RL_MINOR | |
704 | RL_MAJOR | |
705 | RL_VERSION | |
ac50fbac | 706 | LIBS_FOR_BUILD |
3185942a | 707 | STATIC_LD |
3185942a JA |
708 | SIGNAMES_O |
709 | SIGNAMES_H | |
710 | CROSS_COMPILE | |
711 | EGREP | |
712 | GREP | |
713 | CPP | |
714 | OBJEXT | |
715 | EXEEXT | |
716 | ac_ct_CC | |
717 | CPPFLAGS | |
718 | LDFLAGS | |
719 | CFLAGS | |
720 | CC | |
721 | HELPSTRINGS | |
ac50fbac | 722 | HELPFILES_TARGET |
3185942a JA |
723 | HELPINSTALL |
724 | HELPDIRDEFINE | |
725 | HELPDIR | |
726 | MALLOC_DEP | |
727 | MALLOC_LDFLAGS | |
728 | MALLOC_LIBRARY | |
729 | MALLOC_LIB | |
730 | MALLOC_SRC | |
731 | MALLOC_TARGET | |
3185942a | 732 | TESTSCRIPT |
ac50fbac CR |
733 | CPPFLAGS_FOR_BUILD |
734 | LDFLAGS_FOR_BUILD | |
735 | CFLAGS_FOR_BUILD | |
736 | CC_FOR_BUILD | |
3185942a | 737 | DEBUGGER_START_FILE |
3185942a JA |
738 | host_os |
739 | host_vendor | |
740 | host_cpu | |
741 | host | |
742 | build_os | |
743 | build_vendor | |
744 | build_cpu | |
745 | build | |
746 | target_alias | |
747 | host_alias | |
748 | build_alias | |
749 | LIBS | |
750 | ECHO_T | |
751 | ECHO_N | |
752 | ECHO_C | |
753 | DEFS | |
754 | mandir | |
755 | localedir | |
756 | libdir | |
757 | psdir | |
758 | pdfdir | |
759 | dvidir | |
760 | htmldir | |
761 | infodir | |
762 | docdir | |
763 | oldincludedir | |
764 | includedir | |
765 | localstatedir | |
766 | sharedstatedir | |
767 | sysconfdir | |
768 | datadir | |
769 | datarootdir | |
770 | libexecdir | |
771 | sbindir | |
772 | bindir | |
773 | program_transform_name | |
774 | prefix | |
775 | exec_prefix | |
ac50fbac | 776 | PACKAGE_URL |
3185942a JA |
777 | PACKAGE_BUGREPORT |
778 | PACKAGE_STRING | |
779 | PACKAGE_VERSION | |
780 | PACKAGE_TARNAME | |
781 | PACKAGE_NAME | |
782 | PATH_SEPARATOR | |
783 | SHELL' | |
0628567a | 784 | ac_subst_files='' |
3185942a JA |
785 | ac_user_opts=' |
786 | enable_option_checking | |
3185942a JA |
787 | with_afs |
788 | with_bash_malloc | |
789 | with_curses | |
790 | with_gnu_malloc | |
791 | with_installed_readline | |
3185942a JA |
792 | enable_minimal_config |
793 | enable_alias | |
794 | enable_arith_for_command | |
795 | enable_array_variables | |
796 | enable_bang_history | |
797 | enable_brace_expansion | |
798 | enable_casemod_attributes | |
799 | enable_casemod_expansions | |
800 | enable_command_timing | |
801 | enable_cond_command | |
802 | enable_cond_regexp | |
803 | enable_coprocesses | |
804 | enable_debugger | |
ac50fbac | 805 | enable_direxpand_default |
3185942a JA |
806 | enable_directory_stack |
807 | enable_disabled_builtins | |
808 | enable_dparen_arithmetic | |
809 | enable_extended_glob | |
0001803f | 810 | enable_extended_glob_default |
a0c0a00f | 811 | enable_function_import |
ac50fbac | 812 | enable_glob_asciiranges_default |
3185942a JA |
813 | enable_help_builtin |
814 | enable_history | |
815 | enable_job_control | |
816 | enable_multibyte | |
817 | enable_net_redirections | |
818 | enable_process_substitution | |
819 | enable_progcomp | |
820 | enable_prompt_string_decoding | |
821 | enable_readline | |
822 | enable_restricted | |
823 | enable_select | |
824 | enable_separate_helpfiles | |
825 | enable_single_help_strings | |
826 | enable_strict_posix_default | |
827 | enable_usg_echo_default | |
828 | enable_xpg_echo_default | |
829 | enable_mem_scramble | |
830 | enable_profiling | |
831 | enable_static_link | |
832 | enable_largefile | |
833 | enable_nls | |
834 | with_gnu_ld | |
835 | enable_rpath | |
836 | with_libiconv_prefix | |
837 | with_included_gettext | |
838 | with_libintl_prefix | |
839 | ' | |
840 | ac_precious_vars='build_alias | |
841 | host_alias | |
842 | target_alias | |
843 | DEBUGGER_START_FILE | |
ac50fbac CR |
844 | CC_FOR_BUILD |
845 | CFLAGS_FOR_BUILD | |
846 | LDFLAGS_FOR_BUILD | |
847 | CPPFLAGS_FOR_BUILD | |
3185942a JA |
848 | CC |
849 | CFLAGS | |
850 | LDFLAGS | |
851 | LIBS | |
852 | CPPFLAGS | |
853 | CPP | |
854 | YACC | |
855 | YFLAGS' | |
856 | ||
b80f6443 | 857 | |
ccc6cda3 | 858 | # Initialize some variables set by options. |
f73dda09 JA |
859 | ac_init_help= |
860 | ac_init_version=false | |
3185942a JA |
861 | ac_unrecognized_opts= |
862 | ac_unrecognized_sep= | |
ccc6cda3 JA |
863 | # The variables have the same names as the options, with |
864 | # dashes changed to underlines. | |
f73dda09 | 865 | cache_file=/dev/null |
ccc6cda3 | 866 | exec_prefix=NONE |
ccc6cda3 | 867 | no_create= |
ccc6cda3 JA |
868 | no_recursion= |
869 | prefix=NONE | |
870 | program_prefix=NONE | |
871 | program_suffix=NONE | |
872 | program_transform_name=s,x,x, | |
873 | silent= | |
874 | site= | |
875 | srcdir= | |
ccc6cda3 JA |
876 | verbose= |
877 | x_includes=NONE | |
878 | x_libraries=NONE | |
f73dda09 JA |
879 | |
880 | # Installation directory options. | |
881 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
882 | # and all the variables that are supposed to be based on exec_prefix | |
883 | # by default will actually change. | |
884 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
3185942a | 885 | # (The list follows the same order as the GNU Coding Standards.) |
ccc6cda3 JA |
886 | bindir='${exec_prefix}/bin' |
887 | sbindir='${exec_prefix}/sbin' | |
888 | libexecdir='${exec_prefix}/libexec' | |
3185942a JA |
889 | datarootdir='${prefix}/share' |
890 | datadir='${datarootdir}' | |
ccc6cda3 JA |
891 | sysconfdir='${prefix}/etc' |
892 | sharedstatedir='${prefix}/com' | |
893 | localstatedir='${prefix}/var' | |
ccc6cda3 JA |
894 | includedir='${prefix}/include' |
895 | oldincludedir='/usr/include' | |
3185942a JA |
896 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
897 | infodir='${datarootdir}/info' | |
898 | htmldir='${docdir}' | |
899 | dvidir='${docdir}' | |
900 | pdfdir='${docdir}' | |
901 | psdir='${docdir}' | |
902 | libdir='${exec_prefix}/lib' | |
903 | localedir='${datarootdir}/locale' | |
904 | mandir='${datarootdir}/man' | |
ccc6cda3 | 905 | |
ccc6cda3 | 906 | ac_prev= |
3185942a | 907 | ac_dashdash= |
ccc6cda3 JA |
908 | for ac_option |
909 | do | |
ccc6cda3 JA |
910 | # If the previous option needs an argument, assign it. |
911 | if test -n "$ac_prev"; then | |
3185942a | 912 | eval $ac_prev=\$ac_option |
ccc6cda3 JA |
913 | ac_prev= |
914 | continue | |
915 | fi | |
916 | ||
3185942a | 917 | case $ac_option in |
ac50fbac CR |
918 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
919 | *=) ac_optarg= ;; | |
920 | *) ac_optarg=yes ;; | |
3185942a | 921 | esac |
ccc6cda3 JA |
922 | |
923 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
924 | ||
3185942a JA |
925 | case $ac_dashdash$ac_option in |
926 | --) | |
927 | ac_dashdash=yes ;; | |
ccc6cda3 JA |
928 | |
929 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
930 | ac_prev=bindir ;; | |
931 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
f73dda09 | 932 | bindir=$ac_optarg ;; |
ccc6cda3 JA |
933 | |
934 | -build | --build | --buil | --bui | --bu) | |
f73dda09 | 935 | ac_prev=build_alias ;; |
ccc6cda3 | 936 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
f73dda09 | 937 | build_alias=$ac_optarg ;; |
ccc6cda3 JA |
938 | |
939 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
940 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
941 | ac_prev=cache_file ;; | |
942 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
943 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
f73dda09 JA |
944 | cache_file=$ac_optarg ;; |
945 | ||
946 | --config-cache | -C) | |
947 | cache_file=config.cache ;; | |
ccc6cda3 | 948 | |
3185942a | 949 | -datadir | --datadir | --datadi | --datad) |
ccc6cda3 | 950 | ac_prev=datadir ;; |
3185942a | 951 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
f73dda09 | 952 | datadir=$ac_optarg ;; |
ccc6cda3 | 953 | |
3185942a JA |
954 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
955 | | --dataroo | --dataro | --datar) | |
956 | ac_prev=datarootdir ;; | |
957 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
958 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
959 | datarootdir=$ac_optarg ;; | |
960 | ||
ccc6cda3 | 961 | -disable-* | --disable-*) |
3185942a | 962 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
ccc6cda3 | 963 | # Reject names that are not valid shell variable names. |
3185942a | 964 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
ac50fbac | 965 | as_fn_error $? "invalid feature name: $ac_useropt" |
3185942a JA |
966 | ac_useropt_orig=$ac_useropt |
967 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
968 | case $ac_user_opts in | |
969 | *" | |
970 | "enable_$ac_useropt" | |
971 | "*) ;; | |
972 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
973 | ac_unrecognized_sep=', ';; | |
974 | esac | |
975 | eval enable_$ac_useropt=no ;; | |
976 | ||
977 | -docdir | --docdir | --docdi | --doc | --do) | |
978 | ac_prev=docdir ;; | |
979 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
980 | docdir=$ac_optarg ;; | |
981 | ||
982 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
983 | ac_prev=dvidir ;; | |
984 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
985 | dvidir=$ac_optarg ;; | |
ccc6cda3 JA |
986 | |
987 | -enable-* | --enable-*) | |
3185942a | 988 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
ccc6cda3 | 989 | # Reject names that are not valid shell variable names. |
3185942a | 990 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
ac50fbac | 991 | as_fn_error $? "invalid feature name: $ac_useropt" |
3185942a JA |
992 | ac_useropt_orig=$ac_useropt |
993 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
994 | case $ac_user_opts in | |
995 | *" | |
996 | "enable_$ac_useropt" | |
997 | "*) ;; | |
998 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
999 | ac_unrecognized_sep=', ';; | |
ccc6cda3 | 1000 | esac |
3185942a | 1001 | eval enable_$ac_useropt=\$ac_optarg ;; |
ccc6cda3 JA |
1002 | |
1003 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
1004 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
1005 | | --exec | --exe | --ex) | |
1006 | ac_prev=exec_prefix ;; | |
1007 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
1008 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
1009 | | --exec=* | --exe=* | --ex=*) | |
f73dda09 | 1010 | exec_prefix=$ac_optarg ;; |
ccc6cda3 JA |
1011 | |
1012 | -gas | --gas | --ga | --g) | |
1013 | # Obsolete; use --with-gas. | |
1014 | with_gas=yes ;; | |
1015 | ||
f73dda09 JA |
1016 | -help | --help | --hel | --he | -h) |
1017 | ac_init_help=long ;; | |
1018 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
1019 | ac_init_help=recursive ;; | |
1020 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
1021 | ac_init_help=short ;; | |
ccc6cda3 JA |
1022 | |
1023 | -host | --host | --hos | --ho) | |
f73dda09 | 1024 | ac_prev=host_alias ;; |
ccc6cda3 | 1025 | -host=* | --host=* | --hos=* | --ho=*) |
f73dda09 | 1026 | host_alias=$ac_optarg ;; |
ccc6cda3 | 1027 | |
3185942a JA |
1028 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
1029 | ac_prev=htmldir ;; | |
1030 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
1031 | | --ht=*) | |
1032 | htmldir=$ac_optarg ;; | |
1033 | ||
ccc6cda3 JA |
1034 | -includedir | --includedir | --includedi | --included | --include \ |
1035 | | --includ | --inclu | --incl | --inc) | |
1036 | ac_prev=includedir ;; | |
1037 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
1038 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
f73dda09 | 1039 | includedir=$ac_optarg ;; |
ccc6cda3 JA |
1040 | |
1041 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
1042 | ac_prev=infodir ;; | |
1043 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
f73dda09 | 1044 | infodir=$ac_optarg ;; |
ccc6cda3 JA |
1045 | |
1046 | -libdir | --libdir | --libdi | --libd) | |
1047 | ac_prev=libdir ;; | |
1048 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
f73dda09 | 1049 | libdir=$ac_optarg ;; |
ccc6cda3 JA |
1050 | |
1051 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
1052 | | --libexe | --libex | --libe) | |
1053 | ac_prev=libexecdir ;; | |
1054 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
1055 | | --libexe=* | --libex=* | --libe=*) | |
f73dda09 | 1056 | libexecdir=$ac_optarg ;; |
ccc6cda3 | 1057 | |
3185942a JA |
1058 | -localedir | --localedir | --localedi | --localed | --locale) |
1059 | ac_prev=localedir ;; | |
1060 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
1061 | localedir=$ac_optarg ;; | |
1062 | ||
ccc6cda3 | 1063 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
3185942a | 1064 | | --localstate | --localstat | --localsta | --localst | --locals) |
ccc6cda3 JA |
1065 | ac_prev=localstatedir ;; |
1066 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
3185942a | 1067 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
f73dda09 | 1068 | localstatedir=$ac_optarg ;; |
ccc6cda3 JA |
1069 | |
1070 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
1071 | ac_prev=mandir ;; | |
1072 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
f73dda09 | 1073 | mandir=$ac_optarg ;; |
ccc6cda3 JA |
1074 | |
1075 | -nfp | --nfp | --nf) | |
1076 | # Obsolete; use --without-fp. | |
1077 | with_fp=no ;; | |
1078 | ||
1079 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
b80f6443 | 1080 | | --no-cr | --no-c | -n) |
ccc6cda3 JA |
1081 | no_create=yes ;; |
1082 | ||
1083 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
1084 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
1085 | no_recursion=yes ;; | |
1086 | ||
1087 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
1088 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
1089 | | --oldin | --oldi | --old | --ol | --o) | |
1090 | ac_prev=oldincludedir ;; | |
1091 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
1092 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
1093 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
f73dda09 | 1094 | oldincludedir=$ac_optarg ;; |
ccc6cda3 JA |
1095 | |
1096 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
1097 | ac_prev=prefix ;; | |
1098 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
f73dda09 | 1099 | prefix=$ac_optarg ;; |
ccc6cda3 JA |
1100 | |
1101 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
1102 | | --program-pre | --program-pr | --program-p) | |
1103 | ac_prev=program_prefix ;; | |
1104 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
1105 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
f73dda09 | 1106 | program_prefix=$ac_optarg ;; |
ccc6cda3 JA |
1107 | |
1108 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
1109 | | --program-suf | --program-su | --program-s) | |
1110 | ac_prev=program_suffix ;; | |
1111 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
1112 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
f73dda09 | 1113 | program_suffix=$ac_optarg ;; |
ccc6cda3 JA |
1114 | |
1115 | -program-transform-name | --program-transform-name \ | |
1116 | | --program-transform-nam | --program-transform-na \ | |
1117 | | --program-transform-n | --program-transform- \ | |
1118 | | --program-transform | --program-transfor \ | |
1119 | | --program-transfo | --program-transf \ | |
1120 | | --program-trans | --program-tran \ | |
1121 | | --progr-tra | --program-tr | --program-t) | |
1122 | ac_prev=program_transform_name ;; | |
1123 | -program-transform-name=* | --program-transform-name=* \ | |
1124 | | --program-transform-nam=* | --program-transform-na=* \ | |
1125 | | --program-transform-n=* | --program-transform-=* \ | |
1126 | | --program-transform=* | --program-transfor=* \ | |
1127 | | --program-transfo=* | --program-transf=* \ | |
1128 | | --program-trans=* | --program-tran=* \ | |
1129 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
f73dda09 | 1130 | program_transform_name=$ac_optarg ;; |
ccc6cda3 | 1131 | |
3185942a JA |
1132 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
1133 | ac_prev=pdfdir ;; | |
1134 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1135 | pdfdir=$ac_optarg ;; | |
1136 | ||
1137 | -psdir | --psdir | --psdi | --psd | --ps) | |
1138 | ac_prev=psdir ;; | |
1139 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1140 | psdir=$ac_optarg ;; | |
1141 | ||
ccc6cda3 JA |
1142 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
1143 | | -silent | --silent | --silen | --sile | --sil) | |
1144 | silent=yes ;; | |
1145 | ||
1146 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1147 | ac_prev=sbindir ;; | |
1148 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1149 | | --sbi=* | --sb=*) | |
f73dda09 | 1150 | sbindir=$ac_optarg ;; |
ccc6cda3 JA |
1151 | |
1152 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1153 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1154 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1155 | | --sha | --sh) | |
1156 | ac_prev=sharedstatedir ;; | |
1157 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1158 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1159 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1160 | | --sha=* | --sh=*) | |
f73dda09 | 1161 | sharedstatedir=$ac_optarg ;; |
ccc6cda3 JA |
1162 | |
1163 | -site | --site | --sit) | |
1164 | ac_prev=site ;; | |
1165 | -site=* | --site=* | --sit=*) | |
f73dda09 | 1166 | site=$ac_optarg ;; |
ccc6cda3 JA |
1167 | |
1168 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1169 | ac_prev=srcdir ;; | |
1170 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
f73dda09 | 1171 | srcdir=$ac_optarg ;; |
ccc6cda3 JA |
1172 | |
1173 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1174 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1175 | ac_prev=sysconfdir ;; | |
1176 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1177 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
f73dda09 | 1178 | sysconfdir=$ac_optarg ;; |
ccc6cda3 JA |
1179 | |
1180 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
f73dda09 | 1181 | ac_prev=target_alias ;; |
ccc6cda3 | 1182 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
f73dda09 | 1183 | target_alias=$ac_optarg ;; |
ccc6cda3 JA |
1184 | |
1185 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1186 | verbose=yes ;; | |
1187 | ||
f73dda09 JA |
1188 | -version | --version | --versio | --versi | --vers | -V) |
1189 | ac_init_version=: ;; | |
ccc6cda3 JA |
1190 | |
1191 | -with-* | --with-*) | |
3185942a | 1192 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
ccc6cda3 | 1193 | # Reject names that are not valid shell variable names. |
3185942a | 1194 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
ac50fbac | 1195 | as_fn_error $? "invalid package name: $ac_useropt" |
3185942a JA |
1196 | ac_useropt_orig=$ac_useropt |
1197 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1198 | case $ac_user_opts in | |
1199 | *" | |
1200 | "with_$ac_useropt" | |
1201 | "*) ;; | |
1202 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1203 | ac_unrecognized_sep=', ';; | |
ccc6cda3 | 1204 | esac |
3185942a | 1205 | eval with_$ac_useropt=\$ac_optarg ;; |
ccc6cda3 JA |
1206 | |
1207 | -without-* | --without-*) | |
3185942a | 1208 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
ccc6cda3 | 1209 | # Reject names that are not valid shell variable names. |
3185942a | 1210 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
ac50fbac | 1211 | as_fn_error $? "invalid package name: $ac_useropt" |
3185942a JA |
1212 | ac_useropt_orig=$ac_useropt |
1213 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1214 | case $ac_user_opts in | |
1215 | *" | |
1216 | "with_$ac_useropt" | |
1217 | "*) ;; | |
1218 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1219 | ac_unrecognized_sep=', ';; | |
1220 | esac | |
1221 | eval with_$ac_useropt=no ;; | |
ccc6cda3 JA |
1222 | |
1223 | --x) | |
1224 | # Obsolete; use --with-x. | |
1225 | with_x=yes ;; | |
1226 | ||
1227 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1228 | | --x-incl | --x-inc | --x-in | --x-i) | |
1229 | ac_prev=x_includes ;; | |
1230 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1231 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
f73dda09 | 1232 | x_includes=$ac_optarg ;; |
ccc6cda3 JA |
1233 | |
1234 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1235 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1236 | ac_prev=x_libraries ;; | |
1237 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1238 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
f73dda09 | 1239 | x_libraries=$ac_optarg ;; |
ccc6cda3 | 1240 | |
ac50fbac CR |
1241 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
1242 | Try \`$0 --help' for more information" | |
ccc6cda3 JA |
1243 | ;; |
1244 | ||
f73dda09 JA |
1245 | *=*) |
1246 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1247 | # Reject names that are not valid shell variable names. | |
ac50fbac CR |
1248 | case $ac_envvar in #( |
1249 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
1250 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; | |
1251 | esac | |
3185942a | 1252 | eval $ac_envvar=\$ac_optarg |
f73dda09 JA |
1253 | export $ac_envvar ;; |
1254 | ||
ccc6cda3 | 1255 | *) |
f73dda09 | 1256 | # FIXME: should be removed in autoconf 3.0. |
3185942a | 1257 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
f73dda09 | 1258 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
3185942a | 1259 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
ac50fbac | 1260 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
ccc6cda3 JA |
1261 | ;; |
1262 | ||
1263 | esac | |
1264 | done | |
1265 | ||
1266 | if test -n "$ac_prev"; then | |
f73dda09 | 1267 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
ac50fbac | 1268 | as_fn_error $? "missing argument to $ac_option" |
ccc6cda3 | 1269 | fi |
ccc6cda3 | 1270 | |
3185942a JA |
1271 | if test -n "$ac_unrecognized_opts"; then |
1272 | case $enable_option_checking in | |
1273 | no) ;; | |
ac50fbac | 1274 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
3185942a | 1275 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
f73dda09 | 1276 | esac |
3185942a | 1277 | fi |
ccc6cda3 | 1278 | |
3185942a JA |
1279 | # Check all directory arguments for consistency. |
1280 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ | |
1281 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1282 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
1283 | libdir localedir mandir | |
ccc6cda3 | 1284 | do |
3185942a JA |
1285 | eval ac_val=\$$ac_var |
1286 | # Remove trailing slashes. | |
f73dda09 | 1287 | case $ac_val in |
3185942a JA |
1288 | */ ) |
1289 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1290 | eval $ac_var=\$ac_val;; | |
ccc6cda3 | 1291 | esac |
3185942a JA |
1292 | # Be sure to have absolute directory names. |
1293 | case $ac_val in | |
1294 | [\\/$]* | ?:[\\/]* ) continue;; | |
1295 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
1296 | esac | |
ac50fbac | 1297 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
ccc6cda3 JA |
1298 | done |
1299 | ||
f73dda09 JA |
1300 | # There might be people who depend on the old broken behavior: `$host' |
1301 | # used to hold the argument of --host etc. | |
b80f6443 | 1302 | # FIXME: To remove some day. |
f73dda09 JA |
1303 | build=$build_alias |
1304 | host=$host_alias | |
1305 | target=$target_alias | |
1306 | ||
b80f6443 | 1307 | # FIXME: To remove some day. |
f73dda09 JA |
1308 | if test "x$host_alias" != x; then |
1309 | if test "x$build_alias" = x; then | |
1310 | cross_compiling=maybe | |
f73dda09 JA |
1311 | elif test "x$build_alias" != "x$host_alias"; then |
1312 | cross_compiling=yes | |
1313 | fi | |
1314 | fi | |
ccc6cda3 | 1315 | |
f73dda09 JA |
1316 | ac_tool_prefix= |
1317 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
ccc6cda3 | 1318 | |
f73dda09 | 1319 | test "$silent" = yes && exec 6>/dev/null |
ccc6cda3 | 1320 | |
b80f6443 | 1321 | |
3185942a JA |
1322 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
1323 | ac_ls_di=`ls -di .` && | |
1324 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
ac50fbac | 1325 | as_fn_error $? "working directory cannot be determined" |
3185942a | 1326 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
ac50fbac | 1327 | as_fn_error $? "pwd does not report name of working directory" |
3185942a JA |
1328 | |
1329 | ||
ccc6cda3 JA |
1330 | # Find the source files, if location was not specified. |
1331 | if test -z "$srcdir"; then | |
1332 | ac_srcdir_defaulted=yes | |
3185942a JA |
1333 | # Try the directory containing this script, then the parent directory. |
1334 | ac_confdir=`$as_dirname -- "$as_myself" || | |
1335 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1336 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1337 | X"$as_myself" : 'X\(//\)$' \| \ | |
1338 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1339 | $as_echo X"$as_myself" | | |
1340 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
1341 | s//\1/ | |
1342 | q | |
1343 | } | |
1344 | /^X\(\/\/\)[^/].*/{ | |
1345 | s//\1/ | |
1346 | q | |
1347 | } | |
1348 | /^X\(\/\/\)$/{ | |
1349 | s//\1/ | |
1350 | q | |
1351 | } | |
1352 | /^X\(\/\).*/{ | |
1353 | s//\1/ | |
1354 | q | |
1355 | } | |
1356 | s/.*/./; q'` | |
ccc6cda3 | 1357 | srcdir=$ac_confdir |
3185942a | 1358 | if test ! -r "$srcdir/$ac_unique_file"; then |
ccc6cda3 JA |
1359 | srcdir=.. |
1360 | fi | |
1361 | else | |
1362 | ac_srcdir_defaulted=no | |
1363 | fi | |
3185942a JA |
1364 | if test ! -r "$srcdir/$ac_unique_file"; then |
1365 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
ac50fbac | 1366 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
ccc6cda3 | 1367 | fi |
3185942a JA |
1368 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
1369 | ac_abs_confdir=`( | |
ac50fbac | 1370 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
3185942a JA |
1371 | pwd)` |
1372 | # When building in place, set srcdir=. | |
1373 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1374 | srcdir=. | |
1375 | fi | |
1376 | # Remove unnecessary trailing slashes from srcdir. | |
1377 | # Double slashes in file names in object file debugging info | |
1378 | # mess up M-x gdb in Emacs. | |
1379 | case $srcdir in | |
1380 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1381 | esac | |
1382 | for ac_var in $ac_precious_vars; do | |
1383 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1384 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1385 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1386 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1387 | done | |
ccc6cda3 | 1388 | |
f73dda09 JA |
1389 | # |
1390 | # Report the --help message. | |
1391 | # | |
1392 | if test "$ac_init_help" = "long"; then | |
1393 | # Omit some internal or obsolete options to make the list less imposing. | |
1394 | # This message is too long to be a string in the A/UX 3.1 sh. | |
b80f6443 | 1395 | cat <<_ACEOF |
a0c0a00f | 1396 | \`configure' configures bash 4.4-release to adapt to many kinds of systems. |
ccc6cda3 | 1397 | |
f73dda09 | 1398 | Usage: $0 [OPTION]... [VAR=VALUE]... |
ccc6cda3 | 1399 | |
f73dda09 JA |
1400 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
1401 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
1402 | ||
1403 | Defaults for the options are specified in brackets. | |
ccc6cda3 | 1404 | |
f73dda09 JA |
1405 | Configuration: |
1406 | -h, --help display this help and exit | |
1407 | --help=short display options specific to this package | |
1408 | --help=recursive display the short help of all the included packages | |
1409 | -V, --version display version information and exit | |
ac50fbac | 1410 | -q, --quiet, --silent do not print \`checking ...' messages |
f73dda09 JA |
1411 | --cache-file=FILE cache test results in FILE [disabled] |
1412 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1413 | -n, --no-create do not create output files | |
1414 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
ccc6cda3 | 1415 | |
f73dda09 JA |
1416 | Installation directories: |
1417 | --prefix=PREFIX install architecture-independent files in PREFIX | |
3185942a | 1418 | [$ac_default_prefix] |
f73dda09 | 1419 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
3185942a | 1420 | [PREFIX] |
ccc6cda3 | 1421 | |
f73dda09 JA |
1422 | By default, \`make install' will install all the files in |
1423 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1424 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1425 | for instance \`--prefix=\$HOME'. | |
ccc6cda3 | 1426 | |
f73dda09 | 1427 | For better control, use the options below. |
ccc6cda3 | 1428 | |
f73dda09 | 1429 | Fine tuning of the installation directories: |
3185942a JA |
1430 | --bindir=DIR user executables [EPREFIX/bin] |
1431 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1432 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1433 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1434 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1435 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1436 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1437 | --includedir=DIR C header files [PREFIX/include] | |
1438 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1439 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1440 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1441 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1442 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1443 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1444 | --docdir=DIR documentation root [DATAROOTDIR/doc/bash] | |
1445 | --htmldir=DIR html documentation [DOCDIR] | |
1446 | --dvidir=DIR dvi documentation [DOCDIR] | |
1447 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1448 | --psdir=DIR ps documentation [DOCDIR] | |
b80f6443 | 1449 | _ACEOF |
f73dda09 | 1450 | |
b80f6443 | 1451 | cat <<\_ACEOF |
f73dda09 JA |
1452 | |
1453 | System types: | |
1454 | --build=BUILD configure for building on BUILD [guessed] | |
b80f6443 JA |
1455 | --host=HOST cross-compile to build programs to run on HOST [BUILD] |
1456 | _ACEOF | |
ccc6cda3 | 1457 | fi |
ccc6cda3 | 1458 | |
f73dda09 JA |
1459 | if test -n "$ac_init_help"; then |
1460 | case $ac_init_help in | |
a0c0a00f | 1461 | short | recursive ) echo "Configuration of bash 4.4-release:";; |
f73dda09 | 1462 | esac |
b80f6443 | 1463 | cat <<\_ACEOF |
ccc6cda3 | 1464 | |
f73dda09 | 1465 | Optional Features: |
3185942a | 1466 | --disable-option-checking ignore unrecognized --enable/--with options |
f73dda09 JA |
1467 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
1468 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
7117c2d2 JA |
1469 | --enable-minimal-config a minimal sh-like configuration |
1470 | --enable-alias enable shell aliases | |
1471 | --enable-arith-for-command | |
1472 | enable arithmetic for command | |
1473 | --enable-array-variables | |
1474 | include shell array variables | |
1475 | --enable-bang-history turn on csh-style history substitution | |
1476 | --enable-brace-expansion | |
1477 | include brace expansion | |
3185942a JA |
1478 | --enable-casemod-attributes |
1479 | include case-modifying variable attributes | |
1480 | --enable-casemod-expansions | |
1481 | include case-modifying word expansions | |
7117c2d2 JA |
1482 | --enable-command-timing enable the time reserved word and command timing |
1483 | --enable-cond-command enable the conditional command | |
3185942a | 1484 | --enable-cond-regexp enable extended regular expression matching in |
b80f6443 | 1485 | conditional commands |
3185942a JA |
1486 | --enable-coprocesses enable coprocess support and the coproc reserved |
1487 | word | |
b80f6443 | 1488 | --enable-debugger enable support for bash debugger |
ac50fbac CR |
1489 | --enable-direxpand-default |
1490 | enable the direxpand shell option by default | |
7117c2d2 JA |
1491 | --enable-directory-stack |
1492 | enable builtins pushd/popd/dirs | |
1493 | --enable-disabled-builtins | |
1494 | allow disabled builtins to still be invoked | |
1495 | --enable-dparen-arithmetic | |
1496 | include ((...)) command | |
1497 | --enable-extended-glob include ksh-style extended pattern matching | |
0001803f CR |
1498 | --enable-extended-glob-default |
1499 | force extended pattern matching to be enabled by | |
1500 | default | |
a0c0a00f CR |
1501 | --enable-function-import |
1502 | allow bash to import exported function definitions | |
1503 | by default | |
ac50fbac CR |
1504 | --enable-glob-asciiranges-default |
1505 | force bracket range expressions in pattern matching | |
1506 | to use the C locale by default | |
7117c2d2 JA |
1507 | --enable-help-builtin include the help builtin |
1508 | --enable-history turn on command history | |
1509 | --enable-job-control enable job control features | |
b80f6443 | 1510 | --enable-multibyte enable multibyte characters if OS supports them |
7117c2d2 JA |
1511 | --enable-net-redirections |
1512 | enable /dev/tcp/host/port redirection | |
1513 | --enable-process-substitution | |
1514 | enable process substitution | |
1515 | --enable-progcomp enable programmable completion and the complete | |
1516 | builtin | |
1517 | --enable-prompt-string-decoding | |
1518 | turn on escape character decoding in prompts | |
1519 | --enable-readline turn on command line editing | |
1520 | --enable-restricted enable a restricted shell | |
1521 | --enable-select include select command | |
1522 | --enable-separate-helpfiles | |
1523 | use external files for help builtin documentation | |
95732b49 JA |
1524 | --enable-single-help-strings |
1525 | store help documentation as a single string to ease | |
1526 | translation | |
1527 | --enable-strict-posix-default | |
1528 | configure bash to be posix-conformant by default | |
7117c2d2 JA |
1529 | --enable-usg-echo-default |
1530 | a synonym for --enable-xpg-echo-default | |
1531 | --enable-xpg-echo-default | |
1532 | make the echo builtin expand escape sequences by | |
1533 | default | |
1534 | --enable-mem-scramble scramble memory on calls to malloc and free | |
1535 | --enable-profiling allow profiling with gprof | |
1536 | --enable-static-link link bash statically, for use as a root shell | |
f73dda09 | 1537 | --disable-largefile omit support for large files |
b80f6443 JA |
1538 | --disable-nls do not use Native Language Support |
1539 | --disable-rpath do not hardcode runtime library paths | |
f73dda09 JA |
1540 | |
1541 | Optional Packages: | |
1542 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
1543 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
7117c2d2 JA |
1544 | --with-afs if you are running AFS |
1545 | --with-bash-malloc use the Bash version of malloc | |
1546 | --with-curses use the curses library instead of the termcap | |
1547 | library | |
1548 | --with-gnu-malloc synonym for --with-bash-malloc | |
1549 | --with-installed-readline | |
1550 | use a version of the readline library that is | |
1551 | already installed | |
b80f6443 JA |
1552 | --with-gnu-ld assume the C compiler uses GNU ld default=no |
1553 | --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib | |
1554 | --without-libiconv-prefix don't search for libiconv in includedir and libdir | |
1555 | --with-included-gettext use the GNU gettext library included here | |
1556 | --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib | |
1557 | --without-libintl-prefix don't search for libintl in includedir and libdir | |
f73dda09 JA |
1558 | |
1559 | Some influential environment variables: | |
b80f6443 JA |
1560 | DEBUGGER_START_FILE |
1561 | location of bash debugger initialization file | |
ac50fbac CR |
1562 | CC_FOR_BUILD |
1563 | C compiler used when compiling binaries used only at build time | |
1564 | CFLAGS_FOR_BUILD | |
1565 | Compliation options (CFLAGS) used when compiling binaries used | |
1566 | only at build time | |
1567 | LDFLAGS_FOR_BUILD | |
1568 | Linker options (LDFLAGS) used when compiling binaries used only | |
1569 | at build time | |
1570 | CPPFLAGS_FOR_BUILD | |
1571 | C preprocessor options (CPPFLAGS) used when compiling binaries | |
1572 | used only at build time | |
f73dda09 JA |
1573 | CC C compiler command |
1574 | CFLAGS C compiler flags | |
1575 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1576 | nonstandard directory <lib dir> | |
3185942a | 1577 | LIBS libraries to pass to the linker, e.g. -l<library> |
ac50fbac | 1578 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
3185942a | 1579 | you have headers in a nonstandard directory <include dir> |
f73dda09 | 1580 | CPP C preprocessor |
ac50fbac CR |
1581 | YACC The `Yet Another Compiler Compiler' implementation to use. |
1582 | Defaults to the first program found out of: `bison -y', `byacc', | |
1583 | `yacc'. | |
3185942a JA |
1584 | YFLAGS The list of arguments that will be passed by default to $YACC. |
1585 | This script will default YFLAGS to the empty string to avoid a | |
1586 | default value of `-d' given by some make applications. | |
f73dda09 JA |
1587 | |
1588 | Use these variables to override the choices made by `configure' or to help | |
1589 | it to find libraries and programs with nonstandard names/locations. | |
1590 | ||
1591 | Report bugs to <bug-bash@gnu.org>. | |
b80f6443 | 1592 | _ACEOF |
3185942a | 1593 | ac_status=$? |
f73dda09 JA |
1594 | fi |
1595 | ||
1596 | if test "$ac_init_help" = "recursive"; then | |
1597 | # If there are subdirs, report their specific --help. | |
b80f6443 | 1598 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
3185942a JA |
1599 | test -d "$ac_dir" || |
1600 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1601 | continue | |
b80f6443 JA |
1602 | ac_builddir=. |
1603 | ||
3185942a JA |
1604 | case "$ac_dir" in |
1605 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1606 | *) | |
1607 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
1608 | # A ".." for each directory in $ac_dir_suffix. | |
1609 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
1610 | case $ac_top_builddir_sub in | |
1611 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1612 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1613 | esac ;; | |
1614 | esac | |
1615 | ac_abs_top_builddir=$ac_pwd | |
1616 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1617 | # for backward compatibility: | |
1618 | ac_top_builddir=$ac_top_build_prefix | |
ccc6cda3 | 1619 | |
b80f6443 | 1620 | case $srcdir in |
3185942a | 1621 | .) # We are building in place. |
b80f6443 | 1622 | ac_srcdir=. |
3185942a JA |
1623 | ac_top_srcdir=$ac_top_builddir_sub |
1624 | ac_abs_top_srcdir=$ac_pwd ;; | |
1625 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
b80f6443 | 1626 | ac_srcdir=$srcdir$ac_dir_suffix; |
3185942a JA |
1627 | ac_top_srcdir=$srcdir |
1628 | ac_abs_top_srcdir=$srcdir ;; | |
1629 | *) # Relative name. | |
1630 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1631 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1632 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
0628567a | 1633 | esac |
3185942a JA |
1634 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
1635 | ||
1636 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1637 | # Check for guested configure. | |
1638 | if test -f "$ac_srcdir/configure.gnu"; then | |
1639 | echo && | |
1640 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1641 | elif test -f "$ac_srcdir/configure"; then | |
1642 | echo && | |
1643 | $SHELL "$ac_srcdir/configure" --help=recursive | |
f73dda09 | 1644 | else |
3185942a JA |
1645 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
1646 | fi || ac_status=$? | |
1647 | cd "$ac_pwd" || { ac_status=$?; break; } | |
f73dda09 JA |
1648 | done |
1649 | fi | |
ccc6cda3 | 1650 | |
3185942a | 1651 | test -n "$ac_init_help" && exit $ac_status |
f73dda09 | 1652 | if $ac_init_version; then |
b80f6443 | 1653 | cat <<\_ACEOF |
a0c0a00f | 1654 | bash configure 4.4-release |
ac50fbac | 1655 | generated by GNU Autoconf 2.69 |
ccc6cda3 | 1656 | |
ac50fbac | 1657 | Copyright (C) 2012 Free Software Foundation, Inc. |
f73dda09 JA |
1658 | This configure script is free software; the Free Software Foundation |
1659 | gives unlimited permission to copy, distribute and modify it. | |
b80f6443 | 1660 | _ACEOF |
3185942a | 1661 | exit |
f73dda09 | 1662 | fi |
ccc6cda3 | 1663 | |
ac50fbac CR |
1664 | ## ------------------------ ## |
1665 | ## Autoconf initialization. ## | |
1666 | ## ------------------------ ## | |
bb70624e | 1667 | |
ac50fbac CR |
1668 | # ac_fn_c_try_compile LINENO |
1669 | # -------------------------- | |
1670 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1671 | ac_fn_c_try_compile () | |
f73dda09 | 1672 | { |
ac50fbac CR |
1673 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
1674 | rm -f conftest.$ac_objext | |
1675 | if { { ac_try="$ac_compile" | |
1676 | case "(($ac_try" in | |
1677 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1678 | *) ac_try_echo=$ac_try;; | |
1679 | esac | |
1680 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1681 | $as_echo "$ac_try_echo"; } >&5 | |
1682 | (eval "$ac_compile") 2>conftest.err | |
1683 | ac_status=$? | |
1684 | if test -s conftest.err; then | |
1685 | grep -v '^ *+' conftest.err >conftest.er1 | |
1686 | cat conftest.er1 >&5 | |
1687 | mv -f conftest.er1 conftest.err | |
1688 | fi | |
1689 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1690 | test $ac_status = 0; } && { | |
1691 | test -z "$ac_c_werror_flag" || | |
1692 | test ! -s conftest.err | |
1693 | } && test -s conftest.$ac_objext; then : | |
1694 | ac_retval=0 | |
1695 | else | |
1696 | $as_echo "$as_me: failed program was:" >&5 | |
1697 | sed 's/^/| /' conftest.$ac_ext >&5 | |
f73dda09 | 1698 | |
ac50fbac CR |
1699 | ac_retval=1 |
1700 | fi | |
1701 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1702 | as_fn_set_status $ac_retval | |
f73dda09 | 1703 | |
ac50fbac | 1704 | } # ac_fn_c_try_compile |
f73dda09 | 1705 | |
ac50fbac CR |
1706 | # ac_fn_c_try_link LINENO |
1707 | # ----------------------- | |
1708 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
1709 | ac_fn_c_try_link () | |
1710 | { | |
1711 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1712 | rm -f conftest.$ac_objext conftest$ac_exeext | |
1713 | if { { ac_try="$ac_link" | |
1714 | case "(($ac_try" in | |
1715 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1716 | *) ac_try_echo=$ac_try;; | |
1717 | esac | |
1718 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1719 | $as_echo "$ac_try_echo"; } >&5 | |
1720 | (eval "$ac_link") 2>conftest.err | |
1721 | ac_status=$? | |
1722 | if test -s conftest.err; then | |
1723 | grep -v '^ *+' conftest.err >conftest.er1 | |
1724 | cat conftest.er1 >&5 | |
1725 | mv -f conftest.er1 conftest.err | |
1726 | fi | |
1727 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1728 | test $ac_status = 0; } && { | |
1729 | test -z "$ac_c_werror_flag" || | |
1730 | test ! -s conftest.err | |
1731 | } && test -s conftest$ac_exeext && { | |
1732 | test "$cross_compiling" = yes || | |
1733 | test -x conftest$ac_exeext | |
1734 | }; then : | |
1735 | ac_retval=0 | |
1736 | else | |
1737 | $as_echo "$as_me: failed program was:" >&5 | |
1738 | sed 's/^/| /' conftest.$ac_ext >&5 | |
f73dda09 | 1739 | |
ac50fbac CR |
1740 | ac_retval=1 |
1741 | fi | |
1742 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information | |
1743 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
1744 | # interfere with the next link command; also delete a directory that is | |
1745 | # left behind by Apple's compiler. We do this before executing the actions. | |
1746 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1747 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1748 | as_fn_set_status $ac_retval | |
b80f6443 | 1749 | |
ac50fbac | 1750 | } # ac_fn_c_try_link |
b80f6443 | 1751 | |
ac50fbac CR |
1752 | # ac_fn_c_try_cpp LINENO |
1753 | # ---------------------- | |
1754 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
1755 | ac_fn_c_try_cpp () | |
1756 | { | |
1757 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1758 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
1759 | case "(($ac_try" in | |
1760 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1761 | *) ac_try_echo=$ac_try;; | |
1762 | esac | |
1763 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1764 | $as_echo "$ac_try_echo"; } >&5 | |
1765 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
1766 | ac_status=$? | |
1767 | if test -s conftest.err; then | |
1768 | grep -v '^ *+' conftest.err >conftest.er1 | |
1769 | cat conftest.er1 >&5 | |
1770 | mv -f conftest.er1 conftest.err | |
1771 | fi | |
1772 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1773 | test $ac_status = 0; } > conftest.i && { | |
1774 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || | |
1775 | test ! -s conftest.err | |
1776 | }; then : | |
1777 | ac_retval=0 | |
1778 | else | |
1779 | $as_echo "$as_me: failed program was:" >&5 | |
1780 | sed 's/^/| /' conftest.$ac_ext >&5 | |
f73dda09 | 1781 | |
ac50fbac CR |
1782 | ac_retval=1 |
1783 | fi | |
1784 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1785 | as_fn_set_status $ac_retval | |
b80f6443 | 1786 | |
ac50fbac | 1787 | } # ac_fn_c_try_cpp |
b80f6443 | 1788 | |
ac50fbac CR |
1789 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
1790 | # ------------------------------------------------------- | |
1791 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
1792 | # the include files in INCLUDES and setting the cache variable VAR | |
1793 | # accordingly. | |
1794 | ac_fn_c_check_header_mongrel () | |
1795 | { | |
1796 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1797 | if eval \${$3+:} false; then : | |
1798 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1799 | $as_echo_n "checking for $2... " >&6; } | |
1800 | if eval \${$3+:} false; then : | |
1801 | $as_echo_n "(cached) " >&6 | |
1802 | fi | |
1803 | eval ac_res=\$$3 | |
1804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1805 | $as_echo "$ac_res" >&6; } | |
1806 | else | |
1807 | # Is the header compilable? | |
1808 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
1809 | $as_echo_n "checking $2 usability... " >&6; } | |
1810 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1811 | /* end confdefs.h. */ | |
1812 | $4 | |
1813 | #include <$2> | |
1814 | _ACEOF | |
1815 | if ac_fn_c_try_compile "$LINENO"; then : | |
1816 | ac_header_compiler=yes | |
1817 | else | |
1818 | ac_header_compiler=no | |
1819 | fi | |
1820 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1821 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
1822 | $as_echo "$ac_header_compiler" >&6; } | |
b80f6443 | 1823 | |
ac50fbac CR |
1824 | # Is the header present? |
1825 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
1826 | $as_echo_n "checking $2 presence... " >&6; } | |
1827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1828 | /* end confdefs.h. */ | |
1829 | #include <$2> | |
b80f6443 | 1830 | _ACEOF |
ac50fbac CR |
1831 | if ac_fn_c_try_cpp "$LINENO"; then : |
1832 | ac_header_preproc=yes | |
1833 | else | |
1834 | ac_header_preproc=no | |
1835 | fi | |
1836 | rm -f conftest.err conftest.i conftest.$ac_ext | |
1837 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 | |
1838 | $as_echo "$ac_header_preproc" >&6; } | |
f73dda09 | 1839 | |
ac50fbac CR |
1840 | # So? What about this header? |
1841 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
1842 | yes:no: ) | |
1843 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
1844 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
1845 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1846 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1847 | ;; | |
1848 | no:yes:* ) | |
1849 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
1850 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
1851 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
1852 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
1853 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
1854 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
1855 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
1856 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
1857 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1858 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1859 | ( $as_echo "## ------------------------------- ## | |
1860 | ## Report this to bug-bash@gnu.org ## | |
1861 | ## ------------------------------- ##" | |
1862 | ) | sed "s/^/$as_me: WARNING: /" >&2 | |
1863 | ;; | |
1864 | esac | |
1865 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1866 | $as_echo_n "checking for $2... " >&6; } | |
1867 | if eval \${$3+:} false; then : | |
1868 | $as_echo_n "(cached) " >&6 | |
1869 | else | |
1870 | eval "$3=\$ac_header_compiler" | |
1871 | fi | |
1872 | eval ac_res=\$$3 | |
1873 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1874 | $as_echo "$ac_res" >&6; } | |
1875 | fi | |
1876 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
f73dda09 | 1877 | |
ac50fbac | 1878 | } # ac_fn_c_check_header_mongrel |
f73dda09 | 1879 | |
ac50fbac CR |
1880 | # ac_fn_c_try_run LINENO |
1881 | # ---------------------- | |
1882 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
1883 | # that executables *can* be run. | |
1884 | ac_fn_c_try_run () | |
1885 | { | |
1886 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1887 | if { { ac_try="$ac_link" | |
1888 | case "(($ac_try" in | |
1889 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1890 | *) ac_try_echo=$ac_try;; | |
1891 | esac | |
1892 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1893 | $as_echo "$ac_try_echo"; } >&5 | |
1894 | (eval "$ac_link") 2>&5 | |
1895 | ac_status=$? | |
1896 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1897 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
1898 | { { case "(($ac_try" in | |
1899 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1900 | *) ac_try_echo=$ac_try;; | |
1901 | esac | |
1902 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1903 | $as_echo "$ac_try_echo"; } >&5 | |
1904 | (eval "$ac_try") 2>&5 | |
1905 | ac_status=$? | |
1906 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1907 | test $ac_status = 0; }; }; then : | |
1908 | ac_retval=0 | |
1909 | else | |
1910 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
1911 | $as_echo "$as_me: failed program was:" >&5 | |
1912 | sed 's/^/| /' conftest.$ac_ext >&5 | |
0628567a | 1913 | |
ac50fbac CR |
1914 | ac_retval=$ac_status |
1915 | fi | |
1916 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1917 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1918 | as_fn_set_status $ac_retval | |
0628567a | 1919 | |
ac50fbac | 1920 | } # ac_fn_c_try_run |
0628567a | 1921 | |
ac50fbac CR |
1922 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
1923 | # ------------------------------------------------------- | |
1924 | # Tests whether HEADER exists and can be compiled using the include files in | |
1925 | # INCLUDES, setting the cache variable VAR accordingly. | |
1926 | ac_fn_c_check_header_compile () | |
1927 | { | |
1928 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1929 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1930 | $as_echo_n "checking for $2... " >&6; } | |
1931 | if eval \${$3+:} false; then : | |
1932 | $as_echo_n "(cached) " >&6 | |
1933 | else | |
1934 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1935 | /* end confdefs.h. */ | |
1936 | $4 | |
1937 | #include <$2> | |
1938 | _ACEOF | |
1939 | if ac_fn_c_try_compile "$LINENO"; then : | |
1940 | eval "$3=yes" | |
1941 | else | |
1942 | eval "$3=no" | |
1943 | fi | |
1944 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1945 | fi | |
1946 | eval ac_res=\$$3 | |
1947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1948 | $as_echo "$ac_res" >&6; } | |
1949 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
0628567a | 1950 | |
ac50fbac | 1951 | } # ac_fn_c_check_header_compile |
f73dda09 | 1952 | |
ac50fbac CR |
1953 | # ac_fn_c_check_func LINENO FUNC VAR |
1954 | # ---------------------------------- | |
1955 | # Tests whether FUNC exists, setting the cache variable VAR accordingly | |
1956 | ac_fn_c_check_func () | |
1957 | { | |
1958 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1959 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1960 | $as_echo_n "checking for $2... " >&6; } | |
1961 | if eval \${$3+:} false; then : | |
1962 | $as_echo_n "(cached) " >&6 | |
1963 | else | |
1964 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1965 | /* end confdefs.h. */ | |
1966 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. | |
1967 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ | |
1968 | #define $2 innocuous_$2 | |
f73dda09 | 1969 | |
ac50fbac CR |
1970 | /* System header to define __stub macros and hopefully few prototypes, |
1971 | which can conflict with char $2 (); below. | |
1972 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
1973 | <limits.h> exists even on freestanding compilers. */ | |
b80f6443 | 1974 | |
ac50fbac CR |
1975 | #ifdef __STDC__ |
1976 | # include <limits.h> | |
1977 | #else | |
1978 | # include <assert.h> | |
1979 | #endif | |
b80f6443 | 1980 | |
ac50fbac | 1981 | #undef $2 |
b80f6443 | 1982 | |
ac50fbac CR |
1983 | /* Override any GCC internal prototype to avoid an error. |
1984 | Use char because int might match the return type of a GCC | |
1985 | builtin and then its argument prototype would still apply. */ | |
1986 | #ifdef __cplusplus | |
1987 | extern "C" | |
1988 | #endif | |
1989 | char $2 (); | |
1990 | /* The GNU C library defines this for functions which it implements | |
1991 | to always fail with ENOSYS. Some functions are actually named | |
1992 | something starting with __ and the normal name is an alias. */ | |
1993 | #if defined __stub_$2 || defined __stub___$2 | |
1994 | choke me | |
1995 | #endif | |
1996 | ||
1997 | int | |
1998 | main () | |
1999 | { | |
2000 | return $2 (); | |
2001 | ; | |
2002 | return 0; | |
2003 | } | |
b80f6443 | 2004 | _ACEOF |
ac50fbac CR |
2005 | if ac_fn_c_try_link "$LINENO"; then : |
2006 | eval "$3=yes" | |
2007 | else | |
2008 | eval "$3=no" | |
2009 | fi | |
2010 | rm -f core conftest.err conftest.$ac_objext \ | |
2011 | conftest$ac_exeext conftest.$ac_ext | |
2012 | fi | |
2013 | eval ac_res=\$$3 | |
2014 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2015 | $as_echo "$ac_res" >&6; } | |
2016 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
b80f6443 | 2017 | |
ac50fbac | 2018 | } # ac_fn_c_check_func |
b80f6443 | 2019 | |
ac50fbac CR |
2020 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
2021 | # ------------------------------------------- | |
2022 | # Tests whether TYPE exists after having included INCLUDES, setting cache | |
2023 | # variable VAR accordingly. | |
2024 | ac_fn_c_check_type () | |
2025 | { | |
2026 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2027 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2028 | $as_echo_n "checking for $2... " >&6; } | |
2029 | if eval \${$3+:} false; then : | |
2030 | $as_echo_n "(cached) " >&6 | |
2031 | else | |
2032 | eval "$3=no" | |
2033 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2034 | /* end confdefs.h. */ | |
2035 | $4 | |
2036 | int | |
2037 | main () | |
2038 | { | |
2039 | if (sizeof ($2)) | |
2040 | return 0; | |
2041 | ; | |
2042 | return 0; | |
2043 | } | |
b80f6443 | 2044 | _ACEOF |
ac50fbac CR |
2045 | if ac_fn_c_try_compile "$LINENO"; then : |
2046 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2047 | /* end confdefs.h. */ | |
2048 | $4 | |
2049 | int | |
2050 | main () | |
2051 | { | |
2052 | if (sizeof (($2))) | |
2053 | return 0; | |
2054 | ; | |
2055 | return 0; | |
2056 | } | |
b80f6443 | 2057 | _ACEOF |
ac50fbac | 2058 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 2059 | |
3185942a | 2060 | else |
ac50fbac | 2061 | eval "$3=yes" |
3185942a | 2062 | fi |
ac50fbac | 2063 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 2064 | fi |
ac50fbac | 2065 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 2066 | fi |
ac50fbac CR |
2067 | eval ac_res=\$$3 |
2068 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2069 | $as_echo "$ac_res" >&6; } | |
2070 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
f73dda09 | 2071 | |
ac50fbac | 2072 | } # ac_fn_c_check_type |
b80f6443 | 2073 | |
ac50fbac CR |
2074 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
2075 | # --------------------------------------------- | |
2076 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR | |
2077 | # accordingly. | |
2078 | ac_fn_c_check_decl () | |
2079 | { | |
2080 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2081 | as_decl_name=`echo $2|sed 's/ *(.*//'` | |
2082 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` | |
2083 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 | |
2084 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } | |
2085 | if eval \${$3+:} false; then : | |
2086 | $as_echo_n "(cached) " >&6 | |
2087 | else | |
2088 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2089 | /* end confdefs.h. */ | |
2090 | $4 | |
2091 | int | |
2092 | main () | |
2093 | { | |
2094 | #ifndef $as_decl_name | |
2095 | #ifdef __cplusplus | |
2096 | (void) $as_decl_use; | |
2097 | #else | |
2098 | (void) $as_decl_name; | |
2099 | #endif | |
2100 | #endif | |
b80f6443 | 2101 | |
ac50fbac CR |
2102 | ; |
2103 | return 0; | |
2104 | } | |
2105 | _ACEOF | |
2106 | if ac_fn_c_try_compile "$LINENO"; then : | |
2107 | eval "$3=yes" | |
2108 | else | |
2109 | eval "$3=no" | |
2110 | fi | |
2111 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2112 | fi | |
2113 | eval ac_res=\$$3 | |
2114 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2115 | $as_echo "$ac_res" >&6; } | |
2116 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
b80f6443 | 2117 | |
ac50fbac | 2118 | } # ac_fn_c_check_decl |
b80f6443 | 2119 | |
ac50fbac CR |
2120 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
2121 | # -------------------------------------------- | |
2122 | # Tries to find the compile-time value of EXPR in a program that includes | |
2123 | # INCLUDES, setting VAR accordingly. Returns whether the value could be | |
2124 | # computed | |
2125 | ac_fn_c_compute_int () | |
2126 | { | |
2127 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2128 | if test "$cross_compiling" = yes; then | |
2129 | # Depending upon the size, compute the lo and hi bounds. | |
2130 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2131 | /* end confdefs.h. */ | |
2132 | $4 | |
2133 | int | |
2134 | main () | |
2135 | { | |
2136 | static int test_array [1 - 2 * !(($2) >= 0)]; | |
2137 | test_array [0] = 0; | |
2138 | return test_array [0]; | |
b80f6443 | 2139 | |
ac50fbac CR |
2140 | ; |
2141 | return 0; | |
2142 | } | |
2143 | _ACEOF | |
2144 | if ac_fn_c_try_compile "$LINENO"; then : | |
2145 | ac_lo=0 ac_mid=0 | |
2146 | while :; do | |
2147 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2148 | /* end confdefs.h. */ | |
2149 | $4 | |
2150 | int | |
2151 | main () | |
2152 | { | |
2153 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2154 | test_array [0] = 0; | |
2155 | return test_array [0]; | |
b80f6443 | 2156 | |
ac50fbac CR |
2157 | ; |
2158 | return 0; | |
2159 | } | |
2160 | _ACEOF | |
2161 | if ac_fn_c_try_compile "$LINENO"; then : | |
2162 | ac_hi=$ac_mid; break | |
2163 | else | |
2164 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val | |
2165 | if test $ac_lo -le $ac_mid; then | |
2166 | ac_lo= ac_hi= | |
2167 | break | |
2168 | fi | |
2169 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val | |
2170 | fi | |
2171 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2172 | done | |
2173 | else | |
2174 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2175 | /* end confdefs.h. */ | |
2176 | $4 | |
2177 | int | |
2178 | main () | |
2179 | { | |
2180 | static int test_array [1 - 2 * !(($2) < 0)]; | |
2181 | test_array [0] = 0; | |
2182 | return test_array [0]; | |
b80f6443 | 2183 | |
ac50fbac CR |
2184 | ; |
2185 | return 0; | |
2186 | } | |
2187 | _ACEOF | |
2188 | if ac_fn_c_try_compile "$LINENO"; then : | |
2189 | ac_hi=-1 ac_mid=-1 | |
2190 | while :; do | |
2191 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2192 | /* end confdefs.h. */ | |
2193 | $4 | |
2194 | int | |
2195 | main () | |
2196 | { | |
2197 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; | |
2198 | test_array [0] = 0; | |
2199 | return test_array [0]; | |
b80f6443 | 2200 | |
ac50fbac CR |
2201 | ; |
2202 | return 0; | |
2203 | } | |
2204 | _ACEOF | |
2205 | if ac_fn_c_try_compile "$LINENO"; then : | |
2206 | ac_lo=$ac_mid; break | |
2207 | else | |
2208 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val | |
2209 | if test $ac_mid -le $ac_hi; then | |
2210 | ac_lo= ac_hi= | |
2211 | break | |
2212 | fi | |
2213 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val | |
2214 | fi | |
2215 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2216 | done | |
2217 | else | |
2218 | ac_lo= ac_hi= | |
2219 | fi | |
2220 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2221 | fi | |
2222 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2223 | # Binary search between lo and hi bounds. | |
2224 | while test "x$ac_lo" != "x$ac_hi"; do | |
2225 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val | |
2226 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2227 | /* end confdefs.h. */ | |
2228 | $4 | |
2229 | int | |
2230 | main () | |
2231 | { | |
2232 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2233 | test_array [0] = 0; | |
2234 | return test_array [0]; | |
b80f6443 | 2235 | |
ac50fbac CR |
2236 | ; |
2237 | return 0; | |
2238 | } | |
2239 | _ACEOF | |
2240 | if ac_fn_c_try_compile "$LINENO"; then : | |
2241 | ac_hi=$ac_mid | |
2242 | else | |
2243 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val | |
2244 | fi | |
2245 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2246 | done | |
2247 | case $ac_lo in #(( | |
2248 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; | |
2249 | '') ac_retval=1 ;; | |
2250 | esac | |
2251 | else | |
2252 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2253 | /* end confdefs.h. */ | |
2254 | $4 | |
2255 | static long int longval () { return $2; } | |
2256 | static unsigned long int ulongval () { return $2; } | |
2257 | #include <stdio.h> | |
2258 | #include <stdlib.h> | |
2259 | int | |
2260 | main () | |
2261 | { | |
b80f6443 | 2262 | |
ac50fbac CR |
2263 | FILE *f = fopen ("conftest.val", "w"); |
2264 | if (! f) | |
2265 | return 1; | |
2266 | if (($2) < 0) | |
2267 | { | |
2268 | long int i = longval (); | |
2269 | if (i != ($2)) | |
2270 | return 1; | |
2271 | fprintf (f, "%ld", i); | |
2272 | } | |
2273 | else | |
2274 | { | |
2275 | unsigned long int i = ulongval (); | |
2276 | if (i != ($2)) | |
2277 | return 1; | |
2278 | fprintf (f, "%lu", i); | |
2279 | } | |
2280 | /* Do not output a trailing newline, as this causes \r\n confusion | |
2281 | on some platforms. */ | |
2282 | return ferror (f) || fclose (f) != 0; | |
b80f6443 | 2283 | |
ac50fbac CR |
2284 | ; |
2285 | return 0; | |
2286 | } | |
2287 | _ACEOF | |
2288 | if ac_fn_c_try_run "$LINENO"; then : | |
2289 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 | |
2290 | else | |
2291 | ac_retval=1 | |
2292 | fi | |
2293 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
2294 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2295 | rm -f conftest.val | |
b80f6443 | 2296 | |
ac50fbac CR |
2297 | fi |
2298 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
2299 | as_fn_set_status $ac_retval | |
b80f6443 | 2300 | |
ac50fbac | 2301 | } # ac_fn_c_compute_int |
b80f6443 | 2302 | |
ac50fbac CR |
2303 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
2304 | # ---------------------------------------------------- | |
2305 | # Tries to find if the field MEMBER exists in type AGGR, after including | |
2306 | # INCLUDES, setting cache variable VAR accordingly. | |
2307 | ac_fn_c_check_member () | |
2308 | { | |
2309 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2310 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 | |
2311 | $as_echo_n "checking for $2.$3... " >&6; } | |
2312 | if eval \${$4+:} false; then : | |
3185942a JA |
2313 | $as_echo_n "(cached) " >&6 |
2314 | else | |
ac50fbac CR |
2315 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2316 | /* end confdefs.h. */ | |
2317 | $5 | |
2318 | int | |
2319 | main () | |
2320 | { | |
2321 | static $2 ac_aggr; | |
2322 | if (ac_aggr.$3) | |
2323 | return 0; | |
2324 | ; | |
2325 | return 0; | |
2326 | } | |
2327 | _ACEOF | |
2328 | if ac_fn_c_try_compile "$LINENO"; then : | |
2329 | eval "$4=yes" | |
3185942a | 2330 | else |
ac50fbac CR |
2331 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2332 | /* end confdefs.h. */ | |
2333 | $5 | |
2334 | int | |
2335 | main () | |
2336 | { | |
2337 | static $2 ac_aggr; | |
2338 | if (sizeof ac_aggr.$3) | |
2339 | return 0; | |
2340 | ; | |
2341 | return 0; | |
2342 | } | |
2343 | _ACEOF | |
2344 | if ac_fn_c_try_compile "$LINENO"; then : | |
2345 | eval "$4=yes" | |
3185942a | 2346 | else |
ac50fbac | 2347 | eval "$4=no" |
3185942a | 2348 | fi |
ac50fbac | 2349 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3185942a | 2350 | fi |
ac50fbac | 2351 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3185942a | 2352 | fi |
ac50fbac CR |
2353 | eval ac_res=\$$4 |
2354 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2355 | $as_echo "$ac_res" >&6; } | |
2356 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
d166f048 | 2357 | |
ac50fbac CR |
2358 | } # ac_fn_c_check_member |
2359 | cat >config.log <<_ACEOF | |
2360 | This file contains any messages produced by compilers while | |
2361 | running configure, to aid debugging if configure makes a mistake. | |
3185942a | 2362 | |
a0c0a00f | 2363 | It was created by bash $as_me 4.4-release, which was |
ac50fbac | 2364 | generated by GNU Autoconf 2.69. Invocation command line was |
3185942a | 2365 | |
ac50fbac | 2366 | $ $0 $@ |
d166f048 | 2367 | |
ac50fbac CR |
2368 | _ACEOF |
2369 | exec 5>>config.log | |
2370 | { | |
2371 | cat <<_ASUNAME | |
2372 | ## --------- ## | |
2373 | ## Platform. ## | |
2374 | ## --------- ## | |
3185942a | 2375 | |
ac50fbac CR |
2376 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
2377 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
2378 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
2379 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
2380 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
3185942a | 2381 | |
ac50fbac CR |
2382 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
2383 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
ccc6cda3 | 2384 | |
ac50fbac CR |
2385 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
2386 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
2387 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
2388 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
2389 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
2390 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
2391 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
f73dda09 | 2392 | |
ac50fbac | 2393 | _ASUNAME |
f73dda09 | 2394 | |
ac50fbac CR |
2395 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2396 | for as_dir in $PATH | |
2397 | do | |
2398 | IFS=$as_save_IFS | |
2399 | test -z "$as_dir" && as_dir=. | |
2400 | $as_echo "PATH: $as_dir" | |
2401 | done | |
2402 | IFS=$as_save_IFS | |
bb70624e | 2403 | |
ac50fbac | 2404 | } >&5 |
ccc6cda3 | 2405 | |
ac50fbac | 2406 | cat >&5 <<_ACEOF |
7117c2d2 | 2407 | |
ccc6cda3 | 2408 | |
ac50fbac CR |
2409 | ## ----------- ## |
2410 | ## Core tests. ## | |
2411 | ## ----------- ## | |
d166f048 | 2412 | |
b80f6443 | 2413 | _ACEOF |
ccc6cda3 | 2414 | |
d166f048 | 2415 | |
ac50fbac CR |
2416 | # Keep a trace of the command line. |
2417 | # Strip out --no-create and --no-recursion so they do not pile up. | |
2418 | # Strip out --silent because we don't want to record it for future runs. | |
2419 | # Also quote any args containing shell meta-characters. | |
2420 | # Make two passes to allow for proper duplicate-argument suppression. | |
2421 | ac_configure_args= | |
2422 | ac_configure_args0= | |
2423 | ac_configure_args1= | |
2424 | ac_must_keep_next=false | |
2425 | for ac_pass in 1 2 | |
2426 | do | |
2427 | for ac_arg | |
2428 | do | |
2429 | case $ac_arg in | |
2430 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
2431 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
2432 | | -silent | --silent | --silen | --sile | --sil) | |
2433 | continue ;; | |
2434 | *\'*) | |
2435 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2436 | esac | |
2437 | case $ac_pass in | |
2438 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
2439 | 2) | |
2440 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
2441 | if test $ac_must_keep_next = true; then | |
2442 | ac_must_keep_next=false # Got value, back to normal. | |
2443 | else | |
2444 | case $ac_arg in | |
2445 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
2446 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
2447 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
2448 | | -with-* | --with-* | -without-* | --without-* | --x) | |
2449 | case "$ac_configure_args0 " in | |
2450 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
2451 | esac | |
2452 | ;; | |
2453 | -* ) ac_must_keep_next=true ;; | |
2454 | esac | |
2455 | fi | |
2456 | as_fn_append ac_configure_args " '$ac_arg'" | |
2457 | ;; | |
2458 | esac | |
2459 | done | |
2460 | done | |
2461 | { ac_configure_args0=; unset ac_configure_args0;} | |
2462 | { ac_configure_args1=; unset ac_configure_args1;} | |
b80f6443 | 2463 | |
ac50fbac CR |
2464 | # When interrupted or exit'd, cleanup temporary files, and complete |
2465 | # config.log. We remove comments because anyway the quotes in there | |
2466 | # would cause problems or look ugly. | |
2467 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
2468 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
2469 | trap 'exit_status=$? | |
2470 | # Save into config.log some information that might help in debugging. | |
2471 | { | |
2472 | echo | |
ccc6cda3 | 2473 | |
ac50fbac CR |
2474 | $as_echo "## ---------------- ## |
2475 | ## Cache variables. ## | |
2476 | ## ---------------- ##" | |
2477 | echo | |
2478 | # The following way of writing the cache mishandles newlines in values, | |
2479 | ( | |
2480 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
2481 | eval ac_val=\$$ac_var | |
2482 | case $ac_val in #( | |
2483 | *${as_nl}*) | |
2484 | case $ac_var in #( | |
2485 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
2486 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
2487 | esac | |
2488 | case $ac_var in #( | |
2489 | _ | IFS | as_nl) ;; #( | |
2490 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
2491 | *) { eval $ac_var=; unset $ac_var;} ;; | |
2492 | esac ;; | |
2493 | esac | |
2494 | done | |
2495 | (set) 2>&1 | | |
2496 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
2497 | *${as_nl}ac_space=\ *) | |
2498 | sed -n \ | |
2499 | "s/'\''/'\''\\\\'\'''\''/g; | |
2500 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
2501 | ;; #( | |
2502 | *) | |
2503 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
2504 | ;; | |
2505 | esac | | |
2506 | sort | |
2507 | ) | |
2508 | echo | |
cce855bc | 2509 | |
ac50fbac CR |
2510 | $as_echo "## ----------------- ## |
2511 | ## Output variables. ## | |
2512 | ## ----------------- ##" | |
2513 | echo | |
2514 | for ac_var in $ac_subst_vars | |
2515 | do | |
2516 | eval ac_val=\$$ac_var | |
2517 | case $ac_val in | |
2518 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2519 | esac | |
2520 | $as_echo "$ac_var='\''$ac_val'\''" | |
2521 | done | sort | |
2522 | echo | |
ccc6cda3 | 2523 | |
ac50fbac CR |
2524 | if test -n "$ac_subst_files"; then |
2525 | $as_echo "## ------------------- ## | |
2526 | ## File substitutions. ## | |
2527 | ## ------------------- ##" | |
2528 | echo | |
2529 | for ac_var in $ac_subst_files | |
2530 | do | |
2531 | eval ac_val=\$$ac_var | |
2532 | case $ac_val in | |
2533 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2534 | esac | |
2535 | $as_echo "$ac_var='\''$ac_val'\''" | |
2536 | done | sort | |
2537 | echo | |
2538 | fi | |
3185942a | 2539 | |
ac50fbac CR |
2540 | if test -s confdefs.h; then |
2541 | $as_echo "## ----------- ## | |
2542 | ## confdefs.h. ## | |
2543 | ## ----------- ##" | |
2544 | echo | |
2545 | cat confdefs.h | |
2546 | echo | |
2547 | fi | |
2548 | test "$ac_signal" != 0 && | |
2549 | $as_echo "$as_me: caught signal $ac_signal" | |
2550 | $as_echo "$as_me: exit $exit_status" | |
2551 | } >&5 | |
2552 | rm -f core *.core core.conftest.* && | |
2553 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
2554 | exit $exit_status | |
2555 | ' 0 | |
2556 | for ac_signal in 1 2 13 15; do | |
2557 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
2558 | done | |
2559 | ac_signal=0 | |
ccc6cda3 | 2560 | |
ac50fbac CR |
2561 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
2562 | rm -f -r conftest* confdefs.h | |
ccc6cda3 | 2563 | |
ac50fbac | 2564 | $as_echo "/* confdefs.h */" > confdefs.h |
3185942a | 2565 | |
ac50fbac | 2566 | # Predefined preprocessor variables. |
3185942a | 2567 | |
ac50fbac CR |
2568 | cat >>confdefs.h <<_ACEOF |
2569 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
2570 | _ACEOF | |
3185942a | 2571 | |
ac50fbac CR |
2572 | cat >>confdefs.h <<_ACEOF |
2573 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2574 | _ACEOF | |
3185942a | 2575 | |
ac50fbac CR |
2576 | cat >>confdefs.h <<_ACEOF |
2577 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
2578 | _ACEOF | |
3185942a | 2579 | |
ac50fbac CR |
2580 | cat >>confdefs.h <<_ACEOF |
2581 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
2582 | _ACEOF | |
3185942a | 2583 | |
ac50fbac CR |
2584 | cat >>confdefs.h <<_ACEOF |
2585 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2586 | _ACEOF | |
3185942a | 2587 | |
ac50fbac CR |
2588 | cat >>confdefs.h <<_ACEOF |
2589 | #define PACKAGE_URL "$PACKAGE_URL" | |
2590 | _ACEOF | |
3185942a | 2591 | |
3185942a | 2592 | |
ac50fbac CR |
2593 | # Let the site file select an alternate cache file if it wants to. |
2594 | # Prefer an explicitly selected file to automatically selected ones. | |
2595 | ac_site_file1=NONE | |
2596 | ac_site_file2=NONE | |
2597 | if test -n "$CONFIG_SITE"; then | |
2598 | # We do not want a PATH search for config.site. | |
2599 | case $CONFIG_SITE in #(( | |
2600 | -*) ac_site_file1=./$CONFIG_SITE;; | |
2601 | */*) ac_site_file1=$CONFIG_SITE;; | |
2602 | *) ac_site_file1=./$CONFIG_SITE;; | |
2603 | esac | |
2604 | elif test "x$prefix" != xNONE; then | |
2605 | ac_site_file1=$prefix/share/config.site | |
2606 | ac_site_file2=$prefix/etc/config.site | |
2607 | else | |
2608 | ac_site_file1=$ac_default_prefix/share/config.site | |
2609 | ac_site_file2=$ac_default_prefix/etc/config.site | |
3185942a | 2610 | fi |
ac50fbac CR |
2611 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
2612 | do | |
2613 | test "x$ac_site_file" = xNONE && continue | |
2614 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then | |
2615 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 | |
2616 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2617 | sed 's/^/| /' "$ac_site_file" >&5 | |
2618 | . "$ac_site_file" \ | |
2619 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2620 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2621 | as_fn_error $? "failed to load site script $ac_site_file | |
2622 | See \`config.log' for more details" "$LINENO" 5; } | |
2623 | fi | |
2624 | done | |
3185942a | 2625 | |
ac50fbac CR |
2626 | if test -r "$cache_file"; then |
2627 | # Some versions of bash will fail to source /dev/null (special files | |
2628 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. | |
2629 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then | |
2630 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 | |
2631 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2632 | case $cache_file in | |
2633 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2634 | *) . "./$cache_file";; | |
2635 | esac | |
2636 | fi | |
2637 | else | |
2638 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 | |
2639 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2640 | >$cache_file | |
3185942a JA |
2641 | fi |
2642 | ||
ac50fbac CR |
2643 | as_fn_append ac_header_list " stdlib.h" |
2644 | as_fn_append ac_header_list " unistd.h" | |
2645 | as_fn_append ac_header_list " sys/param.h" | |
2646 | as_fn_append ac_header_list " sys/time.h" | |
2647 | as_fn_append ac_func_list " alarm" | |
2648 | as_fn_append ac_func_list " fpurge" | |
2649 | as_fn_append ac_func_list " __fpurge" | |
2650 | as_fn_append ac_func_list " snprintf" | |
2651 | as_fn_append ac_func_list " vsnprintf" | |
2652 | # Check that the precious variables saved in the cache have kept the same | |
2653 | # value. | |
2654 | ac_cache_corrupted=false | |
2655 | for ac_var in $ac_precious_vars; do | |
2656 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2657 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2658 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2659 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2660 | case $ac_old_set,$ac_new_set in | |
2661 | set,) | |
2662 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2663 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2664 | ac_cache_corrupted=: ;; | |
2665 | ,set) | |
2666 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2667 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2668 | ac_cache_corrupted=: ;; | |
2669 | ,);; | |
2670 | *) | |
2671 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2672 | # differences in whitespace do not lead to failure. | |
2673 | ac_old_val_w=`echo x $ac_old_val` | |
2674 | ac_new_val_w=`echo x $ac_new_val` | |
2675 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2676 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2677 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2678 | ac_cache_corrupted=: | |
2679 | else | |
2680 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2681 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2682 | eval $ac_var=\$ac_old_val | |
2683 | fi | |
2684 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2685 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
2686 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
2687 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
2688 | fi;; | |
2689 | esac | |
2690 | # Pass precious variables to config.status. | |
2691 | if test "$ac_new_set" = set; then | |
2692 | case $ac_new_val in | |
2693 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2694 | *) ac_arg=$ac_var=$ac_new_val ;; | |
2695 | esac | |
2696 | case " $ac_configure_args " in | |
2697 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
2698 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
2699 | esac | |
2700 | fi | |
2701 | done | |
2702 | if $ac_cache_corrupted; then | |
2703 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2704 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2705 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
2706 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
2707 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 | |
3185942a | 2708 | fi |
ac50fbac CR |
2709 | ## -------------------- ## |
2710 | ## Main body of script. ## | |
2711 | ## -------------------- ## | |
3185942a | 2712 | |
ac50fbac CR |
2713 | ac_ext=c |
2714 | ac_cpp='$CPP $CPPFLAGS' | |
2715 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2716 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2717 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3185942a | 2718 | |
3185942a | 2719 | |
3185942a | 2720 | |
0001803f | 2721 | |
3185942a | 2722 | |
3185942a | 2723 | |
ac50fbac CR |
2724 | ac_aux_dir= |
2725 | for ac_dir in ./support "$srcdir"/./support; do | |
2726 | if test -f "$ac_dir/install-sh"; then | |
2727 | ac_aux_dir=$ac_dir | |
2728 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
2729 | break | |
2730 | elif test -f "$ac_dir/install.sh"; then | |
2731 | ac_aux_dir=$ac_dir | |
2732 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
2733 | break | |
2734 | elif test -f "$ac_dir/shtool"; then | |
2735 | ac_aux_dir=$ac_dir | |
2736 | ac_install_sh="$ac_aux_dir/shtool install -c" | |
2737 | break | |
2738 | fi | |
2739 | done | |
2740 | if test -z "$ac_aux_dir"; then | |
2741 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in ./support \"$srcdir\"/./support" "$LINENO" 5 | |
3185942a JA |
2742 | fi |
2743 | ||
ac50fbac CR |
2744 | # These three variables are undocumented and unsupported, |
2745 | # and are intended to be withdrawn in a future Autoconf release. | |
2746 | # They can cause serious problems if a builder's source tree is in a directory | |
2747 | # whose full name contains unusual characters. | |
2748 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
2749 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
2750 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
3185942a | 2751 | |
3185942a | 2752 | |
ac50fbac | 2753 | ac_config_headers="$ac_config_headers config.h" |
3185942a | 2754 | |
3185942a | 2755 | |
a0c0a00f | 2756 | BASHVERS=4.4 |
ac50fbac | 2757 | RELSTATUS=release |
3185942a | 2758 | |
ac50fbac | 2759 | case "$RELSTATUS" in |
a0c0a00f | 2760 | alp*|bet*|dev*|rc*|releng*|maint*) DEBUG='-DDEBUG' MALLOC_DEBUG='-DMALLOC_DEBUG' ;; |
ac50fbac CR |
2761 | *) DEBUG= MALLOC_DEBUG= ;; |
2762 | esac | |
3185942a | 2763 | |
ac50fbac CR |
2764 | # Make sure we can run config.sub. |
2765 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || | |
2766 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 | |
3185942a | 2767 | |
ac50fbac CR |
2768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 |
2769 | $as_echo_n "checking build system type... " >&6; } | |
2770 | if ${ac_cv_build+:} false; then : | |
2771 | $as_echo_n "(cached) " >&6 | |
2772 | else | |
2773 | ac_build_alias=$build_alias | |
2774 | test "x$ac_build_alias" = x && | |
2775 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
2776 | test "x$ac_build_alias" = x && | |
2777 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 | |
2778 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || | |
2779 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 | |
3185942a | 2780 | |
3185942a | 2781 | fi |
ac50fbac CR |
2782 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 |
2783 | $as_echo "$ac_cv_build" >&6; } | |
2784 | case $ac_cv_build in | |
2785 | *-*-*) ;; | |
2786 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; | |
2787 | esac | |
2788 | build=$ac_cv_build | |
2789 | ac_save_IFS=$IFS; IFS='-' | |
2790 | set x $ac_cv_build | |
2791 | shift | |
2792 | build_cpu=$1 | |
2793 | build_vendor=$2 | |
2794 | shift; shift | |
2795 | # Remember, the first character of IFS is used to create $*, | |
2796 | # except with old shells: | |
2797 | build_os=$* | |
2798 | IFS=$ac_save_IFS | |
2799 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
3185942a | 2800 | |
3185942a | 2801 | |
ac50fbac CR |
2802 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 |
2803 | $as_echo_n "checking host system type... " >&6; } | |
2804 | if ${ac_cv_host+:} false; then : | |
2805 | $as_echo_n "(cached) " >&6 | |
2806 | else | |
2807 | if test "x$host_alias" = x; then | |
2808 | ac_cv_host=$ac_cv_build | |
2809 | else | |
2810 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
2811 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 | |
3185942a JA |
2812 | fi |
2813 | ||
3185942a | 2814 | fi |
ac50fbac CR |
2815 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
2816 | $as_echo "$ac_cv_host" >&6; } | |
2817 | case $ac_cv_host in | |
2818 | *-*-*) ;; | |
2819 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; | |
2820 | esac | |
2821 | host=$ac_cv_host | |
2822 | ac_save_IFS=$IFS; IFS='-' | |
2823 | set x $ac_cv_host | |
2824 | shift | |
2825 | host_cpu=$1 | |
2826 | host_vendor=$2 | |
2827 | shift; shift | |
2828 | # Remember, the first character of IFS is used to create $*, | |
2829 | # except with old shells: | |
2830 | host_os=$* | |
2831 | IFS=$ac_save_IFS | |
2832 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
3185942a | 2833 | |
ccc6cda3 | 2834 | |
3185942a | 2835 | |
3185942a | 2836 | |
ac50fbac | 2837 | opt_bash_malloc=yes |
ac50fbac CR |
2838 | opt_afs=no |
2839 | opt_curses=no | |
2840 | opt_with_installed_readline=no | |
3185942a | 2841 | |
ac50fbac | 2842 | #htmldir= |
3185942a | 2843 | |
ac50fbac CR |
2844 | case "${host_cpu}-${host_os}" in |
2845 | alpha*-*) opt_bash_malloc=no ;; # alpha running osf/1 or linux | |
2846 | *[Cc]ray*-*) opt_bash_malloc=no ;; # Crays | |
2847 | *-osf1*) opt_bash_malloc=no ;; # other osf/1 machines | |
2848 | sparc-svr4*) opt_bash_malloc=no ;; # sparc SVR4, SVR4.2 | |
2849 | sparc-netbsd*) opt_bash_malloc=no ;; # needs 8-byte alignment | |
2850 | mips-irix6*) opt_bash_malloc=no ;; # needs 8-byte alignment | |
2851 | m68k-sysv) opt_bash_malloc=no ;; # fixes file descriptor leak in closedir | |
2852 | sparc-linux*) opt_bash_malloc=no ;; # sparc running linux; requires ELF | |
2853 | #*-freebsd*-gnu) opt_bash_malloc=no ;; # there's some undetermined problem here | |
2854 | #*-freebsd*) opt_bash_malloc=no ;; # they claim it's better; I disagree | |
2855 | *-openbsd*) opt_bash_malloc=no ;; # they claim it needs eight-bit alignment | |
2856 | *-mirbsd*) opt_bash_malloc=no ;; # they claim it needs eight-bit alignment | |
2857 | *-aix*) opt_bash_malloc=no ;; # AIX machines | |
2858 | *-nextstep*) opt_bash_malloc=no ;; # NeXT machines running NeXTstep | |
2859 | *-openstep*) opt_bash_malloc=no ;; # i386/Sparc/HP machines running Openstep | |
2860 | *-macos*) opt_bash_malloc=no ;; # Apple MacOS X | |
2861 | *-rhapsody*) opt_bash_malloc=no ;; # Apple Rhapsody (MacOS X) | |
2862 | *-darwin*) opt_bash_malloc=no ;; # Apple Darwin (MacOS X) | |
2863 | *-dgux*) opt_bash_malloc=no ;; # DG/UX machines | |
2864 | *-qnx*) opt_bash_malloc=no ;; # QNX 4.2, QNX 6.x | |
2865 | *-machten4) opt_bash_malloc=no ;; # MachTen 4.x | |
2866 | *-bsdi2.1|*-bsdi3.?) opt_bash_malloc=no ; : ${CC:=shlicc2} ;; # for loadable builtins | |
2867 | *-beos*) opt_bash_malloc=no ;; # they say it's suitable | |
2868 | *-cygwin*) opt_bash_malloc=no ;; # Cygnus's CYGWIN environment | |
2869 | *-opennt*|*-interix*) opt_bash_malloc=no ;; # Interix, now owned by Microsoft | |
2870 | *-nsk*) opt_bash_malloc=no ;; # HP NonStop | |
2871 | *-haiku*) opt_bash_malloc=no ;; # Haiku OS | |
2872 | esac | |
b72432fd | 2873 | |
ac50fbac CR |
2874 | # memory scrambling on free() |
2875 | case "${host_os}" in | |
2876 | sco3.2v5*|sco3.2v4*) opt_memscramble=no ;; | |
2877 | *) opt_memscramble=yes ;; | |
2878 | esac | |
b80f6443 JA |
2879 | |
2880 | ||
ccc6cda3 | 2881 | |
ccc6cda3 | 2882 | |
ac50fbac CR |
2883 | # Check whether --with-afs was given. |
2884 | if test "${with_afs+set}" = set; then : | |
2885 | withval=$with_afs; opt_afs=$withval | |
ccc6cda3 | 2886 | fi |
ccc6cda3 | 2887 | |
ccc6cda3 | 2888 | |
ac50fbac CR |
2889 | # Check whether --with-bash-malloc was given. |
2890 | if test "${with_bash_malloc+set}" = set; then : | |
2891 | withval=$with_bash_malloc; opt_bash_malloc=$withval | |
ccc6cda3 | 2892 | fi |
ccc6cda3 | 2893 | |
ccc6cda3 | 2894 | |
ac50fbac CR |
2895 | # Check whether --with-curses was given. |
2896 | if test "${with_curses+set}" = set; then : | |
2897 | withval=$with_curses; opt_curses=$withval | |
ccc6cda3 | 2898 | fi |
ccc6cda3 | 2899 | |
ac50fbac CR |
2900 | |
2901 | # Check whether --with-gnu-malloc was given. | |
2902 | if test "${with_gnu_malloc+set}" = set; then : | |
2903 | withval=$with_gnu_malloc; opt_bash_malloc=$withval | |
ccc6cda3 | 2904 | fi |
ccc6cda3 | 2905 | |
ac50fbac CR |
2906 | |
2907 | # Check whether --with-installed-readline was given. | |
2908 | if test "${with_installed_readline+set}" = set; then : | |
2909 | withval=$with_installed_readline; opt_with_installed_readline=$withval | |
ccc6cda3 | 2910 | fi |
ccc6cda3 | 2911 | |
ac50fbac | 2912 | |
ac50fbac CR |
2913 | if test "$opt_bash_malloc" = yes; then |
2914 | MALLOC_TARGET=malloc | |
2915 | MALLOC_SRC=malloc.c | |
2916 | ||
2917 | MALLOC_LIB='-lmalloc' | |
2918 | MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a' | |
2919 | MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)' | |
2920 | MALLOC_DEP='$(MALLOC_LIBRARY)' | |
2921 | ||
2922 | $as_echo "#define USING_BASH_MALLOC 1" >>confdefs.h | |
2923 | ||
2924 | else | |
2925 | MALLOC_LIB= | |
2926 | MALLOC_LIBRARY= | |
2927 | MALLOC_LDFLAGS= | |
2928 | MALLOC_DEP= | |
ccc6cda3 | 2929 | fi |
ccc6cda3 | 2930 | |
ac50fbac CR |
2931 | if test "$opt_afs" = yes; then |
2932 | $as_echo "#define AFS 1" >>confdefs.h | |
95732b49 | 2933 | |
cce855bc | 2934 | fi |
cce855bc | 2935 | |
ac50fbac CR |
2936 | if test "$opt_curses" = yes; then |
2937 | prefer_curses=yes | |
0001803f | 2938 | fi |
0001803f | 2939 | |
ac50fbac CR |
2940 | if test -z "${DEBUGGER_START_FILE}"; then |
2941 | DEBUGGER_START_FILE='${datadir}/bashdb/bashdb-main.inc' | |
2942 | fi | |
0001803f | 2943 | |
ac50fbac CR |
2944 | opt_minimal_config=no |
2945 | ||
2946 | opt_job_control=yes | |
2947 | opt_alias=yes | |
2948 | opt_readline=yes | |
2949 | opt_history=yes | |
2950 | opt_bang_history=yes | |
2951 | opt_dirstack=yes | |
2952 | opt_restricted=yes | |
2953 | opt_process_subst=yes | |
2954 | opt_prompt_decoding=yes | |
2955 | opt_select=yes | |
2956 | opt_help=yes | |
2957 | opt_array_variables=yes | |
2958 | opt_dparen_arith=yes | |
2959 | opt_extended_glob=yes | |
2960 | opt_brace_expansion=yes | |
2961 | opt_disabled_builtins=no | |
2962 | opt_command_timing=yes | |
2963 | opt_xpg_echo=no | |
2964 | opt_strict_posix=no | |
2965 | opt_cond_command=yes | |
2966 | opt_cond_regexp=yes | |
2967 | opt_coproc=yes | |
2968 | opt_arith_for_command=yes | |
2969 | opt_net_redirs=yes | |
2970 | opt_progcomp=yes | |
2971 | opt_separate_help=no | |
2972 | opt_multibyte=yes | |
2973 | opt_debugger=yes | |
2974 | opt_single_longdoc_strings=yes | |
2975 | opt_casemod_attrs=yes | |
2976 | opt_casemod_expansions=yes | |
2977 | opt_extglob_default=no | |
2978 | opt_dircomplete_expand_default=no | |
2979 | opt_globascii_default=no | |
a0c0a00f | 2980 | opt_function_import=yes |
ac50fbac CR |
2981 | |
2982 | opt_static_link=no | |
2983 | opt_profiling=no | |
2984 | ||
2985 | # Check whether --enable-minimal-config was given. | |
2986 | if test "${enable_minimal_config+set}" = set; then : | |
2987 | enableval=$enable_minimal_config; opt_minimal_config=$enableval | |
cce855bc | 2988 | fi |
b80f6443 | 2989 | |
ac50fbac CR |
2990 | |
2991 | if test $opt_minimal_config = yes; then | |
2992 | opt_job_control=no opt_alias=no opt_readline=no | |
2993 | opt_history=no opt_bang_history=no opt_dirstack=no | |
2994 | opt_restricted=no opt_process_subst=no opt_prompt_decoding=no | |
2995 | opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no | |
2996 | opt_brace_expansion=no opt_disabled_builtins=no opt_command_timing=no | |
2997 | opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no | |
2998 | opt_net_redirs=no opt_progcomp=no opt_separate_help=no | |
2999 | opt_multibyte=yes opt_cond_regexp=no opt_coproc=no | |
3000 | opt_casemod_attrs=no opt_casemod_expansions=no opt_extglob_default=no | |
3001 | opt_globascii_default=no | |
b80f6443 | 3002 | fi |
cce855bc | 3003 | |
ac50fbac CR |
3004 | # Check whether --enable-alias was given. |
3005 | if test "${enable_alias+set}" = set; then : | |
3006 | enableval=$enable_alias; opt_alias=$enableval | |
3185942a | 3007 | fi |
3185942a | 3008 | |
ac50fbac CR |
3009 | # Check whether --enable-arith-for-command was given. |
3010 | if test "${enable_arith_for_command+set}" = set; then : | |
3011 | enableval=$enable_arith_for_command; opt_arith_for_command=$enableval | |
bb70624e | 3012 | fi |
bb70624e | 3013 | |
ac50fbac CR |
3014 | # Check whether --enable-array-variables was given. |
3015 | if test "${enable_array_variables+set}" = set; then : | |
3016 | enableval=$enable_array_variables; opt_array_variables=$enableval | |
bb70624e | 3017 | fi |
bb70624e | 3018 | |
ac50fbac CR |
3019 | # Check whether --enable-bang-history was given. |
3020 | if test "${enable_bang_history+set}" = set; then : | |
3021 | enableval=$enable_bang_history; opt_bang_history=$enableval | |
bb70624e | 3022 | fi |
b80f6443 | 3023 | |
ac50fbac CR |
3024 | # Check whether --enable-brace-expansion was given. |
3025 | if test "${enable_brace_expansion+set}" = set; then : | |
3026 | enableval=$enable_brace_expansion; opt_brace_expansion=$enableval | |
b80f6443 | 3027 | fi |
b80f6443 | 3028 | |
ac50fbac CR |
3029 | # Check whether --enable-casemod-attributes was given. |
3030 | if test "${enable_casemod_attributes+set}" = set; then : | |
3031 | enableval=$enable_casemod_attributes; opt_casemod_attrs=$enableval | |
b80f6443 | 3032 | fi |
bb70624e | 3033 | |
ac50fbac CR |
3034 | # Check whether --enable-casemod-expansions was given. |
3035 | if test "${enable_casemod_expansions+set}" = set; then : | |
3036 | enableval=$enable_casemod_expansions; opt_casemod_expansions=$enableval | |
3185942a | 3037 | fi |
3185942a | 3038 | |
ac50fbac CR |
3039 | # Check whether --enable-command-timing was given. |
3040 | if test "${enable_command_timing+set}" = set; then : | |
3041 | enableval=$enable_command_timing; opt_command_timing=$enableval | |
3185942a | 3042 | fi |
3185942a | 3043 | |
ac50fbac CR |
3044 | # Check whether --enable-cond-command was given. |
3045 | if test "${enable_cond_command+set}" = set; then : | |
3046 | enableval=$enable_cond_command; opt_cond_command=$enableval | |
ccc6cda3 JA |
3047 | fi |
3048 | ||
ac50fbac CR |
3049 | # Check whether --enable-cond-regexp was given. |
3050 | if test "${enable_cond_regexp+set}" = set; then : | |
3051 | enableval=$enable_cond_regexp; opt_cond_regexp=$enableval | |
3052 | fi | |
7117c2d2 | 3053 | |
ac50fbac CR |
3054 | # Check whether --enable-coprocesses was given. |
3055 | if test "${enable_coprocesses+set}" = set; then : | |
3056 | enableval=$enable_coprocesses; opt_coproc=$enableval | |
7117c2d2 JA |
3057 | fi |
3058 | ||
ac50fbac CR |
3059 | # Check whether --enable-debugger was given. |
3060 | if test "${enable_debugger+set}" = set; then : | |
3061 | enableval=$enable_debugger; opt_debugger=$enableval | |
d166f048 JA |
3062 | fi |
3063 | ||
ac50fbac CR |
3064 | # Check whether --enable-direxpand-default was given. |
3065 | if test "${enable_direxpand_default+set}" = set; then : | |
3066 | enableval=$enable_direxpand_default; opt_dircomplete_expand_default=$enableval | |
7117c2d2 | 3067 | fi |
ac50fbac CR |
3068 | |
3069 | # Check whether --enable-directory-stack was given. | |
3070 | if test "${enable_directory_stack+set}" = set; then : | |
3071 | enableval=$enable_directory_stack; opt_dirstack=$enableval | |
95732b49 JA |
3072 | fi |
3073 | ||
ac50fbac CR |
3074 | # Check whether --enable-disabled-builtins was given. |
3075 | if test "${enable_disabled_builtins+set}" = set; then : | |
3076 | enableval=$enable_disabled_builtins; opt_disabled_builtins=$enableval | |
3077 | fi | |
7117c2d2 | 3078 | |
ac50fbac CR |
3079 | # Check whether --enable-dparen-arithmetic was given. |
3080 | if test "${enable_dparen_arithmetic+set}" = set; then : | |
3081 | enableval=$enable_dparen_arithmetic; opt_dparen_arith=$enableval | |
3082 | fi | |
b80f6443 | 3083 | |
ac50fbac CR |
3084 | # Check whether --enable-extended-glob was given. |
3085 | if test "${enable_extended_glob+set}" = set; then : | |
3086 | enableval=$enable_extended_glob; opt_extended_glob=$enableval | |
3087 | fi | |
b80f6443 | 3088 | |
ac50fbac CR |
3089 | # Check whether --enable-extended-glob-default was given. |
3090 | if test "${enable_extended_glob_default+set}" = set; then : | |
3091 | enableval=$enable_extended_glob_default; opt_extglob_default=$enableval | |
3092 | fi | |
b80f6443 | 3093 | |
a0c0a00f CR |
3094 | # Check whether --enable-function-import was given. |
3095 | if test "${enable_function_import+set}" = set; then : | |
3096 | enableval=$enable_function_import; opt_function_import=$enableval | |
3097 | fi | |
3098 | ||
ac50fbac CR |
3099 | # Check whether --enable-glob-asciiranges-default was given. |
3100 | if test "${enable_glob_asciiranges_default+set}" = set; then : | |
3101 | enableval=$enable_glob_asciiranges_default; opt_globascii_default=$enableval | |
3102 | fi | |
b80f6443 | 3103 | |
ac50fbac CR |
3104 | # Check whether --enable-help-builtin was given. |
3105 | if test "${enable_help_builtin+set}" = set; then : | |
3106 | enableval=$enable_help_builtin; opt_help=$enableval | |
3107 | fi | |
b80f6443 | 3108 | |
ac50fbac CR |
3109 | # Check whether --enable-history was given. |
3110 | if test "${enable_history+set}" = set; then : | |
3111 | enableval=$enable_history; opt_history=$enableval | |
3112 | fi | |
b80f6443 | 3113 | |
ac50fbac CR |
3114 | # Check whether --enable-job-control was given. |
3115 | if test "${enable_job_control+set}" = set; then : | |
3116 | enableval=$enable_job_control; opt_job_control=$enableval | |
3117 | fi | |
b80f6443 | 3118 | |
ac50fbac CR |
3119 | # Check whether --enable-multibyte was given. |
3120 | if test "${enable_multibyte+set}" = set; then : | |
3121 | enableval=$enable_multibyte; opt_multibyte=$enableval | |
3122 | fi | |
b80f6443 | 3123 | |
ac50fbac CR |
3124 | # Check whether --enable-net-redirections was given. |
3125 | if test "${enable_net_redirections+set}" = set; then : | |
3126 | enableval=$enable_net_redirections; opt_net_redirs=$enableval | |
3127 | fi | |
b80f6443 | 3128 | |
ac50fbac CR |
3129 | # Check whether --enable-process-substitution was given. |
3130 | if test "${enable_process_substitution+set}" = set; then : | |
3131 | enableval=$enable_process_substitution; opt_process_subst=$enableval | |
3132 | fi | |
b80f6443 | 3133 | |
ac50fbac CR |
3134 | # Check whether --enable-progcomp was given. |
3135 | if test "${enable_progcomp+set}" = set; then : | |
3136 | enableval=$enable_progcomp; opt_progcomp=$enableval | |
3137 | fi | |
b80f6443 | 3138 | |
ac50fbac CR |
3139 | # Check whether --enable-prompt-string-decoding was given. |
3140 | if test "${enable_prompt_string_decoding+set}" = set; then : | |
3141 | enableval=$enable_prompt_string_decoding; opt_prompt_decoding=$enableval | |
3142 | fi | |
b80f6443 | 3143 | |
ac50fbac CR |
3144 | # Check whether --enable-readline was given. |
3145 | if test "${enable_readline+set}" = set; then : | |
3146 | enableval=$enable_readline; opt_readline=$enableval | |
3147 | fi | |
b80f6443 | 3148 | |
ac50fbac CR |
3149 | # Check whether --enable-restricted was given. |
3150 | if test "${enable_restricted+set}" = set; then : | |
3151 | enableval=$enable_restricted; opt_restricted=$enableval | |
3152 | fi | |
b80f6443 | 3153 | |
ac50fbac CR |
3154 | # Check whether --enable-select was given. |
3155 | if test "${enable_select+set}" = set; then : | |
3156 | enableval=$enable_select; opt_select=$enableval | |
3157 | fi | |
b80f6443 | 3158 | |
ac50fbac CR |
3159 | # Check whether --enable-separate-helpfiles was given. |
3160 | if test "${enable_separate_helpfiles+set}" = set; then : | |
3161 | enableval=$enable_separate_helpfiles; opt_separate_help=$enableval | |
3162 | fi | |
b80f6443 | 3163 | |
ac50fbac CR |
3164 | # Check whether --enable-single-help-strings was given. |
3165 | if test "${enable_single_help_strings+set}" = set; then : | |
3166 | enableval=$enable_single_help_strings; opt_single_longdoc_strings=$enableval | |
3167 | fi | |
d166f048 | 3168 | |
ac50fbac CR |
3169 | # Check whether --enable-strict-posix-default was given. |
3170 | if test "${enable_strict_posix_default+set}" = set; then : | |
3171 | enableval=$enable_strict_posix_default; opt_strict_posix=$enableval | |
3172 | fi | |
3173 | ||
3174 | # Check whether --enable-usg-echo-default was given. | |
3175 | if test "${enable_usg_echo_default+set}" = set; then : | |
3176 | enableval=$enable_usg_echo_default; opt_xpg_echo=$enableval | |
3177 | fi | |
3178 | ||
3179 | # Check whether --enable-xpg-echo-default was given. | |
3180 | if test "${enable_xpg_echo_default+set}" = set; then : | |
3181 | enableval=$enable_xpg_echo_default; opt_xpg_echo=$enableval | |
3182 | fi | |
3183 | ||
3184 | ||
3185 | # Check whether --enable-mem-scramble was given. | |
3186 | if test "${enable_mem_scramble+set}" = set; then : | |
3187 | enableval=$enable_mem_scramble; opt_memscramble=$enableval | |
3188 | fi | |
3189 | ||
3190 | # Check whether --enable-profiling was given. | |
3191 | if test "${enable_profiling+set}" = set; then : | |
3192 | enableval=$enable_profiling; opt_profiling=$enableval | |
3193 | fi | |
3194 | ||
3195 | # Check whether --enable-static-link was given. | |
3196 | if test "${enable_static_link+set}" = set; then : | |
3197 | enableval=$enable_static_link; opt_static_link=$enableval | |
3198 | fi | |
3199 | ||
3200 | ||
3201 | ||
3202 | ||
3203 | ||
3204 | ||
3205 | ||
3206 | ||
3207 | ||
3208 | if test $opt_alias = yes; then | |
3209 | $as_echo "#define ALIAS 1" >>confdefs.h | |
3210 | ||
3211 | fi | |
3212 | if test $opt_dirstack = yes; then | |
3213 | $as_echo "#define PUSHD_AND_POPD 1" >>confdefs.h | |
3214 | ||
3215 | fi | |
3216 | if test $opt_restricted = yes; then | |
3217 | $as_echo "#define RESTRICTED_SHELL 1" >>confdefs.h | |
3218 | ||
3219 | fi | |
3220 | if test $opt_process_subst = yes; then | |
3221 | $as_echo "#define PROCESS_SUBSTITUTION 1" >>confdefs.h | |
3222 | ||
3223 | fi | |
3224 | if test $opt_prompt_decoding = yes; then | |
3225 | $as_echo "#define PROMPT_STRING_DECODE 1" >>confdefs.h | |
3226 | ||
3227 | fi | |
3228 | if test $opt_select = yes; then | |
3229 | $as_echo "#define SELECT_COMMAND 1" >>confdefs.h | |
3230 | ||
3231 | fi | |
3232 | if test $opt_help = yes; then | |
3233 | $as_echo "#define HELP_BUILTIN 1" >>confdefs.h | |
3234 | ||
3235 | fi | |
3236 | if test $opt_array_variables = yes; then | |
3237 | $as_echo "#define ARRAY_VARS 1" >>confdefs.h | |
3238 | ||
3239 | fi | |
3240 | if test $opt_dparen_arith = yes; then | |
3241 | $as_echo "#define DPAREN_ARITHMETIC 1" >>confdefs.h | |
3242 | ||
3243 | fi | |
3244 | if test $opt_brace_expansion = yes; then | |
3245 | $as_echo "#define BRACE_EXPANSION 1" >>confdefs.h | |
3246 | ||
3247 | fi | |
3248 | if test $opt_disabled_builtins = yes; then | |
3249 | $as_echo "#define DISABLED_BUILTINS 1" >>confdefs.h | |
3250 | ||
3251 | fi | |
3252 | if test $opt_command_timing = yes; then | |
3253 | $as_echo "#define COMMAND_TIMING 1" >>confdefs.h | |
3254 | ||
3255 | fi | |
3256 | if test $opt_xpg_echo = yes ; then | |
3257 | $as_echo "#define DEFAULT_ECHO_TO_XPG 1" >>confdefs.h | |
3258 | ||
3259 | fi | |
3260 | if test $opt_strict_posix = yes; then | |
3261 | $as_echo "#define STRICT_POSIX 1" >>confdefs.h | |
3262 | ||
3263 | fi | |
3264 | if test $opt_extended_glob = yes ; then | |
3265 | $as_echo "#define EXTENDED_GLOB 1" >>confdefs.h | |
3266 | ||
3267 | fi | |
3268 | if test $opt_extglob_default = yes; then | |
3269 | $as_echo "#define EXTGLOB_DEFAULT 1" >>confdefs.h | |
3270 | ||
3271 | else | |
3272 | $as_echo "#define EXTGLOB_DEFAULT 0" >>confdefs.h | |
3273 | ||
3274 | fi | |
3275 | if test $opt_cond_command = yes ; then | |
3276 | $as_echo "#define COND_COMMAND 1" >>confdefs.h | |
3277 | ||
3278 | fi | |
3279 | if test $opt_cond_regexp = yes ; then | |
3280 | $as_echo "#define COND_REGEXP 1" >>confdefs.h | |
3281 | ||
3282 | fi | |
3283 | if test $opt_coproc = yes; then | |
3284 | $as_echo "#define COPROCESS_SUPPORT 1" >>confdefs.h | |
3285 | ||
3286 | fi | |
3287 | if test $opt_arith_for_command = yes; then | |
3288 | $as_echo "#define ARITH_FOR_COMMAND 1" >>confdefs.h | |
3289 | ||
3290 | fi | |
3291 | if test $opt_net_redirs = yes; then | |
3292 | $as_echo "#define NETWORK_REDIRECTIONS 1" >>confdefs.h | |
3293 | ||
3294 | fi | |
3295 | if test $opt_progcomp = yes; then | |
3296 | $as_echo "#define PROGRAMMABLE_COMPLETION 1" >>confdefs.h | |
3297 | ||
3298 | fi | |
3299 | if test $opt_multibyte = no; then | |
3300 | $as_echo "#define NO_MULTIBYTE_SUPPORT 1" >>confdefs.h | |
3301 | ||
3302 | fi | |
3303 | if test $opt_debugger = yes; then | |
3304 | $as_echo "#define DEBUGGER 1" >>confdefs.h | |
3305 | ||
3306 | fi | |
3307 | if test $opt_casemod_attrs = yes; then | |
3308 | $as_echo "#define CASEMOD_ATTRS 1" >>confdefs.h | |
3309 | ||
3310 | fi | |
3311 | if test $opt_casemod_expansions = yes; then | |
3312 | $as_echo "#define CASEMOD_EXPANSIONS 1" >>confdefs.h | |
3313 | ||
3314 | fi | |
3315 | if test $opt_dircomplete_expand_default = yes; then | |
3316 | $as_echo "#define DIRCOMPLETE_EXPAND_DEFAULT 1" >>confdefs.h | |
3317 | ||
3318 | fi | |
3319 | if test $opt_globascii_default = yes; then | |
3320 | $as_echo "#define GLOBASCII_DEFAULT 1" >>confdefs.h | |
3321 | ||
3322 | else | |
3323 | $as_echo "#define GLOBASCII_DEFAULT 0" >>confdefs.h | |
3324 | ||
a0c0a00f CR |
3325 | fi |
3326 | if test $opt_function_import = yes; then | |
3327 | $as_echo "#define FUNCTION_IMPORT 1" >>confdefs.h | |
3328 | ||
ac50fbac CR |
3329 | fi |
3330 | ||
3331 | if test $opt_memscramble = yes; then | |
3332 | $as_echo "#define MEMSCRAMBLE 1" >>confdefs.h | |
3333 | ||
3334 | fi | |
3335 | ||
3336 | if test "$opt_minimal_config" = yes; then | |
3337 | TESTSCRIPT=run-minimal | |
3338 | else | |
3339 | TESTSCRIPT=run-all | |
3340 | fi | |
3341 | ||
3342 | HELPDIR= HELPDIRDEFINE= HELPINSTALL= HELPFILES_TARGET= | |
3343 | if test "$opt_separate_help" != no; then | |
3344 | if test "$opt_separate_help" = "yes" ; then | |
3345 | HELPDIR='${datadir}/bash' | |
3346 | else | |
3347 | HELPDIR=$opt_separate_help | |
3348 | fi | |
3349 | HELPDIRDEFINE='-H ${HELPDIR}' | |
3350 | HELPINSTALL='install-help' | |
3351 | HELPFILES_TARGET='helpdoc' | |
3352 | fi | |
3353 | HELPSTRINGS= | |
3354 | if test "$opt_single_longdoc_strings" != "yes"; then | |
3355 | HELPSTRINGS='-S' | |
3356 | fi | |
3357 | ||
3358 | ||
3359 | ||
3360 | ||
3361 | ||
3362 | ||
3363 | ||
3364 | ||
3365 | ||
3366 | ||
3367 | ||
3368 | ||
3369 | ||
3370 | ||
3371 | ||
3372 | ||
3373 | ||
3374 | ||
a0c0a00f CR |
3375 | if test -z "$CFLAGS"; then |
3376 | AUTO_CFLAGS="-g ${GCC+-O2} ${GCC+-Wno-parentheses}" | |
3377 | AUTO_LDFLAGS="-g ${GCC+-O2}" | |
3378 | else | |
3379 | AUTO_CFLAGS= AUTO_LDFLAGS= | |
3380 | fi | |
ac50fbac CR |
3381 | |
3382 | echo "" | |
3383 | echo "Beginning configuration for bash-$BASHVERS-$RELSTATUS for ${host_cpu}-${host_vendor}-${host_os}" | |
3384 | echo "" | |
3385 | ||
3386 | ac_ext=c | |
3387 | ac_cpp='$CPP $CPPFLAGS' | |
3388 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3389 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3390 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3391 | if test -n "$ac_tool_prefix"; then | |
3392 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
3393 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
3394 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3395 | $as_echo_n "checking for $ac_word... " >&6; } | |
3396 | if ${ac_cv_prog_CC+:} false; then : | |
3397 | $as_echo_n "(cached) " >&6 | |
3398 | else | |
3399 | if test -n "$CC"; then | |
3400 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3401 | else | |
3402 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3403 | for as_dir in $PATH | |
3404 | do | |
3405 | IFS=$as_save_IFS | |
3406 | test -z "$as_dir" && as_dir=. | |
3407 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3408 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
3409 | ac_cv_prog_CC="${ac_tool_prefix}gcc" | |
3410 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3411 | break 2 | |
b80f6443 JA |
3412 | fi |
3413 | done | |
ac50fbac | 3414 | done |
3185942a | 3415 | IFS=$as_save_IFS |
ccc6cda3 | 3416 | |
f73dda09 JA |
3417 | fi |
3418 | fi | |
3419 | CC=$ac_cv_prog_CC | |
3420 | if test -n "$CC"; then | |
ac50fbac | 3421 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3185942a | 3422 | $as_echo "$CC" >&6; } |
f73dda09 | 3423 | else |
ac50fbac | 3424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3425 | $as_echo "no" >&6; } |
f73dda09 | 3426 | fi |
ccc6cda3 | 3427 | |
3185942a | 3428 | |
f73dda09 JA |
3429 | fi |
3430 | if test -z "$ac_cv_prog_CC"; then | |
3431 | ac_ct_CC=$CC | |
3432 | # Extract the first word of "gcc", so it can be a program name with args. | |
3433 | set dummy gcc; ac_word=$2 | |
ac50fbac | 3434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 3435 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 3436 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
3185942a | 3437 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3438 | else |
3439 | if test -n "$ac_ct_CC"; then | |
3440 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3441 | else | |
b80f6443 JA |
3442 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3443 | for as_dir in $PATH | |
3444 | do | |
3445 | IFS=$as_save_IFS | |
3446 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
3447 | for ac_exec_ext in '' $ac_executable_extensions; do |
3448 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 3449 | ac_cv_prog_ac_ct_CC="gcc" |
ac50fbac | 3450 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
3451 | break 2 |
3452 | fi | |
3453 | done | |
ac50fbac | 3454 | done |
3185942a | 3455 | IFS=$as_save_IFS |
ccc6cda3 | 3456 | |
f73dda09 JA |
3457 | fi |
3458 | fi | |
3459 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
3460 | if test -n "$ac_ct_CC"; then | |
ac50fbac | 3461 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
3185942a | 3462 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3463 | else |
ac50fbac | 3464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3465 | $as_echo "no" >&6; } |
f73dda09 | 3466 | fi |
ccc6cda3 | 3467 | |
3185942a JA |
3468 | if test "x$ac_ct_CC" = x; then |
3469 | CC="" | |
3470 | else | |
3471 | case $cross_compiling:$ac_tool_warned in | |
3472 | yes:) | |
ac50fbac | 3473 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
3185942a JA |
3474 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
3475 | ac_tool_warned=yes ;; | |
3476 | esac | |
3477 | CC=$ac_ct_CC | |
3478 | fi | |
f73dda09 JA |
3479 | else |
3480 | CC="$ac_cv_prog_CC" | |
3481 | fi | |
bb70624e | 3482 | |
f73dda09 | 3483 | if test -z "$CC"; then |
3185942a JA |
3484 | if test -n "$ac_tool_prefix"; then |
3485 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
f73dda09 | 3486 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
ac50fbac | 3487 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 3488 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 3489 | if ${ac_cv_prog_CC+:} false; then : |
3185942a | 3490 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
3491 | else |
3492 | if test -n "$CC"; then | |
3493 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3494 | else | |
b80f6443 JA |
3495 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3496 | for as_dir in $PATH | |
3497 | do | |
3498 | IFS=$as_save_IFS | |
3499 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
3500 | for ac_exec_ext in '' $ac_executable_extensions; do |
3501 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 3502 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
ac50fbac | 3503 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
3504 | break 2 |
3505 | fi | |
3506 | done | |
ac50fbac | 3507 | done |
3185942a | 3508 | IFS=$as_save_IFS |
f73dda09 | 3509 | |
ccc6cda3 JA |
3510 | fi |
3511 | fi | |
f73dda09 | 3512 | CC=$ac_cv_prog_CC |
ccc6cda3 | 3513 | if test -n "$CC"; then |
ac50fbac | 3514 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3185942a | 3515 | $as_echo "$CC" >&6; } |
f73dda09 | 3516 | else |
ac50fbac | 3517 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3518 | $as_echo "no" >&6; } |
f73dda09 JA |
3519 | fi |
3520 | ||
ccc6cda3 | 3521 | |
3185942a | 3522 | fi |
f73dda09 | 3523 | fi |
ccc6cda3 JA |
3524 | if test -z "$CC"; then |
3525 | # Extract the first word of "cc", so it can be a program name with args. | |
3526 | set dummy cc; ac_word=$2 | |
ac50fbac | 3527 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 3528 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 3529 | if ${ac_cv_prog_CC+:} false; then : |
3185942a | 3530 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
3531 | else |
3532 | if test -n "$CC"; then | |
3533 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3534 | else | |
ccc6cda3 | 3535 | ac_prog_rejected=no |
b80f6443 JA |
3536 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3537 | for as_dir in $PATH | |
3538 | do | |
3539 | IFS=$as_save_IFS | |
3540 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
3541 | for ac_exec_ext in '' $ac_executable_extensions; do |
3542 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 JA |
3543 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
3544 | ac_prog_rejected=yes | |
3545 | continue | |
3546 | fi | |
3547 | ac_cv_prog_CC="cc" | |
ac50fbac | 3548 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
3549 | break 2 |
3550 | fi | |
3551 | done | |
ac50fbac | 3552 | done |
3185942a | 3553 | IFS=$as_save_IFS |
f73dda09 | 3554 | |
ccc6cda3 JA |
3555 | if test $ac_prog_rejected = yes; then |
3556 | # We found a bogon in the path, so make sure we never use it. | |
3557 | set dummy $ac_cv_prog_CC | |
3558 | shift | |
f73dda09 | 3559 | if test $# != 0; then |
ccc6cda3 JA |
3560 | # We chose a different compiler from the bogus one. |
3561 | # However, it has the same basename, so the bogon will be chosen | |
3562 | # first if we set CC to just the basename; use the full file name. | |
3563 | shift | |
0628567a | 3564 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
ccc6cda3 JA |
3565 | fi |
3566 | fi | |
3567 | fi | |
3568 | fi | |
f73dda09 | 3569 | CC=$ac_cv_prog_CC |
ccc6cda3 | 3570 | if test -n "$CC"; then |
ac50fbac | 3571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3185942a | 3572 | $as_echo "$CC" >&6; } |
ccc6cda3 | 3573 | else |
ac50fbac | 3574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3575 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3576 | fi |
3577 | ||
3185942a | 3578 | |
f73dda09 JA |
3579 | fi |
3580 | if test -z "$CC"; then | |
3581 | if test -n "$ac_tool_prefix"; then | |
3185942a | 3582 | for ac_prog in cl.exe |
f73dda09 JA |
3583 | do |
3584 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
3585 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
ac50fbac | 3586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 3587 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 3588 | if ${ac_cv_prog_CC+:} false; then : |
3185942a | 3589 | $as_echo_n "(cached) " >&6 |
bb70624e JA |
3590 | else |
3591 | if test -n "$CC"; then | |
3592 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3593 | else | |
b80f6443 JA |
3594 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3595 | for as_dir in $PATH | |
3596 | do | |
3597 | IFS=$as_save_IFS | |
3598 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
3599 | for ac_exec_ext in '' $ac_executable_extensions; do |
3600 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 3601 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
ac50fbac | 3602 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
3603 | break 2 |
3604 | fi | |
3605 | done | |
ac50fbac | 3606 | done |
3185942a | 3607 | IFS=$as_save_IFS |
f73dda09 | 3608 | |
bb70624e JA |
3609 | fi |
3610 | fi | |
f73dda09 | 3611 | CC=$ac_cv_prog_CC |
bb70624e | 3612 | if test -n "$CC"; then |
ac50fbac | 3613 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3185942a | 3614 | $as_echo "$CC" >&6; } |
bb70624e | 3615 | else |
ac50fbac | 3616 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3617 | $as_echo "no" >&6; } |
bb70624e | 3618 | fi |
ccc6cda3 | 3619 | |
3185942a | 3620 | |
f73dda09 JA |
3621 | test -n "$CC" && break |
3622 | done | |
ccc6cda3 | 3623 | fi |
f73dda09 JA |
3624 | if test -z "$CC"; then |
3625 | ac_ct_CC=$CC | |
3185942a | 3626 | for ac_prog in cl.exe |
f73dda09 JA |
3627 | do |
3628 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3629 | set dummy $ac_prog; ac_word=$2 | |
ac50fbac | 3630 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 3631 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 3632 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
3185942a | 3633 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3634 | else |
3635 | if test -n "$ac_ct_CC"; then | |
3636 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3637 | else | |
b80f6443 JA |
3638 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3639 | for as_dir in $PATH | |
3640 | do | |
3641 | IFS=$as_save_IFS | |
3642 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
3643 | for ac_exec_ext in '' $ac_executable_extensions; do |
3644 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 3645 | ac_cv_prog_ac_ct_CC="$ac_prog" |
ac50fbac | 3646 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
3647 | break 2 |
3648 | fi | |
3649 | done | |
ac50fbac | 3650 | done |
3185942a | 3651 | IFS=$as_save_IFS |
ccc6cda3 | 3652 | |
ccc6cda3 | 3653 | fi |
ccc6cda3 | 3654 | fi |
f73dda09 JA |
3655 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
3656 | if test -n "$ac_ct_CC"; then | |
ac50fbac | 3657 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
3185942a | 3658 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3659 | else |
ac50fbac | 3660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 3661 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3662 | fi |
3663 | ||
3185942a | 3664 | |
f73dda09 JA |
3665 | test -n "$ac_ct_CC" && break |
3666 | done | |
ccc6cda3 | 3667 | |
3185942a JA |
3668 | if test "x$ac_ct_CC" = x; then |
3669 | CC="" | |
3670 | else | |
3671 | case $cross_compiling:$ac_tool_warned in | |
3672 | yes:) | |
ac50fbac | 3673 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
3185942a JA |
3674 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
3675 | ac_tool_warned=yes ;; | |
3676 | esac | |
3677 | CC=$ac_ct_CC | |
3678 | fi | |
bb70624e JA |
3679 | fi |
3680 | ||
f73dda09 JA |
3681 | fi |
3682 | ||
b80f6443 | 3683 | |
ac50fbac | 3684 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3185942a | 3685 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
ac50fbac CR |
3686 | as_fn_error $? "no acceptable C compiler found in \$PATH |
3687 | See \`config.log' for more details" "$LINENO" 5; } | |
f73dda09 JA |
3688 | |
3689 | # Provide some information about the compiler. | |
ac50fbac | 3690 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
3185942a JA |
3691 | set X $ac_compile |
3692 | ac_compiler=$2 | |
ac50fbac CR |
3693 | for ac_option in --version -v -V -qversion; do |
3694 | { { ac_try="$ac_compiler $ac_option >&5" | |
3185942a JA |
3695 | case "(($ac_try" in |
3696 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3697 | *) ac_try_echo=$ac_try;; | |
3698 | esac | |
ac50fbac CR |
3699 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3700 | $as_echo "$ac_try_echo"; } >&5 | |
3701 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
f73dda09 | 3702 | ac_status=$? |
ac50fbac CR |
3703 | if test -s conftest.err; then |
3704 | sed '10a\ | |
3705 | ... rest of stderr output deleted ... | |
3706 | 10q' conftest.err >conftest.er1 | |
3707 | cat conftest.er1 >&5 | |
3708 | fi | |
3709 | rm -f conftest.er1 conftest.err | |
3710 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3711 | test $ac_status = 0; } | |
3712 | done | |
f73dda09 | 3713 | |
ac50fbac | 3714 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 3715 | /* end confdefs.h. */ |
f73dda09 JA |
3716 | |
3717 | int | |
3718 | main () | |
3719 | { | |
3720 | ||
3721 | ; | |
3722 | return 0; | |
3723 | } | |
3724 | _ACEOF | |
3725 | ac_clean_files_save=$ac_clean_files | |
3185942a | 3726 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
f73dda09 JA |
3727 | # Try to create an executable without -o first, disregard a.out. |
3728 | # It will help us diagnose broken compilers, and finding out an intuition | |
3729 | # of exeext. | |
ac50fbac CR |
3730 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
3731 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
3185942a JA |
3732 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
3733 | ||
3734 | # The possible output files: | |
3735 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
3736 | ||
3737 | ac_rmfiles= | |
3738 | for ac_file in $ac_files | |
3739 | do | |
3740 | case $ac_file in | |
3741 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3742 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; | |
3743 | esac | |
3744 | done | |
3745 | rm -f $ac_rmfiles | |
3746 | ||
ac50fbac | 3747 | if { { ac_try="$ac_link_default" |
3185942a JA |
3748 | case "(($ac_try" in |
3749 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3750 | *) ac_try_echo=$ac_try;; | |
3751 | esac | |
ac50fbac CR |
3752 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3753 | $as_echo "$ac_try_echo"; } >&5 | |
3185942a | 3754 | (eval "$ac_link_default") 2>&5 |
f73dda09 | 3755 | ac_status=$? |
ac50fbac CR |
3756 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3757 | test $ac_status = 0; }; then : | |
3185942a JA |
3758 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
3759 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
3760 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
3761 | # so that the user can short-circuit this test for compilers unknown to | |
3762 | # Autoconf. | |
3763 | for ac_file in $ac_files '' | |
0628567a JA |
3764 | do |
3765 | test -f "$ac_file" || continue | |
f73dda09 | 3766 | case $ac_file in |
3185942a | 3767 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
0628567a JA |
3768 | ;; |
3769 | [ab].out ) | |
3770 | # We found the default executable, but exeext='' is most | |
3771 | # certainly right. | |
3772 | break;; | |
3773 | *.* ) | |
ac50fbac | 3774 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
3185942a JA |
3775 | then :; else |
3776 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3777 | fi | |
3778 | # We set ac_cv_exeext here because the later test for it is not | |
3779 | # safe: cross compilers may not add the suffix if given an `-o' | |
3780 | # argument, so we may need to know it at that point already. | |
3781 | # Even if this section looks crufty: it has the advantage of | |
3782 | # actually working. | |
0628567a JA |
3783 | break;; |
3784 | * ) | |
3785 | break;; | |
f73dda09 JA |
3786 | esac |
3787 | done | |
3185942a JA |
3788 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
3789 | ||
ccc6cda3 | 3790 | else |
3185942a JA |
3791 | ac_file='' |
3792 | fi | |
ac50fbac CR |
3793 | if test -z "$ac_file"; then : |
3794 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3795 | $as_echo "no" >&6; } | |
3796 | $as_echo "$as_me: failed program was:" >&5 | |
0628567a JA |
3797 | sed 's/^/| /' conftest.$ac_ext >&5 |
3798 | ||
ac50fbac | 3799 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3185942a | 3800 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
ac50fbac CR |
3801 | as_fn_error 77 "C compiler cannot create executables |
3802 | See \`config.log' for more details" "$LINENO" 5; } | |
3803 | else | |
3804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
3805 | $as_echo "yes" >&6; } | |
f73dda09 | 3806 | fi |
ac50fbac CR |
3807 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
3808 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
3809 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
3810 | $as_echo "$ac_file" >&6; } | |
f73dda09 | 3811 | ac_exeext=$ac_cv_exeext |
f73dda09 | 3812 | |
ac50fbac CR |
3813 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
3814 | ac_clean_files=$ac_clean_files_save | |
3815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 | |
3816 | $as_echo_n "checking for suffix of executables... " >&6; } | |
3817 | if { { ac_try="$ac_link" | |
3818 | case "(($ac_try" in | |
3185942a JA |
3819 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; |
3820 | *) ac_try_echo=$ac_try;; | |
3821 | esac | |
ac50fbac CR |
3822 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3823 | $as_echo "$ac_try_echo"; } >&5 | |
3824 | (eval "$ac_link") 2>&5 | |
f73dda09 | 3825 | ac_status=$? |
ac50fbac CR |
3826 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3827 | test $ac_status = 0; }; then : | |
f73dda09 JA |
3828 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
3829 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
3830 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
3831 | # `rm'. | |
0628567a JA |
3832 | for ac_file in conftest.exe conftest conftest.*; do |
3833 | test -f "$ac_file" || continue | |
f73dda09 | 3834 | case $ac_file in |
3185942a | 3835 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
f73dda09 | 3836 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
0628567a | 3837 | break;; |
f73dda09 JA |
3838 | * ) break;; |
3839 | esac | |
3840 | done | |
ccc6cda3 | 3841 | else |
ac50fbac | 3842 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3185942a | 3843 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
ac50fbac CR |
3844 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
3845 | See \`config.log' for more details" "$LINENO" 5; } | |
f73dda09 | 3846 | fi |
ac50fbac CR |
3847 | rm -f conftest conftest$ac_cv_exeext |
3848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
3185942a | 3849 | $as_echo "$ac_cv_exeext" >&6; } |
f73dda09 JA |
3850 | |
3851 | rm -f conftest.$ac_ext | |
3852 | EXEEXT=$ac_cv_exeext | |
3853 | ac_exeext=$EXEEXT | |
ac50fbac CR |
3854 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3855 | /* end confdefs.h. */ | |
3856 | #include <stdio.h> | |
3857 | int | |
3858 | main () | |
3859 | { | |
3860 | FILE *f = fopen ("conftest.out", "w"); | |
3861 | return ferror (f) || fclose (f) != 0; | |
3862 | ||
3863 | ; | |
3864 | return 0; | |
3865 | } | |
3866 | _ACEOF | |
3867 | ac_clean_files="$ac_clean_files conftest.out" | |
3868 | # Check that the compiler produces executables we can run. If not, either | |
3869 | # the compiler is broken, or we cross compile. | |
3870 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
3871 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
3872 | if test "$cross_compiling" != yes; then | |
3873 | { { ac_try="$ac_link" | |
3874 | case "(($ac_try" in | |
3875 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3876 | *) ac_try_echo=$ac_try;; | |
3877 | esac | |
3878 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3879 | $as_echo "$ac_try_echo"; } >&5 | |
3880 | (eval "$ac_link") 2>&5 | |
3881 | ac_status=$? | |
3882 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3883 | test $ac_status = 0; } | |
3884 | if { ac_try='./conftest$ac_cv_exeext' | |
3885 | { { case "(($ac_try" in | |
3886 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3887 | *) ac_try_echo=$ac_try;; | |
3888 | esac | |
3889 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3890 | $as_echo "$ac_try_echo"; } >&5 | |
3891 | (eval "$ac_try") 2>&5 | |
3892 | ac_status=$? | |
3893 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3894 | test $ac_status = 0; }; }; then | |
3895 | cross_compiling=no | |
3896 | else | |
3897 | if test "$cross_compiling" = maybe; then | |
3898 | cross_compiling=yes | |
3899 | else | |
3900 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3901 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3902 | as_fn_error $? "cannot run C compiled programs. | |
3903 | If you meant to cross compile, use \`--host'. | |
3904 | See \`config.log' for more details" "$LINENO" 5; } | |
3905 | fi | |
3906 | fi | |
3907 | fi | |
3908 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
3909 | $as_echo "$cross_compiling" >&6; } | |
3910 | ||
3911 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out | |
3912 | ac_clean_files=$ac_clean_files_save | |
3913 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 | |
3185942a | 3914 | $as_echo_n "checking for suffix of object files... " >&6; } |
ac50fbac | 3915 | if ${ac_cv_objext+:} false; then : |
3185942a | 3916 | $as_echo_n "(cached) " >&6 |
f73dda09 | 3917 | else |
ac50fbac | 3918 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 3919 | /* end confdefs.h. */ |
f73dda09 JA |
3920 | |
3921 | int | |
3922 | main () | |
3923 | { | |
3924 | ||
3925 | ; | |
3926 | return 0; | |
3927 | } | |
3928 | _ACEOF | |
3929 | rm -f conftest.o conftest.obj | |
ac50fbac | 3930 | if { { ac_try="$ac_compile" |
3185942a JA |
3931 | case "(($ac_try" in |
3932 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3933 | *) ac_try_echo=$ac_try;; | |
3934 | esac | |
ac50fbac CR |
3935 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3936 | $as_echo "$ac_try_echo"; } >&5 | |
3185942a | 3937 | (eval "$ac_compile") 2>&5 |
f73dda09 | 3938 | ac_status=$? |
ac50fbac CR |
3939 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3940 | test $ac_status = 0; }; then : | |
3185942a JA |
3941 | for ac_file in conftest.o conftest.obj conftest.*; do |
3942 | test -f "$ac_file" || continue; | |
f73dda09 | 3943 | case $ac_file in |
3185942a | 3944 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; |
f73dda09 JA |
3945 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
3946 | break;; | |
3947 | esac | |
3948 | done | |
3949 | else | |
3185942a | 3950 | $as_echo "$as_me: failed program was:" >&5 |
0628567a JA |
3951 | sed 's/^/| /' conftest.$ac_ext >&5 |
3952 | ||
ac50fbac | 3953 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3185942a | 3954 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
ac50fbac CR |
3955 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
3956 | See \`config.log' for more details" "$LINENO" 5; } | |
ccc6cda3 | 3957 | fi |
f73dda09 | 3958 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
ccc6cda3 | 3959 | fi |
ac50fbac | 3960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
3185942a | 3961 | $as_echo "$ac_cv_objext" >&6; } |
f73dda09 JA |
3962 | OBJEXT=$ac_cv_objext |
3963 | ac_objext=$OBJEXT | |
ac50fbac | 3964 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
3185942a | 3965 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
ac50fbac | 3966 | if ${ac_cv_c_compiler_gnu+:} false; then : |
3185942a | 3967 | $as_echo_n "(cached) " >&6 |
f73dda09 | 3968 | else |
ac50fbac | 3969 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 3970 | /* end confdefs.h. */ |
f73dda09 JA |
3971 | |
3972 | int | |
3973 | main () | |
3974 | { | |
3975 | #ifndef __GNUC__ | |
3976 | choke me | |
3977 | #endif | |
3978 | ||
3979 | ; | |
3980 | return 0; | |
3981 | } | |
3982 | _ACEOF | |
ac50fbac | 3983 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
3984 | ac_compiler_gnu=yes |
3985 | else | |
ac50fbac | 3986 | ac_compiler_gnu=no |
f73dda09 | 3987 | fi |
3185942a | 3988 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 JA |
3989 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
3990 | ||
3991 | fi | |
ac50fbac | 3992 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
3185942a JA |
3993 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
3994 | if test $ac_compiler_gnu = yes; then | |
3995 | GCC=yes | |
3996 | else | |
3997 | GCC= | |
3998 | fi | |
f73dda09 JA |
3999 | ac_test_CFLAGS=${CFLAGS+set} |
4000 | ac_save_CFLAGS=$CFLAGS | |
ac50fbac | 4001 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
3185942a | 4002 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
ac50fbac | 4003 | if ${ac_cv_prog_cc_g+:} false; then : |
3185942a | 4004 | $as_echo_n "(cached) " >&6 |
f73dda09 | 4005 | else |
3185942a JA |
4006 | ac_save_c_werror_flag=$ac_c_werror_flag |
4007 | ac_c_werror_flag=yes | |
4008 | ac_cv_prog_cc_g=no | |
4009 | CFLAGS="-g" | |
ac50fbac | 4010 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4011 | /* end confdefs.h. */ |
f73dda09 JA |
4012 | |
4013 | int | |
4014 | main () | |
4015 | { | |
ccc6cda3 | 4016 | |
f73dda09 JA |
4017 | ; |
4018 | return 0; | |
4019 | } | |
4020 | _ACEOF | |
ac50fbac | 4021 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a JA |
4022 | ac_cv_prog_cc_g=yes |
4023 | else | |
ac50fbac CR |
4024 | CFLAGS="" |
4025 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a JA |
4026 | /* end confdefs.h. */ |
4027 | ||
4028 | int | |
4029 | main () | |
4030 | { | |
4031 | ||
4032 | ; | |
4033 | return 0; | |
4034 | } | |
4035 | _ACEOF | |
ac50fbac | 4036 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 4037 | |
ac50fbac CR |
4038 | else |
4039 | ac_c_werror_flag=$ac_save_c_werror_flag | |
3185942a | 4040 | CFLAGS="-g" |
ac50fbac | 4041 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a JA |
4042 | /* end confdefs.h. */ |
4043 | ||
4044 | int | |
4045 | main () | |
4046 | { | |
4047 | ||
4048 | ; | |
4049 | return 0; | |
4050 | } | |
4051 | _ACEOF | |
ac50fbac | 4052 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4053 | ac_cv_prog_cc_g=yes |
3185942a | 4054 | fi |
3185942a JA |
4055 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4056 | fi | |
3185942a | 4057 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 4058 | fi |
3185942a JA |
4059 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4060 | ac_c_werror_flag=$ac_save_c_werror_flag | |
f73dda09 | 4061 | fi |
ac50fbac | 4062 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
3185942a | 4063 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
bb70624e | 4064 | if test "$ac_test_CFLAGS" = set; then |
f73dda09 | 4065 | CFLAGS=$ac_save_CFLAGS |
bb70624e JA |
4066 | elif test $ac_cv_prog_cc_g = yes; then |
4067 | if test "$GCC" = yes; then | |
ccc6cda3 JA |
4068 | CFLAGS="-g -O2" |
4069 | else | |
bb70624e | 4070 | CFLAGS="-g" |
ccc6cda3 JA |
4071 | fi |
4072 | else | |
bb70624e JA |
4073 | if test "$GCC" = yes; then |
4074 | CFLAGS="-O2" | |
4075 | else | |
4076 | CFLAGS= | |
4077 | fi | |
ccc6cda3 | 4078 | fi |
ac50fbac | 4079 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
3185942a | 4080 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
ac50fbac | 4081 | if ${ac_cv_prog_cc_c89+:} false; then : |
3185942a | 4082 | $as_echo_n "(cached) " >&6 |
0628567a | 4083 | else |
3185942a | 4084 | ac_cv_prog_cc_c89=no |
0628567a | 4085 | ac_save_CC=$CC |
ac50fbac | 4086 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a JA |
4087 | /* end confdefs.h. */ |
4088 | #include <stdarg.h> | |
4089 | #include <stdio.h> | |
ac50fbac | 4090 | struct stat; |
0628567a JA |
4091 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
4092 | struct buf { int x; }; | |
4093 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
4094 | static char *e (p, i) | |
4095 | char **p; | |
4096 | int i; | |
4097 | { | |
4098 | return p[i]; | |
4099 | } | |
4100 | static char *f (char * (*g) (char **, int), char **p, ...) | |
4101 | { | |
4102 | char *s; | |
4103 | va_list v; | |
4104 | va_start (v,p); | |
4105 | s = g (p, va_arg (v,int)); | |
4106 | va_end (v); | |
4107 | return s; | |
4108 | } | |
4109 | ||
4110 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
4111 | function prototypes and stuff, but not '\xHH' hex character constants. | |
4112 | These don't provoke an error unfortunately, instead are silently treated | |
3185942a | 4113 | as 'x'. The following induces an error, until -std is added to get |
0628567a JA |
4114 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
4115 | array size at least. It's necessary to write '\x00'==0 to get something | |
3185942a | 4116 | that's true only with -std. */ |
0628567a JA |
4117 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
4118 | ||
3185942a JA |
4119 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
4120 | inside strings and character constants. */ | |
4121 | #define FOO(x) 'x' | |
4122 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
4123 | ||
0628567a JA |
4124 | int test (int i, double x); |
4125 | struct s1 {int (*f) (int a);}; | |
4126 | struct s2 {int (*f) (double a);}; | |
4127 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
4128 | int argc; | |
4129 | char **argv; | |
4130 | int | |
4131 | main () | |
4132 | { | |
4133 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; | |
4134 | ; | |
4135 | return 0; | |
4136 | } | |
4137 | _ACEOF | |
3185942a JA |
4138 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
4139 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
0628567a JA |
4140 | do |
4141 | CC="$ac_save_CC $ac_arg" | |
ac50fbac | 4142 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 4143 | ac_cv_prog_cc_c89=$ac_arg |
0628567a | 4144 | fi |
3185942a JA |
4145 | rm -f core conftest.err conftest.$ac_objext |
4146 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
0628567a | 4147 | done |
3185942a | 4148 | rm -f conftest.$ac_ext |
0628567a JA |
4149 | CC=$ac_save_CC |
4150 | ||
4151 | fi | |
3185942a JA |
4152 | # AC_CACHE_VAL |
4153 | case "x$ac_cv_prog_cc_c89" in | |
4154 | x) | |
ac50fbac | 4155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
3185942a JA |
4156 | $as_echo "none needed" >&6; } ;; |
4157 | xno) | |
ac50fbac | 4158 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
3185942a | 4159 | $as_echo "unsupported" >&6; } ;; |
0628567a | 4160 | *) |
3185942a | 4161 | CC="$CC $ac_cv_prog_cc_c89" |
ac50fbac | 4162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
3185942a | 4163 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
0628567a | 4164 | esac |
ac50fbac | 4165 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
0628567a | 4166 | |
ac50fbac | 4167 | fi |
0628567a | 4168 | |
f73dda09 JA |
4169 | ac_ext=c |
4170 | ac_cpp='$CPP $CPPFLAGS' | |
4171 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4172 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4173 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
bb70624e | 4174 | |
f73dda09 | 4175 | |
ccc6cda3 | 4176 | |
b80f6443 | 4177 | |
ac50fbac | 4178 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror in -lcposix" >&5 |
3185942a | 4179 | $as_echo_n "checking for strerror in -lcposix... " >&6; } |
ac50fbac | 4180 | if ${ac_cv_lib_cposix_strerror+:} false; then : |
3185942a | 4181 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 4182 | else |
b80f6443 JA |
4183 | ac_check_lib_save_LIBS=$LIBS |
4184 | LIBS="-lcposix $LIBS" | |
ac50fbac | 4185 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4186 | /* end confdefs.h. */ |
b80f6443 | 4187 | |
3185942a JA |
4188 | /* Override any GCC internal prototype to avoid an error. |
4189 | Use char because int might match the return type of a GCC | |
4190 | builtin and then its argument prototype would still apply. */ | |
b80f6443 JA |
4191 | #ifdef __cplusplus |
4192 | extern "C" | |
4193 | #endif | |
b80f6443 JA |
4194 | char strerror (); |
4195 | int | |
4196 | main () | |
4197 | { | |
3185942a | 4198 | return strerror (); |
b80f6443 JA |
4199 | ; |
4200 | return 0; | |
4201 | } | |
4202 | _ACEOF | |
ac50fbac | 4203 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 JA |
4204 | ac_cv_lib_cposix_strerror=yes |
4205 | else | |
ac50fbac | 4206 | ac_cv_lib_cposix_strerror=no |
b80f6443 | 4207 | fi |
ac50fbac CR |
4208 | rm -f core conftest.err conftest.$ac_objext \ |
4209 | conftest$ac_exeext conftest.$ac_ext | |
b80f6443 JA |
4210 | LIBS=$ac_check_lib_save_LIBS |
4211 | fi | |
ac50fbac | 4212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cposix_strerror" >&5 |
3185942a | 4213 | $as_echo "$ac_cv_lib_cposix_strerror" >&6; } |
ac50fbac | 4214 | if test "x$ac_cv_lib_cposix_strerror" = xyes; then : |
b80f6443 | 4215 | LIBS="$LIBS -lcposix" |
ccc6cda3 JA |
4216 | fi |
4217 | ||
b80f6443 JA |
4218 | |
4219 | ||
f73dda09 JA |
4220 | ac_ext=c |
4221 | ac_cpp='$CPP $CPPFLAGS' | |
4222 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4223 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4224 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
ac50fbac | 4225 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
3185942a | 4226 | $as_echo_n "checking how to run the C preprocessor... " >&6; } |
ccc6cda3 JA |
4227 | # On Suns, sometimes $CPP names a directory. |
4228 | if test -n "$CPP" && test -d "$CPP"; then | |
4229 | CPP= | |
4230 | fi | |
4231 | if test -z "$CPP"; then | |
ac50fbac | 4232 | if ${ac_cv_prog_CPP+:} false; then : |
3185942a | 4233 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
4234 | else |
4235 | # Double quotes because CPP needs to be expanded | |
4236 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
4237 | do | |
4238 | ac_preproc_ok=false | |
4239 | for ac_c_preproc_warn_flag in '' yes | |
4240 | do | |
4241 | # Use a header file that comes with gcc, so configuring glibc | |
4242 | # with a fresh cross-compiler works. | |
0628567a JA |
4243 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
4244 | # <limits.h> exists even on freestanding compilers. | |
ccc6cda3 | 4245 | # On the NeXT, cc -E runs the code through the compiler's parser, |
f73dda09 | 4246 | # not just through cpp. "Syntax error" is here to catch this case. |
ac50fbac | 4247 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a JA |
4248 | /* end confdefs.h. */ |
4249 | #ifdef __STDC__ | |
4250 | # include <limits.h> | |
4251 | #else | |
4252 | # include <assert.h> | |
4253 | #endif | |
4254 | Syntax error | |
f73dda09 | 4255 | _ACEOF |
ac50fbac | 4256 | if ac_fn_c_try_cpp "$LINENO"; then : |
0628567a | 4257 | |
ac50fbac | 4258 | else |
f73dda09 JA |
4259 | # Broken: fails on valid input. |
4260 | continue | |
4261 | fi | |
ac50fbac | 4262 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4263 | |
3185942a | 4264 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4265 | # can be detected and how. |
ac50fbac | 4266 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4267 | /* end confdefs.h. */ |
f73dda09 JA |
4268 | #include <ac_nonexistent.h> |
4269 | _ACEOF | |
ac50fbac | 4270 | if ac_fn_c_try_cpp "$LINENO"; then : |
f73dda09 JA |
4271 | # Broken: success on invalid input. |
4272 | continue | |
bb70624e | 4273 | else |
f73dda09 JA |
4274 | # Passes both tests. |
4275 | ac_preproc_ok=: | |
4276 | break | |
4277 | fi | |
ac50fbac | 4278 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 JA |
4279 | |
4280 | done | |
4281 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
ac50fbac CR |
4282 | rm -f conftest.i conftest.err conftest.$ac_ext |
4283 | if $ac_preproc_ok; then : | |
f73dda09 JA |
4284 | break |
4285 | fi | |
4286 | ||
4287 | done | |
4288 | ac_cv_prog_CPP=$CPP | |
4289 | ||
4290 | fi | |
4291 | CPP=$ac_cv_prog_CPP | |
4292 | else | |
4293 | ac_cv_prog_CPP=$CPP | |
4294 | fi | |
ac50fbac | 4295 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
3185942a | 4296 | $as_echo "$CPP" >&6; } |
f73dda09 JA |
4297 | ac_preproc_ok=false |
4298 | for ac_c_preproc_warn_flag in '' yes | |
4299 | do | |
4300 | # Use a header file that comes with gcc, so configuring glibc | |
4301 | # with a fresh cross-compiler works. | |
0628567a JA |
4302 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
4303 | # <limits.h> exists even on freestanding compilers. | |
f73dda09 JA |
4304 | # On the NeXT, cc -E runs the code through the compiler's parser, |
4305 | # not just through cpp. "Syntax error" is here to catch this case. | |
ac50fbac | 4306 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a JA |
4307 | /* end confdefs.h. */ |
4308 | #ifdef __STDC__ | |
4309 | # include <limits.h> | |
4310 | #else | |
4311 | # include <assert.h> | |
4312 | #endif | |
4313 | Syntax error | |
f73dda09 | 4314 | _ACEOF |
ac50fbac | 4315 | if ac_fn_c_try_cpp "$LINENO"; then : |
0628567a | 4316 | |
ac50fbac | 4317 | else |
f73dda09 JA |
4318 | # Broken: fails on valid input. |
4319 | continue | |
4320 | fi | |
ac50fbac | 4321 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4322 | |
3185942a | 4323 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4324 | # can be detected and how. |
ac50fbac | 4325 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4326 | /* end confdefs.h. */ |
f73dda09 JA |
4327 | #include <ac_nonexistent.h> |
4328 | _ACEOF | |
ac50fbac | 4329 | if ac_fn_c_try_cpp "$LINENO"; then : |
f73dda09 JA |
4330 | # Broken: success on invalid input. |
4331 | continue | |
4332 | else | |
f73dda09 JA |
4333 | # Passes both tests. |
4334 | ac_preproc_ok=: | |
4335 | break | |
ccc6cda3 | 4336 | fi |
ac50fbac | 4337 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 JA |
4338 | |
4339 | done | |
4340 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
ac50fbac CR |
4341 | rm -f conftest.i conftest.err conftest.$ac_ext |
4342 | if $ac_preproc_ok; then : | |
4343 | ||
ccc6cda3 | 4344 | else |
ac50fbac | 4345 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3185942a | 4346 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
ac50fbac CR |
4347 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
4348 | See \`config.log' for more details" "$LINENO" 5; } | |
ccc6cda3 | 4349 | fi |
ccc6cda3 | 4350 | |
f73dda09 JA |
4351 | ac_ext=c |
4352 | ac_cpp='$CPP $CPPFLAGS' | |
4353 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4354 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4355 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4356 | ||
b80f6443 | 4357 | |
ac50fbac | 4358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
3185942a | 4359 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
ac50fbac | 4360 | if ${ac_cv_path_GREP+:} false; then : |
3185942a JA |
4361 | $as_echo_n "(cached) " >&6 |
4362 | else | |
4363 | if test -z "$GREP"; then | |
4364 | ac_path_GREP_found=false | |
4365 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4366 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4367 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4368 | do | |
4369 | IFS=$as_save_IFS | |
4370 | test -z "$as_dir" && as_dir=. | |
ac50fbac | 4371 | for ac_prog in grep ggrep; do |
3185942a JA |
4372 | for ac_exec_ext in '' $ac_executable_extensions; do |
4373 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
ac50fbac | 4374 | as_fn_executable_p "$ac_path_GREP" || continue |
3185942a JA |
4375 | # Check for GNU ac_path_GREP and select it if it is found. |
4376 | # Check for GNU $ac_path_GREP | |
4377 | case `"$ac_path_GREP" --version 2>&1` in | |
4378 | *GNU*) | |
4379 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
4380 | *) | |
4381 | ac_count=0 | |
4382 | $as_echo_n 0123456789 >"conftest.in" | |
4383 | while : | |
4384 | do | |
4385 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4386 | mv "conftest.tmp" "conftest.in" | |
4387 | cp "conftest.in" "conftest.nl" | |
4388 | $as_echo 'GREP' >> "conftest.nl" | |
4389 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4390 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
ac50fbac | 4391 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
3185942a JA |
4392 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
4393 | # Best one so far, save it but keep looking for a better one | |
4394 | ac_cv_path_GREP="$ac_path_GREP" | |
4395 | ac_path_GREP_max=$ac_count | |
4396 | fi | |
4397 | # 10*(2^10) chars as input seems more than enough | |
4398 | test $ac_count -gt 10 && break | |
4399 | done | |
4400 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4401 | esac | |
4402 | ||
4403 | $ac_path_GREP_found && break 3 | |
4404 | done | |
4405 | done | |
ac50fbac | 4406 | done |
3185942a JA |
4407 | IFS=$as_save_IFS |
4408 | if test -z "$ac_cv_path_GREP"; then | |
ac50fbac | 4409 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
3185942a JA |
4410 | fi |
4411 | else | |
4412 | ac_cv_path_GREP=$GREP | |
4413 | fi | |
4414 | ||
4415 | fi | |
ac50fbac | 4416 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
3185942a JA |
4417 | $as_echo "$ac_cv_path_GREP" >&6; } |
4418 | GREP="$ac_cv_path_GREP" | |
4419 | ||
4420 | ||
ac50fbac | 4421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
3185942a | 4422 | $as_echo_n "checking for egrep... " >&6; } |
ac50fbac | 4423 | if ${ac_cv_path_EGREP+:} false; then : |
3185942a | 4424 | $as_echo_n "(cached) " >&6 |
0628567a | 4425 | else |
3185942a JA |
4426 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
4427 | then ac_cv_path_EGREP="$GREP -E" | |
4428 | else | |
4429 | if test -z "$EGREP"; then | |
4430 | ac_path_EGREP_found=false | |
4431 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4432 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4433 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4434 | do | |
4435 | IFS=$as_save_IFS | |
4436 | test -z "$as_dir" && as_dir=. | |
ac50fbac | 4437 | for ac_prog in egrep; do |
3185942a JA |
4438 | for ac_exec_ext in '' $ac_executable_extensions; do |
4439 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
ac50fbac | 4440 | as_fn_executable_p "$ac_path_EGREP" || continue |
3185942a JA |
4441 | # Check for GNU ac_path_EGREP and select it if it is found. |
4442 | # Check for GNU $ac_path_EGREP | |
4443 | case `"$ac_path_EGREP" --version 2>&1` in | |
4444 | *GNU*) | |
4445 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
4446 | *) | |
4447 | ac_count=0 | |
4448 | $as_echo_n 0123456789 >"conftest.in" | |
4449 | while : | |
4450 | do | |
4451 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4452 | mv "conftest.tmp" "conftest.in" | |
4453 | cp "conftest.in" "conftest.nl" | |
4454 | $as_echo 'EGREP' >> "conftest.nl" | |
4455 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4456 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
ac50fbac | 4457 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
3185942a JA |
4458 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
4459 | # Best one so far, save it but keep looking for a better one | |
4460 | ac_cv_path_EGREP="$ac_path_EGREP" | |
4461 | ac_path_EGREP_max=$ac_count | |
0628567a | 4462 | fi |
3185942a JA |
4463 | # 10*(2^10) chars as input seems more than enough |
4464 | test $ac_count -gt 10 && break | |
4465 | done | |
4466 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4467 | esac | |
4468 | ||
4469 | $ac_path_EGREP_found && break 3 | |
4470 | done | |
4471 | done | |
ac50fbac | 4472 | done |
3185942a JA |
4473 | IFS=$as_save_IFS |
4474 | if test -z "$ac_cv_path_EGREP"; then | |
ac50fbac | 4475 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
3185942a JA |
4476 | fi |
4477 | else | |
4478 | ac_cv_path_EGREP=$EGREP | |
0628567a | 4479 | fi |
0628567a | 4480 | |
3185942a JA |
4481 | fi |
4482 | fi | |
ac50fbac | 4483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
3185942a JA |
4484 | $as_echo "$ac_cv_path_EGREP" >&6; } |
4485 | EGREP="$ac_cv_path_EGREP" | |
0628567a | 4486 | |
3185942a | 4487 | |
ac50fbac | 4488 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
3185942a | 4489 | $as_echo_n "checking for ANSI C header files... " >&6; } |
ac50fbac | 4490 | if ${ac_cv_header_stdc+:} false; then : |
3185942a | 4491 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 4492 | else |
ac50fbac | 4493 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4494 | /* end confdefs.h. */ |
b80f6443 JA |
4495 | #include <stdlib.h> |
4496 | #include <stdarg.h> | |
4497 | #include <string.h> | |
4498 | #include <float.h> | |
4499 | ||
0628567a JA |
4500 | int |
4501 | main () | |
4502 | { | |
4503 | ||
4504 | ; | |
4505 | return 0; | |
4506 | } | |
b80f6443 | 4507 | _ACEOF |
ac50fbac | 4508 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 JA |
4509 | ac_cv_header_stdc=yes |
4510 | else | |
ac50fbac | 4511 | ac_cv_header_stdc=no |
b80f6443 | 4512 | fi |
3185942a | 4513 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b80f6443 JA |
4514 | |
4515 | if test $ac_cv_header_stdc = yes; then | |
4516 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
ac50fbac | 4517 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4518 | /* end confdefs.h. */ |
b80f6443 JA |
4519 | #include <string.h> |
4520 | ||
4521 | _ACEOF | |
4522 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac CR |
4523 | $EGREP "memchr" >/dev/null 2>&1; then : |
4524 | ||
b80f6443 JA |
4525 | else |
4526 | ac_cv_header_stdc=no | |
4527 | fi | |
4528 | rm -f conftest* | |
4529 | ||
4530 | fi | |
4531 | ||
4532 | if test $ac_cv_header_stdc = yes; then | |
4533 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
ac50fbac | 4534 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4535 | /* end confdefs.h. */ |
b80f6443 JA |
4536 | #include <stdlib.h> |
4537 | ||
4538 | _ACEOF | |
4539 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac CR |
4540 | $EGREP "free" >/dev/null 2>&1; then : |
4541 | ||
b80f6443 JA |
4542 | else |
4543 | ac_cv_header_stdc=no | |
4544 | fi | |
4545 | rm -f conftest* | |
4546 | ||
4547 | fi | |
4548 | ||
4549 | if test $ac_cv_header_stdc = yes; then | |
4550 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
ac50fbac | 4551 | if test "$cross_compiling" = yes; then : |
b80f6443 JA |
4552 | : |
4553 | else | |
ac50fbac | 4554 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4555 | /* end confdefs.h. */ |
b80f6443 | 4556 | #include <ctype.h> |
3185942a | 4557 | #include <stdlib.h> |
b80f6443 JA |
4558 | #if ((' ' & 0x0FF) == 0x020) |
4559 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4560 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4561 | #else | |
0628567a JA |
4562 | # define ISLOWER(c) \ |
4563 | (('a' <= (c) && (c) <= 'i') \ | |
4564 | || ('j' <= (c) && (c) <= 'r') \ | |
4565 | || ('s' <= (c) && (c) <= 'z')) | |
b80f6443 JA |
4566 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
4567 | #endif | |
4568 | ||
4569 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
4570 | int | |
4571 | main () | |
4572 | { | |
4573 | int i; | |
4574 | for (i = 0; i < 256; i++) | |
4575 | if (XOR (islower (i), ISLOWER (i)) | |
0628567a | 4576 | || toupper (i) != TOUPPER (i)) |
3185942a JA |
4577 | return 2; |
4578 | return 0; | |
b80f6443 JA |
4579 | } |
4580 | _ACEOF | |
ac50fbac | 4581 | if ac_fn_c_try_run "$LINENO"; then : |
0628567a | 4582 | |
ac50fbac CR |
4583 | else |
4584 | ac_cv_header_stdc=no | |
b80f6443 | 4585 | fi |
ac50fbac CR |
4586 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
4587 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
b80f6443 | 4588 | fi |
3185942a | 4589 | |
b80f6443 JA |
4590 | fi |
4591 | fi | |
ac50fbac | 4592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
3185942a | 4593 | $as_echo "$ac_cv_header_stdc" >&6; } |
b80f6443 JA |
4594 | if test $ac_cv_header_stdc = yes; then |
4595 | ||
ac50fbac | 4596 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
b80f6443 JA |
4597 | |
4598 | fi | |
4599 | ||
4600 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. | |
ac50fbac CR |
4601 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
4602 | inttypes.h stdint.h unistd.h | |
4603 | do : | |
4604 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
4605 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
4606 | " | |
4607 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
4608 | cat >>confdefs.h <<_ACEOF | |
4609 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
4610 | _ACEOF | |
b80f6443 | 4611 | |
ac50fbac | 4612 | fi |
b80f6443 | 4613 | |
ac50fbac | 4614 | done |
b80f6443 JA |
4615 | |
4616 | ||
4617 | ||
ac50fbac CR |
4618 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
4619 | if test "x$ac_cv_header_minix_config_h" = xyes; then : | |
4620 | MINIX=yes | |
4621 | else | |
4622 | MINIX= | |
4623 | fi | |
b80f6443 JA |
4624 | |
4625 | ||
ac50fbac | 4626 | if test "$MINIX" = yes; then |
b80f6443 | 4627 | |
ac50fbac | 4628 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
b80f6443 | 4629 | |
b80f6443 | 4630 | |
ac50fbac | 4631 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
b80f6443 | 4632 | |
ccc6cda3 | 4633 | |
ac50fbac | 4634 | $as_echo "#define _MINIX 1" >>confdefs.h |
ccc6cda3 | 4635 | |
3185942a | 4636 | fi |
ccc6cda3 | 4637 | |
b80f6443 | 4638 | |
ac50fbac | 4639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
3185942a | 4640 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
ac50fbac | 4641 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
3185942a JA |
4642 | $as_echo_n "(cached) " >&6 |
4643 | else | |
ac50fbac | 4644 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a JA |
4645 | /* end confdefs.h. */ |
4646 | ||
ac50fbac CR |
4647 | # define __EXTENSIONS__ 1 |
4648 | $ac_includes_default | |
3185942a JA |
4649 | int |
4650 | main () | |
4651 | { | |
4652 | ||
4653 | ; | |
4654 | return 0; | |
4655 | } | |
4656 | _ACEOF | |
ac50fbac | 4657 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a JA |
4658 | ac_cv_safe_to_define___extensions__=yes |
4659 | else | |
ac50fbac | 4660 | ac_cv_safe_to_define___extensions__=no |
3185942a | 4661 | fi |
3185942a JA |
4662 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4663 | fi | |
ac50fbac | 4664 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
3185942a JA |
4665 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
4666 | test $ac_cv_safe_to_define___extensions__ = yes && | |
ac50fbac | 4667 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
3185942a | 4668 | |
ac50fbac | 4669 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
3185942a | 4670 | |
ac50fbac | 4671 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
3185942a | 4672 | |
ac50fbac CR |
4673 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
4674 | ||
4675 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
3185942a | 4676 | |
3185942a JA |
4677 | |
4678 | ||
4679 | ||
4680 | # Check whether --enable-largefile was given. | |
ac50fbac | 4681 | if test "${enable_largefile+set}" = set; then : |
3185942a JA |
4682 | enableval=$enable_largefile; |
4683 | fi | |
f73dda09 | 4684 | |
f73dda09 | 4685 | if test "$enable_largefile" != no; then |
ccc6cda3 | 4686 | |
ac50fbac | 4687 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 |
3185942a | 4688 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } |
ac50fbac | 4689 | if ${ac_cv_sys_largefile_CC+:} false; then : |
3185942a | 4690 | $as_echo_n "(cached) " >&6 |
bb70624e | 4691 | else |
f73dda09 JA |
4692 | ac_cv_sys_largefile_CC=no |
4693 | if test "$GCC" != yes; then | |
4694 | ac_save_CC=$CC | |
4695 | while :; do | |
3185942a JA |
4696 | # IRIX 6.2 and later do not support large files by default, |
4697 | # so use the C compiler's -n32 option if that helps. | |
ac50fbac | 4698 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4699 | /* end confdefs.h. */ |
f73dda09 JA |
4700 | #include <sys/types.h> |
4701 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4702 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4703 | since some C++ compilers masquerading as C compilers | |
4704 | incorrectly reject 9223372036854775807. */ | |
4705 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4706 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4707 | && LARGE_OFF_T % 2147483647 == 1) | |
4708 | ? 1 : -1]; | |
4709 | int | |
4710 | main () | |
4711 | { | |
bb70624e | 4712 | |
f73dda09 JA |
4713 | ; |
4714 | return 0; | |
4715 | } | |
4716 | _ACEOF | |
ac50fbac | 4717 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4718 | break |
f73dda09 | 4719 | fi |
3185942a JA |
4720 | rm -f core conftest.err conftest.$ac_objext |
4721 | CC="$CC -n32" | |
ac50fbac | 4722 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4723 | ac_cv_sys_largefile_CC=' -n32'; break |
f73dda09 | 4724 | fi |
3185942a | 4725 | rm -f core conftest.err conftest.$ac_objext |
0628567a | 4726 | break |
f73dda09 JA |
4727 | done |
4728 | CC=$ac_save_CC | |
4729 | rm -f conftest.$ac_ext | |
4730 | fi | |
bb70624e | 4731 | fi |
ac50fbac | 4732 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 |
3185942a | 4733 | $as_echo "$ac_cv_sys_largefile_CC" >&6; } |
f73dda09 JA |
4734 | if test "$ac_cv_sys_largefile_CC" != no; then |
4735 | CC=$CC$ac_cv_sys_largefile_CC | |
4736 | fi | |
bb70624e | 4737 | |
ac50fbac | 4738 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 |
3185942a | 4739 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } |
ac50fbac | 4740 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
3185942a | 4741 | $as_echo_n "(cached) " >&6 |
bb70624e | 4742 | else |
f73dda09 | 4743 | while :; do |
ac50fbac | 4744 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4745 | /* end confdefs.h. */ |
f73dda09 JA |
4746 | #include <sys/types.h> |
4747 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4748 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4749 | since some C++ compilers masquerading as C compilers | |
4750 | incorrectly reject 9223372036854775807. */ | |
4751 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4752 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4753 | && LARGE_OFF_T % 2147483647 == 1) | |
4754 | ? 1 : -1]; | |
4755 | int | |
4756 | main () | |
4757 | { | |
bb70624e | 4758 | |
f73dda09 JA |
4759 | ; |
4760 | return 0; | |
4761 | } | |
4762 | _ACEOF | |
ac50fbac | 4763 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 4764 | ac_cv_sys_file_offset_bits=no; break |
bb70624e | 4765 | fi |
3185942a | 4766 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ac50fbac | 4767 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4768 | /* end confdefs.h. */ |
f73dda09 JA |
4769 | #define _FILE_OFFSET_BITS 64 |
4770 | #include <sys/types.h> | |
4771 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4772 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4773 | since some C++ compilers masquerading as C compilers | |
4774 | incorrectly reject 9223372036854775807. */ | |
4775 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4776 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4777 | && LARGE_OFF_T % 2147483647 == 1) | |
4778 | ? 1 : -1]; | |
4779 | int | |
4780 | main () | |
4781 | { | |
bb70624e | 4782 | |
f73dda09 JA |
4783 | ; |
4784 | return 0; | |
4785 | } | |
4786 | _ACEOF | |
ac50fbac | 4787 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4788 | ac_cv_sys_file_offset_bits=64; break |
f73dda09 | 4789 | fi |
3185942a JA |
4790 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4791 | ac_cv_sys_file_offset_bits=unknown | |
f73dda09 JA |
4792 | break |
4793 | done | |
4794 | fi | |
ac50fbac | 4795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 |
3185942a JA |
4796 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } |
4797 | case $ac_cv_sys_file_offset_bits in #( | |
4798 | no | unknown) ;; | |
4799 | *) | |
b80f6443 | 4800 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4801 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits |
b80f6443 | 4802 | _ACEOF |
3185942a JA |
4803 | ;; |
4804 | esac | |
4805 | rm -rf conftest* | |
4806 | if test $ac_cv_sys_file_offset_bits = unknown; then | |
ac50fbac | 4807 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 |
3185942a | 4808 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } |
ac50fbac | 4809 | if ${ac_cv_sys_large_files+:} false; then : |
3185942a | 4810 | $as_echo_n "(cached) " >&6 |
bb70624e | 4811 | else |
f73dda09 | 4812 | while :; do |
ac50fbac | 4813 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4814 | /* end confdefs.h. */ |
f73dda09 JA |
4815 | #include <sys/types.h> |
4816 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4817 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4818 | since some C++ compilers masquerading as C compilers | |
4819 | incorrectly reject 9223372036854775807. */ | |
4820 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4821 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4822 | && LARGE_OFF_T % 2147483647 == 1) | |
4823 | ? 1 : -1]; | |
4824 | int | |
4825 | main () | |
4826 | { | |
4827 | ||
4828 | ; | |
4829 | return 0; | |
4830 | } | |
4831 | _ACEOF | |
ac50fbac | 4832 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 4833 | ac_cv_sys_large_files=no; break |
bb70624e | 4834 | fi |
3185942a | 4835 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ac50fbac | 4836 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4837 | /* end confdefs.h. */ |
f73dda09 JA |
4838 | #define _LARGE_FILES 1 |
4839 | #include <sys/types.h> | |
4840 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4841 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4842 | since some C++ compilers masquerading as C compilers | |
4843 | incorrectly reject 9223372036854775807. */ | |
4844 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4845 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4846 | && LARGE_OFF_T % 2147483647 == 1) | |
4847 | ? 1 : -1]; | |
4848 | int | |
4849 | main () | |
4850 | { | |
bb70624e | 4851 | |
f73dda09 JA |
4852 | ; |
4853 | return 0; | |
4854 | } | |
4855 | _ACEOF | |
ac50fbac | 4856 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4857 | ac_cv_sys_large_files=1; break |
f73dda09 | 4858 | fi |
3185942a JA |
4859 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4860 | ac_cv_sys_large_files=unknown | |
f73dda09 JA |
4861 | break |
4862 | done | |
4863 | fi | |
ac50fbac | 4864 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 |
3185942a JA |
4865 | $as_echo "$ac_cv_sys_large_files" >&6; } |
4866 | case $ac_cv_sys_large_files in #( | |
4867 | no | unknown) ;; | |
4868 | *) | |
b80f6443 | 4869 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4870 | #define _LARGE_FILES $ac_cv_sys_large_files |
b80f6443 | 4871 | _ACEOF |
3185942a JA |
4872 | ;; |
4873 | esac | |
4874 | rm -rf conftest* | |
4875 | fi | |
ac50fbac CR |
4876 | |
4877 | ||
f73dda09 | 4878 | fi |
cce855bc | 4879 | |
b80f6443 JA |
4880 | |
4881 | ||
0628567a | 4882 | SIGNAMES_O= |
b72432fd JA |
4883 | SIGNAMES_H=lsignames.h |
4884 | ||
b80f6443 JA |
4885 | |
4886 | ||
0628567a | 4887 | CROSS_COMPILE= |
cce855bc JA |
4888 | if test "x$cross_compiling" = "xyes"; then |
4889 | case "${host}" in | |
28ef6c31 | 4890 | *-cygwin*) |
cce855bc | 4891 | cross_cache=${srcdir}/cross-build/cygwin32.cache |
cce855bc | 4892 | ;; |
95732b49 JA |
4893 | *-mingw*) |
4894 | cross_cache=${srcdir}/cross-build/cygwin32.cache | |
4895 | ;; | |
b72432fd JA |
4896 | i[3456]86-*-beos*) |
4897 | cross_cache=${srcdir}/cross-build/x86-beos.cache | |
b72432fd JA |
4898 | ;; |
4899 | *) echo "configure: cross-compiling for $host is not supported" >&2 | |
cce855bc JA |
4900 | ;; |
4901 | esac | |
b72432fd JA |
4902 | if test -n "${cross_cache}" && test -r "${cross_cache}"; then |
4903 | echo "loading cross-build cache file ${cross_cache}" | |
4904 | . ${cross_cache} | |
4905 | fi | |
4906 | unset cross_cache | |
0628567a | 4907 | SIGNAMES_O='signames.o' |
95732b49 JA |
4908 | CROSS_COMPILE='-DCROSS_COMPILING' |
4909 | ||
cce855bc JA |
4910 | fi |
4911 | ||
b80f6443 | 4912 | |
0628567a | 4913 | |
b80f6443 | 4914 | |
ac50fbac CR |
4915 | CFLAGS=${CFLAGS-"$AUTO_CFLAGS"} |
4916 | # LDFLAGS=${LDFLAGS="$AUTO_LDFLAGS"} # XXX | |
ccc6cda3 | 4917 | |
a0c0a00f CR |
4918 | # turn off paren warnings in gcc |
4919 | if test "$GCC" = yes # && test -n "$DEBUG" | |
4920 | then | |
4921 | CFLAGS="$CFLAGS -Wno-parentheses -Wno-format-security" | |
4922 | fi | |
4923 | ||
cce855bc JA |
4924 | if test "$opt_profiling" = "yes"; then |
4925 | PROFILE_FLAGS=-pg | |
b72432fd JA |
4926 | case "$host_os" in |
4927 | solaris2*) ;; | |
4928 | *) opt_static_link=yes ;; | |
4929 | esac | |
7117c2d2 | 4930 | DEBUG= MALLOC_DEBUG= |
cce855bc JA |
4931 | fi |
4932 | ||
ac50fbac CR |
4933 | prefer_shared=yes |
4934 | prefer_static=no | |
4935 | ||
cce855bc | 4936 | if test "$opt_static_link" = yes; then |
ac50fbac CR |
4937 | prefer_static=yes |
4938 | prefer_shared=no | |
f73dda09 JA |
4939 | # if we're using gcc, add `-static' to LDFLAGS, except on Solaris >= 2 |
4940 | if test -n "$GCC" || test "$ac_cv_c_compiler_gnu" = "yes"; then | |
b72432fd | 4941 | STATIC_LD="-static" |
f73dda09 JA |
4942 | case "$host_os" in |
4943 | solaris2*) ;; | |
4944 | *) LDFLAGS="$LDFLAGS -static" ;; # XXX experimental | |
4945 | esac | |
cce855bc JA |
4946 | fi |
4947 | fi | |
4948 | ||
ac50fbac CR |
4949 | # set the appropriate make variables for building the "build tools" |
4950 | # modify defaults based on whether or not we are cross compiling, since the | |
4951 | # options for the target host may not be appropriate for the build host | |
b80f6443 | 4952 | if test "X$cross_compiling" = "Xno"; then |
ac50fbac CR |
4953 | CC_FOR_BUILD=${CC_FOR_BUILD-'$(CC)'} |
4954 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-"$CPPFLAGS"} # XXX - should it be '$(CPPFLAGS)' | |
b80f6443 | 4955 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-'$(LDFLAGS)'} |
ac50fbac CR |
4956 | # CFLAGS set above to default value if not passed in environment |
4957 | CFLAGS_FOR_BUILD=${CFLAGS-'$(CFLAGS)'} | |
4958 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-'$(LIBS)'} | |
b80f6443 | 4959 | else |
ac50fbac | 4960 | CC_FOR_BUILD=${CC_FOR_BUILD-"gcc"} |
b80f6443 JA |
4961 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-""} |
4962 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-""} | |
ac50fbac CR |
4963 | CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD="-g"} |
4964 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-""} | |
b80f6443 JA |
4965 | fi |
4966 | ||
ac50fbac | 4967 | |
7117c2d2 | 4968 | |
b80f6443 JA |
4969 | |
4970 | ||
4971 | ||
4972 | ||
4973 | ||
4974 | ||
4975 | ||
4976 | ||
4977 | ||
f73dda09 | 4978 | if test $ac_cv_c_compiler_gnu = yes; then |
ac50fbac | 4979 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 |
3185942a | 4980 | $as_echo_n "checking whether $CC needs -traditional... " >&6; } |
ac50fbac | 4981 | if ${ac_cv_prog_gcc_traditional+:} false; then : |
3185942a | 4982 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
4983 | else |
4984 | ac_pattern="Autoconf.*'x'" | |
ac50fbac | 4985 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 4986 | /* end confdefs.h. */ |
ccc6cda3 JA |
4987 | #include <sgtty.h> |
4988 | Autoconf TIOCGETP | |
f73dda09 | 4989 | _ACEOF |
ccc6cda3 | 4990 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
ac50fbac | 4991 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
4992 | ac_cv_prog_gcc_traditional=yes |
4993 | else | |
ccc6cda3 JA |
4994 | ac_cv_prog_gcc_traditional=no |
4995 | fi | |
4996 | rm -f conftest* | |
4997 | ||
b80f6443 | 4998 | |
ccc6cda3 | 4999 | if test $ac_cv_prog_gcc_traditional = no; then |
ac50fbac | 5000 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5001 | /* end confdefs.h. */ |
ccc6cda3 JA |
5002 | #include <termio.h> |
5003 | Autoconf TCGETA | |
f73dda09 | 5004 | _ACEOF |
ccc6cda3 | 5005 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
ac50fbac | 5006 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
5007 | ac_cv_prog_gcc_traditional=yes |
5008 | fi | |
5009 | rm -f conftest* | |
5010 | ||
5011 | fi | |
5012 | fi | |
ac50fbac | 5013 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 |
3185942a | 5014 | $as_echo "$ac_cv_prog_gcc_traditional" >&6; } |
ccc6cda3 JA |
5015 | if test $ac_cv_prog_gcc_traditional = yes; then |
5016 | CC="$CC -traditional" | |
5017 | fi | |
5018 | fi | |
5019 | ||
b80f6443 JA |
5020 | |
5021 | ||
f73dda09 | 5022 | if test "$opt_readline" = yes && test "$opt_with_installed_readline" != "no" |
b72432fd | 5023 | then |
f73dda09 JA |
5024 | # If the user specified --with-installed-readline=PREFIX and PREFIX |
5025 | # is not `yes', set ac_cv_rl_prefix to PREFIX | |
5026 | test $opt_with_installed_readline != "yes" && ac_cv_rl_prefix=$opt_with_installed_readline | |
b72432fd | 5027 | |
b80f6443 | 5028 | |
bb70624e JA |
5029 | if test "X$bash_cv_termcap_lib" = "X"; then |
5030 | _bash_needmsg=yes | |
5031 | else | |
ac50fbac | 5032 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
3185942a | 5033 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e JA |
5034 | _bash_needmsg= |
5035 | fi | |
ac50fbac | 5036 | if ${bash_cv_termcap_lib+:} false; then : |
3185942a | 5037 | $as_echo_n "(cached) " >&6 |
bb70624e | 5038 | else |
ac50fbac CR |
5039 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" |
5040 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
5041 | bash_cv_termcap_lib=libc | |
5042 | else | |
5043 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 | |
5044 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } | |
5045 | if ${ac_cv_lib_termcap_tgetent+:} false; then : | |
3185942a | 5046 | $as_echo_n "(cached) " >&6 |
b80f6443 | 5047 | else |
ac50fbac CR |
5048 | ac_check_lib_save_LIBS=$LIBS |
5049 | LIBS="-ltermcap $LIBS" | |
5050 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 5051 | /* end confdefs.h. */ |
0628567a | 5052 | |
3185942a JA |
5053 | /* Override any GCC internal prototype to avoid an error. |
5054 | Use char because int might match the return type of a GCC | |
5055 | builtin and then its argument prototype would still apply. */ | |
b80f6443 JA |
5056 | #ifdef __cplusplus |
5057 | extern "C" | |
b80f6443 | 5058 | #endif |
b80f6443 | 5059 | char tgetent (); |
0628567a JA |
5060 | int |
5061 | main () | |
5062 | { | |
3185942a | 5063 | return tgetent (); |
b80f6443 JA |
5064 | ; |
5065 | return 0; | |
5066 | } | |
5067 | _ACEOF | |
ac50fbac CR |
5068 | if ac_fn_c_try_link "$LINENO"; then : |
5069 | ac_cv_lib_termcap_tgetent=yes | |
b80f6443 | 5070 | else |
ac50fbac | 5071 | ac_cv_lib_termcap_tgetent=no |
b80f6443 | 5072 | fi |
ac50fbac CR |
5073 | rm -f core conftest.err conftest.$ac_objext \ |
5074 | conftest$ac_exeext conftest.$ac_ext | |
5075 | LIBS=$ac_check_lib_save_LIBS | |
b80f6443 | 5076 | fi |
ac50fbac | 5077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
3185942a | 5078 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } |
ac50fbac | 5079 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : |
bb70624e JA |
5080 | bash_cv_termcap_lib=libtermcap |
5081 | else | |
ac50fbac | 5082 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
3185942a | 5083 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } |
ac50fbac | 5084 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : |
3185942a | 5085 | $as_echo_n "(cached) " >&6 |
bb70624e | 5086 | else |
f73dda09 JA |
5087 | ac_check_lib_save_LIBS=$LIBS |
5088 | LIBS="-ltinfo $LIBS" | |
ac50fbac | 5089 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5090 | /* end confdefs.h. */ |
f73dda09 | 5091 | |
3185942a JA |
5092 | /* Override any GCC internal prototype to avoid an error. |
5093 | Use char because int might match the return type of a GCC | |
5094 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5095 | #ifdef __cplusplus |
5096 | extern "C" | |
5097 | #endif | |
f73dda09 JA |
5098 | char tgetent (); |
5099 | int | |
5100 | main () | |
5101 | { | |
3185942a | 5102 | return tgetent (); |
f73dda09 JA |
5103 | ; |
5104 | return 0; | |
5105 | } | |
5106 | _ACEOF | |
ac50fbac | 5107 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5108 | ac_cv_lib_tinfo_tgetent=yes |
5109 | else | |
ac50fbac | 5110 | ac_cv_lib_tinfo_tgetent=no |
f73dda09 | 5111 | fi |
ac50fbac CR |
5112 | rm -f core conftest.err conftest.$ac_objext \ |
5113 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5114 | LIBS=$ac_check_lib_save_LIBS |
5115 | fi | |
ac50fbac | 5116 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
3185942a | 5117 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
ac50fbac | 5118 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
7117c2d2 | 5119 | bash_cv_termcap_lib=libtinfo |
f73dda09 | 5120 | else |
ac50fbac | 5121 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
3185942a | 5122 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
ac50fbac | 5123 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
3185942a | 5124 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5125 | else |
5126 | ac_check_lib_save_LIBS=$LIBS | |
5127 | LIBS="-lcurses $LIBS" | |
ac50fbac | 5128 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5129 | /* end confdefs.h. */ |
b72432fd | 5130 | |
3185942a JA |
5131 | /* Override any GCC internal prototype to avoid an error. |
5132 | Use char because int might match the return type of a GCC | |
5133 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5134 | #ifdef __cplusplus |
5135 | extern "C" | |
5136 | #endif | |
f73dda09 JA |
5137 | char tgetent (); |
5138 | int | |
5139 | main () | |
5140 | { | |
3185942a | 5141 | return tgetent (); |
f73dda09 JA |
5142 | ; |
5143 | return 0; | |
5144 | } | |
5145 | _ACEOF | |
ac50fbac | 5146 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5147 | ac_cv_lib_curses_tgetent=yes |
5148 | else | |
ac50fbac | 5149 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 5150 | fi |
ac50fbac CR |
5151 | rm -f core conftest.err conftest.$ac_objext \ |
5152 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5153 | LIBS=$ac_check_lib_save_LIBS |
5154 | fi | |
ac50fbac | 5155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
3185942a | 5156 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
ac50fbac | 5157 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
bb70624e JA |
5158 | bash_cv_termcap_lib=libcurses |
5159 | else | |
ac50fbac | 5160 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
3185942a | 5161 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
ac50fbac | 5162 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
3185942a | 5163 | $as_echo_n "(cached) " >&6 |
bb70624e | 5164 | else |
f73dda09 | 5165 | ac_check_lib_save_LIBS=$LIBS |
bb70624e | 5166 | LIBS="-lncurses $LIBS" |
ac50fbac | 5167 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5168 | /* end confdefs.h. */ |
f73dda09 | 5169 | |
3185942a JA |
5170 | /* Override any GCC internal prototype to avoid an error. |
5171 | Use char because int might match the return type of a GCC | |
5172 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5173 | #ifdef __cplusplus |
5174 | extern "C" | |
5175 | #endif | |
f73dda09 JA |
5176 | char tgetent (); |
5177 | int | |
5178 | main () | |
5179 | { | |
3185942a | 5180 | return tgetent (); |
f73dda09 JA |
5181 | ; |
5182 | return 0; | |
5183 | } | |
5184 | _ACEOF | |
ac50fbac | 5185 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5186 | ac_cv_lib_ncurses_tgetent=yes |
5187 | else | |
ac50fbac | 5188 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 5189 | fi |
ac50fbac CR |
5190 | rm -f core conftest.err conftest.$ac_objext \ |
5191 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5192 | LIBS=$ac_check_lib_save_LIBS |
5193 | fi | |
ac50fbac | 5194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
3185942a | 5195 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
ac50fbac | 5196 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 5197 | bash_cv_termcap_lib=libncurses |
bb70624e | 5198 | else |
f73dda09 | 5199 | bash_cv_termcap_lib=gnutermcap |
bb70624e | 5200 | fi |
bb70624e | 5201 | |
bb70624e JA |
5202 | fi |
5203 | ||
5204 | fi | |
5205 | ||
5206 | fi | |
5207 | ||
5208 | fi | |
5209 | ||
b80f6443 JA |
5210 | fi |
5211 | ||
bb70624e | 5212 | if test "X$_bash_needmsg" = "Xyes"; then |
ac50fbac | 5213 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
3185942a | 5214 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e | 5215 | fi |
ac50fbac | 5216 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
3185942a | 5217 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
bb70624e JA |
5218 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
5219 | LDFLAGS="$LDFLAGS -L./lib/termcap" | |
5220 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
5221 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
5222 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then | |
5223 | TERMCAP_LIB=-ltermcap | |
5224 | TERMCAP_DEP= | |
f73dda09 JA |
5225 | elif test $bash_cv_termcap_lib = libtinfo; then |
5226 | TERMCAP_LIB=-ltinfo | |
5227 | TERMCAP_DEP= | |
bb70624e JA |
5228 | elif test $bash_cv_termcap_lib = libncurses; then |
5229 | TERMCAP_LIB=-lncurses | |
5230 | TERMCAP_DEP= | |
b80f6443 JA |
5231 | elif test $bash_cv_termcap_lib = libc; then |
5232 | TERMCAP_LIB= | |
5233 | TERMCAP_DEP= | |
bb70624e JA |
5234 | else |
5235 | TERMCAP_LIB=-lcurses | |
5236 | TERMCAP_DEP= | |
5237 | fi | |
5238 | ||
b80f6443 JA |
5239 | |
5240 | ||
5241 | ||
ac50fbac | 5242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of installed readline library" >&5 |
3185942a | 5243 | $as_echo_n "checking version of installed readline library... " >&6; } |
f73dda09 JA |
5244 | |
5245 | # What a pain in the ass this is. | |
5246 | ||
5247 | # save cpp and ld options | |
5248 | _save_CFLAGS="$CFLAGS" | |
5249 | _save_LDFLAGS="$LDFLAGS" | |
5250 | _save_LIBS="$LIBS" | |
5251 | ||
5252 | # Don't set ac_cv_rl_prefix if the caller has already assigned a value. This | |
5253 | # allows the caller to do something like $_rl_prefix=$withval if the user | |
5254 | # specifies --with-installed-readline=PREFIX as an argument to configure | |
5255 | ||
5256 | if test -z "$ac_cv_rl_prefix"; then | |
5257 | test "x$prefix" = xNONE && ac_cv_rl_prefix=$ac_default_prefix || ac_cv_rl_prefix=${prefix} | |
5258 | fi | |
5259 | ||
5260 | eval ac_cv_rl_includedir=${ac_cv_rl_prefix}/include | |
5261 | eval ac_cv_rl_libdir=${ac_cv_rl_prefix}/lib | |
5262 | ||
5263 | LIBS="$LIBS -lreadline ${TERMCAP_LIB}" | |
5264 | CFLAGS="$CFLAGS -I${ac_cv_rl_includedir}" | |
5265 | LDFLAGS="$LDFLAGS -L${ac_cv_rl_libdir}" | |
5266 | ||
ac50fbac | 5267 | if ${ac_cv_rl_version+:} false; then : |
3185942a | 5268 | $as_echo_n "(cached) " >&6 |
b80f6443 | 5269 | else |
ac50fbac | 5270 | if test "$cross_compiling" = yes; then : |
a0c0a00f | 5271 | ac_cv_rl_version='6.3' |
f73dda09 | 5272 | else |
ac50fbac | 5273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5274 | /* end confdefs.h. */ |
f73dda09 JA |
5275 | |
5276 | #include <stdio.h> | |
5277 | #include <readline/readline.h> | |
5278 | ||
95732b49 JA |
5279 | extern int rl_gnu_readline_p; |
5280 | ||
f73dda09 JA |
5281 | main() |
5282 | { | |
5283 | FILE *fp; | |
5284 | fp = fopen("conftest.rlv", "w"); | |
95732b49 JA |
5285 | if (fp == 0) |
5286 | exit(1); | |
5287 | if (rl_gnu_readline_p != 1) | |
5288 | fprintf(fp, "0.0\n"); | |
5289 | else | |
5290 | fprintf(fp, "%s\n", rl_library_version ? rl_library_version : "0.0"); | |
f73dda09 JA |
5291 | fclose(fp); |
5292 | exit(0); | |
5293 | } | |
5294 | ||
5295 | _ACEOF | |
ac50fbac | 5296 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
5297 | ac_cv_rl_version=`cat conftest.rlv` |
5298 | else | |
ac50fbac | 5299 | ac_cv_rl_version='0.0' |
f73dda09 | 5300 | fi |
ac50fbac CR |
5301 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
5302 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 5303 | fi |
3185942a | 5304 | |
b80f6443 JA |
5305 | fi |
5306 | ||
f73dda09 JA |
5307 | |
5308 | CFLAGS="$_save_CFLAGS" | |
5309 | LDFLAGS="$_save_LDFLAGS" | |
5310 | LIBS="$_save_LIBS" | |
5311 | ||
5312 | RL_MAJOR=0 | |
5313 | RL_MINOR=0 | |
5314 | ||
5315 | # ( | |
5316 | case "$ac_cv_rl_version" in | |
5317 | 2*|3*|4*|5*|6*|7*|8*|9*) | |
5318 | RL_MAJOR=`echo $ac_cv_rl_version | sed 's:\..*$::'` | |
7117c2d2 | 5319 | RL_MINOR=`echo $ac_cv_rl_version | sed -e 's:^.*\.::' -e 's:[a-zA-Z]*$::'` |
f73dda09 JA |
5320 | ;; |
5321 | esac | |
5322 | ||
5323 | # ((( | |
5324 | case $RL_MAJOR in | |
5325 | [0-9][0-9]) _RL_MAJOR=$RL_MAJOR ;; | |
5326 | [0-9]) _RL_MAJOR=0$RL_MAJOR ;; | |
5327 | *) _RL_MAJOR=00 ;; | |
5328 | esac | |
5329 | ||
5330 | # ((( | |
5331 | case $RL_MINOR in | |
5332 | [0-9][0-9]) _RL_MINOR=$RL_MINOR ;; | |
5333 | [0-9]) _RL_MINOR=0$RL_MINOR ;; | |
5334 | *) _RL_MINOR=00 ;; | |
5335 | esac | |
5336 | ||
5337 | RL_VERSION="0x${_RL_MAJOR}${_RL_MINOR}" | |
5338 | ||
5339 | # Readline versions greater than 4.2 have these defines in readline.h | |
5340 | ||
5341 | if test $ac_cv_rl_version = '0.0' ; then | |
ac50fbac | 5342 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not test version of installed readline library." >&5 |
3185942a | 5343 | $as_echo "$as_me: WARNING: Could not test version of installed readline library." >&2;} |
f73dda09 JA |
5344 | elif test $RL_MAJOR -gt 4 || { test $RL_MAJOR = 4 && test $RL_MINOR -gt 2 ; } ; then |
5345 | # set these for use by the caller | |
5346 | RL_PREFIX=$ac_cv_rl_prefix | |
5347 | RL_LIBDIR=$ac_cv_rl_libdir | |
5348 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
ac50fbac | 5349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
3185942a | 5350 | $as_echo "$ac_cv_rl_version" >&6; } |
f73dda09 JA |
5351 | else |
5352 | ||
b80f6443 JA |
5353 | |
5354 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5355 | #define RL_READLINE_VERSION $RL_VERSION |
b80f6443 | 5356 | _ACEOF |
f73dda09 | 5357 | |
b80f6443 JA |
5358 | |
5359 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5360 | #define RL_VERSION_MAJOR $RL_MAJOR |
b80f6443 | 5361 | _ACEOF |
f73dda09 | 5362 | |
b80f6443 JA |
5363 | |
5364 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5365 | #define RL_VERSION_MINOR $RL_MINOR |
b80f6443 JA |
5366 | _ACEOF |
5367 | ||
5368 | ||
5369 | ||
5370 | ||
5371 | ||
f73dda09 JA |
5372 | |
5373 | # set these for use by the caller | |
5374 | RL_PREFIX=$ac_cv_rl_prefix | |
5375 | RL_LIBDIR=$ac_cv_rl_libdir | |
5376 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
bb70624e | 5377 | |
ac50fbac | 5378 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
3185942a | 5379 | $as_echo "$ac_cv_rl_version" >&6; } |
bb70624e | 5380 | |
f73dda09 | 5381 | fi |
bb70624e | 5382 | |
b80f6443 | 5383 | |
f73dda09 | 5384 | case "$ac_cv_rl_version" in |
b80f6443 | 5385 | 5*|6*|7*|8*|9*) ;; |
f73dda09 | 5386 | *) opt_with_installed_readline=no |
ac50fbac | 5387 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: installed readline library is too old to be linked with bash" >&5 |
3185942a | 5388 | $as_echo "$as_me: WARNING: installed readline library is too old to be linked with bash" >&2;} |
ac50fbac | 5389 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using private bash version" >&5 |
3185942a | 5390 | $as_echo "$as_me: WARNING: using private bash version" >&2;} |
bb70624e JA |
5391 | ;; |
5392 | esac | |
bb70624e JA |
5393 | fi |
5394 | ||
95732b49 | 5395 | TILDE_LIB=-ltilde |
bb70624e | 5396 | if test $opt_readline = yes; then |
ac50fbac | 5397 | $as_echo "#define READLINE 1" >>confdefs.h |
bb70624e | 5398 | |
f73dda09 | 5399 | if test "$opt_with_installed_readline" != "no" ; then |
b80f6443 JA |
5400 | case "$opt_with_installed_readline" in |
5401 | yes) RL_INCLUDE= ;; | |
5402 | *) case "$RL_INCLUDEDIR" in | |
5403 | /usr/include) ;; | |
5404 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5405 | esac | |
5406 | ;; | |
f73dda09 | 5407 | esac |
bb70624e | 5408 | READLINE_DEP= |
95732b49 JA |
5409 | READLINE_LIB=-lreadline |
5410 | # section for OS versions that don't allow unresolved symbols | |
5411 | # to be compiled into dynamic libraries. | |
5412 | case "$host_os" in | |
5413 | cygwin*) TILDE_LIB= ;; | |
5414 | esac | |
bb70624e JA |
5415 | else |
5416 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5417 | READLINE_DEP='$(READLINE_LIBRARY)' | |
95732b49 JA |
5418 | # section for OS versions that ship an older/broken version of |
5419 | # readline as a standard dynamic library and don't allow a | |
5420 | # static version specified as -llibname to override the | |
5421 | # dynamic version | |
5422 | case "${host_os}" in | |
89a92869 | 5423 | darwin[89]*|darwin10*) READLINE_LIB='${READLINE_LIBRARY}' ;; |
95732b49 JA |
5424 | *) READLINE_LIB=-lreadline ;; |
5425 | esac | |
bb70624e JA |
5426 | fi |
5427 | else | |
5428 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5429 | READLINE_LIB= READLINE_DEP= | |
5430 | fi | |
5431 | if test $opt_history = yes || test $opt_bang_history = yes; then | |
5432 | if test $opt_history = yes; then | |
ac50fbac | 5433 | $as_echo "#define HISTORY 1" >>confdefs.h |
bb70624e JA |
5434 | |
5435 | fi | |
5436 | if test $opt_bang_history = yes; then | |
ac50fbac | 5437 | $as_echo "#define BANG_HISTORY 1" >>confdefs.h |
b72432fd JA |
5438 | |
5439 | fi | |
f73dda09 JA |
5440 | if test "$opt_with_installed_readline" != "no"; then |
5441 | HIST_LIBDIR=$RL_LIBDIR | |
b72432fd | 5442 | HISTORY_DEP= |
95732b49 | 5443 | HISTORY_LIB=-lhistory |
b80f6443 JA |
5444 | case "$opt_with_installed_readline" in |
5445 | yes) RL_INCLUDE= ;; | |
5446 | *) case "$RL_INCLUDEDIR" in | |
5447 | /usr/include) ;; | |
5448 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5449 | esac | |
5450 | ;; | |
f73dda09 | 5451 | esac |
b72432fd JA |
5452 | else |
5453 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5454 | HISTORY_DEP='$(HISTORY_LIBRARY)' | |
95732b49 JA |
5455 | # section for OS versions that ship an older version of |
5456 | # readline as a standard dynamic library and don't allow a | |
5457 | # static version specified as -llibname to override the | |
5458 | # dynamic version | |
5459 | case "${host_os}" in | |
89a92869 | 5460 | darwin[89]*|darwin10*) HISTORY_LIB='${HISTORY_LIBRARY}' ;; |
95732b49 JA |
5461 | *) HISTORY_LIB=-lhistory ;; |
5462 | esac | |
b72432fd JA |
5463 | fi |
5464 | else | |
5465 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5466 | HISTORY_LIB= HISTORY_DEP= | |
5467 | fi | |
5468 | ||
b80f6443 JA |
5469 | |
5470 | ||
5471 | ||
5472 | ||
5473 | ||
5474 | ||
5475 | ||
5476 | ||
5477 | ||
95732b49 | 5478 | |
ccc6cda3 JA |
5479 | # Find a good install program. We prefer a C program (faster), |
5480 | # so one script is as good as another. But avoid the broken or | |
5481 | # incompatible versions: | |
5482 | # SysV /etc/install, /usr/sbin/install | |
5483 | # SunOS /usr/etc/install | |
5484 | # IRIX /sbin/install | |
5485 | # AIX /bin/install | |
f73dda09 | 5486 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
bb70624e | 5487 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
ccc6cda3 JA |
5488 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
5489 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
0628567a | 5490 | # OS/2's system install, which has a completely different semantic |
ccc6cda3 | 5491 | # ./install, which can be erroneously created by make from ./install.sh. |
3185942a | 5492 | # Reject install programs that cannot install multiple files. |
ac50fbac | 5493 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
3185942a | 5494 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
ccc6cda3 | 5495 | if test -z "$INSTALL"; then |
ac50fbac | 5496 | if ${ac_cv_path_install+:} false; then : |
3185942a | 5497 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5498 | else |
b80f6443 JA |
5499 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5500 | for as_dir in $PATH | |
5501 | do | |
5502 | IFS=$as_save_IFS | |
5503 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
5504 | # Account for people who put trailing slashes in PATH elements. |
5505 | case $as_dir/ in #(( | |
5506 | ./ | .// | /[cC]/* | \ | |
b80f6443 | 5507 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
ac50fbac | 5508 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
b80f6443 JA |
5509 | /usr/ucb/* ) ;; |
5510 | *) | |
5511 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
5512 | # Don't use installbsd from OSF since it installs stuff as root | |
5513 | # by default. | |
5514 | for ac_prog in ginstall scoinst install; do | |
5515 | for ac_exec_ext in '' $ac_executable_extensions; do | |
ac50fbac | 5516 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then |
0628567a JA |
5517 | if test $ac_prog = install && |
5518 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5519 | # AIX install. It has an incompatible calling convention. | |
5520 | : | |
5521 | elif test $ac_prog = install && | |
5522 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5523 | # program-specific install script used by HP pwplus--don't use. | |
5524 | : | |
5525 | else | |
3185942a JA |
5526 | rm -rf conftest.one conftest.two conftest.dir |
5527 | echo one > conftest.one | |
5528 | echo two > conftest.two | |
5529 | mkdir conftest.dir | |
5530 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
5531 | test -s conftest.one && test -s conftest.two && | |
5532 | test -s conftest.dir/conftest.one && | |
5533 | test -s conftest.dir/conftest.two | |
5534 | then | |
5535 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
5536 | break 3 | |
5537 | fi | |
0628567a JA |
5538 | fi |
5539 | fi | |
ccc6cda3 | 5540 | done |
b80f6443 JA |
5541 | done |
5542 | ;; | |
5543 | esac | |
3185942a | 5544 | |
ac50fbac | 5545 | done |
3185942a | 5546 | IFS=$as_save_IFS |
b80f6443 | 5547 | |
3185942a | 5548 | rm -rf conftest.one conftest.two conftest.dir |
ccc6cda3 JA |
5549 | |
5550 | fi | |
5551 | if test "${ac_cv_path_install+set}" = set; then | |
f73dda09 | 5552 | INSTALL=$ac_cv_path_install |
ccc6cda3 | 5553 | else |
3185942a JA |
5554 | # As a last resort, use the slow shell script. Don't cache a |
5555 | # value for INSTALL within a source directory, because that will | |
ccc6cda3 | 5556 | # break other packages using the cache if that directory is |
3185942a | 5557 | # removed, or if the value is a relative name. |
f73dda09 | 5558 | INSTALL=$ac_install_sh |
ccc6cda3 JA |
5559 | fi |
5560 | fi | |
ac50fbac | 5561 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
3185942a | 5562 | $as_echo "$INSTALL" >&6; } |
ccc6cda3 JA |
5563 | |
5564 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
5565 | # It thinks the first close brace ends the variable substitution. | |
5566 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
5567 | ||
f73dda09 | 5568 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
bb70624e | 5569 | |
ccc6cda3 JA |
5570 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
5571 | ||
ac50fbac CR |
5572 | if test -n "$ac_tool_prefix"; then |
5573 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
5574 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
5575 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3185942a | 5576 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 5577 | if ${ac_cv_prog_AR+:} false; then : |
3185942a | 5578 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5579 | else |
5580 | if test -n "$AR"; then | |
5581 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
5582 | else | |
b80f6443 JA |
5583 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5584 | for as_dir in $PATH | |
5585 | do | |
5586 | IFS=$as_save_IFS | |
5587 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
5588 | for ac_exec_ext in '' $ac_executable_extensions; do |
5589 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
5590 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
5591 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
b80f6443 JA |
5592 | break 2 |
5593 | fi | |
5594 | done | |
ac50fbac | 5595 | done |
3185942a | 5596 | IFS=$as_save_IFS |
f73dda09 | 5597 | |
ccc6cda3 JA |
5598 | fi |
5599 | fi | |
f73dda09 | 5600 | AR=$ac_cv_prog_AR |
ccc6cda3 | 5601 | if test -n "$AR"; then |
ac50fbac | 5602 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
3185942a | 5603 | $as_echo "$AR" >&6; } |
ccc6cda3 | 5604 | else |
ac50fbac CR |
5605 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
5606 | $as_echo "no" >&6; } | |
5607 | fi | |
5608 | ||
5609 | ||
5610 | fi | |
5611 | if test -z "$ac_cv_prog_AR"; then | |
5612 | ac_ct_AR=$AR | |
5613 | # Extract the first word of "ar", so it can be a program name with args. | |
5614 | set dummy ar; ac_word=$2 | |
5615 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5616 | $as_echo_n "checking for $ac_word... " >&6; } | |
5617 | if ${ac_cv_prog_ac_ct_AR+:} false; then : | |
5618 | $as_echo_n "(cached) " >&6 | |
5619 | else | |
5620 | if test -n "$ac_ct_AR"; then | |
5621 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
5622 | else | |
5623 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5624 | for as_dir in $PATH | |
5625 | do | |
5626 | IFS=$as_save_IFS | |
5627 | test -z "$as_dir" && as_dir=. | |
5628 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5629 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
5630 | ac_cv_prog_ac_ct_AR="ar" | |
5631 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5632 | break 2 | |
5633 | fi | |
5634 | done | |
5635 | done | |
5636 | IFS=$as_save_IFS | |
5637 | ||
5638 | fi | |
5639 | fi | |
5640 | ac_ct_AR=$ac_cv_prog_ac_ct_AR | |
5641 | if test -n "$ac_ct_AR"; then | |
5642 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 | |
5643 | $as_echo "$ac_ct_AR" >&6; } | |
5644 | else | |
5645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3185942a | 5646 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5647 | fi |
5648 | ||
ac50fbac CR |
5649 | if test "x$ac_ct_AR" = x; then |
5650 | AR="" | |
5651 | else | |
5652 | case $cross_compiling:$ac_tool_warned in | |
5653 | yes:) | |
5654 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
5655 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
5656 | ac_tool_warned=yes ;; | |
5657 | esac | |
5658 | AR=$ac_ct_AR | |
5659 | fi | |
5660 | else | |
5661 | AR="$ac_cv_prog_AR" | |
5662 | fi | |
3185942a | 5663 | |
b72432fd | 5664 | test -n "$ARFLAGS" || ARFLAGS="cr" |
f73dda09 JA |
5665 | if test -n "$ac_tool_prefix"; then |
5666 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
5667 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
ac50fbac | 5668 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 5669 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 5670 | if ${ac_cv_prog_RANLIB+:} false; then : |
3185942a | 5671 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5672 | else |
5673 | if test -n "$RANLIB"; then | |
5674 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
5675 | else | |
b80f6443 JA |
5676 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5677 | for as_dir in $PATH | |
5678 | do | |
5679 | IFS=$as_save_IFS | |
5680 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
5681 | for ac_exec_ext in '' $ac_executable_extensions; do |
5682 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 5683 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
ac50fbac | 5684 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
5685 | break 2 |
5686 | fi | |
5687 | done | |
ac50fbac | 5688 | done |
3185942a | 5689 | IFS=$as_save_IFS |
f73dda09 | 5690 | |
ccc6cda3 JA |
5691 | fi |
5692 | fi | |
f73dda09 | 5693 | RANLIB=$ac_cv_prog_RANLIB |
ccc6cda3 | 5694 | if test -n "$RANLIB"; then |
ac50fbac | 5695 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
3185942a | 5696 | $as_echo "$RANLIB" >&6; } |
f73dda09 | 5697 | else |
ac50fbac | 5698 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 5699 | $as_echo "no" >&6; } |
f73dda09 JA |
5700 | fi |
5701 | ||
3185942a | 5702 | |
f73dda09 JA |
5703 | fi |
5704 | if test -z "$ac_cv_prog_RANLIB"; then | |
5705 | ac_ct_RANLIB=$RANLIB | |
5706 | # Extract the first word of "ranlib", so it can be a program name with args. | |
5707 | set dummy ranlib; ac_word=$2 | |
ac50fbac | 5708 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 5709 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 5710 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
3185942a | 5711 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5712 | else |
5713 | if test -n "$ac_ct_RANLIB"; then | |
5714 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
5715 | else | |
b80f6443 JA |
5716 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5717 | for as_dir in $PATH | |
5718 | do | |
5719 | IFS=$as_save_IFS | |
5720 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
5721 | for ac_exec_ext in '' $ac_executable_extensions; do |
5722 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 5723 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
ac50fbac | 5724 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
5725 | break 2 |
5726 | fi | |
5727 | done | |
ac50fbac | 5728 | done |
3185942a | 5729 | IFS=$as_save_IFS |
f73dda09 | 5730 | |
f73dda09 JA |
5731 | fi |
5732 | fi | |
5733 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
5734 | if test -n "$ac_ct_RANLIB"; then | |
ac50fbac | 5735 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
3185942a | 5736 | $as_echo "$ac_ct_RANLIB" >&6; } |
ccc6cda3 | 5737 | else |
ac50fbac | 5738 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 5739 | $as_echo "no" >&6; } |
f73dda09 JA |
5740 | fi |
5741 | ||
3185942a JA |
5742 | if test "x$ac_ct_RANLIB" = x; then |
5743 | RANLIB=":" | |
5744 | else | |
5745 | case $cross_compiling:$ac_tool_warned in | |
5746 | yes:) | |
ac50fbac | 5747 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
3185942a JA |
5748 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
5749 | ac_tool_warned=yes ;; | |
5750 | esac | |
5751 | RANLIB=$ac_ct_RANLIB | |
5752 | fi | |
f73dda09 JA |
5753 | else |
5754 | RANLIB="$ac_cv_prog_RANLIB" | |
ccc6cda3 JA |
5755 | fi |
5756 | ||
5757 | for ac_prog in 'bison -y' byacc | |
5758 | do | |
f73dda09 | 5759 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
ccc6cda3 | 5760 | set dummy $ac_prog; ac_word=$2 |
ac50fbac | 5761 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 5762 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 5763 | if ${ac_cv_prog_YACC+:} false; then : |
3185942a | 5764 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5765 | else |
5766 | if test -n "$YACC"; then | |
5767 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | |
5768 | else | |
b80f6443 JA |
5769 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5770 | for as_dir in $PATH | |
5771 | do | |
5772 | IFS=$as_save_IFS | |
5773 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
5774 | for ac_exec_ext in '' $ac_executable_extensions; do |
5775 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 5776 | ac_cv_prog_YACC="$ac_prog" |
ac50fbac | 5777 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
5778 | break 2 |
5779 | fi | |
5780 | done | |
ac50fbac | 5781 | done |
3185942a | 5782 | IFS=$as_save_IFS |
f73dda09 | 5783 | |
ccc6cda3 JA |
5784 | fi |
5785 | fi | |
f73dda09 | 5786 | YACC=$ac_cv_prog_YACC |
ccc6cda3 | 5787 | if test -n "$YACC"; then |
ac50fbac | 5788 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 |
3185942a | 5789 | $as_echo "$YACC" >&6; } |
ccc6cda3 | 5790 | else |
ac50fbac | 5791 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 5792 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5793 | fi |
5794 | ||
3185942a | 5795 | |
f73dda09 | 5796 | test -n "$YACC" && break |
ccc6cda3 JA |
5797 | done |
5798 | test -n "$YACC" || YACC="yacc" | |
5799 | ||
ac50fbac | 5800 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 |
3185942a JA |
5801 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } |
5802 | set x ${MAKE-make} | |
5803 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
ac50fbac | 5804 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : |
3185942a | 5805 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5806 | else |
b80f6443 | 5807 | cat >conftest.make <<\_ACEOF |
3185942a | 5808 | SHELL = /bin/sh |
ccc6cda3 | 5809 | all: |
3185942a | 5810 | @echo '@@@%%%=$(MAKE)=@@@%%%' |
b80f6443 | 5811 | _ACEOF |
ac50fbac | 5812 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. |
3185942a JA |
5813 | case `${MAKE-make} -f conftest.make 2>/dev/null` in |
5814 | *@@@%%%=?*=@@@%%%*) | |
5815 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
5816 | *) | |
5817 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
5818 | esac | |
f73dda09 | 5819 | rm -f conftest.make |
ccc6cda3 | 5820 | fi |
3185942a | 5821 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then |
ac50fbac | 5822 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
3185942a | 5823 | $as_echo "yes" >&6; } |
ccc6cda3 JA |
5824 | SET_MAKE= |
5825 | else | |
ac50fbac | 5826 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 5827 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5828 | SET_MAKE="MAKE=${MAKE-make}" |
5829 | fi | |
5830 | ||
b80f6443 | 5831 | |
ac50fbac CR |
5832 | case "$ac_cv_prog_YACC" in |
5833 | *bison*) ;; | |
5834 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: bison not available; needed to process parse.y" >&5 | |
5835 | $as_echo "$as_me: WARNING: bison not available; needed to process parse.y" >&2;} ;; | |
5836 | esac | |
5837 | ||
b72432fd | 5838 | case "$host_os" in |
bb70624e | 5839 | opennt*|interix*) MAKE_SHELL="$INTERIX_ROOT/bin/sh" ;; |
b72432fd JA |
5840 | *) MAKE_SHELL=/bin/sh ;; |
5841 | esac | |
5842 | ||
5843 | ||
95732b49 JA |
5844 | if test x$SIZE = x; then |
5845 | if test x$ac_tool_prefix = x; then | |
5846 | SIZE=size | |
5847 | else | |
5848 | SIZE=${ac_tool_prefix}size | |
5849 | save_IFS=$IFS ; IFS=: | |
5850 | size_found=0 | |
5851 | for dir in $PATH; do | |
5852 | if test -x $dir/$SIZE ; then | |
5853 | size_found=1 | |
5854 | break | |
5855 | fi | |
5856 | done | |
5857 | if test $size_found -eq 0; then | |
5858 | SIZE=: | |
5859 | fi | |
5860 | IFS=$save_IFS | |
5861 | fi | |
5862 | fi | |
5863 | ||
5864 | ||
ac50fbac CR |
5865 | # Checks for stat-related time functions. |
5866 | ||
5867 | # Copyright (C) 1998-1999, 2001, 2003, 2005-2007, 2009-2012 Free Software | |
5868 | # Foundation, Inc. | |
5869 | ||
5870 | # This file is free software; the Free Software Foundation | |
5871 | # gives unlimited permission to copy and/or distribute it, | |
5872 | # with or without modifications, as long as this notice is preserved. | |
ccc6cda3 | 5873 | |
f73dda09 | 5874 | |
ac50fbac CR |
5875 | # st_atim.tv_nsec - Linux, Solaris, Cygwin |
5876 | # st_atimespec.tv_nsec - FreeBSD, NetBSD, if ! defined _POSIX_SOURCE | |
5877 | # st_atimensec - FreeBSD, NetBSD, if defined _POSIX_SOURCE | |
5878 | # st_atim.st__tim.tv_nsec - UnixWare (at least 2.1.2 through 7.1) | |
5879 | ||
5880 | # st_birthtimespec - FreeBSD, NetBSD (hidden on OpenBSD 3.9, anyway) | |
5881 | # st_birthtim - Cygwin 1.7.0+ | |
5882 | ||
5883 | ||
5884 | ||
5885 | # Configure checks for struct timespec | |
5886 | ||
5887 | # Copyright (C) 2000-2001, 2003-2007, 2009-2011, 2012 Free Software Foundation, Inc. | |
5888 | ||
5889 | # This file is free software; the Free Software Foundation | |
5890 | # gives unlimited permission to copy and/or distribute it, | |
5891 | # with or without modifications, as long as this notice is preserved. | |
5892 | ||
5893 | # Original written by Paul Eggert and Jim Meyering. | |
5894 | # Modified by Chet Ramey for bash | |
5895 | ||
5896 | ||
5897 | ||
5898 | ||
5899 | ||
5900 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h | |
5901 | ||
5902 | ||
5903 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 | |
3185942a | 5904 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
ac50fbac | 5905 | if ${ac_cv_c_const+:} false; then : |
3185942a | 5906 | $as_echo_n "(cached) " >&6 |
95732b49 | 5907 | else |
ac50fbac | 5908 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a JA |
5909 | /* end confdefs.h. */ |
5910 | ||
5911 | int | |
5912 | main () | |
f73dda09 | 5913 | { |
ac50fbac | 5914 | |
f73dda09 | 5915 | #ifndef __cplusplus |
ac50fbac | 5916 | /* Ultrix mips cc rejects this sort of thing. */ |
f73dda09 | 5917 | typedef int charset[2]; |
ac50fbac | 5918 | const charset cs = { 0, 0 }; |
f73dda09 | 5919 | /* SunOS 4.1.1 cc rejects this. */ |
3185942a JA |
5920 | char const *const *pcpcc; |
5921 | char **ppc; | |
f73dda09 JA |
5922 | /* NEC SVR4.0.2 mips cc rejects this. */ |
5923 | struct point {int x, y;}; | |
5924 | static struct point const zero = {0,0}; | |
5925 | /* AIX XL C 1.02.0.0 rejects this. | |
5926 | It does not let you subtract one const X* pointer from another in | |
5927 | an arm of an if-expression whose if-part is not a constant | |
5928 | expression */ | |
5929 | const char *g = "string"; | |
3185942a | 5930 | pcpcc = &g + (g ? g-g : 0); |
f73dda09 | 5931 | /* HPUX 7.0 cc rejects these. */ |
3185942a JA |
5932 | ++pcpcc; |
5933 | ppc = (char**) pcpcc; | |
5934 | pcpcc = (char const *const *) ppc; | |
ac50fbac CR |
5935 | { /* SCO 3.2v4 cc rejects this sort of thing. */ |
5936 | char tx; | |
5937 | char *t = &tx; | |
f73dda09 JA |
5938 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
5939 | ||
5940 | *t++ = 0; | |
3185942a | 5941 | if (s) return 0; |
f73dda09 JA |
5942 | } |
5943 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
5944 | int x[] = {25, 17}; | |
5945 | const int *foo = &x[0]; | |
5946 | ++foo; | |
5947 | } | |
5948 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
5949 | typedef const int *iptr; | |
5950 | iptr p = 0; | |
5951 | ++p; | |
5952 | } | |
ac50fbac | 5953 | { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying |
f73dda09 | 5954 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
ac50fbac CR |
5955 | struct s { int j; const int *ap[3]; } bx; |
5956 | struct s *b = &bx; b->j = 5; | |
f73dda09 JA |
5957 | } |
5958 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
5959 | const int foo = 10; | |
3185942a | 5960 | if (!foo) return 0; |
f73dda09 | 5961 | } |
3185942a | 5962 | return !cs[0] && !zero.x; |
ccc6cda3 JA |
5963 | #endif |
5964 | ||
f73dda09 JA |
5965 | ; |
5966 | return 0; | |
5967 | } | |
5968 | _ACEOF | |
ac50fbac | 5969 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
5970 | ac_cv_c_const=yes |
5971 | else | |
ac50fbac | 5972 | ac_cv_c_const=no |
f73dda09 | 5973 | fi |
3185942a | 5974 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 5975 | fi |
ac50fbac | 5976 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
3185942a | 5977 | $as_echo "$ac_cv_c_const" >&6; } |
f73dda09 JA |
5978 | if test $ac_cv_c_const = no; then |
5979 | ||
ac50fbac | 5980 | $as_echo "#define const /**/" >>confdefs.h |
ccc6cda3 JA |
5981 | |
5982 | fi | |
5983 | ||
ac50fbac | 5984 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
3185942a | 5985 | $as_echo_n "checking for inline... " >&6; } |
ac50fbac | 5986 | if ${ac_cv_c_inline+:} false; then : |
3185942a | 5987 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5988 | else |
f73dda09 JA |
5989 | ac_cv_c_inline=no |
5990 | for ac_kw in inline __inline__ __inline; do | |
ac50fbac | 5991 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 5992 | /* end confdefs.h. */ |
f73dda09 | 5993 | #ifndef __cplusplus |
0628567a JA |
5994 | typedef int foo_t; |
5995 | static $ac_kw foo_t static_foo () {return 0; } | |
5996 | $ac_kw foo_t foo () {return 0; } | |
ccc6cda3 JA |
5997 | #endif |
5998 | ||
f73dda09 | 5999 | _ACEOF |
ac50fbac | 6000 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 6001 | ac_cv_c_inline=$ac_kw |
f73dda09 | 6002 | fi |
3185942a JA |
6003 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6004 | test "$ac_cv_c_inline" != no && break | |
f73dda09 | 6005 | done |
ccc6cda3 JA |
6006 | |
6007 | fi | |
ac50fbac | 6008 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
3185942a | 6009 | $as_echo "$ac_cv_c_inline" >&6; } |
0628567a | 6010 | |
f73dda09 JA |
6011 | case $ac_cv_c_inline in |
6012 | inline | yes) ;; | |
0628567a JA |
6013 | *) |
6014 | case $ac_cv_c_inline in | |
6015 | no) ac_val=;; | |
6016 | *) ac_val=$ac_cv_c_inline;; | |
6017 | esac | |
6018 | cat >>confdefs.h <<_ACEOF | |
6019 | #ifndef __cplusplus | |
6020 | #define inline $ac_val | |
6021 | #endif | |
b80f6443 | 6022 | _ACEOF |
0628567a | 6023 | ;; |
f73dda09 | 6024 | esac |
ccc6cda3 | 6025 | |
ac50fbac | 6026 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
3185942a | 6027 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
ac50fbac | 6028 | if ${ac_cv_c_bigendian+:} false; then : |
3185942a | 6029 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6030 | else |
3185942a JA |
6031 | ac_cv_c_bigendian=unknown |
6032 | # See if we're dealing with a universal compiler. | |
ac50fbac | 6033 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a JA |
6034 | /* end confdefs.h. */ |
6035 | #ifndef __APPLE_CC__ | |
6036 | not a universal capable compiler | |
6037 | #endif | |
6038 | typedef int dummy; | |
6039 | ||
6040 | _ACEOF | |
ac50fbac | 6041 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a JA |
6042 | |
6043 | # Check for potential -arch flags. It is not universal unless | |
ac50fbac CR |
6044 | # there are at least two -arch flags with different values. |
6045 | ac_arch= | |
6046 | ac_prev= | |
6047 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
6048 | if test -n "$ac_prev"; then | |
6049 | case $ac_word in | |
6050 | i?86 | x86_64 | ppc | ppc64) | |
6051 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
6052 | ac_arch=$ac_word | |
6053 | else | |
6054 | ac_cv_c_bigendian=universal | |
6055 | break | |
6056 | fi | |
6057 | ;; | |
6058 | esac | |
6059 | ac_prev= | |
6060 | elif test "x$ac_word" = "x-arch"; then | |
6061 | ac_prev=arch | |
6062 | fi | |
6063 | done | |
3185942a | 6064 | fi |
3185942a JA |
6065 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6066 | if test $ac_cv_c_bigendian = unknown; then | |
6067 | # See if sys/param.h defines the BYTE_ORDER macro. | |
ac50fbac | 6068 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6069 | /* end confdefs.h. */ |
f73dda09 | 6070 | #include <sys/types.h> |
3185942a | 6071 | #include <sys/param.h> |
ccc6cda3 | 6072 | |
f73dda09 JA |
6073 | int |
6074 | main () | |
6075 | { | |
3185942a JA |
6076 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
6077 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
6078 | && LITTLE_ENDIAN) | |
6079 | bogus endian macros | |
6080 | #endif | |
ccc6cda3 | 6081 | |
f73dda09 JA |
6082 | ; |
6083 | return 0; | |
6084 | } | |
6085 | _ACEOF | |
ac50fbac | 6086 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6087 | # It does; now see whether it defined to BIG_ENDIAN or not. |
ac50fbac | 6088 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6089 | /* end confdefs.h. */ |
f73dda09 | 6090 | #include <sys/types.h> |
3185942a | 6091 | #include <sys/param.h> |
ccc6cda3 | 6092 | |
f73dda09 JA |
6093 | int |
6094 | main () | |
6095 | { | |
6096 | #if BYTE_ORDER != BIG_ENDIAN | |
3185942a JA |
6097 | not big endian |
6098 | #endif | |
ccc6cda3 | 6099 | |
f73dda09 JA |
6100 | ; |
6101 | return 0; | |
6102 | } | |
6103 | _ACEOF | |
ac50fbac | 6104 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6105 | ac_cv_c_bigendian=yes |
ccc6cda3 | 6106 | else |
ac50fbac | 6107 | ac_cv_c_bigendian=no |
ccc6cda3 | 6108 | fi |
3185942a | 6109 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3185942a | 6110 | fi |
3185942a JA |
6111 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6112 | fi | |
6113 | if test $ac_cv_c_bigendian = unknown; then | |
6114 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
ac50fbac | 6115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6116 | /* end confdefs.h. */ |
3185942a JA |
6117 | #include <limits.h> |
6118 | ||
b80f6443 JA |
6119 | int |
6120 | main () | |
6121 | { | |
3185942a JA |
6122 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
6123 | bogus endian macros | |
6124 | #endif | |
6125 | ||
b80f6443 JA |
6126 | ; |
6127 | return 0; | |
6128 | } | |
6129 | _ACEOF | |
ac50fbac | 6130 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 6131 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
ac50fbac | 6132 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6133 | /* end confdefs.h. */ |
3185942a JA |
6134 | #include <limits.h> |
6135 | ||
f73dda09 JA |
6136 | int |
6137 | main () | |
ccc6cda3 | 6138 | { |
3185942a JA |
6139 | #ifndef _BIG_ENDIAN |
6140 | not big endian | |
6141 | #endif | |
6142 | ||
6143 | ; | |
6144 | return 0; | |
ccc6cda3 | 6145 | } |
f73dda09 | 6146 | _ACEOF |
ac50fbac | 6147 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 6148 | ac_cv_c_bigendian=yes |
ccc6cda3 | 6149 | else |
ac50fbac | 6150 | ac_cv_c_bigendian=no |
f73dda09 | 6151 | fi |
3185942a | 6152 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 6153 | fi |
3185942a JA |
6154 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6155 | fi | |
6156 | if test $ac_cv_c_bigendian = unknown; then | |
6157 | # Compile a test program. | |
ac50fbac | 6158 | if test "$cross_compiling" = yes; then : |
3185942a | 6159 | # Try to guess by grepping values from an object file. |
ac50fbac | 6160 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a JA |
6161 | /* end confdefs.h. */ |
6162 | short int ascii_mm[] = | |
6163 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
6164 | short int ascii_ii[] = | |
6165 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
6166 | int use_ascii (int i) { | |
6167 | return ascii_mm[i] + ascii_ii[i]; | |
6168 | } | |
6169 | short int ebcdic_ii[] = | |
6170 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
6171 | short int ebcdic_mm[] = | |
6172 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
6173 | int use_ebcdic (int i) { | |
6174 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
6175 | } | |
6176 | extern int foo; | |
6177 | ||
6178 | int | |
6179 | main () | |
6180 | { | |
6181 | return use_ascii (foo) == use_ebcdic (foo); | |
6182 | ; | |
6183 | return 0; | |
6184 | } | |
6185 | _ACEOF | |
ac50fbac | 6186 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a JA |
6187 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
6188 | ac_cv_c_bigendian=yes | |
6189 | fi | |
6190 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
6191 | if test "$ac_cv_c_bigendian" = unknown; then | |
6192 | ac_cv_c_bigendian=no | |
6193 | else | |
6194 | # finding both strings is unlikely to happen, but who knows? | |
6195 | ac_cv_c_bigendian=unknown | |
6196 | fi | |
6197 | fi | |
3185942a | 6198 | fi |
3185942a JA |
6199 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6200 | else | |
ac50fbac | 6201 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a JA |
6202 | /* end confdefs.h. */ |
6203 | $ac_includes_default | |
6204 | int | |
6205 | main () | |
6206 | { | |
6207 | ||
6208 | /* Are we little or big endian? From Harbison&Steele. */ | |
6209 | union | |
6210 | { | |
6211 | long int l; | |
6212 | char c[sizeof (long int)]; | |
6213 | } u; | |
6214 | u.l = 1; | |
6215 | return u.c[sizeof (long int) - 1] == 1; | |
6216 | ||
6217 | ; | |
6218 | return 0; | |
6219 | } | |
6220 | _ACEOF | |
ac50fbac | 6221 | if ac_fn_c_try_run "$LINENO"; then : |
3185942a JA |
6222 | ac_cv_c_bigendian=no |
6223 | else | |
ac50fbac | 6224 | ac_cv_c_bigendian=yes |
3185942a | 6225 | fi |
ac50fbac CR |
6226 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6227 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
3185942a JA |
6228 | fi |
6229 | ||
3185942a JA |
6230 | fi |
6231 | fi | |
ac50fbac | 6232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
3185942a JA |
6233 | $as_echo "$ac_cv_c_bigendian" >&6; } |
6234 | case $ac_cv_c_bigendian in #( | |
6235 | yes) | |
ac50fbac | 6236 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
3185942a JA |
6237 | ;; #( |
6238 | no) | |
6239 | ;; #( | |
6240 | universal) | |
6241 | ||
ac50fbac | 6242 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
3185942a JA |
6243 | |
6244 | ;; #( | |
6245 | *) | |
ac50fbac CR |
6246 | as_fn_error $? "unknown endianness |
6247 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; | |
3185942a | 6248 | esac |
b80f6443 | 6249 | |
ac50fbac | 6250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for preprocessor stringizing operator" >&5 |
3185942a | 6251 | $as_echo_n "checking for preprocessor stringizing operator... " >&6; } |
ac50fbac | 6252 | if ${ac_cv_c_stringize+:} false; then : |
3185942a | 6253 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6254 | else |
ac50fbac | 6255 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6256 | /* end confdefs.h. */ |
f73dda09 | 6257 | #define x(y) #y |
ccc6cda3 | 6258 | |
f73dda09 JA |
6259 | char *s = x(teststring); |
6260 | _ACEOF | |
6261 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 6262 | $EGREP "#teststring" >/dev/null 2>&1; then : |
f73dda09 | 6263 | ac_cv_c_stringize=no |
ccc6cda3 | 6264 | else |
f73dda09 | 6265 | ac_cv_c_stringize=yes |
ccc6cda3 | 6266 | fi |
f73dda09 | 6267 | rm -f conftest* |
ccc6cda3 JA |
6268 | |
6269 | fi | |
ac50fbac | 6270 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stringize" >&5 |
3185942a | 6271 | $as_echo "$ac_cv_c_stringize" >&6; } |
f73dda09 | 6272 | if test $ac_cv_c_stringize = yes; then |
ccc6cda3 | 6273 | |
ac50fbac | 6274 | $as_echo "#define HAVE_STRINGIZE 1" >>confdefs.h |
ccc6cda3 JA |
6275 | |
6276 | fi | |
6277 | ||
3185942a JA |
6278 | |
6279 | ||
ac50fbac | 6280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double with more range or precision than double" >&5 |
3185942a | 6281 | $as_echo_n "checking for long double with more range or precision than double... " >&6; } |
ac50fbac | 6282 | if ${ac_cv_type_long_double_wider+:} false; then : |
3185942a | 6283 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6284 | else |
ac50fbac | 6285 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6286 | /* end confdefs.h. */ |
b80f6443 | 6287 | #include <float.h> |
3185942a JA |
6288 | long double const a[] = |
6289 | { | |
6290 | 0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON, | |
6291 | LDBL_MIN, LDBL_MAX, LDBL_EPSILON | |
6292 | }; | |
6293 | long double | |
6294 | f (long double x) | |
6295 | { | |
6296 | return ((x + (unsigned long int) 10) * (-1 / x) + a[0] | |
6297 | + (x ? f (x) : 'c')); | |
6298 | } | |
6299 | ||
f73dda09 JA |
6300 | int |
6301 | main () | |
6302 | { | |
3185942a JA |
6303 | static int test_array [1 - 2 * !((0 < ((DBL_MAX_EXP < LDBL_MAX_EXP) |
6304 | + (DBL_MANT_DIG < LDBL_MANT_DIG) | |
6305 | - (LDBL_MAX_EXP < DBL_MAX_EXP) | |
6306 | - (LDBL_MANT_DIG < DBL_MANT_DIG))) | |
6307 | && (int) LDBL_EPSILON == 0 | |
6308 | )]; | |
ac50fbac CR |
6309 | test_array [0] = 0; |
6310 | return test_array [0]; | |
b80f6443 JA |
6311 | |
6312 | ; | |
6313 | return 0; | |
ccc6cda3 | 6314 | } |
f73dda09 | 6315 | _ACEOF |
ac50fbac | 6316 | if ac_fn_c_try_compile "$LINENO"; then : |
3185942a | 6317 | ac_cv_type_long_double_wider=yes |
ccc6cda3 | 6318 | else |
ac50fbac | 6319 | ac_cv_type_long_double_wider=no |
f73dda09 | 6320 | fi |
3185942a | 6321 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 6322 | fi |
ac50fbac | 6323 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double_wider" >&5 |
3185942a JA |
6324 | $as_echo "$ac_cv_type_long_double_wider" >&6; } |
6325 | if test $ac_cv_type_long_double_wider = yes; then | |
6326 | ||
ac50fbac | 6327 | $as_echo "#define HAVE_LONG_DOUBLE_WIDER 1" >>confdefs.h |
3185942a JA |
6328 | |
6329 | fi | |
6330 | ||
6331 | ac_cv_c_long_double=$ac_cv_type_long_double_wider | |
6332 | if test $ac_cv_c_long_double = yes; then | |
ccc6cda3 | 6333 | |
ac50fbac | 6334 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
ccc6cda3 | 6335 | |
3185942a | 6336 | fi |
ccc6cda3 | 6337 | |
ac50fbac | 6338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 |
3185942a JA |
6339 | $as_echo_n "checking for function prototypes... " >&6; } |
6340 | if test "$ac_cv_prog_cc_c89" != no; then | |
ac50fbac | 6341 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
3185942a | 6342 | $as_echo "yes" >&6; } |
ccc6cda3 | 6343 | |
ac50fbac | 6344 | $as_echo "#define PROTOTYPES 1" >>confdefs.h |
ccc6cda3 | 6345 | |
f73dda09 | 6346 | |
ac50fbac | 6347 | $as_echo "#define __PROTOTYPES 1" >>confdefs.h |
f73dda09 | 6348 | |
f73dda09 | 6349 | else |
ac50fbac | 6350 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 6351 | $as_echo "no" >&6; } |
f73dda09 | 6352 | fi |
ccc6cda3 | 6353 | |
ac50fbac | 6354 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
3185942a | 6355 | $as_echo_n "checking whether char is unsigned... " >&6; } |
ac50fbac | 6356 | if ${ac_cv_c_char_unsigned+:} false; then : |
3185942a | 6357 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6358 | else |
ac50fbac | 6359 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6360 | /* end confdefs.h. */ |
f73dda09 JA |
6361 | $ac_includes_default |
6362 | int | |
ccc6cda3 JA |
6363 | main () |
6364 | { | |
b80f6443 | 6365 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
ac50fbac CR |
6366 | test_array [0] = 0; |
6367 | return test_array [0]; | |
b80f6443 | 6368 | |
f73dda09 JA |
6369 | ; |
6370 | return 0; | |
ccc6cda3 | 6371 | } |
f73dda09 | 6372 | _ACEOF |
ac50fbac | 6373 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6374 | ac_cv_c_char_unsigned=no |
ccc6cda3 | 6375 | else |
ac50fbac | 6376 | ac_cv_c_char_unsigned=yes |
ccc6cda3 | 6377 | fi |
3185942a | 6378 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 6379 | fi |
ac50fbac | 6380 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
3185942a | 6381 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
f73dda09 | 6382 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
ac50fbac | 6383 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
ccc6cda3 | 6384 | |
ccc6cda3 JA |
6385 | fi |
6386 | ||
ac50fbac | 6387 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
17345e5a | 6388 | $as_echo_n "checking for working volatile... " >&6; } |
ac50fbac | 6389 | if ${ac_cv_c_volatile+:} false; then : |
17345e5a JA |
6390 | $as_echo_n "(cached) " >&6 |
6391 | else | |
ac50fbac | 6392 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
17345e5a JA |
6393 | /* end confdefs.h. */ |
6394 | ||
6395 | int | |
6396 | main () | |
6397 | { | |
6398 | ||
6399 | volatile int x; | |
6400 | int * volatile y = (int *) 0; | |
6401 | return !x && !y; | |
6402 | ; | |
6403 | return 0; | |
6404 | } | |
6405 | _ACEOF | |
ac50fbac | 6406 | if ac_fn_c_try_compile "$LINENO"; then : |
17345e5a JA |
6407 | ac_cv_c_volatile=yes |
6408 | else | |
ac50fbac | 6409 | ac_cv_c_volatile=no |
17345e5a | 6410 | fi |
17345e5a JA |
6411 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6412 | fi | |
ac50fbac | 6413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 |
17345e5a JA |
6414 | $as_echo "$ac_cv_c_volatile" >&6; } |
6415 | if test $ac_cv_c_volatile = no; then | |
6416 | ||
ac50fbac | 6417 | $as_echo "#define volatile /**/" >>confdefs.h |
17345e5a JA |
6418 | |
6419 | fi | |
6420 | ||
ac50fbac | 6421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5 |
17345e5a | 6422 | $as_echo_n "checking for C/C++ restrict keyword... " >&6; } |
ac50fbac | 6423 | if ${ac_cv_c_restrict+:} false; then : |
17345e5a JA |
6424 | $as_echo_n "(cached) " >&6 |
6425 | else | |
6426 | ac_cv_c_restrict=no | |
6427 | # The order here caters to the fact that C++ does not require restrict. | |
6428 | for ac_kw in __restrict __restrict__ _Restrict restrict; do | |
ac50fbac | 6429 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
17345e5a JA |
6430 | /* end confdefs.h. */ |
6431 | typedef int * int_ptr; | |
6432 | int foo (int_ptr $ac_kw ip) { | |
6433 | return ip[0]; | |
6434 | } | |
6435 | int | |
6436 | main () | |
6437 | { | |
6438 | int s[1]; | |
6439 | int * $ac_kw t = s; | |
6440 | t[0] = 0; | |
6441 | return foo(t) | |
6442 | ; | |
6443 | return 0; | |
6444 | } | |
6445 | _ACEOF | |
ac50fbac | 6446 | if ac_fn_c_try_compile "$LINENO"; then : |
17345e5a | 6447 | ac_cv_c_restrict=$ac_kw |
17345e5a | 6448 | fi |
17345e5a JA |
6449 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6450 | test "$ac_cv_c_restrict" != no && break | |
6451 | done | |
6452 | ||
6453 | fi | |
ac50fbac | 6454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5 |
17345e5a JA |
6455 | $as_echo "$ac_cv_c_restrict" >&6; } |
6456 | ||
17345e5a JA |
6457 | case $ac_cv_c_restrict in |
6458 | restrict) ;; | |
ac50fbac | 6459 | no) $as_echo "#define restrict /**/" >>confdefs.h |
17345e5a JA |
6460 | ;; |
6461 | *) cat >>confdefs.h <<_ACEOF | |
6462 | #define restrict $ac_cv_c_restrict | |
6463 | _ACEOF | |
6464 | ;; | |
6465 | esac | |
6466 | ||
ccc6cda3 | 6467 | |
b80f6443 JA |
6468 | |
6469 | MKINSTALLDIRS= | |
6470 | if test -n "$ac_aux_dir"; then | |
6471 | case "$ac_aux_dir" in | |
6472 | /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; | |
6473 | *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; | |
6474 | esac | |
6475 | fi | |
6476 | if test -z "$MKINSTALLDIRS"; then | |
6477 | MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" | |
6478 | fi | |
6479 | ||
6480 | ||
6481 | ||
ac50fbac | 6482 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
3185942a JA |
6483 | $as_echo_n "checking whether NLS is requested... " >&6; } |
6484 | # Check whether --enable-nls was given. | |
ac50fbac | 6485 | if test "${enable_nls+set}" = set; then : |
3185942a | 6486 | enableval=$enable_nls; USE_NLS=$enableval |
ccc6cda3 | 6487 | else |
b80f6443 | 6488 | USE_NLS=yes |
3185942a JA |
6489 | fi |
6490 | ||
ac50fbac | 6491 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
3185942a | 6492 | $as_echo "$USE_NLS" >&6; } |
b80f6443 JA |
6493 | |
6494 | ||
6495 | ||
6496 | ||
6497 | ||
6498 | ||
6499 | # Prepare PATH_SEPARATOR. | |
6500 | # The user is always right. | |
6501 | if test "${PATH_SEPARATOR+set}" != set; then | |
6502 | echo "#! /bin/sh" >conf$$.sh | |
6503 | echo "exit 0" >>conf$$.sh | |
6504 | chmod +x conf$$.sh | |
6505 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6506 | PATH_SEPARATOR=';' | |
6507 | else | |
6508 | PATH_SEPARATOR=: | |
6509 | fi | |
6510 | rm -f conf$$.sh | |
ccc6cda3 | 6511 | fi |
ccc6cda3 | 6512 | |
b80f6443 JA |
6513 | # Find out how to test for executable files. Don't use a zero-byte file, |
6514 | # as systems may use methods other than mode bits to determine executability. | |
6515 | cat >conf$$.file <<_ASEOF | |
6516 | #! /bin/sh | |
6517 | exit 0 | |
6518 | _ASEOF | |
6519 | chmod +x conf$$.file | |
6520 | if test -x conf$$.file >/dev/null 2>&1; then | |
6521 | ac_executable_p="test -x" | |
6522 | else | |
6523 | ac_executable_p="test -f" | |
f73dda09 | 6524 | fi |
b80f6443 | 6525 | rm -f conf$$.file |
ccc6cda3 | 6526 | |
b80f6443 JA |
6527 | # Extract the first word of "msgfmt", so it can be a program name with args. |
6528 | set dummy msgfmt; ac_word=$2 | |
ac50fbac | 6529 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 6530 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 6531 | if ${ac_cv_path_MSGFMT+:} false; then : |
3185942a | 6532 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6533 | else |
b80f6443 JA |
6534 | case "$MSGFMT" in |
6535 | [\\/]* | ?:[\\/]*) | |
6536 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
6537 | ;; | |
6538 | *) | |
6539 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6540 | for ac_dir in $PATH; do | |
6541 | IFS="$ac_save_IFS" | |
6542 | test -z "$ac_dir" && ac_dir=. | |
6543 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6544 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6545 | if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && | |
6546 | (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6547 | ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" | |
6548 | break 2 | |
6549 | fi | |
6550 | fi | |
6551 | done | |
6552 | done | |
6553 | IFS="$ac_save_IFS" | |
6554 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" | |
6555 | ;; | |
6556 | esac | |
6557 | fi | |
6558 | MSGFMT="$ac_cv_path_MSGFMT" | |
6559 | if test "$MSGFMT" != ":"; then | |
ac50fbac | 6560 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 |
3185942a | 6561 | $as_echo "$MSGFMT" >&6; } |
f73dda09 | 6562 | else |
ac50fbac | 6563 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 6564 | $as_echo "no" >&6; } |
f73dda09 | 6565 | fi |
b80f6443 JA |
6566 | |
6567 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
6568 | set dummy gmsgfmt; ac_word=$2 | |
ac50fbac | 6569 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 6570 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 6571 | if ${ac_cv_path_GMSGFMT+:} false; then : |
3185942a | 6572 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
6573 | else |
6574 | case $GMSGFMT in | |
6575 | [\\/]* | ?:[\\/]*) | |
6576 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
6577 | ;; | |
6578 | *) | |
6579 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
6580 | for as_dir in $PATH | |
6581 | do | |
6582 | IFS=$as_save_IFS | |
6583 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
6584 | for ac_exec_ext in '' $ac_executable_extensions; do |
6585 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 6586 | ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" |
ac50fbac | 6587 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
6588 | break 2 |
6589 | fi | |
6590 | done | |
ac50fbac | 6591 | done |
3185942a | 6592 | IFS=$as_save_IFS |
b80f6443 JA |
6593 | |
6594 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
6595 | ;; | |
6596 | esac | |
6597 | fi | |
6598 | GMSGFMT=$ac_cv_path_GMSGFMT | |
b80f6443 | 6599 | if test -n "$GMSGFMT"; then |
ac50fbac | 6600 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 |
3185942a | 6601 | $as_echo "$GMSGFMT" >&6; } |
b80f6443 | 6602 | else |
ac50fbac | 6603 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 6604 | $as_echo "no" >&6; } |
f73dda09 | 6605 | fi |
b80f6443 JA |
6606 | |
6607 | ||
6608 | ||
3185942a | 6609 | |
b80f6443 JA |
6610 | # Prepare PATH_SEPARATOR. |
6611 | # The user is always right. | |
6612 | if test "${PATH_SEPARATOR+set}" != set; then | |
6613 | echo "#! /bin/sh" >conf$$.sh | |
6614 | echo "exit 0" >>conf$$.sh | |
6615 | chmod +x conf$$.sh | |
6616 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6617 | PATH_SEPARATOR=';' | |
6618 | else | |
6619 | PATH_SEPARATOR=: | |
6620 | fi | |
6621 | rm -f conf$$.sh | |
f73dda09 | 6622 | fi |
ccc6cda3 | 6623 | |
b80f6443 JA |
6624 | # Find out how to test for executable files. Don't use a zero-byte file, |
6625 | # as systems may use methods other than mode bits to determine executability. | |
6626 | cat >conf$$.file <<_ASEOF | |
6627 | #! /bin/sh | |
6628 | exit 0 | |
6629 | _ASEOF | |
6630 | chmod +x conf$$.file | |
6631 | if test -x conf$$.file >/dev/null 2>&1; then | |
6632 | ac_executable_p="test -x" | |
ccc6cda3 | 6633 | else |
b80f6443 JA |
6634 | ac_executable_p="test -f" |
6635 | fi | |
6636 | rm -f conf$$.file | |
6637 | ||
6638 | # Extract the first word of "xgettext", so it can be a program name with args. | |
6639 | set dummy xgettext; ac_word=$2 | |
ac50fbac | 6640 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 6641 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 6642 | if ${ac_cv_path_XGETTEXT+:} false; then : |
3185942a | 6643 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6644 | else |
b80f6443 JA |
6645 | case "$XGETTEXT" in |
6646 | [\\/]* | ?:[\\/]*) | |
6647 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
6648 | ;; | |
6649 | *) | |
6650 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6651 | for ac_dir in $PATH; do | |
6652 | IFS="$ac_save_IFS" | |
6653 | test -z "$ac_dir" && ac_dir=. | |
6654 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6655 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6656 | if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6657 | (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 | |
6658 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" | |
6659 | break 2 | |
6660 | fi | |
6661 | fi | |
6662 | done | |
6663 | done | |
6664 | IFS="$ac_save_IFS" | |
6665 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
6666 | ;; | |
6667 | esac | |
6668 | fi | |
6669 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
6670 | if test "$XGETTEXT" != ":"; then | |
ac50fbac | 6671 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 |
3185942a | 6672 | $as_echo "$XGETTEXT" >&6; } |
b80f6443 | 6673 | else |
ac50fbac | 6674 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 6675 | $as_echo "no" >&6; } |
b80f6443 | 6676 | fi |
f73dda09 | 6677 | |
b80f6443 JA |
6678 | rm -f messages.po |
6679 | ||
6680 | ||
6681 | # Prepare PATH_SEPARATOR. | |
6682 | # The user is always right. | |
6683 | if test "${PATH_SEPARATOR+set}" != set; then | |
6684 | echo "#! /bin/sh" >conf$$.sh | |
6685 | echo "exit 0" >>conf$$.sh | |
6686 | chmod +x conf$$.sh | |
6687 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6688 | PATH_SEPARATOR=';' | |
6689 | else | |
6690 | PATH_SEPARATOR=: | |
6691 | fi | |
6692 | rm -f conf$$.sh | |
6693 | fi | |
6694 | ||
6695 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6696 | # as systems may use methods other than mode bits to determine executability. | |
6697 | cat >conf$$.file <<_ASEOF | |
6698 | #! /bin/sh | |
6699 | exit 0 | |
6700 | _ASEOF | |
6701 | chmod +x conf$$.file | |
6702 | if test -x conf$$.file >/dev/null 2>&1; then | |
6703 | ac_executable_p="test -x" | |
6704 | else | |
6705 | ac_executable_p="test -f" | |
6706 | fi | |
6707 | rm -f conf$$.file | |
6708 | ||
6709 | # Extract the first word of "msgmerge", so it can be a program name with args. | |
6710 | set dummy msgmerge; ac_word=$2 | |
ac50fbac | 6711 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 6712 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 6713 | if ${ac_cv_path_MSGMERGE+:} false; then : |
3185942a | 6714 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
6715 | else |
6716 | case "$MSGMERGE" in | |
6717 | [\\/]* | ?:[\\/]*) | |
6718 | ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. | |
6719 | ;; | |
6720 | *) | |
6721 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6722 | for ac_dir in $PATH; do | |
6723 | IFS="$ac_save_IFS" | |
6724 | test -z "$ac_dir" && ac_dir=. | |
6725 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6726 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6727 | if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then | |
6728 | ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" | |
6729 | break 2 | |
6730 | fi | |
6731 | fi | |
6732 | done | |
6733 | done | |
6734 | IFS="$ac_save_IFS" | |
6735 | test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" | |
6736 | ;; | |
6737 | esac | |
6738 | fi | |
6739 | MSGMERGE="$ac_cv_path_MSGMERGE" | |
6740 | if test "$MSGMERGE" != ":"; then | |
ac50fbac | 6741 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5 |
3185942a | 6742 | $as_echo "$MSGMERGE" >&6; } |
b80f6443 | 6743 | else |
ac50fbac | 6744 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 6745 | $as_echo "no" >&6; } |
b80f6443 JA |
6746 | fi |
6747 | ||
6748 | ||
6749 | if test "$GMSGFMT" != ":"; then | |
6750 | if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && | |
6751 | (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6752 | : ; | |
6753 | else | |
6754 | GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` | |
ac50fbac | 6755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5 |
3185942a | 6756 | $as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; } |
b80f6443 JA |
6757 | GMSGFMT=":" |
6758 | fi | |
6759 | fi | |
6760 | ||
6761 | if test "$XGETTEXT" != ":"; then | |
6762 | if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6763 | (if $XGETTEXT --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 | |
6764 | : ; | |
6765 | else | |
ac50fbac | 6766 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5 |
3185942a | 6767 | $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; } |
b80f6443 JA |
6768 | XGETTEXT=":" |
6769 | fi | |
6770 | rm -f messages.po | |
6771 | fi | |
6772 | ||
3185942a | 6773 | ac_config_commands="$ac_config_commands default-1" |
b80f6443 JA |
6774 | |
6775 | ||
ac50fbac CR |
6776 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
6777 | if test "x$ac_cv_type_off_t" = xyes; then : | |
3185942a | 6778 | |
b80f6443 JA |
6779 | else |
6780 | ||
6781 | cat >>confdefs.h <<_ACEOF | |
3185942a | 6782 | #define off_t long int |
b80f6443 | 6783 | _ACEOF |
ccc6cda3 | 6784 | |
f73dda09 | 6785 | fi |
ccc6cda3 | 6786 | |
ac50fbac CR |
6787 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
6788 | if test "x$ac_cv_type_size_t" = xyes; then : | |
3185942a | 6789 | |
b80f6443 | 6790 | else |
ccc6cda3 | 6791 | |
b80f6443 | 6792 | cat >>confdefs.h <<_ACEOF |
3185942a | 6793 | #define size_t unsigned int |
b80f6443 | 6794 | _ACEOF |
ccc6cda3 | 6795 | |
ccc6cda3 JA |
6796 | fi |
6797 | ||
b80f6443 JA |
6798 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
6799 | # for constant arguments. Useless! | |
ac50fbac | 6800 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 |
3185942a | 6801 | $as_echo_n "checking for working alloca.h... " >&6; } |
ac50fbac | 6802 | if ${ac_cv_working_alloca_h+:} false; then : |
3185942a | 6803 | $as_echo_n "(cached) " >&6 |
f73dda09 | 6804 | else |
ac50fbac | 6805 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6806 | /* end confdefs.h. */ |
b80f6443 JA |
6807 | #include <alloca.h> |
6808 | int | |
6809 | main () | |
6810 | { | |
6811 | char *p = (char *) alloca (2 * sizeof (int)); | |
3185942a | 6812 | if (p) return 0; |
b80f6443 JA |
6813 | ; |
6814 | return 0; | |
6815 | } | |
6816 | _ACEOF | |
ac50fbac | 6817 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 6818 | ac_cv_working_alloca_h=yes |
ccc6cda3 | 6819 | else |
ac50fbac | 6820 | ac_cv_working_alloca_h=no |
ccc6cda3 | 6821 | fi |
ac50fbac CR |
6822 | rm -f core conftest.err conftest.$ac_objext \ |
6823 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 | 6824 | fi |
ac50fbac | 6825 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 |
3185942a | 6826 | $as_echo "$ac_cv_working_alloca_h" >&6; } |
b80f6443 JA |
6827 | if test $ac_cv_working_alloca_h = yes; then |
6828 | ||
ac50fbac | 6829 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h |
ccc6cda3 JA |
6830 | |
6831 | fi | |
6832 | ||
ac50fbac | 6833 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
3185942a | 6834 | $as_echo_n "checking for alloca... " >&6; } |
ac50fbac | 6835 | if ${ac_cv_func_alloca_works+:} false; then : |
3185942a | 6836 | $as_echo_n "(cached) " >&6 |
f73dda09 | 6837 | else |
ac50fbac | 6838 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6839 | /* end confdefs.h. */ |
f73dda09 JA |
6840 | #ifdef __GNUC__ |
6841 | # define alloca __builtin_alloca | |
ccc6cda3 | 6842 | #else |
f73dda09 JA |
6843 | # ifdef _MSC_VER |
6844 | # include <malloc.h> | |
6845 | # define alloca _alloca | |
6846 | # else | |
3185942a | 6847 | # ifdef HAVE_ALLOCA_H |
f73dda09 JA |
6848 | # include <alloca.h> |
6849 | # else | |
6850 | # ifdef _AIX | |
6851 | #pragma alloca | |
6852 | # else | |
6853 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
ac50fbac | 6854 | void *alloca (size_t); |
f73dda09 JA |
6855 | # endif |
6856 | # endif | |
6857 | # endif | |
6858 | # endif | |
ccc6cda3 JA |
6859 | #endif |
6860 | ||
f73dda09 JA |
6861 | int |
6862 | main () | |
6863 | { | |
6864 | char *p = (char *) alloca (1); | |
3185942a | 6865 | if (p) return 0; |
f73dda09 JA |
6866 | ; |
6867 | return 0; | |
6868 | } | |
6869 | _ACEOF | |
ac50fbac | 6870 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 | 6871 | ac_cv_func_alloca_works=yes |
ccc6cda3 | 6872 | else |
ac50fbac | 6873 | ac_cv_func_alloca_works=no |
ccc6cda3 | 6874 | fi |
ac50fbac CR |
6875 | rm -f core conftest.err conftest.$ac_objext \ |
6876 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 | 6877 | fi |
ac50fbac | 6878 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
3185942a | 6879 | $as_echo "$ac_cv_func_alloca_works" >&6; } |
f73dda09 JA |
6880 | |
6881 | if test $ac_cv_func_alloca_works = yes; then | |
ccc6cda3 | 6882 | |
ac50fbac | 6883 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h |
f73dda09 | 6884 | |
ccc6cda3 | 6885 | else |
f73dda09 JA |
6886 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions |
6887 | # that cause trouble. Some versions do not even contain alloca or | |
6888 | # contain a buggy version. If you still want to use their alloca, | |
6889 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
ccc6cda3 | 6890 | |
3185942a | 6891 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext |
ccc6cda3 | 6892 | |
ac50fbac | 6893 | $as_echo "#define C_ALLOCA 1" >>confdefs.h |
f73dda09 | 6894 | |
b80f6443 | 6895 | |
ac50fbac | 6896 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 |
3185942a | 6897 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } |
ac50fbac | 6898 | if ${ac_cv_os_cray+:} false; then : |
3185942a | 6899 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6900 | else |
ac50fbac | 6901 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6902 | /* end confdefs.h. */ |
3185942a | 6903 | #if defined CRAY && ! defined CRAY2 |
f73dda09 JA |
6904 | webecray |
6905 | #else | |
6906 | wenotbecray | |
6907 | #endif | |
ccc6cda3 | 6908 | |
f73dda09 JA |
6909 | _ACEOF |
6910 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 6911 | $EGREP "webecray" >/dev/null 2>&1; then : |
f73dda09 | 6912 | ac_cv_os_cray=yes |
ccc6cda3 | 6913 | else |
f73dda09 | 6914 | ac_cv_os_cray=no |
ccc6cda3 JA |
6915 | fi |
6916 | rm -f conftest* | |
ccc6cda3 JA |
6917 | |
6918 | fi | |
ac50fbac | 6919 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 |
3185942a | 6920 | $as_echo "$ac_cv_os_cray" >&6; } |
f73dda09 JA |
6921 | if test $ac_cv_os_cray = yes; then |
6922 | for ac_func in _getb67 GETB67 getb67; do | |
3185942a | 6923 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
ac50fbac CR |
6924 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
6925 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
f73dda09 | 6926 | |
b80f6443 | 6927 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 6928 | #define CRAY_STACKSEG_END $ac_func |
b80f6443 | 6929 | _ACEOF |
ccc6cda3 | 6930 | |
f73dda09 | 6931 | break |
ccc6cda3 | 6932 | fi |
ccc6cda3 | 6933 | |
f73dda09 | 6934 | done |
ccc6cda3 JA |
6935 | fi |
6936 | ||
ac50fbac | 6937 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 |
3185942a | 6938 | $as_echo_n "checking stack direction for C alloca... " >&6; } |
ac50fbac | 6939 | if ${ac_cv_c_stack_direction+:} false; then : |
3185942a | 6940 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6941 | else |
ac50fbac | 6942 | if test "$cross_compiling" = yes; then : |
f73dda09 JA |
6943 | ac_cv_c_stack_direction=0 |
6944 | else | |
ac50fbac | 6945 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 6946 | /* end confdefs.h. */ |
3185942a | 6947 | $ac_includes_default |
f73dda09 | 6948 | int |
ac50fbac | 6949 | find_stack_direction (int *addr, int depth) |
f73dda09 | 6950 | { |
ac50fbac CR |
6951 | int dir, dummy = 0; |
6952 | if (! addr) | |
6953 | addr = &dummy; | |
6954 | *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; | |
6955 | dir = depth ? find_stack_direction (addr, depth - 1) : 0; | |
6956 | return dir + dummy; | |
f73dda09 | 6957 | } |
ccc6cda3 | 6958 | |
f73dda09 | 6959 | int |
ac50fbac | 6960 | main (int argc, char **argv) |
f73dda09 | 6961 | { |
ac50fbac | 6962 | return find_stack_direction (0, argc + !argv + 20) < 0; |
f73dda09 JA |
6963 | } |
6964 | _ACEOF | |
ac50fbac | 6965 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 | 6966 | ac_cv_c_stack_direction=1 |
ccc6cda3 | 6967 | else |
ac50fbac | 6968 | ac_cv_c_stack_direction=-1 |
ccc6cda3 | 6969 | fi |
ac50fbac CR |
6970 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6971 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 6972 | fi |
3185942a | 6973 | |
f73dda09 | 6974 | fi |
ac50fbac | 6975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 |
3185942a | 6976 | $as_echo "$ac_cv_c_stack_direction" >&6; } |
b80f6443 | 6977 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 6978 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
b80f6443 JA |
6979 | _ACEOF |
6980 | ||
ccc6cda3 | 6981 | |
ccc6cda3 JA |
6982 | fi |
6983 | ||
b80f6443 JA |
6984 | |
6985 | ||
f73dda09 | 6986 | |
ac50fbac CR |
6987 | for ac_header in $ac_header_list |
6988 | do : | |
6989 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
6990 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
6991 | " | |
6992 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
b80f6443 | 6993 | cat >>confdefs.h <<_ACEOF |
3185942a | 6994 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
b80f6443 | 6995 | _ACEOF |
ccc6cda3 | 6996 | |
cce855bc | 6997 | fi |
ccc6cda3 | 6998 | |
b80f6443 JA |
6999 | done |
7000 | ||
7001 | ||
0628567a | 7002 | |
0628567a | 7003 | |
0628567a | 7004 | |
f73dda09 | 7005 | |
0628567a | 7006 | |
3185942a | 7007 | |
ac50fbac CR |
7008 | for ac_func in getpagesize |
7009 | do : | |
7010 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
7011 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
b80f6443 | 7012 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 7013 | #define HAVE_GETPAGESIZE 1 |
b80f6443 | 7014 | _ACEOF |
f73dda09 | 7015 | |
b80f6443 JA |
7016 | fi |
7017 | done | |
7018 | ||
ac50fbac | 7019 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 |
3185942a | 7020 | $as_echo_n "checking for working mmap... " >&6; } |
ac50fbac | 7021 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : |
3185942a | 7022 | $as_echo_n "(cached) " >&6 |
b80f6443 | 7023 | else |
ac50fbac | 7024 | if test "$cross_compiling" = yes; then : |
b80f6443 | 7025 | ac_cv_func_mmap_fixed_mapped=no |
f73dda09 | 7026 | else |
ac50fbac | 7027 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7028 | /* end confdefs.h. */ |
b80f6443 JA |
7029 | $ac_includes_default |
7030 | /* malloc might have been renamed as rpl_malloc. */ | |
7031 | #undef malloc | |
7032 | ||
7033 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
7034 | Here is a matrix of mmap possibilities: | |
7035 | mmap private not fixed | |
7036 | mmap private fixed at somewhere currently unmapped | |
7037 | mmap private fixed at somewhere already mapped | |
7038 | mmap shared not fixed | |
7039 | mmap shared fixed at somewhere currently unmapped | |
7040 | mmap shared fixed at somewhere already mapped | |
7041 | For private mappings, we should verify that changes cannot be read() | |
7042 | back from the file, nor mmap's back from the file at a different | |
7043 | address. (There have been systems where private was not correctly | |
7044 | implemented like the infamous i386 svr4.0, and systems where the | |
7045 | VM page cache was not coherent with the file system buffer cache | |
7046 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
7047 | For shared mappings, we should conversely verify that changes get | |
7048 | propagated back to all the places they're supposed to be. | |
7049 | ||
7050 | Grep wants private fixed already mapped. | |
7051 | The main things grep needs to know about mmap are: | |
7052 | * does it exist and is it safe to write into the mmap'd area | |
7053 | * how to use it (BSD variants) */ | |
7054 | ||
7055 | #include <fcntl.h> | |
7056 | #include <sys/mman.h> | |
7057 | ||
3185942a | 7058 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H |
b80f6443 | 7059 | char *malloc (); |
f73dda09 | 7060 | #endif |
b80f6443 JA |
7061 | |
7062 | /* This mess was copied from the GNU getpagesize.h. */ | |
3185942a | 7063 | #ifndef HAVE_GETPAGESIZE |
b80f6443 JA |
7064 | # ifdef _SC_PAGESIZE |
7065 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
7066 | # else /* no _SC_PAGESIZE */ | |
3185942a | 7067 | # ifdef HAVE_SYS_PARAM_H |
b80f6443 JA |
7068 | # include <sys/param.h> |
7069 | # ifdef EXEC_PAGESIZE | |
7070 | # define getpagesize() EXEC_PAGESIZE | |
7071 | # else /* no EXEC_PAGESIZE */ | |
7072 | # ifdef NBPG | |
7073 | # define getpagesize() NBPG * CLSIZE | |
7074 | # ifndef CLSIZE | |
7075 | # define CLSIZE 1 | |
7076 | # endif /* no CLSIZE */ | |
7077 | # else /* no NBPG */ | |
7078 | # ifdef NBPC | |
7079 | # define getpagesize() NBPC | |
7080 | # else /* no NBPC */ | |
7081 | # ifdef PAGESIZE | |
7082 | # define getpagesize() PAGESIZE | |
7083 | # endif /* PAGESIZE */ | |
7084 | # endif /* no NBPC */ | |
7085 | # endif /* no NBPG */ | |
7086 | # endif /* no EXEC_PAGESIZE */ | |
7087 | # else /* no HAVE_SYS_PARAM_H */ | |
7088 | # define getpagesize() 8192 /* punt totally */ | |
7089 | # endif /* no HAVE_SYS_PARAM_H */ | |
7090 | # endif /* no _SC_PAGESIZE */ | |
7091 | ||
7092 | #endif /* no HAVE_GETPAGESIZE */ | |
ccc6cda3 | 7093 | |
f73dda09 JA |
7094 | int |
7095 | main () | |
7096 | { | |
b80f6443 | 7097 | char *data, *data2, *data3; |
ac50fbac | 7098 | const char *cdata2; |
b80f6443 | 7099 | int i, pagesize; |
ac50fbac | 7100 | int fd, fd2; |
f73dda09 | 7101 | |
b80f6443 JA |
7102 | pagesize = getpagesize (); |
7103 | ||
7104 | /* First, make a file with some known garbage in it. */ | |
7105 | data = (char *) malloc (pagesize); | |
7106 | if (!data) | |
3185942a | 7107 | return 1; |
b80f6443 JA |
7108 | for (i = 0; i < pagesize; ++i) |
7109 | *(data + i) = rand (); | |
7110 | umask (0); | |
7111 | fd = creat ("conftest.mmap", 0600); | |
7112 | if (fd < 0) | |
ac50fbac | 7113 | return 2; |
b80f6443 | 7114 | if (write (fd, data, pagesize) != pagesize) |
ac50fbac | 7115 | return 3; |
b80f6443 JA |
7116 | close (fd); |
7117 | ||
ac50fbac CR |
7118 | /* Next, check that the tail of a page is zero-filled. File must have |
7119 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
7120 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
7121 | if (fd2 < 0) | |
7122 | return 4; | |
7123 | cdata2 = ""; | |
7124 | if (write (fd2, cdata2, 1) != 1) | |
7125 | return 5; | |
7126 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
7127 | if (data2 == MAP_FAILED) | |
7128 | return 6; | |
7129 | for (i = 0; i < pagesize; ++i) | |
7130 | if (*(data2 + i)) | |
7131 | return 7; | |
7132 | close (fd2); | |
7133 | if (munmap (data2, pagesize)) | |
7134 | return 8; | |
7135 | ||
b80f6443 JA |
7136 | /* Next, try to mmap the file at a fixed address which already has |
7137 | something else allocated at it. If we can, also make sure that | |
7138 | we see the same garbage. */ | |
7139 | fd = open ("conftest.mmap", O_RDWR); | |
7140 | if (fd < 0) | |
ac50fbac | 7141 | return 9; |
b80f6443 | 7142 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, |
0628567a | 7143 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) |
ac50fbac | 7144 | return 10; |
b80f6443 JA |
7145 | for (i = 0; i < pagesize; ++i) |
7146 | if (*(data + i) != *(data2 + i)) | |
ac50fbac | 7147 | return 11; |
b80f6443 JA |
7148 | |
7149 | /* Finally, make sure that changes to the mapped area do not | |
7150 | percolate back to the file as seen by read(). (This is a bug on | |
7151 | some variants of i386 svr4.0.) */ | |
7152 | for (i = 0; i < pagesize; ++i) | |
7153 | *(data2 + i) = *(data2 + i) + 1; | |
7154 | data3 = (char *) malloc (pagesize); | |
7155 | if (!data3) | |
ac50fbac | 7156 | return 12; |
b80f6443 | 7157 | if (read (fd, data3, pagesize) != pagesize) |
ac50fbac | 7158 | return 13; |
b80f6443 JA |
7159 | for (i = 0; i < pagesize; ++i) |
7160 | if (*(data + i) != *(data3 + i)) | |
ac50fbac | 7161 | return 14; |
b80f6443 | 7162 | close (fd); |
3185942a | 7163 | return 0; |
f73dda09 JA |
7164 | } |
7165 | _ACEOF | |
ac50fbac | 7166 | if ac_fn_c_try_run "$LINENO"; then : |
b80f6443 | 7167 | ac_cv_func_mmap_fixed_mapped=yes |
f73dda09 | 7168 | else |
ac50fbac | 7169 | ac_cv_func_mmap_fixed_mapped=no |
f73dda09 | 7170 | fi |
ac50fbac CR |
7171 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7172 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 7173 | fi |
3185942a | 7174 | |
b80f6443 | 7175 | fi |
ac50fbac | 7176 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 |
3185942a | 7177 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } |
b80f6443 | 7178 | if test $ac_cv_func_mmap_fixed_mapped = yes; then |
f73dda09 | 7179 | |
ac50fbac | 7180 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
b80f6443 JA |
7181 | |
7182 | fi | |
ac50fbac | 7183 | rm -f conftest.mmap conftest.txt |
b80f6443 JA |
7184 | |
7185 | ||
ac50fbac | 7186 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5 |
3185942a | 7187 | $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; } |
ac50fbac | 7188 | if ${ac_cv_gnu_library_2_1+:} false; then : |
3185942a | 7189 | $as_echo_n "(cached) " >&6 |
b80f6443 | 7190 | else |
ac50fbac | 7191 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7192 | /* end confdefs.h. */ |
b80f6443 JA |
7193 | |
7194 | #include <features.h> | |
7195 | #ifdef __GNU_LIBRARY__ | |
7196 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) | |
7197 | Lucky GNU user | |
7198 | #endif | |
7199 | #endif | |
ccc6cda3 | 7200 | |
b80f6443 JA |
7201 | _ACEOF |
7202 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 7203 | $EGREP "Lucky GNU user" >/dev/null 2>&1; then : |
b80f6443 JA |
7204 | ac_cv_gnu_library_2_1=yes |
7205 | else | |
7206 | ac_cv_gnu_library_2_1=no | |
ccc6cda3 | 7207 | fi |
b80f6443 JA |
7208 | rm -f conftest* |
7209 | ||
7210 | ||
f73dda09 | 7211 | |
ccc6cda3 | 7212 | fi |
ac50fbac | 7213 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5 |
3185942a | 7214 | $as_echo "$ac_cv_gnu_library_2_1" >&6; } |
ccc6cda3 | 7215 | |
b80f6443 JA |
7216 | GLIBC21="$ac_cv_gnu_library_2_1" |
7217 | ||
7218 | ||
7219 | ||
7220 | ||
ac50fbac | 7221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether integer division by zero raises SIGFPE" >&5 |
3185942a | 7222 | $as_echo_n "checking whether integer division by zero raises SIGFPE... " >&6; } |
ac50fbac | 7223 | if ${gt_cv_int_divbyzero_sigfpe+:} false; then : |
3185942a | 7224 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 7225 | else |
b80f6443 | 7226 | |
ac50fbac | 7227 | if test "$cross_compiling" = yes; then : |
b80f6443 JA |
7228 | |
7229 | # Guess based on the CPU. | |
7230 | case "$host_cpu" in | |
7231 | alpha* | i3456786 | m68k | s390*) | |
7232 | gt_cv_int_divbyzero_sigfpe="guessing yes";; | |
7233 | *) | |
7234 | gt_cv_int_divbyzero_sigfpe="guessing no";; | |
7235 | esac | |
7236 | ||
ccc6cda3 | 7237 | else |
ac50fbac | 7238 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7239 | /* end confdefs.h. */ |
b80f6443 JA |
7240 | |
7241 | #include <stdlib.h> | |
7242 | #include <signal.h> | |
7243 | ||
7244 | static void | |
7245 | #ifdef __cplusplus | |
7246 | sigfpe_handler (int sig) | |
7247 | #else | |
7248 | sigfpe_handler (sig) int sig; | |
7249 | #endif | |
f73dda09 | 7250 | { |
b80f6443 JA |
7251 | /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ |
7252 | exit (sig != SIGFPE); | |
7253 | } | |
7254 | ||
7255 | int x = 1; | |
7256 | int y = 0; | |
7257 | int z; | |
7258 | int nan; | |
7259 | ||
7260 | int main () | |
7261 | { | |
7262 | signal (SIGFPE, sigfpe_handler); | |
7263 | /* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */ | |
7264 | #if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP) | |
7265 | signal (SIGTRAP, sigfpe_handler); | |
7266 | #endif | |
7267 | /* Linux/SPARC yields signal SIGILL. */ | |
7268 | #if defined (__sparc__) && defined (__linux__) | |
7269 | signal (SIGILL, sigfpe_handler); | |
7270 | #endif | |
7271 | ||
7272 | z = x / y; | |
7273 | nan = y / y; | |
7274 | exit (1); | |
f73dda09 | 7275 | } |
b80f6443 | 7276 | |
f73dda09 | 7277 | _ACEOF |
ac50fbac | 7278 | if ac_fn_c_try_run "$LINENO"; then : |
b80f6443 | 7279 | gt_cv_int_divbyzero_sigfpe=yes |
ccc6cda3 | 7280 | else |
ac50fbac | 7281 | gt_cv_int_divbyzero_sigfpe=no |
ccc6cda3 | 7282 | fi |
ac50fbac CR |
7283 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7284 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 JA |
7285 | fi |
7286 | ||
3185942a | 7287 | |
ccc6cda3 | 7288 | fi |
ac50fbac | 7289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_int_divbyzero_sigfpe" >&5 |
3185942a | 7290 | $as_echo "$gt_cv_int_divbyzero_sigfpe" >&6; } |
b80f6443 JA |
7291 | case "$gt_cv_int_divbyzero_sigfpe" in |
7292 | *yes) value=1;; | |
7293 | *) value=0;; | |
7294 | esac | |
ccc6cda3 | 7295 | |
b80f6443 JA |
7296 | cat >>confdefs.h <<_ACEOF |
7297 | #define INTDIV0_RAISES_SIGFPE $value | |
7298 | _ACEOF | |
ccc6cda3 | 7299 | |
ccc6cda3 JA |
7300 | |
7301 | ||
ac50fbac | 7302 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
3185942a | 7303 | $as_echo_n "checking for inttypes.h... " >&6; } |
ac50fbac | 7304 | if ${jm_ac_cv_header_inttypes_h+:} false; then : |
3185942a | 7305 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 7306 | else |
ac50fbac | 7307 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7308 | /* end confdefs.h. */ |
f73dda09 | 7309 | #include <sys/types.h> |
b80f6443 | 7310 | #include <inttypes.h> |
f73dda09 JA |
7311 | int |
7312 | main () | |
7313 | { | |
b80f6443 | 7314 | uintmax_t i = (uintmax_t) -1; |
f73dda09 JA |
7315 | ; |
7316 | return 0; | |
7317 | } | |
7318 | _ACEOF | |
ac50fbac | 7319 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 7320 | jm_ac_cv_header_inttypes_h=yes |
ccc6cda3 | 7321 | else |
ac50fbac | 7322 | jm_ac_cv_header_inttypes_h=no |
ccc6cda3 | 7323 | fi |
3185942a | 7324 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 7325 | fi |
ac50fbac | 7326 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_inttypes_h" >&5 |
3185942a | 7327 | $as_echo "$jm_ac_cv_header_inttypes_h" >&6; } |
b80f6443 | 7328 | if test $jm_ac_cv_header_inttypes_h = yes; then |
f73dda09 | 7329 | |
b80f6443 JA |
7330 | cat >>confdefs.h <<_ACEOF |
7331 | #define HAVE_INTTYPES_H_WITH_UINTMAX 1 | |
7332 | _ACEOF | |
ccc6cda3 | 7333 | |
b80f6443 JA |
7334 | fi |
7335 | ||
7336 | ||
ac50fbac | 7337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5 |
3185942a | 7338 | $as_echo_n "checking for stdint.h... " >&6; } |
ac50fbac | 7339 | if ${jm_ac_cv_header_stdint_h+:} false; then : |
3185942a | 7340 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 7341 | else |
ac50fbac | 7342 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7343 | /* end confdefs.h. */ |
b80f6443 JA |
7344 | #include <sys/types.h> |
7345 | #include <stdint.h> | |
f73dda09 JA |
7346 | int |
7347 | main () | |
7348 | { | |
b80f6443 | 7349 | uintmax_t i = (uintmax_t) -1; |
f73dda09 JA |
7350 | ; |
7351 | return 0; | |
7352 | } | |
7353 | _ACEOF | |
ac50fbac | 7354 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 7355 | jm_ac_cv_header_stdint_h=yes |
f73dda09 | 7356 | else |
ac50fbac | 7357 | jm_ac_cv_header_stdint_h=no |
f73dda09 | 7358 | fi |
3185942a | 7359 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 7360 | fi |
ac50fbac | 7361 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_stdint_h" >&5 |
3185942a | 7362 | $as_echo "$jm_ac_cv_header_stdint_h" >&6; } |
b80f6443 | 7363 | if test $jm_ac_cv_header_stdint_h = yes; then |
f73dda09 | 7364 | |
b80f6443 JA |
7365 | cat >>confdefs.h <<_ACEOF |
7366 | #define HAVE_STDINT_H_WITH_UINTMAX 1 | |
7367 | _ACEOF | |
f73dda09 | 7368 | |
b80f6443 JA |
7369 | fi |
7370 | ||
7371 | ||
ac50fbac | 7372 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 |
3185942a | 7373 | $as_echo_n "checking for unsigned long long... " >&6; } |
ac50fbac | 7374 | if ${ac_cv_type_unsigned_long_long+:} false; then : |
3185942a | 7375 | $as_echo_n "(cached) " >&6 |
f73dda09 | 7376 | else |
ac50fbac | 7377 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7378 | /* end confdefs.h. */ |
b80f6443 | 7379 | unsigned long long ull = 1; int i = 63; |
f73dda09 JA |
7380 | int |
7381 | main () | |
7382 | { | |
b80f6443 JA |
7383 | unsigned long long ullmax = (unsigned long long) -1; |
7384 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
f73dda09 JA |
7385 | ; |
7386 | return 0; | |
7387 | } | |
7388 | _ACEOF | |
ac50fbac | 7389 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 7390 | ac_cv_type_unsigned_long_long=yes |
f73dda09 | 7391 | else |
ac50fbac | 7392 | ac_cv_type_unsigned_long_long=no |
f73dda09 | 7393 | fi |
ac50fbac CR |
7394 | rm -f core conftest.err conftest.$ac_objext \ |
7395 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 7396 | fi |
ac50fbac | 7397 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long" >&5 |
3185942a | 7398 | $as_echo "$ac_cv_type_unsigned_long_long" >&6; } |
b80f6443 | 7399 | if test $ac_cv_type_unsigned_long_long = yes; then |
f73dda09 | 7400 | |
ac50fbac | 7401 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h |
f73dda09 | 7402 | |
b80f6443 | 7403 | fi |
7117c2d2 | 7404 | |
7117c2d2 | 7405 | |
b80f6443 JA |
7406 | |
7407 | ||
7408 | if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then | |
7409 | ||
7410 | test $ac_cv_type_unsigned_long_long = yes \ | |
7411 | && ac_type='unsigned long long' \ | |
7412 | || ac_type='unsigned long' | |
7413 | ||
7414 | cat >>confdefs.h <<_ACEOF | |
7415 | #define uintmax_t $ac_type | |
7117c2d2 | 7416 | _ACEOF |
7117c2d2 | 7417 | |
b80f6443 | 7418 | else |
7117c2d2 | 7419 | |
ac50fbac | 7420 | $as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h |
b80f6443 JA |
7421 | |
7422 | fi | |
7423 | ||
7424 | ||
ac50fbac | 7425 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
3185942a | 7426 | $as_echo_n "checking for inttypes.h... " >&6; } |
ac50fbac | 7427 | if ${gt_cv_header_inttypes_h+:} false; then : |
3185942a | 7428 | $as_echo_n "(cached) " >&6 |
f73dda09 | 7429 | else |
f73dda09 | 7430 | |
ac50fbac | 7431 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7432 | /* end confdefs.h. */ |
b80f6443 JA |
7433 | #include <sys/types.h> |
7434 | #include <inttypes.h> | |
f73dda09 JA |
7435 | int |
7436 | main () | |
7437 | { | |
f73dda09 JA |
7438 | |
7439 | ; | |
7440 | return 0; | |
7441 | } | |
7442 | _ACEOF | |
ac50fbac | 7443 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 7444 | gt_cv_header_inttypes_h=yes |
f73dda09 | 7445 | else |
ac50fbac | 7446 | gt_cv_header_inttypes_h=no |
f73dda09 | 7447 | fi |
3185942a | 7448 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b80f6443 | 7449 | |
f73dda09 | 7450 | fi |
ac50fbac | 7451 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_header_inttypes_h" >&5 |
3185942a | 7452 | $as_echo "$gt_cv_header_inttypes_h" >&6; } |
b80f6443 | 7453 | if test $gt_cv_header_inttypes_h = yes; then |
f73dda09 | 7454 | |
b80f6443 JA |
7455 | cat >>confdefs.h <<_ACEOF |
7456 | #define HAVE_INTTYPES_H 1 | |
7457 | _ACEOF | |
f73dda09 | 7458 | |
b80f6443 | 7459 | fi |
f73dda09 | 7460 | |
b80f6443 JA |
7461 | |
7462 | ||
7463 | if test $gt_cv_header_inttypes_h = yes; then | |
ac50fbac | 7464 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5 |
3185942a | 7465 | $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; } |
ac50fbac | 7466 | if ${gt_cv_inttypes_pri_broken+:} false; then : |
3185942a | 7467 | $as_echo_n "(cached) " >&6 |
f73dda09 | 7468 | else |
b80f6443 | 7469 | |
ac50fbac | 7470 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 7471 | /* end confdefs.h. */ |
b80f6443 JA |
7472 | #include <inttypes.h> |
7473 | #ifdef PRId32 | |
7474 | char *p = PRId32; | |
f73dda09 | 7475 | #endif |
f73dda09 JA |
7476 | |
7477 | int | |
7478 | main () | |
7479 | { | |
f73dda09 JA |
7480 | |
7481 | ; | |
7482 | return 0; | |
7483 | } | |
7484 | _ACEOF | |
ac50fbac | 7485 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 7486 | gt_cv_inttypes_pri_broken=no |
f73dda09 | 7487 | else |
ac50fbac | 7488 | gt_cv_inttypes_pri_broken=yes |
f73dda09 | 7489 | fi |
3185942a | 7490 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 JA |
7491 | |
7492 | fi | |
ac50fbac | 7493 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5 |
3185942a | 7494 | $as_echo "$gt_cv_inttypes_pri_broken" >&6; } |
b80f6443 JA |
7495 | fi |
7496 | if test "$gt_cv_inttypes_pri_broken" = yes; then | |
f73dda09 | 7497 | |
b80f6443 JA |
7498 | cat >>confdefs.h <<_ACEOF |
7499 | #define PRI_MACROS_BROKEN 1 | |
7500 | _ACEOF | |
f73dda09 | 7501 | |
b80f6443 | 7502 | fi |
f73dda09 | 7503 | |
b80f6443 JA |
7504 | |
7505 | if test "X$prefix" = "XNONE"; then | |
7506 | acl_final_prefix="$ac_default_prefix" | |
7507 | else | |
7508 | acl_final_prefix="$prefix" | |
7509 | fi | |
7510 | if test "X$exec_prefix" = "XNONE"; then | |
7511 | acl_final_exec_prefix='${prefix}' | |
7512 | else | |
7513 | acl_final_exec_prefix="$exec_prefix" | |
7514 | fi | |
7515 | acl_save_prefix="$prefix" | |
7516 | prefix="$acl_final_prefix" | |
7517 | eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" | |
7518 | prefix="$acl_save_prefix" | |
7519 | ||
7520 | ||
3185942a | 7521 | # Check whether --with-gnu-ld was given. |
ac50fbac | 7522 | if test "${with_gnu_ld+set}" = set; then : |
3185942a | 7523 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes |
f73dda09 | 7524 | else |
b80f6443 | 7525 | with_gnu_ld=no |
3185942a JA |
7526 | fi |
7527 | ||
b80f6443 JA |
7528 | # Prepare PATH_SEPARATOR. |
7529 | # The user is always right. | |
7530 | if test "${PATH_SEPARATOR+set}" != set; then | |
7531 | echo "#! /bin/sh" >conf$$.sh | |
7532 | echo "exit 0" >>conf$$.sh | |
7533 | chmod +x conf$$.sh | |
7534 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
7535 | PATH_SEPARATOR=';' | |
7536 | else | |
7537 | PATH_SEPARATOR=: | |
7538 | fi | |
7539 | rm -f conf$$.sh | |
7540 | fi | |
7541 | ac_prog=ld | |
7542 | if test "$GCC" = yes; then | |
7543 | # Check if gcc -print-prog-name=ld gives a path. | |
ac50fbac | 7544 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 |
3185942a | 7545 | $as_echo_n "checking for ld used by GCC... " >&6; } |
b80f6443 JA |
7546 | case $host in |
7547 | *-*-mingw*) | |
7548 | # gcc leaves a trailing carriage return which upsets mingw | |
7549 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
7550 | *) | |
7551 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
7552 | esac | |
7553 | case $ac_prog in | |
7554 | # Accept absolute paths. | |
7555 | [\\/]* | [A-Za-z]:[\\/]*) | |
7556 | re_direlt='/[^/][^/]*/\.\./' | |
7557 | # Canonicalize the path of ld | |
7558 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
7559 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
7560 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
7561 | done | |
7562 | test -z "$LD" && LD="$ac_prog" | |
7563 | ;; | |
7564 | "") | |
7565 | # If it fails, then pretend we aren't using GCC. | |
7566 | ac_prog=ld | |
7567 | ;; | |
7568 | *) | |
7569 | # If it is relative, then search for the first ld in PATH. | |
7570 | with_gnu_ld=unknown | |
7571 | ;; | |
7572 | esac | |
7573 | elif test "$with_gnu_ld" = yes; then | |
ac50fbac | 7574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
3185942a | 7575 | $as_echo_n "checking for GNU ld... " >&6; } |
b80f6443 | 7576 | else |
ac50fbac | 7577 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
3185942a | 7578 | $as_echo_n "checking for non-GNU ld... " >&6; } |
b80f6443 | 7579 | fi |
ac50fbac | 7580 | if ${acl_cv_path_LD+:} false; then : |
3185942a | 7581 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
7582 | else |
7583 | if test -z "$LD"; then | |
7584 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" | |
7585 | for ac_dir in $PATH; do | |
7586 | test -z "$ac_dir" && ac_dir=. | |
7587 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
7588 | acl_cv_path_LD="$ac_dir/$ac_prog" | |
7589 | # Check to see if the program is GNU ld. I'd rather use --version, | |
7590 | # but apparently some GNU ld's only accept -v. | |
7591 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
7592 | if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then | |
7593 | test "$with_gnu_ld" != no && break | |
7594 | else | |
7595 | test "$with_gnu_ld" != yes && break | |
7596 | fi | |
7597 | fi | |
7598 | done | |
7599 | IFS="$ac_save_ifs" | |
7600 | else | |
7601 | acl_cv_path_LD="$LD" # Let the user override the test with a path. | |
f73dda09 | 7602 | fi |
f73dda09 | 7603 | fi |
f73dda09 | 7604 | |
b80f6443 JA |
7605 | LD="$acl_cv_path_LD" |
7606 | if test -n "$LD"; then | |
ac50fbac | 7607 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
3185942a | 7608 | $as_echo "$LD" >&6; } |
f73dda09 | 7609 | else |
ac50fbac | 7610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 7611 | $as_echo "no" >&6; } |
f73dda09 | 7612 | fi |
ac50fbac CR |
7613 | test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 |
7614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
3185942a | 7615 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } |
ac50fbac | 7616 | if ${acl_cv_prog_gnu_ld+:} false; then : |
3185942a | 7617 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
7618 | else |
7619 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
7620 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then | |
7621 | acl_cv_prog_gnu_ld=yes | |
7622 | else | |
7623 | acl_cv_prog_gnu_ld=no | |
7624 | fi | |
7625 | fi | |
ac50fbac | 7626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5 |
3185942a | 7627 | $as_echo "$acl_cv_prog_gnu_ld" >&6; } |
b80f6443 JA |
7628 | with_gnu_ld=$acl_cv_prog_gnu_ld |
7629 | ||
7630 | ||
7631 | ||
ac50fbac | 7632 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 |
3185942a | 7633 | $as_echo_n "checking for shared library run path origin... " >&6; } |
ac50fbac | 7634 | if ${acl_cv_rpath+:} false; then : |
3185942a | 7635 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
7636 | else |
7637 | ||
7638 | CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ | |
7639 | ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh | |
7640 | . ./conftest.sh | |
7641 | rm -f ./conftest.sh | |
7642 | acl_cv_rpath=done | |
7643 | ||
7644 | fi | |
ac50fbac | 7645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 |
3185942a | 7646 | $as_echo "$acl_cv_rpath" >&6; } |
b80f6443 JA |
7647 | wl="$acl_cv_wl" |
7648 | libext="$acl_cv_libext" | |
7649 | shlibext="$acl_cv_shlibext" | |
7650 | hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" | |
7651 | hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" | |
7652 | hardcode_direct="$acl_cv_hardcode_direct" | |
7653 | hardcode_minus_L="$acl_cv_hardcode_minus_L" | |
3185942a | 7654 | # Check whether --enable-rpath was given. |
ac50fbac | 7655 | if test "${enable_rpath+set}" = set; then : |
3185942a | 7656 | enableval=$enable_rpath; : |
b80f6443 JA |
7657 | else |
7658 | enable_rpath=yes | |
3185942a JA |
7659 | fi |
7660 | ||
b80f6443 JA |
7661 | |
7662 | ||
7663 | ||
7664 | ||
7665 | ||
7666 | ||
7667 | ||
7668 | use_additional=yes | |
7669 | ||
7670 | acl_save_prefix="$prefix" | |
7671 | prefix="$acl_final_prefix" | |
7672 | acl_save_exec_prefix="$exec_prefix" | |
7673 | exec_prefix="$acl_final_exec_prefix" | |
7674 | ||
7675 | eval additional_includedir=\"$includedir\" | |
7676 | eval additional_libdir=\"$libdir\" | |
7677 | ||
7678 | exec_prefix="$acl_save_exec_prefix" | |
7679 | prefix="$acl_save_prefix" | |
7680 | ||
7681 | ||
3185942a | 7682 | # Check whether --with-libiconv-prefix was given. |
ac50fbac | 7683 | if test "${with_libiconv_prefix+set}" = set; then : |
3185942a | 7684 | withval=$with_libiconv_prefix; |
b80f6443 JA |
7685 | if test "X$withval" = "Xno"; then |
7686 | use_additional=no | |
7687 | else | |
7688 | if test "X$withval" = "X"; then | |
7689 | ||
7690 | acl_save_prefix="$prefix" | |
7691 | prefix="$acl_final_prefix" | |
7692 | acl_save_exec_prefix="$exec_prefix" | |
7693 | exec_prefix="$acl_final_exec_prefix" | |
7694 | ||
7695 | eval additional_includedir=\"$includedir\" | |
7696 | eval additional_libdir=\"$libdir\" | |
7697 | ||
7698 | exec_prefix="$acl_save_exec_prefix" | |
7699 | prefix="$acl_save_prefix" | |
7700 | ||
7701 | else | |
7702 | additional_includedir="$withval/include" | |
7703 | additional_libdir="$withval/lib" | |
7704 | fi | |
7705 | fi | |
7706 | ||
3185942a JA |
7707 | fi |
7708 | ||
b80f6443 JA |
7709 | LIBICONV= |
7710 | LTLIBICONV= | |
7711 | INCICONV= | |
7712 | rpathdirs= | |
7713 | ltrpathdirs= | |
7714 | names_already_handled= | |
7715 | names_next_round='iconv ' | |
7716 | while test -n "$names_next_round"; do | |
7717 | names_this_round="$names_next_round" | |
7718 | names_next_round= | |
7719 | for name in $names_this_round; do | |
7720 | already_handled= | |
7721 | for n in $names_already_handled; do | |
7722 | if test "$n" = "$name"; then | |
7723 | already_handled=yes | |
7724 | break | |
7725 | fi | |
7726 | done | |
7727 | if test -z "$already_handled"; then | |
7728 | names_already_handled="$names_already_handled $name" | |
7729 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
7730 | eval value=\"\$HAVE_LIB$uppername\" | |
7731 | if test -n "$value"; then | |
7732 | if test "$value" = yes; then | |
7733 | eval value=\"\$LIB$uppername\" | |
7734 | test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" | |
7735 | eval value=\"\$LTLIB$uppername\" | |
7736 | test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" | |
7737 | else | |
7738 | : | |
7739 | fi | |
7740 | else | |
7741 | found_dir= | |
7742 | found_la= | |
7743 | found_so= | |
7744 | found_a= | |
7745 | if test $use_additional = yes; then | |
ac50fbac | 7746 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
b80f6443 JA |
7747 | found_dir="$additional_libdir" |
7748 | found_so="$additional_libdir/lib$name.$shlibext" | |
7749 | if test -f "$additional_libdir/lib$name.la"; then | |
7750 | found_la="$additional_libdir/lib$name.la" | |
7751 | fi | |
7752 | else | |
7753 | if test -f "$additional_libdir/lib$name.$libext"; then | |
7754 | found_dir="$additional_libdir" | |
7755 | found_a="$additional_libdir/lib$name.$libext" | |
7756 | if test -f "$additional_libdir/lib$name.la"; then | |
7757 | found_la="$additional_libdir/lib$name.la" | |
7758 | fi | |
7759 | fi | |
7760 | fi | |
7761 | fi | |
7762 | if test "X$found_dir" = "X"; then | |
7763 | for x in $LDFLAGS $LTLIBICONV; do | |
7764 | ||
7765 | acl_save_prefix="$prefix" | |
7766 | prefix="$acl_final_prefix" | |
7767 | acl_save_exec_prefix="$exec_prefix" | |
7768 | exec_prefix="$acl_final_exec_prefix" | |
7769 | eval x=\"$x\" | |
7770 | exec_prefix="$acl_save_exec_prefix" | |
7771 | prefix="$acl_save_prefix" | |
7772 | ||
7773 | case "$x" in | |
7774 | -L*) | |
7775 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
ac50fbac | 7776 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
b80f6443 JA |
7777 | found_dir="$dir" |
7778 | found_so="$dir/lib$name.$shlibext" | |
7779 | if test -f "$dir/lib$name.la"; then | |
7780 | found_la="$dir/lib$name.la" | |
7781 | fi | |
7782 | else | |
7783 | if test -f "$dir/lib$name.$libext"; then | |
7784 | found_dir="$dir" | |
7785 | found_a="$dir/lib$name.$libext" | |
7786 | if test -f "$dir/lib$name.la"; then | |
7787 | found_la="$dir/lib$name.la" | |
7788 | fi | |
7789 | fi | |
7790 | fi | |
7791 | ;; | |
7792 | esac | |
7793 | if test "X$found_dir" != "X"; then | |
7794 | break | |
7795 | fi | |
7796 | done | |
7797 | fi | |
7798 | if test "X$found_dir" != "X"; then | |
7799 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" | |
7800 | if test "X$found_so" != "X"; then | |
7801 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
7802 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7803 | else | |
7804 | haveit= | |
7805 | for x in $ltrpathdirs; do | |
7806 | if test "X$x" = "X$found_dir"; then | |
7807 | haveit=yes | |
7808 | break | |
7809 | fi | |
7810 | done | |
7811 | if test -z "$haveit"; then | |
7812 | ltrpathdirs="$ltrpathdirs $found_dir" | |
7813 | fi | |
7814 | if test "$hardcode_direct" = yes; then | |
7815 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7816 | else | |
7817 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
7818 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7819 | haveit= | |
7820 | for x in $rpathdirs; do | |
7821 | if test "X$x" = "X$found_dir"; then | |
7822 | haveit=yes | |
7823 | break | |
7824 | fi | |
7825 | done | |
7826 | if test -z "$haveit"; then | |
7827 | rpathdirs="$rpathdirs $found_dir" | |
7828 | fi | |
7829 | else | |
7830 | haveit= | |
7831 | for x in $LDFLAGS $LIBICONV; do | |
7832 | ||
7833 | acl_save_prefix="$prefix" | |
7834 | prefix="$acl_final_prefix" | |
7835 | acl_save_exec_prefix="$exec_prefix" | |
7836 | exec_prefix="$acl_final_exec_prefix" | |
7837 | eval x=\"$x\" | |
7838 | exec_prefix="$acl_save_exec_prefix" | |
7839 | prefix="$acl_save_prefix" | |
7840 | ||
7841 | if test "X$x" = "X-L$found_dir"; then | |
7842 | haveit=yes | |
7843 | break | |
7844 | fi | |
7845 | done | |
7846 | if test -z "$haveit"; then | |
7847 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" | |
7848 | fi | |
7849 | if test "$hardcode_minus_L" != no; then | |
7850 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7851 | else | |
7852 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
7853 | fi | |
7854 | fi | |
7855 | fi | |
7856 | fi | |
7857 | else | |
7858 | if test "X$found_a" != "X"; then | |
7859 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" | |
7860 | else | |
7861 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" | |
7862 | fi | |
7863 | fi | |
7864 | additional_includedir= | |
7865 | case "$found_dir" in | |
7866 | */lib | */lib/) | |
7867 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
7868 | additional_includedir="$basedir/include" | |
7869 | ;; | |
7870 | esac | |
7871 | if test "X$additional_includedir" != "X"; then | |
7872 | if test "X$additional_includedir" != "X/usr/include"; then | |
7873 | haveit= | |
7874 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
7875 | if test -n "$GCC"; then | |
7876 | case $host_os in | |
7877 | linux*) haveit=yes;; | |
7878 | esac | |
7879 | fi | |
7880 | fi | |
7881 | if test -z "$haveit"; then | |
7882 | for x in $CPPFLAGS $INCICONV; do | |
7883 | ||
7884 | acl_save_prefix="$prefix" | |
7885 | prefix="$acl_final_prefix" | |
7886 | acl_save_exec_prefix="$exec_prefix" | |
7887 | exec_prefix="$acl_final_exec_prefix" | |
7888 | eval x=\"$x\" | |
7889 | exec_prefix="$acl_save_exec_prefix" | |
7890 | prefix="$acl_save_prefix" | |
7891 | ||
7892 | if test "X$x" = "X-I$additional_includedir"; then | |
7893 | haveit=yes | |
7894 | break | |
7895 | fi | |
7896 | done | |
7897 | if test -z "$haveit"; then | |
7898 | if test -d "$additional_includedir"; then | |
7899 | INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" | |
7900 | fi | |
7901 | fi | |
7902 | fi | |
7903 | fi | |
7904 | fi | |
7905 | if test -n "$found_la"; then | |
7906 | save_libdir="$libdir" | |
7907 | case "$found_la" in | |
7908 | */* | *\\*) . "$found_la" ;; | |
7909 | *) . "./$found_la" ;; | |
7910 | esac | |
7911 | libdir="$save_libdir" | |
7912 | for dep in $dependency_libs; do | |
7913 | case "$dep" in | |
7914 | -L*) | |
7915 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
7916 | if test "X$additional_libdir" != "X/usr/lib"; then | |
7917 | haveit= | |
7918 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
7919 | if test -n "$GCC"; then | |
7920 | case $host_os in | |
7921 | linux*) haveit=yes;; | |
7922 | esac | |
7923 | fi | |
7924 | fi | |
7925 | if test -z "$haveit"; then | |
7926 | haveit= | |
7927 | for x in $LDFLAGS $LIBICONV; do | |
7928 | ||
7929 | acl_save_prefix="$prefix" | |
7930 | prefix="$acl_final_prefix" | |
7931 | acl_save_exec_prefix="$exec_prefix" | |
7932 | exec_prefix="$acl_final_exec_prefix" | |
7933 | eval x=\"$x\" | |
7934 | exec_prefix="$acl_save_exec_prefix" | |
7935 | prefix="$acl_save_prefix" | |
7936 | ||
7937 | if test "X$x" = "X-L$additional_libdir"; then | |
7938 | haveit=yes | |
7939 | break | |
7940 | fi | |
7941 | done | |
7942 | if test -z "$haveit"; then | |
7943 | if test -d "$additional_libdir"; then | |
7944 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" | |
7945 | fi | |
7946 | fi | |
7947 | haveit= | |
7948 | for x in $LDFLAGS $LTLIBICONV; do | |
7949 | ||
7950 | acl_save_prefix="$prefix" | |
7951 | prefix="$acl_final_prefix" | |
7952 | acl_save_exec_prefix="$exec_prefix" | |
7953 | exec_prefix="$acl_final_exec_prefix" | |
7954 | eval x=\"$x\" | |
7955 | exec_prefix="$acl_save_exec_prefix" | |
7956 | prefix="$acl_save_prefix" | |
7957 | ||
7958 | if test "X$x" = "X-L$additional_libdir"; then | |
7959 | haveit=yes | |
7960 | break | |
7961 | fi | |
7962 | done | |
7963 | if test -z "$haveit"; then | |
7964 | if test -d "$additional_libdir"; then | |
7965 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" | |
7966 | fi | |
7967 | fi | |
7968 | fi | |
7969 | fi | |
7970 | ;; | |
7971 | -R*) | |
7972 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
7973 | if test "$enable_rpath" != no; then | |
7974 | haveit= | |
7975 | for x in $rpathdirs; do | |
7976 | if test "X$x" = "X$dir"; then | |
7977 | haveit=yes | |
7978 | break | |
7979 | fi | |
7980 | done | |
7981 | if test -z "$haveit"; then | |
7982 | rpathdirs="$rpathdirs $dir" | |
7983 | fi | |
7984 | haveit= | |
7985 | for x in $ltrpathdirs; do | |
7986 | if test "X$x" = "X$dir"; then | |
7987 | haveit=yes | |
7988 | break | |
7989 | fi | |
7990 | done | |
7991 | if test -z "$haveit"; then | |
7992 | ltrpathdirs="$ltrpathdirs $dir" | |
7993 | fi | |
7994 | fi | |
7995 | ;; | |
7996 | -l*) | |
7997 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
7998 | ;; | |
7999 | *.la) | |
8000 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
8001 | ;; | |
8002 | *) | |
8003 | LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" | |
8004 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" | |
8005 | ;; | |
8006 | esac | |
8007 | done | |
8008 | fi | |
8009 | else | |
8010 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
8011 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" | |
8012 | fi | |
8013 | fi | |
8014 | fi | |
8015 | done | |
8016 | done | |
8017 | if test "X$rpathdirs" != "X"; then | |
8018 | if test -n "$hardcode_libdir_separator"; then | |
8019 | alldirs= | |
8020 | for found_dir in $rpathdirs; do | |
8021 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
8022 | done | |
8023 | acl_save_libdir="$libdir" | |
8024 | libdir="$alldirs" | |
8025 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8026 | libdir="$acl_save_libdir" | |
8027 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
8028 | else | |
8029 | for found_dir in $rpathdirs; do | |
8030 | acl_save_libdir="$libdir" | |
8031 | libdir="$found_dir" | |
8032 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8033 | libdir="$acl_save_libdir" | |
8034 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
8035 | done | |
8036 | fi | |
8037 | fi | |
8038 | if test "X$ltrpathdirs" != "X"; then | |
8039 | for found_dir in $ltrpathdirs; do | |
8040 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" | |
8041 | done | |
8042 | fi | |
8043 | ||
8044 | ||
8045 | ||
8046 | ||
ac50fbac | 8047 | for ac_header in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ |
b80f6443 | 8048 | stdlib.h string.h unistd.h sys/param.h |
ac50fbac CR |
8049 | do : |
8050 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
8051 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
8052 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
b80f6443 | 8053 | cat >>confdefs.h <<_ACEOF |
3185942a | 8054 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
b80f6443 JA |
8055 | _ACEOF |
8056 | ||
8057 | fi | |
8058 | ||
f73dda09 JA |
8059 | done |
8060 | ||
ac50fbac | 8061 | for ac_func in feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ |
3185942a | 8062 | geteuid getgid getuid mempcpy munmap putenv setenv setlocale localeconv stpcpy \ |
b80f6443 JA |
8063 | strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ |
8064 | __fsetlocking | |
ac50fbac CR |
8065 | do : |
8066 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
8067 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
8068 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
b80f6443 | 8069 | cat >>confdefs.h <<_ACEOF |
3185942a | 8070 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
b80f6443 | 8071 | _ACEOF |
f73dda09 JA |
8072 | |
8073 | fi | |
8074 | done | |
8075 | ||
b80f6443 JA |
8076 | |
8077 | ||
8078 | ||
8079 | ||
8080 | ||
8081 | ||
8082 | am_save_CPPFLAGS="$CPPFLAGS" | |
8083 | ||
8084 | for element in $INCICONV; do | |
8085 | haveit= | |
8086 | for x in $CPPFLAGS; do | |
8087 | ||
8088 | acl_save_prefix="$prefix" | |
8089 | prefix="$acl_final_prefix" | |
8090 | acl_save_exec_prefix="$exec_prefix" | |
8091 | exec_prefix="$acl_final_exec_prefix" | |
8092 | eval x=\"$x\" | |
8093 | exec_prefix="$acl_save_exec_prefix" | |
8094 | prefix="$acl_save_prefix" | |
8095 | ||
8096 | if test "X$x" = "X$element"; then | |
8097 | haveit=yes | |
8098 | break | |
8099 | fi | |
8100 | done | |
8101 | if test -z "$haveit"; then | |
8102 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8103 | fi | |
8104 | done | |
8105 | ||
8106 | ||
ac50fbac | 8107 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 |
3185942a | 8108 | $as_echo_n "checking for iconv... " >&6; } |
ac50fbac | 8109 | if ${am_cv_func_iconv+:} false; then : |
3185942a | 8110 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8111 | else |
f73dda09 | 8112 | |
b80f6443 JA |
8113 | am_cv_func_iconv="no, consider installing GNU libiconv" |
8114 | am_cv_lib_iconv=no | |
ac50fbac | 8115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8116 | /* end confdefs.h. */ |
b80f6443 JA |
8117 | #include <stdlib.h> |
8118 | #include <iconv.h> | |
f73dda09 JA |
8119 | int |
8120 | main () | |
8121 | { | |
b80f6443 JA |
8122 | iconv_t cd = iconv_open("",""); |
8123 | iconv(cd,NULL,NULL,NULL,NULL); | |
8124 | iconv_close(cd); | |
f73dda09 JA |
8125 | ; |
8126 | return 0; | |
8127 | } | |
8128 | _ACEOF | |
ac50fbac | 8129 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 8130 | am_cv_func_iconv=yes |
f73dda09 | 8131 | fi |
ac50fbac CR |
8132 | rm -f core conftest.err conftest.$ac_objext \ |
8133 | conftest$ac_exeext conftest.$ac_ext | |
b80f6443 JA |
8134 | if test "$am_cv_func_iconv" != yes; then |
8135 | am_save_LIBS="$LIBS" | |
8136 | LIBS="$LIBS $LIBICONV" | |
ac50fbac | 8137 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8138 | /* end confdefs.h. */ |
b80f6443 JA |
8139 | #include <stdlib.h> |
8140 | #include <iconv.h> | |
f73dda09 JA |
8141 | int |
8142 | main () | |
8143 | { | |
b80f6443 JA |
8144 | iconv_t cd = iconv_open("",""); |
8145 | iconv(cd,NULL,NULL,NULL,NULL); | |
8146 | iconv_close(cd); | |
f73dda09 JA |
8147 | ; |
8148 | return 0; | |
8149 | } | |
8150 | _ACEOF | |
ac50fbac | 8151 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 JA |
8152 | am_cv_lib_iconv=yes |
8153 | am_cv_func_iconv=yes | |
f73dda09 | 8154 | fi |
ac50fbac CR |
8155 | rm -f core conftest.err conftest.$ac_objext \ |
8156 | conftest$ac_exeext conftest.$ac_ext | |
b80f6443 JA |
8157 | LIBS="$am_save_LIBS" |
8158 | fi | |
8159 | ||
f73dda09 | 8160 | fi |
ac50fbac | 8161 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 |
3185942a | 8162 | $as_echo "$am_cv_func_iconv" >&6; } |
b80f6443 | 8163 | if test "$am_cv_func_iconv" = yes; then |
f73dda09 | 8164 | |
ac50fbac | 8165 | $as_echo "#define HAVE_ICONV 1" >>confdefs.h |
f73dda09 | 8166 | |
b80f6443 JA |
8167 | fi |
8168 | if test "$am_cv_lib_iconv" = yes; then | |
ac50fbac | 8169 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 |
3185942a | 8170 | $as_echo_n "checking how to link with libiconv... " >&6; } |
ac50fbac | 8171 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 |
3185942a | 8172 | $as_echo "$LIBICONV" >&6; } |
b80f6443 JA |
8173 | else |
8174 | CPPFLAGS="$am_save_CPPFLAGS" | |
8175 | LIBICONV= | |
8176 | LTLIBICONV= | |
8177 | fi | |
8178 | ||
8179 | ||
8180 | ||
8181 | if test "$am_cv_func_iconv" = yes; then | |
ac50fbac | 8182 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5 |
3185942a | 8183 | $as_echo_n "checking for iconv declaration... " >&6; } |
ac50fbac | 8184 | if ${am_cv_proto_iconv+:} false; then : |
3185942a | 8185 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8186 | else |
b80f6443 | 8187 | |
ac50fbac | 8188 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8189 | /* end confdefs.h. */ |
b80f6443 JA |
8190 | |
8191 | #include <stdlib.h> | |
8192 | #include <iconv.h> | |
8193 | extern | |
f73dda09 | 8194 | #ifdef __cplusplus |
b80f6443 JA |
8195 | "C" |
8196 | #endif | |
8197 | #if defined(__STDC__) || defined(__cplusplus) | |
8198 | size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); | |
8199 | #else | |
8200 | size_t iconv(); | |
f73dda09 | 8201 | #endif |
f73dda09 JA |
8202 | |
8203 | int | |
8204 | main () | |
8205 | { | |
f73dda09 JA |
8206 | |
8207 | ; | |
8208 | return 0; | |
8209 | } | |
8210 | _ACEOF | |
ac50fbac | 8211 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 | 8212 | am_cv_proto_iconv_arg1="" |
f73dda09 | 8213 | else |
ac50fbac | 8214 | am_cv_proto_iconv_arg1="const" |
f73dda09 | 8215 | fi |
3185942a | 8216 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b80f6443 | 8217 | am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);" |
f73dda09 | 8218 | fi |
f73dda09 | 8219 | |
b80f6443 | 8220 | am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` |
ac50fbac | 8221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:- |
b80f6443 | 8222 | }$am_cv_proto_iconv" >&5 |
3185942a JA |
8223 | $as_echo "${ac_t:- |
8224 | }$am_cv_proto_iconv" >&6; } | |
f73dda09 | 8225 | |
b80f6443 JA |
8226 | cat >>confdefs.h <<_ACEOF |
8227 | #define ICONV_CONST $am_cv_proto_iconv_arg1 | |
8228 | _ACEOF | |
8229 | ||
8230 | fi | |
8231 | ||
8232 | ||
ac50fbac | 8233 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
3185942a | 8234 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } |
ac50fbac | 8235 | if ${am_cv_langinfo_codeset+:} false; then : |
3185942a | 8236 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8237 | else |
ac50fbac | 8238 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8239 | /* end confdefs.h. */ |
b80f6443 | 8240 | #include <langinfo.h> |
f73dda09 JA |
8241 | int |
8242 | main () | |
8243 | { | |
b80f6443 | 8244 | char* cs = nl_langinfo(CODESET); |
f73dda09 JA |
8245 | ; |
8246 | return 0; | |
8247 | } | |
8248 | _ACEOF | |
ac50fbac | 8249 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 8250 | am_cv_langinfo_codeset=yes |
f73dda09 | 8251 | else |
ac50fbac | 8252 | am_cv_langinfo_codeset=no |
f73dda09 | 8253 | fi |
ac50fbac CR |
8254 | rm -f core conftest.err conftest.$ac_objext \ |
8255 | conftest$ac_exeext conftest.$ac_ext | |
b80f6443 | 8256 | |
f73dda09 | 8257 | fi |
ac50fbac | 8258 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5 |
3185942a | 8259 | $as_echo "$am_cv_langinfo_codeset" >&6; } |
b80f6443 | 8260 | if test $am_cv_langinfo_codeset = yes; then |
f73dda09 | 8261 | |
ac50fbac | 8262 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h |
f73dda09 | 8263 | |
b80f6443 | 8264 | fi |
f73dda09 | 8265 | |
b80f6443 | 8266 | if test $ac_cv_header_locale_h = yes; then |
f73dda09 | 8267 | |
ac50fbac | 8268 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 |
3185942a | 8269 | $as_echo_n "checking for LC_MESSAGES... " >&6; } |
ac50fbac | 8270 | if ${am_cv_val_LC_MESSAGES+:} false; then : |
3185942a | 8271 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8272 | else |
ac50fbac | 8273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8274 | /* end confdefs.h. */ |
b80f6443 | 8275 | #include <locale.h> |
f73dda09 JA |
8276 | int |
8277 | main () | |
8278 | { | |
b80f6443 | 8279 | return LC_MESSAGES |
f73dda09 JA |
8280 | ; |
8281 | return 0; | |
8282 | } | |
8283 | _ACEOF | |
ac50fbac | 8284 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 8285 | am_cv_val_LC_MESSAGES=yes |
f73dda09 | 8286 | else |
ac50fbac | 8287 | am_cv_val_LC_MESSAGES=no |
f73dda09 | 8288 | fi |
ac50fbac CR |
8289 | rm -f core conftest.err conftest.$ac_objext \ |
8290 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 8291 | fi |
ac50fbac | 8292 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5 |
3185942a | 8293 | $as_echo "$am_cv_val_LC_MESSAGES" >&6; } |
b80f6443 | 8294 | if test $am_cv_val_LC_MESSAGES = yes; then |
f73dda09 | 8295 | |
ac50fbac | 8296 | $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h |
b80f6443 JA |
8297 | |
8298 | fi | |
8299 | ||
8300 | fi | |
f73dda09 | 8301 | |
b80f6443 JA |
8302 | for ac_prog in bison |
8303 | do | |
8304 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
8305 | set dummy $ac_prog; ac_word=$2 | |
ac50fbac | 8306 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3185942a | 8307 | $as_echo_n "checking for $ac_word... " >&6; } |
ac50fbac | 8308 | if ${ac_cv_prog_INTLBISON+:} false; then : |
3185942a | 8309 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8310 | else |
b80f6443 JA |
8311 | if test -n "$INTLBISON"; then |
8312 | ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test. | |
8313 | else | |
8314 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
8315 | for as_dir in $PATH | |
8316 | do | |
8317 | IFS=$as_save_IFS | |
8318 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
8319 | for ac_exec_ext in '' $ac_executable_extensions; do |
8320 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
b80f6443 | 8321 | ac_cv_prog_INTLBISON="$ac_prog" |
ac50fbac | 8322 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
b80f6443 JA |
8323 | break 2 |
8324 | fi | |
8325 | done | |
ac50fbac | 8326 | done |
3185942a | 8327 | IFS=$as_save_IFS |
f73dda09 | 8328 | |
b80f6443 JA |
8329 | fi |
8330 | fi | |
8331 | INTLBISON=$ac_cv_prog_INTLBISON | |
8332 | if test -n "$INTLBISON"; then | |
ac50fbac | 8333 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INTLBISON" >&5 |
3185942a | 8334 | $as_echo "$INTLBISON" >&6; } |
b80f6443 | 8335 | else |
ac50fbac | 8336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3185942a | 8337 | $as_echo "no" >&6; } |
f73dda09 JA |
8338 | fi |
8339 | ||
3185942a | 8340 | |
b80f6443 JA |
8341 | test -n "$INTLBISON" && break |
8342 | done | |
8343 | ||
8344 | if test -z "$INTLBISON"; then | |
8345 | ac_verc_fail=yes | |
8346 | else | |
ac50fbac | 8347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of bison" >&5 |
3185942a | 8348 | $as_echo_n "checking version of bison... " >&6; } |
b80f6443 JA |
8349 | ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` |
8350 | case $ac_prog_version in | |
8351 | '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; | |
8352 | 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) | |
8353 | ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; | |
8354 | *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; | |
8355 | esac | |
ac50fbac | 8356 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5 |
3185942a | 8357 | $as_echo "$ac_prog_version" >&6; } |
b80f6443 JA |
8358 | fi |
8359 | if test $ac_verc_fail = yes; then | |
8360 | INTLBISON=: | |
8361 | fi | |
8362 | ||
8363 | ||
8364 | ||
8365 | ||
8366 | ||
8367 | ||
8368 | ||
8369 | ||
8370 | ||
8371 | ||
8372 | ||
8373 | ||
8374 | ||
8375 | ||
8376 | ||
8377 | ||
ac50fbac | 8378 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
3185942a JA |
8379 | $as_echo_n "checking whether NLS is requested... " >&6; } |
8380 | # Check whether --enable-nls was given. | |
ac50fbac | 8381 | if test "${enable_nls+set}" = set; then : |
3185942a | 8382 | enableval=$enable_nls; USE_NLS=$enableval |
b80f6443 JA |
8383 | else |
8384 | USE_NLS=yes | |
3185942a JA |
8385 | fi |
8386 | ||
ac50fbac | 8387 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
3185942a | 8388 | $as_echo "$USE_NLS" >&6; } |
b80f6443 JA |
8389 | |
8390 | ||
8391 | ||
8392 | ||
8393 | BUILD_INCLUDED_LIBINTL=no | |
8394 | USE_INCLUDED_LIBINTL=no | |
8395 | ||
8396 | LIBINTL= | |
8397 | LTLIBINTL= | |
8398 | POSUB= | |
8399 | ||
8400 | if test "$USE_NLS" = "yes"; then | |
8401 | gt_use_preinstalled_gnugettext=no | |
8402 | ||
ac50fbac | 8403 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether included gettext is requested" >&5 |
3185942a | 8404 | $as_echo_n "checking whether included gettext is requested... " >&6; } |
b80f6443 | 8405 | |
3185942a | 8406 | # Check whether --with-included-gettext was given. |
ac50fbac | 8407 | if test "${with_included_gettext+set}" = set; then : |
3185942a | 8408 | withval=$with_included_gettext; nls_cv_force_use_gnu_gettext=$withval |
b80f6443 JA |
8409 | else |
8410 | nls_cv_force_use_gnu_gettext=no | |
3185942a JA |
8411 | fi |
8412 | ||
ac50fbac | 8413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $nls_cv_force_use_gnu_gettext" >&5 |
3185942a | 8414 | $as_echo "$nls_cv_force_use_gnu_gettext" >&6; } |
b80f6443 JA |
8415 | |
8416 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
8417 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
8418 | ||
8419 | ||
8420 | ||
8421 | ||
8422 | ||
8423 | ||
ac50fbac | 8424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5 |
3185942a | 8425 | $as_echo_n "checking for GNU gettext in libc... " >&6; } |
ac50fbac | 8426 | if ${gt_cv_func_gnugettext2_libc+:} false; then : |
3185942a | 8427 | $as_echo_n "(cached) " >&6 |
f73dda09 | 8428 | else |
ac50fbac | 8429 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 8430 | /* end confdefs.h. */ |
b80f6443 JA |
8431 | #include <libintl.h> |
8432 | extern int _nl_msg_cat_cntr; | |
8433 | extern int *_nl_domain_bindings; | |
f73dda09 JA |
8434 | int |
8435 | main () | |
8436 | { | |
b80f6443 JA |
8437 | bindtextdomain ("", ""); |
8438 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_domain_bindings | |
f73dda09 JA |
8439 | ; |
8440 | return 0; | |
8441 | } | |
8442 | _ACEOF | |
ac50fbac | 8443 | if ac_fn_c_try_link "$LINENO"; then : |
b80f6443 | 8444 | gt_cv_func_gnugettext2_libc=yes |
f73dda09 | 8445 | else |
ac50fbac | 8446 | gt_cv_func_gnugettext2_libc=no |
f73dda09 | 8447 | fi |
ac50fbac CR |
8448 | rm -f core conftest.err conftest.$ac_objext \ |
8449 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 8450 | fi |
ac50fbac | 8451 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libc" >&5 |
3185942a | 8452 | $as_echo "$gt_cv_func_gnugettext2_libc" >&6; } |
f73dda09 | 8453 | |
b80f6443 | 8454 | if test "$gt_cv_func_gnugettext2_libc" != "yes"; then |
f73dda09 | 8455 | |
f73dda09 | 8456 | |
f73dda09 | 8457 | |
b80f6443 JA |
8458 | use_additional=yes |
8459 | ||
8460 | acl_save_prefix="$prefix" | |
8461 | prefix="$acl_final_prefix" | |
8462 | acl_save_exec_prefix="$exec_prefix" | |
8463 | exec_prefix="$acl_final_exec_prefix" | |
8464 | ||
8465 | eval additional_includedir=\"$includedir\" | |
8466 | eval additional_libdir=\"$libdir\" | |
8467 | ||
8468 | exec_prefix="$acl_save_exec_prefix" | |
8469 | prefix="$acl_save_prefix" | |
8470 | ||
8471 | ||
3185942a | 8472 | # Check whether --with-libintl-prefix was given. |
ac50fbac | 8473 | if test "${with_libintl_prefix+set}" = set; then : |
3185942a | 8474 | withval=$with_libintl_prefix; |
b80f6443 JA |
8475 | if test "X$withval" = "Xno"; then |
8476 | use_additional=no | |
8477 | else | |
8478 | if test "X$withval" = "X"; then | |
8479 | ||
8480 | acl_save_prefix="$prefix" | |
8481 | prefix="$acl_final_prefix" | |
8482 | acl_save_exec_prefix="$exec_prefix" | |
8483 | exec_prefix="$acl_final_exec_prefix" | |
8484 | ||
8485 | eval additional_includedir=\"$includedir\" | |
8486 | eval additional_libdir=\"$libdir\" | |
8487 | ||
8488 | exec_prefix="$acl_save_exec_prefix" | |
8489 | prefix="$acl_save_prefix" | |
8490 | ||
8491 | else | |
8492 | additional_includedir="$withval/include" | |
8493 | additional_libdir="$withval/lib" | |
8494 | fi | |
8495 | fi | |
8496 | ||
3185942a JA |
8497 | fi |
8498 | ||
b80f6443 JA |
8499 | LIBINTL= |
8500 | LTLIBINTL= | |
8501 | INCINTL= | |
8502 | rpathdirs= | |
8503 | ltrpathdirs= | |
8504 | names_already_handled= | |
8505 | names_next_round='intl ' | |
8506 | while test -n "$names_next_round"; do | |
8507 | names_this_round="$names_next_round" | |
8508 | names_next_round= | |
8509 | for name in $names_this_round; do | |
8510 | already_handled= | |
8511 | for n in $names_already_handled; do | |
8512 | if test "$n" = "$name"; then | |
8513 | already_handled=yes | |
8514 | break | |
8515 | fi | |
8516 | done | |
8517 | if test -z "$already_handled"; then | |
8518 | names_already_handled="$names_already_handled $name" | |
8519 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
8520 | eval value=\"\$HAVE_LIB$uppername\" | |
8521 | if test -n "$value"; then | |
8522 | if test "$value" = yes; then | |
8523 | eval value=\"\$LIB$uppername\" | |
8524 | test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" | |
8525 | eval value=\"\$LTLIB$uppername\" | |
8526 | test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" | |
8527 | else | |
8528 | : | |
8529 | fi | |
8530 | else | |
8531 | found_dir= | |
8532 | found_la= | |
8533 | found_so= | |
8534 | found_a= | |
8535 | if test $use_additional = yes; then | |
ac50fbac | 8536 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
b80f6443 JA |
8537 | found_dir="$additional_libdir" |
8538 | found_so="$additional_libdir/lib$name.$shlibext" | |
8539 | if test -f "$additional_libdir/lib$name.la"; then | |
8540 | found_la="$additional_libdir/lib$name.la" | |
8541 | fi | |
8542 | else | |
8543 | if test -f "$additional_libdir/lib$name.$libext"; then | |
8544 | found_dir="$additional_libdir" | |
8545 | found_a="$additional_libdir/lib$name.$libext" | |
8546 | if test -f "$additional_libdir/lib$name.la"; then | |
8547 | found_la="$additional_libdir/lib$name.la" | |
8548 | fi | |
8549 | fi | |
8550 | fi | |
8551 | fi | |
8552 | if test "X$found_dir" = "X"; then | |
8553 | for x in $LDFLAGS $LTLIBINTL; do | |
8554 | ||
8555 | acl_save_prefix="$prefix" | |
8556 | prefix="$acl_final_prefix" | |
8557 | acl_save_exec_prefix="$exec_prefix" | |
8558 | exec_prefix="$acl_final_exec_prefix" | |
8559 | eval x=\"$x\" | |
8560 | exec_prefix="$acl_save_exec_prefix" | |
8561 | prefix="$acl_save_prefix" | |
8562 | ||
8563 | case "$x" in | |
8564 | -L*) | |
8565 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
ac50fbac | 8566 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
b80f6443 JA |
8567 | found_dir="$dir" |
8568 | found_so="$dir/lib$name.$shlibext" | |
8569 | if test -f "$dir/lib$name.la"; then | |
8570 | found_la="$dir/lib$name.la" | |
8571 | fi | |
8572 | else | |
8573 | if test -f "$dir/lib$name.$libext"; then | |
8574 | found_dir="$dir" | |
8575 | found_a="$dir/lib$name.$libext" | |
8576 | if test -f "$dir/lib$name.la"; then | |
8577 | found_la="$dir/lib$name.la" | |
8578 | fi | |
8579 | fi | |
8580 | fi | |
8581 | ;; | |
8582 | esac | |
8583 | if test "X$found_dir" != "X"; then | |
8584 | break | |
8585 | fi | |
8586 | done | |
8587 | fi | |
8588 | if test "X$found_dir" != "X"; then | |
8589 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" | |
8590 | if test "X$found_so" != "X"; then | |
8591 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
8592 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8593 | else | |
8594 | haveit= | |
8595 | for x in $ltrpathdirs; do | |
8596 | if test "X$x" = "X$found_dir"; then | |
8597 | haveit=yes | |
8598 | break | |
8599 | fi | |
8600 | done | |
8601 | if test -z "$haveit"; then | |
8602 | ltrpathdirs="$ltrpathdirs $found_dir" | |
8603 | fi | |
8604 | if test "$hardcode_direct" = yes; then | |
8605 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8606 | else | |
8607 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
8608 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8609 | haveit= | |
8610 | for x in $rpathdirs; do | |
8611 | if test "X$x" = "X$found_dir"; then | |
8612 | haveit=yes | |
8613 | break | |
8614 | fi | |
8615 | done | |
8616 | if test -z "$haveit"; then | |
8617 | rpathdirs="$rpathdirs $found_dir" | |
8618 | fi | |
8619 | else | |
8620 | haveit= | |
8621 | for x in $LDFLAGS $LIBINTL; do | |
8622 | ||
8623 | acl_save_prefix="$prefix" | |
8624 | prefix="$acl_final_prefix" | |
8625 | acl_save_exec_prefix="$exec_prefix" | |
8626 | exec_prefix="$acl_final_exec_prefix" | |
8627 | eval x=\"$x\" | |
8628 | exec_prefix="$acl_save_exec_prefix" | |
8629 | prefix="$acl_save_prefix" | |
8630 | ||
8631 | if test "X$x" = "X-L$found_dir"; then | |
8632 | haveit=yes | |
8633 | break | |
8634 | fi | |
8635 | done | |
8636 | if test -z "$haveit"; then | |
8637 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" | |
8638 | fi | |
8639 | if test "$hardcode_minus_L" != no; then | |
8640 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8641 | else | |
8642 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8643 | fi | |
8644 | fi | |
8645 | fi | |
8646 | fi | |
8647 | else | |
8648 | if test "X$found_a" != "X"; then | |
8649 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" | |
8650 | else | |
8651 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" | |
8652 | fi | |
8653 | fi | |
8654 | additional_includedir= | |
8655 | case "$found_dir" in | |
8656 | */lib | */lib/) | |
8657 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
8658 | additional_includedir="$basedir/include" | |
8659 | ;; | |
8660 | esac | |
8661 | if test "X$additional_includedir" != "X"; then | |
8662 | if test "X$additional_includedir" != "X/usr/include"; then | |
8663 | haveit= | |
8664 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
8665 | if test -n "$GCC"; then | |
8666 | case $host_os in | |
8667 | linux*) haveit=yes;; | |
8668 | esac | |
8669 | fi | |
8670 | fi | |
8671 | if test -z "$haveit"; then | |
8672 | for x in $CPPFLAGS $INCINTL; do | |
8673 | ||
8674 | acl_save_prefix="$prefix" | |
8675 | prefix="$acl_final_prefix" | |
8676 | acl_save_exec_prefix="$exec_prefix" | |
8677 | exec_prefix="$acl_final_exec_prefix" | |
8678 | eval x=\"$x\" | |
8679 | exec_prefix="$acl_save_exec_prefix" | |
8680 | prefix="$acl_save_prefix" | |
8681 | ||
8682 | if test "X$x" = "X-I$additional_includedir"; then | |
8683 | haveit=yes | |
8684 | break | |
8685 | fi | |
8686 | done | |
8687 | if test -z "$haveit"; then | |
8688 | if test -d "$additional_includedir"; then | |
8689 | INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" | |
8690 | fi | |
8691 | fi | |
8692 | fi | |
8693 | fi | |
8694 | fi | |
8695 | if test -n "$found_la"; then | |
8696 | save_libdir="$libdir" | |
8697 | case "$found_la" in | |
8698 | */* | *\\*) . "$found_la" ;; | |
8699 | *) . "./$found_la" ;; | |
8700 | esac | |
8701 | libdir="$save_libdir" | |
8702 | for dep in $dependency_libs; do | |
8703 | case "$dep" in | |
8704 | -L*) | |
8705 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
8706 | if test "X$additional_libdir" != "X/usr/lib"; then | |
8707 | haveit= | |
8708 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
8709 | if test -n "$GCC"; then | |
8710 | case $host_os in | |
8711 | linux*) haveit=yes;; | |
8712 | esac | |
8713 | fi | |
8714 | fi | |
8715 | if test -z "$haveit"; then | |
8716 | haveit= | |
8717 | for x in $LDFLAGS $LIBINTL; do | |
8718 | ||
8719 | acl_save_prefix="$prefix" | |
8720 | prefix="$acl_final_prefix" | |
8721 | acl_save_exec_prefix="$exec_prefix" | |
8722 | exec_prefix="$acl_final_exec_prefix" | |
8723 | eval x=\"$x\" | |
8724 | exec_prefix="$acl_save_exec_prefix" | |
8725 | prefix="$acl_save_prefix" | |
8726 | ||
8727 | if test "X$x" = "X-L$additional_libdir"; then | |
8728 | haveit=yes | |
8729 | break | |
8730 | fi | |
8731 | done | |
8732 | if test -z "$haveit"; then | |
8733 | if test -d "$additional_libdir"; then | |
8734 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" | |
8735 | fi | |
8736 | fi | |
8737 | haveit= | |
8738 | for x in $LDFLAGS $LTLIBINTL; do | |
8739 | ||
8740 | acl_save_prefix="$prefix" | |
8741 | prefix="$acl_final_prefix" | |
8742 | acl_save_exec_prefix="$exec_prefix" | |
8743 | exec_prefix="$acl_final_exec_prefix" | |
8744 | eval x=\"$x\" | |
8745 | exec_prefix="$acl_save_exec_prefix" | |
8746 | prefix="$acl_save_prefix" | |
8747 | ||
8748 | if test "X$x" = "X-L$additional_libdir"; then | |
8749 | haveit=yes | |
8750 | break | |
8751 | fi | |
8752 | done | |
8753 | if test -z "$haveit"; then | |
8754 | if test -d "$additional_libdir"; then | |
8755 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" | |
8756 | fi | |
8757 | fi | |
8758 | fi | |
8759 | fi | |
8760 | ;; | |
8761 | -R*) | |
8762 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
8763 | if test "$enable_rpath" != no; then | |
8764 | haveit= | |
8765 | for x in $rpathdirs; do | |
8766 | if test "X$x" = "X$dir"; then | |
8767 | haveit=yes | |
8768 | break | |
8769 | fi | |
8770 | done | |
8771 | if test -z "$haveit"; then | |
8772 | rpathdirs="$rpathdirs $dir" | |
8773 | fi | |
8774 | haveit= | |
8775 | for x in $ltrpathdirs; do | |
8776 | if test "X$x" = "X$dir"; then | |
8777 | haveit=yes | |
8778 | break | |
8779 | fi | |
8780 | done | |
8781 | if test -z "$haveit"; then | |
8782 | ltrpathdirs="$ltrpathdirs $dir" | |
8783 | fi | |
8784 | fi | |
8785 | ;; | |
8786 | -l*) | |
8787 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
8788 | ;; | |
8789 | *.la) | |
8790 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
8791 | ;; | |
8792 | *) | |
8793 | LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" | |
8794 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" | |
8795 | ;; | |
8796 | esac | |
8797 | done | |
8798 | fi | |
8799 | else | |
8800 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8801 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" | |
8802 | fi | |
8803 | fi | |
8804 | fi | |
8805 | done | |
8806 | done | |
8807 | if test "X$rpathdirs" != "X"; then | |
8808 | if test -n "$hardcode_libdir_separator"; then | |
8809 | alldirs= | |
8810 | for found_dir in $rpathdirs; do | |
8811 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
8812 | done | |
8813 | acl_save_libdir="$libdir" | |
8814 | libdir="$alldirs" | |
8815 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8816 | libdir="$acl_save_libdir" | |
8817 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8818 | else | |
8819 | for found_dir in $rpathdirs; do | |
8820 | acl_save_libdir="$libdir" | |
8821 | libdir="$found_dir" | |
8822 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8823 | libdir="$acl_save_libdir" | |
8824 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8825 | done | |
8826 | fi | |
8827 | fi | |
ac50fbac CR |
8828 | if test "X$ltrpathdirs" != "X"; then |
8829 | for found_dir in $ltrpathdirs; do | |
8830 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" | |
8831 | done | |
8832 | fi | |
3185942a | 8833 | |
ac50fbac CR |
8834 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5 |
8835 | $as_echo_n "checking for GNU gettext in libintl... " >&6; } | |
8836 | if ${gt_cv_func_gnugettext2_libintl+:} false; then : | |
3185942a JA |
8837 | $as_echo_n "(cached) " >&6 |
8838 | else | |
ac50fbac CR |
8839 | gt_save_CPPFLAGS="$CPPFLAGS" |
8840 | CPPFLAGS="$CPPFLAGS $INCINTL" | |
8841 | gt_save_LIBS="$LIBS" | |
8842 | LIBS="$LIBS $LIBINTL" | |
8843 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 8844 | /* end confdefs.h. */ |
ac50fbac CR |
8845 | #include <libintl.h> |
8846 | extern int _nl_msg_cat_cntr; | |
8847 | extern | |
8848 | #ifdef __cplusplus | |
8849 | "C" | |
8850 | #endif | |
8851 | const char *_nl_expand_alias (); | |
3185942a JA |
8852 | int |
8853 | main () | |
8854 | { | |
ac50fbac CR |
8855 | bindtextdomain ("", ""); |
8856 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
f73dda09 JA |
8857 | ; |
8858 | return 0; | |
8859 | } | |
8860 | _ACEOF | |
ac50fbac CR |
8861 | if ac_fn_c_try_link "$LINENO"; then : |
8862 | gt_cv_func_gnugettext2_libintl=yes | |
8863 | else | |
8864 | gt_cv_func_gnugettext2_libintl=no | |
8865 | fi | |
8866 | rm -f core conftest.err conftest.$ac_objext \ | |
8867 | conftest$ac_exeext conftest.$ac_ext | |
8868 | if test "$gt_cv_func_gnugettext2_libintl" != yes && test -n "$LIBICONV"; then | |
8869 | LIBS="$LIBS $LIBICONV" | |
8870 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 8871 | /* end confdefs.h. */ |
ac50fbac CR |
8872 | #include <libintl.h> |
8873 | extern int _nl_msg_cat_cntr; | |
8874 | extern | |
8875 | #ifdef __cplusplus | |
8876 | "C" | |
8877 | #endif | |
8878 | const char *_nl_expand_alias (); | |
3185942a JA |
8879 | int |
8880 | main () | |
8881 | { | |
ac50fbac CR |
8882 | bindtextdomain ("", ""); |
8883 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
3185942a JA |
8884 | ; |
8885 | return 0; | |
8886 | } | |
8887 | _ACEOF | |
ac50fbac CR |
8888 | if ac_fn_c_try_link "$LINENO"; then : |
8889 | LIBINTL="$LIBINTL $LIBICONV" | |
8890 | LTLIBINTL="$LTLIBINTL $LTLIBICONV" | |
8891 | gt_cv_func_gnugettext2_libintl=yes | |
3185942a | 8892 | |
3185942a | 8893 | fi |
ac50fbac CR |
8894 | rm -f core conftest.err conftest.$ac_objext \ |
8895 | conftest$ac_exeext conftest.$ac_ext | |
8896 | fi | |
8897 | CPPFLAGS="$gt_save_CPPFLAGS" | |
8898 | LIBS="$gt_save_LIBS" | |
8899 | fi | |
8900 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libintl" >&5 | |
8901 | $as_echo "$gt_cv_func_gnugettext2_libintl" >&6; } | |
8902 | fi | |
3185942a | 8903 | |
ac50fbac CR |
8904 | if test "$gt_cv_func_gnugettext2_libc" = "yes" \ |
8905 | || { test "$gt_cv_func_gnugettext2_libintl" = "yes" \ | |
8906 | && test "$PACKAGE" != gettext-runtime \ | |
8907 | && test "$PACKAGE" != gettext-tools; }; then | |
8908 | gt_use_preinstalled_gnugettext=yes | |
8909 | else | |
8910 | LIBINTL= | |
8911 | LTLIBINTL= | |
8912 | INCINTL= | |
8913 | fi | |
0628567a | 8914 | |
3185942a | 8915 | |
ac50fbac CR |
8916 | if test "$gt_use_preinstalled_gnugettext" != "yes"; then |
8917 | nls_cv_use_gnu_gettext=yes | |
8918 | fi | |
8919 | fi | |
3185942a | 8920 | |
ac50fbac CR |
8921 | if test "$nls_cv_use_gnu_gettext" = "yes"; then |
8922 | BUILD_INCLUDED_LIBINTL=yes | |
8923 | USE_INCLUDED_LIBINTL=yes | |
8924 | LIBINTL="lib/intl/libintl.a $LIBICONV" | |
8925 | LTLIBINTL="lib/intl/libintl.a $LTLIBICONV" | |
8926 | LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` | |
8927 | fi | |
f73dda09 | 8928 | |
ac50fbac CR |
8929 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ |
8930 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8931 | CATOBJEXT=.gmo | |
8932 | fi | |
ccc6cda3 | 8933 | |
ccc6cda3 | 8934 | |
ac50fbac CR |
8935 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ |
8936 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
b80f6443 | 8937 | |
ac50fbac | 8938 | $as_echo "#define ENABLE_NLS 1" >>confdefs.h |
b80f6443 | 8939 | |
ac50fbac CR |
8940 | else |
8941 | USE_NLS=no | |
8942 | fi | |
8943 | fi | |
ccc6cda3 | 8944 | |
ac50fbac CR |
8945 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5 |
8946 | $as_echo_n "checking whether to use NLS... " >&6; } | |
8947 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 | |
8948 | $as_echo "$USE_NLS" >&6; } | |
8949 | if test "$USE_NLS" = "yes"; then | |
8950 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5 | |
8951 | $as_echo_n "checking where the gettext function comes from... " >&6; } | |
8952 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then | |
8953 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8954 | gt_source="external libintl" | |
8955 | else | |
8956 | gt_source="libc" | |
8957 | fi | |
8958 | else | |
8959 | gt_source="included intl directory" | |
8960 | fi | |
8961 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5 | |
8962 | $as_echo "$gt_source" >&6; } | |
8963 | fi | |
f73dda09 | 8964 | |
ac50fbac | 8965 | if test "$USE_NLS" = "yes"; then |
f73dda09 | 8966 | |
ac50fbac CR |
8967 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then |
8968 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8969 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5 | |
8970 | $as_echo_n "checking how to link with libintl... " >&6; } | |
8971 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5 | |
8972 | $as_echo "$LIBINTL" >&6; } | |
0628567a | 8973 | |
ac50fbac CR |
8974 | for element in $INCINTL; do |
8975 | haveit= | |
8976 | for x in $CPPFLAGS; do | |
3185942a | 8977 | |
ac50fbac CR |
8978 | acl_save_prefix="$prefix" |
8979 | prefix="$acl_final_prefix" | |
8980 | acl_save_exec_prefix="$exec_prefix" | |
8981 | exec_prefix="$acl_final_exec_prefix" | |
8982 | eval x=\"$x\" | |
8983 | exec_prefix="$acl_save_exec_prefix" | |
8984 | prefix="$acl_save_prefix" | |
ccc6cda3 | 8985 | |
ac50fbac CR |
8986 | if test "X$x" = "X$element"; then |
8987 | haveit=yes | |
8988 | break | |
8989 | fi | |
8990 | done | |
8991 | if test -z "$haveit"; then | |
8992 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8993 | fi | |
8994 | done | |
ccc6cda3 | 8995 | |
ac50fbac | 8996 | fi |
b80f6443 | 8997 | |
f73dda09 | 8998 | |
ac50fbac | 8999 | $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h |
f73dda09 | 9000 | |
f73dda09 | 9001 | |
ac50fbac | 9002 | $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h |
0628567a | 9003 | |
ac50fbac | 9004 | fi |
3185942a | 9005 | |
ac50fbac CR |
9006 | POSUB=po |
9007 | fi | |
ccc6cda3 | 9008 | |
ac50fbac CR |
9009 | |
9010 | if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then | |
9011 | BUILD_INCLUDED_LIBINTL=yes | |
9012 | fi | |
ccc6cda3 | 9013 | |
b80f6443 | 9014 | |
ac50fbac CR |
9015 | |
9016 | ||
9017 | ||
9018 | nls_cv_header_intl= | |
9019 | nls_cv_header_libgt= | |
9020 | ||
9021 | DATADIRNAME=share | |
9022 | ||
9023 | ||
9024 | INSTOBJEXT=.mo | |
9025 | ||
9026 | ||
9027 | GENCAT=gencat | |
9028 | ||
9029 | ||
9030 | if test "$USE_INCLUDED_LIBINTL" = yes; then | |
9031 | INTLOBJS="\$(GETTOBJS)" | |
9032 | fi | |
9033 | ||
9034 | ||
9035 | INTL_LIBTOOL_SUFFIX_PREFIX= | |
9036 | ||
9037 | ||
9038 | ||
9039 | INTLLIBS="$LIBINTL" | |
9040 | ||
9041 | ||
9042 | ||
9043 | ||
9044 | ||
9045 | ||
9046 | ||
9047 | ac_header_dirent=no | |
9048 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do | |
9049 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` | |
9050 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 | |
9051 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } | |
9052 | if eval \${$as_ac_Header+:} false; then : | |
3185942a | 9053 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 9054 | else |
ac50fbac | 9055 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 9056 | /* end confdefs.h. */ |
ccc6cda3 | 9057 | #include <sys/types.h> |
ac50fbac | 9058 | #include <$ac_hdr> |
f73dda09 JA |
9059 | |
9060 | int | |
9061 | main () | |
9062 | { | |
ac50fbac CR |
9063 | if ((DIR *) 0) |
9064 | return 0; | |
f73dda09 JA |
9065 | ; |
9066 | return 0; | |
9067 | } | |
9068 | _ACEOF | |
ac50fbac CR |
9069 | if ac_fn_c_try_compile "$LINENO"; then : |
9070 | eval "$as_ac_Header=yes" | |
ccc6cda3 | 9071 | else |
ac50fbac | 9072 | eval "$as_ac_Header=no" |
ccc6cda3 | 9073 | fi |
3185942a | 9074 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 9075 | fi |
ac50fbac CR |
9076 | eval ac_res=\$$as_ac_Header |
9077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
9078 | $as_echo "$ac_res" >&6; } | |
9079 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9080 | cat >>confdefs.h <<_ACEOF | |
9081 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 | |
b80f6443 JA |
9082 | _ACEOF |
9083 | ||
ac50fbac CR |
9084 | ac_header_dirent=$ac_hdr; break |
9085 | fi | |
ccc6cda3 | 9086 | |
ac50fbac CR |
9087 | done |
9088 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. | |
9089 | if test $ac_header_dirent = dirent.h; then | |
9090 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
9091 | $as_echo_n "checking for library containing opendir... " >&6; } | |
9092 | if ${ac_cv_search_opendir+:} false; then : | |
17345e5a JA |
9093 | $as_echo_n "(cached) " >&6 |
9094 | else | |
ac50fbac CR |
9095 | ac_func_search_save_LIBS=$LIBS |
9096 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17345e5a JA |
9097 | /* end confdefs.h. */ |
9098 | ||
ac50fbac CR |
9099 | /* Override any GCC internal prototype to avoid an error. |
9100 | Use char because int might match the return type of a GCC | |
9101 | builtin and then its argument prototype would still apply. */ | |
9102 | #ifdef __cplusplus | |
9103 | extern "C" | |
9104 | #endif | |
9105 | char opendir (); | |
17345e5a JA |
9106 | int |
9107 | main () | |
9108 | { | |
ac50fbac | 9109 | return opendir (); |
17345e5a JA |
9110 | ; |
9111 | return 0; | |
9112 | } | |
9113 | _ACEOF | |
ac50fbac CR |
9114 | for ac_lib in '' dir; do |
9115 | if test -z "$ac_lib"; then | |
9116 | ac_res="none required" | |
9117 | else | |
9118 | ac_res=-l$ac_lib | |
9119 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9120 | fi | |
9121 | if ac_fn_c_try_link "$LINENO"; then : | |
9122 | ac_cv_search_opendir=$ac_res | |
9123 | fi | |
9124 | rm -f core conftest.err conftest.$ac_objext \ | |
9125 | conftest$ac_exeext | |
9126 | if ${ac_cv_search_opendir+:} false; then : | |
9127 | break | |
9128 | fi | |
9129 | done | |
9130 | if ${ac_cv_search_opendir+:} false; then : | |
17345e5a | 9131 | |
ac50fbac CR |
9132 | else |
9133 | ac_cv_search_opendir=no | |
9134 | fi | |
9135 | rm conftest.$ac_ext | |
9136 | LIBS=$ac_func_search_save_LIBS | |
17345e5a | 9137 | fi |
ac50fbac CR |
9138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
9139 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9140 | ac_res=$ac_cv_search_opendir | |
9141 | if test "$ac_res" != no; then : | |
9142 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
17345e5a | 9143 | |
17345e5a | 9144 | fi |
ac50fbac CR |
9145 | |
9146 | else | |
9147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
9148 | $as_echo_n "checking for library containing opendir... " >&6; } | |
9149 | if ${ac_cv_search_opendir+:} false; then : | |
17345e5a JA |
9150 | $as_echo_n "(cached) " >&6 |
9151 | else | |
ac50fbac CR |
9152 | ac_func_search_save_LIBS=$LIBS |
9153 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17345e5a | 9154 | /* end confdefs.h. */ |
ac50fbac CR |
9155 | |
9156 | /* Override any GCC internal prototype to avoid an error. | |
9157 | Use char because int might match the return type of a GCC | |
9158 | builtin and then its argument prototype would still apply. */ | |
9159 | #ifdef __cplusplus | |
9160 | extern "C" | |
9161 | #endif | |
9162 | char opendir (); | |
17345e5a JA |
9163 | int |
9164 | main () | |
9165 | { | |
ac50fbac | 9166 | return opendir (); |
17345e5a JA |
9167 | ; |
9168 | return 0; | |
9169 | } | |
9170 | _ACEOF | |
ac50fbac CR |
9171 | for ac_lib in '' x; do |
9172 | if test -z "$ac_lib"; then | |
9173 | ac_res="none required" | |
9174 | else | |
9175 | ac_res=-l$ac_lib | |
9176 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9177 | fi | |
9178 | if ac_fn_c_try_link "$LINENO"; then : | |
9179 | ac_cv_search_opendir=$ac_res | |
9180 | fi | |
9181 | rm -f core conftest.err conftest.$ac_objext \ | |
9182 | conftest$ac_exeext | |
9183 | if ${ac_cv_search_opendir+:} false; then : | |
9184 | break | |
17345e5a | 9185 | fi |
ac50fbac CR |
9186 | done |
9187 | if ${ac_cv_search_opendir+:} false; then : | |
17345e5a | 9188 | |
17345e5a | 9189 | else |
ac50fbac | 9190 | ac_cv_search_opendir=no |
17345e5a | 9191 | fi |
ac50fbac CR |
9192 | rm conftest.$ac_ext |
9193 | LIBS=$ac_func_search_save_LIBS | |
17345e5a | 9194 | fi |
ac50fbac CR |
9195 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
9196 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9197 | ac_res=$ac_cv_search_opendir | |
9198 | if test "$ac_res" != no; then : | |
9199 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
17345e5a JA |
9200 | |
9201 | fi | |
9202 | ||
9203 | fi | |
9204 | ||
ac50fbac CR |
9205 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
9206 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
9207 | if ${ac_cv_header_time+:} false; then : | |
3185942a | 9208 | $as_echo_n "(cached) " >&6 |
f73dda09 | 9209 | else |
ac50fbac | 9210 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 9211 | /* end confdefs.h. */ |
ac50fbac CR |
9212 | #include <sys/types.h> |
9213 | #include <sys/time.h> | |
9214 | #include <time.h> | |
b80f6443 | 9215 | |
f73dda09 JA |
9216 | int |
9217 | main () | |
9218 | { | |
ac50fbac CR |
9219 | if ((struct tm *) 0) |
9220 | return 0; | |
f73dda09 JA |
9221 | ; |
9222 | return 0; | |
9223 | } | |
9224 | _ACEOF | |
ac50fbac CR |
9225 | if ac_fn_c_try_compile "$LINENO"; then : |
9226 | ac_cv_header_time=yes | |
f73dda09 | 9227 | else |
ac50fbac CR |
9228 | ac_cv_header_time=no |
9229 | fi | |
9230 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9231 | fi | |
9232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 | |
9233 | $as_echo "$ac_cv_header_time" >&6; } | |
9234 | if test $ac_cv_header_time = yes; then | |
9235 | ||
9236 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h | |
0628567a | 9237 | |
f73dda09 | 9238 | fi |
3185942a | 9239 | |
0628567a | 9240 | |
b80f6443 | 9241 | |
ac50fbac CR |
9242 | for ac_header in inttypes.h |
9243 | do : | |
9244 | ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default" | |
9245 | if test "x$ac_cv_header_inttypes_h" = xyes; then : | |
9246 | cat >>confdefs.h <<_ACEOF | |
9247 | #define HAVE_INTTYPES_H 1 | |
9248 | _ACEOF | |
9249 | ||
9250 | fi | |
9251 | ||
9252 | done | |
9253 | ||
9254 | ||
9255 | ||
9256 | for ac_header in unistd.h stdlib.h stdarg.h varargs.h limits.h string.h \ | |
9257 | memory.h locale.h termcap.h termio.h termios.h dlfcn.h \ | |
9258 | stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \ | |
9259 | regex.h syslog.h ulimit.h | |
9260 | do : | |
9261 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9262 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9263 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9264 | cat >>confdefs.h <<_ACEOF | |
9265 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
0628567a | 9266 | _ACEOF |
b80f6443 | 9267 | |
ac50fbac CR |
9268 | fi |
9269 | ||
9270 | done | |
9271 | ||
a0c0a00f CR |
9272 | for ac_header in sys/pte.h sys/stream.h sys/select.h sys/file.h sys/ioctl.h \ |
9273 | sys/param.h sys/socket.h sys/stat.h \ | |
ac50fbac CR |
9274 | sys/time.h sys/times.h sys/types.h sys/wait.h |
9275 | do : | |
9276 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9277 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9278 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9279 | cat >>confdefs.h <<_ACEOF | |
9280 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
f73dda09 | 9281 | _ACEOF |
0628567a | 9282 | |
f73dda09 | 9283 | fi |
3185942a | 9284 | |
ac50fbac CR |
9285 | done |
9286 | ||
9287 | for ac_header in netinet/in.h arpa/inet.h | |
9288 | do : | |
9289 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9290 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9291 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9292 | cat >>confdefs.h <<_ACEOF | |
9293 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
9294 | _ACEOF | |
0628567a | 9295 | |
b80f6443 | 9296 | fi |
3185942a | 9297 | |
ac50fbac CR |
9298 | done |
9299 | ||
9300 | ||
9301 | ac_fn_c_check_header_compile "$LINENO" "sys/ptem.h" "ac_cv_header_sys_ptem_h" " | |
9302 | #if HAVE_SYS_STREAM_H | |
9303 | # include <sys/stream.h> | |
9304 | #endif | |
9305 | ||
9306 | " | |
9307 | if test "x$ac_cv_header_sys_ptem_h" = xyes; then : | |
9308 | ||
ccc6cda3 | 9309 | fi |
3185942a | 9310 | |
ac50fbac CR |
9311 | |
9312 | ||
a0c0a00f CR |
9313 | ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" " |
9314 | #if HAVE_SYS_TIME_H | |
9315 | # include <sys/time.h> | |
9316 | #endif | |
9317 | ||
9318 | " | |
9319 | if test "x$ac_cv_header_sys_resource_h" = xyes; then : | |
9320 | $as_echo "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h | |
9321 | ||
9322 | fi | |
9323 | ||
9324 | ||
9325 | ||
ac50fbac CR |
9326 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
9327 | # for constant arguments. Useless! | |
9328 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 | |
9329 | $as_echo_n "checking for working alloca.h... " >&6; } | |
9330 | if ${ac_cv_working_alloca_h+:} false; then : | |
9331 | $as_echo_n "(cached) " >&6 | |
9332 | else | |
9333 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 9334 | /* end confdefs.h. */ |
ac50fbac | 9335 | #include <alloca.h> |
f73dda09 JA |
9336 | int |
9337 | main () | |
9338 | { | |
ac50fbac CR |
9339 | char *p = (char *) alloca (2 * sizeof (int)); |
9340 | if (p) return 0; | |
f73dda09 JA |
9341 | ; |
9342 | return 0; | |
9343 | } | |
9344 | _ACEOF | |
ac50fbac CR |
9345 | if ac_fn_c_try_link "$LINENO"; then : |
9346 | ac_cv_working_alloca_h=yes | |
f73dda09 | 9347 | else |
ac50fbac CR |
9348 | ac_cv_working_alloca_h=no |
9349 | fi | |
9350 | rm -f core conftest.err conftest.$ac_objext \ | |
9351 | conftest$ac_exeext conftest.$ac_ext | |
9352 | fi | |
9353 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 | |
9354 | $as_echo "$ac_cv_working_alloca_h" >&6; } | |
9355 | if test $ac_cv_working_alloca_h = yes; then | |
9356 | ||
9357 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h | |
0628567a | 9358 | |
f73dda09 | 9359 | fi |
3185942a | 9360 | |
ac50fbac CR |
9361 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
9362 | $as_echo_n "checking for alloca... " >&6; } | |
9363 | if ${ac_cv_func_alloca_works+:} false; then : | |
9364 | $as_echo_n "(cached) " >&6 | |
f73dda09 | 9365 | else |
ac50fbac | 9366 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 9367 | /* end confdefs.h. */ |
ac50fbac CR |
9368 | #ifdef __GNUC__ |
9369 | # define alloca __builtin_alloca | |
9370 | #else | |
9371 | # ifdef _MSC_VER | |
9372 | # include <malloc.h> | |
9373 | # define alloca _alloca | |
9374 | # else | |
9375 | # ifdef HAVE_ALLOCA_H | |
9376 | # include <alloca.h> | |
9377 | # else | |
9378 | # ifdef _AIX | |
9379 | #pragma alloca | |
9380 | # else | |
9381 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
9382 | void *alloca (size_t); | |
9383 | # endif | |
9384 | # endif | |
9385 | # endif | |
9386 | # endif | |
9387 | #endif | |
9388 | ||
f73dda09 JA |
9389 | int |
9390 | main () | |
9391 | { | |
ac50fbac CR |
9392 | char *p = (char *) alloca (1); |
9393 | if (p) return 0; | |
f73dda09 JA |
9394 | ; |
9395 | return 0; | |
9396 | } | |
9397 | _ACEOF | |
ac50fbac CR |
9398 | if ac_fn_c_try_link "$LINENO"; then : |
9399 | ac_cv_func_alloca_works=yes | |
ccc6cda3 | 9400 | else |
ac50fbac | 9401 | ac_cv_func_alloca_works=no |
f73dda09 | 9402 | fi |
ac50fbac CR |
9403 | rm -f core conftest.err conftest.$ac_objext \ |
9404 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 9405 | fi |
ac50fbac CR |
9406 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
9407 | $as_echo "$ac_cv_func_alloca_works" >&6; } | |
3185942a | 9408 | |
ac50fbac | 9409 | if test $ac_cv_func_alloca_works = yes; then |
3185942a | 9410 | |
ac50fbac | 9411 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h |
3185942a | 9412 | |
ac50fbac CR |
9413 | else |
9414 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
9415 | # that cause trouble. Some versions do not even contain alloca or | |
9416 | # contain a buggy version. If you still want to use their alloca, | |
9417 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
ccc6cda3 | 9418 | |
ac50fbac | 9419 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext |
b80f6443 | 9420 | |
ac50fbac CR |
9421 | $as_echo "#define C_ALLOCA 1" >>confdefs.h |
9422 | ||
9423 | ||
9424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 | |
9425 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } | |
9426 | if ${ac_cv_os_cray+:} false; then : | |
3185942a | 9427 | $as_echo_n "(cached) " >&6 |
f73dda09 | 9428 | else |
ac50fbac | 9429 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 9430 | /* end confdefs.h. */ |
ac50fbac CR |
9431 | #if defined CRAY && ! defined CRAY2 |
9432 | webecray | |
9433 | #else | |
9434 | wenotbecray | |
9435 | #endif | |
3185942a | 9436 | |
f73dda09 | 9437 | _ACEOF |
ac50fbac CR |
9438 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
9439 | $EGREP "webecray" >/dev/null 2>&1; then : | |
9440 | ac_cv_os_cray=yes | |
9441 | else | |
9442 | ac_cv_os_cray=no | |
9443 | fi | |
9444 | rm -f conftest* | |
9445 | ||
9446 | fi | |
9447 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 | |
9448 | $as_echo "$ac_cv_os_cray" >&6; } | |
9449 | if test $ac_cv_os_cray = yes; then | |
9450 | for ac_func in _getb67 GETB67 getb67; do | |
9451 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9452 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9453 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9454 | ||
9455 | cat >>confdefs.h <<_ACEOF | |
9456 | #define CRAY_STACKSEG_END $ac_func | |
0628567a | 9457 | _ACEOF |
ac50fbac CR |
9458 | |
9459 | break | |
9460 | fi | |
9461 | ||
9462 | done | |
9463 | fi | |
9464 | ||
9465 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 | |
9466 | $as_echo_n "checking stack direction for C alloca... " >&6; } | |
9467 | if ${ac_cv_c_stack_direction+:} false; then : | |
9468 | $as_echo_n "(cached) " >&6 | |
9469 | else | |
9470 | if test "$cross_compiling" = yes; then : | |
9471 | ac_cv_c_stack_direction=0 | |
9472 | else | |
9473 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 9474 | /* end confdefs.h. */ |
f73dda09 JA |
9475 | $ac_includes_default |
9476 | int | |
ac50fbac | 9477 | find_stack_direction (int *addr, int depth) |
f73dda09 | 9478 | { |
ac50fbac CR |
9479 | int dir, dummy = 0; |
9480 | if (! addr) | |
9481 | addr = &dummy; | |
9482 | *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; | |
9483 | dir = depth ? find_stack_direction (addr, depth - 1) : 0; | |
9484 | return dir + dummy; | |
9485 | } | |
b80f6443 | 9486 | |
ac50fbac CR |
9487 | int |
9488 | main (int argc, char **argv) | |
9489 | { | |
9490 | return find_stack_direction (0, argc + !argv + 20) < 0; | |
f73dda09 JA |
9491 | } |
9492 | _ACEOF | |
ac50fbac CR |
9493 | if ac_fn_c_try_run "$LINENO"; then : |
9494 | ac_cv_c_stack_direction=1 | |
f73dda09 | 9495 | else |
ac50fbac CR |
9496 | ac_cv_c_stack_direction=-1 |
9497 | fi | |
9498 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9499 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9500 | fi | |
9501 | ||
9502 | fi | |
9503 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 | |
9504 | $as_echo "$ac_cv_c_stack_direction" >&6; } | |
9505 | cat >>confdefs.h <<_ACEOF | |
9506 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
9507 | _ACEOF | |
9508 | ||
0628567a | 9509 | |
a0c0a00f CR |
9510 | fi |
9511 | ||
9512 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 | |
9513 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
9514 | if ${ac_cv_type_uid_t+:} false; then : | |
9515 | $as_echo_n "(cached) " >&6 | |
9516 | else | |
9517 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9518 | /* end confdefs.h. */ | |
9519 | #include <sys/types.h> | |
9520 | ||
9521 | _ACEOF | |
9522 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
9523 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
9524 | ac_cv_type_uid_t=yes | |
9525 | else | |
9526 | ac_cv_type_uid_t=no | |
9527 | fi | |
9528 | rm -f conftest* | |
9529 | ||
9530 | fi | |
9531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 | |
9532 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
9533 | if test $ac_cv_type_uid_t = no; then | |
9534 | ||
9535 | $as_echo "#define uid_t int" >>confdefs.h | |
9536 | ||
9537 | ||
9538 | $as_echo "#define gid_t int" >>confdefs.h | |
9539 | ||
9540 | fi | |
9541 | ||
9542 | for ac_header in unistd.h | |
9543 | do : | |
9544 | ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default" | |
9545 | if test "x$ac_cv_header_unistd_h" = xyes; then : | |
9546 | cat >>confdefs.h <<_ACEOF | |
9547 | #define HAVE_UNISTD_H 1 | |
9548 | _ACEOF | |
9549 | ||
9550 | fi | |
9551 | ||
9552 | done | |
9553 | ||
9554 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5 | |
9555 | $as_echo_n "checking for working chown... " >&6; } | |
9556 | if ${ac_cv_func_chown_works+:} false; then : | |
9557 | $as_echo_n "(cached) " >&6 | |
9558 | else | |
9559 | if test "$cross_compiling" = yes; then : | |
9560 | ac_cv_func_chown_works=no | |
9561 | else | |
9562 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9563 | /* end confdefs.h. */ | |
9564 | $ac_includes_default | |
9565 | #include <fcntl.h> | |
9566 | ||
9567 | int | |
9568 | main () | |
9569 | { | |
9570 | char *f = "conftest.chown"; | |
9571 | struct stat before, after; | |
9572 | ||
9573 | if (creat (f, 0600) < 0) | |
9574 | return 1; | |
9575 | if (stat (f, &before) < 0) | |
9576 | return 1; | |
9577 | if (chown (f, (uid_t) -1, (gid_t) -1) == -1) | |
9578 | return 1; | |
9579 | if (stat (f, &after) < 0) | |
9580 | return 1; | |
9581 | return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid); | |
9582 | ||
9583 | ; | |
9584 | return 0; | |
9585 | } | |
9586 | _ACEOF | |
9587 | if ac_fn_c_try_run "$LINENO"; then : | |
9588 | ac_cv_func_chown_works=yes | |
9589 | else | |
9590 | ac_cv_func_chown_works=no | |
9591 | fi | |
9592 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9593 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9594 | fi | |
9595 | ||
9596 | rm -f conftest.chown | |
9597 | ||
9598 | fi | |
9599 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5 | |
9600 | $as_echo "$ac_cv_func_chown_works" >&6; } | |
9601 | if test $ac_cv_func_chown_works = yes; then | |
9602 | ||
9603 | $as_echo "#define HAVE_CHOWN 1" >>confdefs.h | |
9604 | ||
f73dda09 | 9605 | fi |
3185942a | 9606 | |
ac50fbac CR |
9607 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5 |
9608 | $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; } | |
9609 | if ${ac_cv_func_getpgrp_void+:} false; then : | |
9610 | $as_echo_n "(cached) " >&6 | |
f73dda09 | 9611 | else |
ac50fbac CR |
9612 | # Use it with a single arg. |
9613 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 9614 | /* end confdefs.h. */ |
b80f6443 JA |
9615 | $ac_includes_default |
9616 | int | |
9617 | main () | |
9618 | { | |
ac50fbac | 9619 | getpgrp (0); |
b80f6443 JA |
9620 | ; |
9621 | return 0; | |
9622 | } | |
9623 | _ACEOF | |
ac50fbac CR |
9624 | if ac_fn_c_try_compile "$LINENO"; then : |
9625 | ac_cv_func_getpgrp_void=no | |
9626 | else | |
9627 | ac_cv_func_getpgrp_void=yes | |
9628 | fi | |
9629 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9630 | ||
9631 | fi | |
9632 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5 | |
9633 | $as_echo "$ac_cv_func_getpgrp_void" >&6; } | |
9634 | if test $ac_cv_func_getpgrp_void = yes; then | |
9635 | ||
9636 | $as_echo "#define GETPGRP_VOID 1" >>confdefs.h | |
9637 | ||
9638 | fi | |
9639 | ||
9640 | if ${ac_cv_func_setvbuf_reversed+:} false; then : | |
9641 | $as_echo_n "(cached) " >&6 | |
9642 | else | |
9643 | ac_cv_func_setvbuf_reversed=no | |
9644 | fi | |
9645 | ||
9646 | ||
9647 | for ac_func in vprintf | |
9648 | do : | |
9649 | ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" | |
9650 | if test "x$ac_cv_func_vprintf" = xyes; then : | |
9651 | cat >>confdefs.h <<_ACEOF | |
9652 | #define HAVE_VPRINTF 1 | |
0628567a | 9653 | _ACEOF |
ac50fbac CR |
9654 | |
9655 | ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" | |
9656 | if test "x$ac_cv_func__doprnt" = xyes; then : | |
9657 | ||
9658 | $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h | |
9659 | ||
9660 | fi | |
9661 | ||
9662 | fi | |
9663 | done | |
9664 | ||
9665 | ||
9666 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5 | |
9667 | $as_echo_n "checking for working strcoll... " >&6; } | |
9668 | if ${ac_cv_func_strcoll_works+:} false; then : | |
9669 | $as_echo_n "(cached) " >&6 | |
9670 | else | |
9671 | if test "$cross_compiling" = yes; then : | |
9672 | ac_cv_func_strcoll_works=no | |
9673 | else | |
9674 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 9675 | /* end confdefs.h. */ |
f73dda09 JA |
9676 | $ac_includes_default |
9677 | int | |
9678 | main () | |
9679 | { | |
ac50fbac CR |
9680 | return (strcoll ("abc", "def") >= 0 || |
9681 | strcoll ("ABC", "DEF") >= 0 || | |
9682 | strcoll ("123", "456") >= 0) | |
f73dda09 JA |
9683 | ; |
9684 | return 0; | |
9685 | } | |
9686 | _ACEOF | |
ac50fbac CR |
9687 | if ac_fn_c_try_run "$LINENO"; then : |
9688 | ac_cv_func_strcoll_works=yes | |
f73dda09 | 9689 | else |
ac50fbac CR |
9690 | ac_cv_func_strcoll_works=no |
9691 | fi | |
9692 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9693 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9694 | fi | |
0628567a | 9695 | |
f73dda09 | 9696 | fi |
ac50fbac CR |
9697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5 |
9698 | $as_echo "$ac_cv_func_strcoll_works" >&6; } | |
9699 | if test $ac_cv_func_strcoll_works = yes; then | |
3185942a | 9700 | |
ac50fbac | 9701 | $as_echo "#define HAVE_STRCOLL 1" >>confdefs.h |
0628567a | 9702 | |
b80f6443 | 9703 | fi |
3185942a | 9704 | |
ac50fbac CR |
9705 | |
9706 | ||
9707 | if test "$ac_cv_func_alloca_works" = "no" && test "$opt_bash_malloc" = "no"; then | |
9708 | MALLOC_TARGET=alloca | |
9709 | MALLOC_SRC=alloca.c | |
9710 | ||
9711 | MALLOC_LIB='-lmalloc' | |
9712 | MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a' | |
9713 | MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)' | |
9714 | MALLOC_DEP='$(MALLOC_LIBRARY)' | |
ccc6cda3 | 9715 | fi |
3185942a | 9716 | |
ac50fbac CR |
9717 | if test "$ac_cv_func_vprintf" = no; then |
9718 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of vprintf in stdio.h" >&5 | |
9719 | $as_echo_n "checking for declaration of vprintf in stdio.h... " >&6; } | |
9720 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9721 | /* end confdefs.h. */ | |
9722 | #include <stdio.h> | |
9723 | ||
0628567a | 9724 | _ACEOF |
ac50fbac CR |
9725 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
9726 | $EGREP "[int[ ]*vprintf[^a-zA-Z0-9]]" >/dev/null 2>&1; then : | |
9727 | ac_cv_func_vprintf=yes | |
9728 | fi | |
9729 | rm -f conftest* | |
9730 | ||
9731 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vprintf" >&5 | |
9732 | $as_echo "$ac_cv_func_vprintf" >&6; } | |
9733 | if test $ac_cv_func_vprintf = yes; then | |
9734 | $as_echo "#define HAVE_VPRINTF 1" >>confdefs.h | |
9735 | ||
9736 | fi | |
9737 | fi | |
9738 | ||
9739 | if test "$ac_cv_func_vprintf" = no && test "$ac_cv_func__doprnt" = "yes"; then | |
9740 | case " $LIBOBJS " in | |
9741 | *" vprint.$ac_objext "* ) ;; | |
9742 | *) LIBOBJS="$LIBOBJS vprint.$ac_objext" | |
9743 | ;; | |
9744 | esac | |
9745 | ||
9746 | fi | |
9747 | ||
9748 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 | |
9749 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
9750 | if ${ac_cv_type_signal+:} false; then : | |
9751 | $as_echo_n "(cached) " >&6 | |
9752 | else | |
9753 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 9754 | /* end confdefs.h. */ |
ac50fbac CR |
9755 | #include <sys/types.h> |
9756 | #include <signal.h> | |
9757 | ||
f73dda09 JA |
9758 | int |
9759 | main () | |
9760 | { | |
ac50fbac | 9761 | return *(signal (0, 0)) (0) == 1; |
f73dda09 JA |
9762 | ; |
9763 | return 0; | |
9764 | } | |
9765 | _ACEOF | |
ac50fbac CR |
9766 | if ac_fn_c_try_compile "$LINENO"; then : |
9767 | ac_cv_type_signal=int | |
f73dda09 | 9768 | else |
ac50fbac CR |
9769 | ac_cv_type_signal=void |
9770 | fi | |
9771 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9772 | fi | |
9773 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
9774 | $as_echo "$ac_cv_type_signal" >&6; } | |
9775 | ||
9776 | cat >>confdefs.h <<_ACEOF | |
9777 | #define RETSIGTYPE $ac_cv_type_signal | |
9778 | _ACEOF | |
9779 | ||
9780 | ||
9781 | ||
9782 | ac_fn_c_check_func "$LINENO" "__setostype" "ac_cv_func___setostype" | |
9783 | if test "x$ac_cv_func___setostype" = xyes; then : | |
9784 | $as_echo "#define HAVE_SETOSTYPE 1" >>confdefs.h | |
0628567a | 9785 | |
f73dda09 | 9786 | fi |
3185942a | 9787 | |
ac50fbac CR |
9788 | ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3" |
9789 | if test "x$ac_cv_func_wait3" = xyes; then : | |
9790 | $as_echo "#define HAVE_WAIT3 1" >>confdefs.h | |
9791 | ||
9792 | fi | |
9793 | ||
9794 | ||
9795 | ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo" | |
9796 | if test "x$ac_cv_func_mkfifo" = xyes; then : | |
9797 | $as_echo "#define HAVE_MKFIFO 1" >>confdefs.h | |
9798 | ||
9799 | else | |
9800 | $as_echo "#define MKFIFO_MISSING 1" >>confdefs.h | |
9801 | ||
9802 | fi | |
9803 | ||
9804 | ||
9805 | for ac_func in dup2 eaccess fcntl getdtablesize getgroups gethostname \ | |
9806 | getpagesize getpeername getrlimit getrusage gettimeofday \ | |
a0c0a00f | 9807 | kill killpg lstat pselect readlink sbrk select setdtablesize \ |
ac50fbac CR |
9808 | setitimer tcgetpgrp uname ulimit waitpid |
9809 | do : | |
9810 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9811 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9812 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9813 | cat >>confdefs.h <<_ACEOF | |
9814 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9815 | _ACEOF | |
9816 | ||
9817 | fi | |
f73dda09 | 9818 | done |
ac50fbac CR |
9819 | |
9820 | ac_fn_c_check_func "$LINENO" "rename" "ac_cv_func_rename" | |
9821 | if test "x$ac_cv_func_rename" = xyes; then : | |
9822 | $as_echo "#define HAVE_RENAME 1" >>confdefs.h | |
9823 | ||
ccc6cda3 | 9824 | else |
ac50fbac CR |
9825 | case " $LIBOBJS " in |
9826 | *" rename.$ac_objext "* ) ;; | |
9827 | *) LIBOBJS="$LIBOBJS rename.$ac_objext" | |
9828 | ;; | |
9829 | esac | |
9830 | ||
9831 | fi | |
9832 | ||
9833 | ||
9834 | ||
9835 | for ac_func in bcopy bzero confstr faccessat fnmatch \ | |
9836 | getaddrinfo gethostbyname getservbyname getservent inet_aton \ | |
a0c0a00f | 9837 | imaxdiv memmove pathconf putenv raise random regcomp regexec \ |
ac50fbac CR |
9838 | setenv setlinebuf setlocale setvbuf siginterrupt strchr \ |
9839 | sysconf syslog tcgetattr times ttyname tzset unsetenv | |
9840 | do : | |
9841 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9842 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9843 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9844 | cat >>confdefs.h <<_ACEOF | |
9845 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
0628567a | 9846 | _ACEOF |
b80f6443 | 9847 | |
ac50fbac CR |
9848 | fi |
9849 | done | |
b80f6443 | 9850 | |
ac50fbac CR |
9851 | |
9852 | for ac_func in vasprintf asprintf | |
9853 | do : | |
9854 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9855 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9856 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9857 | cat >>confdefs.h <<_ACEOF | |
9858 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
f73dda09 | 9859 | _ACEOF |
0628567a | 9860 | |
ccc6cda3 | 9861 | fi |
ac50fbac CR |
9862 | done |
9863 | ||
9864 | for ac_func in isascii isblank isgraph isprint isspace isxdigit | |
9865 | do : | |
9866 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9867 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9868 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9869 | cat >>confdefs.h <<_ACEOF | |
9870 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9871 | _ACEOF | |
9872 | ||
ccc6cda3 | 9873 | fi |
ac50fbac CR |
9874 | done |
9875 | ||
9876 | for ac_func in getpwent getpwnam getpwuid | |
9877 | do : | |
9878 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9879 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9880 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9881 | cat >>confdefs.h <<_ACEOF | |
9882 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9883 | _ACEOF | |
9884 | ||
ccc6cda3 | 9885 | fi |
ac50fbac | 9886 | done |
ccc6cda3 | 9887 | |
a0c0a00f CR |
9888 | for ac_func in mkstemp |
9889 | do : | |
9890 | ac_fn_c_check_func "$LINENO" "mkstemp" "ac_cv_func_mkstemp" | |
9891 | if test "x$ac_cv_func_mkstemp" = xyes; then : | |
9892 | cat >>confdefs.h <<_ACEOF | |
9893 | #define HAVE_MKSTEMP 1 | |
9894 | _ACEOF | |
9895 | ||
9896 | fi | |
9897 | done | |
9898 | ||
ac50fbac CR |
9899 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" |
9900 | if test "x$ac_cv_func_getcwd" = xyes; then : | |
9901 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h | |
b80f6443 | 9902 | |
ac50fbac CR |
9903 | else |
9904 | case " $LIBOBJS " in | |
9905 | *" getcwd.$ac_objext "* ) ;; | |
9906 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" | |
9907 | ;; | |
9908 | esac | |
3185942a | 9909 | |
ac50fbac | 9910 | fi |
0628567a | 9911 | |
ac50fbac CR |
9912 | ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset" |
9913 | if test "x$ac_cv_func_memset" = xyes; then : | |
9914 | $as_echo "#define HAVE_MEMSET 1" >>confdefs.h | |
f73dda09 | 9915 | |
f73dda09 | 9916 | else |
ac50fbac CR |
9917 | case " $LIBOBJS " in |
9918 | *" memset.$ac_objext "* ) ;; | |
9919 | *) LIBOBJS="$LIBOBJS memset.$ac_objext" | |
9920 | ;; | |
3185942a | 9921 | esac |
b80f6443 | 9922 | |
ac50fbac CR |
9923 | fi |
9924 | ||
9925 | ||
9926 | ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp" | |
9927 | if test "x$ac_cv_func_strcasecmp" = xyes; then : | |
9928 | $as_echo "#define HAVE_STRCASECMP 1" >>confdefs.h | |
9929 | ||
f73dda09 | 9930 | else |
ac50fbac CR |
9931 | case " $LIBOBJS " in |
9932 | *" strcasecmp.$ac_objext "* ) ;; | |
9933 | *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext" | |
9934 | ;; | |
9935 | esac | |
0628567a | 9936 | |
f73dda09 | 9937 | fi |
3185942a | 9938 | |
ac50fbac CR |
9939 | ac_fn_c_check_func "$LINENO" "strcasestr" "ac_cv_func_strcasestr" |
9940 | if test "x$ac_cv_func_strcasestr" = xyes; then : | |
9941 | $as_echo "#define HAVE_STRCASESTR 1" >>confdefs.h | |
9942 | ||
f73dda09 | 9943 | else |
ac50fbac CR |
9944 | case " $LIBOBJS " in |
9945 | *" strcasestr.$ac_objext "* ) ;; | |
9946 | *) LIBOBJS="$LIBOBJS strcasestr.$ac_objext" | |
9947 | ;; | |
9948 | esac | |
0628567a | 9949 | |
ac50fbac | 9950 | fi |
b80f6443 | 9951 | |
ac50fbac CR |
9952 | ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror" |
9953 | if test "x$ac_cv_func_strerror" = xyes; then : | |
9954 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
b80f6443 | 9955 | |
f73dda09 | 9956 | else |
ac50fbac CR |
9957 | case " $LIBOBJS " in |
9958 | *" strerror.$ac_objext "* ) ;; | |
9959 | *) LIBOBJS="$LIBOBJS strerror.$ac_objext" | |
9960 | ;; | |
9961 | esac | |
0628567a | 9962 | |
f73dda09 | 9963 | fi |
3185942a | 9964 | |
ac50fbac CR |
9965 | ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" |
9966 | if test "x$ac_cv_func_strftime" = xyes; then : | |
9967 | $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h | |
9968 | ||
b80f6443 | 9969 | else |
ac50fbac CR |
9970 | case " $LIBOBJS " in |
9971 | *" strftime.$ac_objext "* ) ;; | |
9972 | *) LIBOBJS="$LIBOBJS strftime.$ac_objext" | |
9973 | ;; | |
9974 | esac | |
0628567a | 9975 | |
b80f6443 | 9976 | fi |
3185942a | 9977 | |
ac50fbac CR |
9978 | ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen" |
9979 | if test "x$ac_cv_func_strnlen" = xyes; then : | |
9980 | $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h | |
9981 | ||
9982 | else | |
9983 | case " $LIBOBJS " in | |
9984 | *" strnlen.$ac_objext "* ) ;; | |
9985 | *) LIBOBJS="$LIBOBJS strnlen.$ac_objext" | |
9986 | ;; | |
9987 | esac | |
9988 | ||
ccc6cda3 | 9989 | fi |
3185942a | 9990 | |
ac50fbac CR |
9991 | ac_fn_c_check_func "$LINENO" "strpbrk" "ac_cv_func_strpbrk" |
9992 | if test "x$ac_cv_func_strpbrk" = xyes; then : | |
9993 | $as_echo "#define HAVE_STRPBRK 1" >>confdefs.h | |
b80f6443 | 9994 | |
f73dda09 | 9995 | else |
ac50fbac CR |
9996 | case " $LIBOBJS " in |
9997 | *" strpbrk.$ac_objext "* ) ;; | |
9998 | *) LIBOBJS="$LIBOBJS strpbrk.$ac_objext" | |
9999 | ;; | |
10000 | esac | |
0628567a | 10001 | |
f73dda09 | 10002 | fi |
3185942a | 10003 | |
ac50fbac CR |
10004 | ac_fn_c_check_func "$LINENO" "strstr" "ac_cv_func_strstr" |
10005 | if test "x$ac_cv_func_strstr" = xyes; then : | |
10006 | $as_echo "#define HAVE_STRSTR 1" >>confdefs.h | |
10007 | ||
ccc6cda3 | 10008 | else |
ac50fbac CR |
10009 | case " $LIBOBJS " in |
10010 | *" strstr.$ac_objext "* ) ;; | |
10011 | *) LIBOBJS="$LIBOBJS strstr.$ac_objext" | |
10012 | ;; | |
10013 | esac | |
b80f6443 | 10014 | |
ac50fbac | 10015 | fi |
b80f6443 | 10016 | |
ac50fbac CR |
10017 | |
10018 | ac_fn_c_check_func "$LINENO" "strtod" "ac_cv_func_strtod" | |
10019 | if test "x$ac_cv_func_strtod" = xyes; then : | |
10020 | $as_echo "#define HAVE_STRTOD 1" >>confdefs.h | |
10021 | ||
10022 | else | |
10023 | case " $LIBOBJS " in | |
10024 | *" strtod.$ac_objext "* ) ;; | |
10025 | *) LIBOBJS="$LIBOBJS strtod.$ac_objext" | |
10026 | ;; | |
3185942a | 10027 | esac |
ac50fbac CR |
10028 | |
10029 | fi | |
10030 | ||
10031 | ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol" | |
10032 | if test "x$ac_cv_func_strtol" = xyes; then : | |
10033 | $as_echo "#define HAVE_STRTOL 1" >>confdefs.h | |
10034 | ||
10035 | else | |
10036 | case " $LIBOBJS " in | |
10037 | *" strtol.$ac_objext "* ) ;; | |
10038 | *) LIBOBJS="$LIBOBJS strtol.$ac_objext" | |
10039 | ;; | |
3185942a | 10040 | esac |
ac50fbac CR |
10041 | |
10042 | fi | |
10043 | ||
10044 | ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul" | |
10045 | if test "x$ac_cv_func_strtoul" = xyes; then : | |
10046 | $as_echo "#define HAVE_STRTOUL 1" >>confdefs.h | |
10047 | ||
ccc6cda3 | 10048 | else |
ac50fbac CR |
10049 | case " $LIBOBJS " in |
10050 | *" strtoul.$ac_objext "* ) ;; | |
10051 | *) LIBOBJS="$LIBOBJS strtoul.$ac_objext" | |
10052 | ;; | |
10053 | esac | |
0628567a | 10054 | |
ccc6cda3 | 10055 | fi |
ac50fbac CR |
10056 | |
10057 | ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" | |
10058 | if test "x$ac_cv_func_strtoll" = xyes; then : | |
10059 | $as_echo "#define HAVE_STRTOLL 1" >>confdefs.h | |
10060 | ||
10061 | else | |
10062 | case " $LIBOBJS " in | |
10063 | *" strtoll.$ac_objext "* ) ;; | |
10064 | *) LIBOBJS="$LIBOBJS strtoll.$ac_objext" | |
10065 | ;; | |
10066 | esac | |
10067 | ||
ccc6cda3 | 10068 | fi |
ac50fbac CR |
10069 | |
10070 | ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull" | |
10071 | if test "x$ac_cv_func_strtoull" = xyes; then : | |
10072 | $as_echo "#define HAVE_STRTOULL 1" >>confdefs.h | |
10073 | ||
10074 | else | |
10075 | case " $LIBOBJS " in | |
10076 | *" strtoull.$ac_objext "* ) ;; | |
10077 | *) LIBOBJS="$LIBOBJS strtoull.$ac_objext" | |
10078 | ;; | |
10079 | esac | |
10080 | ||
ccc6cda3 | 10081 | fi |
ccc6cda3 | 10082 | |
ac50fbac CR |
10083 | ac_fn_c_check_func "$LINENO" "strtoimax" "ac_cv_func_strtoimax" |
10084 | if test "x$ac_cv_func_strtoimax" = xyes; then : | |
10085 | $as_echo "#define HAVE_STRTOIMAX 1" >>confdefs.h | |
b80f6443 | 10086 | |
ac50fbac CR |
10087 | else |
10088 | case " $LIBOBJS " in | |
10089 | *" strtoimax.$ac_objext "* ) ;; | |
10090 | *) LIBOBJS="$LIBOBJS strtoimax.$ac_objext" | |
10091 | ;; | |
10092 | esac | |
3185942a | 10093 | |
ac50fbac | 10094 | fi |
0628567a | 10095 | |
ac50fbac CR |
10096 | ac_fn_c_check_func "$LINENO" "strtoumax" "ac_cv_func_strtoumax" |
10097 | if test "x$ac_cv_func_strtoumax" = xyes; then : | |
10098 | $as_echo "#define HAVE_STRTOUMAX 1" >>confdefs.h | |
f73dda09 | 10099 | |
f73dda09 | 10100 | else |
ac50fbac CR |
10101 | case " $LIBOBJS " in |
10102 | *" strtoumax.$ac_objext "* ) ;; | |
10103 | *) LIBOBJS="$LIBOBJS strtoumax.$ac_objext" | |
10104 | ;; | |
10105 | esac | |
b80f6443 | 10106 | |
ac50fbac CR |
10107 | fi |
10108 | ||
10109 | ||
10110 | ac_fn_c_check_func "$LINENO" "dprintf" "ac_cv_func_dprintf" | |
10111 | if test "x$ac_cv_func_dprintf" = xyes; then : | |
10112 | $as_echo "#define HAVE_DPRINTF 1" >>confdefs.h | |
10113 | ||
10114 | else | |
10115 | case " $LIBOBJS " in | |
10116 | *" dprintf.$ac_objext "* ) ;; | |
10117 | *) LIBOBJS="$LIBOBJS dprintf.$ac_objext" | |
10118 | ;; | |
3185942a | 10119 | esac |
b80f6443 | 10120 | |
ac50fbac CR |
10121 | fi |
10122 | ||
10123 | ||
10124 | ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul" | |
10125 | if test "x$ac_cv_func_strchrnul" = xyes; then : | |
10126 | $as_echo "#define HAVE_STRCHRNUL 1" >>confdefs.h | |
10127 | ||
10128 | else | |
10129 | case " $LIBOBJS " in | |
10130 | *" strchrnul.$ac_objext "* ) ;; | |
10131 | *) LIBOBJS="$LIBOBJS strchrnul.$ac_objext" | |
10132 | ;; | |
3185942a | 10133 | esac |
ac50fbac CR |
10134 | |
10135 | fi | |
10136 | ||
10137 | ||
10138 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" | |
10139 | if test "x$ac_cv_func_strdup" = xyes; then : | |
10140 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h | |
10141 | ||
f73dda09 | 10142 | else |
ac50fbac CR |
10143 | case " $LIBOBJS " in |
10144 | *" strdup.$ac_objext "* ) ;; | |
10145 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" | |
10146 | ;; | |
10147 | esac | |
0628567a | 10148 | |
f73dda09 | 10149 | fi |
3185942a | 10150 | |
ac50fbac CR |
10151 | |
10152 | ||
a0c0a00f CR |
10153 | for ac_header in libaudit.h |
10154 | do : | |
10155 | ac_fn_c_check_header_mongrel "$LINENO" "libaudit.h" "ac_cv_header_libaudit_h" "$ac_includes_default" | |
10156 | if test "x$ac_cv_header_libaudit_h" = xyes; then : | |
10157 | cat >>confdefs.h <<_ACEOF | |
10158 | #define HAVE_LIBAUDIT_H 1 | |
10159 | _ACEOF | |
10160 | ||
10161 | fi | |
10162 | ||
10163 | done | |
10164 | ||
ac50fbac CR |
10165 | ac_fn_c_check_decl "$LINENO" "AUDIT_USER_TTY" "ac_cv_have_decl_AUDIT_USER_TTY" "#include <linux/audit.h> |
10166 | " | |
10167 | if test "x$ac_cv_have_decl_AUDIT_USER_TTY" = xyes; then : | |
10168 | ac_have_decl=1 | |
ccc6cda3 | 10169 | else |
ac50fbac CR |
10170 | ac_have_decl=0 |
10171 | fi | |
0628567a | 10172 | |
ac50fbac CR |
10173 | cat >>confdefs.h <<_ACEOF |
10174 | #define HAVE_DECL_AUDIT_USER_TTY $ac_have_decl | |
0628567a | 10175 | _ACEOF |
b80f6443 | 10176 | |
b80f6443 | 10177 | |
ac50fbac CR |
10178 | ac_fn_c_check_decl "$LINENO" "confstr" "ac_cv_have_decl_confstr" "$ac_includes_default" |
10179 | if test "x$ac_cv_have_decl_confstr" = xyes; then : | |
10180 | ac_have_decl=1 | |
f73dda09 | 10181 | else |
ac50fbac | 10182 | ac_have_decl=0 |
f73dda09 | 10183 | fi |
3185942a | 10184 | |
ac50fbac CR |
10185 | cat >>confdefs.h <<_ACEOF |
10186 | #define HAVE_DECL_CONFSTR $ac_have_decl | |
10187 | _ACEOF | |
0628567a | 10188 | |
ac50fbac CR |
10189 | ac_fn_c_check_decl "$LINENO" "printf" "ac_cv_have_decl_printf" "$ac_includes_default" |
10190 | if test "x$ac_cv_have_decl_printf" = xyes; then : | |
10191 | ac_have_decl=1 | |
10192 | else | |
10193 | ac_have_decl=0 | |
b80f6443 | 10194 | fi |
3185942a | 10195 | |
ac50fbac CR |
10196 | cat >>confdefs.h <<_ACEOF |
10197 | #define HAVE_DECL_PRINTF $ac_have_decl | |
10198 | _ACEOF | |
10199 | ||
10200 | ac_fn_c_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default" | |
10201 | if test "x$ac_cv_have_decl_sbrk" = xyes; then : | |
10202 | ac_have_decl=1 | |
10203 | else | |
10204 | ac_have_decl=0 | |
ccc6cda3 | 10205 | fi |
3185942a | 10206 | |
ac50fbac CR |
10207 | cat >>confdefs.h <<_ACEOF |
10208 | #define HAVE_DECL_SBRK $ac_have_decl | |
0628567a | 10209 | _ACEOF |
b80f6443 | 10210 | |
ac50fbac CR |
10211 | ac_fn_c_check_decl "$LINENO" "setregid" "ac_cv_have_decl_setregid" "$ac_includes_default" |
10212 | if test "x$ac_cv_have_decl_setregid" = xyes; then : | |
10213 | ac_have_decl=1 | |
10214 | else | |
10215 | ac_have_decl=0 | |
10216 | fi | |
10217 | ||
10218 | cat >>confdefs.h <<_ACEOF | |
10219 | #define HAVE_DECL_SETREGID $ac_have_decl | |
f73dda09 | 10220 | _ACEOF |
ac50fbac CR |
10221 | |
10222 | ac_fn_c_check_decl "$LINENO" "strcpy" "ac_cv_have_decl_strcpy" "$ac_includes_default" | |
10223 | if test "x$ac_cv_have_decl_strcpy" = xyes; then : | |
10224 | ac_have_decl=1 | |
f73dda09 | 10225 | else |
ac50fbac CR |
10226 | ac_have_decl=0 |
10227 | fi | |
0628567a | 10228 | |
ac50fbac CR |
10229 | cat >>confdefs.h <<_ACEOF |
10230 | #define HAVE_DECL_STRCPY $ac_have_decl | |
10231 | _ACEOF | |
10232 | ||
10233 | ac_fn_c_check_decl "$LINENO" "strsignal" "ac_cv_have_decl_strsignal" "$ac_includes_default" | |
10234 | if test "x$ac_cv_have_decl_strsignal" = xyes; then : | |
10235 | ac_have_decl=1 | |
10236 | else | |
10237 | ac_have_decl=0 | |
f73dda09 | 10238 | fi |
3185942a | 10239 | |
ac50fbac CR |
10240 | cat >>confdefs.h <<_ACEOF |
10241 | #define HAVE_DECL_STRSIGNAL $ac_have_decl | |
10242 | _ACEOF | |
10243 | ||
10244 | ||
10245 | ac_fn_c_check_decl "$LINENO" "strtold" "ac_cv_have_decl_strtold" "$ac_includes_default" | |
10246 | if test "x$ac_cv_have_decl_strtold" = xyes; then : | |
10247 | ac_have_decl=1 | |
bb70624e | 10248 | else |
ac50fbac CR |
10249 | ac_have_decl=0 |
10250 | fi | |
10251 | ||
10252 | cat >>confdefs.h <<_ACEOF | |
10253 | #define HAVE_DECL_STRTOLD $ac_have_decl | |
0628567a | 10254 | _ACEOF |
ac50fbac CR |
10255 | if test $ac_have_decl = 1; then : |
10256 | ||
10257 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken strtold" >&5 | |
10258 | $as_echo_n "checking for broken strtold... " >&6; } | |
10259 | if ${bash_cv_strtold_broken+:} false; then : | |
10260 | $as_echo_n "(cached) " >&6 | |
10261 | else | |
10262 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10263 | /* end confdefs.h. */ |
b80f6443 | 10264 | #include <stdlib.h> |
f73dda09 JA |
10265 | int |
10266 | main () | |
bb70624e | 10267 | { |
ac50fbac | 10268 | int main() { long double r; char *foo, bar; r = strtold(foo, &bar);} |
f73dda09 JA |
10269 | ; |
10270 | return 0; | |
bb70624e | 10271 | } |
f73dda09 | 10272 | _ACEOF |
ac50fbac CR |
10273 | if ac_fn_c_try_compile "$LINENO"; then : |
10274 | bash_cv_strtold_broken=no | |
bb70624e | 10275 | else |
ac50fbac | 10276 | bash_cv_strtold_broken=yes |
bb70624e | 10277 | fi |
ac50fbac CR |
10278 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
10279 | ||
10280 | ||
bb70624e | 10281 | fi |
ac50fbac CR |
10282 | |
10283 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_strtold_broken" >&5 | |
10284 | $as_echo "$bash_cv_strtold_broken" >&6; } | |
10285 | if test "$bash_cv_strtold_broken" = "yes" ; then | |
10286 | $as_echo "#define STRTOLD_BROKEN 1" >>confdefs.h | |
10287 | ||
10288 | fi | |
10289 | ||
f73dda09 | 10290 | fi |
bb70624e | 10291 | |
b80f6443 | 10292 | |
3185942a | 10293 | |
0628567a | 10294 | |
f73dda09 | 10295 | |
ac50fbac CR |
10296 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoimax" >&5 |
10297 | $as_echo_n "checking for declaration of strtoimax... " >&6; } | |
10298 | if ${bash_cv_decl_strtoimax+:} false; then : | |
3185942a | 10299 | $as_echo_n "(cached) " >&6 |
f73dda09 | 10300 | else |
ac50fbac | 10301 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 10302 | /* end confdefs.h. */ |
ac50fbac CR |
10303 | |
10304 | #if STDC_HEADERS | |
10305 | # include <stdlib.h> | |
10306 | #endif | |
10307 | #if HAVE_INTTYPES_H | |
10308 | # include <inttypes.h> | |
10309 | #endif | |
10310 | ||
f73dda09 JA |
10311 | int |
10312 | main () | |
10313 | { | |
ac50fbac | 10314 | return !strtoimax; |
f73dda09 JA |
10315 | ; |
10316 | return 0; | |
10317 | } | |
10318 | _ACEOF | |
ac50fbac CR |
10319 | if ac_fn_c_try_link "$LINENO"; then : |
10320 | bash_cv_decl_strtoimax=yes | |
10321 | else | |
10322 | bash_cv_decl_strtoimax=no | |
10323 | fi | |
10324 | rm -f core conftest.err conftest.$ac_objext \ | |
10325 | conftest$ac_exeext conftest.$ac_ext | |
10326 | fi | |
10327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoimax" >&5 | |
10328 | $as_echo "$bash_cv_decl_strtoimax" >&6; } | |
10329 | bash_tr_func=HAVE_DECL_`echo strtoimax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10330 | if test $bash_cv_decl_strtoimax = yes; then | |
10331 | cat >>confdefs.h <<_ACEOF | |
10332 | #define $bash_tr_func 1 | |
0628567a | 10333 | _ACEOF |
b80f6443 | 10334 | |
f73dda09 | 10335 | else |
ac50fbac CR |
10336 | cat >>confdefs.h <<_ACEOF |
10337 | #define $bash_tr_func 0 | |
10338 | _ACEOF | |
0628567a | 10339 | |
f73dda09 | 10340 | fi |
3185942a | 10341 | |
0628567a | 10342 | |
b80f6443 | 10343 | |
ac50fbac CR |
10344 | |
10345 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtol" >&5 | |
10346 | $as_echo_n "checking for declaration of strtol... " >&6; } | |
10347 | if ${bash_cv_decl_strtol+:} false; then : | |
10348 | $as_echo_n "(cached) " >&6 | |
10349 | else | |
10350 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10351 | /* end confdefs.h. */ |
ac50fbac CR |
10352 | |
10353 | #if STDC_HEADERS | |
10354 | # include <stdlib.h> | |
10355 | #endif | |
10356 | #if HAVE_INTTYPES_H | |
10357 | # include <inttypes.h> | |
10358 | #endif | |
10359 | ||
f73dda09 JA |
10360 | int |
10361 | main () | |
10362 | { | |
ac50fbac | 10363 | return !strtol; |
f73dda09 JA |
10364 | ; |
10365 | return 0; | |
10366 | } | |
10367 | _ACEOF | |
ac50fbac CR |
10368 | if ac_fn_c_try_link "$LINENO"; then : |
10369 | bash_cv_decl_strtol=yes | |
f73dda09 | 10370 | else |
ac50fbac | 10371 | bash_cv_decl_strtol=no |
f73dda09 | 10372 | fi |
ac50fbac CR |
10373 | rm -f core conftest.err conftest.$ac_objext \ |
10374 | conftest$ac_exeext conftest.$ac_ext | |
10375 | fi | |
10376 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtol" >&5 | |
10377 | $as_echo "$bash_cv_decl_strtol" >&6; } | |
10378 | bash_tr_func=HAVE_DECL_`echo strtol | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10379 | if test $bash_cv_decl_strtol = yes; then | |
10380 | cat >>confdefs.h <<_ACEOF | |
10381 | #define $bash_tr_func 1 | |
10382 | _ACEOF | |
3185942a | 10383 | |
b80f6443 | 10384 | else |
ac50fbac CR |
10385 | cat >>confdefs.h <<_ACEOF |
10386 | #define $bash_tr_func 0 | |
10387 | _ACEOF | |
0628567a | 10388 | |
b80f6443 | 10389 | fi |
3185942a | 10390 | |
3185942a | 10391 | |
ac50fbac CR |
10392 | |
10393 | ||
10394 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoll" >&5 | |
10395 | $as_echo_n "checking for declaration of strtoll... " >&6; } | |
10396 | if ${bash_cv_decl_strtoll+:} false; then : | |
10397 | $as_echo_n "(cached) " >&6 | |
10398 | else | |
10399 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10400 | /* end confdefs.h. */ |
ac50fbac CR |
10401 | |
10402 | #if STDC_HEADERS | |
10403 | # include <stdlib.h> | |
10404 | #endif | |
10405 | #if HAVE_INTTYPES_H | |
10406 | # include <inttypes.h> | |
10407 | #endif | |
10408 | ||
f73dda09 JA |
10409 | int |
10410 | main () | |
10411 | { | |
ac50fbac | 10412 | return !strtoll; |
f73dda09 JA |
10413 | ; |
10414 | return 0; | |
10415 | } | |
10416 | _ACEOF | |
ac50fbac CR |
10417 | if ac_fn_c_try_link "$LINENO"; then : |
10418 | bash_cv_decl_strtoll=yes | |
f73dda09 | 10419 | else |
ac50fbac | 10420 | bash_cv_decl_strtoll=no |
f73dda09 | 10421 | fi |
ac50fbac CR |
10422 | rm -f core conftest.err conftest.$ac_objext \ |
10423 | conftest$ac_exeext conftest.$ac_ext | |
10424 | fi | |
10425 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoll" >&5 | |
10426 | $as_echo "$bash_cv_decl_strtoll" >&6; } | |
10427 | bash_tr_func=HAVE_DECL_`echo strtoll | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10428 | if test $bash_cv_decl_strtoll = yes; then | |
10429 | cat >>confdefs.h <<_ACEOF | |
10430 | #define $bash_tr_func 1 | |
10431 | _ACEOF | |
3185942a | 10432 | |
bb70624e | 10433 | else |
ac50fbac CR |
10434 | cat >>confdefs.h <<_ACEOF |
10435 | #define $bash_tr_func 0 | |
0628567a | 10436 | _ACEOF |
ac50fbac CR |
10437 | |
10438 | fi | |
10439 | ||
10440 | ||
10441 | ||
10442 | ||
10443 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoul" >&5 | |
10444 | $as_echo_n "checking for declaration of strtoul... " >&6; } | |
10445 | if ${bash_cv_decl_strtoul+:} false; then : | |
10446 | $as_echo_n "(cached) " >&6 | |
10447 | else | |
10448 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10449 | /* end confdefs.h. */ |
ac50fbac CR |
10450 | |
10451 | #if STDC_HEADERS | |
10452 | # include <stdlib.h> | |
10453 | #endif | |
10454 | #if HAVE_INTTYPES_H | |
10455 | # include <inttypes.h> | |
10456 | #endif | |
10457 | ||
f73dda09 JA |
10458 | int |
10459 | main () | |
bb70624e | 10460 | { |
ac50fbac | 10461 | return !strtoul; |
f73dda09 JA |
10462 | ; |
10463 | return 0; | |
bb70624e | 10464 | } |
f73dda09 | 10465 | _ACEOF |
ac50fbac CR |
10466 | if ac_fn_c_try_link "$LINENO"; then : |
10467 | bash_cv_decl_strtoul=yes | |
bb70624e | 10468 | else |
ac50fbac | 10469 | bash_cv_decl_strtoul=no |
bb70624e | 10470 | fi |
ac50fbac CR |
10471 | rm -f core conftest.err conftest.$ac_objext \ |
10472 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 10473 | fi |
ac50fbac CR |
10474 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoul" >&5 |
10475 | $as_echo "$bash_cv_decl_strtoul" >&6; } | |
10476 | bash_tr_func=HAVE_DECL_`echo strtoul | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10477 | if test $bash_cv_decl_strtoul = yes; then | |
10478 | cat >>confdefs.h <<_ACEOF | |
10479 | #define $bash_tr_func 1 | |
10480 | _ACEOF | |
bb70624e | 10481 | |
ac50fbac CR |
10482 | else |
10483 | cat >>confdefs.h <<_ACEOF | |
10484 | #define $bash_tr_func 0 | |
10485 | _ACEOF | |
b80f6443 | 10486 | |
ac50fbac | 10487 | fi |
3185942a | 10488 | |
0628567a | 10489 | |
f73dda09 | 10490 | |
ac50fbac CR |
10491 | |
10492 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoull" >&5 | |
10493 | $as_echo_n "checking for declaration of strtoull... " >&6; } | |
10494 | if ${bash_cv_decl_strtoull+:} false; then : | |
3185942a | 10495 | $as_echo_n "(cached) " >&6 |
f73dda09 | 10496 | else |
ac50fbac | 10497 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 10498 | /* end confdefs.h. */ |
ac50fbac CR |
10499 | |
10500 | #if STDC_HEADERS | |
10501 | # include <stdlib.h> | |
10502 | #endif | |
10503 | #if HAVE_INTTYPES_H | |
10504 | # include <inttypes.h> | |
10505 | #endif | |
10506 | ||
f73dda09 JA |
10507 | int |
10508 | main () | |
cce855bc | 10509 | { |
ac50fbac | 10510 | return !strtoull; |
f73dda09 JA |
10511 | ; |
10512 | return 0; | |
cce855bc | 10513 | } |
f73dda09 | 10514 | _ACEOF |
ac50fbac CR |
10515 | if ac_fn_c_try_link "$LINENO"; then : |
10516 | bash_cv_decl_strtoull=yes | |
10517 | else | |
10518 | bash_cv_decl_strtoull=no | |
10519 | fi | |
10520 | rm -f core conftest.err conftest.$ac_objext \ | |
10521 | conftest$ac_exeext conftest.$ac_ext | |
10522 | fi | |
10523 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoull" >&5 | |
10524 | $as_echo "$bash_cv_decl_strtoull" >&6; } | |
10525 | bash_tr_func=HAVE_DECL_`echo strtoull | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10526 | if test $bash_cv_decl_strtoull = yes; then | |
10527 | cat >>confdefs.h <<_ACEOF | |
10528 | #define $bash_tr_func 1 | |
10529 | _ACEOF | |
10530 | ||
10531 | else | |
10532 | cat >>confdefs.h <<_ACEOF | |
10533 | #define $bash_tr_func 0 | |
0628567a | 10534 | _ACEOF |
ac50fbac CR |
10535 | |
10536 | fi | |
10537 | ||
10538 | ||
10539 | ||
10540 | ||
10541 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoumax" >&5 | |
10542 | $as_echo_n "checking for declaration of strtoumax... " >&6; } | |
10543 | if ${bash_cv_decl_strtoumax+:} false; then : | |
10544 | $as_echo_n "(cached) " >&6 | |
10545 | else | |
10546 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10547 | /* end confdefs.h. */ |
ac50fbac CR |
10548 | |
10549 | #if STDC_HEADERS | |
10550 | # include <stdlib.h> | |
10551 | #endif | |
10552 | #if HAVE_INTTYPES_H | |
10553 | # include <inttypes.h> | |
10554 | #endif | |
10555 | ||
f73dda09 JA |
10556 | int |
10557 | main () | |
10558 | { | |
ac50fbac | 10559 | return !strtoumax; |
f73dda09 JA |
10560 | ; |
10561 | return 0; | |
10562 | } | |
10563 | _ACEOF | |
ac50fbac CR |
10564 | if ac_fn_c_try_link "$LINENO"; then : |
10565 | bash_cv_decl_strtoumax=yes | |
f73dda09 | 10566 | else |
ac50fbac CR |
10567 | bash_cv_decl_strtoumax=no |
10568 | fi | |
10569 | rm -f core conftest.err conftest.$ac_objext \ | |
10570 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 10571 | fi |
ac50fbac CR |
10572 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoumax" >&5 |
10573 | $as_echo "$bash_cv_decl_strtoumax" >&6; } | |
10574 | bash_tr_func=HAVE_DECL_`echo strtoumax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10575 | if test $bash_cv_decl_strtoumax = yes; then | |
10576 | cat >>confdefs.h <<_ACEOF | |
10577 | #define $bash_tr_func 1 | |
10578 | _ACEOF | |
3185942a | 10579 | |
cce855bc | 10580 | else |
ac50fbac CR |
10581 | cat >>confdefs.h <<_ACEOF |
10582 | #define $bash_tr_func 0 | |
10583 | _ACEOF | |
10584 | ||
10585 | fi | |
10586 | ||
0628567a | 10587 | |
ac50fbac CR |
10588 | |
10589 | ||
10590 | ||
10591 | ||
10592 | ||
10593 | for ac_func in $ac_func_list | |
10594 | do : | |
10595 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10596 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
10597 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
10598 | cat >>confdefs.h <<_ACEOF | |
10599 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
0628567a | 10600 | _ACEOF |
ac50fbac CR |
10601 | |
10602 | fi | |
10603 | done | |
10604 | ||
10605 | ||
10606 | ||
10607 | ||
10608 | ||
10609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5 | |
10610 | $as_echo_n "checking for working mktime... " >&6; } | |
10611 | if ${ac_cv_func_working_mktime+:} false; then : | |
10612 | $as_echo_n "(cached) " >&6 | |
10613 | else | |
10614 | if test "$cross_compiling" = yes; then : | |
10615 | ac_cv_func_working_mktime=no | |
10616 | else | |
10617 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10618 | /* end confdefs.h. */ |
ac50fbac CR |
10619 | /* Test program from Paul Eggert and Tony Leneis. */ |
10620 | #ifdef TIME_WITH_SYS_TIME | |
10621 | # include <sys/time.h> | |
10622 | # include <time.h> | |
10623 | #else | |
10624 | # ifdef HAVE_SYS_TIME_H | |
10625 | # include <sys/time.h> | |
10626 | # else | |
10627 | # include <time.h> | |
10628 | # endif | |
10629 | #endif | |
10630 | ||
10631 | #include <limits.h> | |
10632 | #include <stdlib.h> | |
10633 | ||
10634 | #ifdef HAVE_UNISTD_H | |
10635 | # include <unistd.h> | |
10636 | #endif | |
10637 | ||
10638 | #ifndef HAVE_ALARM | |
10639 | # define alarm(X) /* empty */ | |
10640 | #endif | |
10641 | ||
10642 | /* Work around redefinition to rpl_putenv by other config tests. */ | |
10643 | #undef putenv | |
10644 | ||
10645 | static time_t time_t_max; | |
10646 | static time_t time_t_min; | |
10647 | ||
10648 | /* Values we'll use to set the TZ environment variable. */ | |
10649 | static const char *tz_strings[] = { | |
10650 | (const char *) 0, "TZ=GMT0", "TZ=JST-9", | |
10651 | "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00" | |
10652 | }; | |
10653 | #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0])) | |
10654 | ||
10655 | /* Return 0 if mktime fails to convert a date in the spring-forward gap. | |
10656 | Based on a problem report from Andreas Jaeger. */ | |
10657 | static int | |
10658 | spring_forward_gap () | |
10659 | { | |
10660 | /* glibc (up to about 1998-10-07) failed this test. */ | |
10661 | struct tm tm; | |
10662 | ||
10663 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10664 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10665 | on systems that don't support the Olson extension, or don't have the | |
10666 | full zoneinfo tables installed. */ | |
10667 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
10668 | ||
10669 | tm.tm_year = 98; | |
10670 | tm.tm_mon = 3; | |
10671 | tm.tm_mday = 5; | |
10672 | tm.tm_hour = 2; | |
10673 | tm.tm_min = 0; | |
10674 | tm.tm_sec = 0; | |
10675 | tm.tm_isdst = -1; | |
10676 | return mktime (&tm) != (time_t) -1; | |
10677 | } | |
10678 | ||
10679 | static int | |
10680 | mktime_test1 (time_t now) | |
10681 | { | |
10682 | struct tm *lt; | |
10683 | return ! (lt = localtime (&now)) || mktime (lt) == now; | |
10684 | } | |
10685 | ||
10686 | static int | |
10687 | mktime_test (time_t now) | |
10688 | { | |
10689 | return (mktime_test1 (now) | |
10690 | && mktime_test1 ((time_t) (time_t_max - now)) | |
10691 | && mktime_test1 ((time_t) (time_t_min + now))); | |
10692 | } | |
10693 | ||
10694 | static int | |
10695 | irix_6_4_bug () | |
10696 | { | |
10697 | /* Based on code from Ariel Faigon. */ | |
10698 | struct tm tm; | |
10699 | tm.tm_year = 96; | |
10700 | tm.tm_mon = 3; | |
10701 | tm.tm_mday = 0; | |
10702 | tm.tm_hour = 0; | |
10703 | tm.tm_min = 0; | |
10704 | tm.tm_sec = 0; | |
10705 | tm.tm_isdst = -1; | |
10706 | mktime (&tm); | |
10707 | return tm.tm_mon == 2 && tm.tm_mday == 31; | |
10708 | } | |
10709 | ||
10710 | static int | |
10711 | bigtime_test (int j) | |
10712 | { | |
10713 | struct tm tm; | |
10714 | time_t now; | |
10715 | tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j; | |
10716 | now = mktime (&tm); | |
10717 | if (now != (time_t) -1) | |
10718 | { | |
10719 | struct tm *lt = localtime (&now); | |
10720 | if (! (lt | |
10721 | && lt->tm_year == tm.tm_year | |
10722 | && lt->tm_mon == tm.tm_mon | |
10723 | && lt->tm_mday == tm.tm_mday | |
10724 | && lt->tm_hour == tm.tm_hour | |
10725 | && lt->tm_min == tm.tm_min | |
10726 | && lt->tm_sec == tm.tm_sec | |
10727 | && lt->tm_yday == tm.tm_yday | |
10728 | && lt->tm_wday == tm.tm_wday | |
10729 | && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst) | |
10730 | == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst)))) | |
10731 | return 0; | |
10732 | } | |
10733 | return 1; | |
10734 | } | |
10735 | ||
10736 | static int | |
10737 | year_2050_test () | |
b80f6443 | 10738 | { |
ac50fbac CR |
10739 | /* The correct answer for 2050-02-01 00:00:00 in Pacific time, |
10740 | ignoring leap seconds. */ | |
10741 | unsigned long int answer = 2527315200UL; | |
10742 | ||
10743 | struct tm tm; | |
10744 | time_t t; | |
10745 | tm.tm_year = 2050 - 1900; | |
10746 | tm.tm_mon = 2 - 1; | |
10747 | tm.tm_mday = 1; | |
10748 | tm.tm_hour = tm.tm_min = tm.tm_sec = 0; | |
10749 | tm.tm_isdst = -1; | |
10750 | ||
10751 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10752 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10753 | on systems that don't support the Olson extension, or don't have the | |
10754 | full zoneinfo tables installed. */ | |
10755 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
b80f6443 | 10756 | |
ac50fbac CR |
10757 | t = mktime (&tm); |
10758 | ||
10759 | /* Check that the result is either a failure, or close enough | |
10760 | to the correct answer that we can assume the discrepancy is | |
10761 | due to leap seconds. */ | |
10762 | return (t == (time_t) -1 | |
10763 | || (0 < t && answer - 120 <= t && t <= answer + 120)); | |
b80f6443 | 10764 | } |
ac50fbac | 10765 | |
f73dda09 JA |
10766 | int |
10767 | main () | |
10768 | { | |
ac50fbac CR |
10769 | time_t t, delta; |
10770 | int i, j; | |
b80f6443 | 10771 | |
ac50fbac CR |
10772 | /* This test makes some buggy mktime implementations loop. |
10773 | Give up after 60 seconds; a mktime slower than that | |
10774 | isn't worth using anyway. */ | |
10775 | alarm (60); | |
10776 | ||
10777 | for (;;) | |
10778 | { | |
10779 | t = (time_t_max << 1) + 1; | |
10780 | if (t <= time_t_max) | |
10781 | break; | |
10782 | time_t_max = t; | |
10783 | } | |
10784 | time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max; | |
10785 | ||
10786 | delta = time_t_max / 997; /* a suitable prime number */ | |
10787 | for (i = 0; i < N_STRINGS; i++) | |
10788 | { | |
10789 | if (tz_strings[i]) | |
10790 | putenv ((char*) tz_strings[i]); | |
10791 | ||
10792 | for (t = 0; t <= time_t_max - delta; t += delta) | |
10793 | if (! mktime_test (t)) | |
10794 | return 1; | |
10795 | if (! (mktime_test ((time_t) 1) | |
10796 | && mktime_test ((time_t) (60 * 60)) | |
10797 | && mktime_test ((time_t) (60 * 60 * 24)))) | |
10798 | return 1; | |
10799 | ||
10800 | for (j = 1; ; j <<= 1) | |
10801 | if (! bigtime_test (j)) | |
10802 | return 1; | |
10803 | else if (INT_MAX / 2 < j) | |
10804 | break; | |
10805 | if (! bigtime_test (INT_MAX)) | |
10806 | return 1; | |
10807 | } | |
10808 | return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ()); | |
f73dda09 JA |
10809 | } |
10810 | _ACEOF | |
ac50fbac CR |
10811 | if ac_fn_c_try_run "$LINENO"; then : |
10812 | ac_cv_func_working_mktime=yes | |
f73dda09 | 10813 | else |
ac50fbac CR |
10814 | ac_cv_func_working_mktime=no |
10815 | fi | |
10816 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
10817 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 10818 | fi |
3185942a | 10819 | |
b80f6443 | 10820 | fi |
ac50fbac CR |
10821 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5 |
10822 | $as_echo "$ac_cv_func_working_mktime" >&6; } | |
10823 | if test $ac_cv_func_working_mktime = no; then | |
10824 | case " $LIBOBJS " in | |
10825 | *" mktime.$ac_objext "* ) ;; | |
10826 | *) LIBOBJS="$LIBOBJS mktime.$ac_objext" | |
10827 | ;; | |
10828 | esac | |
3185942a | 10829 | |
cce855bc | 10830 | fi |
3185942a | 10831 | |
b80f6443 | 10832 | |
ac50fbac CR |
10833 | |
10834 | for ac_header in argz.h errno.h fcntl.h malloc.h stdio_ext.h | |
10835 | do : | |
10836 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
10837 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
10838 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
10839 | cat >>confdefs.h <<_ACEOF | |
10840 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
f73dda09 | 10841 | _ACEOF |
0628567a | 10842 | |
f73dda09 | 10843 | fi |
3185942a | 10844 | |
f73dda09 | 10845 | done |
ac50fbac CR |
10846 | |
10847 | ||
10848 | ||
10849 | for ac_func in getpagesize | |
10850 | do : | |
10851 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
10852 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
10853 | cat >>confdefs.h <<_ACEOF | |
10854 | #define HAVE_GETPAGESIZE 1 | |
0628567a | 10855 | _ACEOF |
ac50fbac CR |
10856 | |
10857 | fi | |
10858 | done | |
10859 | ||
10860 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 | |
10861 | $as_echo_n "checking for working mmap... " >&6; } | |
10862 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : | |
10863 | $as_echo_n "(cached) " >&6 | |
10864 | else | |
10865 | if test "$cross_compiling" = yes; then : | |
10866 | ac_cv_func_mmap_fixed_mapped=no | |
10867 | else | |
10868 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 10869 | /* end confdefs.h. */ |
f73dda09 | 10870 | $ac_includes_default |
ac50fbac CR |
10871 | /* malloc might have been renamed as rpl_malloc. */ |
10872 | #undef malloc | |
10873 | ||
10874 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
10875 | Here is a matrix of mmap possibilities: | |
10876 | mmap private not fixed | |
10877 | mmap private fixed at somewhere currently unmapped | |
10878 | mmap private fixed at somewhere already mapped | |
10879 | mmap shared not fixed | |
10880 | mmap shared fixed at somewhere currently unmapped | |
10881 | mmap shared fixed at somewhere already mapped | |
10882 | For private mappings, we should verify that changes cannot be read() | |
10883 | back from the file, nor mmap's back from the file at a different | |
10884 | address. (There have been systems where private was not correctly | |
10885 | implemented like the infamous i386 svr4.0, and systems where the | |
10886 | VM page cache was not coherent with the file system buffer cache | |
10887 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
10888 | For shared mappings, we should conversely verify that changes get | |
10889 | propagated back to all the places they're supposed to be. | |
10890 | ||
10891 | Grep wants private fixed already mapped. | |
10892 | The main things grep needs to know about mmap are: | |
10893 | * does it exist and is it safe to write into the mmap'd area | |
10894 | * how to use it (BSD variants) */ | |
10895 | ||
10896 | #include <fcntl.h> | |
10897 | #include <sys/mman.h> | |
10898 | ||
10899 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H | |
10900 | char *malloc (); | |
10901 | #endif | |
10902 | ||
10903 | /* This mess was copied from the GNU getpagesize.h. */ | |
10904 | #ifndef HAVE_GETPAGESIZE | |
10905 | # ifdef _SC_PAGESIZE | |
10906 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
10907 | # else /* no _SC_PAGESIZE */ | |
10908 | # ifdef HAVE_SYS_PARAM_H | |
10909 | # include <sys/param.h> | |
10910 | # ifdef EXEC_PAGESIZE | |
10911 | # define getpagesize() EXEC_PAGESIZE | |
10912 | # else /* no EXEC_PAGESIZE */ | |
10913 | # ifdef NBPG | |
10914 | # define getpagesize() NBPG * CLSIZE | |
10915 | # ifndef CLSIZE | |
10916 | # define CLSIZE 1 | |
10917 | # endif /* no CLSIZE */ | |
10918 | # else /* no NBPG */ | |
10919 | # ifdef NBPC | |
10920 | # define getpagesize() NBPC | |
10921 | # else /* no NBPC */ | |
10922 | # ifdef PAGESIZE | |
10923 | # define getpagesize() PAGESIZE | |
10924 | # endif /* PAGESIZE */ | |
10925 | # endif /* no NBPC */ | |
10926 | # endif /* no NBPG */ | |
10927 | # endif /* no EXEC_PAGESIZE */ | |
10928 | # else /* no HAVE_SYS_PARAM_H */ | |
10929 | # define getpagesize() 8192 /* punt totally */ | |
10930 | # endif /* no HAVE_SYS_PARAM_H */ | |
10931 | # endif /* no _SC_PAGESIZE */ | |
10932 | ||
10933 | #endif /* no HAVE_GETPAGESIZE */ | |
10934 | ||
f73dda09 JA |
10935 | int |
10936 | main () | |
cce855bc | 10937 | { |
ac50fbac CR |
10938 | char *data, *data2, *data3; |
10939 | const char *cdata2; | |
10940 | int i, pagesize; | |
10941 | int fd, fd2; | |
b80f6443 | 10942 | |
ac50fbac CR |
10943 | pagesize = getpagesize (); |
10944 | ||
10945 | /* First, make a file with some known garbage in it. */ | |
10946 | data = (char *) malloc (pagesize); | |
10947 | if (!data) | |
3185942a | 10948 | return 1; |
ac50fbac CR |
10949 | for (i = 0; i < pagesize; ++i) |
10950 | *(data + i) = rand (); | |
10951 | umask (0); | |
10952 | fd = creat ("conftest.mmap", 0600); | |
10953 | if (fd < 0) | |
10954 | return 2; | |
10955 | if (write (fd, data, pagesize) != pagesize) | |
10956 | return 3; | |
10957 | close (fd); | |
b80f6443 | 10958 | |
ac50fbac CR |
10959 | /* Next, check that the tail of a page is zero-filled. File must have |
10960 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
10961 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
10962 | if (fd2 < 0) | |
10963 | return 4; | |
10964 | cdata2 = ""; | |
10965 | if (write (fd2, cdata2, 1) != 1) | |
10966 | return 5; | |
10967 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
10968 | if (data2 == MAP_FAILED) | |
10969 | return 6; | |
10970 | for (i = 0; i < pagesize; ++i) | |
10971 | if (*(data2 + i)) | |
10972 | return 7; | |
10973 | close (fd2); | |
10974 | if (munmap (data2, pagesize)) | |
10975 | return 8; | |
10976 | ||
10977 | /* Next, try to mmap the file at a fixed address which already has | |
10978 | something else allocated at it. If we can, also make sure that | |
10979 | we see the same garbage. */ | |
10980 | fd = open ("conftest.mmap", O_RDWR); | |
10981 | if (fd < 0) | |
10982 | return 9; | |
10983 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, | |
10984 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
10985 | return 10; | |
10986 | for (i = 0; i < pagesize; ++i) | |
10987 | if (*(data + i) != *(data2 + i)) | |
10988 | return 11; | |
10989 | ||
10990 | /* Finally, make sure that changes to the mapped area do not | |
10991 | percolate back to the file as seen by read(). (This is a bug on | |
10992 | some variants of i386 svr4.0.) */ | |
10993 | for (i = 0; i < pagesize; ++i) | |
10994 | *(data2 + i) = *(data2 + i) + 1; | |
10995 | data3 = (char *) malloc (pagesize); | |
10996 | if (!data3) | |
10997 | return 12; | |
10998 | if (read (fd, data3, pagesize) != pagesize) | |
10999 | return 13; | |
11000 | for (i = 0; i < pagesize; ++i) | |
11001 | if (*(data + i) != *(data3 + i)) | |
11002 | return 14; | |
11003 | close (fd); | |
f73dda09 | 11004 | return 0; |
cce855bc | 11005 | } |
f73dda09 | 11006 | _ACEOF |
ac50fbac CR |
11007 | if ac_fn_c_try_run "$LINENO"; then : |
11008 | ac_cv_func_mmap_fixed_mapped=yes | |
cce855bc | 11009 | else |
ac50fbac | 11010 | ac_cv_func_mmap_fixed_mapped=no |
cce855bc | 11011 | fi |
ac50fbac CR |
11012 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
11013 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cce855bc | 11014 | fi |
ac50fbac | 11015 | |
f73dda09 | 11016 | fi |
ac50fbac CR |
11017 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 |
11018 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } | |
11019 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
cce855bc | 11020 | |
ac50fbac | 11021 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
b80f6443 | 11022 | |
ac50fbac CR |
11023 | fi |
11024 | rm -f conftest.mmap conftest.txt | |
3185942a | 11025 | |
ac50fbac CR |
11026 | for ac_func in __argz_count __argz_next __argz_stringify dcgettext mempcpy \ |
11027 | munmap stpcpy strcspn | |
11028 | do : | |
11029 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11030 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11031 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11032 | cat >>confdefs.h <<_ACEOF | |
11033 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
f73dda09 | 11034 | _ACEOF |
0628567a | 11035 | |
ac50fbac CR |
11036 | fi |
11037 | done | |
f73dda09 | 11038 | |
b80f6443 | 11039 | |
ac50fbac CR |
11040 | INTL_DEP= INTL_INC= LIBINTL_H= |
11041 | if test "x$USE_INCLUDED_LIBINTL" = "xyes"; then | |
11042 | INTL_DEP='${INTL_LIBDIR}/libintl.a' | |
11043 | INTL_INC='-I${INTL_LIBSRC} -I${INTL_BUILDDIR}' | |
11044 | LIBINTL_H='${INTL_BUILDDIR}/libintl.h' | |
11045 | fi | |
b80f6443 | 11046 | |
ac50fbac CR |
11047 | |
11048 | ||
11049 | ||
11050 | ||
11051 | ||
11052 | for ac_header in wctype.h | |
11053 | do : | |
11054 | ac_fn_c_check_header_mongrel "$LINENO" "wctype.h" "ac_cv_header_wctype_h" "$ac_includes_default" | |
11055 | if test "x$ac_cv_header_wctype_h" = xyes; then : | |
11056 | cat >>confdefs.h <<_ACEOF | |
11057 | #define HAVE_WCTYPE_H 1 | |
f73dda09 | 11058 | _ACEOF |
0628567a | 11059 | |
f73dda09 | 11060 | fi |
3185942a | 11061 | |
ac50fbac | 11062 | done |
0628567a | 11063 | |
ac50fbac CR |
11064 | for ac_header in wchar.h |
11065 | do : | |
11066 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" | |
11067 | if test "x$ac_cv_header_wchar_h" = xyes; then : | |
11068 | cat >>confdefs.h <<_ACEOF | |
11069 | #define HAVE_WCHAR_H 1 | |
0628567a | 11070 | _ACEOF |
b80f6443 | 11071 | |
ac50fbac | 11072 | fi |
b80f6443 | 11073 | |
ac50fbac CR |
11074 | done |
11075 | ||
11076 | for ac_header in langinfo.h | |
11077 | do : | |
11078 | ac_fn_c_check_header_mongrel "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default" | |
11079 | if test "x$ac_cv_header_langinfo_h" = xyes; then : | |
11080 | cat >>confdefs.h <<_ACEOF | |
11081 | #define HAVE_LANGINFO_H 1 | |
f73dda09 | 11082 | _ACEOF |
0628567a | 11083 | |
f73dda09 | 11084 | fi |
3185942a | 11085 | |
ac50fbac CR |
11086 | done |
11087 | ||
11088 | ||
a0c0a00f CR |
11089 | for ac_header in mbstr.h |
11090 | do : | |
11091 | ac_fn_c_check_header_mongrel "$LINENO" "mbstr.h" "ac_cv_header_mbstr_h" "$ac_includes_default" | |
11092 | if test "x$ac_cv_header_mbstr_h" = xyes; then : | |
11093 | cat >>confdefs.h <<_ACEOF | |
11094 | #define HAVE_MBSTR_H 1 | |
11095 | _ACEOF | |
11096 | ||
11097 | fi | |
11098 | ||
11099 | done | |
11100 | ||
11101 | ||
ac50fbac CR |
11102 | ac_fn_c_check_func "$LINENO" "mbrlen" "ac_cv_func_mbrlen" |
11103 | if test "x$ac_cv_func_mbrlen" = xyes; then : | |
11104 | $as_echo "#define HAVE_MBRLEN 1" >>confdefs.h | |
0628567a | 11105 | |
b80f6443 | 11106 | fi |
3185942a | 11107 | |
ac50fbac CR |
11108 | ac_fn_c_check_func "$LINENO" "mbscasecmp" "ac_cv_func_mbscasecmp" |
11109 | if test "x$ac_cv_func_mbscasecmp" = xyes; then : | |
11110 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
11111 | ||
cce855bc | 11112 | fi |
3185942a | 11113 | |
ac50fbac CR |
11114 | ac_fn_c_check_func "$LINENO" "mbscmp" "ac_cv_func_mbscmp" |
11115 | if test "x$ac_cv_func_mbscmp" = xyes; then : | |
11116 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
b80f6443 | 11117 | |
ac50fbac CR |
11118 | fi |
11119 | ||
11120 | ac_fn_c_check_func "$LINENO" "mbsnrtowcs" "ac_cv_func_mbsnrtowcs" | |
11121 | if test "x$ac_cv_func_mbsnrtowcs" = xyes; then : | |
11122 | $as_echo "#define HAVE_MBSNRTOWCS 1" >>confdefs.h | |
0628567a | 11123 | |
f73dda09 | 11124 | fi |
3185942a | 11125 | |
ac50fbac CR |
11126 | ac_fn_c_check_func "$LINENO" "mbsrtowcs" "ac_cv_func_mbsrtowcs" |
11127 | if test "x$ac_cv_func_mbsrtowcs" = xyes; then : | |
11128 | $as_echo "#define HAVE_MBSRTOWCS 1" >>confdefs.h | |
b80f6443 | 11129 | |
ac50fbac CR |
11130 | fi |
11131 | ||
11132 | ||
11133 | ac_fn_c_check_func "$LINENO" "mbschr" "ac_cv_func_mbschr" | |
11134 | if test "x$ac_cv_func_mbschr" = xyes; then : | |
11135 | $as_echo "#define HAVE_MBSCHR 1" >>confdefs.h | |
b80f6443 | 11136 | |
bb70624e | 11137 | else |
ac50fbac CR |
11138 | case " $LIBOBJS " in |
11139 | *" mbschr.$ac_objext "* ) ;; | |
11140 | *) LIBOBJS="$LIBOBJS mbschr.$ac_objext" | |
11141 | ;; | |
11142 | esac | |
11143 | ||
11144 | fi | |
11145 | ||
11146 | ||
11147 | ||
11148 | ac_fn_c_check_func "$LINENO" "wcrtomb" "ac_cv_func_wcrtomb" | |
11149 | if test "x$ac_cv_func_wcrtomb" = xyes; then : | |
11150 | $as_echo "#define HAVE_WCRTOMB 1" >>confdefs.h | |
0628567a | 11151 | |
bb70624e | 11152 | fi |
ac50fbac CR |
11153 | |
11154 | ac_fn_c_check_func "$LINENO" "wcscoll" "ac_cv_func_wcscoll" | |
11155 | if test "x$ac_cv_func_wcscoll" = xyes; then : | |
11156 | $as_echo "#define HAVE_WCSCOLL 1" >>confdefs.h | |
11157 | ||
bb70624e | 11158 | fi |
ac50fbac CR |
11159 | |
11160 | ac_fn_c_check_func "$LINENO" "wcsdup" "ac_cv_func_wcsdup" | |
11161 | if test "x$ac_cv_func_wcsdup" = xyes; then : | |
11162 | $as_echo "#define HAVE_WCSDUP 1" >>confdefs.h | |
11163 | ||
f73dda09 | 11164 | fi |
3185942a | 11165 | |
ac50fbac CR |
11166 | ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth" |
11167 | if test "x$ac_cv_func_wcwidth" = xyes; then : | |
11168 | $as_echo "#define HAVE_WCWIDTH 1" >>confdefs.h | |
11169 | ||
11170 | fi | |
3185942a | 11171 | |
ac50fbac CR |
11172 | ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype" |
11173 | if test "x$ac_cv_func_wctype" = xyes; then : | |
11174 | $as_echo "#define HAVE_WCTYPE 1" >>confdefs.h | |
3185942a | 11175 | |
ac50fbac | 11176 | fi |
bb70624e | 11177 | |
b80f6443 | 11178 | |
ac50fbac CR |
11179 | ac_fn_c_check_func "$LINENO" "wcswidth" "ac_cv_func_wcswidth" |
11180 | if test "x$ac_cv_func_wcswidth" = xyes; then : | |
11181 | $as_echo "#define HAVE_WCSWIDTH 1" >>confdefs.h | |
b80f6443 | 11182 | |
bb70624e | 11183 | else |
ac50fbac CR |
11184 | case " $LIBOBJS " in |
11185 | *" wcswidth.$ac_objext "* ) ;; | |
11186 | *) LIBOBJS="$LIBOBJS wcswidth.$ac_objext" | |
11187 | ;; | |
3185942a | 11188 | esac |
ac50fbac CR |
11189 | |
11190 | fi | |
11191 | ||
11192 | ||
11193 | ||
11194 | ||
11195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc and mbstate_t are properly declared" >&5 | |
11196 | $as_echo_n "checking whether mbrtowc and mbstate_t are properly declared... " >&6; } | |
11197 | if ${ac_cv_func_mbrtowc+:} false; then : | |
11198 | $as_echo_n "(cached) " >&6 | |
11199 | else | |
11200 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 11201 | /* end confdefs.h. */ |
ac50fbac | 11202 | #include <wchar.h> |
f73dda09 JA |
11203 | int |
11204 | main () | |
11205 | { | |
ac50fbac CR |
11206 | wchar_t wc; |
11207 | char const s[] = ""; | |
11208 | size_t n = 1; | |
11209 | mbstate_t state; | |
11210 | return ! (sizeof state && (mbrtowc) (&wc, s, n, &state)); | |
f73dda09 JA |
11211 | ; |
11212 | return 0; | |
11213 | } | |
11214 | _ACEOF | |
ac50fbac CR |
11215 | if ac_fn_c_try_link "$LINENO"; then : |
11216 | ac_cv_func_mbrtowc=yes | |
3185942a | 11217 | else |
ac50fbac CR |
11218 | ac_cv_func_mbrtowc=no |
11219 | fi | |
11220 | rm -f core conftest.err conftest.$ac_objext \ | |
11221 | conftest$ac_exeext conftest.$ac_ext | |
3185942a | 11222 | fi |
ac50fbac CR |
11223 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mbrtowc" >&5 |
11224 | $as_echo "$ac_cv_func_mbrtowc" >&6; } | |
11225 | if test $ac_cv_func_mbrtowc = yes; then | |
3185942a | 11226 | |
ac50fbac | 11227 | $as_echo "#define HAVE_MBRTOWC 1" >>confdefs.h |
0628567a | 11228 | |
ac50fbac | 11229 | fi |
3185942a | 11230 | |
ac50fbac CR |
11231 | if test $ac_cv_func_mbrtowc = yes; then |
11232 | $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h | |
3185942a | 11233 | |
bb70624e | 11234 | fi |
f73dda09 | 11235 | |
ac50fbac CR |
11236 | for ac_func in iswlower iswupper towlower towupper iswctype |
11237 | do : | |
11238 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11239 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11240 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11241 | cat >>confdefs.h <<_ACEOF | |
11242 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
b80f6443 | 11243 | _ACEOF |
bb70624e JA |
11244 | |
11245 | fi | |
ac50fbac | 11246 | done |
bb70624e | 11247 | |
ac50fbac CR |
11248 | |
11249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 | |
11250 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } | |
11251 | if ${bash_cv_langinfo_codeset+:} false; then : | |
3185942a | 11252 | $as_echo_n "(cached) " >&6 |
bb70624e | 11253 | else |
ac50fbac | 11254 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 11255 | /* end confdefs.h. */ |
ac50fbac | 11256 | #include <langinfo.h> |
f73dda09 JA |
11257 | int |
11258 | main () | |
11259 | { | |
ac50fbac | 11260 | char* cs = nl_langinfo(CODESET); |
f73dda09 JA |
11261 | ; |
11262 | return 0; | |
11263 | } | |
11264 | _ACEOF | |
ac50fbac CR |
11265 | if ac_fn_c_try_link "$LINENO"; then : |
11266 | bash_cv_langinfo_codeset=yes | |
11267 | else | |
11268 | bash_cv_langinfo_codeset=no | |
11269 | fi | |
11270 | rm -f core conftest.err conftest.$ac_objext \ | |
11271 | conftest$ac_exeext conftest.$ac_ext | |
11272 | fi | |
11273 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_langinfo_codeset" >&5 | |
11274 | $as_echo "$bash_cv_langinfo_codeset" >&6; } | |
11275 | if test $bash_cv_langinfo_codeset = yes; then | |
11276 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h | |
11277 | ||
11278 | fi | |
11279 | ||
11280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t in wchar.h" >&5 | |
11281 | $as_echo_n "checking for wchar_t in wchar.h... " >&6; } | |
11282 | if ${bash_cv_type_wchar_t+:} false; then : | |
11283 | $as_echo_n "(cached) " >&6 | |
11284 | else | |
11285 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 11286 | /* end confdefs.h. */ |
ac50fbac CR |
11287 | #include <wchar.h> |
11288 | ||
f73dda09 JA |
11289 | int |
11290 | main () | |
11291 | { | |
ac50fbac CR |
11292 | |
11293 | wchar_t foo; | |
11294 | foo = 0; | |
11295 | ||
f73dda09 JA |
11296 | ; |
11297 | return 0; | |
11298 | } | |
11299 | _ACEOF | |
ac50fbac CR |
11300 | if ac_fn_c_try_compile "$LINENO"; then : |
11301 | bash_cv_type_wchar_t=yes | |
bb70624e | 11302 | else |
ac50fbac | 11303 | bash_cv_type_wchar_t=no |
bb70624e | 11304 | fi |
3185942a | 11305 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
bb70624e | 11306 | fi |
ac50fbac CR |
11307 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wchar_t" >&5 |
11308 | $as_echo "$bash_cv_type_wchar_t" >&6; } | |
11309 | if test $bash_cv_type_wchar_t = yes; then | |
f73dda09 | 11310 | |
ac50fbac | 11311 | $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h |
bb70624e JA |
11312 | |
11313 | fi | |
11314 | ||
ac50fbac CR |
11315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t in wctype.h" >&5 |
11316 | $as_echo_n "checking for wctype_t in wctype.h... " >&6; } | |
11317 | if ${bash_cv_type_wctype_t+:} false; then : | |
3185942a | 11318 | $as_echo_n "(cached) " >&6 |
b72432fd | 11319 | else |
ac50fbac | 11320 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 11321 | /* end confdefs.h. */ |
ac50fbac | 11322 | #include <wctype.h> |
f73dda09 JA |
11323 | int |
11324 | main () | |
11325 | { | |
ac50fbac CR |
11326 | |
11327 | wctype_t foo; | |
11328 | foo = 0; | |
11329 | ||
f73dda09 JA |
11330 | ; |
11331 | return 0; | |
11332 | } | |
11333 | _ACEOF | |
ac50fbac CR |
11334 | if ac_fn_c_try_compile "$LINENO"; then : |
11335 | bash_cv_type_wctype_t=yes | |
cce855bc | 11336 | else |
ac50fbac | 11337 | bash_cv_type_wctype_t=no |
cce855bc | 11338 | fi |
3185942a | 11339 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
cce855bc | 11340 | fi |
ac50fbac CR |
11341 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wctype_t" >&5 |
11342 | $as_echo "$bash_cv_type_wctype_t" >&6; } | |
11343 | if test $bash_cv_type_wctype_t = yes; then | |
f73dda09 | 11344 | |
ac50fbac | 11345 | $as_echo "#define HAVE_WCTYPE_T 1" >>confdefs.h |
cce855bc JA |
11346 | |
11347 | fi | |
11348 | ||
ac50fbac CR |
11349 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t in wctype.h" >&5 |
11350 | $as_echo_n "checking for wint_t in wctype.h... " >&6; } | |
11351 | if ${bash_cv_type_wint_t+:} false; then : | |
3185942a | 11352 | $as_echo_n "(cached) " >&6 |
cce855bc | 11353 | else |
ac50fbac | 11354 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 11355 | /* end confdefs.h. */ |
ac50fbac | 11356 | #include <wctype.h> |
f73dda09 JA |
11357 | int |
11358 | main () | |
11359 | { | |
ac50fbac CR |
11360 | |
11361 | wint_t foo; | |
11362 | foo = 0; | |
11363 | ||
f73dda09 JA |
11364 | ; |
11365 | return 0; | |
11366 | } | |
11367 | _ACEOF | |
ac50fbac CR |
11368 | if ac_fn_c_try_compile "$LINENO"; then : |
11369 | bash_cv_type_wint_t=yes | |
3185942a | 11370 | else |
ac50fbac CR |
11371 | bash_cv_type_wint_t=no |
11372 | fi | |
11373 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11374 | fi | |
11375 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wint_t" >&5 | |
11376 | $as_echo "$bash_cv_type_wint_t" >&6; } | |
11377 | if test $bash_cv_type_wint_t = yes; then | |
11378 | ||
11379 | $as_echo "#define HAVE_WINT_T 1" >>confdefs.h | |
11380 | ||
11381 | fi | |
11382 | ||
11383 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcwidth broken with unicode combining characters" >&5 | |
11384 | $as_echo_n "checking for wcwidth broken with unicode combining characters... " >&6; } | |
11385 | if ${bash_cv_wcwidth_broken+:} false; then : | |
11386 | $as_echo_n "(cached) " >&6 | |
11387 | else | |
11388 | if test "$cross_compiling" = yes; then : | |
11389 | bash_cv_wcwidth_broken=no | |
11390 | else | |
11391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11392 | /* end confdefs.h. */ | |
11393 | ||
11394 | #include <unistd.h> | |
11395 | #include <stdlib.h> | |
11396 | #include <stdio.h> | |
11397 | ||
11398 | #include <locale.h> | |
11399 | #include <wchar.h> | |
3185942a | 11400 | |
ac50fbac CR |
11401 | main(c, v) |
11402 | int c; | |
11403 | char **v; | |
11404 | { | |
11405 | int w; | |
3185942a | 11406 | |
ac50fbac CR |
11407 | setlocale(LC_ALL, "en_US.UTF-8"); |
11408 | w = wcwidth (0x0301); | |
11409 | exit (w == 0); /* exit 0 if wcwidth broken */ | |
11410 | } | |
0628567a | 11411 | |
ac50fbac CR |
11412 | _ACEOF |
11413 | if ac_fn_c_try_run "$LINENO"; then : | |
11414 | bash_cv_wcwidth_broken=yes | |
11415 | else | |
a0c0a00f | 11416 | bash_cv_wcwidth_broken=no |
ac50fbac CR |
11417 | fi |
11418 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11419 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11420 | fi | |
3185942a | 11421 | |
cce855bc | 11422 | fi |
ac50fbac CR |
11423 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcwidth_broken" >&5 |
11424 | $as_echo "$bash_cv_wcwidth_broken" >&6; } | |
11425 | if test "$bash_cv_wcwidth_broken" = yes; then | |
11426 | ||
11427 | $as_echo "#define WCWIDTH_BROKEN 1" >>confdefs.h | |
3185942a | 11428 | |
b72432fd | 11429 | fi |
f73dda09 | 11430 | |
ac50fbac CR |
11431 | if test "$am_cv_func_iconv" = yes; then |
11432 | OLDLIBS="$LIBS" | |
a0c0a00f | 11433 | LIBS="$LIBS $LIBINTL $LIBICONV" |
ac50fbac CR |
11434 | for ac_func in locale_charset |
11435 | do : | |
11436 | ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset" | |
11437 | if test "x$ac_cv_func_locale_charset" = xyes; then : | |
11438 | cat >>confdefs.h <<_ACEOF | |
11439 | #define HAVE_LOCALE_CHARSET 1 | |
b80f6443 | 11440 | _ACEOF |
cce855bc | 11441 | |
b72432fd | 11442 | fi |
ac50fbac | 11443 | done |
b72432fd | 11444 | |
ac50fbac CR |
11445 | LIBS="$OLDLIBS" |
11446 | fi | |
11447 | ||
11448 | ||
11449 | ||
11450 | if test "$opt_static_link" != yes; then | |
11451 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 | |
11452 | $as_echo_n "checking for dlopen in -ldl... " >&6; } | |
11453 | if ${ac_cv_lib_dl_dlopen+:} false; then : | |
3185942a JA |
11454 | $as_echo_n "(cached) " >&6 |
11455 | else | |
ac50fbac CR |
11456 | ac_check_lib_save_LIBS=$LIBS |
11457 | LIBS="-ldl $LIBS" | |
11458 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 11459 | /* end confdefs.h. */ |
ac50fbac CR |
11460 | |
11461 | /* Override any GCC internal prototype to avoid an error. | |
11462 | Use char because int might match the return type of a GCC | |
11463 | builtin and then its argument prototype would still apply. */ | |
11464 | #ifdef __cplusplus | |
11465 | extern "C" | |
11466 | #endif | |
11467 | char dlopen (); | |
f73dda09 JA |
11468 | int |
11469 | main () | |
11470 | { | |
ac50fbac | 11471 | return dlopen (); |
f73dda09 JA |
11472 | ; |
11473 | return 0; | |
11474 | } | |
11475 | _ACEOF | |
ac50fbac CR |
11476 | if ac_fn_c_try_link "$LINENO"; then : |
11477 | ac_cv_lib_dl_dlopen=yes | |
3185942a | 11478 | else |
ac50fbac | 11479 | ac_cv_lib_dl_dlopen=no |
3185942a | 11480 | fi |
ac50fbac CR |
11481 | rm -f core conftest.err conftest.$ac_objext \ |
11482 | conftest$ac_exeext conftest.$ac_ext | |
11483 | LIBS=$ac_check_lib_save_LIBS | |
11484 | fi | |
11485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 | |
11486 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } | |
11487 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : | |
11488 | cat >>confdefs.h <<_ACEOF | |
11489 | #define HAVE_LIBDL 1 | |
11490 | _ACEOF | |
3185942a | 11491 | |
ac50fbac CR |
11492 | LIBS="-ldl $LIBS" |
11493 | ||
11494 | fi | |
0628567a | 11495 | |
ac50fbac CR |
11496 | for ac_func in dlopen dlclose dlsym |
11497 | do : | |
11498 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11499 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11500 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11501 | cat >>confdefs.h <<_ACEOF | |
11502 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
11503 | _ACEOF | |
3185942a | 11504 | |
cce855bc | 11505 | fi |
ac50fbac | 11506 | done |
3185942a | 11507 | |
cce855bc | 11508 | fi |
ac50fbac CR |
11509 | |
11510 | ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h> | |
11511 | /* NetBSD declares sys_siglist in unistd.h. */ | |
11512 | #ifdef HAVE_UNISTD_H | |
11513 | # include <unistd.h> | |
11514 | #endif | |
11515 | ||
11516 | " | |
11517 | if test "x$ac_cv_have_decl_sys_siglist" = xyes; then : | |
11518 | ac_have_decl=1 | |
f73dda09 | 11519 | else |
ac50fbac CR |
11520 | ac_have_decl=0 |
11521 | fi | |
f73dda09 | 11522 | |
b80f6443 | 11523 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 11524 | #define HAVE_DECL_SYS_SIGLIST $ac_have_decl |
b80f6443 | 11525 | _ACEOF |
cce855bc | 11526 | |
cce855bc | 11527 | |
3185942a | 11528 | |
ac50fbac | 11529 | if test "$ac_cv_func_inet_aton" != 'yes'; then |
3185942a | 11530 | |
ac50fbac CR |
11531 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
11532 | $as_echo_n "checking for inet_aton... " >&6; } | |
11533 | if ${bash_cv_func_inet_aton+:} false; then : | |
3185942a | 11534 | $as_echo_n "(cached) " >&6 |
cce855bc | 11535 | else |
ac50fbac | 11536 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 11537 | /* end confdefs.h. */ |
ac50fbac CR |
11538 | |
11539 | #include <sys/types.h> | |
11540 | #include <netinet/in.h> | |
11541 | #include <arpa/inet.h> | |
11542 | struct in_addr ap; | |
f73dda09 JA |
11543 | int |
11544 | main () | |
11545 | { | |
ac50fbac | 11546 | inet_aton("127.0.0.1", &ap); |
f73dda09 JA |
11547 | ; |
11548 | return 0; | |
11549 | } | |
11550 | _ACEOF | |
ac50fbac CR |
11551 | if ac_fn_c_try_link "$LINENO"; then : |
11552 | bash_cv_func_inet_aton=yes | |
11553 | else | |
11554 | bash_cv_func_inet_aton=no | |
11555 | fi | |
11556 | rm -f core conftest.err conftest.$ac_objext \ | |
11557 | conftest$ac_exeext conftest.$ac_ext | |
11558 | fi | |
11559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_inet_aton" >&5 | |
11560 | $as_echo "$bash_cv_func_inet_aton" >&6; } | |
11561 | if test $bash_cv_func_inet_aton = yes; then | |
11562 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h | |
11563 | ||
11564 | else | |
11565 | case " $LIBOBJS " in | |
11566 | *" inet_aton.$ac_objext "* ) ;; | |
11567 | *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext" | |
11568 | ;; | |
3185942a | 11569 | esac |
ac50fbac CR |
11570 | |
11571 | fi | |
11572 | ||
11573 | fi | |
11574 | ||
11575 | case "$host_os" in | |
11576 | irix4*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpwent in -lsun" >&5 | |
11577 | $as_echo_n "checking for getpwent in -lsun... " >&6; } | |
11578 | if ${ac_cv_lib_sun_getpwent+:} false; then : | |
11579 | $as_echo_n "(cached) " >&6 | |
11580 | else | |
11581 | ac_check_lib_save_LIBS=$LIBS | |
11582 | LIBS="-lsun $LIBS" | |
11583 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 11584 | /* end confdefs.h. */ |
ac50fbac CR |
11585 | |
11586 | /* Override any GCC internal prototype to avoid an error. | |
11587 | Use char because int might match the return type of a GCC | |
11588 | builtin and then its argument prototype would still apply. */ | |
11589 | #ifdef __cplusplus | |
11590 | extern "C" | |
11591 | #endif | |
11592 | char getpwent (); | |
f73dda09 JA |
11593 | int |
11594 | main () | |
11595 | { | |
ac50fbac | 11596 | return getpwent (); |
f73dda09 JA |
11597 | ; |
11598 | return 0; | |
11599 | } | |
11600 | _ACEOF | |
ac50fbac CR |
11601 | if ac_fn_c_try_link "$LINENO"; then : |
11602 | ac_cv_lib_sun_getpwent=yes | |
3185942a | 11603 | else |
ac50fbac | 11604 | ac_cv_lib_sun_getpwent=no |
3185942a | 11605 | fi |
ac50fbac CR |
11606 | rm -f core conftest.err conftest.$ac_objext \ |
11607 | conftest$ac_exeext conftest.$ac_ext | |
11608 | LIBS=$ac_check_lib_save_LIBS | |
b72432fd | 11609 | fi |
ac50fbac CR |
11610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sun_getpwent" >&5 |
11611 | $as_echo "$ac_cv_lib_sun_getpwent" >&6; } | |
11612 | if test "x$ac_cv_lib_sun_getpwent" = xyes; then : | |
11613 | cat >>confdefs.h <<_ACEOF | |
11614 | #define HAVE_LIBSUN 1 | |
11615 | _ACEOF | |
11616 | ||
11617 | LIBS="-lsun $LIBS" | |
3185942a | 11618 | |
cce855bc | 11619 | fi |
ac50fbac CR |
11620 | ;; |
11621 | esac | |
f73dda09 | 11622 | |
ac50fbac | 11623 | if test "$ac_cv_func_getpeername" = no; then |
cce855bc | 11624 | |
ac50fbac CR |
11625 | if test "X$bash_cv_have_socklib" = "X"; then |
11626 | _bash_needmsg= | |
11627 | else | |
11628 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket library" >&5 | |
11629 | $as_echo_n "checking for socket library... " >&6; } | |
11630 | _bash_needmsg=yes | |
cce855bc | 11631 | fi |
ac50fbac | 11632 | if ${bash_cv_have_socklib+:} false; then : |
3185942a | 11633 | $as_echo_n "(cached) " >&6 |
cce855bc | 11634 | else |
ac50fbac CR |
11635 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpeername in -lsocket" >&5 |
11636 | $as_echo_n "checking for getpeername in -lsocket... " >&6; } | |
11637 | if ${ac_cv_lib_socket_getpeername+:} false; then : | |
11638 | $as_echo_n "(cached) " >&6 | |
11639 | else | |
11640 | ac_check_lib_save_LIBS=$LIBS | |
11641 | LIBS="-lsocket -lnsl $LIBS" | |
11642 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 11643 | /* end confdefs.h. */ |
ac50fbac CR |
11644 | |
11645 | /* Override any GCC internal prototype to avoid an error. | |
11646 | Use char because int might match the return type of a GCC | |
11647 | builtin and then its argument prototype would still apply. */ | |
11648 | #ifdef __cplusplus | |
11649 | extern "C" | |
11650 | #endif | |
11651 | char getpeername (); | |
f73dda09 JA |
11652 | int |
11653 | main () | |
11654 | { | |
ac50fbac | 11655 | return getpeername (); |
f73dda09 JA |
11656 | ; |
11657 | return 0; | |
11658 | } | |
11659 | _ACEOF | |
ac50fbac CR |
11660 | if ac_fn_c_try_link "$LINENO"; then : |
11661 | ac_cv_lib_socket_getpeername=yes | |
11662 | else | |
11663 | ac_cv_lib_socket_getpeername=no | |
11664 | fi | |
11665 | rm -f core conftest.err conftest.$ac_objext \ | |
11666 | conftest$ac_exeext conftest.$ac_ext | |
11667 | LIBS=$ac_check_lib_save_LIBS | |
11668 | fi | |
11669 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getpeername" >&5 | |
11670 | $as_echo "$ac_cv_lib_socket_getpeername" >&6; } | |
11671 | if test "x$ac_cv_lib_socket_getpeername" = xyes; then : | |
11672 | bash_cv_have_socklib=yes | |
11673 | else | |
11674 | bash_cv_have_socklib=no | |
11675 | fi | |
11676 | ||
11677 | fi | |
11678 | ||
11679 | if test "X$_bash_needmsg" = Xyes; then | |
11680 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_socklib" >&5 | |
11681 | $as_echo "$bash_cv_have_socklib" >&6; } | |
11682 | _bash_needmsg= | |
11683 | fi | |
11684 | if test $bash_cv_have_socklib = yes; then | |
11685 | # check for libnsl, add it to LIBS if present | |
11686 | if test "X$bash_cv_have_libnsl" = "X"; then | |
11687 | _bash_needmsg= | |
11688 | else | |
11689 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnsl" >&5 | |
11690 | $as_echo_n "checking for libnsl... " >&6; } | |
11691 | _bash_needmsg=yes | |
11692 | fi | |
11693 | if ${bash_cv_have_libnsl+:} false; then : | |
11694 | $as_echo_n "(cached) " >&6 | |
11695 | else | |
11696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 | |
11697 | $as_echo_n "checking for t_open in -lnsl... " >&6; } | |
11698 | if ${ac_cv_lib_nsl_t_open+:} false; then : | |
11699 | $as_echo_n "(cached) " >&6 | |
11700 | else | |
11701 | ac_check_lib_save_LIBS=$LIBS | |
11702 | LIBS="-lnsl $LIBS" | |
11703 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 11704 | /* end confdefs.h. */ |
ac50fbac CR |
11705 | |
11706 | /* Override any GCC internal prototype to avoid an error. | |
11707 | Use char because int might match the return type of a GCC | |
11708 | builtin and then its argument prototype would still apply. */ | |
11709 | #ifdef __cplusplus | |
11710 | extern "C" | |
11711 | #endif | |
11712 | char t_open (); | |
3185942a JA |
11713 | int |
11714 | main () | |
11715 | { | |
ac50fbac | 11716 | return t_open (); |
3185942a JA |
11717 | ; |
11718 | return 0; | |
11719 | } | |
11720 | _ACEOF | |
ac50fbac CR |
11721 | if ac_fn_c_try_link "$LINENO"; then : |
11722 | ac_cv_lib_nsl_t_open=yes | |
3185942a | 11723 | else |
ac50fbac | 11724 | ac_cv_lib_nsl_t_open=no |
3185942a | 11725 | fi |
ac50fbac CR |
11726 | rm -f core conftest.err conftest.$ac_objext \ |
11727 | conftest$ac_exeext conftest.$ac_ext | |
11728 | LIBS=$ac_check_lib_save_LIBS | |
11729 | fi | |
11730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 | |
11731 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } | |
11732 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : | |
11733 | bash_cv_have_libnsl=yes | |
3185942a | 11734 | else |
ac50fbac | 11735 | bash_cv_have_libnsl=no |
3185942a JA |
11736 | fi |
11737 | ||
3185942a | 11738 | fi |
3185942a | 11739 | |
ac50fbac CR |
11740 | if test "X$_bash_needmsg" = Xyes; then |
11741 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_libnsl" >&5 | |
11742 | $as_echo "$bash_cv_have_libnsl" >&6; } | |
11743 | _bash_needmsg= | |
11744 | fi | |
11745 | if test $bash_cv_have_libnsl = yes; then | |
11746 | LIBS="-lsocket -lnsl $LIBS" | |
11747 | else | |
11748 | LIBS="-lsocket $LIBS" | |
11749 | fi | |
11750 | $as_echo "#define HAVE_LIBSOCKET 1" >>confdefs.h | |
11751 | ||
11752 | $as_echo "#define HAVE_GETPEERNAME 1" >>confdefs.h | |
3185942a JA |
11753 | |
11754 | fi | |
11755 | ||
ac50fbac CR |
11756 | fi |
11757 | if test "$ac_cv_func_gethostbyname" = no; then | |
11758 | if test "X$bash_cv_have_gethostbyname" = "X"; then | |
11759 | _bash_needmsg=yes | |
3185942a | 11760 | else |
ac50fbac CR |
11761 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 |
11762 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11763 | _bash_needmsg= | |
11764 | fi | |
11765 | if ${bash_cv_have_gethostbyname+:} false; then : | |
3185942a JA |
11766 | $as_echo_n "(cached) " >&6 |
11767 | else | |
ac50fbac | 11768 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a | 11769 | /* end confdefs.h. */ |
ac50fbac | 11770 | #include <netdb.h> |
3185942a JA |
11771 | int |
11772 | main () | |
11773 | { | |
ac50fbac CR |
11774 | struct hostent *hp; |
11775 | hp = gethostbyname("localhost"); | |
11776 | ||
3185942a JA |
11777 | ; |
11778 | return 0; | |
11779 | } | |
11780 | _ACEOF | |
ac50fbac CR |
11781 | if ac_fn_c_try_link "$LINENO"; then : |
11782 | bash_cv_have_gethostbyname=yes | |
3185942a | 11783 | else |
ac50fbac | 11784 | bash_cv_have_gethostbyname=no |
3185942a | 11785 | fi |
ac50fbac CR |
11786 | rm -f core conftest.err conftest.$ac_objext \ |
11787 | conftest$ac_exeext conftest.$ac_ext | |
3185942a | 11788 | |
ac50fbac | 11789 | fi |
3185942a | 11790 | |
ac50fbac CR |
11791 | if test "X$_bash_needmsg" = Xyes; then |
11792 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 | |
11793 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11794 | fi | |
11795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_gethostbyname" >&5 | |
11796 | $as_echo "$bash_cv_have_gethostbyname" >&6; } | |
11797 | if test "$bash_cv_have_gethostbyname" = yes; then | |
11798 | $as_echo "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h | |
3185942a JA |
11799 | |
11800 | fi | |
11801 | ||
3185942a | 11802 | fi |
ac50fbac | 11803 | |
ac50fbac CR |
11804 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5 |
11805 | $as_echo_n "checking type of array argument to getgroups... " >&6; } | |
11806 | if ${ac_cv_type_getgroups+:} false; then : | |
3185942a JA |
11807 | $as_echo_n "(cached) " >&6 |
11808 | else | |
ac50fbac CR |
11809 | if test "$cross_compiling" = yes; then : |
11810 | ac_cv_type_getgroups=cross | |
11811 | else | |
11812 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 11813 | /* end confdefs.h. */ |
ac50fbac | 11814 | /* Thanks to Mike Rendell for this test. */ |
3185942a | 11815 | $ac_includes_default |
ac50fbac CR |
11816 | #define NGID 256 |
11817 | #undef MAX | |
11818 | #define MAX(x, y) ((x) > (y) ? (x) : (y)) | |
11819 | ||
3185942a JA |
11820 | int |
11821 | main () | |
11822 | { | |
ac50fbac CR |
11823 | gid_t gidset[NGID]; |
11824 | int i, n; | |
11825 | union { gid_t gval; long int lval; } val; | |
11826 | ||
11827 | val.lval = -1; | |
11828 | for (i = 0; i < NGID; i++) | |
11829 | gidset[i] = val.gval; | |
11830 | n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1, | |
11831 | gidset); | |
11832 | /* Exit non-zero if getgroups seems to require an array of ints. This | |
11833 | happens when gid_t is short int but getgroups modifies an array | |
11834 | of ints. */ | |
11835 | return n > 0 && gidset[n] != val.gval; | |
3185942a JA |
11836 | } |
11837 | _ACEOF | |
ac50fbac CR |
11838 | if ac_fn_c_try_run "$LINENO"; then : |
11839 | ac_cv_type_getgroups=gid_t | |
11840 | else | |
11841 | ac_cv_type_getgroups=int | |
11842 | fi | |
11843 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11844 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11845 | fi | |
11846 | ||
11847 | if test $ac_cv_type_getgroups = cross; then | |
11848 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 11849 | /* end confdefs.h. */ |
ac50fbac CR |
11850 | #include <unistd.h> |
11851 | ||
3185942a | 11852 | _ACEOF |
ac50fbac CR |
11853 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11854 | $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then : | |
11855 | ac_cv_type_getgroups=gid_t | |
3185942a | 11856 | else |
ac50fbac CR |
11857 | ac_cv_type_getgroups=int |
11858 | fi | |
11859 | rm -f conftest* | |
3185942a | 11860 | |
3185942a | 11861 | fi |
ac50fbac CR |
11862 | fi |
11863 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5 | |
11864 | $as_echo "$ac_cv_type_getgroups" >&6; } | |
11865 | ||
11866 | cat >>confdefs.h <<_ACEOF | |
11867 | #define GETGROUPS_T $ac_cv_type_getgroups | |
11868 | _ACEOF | |
11869 | ||
11870 | ||
11871 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" | |
11872 | if test "x$ac_cv_type_off_t" = xyes; then : | |
3185942a | 11873 | |
3185942a | 11874 | else |
3185942a | 11875 | |
ac50fbac CR |
11876 | cat >>confdefs.h <<_ACEOF |
11877 | #define off_t long int | |
11878 | _ACEOF | |
3185942a JA |
11879 | |
11880 | fi | |
11881 | ||
ac50fbac CR |
11882 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
11883 | if test "x$ac_cv_type_mode_t" = xyes; then : | |
11884 | ||
3185942a JA |
11885 | else |
11886 | ||
11887 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 11888 | #define mode_t int |
3185942a JA |
11889 | _ACEOF |
11890 | ||
11891 | fi | |
11892 | ||
ac50fbac CR |
11893 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
11894 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
11895 | if ${ac_cv_type_uid_t+:} false; then : | |
3185942a JA |
11896 | $as_echo_n "(cached) " >&6 |
11897 | else | |
ac50fbac | 11898 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a | 11899 | /* end confdefs.h. */ |
ac50fbac CR |
11900 | #include <sys/types.h> |
11901 | ||
3185942a | 11902 | _ACEOF |
ac50fbac CR |
11903 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11904 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
11905 | ac_cv_type_uid_t=yes | |
3185942a | 11906 | else |
ac50fbac | 11907 | ac_cv_type_uid_t=no |
3185942a | 11908 | fi |
ac50fbac | 11909 | rm -f conftest* |
3185942a | 11910 | |
ac50fbac CR |
11911 | fi |
11912 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 | |
11913 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
11914 | if test $ac_cv_type_uid_t = no; then | |
3185942a | 11915 | |
ac50fbac | 11916 | $as_echo "#define uid_t int" >>confdefs.h |
3185942a | 11917 | |
3185942a | 11918 | |
ac50fbac CR |
11919 | $as_echo "#define gid_t int" >>confdefs.h |
11920 | ||
3185942a | 11921 | fi |
ac50fbac CR |
11922 | |
11923 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" | |
11924 | if test "x$ac_cv_type_pid_t" = xyes; then : | |
11925 | ||
3185942a JA |
11926 | else |
11927 | ||
11928 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 11929 | #define pid_t int |
3185942a JA |
11930 | _ACEOF |
11931 | ||
11932 | fi | |
11933 | ||
ac50fbac CR |
11934 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
11935 | if test "x$ac_cv_type_size_t" = xyes; then : | |
11936 | ||
3185942a | 11937 | else |
ac50fbac CR |
11938 | |
11939 | cat >>confdefs.h <<_ACEOF | |
11940 | #define size_t unsigned int | |
3185942a | 11941 | _ACEOF |
3185942a | 11942 | |
3185942a JA |
11943 | fi |
11944 | ||
a0c0a00f CR |
11945 | |
11946 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" | |
11947 | if test "x$ac_cv_type_uintptr_t" = xyes; then : | |
11948 | ||
11949 | $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h | |
11950 | ||
11951 | else | |
11952 | for ac_type in 'unsigned int' 'unsigned long int' \ | |
11953 | 'unsigned long long int'; do | |
11954 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
11955 | /* end confdefs.h. */ | |
11956 | $ac_includes_default | |
11957 | int | |
11958 | main () | |
11959 | { | |
11960 | static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; | |
11961 | test_array [0] = 0; | |
11962 | return test_array [0]; | |
11963 | ||
11964 | ; | |
11965 | return 0; | |
11966 | } | |
11967 | _ACEOF | |
11968 | if ac_fn_c_try_compile "$LINENO"; then : | |
11969 | ||
11970 | cat >>confdefs.h <<_ACEOF | |
11971 | #define uintptr_t $ac_type | |
11972 | _ACEOF | |
11973 | ||
11974 | ac_type= | |
11975 | fi | |
11976 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11977 | test -z "$ac_type" && break | |
11978 | done | |
11979 | fi | |
11980 | ||
11981 | ||
11982 | ||
ac50fbac CR |
11983 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
11984 | if test "x$ac_cv_type_ssize_t" = xyes; then : | |
11985 | ||
3185942a | 11986 | else |
3185942a | 11987 | |
ac50fbac CR |
11988 | cat >>confdefs.h <<_ACEOF |
11989 | #define ssize_t int | |
11990 | _ACEOF | |
3185942a JA |
11991 | |
11992 | fi | |
11993 | ||
ac50fbac CR |
11994 | ac_fn_c_check_type "$LINENO" "time_t" "ac_cv_type_time_t" "$ac_includes_default" |
11995 | if test "x$ac_cv_type_time_t" = xyes; then : | |
11996 | ||
3185942a JA |
11997 | else |
11998 | ||
11999 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 12000 | #define time_t long |
3185942a JA |
12001 | _ACEOF |
12002 | ||
12003 | fi | |
12004 | ||
3185942a JA |
12005 | |
12006 | ||
ac50fbac CR |
12007 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long" >&5 |
12008 | $as_echo_n "checking for long long... " >&6; } | |
12009 | if ${bash_cv_type_long_long+:} false; then : | |
3185942a JA |
12010 | $as_echo_n "(cached) " >&6 |
12011 | else | |
ac50fbac | 12012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a | 12013 | /* end confdefs.h. */ |
ac50fbac CR |
12014 | |
12015 | long long ll = 1; int i = 63; | |
3185942a JA |
12016 | int |
12017 | main () | |
12018 | { | |
ac50fbac CR |
12019 | |
12020 | long long llm = (long long) -1; | |
12021 | return ll << i | ll >> i | llm / ll | llm % ll; | |
12022 | ||
3185942a JA |
12023 | ; |
12024 | return 0; | |
12025 | } | |
12026 | _ACEOF | |
ac50fbac CR |
12027 | if ac_fn_c_try_link "$LINENO"; then : |
12028 | bash_cv_type_long_long='long long' | |
12029 | else | |
12030 | bash_cv_type_long_long='long' | |
12031 | fi | |
12032 | rm -f core conftest.err conftest.$ac_objext \ | |
12033 | conftest$ac_exeext conftest.$ac_ext | |
12034 | fi | |
12035 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_long_long" >&5 | |
12036 | $as_echo "$bash_cv_type_long_long" >&6; } | |
12037 | if test "$bash_cv_type_long_long" = 'long long'; then | |
12038 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h | |
12039 | ||
12040 | fi | |
12041 | ||
12042 | ||
12043 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 | |
12044 | $as_echo_n "checking for unsigned long long... " >&6; } | |
12045 | if ${bash_cv_type_unsigned_long_long+:} false; then : | |
12046 | $as_echo_n "(cached) " >&6 | |
12047 | else | |
12048 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 12049 | /* end confdefs.h. */ |
ac50fbac CR |
12050 | |
12051 | unsigned long long ull = 1; int i = 63; | |
3185942a JA |
12052 | int |
12053 | main () | |
12054 | { | |
ac50fbac CR |
12055 | |
12056 | unsigned long long ullmax = (unsigned long long) -1; | |
12057 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
12058 | ||
3185942a JA |
12059 | ; |
12060 | return 0; | |
12061 | } | |
12062 | _ACEOF | |
ac50fbac CR |
12063 | if ac_fn_c_try_link "$LINENO"; then : |
12064 | bash_cv_type_unsigned_long_long='unsigned long long' | |
3185942a | 12065 | else |
ac50fbac | 12066 | bash_cv_type_unsigned_long_long='unsigned long' |
3185942a | 12067 | fi |
ac50fbac CR |
12068 | rm -f core conftest.err conftest.$ac_objext \ |
12069 | conftest$ac_exeext conftest.$ac_ext | |
3185942a | 12070 | fi |
ac50fbac CR |
12071 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_unsigned_long_long" >&5 |
12072 | $as_echo "$bash_cv_type_unsigned_long_long" >&6; } | |
12073 | if test "$bash_cv_type_unsigned_long_long" = 'unsigned long long'; then | |
12074 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h | |
3185942a | 12075 | |
3185942a | 12076 | fi |
3185942a | 12077 | |
cce855bc | 12078 | |
ac50fbac CR |
12079 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 |
12080 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
12081 | if ${ac_cv_type_signal+:} false; then : | |
3185942a | 12082 | $as_echo_n "(cached) " >&6 |
cce855bc | 12083 | else |
ac50fbac | 12084 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12085 | /* end confdefs.h. */ |
ac50fbac CR |
12086 | #include <sys/types.h> |
12087 | #include <signal.h> | |
12088 | ||
f73dda09 JA |
12089 | int |
12090 | main () | |
12091 | { | |
ac50fbac | 12092 | return *(signal (0, 0)) (0) == 1; |
3185942a | 12093 | ; |
f73dda09 | 12094 | return 0; |
3185942a JA |
12095 | } |
12096 | _ACEOF | |
ac50fbac CR |
12097 | if ac_fn_c_try_compile "$LINENO"; then : |
12098 | ac_cv_type_signal=int | |
12099 | else | |
12100 | ac_cv_type_signal=void | |
12101 | fi | |
12102 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
12103 | fi | |
12104 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
12105 | $as_echo "$ac_cv_type_signal" >&6; } | |
12106 | ||
12107 | cat >>confdefs.h <<_ACEOF | |
12108 | #define RETSIGTYPE $ac_cv_type_signal | |
3185942a | 12109 | _ACEOF |
ac50fbac CR |
12110 | |
12111 | ||
12112 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t in signal.h" >&5 | |
12113 | $as_echo_n "checking for sig_atomic_t in signal.h... " >&6; } | |
12114 | if ${ac_cv_have_sig_atomic_t+:} false; then : | |
12115 | $as_echo_n "(cached) " >&6 | |
12116 | else | |
12117 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3185942a | 12118 | /* end confdefs.h. */ |
ac50fbac CR |
12119 | |
12120 | #include <signal.h> | |
12121 | ||
3185942a JA |
12122 | int |
12123 | main () | |
12124 | { | |
ac50fbac | 12125 | sig_atomic_t x; |
f73dda09 JA |
12126 | ; |
12127 | return 0; | |
12128 | } | |
12129 | _ACEOF | |
ac50fbac CR |
12130 | if ac_fn_c_try_link "$LINENO"; then : |
12131 | ac_cv_have_sig_atomic_t=yes | |
3185942a | 12132 | else |
ac50fbac CR |
12133 | ac_cv_have_sig_atomic_t=no |
12134 | fi | |
12135 | rm -f core conftest.err conftest.$ac_objext \ | |
12136 | conftest$ac_exeext conftest.$ac_ext | |
3185942a | 12137 | fi |
ac50fbac CR |
12138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sig_atomic_t" >&5 |
12139 | $as_echo "$ac_cv_have_sig_atomic_t" >&6; } | |
12140 | if test "$ac_cv_have_sig_atomic_t" = "no" | |
12141 | then | |
12142 | ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "$ac_includes_default" | |
12143 | if test "x$ac_cv_type_sig_atomic_t" = xyes; then : | |
3185942a | 12144 | |
3185942a | 12145 | else |
3185942a | 12146 | |
ac50fbac CR |
12147 | cat >>confdefs.h <<_ACEOF |
12148 | #define sig_atomic_t int | |
12149 | _ACEOF | |
3185942a JA |
12150 | |
12151 | fi | |
12152 | ||
3185942a | 12153 | fi |
ac50fbac CR |
12154 | |
12155 | ||
12156 | # The cast to long int works around a bug in the HP C Compiler | |
12157 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12158 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12159 | # This bug is HP SR number 8606223364. | |
12160 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char" >&5 | |
12161 | $as_echo_n "checking size of char... " >&6; } | |
12162 | if ${ac_cv_sizeof_char+:} false; then : | |
12163 | $as_echo_n "(cached) " >&6 | |
3185942a | 12164 | else |
ac50fbac | 12165 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char))" "ac_cv_sizeof_char" "$ac_includes_default"; then : |
3185942a | 12166 | |
ac50fbac CR |
12167 | else |
12168 | if test "$ac_cv_type_char" = yes; then | |
12169 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12170 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12171 | as_fn_error 77 "cannot compute sizeof (char) | |
12172 | See \`config.log' for more details" "$LINENO" 5; } | |
12173 | else | |
12174 | ac_cv_sizeof_char=0 | |
12175 | fi | |
12176 | fi | |
3185942a JA |
12177 | |
12178 | fi | |
ac50fbac CR |
12179 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char" >&5 |
12180 | $as_echo "$ac_cv_sizeof_char" >&6; } | |
3185942a | 12181 | |
ac50fbac CR |
12182 | |
12183 | ||
12184 | cat >>confdefs.h <<_ACEOF | |
12185 | #define SIZEOF_CHAR $ac_cv_sizeof_char | |
3185942a | 12186 | _ACEOF |
ac50fbac CR |
12187 | |
12188 | ||
12189 | # The cast to long int works around a bug in the HP C Compiler | |
12190 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12191 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12192 | # This bug is HP SR number 8606223364. | |
12193 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 | |
12194 | $as_echo_n "checking size of short... " >&6; } | |
12195 | if ${ac_cv_sizeof_short+:} false; then : | |
12196 | $as_echo_n "(cached) " >&6 | |
3185942a | 12197 | else |
ac50fbac CR |
12198 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : |
12199 | ||
12200 | else | |
12201 | if test "$ac_cv_type_short" = yes; then | |
12202 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12203 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12204 | as_fn_error 77 "cannot compute sizeof (short) | |
12205 | See \`config.log' for more details" "$LINENO" 5; } | |
12206 | else | |
12207 | ac_cv_sizeof_short=0 | |
12208 | fi | |
12209 | fi | |
3185942a | 12210 | |
3185942a | 12211 | fi |
ac50fbac CR |
12212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
12213 | $as_echo "$ac_cv_sizeof_short" >&6; } | |
3185942a | 12214 | |
0628567a | 12215 | |
3185942a | 12216 | |
ac50fbac CR |
12217 | cat >>confdefs.h <<_ACEOF |
12218 | #define SIZEOF_SHORT $ac_cv_sizeof_short | |
12219 | _ACEOF | |
12220 | ||
12221 | ||
12222 | # The cast to long int works around a bug in the HP C Compiler | |
12223 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12224 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12225 | # This bug is HP SR number 8606223364. | |
12226 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 | |
12227 | $as_echo_n "checking size of int... " >&6; } | |
12228 | if ${ac_cv_sizeof_int+:} false; then : | |
12229 | $as_echo_n "(cached) " >&6 | |
12230 | else | |
12231 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : | |
12232 | ||
12233 | else | |
12234 | if test "$ac_cv_type_int" = yes; then | |
12235 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12236 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12237 | as_fn_error 77 "cannot compute sizeof (int) | |
12238 | See \`config.log' for more details" "$LINENO" 5; } | |
12239 | else | |
12240 | ac_cv_sizeof_int=0 | |
12241 | fi | |
b72432fd | 12242 | fi |
3185942a | 12243 | |
b72432fd | 12244 | fi |
ac50fbac CR |
12245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
12246 | $as_echo "$ac_cv_sizeof_int" >&6; } | |
12247 | ||
12248 | ||
f73dda09 | 12249 | |
b80f6443 | 12250 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12251 | #define SIZEOF_INT $ac_cv_sizeof_int |
b80f6443 | 12252 | _ACEOF |
b72432fd | 12253 | |
ac50fbac CR |
12254 | |
12255 | # The cast to long int works around a bug in the HP C Compiler | |
12256 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12257 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12258 | # This bug is HP SR number 8606223364. | |
12259 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 | |
12260 | $as_echo_n "checking size of long... " >&6; } | |
12261 | if ${ac_cv_sizeof_long+:} false; then : | |
12262 | $as_echo_n "(cached) " >&6 | |
12263 | else | |
12264 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : | |
12265 | ||
12266 | else | |
12267 | if test "$ac_cv_type_long" = yes; then | |
12268 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12269 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12270 | as_fn_error 77 "cannot compute sizeof (long) | |
12271 | See \`config.log' for more details" "$LINENO" 5; } | |
12272 | else | |
12273 | ac_cv_sizeof_long=0 | |
12274 | fi | |
b72432fd | 12275 | fi |
cce855bc | 12276 | |
b72432fd | 12277 | fi |
ac50fbac CR |
12278 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
12279 | $as_echo "$ac_cv_sizeof_long" >&6; } | |
b72432fd | 12280 | |
b80f6443 | 12281 | |
ac50fbac CR |
12282 | |
12283 | cat >>confdefs.h <<_ACEOF | |
12284 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
12285 | _ACEOF | |
12286 | ||
12287 | ||
12288 | # The cast to long int works around a bug in the HP C Compiler | |
12289 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12290 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12291 | # This bug is HP SR number 8606223364. | |
12292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5 | |
12293 | $as_echo_n "checking size of char *... " >&6; } | |
12294 | if ${ac_cv_sizeof_char_p+:} false; then : | |
3185942a JA |
12295 | $as_echo_n "(cached) " >&6 |
12296 | else | |
ac50fbac CR |
12297 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then : |
12298 | ||
3185942a | 12299 | else |
ac50fbac CR |
12300 | if test "$ac_cv_type_char_p" = yes; then |
12301 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12302 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12303 | as_fn_error 77 "cannot compute sizeof (char *) | |
12304 | See \`config.log' for more details" "$LINENO" 5; } | |
12305 | else | |
12306 | ac_cv_sizeof_char_p=0 | |
12307 | fi | |
12308 | fi | |
3185942a | 12309 | |
3185942a | 12310 | fi |
ac50fbac CR |
12311 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5 |
12312 | $as_echo "$ac_cv_sizeof_char_p" >&6; } | |
3185942a | 12313 | |
3185942a JA |
12314 | |
12315 | ||
ac50fbac CR |
12316 | cat >>confdefs.h <<_ACEOF |
12317 | #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p | |
12318 | _ACEOF | |
12319 | ||
12320 | ||
12321 | # The cast to long int works around a bug in the HP C Compiler | |
12322 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12323 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12324 | # This bug is HP SR number 8606223364. | |
12325 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 | |
12326 | $as_echo_n "checking size of double... " >&6; } | |
12327 | if ${ac_cv_sizeof_double+:} false; then : | |
12328 | $as_echo_n "(cached) " >&6 | |
12329 | else | |
12330 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"; then : | |
12331 | ||
12332 | else | |
12333 | if test "$ac_cv_type_double" = yes; then | |
12334 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12335 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12336 | as_fn_error 77 "cannot compute sizeof (double) | |
12337 | See \`config.log' for more details" "$LINENO" 5; } | |
12338 | else | |
12339 | ac_cv_sizeof_double=0 | |
12340 | fi | |
3185942a JA |
12341 | fi |
12342 | ||
3185942a | 12343 | fi |
ac50fbac CR |
12344 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
12345 | $as_echo "$ac_cv_sizeof_double" >&6; } | |
12346 | ||
12347 | ||
3185942a JA |
12348 | |
12349 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 12350 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double |
3185942a JA |
12351 | _ACEOF |
12352 | ||
3185942a | 12353 | |
ac50fbac CR |
12354 | # The cast to long int works around a bug in the HP C Compiler |
12355 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12356 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12357 | # This bug is HP SR number 8606223364. | |
12358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 | |
12359 | $as_echo_n "checking size of long long... " >&6; } | |
12360 | if ${ac_cv_sizeof_long_long+:} false; then : | |
3185942a JA |
12361 | $as_echo_n "(cached) " >&6 |
12362 | else | |
ac50fbac CR |
12363 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : |
12364 | ||
3185942a | 12365 | else |
ac50fbac CR |
12366 | if test "$ac_cv_type_long_long" = yes; then |
12367 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12368 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12369 | as_fn_error 77 "cannot compute sizeof (long long) | |
12370 | See \`config.log' for more details" "$LINENO" 5; } | |
12371 | else | |
12372 | ac_cv_sizeof_long_long=0 | |
12373 | fi | |
12374 | fi | |
3185942a | 12375 | |
3185942a | 12376 | fi |
ac50fbac CR |
12377 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
12378 | $as_echo "$ac_cv_sizeof_long_long" >&6; } | |
3185942a | 12379 | |
3185942a JA |
12380 | |
12381 | ||
ac50fbac CR |
12382 | cat >>confdefs.h <<_ACEOF |
12383 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
12384 | _ACEOF | |
12385 | ||
12386 | ||
12387 | ||
12388 | ac_fn_c_check_type "$LINENO" "u_int" "ac_cv_type_u_int" "$ac_includes_default" | |
12389 | if test "x$ac_cv_type_u_int" = xyes; then : | |
3185942a | 12390 | |
3185942a JA |
12391 | else |
12392 | ||
12393 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 12394 | #define u_int unsigned int |
3185942a JA |
12395 | _ACEOF |
12396 | ||
12397 | fi | |
12398 | ||
ac50fbac CR |
12399 | ac_fn_c_check_type "$LINENO" "u_long" "ac_cv_type_u_long" "$ac_includes_default" |
12400 | if test "x$ac_cv_type_u_long" = xyes; then : | |
12401 | ||
cce855bc | 12402 | else |
ac50fbac CR |
12403 | |
12404 | cat >>confdefs.h <<_ACEOF | |
12405 | #define u_long unsigned long | |
f73dda09 | 12406 | _ACEOF |
3185942a | 12407 | |
ac50fbac CR |
12408 | fi |
12409 | ||
12410 | ||
12411 | ||
12412 | if test "$ac_cv_sizeof_short" = 2; then | |
12413 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12414 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
3185942a | 12415 | |
b72432fd | 12416 | else |
0628567a | 12417 | |
ac50fbac CR |
12418 | cat >>confdefs.h <<_ACEOF |
12419 | #define bits16_t short | |
12420 | _ACEOF | |
3185942a | 12421 | |
b72432fd | 12422 | fi |
3185942a | 12423 | |
ac50fbac CR |
12424 | elif test "$ac_cv_sizeof_char" = 2; then |
12425 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12426 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12427 | ||
f73dda09 JA |
12428 | else |
12429 | ||
b80f6443 | 12430 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12431 | #define bits16_t char |
b80f6443 | 12432 | _ACEOF |
b72432fd JA |
12433 | |
12434 | fi | |
12435 | ||
b72432fd | 12436 | else |
ac50fbac CR |
12437 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" |
12438 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12439 | ||
3185942a | 12440 | else |
3185942a | 12441 | |
ac50fbac CR |
12442 | cat >>confdefs.h <<_ACEOF |
12443 | #define bits16_t short | |
12444 | _ACEOF | |
12445 | ||
3185942a JA |
12446 | fi |
12447 | ||
ac50fbac CR |
12448 | fi |
12449 | ||
12450 | ||
12451 | if test "$ac_cv_sizeof_short" = 2; then | |
12452 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12453 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12454 | ||
b72432fd | 12455 | else |
0628567a | 12456 | |
ac50fbac CR |
12457 | cat >>confdefs.h <<_ACEOF |
12458 | #define u_bits16_t unsigned short | |
12459 | _ACEOF | |
3185942a | 12460 | |
f73dda09 | 12461 | fi |
3185942a | 12462 | |
ac50fbac CR |
12463 | elif test "$ac_cv_sizeof_char" = 2; then |
12464 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12465 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12466 | ||
f73dda09 JA |
12467 | else |
12468 | ||
b80f6443 | 12469 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12470 | #define u_bits16_t unsigned char |
b80f6443 | 12471 | _ACEOF |
f73dda09 | 12472 | |
cce855bc | 12473 | fi |
b72432fd | 12474 | |
3185942a | 12475 | else |
ac50fbac CR |
12476 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" |
12477 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12478 | ||
f73dda09 | 12479 | else |
ac50fbac CR |
12480 | |
12481 | cat >>confdefs.h <<_ACEOF | |
12482 | #define u_bits16_t unsigned short | |
f73dda09 | 12483 | _ACEOF |
3185942a | 12484 | |
3185942a JA |
12485 | fi |
12486 | ||
ac50fbac CR |
12487 | fi |
12488 | ||
12489 | ||
12490 | if test "$ac_cv_sizeof_int" = 4; then | |
12491 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12492 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12493 | ||
b72432fd | 12494 | else |
0628567a | 12495 | |
ac50fbac CR |
12496 | cat >>confdefs.h <<_ACEOF |
12497 | #define bits32_t int | |
12498 | _ACEOF | |
3185942a | 12499 | |
b72432fd | 12500 | fi |
3185942a | 12501 | |
ac50fbac CR |
12502 | elif test "$ac_cv_sizeof_long" = 4; then |
12503 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12504 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12505 | ||
12506 | else | |
12507 | ||
12508 | cat >>confdefs.h <<_ACEOF | |
12509 | #define bits32_t long | |
12510 | _ACEOF | |
12511 | ||
b72432fd | 12512 | fi |
ac50fbac CR |
12513 | |
12514 | else | |
12515 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12516 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12517 | ||
f73dda09 JA |
12518 | else |
12519 | ||
b80f6443 | 12520 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12521 | #define bits32_t int |
b80f6443 | 12522 | _ACEOF |
cce855bc JA |
12523 | |
12524 | fi | |
12525 | ||
12526 | fi | |
12527 | ||
b80f6443 | 12528 | |
ac50fbac CR |
12529 | if test "$ac_cv_sizeof_int" = 4; then |
12530 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12531 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
b80f6443 | 12532 | |
bb70624e | 12533 | else |
ac50fbac CR |
12534 | |
12535 | cat >>confdefs.h <<_ACEOF | |
12536 | #define u_bits32_t unsigned int | |
3185942a | 12537 | _ACEOF |
3185942a | 12538 | |
3185942a JA |
12539 | fi |
12540 | ||
ac50fbac CR |
12541 | elif test "$ac_cv_sizeof_long" = 4; then |
12542 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12543 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
12544 | ||
bb70624e | 12545 | else |
0628567a | 12546 | |
ac50fbac CR |
12547 | cat >>confdefs.h <<_ACEOF |
12548 | #define u_bits32_t unsigned long | |
12549 | _ACEOF | |
3185942a | 12550 | |
bb70624e | 12551 | fi |
3185942a | 12552 | |
ac50fbac CR |
12553 | else |
12554 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12555 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
12556 | ||
f73dda09 JA |
12557 | else |
12558 | ||
b80f6443 | 12559 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12560 | #define u_bits32_t unsigned int |
b80f6443 | 12561 | _ACEOF |
bb70624e JA |
12562 | |
12563 | fi | |
12564 | ||
ac50fbac CR |
12565 | fi |
12566 | ||
12567 | ||
12568 | if test "$ac_cv_sizeof_char_p" = 8; then | |
12569 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12570 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12571 | ||
bb70624e | 12572 | else |
ac50fbac CR |
12573 | |
12574 | cat >>confdefs.h <<_ACEOF | |
12575 | #define bits64_t char * | |
3185942a | 12576 | _ACEOF |
3185942a | 12577 | |
3185942a JA |
12578 | fi |
12579 | ||
ac50fbac CR |
12580 | elif test "$ac_cv_sizeof_double" = 8; then |
12581 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12582 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12583 | ||
bb70624e | 12584 | else |
0628567a | 12585 | |
ac50fbac CR |
12586 | cat >>confdefs.h <<_ACEOF |
12587 | #define bits64_t double | |
12588 | _ACEOF | |
3185942a | 12589 | |
bb70624e | 12590 | fi |
3185942a | 12591 | |
ac50fbac CR |
12592 | elif test -n "$ac_cv_type_long_long" && test "$ac_cv_sizeof_long_long" = 8; then |
12593 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12594 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12595 | ||
f73dda09 JA |
12596 | else |
12597 | ||
b80f6443 | 12598 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12599 | #define bits64_t long long |
b80f6443 | 12600 | _ACEOF |
bb70624e JA |
12601 | |
12602 | fi | |
12603 | ||
ac50fbac CR |
12604 | elif test "$ac_cv_sizeof_long" = 8; then |
12605 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12606 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12607 | ||
bb70624e | 12608 | else |
ac50fbac CR |
12609 | |
12610 | cat >>confdefs.h <<_ACEOF | |
12611 | #define bits64_t long | |
3185942a | 12612 | _ACEOF |
3185942a | 12613 | |
3185942a JA |
12614 | fi |
12615 | ||
bb70624e | 12616 | else |
ac50fbac CR |
12617 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" |
12618 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12619 | ||
12620 | else | |
0628567a | 12621 | |
ac50fbac CR |
12622 | cat >>confdefs.h <<_ACEOF |
12623 | #define bits64_t double | |
12624 | _ACEOF | |
3185942a | 12625 | |
f73dda09 | 12626 | fi |
3185942a | 12627 | |
f73dda09 | 12628 | fi |
ac50fbac CR |
12629 | |
12630 | ||
12631 | ||
12632 | if test "$ac_cv_sizeof_int" = "$ac_cv_sizeof_char_p"; then | |
12633 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12634 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12635 | ||
f73dda09 JA |
12636 | else |
12637 | ||
b80f6443 | 12638 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 12639 | #define ptrdiff_t int |
b80f6443 | 12640 | _ACEOF |
f73dda09 | 12641 | |
bb70624e | 12642 | fi |
bb70624e | 12643 | |
ac50fbac CR |
12644 | elif test "$ac_cv_sizeof_long" = "$ac_cv_sizeof_char_p"; then |
12645 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12646 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12647 | ||
f73dda09 | 12648 | else |
ac50fbac CR |
12649 | |
12650 | cat >>confdefs.h <<_ACEOF | |
12651 | #define ptrdiff_t long | |
3185942a | 12652 | _ACEOF |
3185942a | 12653 | |
3185942a JA |
12654 | fi |
12655 | ||
ac50fbac CR |
12656 | elif test "$ac_cv_type_long_long" = yes && test "$ac_cv_sizeof_long_long" = "$ac_cv_sizeof_char_p"; then |
12657 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12658 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12659 | ||
f73dda09 | 12660 | else |
0628567a | 12661 | |
ac50fbac CR |
12662 | cat >>confdefs.h <<_ACEOF |
12663 | #define ptrdiff_t long long | |
12664 | _ACEOF | |
3185942a | 12665 | |
bb70624e | 12666 | fi |
3185942a | 12667 | |
ac50fbac CR |
12668 | else |
12669 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12670 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12671 | ||
f73dda09 JA |
12672 | else |
12673 | ||
b80f6443 | 12674 | cat >>confdefs.h <<_ACEOF |
bb70624e | 12675 | #define ptrdiff_t int |
b80f6443 | 12676 | _ACEOF |
bb70624e JA |
12677 | |
12678 | fi | |
12679 | ||
12680 | fi | |
12681 | ||
b80f6443 | 12682 | |
ac50fbac | 12683 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5 |
3185942a | 12684 | $as_echo_n "checking whether stat file-mode macros are broken... " >&6; } |
ac50fbac | 12685 | if ${ac_cv_header_stat_broken+:} false; then : |
3185942a | 12686 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 12687 | else |
ac50fbac | 12688 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12689 | /* end confdefs.h. */ |
ccc6cda3 JA |
12690 | #include <sys/types.h> |
12691 | #include <sys/stat.h> | |
12692 | ||
3185942a JA |
12693 | #if defined S_ISBLK && defined S_IFDIR |
12694 | extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1]; | |
ccc6cda3 JA |
12695 | #endif |
12696 | ||
3185942a JA |
12697 | #if defined S_ISBLK && defined S_IFCHR |
12698 | extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1]; | |
ccc6cda3 JA |
12699 | #endif |
12700 | ||
3185942a JA |
12701 | #if defined S_ISLNK && defined S_IFREG |
12702 | extern char c3[S_ISLNK (S_IFREG) ? -1 : 1]; | |
ccc6cda3 JA |
12703 | #endif |
12704 | ||
3185942a JA |
12705 | #if defined S_ISSOCK && defined S_IFREG |
12706 | extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1]; | |
f73dda09 JA |
12707 | #endif |
12708 | ||
12709 | _ACEOF | |
ac50fbac | 12710 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 12711 | ac_cv_header_stat_broken=no |
3185942a | 12712 | else |
ac50fbac | 12713 | ac_cv_header_stat_broken=yes |
ccc6cda3 | 12714 | fi |
3185942a | 12715 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 12716 | fi |
ac50fbac | 12717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5 |
3185942a | 12718 | $as_echo "$ac_cv_header_stat_broken" >&6; } |
f73dda09 | 12719 | if test $ac_cv_header_stat_broken = yes; then |
ccc6cda3 | 12720 | |
ac50fbac | 12721 | $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h |
ccc6cda3 JA |
12722 | |
12723 | fi | |
12724 | ||
b80f6443 | 12725 | |
ac50fbac | 12726 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether #! works in shell scripts" >&5 |
3185942a | 12727 | $as_echo_n "checking whether #! works in shell scripts... " >&6; } |
ac50fbac | 12728 | if ${ac_cv_sys_interpreter+:} false; then : |
3185942a | 12729 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
12730 | else |
12731 | echo '#! /bin/cat | |
12732 | exit 69 | |
f73dda09 | 12733 | ' >conftest |
ccc6cda3 | 12734 | chmod u+x conftest |
3185942a | 12735 | (SHELL=/bin/sh; export SHELL; ./conftest >/dev/null 2>&1) |
ccc6cda3 JA |
12736 | if test $? -ne 69; then |
12737 | ac_cv_sys_interpreter=yes | |
12738 | else | |
12739 | ac_cv_sys_interpreter=no | |
12740 | fi | |
12741 | rm -f conftest | |
12742 | fi | |
ac50fbac | 12743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_interpreter" >&5 |
3185942a | 12744 | $as_echo "$ac_cv_sys_interpreter" >&6; } |
f73dda09 | 12745 | interpval=$ac_cv_sys_interpreter |
ccc6cda3 JA |
12746 | |
12747 | if test $ac_cv_sys_interpreter = yes; then | |
ac50fbac | 12748 | $as_echo "#define HAVE_HASH_BANG_EXEC 1" >>confdefs.h |
ccc6cda3 | 12749 | |
ccc6cda3 JA |
12750 | fi |
12751 | ||
ccc6cda3 | 12752 | if test "$ac_cv_func_lstat" = "no"; then |
ac50fbac | 12753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lstat" >&5 |
3185942a | 12754 | $as_echo_n "checking for lstat... " >&6; } |
ac50fbac | 12755 | if ${bash_cv_func_lstat+:} false; then : |
3185942a | 12756 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 12757 | else |
ac50fbac | 12758 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12759 | /* end confdefs.h. */ |
ccc6cda3 JA |
12760 | |
12761 | #include <sys/types.h> | |
12762 | #include <sys/stat.h> | |
12763 | ||
f73dda09 JA |
12764 | int |
12765 | main () | |
12766 | { | |
12767 | lstat(".",(struct stat *)0); | |
12768 | ; | |
12769 | return 0; | |
12770 | } | |
12771 | _ACEOF | |
ac50fbac | 12772 | if ac_fn_c_try_link "$LINENO"; then : |
ccc6cda3 JA |
12773 | bash_cv_func_lstat=yes |
12774 | else | |
ac50fbac | 12775 | bash_cv_func_lstat=no |
ccc6cda3 | 12776 | fi |
ac50fbac CR |
12777 | rm -f core conftest.err conftest.$ac_objext \ |
12778 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 | 12779 | fi |
ac50fbac | 12780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_lstat" >&5 |
3185942a | 12781 | $as_echo "$bash_cv_func_lstat" >&6; } |
ccc6cda3 | 12782 | if test $bash_cv_func_lstat = yes; then |
ac50fbac | 12783 | $as_echo "#define HAVE_LSTAT 1" >>confdefs.h |
b80f6443 JA |
12784 | |
12785 | fi | |
12786 | ||
12787 | fi | |
12788 | ||
12789 | ||
ac50fbac | 12790 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the ctype macros accept non-ascii characters" >&5 |
3185942a | 12791 | $as_echo_n "checking whether the ctype macros accept non-ascii characters... " >&6; } |
ac50fbac | 12792 | if ${bash_cv_func_ctype_nonascii+:} false; then : |
3185942a | 12793 | $as_echo_n "(cached) " >&6 |
b80f6443 | 12794 | else |
ac50fbac CR |
12795 | if test "$cross_compiling" = yes; then : |
12796 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&5 | |
3185942a | 12797 | $as_echo "$as_me: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&2;} |
b80f6443 JA |
12798 | bash_cv_func_ctype_nonascii=no |
12799 | ||
12800 | else | |
ac50fbac | 12801 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12802 | /* end confdefs.h. */ |
b80f6443 JA |
12803 | |
12804 | #ifdef HAVE_LOCALE_H | |
12805 | #include <locale.h> | |
12806 | #endif | |
12807 | #include <stdio.h> | |
12808 | #include <ctype.h> | |
12809 | ||
12810 | main(c, v) | |
12811 | int c; | |
12812 | char *v[]; | |
12813 | { | |
12814 | char *deflocale; | |
12815 | unsigned char x; | |
12816 | int r1, r2; | |
12817 | ||
12818 | #ifdef HAVE_SETLOCALE | |
12819 | /* We take a shot here. If that locale is not known, try the | |
12820 | system default. We try this one because '\342' (226) is | |
12821 | known to be a printable character in that locale. */ | |
12822 | deflocale = setlocale(LC_ALL, "en_US.ISO8859-1"); | |
12823 | if (deflocale == 0) | |
12824 | deflocale = setlocale(LC_ALL, ""); | |
12825 | #endif | |
12826 | ||
12827 | x = '\342'; | |
12828 | r1 = isprint(x); | |
12829 | x -= 128; | |
12830 | r2 = isprint(x); | |
12831 | exit (r1 == 0 || r2 == 0); | |
12832 | } | |
12833 | ||
12834 | _ACEOF | |
ac50fbac | 12835 | if ac_fn_c_try_run "$LINENO"; then : |
b80f6443 JA |
12836 | bash_cv_func_ctype_nonascii=yes |
12837 | else | |
ac50fbac | 12838 | bash_cv_func_ctype_nonascii=no |
b80f6443 | 12839 | fi |
ac50fbac CR |
12840 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12841 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 12842 | fi |
3185942a | 12843 | |
b80f6443 JA |
12844 | fi |
12845 | ||
ac50fbac | 12846 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_ctype_nonascii" >&5 |
3185942a | 12847 | $as_echo "$bash_cv_func_ctype_nonascii" >&6; } |
b80f6443 | 12848 | if test $bash_cv_func_ctype_nonascii = yes; then |
ac50fbac | 12849 | $as_echo "#define CTYPE_NON_ASCII 1" >>confdefs.h |
ccc6cda3 JA |
12850 | |
12851 | fi | |
12852 | ||
ac50fbac | 12853 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dup2 fails to clear the close-on-exec flag" >&5 |
3185942a | 12854 | $as_echo_n "checking if dup2 fails to clear the close-on-exec flag... " >&6; } |
ac50fbac | 12855 | if ${bash_cv_dup2_broken+:} false; then : |
3185942a | 12856 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 12857 | else |
ac50fbac CR |
12858 | if test "$cross_compiling" = yes; then : |
12859 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&5 | |
3185942a | 12860 | $as_echo "$as_me: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&2;} |
cce855bc | 12861 | bash_cv_dup2_broken=no |
ccc6cda3 | 12862 | else |
ac50fbac | 12863 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12864 | /* end confdefs.h. */ |
ccc6cda3 JA |
12865 | |
12866 | #include <sys/types.h> | |
12867 | #include <fcntl.h> | |
12868 | main() | |
12869 | { | |
12870 | int fd1, fd2, fl; | |
12871 | fd1 = open("/dev/null", 2); | |
12872 | if (fcntl(fd1, 2, 1) < 0) | |
12873 | exit(1); | |
12874 | fd2 = dup2(fd1, 1); | |
12875 | if (fd2 < 0) | |
12876 | exit(2); | |
12877 | fl = fcntl(fd2, 1, 0); | |
12878 | /* fl will be 1 if dup2 did not reset the close-on-exec flag. */ | |
12879 | exit(fl != 1); | |
12880 | } | |
12881 | ||
f73dda09 | 12882 | _ACEOF |
ac50fbac | 12883 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
12884 | bash_cv_dup2_broken=yes |
12885 | else | |
ac50fbac | 12886 | bash_cv_dup2_broken=no |
ccc6cda3 | 12887 | fi |
ac50fbac CR |
12888 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12889 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 JA |
12890 | fi |
12891 | ||
3185942a | 12892 | |
ccc6cda3 JA |
12893 | fi |
12894 | ||
ac50fbac | 12895 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dup2_broken" >&5 |
3185942a | 12896 | $as_echo "$bash_cv_dup2_broken" >&6; } |
ccc6cda3 | 12897 | if test $bash_cv_dup2_broken = yes; then |
ac50fbac | 12898 | $as_echo "#define DUP2_BROKEN 1" >>confdefs.h |
ccc6cda3 JA |
12899 | |
12900 | fi | |
12901 | ||
b80f6443 | 12902 | |
ac50fbac | 12903 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pgrps need synchronization" >&5 |
3185942a | 12904 | $as_echo_n "checking whether pgrps need synchronization... " >&6; } |
ac50fbac | 12905 | if ${bash_cv_pgrp_pipe+:} false; then : |
3185942a | 12906 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 12907 | else |
ac50fbac CR |
12908 | if test "$cross_compiling" = yes; then : |
12909 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&5 | |
3185942a | 12910 | $as_echo "$as_me: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&2;} |
cce855bc | 12911 | bash_cv_pgrp_pipe=no |
ccc6cda3 | 12912 | else |
ac50fbac | 12913 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12914 | /* end confdefs.h. */ |
ccc6cda3 JA |
12915 | |
12916 | #ifdef HAVE_UNISTD_H | |
12917 | # include <unistd.h> | |
12918 | #endif | |
12919 | main() | |
12920 | { | |
12921 | # ifdef GETPGRP_VOID | |
12922 | # define getpgID() getpgrp() | |
12923 | # else | |
12924 | # define getpgID() getpgrp(0) | |
12925 | # define setpgid(x,y) setpgrp(x,y) | |
12926 | # endif | |
12927 | int pid1, pid2, fds[2]; | |
12928 | int status; | |
12929 | char ok; | |
12930 | ||
12931 | switch (pid1 = fork()) { | |
12932 | case -1: | |
12933 | exit(1); | |
12934 | case 0: | |
12935 | setpgid(0, getpid()); | |
12936 | exit(0); | |
12937 | } | |
12938 | setpgid(pid1, pid1); | |
12939 | ||
12940 | sleep(2); /* let first child die */ | |
12941 | ||
12942 | if (pipe(fds) < 0) | |
12943 | exit(2); | |
12944 | ||
12945 | switch (pid2 = fork()) { | |
12946 | case -1: | |
12947 | exit(3); | |
12948 | case 0: | |
12949 | setpgid(0, pid1); | |
12950 | ok = getpgID() == pid1; | |
12951 | write(fds[1], &ok, 1); | |
12952 | exit(0); | |
12953 | } | |
12954 | setpgid(pid2, pid1); | |
12955 | ||
12956 | close(fds[1]); | |
12957 | if (read(fds[0], &ok, 1) != 1) | |
12958 | exit(4); | |
12959 | wait(&status); | |
12960 | wait(&status); | |
12961 | exit(ok ? 0 : 5); | |
12962 | } | |
12963 | ||
f73dda09 | 12964 | _ACEOF |
ac50fbac | 12965 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
12966 | bash_cv_pgrp_pipe=no |
12967 | else | |
ac50fbac | 12968 | bash_cv_pgrp_pipe=yes |
ccc6cda3 | 12969 | fi |
ac50fbac CR |
12970 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12971 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 JA |
12972 | fi |
12973 | ||
3185942a | 12974 | |
ccc6cda3 JA |
12975 | fi |
12976 | ||
ac50fbac | 12977 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_pgrp_pipe" >&5 |
3185942a | 12978 | $as_echo "$bash_cv_pgrp_pipe" >&6; } |
ccc6cda3 | 12979 | if test $bash_cv_pgrp_pipe = yes; then |
ac50fbac | 12980 | $as_echo "#define PGRP_PIPE 1" >>confdefs.h |
ccc6cda3 JA |
12981 | |
12982 | fi | |
12983 | ||
b80f6443 | 12984 | |
ac50fbac | 12985 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for type of signal functions" >&5 |
3185942a | 12986 | $as_echo_n "checking for type of signal functions... " >&6; } |
ac50fbac | 12987 | if ${bash_cv_signal_vintage+:} false; then : |
3185942a | 12988 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 12989 | else |
f73dda09 | 12990 | |
ac50fbac | 12991 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 12992 | /* end confdefs.h. */ |
d166f048 | 12993 | #include <signal.h> |
f73dda09 JA |
12994 | int |
12995 | main () | |
12996 | { | |
d166f048 JA |
12997 | |
12998 | sigset_t ss; | |
12999 | struct sigaction sa; | |
13000 | sigemptyset(&ss); sigsuspend(&ss); | |
13001 | sigaction(SIGINT, &sa, (struct sigaction *) 0); | |
13002 | sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0); | |
f73dda09 JA |
13003 | |
13004 | ; | |
13005 | return 0; | |
13006 | } | |
13007 | _ACEOF | |
ac50fbac | 13008 | if ac_fn_c_try_link "$LINENO"; then : |
d166f048 | 13009 | bash_cv_signal_vintage=posix |
ccc6cda3 | 13010 | else |
0628567a | 13011 | |
ac50fbac | 13012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13013 | /* end confdefs.h. */ |
d166f048 | 13014 | #include <signal.h> |
f73dda09 JA |
13015 | int |
13016 | main () | |
13017 | { | |
d166f048 JA |
13018 | |
13019 | int mask = sigmask(SIGINT); | |
13020 | sigsetmask(mask); sigblock(mask); sigpause(mask); | |
f73dda09 JA |
13021 | |
13022 | ; | |
13023 | return 0; | |
13024 | } | |
13025 | _ACEOF | |
ac50fbac | 13026 | if ac_fn_c_try_link "$LINENO"; then : |
d166f048 JA |
13027 | bash_cv_signal_vintage=4.2bsd |
13028 | else | |
f73dda09 | 13029 | |
ac50fbac | 13030 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13031 | /* end confdefs.h. */ |
d166f048 JA |
13032 | |
13033 | #include <signal.h> | |
13034 | RETSIGTYPE foo() { } | |
f73dda09 JA |
13035 | int |
13036 | main () | |
13037 | { | |
d166f048 JA |
13038 | |
13039 | int mask = sigmask(SIGINT); | |
13040 | sigset(SIGINT, foo); sigrelse(SIGINT); | |
ac50fbac CR |
13041 | sighold(SIGINT); sigpause(SIGINT); |
13042 | ||
13043 | ; | |
13044 | return 0; | |
13045 | } | |
13046 | _ACEOF | |
13047 | if ac_fn_c_try_link "$LINENO"; then : | |
d166f048 JA |
13048 | bash_cv_signal_vintage=svr3 |
13049 | else | |
ac50fbac | 13050 | bash_cv_signal_vintage=v7 |
f73dda09 | 13051 | |
d166f048 | 13052 | fi |
ac50fbac CR |
13053 | rm -f core conftest.err conftest.$ac_objext \ |
13054 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 | 13055 | |
d166f048 | 13056 | fi |
ac50fbac CR |
13057 | rm -f core conftest.err conftest.$ac_objext \ |
13058 | conftest$ac_exeext conftest.$ac_ext | |
d166f048 JA |
13059 | |
13060 | fi | |
ac50fbac CR |
13061 | rm -f core conftest.err conftest.$ac_objext \ |
13062 | conftest$ac_exeext conftest.$ac_ext | |
d166f048 JA |
13063 | |
13064 | fi | |
13065 | ||
ac50fbac | 13066 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_signal_vintage" >&5 |
3185942a | 13067 | $as_echo "$bash_cv_signal_vintage" >&6; } |
d166f048 | 13068 | if test "$bash_cv_signal_vintage" = posix; then |
ac50fbac | 13069 | $as_echo "#define HAVE_POSIX_SIGNALS 1" >>confdefs.h |
d166f048 JA |
13070 | |
13071 | elif test "$bash_cv_signal_vintage" = "4.2bsd"; then | |
ac50fbac | 13072 | $as_echo "#define HAVE_BSD_SIGNALS 1" >>confdefs.h |
d166f048 JA |
13073 | |
13074 | elif test "$bash_cv_signal_vintage" = svr3; then | |
ac50fbac | 13075 | $as_echo "#define HAVE_USG_SIGHOLD 1" >>confdefs.h |
d166f048 JA |
13076 | |
13077 | fi | |
13078 | ||
b80f6443 | 13079 | |
ac50fbac | 13080 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_errlist and sys_nerr" >&5 |
3185942a | 13081 | $as_echo_n "checking for sys_errlist and sys_nerr... " >&6; } |
ac50fbac | 13082 | if ${bash_cv_sys_errlist+:} false; then : |
3185942a | 13083 | $as_echo_n "(cached) " >&6 |
cce855bc | 13084 | else |
ac50fbac | 13085 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13086 | /* end confdefs.h. */ |
f73dda09 JA |
13087 | #include <errno.h> |
13088 | int | |
cce855bc JA |
13089 | main () |
13090 | { | |
d166f048 JA |
13091 | extern char *sys_errlist[]; |
13092 | extern int sys_nerr; | |
13093 | char *msg = sys_errlist[sys_nerr - 1]; | |
f73dda09 JA |
13094 | ; |
13095 | return 0; | |
13096 | } | |
13097 | _ACEOF | |
ac50fbac | 13098 | if ac_fn_c_try_link "$LINENO"; then : |
d166f048 JA |
13099 | bash_cv_sys_errlist=yes |
13100 | else | |
ac50fbac | 13101 | bash_cv_sys_errlist=no |
d166f048 | 13102 | fi |
ac50fbac CR |
13103 | rm -f core conftest.err conftest.$ac_objext \ |
13104 | conftest$ac_exeext conftest.$ac_ext | |
d166f048 | 13105 | fi |
ac50fbac | 13106 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_errlist" >&5 |
3185942a | 13107 | $as_echo "$bash_cv_sys_errlist" >&6; } |
d166f048 | 13108 | if test $bash_cv_sys_errlist = yes; then |
ac50fbac | 13109 | $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h |
d166f048 JA |
13110 | |
13111 | fi | |
13112 | ||
b80f6443 | 13113 | |
ac50fbac | 13114 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_siglist in system C library" >&5 |
3185942a | 13115 | $as_echo_n "checking for sys_siglist in system C library... " >&6; } |
ac50fbac | 13116 | if ${bash_cv_sys_siglist+:} false; then : |
3185942a | 13117 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13118 | else |
ac50fbac CR |
13119 | if test "$cross_compiling" = yes; then : |
13120 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&5 | |
3185942a | 13121 | $as_echo "$as_me: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&2;} |
cce855bc | 13122 | bash_cv_sys_siglist=no |
ccc6cda3 | 13123 | else |
ac50fbac | 13124 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13125 | /* end confdefs.h. */ |
ccc6cda3 JA |
13126 | |
13127 | #include <sys/types.h> | |
13128 | #include <signal.h> | |
13129 | #ifdef HAVE_UNISTD_H | |
13130 | #include <unistd.h> | |
13131 | #endif | |
3185942a | 13132 | #if !HAVE_DECL_SYS_SIGLIST |
ccc6cda3 JA |
13133 | extern char *sys_siglist[]; |
13134 | #endif | |
13135 | main() | |
13136 | { | |
13137 | char *msg = sys_siglist[2]; | |
13138 | exit(msg == 0); | |
13139 | } | |
f73dda09 | 13140 | _ACEOF |
ac50fbac | 13141 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
13142 | bash_cv_sys_siglist=yes |
13143 | else | |
ac50fbac | 13144 | bash_cv_sys_siglist=no |
ccc6cda3 | 13145 | fi |
ac50fbac CR |
13146 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13147 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 13148 | fi |
3185942a | 13149 | |
ccc6cda3 | 13150 | fi |
cce855bc | 13151 | |
ac50fbac | 13152 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_siglist" >&5 |
3185942a | 13153 | $as_echo "$bash_cv_sys_siglist" >&6; } |
ccc6cda3 | 13154 | if test $bash_cv_sys_siglist = yes; then |
ac50fbac | 13155 | $as_echo "#define HAVE_SYS_SIGLIST 1" >>confdefs.h |
ccc6cda3 JA |
13156 | |
13157 | fi | |
13158 | ||
ac50fbac | 13159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in signal.h or unistd.h" >&5 |
3185942a | 13160 | $as_echo_n "checking for _sys_siglist in signal.h or unistd.h... " >&6; } |
ac50fbac | 13161 | if ${bash_cv_decl_under_sys_siglist+:} false; then : |
3185942a | 13162 | $as_echo_n "(cached) " >&6 |
e8ce775d | 13163 | else |
ac50fbac | 13164 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13165 | /* end confdefs.h. */ |
e8ce775d JA |
13166 | |
13167 | #include <sys/types.h> | |
13168 | #include <signal.h> | |
13169 | #ifdef HAVE_UNISTD_H | |
13170 | #include <unistd.h> | |
13171 | #endif | |
f73dda09 JA |
13172 | int |
13173 | main () | |
13174 | { | |
13175 | char *msg = _sys_siglist[2]; | |
13176 | ; | |
13177 | return 0; | |
13178 | } | |
13179 | _ACEOF | |
ac50fbac | 13180 | if ac_fn_c_try_compile "$LINENO"; then : |
e8ce775d JA |
13181 | bash_cv_decl_under_sys_siglist=yes |
13182 | else | |
ac50fbac | 13183 | bash_cv_decl_under_sys_siglist=no |
e8ce775d | 13184 | fi |
3185942a | 13185 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e8ce775d | 13186 | fi |
ac50fbac | 13187 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_under_sys_siglist" >&5 |
3185942a | 13188 | $as_echo "$bash_cv_decl_under_sys_siglist" >&6; } |
e8ce775d | 13189 | if test $bash_cv_decl_under_sys_siglist = yes; then |
ac50fbac | 13190 | $as_echo "#define UNDER_SYS_SIGLIST_DECLARED 1" >>confdefs.h |
e8ce775d JA |
13191 | |
13192 | fi | |
13193 | ||
b80f6443 | 13194 | |
ac50fbac | 13195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in system C library" >&5 |
3185942a | 13196 | $as_echo_n "checking for _sys_siglist in system C library... " >&6; } |
ac50fbac | 13197 | if ${bash_cv_under_sys_siglist+:} false; then : |
3185942a | 13198 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13199 | else |
ac50fbac CR |
13200 | if test "$cross_compiling" = yes; then : |
13201 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&5 | |
3185942a | 13202 | $as_echo "$as_me: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&2;} |
cce855bc | 13203 | bash_cv_under_sys_siglist=no |
ccc6cda3 | 13204 | else |
ac50fbac | 13205 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13206 | /* end confdefs.h. */ |
ccc6cda3 JA |
13207 | |
13208 | #include <sys/types.h> | |
13209 | #include <signal.h> | |
13210 | #ifdef HAVE_UNISTD_H | |
13211 | #include <unistd.h> | |
13212 | #endif | |
e8ce775d | 13213 | #ifndef UNDER_SYS_SIGLIST_DECLARED |
ccc6cda3 JA |
13214 | extern char *_sys_siglist[]; |
13215 | #endif | |
13216 | main() | |
13217 | { | |
e8ce775d | 13218 | char *msg = (char *)_sys_siglist[2]; |
ccc6cda3 JA |
13219 | exit(msg == 0); |
13220 | } | |
f73dda09 | 13221 | _ACEOF |
ac50fbac | 13222 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
13223 | bash_cv_under_sys_siglist=yes |
13224 | else | |
ac50fbac | 13225 | bash_cv_under_sys_siglist=no |
ccc6cda3 | 13226 | fi |
ac50fbac CR |
13227 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13228 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 13229 | fi |
3185942a | 13230 | |
ccc6cda3 | 13231 | fi |
cce855bc | 13232 | |
ac50fbac | 13233 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_under_sys_siglist" >&5 |
3185942a | 13234 | $as_echo "$bash_cv_under_sys_siglist" >&6; } |
ccc6cda3 | 13235 | if test $bash_cv_under_sys_siglist = yes; then |
ac50fbac | 13236 | $as_echo "#define HAVE_UNDER_SYS_SIGLIST 1" >>confdefs.h |
ccc6cda3 JA |
13237 | |
13238 | fi | |
13239 | ||
b80f6443 | 13240 | |
ac50fbac | 13241 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signal handlers are of type void" >&5 |
3185942a | 13242 | $as_echo_n "checking whether signal handlers are of type void... " >&6; } |
ac50fbac | 13243 | if ${bash_cv_void_sighandler+:} false; then : |
3185942a | 13244 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13245 | else |
ac50fbac | 13246 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13247 | /* end confdefs.h. */ |
ccc6cda3 JA |
13248 | #include <sys/types.h> |
13249 | #include <signal.h> | |
13250 | #ifdef signal | |
13251 | #undef signal | |
13252 | #endif | |
13253 | #ifdef __cplusplus | |
13254 | extern "C" | |
13255 | #endif | |
13256 | void (*signal ()) (); | |
f73dda09 JA |
13257 | int |
13258 | main () | |
13259 | { | |
ccc6cda3 | 13260 | int i; |
f73dda09 JA |
13261 | ; |
13262 | return 0; | |
13263 | } | |
13264 | _ACEOF | |
ac50fbac | 13265 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
13266 | bash_cv_void_sighandler=yes |
13267 | else | |
ac50fbac | 13268 | bash_cv_void_sighandler=no |
ccc6cda3 | 13269 | fi |
3185942a | 13270 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 | 13271 | fi |
ac50fbac | 13272 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_void_sighandler" >&5 |
3185942a | 13273 | $as_echo "$bash_cv_void_sighandler" >&6; } |
ccc6cda3 | 13274 | if test $bash_cv_void_sighandler = yes; then |
ac50fbac | 13275 | $as_echo "#define VOID_SIGHANDLER 1" >>confdefs.h |
ccc6cda3 JA |
13276 | |
13277 | fi | |
13278 | ||
b80f6443 JA |
13279 | |
13280 | ||
ac50fbac | 13281 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5 |
3185942a | 13282 | $as_echo_n "checking for clock_t... " >&6; } |
ac50fbac | 13283 | if ${bash_cv_type_clock_t+:} false; then : |
3185942a | 13284 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13285 | else |
ac50fbac | 13286 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13287 | /* end confdefs.h. */ |
ccc6cda3 JA |
13288 | #include <sys/types.h> |
13289 | #if STDC_HEADERS | |
13290 | #include <stdlib.h> | |
f73dda09 JA |
13291 | #include <stddef.h> |
13292 | #endif | |
13293 | #if HAVE_INTTYPES_H | |
13294 | #include <inttypes.h> | |
ccc6cda3 | 13295 | #endif |
0001803f CR |
13296 | #if HAVE_STDINT_H |
13297 | #include <stdint.h> | |
13298 | #endif | |
ccc6cda3 JA |
13299 | #include <sys/times.h> |
13300 | ||
f73dda09 | 13301 | _ACEOF |
ccc6cda3 | 13302 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
ac50fbac | 13303 | $EGREP "clock_t" >/dev/null 2>&1; then : |
ccc6cda3 JA |
13304 | bash_cv_type_clock_t=yes |
13305 | else | |
ccc6cda3 JA |
13306 | bash_cv_type_clock_t=no |
13307 | fi | |
13308 | rm -f conftest* | |
13309 | ||
13310 | fi | |
13311 | ||
ac50fbac | 13312 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_clock_t" >&5 |
3185942a | 13313 | $as_echo "$bash_cv_type_clock_t" >&6; } |
ccc6cda3 JA |
13314 | |
13315 | if test $bash_cv_type_clock_t = no; then | |
b80f6443 | 13316 | cat >>confdefs.h <<_ACEOF |
ccc6cda3 | 13317 | #define clock_t long |
b80f6443 | 13318 | _ACEOF |
ccc6cda3 JA |
13319 | |
13320 | fi | |
13321 | ||
b80f6443 JA |
13322 | |
13323 | ||
ac50fbac | 13324 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigset_t" >&5 |
3185942a | 13325 | $as_echo_n "checking for sigset_t... " >&6; } |
ac50fbac | 13326 | if ${bash_cv_type_sigset_t+:} false; then : |
3185942a | 13327 | $as_echo_n "(cached) " >&6 |
f73dda09 | 13328 | else |
ac50fbac | 13329 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13330 | /* end confdefs.h. */ |
f73dda09 JA |
13331 | #include <sys/types.h> |
13332 | #if STDC_HEADERS | |
13333 | #include <stdlib.h> | |
13334 | #include <stddef.h> | |
13335 | #endif | |
13336 | #if HAVE_INTTYPES_H | |
13337 | #include <inttypes.h> | |
13338 | #endif | |
0001803f CR |
13339 | #if HAVE_STDINT_H |
13340 | #include <stdint.h> | |
13341 | #endif | |
ac50fbac | 13342 | #include <signal.h> |
f73dda09 JA |
13343 | |
13344 | _ACEOF | |
13345 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac CR |
13346 | $EGREP "sigset_t" >/dev/null 2>&1; then : |
13347 | bash_cv_type_sigset_t=yes | |
f73dda09 | 13348 | else |
ac50fbac | 13349 | bash_cv_type_sigset_t=no |
f73dda09 JA |
13350 | fi |
13351 | rm -f conftest* | |
13352 | ||
13353 | fi | |
13354 | ||
ac50fbac CR |
13355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sigset_t" >&5 |
13356 | $as_echo "$bash_cv_type_sigset_t" >&6; } | |
f73dda09 | 13357 | |
ac50fbac | 13358 | if test $bash_cv_type_sigset_t = no; then |
b80f6443 | 13359 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 13360 | #define sigset_t int |
b80f6443 | 13361 | _ACEOF |
f73dda09 JA |
13362 | |
13363 | fi | |
13364 | ||
0628567a | 13365 | |
f73dda09 | 13366 | |
ac50fbac CR |
13367 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t" >&5 |
13368 | $as_echo_n "checking for sig_atomic_t... " >&6; } | |
13369 | if ${bash_cv_type_sig_atomic_t+:} false; then : | |
13370 | $as_echo_n "(cached) " >&6 | |
ccc6cda3 | 13371 | else |
ac50fbac | 13372 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13373 | /* end confdefs.h. */ |
ccc6cda3 | 13374 | #include <sys/types.h> |
ac50fbac CR |
13375 | #if STDC_HEADERS |
13376 | #include <stdlib.h> | |
13377 | #include <stddef.h> | |
ccc6cda3 | 13378 | #endif |
ac50fbac CR |
13379 | #if HAVE_INTTYPES_H |
13380 | #include <inttypes.h> | |
13381 | #endif | |
13382 | #if HAVE_STDINT_H | |
13383 | #include <stdint.h> | |
13384 | #endif | |
13385 | #include <signal.h> | |
13386 | ||
f73dda09 | 13387 | _ACEOF |
ac50fbac CR |
13388 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13389 | $EGREP "sig_atomic_t" >/dev/null 2>&1; then : | |
13390 | bash_cv_type_sig_atomic_t=yes | |
ccc6cda3 | 13391 | else |
ac50fbac | 13392 | bash_cv_type_sig_atomic_t=no |
ccc6cda3 | 13393 | fi |
ac50fbac | 13394 | rm -f conftest* |
ccc6cda3 JA |
13395 | |
13396 | fi | |
13397 | ||
ac50fbac CR |
13398 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sig_atomic_t" >&5 |
13399 | $as_echo "$bash_cv_type_sig_atomic_t" >&6; } | |
ccc6cda3 | 13400 | |
ac50fbac CR |
13401 | if test $bash_cv_type_sig_atomic_t = no; then |
13402 | cat >>confdefs.h <<_ACEOF | |
13403 | #define sig_atomic_t int | |
b80f6443 | 13404 | _ACEOF |
ccc6cda3 JA |
13405 | |
13406 | fi | |
13407 | ||
b80f6443 | 13408 | |
3185942a | 13409 | |
ac50fbac CR |
13410 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for quad_t" >&5 |
13411 | $as_echo_n "checking for quad_t... " >&6; } | |
13412 | if ${bash_cv_type_quad_t+:} false; then : | |
13413 | $as_echo_n "(cached) " >&6 | |
ccc6cda3 | 13414 | else |
ac50fbac | 13415 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13416 | /* end confdefs.h. */ |
ac50fbac CR |
13417 | #include <sys/types.h> |
13418 | #if STDC_HEADERS | |
13419 | #include <stdlib.h> | |
13420 | #include <stddef.h> | |
13421 | #endif | |
13422 | #if HAVE_INTTYPES_H | |
13423 | #include <inttypes.h> | |
13424 | #endif | |
13425 | #if HAVE_STDINT_H | |
13426 | #include <stdint.h> | |
13427 | #endif | |
495aee44 | 13428 | |
495aee44 | 13429 | |
0628567a | 13430 | _ACEOF |
ac50fbac CR |
13431 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13432 | $EGREP "quad_t" >/dev/null 2>&1; then : | |
13433 | bash_cv_type_quad_t=yes | |
495aee44 | 13434 | else |
ac50fbac | 13435 | bash_cv_type_quad_t=no |
f73dda09 | 13436 | fi |
ac50fbac | 13437 | rm -f conftest* |
ccc6cda3 JA |
13438 | |
13439 | fi | |
13440 | ||
ac50fbac CR |
13441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_quad_t" >&5 |
13442 | $as_echo "$bash_cv_type_quad_t" >&6; } | |
13443 | if test $bash_cv_type_quad_t = yes; then | |
13444 | $as_echo "#define HAVE_QUAD_T 1" >>confdefs.h | |
495aee44 | 13445 | |
ac50fbac CR |
13446 | fi |
13447 | if test $bash_cv_type_quad_t = no; then | |
13448 | cat >>confdefs.h <<_ACEOF | |
13449 | #define quad_t long | |
495aee44 | 13450 | _ACEOF |
495aee44 | 13451 | |
495aee44 CR |
13452 | fi |
13453 | ||
ac50fbac CR |
13454 | |
13455 | ||
13456 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5 | |
13457 | $as_echo_n "checking for intmax_t... " >&6; } | |
13458 | if ${bash_cv_type_intmax_t+:} false; then : | |
13459 | $as_echo_n "(cached) " >&6 | |
495aee44 | 13460 | else |
ac50fbac | 13461 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
495aee44 | 13462 | /* end confdefs.h. */ |
ac50fbac CR |
13463 | #include <sys/types.h> |
13464 | #if STDC_HEADERS | |
495aee44 | 13465 | #include <stdlib.h> |
ac50fbac CR |
13466 | #include <stddef.h> |
13467 | #endif | |
13468 | #if HAVE_INTTYPES_H | |
13469 | #include <inttypes.h> | |
13470 | #endif | |
13471 | #if HAVE_STDINT_H | |
13472 | #include <stdint.h> | |
13473 | #endif | |
495aee44 | 13474 | |
495aee44 | 13475 | |
495aee44 | 13476 | _ACEOF |
ac50fbac CR |
13477 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13478 | $EGREP "intmax_t" >/dev/null 2>&1; then : | |
13479 | bash_cv_type_intmax_t=yes | |
495aee44 | 13480 | else |
ac50fbac | 13481 | bash_cv_type_intmax_t=no |
495aee44 | 13482 | fi |
ac50fbac | 13483 | rm -f conftest* |
495aee44 | 13484 | |
ac50fbac | 13485 | fi |
495aee44 | 13486 | |
ac50fbac CR |
13487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_intmax_t" >&5 |
13488 | $as_echo "$bash_cv_type_intmax_t" >&6; } | |
495aee44 | 13489 | |
ac50fbac CR |
13490 | if test $bash_cv_type_intmax_t = no; then |
13491 | cat >>confdefs.h <<_ACEOF | |
13492 | #define intmax_t $bash_cv_type_long_long | |
495aee44 CR |
13493 | _ACEOF |
13494 | ||
ac50fbac | 13495 | fi |
495aee44 CR |
13496 | |
13497 | ||
13498 | ||
ac50fbac CR |
13499 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uintmax_t" >&5 |
13500 | $as_echo_n "checking for uintmax_t... " >&6; } | |
13501 | if ${bash_cv_type_uintmax_t+:} false; then : | |
495aee44 CR |
13502 | $as_echo_n "(cached) " >&6 |
13503 | else | |
ac50fbac | 13504 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
495aee44 | 13505 | /* end confdefs.h. */ |
495aee44 | 13506 | #include <sys/types.h> |
ac50fbac CR |
13507 | #if STDC_HEADERS |
13508 | #include <stdlib.h> | |
13509 | #include <stddef.h> | |
13510 | #endif | |
13511 | #if HAVE_INTTYPES_H | |
13512 | #include <inttypes.h> | |
13513 | #endif | |
13514 | #if HAVE_STDINT_H | |
13515 | #include <stdint.h> | |
13516 | #endif | |
495aee44 CR |
13517 | |
13518 | ||
495aee44 | 13519 | _ACEOF |
ac50fbac CR |
13520 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13521 | $EGREP "uintmax_t" >/dev/null 2>&1; then : | |
13522 | bash_cv_type_uintmax_t=yes | |
495aee44 | 13523 | else |
ac50fbac CR |
13524 | bash_cv_type_uintmax_t=no |
13525 | fi | |
13526 | rm -f conftest* | |
13527 | ||
13528 | fi | |
13529 | ||
13530 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_uintmax_t" >&5 | |
13531 | $as_echo "$bash_cv_type_uintmax_t" >&6; } | |
495aee44 | 13532 | |
ac50fbac CR |
13533 | if test $bash_cv_type_uintmax_t = no; then |
13534 | cat >>confdefs.h <<_ACEOF | |
13535 | #define uintmax_t $bash_cv_type_unsigned_long_long | |
495aee44 | 13536 | _ACEOF |
495aee44 | 13537 | |
ac50fbac CR |
13538 | fi |
13539 | ||
13540 | if test "$ac_cv_header_sys_socket_h" = "yes"; then | |
495aee44 CR |
13541 | |
13542 | ||
ac50fbac CR |
13543 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 |
13544 | $as_echo_n "checking for socklen_t... " >&6; } | |
13545 | if ${bash_cv_type_socklen_t+:} false; then : | |
13546 | $as_echo_n "(cached) " >&6 | |
495aee44 | 13547 | else |
ac50fbac CR |
13548 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
13549 | /* end confdefs.h. */ | |
13550 | #include <sys/types.h> | |
13551 | #if STDC_HEADERS | |
13552 | #include <stdlib.h> | |
13553 | #include <stddef.h> | |
13554 | #endif | |
13555 | #if HAVE_INTTYPES_H | |
13556 | #include <inttypes.h> | |
13557 | #endif | |
13558 | #if HAVE_STDINT_H | |
13559 | #include <stdint.h> | |
13560 | #endif | |
13561 | #include <sys/socket.h> | |
495aee44 | 13562 | |
ac50fbac CR |
13563 | _ACEOF |
13564 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13565 | $EGREP "socklen_t" >/dev/null 2>&1; then : | |
13566 | bash_cv_type_socklen_t=yes | |
13567 | else | |
13568 | bash_cv_type_socklen_t=no | |
495aee44 | 13569 | fi |
ac50fbac | 13570 | rm -f conftest* |
495aee44 | 13571 | |
495aee44 CR |
13572 | fi |
13573 | ||
ac50fbac CR |
13574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_socklen_t" >&5 |
13575 | $as_echo "$bash_cv_type_socklen_t" >&6; } | |
13576 | if test $bash_cv_type_socklen_t = yes; then | |
13577 | $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h | |
13578 | ||
13579 | fi | |
13580 | if test $bash_cv_type_socklen_t = no; then | |
13581 | cat >>confdefs.h <<_ACEOF | |
13582 | #define socklen_t unsigned int | |
495aee44 CR |
13583 | _ACEOF |
13584 | ||
13585 | fi | |
13586 | ||
ac50fbac CR |
13587 | fi |
13588 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for size and type of struct rlimit fields" >&5 | |
13589 | $as_echo_n "checking for size and type of struct rlimit fields... " >&6; } | |
13590 | if ${bash_cv_type_rlimit+:} false; then : | |
495aee44 CR |
13591 | $as_echo_n "(cached) " >&6 |
13592 | else | |
ac50fbac | 13593 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
495aee44 | 13594 | /* end confdefs.h. */ |
495aee44 | 13595 | #include <sys/types.h> |
ac50fbac | 13596 | #include <sys/resource.h> |
495aee44 CR |
13597 | int |
13598 | main () | |
13599 | { | |
ac50fbac | 13600 | rlim_t xxx; |
495aee44 CR |
13601 | ; |
13602 | return 0; | |
13603 | } | |
13604 | _ACEOF | |
ac50fbac CR |
13605 | if ac_fn_c_try_compile "$LINENO"; then : |
13606 | bash_cv_type_rlimit=rlim_t | |
495aee44 | 13607 | else |
495aee44 | 13608 | |
ac50fbac CR |
13609 | if test "$cross_compiling" = yes; then : |
13610 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&5 | |
13611 | $as_echo "$as_me: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&2;} | |
13612 | bash_cv_type_rlimit=long | |
13613 | else | |
13614 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
495aee44 CR |
13615 | /* end confdefs.h. */ |
13616 | ||
13617 | #include <sys/types.h> | |
ac50fbac CR |
13618 | #include <sys/time.h> |
13619 | #include <sys/resource.h> | |
13620 | main() | |
495aee44 | 13621 | { |
ac50fbac CR |
13622 | #ifdef HAVE_QUAD_T |
13623 | struct rlimit rl; | |
13624 | if (sizeof(rl.rlim_cur) == sizeof(quad_t)) | |
13625 | exit(0); | |
13626 | #endif | |
13627 | exit(1); | |
495aee44 CR |
13628 | } |
13629 | _ACEOF | |
ac50fbac CR |
13630 | if ac_fn_c_try_run "$LINENO"; then : |
13631 | bash_cv_type_rlimit=quad_t | |
495aee44 | 13632 | else |
ac50fbac CR |
13633 | bash_cv_type_rlimit=long |
13634 | fi | |
13635 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
13636 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
13637 | fi | |
13638 | ||
13639 | fi | |
13640 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13641 | ||
13642 | fi | |
13643 | ||
13644 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_rlimit" >&5 | |
13645 | $as_echo "$bash_cv_type_rlimit" >&6; } | |
13646 | if test $bash_cv_type_rlimit = quad_t; then | |
13647 | $as_echo "#define RLIMTYPE quad_t" >>confdefs.h | |
13648 | ||
13649 | elif test $bash_cv_type_rlimit = rlim_t; then | |
13650 | $as_echo "#define RLIMTYPE rlim_t" >>confdefs.h | |
13651 | ||
13652 | fi | |
13653 | ||
13654 | ||
13655 | # The cast to long int works around a bug in the HP C Compiler | |
13656 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
13657 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
13658 | # This bug is HP SR number 8606223364. | |
13659 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5 | |
13660 | $as_echo_n "checking size of intmax_t... " >&6; } | |
13661 | if ${ac_cv_sizeof_intmax_t+:} false; then : | |
13662 | $as_echo_n "(cached) " >&6 | |
13663 | else | |
13664 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"; then : | |
495aee44 | 13665 | |
ac50fbac CR |
13666 | else |
13667 | if test "$ac_cv_type_intmax_t" = yes; then | |
13668 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
13669 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
13670 | as_fn_error 77 "cannot compute sizeof (intmax_t) | |
13671 | See \`config.log' for more details" "$LINENO" 5; } | |
13672 | else | |
13673 | ac_cv_sizeof_intmax_t=0 | |
13674 | fi | |
495aee44 CR |
13675 | fi |
13676 | ||
495aee44 | 13677 | fi |
ac50fbac CR |
13678 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5 |
13679 | $as_echo "$ac_cv_sizeof_intmax_t" >&6; } | |
495aee44 | 13680 | |
ac50fbac CR |
13681 | |
13682 | ||
13683 | cat >>confdefs.h <<_ACEOF | |
13684 | #define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t | |
495aee44 CR |
13685 | _ACEOF |
13686 | ||
ac50fbac CR |
13687 | |
13688 | ||
13689 | ||
13690 | ac_fn_c_check_member "$LINENO" "struct termios" "c_line" "ac_cv_member_struct_termios_c_line" " | |
13691 | #include <sys/types.h> | |
13692 | #include <termios.h> | |
13693 | ||
13694 | " | |
13695 | if test "x$ac_cv_member_struct_termios_c_line" = xyes; then : | |
13696 | $as_echo "#define TERMIOS_LDISC 1" >>confdefs.h | |
13697 | ||
13698 | fi | |
13699 | ||
13700 | ||
13701 | ||
13702 | ac_fn_c_check_member "$LINENO" "struct termio" "c_line" "ac_cv_member_struct_termio_c_line" " | |
13703 | #include <sys/types.h> | |
13704 | #include <termio.h> | |
13705 | ||
13706 | " | |
13707 | if test "x$ac_cv_member_struct_termio_c_line" = xyes; then : | |
13708 | $as_echo "#define TERMIO_LDISC 1" >>confdefs.h | |
13709 | ||
495aee44 CR |
13710 | fi |
13711 | ||
13712 | ||
13713 | ||
ac50fbac | 13714 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_ino" >&5 |
495aee44 | 13715 | $as_echo_n "checking for struct dirent.d_ino... " >&6; } |
ac50fbac | 13716 | if ${bash_cv_dirent_has_dino+:} false; then : |
495aee44 | 13717 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13718 | else |
ac50fbac | 13719 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13720 | /* end confdefs.h. */ |
ccc6cda3 JA |
13721 | |
13722 | #include <stdio.h> | |
13723 | #include <sys/types.h> | |
13724 | #ifdef HAVE_UNISTD_H | |
13725 | # include <unistd.h> | |
13726 | #endif /* HAVE_UNISTD_H */ | |
13727 | #if defined(HAVE_DIRENT_H) | |
13728 | # include <dirent.h> | |
13729 | #else | |
13730 | # define dirent direct | |
13731 | # ifdef HAVE_SYS_NDIR_H | |
13732 | # include <sys/ndir.h> | |
13733 | # endif /* SYSNDIR */ | |
13734 | # ifdef HAVE_SYS_DIR_H | |
13735 | # include <sys/dir.h> | |
13736 | # endif /* SYSDIR */ | |
13737 | # ifdef HAVE_NDIR_H | |
13738 | # include <ndir.h> | |
13739 | # endif | |
13740 | #endif /* HAVE_DIRENT_H */ | |
13741 | ||
f73dda09 JA |
13742 | int |
13743 | main () | |
13744 | { | |
ccc6cda3 JA |
13745 | |
13746 | struct dirent d; int z; z = d.d_ino; | |
13747 | ||
f73dda09 JA |
13748 | ; |
13749 | return 0; | |
13750 | } | |
13751 | _ACEOF | |
ac50fbac | 13752 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
13753 | bash_cv_dirent_has_dino=yes |
13754 | else | |
ac50fbac | 13755 | bash_cv_dirent_has_dino=no |
ccc6cda3 | 13756 | fi |
3185942a | 13757 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
13758 | fi |
13759 | ||
ac50fbac | 13760 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_dino" >&5 |
3185942a | 13761 | $as_echo "$bash_cv_dirent_has_dino" >&6; } |
ccc6cda3 | 13762 | if test $bash_cv_dirent_has_dino = yes; then |
ac50fbac | 13763 | $as_echo "#define HAVE_STRUCT_DIRENT_D_INO 1" >>confdefs.h |
ccc6cda3 JA |
13764 | |
13765 | fi | |
13766 | ||
b80f6443 | 13767 | |
ac50fbac | 13768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_fileno" >&5 |
3185942a | 13769 | $as_echo_n "checking for struct dirent.d_fileno... " >&6; } |
ac50fbac | 13770 | if ${bash_cv_dirent_has_d_fileno+:} false; then : |
3185942a | 13771 | $as_echo_n "(cached) " >&6 |
d166f048 | 13772 | else |
ac50fbac | 13773 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13774 | /* end confdefs.h. */ |
d166f048 JA |
13775 | |
13776 | #include <stdio.h> | |
13777 | #include <sys/types.h> | |
13778 | #ifdef HAVE_UNISTD_H | |
13779 | # include <unistd.h> | |
13780 | #endif /* HAVE_UNISTD_H */ | |
13781 | #if defined(HAVE_DIRENT_H) | |
13782 | # include <dirent.h> | |
13783 | #else | |
13784 | # define dirent direct | |
13785 | # ifdef HAVE_SYS_NDIR_H | |
13786 | # include <sys/ndir.h> | |
13787 | # endif /* SYSNDIR */ | |
13788 | # ifdef HAVE_SYS_DIR_H | |
13789 | # include <sys/dir.h> | |
13790 | # endif /* SYSDIR */ | |
13791 | # ifdef HAVE_NDIR_H | |
13792 | # include <ndir.h> | |
13793 | # endif | |
13794 | #endif /* HAVE_DIRENT_H */ | |
13795 | ||
f73dda09 JA |
13796 | int |
13797 | main () | |
13798 | { | |
d166f048 JA |
13799 | |
13800 | struct dirent d; int z; z = d.d_fileno; | |
13801 | ||
f73dda09 JA |
13802 | ; |
13803 | return 0; | |
13804 | } | |
13805 | _ACEOF | |
ac50fbac | 13806 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
13807 | bash_cv_dirent_has_d_fileno=yes |
13808 | else | |
ac50fbac | 13809 | bash_cv_dirent_has_d_fileno=no |
d166f048 | 13810 | fi |
3185942a | 13811 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13812 | fi |
13813 | ||
ac50fbac | 13814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_fileno" >&5 |
3185942a | 13815 | $as_echo "$bash_cv_dirent_has_d_fileno" >&6; } |
d166f048 | 13816 | if test $bash_cv_dirent_has_d_fileno = yes; then |
ac50fbac | 13817 | $as_echo "#define HAVE_STRUCT_DIRENT_D_FILENO 1" >>confdefs.h |
b80f6443 JA |
13818 | |
13819 | fi | |
13820 | ||
13821 | ||
ac50fbac | 13822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_namlen" >&5 |
3185942a | 13823 | $as_echo_n "checking for struct dirent.d_namlen... " >&6; } |
ac50fbac | 13824 | if ${bash_cv_dirent_has_d_namlen+:} false; then : |
3185942a | 13825 | $as_echo_n "(cached) " >&6 |
b80f6443 | 13826 | else |
ac50fbac | 13827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13828 | /* end confdefs.h. */ |
b80f6443 JA |
13829 | |
13830 | #include <stdio.h> | |
13831 | #include <sys/types.h> | |
13832 | #ifdef HAVE_UNISTD_H | |
13833 | # include <unistd.h> | |
13834 | #endif /* HAVE_UNISTD_H */ | |
13835 | #if defined(HAVE_DIRENT_H) | |
13836 | # include <dirent.h> | |
13837 | #else | |
13838 | # define dirent direct | |
13839 | # ifdef HAVE_SYS_NDIR_H | |
13840 | # include <sys/ndir.h> | |
13841 | # endif /* SYSNDIR */ | |
13842 | # ifdef HAVE_SYS_DIR_H | |
13843 | # include <sys/dir.h> | |
13844 | # endif /* SYSDIR */ | |
13845 | # ifdef HAVE_NDIR_H | |
13846 | # include <ndir.h> | |
13847 | # endif | |
13848 | #endif /* HAVE_DIRENT_H */ | |
13849 | ||
13850 | int | |
13851 | main () | |
13852 | { | |
13853 | ||
13854 | struct dirent d; int z; z = d.d_namlen; | |
13855 | ||
13856 | ; | |
13857 | return 0; | |
13858 | } | |
13859 | _ACEOF | |
ac50fbac | 13860 | if ac_fn_c_try_compile "$LINENO"; then : |
b80f6443 JA |
13861 | bash_cv_dirent_has_d_namlen=yes |
13862 | else | |
ac50fbac | 13863 | bash_cv_dirent_has_d_namlen=no |
d166f048 | 13864 | fi |
3185942a | 13865 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b80f6443 JA |
13866 | fi |
13867 | ||
ac50fbac | 13868 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_namlen" >&5 |
3185942a | 13869 | $as_echo "$bash_cv_dirent_has_d_namlen" >&6; } |
b80f6443 | 13870 | if test $bash_cv_dirent_has_d_namlen = yes; then |
ac50fbac | 13871 | $as_echo "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" >>confdefs.h |
d166f048 | 13872 | |
b80f6443 JA |
13873 | fi |
13874 | ||
ac50fbac | 13875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct winsize in sys/ioctl.h and termios.h" >&5 |
3185942a | 13876 | $as_echo_n "checking for struct winsize in sys/ioctl.h and termios.h... " >&6; } |
ac50fbac | 13877 | if ${bash_cv_struct_winsize_header+:} false; then : |
3185942a | 13878 | $as_echo_n "(cached) " >&6 |
d166f048 | 13879 | else |
ac50fbac | 13880 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13881 | /* end confdefs.h. */ |
d166f048 JA |
13882 | #include <sys/types.h> |
13883 | #include <sys/ioctl.h> | |
f73dda09 JA |
13884 | int |
13885 | main () | |
13886 | { | |
d166f048 | 13887 | struct winsize x; |
f73dda09 JA |
13888 | ; |
13889 | return 0; | |
13890 | } | |
13891 | _ACEOF | |
ac50fbac | 13892 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc JA |
13893 | bash_cv_struct_winsize_header=ioctl_h |
13894 | else | |
ac50fbac | 13895 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 13896 | /* end confdefs.h. */ |
cce855bc JA |
13897 | #include <sys/types.h> |
13898 | #include <termios.h> | |
f73dda09 JA |
13899 | int |
13900 | main () | |
13901 | { | |
cce855bc | 13902 | struct winsize x; |
f73dda09 JA |
13903 | ; |
13904 | return 0; | |
13905 | } | |
13906 | _ACEOF | |
ac50fbac | 13907 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc | 13908 | bash_cv_struct_winsize_header=termios_h |
d166f048 | 13909 | else |
ac50fbac | 13910 | bash_cv_struct_winsize_header=other |
cce855bc | 13911 | fi |
3185942a | 13912 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
cce855bc | 13913 | |
d166f048 | 13914 | fi |
3185942a | 13915 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13916 | fi |
13917 | ||
cce855bc | 13918 | if test $bash_cv_struct_winsize_header = ioctl_h; then |
ac50fbac | 13919 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: sys/ioctl.h" >&5 |
3185942a | 13920 | $as_echo "sys/ioctl.h" >&6; } |
ac50fbac | 13921 | $as_echo "#define STRUCT_WINSIZE_IN_SYS_IOCTL 1" >>confdefs.h |
d166f048 | 13922 | |
cce855bc | 13923 | elif test $bash_cv_struct_winsize_header = termios_h; then |
ac50fbac | 13924 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: termios.h" >&5 |
3185942a | 13925 | $as_echo "termios.h" >&6; } |
ac50fbac | 13926 | $as_echo "#define STRUCT_WINSIZE_IN_TERMIOS 1" >>confdefs.h |
d166f048 | 13927 | |
0628567a | 13928 | else |
ac50fbac CR |
13929 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 |
13930 | $as_echo "not found" >&6; } | |
13931 | fi | |
0628567a | 13932 | |
ac50fbac CR |
13933 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval in sys/time.h and time.h" >&5 |
13934 | $as_echo_n "checking for struct timeval in sys/time.h and time.h... " >&6; } | |
13935 | if ${bash_cv_struct_timeval+:} false; then : | |
13936 | $as_echo_n "(cached) " >&6 | |
13937 | else | |
13938 | ||
13939 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
0628567a | 13940 | /* end confdefs.h. */ |
ac50fbac | 13941 | #include <sys/time.h> |
0628567a | 13942 | |
ac50fbac CR |
13943 | _ACEOF |
13944 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13945 | $EGREP "struct timeval" >/dev/null 2>&1; then : | |
13946 | bash_cv_struct_timeval=yes | |
13947 | else | |
13948 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13949 | /* end confdefs.h. */ | |
13950 | #include <time.h> | |
0628567a | 13951 | |
0628567a | 13952 | _ACEOF |
ac50fbac CR |
13953 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13954 | $EGREP "struct timeval" >/dev/null 2>&1; then : | |
13955 | bash_cv_struct_timeval=yes | |
b80f6443 | 13956 | else |
ac50fbac CR |
13957 | bash_cv_struct_timeval=no |
13958 | fi | |
13959 | rm -f conftest* | |
0628567a | 13960 | |
7117c2d2 | 13961 | fi |
ac50fbac CR |
13962 | rm -f conftest* |
13963 | ||
3185942a | 13964 | |
0628567a | 13965 | fi |
3185942a | 13966 | |
ac50fbac CR |
13967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timeval" >&5 |
13968 | $as_echo "$bash_cv_struct_timeval" >&6; } | |
13969 | if test $bash_cv_struct_timeval = yes; then | |
13970 | $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h | |
13971 | ||
7117c2d2 | 13972 | fi |
ac50fbac CR |
13973 | |
13974 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" | |
13975 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : | |
7117c2d2 | 13976 | |
b80f6443 | 13977 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 13978 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
b80f6443 JA |
13979 | _ACEOF |
13980 | ||
7117c2d2 JA |
13981 | |
13982 | fi | |
13983 | ||
ac50fbac CR |
13984 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
13985 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } | |
13986 | if ${ac_cv_struct_tm+:} false; then : | |
3185942a JA |
13987 | $as_echo_n "(cached) " >&6 |
13988 | else | |
ac50fbac | 13989 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3185942a | 13990 | /* end confdefs.h. */ |
ac50fbac | 13991 | #include <sys/types.h> |
3185942a JA |
13992 | #include <time.h> |
13993 | ||
13994 | int | |
13995 | main () | |
13996 | { | |
ac50fbac CR |
13997 | struct tm tm; |
13998 | int *p = &tm.tm_sec; | |
13999 | return !p; | |
3185942a JA |
14000 | ; |
14001 | return 0; | |
14002 | } | |
14003 | _ACEOF | |
ac50fbac CR |
14004 | if ac_fn_c_try_compile "$LINENO"; then : |
14005 | ac_cv_struct_tm=time.h | |
3185942a | 14006 | else |
ac50fbac | 14007 | ac_cv_struct_tm=sys/time.h |
3185942a | 14008 | fi |
3185942a JA |
14009 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
14010 | fi | |
ac50fbac CR |
14011 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
14012 | $as_echo "$ac_cv_struct_tm" >&6; } | |
14013 | if test $ac_cv_struct_tm = sys/time.h; then | |
14014 | ||
14015 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h | |
14016 | ||
14017 | fi | |
14018 | ||
14019 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> | |
14020 | #include <$ac_cv_struct_tm> | |
14021 | ||
14022 | " | |
14023 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : | |
3185942a JA |
14024 | |
14025 | cat >>confdefs.h <<_ACEOF | |
ac50fbac | 14026 | #define HAVE_STRUCT_TM_TM_ZONE 1 |
3185942a JA |
14027 | _ACEOF |
14028 | ||
14029 | ||
ac50fbac | 14030 | fi |
3185942a | 14031 | |
ac50fbac CR |
14032 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
14033 | ||
14034 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h | |
3185942a | 14035 | |
ac50fbac CR |
14036 | else |
14037 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> | |
14038 | " | |
14039 | if test "x$ac_cv_have_decl_tzname" = xyes; then : | |
14040 | ac_have_decl=1 | |
14041 | else | |
14042 | ac_have_decl=0 | |
3185942a JA |
14043 | fi |
14044 | ||
ac50fbac CR |
14045 | cat >>confdefs.h <<_ACEOF |
14046 | #define HAVE_DECL_TZNAME $ac_have_decl | |
14047 | _ACEOF | |
3185942a | 14048 | |
ac50fbac | 14049 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
3185942a | 14050 | $as_echo_n "checking for tzname... " >&6; } |
ac50fbac | 14051 | if ${ac_cv_var_tzname+:} false; then : |
3185942a | 14052 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14053 | else |
ac50fbac | 14054 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14055 | /* end confdefs.h. */ |
7117c2d2 | 14056 | #include <time.h> |
3185942a JA |
14057 | #if !HAVE_DECL_TZNAME |
14058 | extern char *tzname[]; | |
7117c2d2 JA |
14059 | #endif |
14060 | ||
14061 | int | |
14062 | main () | |
14063 | { | |
3185942a | 14064 | return tzname[0][0]; |
7117c2d2 JA |
14065 | ; |
14066 | return 0; | |
14067 | } | |
14068 | _ACEOF | |
ac50fbac | 14069 | if ac_fn_c_try_link "$LINENO"; then : |
7117c2d2 JA |
14070 | ac_cv_var_tzname=yes |
14071 | else | |
ac50fbac | 14072 | ac_cv_var_tzname=no |
7117c2d2 | 14073 | fi |
ac50fbac CR |
14074 | rm -f core conftest.err conftest.$ac_objext \ |
14075 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 14076 | fi |
ac50fbac | 14077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
3185942a | 14078 | $as_echo "$ac_cv_var_tzname" >&6; } |
7117c2d2 JA |
14079 | if test $ac_cv_var_tzname = yes; then |
14080 | ||
ac50fbac | 14081 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
7117c2d2 JA |
14082 | |
14083 | fi | |
14084 | fi | |
14085 | ||
ac50fbac | 14086 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timezone in sys/time.h and time.h" >&5 |
3185942a | 14087 | $as_echo_n "checking for struct timezone in sys/time.h and time.h... " >&6; } |
ac50fbac | 14088 | if ${bash_cv_struct_timezone+:} false; then : |
3185942a | 14089 | $as_echo_n "(cached) " >&6 |
b80f6443 JA |
14090 | else |
14091 | ||
ac50fbac | 14092 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14093 | /* end confdefs.h. */ |
b80f6443 JA |
14094 | #include <sys/time.h> |
14095 | ||
14096 | _ACEOF | |
14097 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 14098 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
b80f6443 JA |
14099 | bash_cv_struct_timezone=yes |
14100 | else | |
ac50fbac | 14101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14102 | /* end confdefs.h. */ |
b80f6443 JA |
14103 | #include <time.h> |
14104 | ||
14105 | _ACEOF | |
14106 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 14107 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
b80f6443 JA |
14108 | bash_cv_struct_timezone=yes |
14109 | else | |
14110 | bash_cv_struct_timezone=no | |
14111 | fi | |
14112 | rm -f conftest* | |
14113 | ||
14114 | fi | |
14115 | rm -f conftest* | |
14116 | ||
14117 | ||
14118 | fi | |
14119 | ||
ac50fbac | 14120 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timezone" >&5 |
3185942a | 14121 | $as_echo "$bash_cv_struct_timezone" >&6; } |
b80f6443 | 14122 | if test $bash_cv_struct_timezone = yes; then |
ac50fbac | 14123 | $as_echo "#define HAVE_STRUCT_TIMEZONE 1" >>confdefs.h |
b80f6443 JA |
14124 | |
14125 | fi | |
14126 | ||
14127 | ||
ac50fbac | 14128 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for offset of exit status in return status from wait" >&5 |
495aee44 | 14129 | $as_echo_n "checking for offset of exit status in return status from wait... " >&6; } |
ac50fbac | 14130 | if ${bash_cv_wexitstatus_offset+:} false; then : |
495aee44 CR |
14131 | $as_echo_n "(cached) " >&6 |
14132 | else | |
ac50fbac CR |
14133 | if test "$cross_compiling" = yes; then : |
14134 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&5 | |
495aee44 CR |
14135 | $as_echo "$as_me: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&2;} |
14136 | bash_cv_wexitstatus_offset=0 | |
14137 | ||
14138 | else | |
ac50fbac CR |
14139 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
14140 | /* end confdefs.h. */ | |
495aee44 CR |
14141 | |
14142 | #include <stdlib.h> | |
14143 | #include <unistd.h> | |
14144 | ||
14145 | #include <sys/wait.h> | |
14146 | ||
14147 | main(c, v) | |
14148 | int c; | |
14149 | char **v; | |
14150 | { | |
14151 | pid_t pid, p; | |
14152 | int s, i, n; | |
14153 | ||
14154 | s = 0; | |
14155 | pid = fork(); | |
14156 | if (pid == 0) | |
14157 | exit (42); | |
14158 | ||
14159 | /* wait for the process */ | |
14160 | p = wait(&s); | |
14161 | if (p != pid) | |
14162 | exit (255); | |
14163 | ||
14164 | /* crack s */ | |
14165 | for (i = 0; i < (sizeof(s) - 8); i++) | |
14166 | { | |
14167 | n = (s >> i) & 0xff; | |
14168 | if (n == 42) | |
14169 | exit (i); | |
14170 | } | |
14171 | ||
14172 | exit (254); | |
14173 | } | |
14174 | ||
14175 | _ACEOF | |
ac50fbac | 14176 | if ac_fn_c_try_run "$LINENO"; then : |
495aee44 CR |
14177 | bash_cv_wexitstatus_offset=0 |
14178 | else | |
ac50fbac CR |
14179 | bash_cv_wexitstatus_offset=$? |
14180 | fi | |
14181 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
14182 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
14183 | fi | |
14184 | ||
14185 | fi | |
14186 | ||
14187 | if test "$bash_cv_wexitstatus_offset" -gt 32 ; then | |
14188 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: bad exit status from test program -- defaulting to 0" >&5 | |
14189 | $as_echo "$as_me: WARNING: bad exit status from test program -- defaulting to 0" >&2;} | |
14190 | bash_cv_wexitstatus_offset=0 | |
14191 | fi | |
14192 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wexitstatus_offset" >&5 | |
14193 | $as_echo "$bash_cv_wexitstatus_offset" >&6; } | |
14194 | ||
14195 | cat >>confdefs.h <<_ACEOF | |
14196 | #define WEXITSTATUS_OFFSET $bash_cv_wexitstatus_offset | |
14197 | _ACEOF | |
14198 | ||
14199 | ||
14200 | ||
14201 | ||
14202 | ||
14203 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5 | |
14204 | $as_echo_n "checking for struct timespec in <time.h>... " >&6; } | |
14205 | if ${bash_cv_sys_struct_timespec_in_time_h+:} false; then : | |
14206 | $as_echo_n "(cached) " >&6 | |
14207 | else | |
14208 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14209 | /* end confdefs.h. */ | |
14210 | #include <time.h> | |
14211 | ||
14212 | int | |
14213 | main () | |
14214 | { | |
14215 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
14216 | ; | |
14217 | return 0; | |
14218 | } | |
14219 | _ACEOF | |
14220 | if ac_fn_c_try_compile "$LINENO"; then : | |
14221 | bash_cv_sys_struct_timespec_in_time_h=yes | |
14222 | else | |
14223 | bash_cv_sys_struct_timespec_in_time_h=no | |
14224 | fi | |
14225 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14226 | fi | |
14227 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_time_h" >&5 | |
14228 | $as_echo "$bash_cv_sys_struct_timespec_in_time_h" >&6; } | |
14229 | ||
14230 | HAVE_STRUCT_TIMESPEC=0 | |
14231 | TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
14232 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
14233 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0 | |
14234 | if test $bash_cv_sys_struct_timespec_in_time_h = yes; then | |
14235 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
14236 | ||
14237 | $as_echo "#define TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
14238 | ||
14239 | TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
14240 | else | |
14241 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5 | |
14242 | $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; } | |
14243 | if ${bash_cv_sys_struct_timespec_in_sys_time_h+:} false; then : | |
14244 | $as_echo_n "(cached) " >&6 | |
14245 | else | |
14246 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14247 | /* end confdefs.h. */ | |
14248 | #include <sys/time.h> | |
14249 | ||
14250 | int | |
14251 | main () | |
14252 | { | |
14253 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
14254 | ; | |
14255 | return 0; | |
14256 | } | |
14257 | _ACEOF | |
14258 | if ac_fn_c_try_compile "$LINENO"; then : | |
14259 | bash_cv_sys_struct_timespec_in_sys_time_h=yes | |
14260 | else | |
14261 | bash_cv_sys_struct_timespec_in_sys_time_h=no | |
14262 | fi | |
14263 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14264 | fi | |
14265 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_sys_time_h" >&5 | |
14266 | $as_echo "$bash_cv_sys_struct_timespec_in_sys_time_h" >&6; } | |
14267 | if test $bash_cv_sys_struct_timespec_in_sys_time_h = yes; then | |
14268 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
14269 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
14270 | ||
14271 | $as_echo "#define SYS_TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
14272 | ||
14273 | else | |
14274 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5 | |
14275 | $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; } | |
14276 | if ${bash_cv_sys_struct_timespec_in_pthread_h+:} false; then : | |
14277 | $as_echo_n "(cached) " >&6 | |
14278 | else | |
14279 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14280 | /* end confdefs.h. */ | |
14281 | #include <pthread.h> | |
14282 | ||
14283 | int | |
14284 | main () | |
14285 | { | |
14286 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
14287 | ; | |
14288 | return 0; | |
14289 | } | |
14290 | _ACEOF | |
14291 | if ac_fn_c_try_compile "$LINENO"; then : | |
14292 | bash_cv_sys_struct_timespec_in_pthread_h=yes | |
14293 | else | |
14294 | bash_cv_sys_struct_timespec_in_pthread_h=no | |
14295 | fi | |
14296 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14297 | fi | |
14298 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_pthread_h" >&5 | |
14299 | $as_echo "$bash_cv_sys_struct_timespec_in_pthread_h" >&6; } | |
14300 | if test $bash_cv_sys_struct_timespec_in_pthread_h = yes; then | |
14301 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 | |
14302 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
14303 | ||
14304 | $as_echo "#define PTHREAD_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
14305 | ||
14306 | fi | |
14307 | fi | |
14308 | fi | |
14309 | ||
14310 | ||
14311 | ||
14312 | ||
14313 | ||
14314 | ||
14315 | ||
14316 | ||
14317 | ||
14318 | 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> | |
14319 | #include <sys/stat.h> | |
14320 | " | |
14321 | if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then : | |
14322 | ||
14323 | cat >>confdefs.h <<_ACEOF | |
14324 | #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1 | |
14325 | _ACEOF | |
14326 | ||
14327 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5 | |
14328 | $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; } | |
14329 | if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then : | |
14330 | $as_echo_n "(cached) " >&6 | |
14331 | else | |
14332 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14333 | /* end confdefs.h. */ | |
14334 | ||
14335 | #include <sys/types.h> | |
14336 | #include <sys/stat.h> | |
14337 | #if HAVE_SYS_TIME_H | |
14338 | # include <sys/time.h> | |
14339 | #endif | |
14340 | #include <time.h> | |
14341 | struct timespec ts; | |
14342 | struct stat st; | |
14343 | ||
14344 | int | |
14345 | main () | |
14346 | { | |
14347 | ||
14348 | st.st_atim = ts; | |
14349 | ||
14350 | ; | |
14351 | return 0; | |
14352 | } | |
14353 | _ACEOF | |
14354 | if ac_fn_c_try_compile "$LINENO"; then : | |
14355 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes | |
14356 | else | |
14357 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no | |
14358 | fi | |
14359 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14360 | fi | |
14361 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5 | |
14362 | $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; } | |
14363 | if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then | |
14364 | ||
14365 | $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h | |
14366 | ||
14367 | fi | |
14368 | else | |
14369 | 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> | |
14370 | #include <sys/stat.h> | |
14371 | " | |
14372 | if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then : | |
14373 | ||
14374 | cat >>confdefs.h <<_ACEOF | |
14375 | #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1 | |
14376 | _ACEOF | |
14377 | ||
14378 | ||
14379 | else | |
14380 | ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h> | |
14381 | #include <sys/stat.h> | |
14382 | " | |
14383 | if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then : | |
14384 | ||
14385 | cat >>confdefs.h <<_ACEOF | |
14386 | #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1 | |
14387 | _ACEOF | |
14388 | ||
14389 | ||
14390 | else | |
14391 | 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> | |
14392 | #include <sys/stat.h> | |
14393 | " | |
14394 | if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then : | |
495aee44 | 14395 | |
ac50fbac CR |
14396 | cat >>confdefs.h <<_ACEOF |
14397 | #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1 | |
14398 | _ACEOF | |
495aee44 CR |
14399 | |
14400 | ||
14401 | fi | |
14402 | ||
495aee44 | 14403 | fi |
495aee44 | 14404 | |
ac50fbac CR |
14405 | fi |
14406 | ||
14407 | fi | |
495aee44 CR |
14408 | |
14409 | ||
14410 | ||
ac50fbac | 14411 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the existence of strsignal" >&5 |
3185942a | 14412 | $as_echo_n "checking for the existence of strsignal... " >&6; } |
ac50fbac | 14413 | if ${bash_cv_have_strsignal+:} false; then : |
3185942a | 14414 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14415 | else |
ac50fbac | 14416 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14417 | /* end confdefs.h. */ |
ccc6cda3 JA |
14418 | #include <sys/types.h> |
14419 | #include <signal.h> | |
f73dda09 JA |
14420 | int |
14421 | main () | |
14422 | { | |
ccc6cda3 | 14423 | char *s = (char *)strsignal(2); |
f73dda09 JA |
14424 | ; |
14425 | return 0; | |
14426 | } | |
14427 | _ACEOF | |
ac50fbac | 14428 | if ac_fn_c_try_link "$LINENO"; then : |
ccc6cda3 JA |
14429 | bash_cv_have_strsignal=yes |
14430 | else | |
ac50fbac | 14431 | bash_cv_have_strsignal=no |
ccc6cda3 | 14432 | fi |
ac50fbac CR |
14433 | rm -f core conftest.err conftest.$ac_objext \ |
14434 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 JA |
14435 | fi |
14436 | ||
ac50fbac | 14437 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_strsignal" >&5 |
3185942a | 14438 | $as_echo "$bash_cv_have_strsignal" >&6; } |
ccc6cda3 | 14439 | if test $bash_cv_have_strsignal = yes; then |
ac50fbac | 14440 | $as_echo "#define HAVE_STRSIGNAL 1" >>confdefs.h |
ccc6cda3 JA |
14441 | |
14442 | fi | |
14443 | ||
ac50fbac | 14444 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if opendir() opens non-directories" >&5 |
3185942a | 14445 | $as_echo_n "checking if opendir() opens non-directories... " >&6; } |
ac50fbac | 14446 | if ${bash_cv_opendir_not_robust+:} false; then : |
3185942a | 14447 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14448 | else |
ac50fbac CR |
14449 | if test "$cross_compiling" = yes; then : |
14450 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&5 | |
3185942a | 14451 | $as_echo "$as_me: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14452 | bash_cv_opendir_not_robust=no |
14453 | ||
ccc6cda3 | 14454 | else |
ac50fbac | 14455 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14456 | /* end confdefs.h. */ |
ccc6cda3 JA |
14457 | |
14458 | #include <stdio.h> | |
14459 | #include <sys/types.h> | |
14460 | #include <fcntl.h> | |
14461 | #ifdef HAVE_UNISTD_H | |
14462 | # include <unistd.h> | |
14463 | #endif /* HAVE_UNISTD_H */ | |
14464 | #if defined(HAVE_DIRENT_H) | |
14465 | # include <dirent.h> | |
14466 | #else | |
14467 | # define dirent direct | |
14468 | # ifdef HAVE_SYS_NDIR_H | |
14469 | # include <sys/ndir.h> | |
14470 | # endif /* SYSNDIR */ | |
14471 | # ifdef HAVE_SYS_DIR_H | |
14472 | # include <sys/dir.h> | |
14473 | # endif /* SYSDIR */ | |
14474 | # ifdef HAVE_NDIR_H | |
14475 | # include <ndir.h> | |
14476 | # endif | |
14477 | #endif /* HAVE_DIRENT_H */ | |
14478 | main() | |
14479 | { | |
14480 | DIR *dir; | |
bb70624e | 14481 | int fd, err; |
3185942a | 14482 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
14483 | if (err < 0) { |
14484 | perror("mkdir"); | |
14485 | exit(1); | |
14486 | } | |
3185942a JA |
14487 | unlink("bash-aclocal/not_a_directory"); |
14488 | fd = open("bash-aclocal/not_a_directory", O_WRONLY|O_CREAT|O_EXCL, 0666); | |
ccc6cda3 JA |
14489 | write(fd, "\n", 1); |
14490 | close(fd); | |
3185942a JA |
14491 | dir = opendir("bash-aclocal/not_a_directory"); |
14492 | unlink("bash-aclocal/not_a_directory"); | |
14493 | rmdir("bash-aclocal"); | |
ccc6cda3 JA |
14494 | exit (dir == 0); |
14495 | } | |
f73dda09 | 14496 | _ACEOF |
ac50fbac | 14497 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14498 | bash_cv_opendir_not_robust=yes |
14499 | else | |
ac50fbac | 14500 | bash_cv_opendir_not_robust=no |
ccc6cda3 | 14501 | fi |
ac50fbac CR |
14502 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14503 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14504 | fi |
3185942a | 14505 | |
ccc6cda3 JA |
14506 | fi |
14507 | ||
ac50fbac | 14508 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_opendir_not_robust" >&5 |
3185942a | 14509 | $as_echo "$bash_cv_opendir_not_robust" >&6; } |
ccc6cda3 | 14510 | if test $bash_cv_opendir_not_robust = yes; then |
ac50fbac | 14511 | $as_echo "#define OPENDIR_NOT_ROBUST 1" >>confdefs.h |
ccc6cda3 JA |
14512 | |
14513 | fi | |
14514 | ||
ac50fbac | 14515 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ulimit can substitute for getdtablesize" >&5 |
3185942a | 14516 | $as_echo_n "checking whether ulimit can substitute for getdtablesize... " >&6; } |
ac50fbac | 14517 | if ${bash_cv_ulimit_maxfds+:} false; then : |
3185942a | 14518 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14519 | else |
ac50fbac CR |
14520 | if test "$cross_compiling" = yes; then : |
14521 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&5 | |
3185942a | 14522 | $as_echo "$as_me: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14523 | bash_cv_ulimit_maxfds=no |
14524 | ||
ccc6cda3 | 14525 | else |
ac50fbac | 14526 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14527 | /* end confdefs.h. */ |
ccc6cda3 JA |
14528 | |
14529 | main() | |
14530 | { | |
14531 | long maxfds = ulimit(4, 0L); | |
14532 | exit (maxfds == -1L); | |
14533 | } | |
14534 | ||
f73dda09 | 14535 | _ACEOF |
ac50fbac | 14536 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14537 | bash_cv_ulimit_maxfds=yes |
14538 | else | |
ac50fbac | 14539 | bash_cv_ulimit_maxfds=no |
3185942a | 14540 | fi |
ac50fbac CR |
14541 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14542 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
3185942a JA |
14543 | fi |
14544 | ||
3185942a JA |
14545 | fi |
14546 | ||
ac50fbac | 14547 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_ulimit_maxfds" >&5 |
3185942a JA |
14548 | $as_echo "$bash_cv_ulimit_maxfds" >&6; } |
14549 | if test $bash_cv_ulimit_maxfds = yes; then | |
ac50fbac | 14550 | $as_echo "#define ULIMIT_MAXFDS 1" >>confdefs.h |
3185942a JA |
14551 | |
14552 | fi | |
14553 | ||
14554 | ||
14555 | ||
14556 | ||
14557 | ||
14558 | ||
14559 | ||
14560 | ||
ac50fbac CR |
14561 | ac_fn_c_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h> |
14562 | " | |
14563 | if test "x$ac_cv_have_decl_fpurge" = xyes; then : | |
14564 | ac_have_decl=1 | |
3185942a | 14565 | else |
ac50fbac | 14566 | ac_have_decl=0 |
ccc6cda3 JA |
14567 | fi |
14568 | ||
3185942a | 14569 | cat >>confdefs.h <<_ACEOF |
ac50fbac | 14570 | #define HAVE_DECL_FPURGE $ac_have_decl |
b80f6443 | 14571 | _ACEOF |
ccc6cda3 | 14572 | |
3185942a | 14573 | |
ac50fbac | 14574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if getenv can be redefined" >&5 |
3185942a | 14575 | $as_echo_n "checking to see if getenv can be redefined... " >&6; } |
ac50fbac | 14576 | if ${bash_cv_getenv_redef+:} false; then : |
3185942a | 14577 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14578 | else |
ac50fbac CR |
14579 | if test "$cross_compiling" = yes; then : |
14580 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&5 | |
3185942a | 14581 | $as_echo "$as_me: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&2;} |
cce855bc JA |
14582 | bash_cv_getenv_redef=yes |
14583 | ||
ccc6cda3 | 14584 | else |
ac50fbac | 14585 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14586 | /* end confdefs.h. */ |
ccc6cda3 JA |
14587 | |
14588 | #ifdef HAVE_UNISTD_H | |
14589 | # include <unistd.h> | |
14590 | #endif | |
14591 | #ifndef __STDC__ | |
14592 | # ifndef const | |
14593 | # define const | |
14594 | # endif | |
14595 | #endif | |
14596 | char * | |
14597 | getenv (name) | |
14598 | #if defined (__linux__) || defined (__bsdi__) || defined (convex) | |
14599 | const char *name; | |
14600 | #else | |
14601 | char const *name; | |
14602 | #endif /* !__linux__ && !__bsdi__ && !convex */ | |
14603 | { | |
14604 | return "42"; | |
14605 | } | |
14606 | main() | |
14607 | { | |
14608 | char *s; | |
14609 | /* The next allows this program to run, but does not allow bash to link | |
14610 | when it redefines getenv. I'm not really interested in figuring out | |
14611 | why not. */ | |
14612 | #if defined (NeXT) | |
14613 | exit(1); | |
14614 | #endif | |
14615 | s = getenv("ABCDE"); | |
14616 | exit(s == 0); /* force optimizer to leave getenv in */ | |
14617 | } | |
14618 | ||
f73dda09 | 14619 | _ACEOF |
ac50fbac | 14620 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14621 | bash_cv_getenv_redef=yes |
14622 | else | |
ac50fbac | 14623 | bash_cv_getenv_redef=no |
ccc6cda3 | 14624 | fi |
ac50fbac CR |
14625 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14626 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14627 | fi |
3185942a | 14628 | |
ccc6cda3 JA |
14629 | fi |
14630 | ||
ac50fbac | 14631 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getenv_redef" >&5 |
3185942a | 14632 | $as_echo "$bash_cv_getenv_redef" >&6; } |
ccc6cda3 | 14633 | if test $bash_cv_getenv_redef = yes; then |
ac50fbac | 14634 | $as_echo "#define CAN_REDEFINE_GETENV 1" >>confdefs.h |
ccc6cda3 JA |
14635 | |
14636 | fi | |
14637 | ||
7117c2d2 | 14638 | if test "$ac_cv_func_getcwd" = "yes"; then |
ac50fbac | 14639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getcwd() will dynamically allocate memory with 0 size" >&5 |
3185942a | 14640 | $as_echo_n "checking if getcwd() will dynamically allocate memory with 0 size... " >&6; } |
ac50fbac | 14641 | if ${bash_cv_getcwd_malloc+:} false; then : |
3185942a | 14642 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14643 | else |
ac50fbac CR |
14644 | if test "$cross_compiling" = yes; then : |
14645 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&5 | |
3185942a | 14646 | $as_echo "$as_me: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&2;} |
b80f6443 | 14647 | bash_cv_getcwd_malloc=no |
cce855bc | 14648 | |
ccc6cda3 | 14649 | else |
ac50fbac | 14650 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14651 | /* end confdefs.h. */ |
ccc6cda3 JA |
14652 | |
14653 | #include <stdio.h> | |
14654 | #ifdef HAVE_UNISTD_H | |
14655 | #include <unistd.h> | |
14656 | #endif | |
14657 | ||
ccc6cda3 JA |
14658 | main() |
14659 | { | |
b80f6443 JA |
14660 | char *xpwd; |
14661 | xpwd = getcwd(0, 0); | |
14662 | exit (xpwd == 0); | |
ccc6cda3 JA |
14663 | } |
14664 | ||
f73dda09 | 14665 | _ACEOF |
ac50fbac | 14666 | if ac_fn_c_try_run "$LINENO"; then : |
b80f6443 | 14667 | bash_cv_getcwd_malloc=yes |
ccc6cda3 | 14668 | else |
ac50fbac | 14669 | bash_cv_getcwd_malloc=no |
ccc6cda3 | 14670 | fi |
ac50fbac CR |
14671 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14672 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14673 | fi |
3185942a | 14674 | |
ccc6cda3 JA |
14675 | fi |
14676 | ||
ac50fbac | 14677 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getcwd_malloc" >&5 |
3185942a | 14678 | $as_echo "$bash_cv_getcwd_malloc" >&6; } |
b80f6443 | 14679 | if test $bash_cv_getcwd_malloc = no; then |
ac50fbac | 14680 | $as_echo "#define GETCWD_BROKEN 1" >>confdefs.h |
ccc6cda3 | 14681 | |
3185942a | 14682 | case " $LIBOBJS " in |
0628567a | 14683 | *" getcwd.$ac_objext "* ) ;; |
3185942a JA |
14684 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
14685 | ;; | |
0628567a JA |
14686 | esac |
14687 | ||
ccc6cda3 JA |
14688 | fi |
14689 | ||
ccc6cda3 JA |
14690 | fi |
14691 | ||
ac50fbac | 14692 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5 |
3185942a | 14693 | $as_echo_n "checking for presence of POSIX-style sigsetjmp/siglongjmp... " >&6; } |
ac50fbac | 14694 | if ${bash_cv_func_sigsetjmp+:} false; then : |
3185942a | 14695 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14696 | else |
ac50fbac CR |
14697 | if test "$cross_compiling" = yes; then : |
14698 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&5 | |
3185942a | 14699 | $as_echo "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
14700 | bash_cv_func_sigsetjmp=missing |
14701 | ||
ccc6cda3 | 14702 | else |
ac50fbac | 14703 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14704 | /* end confdefs.h. */ |
ccc6cda3 JA |
14705 | |
14706 | #ifdef HAVE_UNISTD_H | |
14707 | #include <unistd.h> | |
14708 | #endif | |
14709 | #include <sys/types.h> | |
14710 | #include <signal.h> | |
14711 | #include <setjmp.h> | |
14712 | ||
14713 | main() | |
14714 | { | |
14715 | #if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS) | |
14716 | exit (1); | |
14717 | #else | |
14718 | ||
14719 | int code; | |
14720 | sigset_t set, oset; | |
14721 | sigjmp_buf xx; | |
14722 | ||
14723 | /* get the mask */ | |
14724 | sigemptyset(&set); | |
14725 | sigemptyset(&oset); | |
14726 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set); | |
14727 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset); | |
14728 | ||
14729 | /* save it */ | |
14730 | code = sigsetjmp(xx, 1); | |
14731 | if (code) | |
14732 | exit(0); /* could get sigmask and compare to oset here. */ | |
14733 | ||
14734 | /* change it */ | |
14735 | sigaddset(&set, SIGINT); | |
14736 | sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL); | |
14737 | ||
14738 | /* and siglongjmp */ | |
14739 | siglongjmp(xx, 10); | |
14740 | exit(1); | |
14741 | #endif | |
14742 | } | |
f73dda09 | 14743 | _ACEOF |
ac50fbac | 14744 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14745 | bash_cv_func_sigsetjmp=present |
14746 | else | |
ac50fbac | 14747 | bash_cv_func_sigsetjmp=missing |
ccc6cda3 | 14748 | fi |
ac50fbac CR |
14749 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14750 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14751 | fi |
3185942a | 14752 | |
ccc6cda3 JA |
14753 | fi |
14754 | ||
ac50fbac | 14755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_sigsetjmp" >&5 |
3185942a | 14756 | $as_echo "$bash_cv_func_sigsetjmp" >&6; } |
ccc6cda3 | 14757 | if test $bash_cv_func_sigsetjmp = present; then |
ac50fbac | 14758 | $as_echo "#define HAVE_POSIX_SIGSETJMP 1" >>confdefs.h |
ccc6cda3 JA |
14759 | |
14760 | fi | |
14761 | ||
b80f6443 | 14762 | |
ac50fbac | 14763 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not strcoll and strcmp differ" >&5 |
3185942a | 14764 | $as_echo_n "checking whether or not strcoll and strcmp differ... " >&6; } |
ac50fbac | 14765 | if ${bash_cv_func_strcoll_broken+:} false; then : |
3185942a | 14766 | $as_echo_n "(cached) " >&6 |
d166f048 | 14767 | else |
ac50fbac CR |
14768 | if test "$cross_compiling" = yes; then : |
14769 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5 | |
3185942a | 14770 | $as_echo "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14771 | bash_cv_func_strcoll_broken=no |
14772 | ||
d166f048 | 14773 | else |
ac50fbac | 14774 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14775 | /* end confdefs.h. */ |
d166f048 JA |
14776 | |
14777 | #include <stdio.h> | |
14778 | #if defined (HAVE_LOCALE_H) | |
14779 | #include <locale.h> | |
14780 | #endif | |
14781 | ||
14782 | main(c, v) | |
14783 | int c; | |
14784 | char *v[]; | |
14785 | { | |
14786 | int r1, r2; | |
14787 | char *deflocale, *defcoll; | |
14788 | ||
14789 | #ifdef HAVE_SETLOCALE | |
14790 | deflocale = setlocale(LC_ALL, ""); | |
14791 | defcoll = setlocale(LC_COLLATE, ""); | |
14792 | #endif | |
14793 | ||
14794 | #ifdef HAVE_STRCOLL | |
14795 | /* These two values are taken from tests/glob-test. */ | |
14796 | r1 = strcoll("abd", "aXd"); | |
14797 | #else | |
14798 | r1 = 0; | |
14799 | #endif | |
14800 | r2 = strcmp("abd", "aXd"); | |
14801 | ||
14802 | /* These two should both be greater than 0. It is permissible for | |
14803 | a system to return different values, as long as the sign is the | |
14804 | same. */ | |
14805 | ||
14806 | /* Exit with 1 (failure) if these two values are both > 0, since | |
14807 | this tests whether strcoll(3) is broken with respect to strcmp(3) | |
14808 | in the default locale. */ | |
14809 | exit (r1 > 0 && r2 > 0); | |
14810 | } | |
14811 | ||
f73dda09 | 14812 | _ACEOF |
ac50fbac | 14813 | if ac_fn_c_try_run "$LINENO"; then : |
d166f048 JA |
14814 | bash_cv_func_strcoll_broken=yes |
14815 | else | |
ac50fbac | 14816 | bash_cv_func_strcoll_broken=no |
d166f048 | 14817 | fi |
ac50fbac CR |
14818 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14819 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
d166f048 | 14820 | fi |
3185942a | 14821 | |
d166f048 JA |
14822 | fi |
14823 | ||
ac50fbac | 14824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_strcoll_broken" >&5 |
3185942a | 14825 | $as_echo "$bash_cv_func_strcoll_broken" >&6; } |
d166f048 | 14826 | if test $bash_cv_func_strcoll_broken = yes; then |
ac50fbac | 14827 | $as_echo "#define STRCOLL_BROKEN 1" >>confdefs.h |
d166f048 JA |
14828 | |
14829 | fi | |
14830 | ||
b80f6443 JA |
14831 | |
14832 | ||
0001803f CR |
14833 | |
14834 | ||
0001803f | 14835 | if test X$ac_cv_func_snprintf = Xyes; then |
ac50fbac | 14836 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant snprintf" >&5 |
0001803f | 14837 | $as_echo_n "checking for standard-conformant snprintf... " >&6; } |
ac50fbac | 14838 | if ${bash_cv_func_snprintf+:} false; then : |
0001803f CR |
14839 | $as_echo_n "(cached) " >&6 |
14840 | else | |
ac50fbac CR |
14841 | if test "$cross_compiling" = yes; then : |
14842 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard snprintf if cross-compiling" >&5 | |
0001803f CR |
14843 | $as_echo "$as_me: WARNING: cannot check standard snprintf if cross-compiling" >&2;} |
14844 | bash_cv_func_snprintf=yes | |
14845 | ||
14846 | else | |
ac50fbac | 14847 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0001803f CR |
14848 | /* end confdefs.h. */ |
14849 | ||
14850 | #include <stdio.h> | |
14851 | ||
14852 | main() | |
14853 | { | |
14854 | int n; | |
14855 | n = snprintf (0, 0, "%s", "0123456"); | |
14856 | exit(n != 7); | |
14857 | } | |
14858 | ||
14859 | _ACEOF | |
ac50fbac | 14860 | if ac_fn_c_try_run "$LINENO"; then : |
0001803f CR |
14861 | bash_cv_func_snprintf=yes |
14862 | else | |
ac50fbac | 14863 | bash_cv_func_snprintf=no |
0001803f | 14864 | fi |
ac50fbac CR |
14865 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14866 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
0001803f CR |
14867 | fi |
14868 | ||
0001803f | 14869 | fi |
ac50fbac | 14870 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_snprintf" >&5 |
0001803f CR |
14871 | $as_echo "$bash_cv_func_snprintf" >&6; } |
14872 | if test $bash_cv_func_snprintf = no; then | |
14873 | ac_cv_func_snprintf=no | |
14874 | fi | |
14875 | fi | |
14876 | if test $ac_cv_func_snprintf = no; then | |
14877 | ||
ac50fbac | 14878 | $as_echo "#define HAVE_SNPRINTF 0" >>confdefs.h |
0001803f CR |
14879 | |
14880 | fi | |
14881 | ||
14882 | ||
14883 | ||
14884 | ||
14885 | ||
0001803f | 14886 | if test X$ac_cv_func_vsnprintf = Xyes; then |
ac50fbac | 14887 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant vsnprintf" >&5 |
0001803f | 14888 | $as_echo_n "checking for standard-conformant vsnprintf... " >&6; } |
ac50fbac | 14889 | if ${bash_cv_func_vsnprintf+:} false; then : |
0001803f CR |
14890 | $as_echo_n "(cached) " >&6 |
14891 | else | |
ac50fbac CR |
14892 | if test "$cross_compiling" = yes; then : |
14893 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard vsnprintf if cross-compiling" >&5 | |
0001803f CR |
14894 | $as_echo "$as_me: WARNING: cannot check standard vsnprintf if cross-compiling" >&2;} |
14895 | bash_cv_func_vsnprintf=yes | |
14896 | ||
14897 | else | |
ac50fbac | 14898 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0001803f CR |
14899 | /* end confdefs.h. */ |
14900 | ||
14901 | #if HAVE_STDARG_H | |
14902 | #include <stdarg.h> | |
14903 | #else | |
14904 | #include <varargs.h> | |
14905 | #endif | |
14906 | #include <stdio.h> | |
14907 | #include <stdlib.h> | |
14908 | ||
14909 | static int | |
14910 | #if HAVE_STDARG_H | |
14911 | foo(const char *fmt, ...) | |
14912 | #else | |
14913 | foo(format, va_alist) | |
14914 | const char *format; | |
14915 | va_dcl | |
14916 | #endif | |
14917 | { | |
14918 | va_list args; | |
14919 | int n; | |
14920 | ||
14921 | #if HAVE_STDARG_H | |
14922 | va_start(args, fmt); | |
14923 | #else | |
14924 | va_start(args); | |
14925 | #endif | |
14926 | n = vsnprintf(0, 0, fmt, args); | |
14927 | va_end (args); | |
14928 | return n; | |
14929 | } | |
14930 | ||
14931 | main() | |
14932 | { | |
14933 | int n; | |
14934 | n = foo("%s", "0123456"); | |
14935 | exit(n != 7); | |
14936 | } | |
14937 | ||
14938 | _ACEOF | |
ac50fbac | 14939 | if ac_fn_c_try_run "$LINENO"; then : |
0001803f CR |
14940 | bash_cv_func_vsnprintf=yes |
14941 | else | |
ac50fbac | 14942 | bash_cv_func_vsnprintf=no |
0001803f | 14943 | fi |
ac50fbac CR |
14944 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14945 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
0001803f CR |
14946 | fi |
14947 | ||
0001803f | 14948 | fi |
ac50fbac | 14949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_vsnprintf" >&5 |
0001803f CR |
14950 | $as_echo "$bash_cv_func_vsnprintf" >&6; } |
14951 | if test $bash_cv_func_vsnprintf = no; then | |
14952 | ac_cv_func_vsnprintf=no | |
14953 | fi | |
14954 | fi | |
14955 | if test $ac_cv_func_vsnprintf = no; then | |
14956 | ||
ac50fbac | 14957 | $as_echo "#define HAVE_VSNPRINTF 0" >>confdefs.h |
0001803f CR |
14958 | |
14959 | fi | |
14960 | ||
14961 | ||
14962 | ||
7117c2d2 JA |
14963 | if test "$ac_cv_func_putenv" = "yes"; then |
14964 | ||
b80f6443 JA |
14965 | |
14966 | ||
ac50fbac | 14967 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant putenv declaration" >&5 |
3185942a | 14968 | $as_echo_n "checking for standard-conformant putenv declaration... " >&6; } |
ac50fbac | 14969 | if ${bash_cv_std_putenv+:} false; then : |
3185942a | 14970 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14971 | else |
ac50fbac | 14972 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 14973 | /* end confdefs.h. */ |
7117c2d2 JA |
14974 | |
14975 | #if STDC_HEADERS | |
14976 | #include <stdlib.h> | |
14977 | #include <stddef.h> | |
14978 | #endif | |
14979 | #ifndef __STDC__ | |
14980 | # ifndef const | |
14981 | # define const | |
14982 | # endif | |
14983 | #endif | |
14984 | #ifdef PROTOTYPES | |
14985 | extern int putenv (char *); | |
14986 | #else | |
14987 | extern int putenv (); | |
14988 | #endif | |
14989 | ||
14990 | int | |
14991 | main () | |
14992 | { | |
14993 | return (putenv == 0); | |
14994 | ; | |
14995 | return 0; | |
14996 | } | |
14997 | _ACEOF | |
ac50fbac | 14998 | if ac_fn_c_try_link "$LINENO"; then : |
7117c2d2 JA |
14999 | bash_cv_std_putenv=yes |
15000 | else | |
ac50fbac | 15001 | bash_cv_std_putenv=no |
7117c2d2 JA |
15002 | |
15003 | fi | |
ac50fbac CR |
15004 | rm -f core conftest.err conftest.$ac_objext \ |
15005 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 15006 | fi |
ac50fbac | 15007 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_putenv" >&5 |
3185942a | 15008 | $as_echo "$bash_cv_std_putenv" >&6; } |
7117c2d2 | 15009 | if test $bash_cv_std_putenv = yes; then |
ac50fbac | 15010 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
15011 | |
15012 | fi | |
15013 | ||
15014 | else | |
ac50fbac | 15015 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
15016 | |
15017 | fi | |
15018 | if test "$ac_cv_func_unsetenv" = "yes"; then | |
15019 | ||
b80f6443 JA |
15020 | |
15021 | ||
ac50fbac | 15022 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant unsetenv declaration" >&5 |
3185942a | 15023 | $as_echo_n "checking for standard-conformant unsetenv declaration... " >&6; } |
ac50fbac | 15024 | if ${bash_cv_std_unsetenv+:} false; then : |
3185942a | 15025 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 15026 | else |
ac50fbac | 15027 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15028 | /* end confdefs.h. */ |
7117c2d2 JA |
15029 | |
15030 | #if STDC_HEADERS | |
15031 | #include <stdlib.h> | |
15032 | #include <stddef.h> | |
15033 | #endif | |
15034 | #ifndef __STDC__ | |
15035 | # ifndef const | |
15036 | # define const | |
15037 | # endif | |
15038 | #endif | |
15039 | #ifdef PROTOTYPES | |
15040 | extern int unsetenv (const char *); | |
15041 | #else | |
15042 | extern int unsetenv (); | |
15043 | #endif | |
15044 | ||
15045 | int | |
15046 | main () | |
15047 | { | |
15048 | return (unsetenv == 0); | |
15049 | ; | |
15050 | return 0; | |
15051 | } | |
15052 | _ACEOF | |
ac50fbac | 15053 | if ac_fn_c_try_link "$LINENO"; then : |
7117c2d2 JA |
15054 | bash_cv_std_unsetenv=yes |
15055 | else | |
ac50fbac | 15056 | bash_cv_std_unsetenv=no |
7117c2d2 JA |
15057 | |
15058 | fi | |
ac50fbac CR |
15059 | rm -f core conftest.err conftest.$ac_objext \ |
15060 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 15061 | fi |
ac50fbac | 15062 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_unsetenv" >&5 |
3185942a | 15063 | $as_echo "$bash_cv_std_unsetenv" >&6; } |
7117c2d2 | 15064 | if test $bash_cv_std_unsetenv = yes; then |
ac50fbac | 15065 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
15066 | |
15067 | fi | |
15068 | ||
15069 | else | |
ac50fbac | 15070 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
15071 | |
15072 | fi | |
15073 | ||
ac50fbac | 15074 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf floating point output in hex notation" >&5 |
3185942a | 15075 | $as_echo_n "checking for printf floating point output in hex notation... " >&6; } |
ac50fbac | 15076 | if ${bash_cv_printf_a_format+:} false; then : |
3185942a | 15077 | $as_echo_n "(cached) " >&6 |
f73dda09 | 15078 | else |
ac50fbac CR |
15079 | if test "$cross_compiling" = yes; then : |
15080 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check printf if cross compiling -- defaulting to no" >&5 | |
3185942a | 15081 | $as_echo "$as_me: WARNING: cannot check printf if cross compiling -- defaulting to no" >&2;} |
f73dda09 JA |
15082 | bash_cv_printf_a_format=no |
15083 | ||
15084 | else | |
ac50fbac | 15085 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15086 | /* end confdefs.h. */ |
f73dda09 JA |
15087 | |
15088 | #include <stdio.h> | |
15089 | #include <string.h> | |
15090 | ||
15091 | int | |
15092 | main() | |
15093 | { | |
15094 | double y = 0.0; | |
15095 | char abuf[1024]; | |
15096 | ||
15097 | sprintf(abuf, "%A", y); | |
15098 | exit(strchr(abuf, 'P') == (char *)0); | |
15099 | } | |
15100 | ||
15101 | _ACEOF | |
ac50fbac | 15102 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
15103 | bash_cv_printf_a_format=yes |
15104 | else | |
ac50fbac | 15105 | bash_cv_printf_a_format=no |
f73dda09 | 15106 | fi |
ac50fbac CR |
15107 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15108 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 15109 | fi |
3185942a | 15110 | |
f73dda09 | 15111 | fi |
d166f048 | 15112 | |
ac50fbac | 15113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_printf_a_format" >&5 |
3185942a | 15114 | $as_echo "$bash_cv_printf_a_format" >&6; } |
f73dda09 | 15115 | if test $bash_cv_printf_a_format = yes; then |
ac50fbac | 15116 | $as_echo "#define HAVE_PRINTF_A_FORMAT 1" >>confdefs.h |
d166f048 | 15117 | |
f73dda09 | 15118 | fi |
ccc6cda3 | 15119 | |
b80f6443 JA |
15120 | |
15121 | ||
15122 | ||
ac50fbac | 15123 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal handlers must be reinstalled when invoked" >&5 |
3185942a | 15124 | $as_echo_n "checking if signal handlers must be reinstalled when invoked... " >&6; } |
ac50fbac | 15125 | if ${bash_cv_must_reinstall_sighandlers+:} false; then : |
3185942a | 15126 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15127 | else |
ac50fbac CR |
15128 | if test "$cross_compiling" = yes; then : |
15129 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5 | |
3185942a | 15130 | $as_echo "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
15131 | bash_cv_must_reinstall_sighandlers=no |
15132 | ||
ccc6cda3 | 15133 | else |
ac50fbac | 15134 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15135 | /* end confdefs.h. */ |
ccc6cda3 JA |
15136 | |
15137 | #include <signal.h> | |
15138 | #ifdef HAVE_UNISTD_H | |
15139 | #include <unistd.h> | |
15140 | #endif | |
15141 | ||
15142 | typedef RETSIGTYPE sigfunc(); | |
15143 | ||
15144 | int nsigint; | |
15145 | ||
15146 | #ifdef HAVE_POSIX_SIGNALS | |
15147 | sigfunc * | |
15148 | set_signal_handler(sig, handler) | |
15149 | int sig; | |
15150 | sigfunc *handler; | |
15151 | { | |
15152 | struct sigaction act, oact; | |
15153 | act.sa_handler = handler; | |
15154 | act.sa_flags = 0; | |
15155 | sigemptyset (&act.sa_mask); | |
15156 | sigemptyset (&oact.sa_mask); | |
15157 | sigaction (sig, &act, &oact); | |
15158 | return (oact.sa_handler); | |
15159 | } | |
15160 | #else | |
15161 | #define set_signal_handler(s, h) signal(s, h) | |
15162 | #endif | |
15163 | ||
15164 | RETSIGTYPE | |
15165 | sigint(s) | |
15166 | int s; | |
15167 | { | |
15168 | nsigint++; | |
15169 | } | |
15170 | ||
15171 | main() | |
15172 | { | |
15173 | nsigint = 0; | |
15174 | set_signal_handler(SIGINT, sigint); | |
15175 | kill((int)getpid(), SIGINT); | |
15176 | kill((int)getpid(), SIGINT); | |
15177 | exit(nsigint != 2); | |
15178 | } | |
15179 | ||
f73dda09 | 15180 | _ACEOF |
ac50fbac | 15181 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
15182 | bash_cv_must_reinstall_sighandlers=no |
15183 | else | |
ac50fbac | 15184 | bash_cv_must_reinstall_sighandlers=yes |
ccc6cda3 | 15185 | fi |
ac50fbac CR |
15186 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15187 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15188 | fi |
3185942a | 15189 | |
ccc6cda3 JA |
15190 | fi |
15191 | ||
ac50fbac | 15192 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_must_reinstall_sighandlers" >&5 |
3185942a | 15193 | $as_echo "$bash_cv_must_reinstall_sighandlers" >&6; } |
ccc6cda3 | 15194 | if test $bash_cv_must_reinstall_sighandlers = yes; then |
ac50fbac | 15195 | $as_echo "#define MUST_REINSTALL_SIGHANDLERS 1" >>confdefs.h |
ccc6cda3 JA |
15196 | |
15197 | fi | |
15198 | ||
b80f6443 | 15199 | |
ac50fbac | 15200 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of necessary job control definitions" >&5 |
3185942a | 15201 | $as_echo_n "checking for presence of necessary job control definitions... " >&6; } |
ac50fbac | 15202 | if ${bash_cv_job_control_missing+:} false; then : |
3185942a | 15203 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15204 | else |
ac50fbac CR |
15205 | if test "$cross_compiling" = yes; then : |
15206 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&5 | |
3185942a | 15207 | $as_echo "$as_me: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
15208 | bash_cv_job_control_missing=missing |
15209 | ||
ccc6cda3 | 15210 | else |
ac50fbac | 15211 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15212 | /* end confdefs.h. */ |
ccc6cda3 JA |
15213 | |
15214 | #include <sys/types.h> | |
15215 | #ifdef HAVE_SYS_WAIT_H | |
15216 | #include <sys/wait.h> | |
15217 | #endif | |
15218 | #ifdef HAVE_UNISTD_H | |
15219 | #include <unistd.h> | |
15220 | #endif | |
15221 | #include <signal.h> | |
15222 | ||
15223 | /* Add more tests in here as appropriate. */ | |
15224 | main() | |
15225 | { | |
15226 | /* signal type */ | |
15227 | #if !defined (HAVE_POSIX_SIGNALS) && !defined (HAVE_BSD_SIGNALS) | |
15228 | exit(1); | |
15229 | #endif | |
15230 | ||
15231 | /* signals and tty control. */ | |
15232 | #if !defined (SIGTSTP) || !defined (SIGSTOP) || !defined (SIGCONT) | |
15233 | exit (1); | |
15234 | #endif | |
15235 | ||
15236 | /* process control */ | |
f73dda09 | 15237 | #if !defined (WNOHANG) || !defined (WUNTRACED) |
ccc6cda3 JA |
15238 | exit(1); |
15239 | #endif | |
15240 | ||
15241 | /* Posix systems have tcgetpgrp and waitpid. */ | |
15242 | #if defined (_POSIX_VERSION) && !defined (HAVE_TCGETPGRP) | |
15243 | exit(1); | |
15244 | #endif | |
15245 | ||
15246 | #if defined (_POSIX_VERSION) && !defined (HAVE_WAITPID) | |
15247 | exit(1); | |
15248 | #endif | |
15249 | ||
15250 | /* Other systems have TIOCSPGRP/TIOCGPRGP and wait3. */ | |
15251 | #if !defined (_POSIX_VERSION) && !defined (HAVE_WAIT3) | |
15252 | exit(1); | |
15253 | #endif | |
15254 | ||
15255 | exit(0); | |
15256 | } | |
f73dda09 | 15257 | _ACEOF |
ac50fbac | 15258 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
15259 | bash_cv_job_control_missing=present |
15260 | else | |
ac50fbac | 15261 | bash_cv_job_control_missing=missing |
ccc6cda3 | 15262 | fi |
ac50fbac CR |
15263 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15264 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15265 | fi |
3185942a | 15266 | |
ccc6cda3 JA |
15267 | fi |
15268 | ||
ac50fbac | 15269 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_job_control_missing" >&5 |
3185942a | 15270 | $as_echo "$bash_cv_job_control_missing" >&6; } |
ccc6cda3 | 15271 | if test $bash_cv_job_control_missing = missing; then |
ac50fbac | 15272 | $as_echo "#define JOB_CONTROL_MISSING 1" >>confdefs.h |
ccc6cda3 JA |
15273 | |
15274 | fi | |
15275 | ||
ac50fbac | 15276 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of named pipes" >&5 |
3185942a | 15277 | $as_echo_n "checking for presence of named pipes... " >&6; } |
ac50fbac | 15278 | if ${bash_cv_sys_named_pipes+:} false; then : |
3185942a | 15279 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15280 | else |
ac50fbac CR |
15281 | if test "$cross_compiling" = yes; then : |
15282 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&5 | |
3185942a | 15283 | $as_echo "$as_me: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
15284 | bash_cv_sys_named_pipes=missing |
15285 | ||
ccc6cda3 | 15286 | else |
ac50fbac | 15287 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15288 | /* end confdefs.h. */ |
ccc6cda3 JA |
15289 | |
15290 | #include <sys/types.h> | |
15291 | #include <sys/stat.h> | |
15292 | #ifdef HAVE_UNISTD_H | |
15293 | #include <unistd.h> | |
15294 | #endif | |
15295 | ||
15296 | /* Add more tests in here as appropriate. */ | |
15297 | main() | |
15298 | { | |
bb70624e | 15299 | int fd, err; |
ccc6cda3 JA |
15300 | |
15301 | #if defined (HAVE_MKFIFO) | |
15302 | exit (0); | |
15303 | #endif | |
15304 | ||
15305 | #if !defined (S_IFIFO) && (defined (_POSIX_VERSION) && !defined (S_ISFIFO)) | |
15306 | exit (1); | |
15307 | #endif | |
15308 | ||
15309 | #if defined (NeXT) | |
15310 | exit (1); | |
15311 | #endif | |
3185942a | 15312 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
15313 | if (err < 0) { |
15314 | perror ("mkdir"); | |
15315 | exit(1); | |
15316 | } | |
3185942a | 15317 | fd = mknod ("bash-aclocal/sh-np-autoconf", 0666 | S_IFIFO, 0); |
bb70624e | 15318 | if (fd == -1) { |
3185942a | 15319 | rmdir ("bash-aclocal"); |
ccc6cda3 | 15320 | exit (1); |
bb70624e | 15321 | } |
ccc6cda3 | 15322 | close(fd); |
3185942a JA |
15323 | unlink ("bash-aclocal/sh-np-autoconf"); |
15324 | rmdir ("bash-aclocal"); | |
ccc6cda3 JA |
15325 | exit(0); |
15326 | } | |
f73dda09 | 15327 | _ACEOF |
ac50fbac | 15328 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
15329 | bash_cv_sys_named_pipes=present |
15330 | else | |
ac50fbac | 15331 | bash_cv_sys_named_pipes=missing |
0628567a | 15332 | fi |
ac50fbac CR |
15333 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15334 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
95732b49 | 15335 | fi |
3185942a | 15336 | |
95732b49 | 15337 | fi |
95732b49 | 15338 | |
ac50fbac | 15339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_named_pipes" >&5 |
3185942a | 15340 | $as_echo "$bash_cv_sys_named_pipes" >&6; } |
0628567a | 15341 | if test $bash_cv_sys_named_pipes = missing; then |
ac50fbac | 15342 | $as_echo "#define NAMED_PIPES_MISSING 1" >>confdefs.h |
0628567a JA |
15343 | |
15344 | fi | |
15345 | ||
15346 | ||
ac50fbac | 15347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether termios.h defines TIOCGWINSZ" >&5 |
3185942a | 15348 | $as_echo_n "checking whether termios.h defines TIOCGWINSZ... " >&6; } |
ac50fbac | 15349 | if ${ac_cv_sys_tiocgwinsz_in_termios_h+:} false; then : |
3185942a | 15350 | $as_echo_n "(cached) " >&6 |
f73dda09 | 15351 | else |
ac50fbac | 15352 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15353 | /* end confdefs.h. */ |
f73dda09 JA |
15354 | #include <sys/types.h> |
15355 | #include <termios.h> | |
15356 | #ifdef TIOCGWINSZ | |
15357 | yes | |
15358 | #endif | |
15359 | ||
15360 | _ACEOF | |
15361 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 15362 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 JA |
15363 | ac_cv_sys_tiocgwinsz_in_termios_h=yes |
15364 | else | |
15365 | ac_cv_sys_tiocgwinsz_in_termios_h=no | |
15366 | fi | |
15367 | rm -f conftest* | |
15368 | ||
15369 | fi | |
ac50fbac | 15370 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5 |
3185942a | 15371 | $as_echo "$ac_cv_sys_tiocgwinsz_in_termios_h" >&6; } |
d166f048 | 15372 | |
f73dda09 | 15373 | if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then |
ac50fbac | 15374 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5 |
3185942a | 15375 | $as_echo_n "checking whether sys/ioctl.h defines TIOCGWINSZ... " >&6; } |
ac50fbac | 15376 | if ${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+:} false; then : |
3185942a | 15377 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15378 | else |
ac50fbac | 15379 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15380 | /* end confdefs.h. */ |
ccc6cda3 JA |
15381 | #include <sys/types.h> |
15382 | #include <sys/ioctl.h> | |
f73dda09 JA |
15383 | #ifdef TIOCGWINSZ |
15384 | yes | |
15385 | #endif | |
15386 | ||
15387 | _ACEOF | |
15388 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
ac50fbac | 15389 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 | 15390 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes |
ccc6cda3 | 15391 | else |
f73dda09 | 15392 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no |
ccc6cda3 JA |
15393 | fi |
15394 | rm -f conftest* | |
f73dda09 | 15395 | |
ccc6cda3 | 15396 | fi |
ac50fbac | 15397 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5 |
3185942a | 15398 | $as_echo "$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6; } |
f73dda09 JA |
15399 | |
15400 | if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then | |
ccc6cda3 | 15401 | |
ac50fbac | 15402 | $as_echo "#define GWINSZ_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 | 15403 | |
f73dda09 | 15404 | fi |
ccc6cda3 JA |
15405 | fi |
15406 | ||
ac50fbac | 15407 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIOCSTAT in sys/ioctl.h" >&5 |
3185942a | 15408 | $as_echo_n "checking for TIOCSTAT in sys/ioctl.h... " >&6; } |
ac50fbac | 15409 | if ${bash_cv_tiocstat_in_ioctl+:} false; then : |
3185942a | 15410 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15411 | else |
ac50fbac | 15412 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15413 | /* end confdefs.h. */ |
ccc6cda3 JA |
15414 | #include <sys/types.h> |
15415 | #include <sys/ioctl.h> | |
f73dda09 JA |
15416 | int |
15417 | main () | |
15418 | { | |
ccc6cda3 | 15419 | int x = TIOCSTAT; |
f73dda09 JA |
15420 | ; |
15421 | return 0; | |
15422 | } | |
15423 | _ACEOF | |
ac50fbac | 15424 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15425 | bash_cv_tiocstat_in_ioctl=yes |
15426 | else | |
ac50fbac | 15427 | bash_cv_tiocstat_in_ioctl=no |
ccc6cda3 | 15428 | fi |
3185942a | 15429 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15430 | fi |
15431 | ||
ac50fbac | 15432 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_tiocstat_in_ioctl" >&5 |
3185942a | 15433 | $as_echo "$bash_cv_tiocstat_in_ioctl" >&6; } |
f73dda09 | 15434 | if test $bash_cv_tiocstat_in_ioctl = yes; then |
ac50fbac | 15435 | $as_echo "#define TIOCSTAT_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15436 | |
15437 | fi | |
15438 | ||
ac50fbac | 15439 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIONREAD in sys/ioctl.h" >&5 |
3185942a | 15440 | $as_echo_n "checking for FIONREAD in sys/ioctl.h... " >&6; } |
ac50fbac | 15441 | if ${bash_cv_fionread_in_ioctl+:} false; then : |
3185942a | 15442 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15443 | else |
ac50fbac | 15444 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15445 | /* end confdefs.h. */ |
ccc6cda3 JA |
15446 | #include <sys/types.h> |
15447 | #include <sys/ioctl.h> | |
f73dda09 JA |
15448 | int |
15449 | main () | |
15450 | { | |
ccc6cda3 | 15451 | int x = FIONREAD; |
f73dda09 JA |
15452 | ; |
15453 | return 0; | |
15454 | } | |
15455 | _ACEOF | |
ac50fbac | 15456 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15457 | bash_cv_fionread_in_ioctl=yes |
15458 | else | |
ac50fbac | 15459 | bash_cv_fionread_in_ioctl=no |
ccc6cda3 | 15460 | fi |
3185942a | 15461 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15462 | fi |
15463 | ||
ac50fbac | 15464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_fionread_in_ioctl" >&5 |
3185942a | 15465 | $as_echo "$bash_cv_fionread_in_ioctl" >&6; } |
f73dda09 | 15466 | if test $bash_cv_fionread_in_ioctl = yes; then |
ac50fbac | 15467 | $as_echo "#define FIONREAD_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15468 | |
15469 | fi | |
15470 | ||
b80f6443 | 15471 | |
95732b49 | 15472 | |
ac50fbac | 15473 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WCONTINUED flag to waitpid is unavailable or available but broken" >&5 |
3185942a | 15474 | $as_echo_n "checking whether WCONTINUED flag to waitpid is unavailable or available but broken... " >&6; } |
ac50fbac | 15475 | if ${bash_cv_wcontinued_broken+:} false; then : |
3185942a | 15476 | $as_echo_n "(cached) " >&6 |
95732b49 | 15477 | else |
ac50fbac CR |
15478 | if test "$cross_compiling" = yes; then : |
15479 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&5 | |
3185942a | 15480 | $as_echo "$as_me: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&2;} |
95732b49 JA |
15481 | bash_cv_wcontinued_broken=no |
15482 | ||
15483 | else | |
ac50fbac | 15484 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15485 | /* end confdefs.h. */ |
95732b49 JA |
15486 | |
15487 | #include <sys/types.h> | |
15488 | #include <sys/wait.h> | |
15489 | #include <unistd.h> | |
15490 | #include <errno.h> | |
15491 | ||
15492 | #ifndef errno | |
15493 | extern int errno; | |
15494 | #endif | |
15495 | main() | |
15496 | { | |
15497 | int x; | |
15498 | ||
15499 | x = waitpid(-1, (int *)0, WNOHANG|WCONTINUED); | |
15500 | if (x == -1 && errno == EINVAL) | |
15501 | exit (1); | |
15502 | else | |
15503 | exit (0); | |
15504 | } | |
15505 | ||
15506 | _ACEOF | |
ac50fbac | 15507 | if ac_fn_c_try_run "$LINENO"; then : |
95732b49 JA |
15508 | bash_cv_wcontinued_broken=no |
15509 | else | |
ac50fbac | 15510 | bash_cv_wcontinued_broken=yes |
95732b49 | 15511 | fi |
ac50fbac CR |
15512 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15513 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
95732b49 | 15514 | fi |
3185942a | 15515 | |
95732b49 JA |
15516 | fi |
15517 | ||
ac50fbac | 15518 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcontinued_broken" >&5 |
3185942a | 15519 | $as_echo "$bash_cv_wcontinued_broken" >&6; } |
95732b49 | 15520 | if test $bash_cv_wcontinued_broken = yes; then |
ac50fbac | 15521 | $as_echo "#define WCONTINUED_BROKEN 1" >>confdefs.h |
95732b49 JA |
15522 | |
15523 | fi | |
15524 | ||
15525 | ||
ac50fbac | 15526 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t in sys/types.h" >&5 |
3185942a | 15527 | $as_echo_n "checking for speed_t in sys/types.h... " >&6; } |
ac50fbac | 15528 | if ${bash_cv_speed_t_in_sys_types+:} false; then : |
3185942a | 15529 | $as_echo_n "(cached) " >&6 |
d166f048 | 15530 | else |
ac50fbac | 15531 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15532 | /* end confdefs.h. */ |
d166f048 | 15533 | #include <sys/types.h> |
f73dda09 JA |
15534 | int |
15535 | main () | |
15536 | { | |
d166f048 | 15537 | speed_t x; |
f73dda09 JA |
15538 | ; |
15539 | return 0; | |
15540 | } | |
15541 | _ACEOF | |
ac50fbac | 15542 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
15543 | bash_cv_speed_t_in_sys_types=yes |
15544 | else | |
ac50fbac | 15545 | bash_cv_speed_t_in_sys_types=no |
d166f048 | 15546 | fi |
3185942a | 15547 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
15548 | fi |
15549 | ||
ac50fbac | 15550 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_speed_t_in_sys_types" >&5 |
3185942a | 15551 | $as_echo "$bash_cv_speed_t_in_sys_types" >&6; } |
f73dda09 | 15552 | if test $bash_cv_speed_t_in_sys_types = yes; then |
ac50fbac | 15553 | $as_echo "#define SPEED_T_IN_SYS_TYPES 1" >>confdefs.h |
d166f048 JA |
15554 | |
15555 | fi | |
15556 | ||
ac50fbac | 15557 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpw functions are declared in pwd.h" >&5 |
3185942a | 15558 | $as_echo_n "checking whether getpw functions are declared in pwd.h... " >&6; } |
ac50fbac | 15559 | if ${bash_cv_getpw_declared+:} false; then : |
3185942a | 15560 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15561 | else |
ac50fbac | 15562 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15563 | /* end confdefs.h. */ |
28ef6c31 | 15564 | |
ccc6cda3 | 15565 | #include <sys/types.h> |
28ef6c31 JA |
15566 | #ifdef HAVE_UNISTD_H |
15567 | # include <unistd.h> | |
15568 | #endif | |
ccc6cda3 | 15569 | #include <pwd.h> |
28ef6c31 | 15570 | |
f73dda09 | 15571 | _ACEOF |
28ef6c31 | 15572 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
ac50fbac | 15573 | $EGREP "getpwuid" >/dev/null 2>&1; then : |
28ef6c31 | 15574 | bash_cv_getpw_declared=yes |
ccc6cda3 | 15575 | else |
28ef6c31 | 15576 | bash_cv_getpw_declared=no |
ccc6cda3 JA |
15577 | fi |
15578 | rm -f conftest* | |
28ef6c31 | 15579 | |
ccc6cda3 JA |
15580 | fi |
15581 | ||
ac50fbac | 15582 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getpw_declared" >&5 |
3185942a | 15583 | $as_echo "$bash_cv_getpw_declared" >&6; } |
28ef6c31 | 15584 | if test $bash_cv_getpw_declared = yes; then |
ac50fbac | 15585 | $as_echo "#define HAVE_GETPW_DECLS 1" >>confdefs.h |
ccc6cda3 JA |
15586 | |
15587 | fi | |
15588 | ||
ac50fbac | 15589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unusable real-time signals due to large values" >&5 |
3185942a | 15590 | $as_echo_n "checking for unusable real-time signals due to large values... " >&6; } |
ac50fbac | 15591 | if ${bash_cv_unusable_rtsigs+:} false; then : |
3185942a | 15592 | $as_echo_n "(cached) " >&6 |
28ef6c31 | 15593 | else |
ac50fbac CR |
15594 | if test "$cross_compiling" = yes; then : |
15595 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&5 | |
3185942a | 15596 | $as_echo "$as_me: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&2;} |
28ef6c31 JA |
15597 | bash_cv_unusable_rtsigs=yes |
15598 | ||
15599 | else | |
ac50fbac | 15600 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15601 | /* end confdefs.h. */ |
28ef6c31 JA |
15602 | |
15603 | #include <sys/types.h> | |
15604 | #include <signal.h> | |
15605 | ||
15606 | #ifndef NSIG | |
15607 | # define NSIG 64 | |
15608 | #endif | |
15609 | ||
15610 | main () | |
15611 | { | |
15612 | int n_sigs = 2 * NSIG; | |
15613 | #ifdef SIGRTMIN | |
15614 | int rtmin = SIGRTMIN; | |
15615 | #else | |
15616 | int rtmin = 0; | |
15617 | #endif | |
15618 | ||
15619 | exit(rtmin < n_sigs); | |
15620 | } | |
f73dda09 | 15621 | _ACEOF |
ac50fbac | 15622 | if ac_fn_c_try_run "$LINENO"; then : |
28ef6c31 JA |
15623 | bash_cv_unusable_rtsigs=yes |
15624 | else | |
ac50fbac | 15625 | bash_cv_unusable_rtsigs=no |
28ef6c31 | 15626 | fi |
ac50fbac CR |
15627 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15628 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
28ef6c31 | 15629 | fi |
3185942a | 15630 | |
28ef6c31 JA |
15631 | fi |
15632 | ||
ac50fbac | 15633 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_unusable_rtsigs" >&5 |
3185942a | 15634 | $as_echo "$bash_cv_unusable_rtsigs" >&6; } |
28ef6c31 | 15635 | if test $bash_cv_unusable_rtsigs = yes; then |
ac50fbac | 15636 | $as_echo "#define UNUSABLE_RT_SIGNALS 1" >>confdefs.h |
28ef6c31 JA |
15637 | |
15638 | fi | |
15639 | ||
b80f6443 JA |
15640 | |
15641 | ||
15642 | ||
15643 | ||
f73dda09 JA |
15644 | if test "$bash_cv_sys_siglist" = no && test "$bash_cv_under_sys_siglist" = no && test "$bash_cv_have_strsignal" = no; then |
15645 | SIGLIST_O=siglist.o | |
15646 | else | |
15647 | SIGLIST_O= | |
15648 | fi | |
ccc6cda3 | 15649 | |
b80f6443 JA |
15650 | |
15651 | ||
ccc6cda3 | 15652 | case "$host_os" in |
ac50fbac | 15653 | hpux*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $host_os needs _KERNEL for RLIMIT defines" >&5 |
3185942a | 15654 | $as_echo_n "checking whether $host_os needs _KERNEL for RLIMIT defines... " >&6; } |
ac50fbac | 15655 | if ${bash_cv_kernel_rlimit+:} false; then : |
3185942a | 15656 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15657 | else |
ac50fbac | 15658 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15659 | /* end confdefs.h. */ |
ccc6cda3 JA |
15660 | |
15661 | #include <sys/types.h> | |
15662 | #include <sys/resource.h> | |
15663 | ||
f73dda09 JA |
15664 | int |
15665 | main () | |
15666 | { | |
ccc6cda3 JA |
15667 | |
15668 | int f; | |
15669 | f = RLIMIT_DATA; | |
15670 | ||
f73dda09 JA |
15671 | ; |
15672 | return 0; | |
15673 | } | |
15674 | _ACEOF | |
ac50fbac | 15675 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15676 | bash_cv_kernel_rlimit=no |
15677 | else | |
ac50fbac | 15678 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15679 | /* end confdefs.h. */ |
ccc6cda3 | 15680 | |
cce855bc JA |
15681 | #include <sys/types.h> |
15682 | #define _KERNEL | |
15683 | #include <sys/resource.h> | |
15684 | #undef _KERNEL | |
15685 | ||
f73dda09 JA |
15686 | int |
15687 | main () | |
15688 | { | |
ccc6cda3 JA |
15689 | |
15690 | int f; | |
15691 | f = RLIMIT_DATA; | |
cce855bc | 15692 | |
f73dda09 JA |
15693 | ; |
15694 | return 0; | |
15695 | } | |
15696 | _ACEOF | |
ac50fbac | 15697 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15698 | bash_cv_kernel_rlimit=yes |
15699 | else | |
ac50fbac | 15700 | bash_cv_kernel_rlimit=no |
ccc6cda3 | 15701 | fi |
3185942a | 15702 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15703 | |
15704 | fi | |
3185942a | 15705 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15706 | fi |
15707 | ||
ac50fbac | 15708 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_kernel_rlimit" >&5 |
3185942a | 15709 | $as_echo "$bash_cv_kernel_rlimit" >&6; } |
ccc6cda3 | 15710 | if test $bash_cv_kernel_rlimit = yes; then |
ac50fbac | 15711 | $as_echo "#define RLIMIT_NEEDS_KERNEL 1" >>confdefs.h |
ccc6cda3 JA |
15712 | |
15713 | fi | |
15714 | ;; | |
15715 | esac | |
15716 | ||
15717 | if test "$opt_readline" = yes; then | |
d166f048 JA |
15718 | case "$host_os" in |
15719 | aix*) prefer_curses=yes ;; | |
15720 | esac | |
ccc6cda3 JA |
15721 | |
15722 | if test "X$bash_cv_termcap_lib" = "X"; then | |
15723 | _bash_needmsg=yes | |
15724 | else | |
ac50fbac | 15725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
3185942a | 15726 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 JA |
15727 | _bash_needmsg= |
15728 | fi | |
ac50fbac | 15729 | if ${bash_cv_termcap_lib+:} false; then : |
3185942a | 15730 | $as_echo_n "(cached) " >&6 |
b80f6443 | 15731 | else |
ac50fbac CR |
15732 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" |
15733 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
b80f6443 JA |
15734 | bash_cv_termcap_lib=libc |
15735 | else | |
ac50fbac | 15736 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 |
3185942a | 15737 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } |
ac50fbac | 15738 | if ${ac_cv_lib_termcap_tgetent+:} false; then : |
3185942a | 15739 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15740 | else |
f73dda09 | 15741 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15742 | LIBS="-ltermcap $LIBS" |
ac50fbac | 15743 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15744 | /* end confdefs.h. */ |
f73dda09 | 15745 | |
3185942a JA |
15746 | /* Override any GCC internal prototype to avoid an error. |
15747 | Use char because int might match the return type of a GCC | |
15748 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15749 | #ifdef __cplusplus |
15750 | extern "C" | |
15751 | #endif | |
f73dda09 JA |
15752 | char tgetent (); |
15753 | int | |
15754 | main () | |
15755 | { | |
3185942a | 15756 | return tgetent (); |
f73dda09 JA |
15757 | ; |
15758 | return 0; | |
15759 | } | |
15760 | _ACEOF | |
ac50fbac | 15761 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15762 | ac_cv_lib_termcap_tgetent=yes |
15763 | else | |
ac50fbac | 15764 | ac_cv_lib_termcap_tgetent=no |
f73dda09 | 15765 | fi |
ac50fbac CR |
15766 | rm -f core conftest.err conftest.$ac_objext \ |
15767 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15768 | LIBS=$ac_check_lib_save_LIBS |
15769 | fi | |
ac50fbac | 15770 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
3185942a | 15771 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } |
ac50fbac | 15772 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : |
ccc6cda3 JA |
15773 | bash_cv_termcap_lib=libtermcap |
15774 | else | |
ac50fbac | 15775 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
3185942a | 15776 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } |
ac50fbac | 15777 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : |
3185942a | 15778 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15779 | else |
f73dda09 JA |
15780 | ac_check_lib_save_LIBS=$LIBS |
15781 | LIBS="-ltinfo $LIBS" | |
ac50fbac | 15782 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15783 | /* end confdefs.h. */ |
f73dda09 | 15784 | |
3185942a JA |
15785 | /* Override any GCC internal prototype to avoid an error. |
15786 | Use char because int might match the return type of a GCC | |
15787 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15788 | #ifdef __cplusplus |
15789 | extern "C" | |
15790 | #endif | |
f73dda09 JA |
15791 | char tgetent (); |
15792 | int | |
15793 | main () | |
15794 | { | |
3185942a | 15795 | return tgetent (); |
f73dda09 JA |
15796 | ; |
15797 | return 0; | |
15798 | } | |
15799 | _ACEOF | |
ac50fbac | 15800 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15801 | ac_cv_lib_tinfo_tgetent=yes |
15802 | else | |
ac50fbac | 15803 | ac_cv_lib_tinfo_tgetent=no |
f73dda09 | 15804 | fi |
ac50fbac CR |
15805 | rm -f core conftest.err conftest.$ac_objext \ |
15806 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15807 | LIBS=$ac_check_lib_save_LIBS |
15808 | fi | |
ac50fbac | 15809 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
3185942a | 15810 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
ac50fbac | 15811 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
7117c2d2 | 15812 | bash_cv_termcap_lib=libtinfo |
f73dda09 | 15813 | else |
ac50fbac | 15814 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
3185942a | 15815 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
ac50fbac | 15816 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
3185942a | 15817 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
15818 | else |
15819 | ac_check_lib_save_LIBS=$LIBS | |
15820 | LIBS="-lcurses $LIBS" | |
ac50fbac | 15821 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15822 | /* end confdefs.h. */ |
ccc6cda3 | 15823 | |
3185942a JA |
15824 | /* Override any GCC internal prototype to avoid an error. |
15825 | Use char because int might match the return type of a GCC | |
15826 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15827 | #ifdef __cplusplus |
15828 | extern "C" | |
15829 | #endif | |
f73dda09 JA |
15830 | char tgetent (); |
15831 | int | |
15832 | main () | |
15833 | { | |
3185942a | 15834 | return tgetent (); |
f73dda09 JA |
15835 | ; |
15836 | return 0; | |
15837 | } | |
15838 | _ACEOF | |
ac50fbac | 15839 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15840 | ac_cv_lib_curses_tgetent=yes |
15841 | else | |
ac50fbac | 15842 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 15843 | fi |
ac50fbac CR |
15844 | rm -f core conftest.err conftest.$ac_objext \ |
15845 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15846 | LIBS=$ac_check_lib_save_LIBS |
15847 | fi | |
ac50fbac | 15848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
3185942a | 15849 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
ac50fbac | 15850 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
ccc6cda3 JA |
15851 | bash_cv_termcap_lib=libcurses |
15852 | else | |
ac50fbac | 15853 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
3185942a | 15854 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
ac50fbac | 15855 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
3185942a | 15856 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15857 | else |
f73dda09 | 15858 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15859 | LIBS="-lncurses $LIBS" |
ac50fbac | 15860 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
0628567a | 15861 | /* end confdefs.h. */ |
f73dda09 | 15862 | |
3185942a JA |
15863 | /* Override any GCC internal prototype to avoid an error. |
15864 | Use char because int might match the return type of a GCC | |
15865 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15866 | #ifdef __cplusplus |
15867 | extern "C" | |
15868 | #endif | |
f73dda09 JA |
15869 | char tgetent (); |
15870 | int | |
15871 | main () | |
15872 | { | |
3185942a | 15873 | return tgetent (); |
f73dda09 JA |
15874 | ; |
15875 | return 0; | |
15876 | } | |
15877 | _ACEOF | |
ac50fbac | 15878 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15879 | ac_cv_lib_ncurses_tgetent=yes |
15880 | else | |
ac50fbac | 15881 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 15882 | fi |
ac50fbac CR |
15883 | rm -f core conftest.err conftest.$ac_objext \ |
15884 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15885 | LIBS=$ac_check_lib_save_LIBS |
15886 | fi | |
ac50fbac | 15887 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
3185942a | 15888 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
ac50fbac | 15889 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 15890 | bash_cv_termcap_lib=libncurses |
ccc6cda3 | 15891 | else |
f73dda09 | 15892 | bash_cv_termcap_lib=gnutermcap |
ccc6cda3 | 15893 | fi |
ccc6cda3 | 15894 | |
ccc6cda3 JA |
15895 | fi |
15896 | ||
15897 | fi | |
15898 | ||
15899 | fi | |
15900 | ||
15901 | fi | |
15902 | ||
b80f6443 JA |
15903 | fi |
15904 | ||
ccc6cda3 | 15905 | if test "X$_bash_needmsg" = "Xyes"; then |
ac50fbac | 15906 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
3185942a | 15907 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 | 15908 | fi |
ac50fbac | 15909 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
3185942a | 15910 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
cce855bc | 15911 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15912 | LDFLAGS="$LDFLAGS -L./lib/termcap" |
15913 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
15914 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
d166f048 | 15915 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15916 | TERMCAP_LIB=-ltermcap |
15917 | TERMCAP_DEP= | |
f73dda09 JA |
15918 | elif test $bash_cv_termcap_lib = libtinfo; then |
15919 | TERMCAP_LIB=-ltinfo | |
15920 | TERMCAP_DEP= | |
ccc6cda3 JA |
15921 | elif test $bash_cv_termcap_lib = libncurses; then |
15922 | TERMCAP_LIB=-lncurses | |
15923 | TERMCAP_DEP= | |
b80f6443 JA |
15924 | elif test $bash_cv_termcap_lib = libc; then |
15925 | TERMCAP_LIB= | |
15926 | TERMCAP_DEP= | |
ccc6cda3 JA |
15927 | else |
15928 | TERMCAP_LIB=-lcurses | |
15929 | TERMCAP_DEP= | |
15930 | fi | |
15931 | ||
15932 | fi | |
15933 | ||
b80f6443 JA |
15934 | |
15935 | ||
ac50fbac | 15936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/fd is available" >&5 |
3185942a | 15937 | $as_echo_n "checking whether /dev/fd is available... " >&6; } |
ac50fbac | 15938 | if ${bash_cv_dev_fd+:} false; then : |
3185942a | 15939 | $as_echo_n "(cached) " >&6 |
d166f048 | 15940 | else |
0628567a | 15941 | bash_cv_dev_fd="" |
3185942a | 15942 | if test -d /dev/fd && (exec test -r /dev/fd/0 < /dev/null) ; then |
95732b49 | 15943 | # check for systems like FreeBSD 5 that only provide /dev/fd/[012] |
3185942a | 15944 | if (exec test -r /dev/fd/3 3</dev/null) ; then |
95732b49 JA |
15945 | bash_cv_dev_fd=standard |
15946 | else | |
15947 | bash_cv_dev_fd=absent | |
15948 | fi | |
0628567a JA |
15949 | fi |
15950 | if test -z "$bash_cv_dev_fd" ; then | |
3185942a | 15951 | if test -d /proc/self/fd && (exec test -r /proc/self/fd/0 < /dev/null) ; then |
0628567a JA |
15952 | bash_cv_dev_fd=whacky |
15953 | else | |
15954 | bash_cv_dev_fd=absent | |
15955 | fi | |
15956 | fi | |
d166f048 JA |
15957 | |
15958 | fi | |
15959 | ||
ac50fbac | 15960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_fd" >&5 |
3185942a | 15961 | $as_echo "$bash_cv_dev_fd" >&6; } |
d166f048 | 15962 | if test $bash_cv_dev_fd = "standard"; then |
ac50fbac | 15963 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15964 | |
ac50fbac | 15965 | $as_echo "#define DEV_FD_PREFIX \"/dev/fd/\"" >>confdefs.h |
d166f048 JA |
15966 | |
15967 | elif test $bash_cv_dev_fd = "whacky"; then | |
ac50fbac | 15968 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15969 | |
ac50fbac | 15970 | $as_echo "#define DEV_FD_PREFIX \"/proc/self/fd/\"" >>confdefs.h |
d166f048 JA |
15971 | |
15972 | fi | |
15973 | ||
ac50fbac | 15974 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/stdin stdout stderr are available" >&5 |
3185942a | 15975 | $as_echo_n "checking whether /dev/stdin stdout stderr are available... " >&6; } |
ac50fbac | 15976 | if ${bash_cv_dev_stdin+:} false; then : |
3185942a | 15977 | $as_echo_n "(cached) " >&6 |
bb70624e | 15978 | else |
3185942a | 15979 | if test -d /dev/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e | 15980 | bash_cv_dev_stdin=present |
3185942a | 15981 | elif test -d /proc/self/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e JA |
15982 | bash_cv_dev_stdin=present |
15983 | else | |
15984 | bash_cv_dev_stdin=absent | |
15985 | fi | |
15986 | ||
15987 | fi | |
15988 | ||
ac50fbac | 15989 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_stdin" >&5 |
3185942a | 15990 | $as_echo "$bash_cv_dev_stdin" >&6; } |
bb70624e | 15991 | if test $bash_cv_dev_stdin = "present"; then |
ac50fbac | 15992 | $as_echo "#define HAVE_DEV_STDIN 1" >>confdefs.h |
bb70624e JA |
15993 | |
15994 | fi | |
15995 | ||
ac50fbac | 15996 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default mail directory" >&5 |
3185942a | 15997 | $as_echo_n "checking for default mail directory... " >&6; } |
ac50fbac | 15998 | if ${bash_cv_mail_dir+:} false; then : |
3185942a | 15999 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
16000 | else |
16001 | if test -d /var/mail; then | |
16002 | bash_cv_mail_dir=/var/mail | |
ccc6cda3 JA |
16003 | elif test -d /var/spool/mail; then |
16004 | bash_cv_mail_dir=/var/spool/mail | |
7117c2d2 JA |
16005 | elif test -d /usr/mail; then |
16006 | bash_cv_mail_dir=/usr/mail | |
e8ce775d JA |
16007 | elif test -d /usr/spool/mail; then |
16008 | bash_cv_mail_dir=/usr/spool/mail | |
ccc6cda3 JA |
16009 | else |
16010 | bash_cv_mail_dir=unknown | |
16011 | fi | |
16012 | ||
16013 | fi | |
16014 | ||
ac50fbac | 16015 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_mail_dir" >&5 |
3185942a | 16016 | $as_echo "$bash_cv_mail_dir" >&6; } |
b80f6443 JA |
16017 | cat >>confdefs.h <<_ACEOF |
16018 | #define DEFAULT_MAIL_DIRECTORY "$bash_cv_mail_dir" | |
16019 | _ACEOF | |
16020 | ||
16021 | ||
ccc6cda3 | 16022 | |
ccc6cda3 JA |
16023 | if test "$bash_cv_job_control_missing" = missing; then |
16024 | opt_job_control=no | |
16025 | fi | |
16026 | ||
16027 | if test "$opt_job_control" = yes; then | |
ac50fbac | 16028 | $as_echo "#define JOB_CONTROL 1" >>confdefs.h |
ccc6cda3 JA |
16029 | |
16030 | JOBS_O=jobs.o | |
16031 | else | |
16032 | JOBS_O=nojobs.o | |
16033 | fi | |
16034 | ||
b80f6443 JA |
16035 | |
16036 | ||
16037 | ||
d166f048 JA |
16038 | LOCAL_DEFS=-DSHELL |
16039 | ||
b80f6443 | 16040 | |
b72432fd | 16041 | case "${host_os}" in |
ac50fbac | 16042 | sysv4.2*) $as_echo "#define SVR4_2 1" >>confdefs.h |
ccc6cda3 | 16043 | |
ac50fbac | 16044 | $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 16045 | ;; |
ac50fbac | 16046 | sysv4*) $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 16047 | ;; |
ac50fbac | 16048 | sysv5*) $as_echo "#define SVR5 1" >>confdefs.h |
b72432fd JA |
16049 | ;; |
16050 | hpux9*) LOCAL_CFLAGS="-DHPUX9 -DHPUX" ;; | |
ccc6cda3 JA |
16051 | hpux*) LOCAL_CFLAGS=-DHPUX ;; |
16052 | dgux*) LOCAL_CFLAGS=-D_DGUX_SOURCE; LOCAL_LIBS=-ldgc ;; | |
bb70624e JA |
16053 | isc*) LOCAL_CFLAGS=-Disc386 ;; |
16054 | rhapsody*) LOCAL_CFLAGS=-DRHAPSODY ;; | |
f73dda09 | 16055 | darwin*) LOCAL_CFLAGS=-DMACOSX ;; |
7117c2d2 JA |
16056 | sco3.2v5*) LOCAL_CFLAGS="-b elf -DWAITPID_BROKEN -DPATH_MAX=1024" ;; |
16057 | sco3.2v4*) LOCAL_CFLAGS="-DMUST_UNBLOCK_CHLD -DPATH_MAX=1024" ;; | |
ccc6cda3 | 16058 | sco3.2*) LOCAL_CFLAGS=-DMUST_UNBLOCK_CHLD ;; |
d166f048 | 16059 | sunos4*) LOCAL_CFLAGS=-DSunOS4 ;; |
f1be666c | 16060 | solaris2.5*) LOCAL_CFLAGS="-DSunOS5 -DSOLARIS" ;; |
17345e5a JA |
16061 | solaris2.8*) LOCAL_CFLAGS=-DSOLARIS ;; |
16062 | solaris2.9*) LOCAL_CFLAGS=-DSOLARIS ;; | |
16063 | solaris2.10*) LOCAL_CFLAGS=-DSOLARIS ;; | |
f1be666c | 16064 | solaris2*) LOCAL_CFLAGS=-DSOLARIS ;; |
b72432fd | 16065 | lynxos*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
95732b49 JA |
16066 | linux*) LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
16067 | case "`uname -r`" in | |
a0c0a00f | 16068 | 2.[456789]*|[34]*) $as_echo "#define PGRP_PIPE 1" >>confdefs.h |
95732b49 JA |
16069 | ;; |
16070 | esac ;; | |
16071 | *qnx6*) LOCAL_CFLAGS="-Dqnx -Dqnx6" LOCAL_LIBS="-lncurses" ;; | |
7117c2d2 | 16072 | *qnx*) LOCAL_CFLAGS="-Dqnx -F -3s" LOCAL_LDFLAGS="-3s" LOCAL_LIBS="-lunix -lncurses" ;; |
b72432fd | 16073 | powerux*) LOCAL_LIBS="-lgen" ;; |
b80f6443 | 16074 | cygwin*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
ac50fbac CR |
16075 | opennt*|interix*) LOCAL_CFLAGS="-DNO_MAIN_ENV_ARG -DBROKEN_DIRENT_D_INO -D_POSIX_SOURCE -D_ALL_SOURCE -DRECYCLES_PIDS" ;; |
16076 | *openstep*) LOCAL_CFLAGS="-D__APPLE_CC__" ;; | |
b72432fd JA |
16077 | esac |
16078 | ||
16079 | case "${host_os}-${CC}" in | |
16080 | aix4.2*-*gcc*) LOCAL_LDFLAGS="-Xlinker -bexpall -Xlinker -brtl" ;; | |
16081 | aix4.2*) LOCAL_LDFLAGS="-bexpall -brtl" ;; | |
16082 | bsdi4*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux | |
a0c0a00f CR |
16083 | bsdi5*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux |
16084 | hpux11*-gcc*) LOCAL_LDFLAGS="-Wl,-E" ;; # allow dynamic loading | |
ccc6cda3 JA |
16085 | esac |
16086 | ||
bb70624e | 16087 | case "${host_os}" in |
28ef6c31 JA |
16088 | freebsd[3-9]*) |
16089 | if test -x /usr/bin/objformat && test "`/usr/bin/objformat`" = "elf" ; then | |
bb70624e JA |
16090 | LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
16091 | fi ;; | |
28ef6c31 | 16092 | freebsdelf*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
95732b49 | 16093 | dragonfly*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
bb70624e JA |
16094 | esac |
16095 | ||
ccc6cda3 JA |
16096 | case "$host_cpu" in |
16097 | *cray*) LOCAL_CFLAGS="-DCRAY" ;; # shell var so config.h can use it | |
16098 | esac | |
16099 | ||
16100 | case "$host_cpu-$host_os" in | |
16101 | ibmrt-*bsd4*) LOCAL_CFLAGS="-ma -U__STDC__" ;; | |
16102 | esac | |
16103 | ||
16104 | case "$host_cpu-$host_vendor-$host_os" in | |
16105 | m88k-motorola-sysv3) LOCAL_CFLAGS=-DWAITPID_BROKEN ;; | |
16106 | mips-pyramid-sysv4) LOCAL_CFLAGS=-Xa ;; | |
16107 | esac | |
16108 | ||
b72432fd JA |
16109 | # |
16110 | # Shared object configuration section. These values are generated by | |
16111 | # ${srcdir}/support/shobj-conf | |
16112 | # | |
16113 | if test "$ac_cv_func_dlopen" = "yes" && test -f ${srcdir}/support/shobj-conf | |
16114 | then | |
ac50fbac | 16115 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking shared object configuration for loadable builtins" >&5 |
3185942a | 16116 | $as_echo_n "checking shared object configuration for loadable builtins... " >&6; } |
28ef6c31 | 16117 | eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c "${host_cpu}" -o "${host_os}" -v "${host_vendor}"` |
f73dda09 | 16118 | |
b80f6443 JA |
16119 | |
16120 | ||
16121 | ||
16122 | ||
16123 | ||
16124 | ||
ac50fbac | 16125 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHOBJ_STATUS" >&5 |
3185942a | 16126 | $as_echo "$SHOBJ_STATUS" >&6; } |
b72432fd JA |
16127 | fi |
16128 | ||
ccc6cda3 JA |
16129 | # try to create a directory tree if the source is elsewhere |
16130 | # this should be packaged into a script accessible via ${srcdir}/support | |
16131 | case "$srcdir" in | |
16132 | .) ;; | |
cce855bc | 16133 | *) for d in doc tests support lib examples; do # dirs |
ccc6cda3 JA |
16134 | test -d $d || mkdir $d |
16135 | done | |
cce855bc | 16136 | for ld in readline glob tilde malloc sh termcap; do # libdirs |
ccc6cda3 JA |
16137 | test -d lib/$ld || mkdir lib/$ld |
16138 | done | |
cce855bc | 16139 | test -d examples/loadables || mkdir examples/loadables # loadable builtins |
bb70624e | 16140 | test -d examples/loadables/perl || mkdir examples/loadables/perl |
ccc6cda3 JA |
16141 | ;; |
16142 | esac | |
16143 | ||
16144 | BUILD_DIR=`pwd` | |
95732b49 JA |
16145 | case "$BUILD_DIR" in |
16146 | *\ *) BUILD_DIR=`echo "$BUILD_DIR" | sed 's: :\\\\ :g'` ;; | |
16147 | *) ;; | |
16148 | esac | |
ccc6cda3 | 16149 | |
3185942a JA |
16150 | if test -z "$localedir"; then |
16151 | localedir='${datarootdir}/locale' | |
16152 | fi | |
16153 | if test -z "$datarootdir"; then | |
16154 | datarootdir='${prefix}/share' | |
16155 | fi | |
16156 | ||
16157 | ||
16158 | ||
16159 | ||
b80f6443 JA |
16160 | |
16161 | ||
3185942a | 16162 | # Some versions of autoconf don't substitute these automatically |
b80f6443 JA |
16163 | |
16164 | ||
16165 | ||
a0c0a00f CR |
16166 | # directory where we install dynamically loadable builtins |
16167 | if test -z "$loadablesdir"; then | |
16168 | loadablesdir='${libdir}/bash' | |
16169 | fi | |
16170 | ||
16171 | if test -z "$headersdir"; then | |
16172 | headersdir='$(includedir)/$(PACKAGE_NAME)' | |
16173 | fi | |
16174 | ||
16175 | ||
b80f6443 JA |
16176 | |
16177 | ||
16178 | ||
16179 | ||
16180 | ||
16181 | ||
16182 | ||
16183 | ||
16184 | ||
16185 | ||
16186 | ||
16187 | ||
16188 | ||
16189 | ||
16190 | ||
16191 | ||
16192 | ||
16193 | ||
d166f048 JA |
16194 | #AC_SUBST(ALLOCA_SOURCE) |
16195 | #AC_SUBST(ALLOCA_OBJECT) | |
16196 | ||
a0c0a00f | 16197 | ac_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/perl/Makefile support/bash.pc" |
3185942a JA |
16198 | |
16199 | ac_config_commands="$ac_config_commands default" | |
16200 | ||
f73dda09 | 16201 | cat >confcache <<\_ACEOF |
ccc6cda3 JA |
16202 | # This file is a shell script that caches the results of configure |
16203 | # tests run on this system so they can be shared between configure | |
f73dda09 JA |
16204 | # scripts and configure runs, see configure's option --config-cache. |
16205 | # It is not useful on other systems. If it contains results you don't | |
16206 | # want to keep, you may remove or edit it. | |
726f6388 | 16207 | # |
f73dda09 JA |
16208 | # config.status only pays attention to the cache file if you give it |
16209 | # the --recheck option to rerun configure. | |
ccc6cda3 | 16210 | # |
0628567a | 16211 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
f73dda09 JA |
16212 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
16213 | # following values. | |
16214 | ||
16215 | _ACEOF | |
16216 | ||
ccc6cda3 JA |
16217 | # The following way of writing the cache mishandles newlines in values, |
16218 | # but we know of no workaround that is simple, portable, and efficient. | |
3185942a | 16219 | # So, we kill variables containing newlines. |
ccc6cda3 JA |
16220 | # Ultrix sh set writes to stderr and can't be redirected directly, |
16221 | # and sets the high bit in the cache file unless we assign to the vars. | |
3185942a JA |
16222 | ( |
16223 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
16224 | eval ac_val=\$$ac_var | |
16225 | case $ac_val in #( | |
16226 | *${as_nl}*) | |
16227 | case $ac_var in #( | |
ac50fbac | 16228 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
3185942a JA |
16229 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
16230 | esac | |
16231 | case $ac_var in #( | |
16232 | _ | IFS | as_nl) ;; #( | |
16233 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
ac50fbac | 16234 | *) { eval $ac_var=; unset $ac_var;} ;; |
3185942a JA |
16235 | esac ;; |
16236 | esac | |
16237 | done | |
16238 | ||
f73dda09 | 16239 | (set) 2>&1 | |
3185942a JA |
16240 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
16241 | *${as_nl}ac_space=\ *) | |
ac50fbac CR |
16242 | # `set' does not quote correctly, so add quotes: double-quote |
16243 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
f73dda09 | 16244 | sed -n \ |
0628567a JA |
16245 | "s/'/'\\\\''/g; |
16246 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
3185942a | 16247 | ;; #( |
f73dda09 JA |
16248 | *) |
16249 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
3185942a | 16250 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
f73dda09 | 16251 | ;; |
3185942a JA |
16252 | esac | |
16253 | sort | |
16254 | ) | | |
f73dda09 | 16255 | sed ' |
3185942a | 16256 | /^ac_cv_env_/b end |
f73dda09 | 16257 | t clear |
3185942a | 16258 | :clear |
f73dda09 JA |
16259 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
16260 | t end | |
3185942a JA |
16261 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
16262 | :end' >>confcache | |
16263 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
16264 | if test -w "$cache_file"; then | |
ac50fbac CR |
16265 | if test "x$cache_file" != "x/dev/null"; then |
16266 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 | |
3185942a | 16267 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
ac50fbac CR |
16268 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
16269 | cat confcache >"$cache_file" | |
16270 | else | |
16271 | case $cache_file in #( | |
16272 | */* | ?:*) | |
16273 | mv -f confcache "$cache_file"$$ && | |
16274 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
16275 | *) | |
16276 | mv -f confcache "$cache_file" ;; | |
16277 | esac | |
16278 | fi | |
16279 | fi | |
ccc6cda3 | 16280 | else |
ac50fbac | 16281 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
3185942a | 16282 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
ccc6cda3 JA |
16283 | fi |
16284 | fi | |
16285 | rm -f confcache | |
16286 | ||
ccc6cda3 JA |
16287 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
16288 | # Let make expand exec_prefix. | |
16289 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
16290 | ||
ccc6cda3 JA |
16291 | DEFS=-DHAVE_CONFIG_H |
16292 | ||
0628567a JA |
16293 | ac_libobjs= |
16294 | ac_ltlibobjs= | |
ac50fbac | 16295 | U= |
0628567a JA |
16296 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
16297 | # 1. Remove the extension, and $U if already installed. | |
3185942a JA |
16298 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
16299 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` | |
16300 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR | |
16301 | # will be set to the directory where LIBOBJS objects are built. | |
ac50fbac CR |
16302 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
16303 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
0628567a JA |
16304 | done |
16305 | LIBOBJS=$ac_libobjs | |
16306 | ||
16307 | LTLIBOBJS=$ac_ltlibobjs | |
16308 | ||
16309 | ||
b80f6443 | 16310 | |
3185942a | 16311 | |
ac50fbac | 16312 | : "${CONFIG_STATUS=./config.status}" |
3185942a | 16313 | ac_write_fail=0 |
f73dda09 JA |
16314 | ac_clean_files_save=$ac_clean_files |
16315 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
ac50fbac | 16316 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
3185942a | 16317 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
ac50fbac CR |
16318 | as_write_fail=0 |
16319 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
f73dda09 | 16320 | #! $SHELL |
b80f6443 | 16321 | # Generated by $as_me. |
ccc6cda3 | 16322 | # Run this file to recreate the current configuration. |
ccc6cda3 | 16323 | # Compiler output produced by configure, useful for debugging |
f73dda09 | 16324 | # configure, is in config.log if it exists. |
ccc6cda3 | 16325 | |
f73dda09 | 16326 | debug=false |
0628567a JA |
16327 | ac_cs_recheck=false |
16328 | ac_cs_silent=false | |
f73dda09 | 16329 | |
ac50fbac CR |
16330 | SHELL=\${CONFIG_SHELL-$SHELL} |
16331 | export SHELL | |
16332 | _ASEOF | |
16333 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
16334 | ## -------------------- ## | |
16335 | ## M4sh Initialization. ## | |
16336 | ## -------------------- ## | |
b80f6443 | 16337 | |
3185942a JA |
16338 | # Be more Bourne compatible |
16339 | DUALCASE=1; export DUALCASE # for MKS sh | |
ac50fbac | 16340 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
f73dda09 JA |
16341 | emulate sh |
16342 | NULLCMD=: | |
3185942a | 16343 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
0628567a JA |
16344 | # is contrary to our usage. Disable this feature. |
16345 | alias -g '${1+"$@"}'='"$@"' | |
3185942a JA |
16346 | setopt NO_GLOB_SUBST |
16347 | else | |
ac50fbac CR |
16348 | case `(set -o) 2>/dev/null` in #( |
16349 | *posix*) : | |
16350 | set -o posix ;; #( | |
16351 | *) : | |
16352 | ;; | |
3185942a | 16353 | esac |
3185942a JA |
16354 | fi |
16355 | ||
16356 | ||
3185942a JA |
16357 | as_nl=' |
16358 | ' | |
16359 | export as_nl | |
16360 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
16361 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
16362 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
16363 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
ac50fbac CR |
16364 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
16365 | # but without wasting forks for bash or zsh. | |
16366 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
16367 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
16368 | as_echo='print -r --' | |
16369 | as_echo_n='print -rn --' | |
16370 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
3185942a JA |
16371 | as_echo='printf %s\n' |
16372 | as_echo_n='printf %s' | |
16373 | else | |
16374 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
16375 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
16376 | as_echo_n='/usr/ucb/echo -n' | |
16377 | else | |
16378 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
16379 | as_echo_n_body='eval | |
16380 | arg=$1; | |
ac50fbac | 16381 | case $arg in #( |
3185942a JA |
16382 | *"$as_nl"*) |
16383 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
16384 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
16385 | esac; | |
16386 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
16387 | ' | |
16388 | export as_echo_n_body | |
16389 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
16390 | fi | |
16391 | export as_echo_body | |
16392 | as_echo='sh -c $as_echo_body as_echo' | |
16393 | fi | |
16394 | ||
16395 | # The user is always right. | |
16396 | if test "${PATH_SEPARATOR+set}" != set; then | |
16397 | PATH_SEPARATOR=: | |
16398 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
16399 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
16400 | PATH_SEPARATOR=';' | |
16401 | } | |
f73dda09 JA |
16402 | fi |
16403 | ||
0628567a | 16404 | |
3185942a JA |
16405 | # IFS |
16406 | # We need space, tab and new line, in precisely that order. Quoting is | |
16407 | # there to prevent editors from complaining about space-tab. | |
16408 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
16409 | # splitting by setting IFS to empty value.) | |
16410 | IFS=" "" $as_nl" | |
16411 | ||
16412 | # Find who we are. Look in the path if we contain no directory separator. | |
ac50fbac CR |
16413 | as_myself= |
16414 | case $0 in #(( | |
3185942a JA |
16415 | *[\\/]* ) as_myself=$0 ;; |
16416 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
16417 | for as_dir in $PATH | |
16418 | do | |
16419 | IFS=$as_save_IFS | |
16420 | test -z "$as_dir" && as_dir=. | |
ac50fbac CR |
16421 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
16422 | done | |
3185942a JA |
16423 | IFS=$as_save_IFS |
16424 | ||
16425 | ;; | |
16426 | esac | |
16427 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
16428 | # in which case we are not to be found in the path. | |
16429 | if test "x$as_myself" = x; then | |
16430 | as_myself=$0 | |
16431 | fi | |
16432 | if test ! -f "$as_myself"; then | |
16433 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
ac50fbac | 16434 | exit 1 |
3185942a JA |
16435 | fi |
16436 | ||
ac50fbac CR |
16437 | # Unset variables that we do not need and which cause bugs (e.g. in |
16438 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
16439 | # suppresses any "Segmentation fault" message there. '((' could | |
16440 | # trigger a bug in pdksh 5.2.14. | |
16441 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
16442 | do eval test x\${$as_var+set} = xset \ | |
16443 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
3185942a | 16444 | done |
0628567a JA |
16445 | PS1='$ ' |
16446 | PS2='> ' | |
16447 | PS4='+ ' | |
16448 | ||
16449 | # NLS nuisances. | |
3185942a JA |
16450 | LC_ALL=C |
16451 | export LC_ALL | |
16452 | LANGUAGE=C | |
16453 | export LANGUAGE | |
0628567a | 16454 | |
ac50fbac CR |
16455 | # CDPATH. |
16456 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
16457 | ||
16458 | ||
16459 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
16460 | # ---------------------------------------- | |
16461 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
16462 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
16463 | # script with STATUS, using 1 if that was 0. | |
16464 | as_fn_error () | |
16465 | { | |
16466 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
16467 | if test "$4"; then | |
16468 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
16469 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
16470 | fi | |
16471 | $as_echo "$as_me: error: $2" >&2 | |
16472 | as_fn_exit $as_status | |
16473 | } # as_fn_error | |
16474 | ||
16475 | ||
16476 | # as_fn_set_status STATUS | |
16477 | # ----------------------- | |
16478 | # Set $? to STATUS, without forking. | |
16479 | as_fn_set_status () | |
16480 | { | |
16481 | return $1 | |
16482 | } # as_fn_set_status | |
16483 | ||
16484 | # as_fn_exit STATUS | |
16485 | # ----------------- | |
16486 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
16487 | as_fn_exit () | |
16488 | { | |
16489 | set +e | |
16490 | as_fn_set_status $1 | |
16491 | exit $1 | |
16492 | } # as_fn_exit | |
16493 | ||
16494 | # as_fn_unset VAR | |
16495 | # --------------- | |
16496 | # Portably unset VAR. | |
16497 | as_fn_unset () | |
16498 | { | |
16499 | { eval $1=; unset $1;} | |
16500 | } | |
16501 | as_unset=as_fn_unset | |
16502 | # as_fn_append VAR VALUE | |
16503 | # ---------------------- | |
16504 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
16505 | # advantage of any shell optimizations that allow amortized linear growth over | |
16506 | # repeated appends, instead of the typical quadratic growth present in naive | |
16507 | # implementations. | |
16508 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
16509 | eval 'as_fn_append () | |
16510 | { | |
16511 | eval $1+=\$2 | |
16512 | }' | |
16513 | else | |
16514 | as_fn_append () | |
16515 | { | |
16516 | eval $1=\$$1\$2 | |
16517 | } | |
16518 | fi # as_fn_append | |
16519 | ||
16520 | # as_fn_arith ARG... | |
16521 | # ------------------ | |
16522 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
16523 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
16524 | # must be portable across $(()) and expr. | |
16525 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
16526 | eval 'as_fn_arith () | |
16527 | { | |
16528 | as_val=$(( $* )) | |
16529 | }' | |
16530 | else | |
16531 | as_fn_arith () | |
16532 | { | |
16533 | as_val=`expr "$@" || test $? -eq 1` | |
16534 | } | |
16535 | fi # as_fn_arith | |
16536 | ||
16537 | ||
3185942a JA |
16538 | if expr a : '\(a\)' >/dev/null 2>&1 && |
16539 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
0628567a JA |
16540 | as_expr=expr |
16541 | else | |
16542 | as_expr=false | |
16543 | fi | |
16544 | ||
3185942a | 16545 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
0628567a JA |
16546 | as_basename=basename |
16547 | else | |
16548 | as_basename=false | |
16549 | fi | |
b80f6443 | 16550 | |
ac50fbac CR |
16551 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
16552 | as_dirname=dirname | |
16553 | else | |
16554 | as_dirname=false | |
16555 | fi | |
b80f6443 | 16556 | |
3185942a | 16557 | as_me=`$as_basename -- "$0" || |
b80f6443 JA |
16558 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
16559 | X"$0" : 'X\(//\)$' \| \ | |
3185942a JA |
16560 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
16561 | $as_echo X/"$0" | | |
16562 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
16563 | s//\1/ | |
16564 | q | |
16565 | } | |
16566 | /^X\/\(\/\/\)$/{ | |
16567 | s//\1/ | |
16568 | q | |
16569 | } | |
16570 | /^X\/\(\/\).*/{ | |
16571 | s//\1/ | |
16572 | q | |
16573 | } | |
16574 | s/.*/./; q'` | |
b80f6443 | 16575 | |
ac50fbac CR |
16576 | # Avoid depending upon Character Ranges. |
16577 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
16578 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
16579 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
16580 | as_cr_digits='0123456789' | |
16581 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
f73dda09 | 16582 | |
3185942a | 16583 | ECHO_C= ECHO_N= ECHO_T= |
ac50fbac | 16584 | case `echo -n x` in #((((( |
3185942a | 16585 | -n*) |
ac50fbac | 16586 | case `echo 'xy\c'` in |
3185942a | 16587 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
ac50fbac CR |
16588 | xy) ECHO_C='\c';; |
16589 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
16590 | ECHO_T=' ';; | |
3185942a JA |
16591 | esac;; |
16592 | *) | |
16593 | ECHO_N='-n';; | |
16594 | esac | |
f73dda09 JA |
16595 | |
16596 | rm -f conf$$ conf$$.exe conf$$.file | |
3185942a JA |
16597 | if test -d conf$$.dir; then |
16598 | rm -f conf$$.dir/conf$$.file | |
16599 | else | |
16600 | rm -f conf$$.dir | |
16601 | mkdir conf$$.dir 2>/dev/null | |
16602 | fi | |
16603 | if (echo >conf$$.file) 2>/dev/null; then | |
16604 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
f73dda09 | 16605 | as_ln_s='ln -s' |
3185942a JA |
16606 | # ... but there are two gotchas: |
16607 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
16608 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
ac50fbac | 16609 | # In both cases, we have to default to `cp -pR'. |
3185942a | 16610 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
ac50fbac | 16611 | as_ln_s='cp -pR' |
3185942a JA |
16612 | elif ln conf$$.file conf$$ 2>/dev/null; then |
16613 | as_ln_s=ln | |
16614 | else | |
ac50fbac | 16615 | as_ln_s='cp -pR' |
f73dda09 | 16616 | fi |
f73dda09 | 16617 | else |
ac50fbac | 16618 | as_ln_s='cp -pR' |
f73dda09 | 16619 | fi |
3185942a JA |
16620 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
16621 | rmdir conf$$.dir 2>/dev/null | |
f73dda09 | 16622 | |
ac50fbac CR |
16623 | |
16624 | # as_fn_mkdir_p | |
16625 | # ------------- | |
16626 | # Create "$as_dir" as a directory, including parents if necessary. | |
16627 | as_fn_mkdir_p () | |
16628 | { | |
16629 | ||
16630 | case $as_dir in #( | |
16631 | -*) as_dir=./$as_dir;; | |
16632 | esac | |
16633 | test -d "$as_dir" || eval $as_mkdir_p || { | |
16634 | as_dirs= | |
16635 | while :; do | |
16636 | case $as_dir in #( | |
16637 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
16638 | *) as_qdir=$as_dir;; | |
16639 | esac | |
16640 | as_dirs="'$as_qdir' $as_dirs" | |
16641 | as_dir=`$as_dirname -- "$as_dir" || | |
16642 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
16643 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
16644 | X"$as_dir" : 'X\(//\)$' \| \ | |
16645 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
16646 | $as_echo X"$as_dir" | | |
16647 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
16648 | s//\1/ | |
16649 | q | |
16650 | } | |
16651 | /^X\(\/\/\)[^/].*/{ | |
16652 | s//\1/ | |
16653 | q | |
16654 | } | |
16655 | /^X\(\/\/\)$/{ | |
16656 | s//\1/ | |
16657 | q | |
16658 | } | |
16659 | /^X\(\/\).*/{ | |
16660 | s//\1/ | |
16661 | q | |
16662 | } | |
16663 | s/.*/./; q'` | |
16664 | test -d "$as_dir" && break | |
16665 | done | |
16666 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
16667 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
16668 | ||
16669 | ||
16670 | } # as_fn_mkdir_p | |
0628567a | 16671 | if mkdir -p . 2>/dev/null; then |
ac50fbac | 16672 | as_mkdir_p='mkdir -p "$as_dir"' |
0628567a JA |
16673 | else |
16674 | test -d ./-p && rmdir ./-p | |
16675 | as_mkdir_p=false | |
16676 | fi | |
16677 | ||
ac50fbac CR |
16678 | |
16679 | # as_fn_executable_p FILE | |
16680 | # ----------------------- | |
16681 | # Test if FILE is an executable regular file. | |
16682 | as_fn_executable_p () | |
16683 | { | |
16684 | test -f "$1" && test -x "$1" | |
16685 | } # as_fn_executable_p | |
16686 | as_test_x='test -x' | |
16687 | as_executable_p=as_fn_executable_p | |
b80f6443 JA |
16688 | |
16689 | # Sed expression to map a string onto a valid CPP name. | |
0628567a | 16690 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
b80f6443 JA |
16691 | |
16692 | # Sed expression to map a string onto a valid variable name. | |
0628567a | 16693 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
b80f6443 | 16694 | |
f73dda09 | 16695 | |
f73dda09 | 16696 | exec 6>&1 |
ac50fbac CR |
16697 | ## ----------------------------------- ## |
16698 | ## Main body of $CONFIG_STATUS script. ## | |
16699 | ## ----------------------------------- ## | |
16700 | _ASEOF | |
16701 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
f73dda09 | 16702 | |
ac50fbac CR |
16703 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16704 | # Save the log message, to keep $0 and so on meaningful, and to | |
b80f6443 | 16705 | # report actual input values of CONFIG_FILES etc. instead of their |
3185942a JA |
16706 | # values after options handling. |
16707 | ac_log=" | |
a0c0a00f | 16708 | This file was extended by bash $as_me 4.4-release, which was |
ac50fbac | 16709 | generated by GNU Autoconf 2.69. Invocation command line was |
b80f6443 JA |
16710 | |
16711 | CONFIG_FILES = $CONFIG_FILES | |
16712 | CONFIG_HEADERS = $CONFIG_HEADERS | |
16713 | CONFIG_LINKS = $CONFIG_LINKS | |
16714 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
16715 | $ $0 $@ | |
16716 | ||
3185942a JA |
16717 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
16718 | " | |
16719 | ||
f73dda09 JA |
16720 | _ACEOF |
16721 | ||
3185942a JA |
16722 | case $ac_config_files in *" |
16723 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
16724 | esac | |
f73dda09 | 16725 | |
3185942a JA |
16726 | case $ac_config_headers in *" |
16727 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
16728 | esac | |
f73dda09 | 16729 | |
f73dda09 | 16730 | |
3185942a JA |
16731 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
16732 | # Files that config.status was made for. | |
16733 | config_files="$ac_config_files" | |
16734 | config_headers="$ac_config_headers" | |
16735 | config_commands="$ac_config_commands" | |
f73dda09 | 16736 | |
3185942a | 16737 | _ACEOF |
f73dda09 | 16738 | |
3185942a | 16739 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 | 16740 | ac_cs_usage="\ |
ac50fbac CR |
16741 | \`$as_me' instantiates files and other configuration actions |
16742 | from templates according to the current configuration. Unless the files | |
16743 | and actions are specified as TAGs, all are instantiated by default. | |
f73dda09 | 16744 | |
ac50fbac | 16745 | Usage: $0 [OPTION]... [TAG]... |
f73dda09 JA |
16746 | |
16747 | -h, --help print this help, then exit | |
3185942a | 16748 | -V, --version print version number and configuration settings, then exit |
ac50fbac | 16749 | --config print configuration, then exit |
3185942a JA |
16750 | -q, --quiet, --silent |
16751 | do not print progress messages | |
f73dda09 JA |
16752 | -d, --debug don't remove temporary files |
16753 | --recheck update $as_me by reconfiguring in the same conditions | |
3185942a JA |
16754 | --file=FILE[:TEMPLATE] |
16755 | instantiate the configuration file FILE | |
16756 | --header=FILE[:TEMPLATE] | |
16757 | instantiate the configuration header FILE | |
f73dda09 JA |
16758 | |
16759 | Configuration files: | |
16760 | $config_files | |
16761 | ||
16762 | Configuration headers: | |
16763 | $config_headers | |
16764 | ||
16765 | Configuration commands: | |
16766 | $config_commands | |
16767 | ||
ac50fbac | 16768 | Report bugs to <bug-bash@gnu.org>." |
f73dda09 | 16769 | |
3185942a JA |
16770 | _ACEOF |
16771 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
ac50fbac | 16772 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
f73dda09 | 16773 | ac_cs_version="\\ |
a0c0a00f | 16774 | bash config.status 4.4-release |
ac50fbac CR |
16775 | configured by $0, generated by GNU Autoconf 2.69, |
16776 | with options \\"\$ac_cs_config\\" | |
f73dda09 | 16777 | |
ac50fbac | 16778 | Copyright (C) 2012 Free Software Foundation, Inc. |
f73dda09 JA |
16779 | This config.status script is free software; the Free Software Foundation |
16780 | gives unlimited permission to copy, distribute and modify it." | |
3185942a JA |
16781 | |
16782 | ac_pwd='$ac_pwd' | |
16783 | srcdir='$srcdir' | |
16784 | INSTALL='$INSTALL' | |
16785 | test -n "\$AWK" || AWK=awk | |
b80f6443 | 16786 | _ACEOF |
f73dda09 | 16787 | |
3185942a JA |
16788 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16789 | # The default lists apply if the user does not specify any file. | |
f73dda09 JA |
16790 | ac_need_defaults=: |
16791 | while test $# != 0 | |
ccc6cda3 | 16792 | do |
f73dda09 | 16793 | case $1 in |
ac50fbac | 16794 | --*=?*) |
3185942a JA |
16795 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
16796 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
0628567a JA |
16797 | ac_shift=: |
16798 | ;; | |
ac50fbac CR |
16799 | --*=) |
16800 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
16801 | ac_optarg= | |
16802 | ac_shift=: | |
16803 | ;; | |
3185942a | 16804 | *) |
0628567a JA |
16805 | ac_option=$1 |
16806 | ac_optarg=$2 | |
16807 | ac_shift=shift | |
f73dda09 | 16808 | ;; |
f73dda09 JA |
16809 | esac |
16810 | ||
0628567a | 16811 | case $ac_option in |
f73dda09 | 16812 | # Handling of the options. |
0628567a JA |
16813 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
16814 | ac_cs_recheck=: ;; | |
3185942a JA |
16815 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
16816 | $as_echo "$ac_cs_version"; exit ;; | |
ac50fbac CR |
16817 | --config | --confi | --conf | --con | --co | --c ) |
16818 | $as_echo "$ac_cs_config"; exit ;; | |
3185942a | 16819 | --debug | --debu | --deb | --de | --d | -d ) |
f73dda09 JA |
16820 | debug=: ;; |
16821 | --file | --fil | --fi | --f ) | |
0628567a | 16822 | $ac_shift |
3185942a JA |
16823 | case $ac_optarg in |
16824 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
ac50fbac | 16825 | '') as_fn_error $? "missing file argument" ;; |
3185942a | 16826 | esac |
ac50fbac | 16827 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
f73dda09 JA |
16828 | ac_need_defaults=false;; |
16829 | --header | --heade | --head | --hea ) | |
0628567a | 16830 | $ac_shift |
3185942a JA |
16831 | case $ac_optarg in |
16832 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
16833 | esac | |
ac50fbac | 16834 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
f73dda09 | 16835 | ac_need_defaults=false;; |
3185942a JA |
16836 | --he | --h) |
16837 | # Conflict between --help and --header | |
ac50fbac CR |
16838 | as_fn_error $? "ambiguous option: \`$1' |
16839 | Try \`$0 --help' for more information.";; | |
3185942a JA |
16840 | --help | --hel | -h ) |
16841 | $as_echo "$ac_cs_usage"; exit ;; | |
0628567a JA |
16842 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
16843 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
16844 | ac_cs_silent=: ;; | |
f73dda09 JA |
16845 | |
16846 | # This is an error. | |
ac50fbac CR |
16847 | -*) as_fn_error $? "unrecognized option: \`$1' |
16848 | Try \`$0 --help' for more information." ;; | |
f73dda09 | 16849 | |
ac50fbac | 16850 | *) as_fn_append ac_config_targets " $1" |
3185942a | 16851 | ac_need_defaults=false ;; |
f73dda09 | 16852 | |
ccc6cda3 | 16853 | esac |
f73dda09 | 16854 | shift |
ccc6cda3 JA |
16855 | done |
16856 | ||
0628567a JA |
16857 | ac_configure_extra_args= |
16858 | ||
16859 | if $ac_cs_silent; then | |
16860 | exec 6>/dev/null | |
16861 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
16862 | fi | |
16863 | ||
16864 | _ACEOF | |
3185942a | 16865 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
0628567a | 16866 | if \$ac_cs_recheck; then |
ac50fbac | 16867 | set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
3185942a JA |
16868 | shift |
16869 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
16870 | CONFIG_SHELL='$SHELL' | |
16871 | export CONFIG_SHELL | |
16872 | exec "\$@" | |
0628567a JA |
16873 | fi |
16874 | ||
b80f6443 | 16875 | _ACEOF |
3185942a JA |
16876 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16877 | exec 5>>config.log | |
16878 | { | |
16879 | echo | |
16880 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
16881 | ## Running $as_me. ## | |
16882 | _ASBOX | |
16883 | $as_echo "$ac_log" | |
16884 | } >&5 | |
b80f6443 | 16885 | |
3185942a JA |
16886 | _ACEOF |
16887 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
b80f6443 | 16888 | # |
3185942a | 16889 | # INIT-COMMANDS |
b80f6443 | 16890 | # |
b80f6443 JA |
16891 | # Capture the value of obsolete ALL_LINGUAS because we need it to compute |
16892 | # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it | |
16893 | # from automake. | |
16894 | eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' | |
16895 | # Capture the value of LINGUAS because we need it to compute CATALOGS. | |
16896 | LINGUAS="${LINGUAS-%UNSET%}" | |
f73dda09 | 16897 | |
f73dda09 JA |
16898 | |
16899 | _ACEOF | |
ccc6cda3 | 16900 | |
3185942a | 16901 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b80f6443 | 16902 | |
3185942a | 16903 | # Handling of arguments. |
f73dda09 JA |
16904 | for ac_config_target in $ac_config_targets |
16905 | do | |
3185942a JA |
16906 | case $ac_config_target in |
16907 | "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; | |
16908 | "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; | |
16909 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; | |
16910 | "builtins/Makefile") CONFIG_FILES="$CONFIG_FILES builtins/Makefile" ;; | |
16911 | "lib/readline/Makefile") CONFIG_FILES="$CONFIG_FILES lib/readline/Makefile" ;; | |
16912 | "lib/glob/Makefile") CONFIG_FILES="$CONFIG_FILES lib/glob/Makefile" ;; | |
16913 | "lib/intl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/intl/Makefile" ;; | |
16914 | "lib/malloc/Makefile") CONFIG_FILES="$CONFIG_FILES lib/malloc/Makefile" ;; | |
16915 | "lib/sh/Makefile") CONFIG_FILES="$CONFIG_FILES lib/sh/Makefile" ;; | |
16916 | "lib/termcap/Makefile") CONFIG_FILES="$CONFIG_FILES lib/termcap/Makefile" ;; | |
16917 | "lib/tilde/Makefile") CONFIG_FILES="$CONFIG_FILES lib/tilde/Makefile" ;; | |
16918 | "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;; | |
16919 | "support/Makefile") CONFIG_FILES="$CONFIG_FILES support/Makefile" ;; | |
16920 | "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; | |
16921 | "examples/loadables/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile" ;; | |
a0c0a00f | 16922 | "examples/loadables/Makefile.inc") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile.inc" ;; |
3185942a | 16923 | "examples/loadables/perl/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/perl/Makefile" ;; |
a0c0a00f | 16924 | "support/bash.pc") CONFIG_FILES="$CONFIG_FILES support/bash.pc" ;; |
3185942a JA |
16925 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; |
16926 | ||
ac50fbac | 16927 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
f73dda09 JA |
16928 | esac |
16929 | done | |
16930 | ||
3185942a | 16931 | |
f73dda09 JA |
16932 | # If the user did not use the arguments to specify the items to instantiate, |
16933 | # then the envvar interface is used. Set only those that are not. | |
16934 | # We use the long form for the default assignment because of an extremely | |
16935 | # bizarre bug on SunOS 4.1.3. | |
16936 | if $ac_need_defaults; then | |
16937 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
16938 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
16939 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
16940 | fi | |
16941 | ||
0628567a | 16942 | # Have a temporary directory for convenience. Make it in the build tree |
3185942a | 16943 | # simply because there is no reason against having it here, and in addition, |
0628567a | 16944 | # creating and moving files from /tmp can sometimes cause problems. |
3185942a JA |
16945 | # Hook for its removal unless debugging. |
16946 | # Note that there is a small window in which the directory will not be cleaned: | |
16947 | # after its creation but before its name has been assigned to `$tmp'. | |
f73dda09 JA |
16948 | $debug || |
16949 | { | |
ac50fbac | 16950 | tmp= ac_tmp= |
3185942a | 16951 | trap 'exit_status=$? |
ac50fbac CR |
16952 | : "${ac_tmp:=$tmp}" |
16953 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
3185942a | 16954 | ' 0 |
ac50fbac | 16955 | trap 'as_fn_exit 1' 1 2 13 15 |
f73dda09 | 16956 | } |
f73dda09 | 16957 | # Create a (secure) tmp directory for tmp files. |
0628567a | 16958 | |
f73dda09 | 16959 | { |
3185942a | 16960 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
ac50fbac | 16961 | test -d "$tmp" |
f73dda09 JA |
16962 | } || |
16963 | { | |
3185942a JA |
16964 | tmp=./conf$$-$RANDOM |
16965 | (umask 077 && mkdir "$tmp") | |
ac50fbac CR |
16966 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
16967 | ac_tmp=$tmp | |
ccc6cda3 | 16968 | |
3185942a JA |
16969 | # Set up the scripts for CONFIG_FILES section. |
16970 | # No need to generate them if there are no CONFIG_FILES. | |
16971 | # This happens for instance with `./config.status config.h'. | |
16972 | if test -n "$CONFIG_FILES"; then | |
16973 | ||
16974 | ||
ac50fbac CR |
16975 | ac_cr=`echo X | tr X '\015'` |
16976 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
16977 | # But we know of no other shell where ac_cr would be empty at this | |
16978 | # point, so we can use a bashism as a fallback. | |
16979 | if test "x$ac_cr" = x; then | |
16980 | eval ac_cr=\$\'\\r\' | |
16981 | fi | |
3185942a JA |
16982 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
16983 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
16984 | ac_cs_awk_cr='\\r' | |
16985 | else | |
16986 | ac_cs_awk_cr=$ac_cr | |
16987 | fi | |
16988 | ||
ac50fbac | 16989 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
b80f6443 | 16990 | _ACEOF |
ccc6cda3 | 16991 | |
ccc6cda3 | 16992 | |
3185942a JA |
16993 | { |
16994 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
16995 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
16996 | echo "_ACEOF" | |
16997 | } >conf$$subs.sh || | |
ac50fbac CR |
16998 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
16999 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
3185942a JA |
17000 | ac_delim='%!_!# ' |
17001 | for ac_last_try in false false false false false :; do | |
17002 | . ./conf$$subs.sh || | |
ac50fbac | 17003 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
f73dda09 | 17004 | |
3185942a JA |
17005 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
17006 | if test $ac_delim_n = $ac_delim_num; then | |
17007 | break | |
17008 | elif $ac_last_try; then | |
ac50fbac | 17009 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
3185942a JA |
17010 | else |
17011 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
ccc6cda3 | 17012 | fi |
3185942a JA |
17013 | done |
17014 | rm -f conf$$subs.sh | |
17015 | ||
17016 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
ac50fbac | 17017 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
3185942a JA |
17018 | _ACEOF |
17019 | sed -n ' | |
17020 | h | |
17021 | s/^/S["/; s/!.*/"]=/ | |
17022 | p | |
17023 | g | |
17024 | s/^[^!]*!// | |
17025 | :repl | |
17026 | t repl | |
17027 | s/'"$ac_delim"'$// | |
17028 | t delim | |
17029 | :nl | |
17030 | h | |
ac50fbac | 17031 | s/\(.\{148\}\)..*/\1/ |
3185942a JA |
17032 | t more1 |
17033 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
17034 | p | |
17035 | n | |
17036 | b repl | |
17037 | :more1 | |
17038 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
17039 | p | |
17040 | g | |
17041 | s/.\{148\}// | |
17042 | t nl | |
17043 | :delim | |
17044 | h | |
ac50fbac | 17045 | s/\(.\{148\}\)..*/\1/ |
3185942a JA |
17046 | t more2 |
17047 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
17048 | p | |
17049 | b | |
17050 | :more2 | |
17051 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
17052 | p | |
17053 | g | |
17054 | s/.\{148\}// | |
17055 | t delim | |
17056 | ' <conf$$subs.awk | sed ' | |
17057 | /^[^""]/{ | |
17058 | N | |
17059 | s/\n// | |
17060 | } | |
17061 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
17062 | rm -f conf$$subs.awk | |
17063 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17064 | _ACAWK | |
ac50fbac | 17065 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
3185942a JA |
17066 | for (key in S) S_is_set[key] = 1 |
17067 | FS = "\a" | |
17068 | ||
17069 | } | |
17070 | { | |
17071 | line = $ 0 | |
17072 | nfields = split(line, field, "@") | |
17073 | substed = 0 | |
17074 | len = length(field[1]) | |
17075 | for (i = 2; i < nfields; i++) { | |
17076 | key = field[i] | |
17077 | keylen = length(key) | |
17078 | if (S_is_set[key]) { | |
17079 | value = S[key] | |
17080 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
17081 | len += length(value) + length(field[++i]) | |
17082 | substed = 1 | |
17083 | } else | |
17084 | len += 1 + keylen | |
17085 | } | |
17086 | ||
17087 | print line | |
17088 | } | |
17089 | ||
17090 | _ACAWK | |
17091 | _ACEOF | |
17092 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
17093 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
17094 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
17095 | else | |
17096 | cat | |
ac50fbac CR |
17097 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
17098 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 | |
3185942a JA |
17099 | _ACEOF |
17100 | ||
ac50fbac CR |
17101 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
17102 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
3185942a JA |
17103 | # trailing colons and then remove the whole line if VPATH becomes empty |
17104 | # (actually we leave an empty line to preserve line numbers). | |
17105 | if test "x$srcdir" = x.; then | |
ac50fbac CR |
17106 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
17107 | h | |
17108 | s/// | |
17109 | s/^/:/ | |
17110 | s/[ ]*$/:/ | |
17111 | s/:\$(srcdir):/:/g | |
17112 | s/:\${srcdir}:/:/g | |
17113 | s/:@srcdir@:/:/g | |
17114 | s/^:*// | |
3185942a | 17115 | s/:*$// |
ac50fbac CR |
17116 | x |
17117 | s/\(=[ ]*\).*/\1/ | |
17118 | G | |
17119 | s/\n// | |
3185942a JA |
17120 | s/^[^=]*=[ ]*$// |
17121 | }' | |
17122 | fi | |
17123 | ||
17124 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
f73dda09 | 17125 | fi # test -n "$CONFIG_FILES" |
ccc6cda3 | 17126 | |
3185942a JA |
17127 | # Set up the scripts for CONFIG_HEADERS section. |
17128 | # No need to generate them if there are no CONFIG_HEADERS. | |
17129 | # This happens for instance with `./config.status Makefile'. | |
17130 | if test -n "$CONFIG_HEADERS"; then | |
ac50fbac | 17131 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
3185942a | 17132 | BEGIN { |
b80f6443 | 17133 | _ACEOF |
3185942a JA |
17134 | |
17135 | # Transform confdefs.h into an awk script `defines.awk', embedded as | |
17136 | # here-document in config.status, that substitutes the proper values into | |
17137 | # config.h.in to produce config.h. | |
17138 | ||
17139 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
17140 | # handling of long lines. | |
17141 | ac_delim='%!_!# ' | |
17142 | for ac_last_try in false false :; do | |
ac50fbac CR |
17143 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
17144 | if test -z "$ac_tt"; then | |
3185942a JA |
17145 | break |
17146 | elif $ac_last_try; then | |
ac50fbac | 17147 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
3185942a JA |
17148 | else |
17149 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
17150 | fi | |
17151 | done | |
17152 | ||
17153 | # For the awk script, D is an array of macro values keyed by name, | |
17154 | # likewise P contains macro parameters if any. Preserve backslash | |
17155 | # newline sequences. | |
17156 | ||
17157 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
17158 | sed -n ' | |
17159 | s/.\{148\}/&'"$ac_delim"'/g | |
17160 | t rset | |
17161 | :rset | |
17162 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
17163 | t def | |
17164 | d | |
17165 | :def | |
17166 | s/\\$// | |
17167 | t bsnl | |
17168 | s/["\\]/\\&/g | |
17169 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
17170 | D["\1"]=" \3"/p | |
17171 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
17172 | d | |
17173 | :bsnl | |
17174 | s/["\\]/\\&/g | |
17175 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
17176 | D["\1"]=" \3\\\\\\n"\\/p | |
17177 | t cont | |
17178 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
17179 | t cont | |
17180 | d | |
17181 | :cont | |
17182 | n | |
17183 | s/.\{148\}/&'"$ac_delim"'/g | |
17184 | t clear | |
17185 | :clear | |
17186 | s/\\$// | |
17187 | t bsnlc | |
17188 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
17189 | d | |
17190 | :bsnlc | |
17191 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
17192 | b cont | |
17193 | ' <confdefs.h | sed ' | |
17194 | s/'"$ac_delim"'/"\\\ | |
17195 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
17196 | ||
17197 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17198 | for (key in D) D_is_set[key] = 1 | |
17199 | FS = "\a" | |
17200 | } | |
17201 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
17202 | line = \$ 0 | |
17203 | split(line, arg, " ") | |
17204 | if (arg[1] == "#") { | |
17205 | defundef = arg[2] | |
17206 | mac1 = arg[3] | |
17207 | } else { | |
17208 | defundef = substr(arg[1], 2) | |
17209 | mac1 = arg[2] | |
17210 | } | |
17211 | split(mac1, mac2, "(") #) | |
17212 | macro = mac2[1] | |
17213 | prefix = substr(line, 1, index(line, defundef) - 1) | |
17214 | if (D_is_set[macro]) { | |
17215 | # Preserve the white space surrounding the "#". | |
17216 | print prefix "define", macro P[macro] D[macro] | |
17217 | next | |
17218 | } else { | |
17219 | # Replace #undef with comments. This is necessary, for example, | |
17220 | # in the case of _POSIX_SOURCE, which is predefined and required | |
17221 | # on some systems where configure will not decide to define it. | |
17222 | if (defundef == "undef") { | |
17223 | print "/*", prefix defundef, macro, "*/" | |
17224 | next | |
17225 | } | |
17226 | } | |
17227 | } | |
17228 | { print } | |
17229 | _ACAWK | |
17230 | _ACEOF | |
17231 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
ac50fbac | 17232 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
3185942a JA |
17233 | fi # test -n "$CONFIG_HEADERS" |
17234 | ||
17235 | ||
17236 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" | |
17237 | shift | |
17238 | for ac_tag | |
17239 | do | |
17240 | case $ac_tag in | |
17241 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
17242 | esac | |
17243 | case $ac_mode$ac_tag in | |
17244 | :[FHL]*:*);; | |
ac50fbac | 17245 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
3185942a JA |
17246 | :[FH]-) ac_tag=-:-;; |
17247 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
17248 | esac | |
17249 | ac_save_IFS=$IFS | |
17250 | IFS=: | |
17251 | set x $ac_tag | |
17252 | IFS=$ac_save_IFS | |
17253 | shift | |
17254 | ac_file=$1 | |
17255 | shift | |
17256 | ||
17257 | case $ac_mode in | |
17258 | :L) ac_source=$1;; | |
17259 | :[FH]) | |
17260 | ac_file_inputs= | |
17261 | for ac_f | |
17262 | do | |
17263 | case $ac_f in | |
ac50fbac | 17264 | -) ac_f="$ac_tmp/stdin";; |
3185942a JA |
17265 | *) # Look for the file first in the build tree, then in the source tree |
17266 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
17267 | # because $ac_f cannot contain `:'. | |
17268 | test -f "$ac_f" || | |
17269 | case $ac_f in | |
17270 | [\\/$]*) false;; | |
17271 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
17272 | esac || | |
ac50fbac | 17273 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
3185942a JA |
17274 | esac |
17275 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac | |
ac50fbac | 17276 | as_fn_append ac_file_inputs " '$ac_f'" |
3185942a JA |
17277 | done |
17278 | ||
17279 | # Let's still pretend it is `configure' which instantiates (i.e., don't | |
17280 | # use $as_me), people would be surprised to read: | |
17281 | # /* config.h. Generated by config.status. */ | |
17282 | configure_input='Generated from '` | |
17283 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
17284 | `' by configure.' | |
17285 | if test x"$ac_file" != x-; then | |
17286 | configure_input="$ac_file. $configure_input" | |
ac50fbac | 17287 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
3185942a JA |
17288 | $as_echo "$as_me: creating $ac_file" >&6;} |
17289 | fi | |
17290 | # Neutralize special characters interpreted by sed in replacement strings. | |
17291 | case $configure_input in #( | |
17292 | *\&* | *\|* | *\\* ) | |
17293 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
17294 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
17295 | *) ac_sed_conf_input=$configure_input;; | |
17296 | esac | |
17297 | ||
17298 | case $ac_tag in | |
ac50fbac CR |
17299 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
17300 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
3185942a JA |
17301 | esac |
17302 | ;; | |
ccc6cda3 JA |
17303 | esac |
17304 | ||
3185942a | 17305 | ac_dir=`$as_dirname -- "$ac_file" || |
b80f6443 | 17306 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
0628567a JA |
17307 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
17308 | X"$ac_file" : 'X\(//\)$' \| \ | |
3185942a JA |
17309 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
17310 | $as_echo X"$ac_file" | | |
17311 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
17312 | s//\1/ | |
17313 | q | |
17314 | } | |
17315 | /^X\(\/\/\)[^/].*/{ | |
17316 | s//\1/ | |
17317 | q | |
17318 | } | |
17319 | /^X\(\/\/\)$/{ | |
17320 | s//\1/ | |
17321 | q | |
17322 | } | |
17323 | /^X\(\/\).*/{ | |
17324 | s//\1/ | |
17325 | q | |
17326 | } | |
17327 | s/.*/./; q'` | |
ac50fbac | 17328 | as_dir="$ac_dir"; as_fn_mkdir_p |
b80f6443 JA |
17329 | ac_builddir=. |
17330 | ||
3185942a JA |
17331 | case "$ac_dir" in |
17332 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17333 | *) | |
17334 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
17335 | # A ".." for each directory in $ac_dir_suffix. | |
17336 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
17337 | case $ac_top_builddir_sub in | |
17338 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17339 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
17340 | esac ;; | |
17341 | esac | |
17342 | ac_abs_top_builddir=$ac_pwd | |
17343 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
17344 | # for backward compatibility: | |
17345 | ac_top_builddir=$ac_top_build_prefix | |
b80f6443 JA |
17346 | |
17347 | case $srcdir in | |
3185942a | 17348 | .) # We are building in place. |
b80f6443 | 17349 | ac_srcdir=. |
3185942a JA |
17350 | ac_top_srcdir=$ac_top_builddir_sub |
17351 | ac_abs_top_srcdir=$ac_pwd ;; | |
17352 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
b80f6443 | 17353 | ac_srcdir=$srcdir$ac_dir_suffix; |
3185942a JA |
17354 | ac_top_srcdir=$srcdir |
17355 | ac_abs_top_srcdir=$srcdir ;; | |
17356 | *) # Relative name. | |
17357 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
17358 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
17359 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
b80f6443 | 17360 | esac |
3185942a | 17361 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
0628567a | 17362 | |
b80f6443 | 17363 | |
3185942a JA |
17364 | case $ac_mode in |
17365 | :F) | |
17366 | # | |
17367 | # CONFIG_FILE | |
17368 | # | |
ccc6cda3 | 17369 | |
f73dda09 JA |
17370 | case $INSTALL in |
17371 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
3185942a | 17372 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
ccc6cda3 | 17373 | esac |
3185942a | 17374 | _ACEOF |
ccc6cda3 | 17375 | |
3185942a JA |
17376 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
17377 | # If the template does not know about datarootdir, expand it. | |
17378 | # FIXME: This hack should be removed a few years after 2.60. | |
17379 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
3185942a JA |
17380 | ac_sed_dataroot=' |
17381 | /datarootdir/ { | |
17382 | p | |
17383 | q | |
17384 | } | |
17385 | /@datadir@/p | |
17386 | /@docdir@/p | |
17387 | /@infodir@/p | |
17388 | /@localedir@/p | |
ac50fbac | 17389 | /@mandir@/p' |
3185942a JA |
17390 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
17391 | *datarootdir*) ac_datarootdir_seen=yes;; | |
17392 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
ac50fbac | 17393 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
3185942a JA |
17394 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
17395 | _ACEOF | |
17396 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17397 | ac_datarootdir_hack=' | |
17398 | s&@datadir@&$datadir&g | |
17399 | s&@docdir@&$docdir&g | |
17400 | s&@infodir@&$infodir&g | |
17401 | s&@localedir@&$localedir&g | |
17402 | s&@mandir@&$mandir&g | |
ac50fbac | 17403 | s&\\\${datarootdir}&$datarootdir&g' ;; |
3185942a | 17404 | esac |
b80f6443 | 17405 | _ACEOF |
3185942a JA |
17406 | |
17407 | # Neutralize VPATH when `$srcdir' = `.'. | |
17408 | # Shell code in configure.ac might set extrasub. | |
17409 | # FIXME: do we really want to maintain this feature? | |
17410 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17411 | ac_sed_extra="$ac_vpsub | |
f73dda09 | 17412 | $extrasub |
b80f6443 | 17413 | _ACEOF |
3185942a | 17414 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 JA |
17415 | :t |
17416 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
3185942a JA |
17417 | s|@configure_input@|$ac_sed_conf_input|;t t |
17418 | s&@top_builddir@&$ac_top_builddir_sub&;t t | |
17419 | s&@top_build_prefix@&$ac_top_build_prefix&;t t | |
17420 | s&@srcdir@&$ac_srcdir&;t t | |
17421 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
17422 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
17423 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
17424 | s&@builddir@&$ac_builddir&;t t | |
17425 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
17426 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
17427 | s&@INSTALL@&$ac_INSTALL&;t t | |
17428 | $ac_datarootdir_hack | |
17429 | " | |
ac50fbac CR |
17430 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
17431 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
ccc6cda3 | 17432 | |
3185942a | 17433 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && |
ac50fbac CR |
17434 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
17435 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
17436 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
17437 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
17438 | which seems to be undefined. Please make sure it is defined" >&5 | |
3185942a | 17439 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
ac50fbac | 17440 | which seems to be undefined. Please make sure it is defined" >&2;} |
ccc6cda3 | 17441 | |
ac50fbac | 17442 | rm -f "$ac_tmp/stdin" |
f73dda09 | 17443 | case $ac_file in |
ac50fbac CR |
17444 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
17445 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
3185942a | 17446 | esac \ |
ac50fbac | 17447 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
3185942a JA |
17448 | ;; |
17449 | :H) | |
17450 | # | |
17451 | # CONFIG_HEADER | |
17452 | # | |
f73dda09 | 17453 | if test x"$ac_file" != x-; then |
3185942a JA |
17454 | { |
17455 | $as_echo "/* $configure_input */" \ | |
ac50fbac CR |
17456 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
17457 | } >"$ac_tmp/config.h" \ | |
17458 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
17459 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then | |
17460 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 | |
3185942a | 17461 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
f73dda09 | 17462 | else |
3185942a | 17463 | rm -f "$ac_file" |
ac50fbac CR |
17464 | mv "$ac_tmp/config.h" "$ac_file" \ |
17465 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
ccc6cda3 | 17466 | fi |
f73dda09 | 17467 | else |
3185942a | 17468 | $as_echo "/* $configure_input */" \ |
ac50fbac CR |
17469 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
17470 | || as_fn_error $? "could not create -" "$LINENO" 5 | |
ccc6cda3 | 17471 | fi |
3185942a | 17472 | ;; |
0628567a | 17473 | |
ac50fbac | 17474 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
3185942a JA |
17475 | $as_echo "$as_me: executing $ac_file commands" >&6;} |
17476 | ;; | |
17477 | esac | |
b80f6443 | 17478 | |
ccc6cda3 | 17479 | |
3185942a JA |
17480 | case $ac_file$ac_mode in |
17481 | "default-1":C) | |
b80f6443 JA |
17482 | for ac_file in $CONFIG_FILES; do |
17483 | # Support "outfile[:infile[:infile...]]" | |
17484 | case "$ac_file" in | |
17485 | *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
17486 | esac | |
17487 | # PO directories have a Makefile.in generated from Makefile.in.in. | |
17488 | case "$ac_file" in */Makefile.in) | |
17489 | # Adjust a relative srcdir. | |
17490 | ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` | |
17491 | ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" | |
17492 | ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` | |
17493 | # In autoconf-2.13 it is called $ac_given_srcdir. | |
17494 | # In autoconf-2.50 it is called $srcdir. | |
17495 | test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" | |
17496 | case "$ac_given_srcdir" in | |
17497 | .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; | |
17498 | /*) top_srcdir="$ac_given_srcdir" ;; | |
17499 | *) top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
17500 | esac | |
17501 | if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then | |
17502 | rm -f "$ac_dir/POTFILES" | |
17503 | test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" | |
17504 | cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" | |
17505 | POMAKEFILEDEPS="POTFILES.in" | |
17506 | # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend | |
17507 | # on $ac_dir but don't depend on user-specified configuration | |
17508 | # parameters. | |
17509 | if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then | |
17510 | # The LINGUAS file contains the set of available languages. | |
17511 | if test -n "$OBSOLETE_ALL_LINGUAS"; then | |
17512 | test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" | |
17513 | fi | |
17514 | ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` | |
17515 | # Hide the ALL_LINGUAS assigment from automake. | |
17516 | eval 'ALL_LINGUAS''=$ALL_LINGUAS_' | |
17517 | POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" | |
17518 | else | |
17519 | # The set of available languages was given in configure.in. | |
17520 | eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' | |
17521 | fi | |
17522 | case "$ac_given_srcdir" in | |
17523 | .) srcdirpre= ;; | |
17524 | *) srcdirpre='$(srcdir)/' ;; | |
17525 | esac | |
17526 | POFILES= | |
17527 | GMOFILES= | |
17528 | UPDATEPOFILES= | |
17529 | DUMMYPOFILES= | |
17530 | for lang in $ALL_LINGUAS; do | |
17531 | POFILES="$POFILES $srcdirpre$lang.po" | |
17532 | GMOFILES="$GMOFILES $srcdirpre$lang.gmo" | |
17533 | UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" | |
17534 | DUMMYPOFILES="$DUMMYPOFILES $lang.nop" | |
17535 | done | |
17536 | # CATALOGS depends on both $ac_dir and the user's LINGUAS | |
17537 | # environment variable. | |
17538 | INST_LINGUAS= | |
17539 | if test -n "$ALL_LINGUAS"; then | |
17540 | for presentlang in $ALL_LINGUAS; do | |
17541 | useit=no | |
17542 | if test "%UNSET%" != "$LINGUAS"; then | |
17543 | desiredlanguages="$LINGUAS" | |
17544 | else | |
17545 | desiredlanguages="$ALL_LINGUAS" | |
17546 | fi | |
17547 | for desiredlang in $desiredlanguages; do | |
17548 | # Use the presentlang catalog if desiredlang is | |
17549 | # a. equal to presentlang, or | |
17550 | # b. a variant of presentlang (because in this case, | |
17551 | # presentlang can be used as a fallback for messages | |
17552 | # which are not translated in the desiredlang catalog). | |
17553 | case "$desiredlang" in | |
17554 | "$presentlang"*) useit=yes;; | |
17555 | esac | |
17556 | done | |
17557 | if test $useit = yes; then | |
17558 | INST_LINGUAS="$INST_LINGUAS $presentlang" | |
17559 | fi | |
17560 | done | |
17561 | fi | |
17562 | CATALOGS= | |
17563 | if test -n "$INST_LINGUAS"; then | |
17564 | for lang in $INST_LINGUAS; do | |
17565 | CATALOGS="$CATALOGS $lang.gmo" | |
17566 | done | |
17567 | fi | |
17568 | test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" | |
17569 | sed -e "/^POTFILES =/r $ac_dir/POTFILES" -e "/^# Makevars/r $ac_given_srcdir/$ac_dir/Makevars" -e "s|@POFILES@|$POFILES|g" -e "s|@GMOFILES@|$GMOFILES|g" -e "s|@UPDATEPOFILES@|$UPDATEPOFILES|g" -e "s|@DUMMYPOFILES@|$DUMMYPOFILES|g" -e "s|@CATALOGS@|$CATALOGS|g" -e "s|@POMAKEFILEDEPS@|$POMAKEFILEDEPS|g" "$ac_dir/Makefile.in" > "$ac_dir/Makefile" | |
17570 | for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do | |
17571 | if test -f "$f"; then | |
17572 | case "$f" in | |
17573 | *.orig | *.bak | *~) ;; | |
17574 | *) cat "$f" >> "$ac_dir/Makefile" ;; | |
17575 | esac | |
17576 | fi | |
17577 | done | |
17578 | fi | |
17579 | ;; | |
17580 | esac | |
17581 | done ;; | |
3185942a | 17582 | "default":C) |
ccc6cda3 JA |
17583 | # Makefile uses this timestamp file to record whether config.h is up to date. |
17584 | echo timestamp > stamp-h | |
f73dda09 | 17585 | ;; |
3185942a | 17586 | |
f73dda09 | 17587 | esac |
3185942a | 17588 | done # for ac_tag |
ccc6cda3 | 17589 | |
f73dda09 | 17590 | |
ac50fbac | 17591 | as_fn_exit 0 |
b80f6443 | 17592 | _ACEOF |
f73dda09 JA |
17593 | ac_clean_files=$ac_clean_files_save |
17594 | ||
3185942a | 17595 | test $ac_write_fail = 0 || |
ac50fbac | 17596 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
3185942a | 17597 | |
b80f6443 | 17598 | |
f73dda09 JA |
17599 | # configure is writing to config.log, and then calls config.status. |
17600 | # config.status does its own redirection, appending to config.log. | |
17601 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
17602 | # by configure, so config.status won't be able to write to it; its | |
17603 | # output is simply discarded. So we exec the FD to /dev/null, | |
17604 | # effectively closing config.log, so it can be properly (re)opened and | |
17605 | # appended to by config.status. When coming back to configure, we | |
17606 | # need to make the FD available again. | |
17607 | if test "$no_create" != yes; then | |
17608 | ac_cs_success=: | |
0628567a JA |
17609 | ac_config_status_args= |
17610 | test "$silent" = yes && | |
17611 | ac_config_status_args="$ac_config_status_args --quiet" | |
f73dda09 | 17612 | exec 5>/dev/null |
0628567a | 17613 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false |
f73dda09 JA |
17614 | exec 5>>config.log |
17615 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
17616 | # would make configure fail if this is the last instruction. | |
ac50fbac | 17617 | $ac_cs_success || as_fn_exit 1 |
f73dda09 | 17618 | fi |
3185942a | 17619 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
ac50fbac | 17620 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
3185942a JA |
17621 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
17622 | fi | |
ccc6cda3 | 17623 |