]>
Commit | Line | Data |
---|---|---|
ccc6cda3 | 1 | #! /bin/sh |
690150f9 | 2 | # From configure.ac for Bash 4.4, version 4.078. |
f73dda09 | 3 | # Guess values for system-dependent variables and create Makefiles. |
690150f9 | 4 | # Generated by GNU Autoconf 2.69 for bash 4.4-rc1. |
f73dda09 JA |
5 | # |
6 | # Report bugs to <bug-bash@gnu.org>. | |
7 | # | |
1b1fe467 | 8 | # |
0ee50808 | 9 | # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. |
1b1fe467 CR |
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. | |
1b1fe467 CR |
14 | ## -------------------- ## |
15 | ## M4sh Initialization. ## | |
16 | ## -------------------- ## | |
ccc6cda3 | 17 | |
dd4f3dd8 CR |
18 | # Be more Bourne compatible |
19 | DUALCASE=1; export DUALCASE # for MKS sh | |
1b1fe467 | 20 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
a82a04b3 CR |
21 | emulate sh |
22 | NULLCMD=: | |
dd4f3dd8 | 23 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
5e4a95c7 CR |
24 | # is contrary to our usage. Disable this feature. |
25 | alias -g '${1+"$@"}'='"$@"' | |
b709b946 CR |
26 | setopt NO_GLOB_SUBST |
27 | else | |
1b1fe467 CR |
28 | case `(set -o) 2>/dev/null` in #( |
29 | *posix*) : | |
30 | set -o posix ;; #( | |
31 | *) : | |
32 | ;; | |
dd4f3dd8 | 33 | esac |
a82a04b3 | 34 | fi |
dd4f3dd8 CR |
35 | |
36 | ||
dd4f3dd8 CR |
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 | |
1b1fe467 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 | |
dd4f3dd8 CR |
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' | |
b709b946 | 57 | else |
dd4f3dd8 CR |
58 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
59 | as_echo_n_body='eval | |
60 | arg=$1; | |
1b1fe467 | 61 | case $arg in #( |
dd4f3dd8 CR |
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' | |
b709b946 | 70 | fi |
dd4f3dd8 CR |
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 | } | |
b709b946 CR |
82 | fi |
83 | ||
5e4a95c7 | 84 | |
b709b946 CR |
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.) | |
b709b946 CR |
90 | IFS=" "" $as_nl" |
91 | ||
92 | # Find who we are. Look in the path if we contain no directory separator. | |
1b1fe467 CR |
93 | as_myself= |
94 | case $0 in #(( | |
b709b946 CR |
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=. | |
1b1fe467 CR |
101 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
102 | done | |
b709b946 CR |
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 | |
dd4f3dd8 | 113 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
1b1fe467 | 114 | exit 1 |
b709b946 CR |
115 | fi |
116 | ||
1b1fe467 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 || : | |
b709b946 | 124 | done |
5e4a95c7 CR |
125 | PS1='$ ' |
126 | PS2='> ' | |
127 | PS4='+ ' | |
128 | ||
129 | # NLS nuisances. | |
dd4f3dd8 CR |
130 | LC_ALL=C |
131 | export LC_ALL | |
132 | LANGUAGE=C | |
133 | export LANGUAGE | |
5e4a95c7 | 134 | |
1b1fe467 CR |
135 | # CDPATH. |
136 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
137 | ||
0ee50808 CR |
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;} | |
1b1fe467 CR |
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 | |
0ee50808 CR |
196 | test x\$exitcode = x0 || exit 1 |
197 | test -x / || exit 1" | |
1b1fe467 CR |
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 : | |
0ee50808 CR |
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 | |
1b1fe467 CR |
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 | |
0ee50808 CR |
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 | |
1b1fe467 CR |
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 | ||
b709b946 CR |
423 | if expr a : '\(a\)' >/dev/null 2>&1 && |
424 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
5e4a95c7 CR |
425 | as_expr=expr |
426 | else | |
427 | as_expr=false | |
428 | fi | |
429 | ||
b709b946 | 430 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
5e4a95c7 CR |
431 | as_basename=basename |
432 | else | |
433 | as_basename=false | |
434 | fi | |
a82a04b3 | 435 | |
1b1fe467 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 | |
a82a04b3 | 441 | |
b709b946 | 442 | as_me=`$as_basename -- "$0" || |
a82a04b3 CR |
443 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
444 | X"$0" : 'X\(//\)$' \| \ | |
b709b946 | 445 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 446 | $as_echo X/"$0" | |
b709b946 CR |
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'` | |
9d6e5e30 | 460 | |
1b1fe467 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 | |
9d6e5e30 | 467 | |
9d6e5e30 | 468 | |
1b1fe467 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; } | |
b709b946 | 491 | |
0ee50808 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 | |
1b1fe467 CR |
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 | |
b709b946 CR |
502 | } |
503 | ||
1b1fe467 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 | |
e3db237e | 516 | |
1b1fe467 CR |
517 | rm -f conf$$ conf$$.exe conf$$.file |
518 | if test -d conf$$.dir; then | |
519 | rm -f conf$$.dir/conf$$.file | |
520 | else | |
521 | rm -f conf$$.dir | |
522 | mkdir conf$$.dir 2>/dev/null | |
abe2eb5b | 523 | fi |
1b1fe467 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. | |
0ee50808 | 530 | # In both cases, we have to default to `cp -pR'. |
1b1fe467 | 531 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
0ee50808 | 532 | as_ln_s='cp -pR' |
1b1fe467 CR |
533 | elif ln conf$$.file conf$$ 2>/dev/null; then |
534 | as_ln_s=ln | |
535 | else | |
0ee50808 | 536 | as_ln_s='cp -pR' |
1b1fe467 | 537 | fi |
b709b946 | 538 | else |
0ee50808 | 539 | as_ln_s='cp -pR' |
b709b946 | 540 | fi |
1b1fe467 CR |
541 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
542 | rmdir conf$$.dir 2>/dev/null | |
b709b946 | 543 | |
1b1fe467 CR |
544 | if mkdir -p . 2>/dev/null; then |
545 | as_mkdir_p='mkdir -p "$as_dir"' | |
546 | else | |
547 | test -d ./-p && rmdir ./-p | |
548 | as_mkdir_p=false | |
7175a77f | 549 | fi |
b709b946 | 550 | |
0ee50808 CR |
551 | as_test_x='test -x' |
552 | as_executable_p=as_fn_executable_p | |
b709b946 | 553 | |
1b1fe467 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'" | |
b709b946 | 556 | |
1b1fe467 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'" | |
f73dda09 | 559 | |
f73dda09 | 560 | |
1b1fe467 CR |
561 | test -n "$DJDIR" || exec 7<&0 </dev/null |
562 | exec 6>&1 | |
7175a77f CR |
563 | |
564 | # Name of the host. | |
1b1fe467 | 565 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
7175a77f CR |
566 | # so uname gets run too. |
567 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
568 | ||
569 | # | |
570 | # Initializations. | |
f73dda09 | 571 | # |
ccc6cda3 | 572 | ac_default_prefix=/usr/local |
b709b946 | 573 | ac_clean_files= |
5e4a95c7 | 574 | ac_config_libobj_dir=. |
b709b946 | 575 | LIBOBJS= |
f73dda09 JA |
576 | cross_compiling=no |
577 | subdirs= | |
a82a04b3 CR |
578 | MFLAGS= |
579 | MAKEFLAGS= | |
f73dda09 | 580 | |
a82a04b3 CR |
581 | # Identity of this package. |
582 | PACKAGE_NAME='bash' | |
583 | PACKAGE_TARNAME='bash' | |
690150f9 CR |
584 | PACKAGE_VERSION='4.4-rc1' |
585 | PACKAGE_STRING='bash 4.4-rc1' | |
a82a04b3 | 586 | PACKAGE_BUGREPORT='bug-bash@gnu.org' |
1b1fe467 | 587 | PACKAGE_URL='' |
a82a04b3 | 588 | |
f73dda09 JA |
589 | ac_unique_file="shell.h" |
590 | # Factoring default headers for most tests. | |
591 | ac_includes_default="\ | |
592 | #include <stdio.h> | |
dd4f3dd8 | 593 | #ifdef HAVE_SYS_TYPES_H |
f73dda09 JA |
594 | # include <sys/types.h> |
595 | #endif | |
dd4f3dd8 | 596 | #ifdef HAVE_SYS_STAT_H |
f73dda09 JA |
597 | # include <sys/stat.h> |
598 | #endif | |
dd4f3dd8 | 599 | #ifdef STDC_HEADERS |
f73dda09 JA |
600 | # include <stdlib.h> |
601 | # include <stddef.h> | |
602 | #else | |
dd4f3dd8 | 603 | # ifdef HAVE_STDLIB_H |
f73dda09 JA |
604 | # include <stdlib.h> |
605 | # endif | |
606 | #endif | |
dd4f3dd8 CR |
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 | |
dd4f3dd8 | 613 | #ifdef HAVE_STRINGS_H |
f73dda09 JA |
614 | # include <strings.h> |
615 | #endif | |
dd4f3dd8 | 616 | #ifdef HAVE_INTTYPES_H |
f73dda09 | 617 | # include <inttypes.h> |
b709b946 | 618 | #endif |
dd4f3dd8 | 619 | #ifdef HAVE_STDINT_H |
b709b946 | 620 | # include <stdint.h> |
f73dda09 | 621 | #endif |
dd4f3dd8 | 622 | #ifdef HAVE_UNISTD_H |
f73dda09 JA |
623 | # include <unistd.h> |
624 | #endif" | |
ccc6cda3 | 625 | |
dd4f3dd8 | 626 | ac_header_list= |
53ac45a3 | 627 | ac_func_list= |
af98a2a6 | 628 | ac_subst_vars='LTLIBOBJS |
691aebcb | 629 | LOCAL_DEFS |
af98a2a6 CR |
630 | LOCAL_LDFLAGS |
631 | LOCAL_CFLAGS | |
632 | LOCAL_LIBS | |
633 | MALLOC_DEBUG | |
634 | DEBUG | |
635 | RELSTATUS | |
636 | BASHVERS | |
637 | ARFLAGS | |
54a5fbe1 CR |
638 | headersdir |
639 | loadablesdir | |
af98a2a6 CR |
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 | |
278286c9 CR |
654 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC |
655 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC | |
656 | TIME_H_DEFINES_STRUCT_TIMESPEC | |
af98a2a6 CR |
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 | |
7610e0c5 | 706 | LIBS_FOR_BUILD |
af98a2a6 | 707 | STATIC_LD |
af98a2a6 CR |
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 | |
abe2eb5b | 722 | HELPFILES_TARGET |
af98a2a6 CR |
723 | HELPINSTALL |
724 | HELPDIRDEFINE | |
725 | HELPDIR | |
726 | MALLOC_DEP | |
727 | MALLOC_LDFLAGS | |
728 | MALLOC_LIBRARY | |
729 | MALLOC_LIB | |
730 | MALLOC_SRC | |
731 | MALLOC_TARGET | |
af98a2a6 | 732 | TESTSCRIPT |
7610e0c5 CR |
733 | CPPFLAGS_FOR_BUILD |
734 | LDFLAGS_FOR_BUILD | |
735 | CFLAGS_FOR_BUILD | |
736 | CC_FOR_BUILD | |
af98a2a6 | 737 | DEBUGGER_START_FILE |
af98a2a6 CR |
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 | |
1b1fe467 | 776 | PACKAGE_URL |
af98a2a6 CR |
777 | PACKAGE_BUGREPORT |
778 | PACKAGE_STRING | |
779 | PACKAGE_VERSION | |
780 | PACKAGE_TARNAME | |
781 | PACKAGE_NAME | |
782 | PATH_SEPARATOR | |
783 | SHELL' | |
5e4a95c7 | 784 | ac_subst_files='' |
dd4f3dd8 CR |
785 | ac_user_opts=' |
786 | enable_option_checking | |
dd4f3dd8 CR |
787 | with_afs |
788 | with_bash_malloc | |
789 | with_curses | |
790 | with_gnu_malloc | |
791 | with_installed_readline | |
dd4f3dd8 CR |
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 | |
f14388d3 | 805 | enable_direxpand_default |
dd4f3dd8 CR |
806 | enable_directory_stack |
807 | enable_disabled_builtins | |
808 | enable_dparen_arithmetic | |
809 | enable_extended_glob | |
691aebcb | 810 | enable_extended_glob_default |
85ec0778 | 811 | enable_function_import |
c111d992 | 812 | enable_glob_asciiranges_default |
dd4f3dd8 CR |
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 | ' | |
b709b946 CR |
840 | ac_precious_vars='build_alias |
841 | host_alias | |
842 | target_alias | |
843 | DEBUGGER_START_FILE | |
7610e0c5 CR |
844 | CC_FOR_BUILD |
845 | CFLAGS_FOR_BUILD | |
846 | LDFLAGS_FOR_BUILD | |
847 | CPPFLAGS_FOR_BUILD | |
b709b946 CR |
848 | CC |
849 | CFLAGS | |
850 | LDFLAGS | |
dd4f3dd8 | 851 | LIBS |
b709b946 CR |
852 | CPPFLAGS |
853 | CPP | |
854 | YACC | |
855 | YFLAGS' | |
856 | ||
a82a04b3 | 857 | |
ccc6cda3 | 858 | # Initialize some variables set by options. |
f73dda09 JA |
859 | ac_init_help= |
860 | ac_init_version=false | |
dd4f3dd8 CR |
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. | |
b709b946 | 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' | |
b709b946 CR |
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' | |
b709b946 CR |
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= |
b709b946 | 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 | |
b709b946 | 912 | eval $ac_prev=\$ac_option |
ccc6cda3 JA |
913 | ac_prev= |
914 | continue | |
915 | fi | |
916 | ||
b709b946 | 917 | case $ac_option in |
1b1fe467 CR |
918 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
919 | *=) ac_optarg= ;; | |
920 | *) ac_optarg=yes ;; | |
b709b946 | 921 | esac |
ccc6cda3 JA |
922 | |
923 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
924 | ||
b709b946 CR |
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 | |
b709b946 | 949 | -datadir | --datadir | --datadi | --datad) |
ccc6cda3 | 950 | ac_prev=datadir ;; |
b709b946 | 951 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
f73dda09 | 952 | datadir=$ac_optarg ;; |
ccc6cda3 | 953 | |
b709b946 CR |
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-*) |
dd4f3dd8 | 962 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
ccc6cda3 | 963 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 964 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1b1fe467 | 965 | as_fn_error $? "invalid feature name: $ac_useropt" |
dd4f3dd8 CR |
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 ;; | |
b709b946 CR |
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-*) | |
dd4f3dd8 | 988 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
ccc6cda3 | 989 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 990 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1b1fe467 | 991 | as_fn_error $? "invalid feature name: $ac_useropt" |
dd4f3dd8 CR |
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=', ';; | |
1000 | esac | |
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 | |
b709b946 CR |
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 | |
b709b946 CR |
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 \ |
b709b946 | 1064 | | --localstate | --localstat | --localsta | --localst | --locals) |
ccc6cda3 JA |
1065 | ac_prev=localstatedir ;; |
1066 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
b709b946 | 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 \ | |
a82a04b3 | 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 | |
b709b946 CR |
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-*) | |
dd4f3dd8 | 1192 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
ccc6cda3 | 1193 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 1194 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1b1fe467 | 1195 | as_fn_error $? "invalid package name: $ac_useropt" |
dd4f3dd8 CR |
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=', ';; | |
1204 | esac | |
1205 | eval with_$ac_useropt=\$ac_optarg ;; | |
ccc6cda3 JA |
1206 | |
1207 | -without-* | --without-*) | |
dd4f3dd8 | 1208 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
ccc6cda3 | 1209 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 1210 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1b1fe467 | 1211 | as_fn_error $? "invalid package name: $ac_useropt" |
dd4f3dd8 CR |
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 | |
1b1fe467 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. | |
1b1fe467 CR |
1248 | case $ac_envvar in #( |
1249 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
1250 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; | |
1251 | esac | |
b709b946 | 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. |
dd4f3dd8 | 1257 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
f73dda09 | 1258 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
dd4f3dd8 | 1259 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
1b1fe467 | 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'` |
1b1fe467 | 1268 | as_fn_error $? "missing argument to $ac_option" |
ccc6cda3 | 1269 | fi |
ccc6cda3 | 1270 | |
dd4f3dd8 CR |
1271 | if test -n "$ac_unrecognized_opts"; then |
1272 | case $enable_option_checking in | |
1273 | no) ;; | |
1b1fe467 | 1274 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
af98a2a6 | 1275 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
dd4f3dd8 CR |
1276 | esac |
1277 | fi | |
1278 | ||
1279 | # Check all directory arguments for consistency. | |
b709b946 CR |
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 | |
c184f645 | 1284 | do |
b709b946 | 1285 | eval ac_val=\$$ac_var |
dd4f3dd8 CR |
1286 | # Remove trailing slashes. |
1287 | case $ac_val in | |
1288 | */ ) | |
1289 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1290 | eval $ac_var=\$ac_val;; | |
1291 | esac | |
1292 | # Be sure to have absolute directory names. | |
c184f645 | 1293 | case $ac_val in |
b709b946 CR |
1294 | [\\/$]* | ?:[\\/]* ) continue;; |
1295 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
ccc6cda3 | 1296 | esac |
1b1fe467 | 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. | |
a82a04b3 | 1302 | # FIXME: To remove some day. |
f73dda09 JA |
1303 | build=$build_alias |
1304 | host=$host_alias | |
1305 | target=$target_alias | |
1306 | ||
a82a04b3 | 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 | |
a82a04b3 | 1321 | |
b709b946 CR |
1322 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
1323 | ac_ls_di=`ls -di .` && | |
1324 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
1b1fe467 | 1325 | as_fn_error $? "working directory cannot be determined" |
b709b946 | 1326 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
1b1fe467 | 1327 | as_fn_error $? "pwd does not report name of working directory" |
b709b946 CR |
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 | |
b709b946 | 1333 | # Try the directory containing this script, then the parent directory. |
dd4f3dd8 CR |
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" | | |
b709b946 CR |
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 |
b709b946 | 1358 | if test ! -r "$srcdir/$ac_unique_file"; then |
ccc6cda3 JA |
1359 | srcdir=.. |
1360 | fi | |
1361 | else | |
1362 | ac_srcdir_defaulted=no | |
1363 | fi | |
b709b946 CR |
1364 | if test ! -r "$srcdir/$ac_unique_file"; then |
1365 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
1b1fe467 | 1366 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
c184f645 | 1367 | fi |
b709b946 CR |
1368 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
1369 | ac_abs_confdir=`( | |
1b1fe467 | 1370 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
b709b946 CR |
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. | |
a82a04b3 | 1395 | cat <<_ACEOF |
690150f9 | 1396 | \`configure' configures bash 4.4-rc1 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 | |
1b1fe467 | 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 | |
dd4f3dd8 | 1418 | [$ac_default_prefix] |
f73dda09 | 1419 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
dd4f3dd8 | 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: |
dd4f3dd8 CR |
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] | |
a82a04b3 | 1449 | _ACEOF |
f73dda09 | 1450 | |
a82a04b3 | 1451 | cat <<\_ACEOF |
f73dda09 JA |
1452 | |
1453 | System types: | |
1454 | --build=BUILD configure for building on BUILD [guessed] | |
a82a04b3 CR |
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 | |
690150f9 | 1461 | short | recursive ) echo "Configuration of bash 4.4-rc1:";; |
f73dda09 | 1462 | esac |
a82a04b3 | 1463 | cat <<\_ACEOF |
ccc6cda3 | 1464 | |
f73dda09 | 1465 | Optional Features: |
dd4f3dd8 | 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 | |
fdf670ea CR |
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 | |
35ee8ea0 | 1484 | --enable-cond-regexp enable extended regular expression matching in |
d3a24ed2 | 1485 | conditional commands |
09767ff0 CR |
1486 | --enable-coprocesses enable coprocess support and the coproc reserved |
1487 | word | |
d3a24ed2 | 1488 | --enable-debugger enable support for bash debugger |
f14388d3 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 | |
691aebcb CR |
1498 | --enable-extended-glob-default |
1499 | force extended pattern matching to be enabled by | |
1500 | default | |
f3aad56d CR |
1501 | --enable-function-import |
1502 | allow bash to import exported function definitions | |
1503 | by default | |
c111d992 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 | |
d3a24ed2 | 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 | |
01ed5ba4 CR |
1524 | --enable-single-help-strings |
1525 | store help documentation as a single string to ease | |
1526 | translation | |
7790f917 CR |
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 |
5e13499c CR |
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 | |
5e13499c CR |
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: | |
d3a24ed2 CR |
1560 | DEBUGGER_START_FILE |
1561 | location of bash debugger initialization file | |
7610e0c5 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> | |
dd4f3dd8 | 1577 | LIBS libraries to pass to the linker, e.g. -l<library> |
1b1fe467 | 1578 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
b709b946 | 1579 | you have headers in a nonstandard directory <include dir> |
f73dda09 | 1580 | CPP C preprocessor |
1b1fe467 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'. | |
b709b946 CR |
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>. | |
a82a04b3 | 1592 | _ACEOF |
b709b946 | 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. | |
a82a04b3 | 1598 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
dd4f3dd8 CR |
1599 | test -d "$ac_dir" || |
1600 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1601 | continue | |
a82a04b3 CR |
1602 | ac_builddir=. |
1603 | ||
b709b946 CR |
1604 | case "$ac_dir" in |
1605 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1606 | *) | |
dd4f3dd8 | 1607 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
b709b946 | 1608 | # A ".." for each directory in $ac_dir_suffix. |
dd4f3dd8 | 1609 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
b709b946 CR |
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 | |
a82a04b3 CR |
1619 | |
1620 | case $srcdir in | |
b709b946 | 1621 | .) # We are building in place. |
a82a04b3 | 1622 | ac_srcdir=. |
b709b946 CR |
1623 | ac_top_srcdir=$ac_top_builddir_sub |
1624 | ac_abs_top_srcdir=$ac_pwd ;; | |
1625 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
a82a04b3 | 1626 | ac_srcdir=$srcdir$ac_dir_suffix; |
b709b946 CR |
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 ;; | |
5e4a95c7 | 1633 | esac |
b709b946 CR |
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 |
dd4f3dd8 | 1645 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
b709b946 CR |
1646 | fi || ac_status=$? |
1647 | cd "$ac_pwd" || { ac_status=$?; break; } | |
f73dda09 JA |
1648 | done |
1649 | fi | |
ccc6cda3 | 1650 | |
b709b946 | 1651 | test -n "$ac_init_help" && exit $ac_status |
f73dda09 | 1652 | if $ac_init_version; then |
a82a04b3 | 1653 | cat <<\_ACEOF |
690150f9 | 1654 | bash configure 4.4-rc1 |
0ee50808 | 1655 | generated by GNU Autoconf 2.69 |
ccc6cda3 | 1656 | |
0ee50808 | 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. | |
a82a04b3 | 1660 | _ACEOF |
b709b946 | 1661 | exit |
f73dda09 | 1662 | fi |
7175a77f | 1663 | |
1b1fe467 CR |
1664 | ## ------------------------ ## |
1665 | ## Autoconf initialization. ## | |
1666 | ## ------------------------ ## | |
ccc6cda3 | 1667 | |
1b1fe467 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 () | |
1672 | { | |
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 | |
2dead0c4 | 1698 | |
1b1fe467 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 | |
1703 | ||
1704 | } # ac_fn_c_try_compile | |
1705 | ||
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 () | |
7f947b68 | 1710 | { |
1b1fe467 CR |
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 || | |
0ee50808 | 1733 | test -x conftest$ac_exeext |
1b1fe467 CR |
1734 | }; then : |
1735 | ac_retval=0 | |
1736 | else | |
1737 | $as_echo "$as_me: failed program was:" >&5 | |
1738 | sed 's/^/| /' conftest.$ac_ext >&5 | |
2dead0c4 | 1739 | |
1b1fe467 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 | |
7f947b68 | 1749 | |
1b1fe467 | 1750 | } # ac_fn_c_try_link |
7f947b68 | 1751 | |
1b1fe467 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 | |
a82a04b3 | 1781 | |
1b1fe467 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 | |
a82a04b3 | 1786 | |
1b1fe467 | 1787 | } # ac_fn_c_try_cpp |
c920c360 | 1788 | |
1b1fe467 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> | |
7f947b68 | 1814 | _ACEOF |
1b1fe467 CR |
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; } | |
a82a04b3 | 1823 | |
1b1fe467 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> | |
1830 | _ACEOF | |
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; } | |
b709b946 | 1839 | |
1b1fe467 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 | |
ccc6cda3 | 1877 | |
1b1fe467 | 1878 | } # ac_fn_c_check_header_mongrel |
ccc6cda3 | 1879 | |
1b1fe467 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 | |
71412226 | 1913 | |
1b1fe467 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 | |
ccc6cda3 | 1919 | |
1b1fe467 | 1920 | } # ac_fn_c_try_run |
71412226 | 1921 | |
1b1fe467 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> | |
7f947b68 | 1938 | _ACEOF |
1b1fe467 CR |
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 | |
71412226 | 1950 | |
1b1fe467 | 1951 | } # ac_fn_c_check_header_compile |
71412226 | 1952 | |
1b1fe467 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 | |
71412226 | 1969 | |
1b1fe467 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. */ | |
7610e0c5 | 1974 | |
1b1fe467 CR |
1975 | #ifdef __STDC__ |
1976 | # include <limits.h> | |
1977 | #else | |
1978 | # include <assert.h> | |
1979 | #endif | |
7610e0c5 | 1980 | |
1b1fe467 | 1981 | #undef $2 |
c920c360 | 1982 | |
1b1fe467 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 | } | |
7f947b68 | 2004 | _ACEOF |
1b1fe467 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 | |
7610e0c5 | 2017 | |
1b1fe467 | 2018 | } # ac_fn_c_check_func |
71412226 | 2019 | |
1b1fe467 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 | |
7f947b68 | 2031 | else |
1b1fe467 CR |
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 | } | |
2044 | _ACEOF | |
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 | } | |
2057 | _ACEOF | |
2058 | if ac_fn_c_try_compile "$LINENO"; then : | |
c920c360 | 2059 | |
7f947b68 | 2060 | else |
1b1fe467 | 2061 | eval "$3=yes" |
7f947b68 | 2062 | fi |
1b1fe467 | 2063 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7175a77f | 2064 | fi |
1b1fe467 CR |
2065 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2066 | fi | |
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 | |
71412226 | 2071 | |
1b1fe467 | 2072 | } # ac_fn_c_check_type |
c920c360 | 2073 | |
1b1fe467 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 | |
c920c360 | 2101 | |
1b1fe467 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 | |
c920c360 | 2117 | |
1b1fe467 | 2118 | } # ac_fn_c_check_decl |
c920c360 | 2119 | |
1b1fe467 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)]; | |
0ee50808 CR |
2137 | test_array [0] = 0; |
2138 | return test_array [0]; | |
c920c360 | 2139 | |
1b1fe467 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)]; | |
0ee50808 CR |
2154 | test_array [0] = 0; |
2155 | return test_array [0]; | |
c920c360 | 2156 | |
1b1fe467 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)]; | |
0ee50808 CR |
2181 | test_array [0] = 0; |
2182 | return test_array [0]; | |
c920c360 | 2183 | |
1b1fe467 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)]; | |
0ee50808 CR |
2198 | test_array [0] = 0; |
2199 | return test_array [0]; | |
c920c360 | 2200 | |
1b1fe467 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)]; | |
0ee50808 CR |
2233 | test_array [0] = 0; |
2234 | return test_array [0]; | |
c920c360 | 2235 | |
1b1fe467 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 | { | |
c920c360 | 2262 | |
1b1fe467 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; | |
2dead0c4 | 2283 | |
1b1fe467 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 | |
c920c360 | 2296 | |
1b1fe467 CR |
2297 | fi |
2298 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
2299 | as_fn_set_status $ac_retval | |
c920c360 | 2300 | |
1b1fe467 | 2301 | } # ac_fn_c_compute_int |
2dead0c4 | 2302 | |
1b1fe467 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 : | |
7f947b68 CR |
2313 | $as_echo_n "(cached) " >&6 |
2314 | else | |
1b1fe467 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" | |
7f947b68 | 2330 | else |
1b1fe467 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" | |
7f947b68 | 2346 | else |
1b1fe467 | 2347 | eval "$4=no" |
2dead0c4 | 2348 | fi |
1b1fe467 | 2349 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2dead0c4 | 2350 | fi |
1b1fe467 | 2351 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7175a77f | 2352 | fi |
1b1fe467 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 | |
200aed9a | 2357 | |
1b1fe467 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. | |
2dead0c4 | 2362 | |
690150f9 | 2363 | It was created by bash $as_me 4.4-rc1, which was |
0ee50808 | 2364 | generated by GNU Autoconf 2.69. Invocation command line was |
2dead0c4 | 2365 | |
1b1fe467 | 2366 | $ $0 $@ |
2dead0c4 | 2367 | |
1b1fe467 CR |
2368 | _ACEOF |
2369 | exec 5>>config.log | |
2370 | { | |
2371 | cat <<_ASUNAME | |
2372 | ## --------- ## | |
2373 | ## Platform. ## | |
2374 | ## --------- ## | |
2dead0c4 | 2375 | |
1b1fe467 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` | |
2dead0c4 | 2381 | |
1b1fe467 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` | |
2dead0c4 | 2384 | |
1b1fe467 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` | |
2dead0c4 | 2392 | |
1b1fe467 | 2393 | _ASUNAME |
2dead0c4 | 2394 | |
1b1fe467 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 | |
2dead0c4 | 2403 | |
1b1fe467 | 2404 | } >&5 |
2dead0c4 | 2405 | |
1b1fe467 | 2406 | cat >&5 <<_ACEOF |
2dead0c4 CR |
2407 | |
2408 | ||
1b1fe467 CR |
2409 | ## ----------- ## |
2410 | ## Core tests. ## | |
2411 | ## ----------- ## | |
2dead0c4 | 2412 | |
1b1fe467 | 2413 | _ACEOF |
2dead0c4 CR |
2414 | |
2415 | ||
1b1fe467 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;} | |
2dead0c4 | 2463 | |
1b1fe467 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 | |
2dead0c4 | 2473 | |
1b1fe467 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 | |
2509 | ||
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 | |
2dead0c4 | 2523 | |
1b1fe467 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 | |
7f947b68 | 2539 | |
1b1fe467 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 | |
2dead0c4 | 2560 | |
1b1fe467 CR |
2561 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
2562 | rm -f -r conftest* confdefs.h | |
7f947b68 | 2563 | |
1b1fe467 | 2564 | $as_echo "/* confdefs.h */" > confdefs.h |
7f947b68 | 2565 | |
1b1fe467 | 2566 | # Predefined preprocessor variables. |
7f947b68 | 2567 | |
1b1fe467 CR |
2568 | cat >>confdefs.h <<_ACEOF |
2569 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
7175a77f | 2570 | _ACEOF |
7f947b68 | 2571 | |
1b1fe467 CR |
2572 | cat >>confdefs.h <<_ACEOF |
2573 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2574 | _ACEOF | |
2dead0c4 | 2575 | |
1b1fe467 CR |
2576 | cat >>confdefs.h <<_ACEOF |
2577 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
7175a77f | 2578 | _ACEOF |
7f947b68 | 2579 | |
1b1fe467 CR |
2580 | cat >>confdefs.h <<_ACEOF |
2581 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
2582 | _ACEOF | |
2dead0c4 | 2583 | |
1b1fe467 CR |
2584 | cat >>confdefs.h <<_ACEOF |
2585 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2586 | _ACEOF | |
7f947b68 | 2587 | |
1b1fe467 CR |
2588 | cat >>confdefs.h <<_ACEOF |
2589 | #define PACKAGE_URL "$PACKAGE_URL" | |
7175a77f | 2590 | _ACEOF |
2dead0c4 | 2591 | |
1b1fe467 CR |
2592 | |
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 | |
2dead0c4 | 2610 | fi |
1b1fe467 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 | |
2dead0c4 | 2625 | |
1b1fe467 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 | |
2dead0c4 | 2641 | fi |
2dead0c4 | 2642 | |
1b1fe467 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 | |
2dead0c4 | 2708 | fi |
1b1fe467 CR |
2709 | ## -------------------- ## |
2710 | ## Main body of script. ## | |
2711 | ## -------------------- ## | |
2dead0c4 | 2712 | |
1b1fe467 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 | |
2718 | ||
2719 | ||
2720 | ||
2721 | ||
2722 | ||
2723 | ||
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 | |
2742 | fi | |
2743 | ||
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. | |
2751 | ||
2752 | ||
2753 | ac_config_headers="$ac_config_headers config.h" | |
2754 | ||
2755 | ||
8f50a023 | 2756 | BASHVERS=4.4 |
690150f9 | 2757 | RELSTATUS=rc1 |
1b1fe467 CR |
2758 | |
2759 | case "$RELSTATUS" in | |
2760 | alp*|bet*|dev*|rc*|maint*) DEBUG='-DDEBUG' MALLOC_DEBUG='-DMALLOC_DEBUG' ;; | |
2761 | *) DEBUG= MALLOC_DEBUG= ;; | |
2762 | esac | |
2763 | ||
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 | |
2767 | ||
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 | |
2780 | ||
2781 | fi | |
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 | |
2800 | ||
2801 | ||
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 | |
2812 | fi | |
2813 | ||
2814 | fi | |
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 | |
2833 | ||
2834 | ||
2835 | ||
2836 | ||
2837 | opt_bash_malloc=yes | |
1b1fe467 CR |
2838 | opt_afs=no |
2839 | opt_curses=no | |
2840 | opt_with_installed_readline=no | |
2841 | ||
2842 | #htmldir= | |
2843 | ||
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 | |
10e78433 | 2859 | *-openstep*) opt_bash_malloc=no ;; # i386/Sparc/HP machines running Openstep |
1b1fe467 CR |
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 | |
c51b384f | 2871 | *-haiku*) opt_bash_malloc=no ;; # Haiku OS |
1b1fe467 CR |
2872 | esac |
2873 | ||
2874 | # memory scrambling on free() | |
2875 | case "${host_os}" in | |
2876 | sco3.2v5*|sco3.2v4*) opt_memscramble=no ;; | |
2877 | *) opt_memscramble=yes ;; | |
2878 | esac | |
2879 | ||
2880 | ||
2881 | ||
2882 | ||
2883 | # Check whether --with-afs was given. | |
2884 | if test "${with_afs+set}" = set; then : | |
2885 | withval=$with_afs; opt_afs=$withval | |
2886 | fi | |
2887 | ||
2888 | ||
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 | |
2892 | fi | |
2893 | ||
2894 | ||
2895 | # Check whether --with-curses was given. | |
2896 | if test "${with_curses+set}" = set; then : | |
2897 | withval=$with_curses; opt_curses=$withval | |
2898 | fi | |
2899 | ||
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 | |
2904 | fi | |
2905 | ||
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 | |
2910 | fi | |
2911 | ||
2912 | ||
1b1fe467 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= | |
2929 | fi | |
2930 | ||
1b1fe467 CR |
2931 | if test "$opt_afs" = yes; then |
2932 | $as_echo "#define AFS 1" >>confdefs.h | |
2933 | ||
2934 | fi | |
2935 | ||
2936 | if test "$opt_curses" = yes; then | |
2937 | prefer_curses=yes | |
2938 | fi | |
2939 | ||
2940 | if test -z "${DEBUGGER_START_FILE}"; then | |
2941 | DEBUGGER_START_FILE='${datadir}/bashdb/bashdb-main.inc' | |
2942 | fi | |
2943 | ||
2944 | opt_minimal_config=no | |
7f947b68 CR |
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 | |
f14388d3 | 2978 | opt_dircomplete_expand_default=no |
c111d992 | 2979 | opt_globascii_default=no |
f3aad56d | 2980 | opt_function_import=yes |
7f947b68 CR |
2981 | |
2982 | opt_static_link=no | |
2983 | opt_profiling=no | |
2984 | ||
2985 | # Check whether --enable-minimal-config was given. | |
1b1fe467 | 2986 | if test "${enable_minimal_config+set}" = set; then : |
7f947b68 | 2987 | enableval=$enable_minimal_config; opt_minimal_config=$enableval |
2dead0c4 | 2988 | fi |
2dead0c4 | 2989 | |
7f947b68 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 | |
c111d992 | 3001 | opt_globascii_default=no |
2dead0c4 | 3002 | fi |
2dead0c4 | 3003 | |
7f947b68 | 3004 | # Check whether --enable-alias was given. |
1b1fe467 | 3005 | if test "${enable_alias+set}" = set; then : |
7f947b68 | 3006 | enableval=$enable_alias; opt_alias=$enableval |
2dead0c4 | 3007 | fi |
2dead0c4 | 3008 | |
7f947b68 | 3009 | # Check whether --enable-arith-for-command was given. |
1b1fe467 | 3010 | if test "${enable_arith_for_command+set}" = set; then : |
7f947b68 | 3011 | enableval=$enable_arith_for_command; opt_arith_for_command=$enableval |
2dead0c4 | 3012 | fi |
2dead0c4 | 3013 | |
7f947b68 | 3014 | # Check whether --enable-array-variables was given. |
1b1fe467 | 3015 | if test "${enable_array_variables+set}" = set; then : |
7f947b68 | 3016 | enableval=$enable_array_variables; opt_array_variables=$enableval |
2dead0c4 | 3017 | fi |
2dead0c4 | 3018 | |
7f947b68 | 3019 | # Check whether --enable-bang-history was given. |
1b1fe467 | 3020 | if test "${enable_bang_history+set}" = set; then : |
7f947b68 CR |
3021 | enableval=$enable_bang_history; opt_bang_history=$enableval |
3022 | fi | |
2dead0c4 | 3023 | |
7f947b68 | 3024 | # Check whether --enable-brace-expansion was given. |
1b1fe467 | 3025 | if test "${enable_brace_expansion+set}" = set; then : |
7f947b68 | 3026 | enableval=$enable_brace_expansion; opt_brace_expansion=$enableval |
2dead0c4 | 3027 | fi |
2dead0c4 | 3028 | |
7f947b68 | 3029 | # Check whether --enable-casemod-attributes was given. |
1b1fe467 | 3030 | if test "${enable_casemod_attributes+set}" = set; then : |
7f947b68 | 3031 | enableval=$enable_casemod_attributes; opt_casemod_attrs=$enableval |
2dead0c4 | 3032 | fi |
2dead0c4 | 3033 | |
7f947b68 | 3034 | # Check whether --enable-casemod-expansions was given. |
1b1fe467 | 3035 | if test "${enable_casemod_expansions+set}" = set; then : |
7f947b68 | 3036 | enableval=$enable_casemod_expansions; opt_casemod_expansions=$enableval |
2dead0c4 | 3037 | fi |
2dead0c4 | 3038 | |
7f947b68 | 3039 | # Check whether --enable-command-timing was given. |
1b1fe467 | 3040 | if test "${enable_command_timing+set}" = set; then : |
7f947b68 | 3041 | enableval=$enable_command_timing; opt_command_timing=$enableval |
2dead0c4 | 3042 | fi |
2dead0c4 | 3043 | |
7f947b68 | 3044 | # Check whether --enable-cond-command was given. |
1b1fe467 | 3045 | if test "${enable_cond_command+set}" = set; then : |
7f947b68 | 3046 | enableval=$enable_cond_command; opt_cond_command=$enableval |
2dead0c4 | 3047 | fi |
2dead0c4 | 3048 | |
7f947b68 | 3049 | # Check whether --enable-cond-regexp was given. |
1b1fe467 | 3050 | if test "${enable_cond_regexp+set}" = set; then : |
7f947b68 | 3051 | enableval=$enable_cond_regexp; opt_cond_regexp=$enableval |
2dead0c4 | 3052 | fi |
2dead0c4 | 3053 | |
7f947b68 | 3054 | # Check whether --enable-coprocesses was given. |
1b1fe467 | 3055 | if test "${enable_coprocesses+set}" = set; then : |
7f947b68 | 3056 | enableval=$enable_coprocesses; opt_coproc=$enableval |
2dead0c4 | 3057 | fi |
2dead0c4 | 3058 | |
7f947b68 | 3059 | # Check whether --enable-debugger was given. |
1b1fe467 | 3060 | if test "${enable_debugger+set}" = set; then : |
7f947b68 | 3061 | enableval=$enable_debugger; opt_debugger=$enableval |
2dead0c4 | 3062 | fi |
2dead0c4 | 3063 | |
f14388d3 | 3064 | # Check whether --enable-direxpand-default was given. |
1b1fe467 | 3065 | if test "${enable_direxpand_default+set}" = set; then : |
f14388d3 CR |
3066 | enableval=$enable_direxpand_default; opt_dircomplete_expand_default=$enableval |
3067 | fi | |
3068 | ||
7f947b68 | 3069 | # Check whether --enable-directory-stack was given. |
1b1fe467 | 3070 | if test "${enable_directory_stack+set}" = set; then : |
7f947b68 | 3071 | enableval=$enable_directory_stack; opt_dirstack=$enableval |
2dead0c4 | 3072 | fi |
2dead0c4 | 3073 | |
7f947b68 | 3074 | # Check whether --enable-disabled-builtins was given. |
1b1fe467 | 3075 | if test "${enable_disabled_builtins+set}" = set; then : |
7f947b68 | 3076 | enableval=$enable_disabled_builtins; opt_disabled_builtins=$enableval |
2dead0c4 | 3077 | fi |
2dead0c4 | 3078 | |
7f947b68 | 3079 | # Check whether --enable-dparen-arithmetic was given. |
1b1fe467 | 3080 | if test "${enable_dparen_arithmetic+set}" = set; then : |
7f947b68 | 3081 | enableval=$enable_dparen_arithmetic; opt_dparen_arith=$enableval |
2dead0c4 CR |
3082 | fi |
3083 | ||
7f947b68 | 3084 | # Check whether --enable-extended-glob was given. |
1b1fe467 | 3085 | if test "${enable_extended_glob+set}" = set; then : |
7f947b68 CR |
3086 | enableval=$enable_extended_glob; opt_extended_glob=$enableval |
3087 | fi | |
2dead0c4 | 3088 | |
7f947b68 | 3089 | # Check whether --enable-extended-glob-default was given. |
1b1fe467 | 3090 | if test "${enable_extended_glob_default+set}" = set; then : |
7f947b68 | 3091 | enableval=$enable_extended_glob_default; opt_extglob_default=$enableval |
2dead0c4 CR |
3092 | fi |
3093 | ||
85ec0778 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 | |
f3aad56d CR |
3097 | fi |
3098 | ||
c111d992 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 | |
3103 | ||
7f947b68 | 3104 | # Check whether --enable-help-builtin was given. |
1b1fe467 | 3105 | if test "${enable_help_builtin+set}" = set; then : |
7f947b68 | 3106 | enableval=$enable_help_builtin; opt_help=$enableval |
2dead0c4 CR |
3107 | fi |
3108 | ||
7f947b68 | 3109 | # Check whether --enable-history was given. |
1b1fe467 | 3110 | if test "${enable_history+set}" = set; then : |
7f947b68 | 3111 | enableval=$enable_history; opt_history=$enableval |
2dead0c4 | 3112 | fi |
7f947b68 CR |
3113 | |
3114 | # Check whether --enable-job-control was given. | |
1b1fe467 | 3115 | if test "${enable_job_control+set}" = set; then : |
7f947b68 CR |
3116 | enableval=$enable_job_control; opt_job_control=$enableval |
3117 | fi | |
3118 | ||
3119 | # Check whether --enable-multibyte was given. | |
1b1fe467 | 3120 | if test "${enable_multibyte+set}" = set; then : |
7f947b68 CR |
3121 | enableval=$enable_multibyte; opt_multibyte=$enableval |
3122 | fi | |
3123 | ||
3124 | # Check whether --enable-net-redirections was given. | |
1b1fe467 | 3125 | if test "${enable_net_redirections+set}" = set; then : |
7f947b68 CR |
3126 | enableval=$enable_net_redirections; opt_net_redirs=$enableval |
3127 | fi | |
3128 | ||
3129 | # Check whether --enable-process-substitution was given. | |
1b1fe467 | 3130 | if test "${enable_process_substitution+set}" = set; then : |
7f947b68 CR |
3131 | enableval=$enable_process_substitution; opt_process_subst=$enableval |
3132 | fi | |
3133 | ||
3134 | # Check whether --enable-progcomp was given. | |
1b1fe467 | 3135 | if test "${enable_progcomp+set}" = set; then : |
7f947b68 CR |
3136 | enableval=$enable_progcomp; opt_progcomp=$enableval |
3137 | fi | |
3138 | ||
3139 | # Check whether --enable-prompt-string-decoding was given. | |
1b1fe467 | 3140 | if test "${enable_prompt_string_decoding+set}" = set; then : |
7f947b68 CR |
3141 | enableval=$enable_prompt_string_decoding; opt_prompt_decoding=$enableval |
3142 | fi | |
3143 | ||
3144 | # Check whether --enable-readline was given. | |
1b1fe467 | 3145 | if test "${enable_readline+set}" = set; then : |
7f947b68 CR |
3146 | enableval=$enable_readline; opt_readline=$enableval |
3147 | fi | |
3148 | ||
3149 | # Check whether --enable-restricted was given. | |
1b1fe467 | 3150 | if test "${enable_restricted+set}" = set; then : |
7f947b68 CR |
3151 | enableval=$enable_restricted; opt_restricted=$enableval |
3152 | fi | |
3153 | ||
3154 | # Check whether --enable-select was given. | |
1b1fe467 | 3155 | if test "${enable_select+set}" = set; then : |
7f947b68 CR |
3156 | enableval=$enable_select; opt_select=$enableval |
3157 | fi | |
3158 | ||
3159 | # Check whether --enable-separate-helpfiles was given. | |
1b1fe467 | 3160 | if test "${enable_separate_helpfiles+set}" = set; then : |
7f947b68 CR |
3161 | enableval=$enable_separate_helpfiles; opt_separate_help=$enableval |
3162 | fi | |
3163 | ||
3164 | # Check whether --enable-single-help-strings was given. | |
1b1fe467 | 3165 | if test "${enable_single_help_strings+set}" = set; then : |
7f947b68 CR |
3166 | enableval=$enable_single_help_strings; opt_single_longdoc_strings=$enableval |
3167 | fi | |
3168 | ||
3169 | # Check whether --enable-strict-posix-default was given. | |
1b1fe467 | 3170 | if test "${enable_strict_posix_default+set}" = set; then : |
7f947b68 CR |
3171 | enableval=$enable_strict_posix_default; opt_strict_posix=$enableval |
3172 | fi | |
3173 | ||
3174 | # Check whether --enable-usg-echo-default was given. | |
1b1fe467 | 3175 | if test "${enable_usg_echo_default+set}" = set; then : |
7f947b68 CR |
3176 | enableval=$enable_usg_echo_default; opt_xpg_echo=$enableval |
3177 | fi | |
3178 | ||
3179 | # Check whether --enable-xpg-echo-default was given. | |
1b1fe467 | 3180 | if test "${enable_xpg_echo_default+set}" = set; then : |
7f947b68 CR |
3181 | enableval=$enable_xpg_echo_default; opt_xpg_echo=$enableval |
3182 | fi | |
3183 | ||
3184 | ||
3185 | # Check whether --enable-mem-scramble was given. | |
1b1fe467 | 3186 | if test "${enable_mem_scramble+set}" = set; then : |
7f947b68 CR |
3187 | enableval=$enable_mem_scramble; opt_memscramble=$enableval |
3188 | fi | |
3189 | ||
3190 | # Check whether --enable-profiling was given. | |
1b1fe467 | 3191 | if test "${enable_profiling+set}" = set; then : |
7f947b68 CR |
3192 | enableval=$enable_profiling; opt_profiling=$enableval |
3193 | fi | |
3194 | ||
3195 | # Check whether --enable-static-link was given. | |
1b1fe467 | 3196 | if test "${enable_static_link+set}" = set; then : |
7f947b68 CR |
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 | |
1b1fe467 | 3209 | $as_echo "#define ALIAS 1" >>confdefs.h |
7f947b68 CR |
3210 | |
3211 | fi | |
3212 | if test $opt_dirstack = yes; then | |
1b1fe467 | 3213 | $as_echo "#define PUSHD_AND_POPD 1" >>confdefs.h |
7f947b68 CR |
3214 | |
3215 | fi | |
3216 | if test $opt_restricted = yes; then | |
1b1fe467 | 3217 | $as_echo "#define RESTRICTED_SHELL 1" >>confdefs.h |
7f947b68 CR |
3218 | |
3219 | fi | |
3220 | if test $opt_process_subst = yes; then | |
1b1fe467 | 3221 | $as_echo "#define PROCESS_SUBSTITUTION 1" >>confdefs.h |
7f947b68 CR |
3222 | |
3223 | fi | |
3224 | if test $opt_prompt_decoding = yes; then | |
1b1fe467 | 3225 | $as_echo "#define PROMPT_STRING_DECODE 1" >>confdefs.h |
7f947b68 CR |
3226 | |
3227 | fi | |
3228 | if test $opt_select = yes; then | |
1b1fe467 | 3229 | $as_echo "#define SELECT_COMMAND 1" >>confdefs.h |
7f947b68 CR |
3230 | |
3231 | fi | |
3232 | if test $opt_help = yes; then | |
1b1fe467 | 3233 | $as_echo "#define HELP_BUILTIN 1" >>confdefs.h |
7f947b68 CR |
3234 | |
3235 | fi | |
3236 | if test $opt_array_variables = yes; then | |
1b1fe467 | 3237 | $as_echo "#define ARRAY_VARS 1" >>confdefs.h |
7f947b68 CR |
3238 | |
3239 | fi | |
3240 | if test $opt_dparen_arith = yes; then | |
1b1fe467 | 3241 | $as_echo "#define DPAREN_ARITHMETIC 1" >>confdefs.h |
7f947b68 CR |
3242 | |
3243 | fi | |
3244 | if test $opt_brace_expansion = yes; then | |
1b1fe467 | 3245 | $as_echo "#define BRACE_EXPANSION 1" >>confdefs.h |
7f947b68 CR |
3246 | |
3247 | fi | |
3248 | if test $opt_disabled_builtins = yes; then | |
1b1fe467 | 3249 | $as_echo "#define DISABLED_BUILTINS 1" >>confdefs.h |
7f947b68 CR |
3250 | |
3251 | fi | |
3252 | if test $opt_command_timing = yes; then | |
1b1fe467 | 3253 | $as_echo "#define COMMAND_TIMING 1" >>confdefs.h |
7f947b68 CR |
3254 | |
3255 | fi | |
3256 | if test $opt_xpg_echo = yes ; then | |
1b1fe467 | 3257 | $as_echo "#define DEFAULT_ECHO_TO_XPG 1" >>confdefs.h |
7f947b68 CR |
3258 | |
3259 | fi | |
3260 | if test $opt_strict_posix = yes; then | |
1b1fe467 | 3261 | $as_echo "#define STRICT_POSIX 1" >>confdefs.h |
7f947b68 CR |
3262 | |
3263 | fi | |
3264 | if test $opt_extended_glob = yes ; then | |
1b1fe467 | 3265 | $as_echo "#define EXTENDED_GLOB 1" >>confdefs.h |
7f947b68 CR |
3266 | |
3267 | fi | |
3268 | if test $opt_extglob_default = yes; then | |
1b1fe467 | 3269 | $as_echo "#define EXTGLOB_DEFAULT 1" >>confdefs.h |
7f947b68 CR |
3270 | |
3271 | else | |
1b1fe467 | 3272 | $as_echo "#define EXTGLOB_DEFAULT 0" >>confdefs.h |
7f947b68 CR |
3273 | |
3274 | fi | |
3275 | if test $opt_cond_command = yes ; then | |
1b1fe467 | 3276 | $as_echo "#define COND_COMMAND 1" >>confdefs.h |
7f947b68 CR |
3277 | |
3278 | fi | |
3279 | if test $opt_cond_regexp = yes ; then | |
1b1fe467 | 3280 | $as_echo "#define COND_REGEXP 1" >>confdefs.h |
7f947b68 CR |
3281 | |
3282 | fi | |
3283 | if test $opt_coproc = yes; then | |
1b1fe467 | 3284 | $as_echo "#define COPROCESS_SUPPORT 1" >>confdefs.h |
7f947b68 CR |
3285 | |
3286 | fi | |
3287 | if test $opt_arith_for_command = yes; then | |
1b1fe467 | 3288 | $as_echo "#define ARITH_FOR_COMMAND 1" >>confdefs.h |
7f947b68 CR |
3289 | |
3290 | fi | |
3291 | if test $opt_net_redirs = yes; then | |
1b1fe467 | 3292 | $as_echo "#define NETWORK_REDIRECTIONS 1" >>confdefs.h |
7f947b68 CR |
3293 | |
3294 | fi | |
3295 | if test $opt_progcomp = yes; then | |
1b1fe467 | 3296 | $as_echo "#define PROGRAMMABLE_COMPLETION 1" >>confdefs.h |
7f947b68 CR |
3297 | |
3298 | fi | |
3299 | if test $opt_multibyte = no; then | |
1b1fe467 | 3300 | $as_echo "#define NO_MULTIBYTE_SUPPORT 1" >>confdefs.h |
7f947b68 CR |
3301 | |
3302 | fi | |
3303 | if test $opt_debugger = yes; then | |
1b1fe467 | 3304 | $as_echo "#define DEBUGGER 1" >>confdefs.h |
7f947b68 CR |
3305 | |
3306 | fi | |
3307 | if test $opt_casemod_attrs = yes; then | |
1b1fe467 | 3308 | $as_echo "#define CASEMOD_ATTRS 1" >>confdefs.h |
7f947b68 CR |
3309 | |
3310 | fi | |
3311 | if test $opt_casemod_expansions = yes; then | |
1b1fe467 | 3312 | $as_echo "#define CASEMOD_EXPANSIONS 1" >>confdefs.h |
7f947b68 | 3313 | |
f14388d3 CR |
3314 | fi |
3315 | if test $opt_dircomplete_expand_default = yes; then | |
1b1fe467 | 3316 | $as_echo "#define DIRCOMPLETE_EXPAND_DEFAULT 1" >>confdefs.h |
f14388d3 | 3317 | |
c111d992 CR |
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 | ||
f3aad56d CR |
3325 | fi |
3326 | if test $opt_function_import = yes; then | |
3327 | $as_echo "#define FUNCTION_IMPORT 1" >>confdefs.h | |
3328 | ||
7f947b68 CR |
3329 | fi |
3330 | ||
3331 | if test $opt_memscramble = yes; then | |
1b1fe467 | 3332 | $as_echo "#define MEMSCRAMBLE 1" >>confdefs.h |
7f947b68 CR |
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' | |
71412226 CR |
3356 | fi |
3357 | ||
3358 | ||
3359 | ||
3360 | ||
3361 | ||
3362 | ||
3363 | ||
3364 | ||
3365 | ||
3366 | ||
3367 | ||
3368 | ||
3369 | ||
3370 | ||
3371 | ||
3372 | ||
3373 | ||
3374 | ||
8f50a023 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 | |
3381 | ||
71412226 | 3382 | echo "" |
7117c2d2 | 3383 | echo "Beginning configuration for bash-$BASHVERS-$RELSTATUS for ${host_cpu}-${host_vendor}-${host_os}" |
f73dda09 | 3384 | echo "" |
d166f048 | 3385 | |
f73dda09 JA |
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 | |
1b1fe467 | 3394 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3395 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3396 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 3397 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3398 | else |
3399 | if test -n "$CC"; then | |
3400 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3401 | else | |
a82a04b3 CR |
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=. | |
1b1fe467 | 3407 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3408 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 3409 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
1b1fe467 | 3410 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3411 | break 2 |
3412 | fi | |
3413 | done | |
1b1fe467 | 3414 | done |
b709b946 | 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 | |
1b1fe467 | 3421 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3422 | $as_echo "$CC" >&6; } |
f73dda09 | 3423 | else |
1b1fe467 | 3424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3425 | $as_echo "no" >&6; } |
f73dda09 | 3426 | fi |
ccc6cda3 | 3427 | |
b709b946 | 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 | |
1b1fe467 | 3434 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3435 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3436 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
dd4f3dd8 | 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 | |
a82a04b3 CR |
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=. | |
1b1fe467 | 3447 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3448 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 3449 | ac_cv_prog_ac_ct_CC="gcc" |
1b1fe467 | 3450 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3451 | break 2 |
3452 | fi | |
3453 | done | |
1b1fe467 | 3454 | done |
b709b946 | 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 | |
1b1fe467 | 3461 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
dd4f3dd8 | 3462 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3463 | else |
1b1fe467 | 3464 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3465 | $as_echo "no" >&6; } |
f73dda09 | 3466 | fi |
ccc6cda3 | 3467 | |
b709b946 CR |
3468 | if test "x$ac_ct_CC" = x; then |
3469 | CC="" | |
3470 | else | |
3471 | case $cross_compiling:$ac_tool_warned in | |
3472 | yes:) | |
1b1fe467 | 3473 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 3474 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
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 |
b709b946 CR |
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 |
1b1fe467 | 3487 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3488 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3489 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 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 | |
a82a04b3 CR |
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=. | |
1b1fe467 | 3500 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3501 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 3502 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
1b1fe467 | 3503 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3504 | break 2 |
3505 | fi | |
3506 | done | |
1b1fe467 | 3507 | done |
b709b946 | 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 |
1b1fe467 | 3514 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3515 | $as_echo "$CC" >&6; } |
c184f645 | 3516 | else |
1b1fe467 | 3517 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3518 | $as_echo "no" >&6; } |
c184f645 CR |
3519 | fi |
3520 | ||
c184f645 | 3521 | |
b709b946 | 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 | |
1b1fe467 | 3527 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3528 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3529 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 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 |
a82a04b3 CR |
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=. | |
1b1fe467 | 3541 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3542 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 CR |
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" | |
1b1fe467 | 3548 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3549 | break 2 |
3550 | fi | |
3551 | done | |
1b1fe467 | 3552 | done |
b709b946 | 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 | |
5e4a95c7 | 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 |
1b1fe467 | 3571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3572 | $as_echo "$CC" >&6; } |
ccc6cda3 | 3573 | else |
1b1fe467 | 3574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3575 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3576 | fi |
3577 | ||
b709b946 | 3578 | |
f73dda09 JA |
3579 | fi |
3580 | if test -z "$CC"; then | |
3581 | if test -n "$ac_tool_prefix"; then | |
b709b946 | 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 | |
1b1fe467 | 3586 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3587 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3588 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 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 | |
a82a04b3 CR |
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=. | |
1b1fe467 | 3599 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3600 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 3601 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
1b1fe467 | 3602 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3603 | break 2 |
3604 | fi | |
3605 | done | |
1b1fe467 | 3606 | done |
b709b946 | 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 |
1b1fe467 | 3613 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3614 | $as_echo "$CC" >&6; } |
bb70624e | 3615 | else |
1b1fe467 | 3616 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3617 | $as_echo "no" >&6; } |
bb70624e | 3618 | fi |
ccc6cda3 | 3619 | |
b709b946 | 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 | |
b709b946 | 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 | |
1b1fe467 | 3630 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3631 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 3632 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
dd4f3dd8 | 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 | |
a82a04b3 CR |
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=. | |
1b1fe467 | 3643 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 3644 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 3645 | ac_cv_prog_ac_ct_CC="$ac_prog" |
1b1fe467 | 3646 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3647 | break 2 |
3648 | fi | |
3649 | done | |
1b1fe467 | 3650 | done |
b709b946 | 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 | |
1b1fe467 | 3657 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
dd4f3dd8 | 3658 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3659 | else |
1b1fe467 | 3660 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3661 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3662 | fi |
3663 | ||
b709b946 | 3664 | |
f73dda09 JA |
3665 | test -n "$ac_ct_CC" && break |
3666 | done | |
ccc6cda3 | 3667 | |
b709b946 CR |
3668 | if test "x$ac_ct_CC" = x; then |
3669 | CC="" | |
3670 | else | |
3671 | case $cross_compiling:$ac_tool_warned in | |
3672 | yes:) | |
1b1fe467 | 3673 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 3674 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
3675 | ac_tool_warned=yes ;; |
3676 | esac | |
3677 | CC=$ac_ct_CC | |
3678 | fi | |
bb70624e JA |
3679 | fi |
3680 | ||
f73dda09 JA |
3681 | fi |
3682 | ||
a82a04b3 | 3683 | |
1b1fe467 | 3684 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3685 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
1b1fe467 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. | |
1b1fe467 | 3690 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
dd4f3dd8 CR |
3691 | set X $ac_compile |
3692 | ac_compiler=$2 | |
1b1fe467 CR |
3693 | for ac_option in --version -v -V -qversion; do |
3694 | { { ac_try="$ac_compiler $ac_option >&5" | |
7175a77f CR |
3695 | case "(($ac_try" in |
3696 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3697 | *) ac_try_echo=$ac_try;; | |
3698 | esac | |
1b1fe467 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 | |
7175a77f | 3702 | ac_status=$? |
1b1fe467 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 | |
1b1fe467 | 3714 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 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 | |
dd4f3dd8 | 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. | |
1b1fe467 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; } | |
dd4f3dd8 CR |
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 | ||
b709b946 CR |
3737 | ac_rmfiles= |
3738 | for ac_file in $ac_files | |
3739 | do | |
3740 | case $ac_file in | |
dd4f3dd8 | 3741 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
b709b946 CR |
3742 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
3743 | esac | |
3744 | done | |
3745 | rm -f $ac_rmfiles | |
3746 | ||
1b1fe467 | 3747 | if { { ac_try="$ac_link_default" |
b709b946 CR |
3748 | case "(($ac_try" in |
3749 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3750 | *) ac_try_echo=$ac_try;; | |
3751 | esac | |
1b1fe467 CR |
3752 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3753 | $as_echo "$ac_try_echo"; } >&5 | |
b709b946 | 3754 | (eval "$ac_link_default") 2>&5 |
f73dda09 | 3755 | ac_status=$? |
1b1fe467 CR |
3756 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3757 | test $ac_status = 0; }; then : | |
b709b946 CR |
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. | |
dd4f3dd8 | 3763 | for ac_file in $ac_files '' |
5e4a95c7 CR |
3764 | do |
3765 | test -f "$ac_file" || continue | |
f73dda09 | 3766 | case $ac_file in |
dd4f3dd8 | 3767 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
5e4a95c7 CR |
3768 | ;; |
3769 | [ab].out ) | |
3770 | # We found the default executable, but exeext='' is most | |
3771 | # certainly right. | |
3772 | break;; | |
3773 | *.* ) | |
1b1fe467 | 3774 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
b709b946 CR |
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. | |
5e4a95c7 CR |
3783 | break;; |
3784 | * ) | |
3785 | break;; | |
f73dda09 JA |
3786 | esac |
3787 | done | |
b709b946 CR |
3788 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
3789 | ||
ccc6cda3 | 3790 | else |
dd4f3dd8 CR |
3791 | ac_file='' |
3792 | fi | |
1b1fe467 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 | |
5e4a95c7 CR |
3797 | sed 's/^/| /' conftest.$ac_ext >&5 |
3798 | ||
1b1fe467 | 3799 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3800 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
1b1fe467 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 |
1b1fe467 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 | |
dd4f3dd8 | 3813 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
f73dda09 | 3814 | ac_clean_files=$ac_clean_files_save |
1b1fe467 | 3815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
dd4f3dd8 | 3816 | $as_echo_n "checking for suffix of executables... " >&6; } |
1b1fe467 | 3817 | if { { ac_try="$ac_link" |
b709b946 CR |
3818 | case "(($ac_try" in |
3819 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3820 | *) ac_try_echo=$ac_try;; | |
3821 | esac | |
1b1fe467 CR |
3822 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3823 | $as_echo "$ac_try_echo"; } >&5 | |
b709b946 | 3824 | (eval "$ac_link") 2>&5 |
f73dda09 | 3825 | ac_status=$? |
1b1fe467 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'. | |
5e4a95c7 CR |
3832 | for ac_file in conftest.exe conftest conftest.*; do |
3833 | test -f "$ac_file" || continue | |
f73dda09 | 3834 | case $ac_file in |
dd4f3dd8 | 3835 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
f73dda09 | 3836 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
5e4a95c7 | 3837 | break;; |
f73dda09 JA |
3838 | * ) break;; |
3839 | esac | |
3840 | done | |
ccc6cda3 | 3841 | else |
1b1fe467 | 3842 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3843 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
1b1fe467 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 |
1b1fe467 CR |
3847 | rm -f conftest conftest$ac_cv_exeext |
3848 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
dd4f3dd8 | 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 | |
1b1fe467 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 | |
7175a77f | 3914 | $as_echo_n "checking for suffix of object files... " >&6; } |
1b1fe467 | 3915 | if ${ac_cv_objext+:} false; then : |
7175a77f CR |
3916 | $as_echo_n "(cached) " >&6 |
3917 | else | |
1b1fe467 | 3918 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7f947b68 | 3919 | /* end confdefs.h. */ |
7175a77f | 3920 | |
7f947b68 CR |
3921 | int |
3922 | main () | |
3923 | { | |
7f947b68 CR |
3924 | |
3925 | ; | |
3926 | return 0; | |
3927 | } | |
3928 | _ACEOF | |
7175a77f | 3929 | rm -f conftest.o conftest.obj |
1b1fe467 | 3930 | if { { ac_try="$ac_compile" |
7f947b68 CR |
3931 | case "(($ac_try" in |
3932 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3933 | *) ac_try_echo=$ac_try;; | |
3934 | esac | |
1b1fe467 CR |
3935 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3936 | $as_echo "$ac_try_echo"; } >&5 | |
7175a77f | 3937 | (eval "$ac_compile") 2>&5 |
7f947b68 | 3938 | ac_status=$? |
1b1fe467 CR |
3939 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3940 | test $ac_status = 0; }; then : | |
7610e0c5 CR |
3941 | for ac_file in conftest.o conftest.obj conftest.*; do |
3942 | test -f "$ac_file" || continue; | |
3943 | case $ac_file in | |
3944 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; | |
3945 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` | |
3946 | break;; | |
3947 | esac | |
3948 | done | |
3949 | else | |
3950 | $as_echo "$as_me: failed program was:" >&5 | |
3951 | sed 's/^/| /' conftest.$ac_ext >&5 | |
3952 | ||
1b1fe467 | 3953 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
71412226 | 3954 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
1b1fe467 CR |
3955 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
3956 | See \`config.log' for more details" "$LINENO" 5; } | |
71412226 | 3957 | fi |
f73dda09 | 3958 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
ccc6cda3 | 3959 | fi |
1b1fe467 | 3960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
dd4f3dd8 | 3961 | $as_echo "$ac_cv_objext" >&6; } |
f73dda09 JA |
3962 | OBJEXT=$ac_cv_objext |
3963 | ac_objext=$OBJEXT | |
1b1fe467 | 3964 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
dd4f3dd8 | 3965 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
1b1fe467 | 3966 | if ${ac_cv_c_compiler_gnu+:} false; then : |
dd4f3dd8 | 3967 | $as_echo_n "(cached) " >&6 |
f73dda09 | 3968 | else |
1b1fe467 | 3969 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 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 | |
1b1fe467 | 3983 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
3984 | ac_compiler_gnu=yes |
3985 | else | |
1b1fe467 | 3986 | ac_compiler_gnu=no |
f73dda09 | 3987 | fi |
b709b946 | 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 | |
1b1fe467 | 3992 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
dd4f3dd8 CR |
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 | |
1b1fe467 | 4001 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
dd4f3dd8 | 4002 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
1b1fe467 | 4003 | if ${ac_cv_prog_cc_g+:} false; then : |
dd4f3dd8 | 4004 | $as_echo_n "(cached) " >&6 |
f73dda09 | 4005 | else |
b709b946 CR |
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" | |
1b1fe467 | 4010 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4011 | /* end confdefs.h. */ |
f73dda09 JA |
4012 | |
4013 | int | |
4014 | main () | |
4015 | { | |
ccc6cda3 | 4016 | |
f73dda09 JA |
4017 | ; |
4018 | return 0; | |
4019 | } | |
4020 | _ACEOF | |
1b1fe467 | 4021 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
4022 | ac_cv_prog_cc_g=yes |
4023 | else | |
1b1fe467 CR |
4024 | CFLAGS="" |
4025 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 4026 | /* end confdefs.h. */ |
c184f645 | 4027 | |
c184f645 CR |
4028 | int |
4029 | main () | |
4030 | { | |
b709b946 | 4031 | |
c184f645 CR |
4032 | ; |
4033 | return 0; | |
4034 | } | |
4035 | _ACEOF | |
1b1fe467 | 4036 | if ac_fn_c_try_compile "$LINENO"; then : |
7175a77f | 4037 | |
1b1fe467 CR |
4038 | else |
4039 | ac_c_werror_flag=$ac_save_c_werror_flag | |
b709b946 | 4040 | CFLAGS="-g" |
1b1fe467 | 4041 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4042 | /* end confdefs.h. */ |
b709b946 | 4043 | |
f73dda09 JA |
4044 | int |
4045 | main () | |
4046 | { | |
b709b946 | 4047 | |
f73dda09 JA |
4048 | ; |
4049 | return 0; | |
4050 | } | |
4051 | _ACEOF | |
1b1fe467 | 4052 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 4053 | ac_cv_prog_cc_g=yes |
d3ad40de | 4054 | fi |
b709b946 CR |
4055 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4056 | fi | |
b709b946 CR |
4057 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4058 | fi | |
b709b946 CR |
4059 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4060 | ac_c_werror_flag=$ac_save_c_werror_flag | |
4061 | fi | |
1b1fe467 | 4062 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
dd4f3dd8 | 4063 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
b709b946 CR |
4064 | if test "$ac_test_CFLAGS" = set; then |
4065 | CFLAGS=$ac_save_CFLAGS | |
4066 | elif test $ac_cv_prog_cc_g = yes; then | |
4067 | if test "$GCC" = yes; then | |
4068 | CFLAGS="-g -O2" | |
4069 | else | |
4070 | CFLAGS="-g" | |
4071 | fi | |
4072 | else | |
4073 | if test "$GCC" = yes; then | |
4074 | CFLAGS="-O2" | |
4075 | else | |
4076 | CFLAGS= | |
4077 | fi | |
4078 | fi | |
1b1fe467 | 4079 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
dd4f3dd8 | 4080 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
1b1fe467 | 4081 | if ${ac_cv_prog_cc_c89+:} false; then : |
dd4f3dd8 | 4082 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
4083 | else |
4084 | ac_cv_prog_cc_c89=no | |
4085 | ac_save_CC=$CC | |
1b1fe467 | 4086 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4087 | /* end confdefs.h. */ |
b709b946 CR |
4088 | #include <stdarg.h> |
4089 | #include <stdio.h> | |
0ee50808 | 4090 | struct stat; |
b709b946 CR |
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 | |
4113 | as 'x'. The following induces an error, until -std is added to get | |
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 | |
4116 | that's true only with -std. */ | |
4117 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; | |
4118 | ||
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 | ||
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; | |
f73dda09 JA |
4130 | int |
4131 | main () | |
4132 | { | |
b709b946 | 4133 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
f73dda09 JA |
4134 | ; |
4135 | return 0; | |
4136 | } | |
4137 | _ACEOF | |
b709b946 CR |
4138 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
4139 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
4140 | do | |
4141 | CC="$ac_save_CC $ac_arg" | |
1b1fe467 | 4142 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 4143 | ac_cv_prog_cc_c89=$ac_arg |
f73dda09 | 4144 | fi |
b709b946 CR |
4145 | rm -f core conftest.err conftest.$ac_objext |
4146 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
cce855bc | 4147 | done |
b709b946 CR |
4148 | rm -f conftest.$ac_ext |
4149 | CC=$ac_save_CC | |
4150 | ||
f73dda09 | 4151 | fi |
b709b946 CR |
4152 | # AC_CACHE_VAL |
4153 | case "x$ac_cv_prog_cc_c89" in | |
4154 | x) | |
1b1fe467 | 4155 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
dd4f3dd8 | 4156 | $as_echo "none needed" >&6; } ;; |
b709b946 | 4157 | xno) |
1b1fe467 | 4158 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
dd4f3dd8 | 4159 | $as_echo "unsupported" >&6; } ;; |
b709b946 CR |
4160 | *) |
4161 | CC="$CC $ac_cv_prog_cc_c89" | |
1b1fe467 | 4162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
dd4f3dd8 | 4163 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
b709b946 | 4164 | esac |
1b1fe467 | 4165 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
cce855bc | 4166 | |
1b1fe467 | 4167 | fi |
5e4a95c7 | 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 | |
a82a04b3 CR |
4175 | |
4176 | ||
4177 | ||
1b1fe467 | 4178 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror in -lcposix" >&5 |
dd4f3dd8 | 4179 | $as_echo_n "checking for strerror in -lcposix... " >&6; } |
1b1fe467 | 4180 | if ${ac_cv_lib_cposix_strerror+:} false; then : |
dd4f3dd8 | 4181 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
4182 | else |
4183 | ac_check_lib_save_LIBS=$LIBS | |
4184 | LIBS="-lcposix $LIBS" | |
1b1fe467 | 4185 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4186 | /* end confdefs.h. */ |
ccc6cda3 | 4187 | |
b709b946 CR |
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. */ | |
5e13499c CR |
4191 | #ifdef __cplusplus |
4192 | extern "C" | |
4193 | #endif | |
5e13499c CR |
4194 | char strerror (); |
4195 | int | |
4196 | main () | |
4197 | { | |
b709b946 | 4198 | return strerror (); |
5e13499c CR |
4199 | ; |
4200 | return 0; | |
4201 | } | |
4202 | _ACEOF | |
1b1fe467 | 4203 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c | 4204 | ac_cv_lib_cposix_strerror=yes |
ccc6cda3 | 4205 | else |
1b1fe467 | 4206 | ac_cv_lib_cposix_strerror=no |
5e13499c | 4207 | fi |
1b1fe467 CR |
4208 | rm -f core conftest.err conftest.$ac_objext \ |
4209 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
4210 | LIBS=$ac_check_lib_save_LIBS |
4211 | fi | |
1b1fe467 | 4212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cposix_strerror" >&5 |
dd4f3dd8 | 4213 | $as_echo "$ac_cv_lib_cposix_strerror" >&6; } |
1b1fe467 | 4214 | if test "x$ac_cv_lib_cposix_strerror" = xyes; then : |
5e13499c | 4215 | LIBS="$LIBS -lcposix" |
ccc6cda3 JA |
4216 | fi |
4217 | ||
a82a04b3 CR |
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 | |
1b1fe467 | 4225 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
dd4f3dd8 | 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 | |
1b1fe467 | 4232 | if ${ac_cv_prog_CPP+:} false; then : |
dd4f3dd8 | 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. | |
5e4a95c7 CR |
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. |
1b1fe467 | 4247 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
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 |
1b1fe467 | 4256 | if ac_fn_c_try_cpp "$LINENO"; then : |
7175a77f | 4257 | |
1b1fe467 | 4258 | else |
f73dda09 JA |
4259 | # Broken: fails on valid input. |
4260 | continue | |
4261 | fi | |
1b1fe467 | 4262 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4263 | |
b709b946 | 4264 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4265 | # can be detected and how. |
1b1fe467 | 4266 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4267 | /* end confdefs.h. */ |
f73dda09 JA |
4268 | #include <ac_nonexistent.h> |
4269 | _ACEOF | |
1b1fe467 | 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 | |
1b1fe467 | 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. | |
1b1fe467 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 | |
1b1fe467 | 4295 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
dd4f3dd8 | 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. | |
5e4a95c7 CR |
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. | |
1b1fe467 | 4306 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
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 |
1b1fe467 | 4315 | if ac_fn_c_try_cpp "$LINENO"; then : |
7175a77f | 4316 | |
1b1fe467 | 4317 | else |
f73dda09 JA |
4318 | # Broken: fails on valid input. |
4319 | continue | |
4320 | fi | |
1b1fe467 | 4321 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4322 | |
b709b946 | 4323 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4324 | # can be detected and how. |
1b1fe467 | 4325 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4326 | /* end confdefs.h. */ |
f73dda09 JA |
4327 | #include <ac_nonexistent.h> |
4328 | _ACEOF | |
1b1fe467 | 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 |
1b1fe467 | 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. | |
1b1fe467 CR |
4341 | rm -f conftest.i conftest.err conftest.$ac_ext |
4342 | if $ac_preproc_ok; then : | |
4343 | ||
ccc6cda3 | 4344 | else |
1b1fe467 | 4345 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 4346 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
1b1fe467 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 | ||
a82a04b3 | 4357 | |
1b1fe467 | 4358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
dd4f3dd8 | 4359 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
1b1fe467 | 4360 | if ${ac_cv_path_GREP+:} false; then : |
dd4f3dd8 | 4361 | $as_echo_n "(cached) " >&6 |
b709b946 | 4362 | else |
dd4f3dd8 | 4363 | if test -z "$GREP"; then |
b709b946 | 4364 | ac_path_GREP_found=false |
dd4f3dd8 CR |
4365 | # Loop through the user's path and test for each of PROGNAME-LIST |
4366 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
b709b946 CR |
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=. | |
1b1fe467 | 4371 | for ac_prog in grep ggrep; do |
dd4f3dd8 CR |
4372 | for ac_exec_ext in '' $ac_executable_extensions; do |
4373 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
0ee50808 | 4374 | as_fn_executable_p "$ac_path_GREP" || continue |
dd4f3dd8 | 4375 | # Check for GNU ac_path_GREP and select it if it is found. |
b709b946 CR |
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 | |
dd4f3dd8 | 4382 | $as_echo_n 0123456789 >"conftest.in" |
b709b946 CR |
4383 | while : |
4384 | do | |
4385 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4386 | mv "conftest.tmp" "conftest.in" | |
4387 | cp "conftest.in" "conftest.nl" | |
dd4f3dd8 | 4388 | $as_echo 'GREP' >> "conftest.nl" |
b709b946 CR |
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 | |
1b1fe467 | 4391 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
b709b946 CR |
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 | ||
dd4f3dd8 CR |
4403 | $ac_path_GREP_found && break 3 |
4404 | done | |
b709b946 | 4405 | done |
1b1fe467 | 4406 | done |
b709b946 | 4407 | IFS=$as_save_IFS |
dd4f3dd8 | 4408 | if test -z "$ac_cv_path_GREP"; then |
1b1fe467 | 4409 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
dd4f3dd8 | 4410 | fi |
b709b946 CR |
4411 | else |
4412 | ac_cv_path_GREP=$GREP | |
4413 | fi | |
4414 | ||
b709b946 | 4415 | fi |
1b1fe467 | 4416 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
dd4f3dd8 | 4417 | $as_echo "$ac_cv_path_GREP" >&6; } |
b709b946 CR |
4418 | GREP="$ac_cv_path_GREP" |
4419 | ||
4420 | ||
1b1fe467 | 4421 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
dd4f3dd8 | 4422 | $as_echo_n "checking for egrep... " >&6; } |
1b1fe467 | 4423 | if ${ac_cv_path_EGREP+:} false; then : |
dd4f3dd8 | 4424 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
4425 | else |
4426 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 | |
4427 | then ac_cv_path_EGREP="$GREP -E" | |
4428 | else | |
dd4f3dd8 | 4429 | if test -z "$EGREP"; then |
b709b946 | 4430 | ac_path_EGREP_found=false |
dd4f3dd8 CR |
4431 | # Loop through the user's path and test for each of PROGNAME-LIST |
4432 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
b709b946 CR |
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=. | |
1b1fe467 | 4437 | for ac_prog in egrep; do |
dd4f3dd8 CR |
4438 | for ac_exec_ext in '' $ac_executable_extensions; do |
4439 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
0ee50808 | 4440 | as_fn_executable_p "$ac_path_EGREP" || continue |
dd4f3dd8 | 4441 | # Check for GNU ac_path_EGREP and select it if it is found. |
b709b946 CR |
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 | |
dd4f3dd8 | 4448 | $as_echo_n 0123456789 >"conftest.in" |
b709b946 CR |
4449 | while : |
4450 | do | |
4451 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4452 | mv "conftest.tmp" "conftest.in" | |
4453 | cp "conftest.in" "conftest.nl" | |
dd4f3dd8 | 4454 | $as_echo 'EGREP' >> "conftest.nl" |
b709b946 CR |
4455 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
4456 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
1b1fe467 | 4457 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
b709b946 CR |
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 | |
5e4a95c7 | 4462 | fi |
b709b946 CR |
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 | ||
dd4f3dd8 CR |
4469 | $ac_path_EGREP_found && break 3 |
4470 | done | |
b709b946 | 4471 | done |
1b1fe467 | 4472 | done |
b709b946 | 4473 | IFS=$as_save_IFS |
dd4f3dd8 | 4474 | if test -z "$ac_cv_path_EGREP"; then |
1b1fe467 | 4475 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
dd4f3dd8 | 4476 | fi |
b709b946 CR |
4477 | else |
4478 | ac_cv_path_EGREP=$EGREP | |
4479 | fi | |
4480 | ||
b709b946 | 4481 | fi |
d3ad40de | 4482 | fi |
1b1fe467 | 4483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
dd4f3dd8 | 4484 | $as_echo "$ac_cv_path_EGREP" >&6; } |
b709b946 | 4485 | EGREP="$ac_cv_path_EGREP" |
d3ad40de | 4486 | |
9d6e5e30 | 4487 | |
1b1fe467 | 4488 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
dd4f3dd8 | 4489 | $as_echo_n "checking for ANSI C header files... " >&6; } |
1b1fe467 | 4490 | if ${ac_cv_header_stdc+:} false; then : |
dd4f3dd8 | 4491 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 4492 | else |
1b1fe467 | 4493 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4494 | /* end confdefs.h. */ |
a82a04b3 CR |
4495 | #include <stdlib.h> |
4496 | #include <stdarg.h> | |
4497 | #include <string.h> | |
4498 | #include <float.h> | |
4499 | ||
5e4a95c7 CR |
4500 | int |
4501 | main () | |
4502 | { | |
4503 | ||
4504 | ; | |
4505 | return 0; | |
4506 | } | |
a82a04b3 | 4507 | _ACEOF |
1b1fe467 | 4508 | if ac_fn_c_try_compile "$LINENO"; then : |
a82a04b3 | 4509 | ac_cv_header_stdc=yes |
f73dda09 | 4510 | else |
1b1fe467 | 4511 | ac_cv_header_stdc=no |
a82a04b3 | 4512 | fi |
b709b946 | 4513 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
a82a04b3 CR |
4514 | |
4515 | if test $ac_cv_header_stdc = yes; then | |
4516 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
1b1fe467 | 4517 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4518 | /* end confdefs.h. */ |
a82a04b3 CR |
4519 | #include <string.h> |
4520 | ||
4521 | _ACEOF | |
4522 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 CR |
4523 | $EGREP "memchr" >/dev/null 2>&1; then : |
4524 | ||
a82a04b3 CR |
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. | |
1b1fe467 | 4534 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4535 | /* end confdefs.h. */ |
a82a04b3 CR |
4536 | #include <stdlib.h> |
4537 | ||
4538 | _ACEOF | |
4539 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 CR |
4540 | $EGREP "free" >/dev/null 2>&1; then : |
4541 | ||
a82a04b3 CR |
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. | |
1b1fe467 | 4551 | if test "$cross_compiling" = yes; then : |
a82a04b3 CR |
4552 | : |
4553 | else | |
1b1fe467 | 4554 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4555 | /* end confdefs.h. */ |
a82a04b3 | 4556 | #include <ctype.h> |
b709b946 | 4557 | #include <stdlib.h> |
a82a04b3 CR |
4558 | #if ((' ' & 0x0FF) == 0x020) |
4559 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4560 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4561 | #else | |
5e4a95c7 CR |
4562 | # define ISLOWER(c) \ |
4563 | (('a' <= (c) && (c) <= 'i') \ | |
4564 | || ('j' <= (c) && (c) <= 'r') \ | |
4565 | || ('s' <= (c) && (c) <= 'z')) | |
a82a04b3 CR |
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)) | |
5e4a95c7 | 4576 | || toupper (i) != TOUPPER (i)) |
b709b946 CR |
4577 | return 2; |
4578 | return 0; | |
a82a04b3 CR |
4579 | } |
4580 | _ACEOF | |
1b1fe467 | 4581 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f | 4582 | |
1b1fe467 CR |
4583 | else |
4584 | ac_cv_header_stdc=no | |
a82a04b3 | 4585 | fi |
1b1fe467 CR |
4586 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
4587 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
a82a04b3 | 4588 | fi |
b709b946 | 4589 | |
a82a04b3 CR |
4590 | fi |
4591 | fi | |
1b1fe467 | 4592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
dd4f3dd8 | 4593 | $as_echo "$ac_cv_header_stdc" >&6; } |
a82a04b3 CR |
4594 | if test $ac_cv_header_stdc = yes; then |
4595 | ||
1b1fe467 | 4596 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
7f947b68 CR |
4597 | |
4598 | fi | |
4599 | ||
7175a77f | 4600 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
7175a77f 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 | |
1b1fe467 CR |
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 : | |
7175a77f CR |
4608 | cat >>confdefs.h <<_ACEOF |
4609 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
4610 | _ACEOF | |
4611 | ||
4612 | fi | |
4613 | ||
4614 | done | |
4615 | ||
4616 | ||
4617 | ||
1b1fe467 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 : | |
7175a77f CR |
4620 | MINIX=yes |
4621 | else | |
4622 | MINIX= | |
4623 | fi | |
4624 | ||
4625 | ||
4626 | if test "$MINIX" = yes; then | |
4627 | ||
1b1fe467 | 4628 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
7175a77f CR |
4629 | |
4630 | ||
1b1fe467 | 4631 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
7175a77f CR |
4632 | |
4633 | ||
1b1fe467 | 4634 | $as_echo "#define _MINIX 1" >>confdefs.h |
7175a77f CR |
4635 | |
4636 | fi | |
4637 | ||
4638 | ||
1b1fe467 | 4639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 |
7175a77f | 4640 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } |
1b1fe467 | 4641 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
7175a77f CR |
4642 | $as_echo_n "(cached) " >&6 |
4643 | else | |
1b1fe467 | 4644 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
4645 | /* end confdefs.h. */ |
4646 | ||
0ee50808 CR |
4647 | # define __EXTENSIONS__ 1 |
4648 | $ac_includes_default | |
7175a77f CR |
4649 | int |
4650 | main () | |
4651 | { | |
4652 | ||
4653 | ; | |
4654 | return 0; | |
4655 | } | |
4656 | _ACEOF | |
1b1fe467 | 4657 | if ac_fn_c_try_compile "$LINENO"; then : |
7175a77f | 4658 | ac_cv_safe_to_define___extensions__=yes |
7610e0c5 | 4659 | else |
1b1fe467 | 4660 | ac_cv_safe_to_define___extensions__=no |
7610e0c5 | 4661 | fi |
7610e0c5 CR |
4662 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4663 | fi | |
1b1fe467 | 4664 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
7f947b68 CR |
4665 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } |
4666 | test $ac_cv_safe_to_define___extensions__ = yes && | |
1b1fe467 | 4667 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h |
2dead0c4 | 4668 | |
1b1fe467 | 4669 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
7610e0c5 | 4670 | |
1b1fe467 | 4671 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
7f947b68 | 4672 | |
1b1fe467 CR |
4673 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
4674 | ||
4675 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
7610e0c5 | 4676 | |
c920c360 | 4677 | |
2dead0c4 | 4678 | |
7f947b68 CR |
4679 | |
4680 | # Check whether --enable-largefile was given. | |
1b1fe467 | 4681 | if test "${enable_largefile+set}" = set; then : |
7f947b68 | 4682 | enableval=$enable_largefile; |
7610e0c5 CR |
4683 | fi |
4684 | ||
7f947b68 | 4685 | if test "$enable_largefile" != no; then |
7610e0c5 | 4686 | |
1b1fe467 | 4687 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 |
abe2eb5b | 4688 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } |
1b1fe467 | 4689 | if ${ac_cv_sys_largefile_CC+:} false; then : |
abe2eb5b CR |
4690 | $as_echo_n "(cached) " >&6 |
4691 | else | |
4692 | ac_cv_sys_largefile_CC=no | |
4693 | if test "$GCC" != yes; then | |
4694 | ac_save_CC=$CC | |
4695 | while :; do | |
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. | |
1b1fe467 | 4698 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b CR |
4699 | /* end confdefs.h. */ |
4700 | #include <sys/types.h> | |
4701 | /* Check that off_t can represent 2**63 - 1 correctly. | |
e3db237e CR |
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. */ | |
f73dda09 JA |
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 | |
1b1fe467 | 4717 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4718 | break |
f73dda09 | 4719 | fi |
b709b946 CR |
4720 | rm -f core conftest.err conftest.$ac_objext |
4721 | CC="$CC -n32" | |
1b1fe467 | 4722 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4723 | ac_cv_sys_largefile_CC=' -n32'; break |
f73dda09 | 4724 | fi |
b709b946 | 4725 | rm -f core conftest.err conftest.$ac_objext |
5e4a95c7 | 4726 | break |
f73dda09 JA |
4727 | done |
4728 | CC=$ac_save_CC | |
4729 | rm -f conftest.$ac_ext | |
4730 | fi | |
bb70624e | 4731 | fi |
1b1fe467 | 4732 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 |
dd4f3dd8 | 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 | |
1b1fe467 | 4738 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 |
dd4f3dd8 | 4739 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } |
1b1fe467 | 4740 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
dd4f3dd8 | 4741 | $as_echo_n "(cached) " >&6 |
bb70624e | 4742 | else |
f73dda09 | 4743 | while :; do |
1b1fe467 | 4744 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 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 | |
1b1fe467 | 4763 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 4764 | ac_cv_sys_file_offset_bits=no; break |
2e4498b3 | 4765 | fi |
2e4498b3 | 4766 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
1b1fe467 | 4767 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2e4498b3 | 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 | |
1b1fe467 | 4787 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4788 | ac_cv_sys_file_offset_bits=64; break |
f73dda09 | 4789 | fi |
b709b946 | 4790 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 4791 | ac_cv_sys_file_offset_bits=unknown |
f73dda09 JA |
4792 | break |
4793 | done | |
4794 | fi | |
1b1fe467 | 4795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 |
dd4f3dd8 CR |
4796 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } |
4797 | case $ac_cv_sys_file_offset_bits in #( | |
4798 | no | unknown) ;; | |
4799 | *) | |
a82a04b3 | 4800 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4801 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits |
a82a04b3 | 4802 | _ACEOF |
dd4f3dd8 CR |
4803 | ;; |
4804 | esac | |
4805 | rm -rf conftest* | |
4806 | if test $ac_cv_sys_file_offset_bits = unknown; then | |
1b1fe467 | 4807 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 |
dd4f3dd8 | 4808 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } |
1b1fe467 | 4809 | if ${ac_cv_sys_large_files+:} false; then : |
dd4f3dd8 | 4810 | $as_echo_n "(cached) " >&6 |
bb70624e | 4811 | else |
f73dda09 | 4812 | while :; do |
1b1fe467 | 4813 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 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 | |
1b1fe467 | 4832 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 4833 | ac_cv_sys_large_files=no; break |
bb70624e | 4834 | fi |
b709b946 | 4835 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
1b1fe467 | 4836 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 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 | |
1b1fe467 | 4856 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4857 | ac_cv_sys_large_files=1; break |
f73dda09 | 4858 | fi |
b709b946 | 4859 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 4860 | ac_cv_sys_large_files=unknown |
f73dda09 JA |
4861 | break |
4862 | done | |
4863 | fi | |
1b1fe467 | 4864 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 |
dd4f3dd8 CR |
4865 | $as_echo "$ac_cv_sys_large_files" >&6; } |
4866 | case $ac_cv_sys_large_files in #( | |
4867 | no | unknown) ;; | |
4868 | *) | |
a82a04b3 | 4869 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4870 | #define _LARGE_FILES $ac_cv_sys_large_files |
a82a04b3 | 4871 | _ACEOF |
dd4f3dd8 CR |
4872 | ;; |
4873 | esac | |
4874 | rm -rf conftest* | |
4875 | fi | |
0ee50808 CR |
4876 | |
4877 | ||
f73dda09 | 4878 | fi |
cce855bc | 4879 | |
a82a04b3 CR |
4880 | |
4881 | ||
dc8fbaf9 | 4882 | SIGNAMES_O= |
b72432fd JA |
4883 | SIGNAMES_H=lsignames.h |
4884 | ||
a82a04b3 CR |
4885 | |
4886 | ||
d3ad40de | 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 | ;; |
9607141c CR |
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 | |
dc8fbaf9 | 4907 | SIGNAMES_O='signames.o' |
9607141c CR |
4908 | CROSS_COMPILE='-DCROSS_COMPILING' |
4909 | ||
cce855bc JA |
4910 | fi |
4911 | ||
a82a04b3 | 4912 | |
dc8fbaf9 | 4913 | |
a82a04b3 | 4914 | |
7610e0c5 CR |
4915 | CFLAGS=${CFLAGS-"$AUTO_CFLAGS"} |
4916 | # LDFLAGS=${LDFLAGS="$AUTO_LDFLAGS"} # XXX | |
ccc6cda3 | 4917 | |
8f50a023 CR |
4918 | # turn off paren warnings in gcc |
4919 | if test "$GCC" = yes && test -n "$DEBUG"; then | |
4920 | CFLAGS="$CFLAGS -Wno-parentheses -Wno-format-security" | |
4921 | fi | |
4922 | ||
cce855bc JA |
4923 | if test "$opt_profiling" = "yes"; then |
4924 | PROFILE_FLAGS=-pg | |
b72432fd JA |
4925 | case "$host_os" in |
4926 | solaris2*) ;; | |
4927 | *) opt_static_link=yes ;; | |
4928 | esac | |
7117c2d2 | 4929 | DEBUG= MALLOC_DEBUG= |
cce855bc JA |
4930 | fi |
4931 | ||
f4f5e1c2 CR |
4932 | prefer_shared=yes |
4933 | prefer_static=no | |
4934 | ||
cce855bc | 4935 | if test "$opt_static_link" = yes; then |
f4f5e1c2 CR |
4936 | prefer_static=yes |
4937 | prefer_shared=no | |
f73dda09 JA |
4938 | # if we're using gcc, add `-static' to LDFLAGS, except on Solaris >= 2 |
4939 | if test -n "$GCC" || test "$ac_cv_c_compiler_gnu" = "yes"; then | |
b72432fd | 4940 | STATIC_LD="-static" |
f73dda09 JA |
4941 | case "$host_os" in |
4942 | solaris2*) ;; | |
4943 | *) LDFLAGS="$LDFLAGS -static" ;; # XXX experimental | |
4944 | esac | |
cce855bc JA |
4945 | fi |
4946 | fi | |
4947 | ||
7610e0c5 | 4948 | # set the appropriate make variables for building the "build tools" |
348a457e CR |
4949 | # modify defaults based on whether or not we are cross compiling, since the |
4950 | # options for the target host may not be appropriate for the build host | |
da5b17cd | 4951 | if test "X$cross_compiling" = "Xno"; then |
7610e0c5 CR |
4952 | CC_FOR_BUILD=${CC_FOR_BUILD-'$(CC)'} |
4953 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-"$CPPFLAGS"} # XXX - should it be '$(CPPFLAGS)' | |
da5b17cd | 4954 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-'$(LDFLAGS)'} |
7610e0c5 CR |
4955 | # CFLAGS set above to default value if not passed in environment |
4956 | CFLAGS_FOR_BUILD=${CFLAGS-'$(CFLAGS)'} | |
4957 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-'$(LIBS)'} | |
da5b17cd | 4958 | else |
7610e0c5 | 4959 | CC_FOR_BUILD=${CC_FOR_BUILD-"gcc"} |
da5b17cd CR |
4960 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-""} |
4961 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-""} | |
7610e0c5 CR |
4962 | CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD="-g"} |
4963 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-""} | |
da5b17cd CR |
4964 | fi |
4965 | ||
7610e0c5 | 4966 | |
7117c2d2 | 4967 | |
a82a04b3 CR |
4968 | |
4969 | ||
4970 | ||
4971 | ||
4972 | ||
4973 | ||
4974 | ||
4975 | ||
4976 | ||
f73dda09 | 4977 | if test $ac_cv_c_compiler_gnu = yes; then |
1b1fe467 | 4978 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 |
dd4f3dd8 | 4979 | $as_echo_n "checking whether $CC needs -traditional... " >&6; } |
1b1fe467 | 4980 | if ${ac_cv_prog_gcc_traditional+:} false; then : |
dd4f3dd8 | 4981 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
4982 | else |
4983 | ac_pattern="Autoconf.*'x'" | |
1b1fe467 | 4984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4985 | /* end confdefs.h. */ |
ccc6cda3 JA |
4986 | #include <sgtty.h> |
4987 | Autoconf TIOCGETP | |
f73dda09 | 4988 | _ACEOF |
ccc6cda3 | 4989 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 | 4990 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
4991 | ac_cv_prog_gcc_traditional=yes |
4992 | else | |
ccc6cda3 JA |
4993 | ac_cv_prog_gcc_traditional=no |
4994 | fi | |
4995 | rm -f conftest* | |
4996 | ||
a82a04b3 | 4997 | |
ccc6cda3 | 4998 | if test $ac_cv_prog_gcc_traditional = no; then |
1b1fe467 | 4999 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5000 | /* end confdefs.h. */ |
ccc6cda3 JA |
5001 | #include <termio.h> |
5002 | Autoconf TCGETA | |
f73dda09 | 5003 | _ACEOF |
ccc6cda3 | 5004 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 | 5005 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
5006 | ac_cv_prog_gcc_traditional=yes |
5007 | fi | |
5008 | rm -f conftest* | |
5009 | ||
5010 | fi | |
5011 | fi | |
1b1fe467 | 5012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 |
dd4f3dd8 | 5013 | $as_echo "$ac_cv_prog_gcc_traditional" >&6; } |
ccc6cda3 JA |
5014 | if test $ac_cv_prog_gcc_traditional = yes; then |
5015 | CC="$CC -traditional" | |
5016 | fi | |
5017 | fi | |
5018 | ||
a82a04b3 CR |
5019 | |
5020 | ||
f73dda09 | 5021 | if test "$opt_readline" = yes && test "$opt_with_installed_readline" != "no" |
b72432fd | 5022 | then |
f73dda09 JA |
5023 | # If the user specified --with-installed-readline=PREFIX and PREFIX |
5024 | # is not `yes', set ac_cv_rl_prefix to PREFIX | |
5025 | test $opt_with_installed_readline != "yes" && ac_cv_rl_prefix=$opt_with_installed_readline | |
b72432fd | 5026 | |
a82a04b3 | 5027 | |
bb70624e JA |
5028 | if test "X$bash_cv_termcap_lib" = "X"; then |
5029 | _bash_needmsg=yes | |
5030 | else | |
1b1fe467 | 5031 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 5032 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e JA |
5033 | _bash_needmsg= |
5034 | fi | |
1b1fe467 | 5035 | if ${bash_cv_termcap_lib+:} false; then : |
dd4f3dd8 | 5036 | $as_echo_n "(cached) " >&6 |
bb70624e | 5037 | else |
1b1fe467 CR |
5038 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" |
5039 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
5040 | bash_cv_termcap_lib=libc | |
5041 | else | |
5042 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 | |
5043 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } | |
5044 | if ${ac_cv_lib_termcap_tgetent+:} false; then : | |
dd4f3dd8 | 5045 | $as_echo_n "(cached) " >&6 |
bb70624e | 5046 | else |
1b1fe467 CR |
5047 | ac_check_lib_save_LIBS=$LIBS |
5048 | LIBS="-ltermcap $LIBS" | |
5049 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f CR |
5050 | /* end confdefs.h. */ |
5051 | ||
5052 | /* Override any GCC internal prototype to avoid an error. | |
5053 | Use char because int might match the return type of a GCC | |
5054 | builtin and then its argument prototype would still apply. */ | |
5055 | #ifdef __cplusplus | |
5056 | extern "C" | |
5057 | #endif | |
5058 | char tgetent (); | |
5059 | int | |
5060 | main () | |
5061 | { | |
5062 | return tgetent (); | |
5063 | ; | |
5064 | return 0; | |
5065 | } | |
5066 | _ACEOF | |
1b1fe467 | 5067 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f CR |
5068 | ac_cv_lib_termcap_tgetent=yes |
5069 | else | |
1b1fe467 | 5070 | ac_cv_lib_termcap_tgetent=no |
7175a77f | 5071 | fi |
1b1fe467 CR |
5072 | rm -f core conftest.err conftest.$ac_objext \ |
5073 | conftest$ac_exeext conftest.$ac_ext | |
7175a77f CR |
5074 | LIBS=$ac_check_lib_save_LIBS |
5075 | fi | |
1b1fe467 | 5076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
7175a77f | 5077 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } |
1b1fe467 | 5078 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : |
7f947b68 | 5079 | bash_cv_termcap_lib=libtermcap |
e3db237e | 5080 | else |
1b1fe467 | 5081 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
7f947b68 | 5082 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } |
1b1fe467 | 5083 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : |
e3db237e CR |
5084 | $as_echo_n "(cached) " >&6 |
5085 | else | |
5086 | ac_check_lib_save_LIBS=$LIBS | |
7f947b68 | 5087 | LIBS="-ltinfo $LIBS" |
1b1fe467 | 5088 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e CR |
5089 | /* end confdefs.h. */ |
5090 | ||
5091 | /* Override any GCC internal prototype to avoid an error. | |
5092 | Use char because int might match the return type of a GCC | |
5093 | builtin and then its argument prototype would still apply. */ | |
5094 | #ifdef __cplusplus | |
5095 | extern "C" | |
5096 | #endif | |
5097 | char tgetent (); | |
5098 | int | |
5099 | main () | |
5100 | { | |
5101 | return tgetent (); | |
5102 | ; | |
5103 | return 0; | |
5104 | } | |
5105 | _ACEOF | |
1b1fe467 | 5106 | if ac_fn_c_try_link "$LINENO"; then : |
7f947b68 | 5107 | ac_cv_lib_tinfo_tgetent=yes |
abe2eb5b | 5108 | else |
1b1fe467 | 5109 | ac_cv_lib_tinfo_tgetent=no |
abe2eb5b | 5110 | fi |
1b1fe467 CR |
5111 | rm -f core conftest.err conftest.$ac_objext \ |
5112 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b CR |
5113 | LIBS=$ac_check_lib_save_LIBS |
5114 | fi | |
1b1fe467 | 5115 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
abe2eb5b | 5116 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
1b1fe467 | 5117 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
abe2eb5b | 5118 | bash_cv_termcap_lib=libtinfo |
bb70624e | 5119 | else |
1b1fe467 | 5120 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
dd4f3dd8 | 5121 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
1b1fe467 | 5122 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
dd4f3dd8 | 5123 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5124 | else |
5125 | ac_check_lib_save_LIBS=$LIBS | |
5126 | LIBS="-lcurses $LIBS" | |
1b1fe467 | 5127 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5128 | /* end confdefs.h. */ |
b72432fd | 5129 | |
b709b946 CR |
5130 | /* Override any GCC internal prototype to avoid an error. |
5131 | Use char because int might match the return type of a GCC | |
5132 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5133 | #ifdef __cplusplus |
5134 | extern "C" | |
5135 | #endif | |
f73dda09 JA |
5136 | char tgetent (); |
5137 | int | |
5138 | main () | |
5139 | { | |
b709b946 | 5140 | return tgetent (); |
f73dda09 JA |
5141 | ; |
5142 | return 0; | |
5143 | } | |
5144 | _ACEOF | |
1b1fe467 | 5145 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5146 | ac_cv_lib_curses_tgetent=yes |
5147 | else | |
1b1fe467 | 5148 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 5149 | fi |
1b1fe467 CR |
5150 | rm -f core conftest.err conftest.$ac_objext \ |
5151 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5152 | LIBS=$ac_check_lib_save_LIBS |
5153 | fi | |
1b1fe467 | 5154 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
dd4f3dd8 | 5155 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
1b1fe467 | 5156 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
bb70624e JA |
5157 | bash_cv_termcap_lib=libcurses |
5158 | else | |
1b1fe467 | 5159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
dd4f3dd8 | 5160 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
1b1fe467 | 5161 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
dd4f3dd8 | 5162 | $as_echo_n "(cached) " >&6 |
bb70624e | 5163 | else |
f73dda09 | 5164 | ac_check_lib_save_LIBS=$LIBS |
bb70624e | 5165 | LIBS="-lncurses $LIBS" |
1b1fe467 | 5166 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5167 | /* end confdefs.h. */ |
f73dda09 | 5168 | |
b709b946 CR |
5169 | /* Override any GCC internal prototype to avoid an error. |
5170 | Use char because int might match the return type of a GCC | |
5171 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5172 | #ifdef __cplusplus |
5173 | extern "C" | |
5174 | #endif | |
f73dda09 JA |
5175 | char tgetent (); |
5176 | int | |
5177 | main () | |
5178 | { | |
b709b946 | 5179 | return tgetent (); |
f73dda09 JA |
5180 | ; |
5181 | return 0; | |
5182 | } | |
5183 | _ACEOF | |
1b1fe467 | 5184 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5185 | ac_cv_lib_ncurses_tgetent=yes |
5186 | else | |
1b1fe467 | 5187 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 5188 | fi |
1b1fe467 CR |
5189 | rm -f core conftest.err conftest.$ac_objext \ |
5190 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5191 | LIBS=$ac_check_lib_save_LIBS |
5192 | fi | |
1b1fe467 | 5193 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
dd4f3dd8 | 5194 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
1b1fe467 | 5195 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 5196 | bash_cv_termcap_lib=libncurses |
bb70624e | 5197 | else |
f73dda09 | 5198 | bash_cv_termcap_lib=gnutermcap |
bb70624e | 5199 | fi |
bb70624e | 5200 | |
bb70624e JA |
5201 | fi |
5202 | ||
5203 | fi | |
5204 | ||
5205 | fi | |
5206 | ||
5207 | fi | |
5208 | ||
d3a24ed2 CR |
5209 | fi |
5210 | ||
bb70624e | 5211 | if test "X$_bash_needmsg" = "Xyes"; then |
1b1fe467 | 5212 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 5213 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e | 5214 | fi |
1b1fe467 | 5215 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
dd4f3dd8 | 5216 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
bb70624e JA |
5217 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
5218 | LDFLAGS="$LDFLAGS -L./lib/termcap" | |
5219 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
5220 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
5221 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then | |
5222 | TERMCAP_LIB=-ltermcap | |
5223 | TERMCAP_DEP= | |
f73dda09 JA |
5224 | elif test $bash_cv_termcap_lib = libtinfo; then |
5225 | TERMCAP_LIB=-ltinfo | |
5226 | TERMCAP_DEP= | |
bb70624e JA |
5227 | elif test $bash_cv_termcap_lib = libncurses; then |
5228 | TERMCAP_LIB=-lncurses | |
5229 | TERMCAP_DEP= | |
d3a24ed2 CR |
5230 | elif test $bash_cv_termcap_lib = libc; then |
5231 | TERMCAP_LIB= | |
5232 | TERMCAP_DEP= | |
bb70624e JA |
5233 | else |
5234 | TERMCAP_LIB=-lcurses | |
5235 | TERMCAP_DEP= | |
5236 | fi | |
5237 | ||
a82a04b3 CR |
5238 | |
5239 | ||
5240 | ||
1b1fe467 | 5241 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of installed readline library" >&5 |
dd4f3dd8 | 5242 | $as_echo_n "checking version of installed readline library... " >&6; } |
f73dda09 JA |
5243 | |
5244 | # What a pain in the ass this is. | |
5245 | ||
5246 | # save cpp and ld options | |
5247 | _save_CFLAGS="$CFLAGS" | |
5248 | _save_LDFLAGS="$LDFLAGS" | |
5249 | _save_LIBS="$LIBS" | |
5250 | ||
5251 | # Don't set ac_cv_rl_prefix if the caller has already assigned a value. This | |
5252 | # allows the caller to do something like $_rl_prefix=$withval if the user | |
5253 | # specifies --with-installed-readline=PREFIX as an argument to configure | |
5254 | ||
5255 | if test -z "$ac_cv_rl_prefix"; then | |
5256 | test "x$prefix" = xNONE && ac_cv_rl_prefix=$ac_default_prefix || ac_cv_rl_prefix=${prefix} | |
5257 | fi | |
5258 | ||
5259 | eval ac_cv_rl_includedir=${ac_cv_rl_prefix}/include | |
5260 | eval ac_cv_rl_libdir=${ac_cv_rl_prefix}/lib | |
5261 | ||
5262 | LIBS="$LIBS -lreadline ${TERMCAP_LIB}" | |
5263 | CFLAGS="$CFLAGS -I${ac_cv_rl_includedir}" | |
5264 | LDFLAGS="$LDFLAGS -L${ac_cv_rl_libdir}" | |
5265 | ||
1b1fe467 | 5266 | if ${ac_cv_rl_version+:} false; then : |
dd4f3dd8 | 5267 | $as_echo_n "(cached) " >&6 |
d3a24ed2 | 5268 | else |
1b1fe467 | 5269 | if test "$cross_compiling" = yes; then : |
690150f9 | 5270 | ac_cv_rl_version='6.3' |
f73dda09 | 5271 | else |
1b1fe467 | 5272 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5273 | /* end confdefs.h. */ |
f73dda09 JA |
5274 | |
5275 | #include <stdio.h> | |
5276 | #include <readline/readline.h> | |
5277 | ||
798a67db CR |
5278 | extern int rl_gnu_readline_p; |
5279 | ||
f73dda09 JA |
5280 | main() |
5281 | { | |
5282 | FILE *fp; | |
5283 | fp = fopen("conftest.rlv", "w"); | |
798a67db CR |
5284 | if (fp == 0) |
5285 | exit(1); | |
5286 | if (rl_gnu_readline_p != 1) | |
5287 | fprintf(fp, "0.0\n"); | |
5288 | else | |
5289 | fprintf(fp, "%s\n", rl_library_version ? rl_library_version : "0.0"); | |
f73dda09 JA |
5290 | fclose(fp); |
5291 | exit(0); | |
5292 | } | |
5293 | ||
5294 | _ACEOF | |
1b1fe467 | 5295 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
5296 | ac_cv_rl_version=`cat conftest.rlv` |
5297 | else | |
1b1fe467 | 5298 | ac_cv_rl_version='0.0' |
f73dda09 | 5299 | fi |
1b1fe467 CR |
5300 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
5301 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 5302 | fi |
b709b946 | 5303 | |
d3a24ed2 | 5304 | fi |
f73dda09 | 5305 | |
a82a04b3 | 5306 | |
f73dda09 JA |
5307 | CFLAGS="$_save_CFLAGS" |
5308 | LDFLAGS="$_save_LDFLAGS" | |
5309 | LIBS="$_save_LIBS" | |
5310 | ||
5311 | RL_MAJOR=0 | |
5312 | RL_MINOR=0 | |
5313 | ||
5314 | # ( | |
5315 | case "$ac_cv_rl_version" in | |
5316 | 2*|3*|4*|5*|6*|7*|8*|9*) | |
5317 | RL_MAJOR=`echo $ac_cv_rl_version | sed 's:\..*$::'` | |
7117c2d2 | 5318 | RL_MINOR=`echo $ac_cv_rl_version | sed -e 's:^.*\.::' -e 's:[a-zA-Z]*$::'` |
f73dda09 JA |
5319 | ;; |
5320 | esac | |
5321 | ||
5322 | # ((( | |
5323 | case $RL_MAJOR in | |
5324 | [0-9][0-9]) _RL_MAJOR=$RL_MAJOR ;; | |
5325 | [0-9]) _RL_MAJOR=0$RL_MAJOR ;; | |
5326 | *) _RL_MAJOR=00 ;; | |
5327 | esac | |
5328 | ||
5329 | # ((( | |
5330 | case $RL_MINOR in | |
5331 | [0-9][0-9]) _RL_MINOR=$RL_MINOR ;; | |
5332 | [0-9]) _RL_MINOR=0$RL_MINOR ;; | |
5333 | *) _RL_MINOR=00 ;; | |
5334 | esac | |
5335 | ||
5336 | RL_VERSION="0x${_RL_MAJOR}${_RL_MINOR}" | |
5337 | ||
5338 | # Readline versions greater than 4.2 have these defines in readline.h | |
5339 | ||
5340 | if test $ac_cv_rl_version = '0.0' ; then | |
1b1fe467 | 5341 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not test version of installed readline library." >&5 |
dd4f3dd8 | 5342 | $as_echo "$as_me: WARNING: Could not test version of installed readline library." >&2;} |
f73dda09 JA |
5343 | elif test $RL_MAJOR -gt 4 || { test $RL_MAJOR = 4 && test $RL_MINOR -gt 2 ; } ; then |
5344 | # set these for use by the caller | |
5345 | RL_PREFIX=$ac_cv_rl_prefix | |
5346 | RL_LIBDIR=$ac_cv_rl_libdir | |
5347 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
1b1fe467 | 5348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
dd4f3dd8 | 5349 | $as_echo "$ac_cv_rl_version" >&6; } |
f73dda09 JA |
5350 | else |
5351 | ||
a82a04b3 CR |
5352 | |
5353 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5354 | #define RL_READLINE_VERSION $RL_VERSION |
a82a04b3 | 5355 | _ACEOF |
f73dda09 | 5356 | |
a82a04b3 CR |
5357 | |
5358 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5359 | #define RL_VERSION_MAJOR $RL_MAJOR |
a82a04b3 | 5360 | _ACEOF |
f73dda09 | 5361 | |
a82a04b3 CR |
5362 | |
5363 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5364 | #define RL_VERSION_MINOR $RL_MINOR |
a82a04b3 CR |
5365 | _ACEOF |
5366 | ||
5367 | ||
5368 | ||
5369 | ||
5370 | ||
545f34cf CR |
5371 | |
5372 | # set these for use by the caller | |
5373 | RL_PREFIX=$ac_cv_rl_prefix | |
5374 | RL_LIBDIR=$ac_cv_rl_libdir | |
5375 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
5376 | ||
1b1fe467 | 5377 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
dd4f3dd8 | 5378 | $as_echo "$ac_cv_rl_version" >&6; } |
bb70624e | 5379 | |
f73dda09 | 5380 | fi |
bb70624e | 5381 | |
a82a04b3 | 5382 | |
f73dda09 | 5383 | case "$ac_cv_rl_version" in |
d3a24ed2 | 5384 | 5*|6*|7*|8*|9*) ;; |
f73dda09 | 5385 | *) opt_with_installed_readline=no |
1b1fe467 | 5386 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: installed readline library is too old to be linked with bash" >&5 |
dd4f3dd8 | 5387 | $as_echo "$as_me: WARNING: installed readline library is too old to be linked with bash" >&2;} |
1b1fe467 | 5388 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using private bash version" >&5 |
dd4f3dd8 | 5389 | $as_echo "$as_me: WARNING: using private bash version" >&2;} |
bb70624e JA |
5390 | ;; |
5391 | esac | |
bb70624e JA |
5392 | fi |
5393 | ||
fd3925f1 | 5394 | TILDE_LIB=-ltilde |
bb70624e | 5395 | if test $opt_readline = yes; then |
1b1fe467 | 5396 | $as_echo "#define READLINE 1" >>confdefs.h |
bb70624e | 5397 | |
f73dda09 | 5398 | if test "$opt_with_installed_readline" != "no" ; then |
d3a24ed2 CR |
5399 | case "$opt_with_installed_readline" in |
5400 | yes) RL_INCLUDE= ;; | |
5401 | *) case "$RL_INCLUDEDIR" in | |
5402 | /usr/include) ;; | |
5403 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5404 | esac | |
5405 | ;; | |
f73dda09 | 5406 | esac |
bb70624e | 5407 | READLINE_DEP= |
233564d2 | 5408 | READLINE_LIB=-lreadline |
fd3925f1 CR |
5409 | # section for OS versions that don't allow unresolved symbols |
5410 | # to be compiled into dynamic libraries. | |
5411 | case "$host_os" in | |
5412 | cygwin*) TILDE_LIB= ;; | |
5413 | esac | |
bb70624e JA |
5414 | else |
5415 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5416 | READLINE_DEP='$(READLINE_LIBRARY)' | |
fd3925f1 | 5417 | # section for OS versions that ship an older/broken version of |
233564d2 CR |
5418 | # readline as a standard dynamic library and don't allow a |
5419 | # static version specified as -llibname to override the | |
5420 | # dynamic version | |
5421 | case "${host_os}" in | |
82a5df63 | 5422 | darwin[89]*|darwin10*) READLINE_LIB='${READLINE_LIBRARY}' ;; |
233564d2 CR |
5423 | *) READLINE_LIB=-lreadline ;; |
5424 | esac | |
bb70624e JA |
5425 | fi |
5426 | else | |
5427 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5428 | READLINE_LIB= READLINE_DEP= | |
5429 | fi | |
5430 | if test $opt_history = yes || test $opt_bang_history = yes; then | |
5431 | if test $opt_history = yes; then | |
1b1fe467 | 5432 | $as_echo "#define HISTORY 1" >>confdefs.h |
bb70624e JA |
5433 | |
5434 | fi | |
5435 | if test $opt_bang_history = yes; then | |
1b1fe467 | 5436 | $as_echo "#define BANG_HISTORY 1" >>confdefs.h |
b72432fd JA |
5437 | |
5438 | fi | |
f73dda09 JA |
5439 | if test "$opt_with_installed_readline" != "no"; then |
5440 | HIST_LIBDIR=$RL_LIBDIR | |
b72432fd | 5441 | HISTORY_DEP= |
233564d2 | 5442 | HISTORY_LIB=-lhistory |
d3a24ed2 CR |
5443 | case "$opt_with_installed_readline" in |
5444 | yes) RL_INCLUDE= ;; | |
5445 | *) case "$RL_INCLUDEDIR" in | |
5446 | /usr/include) ;; | |
5447 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5448 | esac | |
5449 | ;; | |
f73dda09 | 5450 | esac |
b72432fd JA |
5451 | else |
5452 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5453 | HISTORY_DEP='$(HISTORY_LIBRARY)' | |
233564d2 CR |
5454 | # section for OS versions that ship an older version of |
5455 | # readline as a standard dynamic library and don't allow a | |
5456 | # static version specified as -llibname to override the | |
5457 | # dynamic version | |
5458 | case "${host_os}" in | |
82a5df63 | 5459 | darwin[89]*|darwin10*) HISTORY_LIB='${HISTORY_LIBRARY}' ;; |
233564d2 CR |
5460 | *) HISTORY_LIB=-lhistory ;; |
5461 | esac | |
b72432fd JA |
5462 | fi |
5463 | else | |
5464 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5465 | HISTORY_LIB= HISTORY_DEP= | |
5466 | fi | |
5467 | ||
a82a04b3 CR |
5468 | |
5469 | ||
5470 | ||
5471 | ||
5472 | ||
5473 | ||
5474 | ||
5475 | ||
5476 | ||
fd3925f1 | 5477 | |
ccc6cda3 JA |
5478 | # Find a good install program. We prefer a C program (faster), |
5479 | # so one script is as good as another. But avoid the broken or | |
5480 | # incompatible versions: | |
5481 | # SysV /etc/install, /usr/sbin/install | |
5482 | # SunOS /usr/etc/install | |
5483 | # IRIX /sbin/install | |
5484 | # AIX /bin/install | |
f73dda09 | 5485 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
bb70624e | 5486 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
ccc6cda3 JA |
5487 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
5488 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
5e4a95c7 | 5489 | # OS/2's system install, which has a completely different semantic |
ccc6cda3 | 5490 | # ./install, which can be erroneously created by make from ./install.sh. |
dd4f3dd8 | 5491 | # Reject install programs that cannot install multiple files. |
1b1fe467 | 5492 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
dd4f3dd8 | 5493 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
ccc6cda3 | 5494 | if test -z "$INSTALL"; then |
1b1fe467 | 5495 | if ${ac_cv_path_install+:} false; then : |
dd4f3dd8 | 5496 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5497 | else |
a82a04b3 CR |
5498 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5499 | for as_dir in $PATH | |
5500 | do | |
5501 | IFS=$as_save_IFS | |
5502 | test -z "$as_dir" && as_dir=. | |
1b1fe467 CR |
5503 | # Account for people who put trailing slashes in PATH elements. |
5504 | case $as_dir/ in #(( | |
5505 | ./ | .// | /[cC]/* | \ | |
a82a04b3 | 5506 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
1b1fe467 | 5507 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
a82a04b3 CR |
5508 | /usr/ucb/* ) ;; |
5509 | *) | |
5510 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
5511 | # Don't use installbsd from OSF since it installs stuff as root | |
5512 | # by default. | |
5513 | for ac_prog in ginstall scoinst install; do | |
5514 | for ac_exec_ext in '' $ac_executable_extensions; do | |
0ee50808 | 5515 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then |
5e4a95c7 CR |
5516 | if test $ac_prog = install && |
5517 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5518 | # AIX install. It has an incompatible calling convention. | |
5519 | : | |
5520 | elif test $ac_prog = install && | |
5521 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5522 | # program-specific install script used by HP pwplus--don't use. | |
5523 | : | |
5524 | else | |
dd4f3dd8 CR |
5525 | rm -rf conftest.one conftest.two conftest.dir |
5526 | echo one > conftest.one | |
5527 | echo two > conftest.two | |
5528 | mkdir conftest.dir | |
5529 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
5530 | test -s conftest.one && test -s conftest.two && | |
5531 | test -s conftest.dir/conftest.one && | |
5532 | test -s conftest.dir/conftest.two | |
5533 | then | |
5534 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
5535 | break 3 | |
5536 | fi | |
5e4a95c7 CR |
5537 | fi |
5538 | fi | |
ccc6cda3 | 5539 | done |
a82a04b3 CR |
5540 | done |
5541 | ;; | |
5542 | esac | |
dd4f3dd8 | 5543 | |
1b1fe467 | 5544 | done |
b709b946 | 5545 | IFS=$as_save_IFS |
a82a04b3 | 5546 | |
dd4f3dd8 | 5547 | rm -rf conftest.one conftest.two conftest.dir |
ccc6cda3 JA |
5548 | |
5549 | fi | |
5550 | if test "${ac_cv_path_install+set}" = set; then | |
f73dda09 | 5551 | INSTALL=$ac_cv_path_install |
ccc6cda3 | 5552 | else |
b709b946 CR |
5553 | # As a last resort, use the slow shell script. Don't cache a |
5554 | # value for INSTALL within a source directory, because that will | |
ccc6cda3 | 5555 | # break other packages using the cache if that directory is |
b709b946 | 5556 | # removed, or if the value is a relative name. |
f73dda09 | 5557 | INSTALL=$ac_install_sh |
ccc6cda3 JA |
5558 | fi |
5559 | fi | |
1b1fe467 | 5560 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
dd4f3dd8 | 5561 | $as_echo "$INSTALL" >&6; } |
ccc6cda3 JA |
5562 | |
5563 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
5564 | # It thinks the first close brace ends the variable substitution. | |
5565 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
5566 | ||
f73dda09 | 5567 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
bb70624e | 5568 | |
ccc6cda3 JA |
5569 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
5570 | ||
208fdb50 CR |
5571 | if test -n "$ac_tool_prefix"; then |
5572 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
5573 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
1b1fe467 | 5574 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5575 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 5576 | if ${ac_cv_prog_AR+:} false; then : |
dd4f3dd8 | 5577 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5578 | else |
5579 | if test -n "$AR"; then | |
5580 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
5581 | else | |
a82a04b3 CR |
5582 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5583 | for as_dir in $PATH | |
5584 | do | |
5585 | IFS=$as_save_IFS | |
5586 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 5587 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 5588 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
208fdb50 | 5589 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
1b1fe467 | 5590 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5591 | break 2 |
5592 | fi | |
5593 | done | |
1b1fe467 | 5594 | done |
b709b946 | 5595 | IFS=$as_save_IFS |
f73dda09 | 5596 | |
ccc6cda3 JA |
5597 | fi |
5598 | fi | |
f73dda09 | 5599 | AR=$ac_cv_prog_AR |
ccc6cda3 | 5600 | if test -n "$AR"; then |
1b1fe467 | 5601 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
dd4f3dd8 | 5602 | $as_echo "$AR" >&6; } |
ccc6cda3 | 5603 | else |
1b1fe467 | 5604 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5605 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5606 | fi |
5607 | ||
b709b946 | 5608 | |
208fdb50 CR |
5609 | fi |
5610 | if test -z "$ac_cv_prog_AR"; then | |
5611 | ac_ct_AR=$AR | |
5612 | # Extract the first word of "ar", so it can be a program name with args. | |
5613 | set dummy ar; ac_word=$2 | |
5614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
5615 | $as_echo_n "checking for $ac_word... " >&6; } | |
5616 | if ${ac_cv_prog_ac_ct_AR+:} false; then : | |
5617 | $as_echo_n "(cached) " >&6 | |
5618 | else | |
5619 | if test -n "$ac_ct_AR"; then | |
5620 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
5621 | else | |
5622 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5623 | for as_dir in $PATH | |
5624 | do | |
5625 | IFS=$as_save_IFS | |
5626 | test -z "$as_dir" && as_dir=. | |
5627 | for ac_exec_ext in '' $ac_executable_extensions; do | |
0ee50808 | 5628 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
208fdb50 CR |
5629 | ac_cv_prog_ac_ct_AR="ar" |
5630 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
5631 | break 2 | |
5632 | fi | |
5633 | done | |
5634 | done | |
5635 | IFS=$as_save_IFS | |
5636 | ||
5637 | fi | |
5638 | fi | |
5639 | ac_ct_AR=$ac_cv_prog_ac_ct_AR | |
5640 | if test -n "$ac_ct_AR"; then | |
5641 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 | |
5642 | $as_echo "$ac_ct_AR" >&6; } | |
5643 | else | |
5644 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5645 | $as_echo "no" >&6; } | |
5646 | fi | |
5647 | ||
5648 | if test "x$ac_ct_AR" = x; then | |
5649 | AR="" | |
5650 | else | |
5651 | case $cross_compiling:$ac_tool_warned in | |
5652 | yes:) | |
5653 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
5654 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
5655 | ac_tool_warned=yes ;; | |
5656 | esac | |
5657 | AR=$ac_ct_AR | |
5658 | fi | |
5659 | else | |
5660 | AR="$ac_cv_prog_AR" | |
5661 | fi | |
5662 | ||
b72432fd | 5663 | test -n "$ARFLAGS" || ARFLAGS="cr" |
f73dda09 JA |
5664 | if test -n "$ac_tool_prefix"; then |
5665 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
5666 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
1b1fe467 | 5667 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5668 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 5669 | if ${ac_cv_prog_RANLIB+:} false; then : |
dd4f3dd8 | 5670 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5671 | else |
5672 | if test -n "$RANLIB"; then | |
5673 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
5674 | else | |
a82a04b3 CR |
5675 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5676 | for as_dir in $PATH | |
5677 | do | |
5678 | IFS=$as_save_IFS | |
5679 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 5680 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 5681 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 5682 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
1b1fe467 | 5683 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5684 | break 2 |
5685 | fi | |
5686 | done | |
1b1fe467 | 5687 | done |
b709b946 | 5688 | IFS=$as_save_IFS |
f73dda09 | 5689 | |
ccc6cda3 JA |
5690 | fi |
5691 | fi | |
f73dda09 | 5692 | RANLIB=$ac_cv_prog_RANLIB |
ccc6cda3 | 5693 | if test -n "$RANLIB"; then |
1b1fe467 | 5694 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
dd4f3dd8 | 5695 | $as_echo "$RANLIB" >&6; } |
f73dda09 | 5696 | else |
1b1fe467 | 5697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5698 | $as_echo "no" >&6; } |
f73dda09 JA |
5699 | fi |
5700 | ||
b709b946 | 5701 | |
f73dda09 JA |
5702 | fi |
5703 | if test -z "$ac_cv_prog_RANLIB"; then | |
5704 | ac_ct_RANLIB=$RANLIB | |
5705 | # Extract the first word of "ranlib", so it can be a program name with args. | |
5706 | set dummy ranlib; ac_word=$2 | |
1b1fe467 | 5707 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5708 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 5709 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
dd4f3dd8 | 5710 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5711 | else |
5712 | if test -n "$ac_ct_RANLIB"; then | |
5713 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
5714 | else | |
a82a04b3 CR |
5715 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5716 | for as_dir in $PATH | |
5717 | do | |
5718 | IFS=$as_save_IFS | |
5719 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 5720 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 5721 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 5722 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
1b1fe467 | 5723 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5724 | break 2 |
5725 | fi | |
5726 | done | |
1b1fe467 | 5727 | done |
b709b946 | 5728 | IFS=$as_save_IFS |
f73dda09 | 5729 | |
f73dda09 JA |
5730 | fi |
5731 | fi | |
5732 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
5733 | if test -n "$ac_ct_RANLIB"; then | |
1b1fe467 | 5734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
dd4f3dd8 | 5735 | $as_echo "$ac_ct_RANLIB" >&6; } |
ccc6cda3 | 5736 | else |
1b1fe467 | 5737 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5738 | $as_echo "no" >&6; } |
f73dda09 JA |
5739 | fi |
5740 | ||
b709b946 CR |
5741 | if test "x$ac_ct_RANLIB" = x; then |
5742 | RANLIB=":" | |
5743 | else | |
5744 | case $cross_compiling:$ac_tool_warned in | |
5745 | yes:) | |
1b1fe467 | 5746 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 5747 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
5748 | ac_tool_warned=yes ;; |
5749 | esac | |
5750 | RANLIB=$ac_ct_RANLIB | |
5751 | fi | |
f73dda09 JA |
5752 | else |
5753 | RANLIB="$ac_cv_prog_RANLIB" | |
ccc6cda3 JA |
5754 | fi |
5755 | ||
5756 | for ac_prog in 'bison -y' byacc | |
5757 | do | |
f73dda09 | 5758 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
ccc6cda3 | 5759 | set dummy $ac_prog; ac_word=$2 |
1b1fe467 | 5760 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5761 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 5762 | if ${ac_cv_prog_YACC+:} false; then : |
dd4f3dd8 | 5763 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5764 | else |
5765 | if test -n "$YACC"; then | |
5766 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | |
5767 | else | |
a82a04b3 CR |
5768 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5769 | for as_dir in $PATH | |
5770 | do | |
5771 | IFS=$as_save_IFS | |
5772 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 5773 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 5774 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 5775 | ac_cv_prog_YACC="$ac_prog" |
1b1fe467 | 5776 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5777 | break 2 |
5778 | fi | |
5779 | done | |
1b1fe467 | 5780 | done |
b709b946 | 5781 | IFS=$as_save_IFS |
f73dda09 | 5782 | |
ccc6cda3 JA |
5783 | fi |
5784 | fi | |
f73dda09 | 5785 | YACC=$ac_cv_prog_YACC |
ccc6cda3 | 5786 | if test -n "$YACC"; then |
1b1fe467 | 5787 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 |
dd4f3dd8 | 5788 | $as_echo "$YACC" >&6; } |
ccc6cda3 | 5789 | else |
1b1fe467 | 5790 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5791 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5792 | fi |
5793 | ||
b709b946 | 5794 | |
f73dda09 | 5795 | test -n "$YACC" && break |
ccc6cda3 JA |
5796 | done |
5797 | test -n "$YACC" || YACC="yacc" | |
5798 | ||
1b1fe467 | 5799 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 |
dd4f3dd8 CR |
5800 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } |
5801 | set x ${MAKE-make} | |
5802 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
1b1fe467 | 5803 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : |
dd4f3dd8 | 5804 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5805 | else |
a82a04b3 | 5806 | cat >conftest.make <<\_ACEOF |
b709b946 | 5807 | SHELL = /bin/sh |
ccc6cda3 | 5808 | all: |
b709b946 | 5809 | @echo '@@@%%%=$(MAKE)=@@@%%%' |
a82a04b3 | 5810 | _ACEOF |
1b1fe467 | 5811 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. |
b709b946 CR |
5812 | case `${MAKE-make} -f conftest.make 2>/dev/null` in |
5813 | *@@@%%%=?*=@@@%%%*) | |
5814 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
5815 | *) | |
5816 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
5817 | esac | |
f73dda09 | 5818 | rm -f conftest.make |
ccc6cda3 | 5819 | fi |
b709b946 | 5820 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then |
1b1fe467 | 5821 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
dd4f3dd8 | 5822 | $as_echo "yes" >&6; } |
ccc6cda3 JA |
5823 | SET_MAKE= |
5824 | else | |
1b1fe467 | 5825 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5826 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5827 | SET_MAKE="MAKE=${MAKE-make}" |
5828 | fi | |
5829 | ||
a82a04b3 | 5830 | |
41d203e2 CR |
5831 | case "$ac_cv_prog_YACC" in |
5832 | *bison*) ;; | |
5833 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: bison not available; needed to process parse.y" >&5 | |
5834 | $as_echo "$as_me: WARNING: bison not available; needed to process parse.y" >&2;} ;; | |
5835 | esac | |
5836 | ||
b72432fd | 5837 | case "$host_os" in |
bb70624e | 5838 | opennt*|interix*) MAKE_SHELL="$INTERIX_ROOT/bin/sh" ;; |
b72432fd JA |
5839 | *) MAKE_SHELL=/bin/sh ;; |
5840 | esac | |
5841 | ||
a82a04b3 | 5842 | |
10590446 CR |
5843 | if test x$SIZE = x; then |
5844 | if test x$ac_tool_prefix = x; then | |
5845 | SIZE=size | |
5846 | else | |
5847 | SIZE=${ac_tool_prefix}size | |
5848 | save_IFS=$IFS ; IFS=: | |
5849 | size_found=0 | |
5850 | for dir in $PATH; do | |
5851 | if test -x $dir/$SIZE ; then | |
5852 | size_found=1 | |
5853 | break | |
5854 | fi | |
5855 | done | |
5856 | if test $size_found -eq 0; then | |
233564d2 | 5857 | SIZE=: |
10590446 CR |
5858 | fi |
5859 | IFS=$save_IFS | |
5860 | fi | |
5861 | fi | |
5862 | ||
e624d0f7 | 5863 | |
278286c9 CR |
5864 | # Checks for stat-related time functions. |
5865 | ||
5866 | # Copyright (C) 1998-1999, 2001, 2003, 2005-2007, 2009-2012 Free Software | |
5867 | # Foundation, Inc. | |
5868 | ||
5869 | # This file is free software; the Free Software Foundation | |
5870 | # gives unlimited permission to copy and/or distribute it, | |
5871 | # with or without modifications, as long as this notice is preserved. | |
5872 | ||
5873 | ||
5874 | # st_atim.tv_nsec - Linux, Solaris, Cygwin | |
5875 | # st_atimespec.tv_nsec - FreeBSD, NetBSD, if ! defined _POSIX_SOURCE | |
5876 | # st_atimensec - FreeBSD, NetBSD, if defined _POSIX_SOURCE | |
5877 | # st_atim.st__tim.tv_nsec - UnixWare (at least 2.1.2 through 7.1) | |
5878 | ||
5879 | # st_birthtimespec - FreeBSD, NetBSD (hidden on OpenBSD 3.9, anyway) | |
5880 | # st_birthtim - Cygwin 1.7.0+ | |
5881 | ||
5882 | ||
5883 | ||
5884 | # Configure checks for struct timespec | |
5885 | ||
5886 | # Copyright (C) 2000-2001, 2003-2007, 2009-2011, 2012 Free Software Foundation, Inc. | |
5887 | ||
5888 | # This file is free software; the Free Software Foundation | |
5889 | # gives unlimited permission to copy and/or distribute it, | |
5890 | # with or without modifications, as long as this notice is preserved. | |
5891 | ||
5892 | # Original written by Paul Eggert and Jim Meyering. | |
5893 | # Modified by Chet Ramey for bash | |
5894 | ||
5895 | ||
5896 | ||
5897 | ||
5898 | ||
1b1fe467 | 5899 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
ccc6cda3 | 5900 | |
e624d0f7 | 5901 | |
1b1fe467 | 5902 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
dd4f3dd8 | 5903 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
1b1fe467 | 5904 | if ${ac_cv_c_const+:} false; then : |
dd4f3dd8 | 5905 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5906 | else |
1b1fe467 | 5907 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
5908 | /* end confdefs.h. */ |
5909 | ||
5910 | int | |
5911 | main () | |
5c26afb8 | 5912 | { |
0ee50808 | 5913 | |
5c26afb8 | 5914 | #ifndef __cplusplus |
0ee50808 | 5915 | /* Ultrix mips cc rejects this sort of thing. */ |
5c26afb8 | 5916 | typedef int charset[2]; |
0ee50808 | 5917 | const charset cs = { 0, 0 }; |
5c26afb8 | 5918 | /* SunOS 4.1.1 cc rejects this. */ |
dd4f3dd8 CR |
5919 | char const *const *pcpcc; |
5920 | char **ppc; | |
5c26afb8 CR |
5921 | /* NEC SVR4.0.2 mips cc rejects this. */ |
5922 | struct point {int x, y;}; | |
5923 | static struct point const zero = {0,0}; | |
5924 | /* AIX XL C 1.02.0.0 rejects this. | |
5925 | It does not let you subtract one const X* pointer from another in | |
5926 | an arm of an if-expression whose if-part is not a constant | |
5927 | expression */ | |
f73dda09 | 5928 | const char *g = "string"; |
dd4f3dd8 | 5929 | pcpcc = &g + (g ? g-g : 0); |
f73dda09 | 5930 | /* HPUX 7.0 cc rejects these. */ |
dd4f3dd8 CR |
5931 | ++pcpcc; |
5932 | ppc = (char**) pcpcc; | |
5933 | pcpcc = (char const *const *) ppc; | |
0ee50808 CR |
5934 | { /* SCO 3.2v4 cc rejects this sort of thing. */ |
5935 | char tx; | |
5936 | char *t = &tx; | |
f73dda09 JA |
5937 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
5938 | ||
5939 | *t++ = 0; | |
b709b946 | 5940 | if (s) return 0; |
f73dda09 JA |
5941 | } |
5942 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
5943 | int x[] = {25, 17}; | |
5944 | const int *foo = &x[0]; | |
5945 | ++foo; | |
5946 | } | |
5947 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
5948 | typedef const int *iptr; | |
5949 | iptr p = 0; | |
5950 | ++p; | |
5951 | } | |
0ee50808 | 5952 | { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying |
f73dda09 | 5953 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
0ee50808 CR |
5954 | struct s { int j; const int *ap[3]; } bx; |
5955 | struct s *b = &bx; b->j = 5; | |
f73dda09 JA |
5956 | } |
5957 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
5958 | const int foo = 10; | |
b709b946 | 5959 | if (!foo) return 0; |
f73dda09 | 5960 | } |
dd4f3dd8 | 5961 | return !cs[0] && !zero.x; |
ccc6cda3 JA |
5962 | #endif |
5963 | ||
f73dda09 JA |
5964 | ; |
5965 | return 0; | |
5966 | } | |
5967 | _ACEOF | |
1b1fe467 | 5968 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
5969 | ac_cv_c_const=yes |
5970 | else | |
1b1fe467 | 5971 | ac_cv_c_const=no |
f73dda09 | 5972 | fi |
b709b946 | 5973 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 5974 | fi |
1b1fe467 | 5975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
dd4f3dd8 | 5976 | $as_echo "$ac_cv_c_const" >&6; } |
f73dda09 JA |
5977 | if test $ac_cv_c_const = no; then |
5978 | ||
1b1fe467 | 5979 | $as_echo "#define const /**/" >>confdefs.h |
ccc6cda3 JA |
5980 | |
5981 | fi | |
5982 | ||
1b1fe467 | 5983 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
dd4f3dd8 | 5984 | $as_echo_n "checking for inline... " >&6; } |
1b1fe467 | 5985 | if ${ac_cv_c_inline+:} false; then : |
dd4f3dd8 | 5986 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5987 | else |
f73dda09 JA |
5988 | ac_cv_c_inline=no |
5989 | for ac_kw in inline __inline__ __inline; do | |
1b1fe467 | 5990 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5991 | /* end confdefs.h. */ |
f73dda09 | 5992 | #ifndef __cplusplus |
5e4a95c7 CR |
5993 | typedef int foo_t; |
5994 | static $ac_kw foo_t static_foo () {return 0; } | |
5995 | $ac_kw foo_t foo () {return 0; } | |
ccc6cda3 JA |
5996 | #endif |
5997 | ||
f73dda09 | 5998 | _ACEOF |
1b1fe467 | 5999 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 6000 | ac_cv_c_inline=$ac_kw |
f73dda09 | 6001 | fi |
b709b946 CR |
6002 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6003 | test "$ac_cv_c_inline" != no && break | |
f73dda09 | 6004 | done |
ccc6cda3 JA |
6005 | |
6006 | fi | |
1b1fe467 | 6007 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
dd4f3dd8 | 6008 | $as_echo "$ac_cv_c_inline" >&6; } |
5e4a95c7 | 6009 | |
f73dda09 JA |
6010 | case $ac_cv_c_inline in |
6011 | inline | yes) ;; | |
5e4a95c7 CR |
6012 | *) |
6013 | case $ac_cv_c_inline in | |
6014 | no) ac_val=;; | |
6015 | *) ac_val=$ac_cv_c_inline;; | |
6016 | esac | |
6017 | cat >>confdefs.h <<_ACEOF | |
6018 | #ifndef __cplusplus | |
6019 | #define inline $ac_val | |
6020 | #endif | |
5c26afb8 | 6021 | _ACEOF |
5e4a95c7 | 6022 | ;; |
f73dda09 | 6023 | esac |
ccc6cda3 | 6024 | |
1b1fe467 | 6025 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
dd4f3dd8 | 6026 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
1b1fe467 | 6027 | if ${ac_cv_c_bigendian+:} false; then : |
dd4f3dd8 | 6028 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6029 | else |
dd4f3dd8 | 6030 | ac_cv_c_bigendian=unknown |
af98a2a6 | 6031 | # See if we're dealing with a universal compiler. |
1b1fe467 | 6032 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6033 | /* end confdefs.h. */ |
af98a2a6 CR |
6034 | #ifndef __APPLE_CC__ |
6035 | not a universal capable compiler | |
dd4f3dd8 CR |
6036 | #endif |
6037 | typedef int dummy; | |
ccc6cda3 | 6038 | |
f73dda09 | 6039 | _ACEOF |
1b1fe467 | 6040 | if ac_fn_c_try_compile "$LINENO"; then : |
af98a2a6 CR |
6041 | |
6042 | # Check for potential -arch flags. It is not universal unless | |
1b1fe467 CR |
6043 | # there are at least two -arch flags with different values. |
6044 | ac_arch= | |
6045 | ac_prev= | |
6046 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
6047 | if test -n "$ac_prev"; then | |
6048 | case $ac_word in | |
6049 | i?86 | x86_64 | ppc | ppc64) | |
6050 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
6051 | ac_arch=$ac_word | |
6052 | else | |
6053 | ac_cv_c_bigendian=universal | |
6054 | break | |
6055 | fi | |
6056 | ;; | |
6057 | esac | |
6058 | ac_prev= | |
6059 | elif test "x$ac_word" = "x-arch"; then | |
6060 | ac_prev=arch | |
6061 | fi | |
6062 | done | |
dd4f3dd8 | 6063 | fi |
dd4f3dd8 CR |
6064 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6065 | if test $ac_cv_c_bigendian = unknown; then | |
6066 | # See if sys/param.h defines the BYTE_ORDER macro. | |
1b1fe467 | 6067 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
6068 | /* end confdefs.h. */ |
6069 | #include <sys/types.h> | |
6070 | #include <sys/param.h> | |
6071 | ||
6072 | int | |
6073 | main () | |
6074 | { | |
6075 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ | |
6076 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
6077 | && LITTLE_ENDIAN) | |
6078 | bogus endian macros | |
6079 | #endif | |
6080 | ||
6081 | ; | |
6082 | return 0; | |
6083 | } | |
6084 | _ACEOF | |
1b1fe467 | 6085 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6086 | # It does; now see whether it defined to BIG_ENDIAN or not. |
1b1fe467 | 6087 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6088 | /* end confdefs.h. */ |
f73dda09 | 6089 | #include <sys/types.h> |
dd4f3dd8 | 6090 | #include <sys/param.h> |
ccc6cda3 | 6091 | |
f73dda09 JA |
6092 | int |
6093 | main () | |
6094 | { | |
6095 | #if BYTE_ORDER != BIG_ENDIAN | |
dd4f3dd8 CR |
6096 | not big endian |
6097 | #endif | |
ccc6cda3 | 6098 | |
f73dda09 JA |
6099 | ; |
6100 | return 0; | |
6101 | } | |
6102 | _ACEOF | |
1b1fe467 | 6103 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6104 | ac_cv_c_bigendian=yes |
ccc6cda3 | 6105 | else |
1b1fe467 | 6106 | ac_cv_c_bigendian=no |
ccc6cda3 | 6107 | fi |
b709b946 | 6108 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 6109 | fi |
dd4f3dd8 CR |
6110 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6111 | fi | |
6112 | if test $ac_cv_c_bigendian = unknown; then | |
6113 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
1b1fe467 | 6114 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6115 | /* end confdefs.h. */ |
dd4f3dd8 CR |
6116 | #include <limits.h> |
6117 | ||
a82a04b3 CR |
6118 | int |
6119 | main () | |
6120 | { | |
dd4f3dd8 CR |
6121 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
6122 | bogus endian macros | |
6123 | #endif | |
6124 | ||
a82a04b3 CR |
6125 | ; |
6126 | return 0; | |
6127 | } | |
6128 | _ACEOF | |
1b1fe467 | 6129 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 6130 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
1b1fe467 | 6131 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
6132 | /* end confdefs.h. */ |
6133 | #include <limits.h> | |
6134 | ||
6135 | int | |
6136 | main () | |
6137 | { | |
6138 | #ifndef _BIG_ENDIAN | |
6139 | not big endian | |
6140 | #endif | |
6141 | ||
6142 | ; | |
6143 | return 0; | |
6144 | } | |
6145 | _ACEOF | |
1b1fe467 | 6146 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 CR |
6147 | ac_cv_c_bigendian=yes |
6148 | else | |
1b1fe467 | 6149 | ac_cv_c_bigendian=no |
dd4f3dd8 | 6150 | fi |
dd4f3dd8 | 6151 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 6152 | fi |
dd4f3dd8 CR |
6153 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6154 | fi | |
6155 | if test $ac_cv_c_bigendian = unknown; then | |
6156 | # Compile a test program. | |
1b1fe467 | 6157 | if test "$cross_compiling" = yes; then : |
dd4f3dd8 | 6158 | # Try to guess by grepping values from an object file. |
1b1fe467 | 6159 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
6160 | /* end confdefs.h. */ |
6161 | short int ascii_mm[] = | |
6162 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
6163 | short int ascii_ii[] = | |
6164 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
6165 | int use_ascii (int i) { | |
6166 | return ascii_mm[i] + ascii_ii[i]; | |
6167 | } | |
6168 | short int ebcdic_ii[] = | |
6169 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
6170 | short int ebcdic_mm[] = | |
6171 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
6172 | int use_ebcdic (int i) { | |
6173 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
6174 | } | |
6175 | extern int foo; | |
6176 | ||
6177 | int | |
6178 | main () | |
6179 | { | |
6180 | return use_ascii (foo) == use_ebcdic (foo); | |
6181 | ; | |
6182 | return 0; | |
6183 | } | |
6184 | _ACEOF | |
1b1fe467 | 6185 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 CR |
6186 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
6187 | ac_cv_c_bigendian=yes | |
6188 | fi | |
6189 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
6190 | if test "$ac_cv_c_bigendian" = unknown; then | |
6191 | ac_cv_c_bigendian=no | |
6192 | else | |
6193 | # finding both strings is unlikely to happen, but who knows? | |
6194 | ac_cv_c_bigendian=unknown | |
6195 | fi | |
6196 | fi | |
1b1fe467 CR |
6197 | fi |
6198 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7175a77f | 6199 | else |
1b1fe467 | 6200 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7610e0c5 | 6201 | /* end confdefs.h. */ |
b709b946 | 6202 | $ac_includes_default |
f73dda09 JA |
6203 | int |
6204 | main () | |
ccc6cda3 | 6205 | { |
b709b946 | 6206 | |
dd4f3dd8 CR |
6207 | /* Are we little or big endian? From Harbison&Steele. */ |
6208 | union | |
6209 | { | |
6210 | long int l; | |
6211 | char c[sizeof (long int)]; | |
6212 | } u; | |
6213 | u.l = 1; | |
6214 | return u.c[sizeof (long int) - 1] == 1; | |
b709b946 CR |
6215 | |
6216 | ; | |
6217 | return 0; | |
ccc6cda3 | 6218 | } |
f73dda09 | 6219 | _ACEOF |
1b1fe467 | 6220 | if ac_fn_c_try_run "$LINENO"; then : |
abe2eb5b CR |
6221 | ac_cv_c_bigendian=no |
6222 | else | |
1b1fe467 | 6223 | ac_cv_c_bigendian=yes |
abe2eb5b | 6224 | fi |
1b1fe467 CR |
6225 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6226 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
abe2eb5b CR |
6227 | fi |
6228 | ||
abe2eb5b CR |
6229 | fi |
6230 | fi | |
1b1fe467 | 6231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
abe2eb5b CR |
6232 | $as_echo "$ac_cv_c_bigendian" >&6; } |
6233 | case $ac_cv_c_bigendian in #( | |
dd4f3dd8 | 6234 | yes) |
1b1fe467 | 6235 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
dd4f3dd8 CR |
6236 | ;; #( |
6237 | no) | |
6238 | ;; #( | |
6239 | universal) | |
af98a2a6 | 6240 | |
1b1fe467 | 6241 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
af98a2a6 CR |
6242 | |
6243 | ;; #( | |
dd4f3dd8 | 6244 | *) |
1b1fe467 CR |
6245 | as_fn_error $? "unknown endianness |
6246 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; | |
dd4f3dd8 | 6247 | esac |
ccc6cda3 | 6248 | |
1b1fe467 | 6249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for preprocessor stringizing operator" >&5 |
dd4f3dd8 | 6250 | $as_echo_n "checking for preprocessor stringizing operator... " >&6; } |
1b1fe467 | 6251 | if ${ac_cv_c_stringize+:} false; then : |
dd4f3dd8 | 6252 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6253 | else |
1b1fe467 | 6254 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6255 | /* end confdefs.h. */ |
f73dda09 | 6256 | #define x(y) #y |
ccc6cda3 | 6257 | |
f73dda09 JA |
6258 | char *s = x(teststring); |
6259 | _ACEOF | |
6260 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 6261 | $EGREP "#teststring" >/dev/null 2>&1; then : |
f73dda09 | 6262 | ac_cv_c_stringize=no |
ccc6cda3 | 6263 | else |
f73dda09 | 6264 | ac_cv_c_stringize=yes |
ccc6cda3 | 6265 | fi |
f73dda09 | 6266 | rm -f conftest* |
ccc6cda3 JA |
6267 | |
6268 | fi | |
1b1fe467 | 6269 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stringize" >&5 |
dd4f3dd8 | 6270 | $as_echo "$ac_cv_c_stringize" >&6; } |
f73dda09 | 6271 | if test $ac_cv_c_stringize = yes; then |
ccc6cda3 | 6272 | |
1b1fe467 | 6273 | $as_echo "#define HAVE_STRINGIZE 1" >>confdefs.h |
ccc6cda3 JA |
6274 | |
6275 | fi | |
6276 | ||
b709b946 CR |
6277 | |
6278 | ||
1b1fe467 | 6279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double with more range or precision than double" >&5 |
dd4f3dd8 | 6280 | $as_echo_n "checking for long double with more range or precision than double... " >&6; } |
1b1fe467 | 6281 | if ${ac_cv_type_long_double_wider+:} false; then : |
dd4f3dd8 | 6282 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6283 | else |
1b1fe467 | 6284 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6285 | /* end confdefs.h. */ |
a82a04b3 | 6286 | #include <float.h> |
b709b946 CR |
6287 | long double const a[] = |
6288 | { | |
6289 | 0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON, | |
6290 | LDBL_MIN, LDBL_MAX, LDBL_EPSILON | |
6291 | }; | |
6292 | long double | |
6293 | f (long double x) | |
6294 | { | |
6295 | return ((x + (unsigned long int) 10) * (-1 / x) + a[0] | |
6296 | + (x ? f (x) : 'c')); | |
6297 | } | |
6298 | ||
f73dda09 JA |
6299 | int |
6300 | main () | |
6301 | { | |
b709b946 CR |
6302 | static int test_array [1 - 2 * !((0 < ((DBL_MAX_EXP < LDBL_MAX_EXP) |
6303 | + (DBL_MANT_DIG < LDBL_MANT_DIG) | |
6304 | - (LDBL_MAX_EXP < DBL_MAX_EXP) | |
6305 | - (LDBL_MANT_DIG < DBL_MANT_DIG))) | |
6306 | && (int) LDBL_EPSILON == 0 | |
6307 | )]; | |
0ee50808 CR |
6308 | test_array [0] = 0; |
6309 | return test_array [0]; | |
a82a04b3 CR |
6310 | |
6311 | ; | |
6312 | return 0; | |
ccc6cda3 | 6313 | } |
f73dda09 | 6314 | _ACEOF |
1b1fe467 | 6315 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 6316 | ac_cv_type_long_double_wider=yes |
ccc6cda3 | 6317 | else |
1b1fe467 | 6318 | ac_cv_type_long_double_wider=no |
f73dda09 | 6319 | fi |
b709b946 | 6320 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e624d0f7 | 6321 | fi |
1b1fe467 | 6322 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double_wider" >&5 |
dd4f3dd8 | 6323 | $as_echo "$ac_cv_type_long_double_wider" >&6; } |
b709b946 CR |
6324 | if test $ac_cv_type_long_double_wider = yes; then |
6325 | ||
1b1fe467 | 6326 | $as_echo "#define HAVE_LONG_DOUBLE_WIDER 1" >>confdefs.h |
b709b946 CR |
6327 | |
6328 | fi | |
6329 | ||
6330 | ac_cv_c_long_double=$ac_cv_type_long_double_wider | |
6331 | if test $ac_cv_c_long_double = yes; then | |
ccc6cda3 | 6332 | |
1b1fe467 | 6333 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
ccc6cda3 | 6334 | |
b709b946 | 6335 | fi |
ccc6cda3 | 6336 | |
1b1fe467 | 6337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 |
dd4f3dd8 | 6338 | $as_echo_n "checking for function prototypes... " >&6; } |
b709b946 | 6339 | if test "$ac_cv_prog_cc_c89" != no; then |
1b1fe467 | 6340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
dd4f3dd8 | 6341 | $as_echo "yes" >&6; } |
ccc6cda3 | 6342 | |
1b1fe467 | 6343 | $as_echo "#define PROTOTYPES 1" >>confdefs.h |
ccc6cda3 | 6344 | |
545f34cf | 6345 | |
1b1fe467 | 6346 | $as_echo "#define __PROTOTYPES 1" >>confdefs.h |
e624d0f7 | 6347 | |
e624d0f7 | 6348 | else |
1b1fe467 | 6349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6350 | $as_echo "no" >&6; } |
e624d0f7 | 6351 | fi |
e624d0f7 | 6352 | |
1b1fe467 | 6353 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
dd4f3dd8 | 6354 | $as_echo_n "checking whether char is unsigned... " >&6; } |
1b1fe467 | 6355 | if ${ac_cv_c_char_unsigned+:} false; then : |
dd4f3dd8 | 6356 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6357 | else |
1b1fe467 | 6358 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6359 | /* end confdefs.h. */ |
545f34cf CR |
6360 | $ac_includes_default |
6361 | int | |
6362 | main () | |
6363 | { | |
a82a04b3 | 6364 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
0ee50808 CR |
6365 | test_array [0] = 0; |
6366 | return test_array [0]; | |
a82a04b3 | 6367 | |
545f34cf CR |
6368 | ; |
6369 | return 0; | |
6370 | } | |
f73dda09 | 6371 | _ACEOF |
1b1fe467 | 6372 | if ac_fn_c_try_compile "$LINENO"; then : |
545f34cf | 6373 | ac_cv_c_char_unsigned=no |
f73dda09 | 6374 | else |
1b1fe467 | 6375 | ac_cv_c_char_unsigned=yes |
5e13499c | 6376 | fi |
b709b946 | 6377 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c | 6378 | fi |
1b1fe467 | 6379 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
dd4f3dd8 | 6380 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
5e13499c | 6381 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
1b1fe467 | 6382 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
5e13499c | 6383 | |
a927e029 CR |
6384 | fi |
6385 | ||
1b1fe467 | 6386 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
a927e029 | 6387 | $as_echo_n "checking for working volatile... " >&6; } |
1b1fe467 | 6388 | if ${ac_cv_c_volatile+:} false; then : |
a927e029 CR |
6389 | $as_echo_n "(cached) " >&6 |
6390 | else | |
1b1fe467 | 6391 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
a927e029 CR |
6392 | /* end confdefs.h. */ |
6393 | ||
6394 | int | |
6395 | main () | |
6396 | { | |
6397 | ||
6398 | volatile int x; | |
6399 | int * volatile y = (int *) 0; | |
6400 | return !x && !y; | |
6401 | ; | |
6402 | return 0; | |
6403 | } | |
6404 | _ACEOF | |
1b1fe467 | 6405 | if ac_fn_c_try_compile "$LINENO"; then : |
a927e029 CR |
6406 | ac_cv_c_volatile=yes |
6407 | else | |
1b1fe467 | 6408 | ac_cv_c_volatile=no |
a927e029 | 6409 | fi |
a927e029 CR |
6410 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6411 | fi | |
1b1fe467 | 6412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 |
a927e029 CR |
6413 | $as_echo "$ac_cv_c_volatile" >&6; } |
6414 | if test $ac_cv_c_volatile = no; then | |
6415 | ||
1b1fe467 | 6416 | $as_echo "#define volatile /**/" >>confdefs.h |
a927e029 | 6417 | |
5e13499c CR |
6418 | fi |
6419 | ||
1b1fe467 | 6420 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5 |
c1d39fb8 | 6421 | $as_echo_n "checking for C/C++ restrict keyword... " >&6; } |
1b1fe467 | 6422 | if ${ac_cv_c_restrict+:} false; then : |
c1d39fb8 CR |
6423 | $as_echo_n "(cached) " >&6 |
6424 | else | |
6425 | ac_cv_c_restrict=no | |
6426 | # The order here caters to the fact that C++ does not require restrict. | |
6427 | for ac_kw in __restrict __restrict__ _Restrict restrict; do | |
1b1fe467 | 6428 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
c1d39fb8 CR |
6429 | /* end confdefs.h. */ |
6430 | typedef int * int_ptr; | |
6431 | int foo (int_ptr $ac_kw ip) { | |
6432 | return ip[0]; | |
6433 | } | |
6434 | int | |
6435 | main () | |
6436 | { | |
6437 | int s[1]; | |
6438 | int * $ac_kw t = s; | |
6439 | t[0] = 0; | |
6440 | return foo(t) | |
6441 | ; | |
6442 | return 0; | |
6443 | } | |
6444 | _ACEOF | |
1b1fe467 | 6445 | if ac_fn_c_try_compile "$LINENO"; then : |
c1d39fb8 | 6446 | ac_cv_c_restrict=$ac_kw |
c1d39fb8 | 6447 | fi |
c1d39fb8 CR |
6448 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6449 | test "$ac_cv_c_restrict" != no && break | |
6450 | done | |
6451 | ||
6452 | fi | |
1b1fe467 | 6453 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5 |
c1d39fb8 CR |
6454 | $as_echo "$ac_cv_c_restrict" >&6; } |
6455 | ||
c1d39fb8 CR |
6456 | case $ac_cv_c_restrict in |
6457 | restrict) ;; | |
1b1fe467 | 6458 | no) $as_echo "#define restrict /**/" >>confdefs.h |
c1d39fb8 CR |
6459 | ;; |
6460 | *) cat >>confdefs.h <<_ACEOF | |
6461 | #define restrict $ac_cv_c_restrict | |
6462 | _ACEOF | |
6463 | ;; | |
6464 | esac | |
6465 | ||
a82a04b3 CR |
6466 | |
6467 | ||
5e13499c CR |
6468 | MKINSTALLDIRS= |
6469 | if test -n "$ac_aux_dir"; then | |
6470 | case "$ac_aux_dir" in | |
6471 | /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; | |
6472 | *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; | |
6473 | esac | |
6474 | fi | |
6475 | if test -z "$MKINSTALLDIRS"; then | |
6476 | MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" | |
6477 | fi | |
6478 | ||
a82a04b3 CR |
6479 | |
6480 | ||
1b1fe467 | 6481 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
dd4f3dd8 | 6482 | $as_echo_n "checking whether NLS is requested... " >&6; } |
b709b946 | 6483 | # Check whether --enable-nls was given. |
1b1fe467 | 6484 | if test "${enable_nls+set}" = set; then : |
b709b946 | 6485 | enableval=$enable_nls; USE_NLS=$enableval |
5e13499c CR |
6486 | else |
6487 | USE_NLS=yes | |
b709b946 CR |
6488 | fi |
6489 | ||
1b1fe467 | 6490 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
dd4f3dd8 | 6491 | $as_echo "$USE_NLS" >&6; } |
5e13499c | 6492 | |
a82a04b3 CR |
6493 | |
6494 | ||
6495 | ||
6496 | ||
6497 | ||
5e13499c CR |
6498 | # Prepare PATH_SEPARATOR. |
6499 | # The user is always right. | |
6500 | if test "${PATH_SEPARATOR+set}" != set; then | |
6501 | echo "#! /bin/sh" >conf$$.sh | |
6502 | echo "exit 0" >>conf$$.sh | |
6503 | chmod +x conf$$.sh | |
6504 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6505 | PATH_SEPARATOR=';' | |
6506 | else | |
6507 | PATH_SEPARATOR=: | |
6508 | fi | |
6509 | rm -f conf$$.sh | |
6510 | fi | |
6511 | ||
6512 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6513 | # as systems may use methods other than mode bits to determine executability. | |
6514 | cat >conf$$.file <<_ASEOF | |
6515 | #! /bin/sh | |
6516 | exit 0 | |
6517 | _ASEOF | |
6518 | chmod +x conf$$.file | |
6519 | if test -x conf$$.file >/dev/null 2>&1; then | |
6520 | ac_executable_p="test -x" | |
6521 | else | |
6522 | ac_executable_p="test -f" | |
6523 | fi | |
6524 | rm -f conf$$.file | |
6525 | ||
6526 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
6527 | set dummy msgfmt; ac_word=$2 | |
1b1fe467 | 6528 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6529 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 6530 | if ${ac_cv_path_MSGFMT+:} false; then : |
dd4f3dd8 | 6531 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6532 | else |
6533 | case "$MSGFMT" in | |
6534 | [\\/]* | ?:[\\/]*) | |
6535 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
6536 | ;; | |
6537 | *) | |
6538 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6539 | for ac_dir in $PATH; do | |
6540 | IFS="$ac_save_IFS" | |
6541 | test -z "$ac_dir" && ac_dir=. | |
6542 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6543 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6544 | if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && | |
6545 | (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6546 | ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" | |
6547 | break 2 | |
6548 | fi | |
6549 | fi | |
6550 | done | |
6551 | done | |
6552 | IFS="$ac_save_IFS" | |
6553 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" | |
6554 | ;; | |
6555 | esac | |
6556 | fi | |
6557 | MSGFMT="$ac_cv_path_MSGFMT" | |
6558 | if test "$MSGFMT" != ":"; then | |
1b1fe467 | 6559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 |
dd4f3dd8 | 6560 | $as_echo "$MSGFMT" >&6; } |
5e13499c | 6561 | else |
1b1fe467 | 6562 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6563 | $as_echo "no" >&6; } |
5e13499c CR |
6564 | fi |
6565 | ||
6566 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
6567 | set dummy gmsgfmt; ac_word=$2 | |
1b1fe467 | 6568 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6569 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 6570 | if ${ac_cv_path_GMSGFMT+:} false; then : |
dd4f3dd8 | 6571 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6572 | else |
6573 | case $GMSGFMT in | |
6574 | [\\/]* | ?:[\\/]*) | |
6575 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
6576 | ;; | |
6577 | *) | |
a82a04b3 CR |
6578 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
6579 | for as_dir in $PATH | |
6580 | do | |
6581 | IFS=$as_save_IFS | |
6582 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 6583 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 6584 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 6585 | ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" |
1b1fe467 | 6586 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
6587 | break 2 |
6588 | fi | |
6589 | done | |
1b1fe467 | 6590 | done |
b709b946 | 6591 | IFS=$as_save_IFS |
5e13499c CR |
6592 | |
6593 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
6594 | ;; | |
6595 | esac | |
6596 | fi | |
6597 | GMSGFMT=$ac_cv_path_GMSGFMT | |
5e13499c | 6598 | if test -n "$GMSGFMT"; then |
1b1fe467 | 6599 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 |
dd4f3dd8 | 6600 | $as_echo "$GMSGFMT" >&6; } |
5e13499c | 6601 | else |
1b1fe467 | 6602 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6603 | $as_echo "no" >&6; } |
5e13499c CR |
6604 | fi |
6605 | ||
a82a04b3 CR |
6606 | |
6607 | ||
b709b946 | 6608 | |
5e13499c CR |
6609 | # Prepare PATH_SEPARATOR. |
6610 | # The user is always right. | |
6611 | if test "${PATH_SEPARATOR+set}" != set; then | |
6612 | echo "#! /bin/sh" >conf$$.sh | |
6613 | echo "exit 0" >>conf$$.sh | |
6614 | chmod +x conf$$.sh | |
6615 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6616 | PATH_SEPARATOR=';' | |
6617 | else | |
6618 | PATH_SEPARATOR=: | |
6619 | fi | |
6620 | rm -f conf$$.sh | |
6621 | fi | |
6622 | ||
6623 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6624 | # as systems may use methods other than mode bits to determine executability. | |
6625 | cat >conf$$.file <<_ASEOF | |
6626 | #! /bin/sh | |
6627 | exit 0 | |
6628 | _ASEOF | |
6629 | chmod +x conf$$.file | |
6630 | if test -x conf$$.file >/dev/null 2>&1; then | |
6631 | ac_executable_p="test -x" | |
6632 | else | |
6633 | ac_executable_p="test -f" | |
6634 | fi | |
6635 | rm -f conf$$.file | |
6636 | ||
6637 | # Extract the first word of "xgettext", so it can be a program name with args. | |
6638 | set dummy xgettext; ac_word=$2 | |
1b1fe467 | 6639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6640 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 6641 | if ${ac_cv_path_XGETTEXT+:} false; then : |
dd4f3dd8 | 6642 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6643 | else |
6644 | case "$XGETTEXT" in | |
6645 | [\\/]* | ?:[\\/]*) | |
6646 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
6647 | ;; | |
6648 | *) | |
6649 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6650 | for ac_dir in $PATH; do | |
6651 | IFS="$ac_save_IFS" | |
6652 | test -z "$ac_dir" && ac_dir=. | |
6653 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6654 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6655 | if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6656 | (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 | |
6657 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" | |
6658 | break 2 | |
6659 | fi | |
6660 | fi | |
6661 | done | |
6662 | done | |
6663 | IFS="$ac_save_IFS" | |
6664 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
6665 | ;; | |
6666 | esac | |
6667 | fi | |
6668 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
6669 | if test "$XGETTEXT" != ":"; then | |
1b1fe467 | 6670 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 |
dd4f3dd8 | 6671 | $as_echo "$XGETTEXT" >&6; } |
5e13499c | 6672 | else |
1b1fe467 | 6673 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6674 | $as_echo "no" >&6; } |
5e13499c CR |
6675 | fi |
6676 | ||
6677 | rm -f messages.po | |
6678 | ||
a82a04b3 | 6679 | |
5e13499c CR |
6680 | # Prepare PATH_SEPARATOR. |
6681 | # The user is always right. | |
6682 | if test "${PATH_SEPARATOR+set}" != set; then | |
6683 | echo "#! /bin/sh" >conf$$.sh | |
6684 | echo "exit 0" >>conf$$.sh | |
6685 | chmod +x conf$$.sh | |
6686 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6687 | PATH_SEPARATOR=';' | |
6688 | else | |
6689 | PATH_SEPARATOR=: | |
6690 | fi | |
6691 | rm -f conf$$.sh | |
6692 | fi | |
6693 | ||
6694 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6695 | # as systems may use methods other than mode bits to determine executability. | |
6696 | cat >conf$$.file <<_ASEOF | |
6697 | #! /bin/sh | |
6698 | exit 0 | |
6699 | _ASEOF | |
6700 | chmod +x conf$$.file | |
6701 | if test -x conf$$.file >/dev/null 2>&1; then | |
6702 | ac_executable_p="test -x" | |
6703 | else | |
6704 | ac_executable_p="test -f" | |
6705 | fi | |
6706 | rm -f conf$$.file | |
6707 | ||
6708 | # Extract the first word of "msgmerge", so it can be a program name with args. | |
6709 | set dummy msgmerge; ac_word=$2 | |
1b1fe467 | 6710 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6711 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 6712 | if ${ac_cv_path_MSGMERGE+:} false; then : |
dd4f3dd8 | 6713 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6714 | else |
6715 | case "$MSGMERGE" in | |
6716 | [\\/]* | ?:[\\/]*) | |
6717 | ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. | |
6718 | ;; | |
6719 | *) | |
6720 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6721 | for ac_dir in $PATH; do | |
6722 | IFS="$ac_save_IFS" | |
6723 | test -z "$ac_dir" && ac_dir=. | |
6724 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6725 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6726 | if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then | |
6727 | ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" | |
6728 | break 2 | |
6729 | fi | |
6730 | fi | |
6731 | done | |
6732 | done | |
6733 | IFS="$ac_save_IFS" | |
6734 | test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" | |
6735 | ;; | |
6736 | esac | |
6737 | fi | |
6738 | MSGMERGE="$ac_cv_path_MSGMERGE" | |
6739 | if test "$MSGMERGE" != ":"; then | |
1b1fe467 | 6740 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5 |
dd4f3dd8 | 6741 | $as_echo "$MSGMERGE" >&6; } |
5e13499c | 6742 | else |
1b1fe467 | 6743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6744 | $as_echo "no" >&6; } |
5e13499c CR |
6745 | fi |
6746 | ||
a82a04b3 | 6747 | |
5e13499c CR |
6748 | if test "$GMSGFMT" != ":"; then |
6749 | if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && | |
6750 | (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6751 | : ; | |
6752 | else | |
6753 | GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` | |
1b1fe467 | 6754 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5 |
dd4f3dd8 | 6755 | $as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; } |
5e13499c CR |
6756 | GMSGFMT=":" |
6757 | fi | |
6758 | fi | |
6759 | ||
6760 | if test "$XGETTEXT" != ":"; then | |
6761 | if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6762 | (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 | |
6763 | : ; | |
6764 | else | |
1b1fe467 | 6765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5 |
dd4f3dd8 | 6766 | $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; } |
5e13499c CR |
6767 | XGETTEXT=":" |
6768 | fi | |
6769 | rm -f messages.po | |
6770 | fi | |
6771 | ||
b709b946 | 6772 | ac_config_commands="$ac_config_commands default-1" |
a82a04b3 | 6773 | |
5e13499c | 6774 | |
1b1fe467 CR |
6775 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
6776 | if test "x$ac_cv_type_off_t" = xyes; then : | |
7175a77f | 6777 | |
5e13499c CR |
6778 | else |
6779 | ||
a82a04b3 | 6780 | cat >>confdefs.h <<_ACEOF |
b709b946 | 6781 | #define off_t long int |
a82a04b3 | 6782 | _ACEOF |
5e13499c CR |
6783 | |
6784 | fi | |
6785 | ||
1b1fe467 CR |
6786 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
6787 | if test "x$ac_cv_type_size_t" = xyes; then : | |
abe2eb5b | 6788 | |
5e13499c CR |
6789 | else |
6790 | ||
a82a04b3 | 6791 | cat >>confdefs.h <<_ACEOF |
b709b946 | 6792 | #define size_t unsigned int |
a82a04b3 | 6793 | _ACEOF |
5e13499c CR |
6794 | |
6795 | fi | |
6796 | ||
6797 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
6798 | # for constant arguments. Useless! | |
1b1fe467 | 6799 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 |
dd4f3dd8 | 6800 | $as_echo_n "checking for working alloca.h... " >&6; } |
1b1fe467 | 6801 | if ${ac_cv_working_alloca_h+:} false; then : |
dd4f3dd8 | 6802 | $as_echo_n "(cached) " >&6 |
5e13499c | 6803 | else |
1b1fe467 | 6804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6805 | /* end confdefs.h. */ |
5e13499c CR |
6806 | #include <alloca.h> |
6807 | int | |
6808 | main () | |
6809 | { | |
6810 | char *p = (char *) alloca (2 * sizeof (int)); | |
b709b946 | 6811 | if (p) return 0; |
5e13499c CR |
6812 | ; |
6813 | return 0; | |
6814 | } | |
6815 | _ACEOF | |
1b1fe467 | 6816 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
6817 | ac_cv_working_alloca_h=yes |
6818 | else | |
1b1fe467 | 6819 | ac_cv_working_alloca_h=no |
5e13499c | 6820 | fi |
1b1fe467 CR |
6821 | rm -f core conftest.err conftest.$ac_objext \ |
6822 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 6823 | fi |
1b1fe467 | 6824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 |
dd4f3dd8 | 6825 | $as_echo "$ac_cv_working_alloca_h" >&6; } |
5e13499c CR |
6826 | if test $ac_cv_working_alloca_h = yes; then |
6827 | ||
1b1fe467 | 6828 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h |
5e13499c CR |
6829 | |
6830 | fi | |
6831 | ||
1b1fe467 | 6832 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
dd4f3dd8 | 6833 | $as_echo_n "checking for alloca... " >&6; } |
1b1fe467 | 6834 | if ${ac_cv_func_alloca_works+:} false; then : |
dd4f3dd8 | 6835 | $as_echo_n "(cached) " >&6 |
5e13499c | 6836 | else |
1b1fe467 | 6837 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6838 | /* end confdefs.h. */ |
5e13499c CR |
6839 | #ifdef __GNUC__ |
6840 | # define alloca __builtin_alloca | |
6841 | #else | |
6842 | # ifdef _MSC_VER | |
6843 | # include <malloc.h> | |
6844 | # define alloca _alloca | |
6845 | # else | |
dd4f3dd8 | 6846 | # ifdef HAVE_ALLOCA_H |
5e13499c CR |
6847 | # include <alloca.h> |
6848 | # else | |
6849 | # ifdef _AIX | |
6850 | #pragma alloca | |
6851 | # else | |
6852 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
1b1fe467 | 6853 | void *alloca (size_t); |
5e13499c CR |
6854 | # endif |
6855 | # endif | |
6856 | # endif | |
6857 | # endif | |
6858 | #endif | |
6859 | ||
6860 | int | |
6861 | main () | |
6862 | { | |
6863 | char *p = (char *) alloca (1); | |
b709b946 | 6864 | if (p) return 0; |
5e13499c CR |
6865 | ; |
6866 | return 0; | |
6867 | } | |
6868 | _ACEOF | |
1b1fe467 | 6869 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
6870 | ac_cv_func_alloca_works=yes |
6871 | else | |
1b1fe467 | 6872 | ac_cv_func_alloca_works=no |
5e13499c | 6873 | fi |
1b1fe467 CR |
6874 | rm -f core conftest.err conftest.$ac_objext \ |
6875 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 6876 | fi |
1b1fe467 | 6877 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
dd4f3dd8 | 6878 | $as_echo "$ac_cv_func_alloca_works" >&6; } |
5e13499c CR |
6879 | |
6880 | if test $ac_cv_func_alloca_works = yes; then | |
6881 | ||
1b1fe467 | 6882 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h |
5e13499c CR |
6883 | |
6884 | else | |
6885 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
6886 | # that cause trouble. Some versions do not even contain alloca or | |
6887 | # contain a buggy version. If you still want to use their alloca, | |
6888 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
6889 | ||
b709b946 | 6890 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext |
5e13499c | 6891 | |
1b1fe467 | 6892 | $as_echo "#define C_ALLOCA 1" >>confdefs.h |
a82a04b3 | 6893 | |
545f34cf | 6894 | |
1b1fe467 | 6895 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 |
dd4f3dd8 | 6896 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } |
1b1fe467 | 6897 | if ${ac_cv_os_cray+:} false; then : |
dd4f3dd8 | 6898 | $as_echo_n "(cached) " >&6 |
5e13499c | 6899 | else |
1b1fe467 | 6900 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6901 | /* end confdefs.h. */ |
b709b946 | 6902 | #if defined CRAY && ! defined CRAY2 |
5e13499c CR |
6903 | webecray |
6904 | #else | |
6905 | wenotbecray | |
6906 | #endif | |
6907 | ||
6908 | _ACEOF | |
6909 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 6910 | $EGREP "webecray" >/dev/null 2>&1; then : |
5e13499c CR |
6911 | ac_cv_os_cray=yes |
6912 | else | |
6913 | ac_cv_os_cray=no | |
6914 | fi | |
6915 | rm -f conftest* | |
6916 | ||
6917 | fi | |
1b1fe467 | 6918 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 |
dd4f3dd8 | 6919 | $as_echo "$ac_cv_os_cray" >&6; } |
5e13499c CR |
6920 | if test $ac_cv_os_cray = yes; then |
6921 | for ac_func in _getb67 GETB67 getb67; do | |
dd4f3dd8 | 6922 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
1b1fe467 CR |
6923 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
6924 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
5e13499c | 6925 | |
1b1fe467 CR |
6926 | cat >>confdefs.h <<_ACEOF |
6927 | #define CRAY_STACKSEG_END $ac_func | |
6928 | _ACEOF | |
7175a77f | 6929 | |
1b1fe467 CR |
6930 | break |
6931 | fi | |
7175a77f | 6932 | |
1b1fe467 CR |
6933 | done |
6934 | fi | |
7175a77f | 6935 | |
1b1fe467 | 6936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 |
7175a77f | 6937 | $as_echo_n "checking stack direction for C alloca... " >&6; } |
1b1fe467 | 6938 | if ${ac_cv_c_stack_direction+:} false; then : |
7175a77f CR |
6939 | $as_echo_n "(cached) " >&6 |
6940 | else | |
1b1fe467 | 6941 | if test "$cross_compiling" = yes; then : |
7175a77f CR |
6942 | ac_cv_c_stack_direction=0 |
6943 | else | |
1b1fe467 | 6944 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
6945 | /* end confdefs.h. */ |
6946 | $ac_includes_default | |
6947 | int | |
0ee50808 | 6948 | find_stack_direction (int *addr, int depth) |
7175a77f | 6949 | { |
0ee50808 CR |
6950 | int dir, dummy = 0; |
6951 | if (! addr) | |
6952 | addr = &dummy; | |
6953 | *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; | |
6954 | dir = depth ? find_stack_direction (addr, depth - 1) : 0; | |
6955 | return dir + dummy; | |
7175a77f CR |
6956 | } |
6957 | ||
6958 | int | |
0ee50808 | 6959 | main (int argc, char **argv) |
5e13499c | 6960 | { |
0ee50808 | 6961 | return find_stack_direction (0, argc + !argv + 20) < 0; |
5e13499c CR |
6962 | } |
6963 | _ACEOF | |
1b1fe467 | 6964 | if ac_fn_c_try_run "$LINENO"; then : |
5e13499c CR |
6965 | ac_cv_c_stack_direction=1 |
6966 | else | |
1b1fe467 | 6967 | ac_cv_c_stack_direction=-1 |
5e13499c | 6968 | fi |
1b1fe467 CR |
6969 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6970 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e13499c | 6971 | fi |
b709b946 | 6972 | |
5e13499c | 6973 | fi |
1b1fe467 | 6974 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 |
dd4f3dd8 | 6975 | $as_echo "$ac_cv_c_stack_direction" >&6; } |
a82a04b3 | 6976 | cat >>confdefs.h <<_ACEOF |
5e13499c | 6977 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
a82a04b3 CR |
6978 | _ACEOF |
6979 | ||
5e13499c CR |
6980 | |
6981 | fi | |
6982 | ||
a82a04b3 CR |
6983 | |
6984 | ||
7175a77f | 6985 | |
1b1fe467 CR |
6986 | for ac_header in $ac_header_list |
6987 | do : | |
6988 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
6989 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
6990 | " | |
6991 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
2dead0c4 CR |
6992 | cat >>confdefs.h <<_ACEOF |
6993 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
6994 | _ACEOF | |
6995 | ||
e3db237e | 6996 | fi |
2dead0c4 CR |
6997 | |
6998 | done | |
6999 | ||
7000 | ||
7001 | ||
7002 | ||
7003 | ||
7004 | ||
7005 | ||
7006 | ||
1b1fe467 CR |
7007 | for ac_func in getpagesize |
7008 | do : | |
7009 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
7010 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
2dead0c4 | 7011 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 7012 | #define HAVE_GETPAGESIZE 1 |
a82a04b3 | 7013 | _ACEOF |
5e13499c CR |
7014 | |
7015 | fi | |
7016 | done | |
7017 | ||
1b1fe467 | 7018 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 |
dd4f3dd8 | 7019 | $as_echo_n "checking for working mmap... " >&6; } |
1b1fe467 | 7020 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : |
dd4f3dd8 | 7021 | $as_echo_n "(cached) " >&6 |
5e13499c | 7022 | else |
1b1fe467 | 7023 | if test "$cross_compiling" = yes; then : |
5e13499c CR |
7024 | ac_cv_func_mmap_fixed_mapped=no |
7025 | else | |
1b1fe467 | 7026 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7027 | /* end confdefs.h. */ |
5e13499c | 7028 | $ac_includes_default |
a82a04b3 CR |
7029 | /* malloc might have been renamed as rpl_malloc. */ |
7030 | #undef malloc | |
7031 | ||
5e13499c CR |
7032 | /* Thanks to Mike Haertel and Jim Avera for this test. |
7033 | Here is a matrix of mmap possibilities: | |
7034 | mmap private not fixed | |
7035 | mmap private fixed at somewhere currently unmapped | |
7036 | mmap private fixed at somewhere already mapped | |
7037 | mmap shared not fixed | |
7038 | mmap shared fixed at somewhere currently unmapped | |
7039 | mmap shared fixed at somewhere already mapped | |
7040 | For private mappings, we should verify that changes cannot be read() | |
7041 | back from the file, nor mmap's back from the file at a different | |
7042 | address. (There have been systems where private was not correctly | |
7043 | implemented like the infamous i386 svr4.0, and systems where the | |
7044 | VM page cache was not coherent with the file system buffer cache | |
7045 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
7046 | For shared mappings, we should conversely verify that changes get | |
a82a04b3 | 7047 | propagated back to all the places they're supposed to be. |
5e13499c CR |
7048 | |
7049 | Grep wants private fixed already mapped. | |
7050 | The main things grep needs to know about mmap are: | |
7051 | * does it exist and is it safe to write into the mmap'd area | |
7052 | * how to use it (BSD variants) */ | |
7053 | ||
7054 | #include <fcntl.h> | |
7055 | #include <sys/mman.h> | |
7056 | ||
dd4f3dd8 | 7057 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H |
5e13499c CR |
7058 | char *malloc (); |
7059 | #endif | |
7060 | ||
7061 | /* This mess was copied from the GNU getpagesize.h. */ | |
dd4f3dd8 | 7062 | #ifndef HAVE_GETPAGESIZE |
5e13499c CR |
7063 | # ifdef _SC_PAGESIZE |
7064 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
7065 | # else /* no _SC_PAGESIZE */ | |
dd4f3dd8 | 7066 | # ifdef HAVE_SYS_PARAM_H |
5e13499c CR |
7067 | # include <sys/param.h> |
7068 | # ifdef EXEC_PAGESIZE | |
7069 | # define getpagesize() EXEC_PAGESIZE | |
7070 | # else /* no EXEC_PAGESIZE */ | |
7071 | # ifdef NBPG | |
7072 | # define getpagesize() NBPG * CLSIZE | |
7073 | # ifndef CLSIZE | |
7074 | # define CLSIZE 1 | |
7075 | # endif /* no CLSIZE */ | |
7076 | # else /* no NBPG */ | |
7077 | # ifdef NBPC | |
7078 | # define getpagesize() NBPC | |
7079 | # else /* no NBPC */ | |
7080 | # ifdef PAGESIZE | |
7081 | # define getpagesize() PAGESIZE | |
7082 | # endif /* PAGESIZE */ | |
7083 | # endif /* no NBPC */ | |
7084 | # endif /* no NBPG */ | |
7085 | # endif /* no EXEC_PAGESIZE */ | |
7086 | # else /* no HAVE_SYS_PARAM_H */ | |
7087 | # define getpagesize() 8192 /* punt totally */ | |
7088 | # endif /* no HAVE_SYS_PARAM_H */ | |
7089 | # endif /* no _SC_PAGESIZE */ | |
7090 | ||
7091 | #endif /* no HAVE_GETPAGESIZE */ | |
7092 | ||
7093 | int | |
7094 | main () | |
7095 | { | |
7096 | char *data, *data2, *data3; | |
1b1fe467 | 7097 | const char *cdata2; |
5e13499c | 7098 | int i, pagesize; |
1b1fe467 | 7099 | int fd, fd2; |
5e13499c CR |
7100 | |
7101 | pagesize = getpagesize (); | |
7102 | ||
7103 | /* First, make a file with some known garbage in it. */ | |
7104 | data = (char *) malloc (pagesize); | |
7105 | if (!data) | |
b709b946 | 7106 | return 1; |
5e13499c CR |
7107 | for (i = 0; i < pagesize; ++i) |
7108 | *(data + i) = rand (); | |
7109 | umask (0); | |
7110 | fd = creat ("conftest.mmap", 0600); | |
7111 | if (fd < 0) | |
1b1fe467 | 7112 | return 2; |
5e13499c | 7113 | if (write (fd, data, pagesize) != pagesize) |
1b1fe467 | 7114 | return 3; |
5e13499c CR |
7115 | close (fd); |
7116 | ||
1b1fe467 CR |
7117 | /* Next, check that the tail of a page is zero-filled. File must have |
7118 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
7119 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
7120 | if (fd2 < 0) | |
7121 | return 4; | |
7122 | cdata2 = ""; | |
7123 | if (write (fd2, cdata2, 1) != 1) | |
7124 | return 5; | |
7125 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
7126 | if (data2 == MAP_FAILED) | |
7127 | return 6; | |
7128 | for (i = 0; i < pagesize; ++i) | |
7129 | if (*(data2 + i)) | |
7130 | return 7; | |
7131 | close (fd2); | |
7132 | if (munmap (data2, pagesize)) | |
7133 | return 8; | |
7134 | ||
5e13499c CR |
7135 | /* Next, try to mmap the file at a fixed address which already has |
7136 | something else allocated at it. If we can, also make sure that | |
7137 | we see the same garbage. */ | |
7138 | fd = open ("conftest.mmap", O_RDWR); | |
7139 | if (fd < 0) | |
1b1fe467 | 7140 | return 9; |
5e13499c | 7141 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, |
5e4a95c7 | 7142 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) |
1b1fe467 | 7143 | return 10; |
5e13499c CR |
7144 | for (i = 0; i < pagesize; ++i) |
7145 | if (*(data + i) != *(data2 + i)) | |
1b1fe467 | 7146 | return 11; |
5e13499c CR |
7147 | |
7148 | /* Finally, make sure that changes to the mapped area do not | |
7149 | percolate back to the file as seen by read(). (This is a bug on | |
7150 | some variants of i386 svr4.0.) */ | |
7151 | for (i = 0; i < pagesize; ++i) | |
7152 | *(data2 + i) = *(data2 + i) + 1; | |
7153 | data3 = (char *) malloc (pagesize); | |
7154 | if (!data3) | |
1b1fe467 | 7155 | return 12; |
5e13499c | 7156 | if (read (fd, data3, pagesize) != pagesize) |
1b1fe467 | 7157 | return 13; |
5e13499c CR |
7158 | for (i = 0; i < pagesize; ++i) |
7159 | if (*(data + i) != *(data3 + i)) | |
1b1fe467 | 7160 | return 14; |
5e13499c | 7161 | close (fd); |
b709b946 | 7162 | return 0; |
5e13499c CR |
7163 | } |
7164 | _ACEOF | |
1b1fe467 | 7165 | if ac_fn_c_try_run "$LINENO"; then : |
5e13499c CR |
7166 | ac_cv_func_mmap_fixed_mapped=yes |
7167 | else | |
1b1fe467 | 7168 | ac_cv_func_mmap_fixed_mapped=no |
5e13499c | 7169 | fi |
1b1fe467 CR |
7170 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7171 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e13499c | 7172 | fi |
b709b946 | 7173 | |
5e13499c | 7174 | fi |
1b1fe467 | 7175 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 |
dd4f3dd8 | 7176 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } |
5e13499c CR |
7177 | if test $ac_cv_func_mmap_fixed_mapped = yes; then |
7178 | ||
1b1fe467 | 7179 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
5e13499c CR |
7180 | |
7181 | fi | |
1b1fe467 | 7182 | rm -f conftest.mmap conftest.txt |
5e13499c | 7183 | |
a82a04b3 | 7184 | |
1b1fe467 | 7185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5 |
dd4f3dd8 | 7186 | $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; } |
1b1fe467 | 7187 | if ${ac_cv_gnu_library_2_1+:} false; then : |
dd4f3dd8 | 7188 | $as_echo_n "(cached) " >&6 |
5e13499c | 7189 | else |
1b1fe467 | 7190 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7191 | /* end confdefs.h. */ |
5e13499c CR |
7192 | |
7193 | #include <features.h> | |
7194 | #ifdef __GNU_LIBRARY__ | |
7195 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) | |
7196 | Lucky GNU user | |
7197 | #endif | |
7198 | #endif | |
7199 | ||
7200 | _ACEOF | |
7201 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 7202 | $EGREP "Lucky GNU user" >/dev/null 2>&1; then : |
5e13499c CR |
7203 | ac_cv_gnu_library_2_1=yes |
7204 | else | |
7205 | ac_cv_gnu_library_2_1=no | |
7206 | fi | |
7207 | rm -f conftest* | |
7208 | ||
a82a04b3 CR |
7209 | |
7210 | ||
5e13499c | 7211 | fi |
1b1fe467 | 7212 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5 |
dd4f3dd8 | 7213 | $as_echo "$ac_cv_gnu_library_2_1" >&6; } |
5e13499c CR |
7214 | |
7215 | GLIBC21="$ac_cv_gnu_library_2_1" | |
7216 | ||
a82a04b3 CR |
7217 | |
7218 | ||
7219 | ||
1b1fe467 | 7220 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether integer division by zero raises SIGFPE" >&5 |
dd4f3dd8 | 7221 | $as_echo_n "checking whether integer division by zero raises SIGFPE... " >&6; } |
1b1fe467 | 7222 | if ${gt_cv_int_divbyzero_sigfpe+:} false; then : |
dd4f3dd8 | 7223 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7224 | else |
7225 | ||
1b1fe467 | 7226 | if test "$cross_compiling" = yes; then : |
5e13499c CR |
7227 | |
7228 | # Guess based on the CPU. | |
7229 | case "$host_cpu" in | |
7230 | alpha* | i3456786 | m68k | s390*) | |
7231 | gt_cv_int_divbyzero_sigfpe="guessing yes";; | |
7232 | *) | |
7233 | gt_cv_int_divbyzero_sigfpe="guessing no";; | |
7234 | esac | |
7235 | ||
7236 | else | |
1b1fe467 | 7237 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7238 | /* end confdefs.h. */ |
5e13499c CR |
7239 | |
7240 | #include <stdlib.h> | |
7241 | #include <signal.h> | |
7242 | ||
7243 | static void | |
7244 | #ifdef __cplusplus | |
7245 | sigfpe_handler (int sig) | |
7246 | #else | |
7247 | sigfpe_handler (sig) int sig; | |
7248 | #endif | |
7249 | { | |
7250 | /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ | |
7251 | exit (sig != SIGFPE); | |
7252 | } | |
7253 | ||
7254 | int x = 1; | |
7255 | int y = 0; | |
7256 | int z; | |
7257 | int nan; | |
7258 | ||
7259 | int main () | |
7260 | { | |
7261 | signal (SIGFPE, sigfpe_handler); | |
7262 | /* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */ | |
7263 | #if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP) | |
7264 | signal (SIGTRAP, sigfpe_handler); | |
7265 | #endif | |
7266 | /* Linux/SPARC yields signal SIGILL. */ | |
7267 | #if defined (__sparc__) && defined (__linux__) | |
7268 | signal (SIGILL, sigfpe_handler); | |
7269 | #endif | |
7270 | ||
7271 | z = x / y; | |
7272 | nan = y / y; | |
7273 | exit (1); | |
7274 | } | |
7275 | ||
7276 | _ACEOF | |
1b1fe467 | 7277 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f CR |
7278 | gt_cv_int_divbyzero_sigfpe=yes |
7279 | else | |
1b1fe467 | 7280 | gt_cv_int_divbyzero_sigfpe=no |
7175a77f | 7281 | fi |
1b1fe467 CR |
7282 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7283 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7175a77f CR |
7284 | fi |
7285 | ||
7286 | ||
5e13499c | 7287 | fi |
1b1fe467 | 7288 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_int_divbyzero_sigfpe" >&5 |
dd4f3dd8 | 7289 | $as_echo "$gt_cv_int_divbyzero_sigfpe" >&6; } |
5e13499c CR |
7290 | case "$gt_cv_int_divbyzero_sigfpe" in |
7291 | *yes) value=1;; | |
7292 | *) value=0;; | |
7293 | esac | |
7294 | ||
a82a04b3 | 7295 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7296 | #define INTDIV0_RAISES_SIGFPE $value |
a82a04b3 CR |
7297 | _ACEOF |
7298 | ||
545f34cf | 7299 | |
a82a04b3 | 7300 | |
1b1fe467 | 7301 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
dd4f3dd8 | 7302 | $as_echo_n "checking for inttypes.h... " >&6; } |
1b1fe467 | 7303 | if ${jm_ac_cv_header_inttypes_h+:} false; then : |
dd4f3dd8 | 7304 | $as_echo_n "(cached) " >&6 |
5e13499c | 7305 | else |
1b1fe467 | 7306 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7307 | /* end confdefs.h. */ |
5e13499c CR |
7308 | #include <sys/types.h> |
7309 | #include <inttypes.h> | |
7310 | int | |
7311 | main () | |
7312 | { | |
7313 | uintmax_t i = (uintmax_t) -1; | |
7314 | ; | |
7315 | return 0; | |
7316 | } | |
7317 | _ACEOF | |
1b1fe467 | 7318 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
7319 | jm_ac_cv_header_inttypes_h=yes |
7320 | else | |
1b1fe467 | 7321 | jm_ac_cv_header_inttypes_h=no |
5e13499c | 7322 | fi |
b709b946 | 7323 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c | 7324 | fi |
1b1fe467 | 7325 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_inttypes_h" >&5 |
dd4f3dd8 | 7326 | $as_echo "$jm_ac_cv_header_inttypes_h" >&6; } |
5e13499c CR |
7327 | if test $jm_ac_cv_header_inttypes_h = yes; then |
7328 | ||
a82a04b3 | 7329 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7330 | #define HAVE_INTTYPES_H_WITH_UINTMAX 1 |
a82a04b3 | 7331 | _ACEOF |
5e13499c CR |
7332 | |
7333 | fi | |
7334 | ||
a82a04b3 | 7335 | |
1b1fe467 | 7336 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5 |
dd4f3dd8 | 7337 | $as_echo_n "checking for stdint.h... " >&6; } |
1b1fe467 | 7338 | if ${jm_ac_cv_header_stdint_h+:} false; then : |
dd4f3dd8 | 7339 | $as_echo_n "(cached) " >&6 |
5e13499c | 7340 | else |
1b1fe467 | 7341 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7342 | /* end confdefs.h. */ |
5e13499c CR |
7343 | #include <sys/types.h> |
7344 | #include <stdint.h> | |
7345 | int | |
7346 | main () | |
7347 | { | |
7348 | uintmax_t i = (uintmax_t) -1; | |
7349 | ; | |
7350 | return 0; | |
7351 | } | |
7352 | _ACEOF | |
1b1fe467 | 7353 | if ac_fn_c_try_compile "$LINENO"; then : |
abe2eb5b CR |
7354 | jm_ac_cv_header_stdint_h=yes |
7355 | else | |
1b1fe467 | 7356 | jm_ac_cv_header_stdint_h=no |
7610e0c5 | 7357 | fi |
abe2eb5b CR |
7358 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7359 | fi | |
1b1fe467 | 7360 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_stdint_h" >&5 |
7610e0c5 | 7361 | $as_echo "$jm_ac_cv_header_stdint_h" >&6; } |
5e13499c CR |
7362 | if test $jm_ac_cv_header_stdint_h = yes; then |
7363 | ||
a82a04b3 | 7364 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7365 | #define HAVE_STDINT_H_WITH_UINTMAX 1 |
a82a04b3 | 7366 | _ACEOF |
5e13499c CR |
7367 | |
7368 | fi | |
7369 | ||
a82a04b3 | 7370 | |
1b1fe467 | 7371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 |
dd4f3dd8 | 7372 | $as_echo_n "checking for unsigned long long... " >&6; } |
1b1fe467 | 7373 | if ${ac_cv_type_unsigned_long_long+:} false; then : |
dd4f3dd8 | 7374 | $as_echo_n "(cached) " >&6 |
5e13499c | 7375 | else |
1b1fe467 | 7376 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7377 | /* end confdefs.h. */ |
5e13499c CR |
7378 | unsigned long long ull = 1; int i = 63; |
7379 | int | |
7380 | main () | |
7381 | { | |
7382 | unsigned long long ullmax = (unsigned long long) -1; | |
7383 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
7384 | ; | |
7385 | return 0; | |
7386 | } | |
7387 | _ACEOF | |
1b1fe467 | 7388 | if ac_fn_c_try_link "$LINENO"; then : |
e3db237e | 7389 | ac_cv_type_unsigned_long_long=yes |
5e13499c | 7390 | else |
1b1fe467 | 7391 | ac_cv_type_unsigned_long_long=no |
5e13499c | 7392 | fi |
1b1fe467 CR |
7393 | rm -f core conftest.err conftest.$ac_objext \ |
7394 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 7395 | fi |
1b1fe467 | 7396 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long" >&5 |
dd4f3dd8 | 7397 | $as_echo "$ac_cv_type_unsigned_long_long" >&6; } |
5e13499c CR |
7398 | if test $ac_cv_type_unsigned_long_long = yes; then |
7399 | ||
1b1fe467 | 7400 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h |
5e13499c CR |
7401 | |
7402 | fi | |
7403 | ||
a82a04b3 CR |
7404 | |
7405 | ||
7406 | ||
5e13499c CR |
7407 | if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then |
7408 | ||
7409 | test $ac_cv_type_unsigned_long_long = yes \ | |
7410 | && ac_type='unsigned long long' \ | |
7411 | || ac_type='unsigned long' | |
7412 | ||
a82a04b3 | 7413 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7414 | #define uintmax_t $ac_type |
a82a04b3 | 7415 | _ACEOF |
5e13499c CR |
7416 | |
7417 | else | |
7418 | ||
1b1fe467 | 7419 | $as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h |
5e13499c CR |
7420 | |
7421 | fi | |
7422 | ||
a82a04b3 | 7423 | |
1b1fe467 | 7424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
dd4f3dd8 | 7425 | $as_echo_n "checking for inttypes.h... " >&6; } |
1b1fe467 | 7426 | if ${gt_cv_header_inttypes_h+:} false; then : |
dd4f3dd8 | 7427 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7428 | else |
7429 | ||
1b1fe467 | 7430 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7431 | /* end confdefs.h. */ |
5e13499c CR |
7432 | #include <sys/types.h> |
7433 | #include <inttypes.h> | |
7434 | int | |
7435 | main () | |
7436 | { | |
7437 | ||
7438 | ; | |
7439 | return 0; | |
7440 | } | |
7441 | _ACEOF | |
1b1fe467 | 7442 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
7443 | gt_cv_header_inttypes_h=yes |
7444 | else | |
1b1fe467 | 7445 | gt_cv_header_inttypes_h=no |
5e13499c | 7446 | fi |
b709b946 | 7447 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
7448 | |
7449 | fi | |
1b1fe467 | 7450 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_header_inttypes_h" >&5 |
dd4f3dd8 | 7451 | $as_echo "$gt_cv_header_inttypes_h" >&6; } |
5e13499c CR |
7452 | if test $gt_cv_header_inttypes_h = yes; then |
7453 | ||
a82a04b3 | 7454 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7455 | #define HAVE_INTTYPES_H 1 |
a82a04b3 | 7456 | _ACEOF |
5e13499c CR |
7457 | |
7458 | fi | |
7459 | ||
a82a04b3 CR |
7460 | |
7461 | ||
5e13499c | 7462 | if test $gt_cv_header_inttypes_h = yes; then |
1b1fe467 | 7463 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5 |
dd4f3dd8 | 7464 | $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; } |
1b1fe467 | 7465 | if ${gt_cv_inttypes_pri_broken+:} false; then : |
dd4f3dd8 | 7466 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7467 | else |
7468 | ||
1b1fe467 | 7469 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7470 | /* end confdefs.h. */ |
5e13499c CR |
7471 | #include <inttypes.h> |
7472 | #ifdef PRId32 | |
7473 | char *p = PRId32; | |
7474 | #endif | |
7475 | ||
7476 | int | |
7477 | main () | |
7478 | { | |
7479 | ||
7480 | ; | |
7481 | return 0; | |
7482 | } | |
7483 | _ACEOF | |
1b1fe467 | 7484 | if ac_fn_c_try_compile "$LINENO"; then : |
2e4498b3 CR |
7485 | gt_cv_inttypes_pri_broken=no |
7486 | else | |
1b1fe467 | 7487 | gt_cv_inttypes_pri_broken=yes |
5e13499c | 7488 | fi |
b709b946 | 7489 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
7490 | |
7491 | fi | |
1b1fe467 | 7492 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5 |
dd4f3dd8 | 7493 | $as_echo "$gt_cv_inttypes_pri_broken" >&6; } |
5e13499c CR |
7494 | fi |
7495 | if test "$gt_cv_inttypes_pri_broken" = yes; then | |
7496 | ||
a82a04b3 | 7497 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7498 | #define PRI_MACROS_BROKEN 1 |
a82a04b3 | 7499 | _ACEOF |
5e13499c CR |
7500 | |
7501 | fi | |
7502 | ||
a82a04b3 | 7503 | |
5e13499c CR |
7504 | if test "X$prefix" = "XNONE"; then |
7505 | acl_final_prefix="$ac_default_prefix" | |
7506 | else | |
7507 | acl_final_prefix="$prefix" | |
7508 | fi | |
7509 | if test "X$exec_prefix" = "XNONE"; then | |
7510 | acl_final_exec_prefix='${prefix}' | |
7511 | else | |
7512 | acl_final_exec_prefix="$exec_prefix" | |
7513 | fi | |
7514 | acl_save_prefix="$prefix" | |
7515 | prefix="$acl_final_prefix" | |
7516 | eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" | |
7517 | prefix="$acl_save_prefix" | |
7518 | ||
a82a04b3 | 7519 | |
b709b946 | 7520 | # Check whether --with-gnu-ld was given. |
1b1fe467 | 7521 | if test "${with_gnu_ld+set}" = set; then : |
b709b946 | 7522 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes |
5e13499c CR |
7523 | else |
7524 | with_gnu_ld=no | |
b709b946 CR |
7525 | fi |
7526 | ||
5e13499c CR |
7527 | # Prepare PATH_SEPARATOR. |
7528 | # The user is always right. | |
7529 | if test "${PATH_SEPARATOR+set}" != set; then | |
7530 | echo "#! /bin/sh" >conf$$.sh | |
7531 | echo "exit 0" >>conf$$.sh | |
7532 | chmod +x conf$$.sh | |
7533 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
7534 | PATH_SEPARATOR=';' | |
7535 | else | |
7536 | PATH_SEPARATOR=: | |
7537 | fi | |
7538 | rm -f conf$$.sh | |
7539 | fi | |
7540 | ac_prog=ld | |
7541 | if test "$GCC" = yes; then | |
7542 | # Check if gcc -print-prog-name=ld gives a path. | |
1b1fe467 | 7543 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 |
dd4f3dd8 | 7544 | $as_echo_n "checking for ld used by GCC... " >&6; } |
5e13499c CR |
7545 | case $host in |
7546 | *-*-mingw*) | |
7547 | # gcc leaves a trailing carriage return which upsets mingw | |
7548 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
7549 | *) | |
7550 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
7551 | esac | |
7552 | case $ac_prog in | |
7553 | # Accept absolute paths. | |
7554 | [\\/]* | [A-Za-z]:[\\/]*) | |
7555 | re_direlt='/[^/][^/]*/\.\./' | |
7556 | # Canonicalize the path of ld | |
7557 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
7558 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
7559 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
7560 | done | |
7561 | test -z "$LD" && LD="$ac_prog" | |
7562 | ;; | |
7563 | "") | |
7564 | # If it fails, then pretend we aren't using GCC. | |
7565 | ac_prog=ld | |
7566 | ;; | |
7567 | *) | |
7568 | # If it is relative, then search for the first ld in PATH. | |
7569 | with_gnu_ld=unknown | |
7570 | ;; | |
7571 | esac | |
7572 | elif test "$with_gnu_ld" = yes; then | |
1b1fe467 | 7573 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
dd4f3dd8 | 7574 | $as_echo_n "checking for GNU ld... " >&6; } |
5e13499c | 7575 | else |
1b1fe467 | 7576 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
dd4f3dd8 | 7577 | $as_echo_n "checking for non-GNU ld... " >&6; } |
5e13499c | 7578 | fi |
1b1fe467 | 7579 | if ${acl_cv_path_LD+:} false; then : |
dd4f3dd8 | 7580 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7581 | else |
7582 | if test -z "$LD"; then | |
7583 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" | |
7584 | for ac_dir in $PATH; do | |
7585 | test -z "$ac_dir" && ac_dir=. | |
7586 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
7587 | acl_cv_path_LD="$ac_dir/$ac_prog" | |
7588 | # Check to see if the program is GNU ld. I'd rather use --version, | |
7589 | # but apparently some GNU ld's only accept -v. | |
7590 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
7591 | if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then | |
7592 | test "$with_gnu_ld" != no && break | |
7593 | else | |
7594 | test "$with_gnu_ld" != yes && break | |
7595 | fi | |
7596 | fi | |
7597 | done | |
7598 | IFS="$ac_save_ifs" | |
7599 | else | |
7600 | acl_cv_path_LD="$LD" # Let the user override the test with a path. | |
7601 | fi | |
7602 | fi | |
7603 | ||
7604 | LD="$acl_cv_path_LD" | |
7605 | if test -n "$LD"; then | |
1b1fe467 | 7606 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
dd4f3dd8 | 7607 | $as_echo "$LD" >&6; } |
5e13499c | 7608 | else |
1b1fe467 | 7609 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 7610 | $as_echo "no" >&6; } |
5e13499c | 7611 | fi |
1b1fe467 CR |
7612 | test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 |
7613 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
dd4f3dd8 | 7614 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } |
1b1fe467 | 7615 | if ${acl_cv_prog_gnu_ld+:} false; then : |
dd4f3dd8 | 7616 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7617 | else |
7618 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
7619 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then | |
7620 | acl_cv_prog_gnu_ld=yes | |
7621 | else | |
7622 | acl_cv_prog_gnu_ld=no | |
7623 | fi | |
7624 | fi | |
1b1fe467 | 7625 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5 |
dd4f3dd8 | 7626 | $as_echo "$acl_cv_prog_gnu_ld" >&6; } |
5e13499c CR |
7627 | with_gnu_ld=$acl_cv_prog_gnu_ld |
7628 | ||
a82a04b3 CR |
7629 | |
7630 | ||
1b1fe467 | 7631 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 |
dd4f3dd8 | 7632 | $as_echo_n "checking for shared library run path origin... " >&6; } |
1b1fe467 | 7633 | if ${acl_cv_rpath+:} false; then : |
dd4f3dd8 | 7634 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7635 | else |
7636 | ||
7637 | CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ | |
7638 | ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh | |
7639 | . ./conftest.sh | |
7640 | rm -f ./conftest.sh | |
7641 | acl_cv_rpath=done | |
7642 | ||
7643 | fi | |
1b1fe467 | 7644 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 |
dd4f3dd8 | 7645 | $as_echo "$acl_cv_rpath" >&6; } |
5e13499c CR |
7646 | wl="$acl_cv_wl" |
7647 | libext="$acl_cv_libext" | |
7648 | shlibext="$acl_cv_shlibext" | |
7649 | hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" | |
7650 | hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" | |
7651 | hardcode_direct="$acl_cv_hardcode_direct" | |
7652 | hardcode_minus_L="$acl_cv_hardcode_minus_L" | |
b709b946 | 7653 | # Check whether --enable-rpath was given. |
1b1fe467 | 7654 | if test "${enable_rpath+set}" = set; then : |
b709b946 | 7655 | enableval=$enable_rpath; : |
5e13499c CR |
7656 | else |
7657 | enable_rpath=yes | |
b709b946 CR |
7658 | fi |
7659 | ||
5e13499c | 7660 | |
a82a04b3 CR |
7661 | |
7662 | ||
7663 | ||
7664 | ||
7665 | ||
7666 | ||
5e13499c CR |
7667 | use_additional=yes |
7668 | ||
7669 | acl_save_prefix="$prefix" | |
7670 | prefix="$acl_final_prefix" | |
7671 | acl_save_exec_prefix="$exec_prefix" | |
7672 | exec_prefix="$acl_final_exec_prefix" | |
7673 | ||
7674 | eval additional_includedir=\"$includedir\" | |
7675 | eval additional_libdir=\"$libdir\" | |
7676 | ||
7677 | exec_prefix="$acl_save_exec_prefix" | |
7678 | prefix="$acl_save_prefix" | |
7679 | ||
a82a04b3 | 7680 | |
b709b946 | 7681 | # Check whether --with-libiconv-prefix was given. |
1b1fe467 | 7682 | if test "${with_libiconv_prefix+set}" = set; then : |
b709b946 | 7683 | withval=$with_libiconv_prefix; |
5e13499c CR |
7684 | if test "X$withval" = "Xno"; then |
7685 | use_additional=no | |
7686 | else | |
7687 | if test "X$withval" = "X"; then | |
7688 | ||
7689 | acl_save_prefix="$prefix" | |
7690 | prefix="$acl_final_prefix" | |
7691 | acl_save_exec_prefix="$exec_prefix" | |
7692 | exec_prefix="$acl_final_exec_prefix" | |
7693 | ||
7694 | eval additional_includedir=\"$includedir\" | |
7695 | eval additional_libdir=\"$libdir\" | |
7696 | ||
7697 | exec_prefix="$acl_save_exec_prefix" | |
7698 | prefix="$acl_save_prefix" | |
7699 | ||
7700 | else | |
7701 | additional_includedir="$withval/include" | |
7702 | additional_libdir="$withval/lib" | |
7703 | fi | |
7704 | fi | |
7705 | ||
b709b946 CR |
7706 | fi |
7707 | ||
5e13499c CR |
7708 | LIBICONV= |
7709 | LTLIBICONV= | |
7710 | INCICONV= | |
7711 | rpathdirs= | |
7712 | ltrpathdirs= | |
7713 | names_already_handled= | |
7714 | names_next_round='iconv ' | |
7715 | while test -n "$names_next_round"; do | |
7716 | names_this_round="$names_next_round" | |
7717 | names_next_round= | |
7718 | for name in $names_this_round; do | |
7719 | already_handled= | |
7720 | for n in $names_already_handled; do | |
7721 | if test "$n" = "$name"; then | |
7722 | already_handled=yes | |
7723 | break | |
7724 | fi | |
7725 | done | |
7726 | if test -z "$already_handled"; then | |
7727 | names_already_handled="$names_already_handled $name" | |
7728 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
7729 | eval value=\"\$HAVE_LIB$uppername\" | |
7730 | if test -n "$value"; then | |
7731 | if test "$value" = yes; then | |
7732 | eval value=\"\$LIB$uppername\" | |
7733 | test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" | |
7734 | eval value=\"\$LTLIB$uppername\" | |
7735 | test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" | |
7736 | else | |
7737 | : | |
7738 | fi | |
7739 | else | |
7740 | found_dir= | |
7741 | found_la= | |
7742 | found_so= | |
7743 | found_a= | |
7744 | if test $use_additional = yes; then | |
f4f5e1c2 | 7745 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
5e13499c CR |
7746 | found_dir="$additional_libdir" |
7747 | found_so="$additional_libdir/lib$name.$shlibext" | |
7748 | if test -f "$additional_libdir/lib$name.la"; then | |
7749 | found_la="$additional_libdir/lib$name.la" | |
7750 | fi | |
7751 | else | |
7752 | if test -f "$additional_libdir/lib$name.$libext"; then | |
7753 | found_dir="$additional_libdir" | |
7754 | found_a="$additional_libdir/lib$name.$libext" | |
7755 | if test -f "$additional_libdir/lib$name.la"; then | |
7756 | found_la="$additional_libdir/lib$name.la" | |
7757 | fi | |
7758 | fi | |
7759 | fi | |
7760 | fi | |
7761 | if test "X$found_dir" = "X"; then | |
7762 | for x in $LDFLAGS $LTLIBICONV; do | |
7763 | ||
7764 | acl_save_prefix="$prefix" | |
7765 | prefix="$acl_final_prefix" | |
7766 | acl_save_exec_prefix="$exec_prefix" | |
7767 | exec_prefix="$acl_final_exec_prefix" | |
7768 | eval x=\"$x\" | |
7769 | exec_prefix="$acl_save_exec_prefix" | |
7770 | prefix="$acl_save_prefix" | |
7771 | ||
7772 | case "$x" in | |
7773 | -L*) | |
7774 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
f4f5e1c2 | 7775 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
5e13499c CR |
7776 | found_dir="$dir" |
7777 | found_so="$dir/lib$name.$shlibext" | |
7778 | if test -f "$dir/lib$name.la"; then | |
7779 | found_la="$dir/lib$name.la" | |
7780 | fi | |
7781 | else | |
7782 | if test -f "$dir/lib$name.$libext"; then | |
7783 | found_dir="$dir" | |
7784 | found_a="$dir/lib$name.$libext" | |
7785 | if test -f "$dir/lib$name.la"; then | |
7786 | found_la="$dir/lib$name.la" | |
7787 | fi | |
7788 | fi | |
7789 | fi | |
7790 | ;; | |
7791 | esac | |
7792 | if test "X$found_dir" != "X"; then | |
7793 | break | |
7794 | fi | |
7795 | done | |
7796 | fi | |
7797 | if test "X$found_dir" != "X"; then | |
7798 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" | |
7799 | if test "X$found_so" != "X"; then | |
7800 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
7801 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7802 | else | |
7803 | haveit= | |
7804 | for x in $ltrpathdirs; do | |
7805 | if test "X$x" = "X$found_dir"; then | |
7806 | haveit=yes | |
7807 | break | |
7808 | fi | |
7809 | done | |
7810 | if test -z "$haveit"; then | |
7811 | ltrpathdirs="$ltrpathdirs $found_dir" | |
7812 | fi | |
7813 | if test "$hardcode_direct" = yes; then | |
7814 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7815 | else | |
7816 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
7817 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7818 | haveit= | |
7819 | for x in $rpathdirs; do | |
7820 | if test "X$x" = "X$found_dir"; then | |
7821 | haveit=yes | |
7822 | break | |
7823 | fi | |
7824 | done | |
7825 | if test -z "$haveit"; then | |
7826 | rpathdirs="$rpathdirs $found_dir" | |
7827 | fi | |
7828 | else | |
7829 | haveit= | |
7830 | for x in $LDFLAGS $LIBICONV; do | |
7831 | ||
7832 | acl_save_prefix="$prefix" | |
7833 | prefix="$acl_final_prefix" | |
7834 | acl_save_exec_prefix="$exec_prefix" | |
7835 | exec_prefix="$acl_final_exec_prefix" | |
7836 | eval x=\"$x\" | |
7837 | exec_prefix="$acl_save_exec_prefix" | |
7838 | prefix="$acl_save_prefix" | |
7839 | ||
7840 | if test "X$x" = "X-L$found_dir"; then | |
7841 | haveit=yes | |
7842 | break | |
7843 | fi | |
7844 | done | |
7845 | if test -z "$haveit"; then | |
7846 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" | |
7847 | fi | |
7848 | if test "$hardcode_minus_L" != no; then | |
7849 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7850 | else | |
7851 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
7852 | fi | |
7853 | fi | |
7854 | fi | |
7855 | fi | |
7856 | else | |
7857 | if test "X$found_a" != "X"; then | |
7858 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" | |
7859 | else | |
7860 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" | |
7861 | fi | |
7862 | fi | |
7863 | additional_includedir= | |
7864 | case "$found_dir" in | |
7865 | */lib | */lib/) | |
7866 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
7867 | additional_includedir="$basedir/include" | |
7868 | ;; | |
7869 | esac | |
7870 | if test "X$additional_includedir" != "X"; then | |
7871 | if test "X$additional_includedir" != "X/usr/include"; then | |
7872 | haveit= | |
7873 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
7874 | if test -n "$GCC"; then | |
7875 | case $host_os in | |
7876 | linux*) haveit=yes;; | |
7877 | esac | |
7878 | fi | |
7879 | fi | |
7880 | if test -z "$haveit"; then | |
7881 | for x in $CPPFLAGS $INCICONV; do | |
7882 | ||
7883 | acl_save_prefix="$prefix" | |
7884 | prefix="$acl_final_prefix" | |
7885 | acl_save_exec_prefix="$exec_prefix" | |
7886 | exec_prefix="$acl_final_exec_prefix" | |
7887 | eval x=\"$x\" | |
7888 | exec_prefix="$acl_save_exec_prefix" | |
7889 | prefix="$acl_save_prefix" | |
7890 | ||
7891 | if test "X$x" = "X-I$additional_includedir"; then | |
7892 | haveit=yes | |
7893 | break | |
7894 | fi | |
7895 | done | |
7896 | if test -z "$haveit"; then | |
7897 | if test -d "$additional_includedir"; then | |
7898 | INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" | |
7899 | fi | |
7900 | fi | |
7901 | fi | |
7902 | fi | |
7903 | fi | |
7904 | if test -n "$found_la"; then | |
7905 | save_libdir="$libdir" | |
7906 | case "$found_la" in | |
7907 | */* | *\\*) . "$found_la" ;; | |
7908 | *) . "./$found_la" ;; | |
7909 | esac | |
7910 | libdir="$save_libdir" | |
7911 | for dep in $dependency_libs; do | |
7912 | case "$dep" in | |
7913 | -L*) | |
7914 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
7915 | if test "X$additional_libdir" != "X/usr/lib"; then | |
7916 | haveit= | |
7917 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
7918 | if test -n "$GCC"; then | |
7919 | case $host_os in | |
7920 | linux*) haveit=yes;; | |
7921 | esac | |
7922 | fi | |
7923 | fi | |
7924 | if test -z "$haveit"; then | |
7925 | haveit= | |
7926 | for x in $LDFLAGS $LIBICONV; do | |
7927 | ||
7928 | acl_save_prefix="$prefix" | |
7929 | prefix="$acl_final_prefix" | |
7930 | acl_save_exec_prefix="$exec_prefix" | |
7931 | exec_prefix="$acl_final_exec_prefix" | |
7932 | eval x=\"$x\" | |
7933 | exec_prefix="$acl_save_exec_prefix" | |
7934 | prefix="$acl_save_prefix" | |
7935 | ||
7936 | if test "X$x" = "X-L$additional_libdir"; then | |
7937 | haveit=yes | |
7938 | break | |
7939 | fi | |
7940 | done | |
7941 | if test -z "$haveit"; then | |
7942 | if test -d "$additional_libdir"; then | |
7943 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" | |
7944 | fi | |
7945 | fi | |
7946 | haveit= | |
7947 | for x in $LDFLAGS $LTLIBICONV; do | |
7948 | ||
7949 | acl_save_prefix="$prefix" | |
7950 | prefix="$acl_final_prefix" | |
7951 | acl_save_exec_prefix="$exec_prefix" | |
7952 | exec_prefix="$acl_final_exec_prefix" | |
7953 | eval x=\"$x\" | |
7954 | exec_prefix="$acl_save_exec_prefix" | |
7955 | prefix="$acl_save_prefix" | |
7956 | ||
7957 | if test "X$x" = "X-L$additional_libdir"; then | |
7958 | haveit=yes | |
7959 | break | |
7960 | fi | |
7961 | done | |
7962 | if test -z "$haveit"; then | |
7963 | if test -d "$additional_libdir"; then | |
7964 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" | |
7965 | fi | |
7966 | fi | |
7967 | fi | |
7968 | fi | |
7969 | ;; | |
7970 | -R*) | |
7971 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
7972 | if test "$enable_rpath" != no; then | |
7973 | haveit= | |
7974 | for x in $rpathdirs; do | |
7975 | if test "X$x" = "X$dir"; then | |
7976 | haveit=yes | |
7977 | break | |
7978 | fi | |
7979 | done | |
7980 | if test -z "$haveit"; then | |
7981 | rpathdirs="$rpathdirs $dir" | |
7982 | fi | |
7983 | haveit= | |
7984 | for x in $ltrpathdirs; do | |
7985 | if test "X$x" = "X$dir"; then | |
7986 | haveit=yes | |
7987 | break | |
7988 | fi | |
7989 | done | |
7990 | if test -z "$haveit"; then | |
7991 | ltrpathdirs="$ltrpathdirs $dir" | |
7992 | fi | |
7993 | fi | |
7994 | ;; | |
7995 | -l*) | |
7996 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
7997 | ;; | |
7998 | *.la) | |
7999 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
8000 | ;; | |
8001 | *) | |
8002 | LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" | |
8003 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" | |
8004 | ;; | |
8005 | esac | |
8006 | done | |
8007 | fi | |
8008 | else | |
8009 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
8010 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" | |
8011 | fi | |
8012 | fi | |
8013 | fi | |
8014 | done | |
8015 | done | |
8016 | if test "X$rpathdirs" != "X"; then | |
8017 | if test -n "$hardcode_libdir_separator"; then | |
8018 | alldirs= | |
8019 | for found_dir in $rpathdirs; do | |
8020 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
8021 | done | |
8022 | acl_save_libdir="$libdir" | |
8023 | libdir="$alldirs" | |
8024 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8025 | libdir="$acl_save_libdir" | |
8026 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
8027 | else | |
8028 | for found_dir in $rpathdirs; do | |
8029 | acl_save_libdir="$libdir" | |
8030 | libdir="$found_dir" | |
8031 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8032 | libdir="$acl_save_libdir" | |
8033 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
8034 | done | |
8035 | fi | |
8036 | fi | |
8037 | if test "X$ltrpathdirs" != "X"; then | |
8038 | for found_dir in $ltrpathdirs; do | |
8039 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" | |
8040 | done | |
8041 | fi | |
8042 | ||
a82a04b3 CR |
8043 | |
8044 | ||
8045 | ||
1b1fe467 | 8046 | for ac_header in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ |
7f947b68 | 8047 | stdlib.h string.h unistd.h sys/param.h |
1b1fe467 CR |
8048 | do : |
8049 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
8050 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
8051 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
7f947b68 CR |
8052 | cat >>confdefs.h <<_ACEOF |
8053 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
8054 | _ACEOF | |
abe2eb5b | 8055 | |
7f947b68 | 8056 | fi |
abe2eb5b | 8057 | |
7f947b68 | 8058 | done |
abe2eb5b | 8059 | |
1b1fe467 | 8060 | for ac_func in feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ |
7f947b68 CR |
8061 | geteuid getgid getuid mempcpy munmap putenv setenv setlocale localeconv stpcpy \ |
8062 | strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ | |
8063 | __fsetlocking | |
1b1fe467 CR |
8064 | do : |
8065 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
8066 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
8067 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
7f947b68 CR |
8068 | cat >>confdefs.h <<_ACEOF |
8069 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
8070 | _ACEOF | |
abe2eb5b | 8071 | |
7f947b68 CR |
8072 | fi |
8073 | done | |
5e13499c | 8074 | |
a82a04b3 CR |
8075 | |
8076 | ||
8077 | ||
8078 | ||
8079 | ||
8080 | ||
5e13499c CR |
8081 | am_save_CPPFLAGS="$CPPFLAGS" |
8082 | ||
8083 | for element in $INCICONV; do | |
8084 | haveit= | |
8085 | for x in $CPPFLAGS; do | |
8086 | ||
8087 | acl_save_prefix="$prefix" | |
8088 | prefix="$acl_final_prefix" | |
8089 | acl_save_exec_prefix="$exec_prefix" | |
8090 | exec_prefix="$acl_final_exec_prefix" | |
8091 | eval x=\"$x\" | |
8092 | exec_prefix="$acl_save_exec_prefix" | |
8093 | prefix="$acl_save_prefix" | |
8094 | ||
8095 | if test "X$x" = "X$element"; then | |
8096 | haveit=yes | |
8097 | break | |
8098 | fi | |
8099 | done | |
8100 | if test -z "$haveit"; then | |
8101 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8102 | fi | |
8103 | done | |
8104 | ||
a82a04b3 | 8105 | |
1b1fe467 | 8106 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 |
dd4f3dd8 | 8107 | $as_echo_n "checking for iconv... " >&6; } |
1b1fe467 | 8108 | if ${am_cv_func_iconv+:} false; then : |
dd4f3dd8 | 8109 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8110 | else |
8111 | ||
8112 | am_cv_func_iconv="no, consider installing GNU libiconv" | |
8113 | am_cv_lib_iconv=no | |
1b1fe467 | 8114 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8115 | /* end confdefs.h. */ |
5e13499c CR |
8116 | #include <stdlib.h> |
8117 | #include <iconv.h> | |
8118 | int | |
8119 | main () | |
8120 | { | |
8121 | iconv_t cd = iconv_open("",""); | |
8122 | iconv(cd,NULL,NULL,NULL,NULL); | |
8123 | iconv_close(cd); | |
8124 | ; | |
8125 | return 0; | |
8126 | } | |
8127 | _ACEOF | |
1b1fe467 | 8128 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c | 8129 | am_cv_func_iconv=yes |
5e13499c | 8130 | fi |
1b1fe467 CR |
8131 | rm -f core conftest.err conftest.$ac_objext \ |
8132 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8133 | if test "$am_cv_func_iconv" != yes; then |
8134 | am_save_LIBS="$LIBS" | |
8135 | LIBS="$LIBS $LIBICONV" | |
1b1fe467 | 8136 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8137 | /* end confdefs.h. */ |
5e13499c CR |
8138 | #include <stdlib.h> |
8139 | #include <iconv.h> | |
8140 | int | |
8141 | main () | |
8142 | { | |
8143 | iconv_t cd = iconv_open("",""); | |
8144 | iconv(cd,NULL,NULL,NULL,NULL); | |
8145 | iconv_close(cd); | |
8146 | ; | |
8147 | return 0; | |
8148 | } | |
8149 | _ACEOF | |
1b1fe467 | 8150 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8151 | am_cv_lib_iconv=yes |
8152 | am_cv_func_iconv=yes | |
5e13499c | 8153 | fi |
1b1fe467 CR |
8154 | rm -f core conftest.err conftest.$ac_objext \ |
8155 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8156 | LIBS="$am_save_LIBS" |
8157 | fi | |
8158 | ||
8159 | fi | |
1b1fe467 | 8160 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 |
dd4f3dd8 | 8161 | $as_echo "$am_cv_func_iconv" >&6; } |
5e13499c CR |
8162 | if test "$am_cv_func_iconv" = yes; then |
8163 | ||
1b1fe467 | 8164 | $as_echo "#define HAVE_ICONV 1" >>confdefs.h |
5e13499c CR |
8165 | |
8166 | fi | |
8167 | if test "$am_cv_lib_iconv" = yes; then | |
1b1fe467 | 8168 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 |
dd4f3dd8 | 8169 | $as_echo_n "checking how to link with libiconv... " >&6; } |
1b1fe467 | 8170 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 |
dd4f3dd8 | 8171 | $as_echo "$LIBICONV" >&6; } |
5e13499c CR |
8172 | else |
8173 | CPPFLAGS="$am_save_CPPFLAGS" | |
8174 | LIBICONV= | |
8175 | LTLIBICONV= | |
8176 | fi | |
8177 | ||
a82a04b3 CR |
8178 | |
8179 | ||
5e13499c | 8180 | if test "$am_cv_func_iconv" = yes; then |
1b1fe467 | 8181 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5 |
dd4f3dd8 | 8182 | $as_echo_n "checking for iconv declaration... " >&6; } |
1b1fe467 | 8183 | if ${am_cv_proto_iconv+:} false; then : |
dd4f3dd8 | 8184 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8185 | else |
8186 | ||
1b1fe467 | 8187 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8188 | /* end confdefs.h. */ |
5e13499c CR |
8189 | |
8190 | #include <stdlib.h> | |
8191 | #include <iconv.h> | |
8192 | extern | |
8193 | #ifdef __cplusplus | |
8194 | "C" | |
8195 | #endif | |
8196 | #if defined(__STDC__) || defined(__cplusplus) | |
8197 | size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); | |
8198 | #else | |
8199 | size_t iconv(); | |
8200 | #endif | |
8201 | ||
8202 | int | |
8203 | main () | |
8204 | { | |
8205 | ||
8206 | ; | |
8207 | return 0; | |
8208 | } | |
8209 | _ACEOF | |
1b1fe467 | 8210 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
8211 | am_cv_proto_iconv_arg1="" |
8212 | else | |
1b1fe467 | 8213 | am_cv_proto_iconv_arg1="const" |
5e13499c | 8214 | fi |
b709b946 | 8215 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
8216 | 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);" |
8217 | fi | |
8218 | ||
8219 | am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` | |
1b1fe467 | 8220 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:- |
5e13499c | 8221 | }$am_cv_proto_iconv" >&5 |
dd4f3dd8 | 8222 | $as_echo "${ac_t:- |
b709b946 | 8223 | }$am_cv_proto_iconv" >&6; } |
5e13499c | 8224 | |
a82a04b3 | 8225 | cat >>confdefs.h <<_ACEOF |
5e13499c | 8226 | #define ICONV_CONST $am_cv_proto_iconv_arg1 |
a82a04b3 | 8227 | _ACEOF |
5e13499c CR |
8228 | |
8229 | fi | |
8230 | ||
a82a04b3 | 8231 | |
1b1fe467 | 8232 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
dd4f3dd8 | 8233 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } |
1b1fe467 | 8234 | if ${am_cv_langinfo_codeset+:} false; then : |
dd4f3dd8 | 8235 | $as_echo_n "(cached) " >&6 |
5e13499c | 8236 | else |
1b1fe467 | 8237 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8238 | /* end confdefs.h. */ |
5e13499c CR |
8239 | #include <langinfo.h> |
8240 | int | |
8241 | main () | |
8242 | { | |
8243 | char* cs = nl_langinfo(CODESET); | |
8244 | ; | |
8245 | return 0; | |
8246 | } | |
8247 | _ACEOF | |
1b1fe467 | 8248 | if ac_fn_c_try_link "$LINENO"; then : |
abe2eb5b | 8249 | am_cv_langinfo_codeset=yes |
5e13499c | 8250 | else |
1b1fe467 | 8251 | am_cv_langinfo_codeset=no |
5e13499c | 8252 | fi |
1b1fe467 CR |
8253 | rm -f core conftest.err conftest.$ac_objext \ |
8254 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8255 | |
8256 | fi | |
1b1fe467 | 8257 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5 |
dd4f3dd8 | 8258 | $as_echo "$am_cv_langinfo_codeset" >&6; } |
5e13499c CR |
8259 | if test $am_cv_langinfo_codeset = yes; then |
8260 | ||
1b1fe467 | 8261 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h |
5e13499c CR |
8262 | |
8263 | fi | |
8264 | ||
8265 | if test $ac_cv_header_locale_h = yes; then | |
8266 | ||
1b1fe467 | 8267 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 |
dd4f3dd8 | 8268 | $as_echo_n "checking for LC_MESSAGES... " >&6; } |
1b1fe467 | 8269 | if ${am_cv_val_LC_MESSAGES+:} false; then : |
dd4f3dd8 | 8270 | $as_echo_n "(cached) " >&6 |
5e13499c | 8271 | else |
1b1fe467 | 8272 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8273 | /* end confdefs.h. */ |
5e13499c CR |
8274 | #include <locale.h> |
8275 | int | |
8276 | main () | |
8277 | { | |
8278 | return LC_MESSAGES | |
8279 | ; | |
8280 | return 0; | |
8281 | } | |
8282 | _ACEOF | |
1b1fe467 | 8283 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8284 | am_cv_val_LC_MESSAGES=yes |
8285 | else | |
1b1fe467 | 8286 | am_cv_val_LC_MESSAGES=no |
5e13499c | 8287 | fi |
1b1fe467 CR |
8288 | rm -f core conftest.err conftest.$ac_objext \ |
8289 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 8290 | fi |
1b1fe467 | 8291 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5 |
dd4f3dd8 | 8292 | $as_echo "$am_cv_val_LC_MESSAGES" >&6; } |
5e13499c CR |
8293 | if test $am_cv_val_LC_MESSAGES = yes; then |
8294 | ||
1b1fe467 | 8295 | $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h |
5e13499c CR |
8296 | |
8297 | fi | |
8298 | ||
8299 | fi | |
8300 | ||
8301 | for ac_prog in bison | |
8302 | do | |
8303 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
8304 | set dummy $ac_prog; ac_word=$2 | |
1b1fe467 | 8305 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 8306 | $as_echo_n "checking for $ac_word... " >&6; } |
1b1fe467 | 8307 | if ${ac_cv_prog_INTLBISON+:} false; then : |
dd4f3dd8 | 8308 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8309 | else |
8310 | if test -n "$INTLBISON"; then | |
8311 | ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test. | |
8312 | else | |
a82a04b3 CR |
8313 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
8314 | for as_dir in $PATH | |
8315 | do | |
8316 | IFS=$as_save_IFS | |
8317 | test -z "$as_dir" && as_dir=. | |
1b1fe467 | 8318 | for ac_exec_ext in '' $ac_executable_extensions; do |
0ee50808 | 8319 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
a82a04b3 | 8320 | ac_cv_prog_INTLBISON="$ac_prog" |
1b1fe467 | 8321 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
8322 | break 2 |
8323 | fi | |
8324 | done | |
1b1fe467 | 8325 | done |
b709b946 | 8326 | IFS=$as_save_IFS |
5e13499c CR |
8327 | |
8328 | fi | |
8329 | fi | |
8330 | INTLBISON=$ac_cv_prog_INTLBISON | |
8331 | if test -n "$INTLBISON"; then | |
1b1fe467 | 8332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INTLBISON" >&5 |
dd4f3dd8 | 8333 | $as_echo "$INTLBISON" >&6; } |
5e13499c | 8334 | else |
1b1fe467 | 8335 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 8336 | $as_echo "no" >&6; } |
5e13499c CR |
8337 | fi |
8338 | ||
b709b946 | 8339 | |
5e13499c CR |
8340 | test -n "$INTLBISON" && break |
8341 | done | |
8342 | ||
8343 | if test -z "$INTLBISON"; then | |
8344 | ac_verc_fail=yes | |
8345 | else | |
1b1fe467 | 8346 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of bison" >&5 |
dd4f3dd8 | 8347 | $as_echo_n "checking version of bison... " >&6; } |
e624d0f7 CR |
8348 | ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` |
8349 | case $ac_prog_version in | |
8350 | '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; | |
8351 | 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) | |
8352 | ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; | |
8353 | *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; | |
8354 | esac | |
1b1fe467 | 8355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5 |
dd4f3dd8 | 8356 | $as_echo "$ac_prog_version" >&6; } |
e624d0f7 CR |
8357 | fi |
8358 | if test $ac_verc_fail = yes; then | |
8359 | INTLBISON=: | |
8360 | fi | |
545f34cf | 8361 | |
a82a04b3 CR |
8362 | |
8363 | ||
8364 | ||
8365 | ||
8366 | ||
8367 | ||
8368 | ||
8369 | ||
8370 | ||
8371 | ||
8372 | ||
8373 | ||
8374 | ||
8375 | ||
8376 | ||
1b1fe467 | 8377 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
dd4f3dd8 | 8378 | $as_echo_n "checking whether NLS is requested... " >&6; } |
b709b946 | 8379 | # Check whether --enable-nls was given. |
1b1fe467 | 8380 | if test "${enable_nls+set}" = set; then : |
b709b946 | 8381 | enableval=$enable_nls; USE_NLS=$enableval |
5e13499c CR |
8382 | else |
8383 | USE_NLS=yes | |
b709b946 CR |
8384 | fi |
8385 | ||
1b1fe467 | 8386 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
dd4f3dd8 | 8387 | $as_echo "$USE_NLS" >&6; } |
5e13499c | 8388 | |
a82a04b3 CR |
8389 | |
8390 | ||
8391 | ||
5e13499c CR |
8392 | BUILD_INCLUDED_LIBINTL=no |
8393 | USE_INCLUDED_LIBINTL=no | |
8394 | ||
8395 | LIBINTL= | |
8396 | LTLIBINTL= | |
8397 | POSUB= | |
8398 | ||
8399 | if test "$USE_NLS" = "yes"; then | |
8400 | gt_use_preinstalled_gnugettext=no | |
8401 | ||
1b1fe467 | 8402 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether included gettext is requested" >&5 |
dd4f3dd8 | 8403 | $as_echo_n "checking whether included gettext is requested... " >&6; } |
5e13499c | 8404 | |
b709b946 | 8405 | # Check whether --with-included-gettext was given. |
1b1fe467 | 8406 | if test "${with_included_gettext+set}" = set; then : |
b709b946 | 8407 | withval=$with_included_gettext; nls_cv_force_use_gnu_gettext=$withval |
5e13499c CR |
8408 | else |
8409 | nls_cv_force_use_gnu_gettext=no | |
b709b946 CR |
8410 | fi |
8411 | ||
1b1fe467 | 8412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $nls_cv_force_use_gnu_gettext" >&5 |
dd4f3dd8 | 8413 | $as_echo "$nls_cv_force_use_gnu_gettext" >&6; } |
5e13499c CR |
8414 | |
8415 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
8416 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
8417 | ||
a82a04b3 CR |
8418 | |
8419 | ||
8420 | ||
8421 | ||
8422 | ||
1b1fe467 | 8423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5 |
dd4f3dd8 | 8424 | $as_echo_n "checking for GNU gettext in libc... " >&6; } |
1b1fe467 | 8425 | if ${gt_cv_func_gnugettext2_libc+:} false; then : |
dd4f3dd8 | 8426 | $as_echo_n "(cached) " >&6 |
5e13499c | 8427 | else |
1b1fe467 | 8428 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8429 | /* end confdefs.h. */ |
5e13499c CR |
8430 | #include <libintl.h> |
8431 | extern int _nl_msg_cat_cntr; | |
8432 | extern int *_nl_domain_bindings; | |
8433 | int | |
8434 | main () | |
8435 | { | |
8436 | bindtextdomain ("", ""); | |
8437 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_domain_bindings | |
8438 | ; | |
8439 | return 0; | |
8440 | } | |
8441 | _ACEOF | |
1b1fe467 | 8442 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8443 | gt_cv_func_gnugettext2_libc=yes |
8444 | else | |
1b1fe467 | 8445 | gt_cv_func_gnugettext2_libc=no |
5e13499c | 8446 | fi |
1b1fe467 CR |
8447 | rm -f core conftest.err conftest.$ac_objext \ |
8448 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 8449 | fi |
1b1fe467 | 8450 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libc" >&5 |
dd4f3dd8 | 8451 | $as_echo "$gt_cv_func_gnugettext2_libc" >&6; } |
5e13499c CR |
8452 | |
8453 | if test "$gt_cv_func_gnugettext2_libc" != "yes"; then | |
8454 | ||
a82a04b3 CR |
8455 | |
8456 | ||
5e13499c CR |
8457 | use_additional=yes |
8458 | ||
8459 | acl_save_prefix="$prefix" | |
8460 | prefix="$acl_final_prefix" | |
8461 | acl_save_exec_prefix="$exec_prefix" | |
8462 | exec_prefix="$acl_final_exec_prefix" | |
8463 | ||
8464 | eval additional_includedir=\"$includedir\" | |
8465 | eval additional_libdir=\"$libdir\" | |
8466 | ||
8467 | exec_prefix="$acl_save_exec_prefix" | |
8468 | prefix="$acl_save_prefix" | |
8469 | ||
a82a04b3 | 8470 | |
b709b946 | 8471 | # Check whether --with-libintl-prefix was given. |
1b1fe467 | 8472 | if test "${with_libintl_prefix+set}" = set; then : |
b709b946 | 8473 | withval=$with_libintl_prefix; |
5e13499c CR |
8474 | if test "X$withval" = "Xno"; then |
8475 | use_additional=no | |
8476 | else | |
8477 | if test "X$withval" = "X"; then | |
8478 | ||
8479 | acl_save_prefix="$prefix" | |
8480 | prefix="$acl_final_prefix" | |
8481 | acl_save_exec_prefix="$exec_prefix" | |
8482 | exec_prefix="$acl_final_exec_prefix" | |
8483 | ||
8484 | eval additional_includedir=\"$includedir\" | |
8485 | eval additional_libdir=\"$libdir\" | |
8486 | ||
8487 | exec_prefix="$acl_save_exec_prefix" | |
8488 | prefix="$acl_save_prefix" | |
8489 | ||
8490 | else | |
8491 | additional_includedir="$withval/include" | |
8492 | additional_libdir="$withval/lib" | |
8493 | fi | |
8494 | fi | |
8495 | ||
b709b946 CR |
8496 | fi |
8497 | ||
5e13499c CR |
8498 | LIBINTL= |
8499 | LTLIBINTL= | |
8500 | INCINTL= | |
8501 | rpathdirs= | |
8502 | ltrpathdirs= | |
8503 | names_already_handled= | |
8504 | names_next_round='intl ' | |
8505 | while test -n "$names_next_round"; do | |
8506 | names_this_round="$names_next_round" | |
8507 | names_next_round= | |
8508 | for name in $names_this_round; do | |
8509 | already_handled= | |
8510 | for n in $names_already_handled; do | |
8511 | if test "$n" = "$name"; then | |
8512 | already_handled=yes | |
8513 | break | |
8514 | fi | |
8515 | done | |
8516 | if test -z "$already_handled"; then | |
8517 | names_already_handled="$names_already_handled $name" | |
8518 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
8519 | eval value=\"\$HAVE_LIB$uppername\" | |
8520 | if test -n "$value"; then | |
8521 | if test "$value" = yes; then | |
8522 | eval value=\"\$LIB$uppername\" | |
8523 | test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" | |
8524 | eval value=\"\$LTLIB$uppername\" | |
8525 | test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" | |
8526 | else | |
8527 | : | |
8528 | fi | |
8529 | else | |
8530 | found_dir= | |
8531 | found_la= | |
8532 | found_so= | |
8533 | found_a= | |
8534 | if test $use_additional = yes; then | |
f4f5e1c2 | 8535 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
5e13499c CR |
8536 | found_dir="$additional_libdir" |
8537 | found_so="$additional_libdir/lib$name.$shlibext" | |
8538 | if test -f "$additional_libdir/lib$name.la"; then | |
8539 | found_la="$additional_libdir/lib$name.la" | |
8540 | fi | |
8541 | else | |
8542 | if test -f "$additional_libdir/lib$name.$libext"; then | |
8543 | found_dir="$additional_libdir" | |
8544 | found_a="$additional_libdir/lib$name.$libext" | |
8545 | if test -f "$additional_libdir/lib$name.la"; then | |
8546 | found_la="$additional_libdir/lib$name.la" | |
8547 | fi | |
8548 | fi | |
8549 | fi | |
8550 | fi | |
8551 | if test "X$found_dir" = "X"; then | |
8552 | for x in $LDFLAGS $LTLIBINTL; do | |
8553 | ||
8554 | acl_save_prefix="$prefix" | |
8555 | prefix="$acl_final_prefix" | |
8556 | acl_save_exec_prefix="$exec_prefix" | |
8557 | exec_prefix="$acl_final_exec_prefix" | |
8558 | eval x=\"$x\" | |
8559 | exec_prefix="$acl_save_exec_prefix" | |
8560 | prefix="$acl_save_prefix" | |
8561 | ||
8562 | case "$x" in | |
8563 | -L*) | |
8564 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
f4f5e1c2 | 8565 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
5e13499c CR |
8566 | found_dir="$dir" |
8567 | found_so="$dir/lib$name.$shlibext" | |
8568 | if test -f "$dir/lib$name.la"; then | |
8569 | found_la="$dir/lib$name.la" | |
8570 | fi | |
8571 | else | |
8572 | if test -f "$dir/lib$name.$libext"; then | |
8573 | found_dir="$dir" | |
8574 | found_a="$dir/lib$name.$libext" | |
8575 | if test -f "$dir/lib$name.la"; then | |
8576 | found_la="$dir/lib$name.la" | |
8577 | fi | |
8578 | fi | |
8579 | fi | |
8580 | ;; | |
8581 | esac | |
8582 | if test "X$found_dir" != "X"; then | |
8583 | break | |
8584 | fi | |
8585 | done | |
8586 | fi | |
8587 | if test "X$found_dir" != "X"; then | |
8588 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" | |
8589 | if test "X$found_so" != "X"; then | |
8590 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
8591 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8592 | else | |
8593 | haveit= | |
8594 | for x in $ltrpathdirs; do | |
8595 | if test "X$x" = "X$found_dir"; then | |
8596 | haveit=yes | |
8597 | break | |
8598 | fi | |
8599 | done | |
8600 | if test -z "$haveit"; then | |
8601 | ltrpathdirs="$ltrpathdirs $found_dir" | |
8602 | fi | |
8603 | if test "$hardcode_direct" = yes; then | |
8604 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8605 | else | |
8606 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
8607 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8608 | haveit= | |
8609 | for x in $rpathdirs; do | |
8610 | if test "X$x" = "X$found_dir"; then | |
8611 | haveit=yes | |
8612 | break | |
8613 | fi | |
8614 | done | |
8615 | if test -z "$haveit"; then | |
8616 | rpathdirs="$rpathdirs $found_dir" | |
8617 | fi | |
8618 | else | |
8619 | haveit= | |
8620 | for x in $LDFLAGS $LIBINTL; do | |
8621 | ||
8622 | acl_save_prefix="$prefix" | |
8623 | prefix="$acl_final_prefix" | |
8624 | acl_save_exec_prefix="$exec_prefix" | |
8625 | exec_prefix="$acl_final_exec_prefix" | |
8626 | eval x=\"$x\" | |
8627 | exec_prefix="$acl_save_exec_prefix" | |
8628 | prefix="$acl_save_prefix" | |
8629 | ||
8630 | if test "X$x" = "X-L$found_dir"; then | |
8631 | haveit=yes | |
8632 | break | |
8633 | fi | |
8634 | done | |
8635 | if test -z "$haveit"; then | |
8636 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" | |
8637 | fi | |
8638 | if test "$hardcode_minus_L" != no; then | |
8639 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8640 | else | |
8641 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8642 | fi | |
8643 | fi | |
8644 | fi | |
8645 | fi | |
8646 | else | |
8647 | if test "X$found_a" != "X"; then | |
8648 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" | |
8649 | else | |
8650 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" | |
8651 | fi | |
8652 | fi | |
8653 | additional_includedir= | |
8654 | case "$found_dir" in | |
8655 | */lib | */lib/) | |
8656 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
8657 | additional_includedir="$basedir/include" | |
8658 | ;; | |
8659 | esac | |
8660 | if test "X$additional_includedir" != "X"; then | |
8661 | if test "X$additional_includedir" != "X/usr/include"; then | |
8662 | haveit= | |
8663 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
8664 | if test -n "$GCC"; then | |
8665 | case $host_os in | |
8666 | linux*) haveit=yes;; | |
8667 | esac | |
8668 | fi | |
8669 | fi | |
8670 | if test -z "$haveit"; then | |
8671 | for x in $CPPFLAGS $INCINTL; do | |
8672 | ||
8673 | acl_save_prefix="$prefix" | |
8674 | prefix="$acl_final_prefix" | |
8675 | acl_save_exec_prefix="$exec_prefix" | |
8676 | exec_prefix="$acl_final_exec_prefix" | |
8677 | eval x=\"$x\" | |
8678 | exec_prefix="$acl_save_exec_prefix" | |
8679 | prefix="$acl_save_prefix" | |
8680 | ||
8681 | if test "X$x" = "X-I$additional_includedir"; then | |
8682 | haveit=yes | |
8683 | break | |
8684 | fi | |
8685 | done | |
8686 | if test -z "$haveit"; then | |
8687 | if test -d "$additional_includedir"; then | |
8688 | INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" | |
8689 | fi | |
8690 | fi | |
8691 | fi | |
8692 | fi | |
8693 | fi | |
8694 | if test -n "$found_la"; then | |
8695 | save_libdir="$libdir" | |
8696 | case "$found_la" in | |
8697 | */* | *\\*) . "$found_la" ;; | |
8698 | *) . "./$found_la" ;; | |
8699 | esac | |
8700 | libdir="$save_libdir" | |
8701 | for dep in $dependency_libs; do | |
8702 | case "$dep" in | |
8703 | -L*) | |
8704 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
8705 | if test "X$additional_libdir" != "X/usr/lib"; then | |
8706 | haveit= | |
8707 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
8708 | if test -n "$GCC"; then | |
8709 | case $host_os in | |
8710 | linux*) haveit=yes;; | |
8711 | esac | |
8712 | fi | |
8713 | fi | |
8714 | if test -z "$haveit"; then | |
8715 | haveit= | |
8716 | for x in $LDFLAGS $LIBINTL; do | |
8717 | ||
8718 | acl_save_prefix="$prefix" | |
8719 | prefix="$acl_final_prefix" | |
8720 | acl_save_exec_prefix="$exec_prefix" | |
8721 | exec_prefix="$acl_final_exec_prefix" | |
8722 | eval x=\"$x\" | |
8723 | exec_prefix="$acl_save_exec_prefix" | |
8724 | prefix="$acl_save_prefix" | |
8725 | ||
8726 | if test "X$x" = "X-L$additional_libdir"; then | |
8727 | haveit=yes | |
8728 | break | |
8729 | fi | |
8730 | done | |
8731 | if test -z "$haveit"; then | |
8732 | if test -d "$additional_libdir"; then | |
8733 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" | |
8734 | fi | |
8735 | fi | |
8736 | haveit= | |
8737 | for x in $LDFLAGS $LTLIBINTL; do | |
8738 | ||
8739 | acl_save_prefix="$prefix" | |
8740 | prefix="$acl_final_prefix" | |
8741 | acl_save_exec_prefix="$exec_prefix" | |
8742 | exec_prefix="$acl_final_exec_prefix" | |
8743 | eval x=\"$x\" | |
8744 | exec_prefix="$acl_save_exec_prefix" | |
8745 | prefix="$acl_save_prefix" | |
8746 | ||
8747 | if test "X$x" = "X-L$additional_libdir"; then | |
8748 | haveit=yes | |
8749 | break | |
8750 | fi | |
8751 | done | |
8752 | if test -z "$haveit"; then | |
8753 | if test -d "$additional_libdir"; then | |
8754 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" | |
8755 | fi | |
8756 | fi | |
8757 | fi | |
8758 | fi | |
8759 | ;; | |
8760 | -R*) | |
8761 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
8762 | if test "$enable_rpath" != no; then | |
8763 | haveit= | |
8764 | for x in $rpathdirs; do | |
8765 | if test "X$x" = "X$dir"; then | |
8766 | haveit=yes | |
8767 | break | |
8768 | fi | |
8769 | done | |
8770 | if test -z "$haveit"; then | |
8771 | rpathdirs="$rpathdirs $dir" | |
8772 | fi | |
8773 | haveit= | |
8774 | for x in $ltrpathdirs; do | |
8775 | if test "X$x" = "X$dir"; then | |
8776 | haveit=yes | |
8777 | break | |
8778 | fi | |
8779 | done | |
8780 | if test -z "$haveit"; then | |
8781 | ltrpathdirs="$ltrpathdirs $dir" | |
8782 | fi | |
8783 | fi | |
8784 | ;; | |
8785 | -l*) | |
8786 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
8787 | ;; | |
7f947b68 CR |
8788 | *.la) |
8789 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
8790 | ;; | |
8791 | *) | |
8792 | LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" | |
8793 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" | |
8794 | ;; | |
8795 | esac | |
8796 | done | |
8797 | fi | |
8798 | else | |
8799 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8800 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" | |
8801 | fi | |
8802 | fi | |
8803 | fi | |
8804 | done | |
8805 | done | |
8806 | if test "X$rpathdirs" != "X"; then | |
8807 | if test -n "$hardcode_libdir_separator"; then | |
8808 | alldirs= | |
8809 | for found_dir in $rpathdirs; do | |
8810 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
8811 | done | |
8812 | acl_save_libdir="$libdir" | |
8813 | libdir="$alldirs" | |
8814 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8815 | libdir="$acl_save_libdir" | |
8816 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8817 | else | |
8818 | for found_dir in $rpathdirs; do | |
8819 | acl_save_libdir="$libdir" | |
1b1fe467 CR |
8820 | libdir="$found_dir" |
8821 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8822 | libdir="$acl_save_libdir" | |
8823 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8824 | done | |
8825 | fi | |
8826 | fi | |
8827 | if test "X$ltrpathdirs" != "X"; then | |
8828 | for found_dir in $ltrpathdirs; do | |
8829 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" | |
8830 | done | |
8831 | fi | |
7f947b68 | 8832 | |
1b1fe467 CR |
8833 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5 |
8834 | $as_echo_n "checking for GNU gettext in libintl... " >&6; } | |
8835 | if ${gt_cv_func_gnugettext2_libintl+:} false; then : | |
7175a77f CR |
8836 | $as_echo_n "(cached) " >&6 |
8837 | else | |
1b1fe467 CR |
8838 | gt_save_CPPFLAGS="$CPPFLAGS" |
8839 | CPPFLAGS="$CPPFLAGS $INCINTL" | |
8840 | gt_save_LIBS="$LIBS" | |
8841 | LIBS="$LIBS $LIBINTL" | |
8842 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 8843 | /* end confdefs.h. */ |
1b1fe467 CR |
8844 | #include <libintl.h> |
8845 | extern int _nl_msg_cat_cntr; | |
8846 | extern | |
8847 | #ifdef __cplusplus | |
8848 | "C" | |
8849 | #endif | |
8850 | const char *_nl_expand_alias (); | |
7175a77f CR |
8851 | int |
8852 | main () | |
8853 | { | |
1b1fe467 CR |
8854 | bindtextdomain ("", ""); |
8855 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
7175a77f CR |
8856 | ; |
8857 | return 0; | |
8858 | } | |
8859 | _ACEOF | |
1b1fe467 CR |
8860 | if ac_fn_c_try_link "$LINENO"; then : |
8861 | gt_cv_func_gnugettext2_libintl=yes | |
7175a77f | 8862 | else |
1b1fe467 | 8863 | gt_cv_func_gnugettext2_libintl=no |
7175a77f | 8864 | fi |
1b1fe467 CR |
8865 | rm -f core conftest.err conftest.$ac_objext \ |
8866 | conftest$ac_exeext conftest.$ac_ext | |
8867 | if test "$gt_cv_func_gnugettext2_libintl" != yes && test -n "$LIBICONV"; then | |
8868 | LIBS="$LIBS $LIBICONV" | |
8869 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7610e0c5 | 8870 | /* end confdefs.h. */ |
1b1fe467 CR |
8871 | #include <libintl.h> |
8872 | extern int _nl_msg_cat_cntr; | |
8873 | extern | |
8874 | #ifdef __cplusplus | |
8875 | "C" | |
8876 | #endif | |
8877 | const char *_nl_expand_alias (); | |
abe2eb5b CR |
8878 | int |
8879 | main () | |
2dead0c4 | 8880 | { |
1b1fe467 CR |
8881 | bindtextdomain ("", ""); |
8882 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
abe2eb5b CR |
8883 | ; |
8884 | return 0; | |
2dead0c4 | 8885 | } |
abe2eb5b | 8886 | _ACEOF |
1b1fe467 CR |
8887 | if ac_fn_c_try_link "$LINENO"; then : |
8888 | LIBINTL="$LIBINTL $LIBICONV" | |
8889 | LTLIBINTL="$LTLIBINTL $LTLIBICONV" | |
8890 | gt_cv_func_gnugettext2_libintl=yes | |
7175a77f | 8891 | |
7f947b68 | 8892 | fi |
1b1fe467 CR |
8893 | rm -f core conftest.err conftest.$ac_objext \ |
8894 | conftest$ac_exeext conftest.$ac_ext | |
8895 | fi | |
8896 | CPPFLAGS="$gt_save_CPPFLAGS" | |
8897 | LIBS="$gt_save_LIBS" | |
7f947b68 | 8898 | fi |
1b1fe467 CR |
8899 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libintl" >&5 |
8900 | $as_echo "$gt_cv_func_gnugettext2_libintl" >&6; } | |
8901 | fi | |
7175a77f | 8902 | |
1b1fe467 CR |
8903 | if test "$gt_cv_func_gnugettext2_libc" = "yes" \ |
8904 | || { test "$gt_cv_func_gnugettext2_libintl" = "yes" \ | |
8905 | && test "$PACKAGE" != gettext-runtime \ | |
8906 | && test "$PACKAGE" != gettext-tools; }; then | |
8907 | gt_use_preinstalled_gnugettext=yes | |
8908 | else | |
8909 | LIBINTL= | |
8910 | LTLIBINTL= | |
8911 | INCINTL= | |
8912 | fi | |
abe2eb5b | 8913 | |
2dead0c4 | 8914 | |
1b1fe467 CR |
8915 | if test "$gt_use_preinstalled_gnugettext" != "yes"; then |
8916 | nls_cv_use_gnu_gettext=yes | |
8917 | fi | |
8918 | fi | |
7f947b68 | 8919 | |
1b1fe467 CR |
8920 | if test "$nls_cv_use_gnu_gettext" = "yes"; then |
8921 | BUILD_INCLUDED_LIBINTL=yes | |
8922 | USE_INCLUDED_LIBINTL=yes | |
8923 | LIBINTL="lib/intl/libintl.a $LIBICONV" | |
8924 | LTLIBINTL="lib/intl/libintl.a $LTLIBICONV" | |
8925 | LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` | |
8926 | fi | |
7175a77f | 8927 | |
1b1fe467 CR |
8928 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ |
8929 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8930 | CATOBJEXT=.gmo | |
8931 | fi | |
f73dda09 | 8932 | |
c920c360 | 8933 | |
1b1fe467 CR |
8934 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ |
8935 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8936 | ||
8937 | $as_echo "#define ENABLE_NLS 1" >>confdefs.h | |
8938 | ||
8939 | else | |
8940 | USE_NLS=no | |
8941 | fi | |
8942 | fi | |
8943 | ||
8944 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5 | |
8945 | $as_echo_n "checking whether to use NLS... " >&6; } | |
8946 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 | |
8947 | $as_echo "$USE_NLS" >&6; } | |
8948 | if test "$USE_NLS" = "yes"; then | |
8949 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5 | |
8950 | $as_echo_n "checking where the gettext function comes from... " >&6; } | |
8951 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then | |
8952 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8953 | gt_source="external libintl" | |
8954 | else | |
8955 | gt_source="libc" | |
8956 | fi | |
8957 | else | |
8958 | gt_source="included intl directory" | |
8959 | fi | |
8960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5 | |
8961 | $as_echo "$gt_source" >&6; } | |
8962 | fi | |
8963 | ||
8964 | if test "$USE_NLS" = "yes"; then | |
8965 | ||
8966 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then | |
8967 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8968 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5 | |
8969 | $as_echo_n "checking how to link with libintl... " >&6; } | |
8970 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5 | |
8971 | $as_echo "$LIBINTL" >&6; } | |
8972 | ||
8973 | for element in $INCINTL; do | |
8974 | haveit= | |
8975 | for x in $CPPFLAGS; do | |
8976 | ||
8977 | acl_save_prefix="$prefix" | |
8978 | prefix="$acl_final_prefix" | |
8979 | acl_save_exec_prefix="$exec_prefix" | |
8980 | exec_prefix="$acl_final_exec_prefix" | |
8981 | eval x=\"$x\" | |
8982 | exec_prefix="$acl_save_exec_prefix" | |
8983 | prefix="$acl_save_prefix" | |
8984 | ||
8985 | if test "X$x" = "X$element"; then | |
8986 | haveit=yes | |
8987 | break | |
8988 | fi | |
8989 | done | |
8990 | if test -z "$haveit"; then | |
8991 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8992 | fi | |
8993 | done | |
8994 | ||
8995 | fi | |
8996 | ||
2dead0c4 | 8997 | |
1b1fe467 | 8998 | $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h |
b709b946 | 8999 | |
2dead0c4 | 9000 | |
1b1fe467 | 9001 | $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h |
7f947b68 | 9002 | |
1b1fe467 | 9003 | fi |
2dead0c4 | 9004 | |
1b1fe467 CR |
9005 | POSUB=po |
9006 | fi | |
2dead0c4 | 9007 | |
7f947b68 | 9008 | |
1b1fe467 CR |
9009 | if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then |
9010 | BUILD_INCLUDED_LIBINTL=yes | |
9011 | fi | |
7f947b68 | 9012 | |
7f947b68 | 9013 | |
7f947b68 | 9014 | |
1b1fe467 CR |
9015 | |
9016 | ||
9017 | nls_cv_header_intl= | |
9018 | nls_cv_header_libgt= | |
9019 | ||
9020 | DATADIRNAME=share | |
9021 | ||
9022 | ||
9023 | INSTOBJEXT=.mo | |
9024 | ||
9025 | ||
9026 | GENCAT=gencat | |
9027 | ||
9028 | ||
9029 | if test "$USE_INCLUDED_LIBINTL" = yes; then | |
9030 | INTLOBJS="\$(GETTOBJS)" | |
9031 | fi | |
9032 | ||
9033 | ||
9034 | INTL_LIBTOOL_SUFFIX_PREFIX= | |
9035 | ||
9036 | ||
9037 | ||
9038 | INTLLIBS="$LIBINTL" | |
9039 | ||
9040 | ||
9041 | ||
9042 | ||
9043 | ||
9044 | ||
9045 | ||
9046 | ac_header_dirent=no | |
9047 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do | |
9048 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` | |
9049 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 | |
9050 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } | |
9051 | if eval \${$as_ac_Header+:} false; then : | |
7175a77f CR |
9052 | $as_echo_n "(cached) " >&6 |
9053 | else | |
1b1fe467 | 9054 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 9055 | /* end confdefs.h. */ |
1b1fe467 CR |
9056 | #include <sys/types.h> |
9057 | #include <$ac_hdr> | |
7f947b68 | 9058 | |
7175a77f CR |
9059 | int |
9060 | main () | |
9061 | { | |
1b1fe467 CR |
9062 | if ((DIR *) 0) |
9063 | return 0; | |
7175a77f CR |
9064 | ; |
9065 | return 0; | |
9066 | } | |
9067 | _ACEOF | |
1b1fe467 CR |
9068 | if ac_fn_c_try_compile "$LINENO"; then : |
9069 | eval "$as_ac_Header=yes" | |
7175a77f | 9070 | else |
1b1fe467 CR |
9071 | eval "$as_ac_Header=no" |
9072 | fi | |
9073 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9074 | fi | |
9075 | eval ac_res=\$$as_ac_Header | |
9076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
9077 | $as_echo "$ac_res" >&6; } | |
9078 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9079 | cat >>confdefs.h <<_ACEOF | |
9080 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 | |
9081 | _ACEOF | |
7f947b68 | 9082 | |
1b1fe467 | 9083 | ac_header_dirent=$ac_hdr; break |
7f947b68 CR |
9084 | fi |
9085 | ||
1b1fe467 CR |
9086 | done |
9087 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. | |
9088 | if test $ac_header_dirent = dirent.h; then | |
9089 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
9090 | $as_echo_n "checking for library containing opendir... " >&6; } | |
9091 | if ${ac_cv_search_opendir+:} false; then : | |
9092 | $as_echo_n "(cached) " >&6 | |
7175a77f | 9093 | else |
1b1fe467 CR |
9094 | ac_func_search_save_LIBS=$LIBS |
9095 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 9096 | /* end confdefs.h. */ |
7f947b68 | 9097 | |
1b1fe467 CR |
9098 | /* Override any GCC internal prototype to avoid an error. |
9099 | Use char because int might match the return type of a GCC | |
9100 | builtin and then its argument prototype would still apply. */ | |
9101 | #ifdef __cplusplus | |
9102 | extern "C" | |
9103 | #endif | |
9104 | char opendir (); | |
abe2eb5b CR |
9105 | int |
9106 | main () | |
9107 | { | |
1b1fe467 | 9108 | return opendir (); |
abe2eb5b CR |
9109 | ; |
9110 | return 0; | |
9111 | } | |
71412226 | 9112 | _ACEOF |
1b1fe467 CR |
9113 | for ac_lib in '' dir; do |
9114 | if test -z "$ac_lib"; then | |
9115 | ac_res="none required" | |
9116 | else | |
9117 | ac_res=-l$ac_lib | |
9118 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9119 | fi | |
9120 | if ac_fn_c_try_link "$LINENO"; then : | |
9121 | ac_cv_search_opendir=$ac_res | |
7f947b68 | 9122 | fi |
1b1fe467 CR |
9123 | rm -f core conftest.err conftest.$ac_objext \ |
9124 | conftest$ac_exeext | |
9125 | if ${ac_cv_search_opendir+:} false; then : | |
9126 | break | |
9127 | fi | |
9128 | done | |
9129 | if ${ac_cv_search_opendir+:} false; then : | |
7f947b68 | 9130 | |
7175a77f | 9131 | else |
1b1fe467 CR |
9132 | ac_cv_search_opendir=no |
9133 | fi | |
9134 | rm conftest.$ac_ext | |
9135 | LIBS=$ac_func_search_save_LIBS | |
d166f048 | 9136 | fi |
1b1fe467 CR |
9137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 |
9138 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9139 | ac_res=$ac_cv_search_opendir | |
9140 | if test "$ac_res" != no; then : | |
9141 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
b709b946 | 9142 | |
7175a77f | 9143 | fi |
7f947b68 | 9144 | |
1b1fe467 CR |
9145 | else |
9146 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
9147 | $as_echo_n "checking for library containing opendir... " >&6; } | |
9148 | if ${ac_cv_search_opendir+:} false; then : | |
9149 | $as_echo_n "(cached) " >&6 | |
9150 | else | |
9151 | ac_func_search_save_LIBS=$LIBS | |
9152 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 9153 | /* end confdefs.h. */ |
1b1fe467 CR |
9154 | |
9155 | /* Override any GCC internal prototype to avoid an error. | |
9156 | Use char because int might match the return type of a GCC | |
9157 | builtin and then its argument prototype would still apply. */ | |
9158 | #ifdef __cplusplus | |
9159 | extern "C" | |
9160 | #endif | |
9161 | char opendir (); | |
abe2eb5b CR |
9162 | int |
9163 | main () | |
9164 | { | |
1b1fe467 | 9165 | return opendir (); |
abe2eb5b CR |
9166 | ; |
9167 | return 0; | |
9168 | } | |
2dead0c4 | 9169 | _ACEOF |
1b1fe467 CR |
9170 | for ac_lib in '' x; do |
9171 | if test -z "$ac_lib"; then | |
9172 | ac_res="none required" | |
9173 | else | |
9174 | ac_res=-l$ac_lib | |
9175 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9176 | fi | |
9177 | if ac_fn_c_try_link "$LINENO"; then : | |
9178 | ac_cv_search_opendir=$ac_res | |
9179 | fi | |
9180 | rm -f core conftest.err conftest.$ac_objext \ | |
9181 | conftest$ac_exeext | |
9182 | if ${ac_cv_search_opendir+:} false; then : | |
9183 | break | |
9184 | fi | |
9185 | done | |
9186 | if ${ac_cv_search_opendir+:} false; then : | |
9187 | ||
7f947b68 | 9188 | else |
1b1fe467 CR |
9189 | ac_cv_search_opendir=no |
9190 | fi | |
9191 | rm conftest.$ac_ext | |
9192 | LIBS=$ac_func_search_save_LIBS | |
9193 | fi | |
9194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 | |
9195 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9196 | ac_res=$ac_cv_search_opendir | |
9197 | if test "$ac_res" != no; then : | |
9198 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
7f947b68 | 9199 | |
7175a77f | 9200 | fi |
7f947b68 | 9201 | |
1b1fe467 CR |
9202 | fi |
9203 | ||
9204 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 | |
9205 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
9206 | if ${ac_cv_header_time+:} false; then : | |
9207 | $as_echo_n "(cached) " >&6 | |
7f947b68 | 9208 | else |
1b1fe467 | 9209 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7f947b68 | 9210 | /* end confdefs.h. */ |
1b1fe467 CR |
9211 | #include <sys/types.h> |
9212 | #include <sys/time.h> | |
9213 | #include <time.h> | |
9214 | ||
7175a77f CR |
9215 | int |
9216 | main () | |
9217 | { | |
1b1fe467 CR |
9218 | if ((struct tm *) 0) |
9219 | return 0; | |
7175a77f CR |
9220 | ; |
9221 | return 0; | |
9222 | } | |
7f947b68 | 9223 | _ACEOF |
1b1fe467 CR |
9224 | if ac_fn_c_try_compile "$LINENO"; then : |
9225 | ac_cv_header_time=yes | |
7f947b68 | 9226 | else |
1b1fe467 | 9227 | ac_cv_header_time=no |
7f947b68 | 9228 | fi |
1b1fe467 | 9229 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7175a77f | 9230 | fi |
1b1fe467 CR |
9231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
9232 | $as_echo "$ac_cv_header_time" >&6; } | |
9233 | if test $ac_cv_header_time = yes; then | |
9234 | ||
9235 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h | |
9236 | ||
7175a77f | 9237 | fi |
7175a77f CR |
9238 | |
9239 | ||
abe2eb5b | 9240 | |
1b1fe467 CR |
9241 | for ac_header in inttypes.h |
9242 | do : | |
9243 | ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default" | |
9244 | if test "x$ac_cv_header_inttypes_h" = xyes; then : | |
9245 | cat >>confdefs.h <<_ACEOF | |
9246 | #define HAVE_INTTYPES_H 1 | |
2dead0c4 | 9247 | _ACEOF |
c920c360 | 9248 | |
1b1fe467 | 9249 | fi |
d166f048 | 9250 | |
1b1fe467 CR |
9251 | done |
9252 | ||
9253 | ||
9254 | ||
9255 | for ac_header in unistd.h stdlib.h stdarg.h varargs.h limits.h string.h \ | |
9256 | memory.h locale.h termcap.h termio.h termios.h dlfcn.h \ | |
9257 | stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \ | |
9258 | regex.h syslog.h ulimit.h | |
9259 | do : | |
9260 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9261 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9262 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9263 | cat >>confdefs.h <<_ACEOF | |
9264 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7175a77f | 9265 | _ACEOF |
7f947b68 | 9266 | |
1b1fe467 CR |
9267 | fi |
9268 | ||
9269 | done | |
9270 | ||
48abf0fd | 9271 | for ac_header in sys/pte.h sys/stream.h sys/select.h sys/file.h sys/ioctl.h \ |
690150f9 | 9272 | sys/param.h sys/socket.h sys/stat.h \ |
1b1fe467 CR |
9273 | sys/time.h sys/times.h sys/types.h sys/wait.h |
9274 | do : | |
9275 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9276 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9277 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9278 | cat >>confdefs.h <<_ACEOF | |
9279 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7175a77f | 9280 | _ACEOF |
1b1fe467 CR |
9281 | |
9282 | fi | |
9283 | ||
9284 | done | |
9285 | ||
9286 | for ac_header in netinet/in.h arpa/inet.h | |
9287 | do : | |
9288 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9289 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9290 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9291 | cat >>confdefs.h <<_ACEOF | |
9292 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7175a77f | 9293 | _ACEOF |
1b1fe467 CR |
9294 | |
9295 | fi | |
9296 | ||
9297 | done | |
9298 | ||
9299 | ||
9300 | ac_fn_c_check_header_compile "$LINENO" "sys/ptem.h" "ac_cv_header_sys_ptem_h" " | |
9301 | #if HAVE_SYS_STREAM_H | |
9302 | # include <sys/stream.h> | |
9303 | #endif | |
9304 | ||
9305 | " | |
9306 | if test "x$ac_cv_header_sys_ptem_h" = xyes; then : | |
9307 | ||
9308 | fi | |
9309 | ||
9310 | ||
9311 | ||
690150f9 CR |
9312 | ac_fn_c_check_header_compile "$LINENO" "sys/resource.h" "ac_cv_header_sys_resource_h" " |
9313 | #if HAVE_SYS_TIME_H | |
9314 | # include <sys/time.h> | |
9315 | #endif | |
9316 | ||
9317 | " | |
9318 | if test "x$ac_cv_header_sys_resource_h" = xyes; then : | |
9319 | $as_echo "#define HAVE_SYS_RESOURCE_H 1" >>confdefs.h | |
9320 | ||
9321 | fi | |
9322 | ||
9323 | ||
9324 | ||
1b1fe467 CR |
9325 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works |
9326 | # for constant arguments. Useless! | |
9327 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 | |
9328 | $as_echo_n "checking for working alloca.h... " >&6; } | |
9329 | if ${ac_cv_working_alloca_h+:} false; then : | |
9330 | $as_echo_n "(cached) " >&6 | |
9331 | else | |
9332 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 9333 | /* end confdefs.h. */ |
1b1fe467 | 9334 | #include <alloca.h> |
abe2eb5b CR |
9335 | int |
9336 | main () | |
9337 | { | |
1b1fe467 CR |
9338 | char *p = (char *) alloca (2 * sizeof (int)); |
9339 | if (p) return 0; | |
7175a77f CR |
9340 | ; |
9341 | return 0; | |
abe2eb5b CR |
9342 | } |
9343 | _ACEOF | |
1b1fe467 CR |
9344 | if ac_fn_c_try_link "$LINENO"; then : |
9345 | ac_cv_working_alloca_h=yes | |
abe2eb5b | 9346 | else |
1b1fe467 CR |
9347 | ac_cv_working_alloca_h=no |
9348 | fi | |
9349 | rm -f core conftest.err conftest.$ac_objext \ | |
9350 | conftest$ac_exeext conftest.$ac_ext | |
9351 | fi | |
9352 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 | |
9353 | $as_echo "$ac_cv_working_alloca_h" >&6; } | |
9354 | if test $ac_cv_working_alloca_h = yes; then | |
9355 | ||
9356 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h | |
d166f048 JA |
9357 | |
9358 | fi | |
9359 | ||
1b1fe467 CR |
9360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
9361 | $as_echo_n "checking for alloca... " >&6; } | |
9362 | if ${ac_cv_func_alloca_works+:} false; then : | |
9363 | $as_echo_n "(cached) " >&6 | |
7175a77f | 9364 | else |
1b1fe467 | 9365 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 9366 | /* end confdefs.h. */ |
1b1fe467 CR |
9367 | #ifdef __GNUC__ |
9368 | # define alloca __builtin_alloca | |
9369 | #else | |
9370 | # ifdef _MSC_VER | |
9371 | # include <malloc.h> | |
9372 | # define alloca _alloca | |
9373 | # else | |
9374 | # ifdef HAVE_ALLOCA_H | |
9375 | # include <alloca.h> | |
9376 | # else | |
9377 | # ifdef _AIX | |
9378 | #pragma alloca | |
9379 | # else | |
9380 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
9381 | void *alloca (size_t); | |
9382 | # endif | |
9383 | # endif | |
9384 | # endif | |
9385 | # endif | |
9386 | #endif | |
7f947b68 | 9387 | |
abe2eb5b CR |
9388 | int |
9389 | main () | |
9390 | { | |
1b1fe467 CR |
9391 | char *p = (char *) alloca (1); |
9392 | if (p) return 0; | |
abe2eb5b CR |
9393 | ; |
9394 | return 0; | |
9395 | } | |
9396 | _ACEOF | |
1b1fe467 CR |
9397 | if ac_fn_c_try_link "$LINENO"; then : |
9398 | ac_cv_func_alloca_works=yes | |
7f947b68 | 9399 | else |
1b1fe467 CR |
9400 | ac_cv_func_alloca_works=no |
9401 | fi | |
9402 | rm -f core conftest.err conftest.$ac_objext \ | |
9403 | conftest$ac_exeext conftest.$ac_ext | |
7f947b68 | 9404 | fi |
1b1fe467 CR |
9405 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
9406 | $as_echo "$ac_cv_func_alloca_works" >&6; } | |
9407 | ||
9408 | if test $ac_cv_func_alloca_works = yes; then | |
9409 | ||
9410 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h | |
7f947b68 | 9411 | |
7f947b68 | 9412 | else |
1b1fe467 CR |
9413 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions |
9414 | # that cause trouble. Some versions do not even contain alloca or | |
9415 | # contain a buggy version. If you still want to use their alloca, | |
9416 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
9417 | ||
9418 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext | |
9419 | ||
9420 | $as_echo "#define C_ALLOCA 1" >>confdefs.h | |
9421 | ||
9422 | ||
9423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 | |
9424 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } | |
9425 | if ${ac_cv_os_cray+:} false; then : | |
9426 | $as_echo_n "(cached) " >&6 | |
9427 | else | |
9428 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9429 | /* end confdefs.h. */ | |
9430 | #if defined CRAY && ! defined CRAY2 | |
9431 | webecray | |
9432 | #else | |
9433 | wenotbecray | |
9434 | #endif | |
7f947b68 | 9435 | |
1b1fe467 CR |
9436 | _ACEOF |
9437 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
9438 | $EGREP "webecray" >/dev/null 2>&1; then : | |
9439 | ac_cv_os_cray=yes | |
9440 | else | |
9441 | ac_cv_os_cray=no | |
7f947b68 | 9442 | fi |
1b1fe467 | 9443 | rm -f conftest* |
7f947b68 CR |
9444 | |
9445 | fi | |
1b1fe467 CR |
9446 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 |
9447 | $as_echo "$ac_cv_os_cray" >&6; } | |
9448 | if test $ac_cv_os_cray = yes; then | |
9449 | for ac_func in _getb67 GETB67 getb67; do | |
9450 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9451 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9452 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
7f947b68 | 9453 | |
1b1fe467 CR |
9454 | cat >>confdefs.h <<_ACEOF |
9455 | #define CRAY_STACKSEG_END $ac_func | |
7175a77f | 9456 | _ACEOF |
7175a77f | 9457 | |
1b1fe467 CR |
9458 | break |
9459 | fi | |
e3db237e | 9460 | |
1b1fe467 | 9461 | done |
d166f048 | 9462 | fi |
e3db237e | 9463 | |
1b1fe467 CR |
9464 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 |
9465 | $as_echo_n "checking stack direction for C alloca... " >&6; } | |
9466 | if ${ac_cv_c_stack_direction+:} false; then : | |
9467 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 9468 | else |
1b1fe467 CR |
9469 | if test "$cross_compiling" = yes; then : |
9470 | ac_cv_c_stack_direction=0 | |
9471 | else | |
9472 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 9473 | /* end confdefs.h. */ |
7175a77f | 9474 | $ac_includes_default |
abe2eb5b | 9475 | int |
0ee50808 | 9476 | find_stack_direction (int *addr, int depth) |
abe2eb5b | 9477 | { |
0ee50808 CR |
9478 | int dir, dummy = 0; |
9479 | if (! addr) | |
9480 | addr = &dummy; | |
9481 | *addr = addr < &dummy ? 1 : addr == &dummy ? 0 : -1; | |
9482 | dir = depth ? find_stack_direction (addr, depth - 1) : 0; | |
9483 | return dir + dummy; | |
1b1fe467 | 9484 | } |
7175a77f | 9485 | |
1b1fe467 | 9486 | int |
0ee50808 | 9487 | main (int argc, char **argv) |
1b1fe467 | 9488 | { |
0ee50808 | 9489 | return find_stack_direction (0, argc + !argv + 20) < 0; |
abe2eb5b CR |
9490 | } |
9491 | _ACEOF | |
1b1fe467 CR |
9492 | if ac_fn_c_try_run "$LINENO"; then : |
9493 | ac_cv_c_stack_direction=1 | |
abe2eb5b | 9494 | else |
1b1fe467 | 9495 | ac_cv_c_stack_direction=-1 |
7610e0c5 | 9496 | fi |
1b1fe467 CR |
9497 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
9498 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2dead0c4 | 9499 | fi |
2dead0c4 | 9500 | |
1b1fe467 CR |
9501 | fi |
9502 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 | |
9503 | $as_echo "$ac_cv_c_stack_direction" >&6; } | |
7175a77f | 9504 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 9505 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
7175a77f | 9506 | _ACEOF |
7f947b68 | 9507 | |
7f947b68 | 9508 | |
03d922b1 CR |
9509 | fi |
9510 | ||
9511 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 | |
9512 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
9513 | if ${ac_cv_type_uid_t+:} false; then : | |
9514 | $as_echo_n "(cached) " >&6 | |
9515 | else | |
9516 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9517 | /* end confdefs.h. */ | |
9518 | #include <sys/types.h> | |
9519 | ||
9520 | _ACEOF | |
9521 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
9522 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
9523 | ac_cv_type_uid_t=yes | |
9524 | else | |
9525 | ac_cv_type_uid_t=no | |
9526 | fi | |
9527 | rm -f conftest* | |
9528 | ||
9529 | fi | |
9530 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 | |
9531 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
9532 | if test $ac_cv_type_uid_t = no; then | |
9533 | ||
9534 | $as_echo "#define uid_t int" >>confdefs.h | |
9535 | ||
9536 | ||
9537 | $as_echo "#define gid_t int" >>confdefs.h | |
9538 | ||
9539 | fi | |
9540 | ||
9541 | for ac_header in unistd.h | |
9542 | do : | |
9543 | ac_fn_c_check_header_mongrel "$LINENO" "unistd.h" "ac_cv_header_unistd_h" "$ac_includes_default" | |
9544 | if test "x$ac_cv_header_unistd_h" = xyes; then : | |
9545 | cat >>confdefs.h <<_ACEOF | |
9546 | #define HAVE_UNISTD_H 1 | |
9547 | _ACEOF | |
9548 | ||
9549 | fi | |
9550 | ||
9551 | done | |
9552 | ||
9553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working chown" >&5 | |
9554 | $as_echo_n "checking for working chown... " >&6; } | |
9555 | if ${ac_cv_func_chown_works+:} false; then : | |
9556 | $as_echo_n "(cached) " >&6 | |
9557 | else | |
9558 | if test "$cross_compiling" = yes; then : | |
9559 | ac_cv_func_chown_works=no | |
9560 | else | |
9561 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9562 | /* end confdefs.h. */ | |
9563 | $ac_includes_default | |
9564 | #include <fcntl.h> | |
9565 | ||
9566 | int | |
9567 | main () | |
9568 | { | |
9569 | char *f = "conftest.chown"; | |
9570 | struct stat before, after; | |
9571 | ||
9572 | if (creat (f, 0600) < 0) | |
9573 | return 1; | |
9574 | if (stat (f, &before) < 0) | |
9575 | return 1; | |
9576 | if (chown (f, (uid_t) -1, (gid_t) -1) == -1) | |
9577 | return 1; | |
9578 | if (stat (f, &after) < 0) | |
9579 | return 1; | |
9580 | return ! (before.st_uid == after.st_uid && before.st_gid == after.st_gid); | |
9581 | ||
9582 | ; | |
9583 | return 0; | |
9584 | } | |
9585 | _ACEOF | |
9586 | if ac_fn_c_try_run "$LINENO"; then : | |
9587 | ac_cv_func_chown_works=yes | |
9588 | else | |
9589 | ac_cv_func_chown_works=no | |
9590 | fi | |
9591 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9592 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9593 | fi | |
9594 | ||
9595 | rm -f conftest.chown | |
9596 | ||
9597 | fi | |
9598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_chown_works" >&5 | |
9599 | $as_echo "$ac_cv_func_chown_works" >&6; } | |
9600 | if test $ac_cv_func_chown_works = yes; then | |
9601 | ||
9602 | $as_echo "#define HAVE_CHOWN 1" >>confdefs.h | |
9603 | ||
1b1fe467 CR |
9604 | fi |
9605 | ||
9606 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5 | |
9607 | $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; } | |
9608 | if ${ac_cv_func_getpgrp_void+:} false; then : | |
7175a77f | 9609 | $as_echo_n "(cached) " >&6 |
7f947b68 | 9610 | else |
1b1fe467 CR |
9611 | # Use it with a single arg. |
9612 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f CR |
9613 | /* end confdefs.h. */ |
9614 | $ac_includes_default | |
9615 | int | |
9616 | main () | |
9617 | { | |
1b1fe467 | 9618 | getpgrp (0); |
7175a77f CR |
9619 | ; |
9620 | return 0; | |
9621 | } | |
9622 | _ACEOF | |
1b1fe467 CR |
9623 | if ac_fn_c_try_compile "$LINENO"; then : |
9624 | ac_cv_func_getpgrp_void=no | |
9625 | else | |
9626 | ac_cv_func_getpgrp_void=yes | |
9627 | fi | |
9628 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9629 | ||
9630 | fi | |
9631 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5 | |
9632 | $as_echo "$ac_cv_func_getpgrp_void" >&6; } | |
9633 | if test $ac_cv_func_getpgrp_void = yes; then | |
9634 | ||
9635 | $as_echo "#define GETPGRP_VOID 1" >>confdefs.h | |
9636 | ||
9637 | fi | |
9638 | ||
9639 | if ${ac_cv_func_setvbuf_reversed+:} false; then : | |
9640 | $as_echo_n "(cached) " >&6 | |
9641 | else | |
9642 | ac_cv_func_setvbuf_reversed=no | |
9643 | fi | |
9644 | ||
9645 | ||
9646 | for ac_func in vprintf | |
9647 | do : | |
9648 | ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" | |
9649 | if test "x$ac_cv_func_vprintf" = xyes; then : | |
9650 | cat >>confdefs.h <<_ACEOF | |
9651 | #define HAVE_VPRINTF 1 | |
7175a77f | 9652 | _ACEOF |
1b1fe467 CR |
9653 | |
9654 | ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" | |
9655 | if test "x$ac_cv_func__doprnt" = xyes; then : | |
9656 | ||
9657 | $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h | |
9658 | ||
9659 | fi | |
9660 | ||
9661 | fi | |
9662 | done | |
9663 | ||
9664 | ||
9665 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5 | |
9666 | $as_echo_n "checking for working strcoll... " >&6; } | |
9667 | if ${ac_cv_func_strcoll_works+:} false; then : | |
9668 | $as_echo_n "(cached) " >&6 | |
9669 | else | |
9670 | if test "$cross_compiling" = yes; then : | |
9671 | ac_cv_func_strcoll_works=no | |
9672 | else | |
9673 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f CR |
9674 | /* end confdefs.h. */ |
9675 | $ac_includes_default | |
9676 | int | |
9677 | main () | |
9678 | { | |
1b1fe467 CR |
9679 | return (strcoll ("abc", "def") >= 0 || |
9680 | strcoll ("ABC", "DEF") >= 0 || | |
9681 | strcoll ("123", "456") >= 0) | |
7175a77f CR |
9682 | ; |
9683 | return 0; | |
9684 | } | |
abe2eb5b | 9685 | _ACEOF |
1b1fe467 CR |
9686 | if ac_fn_c_try_run "$LINENO"; then : |
9687 | ac_cv_func_strcoll_works=yes | |
7175a77f | 9688 | else |
1b1fe467 CR |
9689 | ac_cv_func_strcoll_works=no |
9690 | fi | |
9691 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9692 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9693 | fi | |
2dead0c4 | 9694 | |
7f947b68 | 9695 | fi |
1b1fe467 CR |
9696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5 |
9697 | $as_echo "$ac_cv_func_strcoll_works" >&6; } | |
9698 | if test $ac_cv_func_strcoll_works = yes; then | |
7f947b68 | 9699 | |
1b1fe467 | 9700 | $as_echo "#define HAVE_STRCOLL 1" >>confdefs.h |
7f947b68 | 9701 | |
1b1fe467 CR |
9702 | fi |
9703 | ||
9704 | ||
9705 | ||
9706 | if test "$ac_cv_func_alloca_works" = "no" && test "$opt_bash_malloc" = "no"; then | |
9707 | MALLOC_TARGET=alloca | |
9708 | MALLOC_SRC=alloca.c | |
9709 | ||
9710 | MALLOC_LIB='-lmalloc' | |
9711 | MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a' | |
9712 | MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)' | |
9713 | MALLOC_DEP='$(MALLOC_LIBRARY)' | |
9714 | fi | |
9715 | ||
9716 | if test "$ac_cv_func_vprintf" = no; then | |
9717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of vprintf in stdio.h" >&5 | |
9718 | $as_echo_n "checking for declaration of vprintf in stdio.h... " >&6; } | |
9719 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 9720 | /* end confdefs.h. */ |
1b1fe467 | 9721 | #include <stdio.h> |
7f947b68 | 9722 | |
abe2eb5b | 9723 | _ACEOF |
1b1fe467 CR |
9724 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
9725 | $EGREP "[int[ ]*vprintf[^a-zA-Z0-9]]" >/dev/null 2>&1; then : | |
9726 | ac_cv_func_vprintf=yes | |
9727 | fi | |
9728 | rm -f conftest* | |
9729 | ||
9730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vprintf" >&5 | |
9731 | $as_echo "$ac_cv_func_vprintf" >&6; } | |
9732 | if test $ac_cv_func_vprintf = yes; then | |
9733 | $as_echo "#define HAVE_VPRINTF 1" >>confdefs.h | |
9734 | ||
9735 | fi | |
9736 | fi | |
9737 | ||
9738 | if test "$ac_cv_func_vprintf" = no && test "$ac_cv_func__doprnt" = "yes"; then | |
9739 | case " $LIBOBJS " in | |
9740 | *" vprint.$ac_objext "* ) ;; | |
9741 | *) LIBOBJS="$LIBOBJS vprint.$ac_objext" | |
9742 | ;; | |
7175a77f | 9743 | esac |
1b1fe467 CR |
9744 | |
9745 | fi | |
9746 | ||
9747 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 | |
9748 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
9749 | if ${ac_cv_type_signal+:} false; then : | |
9750 | $as_echo_n "(cached) " >&6 | |
9751 | else | |
9752 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 9753 | /* end confdefs.h. */ |
1b1fe467 CR |
9754 | #include <sys/types.h> |
9755 | #include <signal.h> | |
9756 | ||
7175a77f CR |
9757 | int |
9758 | main () | |
9759 | { | |
1b1fe467 | 9760 | return *(signal (0, 0)) (0) == 1; |
7175a77f CR |
9761 | ; |
9762 | return 0; | |
9763 | } | |
9764 | _ACEOF | |
1b1fe467 CR |
9765 | if ac_fn_c_try_compile "$LINENO"; then : |
9766 | ac_cv_type_signal=int | |
7175a77f | 9767 | else |
1b1fe467 CR |
9768 | ac_cv_type_signal=void |
9769 | fi | |
9770 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9771 | fi | |
9772 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
9773 | $as_echo "$ac_cv_type_signal" >&6; } | |
9774 | ||
9775 | cat >>confdefs.h <<_ACEOF | |
9776 | #define RETSIGTYPE $ac_cv_type_signal | |
9777 | _ACEOF | |
9778 | ||
9779 | ||
9780 | ||
9781 | ac_fn_c_check_func "$LINENO" "__setostype" "ac_cv_func___setostype" | |
9782 | if test "x$ac_cv_func___setostype" = xyes; then : | |
9783 | $as_echo "#define HAVE_SETOSTYPE 1" >>confdefs.h | |
7f947b68 CR |
9784 | |
9785 | fi | |
9786 | ||
1b1fe467 CR |
9787 | ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3" |
9788 | if test "x$ac_cv_func_wait3" = xyes; then : | |
9789 | $as_echo "#define HAVE_WAIT3 1" >>confdefs.h | |
2dead0c4 CR |
9790 | |
9791 | fi | |
9792 | ||
1b1fe467 CR |
9793 | |
9794 | ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo" | |
9795 | if test "x$ac_cv_func_mkfifo" = xyes; then : | |
9796 | $as_echo "#define HAVE_MKFIFO 1" >>confdefs.h | |
9797 | ||
9798 | else | |
9799 | $as_echo "#define MKFIFO_MISSING 1" >>confdefs.h | |
9800 | ||
7175a77f | 9801 | fi |
7f947b68 | 9802 | |
7f947b68 | 9803 | |
1b1fe467 CR |
9804 | for ac_func in dup2 eaccess fcntl getdtablesize getgroups gethostname \ |
9805 | getpagesize getpeername getrlimit getrusage gettimeofday \ | |
09f70f2f | 9806 | kill killpg lstat pselect readlink sbrk select setdtablesize \ |
1b1fe467 CR |
9807 | setitimer tcgetpgrp uname ulimit waitpid |
9808 | do : | |
9809 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9810 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9811 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9812 | cat >>confdefs.h <<_ACEOF | |
9813 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7175a77f | 9814 | _ACEOF |
1b1fe467 CR |
9815 | |
9816 | fi | |
9817 | done | |
9818 | ||
9819 | ac_fn_c_check_func "$LINENO" "rename" "ac_cv_func_rename" | |
9820 | if test "x$ac_cv_func_rename" = xyes; then : | |
9821 | $as_echo "#define HAVE_RENAME 1" >>confdefs.h | |
9822 | ||
7175a77f | 9823 | else |
1b1fe467 CR |
9824 | case " $LIBOBJS " in |
9825 | *" rename.$ac_objext "* ) ;; | |
9826 | *) LIBOBJS="$LIBOBJS rename.$ac_objext" | |
9827 | ;; | |
9828 | esac | |
2dead0c4 | 9829 | |
7f947b68 | 9830 | fi |
2dead0c4 | 9831 | |
1b1fe467 CR |
9832 | |
9833 | ||
9834 | for ac_func in bcopy bzero confstr faccessat fnmatch \ | |
9835 | getaddrinfo gethostbyname getservbyname getservent inet_aton \ | |
690150f9 | 9836 | imaxdiv memmove pathconf putenv raise random regcomp regexec \ |
1b1fe467 CR |
9837 | setenv setlinebuf setlocale setvbuf siginterrupt strchr \ |
9838 | sysconf syslog tcgetattr times ttyname tzset unsetenv | |
9839 | do : | |
9840 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9841 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9842 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9843 | cat >>confdefs.h <<_ACEOF | |
9844 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9845 | _ACEOF | |
9846 | ||
9847 | fi | |
7175a77f | 9848 | done |
1b1fe467 CR |
9849 | |
9850 | ||
9851 | for ac_func in vasprintf asprintf | |
9852 | do : | |
9853 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9854 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9855 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9856 | cat >>confdefs.h <<_ACEOF | |
9857 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7175a77f | 9858 | _ACEOF |
abe2eb5b | 9859 | |
1b1fe467 CR |
9860 | fi |
9861 | done | |
7f947b68 | 9862 | |
1b1fe467 CR |
9863 | for ac_func in isascii isblank isgraph isprint isspace isxdigit |
9864 | do : | |
9865 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9866 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9867 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9868 | cat >>confdefs.h <<_ACEOF | |
9869 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7175a77f | 9870 | _ACEOF |
1b1fe467 CR |
9871 | |
9872 | fi | |
9873 | done | |
9874 | ||
9875 | for ac_func in getpwent getpwnam getpwuid | |
9876 | do : | |
9877 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9878 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9879 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9880 | cat >>confdefs.h <<_ACEOF | |
9881 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
9882 | _ACEOF | |
9883 | ||
9884 | fi | |
9885 | done | |
9886 | ||
9887 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" | |
9888 | if test "x$ac_cv_func_getcwd" = xyes; then : | |
9889 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h | |
9890 | ||
9891 | else | |
9892 | case " $LIBOBJS " in | |
9893 | *" getcwd.$ac_objext "* ) ;; | |
9894 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" | |
9895 | ;; | |
abe2eb5b | 9896 | esac |
1b1fe467 CR |
9897 | |
9898 | fi | |
9899 | ||
9900 | ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset" | |
9901 | if test "x$ac_cv_func_memset" = xyes; then : | |
9902 | $as_echo "#define HAVE_MEMSET 1" >>confdefs.h | |
9903 | ||
7175a77f | 9904 | else |
1b1fe467 CR |
9905 | case " $LIBOBJS " in |
9906 | *" memset.$ac_objext "* ) ;; | |
9907 | *) LIBOBJS="$LIBOBJS memset.$ac_objext" | |
9908 | ;; | |
9909 | esac | |
7f947b68 | 9910 | |
7175a77f | 9911 | fi |
1b1fe467 CR |
9912 | |
9913 | ||
9914 | ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp" | |
9915 | if test "x$ac_cv_func_strcasecmp" = xyes; then : | |
9916 | $as_echo "#define HAVE_STRCASECMP 1" >>confdefs.h | |
9917 | ||
9918 | else | |
9919 | case " $LIBOBJS " in | |
9920 | *" strcasecmp.$ac_objext "* ) ;; | |
9921 | *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext" | |
9922 | ;; | |
9923 | esac | |
9924 | ||
7175a77f | 9925 | fi |
1b1fe467 CR |
9926 | |
9927 | ac_fn_c_check_func "$LINENO" "strcasestr" "ac_cv_func_strcasestr" | |
9928 | if test "x$ac_cv_func_strcasestr" = xyes; then : | |
9929 | $as_echo "#define HAVE_STRCASESTR 1" >>confdefs.h | |
9930 | ||
9931 | else | |
9932 | case " $LIBOBJS " in | |
9933 | *" strcasestr.$ac_objext "* ) ;; | |
9934 | *) LIBOBJS="$LIBOBJS strcasestr.$ac_objext" | |
9935 | ;; | |
9936 | esac | |
9937 | ||
7f947b68 CR |
9938 | fi |
9939 | ||
1b1fe467 CR |
9940 | ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror" |
9941 | if test "x$ac_cv_func_strerror" = xyes; then : | |
9942 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
7f947b68 | 9943 | |
1b1fe467 CR |
9944 | else |
9945 | case " $LIBOBJS " in | |
9946 | *" strerror.$ac_objext "* ) ;; | |
9947 | *) LIBOBJS="$LIBOBJS strerror.$ac_objext" | |
9948 | ;; | |
9949 | esac | |
e8ce775d | 9950 | |
1b1fe467 | 9951 | fi |
71412226 | 9952 | |
1b1fe467 CR |
9953 | ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" |
9954 | if test "x$ac_cv_func_strftime" = xyes; then : | |
9955 | $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h | |
7f947b68 | 9956 | |
abe2eb5b | 9957 | else |
1b1fe467 CR |
9958 | case " $LIBOBJS " in |
9959 | *" strftime.$ac_objext "* ) ;; | |
9960 | *) LIBOBJS="$LIBOBJS strftime.$ac_objext" | |
9961 | ;; | |
9962 | esac | |
cce855bc | 9963 | |
1b1fe467 CR |
9964 | fi |
9965 | ||
9966 | ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen" | |
9967 | if test "x$ac_cv_func_strnlen" = xyes; then : | |
9968 | $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h | |
9969 | ||
9970 | else | |
9971 | case " $LIBOBJS " in | |
9972 | *" strnlen.$ac_objext "* ) ;; | |
9973 | *) LIBOBJS="$LIBOBJS strnlen.$ac_objext" | |
9974 | ;; | |
7175a77f | 9975 | esac |
7f947b68 | 9976 | |
1b1fe467 CR |
9977 | fi |
9978 | ||
9979 | ac_fn_c_check_func "$LINENO" "strpbrk" "ac_cv_func_strpbrk" | |
9980 | if test "x$ac_cv_func_strpbrk" = xyes; then : | |
9981 | $as_echo "#define HAVE_STRPBRK 1" >>confdefs.h | |
9982 | ||
9983 | else | |
9984 | case " $LIBOBJS " in | |
9985 | *" strpbrk.$ac_objext "* ) ;; | |
9986 | *) LIBOBJS="$LIBOBJS strpbrk.$ac_objext" | |
9987 | ;; | |
7f947b68 | 9988 | esac |
1b1fe467 CR |
9989 | |
9990 | fi | |
9991 | ||
9992 | ac_fn_c_check_func "$LINENO" "strstr" "ac_cv_func_strstr" | |
9993 | if test "x$ac_cv_func_strstr" = xyes; then : | |
9994 | $as_echo "#define HAVE_STRSTR 1" >>confdefs.h | |
9995 | ||
7175a77f | 9996 | else |
1b1fe467 CR |
9997 | case " $LIBOBJS " in |
9998 | *" strstr.$ac_objext "* ) ;; | |
9999 | *) LIBOBJS="$LIBOBJS strstr.$ac_objext" | |
10000 | ;; | |
10001 | esac | |
7f947b68 | 10002 | |
abe2eb5b | 10003 | fi |
71412226 | 10004 | |
1b1fe467 CR |
10005 | |
10006 | ac_fn_c_check_func "$LINENO" "strtod" "ac_cv_func_strtod" | |
10007 | if test "x$ac_cv_func_strtod" = xyes; then : | |
10008 | $as_echo "#define HAVE_STRTOD 1" >>confdefs.h | |
10009 | ||
7f947b68 | 10010 | else |
1b1fe467 CR |
10011 | case " $LIBOBJS " in |
10012 | *" strtod.$ac_objext "* ) ;; | |
10013 | *) LIBOBJS="$LIBOBJS strtod.$ac_objext" | |
10014 | ;; | |
10015 | esac | |
7f947b68 | 10016 | |
1b1fe467 | 10017 | fi |
7f947b68 | 10018 | |
1b1fe467 CR |
10019 | ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol" |
10020 | if test "x$ac_cv_func_strtol" = xyes; then : | |
10021 | $as_echo "#define HAVE_STRTOL 1" >>confdefs.h | |
10022 | ||
10023 | else | |
10024 | case " $LIBOBJS " in | |
10025 | *" strtol.$ac_objext "* ) ;; | |
10026 | *) LIBOBJS="$LIBOBJS strtol.$ac_objext" | |
10027 | ;; | |
7175a77f | 10028 | esac |
7f947b68 | 10029 | |
1b1fe467 CR |
10030 | fi |
10031 | ||
10032 | ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul" | |
10033 | if test "x$ac_cv_func_strtoul" = xyes; then : | |
10034 | $as_echo "#define HAVE_STRTOUL 1" >>confdefs.h | |
10035 | ||
10036 | else | |
10037 | case " $LIBOBJS " in | |
10038 | *" strtoul.$ac_objext "* ) ;; | |
10039 | *) LIBOBJS="$LIBOBJS strtoul.$ac_objext" | |
10040 | ;; | |
7f947b68 | 10041 | esac |
1b1fe467 CR |
10042 | |
10043 | fi | |
10044 | ||
10045 | ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" | |
10046 | if test "x$ac_cv_func_strtoll" = xyes; then : | |
10047 | $as_echo "#define HAVE_STRTOLL 1" >>confdefs.h | |
10048 | ||
2dead0c4 | 10049 | else |
1b1fe467 CR |
10050 | case " $LIBOBJS " in |
10051 | *" strtoll.$ac_objext "* ) ;; | |
10052 | *) LIBOBJS="$LIBOBJS strtoll.$ac_objext" | |
10053 | ;; | |
10054 | esac | |
2dead0c4 | 10055 | |
7f947b68 | 10056 | fi |
2dead0c4 | 10057 | |
1b1fe467 CR |
10058 | ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull" |
10059 | if test "x$ac_cv_func_strtoull" = xyes; then : | |
10060 | $as_echo "#define HAVE_STRTOULL 1" >>confdefs.h | |
10061 | ||
7f947b68 | 10062 | else |
1b1fe467 CR |
10063 | case " $LIBOBJS " in |
10064 | *" strtoull.$ac_objext "* ) ;; | |
10065 | *) LIBOBJS="$LIBOBJS strtoull.$ac_objext" | |
10066 | ;; | |
10067 | esac | |
7f947b68 CR |
10068 | |
10069 | fi | |
10070 | ||
1b1fe467 CR |
10071 | ac_fn_c_check_func "$LINENO" "strtoimax" "ac_cv_func_strtoimax" |
10072 | if test "x$ac_cv_func_strtoimax" = xyes; then : | |
10073 | $as_echo "#define HAVE_STRTOIMAX 1" >>confdefs.h | |
10074 | ||
10075 | else | |
10076 | case " $LIBOBJS " in | |
10077 | *" strtoimax.$ac_objext "* ) ;; | |
10078 | *) LIBOBJS="$LIBOBJS strtoimax.$ac_objext" | |
10079 | ;; | |
10080 | esac | |
10081 | ||
2dead0c4 | 10082 | fi |
7f947b68 | 10083 | |
1b1fe467 CR |
10084 | ac_fn_c_check_func "$LINENO" "strtoumax" "ac_cv_func_strtoumax" |
10085 | if test "x$ac_cv_func_strtoumax" = xyes; then : | |
10086 | $as_echo "#define HAVE_STRTOUMAX 1" >>confdefs.h | |
7f947b68 | 10087 | |
1b1fe467 CR |
10088 | else |
10089 | case " $LIBOBJS " in | |
10090 | *" strtoumax.$ac_objext "* ) ;; | |
10091 | *) LIBOBJS="$LIBOBJS strtoumax.$ac_objext" | |
10092 | ;; | |
7f947b68 | 10093 | esac |
1b1fe467 CR |
10094 | |
10095 | fi | |
10096 | ||
10097 | ||
10098 | ac_fn_c_check_func "$LINENO" "dprintf" "ac_cv_func_dprintf" | |
10099 | if test "x$ac_cv_func_dprintf" = xyes; then : | |
10100 | $as_echo "#define HAVE_DPRINTF 1" >>confdefs.h | |
10101 | ||
7f947b68 | 10102 | else |
1b1fe467 CR |
10103 | case " $LIBOBJS " in |
10104 | *" dprintf.$ac_objext "* ) ;; | |
10105 | *) LIBOBJS="$LIBOBJS dprintf.$ac_objext" | |
10106 | ;; | |
10107 | esac | |
7f947b68 | 10108 | |
abe2eb5b | 10109 | fi |
2dead0c4 | 10110 | |
1b1fe467 CR |
10111 | |
10112 | ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul" | |
10113 | if test "x$ac_cv_func_strchrnul" = xyes; then : | |
10114 | $as_echo "#define HAVE_STRCHRNUL 1" >>confdefs.h | |
10115 | ||
10116 | else | |
10117 | case " $LIBOBJS " in | |
10118 | *" strchrnul.$ac_objext "* ) ;; | |
10119 | *) LIBOBJS="$LIBOBJS strchrnul.$ac_objext" | |
10120 | ;; | |
7f947b68 | 10121 | esac |
1b1fe467 CR |
10122 | |
10123 | fi | |
10124 | ||
10125 | ||
67440bc5 CR |
10126 | ac_fn_c_check_func "$LINENO" "strdup" "ac_cv_func_strdup" |
10127 | if test "x$ac_cv_func_strdup" = xyes; then : | |
10128 | $as_echo "#define HAVE_STRDUP 1" >>confdefs.h | |
10129 | ||
10130 | else | |
10131 | case " $LIBOBJS " in | |
10132 | *" strdup.$ac_objext "* ) ;; | |
10133 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" | |
10134 | ;; | |
10135 | esac | |
10136 | ||
10137 | fi | |
10138 | ||
10139 | ||
1b1fe467 | 10140 | |
54a5fbe1 CR |
10141 | for ac_header in libaudit.h |
10142 | do : | |
10143 | ac_fn_c_check_header_mongrel "$LINENO" "libaudit.h" "ac_cv_header_libaudit_h" "$ac_includes_default" | |
10144 | if test "x$ac_cv_header_libaudit_h" = xyes; then : | |
10145 | cat >>confdefs.h <<_ACEOF | |
10146 | #define HAVE_LIBAUDIT_H 1 | |
10147 | _ACEOF | |
10148 | ||
10149 | fi | |
10150 | ||
10151 | done | |
10152 | ||
1b1fe467 CR |
10153 | ac_fn_c_check_decl "$LINENO" "AUDIT_USER_TTY" "ac_cv_have_decl_AUDIT_USER_TTY" "#include <linux/audit.h> |
10154 | " | |
10155 | if test "x$ac_cv_have_decl_AUDIT_USER_TTY" = xyes; then : | |
10156 | ac_have_decl=1 | |
ccc6cda3 | 10157 | else |
1b1fe467 CR |
10158 | ac_have_decl=0 |
10159 | fi | |
10160 | ||
10161 | cat >>confdefs.h <<_ACEOF | |
10162 | #define HAVE_DECL_AUDIT_USER_TTY $ac_have_decl | |
7175a77f | 10163 | _ACEOF |
2dead0c4 | 10164 | |
7610e0c5 | 10165 | |
1b1fe467 CR |
10166 | ac_fn_c_check_decl "$LINENO" "confstr" "ac_cv_have_decl_confstr" "$ac_includes_default" |
10167 | if test "x$ac_cv_have_decl_confstr" = xyes; then : | |
10168 | ac_have_decl=1 | |
7175a77f | 10169 | else |
1b1fe467 | 10170 | ac_have_decl=0 |
2dead0c4 | 10171 | fi |
1b1fe467 CR |
10172 | |
10173 | cat >>confdefs.h <<_ACEOF | |
10174 | #define HAVE_DECL_CONFSTR $ac_have_decl | |
10175 | _ACEOF | |
10176 | ||
10177 | ac_fn_c_check_decl "$LINENO" "printf" "ac_cv_have_decl_printf" "$ac_includes_default" | |
10178 | if test "x$ac_cv_have_decl_printf" = xyes; then : | |
10179 | ac_have_decl=1 | |
10180 | else | |
10181 | ac_have_decl=0 | |
7175a77f | 10182 | fi |
7f947b68 | 10183 | |
1b1fe467 CR |
10184 | cat >>confdefs.h <<_ACEOF |
10185 | #define HAVE_DECL_PRINTF $ac_have_decl | |
10186 | _ACEOF | |
7f947b68 | 10187 | |
1b1fe467 CR |
10188 | ac_fn_c_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default" |
10189 | if test "x$ac_cv_have_decl_sbrk" = xyes; then : | |
10190 | ac_have_decl=1 | |
10191 | else | |
10192 | ac_have_decl=0 | |
10193 | fi | |
7f947b68 | 10194 | |
abe2eb5b | 10195 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 10196 | #define HAVE_DECL_SBRK $ac_have_decl |
2dead0c4 | 10197 | _ACEOF |
c920c360 | 10198 | |
1b1fe467 CR |
10199 | ac_fn_c_check_decl "$LINENO" "setregid" "ac_cv_have_decl_setregid" "$ac_includes_default" |
10200 | if test "x$ac_cv_have_decl_setregid" = xyes; then : | |
10201 | ac_have_decl=1 | |
10202 | else | |
10203 | ac_have_decl=0 | |
10204 | fi | |
c920c360 | 10205 | |
1b1fe467 CR |
10206 | cat >>confdefs.h <<_ACEOF |
10207 | #define HAVE_DECL_SETREGID $ac_have_decl | |
10208 | _ACEOF | |
10209 | ||
10210 | ac_fn_c_check_decl "$LINENO" "strcpy" "ac_cv_have_decl_strcpy" "$ac_includes_default" | |
10211 | if test "x$ac_cv_have_decl_strcpy" = xyes; then : | |
10212 | ac_have_decl=1 | |
c920c360 | 10213 | else |
1b1fe467 CR |
10214 | ac_have_decl=0 |
10215 | fi | |
10216 | ||
10217 | cat >>confdefs.h <<_ACEOF | |
10218 | #define HAVE_DECL_STRCPY $ac_have_decl | |
2dead0c4 | 10219 | _ACEOF |
c920c360 | 10220 | |
1b1fe467 CR |
10221 | ac_fn_c_check_decl "$LINENO" "strsignal" "ac_cv_have_decl_strsignal" "$ac_includes_default" |
10222 | if test "x$ac_cv_have_decl_strsignal" = xyes; then : | |
10223 | ac_have_decl=1 | |
10224 | else | |
10225 | ac_have_decl=0 | |
10226 | fi | |
10227 | ||
10228 | cat >>confdefs.h <<_ACEOF | |
10229 | #define HAVE_DECL_STRSIGNAL $ac_have_decl | |
7175a77f | 10230 | _ACEOF |
1b1fe467 CR |
10231 | |
10232 | ||
10233 | ac_fn_c_check_decl "$LINENO" "strtold" "ac_cv_have_decl_strtold" "$ac_includes_default" | |
10234 | if test "x$ac_cv_have_decl_strtold" = xyes; then : | |
10235 | ac_have_decl=1 | |
10236 | else | |
10237 | ac_have_decl=0 | |
10238 | fi | |
10239 | ||
10240 | cat >>confdefs.h <<_ACEOF | |
10241 | #define HAVE_DECL_STRTOLD $ac_have_decl | |
7f947b68 | 10242 | _ACEOF |
1b1fe467 CR |
10243 | if test $ac_have_decl = 1; then : |
10244 | ||
10245 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken strtold" >&5 | |
10246 | $as_echo_n "checking for broken strtold... " >&6; } | |
10247 | if ${bash_cv_strtold_broken+:} false; then : | |
10248 | $as_echo_n "(cached) " >&6 | |
10249 | else | |
10250 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 10251 | /* end confdefs.h. */ |
1b1fe467 | 10252 | #include <stdlib.h> |
7175a77f CR |
10253 | int |
10254 | main () | |
10255 | { | |
1b1fe467 | 10256 | int main() { long double r; char *foo, bar; r = strtold(foo, &bar);} |
7175a77f CR |
10257 | ; |
10258 | return 0; | |
10259 | } | |
10260 | _ACEOF | |
1b1fe467 CR |
10261 | if ac_fn_c_try_compile "$LINENO"; then : |
10262 | bash_cv_strtold_broken=no | |
abe2eb5b | 10263 | else |
1b1fe467 CR |
10264 | bash_cv_strtold_broken=yes |
10265 | fi | |
10266 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
10267 | ||
2dead0c4 | 10268 | |
7175a77f | 10269 | fi |
2dead0c4 | 10270 | |
1b1fe467 CR |
10271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_strtold_broken" >&5 |
10272 | $as_echo "$bash_cv_strtold_broken" >&6; } | |
10273 | if test "$bash_cv_strtold_broken" = "yes" ; then | |
10274 | $as_echo "#define STRTOLD_BROKEN 1" >>confdefs.h | |
71412226 | 10275 | |
1b1fe467 CR |
10276 | fi |
10277 | ||
10278 | fi | |
10279 | ||
10280 | ||
10281 | ||
10282 | ||
10283 | ||
10284 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoimax" >&5 | |
10285 | $as_echo_n "checking for declaration of strtoimax... " >&6; } | |
10286 | if ${bash_cv_decl_strtoimax+:} false; then : | |
10287 | $as_echo_n "(cached) " >&6 | |
10288 | else | |
10289 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 10290 | /* end confdefs.h. */ |
1b1fe467 CR |
10291 | |
10292 | #if STDC_HEADERS | |
10293 | # include <stdlib.h> | |
10294 | #endif | |
10295 | #if HAVE_INTTYPES_H | |
10296 | # include <inttypes.h> | |
10297 | #endif | |
10298 | ||
7175a77f CR |
10299 | int |
10300 | main () | |
10301 | { | |
1b1fe467 | 10302 | return !strtoimax; |
7175a77f CR |
10303 | ; |
10304 | return 0; | |
10305 | } | |
e3db237e | 10306 | _ACEOF |
1b1fe467 CR |
10307 | if ac_fn_c_try_link "$LINENO"; then : |
10308 | bash_cv_decl_strtoimax=yes | |
10309 | else | |
10310 | bash_cv_decl_strtoimax=no | |
10311 | fi | |
10312 | rm -f core conftest.err conftest.$ac_objext \ | |
10313 | conftest$ac_exeext conftest.$ac_ext | |
10314 | fi | |
10315 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoimax" >&5 | |
10316 | $as_echo "$bash_cv_decl_strtoimax" >&6; } | |
10317 | bash_tr_func=HAVE_DECL_`echo strtoimax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10318 | if test $bash_cv_decl_strtoimax = yes; then | |
10319 | cat >>confdefs.h <<_ACEOF | |
10320 | #define $bash_tr_func 1 | |
10321 | _ACEOF | |
10322 | ||
10323 | else | |
10324 | cat >>confdefs.h <<_ACEOF | |
10325 | #define $bash_tr_func 0 | |
7175a77f | 10326 | _ACEOF |
1b1fe467 CR |
10327 | |
10328 | fi | |
10329 | ||
10330 | ||
10331 | ||
10332 | ||
10333 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtol" >&5 | |
10334 | $as_echo_n "checking for declaration of strtol... " >&6; } | |
10335 | if ${bash_cv_decl_strtol+:} false; then : | |
10336 | $as_echo_n "(cached) " >&6 | |
10337 | else | |
10338 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 10339 | /* end confdefs.h. */ |
1b1fe467 CR |
10340 | |
10341 | #if STDC_HEADERS | |
10342 | # include <stdlib.h> | |
10343 | #endif | |
10344 | #if HAVE_INTTYPES_H | |
10345 | # include <inttypes.h> | |
10346 | #endif | |
10347 | ||
7175a77f CR |
10348 | int |
10349 | main () | |
10350 | { | |
1b1fe467 | 10351 | return !strtol; |
7175a77f CR |
10352 | ; |
10353 | return 0; | |
10354 | } | |
10355 | _ACEOF | |
1b1fe467 CR |
10356 | if ac_fn_c_try_link "$LINENO"; then : |
10357 | bash_cv_decl_strtol=yes | |
7f947b68 | 10358 | else |
1b1fe467 | 10359 | bash_cv_decl_strtol=no |
abe2eb5b | 10360 | fi |
1b1fe467 CR |
10361 | rm -f core conftest.err conftest.$ac_objext \ |
10362 | conftest$ac_exeext conftest.$ac_ext | |
10363 | fi | |
10364 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtol" >&5 | |
10365 | $as_echo "$bash_cv_decl_strtol" >&6; } | |
10366 | bash_tr_func=HAVE_DECL_`echo strtol | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10367 | if test $bash_cv_decl_strtol = yes; then | |
10368 | cat >>confdefs.h <<_ACEOF | |
10369 | #define $bash_tr_func 1 | |
10370 | _ACEOF | |
71412226 | 10371 | |
7175a77f | 10372 | else |
1b1fe467 CR |
10373 | cat >>confdefs.h <<_ACEOF |
10374 | #define $bash_tr_func 0 | |
10375 | _ACEOF | |
71412226 | 10376 | |
7175a77f | 10377 | fi |
ccc6cda3 | 10378 | |
7f947b68 | 10379 | |
1b1fe467 CR |
10380 | |
10381 | ||
10382 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoll" >&5 | |
10383 | $as_echo_n "checking for declaration of strtoll... " >&6; } | |
10384 | if ${bash_cv_decl_strtoll+:} false; then : | |
10385 | $as_echo_n "(cached) " >&6 | |
10386 | else | |
10387 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 10388 | /* end confdefs.h. */ |
1b1fe467 CR |
10389 | |
10390 | #if STDC_HEADERS | |
10391 | # include <stdlib.h> | |
10392 | #endif | |
10393 | #if HAVE_INTTYPES_H | |
10394 | # include <inttypes.h> | |
10395 | #endif | |
10396 | ||
abe2eb5b | 10397 | int |
7f947b68 CR |
10398 | main () |
10399 | { | |
1b1fe467 | 10400 | return !strtoll; |
7f947b68 CR |
10401 | ; |
10402 | return 0; | |
10403 | } | |
10404 | _ACEOF | |
1b1fe467 CR |
10405 | if ac_fn_c_try_link "$LINENO"; then : |
10406 | bash_cv_decl_strtoll=yes | |
e3db237e | 10407 | else |
1b1fe467 CR |
10408 | bash_cv_decl_strtoll=no |
10409 | fi | |
10410 | rm -f core conftest.err conftest.$ac_objext \ | |
10411 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b | 10412 | fi |
1b1fe467 CR |
10413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoll" >&5 |
10414 | $as_echo "$bash_cv_decl_strtoll" >&6; } | |
10415 | bash_tr_func=HAVE_DECL_`echo strtoll | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10416 | if test $bash_cv_decl_strtoll = yes; then | |
10417 | cat >>confdefs.h <<_ACEOF | |
10418 | #define $bash_tr_func 1 | |
10419 | _ACEOF | |
abe2eb5b | 10420 | |
c920c360 | 10421 | else |
1b1fe467 CR |
10422 | cat >>confdefs.h <<_ACEOF |
10423 | #define $bash_tr_func 0 | |
7175a77f | 10424 | _ACEOF |
1b1fe467 CR |
10425 | |
10426 | fi | |
10427 | ||
10428 | ||
10429 | ||
10430 | ||
10431 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoul" >&5 | |
10432 | $as_echo_n "checking for declaration of strtoul... " >&6; } | |
10433 | if ${bash_cv_decl_strtoul+:} false; then : | |
10434 | $as_echo_n "(cached) " >&6 | |
10435 | else | |
10436 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 10437 | /* end confdefs.h. */ |
1b1fe467 CR |
10438 | |
10439 | #if STDC_HEADERS | |
10440 | # include <stdlib.h> | |
10441 | #endif | |
10442 | #if HAVE_INTTYPES_H | |
10443 | # include <inttypes.h> | |
10444 | #endif | |
10445 | ||
e3db237e CR |
10446 | int |
10447 | main () | |
10448 | { | |
1b1fe467 | 10449 | return !strtoul; |
e3db237e CR |
10450 | ; |
10451 | return 0; | |
10452 | } | |
10453 | _ACEOF | |
1b1fe467 CR |
10454 | if ac_fn_c_try_link "$LINENO"; then : |
10455 | bash_cv_decl_strtoul=yes | |
7f947b68 | 10456 | else |
1b1fe467 CR |
10457 | bash_cv_decl_strtoul=no |
10458 | fi | |
10459 | rm -f core conftest.err conftest.$ac_objext \ | |
10460 | conftest$ac_exeext conftest.$ac_ext | |
10461 | fi | |
10462 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoul" >&5 | |
10463 | $as_echo "$bash_cv_decl_strtoul" >&6; } | |
10464 | bash_tr_func=HAVE_DECL_`echo strtoul | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10465 | if test $bash_cv_decl_strtoul = yes; then | |
10466 | cat >>confdefs.h <<_ACEOF | |
10467 | #define $bash_tr_func 1 | |
10468 | _ACEOF | |
10469 | ||
10470 | else | |
10471 | cat >>confdefs.h <<_ACEOF | |
10472 | #define $bash_tr_func 0 | |
10473 | _ACEOF | |
7175a77f | 10474 | |
7f947b68 | 10475 | fi |
7175a77f | 10476 | |
7f947b68 CR |
10477 | |
10478 | ||
7f947b68 | 10479 | |
1b1fe467 CR |
10480 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoull" >&5 |
10481 | $as_echo_n "checking for declaration of strtoull... " >&6; } | |
10482 | if ${bash_cv_decl_strtoull+:} false; then : | |
7f947b68 CR |
10483 | $as_echo_n "(cached) " >&6 |
10484 | else | |
1b1fe467 | 10485 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 10486 | /* end confdefs.h. */ |
1b1fe467 CR |
10487 | |
10488 | #if STDC_HEADERS | |
10489 | # include <stdlib.h> | |
10490 | #endif | |
10491 | #if HAVE_INTTYPES_H | |
10492 | # include <inttypes.h> | |
10493 | #endif | |
10494 | ||
e3db237e CR |
10495 | int |
10496 | main () | |
10497 | { | |
1b1fe467 | 10498 | return !strtoull; |
e3db237e CR |
10499 | ; |
10500 | return 0; | |
10501 | } | |
7610e0c5 | 10502 | _ACEOF |
1b1fe467 CR |
10503 | if ac_fn_c_try_link "$LINENO"; then : |
10504 | bash_cv_decl_strtoull=yes | |
10505 | else | |
10506 | bash_cv_decl_strtoull=no | |
10507 | fi | |
10508 | rm -f core conftest.err conftest.$ac_objext \ | |
10509 | conftest$ac_exeext conftest.$ac_ext | |
10510 | fi | |
10511 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoull" >&5 | |
10512 | $as_echo "$bash_cv_decl_strtoull" >&6; } | |
10513 | bash_tr_func=HAVE_DECL_`echo strtoull | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10514 | if test $bash_cv_decl_strtoull = yes; then | |
10515 | cat >>confdefs.h <<_ACEOF | |
10516 | #define $bash_tr_func 1 | |
10517 | _ACEOF | |
10518 | ||
10519 | else | |
10520 | cat >>confdefs.h <<_ACEOF | |
10521 | #define $bash_tr_func 0 | |
7f947b68 | 10522 | _ACEOF |
1b1fe467 CR |
10523 | |
10524 | fi | |
10525 | ||
10526 | ||
10527 | ||
10528 | ||
10529 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoumax" >&5 | |
10530 | $as_echo_n "checking for declaration of strtoumax... " >&6; } | |
10531 | if ${bash_cv_decl_strtoumax+:} false; then : | |
10532 | $as_echo_n "(cached) " >&6 | |
10533 | else | |
10534 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 10535 | /* end confdefs.h. */ |
1b1fe467 CR |
10536 | |
10537 | #if STDC_HEADERS | |
10538 | # include <stdlib.h> | |
10539 | #endif | |
10540 | #if HAVE_INTTYPES_H | |
10541 | # include <inttypes.h> | |
10542 | #endif | |
10543 | ||
e3db237e CR |
10544 | int |
10545 | main () | |
10546 | { | |
1b1fe467 | 10547 | return !strtoumax; |
e3db237e CR |
10548 | ; |
10549 | return 0; | |
10550 | } | |
f73dda09 | 10551 | _ACEOF |
1b1fe467 CR |
10552 | if ac_fn_c_try_link "$LINENO"; then : |
10553 | bash_cv_decl_strtoumax=yes | |
7f947b68 | 10554 | else |
1b1fe467 CR |
10555 | bash_cv_decl_strtoumax=no |
10556 | fi | |
10557 | rm -f core conftest.err conftest.$ac_objext \ | |
10558 | conftest$ac_exeext conftest.$ac_ext | |
10559 | fi | |
10560 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoumax" >&5 | |
10561 | $as_echo "$bash_cv_decl_strtoumax" >&6; } | |
10562 | bash_tr_func=HAVE_DECL_`echo strtoumax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10563 | if test $bash_cv_decl_strtoumax = yes; then | |
10564 | cat >>confdefs.h <<_ACEOF | |
10565 | #define $bash_tr_func 1 | |
10566 | _ACEOF | |
10567 | ||
10568 | else | |
10569 | cat >>confdefs.h <<_ACEOF | |
10570 | #define $bash_tr_func 0 | |
10571 | _ACEOF | |
7f947b68 CR |
10572 | |
10573 | fi | |
10574 | ||
1b1fe467 CR |
10575 | |
10576 | ||
10577 | ||
10578 | ||
10579 | ||
10580 | ||
10581 | for ac_func in $ac_func_list | |
10582 | do : | |
10583 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10584 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
10585 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
10586 | cat >>confdefs.h <<_ACEOF | |
10587 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
10588 | _ACEOF | |
10589 | ||
10590 | fi | |
10591 | done | |
10592 | ||
10593 | ||
10594 | ||
10595 | ||
10596 | ||
10597 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5 | |
10598 | $as_echo_n "checking for working mktime... " >&6; } | |
10599 | if ${ac_cv_func_working_mktime+:} false; then : | |
10600 | $as_echo_n "(cached) " >&6 | |
7f947b68 | 10601 | else |
1b1fe467 CR |
10602 | if test "$cross_compiling" = yes; then : |
10603 | ac_cv_func_working_mktime=no | |
10604 | else | |
10605 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10606 | /* end confdefs.h. */ | |
10607 | /* Test program from Paul Eggert and Tony Leneis. */ | |
10608 | #ifdef TIME_WITH_SYS_TIME | |
10609 | # include <sys/time.h> | |
10610 | # include <time.h> | |
10611 | #else | |
10612 | # ifdef HAVE_SYS_TIME_H | |
10613 | # include <sys/time.h> | |
10614 | # else | |
10615 | # include <time.h> | |
10616 | # endif | |
10617 | #endif | |
10618 | ||
10619 | #include <limits.h> | |
10620 | #include <stdlib.h> | |
10621 | ||
10622 | #ifdef HAVE_UNISTD_H | |
10623 | # include <unistd.h> | |
10624 | #endif | |
10625 | ||
10626 | #ifndef HAVE_ALARM | |
10627 | # define alarm(X) /* empty */ | |
10628 | #endif | |
10629 | ||
10630 | /* Work around redefinition to rpl_putenv by other config tests. */ | |
10631 | #undef putenv | |
10632 | ||
10633 | static time_t time_t_max; | |
10634 | static time_t time_t_min; | |
10635 | ||
10636 | /* Values we'll use to set the TZ environment variable. */ | |
10637 | static const char *tz_strings[] = { | |
10638 | (const char *) 0, "TZ=GMT0", "TZ=JST-9", | |
10639 | "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00" | |
10640 | }; | |
10641 | #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0])) | |
10642 | ||
10643 | /* Return 0 if mktime fails to convert a date in the spring-forward gap. | |
10644 | Based on a problem report from Andreas Jaeger. */ | |
10645 | static int | |
10646 | spring_forward_gap () | |
10647 | { | |
10648 | /* glibc (up to about 1998-10-07) failed this test. */ | |
10649 | struct tm tm; | |
10650 | ||
10651 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10652 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10653 | on systems that don't support the Olson extension, or don't have the | |
10654 | full zoneinfo tables installed. */ | |
10655 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
10656 | ||
10657 | tm.tm_year = 98; | |
10658 | tm.tm_mon = 3; | |
10659 | tm.tm_mday = 5; | |
10660 | tm.tm_hour = 2; | |
10661 | tm.tm_min = 0; | |
10662 | tm.tm_sec = 0; | |
10663 | tm.tm_isdst = -1; | |
10664 | return mktime (&tm) != (time_t) -1; | |
10665 | } | |
10666 | ||
10667 | static int | |
10668 | mktime_test1 (time_t now) | |
10669 | { | |
10670 | struct tm *lt; | |
10671 | return ! (lt = localtime (&now)) || mktime (lt) == now; | |
10672 | } | |
10673 | ||
10674 | static int | |
10675 | mktime_test (time_t now) | |
10676 | { | |
10677 | return (mktime_test1 (now) | |
10678 | && mktime_test1 ((time_t) (time_t_max - now)) | |
10679 | && mktime_test1 ((time_t) (time_t_min + now))); | |
10680 | } | |
10681 | ||
10682 | static int | |
10683 | irix_6_4_bug () | |
10684 | { | |
10685 | /* Based on code from Ariel Faigon. */ | |
10686 | struct tm tm; | |
10687 | tm.tm_year = 96; | |
10688 | tm.tm_mon = 3; | |
10689 | tm.tm_mday = 0; | |
10690 | tm.tm_hour = 0; | |
10691 | tm.tm_min = 0; | |
10692 | tm.tm_sec = 0; | |
10693 | tm.tm_isdst = -1; | |
10694 | mktime (&tm); | |
10695 | return tm.tm_mon == 2 && tm.tm_mday == 31; | |
10696 | } | |
10697 | ||
10698 | static int | |
10699 | bigtime_test (int j) | |
10700 | { | |
10701 | struct tm tm; | |
10702 | time_t now; | |
10703 | tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j; | |
10704 | now = mktime (&tm); | |
10705 | if (now != (time_t) -1) | |
10706 | { | |
10707 | struct tm *lt = localtime (&now); | |
10708 | if (! (lt | |
10709 | && lt->tm_year == tm.tm_year | |
10710 | && lt->tm_mon == tm.tm_mon | |
10711 | && lt->tm_mday == tm.tm_mday | |
10712 | && lt->tm_hour == tm.tm_hour | |
10713 | && lt->tm_min == tm.tm_min | |
10714 | && lt->tm_sec == tm.tm_sec | |
10715 | && lt->tm_yday == tm.tm_yday | |
10716 | && lt->tm_wday == tm.tm_wday | |
10717 | && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst) | |
10718 | == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst)))) | |
10719 | return 0; | |
10720 | } | |
10721 | return 1; | |
10722 | } | |
10723 | ||
10724 | static int | |
10725 | year_2050_test () | |
10726 | { | |
10727 | /* The correct answer for 2050-02-01 00:00:00 in Pacific time, | |
10728 | ignoring leap seconds. */ | |
10729 | unsigned long int answer = 2527315200UL; | |
10730 | ||
10731 | struct tm tm; | |
10732 | time_t t; | |
10733 | tm.tm_year = 2050 - 1900; | |
10734 | tm.tm_mon = 2 - 1; | |
10735 | tm.tm_mday = 1; | |
10736 | tm.tm_hour = tm.tm_min = tm.tm_sec = 0; | |
10737 | tm.tm_isdst = -1; | |
10738 | ||
10739 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10740 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10741 | on systems that don't support the Olson extension, or don't have the | |
10742 | full zoneinfo tables installed. */ | |
10743 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
7f947b68 | 10744 | |
1b1fe467 | 10745 | t = mktime (&tm); |
7f947b68 | 10746 | |
1b1fe467 CR |
10747 | /* Check that the result is either a failure, or close enough |
10748 | to the correct answer that we can assume the discrepancy is | |
10749 | due to leap seconds. */ | |
10750 | return (t == (time_t) -1 | |
10751 | || (0 < t && answer - 120 <= t && t <= answer + 120)); | |
7175a77f | 10752 | } |
1b1fe467 | 10753 | |
abe2eb5b CR |
10754 | int |
10755 | main () | |
10756 | { | |
1b1fe467 CR |
10757 | time_t t, delta; |
10758 | int i, j; | |
7175a77f | 10759 | |
1b1fe467 CR |
10760 | /* This test makes some buggy mktime implementations loop. |
10761 | Give up after 60 seconds; a mktime slower than that | |
10762 | isn't worth using anyway. */ | |
10763 | alarm (60); | |
10764 | ||
10765 | for (;;) | |
10766 | { | |
10767 | t = (time_t_max << 1) + 1; | |
10768 | if (t <= time_t_max) | |
10769 | break; | |
10770 | time_t_max = t; | |
10771 | } | |
10772 | time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max; | |
10773 | ||
10774 | delta = time_t_max / 997; /* a suitable prime number */ | |
10775 | for (i = 0; i < N_STRINGS; i++) | |
10776 | { | |
10777 | if (tz_strings[i]) | |
10778 | putenv ((char*) tz_strings[i]); | |
10779 | ||
10780 | for (t = 0; t <= time_t_max - delta; t += delta) | |
10781 | if (! mktime_test (t)) | |
10782 | return 1; | |
10783 | if (! (mktime_test ((time_t) 1) | |
10784 | && mktime_test ((time_t) (60 * 60)) | |
10785 | && mktime_test ((time_t) (60 * 60 * 24)))) | |
10786 | return 1; | |
10787 | ||
10788 | for (j = 1; ; j <<= 1) | |
10789 | if (! bigtime_test (j)) | |
10790 | return 1; | |
10791 | else if (INT_MAX / 2 < j) | |
10792 | break; | |
10793 | if (! bigtime_test (INT_MAX)) | |
10794 | return 1; | |
10795 | } | |
10796 | return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ()); | |
abe2eb5b CR |
10797 | } |
10798 | _ACEOF | |
1b1fe467 CR |
10799 | if ac_fn_c_try_run "$LINENO"; then : |
10800 | ac_cv_func_working_mktime=yes | |
e3db237e | 10801 | else |
1b1fe467 CR |
10802 | ac_cv_func_working_mktime=no |
10803 | fi | |
10804 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
10805 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
c920c360 CR |
10806 | fi |
10807 | ||
ccc6cda3 | 10808 | fi |
1b1fe467 CR |
10809 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5 |
10810 | $as_echo "$ac_cv_func_working_mktime" >&6; } | |
10811 | if test $ac_cv_func_working_mktime = no; then | |
10812 | case " $LIBOBJS " in | |
10813 | *" mktime.$ac_objext "* ) ;; | |
10814 | *) LIBOBJS="$LIBOBJS mktime.$ac_objext" | |
10815 | ;; | |
10816 | esac | |
c920c360 | 10817 | |
7175a77f | 10818 | fi |
abe2eb5b | 10819 | |
7175a77f | 10820 | |
1b1fe467 CR |
10821 | |
10822 | for ac_header in argz.h errno.h fcntl.h malloc.h stdio_ext.h | |
10823 | do : | |
10824 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
10825 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
10826 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
10827 | cat >>confdefs.h <<_ACEOF | |
10828 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
e3db237e | 10829 | _ACEOF |
7f947b68 CR |
10830 | |
10831 | fi | |
10832 | ||
7175a77f | 10833 | done |
7175a77f | 10834 | |
7175a77f | 10835 | |
1b1fe467 CR |
10836 | |
10837 | for ac_func in getpagesize | |
10838 | do : | |
10839 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
10840 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
10841 | cat >>confdefs.h <<_ACEOF | |
10842 | #define HAVE_GETPAGESIZE 1 | |
abe2eb5b | 10843 | _ACEOF |
7175a77f | 10844 | |
c920c360 | 10845 | fi |
1b1fe467 | 10846 | done |
2dead0c4 | 10847 | |
1b1fe467 CR |
10848 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 |
10849 | $as_echo_n "checking for working mmap... " >&6; } | |
10850 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : | |
10851 | $as_echo_n "(cached) " >&6 | |
10852 | else | |
10853 | if test "$cross_compiling" = yes; then : | |
10854 | ac_cv_func_mmap_fixed_mapped=no | |
10855 | else | |
10856 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
10857 | /* end confdefs.h. */ | |
10858 | $ac_includes_default | |
10859 | /* malloc might have been renamed as rpl_malloc. */ | |
10860 | #undef malloc | |
7610e0c5 | 10861 | |
1b1fe467 CR |
10862 | /* Thanks to Mike Haertel and Jim Avera for this test. |
10863 | Here is a matrix of mmap possibilities: | |
10864 | mmap private not fixed | |
10865 | mmap private fixed at somewhere currently unmapped | |
10866 | mmap private fixed at somewhere already mapped | |
10867 | mmap shared not fixed | |
10868 | mmap shared fixed at somewhere currently unmapped | |
10869 | mmap shared fixed at somewhere already mapped | |
10870 | For private mappings, we should verify that changes cannot be read() | |
10871 | back from the file, nor mmap's back from the file at a different | |
10872 | address. (There have been systems where private was not correctly | |
10873 | implemented like the infamous i386 svr4.0, and systems where the | |
10874 | VM page cache was not coherent with the file system buffer cache | |
10875 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
10876 | For shared mappings, we should conversely verify that changes get | |
10877 | propagated back to all the places they're supposed to be. | |
7f947b68 | 10878 | |
1b1fe467 CR |
10879 | Grep wants private fixed already mapped. |
10880 | The main things grep needs to know about mmap are: | |
10881 | * does it exist and is it safe to write into the mmap'd area | |
10882 | * how to use it (BSD variants) */ | |
10883 | ||
10884 | #include <fcntl.h> | |
10885 | #include <sys/mman.h> | |
10886 | ||
10887 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H | |
10888 | char *malloc (); | |
10889 | #endif | |
10890 | ||
10891 | /* This mess was copied from the GNU getpagesize.h. */ | |
10892 | #ifndef HAVE_GETPAGESIZE | |
10893 | # ifdef _SC_PAGESIZE | |
10894 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
10895 | # else /* no _SC_PAGESIZE */ | |
10896 | # ifdef HAVE_SYS_PARAM_H | |
10897 | # include <sys/param.h> | |
10898 | # ifdef EXEC_PAGESIZE | |
10899 | # define getpagesize() EXEC_PAGESIZE | |
10900 | # else /* no EXEC_PAGESIZE */ | |
10901 | # ifdef NBPG | |
10902 | # define getpagesize() NBPG * CLSIZE | |
10903 | # ifndef CLSIZE | |
10904 | # define CLSIZE 1 | |
10905 | # endif /* no CLSIZE */ | |
10906 | # else /* no NBPG */ | |
10907 | # ifdef NBPC | |
10908 | # define getpagesize() NBPC | |
10909 | # else /* no NBPC */ | |
10910 | # ifdef PAGESIZE | |
10911 | # define getpagesize() PAGESIZE | |
10912 | # endif /* PAGESIZE */ | |
10913 | # endif /* no NBPC */ | |
10914 | # endif /* no NBPG */ | |
10915 | # endif /* no EXEC_PAGESIZE */ | |
10916 | # else /* no HAVE_SYS_PARAM_H */ | |
10917 | # define getpagesize() 8192 /* punt totally */ | |
10918 | # endif /* no HAVE_SYS_PARAM_H */ | |
10919 | # endif /* no _SC_PAGESIZE */ | |
2dead0c4 | 10920 | |
1b1fe467 | 10921 | #endif /* no HAVE_GETPAGESIZE */ |
7f947b68 | 10922 | |
7175a77f CR |
10923 | int |
10924 | main () | |
10925 | { | |
1b1fe467 CR |
10926 | char *data, *data2, *data3; |
10927 | const char *cdata2; | |
10928 | int i, pagesize; | |
10929 | int fd, fd2; | |
7f947b68 | 10930 | |
1b1fe467 | 10931 | pagesize = getpagesize (); |
7175a77f | 10932 | |
1b1fe467 CR |
10933 | /* First, make a file with some known garbage in it. */ |
10934 | data = (char *) malloc (pagesize); | |
10935 | if (!data) | |
10936 | return 1; | |
10937 | for (i = 0; i < pagesize; ++i) | |
10938 | *(data + i) = rand (); | |
10939 | umask (0); | |
10940 | fd = creat ("conftest.mmap", 0600); | |
10941 | if (fd < 0) | |
10942 | return 2; | |
10943 | if (write (fd, data, pagesize) != pagesize) | |
10944 | return 3; | |
10945 | close (fd); | |
10946 | ||
10947 | /* Next, check that the tail of a page is zero-filled. File must have | |
10948 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
10949 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
10950 | if (fd2 < 0) | |
10951 | return 4; | |
10952 | cdata2 = ""; | |
10953 | if (write (fd2, cdata2, 1) != 1) | |
10954 | return 5; | |
10955 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
10956 | if (data2 == MAP_FAILED) | |
10957 | return 6; | |
10958 | for (i = 0; i < pagesize; ++i) | |
10959 | if (*(data2 + i)) | |
10960 | return 7; | |
10961 | close (fd2); | |
10962 | if (munmap (data2, pagesize)) | |
10963 | return 8; | |
10964 | ||
10965 | /* Next, try to mmap the file at a fixed address which already has | |
10966 | something else allocated at it. If we can, also make sure that | |
10967 | we see the same garbage. */ | |
10968 | fd = open ("conftest.mmap", O_RDWR); | |
10969 | if (fd < 0) | |
10970 | return 9; | |
10971 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, | |
10972 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
10973 | return 10; | |
10974 | for (i = 0; i < pagesize; ++i) | |
10975 | if (*(data + i) != *(data2 + i)) | |
10976 | return 11; | |
10977 | ||
10978 | /* Finally, make sure that changes to the mapped area do not | |
10979 | percolate back to the file as seen by read(). (This is a bug on | |
10980 | some variants of i386 svr4.0.) */ | |
10981 | for (i = 0; i < pagesize; ++i) | |
10982 | *(data2 + i) = *(data2 + i) + 1; | |
10983 | data3 = (char *) malloc (pagesize); | |
10984 | if (!data3) | |
10985 | return 12; | |
10986 | if (read (fd, data3, pagesize) != pagesize) | |
10987 | return 13; | |
10988 | for (i = 0; i < pagesize; ++i) | |
10989 | if (*(data + i) != *(data3 + i)) | |
10990 | return 14; | |
10991 | close (fd); | |
7175a77f CR |
10992 | return 0; |
10993 | } | |
10994 | _ACEOF | |
1b1fe467 CR |
10995 | if ac_fn_c_try_run "$LINENO"; then : |
10996 | ac_cv_func_mmap_fixed_mapped=yes | |
7175a77f | 10997 | else |
1b1fe467 CR |
10998 | ac_cv_func_mmap_fixed_mapped=no |
10999 | fi | |
11000 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11001 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7175a77f | 11002 | fi |
7f947b68 | 11003 | |
1b1fe467 CR |
11004 | fi |
11005 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 | |
11006 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } | |
11007 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
7f947b68 | 11008 | |
1b1fe467 | 11009 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
7f947b68 | 11010 | |
1b1fe467 CR |
11011 | fi |
11012 | rm -f conftest.mmap conftest.txt | |
7f947b68 | 11013 | |
1b1fe467 | 11014 | for ac_func in __argz_count __argz_next __argz_stringify dcgettext mempcpy \ |
67440bc5 | 11015 | munmap stpcpy strcspn |
1b1fe467 CR |
11016 | do : |
11017 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11018 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11019 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11020 | cat >>confdefs.h <<_ACEOF | |
11021 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7175a77f | 11022 | _ACEOF |
7f947b68 | 11023 | |
7175a77f | 11024 | fi |
1b1fe467 | 11025 | done |
7f947b68 | 11026 | |
7f947b68 | 11027 | |
1b1fe467 CR |
11028 | INTL_DEP= INTL_INC= LIBINTL_H= |
11029 | if test "x$USE_INCLUDED_LIBINTL" = "xyes"; then | |
11030 | INTL_DEP='${INTL_LIBDIR}/libintl.a' | |
11031 | INTL_INC='-I${INTL_LIBSRC} -I${INTL_BUILDDIR}' | |
11032 | LIBINTL_H='${INTL_BUILDDIR}/libintl.h' | |
7175a77f | 11033 | fi |
7f947b68 | 11034 | |
7f947b68 | 11035 | |
7175a77f | 11036 | |
1b1fe467 CR |
11037 | |
11038 | ||
11039 | ||
11040 | for ac_header in wctype.h | |
11041 | do : | |
11042 | ac_fn_c_check_header_mongrel "$LINENO" "wctype.h" "ac_cv_header_wctype_h" "$ac_includes_default" | |
11043 | if test "x$ac_cv_header_wctype_h" = xyes; then : | |
11044 | cat >>confdefs.h <<_ACEOF | |
11045 | #define HAVE_WCTYPE_H 1 | |
7175a77f | 11046 | _ACEOF |
7175a77f | 11047 | |
7175a77f | 11048 | fi |
7f947b68 | 11049 | |
7175a77f | 11050 | done |
1b1fe467 CR |
11051 | |
11052 | for ac_header in wchar.h | |
11053 | do : | |
11054 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" | |
11055 | if test "x$ac_cv_header_wchar_h" = xyes; then : | |
11056 | cat >>confdefs.h <<_ACEOF | |
11057 | #define HAVE_WCHAR_H 1 | |
7175a77f | 11058 | _ACEOF |
7f947b68 | 11059 | |
1b1fe467 | 11060 | fi |
7175a77f | 11061 | |
1b1fe467 CR |
11062 | done |
11063 | ||
11064 | for ac_header in langinfo.h | |
11065 | do : | |
11066 | ac_fn_c_check_header_mongrel "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default" | |
11067 | if test "x$ac_cv_header_langinfo_h" = xyes; then : | |
11068 | cat >>confdefs.h <<_ACEOF | |
11069 | #define HAVE_LANGINFO_H 1 | |
11070 | _ACEOF | |
7175a77f | 11071 | |
7f947b68 | 11072 | fi |
1b1fe467 CR |
11073 | |
11074 | done | |
11075 | ||
11076 | ||
c4c90ef8 CR |
11077 | for ac_header in mbstr.h |
11078 | do : | |
11079 | ac_fn_c_check_header_mongrel "$LINENO" "mbstr.h" "ac_cv_header_mbstr_h" "$ac_includes_default" | |
11080 | if test "x$ac_cv_header_mbstr_h" = xyes; then : | |
11081 | cat >>confdefs.h <<_ACEOF | |
11082 | #define HAVE_MBSTR_H 1 | |
11083 | _ACEOF | |
11084 | ||
11085 | fi | |
11086 | ||
11087 | done | |
11088 | ||
11089 | ||
1b1fe467 CR |
11090 | ac_fn_c_check_func "$LINENO" "mbrlen" "ac_cv_func_mbrlen" |
11091 | if test "x$ac_cv_func_mbrlen" = xyes; then : | |
11092 | $as_echo "#define HAVE_MBRLEN 1" >>confdefs.h | |
11093 | ||
7f947b68 | 11094 | fi |
1b1fe467 CR |
11095 | |
11096 | ac_fn_c_check_func "$LINENO" "mbscasecmp" "ac_cv_func_mbscasecmp" | |
11097 | if test "x$ac_cv_func_mbscasecmp" = xyes; then : | |
11098 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
11099 | ||
7f947b68 | 11100 | fi |
7175a77f | 11101 | |
1b1fe467 CR |
11102 | ac_fn_c_check_func "$LINENO" "mbscmp" "ac_cv_func_mbscmp" |
11103 | if test "x$ac_cv_func_mbscmp" = xyes; then : | |
11104 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
7610e0c5 | 11105 | |
1b1fe467 | 11106 | fi |
a82a04b3 | 11107 | |
1b1fe467 CR |
11108 | ac_fn_c_check_func "$LINENO" "mbsnrtowcs" "ac_cv_func_mbsnrtowcs" |
11109 | if test "x$ac_cv_func_mbsnrtowcs" = xyes; then : | |
11110 | $as_echo "#define HAVE_MBSNRTOWCS 1" >>confdefs.h | |
71412226 | 11111 | |
1b1fe467 | 11112 | fi |
f73dda09 | 11113 | |
1b1fe467 CR |
11114 | ac_fn_c_check_func "$LINENO" "mbsrtowcs" "ac_cv_func_mbsrtowcs" |
11115 | if test "x$ac_cv_func_mbsrtowcs" = xyes; then : | |
11116 | $as_echo "#define HAVE_MBSRTOWCS 1" >>confdefs.h | |
11117 | ||
11118 | fi | |
11119 | ||
11120 | ||
11121 | ac_fn_c_check_func "$LINENO" "mbschr" "ac_cv_func_mbschr" | |
11122 | if test "x$ac_cv_func_mbschr" = xyes; then : | |
11123 | $as_echo "#define HAVE_MBSCHR 1" >>confdefs.h | |
7175a77f | 11124 | |
7175a77f | 11125 | else |
1b1fe467 CR |
11126 | case " $LIBOBJS " in |
11127 | *" mbschr.$ac_objext "* ) ;; | |
11128 | *) LIBOBJS="$LIBOBJS mbschr.$ac_objext" | |
11129 | ;; | |
7175a77f | 11130 | esac |
a82a04b3 | 11131 | |
abe2eb5b | 11132 | fi |
7610e0c5 | 11133 | |
7f947b68 CR |
11134 | |
11135 | ||
1b1fe467 CR |
11136 | ac_fn_c_check_func "$LINENO" "wcrtomb" "ac_cv_func_wcrtomb" |
11137 | if test "x$ac_cv_func_wcrtomb" = xyes; then : | |
11138 | $as_echo "#define HAVE_WCRTOMB 1" >>confdefs.h | |
11139 | ||
7175a77f | 11140 | fi |
7f947b68 | 11141 | |
1b1fe467 CR |
11142 | ac_fn_c_check_func "$LINENO" "wcscoll" "ac_cv_func_wcscoll" |
11143 | if test "x$ac_cv_func_wcscoll" = xyes; then : | |
11144 | $as_echo "#define HAVE_WCSCOLL 1" >>confdefs.h | |
11145 | ||
7175a77f | 11146 | fi |
7175a77f | 11147 | |
1b1fe467 CR |
11148 | ac_fn_c_check_func "$LINENO" "wcsdup" "ac_cv_func_wcsdup" |
11149 | if test "x$ac_cv_func_wcsdup" = xyes; then : | |
11150 | $as_echo "#define HAVE_WCSDUP 1" >>confdefs.h | |
f73dda09 | 11151 | |
2dead0c4 CR |
11152 | fi |
11153 | ||
1b1fe467 CR |
11154 | ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth" |
11155 | if test "x$ac_cv_func_wcwidth" = xyes; then : | |
11156 | $as_echo "#define HAVE_WCWIDTH 1" >>confdefs.h | |
11157 | ||
11158 | fi | |
11159 | ||
11160 | ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype" | |
11161 | if test "x$ac_cv_func_wctype" = xyes; then : | |
11162 | $as_echo "#define HAVE_WCTYPE 1" >>confdefs.h | |
11163 | ||
11164 | fi | |
11165 | ||
11166 | ||
11167 | ac_fn_c_check_func "$LINENO" "wcswidth" "ac_cv_func_wcswidth" | |
11168 | if test "x$ac_cv_func_wcswidth" = xyes; then : | |
11169 | $as_echo "#define HAVE_WCSWIDTH 1" >>confdefs.h | |
11170 | ||
e3db237e | 11171 | else |
1b1fe467 CR |
11172 | case " $LIBOBJS " in |
11173 | *" wcswidth.$ac_objext "* ) ;; | |
11174 | *) LIBOBJS="$LIBOBJS wcswidth.$ac_objext" | |
11175 | ;; | |
7175a77f | 11176 | esac |
1b1fe467 CR |
11177 | |
11178 | fi | |
11179 | ||
11180 | ||
11181 | ||
11182 | ||
11183 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc and mbstate_t are properly declared" >&5 | |
11184 | $as_echo_n "checking whether mbrtowc and mbstate_t are properly declared... " >&6; } | |
11185 | if ${ac_cv_func_mbrtowc+:} false; then : | |
11186 | $as_echo_n "(cached) " >&6 | |
11187 | else | |
11188 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11189 | /* end confdefs.h. */ |
1b1fe467 | 11190 | #include <wchar.h> |
7175a77f CR |
11191 | int |
11192 | main () | |
11193 | { | |
1b1fe467 CR |
11194 | wchar_t wc; |
11195 | char const s[] = ""; | |
11196 | size_t n = 1; | |
11197 | mbstate_t state; | |
11198 | return ! (sizeof state && (mbrtowc) (&wc, s, n, &state)); | |
7175a77f CR |
11199 | ; |
11200 | return 0; | |
11201 | } | |
11202 | _ACEOF | |
1b1fe467 CR |
11203 | if ac_fn_c_try_link "$LINENO"; then : |
11204 | ac_cv_func_mbrtowc=yes | |
7175a77f | 11205 | else |
1b1fe467 CR |
11206 | ac_cv_func_mbrtowc=no |
11207 | fi | |
11208 | rm -f core conftest.err conftest.$ac_objext \ | |
11209 | conftest$ac_exeext conftest.$ac_ext | |
7175a77f | 11210 | fi |
1b1fe467 CR |
11211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mbrtowc" >&5 |
11212 | $as_echo "$ac_cv_func_mbrtowc" >&6; } | |
11213 | if test $ac_cv_func_mbrtowc = yes; then | |
7f947b68 | 11214 | |
1b1fe467 | 11215 | $as_echo "#define HAVE_MBRTOWC 1" >>confdefs.h |
7f947b68 | 11216 | |
1b1fe467 | 11217 | fi |
7f947b68 | 11218 | |
1b1fe467 CR |
11219 | if test $ac_cv_func_mbrtowc = yes; then |
11220 | $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h | |
7f947b68 | 11221 | |
7175a77f | 11222 | fi |
7f947b68 | 11223 | |
1b1fe467 CR |
11224 | for ac_func in iswlower iswupper towlower towupper iswctype |
11225 | do : | |
11226 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11227 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11228 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11229 | cat >>confdefs.h <<_ACEOF | |
11230 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7175a77f | 11231 | _ACEOF |
7f947b68 | 11232 | |
7175a77f | 11233 | fi |
1b1fe467 | 11234 | done |
7f947b68 | 11235 | |
7f947b68 | 11236 | |
1b1fe467 CR |
11237 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
11238 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } | |
11239 | if ${bash_cv_langinfo_codeset+:} false; then : | |
7175a77f CR |
11240 | $as_echo_n "(cached) " >&6 |
11241 | else | |
1b1fe467 | 11242 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 11243 | /* end confdefs.h. */ |
1b1fe467 | 11244 | #include <langinfo.h> |
7175a77f CR |
11245 | int |
11246 | main () | |
11247 | { | |
1b1fe467 | 11248 | char* cs = nl_langinfo(CODESET); |
7175a77f CR |
11249 | ; |
11250 | return 0; | |
11251 | } | |
11252 | _ACEOF | |
1b1fe467 CR |
11253 | if ac_fn_c_try_link "$LINENO"; then : |
11254 | bash_cv_langinfo_codeset=yes | |
11255 | else | |
11256 | bash_cv_langinfo_codeset=no | |
11257 | fi | |
11258 | rm -f core conftest.err conftest.$ac_objext \ | |
11259 | conftest$ac_exeext conftest.$ac_ext | |
11260 | fi | |
11261 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_langinfo_codeset" >&5 | |
11262 | $as_echo "$bash_cv_langinfo_codeset" >&6; } | |
11263 | if test $bash_cv_langinfo_codeset = yes; then | |
11264 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h | |
11265 | ||
11266 | fi | |
11267 | ||
11268 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t in wchar.h" >&5 | |
11269 | $as_echo_n "checking for wchar_t in wchar.h... " >&6; } | |
11270 | if ${bash_cv_type_wchar_t+:} false; then : | |
11271 | $as_echo_n "(cached) " >&6 | |
11272 | else | |
11273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11274 | /* end confdefs.h. */ |
1b1fe467 CR |
11275 | #include <wchar.h> |
11276 | ||
7175a77f CR |
11277 | int |
11278 | main () | |
11279 | { | |
1b1fe467 CR |
11280 | |
11281 | wchar_t foo; | |
11282 | foo = 0; | |
11283 | ||
7175a77f | 11284 | ; |
abe2eb5b CR |
11285 | return 0; |
11286 | } | |
11287 | _ACEOF | |
1b1fe467 CR |
11288 | if ac_fn_c_try_compile "$LINENO"; then : |
11289 | bash_cv_type_wchar_t=yes | |
e3db237e | 11290 | else |
1b1fe467 CR |
11291 | bash_cv_type_wchar_t=no |
11292 | fi | |
11293 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11294 | fi | |
11295 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wchar_t" >&5 | |
11296 | $as_echo "$bash_cv_type_wchar_t" >&6; } | |
11297 | if test $bash_cv_type_wchar_t = yes; then | |
11298 | ||
11299 | $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h | |
f73dda09 | 11300 | |
c920c360 | 11301 | fi |
7610e0c5 | 11302 | |
1b1fe467 CR |
11303 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t in wctype.h" >&5 |
11304 | $as_echo_n "checking for wctype_t in wctype.h... " >&6; } | |
11305 | if ${bash_cv_type_wctype_t+:} false; then : | |
11306 | $as_echo_n "(cached) " >&6 | |
7175a77f | 11307 | else |
1b1fe467 CR |
11308 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
11309 | /* end confdefs.h. */ | |
11310 | #include <wctype.h> | |
11311 | int | |
11312 | main () | |
11313 | { | |
7610e0c5 | 11314 | |
1b1fe467 CR |
11315 | wctype_t foo; |
11316 | foo = 0; | |
f73dda09 | 11317 | |
1b1fe467 CR |
11318 | ; |
11319 | return 0; | |
11320 | } | |
11321 | _ACEOF | |
11322 | if ac_fn_c_try_compile "$LINENO"; then : | |
11323 | bash_cv_type_wctype_t=yes | |
11324 | else | |
11325 | bash_cv_type_wctype_t=no | |
e3db237e | 11326 | fi |
7175a77f | 11327 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
abe2eb5b | 11328 | fi |
1b1fe467 CR |
11329 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wctype_t" >&5 |
11330 | $as_echo "$bash_cv_type_wctype_t" >&6; } | |
11331 | if test $bash_cv_type_wctype_t = yes; then | |
7610e0c5 | 11332 | |
1b1fe467 | 11333 | $as_echo "#define HAVE_WCTYPE_T 1" >>confdefs.h |
f73dda09 | 11334 | |
71412226 | 11335 | fi |
7610e0c5 | 11336 | |
1b1fe467 CR |
11337 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t in wctype.h" >&5 |
11338 | $as_echo_n "checking for wint_t in wctype.h... " >&6; } | |
11339 | if ${bash_cv_type_wint_t+:} false; then : | |
7175a77f CR |
11340 | $as_echo_n "(cached) " >&6 |
11341 | else | |
1b1fe467 | 11342 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 11343 | /* end confdefs.h. */ |
1b1fe467 | 11344 | #include <wctype.h> |
7175a77f CR |
11345 | int |
11346 | main () | |
11347 | { | |
1b1fe467 CR |
11348 | |
11349 | wint_t foo; | |
11350 | foo = 0; | |
11351 | ||
7175a77f CR |
11352 | ; |
11353 | return 0; | |
11354 | } | |
11355 | _ACEOF | |
1b1fe467 CR |
11356 | if ac_fn_c_try_compile "$LINENO"; then : |
11357 | bash_cv_type_wint_t=yes | |
11358 | else | |
11359 | bash_cv_type_wint_t=no | |
11360 | fi | |
11361 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11362 | fi | |
11363 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wint_t" >&5 | |
11364 | $as_echo "$bash_cv_type_wint_t" >&6; } | |
11365 | if test $bash_cv_type_wint_t = yes; then | |
11366 | ||
11367 | $as_echo "#define HAVE_WINT_T 1" >>confdefs.h | |
11368 | ||
11369 | fi | |
11370 | ||
11371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcwidth broken with unicode combining characters" >&5 | |
11372 | $as_echo_n "checking for wcwidth broken with unicode combining characters... " >&6; } | |
11373 | if ${bash_cv_wcwidth_broken+:} false; then : | |
11374 | $as_echo_n "(cached) " >&6 | |
11375 | else | |
11376 | if test "$cross_compiling" = yes; then : | |
d76edd30 | 11377 | bash_cv_wcwidth_broken=no |
1b1fe467 CR |
11378 | else |
11379 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11380 | /* end confdefs.h. */ |
1b1fe467 CR |
11381 | |
11382 | #include <unistd.h> | |
11383 | #include <stdlib.h> | |
11384 | #include <stdio.h> | |
11385 | ||
11386 | #include <locale.h> | |
11387 | #include <wchar.h> | |
11388 | ||
11389 | main(c, v) | |
11390 | int c; | |
11391 | char **v; | |
7175a77f | 11392 | { |
1b1fe467 CR |
11393 | int w; |
11394 | ||
11395 | setlocale(LC_ALL, "en_US.UTF-8"); | |
11396 | w = wcwidth (0x0301); | |
11397 | exit (w == 0); /* exit 0 if wcwidth broken */ | |
7175a77f | 11398 | } |
1b1fe467 | 11399 | |
7f947b68 | 11400 | _ACEOF |
1b1fe467 CR |
11401 | if ac_fn_c_try_run "$LINENO"; then : |
11402 | bash_cv_wcwidth_broken=yes | |
7175a77f | 11403 | else |
15baad62 | 11404 | bash_cv_wcwidth_broken=no |
1b1fe467 CR |
11405 | fi |
11406 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11407 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11408 | fi | |
7f947b68 | 11409 | |
abe2eb5b | 11410 | fi |
1b1fe467 CR |
11411 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcwidth_broken" >&5 |
11412 | $as_echo "$bash_cv_wcwidth_broken" >&6; } | |
c7e43312 | 11413 | if test "$bash_cv_wcwidth_broken" = yes; then |
abe2eb5b | 11414 | |
1b1fe467 CR |
11415 | $as_echo "#define WCWIDTH_BROKEN 1" >>confdefs.h |
11416 | ||
11417 | fi | |
2dead0c4 | 11418 | |
1b1fe467 CR |
11419 | if test "$am_cv_func_iconv" = yes; then |
11420 | OLDLIBS="$LIBS" | |
74b8cbb4 | 11421 | LIBS="$LIBS $LIBINTL $LIBICONV" |
1b1fe467 CR |
11422 | for ac_func in locale_charset |
11423 | do : | |
11424 | ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset" | |
11425 | if test "x$ac_cv_func_locale_charset" = xyes; then : | |
11426 | cat >>confdefs.h <<_ACEOF | |
11427 | #define HAVE_LOCALE_CHARSET 1 | |
11428 | _ACEOF | |
2dead0c4 | 11429 | |
c920c360 | 11430 | fi |
1b1fe467 | 11431 | done |
71412226 | 11432 | |
1b1fe467 | 11433 | LIBS="$OLDLIBS" |
7175a77f | 11434 | fi |
c920c360 | 11435 | |
71412226 | 11436 | |
71412226 | 11437 | |
1b1fe467 CR |
11438 | if test "$opt_static_link" != yes; then |
11439 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 | |
11440 | $as_echo_n "checking for dlopen in -ldl... " >&6; } | |
11441 | if ${ac_cv_lib_dl_dlopen+:} false; then : | |
7175a77f CR |
11442 | $as_echo_n "(cached) " >&6 |
11443 | else | |
1b1fe467 CR |
11444 | ac_check_lib_save_LIBS=$LIBS |
11445 | LIBS="-ldl $LIBS" | |
11446 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11447 | /* end confdefs.h. */ |
1b1fe467 CR |
11448 | |
11449 | /* Override any GCC internal prototype to avoid an error. | |
11450 | Use char because int might match the return type of a GCC | |
11451 | builtin and then its argument prototype would still apply. */ | |
11452 | #ifdef __cplusplus | |
11453 | extern "C" | |
11454 | #endif | |
11455 | char dlopen (); | |
7175a77f CR |
11456 | int |
11457 | main () | |
11458 | { | |
1b1fe467 | 11459 | return dlopen (); |
7175a77f CR |
11460 | ; |
11461 | return 0; | |
11462 | } | |
11463 | _ACEOF | |
1b1fe467 CR |
11464 | if ac_fn_c_try_link "$LINENO"; then : |
11465 | ac_cv_lib_dl_dlopen=yes | |
7175a77f | 11466 | else |
1b1fe467 CR |
11467 | ac_cv_lib_dl_dlopen=no |
11468 | fi | |
11469 | rm -f core conftest.err conftest.$ac_objext \ | |
11470 | conftest$ac_exeext conftest.$ac_ext | |
11471 | LIBS=$ac_check_lib_save_LIBS | |
abe2eb5b | 11472 | fi |
1b1fe467 CR |
11473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
11474 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } | |
11475 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : | |
11476 | cat >>confdefs.h <<_ACEOF | |
11477 | #define HAVE_LIBDL 1 | |
11478 | _ACEOF | |
c920c360 | 11479 | |
1b1fe467 CR |
11480 | LIBS="-ldl $LIBS" |
11481 | ||
11482 | fi | |
7175a77f | 11483 | |
1b1fe467 CR |
11484 | for ac_func in dlopen dlclose dlsym |
11485 | do : | |
11486 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11487 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11488 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11489 | cat >>confdefs.h <<_ACEOF | |
11490 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
11491 | _ACEOF | |
7610e0c5 | 11492 | |
71412226 | 11493 | fi |
1b1fe467 | 11494 | done |
7610e0c5 | 11495 | |
7f947b68 | 11496 | fi |
1b1fe467 CR |
11497 | |
11498 | ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h> | |
11499 | /* NetBSD declares sys_siglist in unistd.h. */ | |
11500 | #ifdef HAVE_UNISTD_H | |
11501 | # include <unistd.h> | |
11502 | #endif | |
11503 | ||
11504 | " | |
11505 | if test "x$ac_cv_have_decl_sys_siglist" = xyes; then : | |
11506 | ac_have_decl=1 | |
7175a77f | 11507 | else |
1b1fe467 CR |
11508 | ac_have_decl=0 |
11509 | fi | |
7f947b68 | 11510 | |
7175a77f | 11511 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 11512 | #define HAVE_DECL_SYS_SIGLIST $ac_have_decl |
7175a77f | 11513 | _ACEOF |
7f947b68 | 11514 | |
7f947b68 CR |
11515 | |
11516 | ||
1b1fe467 | 11517 | if test "$ac_cv_func_inet_aton" != 'yes'; then |
7f947b68 | 11518 | |
1b1fe467 CR |
11519 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
11520 | $as_echo_n "checking for inet_aton... " >&6; } | |
11521 | if ${bash_cv_func_inet_aton+:} false; then : | |
7175a77f | 11522 | $as_echo_n "(cached) " >&6 |
e3db237e | 11523 | else |
1b1fe467 | 11524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 11525 | /* end confdefs.h. */ |
1b1fe467 CR |
11526 | |
11527 | #include <sys/types.h> | |
11528 | #include <netinet/in.h> | |
11529 | #include <arpa/inet.h> | |
11530 | struct in_addr ap; | |
7175a77f CR |
11531 | int |
11532 | main () | |
11533 | { | |
1b1fe467 | 11534 | inet_aton("127.0.0.1", &ap); |
7175a77f CR |
11535 | ; |
11536 | return 0; | |
11537 | } | |
11538 | _ACEOF | |
1b1fe467 CR |
11539 | if ac_fn_c_try_link "$LINENO"; then : |
11540 | bash_cv_func_inet_aton=yes | |
7175a77f | 11541 | else |
1b1fe467 | 11542 | bash_cv_func_inet_aton=no |
71412226 | 11543 | fi |
1b1fe467 CR |
11544 | rm -f core conftest.err conftest.$ac_objext \ |
11545 | conftest$ac_exeext conftest.$ac_ext | |
e3db237e | 11546 | fi |
1b1fe467 CR |
11547 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_inet_aton" >&5 |
11548 | $as_echo "$bash_cv_func_inet_aton" >&6; } | |
11549 | if test $bash_cv_func_inet_aton = yes; then | |
11550 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h | |
abe2eb5b | 11551 | |
7175a77f | 11552 | else |
1b1fe467 CR |
11553 | case " $LIBOBJS " in |
11554 | *" inet_aton.$ac_objext "* ) ;; | |
11555 | *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext" | |
11556 | ;; | |
11557 | esac | |
7f947b68 | 11558 | |
1b1fe467 | 11559 | fi |
7f947b68 CR |
11560 | |
11561 | fi | |
11562 | ||
1b1fe467 CR |
11563 | case "$host_os" in |
11564 | irix4*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpwent in -lsun" >&5 | |
11565 | $as_echo_n "checking for getpwent in -lsun... " >&6; } | |
11566 | if ${ac_cv_lib_sun_getpwent+:} false; then : | |
7175a77f CR |
11567 | $as_echo_n "(cached) " >&6 |
11568 | else | |
1b1fe467 CR |
11569 | ac_check_lib_save_LIBS=$LIBS |
11570 | LIBS="-lsun $LIBS" | |
11571 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11572 | /* end confdefs.h. */ |
1b1fe467 CR |
11573 | |
11574 | /* Override any GCC internal prototype to avoid an error. | |
11575 | Use char because int might match the return type of a GCC | |
11576 | builtin and then its argument prototype would still apply. */ | |
11577 | #ifdef __cplusplus | |
11578 | extern "C" | |
11579 | #endif | |
11580 | char getpwent (); | |
7175a77f CR |
11581 | int |
11582 | main () | |
11583 | { | |
1b1fe467 | 11584 | return getpwent (); |
7175a77f CR |
11585 | ; |
11586 | return 0; | |
11587 | } | |
11588 | _ACEOF | |
1b1fe467 CR |
11589 | if ac_fn_c_try_link "$LINENO"; then : |
11590 | ac_cv_lib_sun_getpwent=yes | |
11591 | else | |
11592 | ac_cv_lib_sun_getpwent=no | |
11593 | fi | |
11594 | rm -f core conftest.err conftest.$ac_objext \ | |
11595 | conftest$ac_exeext conftest.$ac_ext | |
11596 | LIBS=$ac_check_lib_save_LIBS | |
11597 | fi | |
11598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sun_getpwent" >&5 | |
11599 | $as_echo "$ac_cv_lib_sun_getpwent" >&6; } | |
11600 | if test "x$ac_cv_lib_sun_getpwent" = xyes; then : | |
11601 | cat >>confdefs.h <<_ACEOF | |
11602 | #define HAVE_LIBSUN 1 | |
7175a77f | 11603 | _ACEOF |
1b1fe467 CR |
11604 | |
11605 | LIBS="-lsun $LIBS" | |
11606 | ||
11607 | fi | |
11608 | ;; | |
11609 | esac | |
11610 | ||
11611 | if test "$ac_cv_func_getpeername" = no; then | |
11612 | ||
11613 | if test "X$bash_cv_have_socklib" = "X"; then | |
11614 | _bash_needmsg= | |
11615 | else | |
11616 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket library" >&5 | |
11617 | $as_echo_n "checking for socket library... " >&6; } | |
11618 | _bash_needmsg=yes | |
11619 | fi | |
11620 | if ${bash_cv_have_socklib+:} false; then : | |
11621 | $as_echo_n "(cached) " >&6 | |
11622 | else | |
11623 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpeername in -lsocket" >&5 | |
11624 | $as_echo_n "checking for getpeername in -lsocket... " >&6; } | |
11625 | if ${ac_cv_lib_socket_getpeername+:} false; then : | |
11626 | $as_echo_n "(cached) " >&6 | |
11627 | else | |
11628 | ac_check_lib_save_LIBS=$LIBS | |
11629 | LIBS="-lsocket -lnsl $LIBS" | |
11630 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11631 | /* end confdefs.h. */ |
1b1fe467 CR |
11632 | |
11633 | /* Override any GCC internal prototype to avoid an error. | |
11634 | Use char because int might match the return type of a GCC | |
11635 | builtin and then its argument prototype would still apply. */ | |
11636 | #ifdef __cplusplus | |
11637 | extern "C" | |
11638 | #endif | |
11639 | char getpeername (); | |
7175a77f CR |
11640 | int |
11641 | main () | |
11642 | { | |
1b1fe467 | 11643 | return getpeername (); |
7175a77f CR |
11644 | ; |
11645 | return 0; | |
11646 | } | |
11647 | _ACEOF | |
1b1fe467 CR |
11648 | if ac_fn_c_try_link "$LINENO"; then : |
11649 | ac_cv_lib_socket_getpeername=yes | |
7175a77f | 11650 | else |
1b1fe467 | 11651 | ac_cv_lib_socket_getpeername=no |
abe2eb5b | 11652 | fi |
1b1fe467 CR |
11653 | rm -f core conftest.err conftest.$ac_objext \ |
11654 | conftest$ac_exeext conftest.$ac_ext | |
11655 | LIBS=$ac_check_lib_save_LIBS | |
11656 | fi | |
11657 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getpeername" >&5 | |
11658 | $as_echo "$ac_cv_lib_socket_getpeername" >&6; } | |
11659 | if test "x$ac_cv_lib_socket_getpeername" = xyes; then : | |
11660 | bash_cv_have_socklib=yes | |
abe2eb5b | 11661 | else |
1b1fe467 | 11662 | bash_cv_have_socklib=no |
7f947b68 CR |
11663 | fi |
11664 | ||
7175a77f | 11665 | fi |
7f947b68 | 11666 | |
1b1fe467 CR |
11667 | if test "X$_bash_needmsg" = Xyes; then |
11668 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_socklib" >&5 | |
11669 | $as_echo "$bash_cv_have_socklib" >&6; } | |
11670 | _bash_needmsg= | |
7175a77f | 11671 | fi |
1b1fe467 CR |
11672 | if test $bash_cv_have_socklib = yes; then |
11673 | # check for libnsl, add it to LIBS if present | |
11674 | if test "X$bash_cv_have_libnsl" = "X"; then | |
11675 | _bash_needmsg= | |
11676 | else | |
11677 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnsl" >&5 | |
11678 | $as_echo_n "checking for libnsl... " >&6; } | |
11679 | _bash_needmsg=yes | |
11680 | fi | |
11681 | if ${bash_cv_have_libnsl+:} false; then : | |
11682 | $as_echo_n "(cached) " >&6 | |
7175a77f | 11683 | else |
1b1fe467 CR |
11684 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
11685 | $as_echo_n "checking for t_open in -lnsl... " >&6; } | |
11686 | if ${ac_cv_lib_nsl_t_open+:} false; then : | |
e3db237e CR |
11687 | $as_echo_n "(cached) " >&6 |
11688 | else | |
1b1fe467 CR |
11689 | ac_check_lib_save_LIBS=$LIBS |
11690 | LIBS="-lnsl $LIBS" | |
11691 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 11692 | /* end confdefs.h. */ |
1b1fe467 CR |
11693 | |
11694 | /* Override any GCC internal prototype to avoid an error. | |
11695 | Use char because int might match the return type of a GCC | |
11696 | builtin and then its argument prototype would still apply. */ | |
11697 | #ifdef __cplusplus | |
11698 | extern "C" | |
11699 | #endif | |
11700 | char t_open (); | |
7175a77f CR |
11701 | int |
11702 | main () | |
11703 | { | |
1b1fe467 | 11704 | return t_open (); |
7175a77f CR |
11705 | ; |
11706 | return 0; | |
11707 | } | |
11708 | _ACEOF | |
1b1fe467 CR |
11709 | if ac_fn_c_try_link "$LINENO"; then : |
11710 | ac_cv_lib_nsl_t_open=yes | |
c920c360 | 11711 | else |
1b1fe467 | 11712 | ac_cv_lib_nsl_t_open=no |
e3db237e | 11713 | fi |
1b1fe467 CR |
11714 | rm -f core conftest.err conftest.$ac_objext \ |
11715 | conftest$ac_exeext conftest.$ac_ext | |
11716 | LIBS=$ac_check_lib_save_LIBS | |
11717 | fi | |
11718 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 | |
11719 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } | |
11720 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : | |
11721 | bash_cv_have_libnsl=yes | |
7175a77f | 11722 | else |
1b1fe467 | 11723 | bash_cv_have_libnsl=no |
7175a77f | 11724 | fi |
71412226 CR |
11725 | |
11726 | fi | |
c920c360 | 11727 | |
1b1fe467 CR |
11728 | if test "X$_bash_needmsg" = Xyes; then |
11729 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_libnsl" >&5 | |
11730 | $as_echo "$bash_cv_have_libnsl" >&6; } | |
11731 | _bash_needmsg= | |
11732 | fi | |
11733 | if test $bash_cv_have_libnsl = yes; then | |
11734 | LIBS="-lsocket -lnsl $LIBS" | |
11735 | else | |
11736 | LIBS="-lsocket $LIBS" | |
11737 | fi | |
11738 | $as_echo "#define HAVE_LIBSOCKET 1" >>confdefs.h | |
2dead0c4 | 11739 | |
1b1fe467 | 11740 | $as_echo "#define HAVE_GETPEERNAME 1" >>confdefs.h |
7175a77f CR |
11741 | |
11742 | fi | |
5f8cde23 | 11743 | |
1b1fe467 CR |
11744 | fi |
11745 | if test "$ac_cv_func_gethostbyname" = no; then | |
11746 | if test "X$bash_cv_have_gethostbyname" = "X"; then | |
11747 | _bash_needmsg=yes | |
11748 | else | |
11749 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 | |
11750 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11751 | _bash_needmsg= | |
11752 | fi | |
11753 | if ${bash_cv_have_gethostbyname+:} false; then : | |
c920c360 CR |
11754 | $as_echo_n "(cached) " >&6 |
11755 | else | |
1b1fe467 | 11756 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11757 | /* end confdefs.h. */ |
1b1fe467 | 11758 | #include <netdb.h> |
abe2eb5b CR |
11759 | int |
11760 | main () | |
11761 | { | |
1b1fe467 CR |
11762 | struct hostent *hp; |
11763 | hp = gethostbyname("localhost"); | |
11764 | ||
abe2eb5b CR |
11765 | ; |
11766 | return 0; | |
11767 | } | |
11768 | _ACEOF | |
1b1fe467 CR |
11769 | if ac_fn_c_try_link "$LINENO"; then : |
11770 | bash_cv_have_gethostbyname=yes | |
7175a77f | 11771 | else |
1b1fe467 | 11772 | bash_cv_have_gethostbyname=no |
7175a77f | 11773 | fi |
1b1fe467 CR |
11774 | rm -f core conftest.err conftest.$ac_objext \ |
11775 | conftest$ac_exeext conftest.$ac_ext | |
7175a77f | 11776 | |
1b1fe467 | 11777 | fi |
7175a77f | 11778 | |
1b1fe467 CR |
11779 | if test "X$_bash_needmsg" = Xyes; then |
11780 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 | |
11781 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11782 | fi | |
11783 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_gethostbyname" >&5 | |
11784 | $as_echo "$bash_cv_have_gethostbyname" >&6; } | |
11785 | if test "$bash_cv_have_gethostbyname" = yes; then | |
11786 | $as_echo "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h | |
7175a77f | 11787 | |
7f947b68 | 11788 | fi |
7175a77f | 11789 | |
7f947b68 | 11790 | fi |
1b1fe467 | 11791 | |
1b1fe467 CR |
11792 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5 |
11793 | $as_echo_n "checking type of array argument to getgroups... " >&6; } | |
11794 | if ${ac_cv_type_getgroups+:} false; then : | |
7f947b68 | 11795 | $as_echo_n "(cached) " >&6 |
71412226 | 11796 | else |
1b1fe467 CR |
11797 | if test "$cross_compiling" = yes; then : |
11798 | ac_cv_type_getgroups=cross | |
11799 | else | |
11800 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7f947b68 | 11801 | /* end confdefs.h. */ |
1b1fe467 | 11802 | /* Thanks to Mike Rendell for this test. */ |
7175a77f | 11803 | $ac_includes_default |
1b1fe467 CR |
11804 | #define NGID 256 |
11805 | #undef MAX | |
11806 | #define MAX(x, y) ((x) > (y) ? (x) : (y)) | |
11807 | ||
7f947b68 CR |
11808 | int |
11809 | main () | |
11810 | { | |
1b1fe467 CR |
11811 | gid_t gidset[NGID]; |
11812 | int i, n; | |
11813 | union { gid_t gval; long int lval; } val; | |
11814 | ||
11815 | val.lval = -1; | |
11816 | for (i = 0; i < NGID; i++) | |
11817 | gidset[i] = val.gval; | |
11818 | n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1, | |
11819 | gidset); | |
11820 | /* Exit non-zero if getgroups seems to require an array of ints. This | |
11821 | happens when gid_t is short int but getgroups modifies an array | |
11822 | of ints. */ | |
11823 | return n > 0 && gidset[n] != val.gval; | |
7f947b68 CR |
11824 | } |
11825 | _ACEOF | |
1b1fe467 CR |
11826 | if ac_fn_c_try_run "$LINENO"; then : |
11827 | ac_cv_type_getgroups=gid_t | |
11828 | else | |
11829 | ac_cv_type_getgroups=int | |
11830 | fi | |
11831 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11832 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11833 | fi | |
11834 | ||
11835 | if test $ac_cv_type_getgroups = cross; then | |
11836 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11837 | /* end confdefs.h. */ |
1b1fe467 CR |
11838 | #include <unistd.h> |
11839 | ||
abe2eb5b | 11840 | _ACEOF |
1b1fe467 CR |
11841 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11842 | $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then : | |
11843 | ac_cv_type_getgroups=gid_t | |
7f947b68 | 11844 | else |
1b1fe467 CR |
11845 | ac_cv_type_getgroups=int |
11846 | fi | |
11847 | rm -f conftest* | |
7f947b68 CR |
11848 | |
11849 | fi | |
1b1fe467 CR |
11850 | fi |
11851 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5 | |
11852 | $as_echo "$ac_cv_type_getgroups" >&6; } | |
11853 | ||
11854 | cat >>confdefs.h <<_ACEOF | |
11855 | #define GETGROUPS_T $ac_cv_type_getgroups | |
11856 | _ACEOF | |
11857 | ||
11858 | ||
11859 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" | |
11860 | if test "x$ac_cv_type_off_t" = xyes; then : | |
7f947b68 | 11861 | |
7f947b68 | 11862 | else |
7f947b68 | 11863 | |
1b1fe467 CR |
11864 | cat >>confdefs.h <<_ACEOF |
11865 | #define off_t long int | |
11866 | _ACEOF | |
e3db237e | 11867 | |
71412226 | 11868 | fi |
7f947b68 | 11869 | |
1b1fe467 CR |
11870 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
11871 | if test "x$ac_cv_type_mode_t" = xyes; then : | |
11872 | ||
7175a77f | 11873 | else |
2dead0c4 | 11874 | |
7175a77f | 11875 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 11876 | #define mode_t int |
7f947b68 | 11877 | _ACEOF |
2dead0c4 | 11878 | |
abe2eb5b | 11879 | fi |
5f8cde23 | 11880 | |
1b1fe467 CR |
11881 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 |
11882 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
11883 | if ${ac_cv_type_uid_t+:} false; then : | |
2dead0c4 CR |
11884 | $as_echo_n "(cached) " >&6 |
11885 | else | |
1b1fe467 | 11886 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11887 | /* end confdefs.h. */ |
1b1fe467 CR |
11888 | #include <sys/types.h> |
11889 | ||
abe2eb5b | 11890 | _ACEOF |
1b1fe467 CR |
11891 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11892 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
11893 | ac_cv_type_uid_t=yes | |
2dead0c4 | 11894 | else |
1b1fe467 CR |
11895 | ac_cv_type_uid_t=no |
11896 | fi | |
11897 | rm -f conftest* | |
7f947b68 CR |
11898 | |
11899 | fi | |
1b1fe467 CR |
11900 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
11901 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
11902 | if test $ac_cv_type_uid_t = no; then | |
2dead0c4 | 11903 | |
1b1fe467 | 11904 | $as_echo "#define uid_t int" >>confdefs.h |
2dead0c4 CR |
11905 | |
11906 | ||
1b1fe467 | 11907 | $as_echo "#define gid_t int" >>confdefs.h |
7f947b68 | 11908 | |
7f947b68 | 11909 | fi |
1b1fe467 CR |
11910 | |
11911 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" | |
11912 | if test "x$ac_cv_type_pid_t" = xyes; then : | |
11913 | ||
7175a77f | 11914 | else |
c920c360 | 11915 | |
abe2eb5b | 11916 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 11917 | #define pid_t int |
abe2eb5b | 11918 | _ACEOF |
c920c360 | 11919 | |
7175a77f | 11920 | fi |
c920c360 | 11921 | |
1b1fe467 CR |
11922 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
11923 | if test "x$ac_cv_type_size_t" = xyes; then : | |
5f8cde23 | 11924 | |
abe2eb5b | 11925 | else |
1b1fe467 CR |
11926 | |
11927 | cat >>confdefs.h <<_ACEOF | |
11928 | #define size_t unsigned int | |
abe2eb5b | 11929 | _ACEOF |
7175a77f | 11930 | |
7f947b68 | 11931 | fi |
7f947b68 | 11932 | |
1b1fe467 CR |
11933 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
11934 | if test "x$ac_cv_type_ssize_t" = xyes; then : | |
11935 | ||
7175a77f | 11936 | else |
7f947b68 | 11937 | |
1b1fe467 CR |
11938 | cat >>confdefs.h <<_ACEOF |
11939 | #define ssize_t int | |
11940 | _ACEOF | |
7f947b68 | 11941 | |
7175a77f | 11942 | fi |
7f947b68 | 11943 | |
1b1fe467 CR |
11944 | ac_fn_c_check_type "$LINENO" "time_t" "ac_cv_type_time_t" "$ac_includes_default" |
11945 | if test "x$ac_cv_type_time_t" = xyes; then : | |
11946 | ||
7f947b68 | 11947 | else |
7175a77f CR |
11948 | |
11949 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 11950 | #define time_t long |
7175a77f CR |
11951 | _ACEOF |
11952 | ||
11953 | fi | |
11954 | ||
1b1fe467 CR |
11955 | |
11956 | ||
11957 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long" >&5 | |
11958 | $as_echo_n "checking for long long... " >&6; } | |
11959 | if ${bash_cv_type_long_long+:} false; then : | |
7f947b68 CR |
11960 | $as_echo_n "(cached) " >&6 |
11961 | else | |
1b1fe467 | 11962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11963 | /* end confdefs.h. */ |
1b1fe467 CR |
11964 | |
11965 | long long ll = 1; int i = 63; | |
abe2eb5b CR |
11966 | int |
11967 | main () | |
11968 | { | |
1b1fe467 CR |
11969 | |
11970 | long long llm = (long long) -1; | |
11971 | return ll << i | ll >> i | llm / ll | llm % ll; | |
11972 | ||
abe2eb5b CR |
11973 | ; |
11974 | return 0; | |
11975 | } | |
e3db237e | 11976 | _ACEOF |
1b1fe467 CR |
11977 | if ac_fn_c_try_link "$LINENO"; then : |
11978 | bash_cv_type_long_long='long long' | |
11979 | else | |
11980 | bash_cv_type_long_long='long' | |
11981 | fi | |
11982 | rm -f core conftest.err conftest.$ac_objext \ | |
11983 | conftest$ac_exeext conftest.$ac_ext | |
11984 | fi | |
11985 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_long_long" >&5 | |
11986 | $as_echo "$bash_cv_type_long_long" >&6; } | |
11987 | if test "$bash_cv_type_long_long" = 'long long'; then | |
11988 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h | |
11989 | ||
11990 | fi | |
11991 | ||
11992 | ||
11993 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 | |
11994 | $as_echo_n "checking for unsigned long long... " >&6; } | |
11995 | if ${bash_cv_type_unsigned_long_long+:} false; then : | |
11996 | $as_echo_n "(cached) " >&6 | |
11997 | else | |
11998 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11999 | /* end confdefs.h. */ |
1b1fe467 CR |
12000 | |
12001 | unsigned long long ull = 1; int i = 63; | |
abe2eb5b CR |
12002 | int |
12003 | main () | |
12004 | { | |
1b1fe467 CR |
12005 | |
12006 | unsigned long long ullmax = (unsigned long long) -1; | |
12007 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
12008 | ||
abe2eb5b CR |
12009 | ; |
12010 | return 0; | |
12011 | } | |
7610e0c5 | 12012 | _ACEOF |
1b1fe467 CR |
12013 | if ac_fn_c_try_link "$LINENO"; then : |
12014 | bash_cv_type_unsigned_long_long='unsigned long long' | |
abe2eb5b | 12015 | else |
1b1fe467 | 12016 | bash_cv_type_unsigned_long_long='unsigned long' |
7f947b68 | 12017 | fi |
1b1fe467 CR |
12018 | rm -f core conftest.err conftest.$ac_objext \ |
12019 | conftest$ac_exeext conftest.$ac_ext | |
2dead0c4 | 12020 | fi |
1b1fe467 CR |
12021 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_unsigned_long_long" >&5 |
12022 | $as_echo "$bash_cv_type_unsigned_long_long" >&6; } | |
12023 | if test "$bash_cv_type_unsigned_long_long" = 'unsigned long long'; then | |
12024 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h | |
2dead0c4 | 12025 | |
7175a77f | 12026 | fi |
2dead0c4 | 12027 | |
2dead0c4 | 12028 | |
1b1fe467 CR |
12029 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 |
12030 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
12031 | if ${ac_cv_type_signal+:} false; then : | |
abe2eb5b | 12032 | $as_echo_n "(cached) " >&6 |
7610e0c5 | 12033 | else |
1b1fe467 | 12034 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 12035 | /* end confdefs.h. */ |
1b1fe467 CR |
12036 | #include <sys/types.h> |
12037 | #include <signal.h> | |
12038 | ||
abe2eb5b CR |
12039 | int |
12040 | main () | |
12041 | { | |
1b1fe467 | 12042 | return *(signal (0, 0)) (0) == 1; |
abe2eb5b CR |
12043 | ; |
12044 | return 0; | |
12045 | } | |
12046 | _ACEOF | |
1b1fe467 CR |
12047 | if ac_fn_c_try_compile "$LINENO"; then : |
12048 | ac_cv_type_signal=int | |
12049 | else | |
12050 | ac_cv_type_signal=void | |
12051 | fi | |
12052 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
12053 | fi | |
12054 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
12055 | $as_echo "$ac_cv_type_signal" >&6; } | |
12056 | ||
12057 | cat >>confdefs.h <<_ACEOF | |
12058 | #define RETSIGTYPE $ac_cv_type_signal | |
7175a77f | 12059 | _ACEOF |
1b1fe467 CR |
12060 | |
12061 | ||
12062 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t in signal.h" >&5 | |
12063 | $as_echo_n "checking for sig_atomic_t in signal.h... " >&6; } | |
12064 | if ${ac_cv_have_sig_atomic_t+:} false; then : | |
12065 | $as_echo_n "(cached) " >&6 | |
12066 | else | |
12067 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7175a77f | 12068 | /* end confdefs.h. */ |
1b1fe467 CR |
12069 | |
12070 | #include <signal.h> | |
12071 | ||
7175a77f CR |
12072 | int |
12073 | main () | |
12074 | { | |
1b1fe467 | 12075 | sig_atomic_t x; |
7175a77f CR |
12076 | ; |
12077 | return 0; | |
12078 | } | |
12079 | _ACEOF | |
1b1fe467 CR |
12080 | if ac_fn_c_try_link "$LINENO"; then : |
12081 | ac_cv_have_sig_atomic_t=yes | |
12082 | else | |
12083 | ac_cv_have_sig_atomic_t=no | |
12084 | fi | |
12085 | rm -f core conftest.err conftest.$ac_objext \ | |
12086 | conftest$ac_exeext conftest.$ac_ext | |
12087 | fi | |
12088 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sig_atomic_t" >&5 | |
12089 | $as_echo "$ac_cv_have_sig_atomic_t" >&6; } | |
12090 | if test "$ac_cv_have_sig_atomic_t" = "no" | |
12091 | then | |
12092 | ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "$ac_includes_default" | |
12093 | if test "x$ac_cv_type_sig_atomic_t" = xyes; then : | |
12094 | ||
abe2eb5b | 12095 | else |
7610e0c5 | 12096 | |
1b1fe467 CR |
12097 | cat >>confdefs.h <<_ACEOF |
12098 | #define sig_atomic_t int | |
12099 | _ACEOF | |
12100 | ||
12101 | fi | |
12102 | ||
7f947b68 | 12103 | fi |
7610e0c5 CR |
12104 | |
12105 | ||
1b1fe467 CR |
12106 | # The cast to long int works around a bug in the HP C Compiler |
12107 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12108 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12109 | # This bug is HP SR number 8606223364. | |
12110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char" >&5 | |
12111 | $as_echo_n "checking size of char... " >&6; } | |
12112 | if ${ac_cv_sizeof_char+:} false; then : | |
12113 | $as_echo_n "(cached) " >&6 | |
12114 | else | |
12115 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char))" "ac_cv_sizeof_char" "$ac_includes_default"; then : | |
7610e0c5 | 12116 | |
1b1fe467 CR |
12117 | else |
12118 | if test "$ac_cv_type_char" = yes; then | |
12119 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12120 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12121 | as_fn_error 77 "cannot compute sizeof (char) | |
12122 | See \`config.log' for more details" "$LINENO" 5; } | |
12123 | else | |
12124 | ac_cv_sizeof_char=0 | |
12125 | fi | |
2dead0c4 | 12126 | fi |
7f947b68 | 12127 | |
7175a77f | 12128 | fi |
1b1fe467 CR |
12129 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char" >&5 |
12130 | $as_echo "$ac_cv_sizeof_char" >&6; } | |
12131 | ||
12132 | ||
e3db237e | 12133 | |
7175a77f | 12134 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 12135 | #define SIZEOF_CHAR $ac_cv_sizeof_char |
2dead0c4 CR |
12136 | _ACEOF |
12137 | ||
1b1fe467 CR |
12138 | |
12139 | # The cast to long int works around a bug in the HP C Compiler | |
12140 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12141 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12142 | # This bug is HP SR number 8606223364. | |
12143 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 | |
12144 | $as_echo_n "checking size of short... " >&6; } | |
12145 | if ${ac_cv_sizeof_short+:} false; then : | |
12146 | $as_echo_n "(cached) " >&6 | |
12147 | else | |
12148 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : | |
12149 | ||
12150 | else | |
12151 | if test "$ac_cv_type_short" = yes; then | |
12152 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12153 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12154 | as_fn_error 77 "cannot compute sizeof (short) | |
12155 | See \`config.log' for more details" "$LINENO" 5; } | |
12156 | else | |
12157 | ac_cv_sizeof_short=0 | |
12158 | fi | |
7610e0c5 | 12159 | fi |
7f947b68 CR |
12160 | |
12161 | fi | |
1b1fe467 CR |
12162 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
12163 | $as_echo "$ac_cv_sizeof_short" >&6; } | |
7f947b68 | 12164 | |
7175a77f | 12165 | |
1b1fe467 CR |
12166 | |
12167 | cat >>confdefs.h <<_ACEOF | |
12168 | #define SIZEOF_SHORT $ac_cv_sizeof_short | |
2dead0c4 | 12169 | _ACEOF |
e3db237e | 12170 | |
71412226 | 12171 | |
1b1fe467 CR |
12172 | # The cast to long int works around a bug in the HP C Compiler |
12173 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12174 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12175 | # This bug is HP SR number 8606223364. | |
12176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 | |
12177 | $as_echo_n "checking size of int... " >&6; } | |
12178 | if ${ac_cv_sizeof_int+:} false; then : | |
12179 | $as_echo_n "(cached) " >&6 | |
71412226 | 12180 | else |
1b1fe467 | 12181 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : |
7610e0c5 | 12182 | |
1b1fe467 CR |
12183 | else |
12184 | if test "$ac_cv_type_int" = yes; then | |
12185 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12186 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12187 | as_fn_error 77 "cannot compute sizeof (int) | |
12188 | See \`config.log' for more details" "$LINENO" 5; } | |
12189 | else | |
12190 | ac_cv_sizeof_int=0 | |
12191 | fi | |
2dead0c4 | 12192 | fi |
5f8cde23 | 12193 | |
7175a77f | 12194 | fi |
1b1fe467 CR |
12195 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
12196 | $as_echo "$ac_cv_sizeof_int" >&6; } | |
12197 | ||
12198 | ||
e3db237e | 12199 | |
7f947b68 | 12200 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 12201 | #define SIZEOF_INT $ac_cv_sizeof_int |
7f947b68 | 12202 | _ACEOF |
71412226 | 12203 | |
7f947b68 | 12204 | |
1b1fe467 CR |
12205 | # The cast to long int works around a bug in the HP C Compiler |
12206 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12207 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12208 | # This bug is HP SR number 8606223364. | |
12209 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 | |
12210 | $as_echo_n "checking size of long... " >&6; } | |
12211 | if ${ac_cv_sizeof_long+:} false; then : | |
abe2eb5b CR |
12212 | $as_echo_n "(cached) " >&6 |
12213 | else | |
1b1fe467 CR |
12214 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : |
12215 | ||
abe2eb5b | 12216 | else |
1b1fe467 CR |
12217 | if test "$ac_cv_type_long" = yes; then |
12218 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12219 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12220 | as_fn_error 77 "cannot compute sizeof (long) | |
12221 | See \`config.log' for more details" "$LINENO" 5; } | |
12222 | else | |
12223 | ac_cv_sizeof_long=0 | |
12224 | fi | |
12225 | fi | |
71412226 | 12226 | |
2dead0c4 | 12227 | fi |
1b1fe467 CR |
12228 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 |
12229 | $as_echo "$ac_cv_sizeof_long" >&6; } | |
e3db237e | 12230 | |
e3db237e | 12231 | |
5f8cde23 | 12232 | |
1b1fe467 CR |
12233 | cat >>confdefs.h <<_ACEOF |
12234 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
12235 | _ACEOF | |
12236 | ||
12237 | ||
12238 | # The cast to long int works around a bug in the HP C Compiler | |
12239 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12240 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12241 | # This bug is HP SR number 8606223364. | |
12242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5 | |
12243 | $as_echo_n "checking size of char *... " >&6; } | |
12244 | if ${ac_cv_sizeof_char_p+:} false; then : | |
12245 | $as_echo_n "(cached) " >&6 | |
12246 | else | |
12247 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then : | |
12248 | ||
12249 | else | |
12250 | if test "$ac_cv_type_char_p" = yes; then | |
12251 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12252 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12253 | as_fn_error 77 "cannot compute sizeof (char *) | |
12254 | See \`config.log' for more details" "$LINENO" 5; } | |
12255 | else | |
12256 | ac_cv_sizeof_char_p=0 | |
12257 | fi | |
abe2eb5b | 12258 | fi |
7f947b68 | 12259 | |
7175a77f | 12260 | fi |
1b1fe467 CR |
12261 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5 |
12262 | $as_echo "$ac_cv_sizeof_char_p" >&6; } | |
12263 | ||
12264 | ||
e3db237e | 12265 | |
2dead0c4 | 12266 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 12267 | #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p |
2dead0c4 | 12268 | _ACEOF |
5f8cde23 | 12269 | |
e3db237e | 12270 | |
1b1fe467 CR |
12271 | # The cast to long int works around a bug in the HP C Compiler |
12272 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12273 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12274 | # This bug is HP SR number 8606223364. | |
12275 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 | |
12276 | $as_echo_n "checking size of double... " >&6; } | |
12277 | if ${ac_cv_sizeof_double+:} false; then : | |
7175a77f CR |
12278 | $as_echo_n "(cached) " >&6 |
12279 | else | |
1b1fe467 CR |
12280 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"; then : |
12281 | ||
12282 | else | |
12283 | if test "$ac_cv_type_double" = yes; then | |
12284 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12285 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12286 | as_fn_error 77 "cannot compute sizeof (double) | |
12287 | See \`config.log' for more details" "$LINENO" 5; } | |
12288 | else | |
12289 | ac_cv_sizeof_double=0 | |
12290 | fi | |
12291 | fi | |
12292 | ||
12293 | fi | |
12294 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 | |
12295 | $as_echo "$ac_cv_sizeof_double" >&6; } | |
12296 | ||
12297 | ||
12298 | ||
12299 | cat >>confdefs.h <<_ACEOF | |
12300 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double | |
7175a77f | 12301 | _ACEOF |
1b1fe467 CR |
12302 | |
12303 | ||
12304 | # The cast to long int works around a bug in the HP C Compiler | |
12305 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12306 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12307 | # This bug is HP SR number 8606223364. | |
12308 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 | |
12309 | $as_echo_n "checking size of long long... " >&6; } | |
12310 | if ${ac_cv_sizeof_long_long+:} false; then : | |
12311 | $as_echo_n "(cached) " >&6 | |
2dead0c4 | 12312 | else |
1b1fe467 | 12313 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : |
7f947b68 | 12314 | |
1b1fe467 CR |
12315 | else |
12316 | if test "$ac_cv_type_long_long" = yes; then | |
12317 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12318 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12319 | as_fn_error 77 "cannot compute sizeof (long long) | |
12320 | See \`config.log' for more details" "$LINENO" 5; } | |
12321 | else | |
12322 | ac_cv_sizeof_long_long=0 | |
12323 | fi | |
2dead0c4 | 12324 | fi |
c920c360 | 12325 | |
1b1fe467 CR |
12326 | fi |
12327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 | |
12328 | $as_echo "$ac_cv_sizeof_long_long" >&6; } | |
2dead0c4 | 12329 | |
c920c360 | 12330 | |
c920c360 | 12331 | |
1b1fe467 CR |
12332 | cat >>confdefs.h <<_ACEOF |
12333 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
12334 | _ACEOF | |
12335 | ||
12336 | ||
12337 | ||
12338 | ac_fn_c_check_type "$LINENO" "u_int" "ac_cv_type_u_int" "$ac_includes_default" | |
12339 | if test "x$ac_cv_type_u_int" = xyes; then : | |
12340 | ||
ccc6cda3 | 12341 | else |
2dead0c4 CR |
12342 | |
12343 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 12344 | #define u_int unsigned int |
7610e0c5 | 12345 | _ACEOF |
e3db237e | 12346 | |
c920c360 | 12347 | fi |
e3db237e | 12348 | |
1b1fe467 CR |
12349 | ac_fn_c_check_type "$LINENO" "u_long" "ac_cv_type_u_long" "$ac_includes_default" |
12350 | if test "x$ac_cv_type_u_long" = xyes; then : | |
12351 | ||
abe2eb5b | 12352 | else |
1b1fe467 CR |
12353 | |
12354 | cat >>confdefs.h <<_ACEOF | |
12355 | #define u_long unsigned long | |
abe2eb5b | 12356 | _ACEOF |
7175a77f | 12357 | |
c920c360 | 12358 | fi |
7175a77f | 12359 | |
1b1fe467 CR |
12360 | |
12361 | ||
12362 | if test "$ac_cv_sizeof_short" = 2; then | |
12363 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12364 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12365 | ||
7175a77f | 12366 | else |
7175a77f | 12367 | |
1b1fe467 CR |
12368 | cat >>confdefs.h <<_ACEOF |
12369 | #define bits16_t short | |
12370 | _ACEOF | |
7175a77f | 12371 | |
abe2eb5b | 12372 | fi |
2dead0c4 | 12373 | |
1b1fe467 CR |
12374 | elif test "$ac_cv_sizeof_char" = 2; then |
12375 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12376 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12377 | ||
7175a77f CR |
12378 | else |
12379 | ||
12380 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 12381 | #define bits16_t char |
7175a77f | 12382 | _ACEOF |
f73dda09 | 12383 | |
7175a77f | 12384 | fi |
a82a04b3 | 12385 | |
7175a77f | 12386 | else |
1b1fe467 CR |
12387 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" |
12388 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12389 | ||
abe2eb5b | 12390 | else |
1b1fe467 CR |
12391 | |
12392 | cat >>confdefs.h <<_ACEOF | |
12393 | #define bits16_t short | |
abe2eb5b | 12394 | _ACEOF |
7175a77f | 12395 | |
abe2eb5b | 12396 | fi |
7f947b68 | 12397 | |
1b1fe467 CR |
12398 | fi |
12399 | ||
12400 | ||
12401 | if test "$ac_cv_sizeof_short" = 2; then | |
12402 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12403 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12404 | ||
c920c360 | 12405 | else |
e3db237e | 12406 | |
1b1fe467 CR |
12407 | cat >>confdefs.h <<_ACEOF |
12408 | #define u_bits16_t unsigned short | |
12409 | _ACEOF | |
e3db237e | 12410 | |
c920c360 | 12411 | fi |
c920c360 | 12412 | |
1b1fe467 CR |
12413 | elif test "$ac_cv_sizeof_char" = 2; then |
12414 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12415 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12416 | ||
12417 | else | |
12418 | ||
12419 | cat >>confdefs.h <<_ACEOF | |
12420 | #define u_bits16_t unsigned char | |
12421 | _ACEOF | |
12422 | ||
c920c360 | 12423 | fi |
1b1fe467 CR |
12424 | |
12425 | else | |
12426 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12427 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
12428 | ||
7f947b68 | 12429 | else |
2dead0c4 | 12430 | |
7f947b68 | 12431 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 12432 | #define u_bits16_t unsigned short |
5e4a95c7 | 12433 | _ACEOF |
7f947b68 | 12434 | |
c920c360 | 12435 | fi |
abe2eb5b | 12436 | |
c920c360 | 12437 | fi |
e3db237e | 12438 | |
7f947b68 | 12439 | |
1b1fe467 CR |
12440 | if test "$ac_cv_sizeof_int" = 4; then |
12441 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12442 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
2dead0c4 | 12443 | |
2dead0c4 | 12444 | else |
1b1fe467 CR |
12445 | |
12446 | cat >>confdefs.h <<_ACEOF | |
12447 | #define bits32_t int | |
7175a77f | 12448 | _ACEOF |
7175a77f | 12449 | |
7175a77f | 12450 | fi |
2dead0c4 | 12451 | |
1b1fe467 CR |
12452 | elif test "$ac_cv_sizeof_long" = 4; then |
12453 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12454 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12455 | ||
7f947b68 | 12456 | else |
2dead0c4 | 12457 | |
1b1fe467 CR |
12458 | cat >>confdefs.h <<_ACEOF |
12459 | #define bits32_t long | |
12460 | _ACEOF | |
7f947b68 | 12461 | |
7175a77f | 12462 | fi |
7f947b68 | 12463 | |
1b1fe467 CR |
12464 | else |
12465 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12466 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12467 | ||
7175a77f | 12468 | else |
7f947b68 CR |
12469 | |
12470 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 12471 | #define bits32_t int |
7610e0c5 | 12472 | _ACEOF |
7f947b68 | 12473 | |
7175a77f | 12474 | fi |
7f947b68 | 12475 | |
1b1fe467 CR |
12476 | fi |
12477 | ||
12478 | ||
12479 | if test "$ac_cv_sizeof_int" = 4; then | |
12480 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12481 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
12482 | ||
7f947b68 | 12483 | else |
abe2eb5b | 12484 | |
1b1fe467 CR |
12485 | cat >>confdefs.h <<_ACEOF |
12486 | #define u_bits32_t unsigned int | |
12487 | _ACEOF | |
12488 | ||
c920c360 | 12489 | fi |
7f947b68 | 12490 | |
1b1fe467 CR |
12491 | elif test "$ac_cv_sizeof_long" = 4; then |
12492 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12493 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
12494 | ||
7175a77f | 12495 | else |
7175a77f | 12496 | |
1b1fe467 CR |
12497 | cat >>confdefs.h <<_ACEOF |
12498 | #define u_bits32_t unsigned long | |
12499 | _ACEOF | |
7175a77f CR |
12500 | |
12501 | fi | |
7f947b68 | 12502 | |
1b1fe467 CR |
12503 | else |
12504 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12505 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
12506 | ||
7175a77f | 12507 | else |
7f947b68 CR |
12508 | |
12509 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 12510 | #define u_bits32_t unsigned int |
abe2eb5b | 12511 | _ACEOF |
7610e0c5 | 12512 | |
7175a77f | 12513 | fi |
7f947b68 | 12514 | |
1b1fe467 CR |
12515 | fi |
12516 | ||
12517 | ||
12518 | if test "$ac_cv_sizeof_char_p" = 8; then | |
12519 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12520 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12521 | ||
7f947b68 | 12522 | else |
1b1fe467 CR |
12523 | |
12524 | cat >>confdefs.h <<_ACEOF | |
12525 | #define bits64_t char * | |
7175a77f | 12526 | _ACEOF |
7610e0c5 | 12527 | |
2dead0c4 | 12528 | fi |
c920c360 | 12529 | |
1b1fe467 CR |
12530 | elif test "$ac_cv_sizeof_double" = 8; then |
12531 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12532 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12533 | ||
7175a77f | 12534 | else |
7175a77f | 12535 | |
1b1fe467 CR |
12536 | cat >>confdefs.h <<_ACEOF |
12537 | #define bits64_t double | |
12538 | _ACEOF | |
7175a77f CR |
12539 | |
12540 | fi | |
c920c360 | 12541 | |
1b1fe467 CR |
12542 | elif test -n "$ac_cv_type_long_long" && test "$ac_cv_sizeof_long_long" = 8; then |
12543 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12544 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12545 | ||
12546 | else | |
12547 | ||
12548 | cat >>confdefs.h <<_ACEOF | |
12549 | #define bits64_t long long | |
12550 | _ACEOF | |
12551 | ||
7175a77f | 12552 | fi |
1b1fe467 CR |
12553 | |
12554 | elif test "$ac_cv_sizeof_long" = 8; then | |
12555 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12556 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12557 | ||
7175a77f | 12558 | else |
7f947b68 CR |
12559 | |
12560 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 12561 | #define bits64_t long |
7f947b68 CR |
12562 | _ACEOF |
12563 | ||
7175a77f | 12564 | fi |
7f947b68 | 12565 | |
7175a77f | 12566 | else |
1b1fe467 CR |
12567 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" |
12568 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12569 | ||
7610e0c5 | 12570 | else |
1b1fe467 CR |
12571 | |
12572 | cat >>confdefs.h <<_ACEOF | |
12573 | #define bits64_t double | |
7175a77f | 12574 | _ACEOF |
1b1fe467 CR |
12575 | |
12576 | fi | |
12577 | ||
12578 | fi | |
12579 | ||
12580 | ||
12581 | ||
12582 | if test "$ac_cv_sizeof_int" = "$ac_cv_sizeof_char_p"; then | |
12583 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12584 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12585 | ||
2dead0c4 | 12586 | else |
2dead0c4 | 12587 | |
1b1fe467 CR |
12588 | cat >>confdefs.h <<_ACEOF |
12589 | #define ptrdiff_t int | |
12590 | _ACEOF | |
12591 | ||
7f947b68 | 12592 | fi |
7f947b68 | 12593 | |
1b1fe467 CR |
12594 | elif test "$ac_cv_sizeof_long" = "$ac_cv_sizeof_char_p"; then |
12595 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12596 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12597 | ||
7175a77f | 12598 | else |
7f947b68 | 12599 | |
1b1fe467 CR |
12600 | cat >>confdefs.h <<_ACEOF |
12601 | #define ptrdiff_t long | |
12602 | _ACEOF | |
7f947b68 | 12603 | |
7175a77f | 12604 | fi |
7f947b68 | 12605 | |
1b1fe467 CR |
12606 | elif test "$ac_cv_type_long_long" = yes && test "$ac_cv_sizeof_long_long" = "$ac_cv_sizeof_char_p"; then |
12607 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12608 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12609 | ||
12610 | else | |
12611 | ||
12612 | cat >>confdefs.h <<_ACEOF | |
12613 | #define ptrdiff_t long long | |
12614 | _ACEOF | |
12615 | ||
7175a77f | 12616 | fi |
1b1fe467 CR |
12617 | |
12618 | else | |
12619 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12620 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12621 | ||
c920c360 | 12622 | else |
abe2eb5b | 12623 | |
7f947b68 | 12624 | cat >>confdefs.h <<_ACEOF |
7175a77f | 12625 | #define ptrdiff_t int |
7f947b68 CR |
12626 | _ACEOF |
12627 | ||
5e4a95c7 | 12628 | fi |
b709b946 | 12629 | |
7175a77f | 12630 | fi |
abe2eb5b | 12631 | |
e3db237e | 12632 | |
1b1fe467 | 12633 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5 |
7175a77f | 12634 | $as_echo_n "checking whether stat file-mode macros are broken... " >&6; } |
1b1fe467 | 12635 | if ${ac_cv_header_stat_broken+:} false; then : |
7175a77f CR |
12636 | $as_echo_n "(cached) " >&6 |
12637 | else | |
1b1fe467 | 12638 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
12639 | /* end confdefs.h. */ |
12640 | #include <sys/types.h> | |
12641 | #include <sys/stat.h> | |
e3db237e | 12642 | |
7175a77f CR |
12643 | #if defined S_ISBLK && defined S_IFDIR |
12644 | extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1]; | |
12645 | #endif | |
e3db237e | 12646 | |
7175a77f CR |
12647 | #if defined S_ISBLK && defined S_IFCHR |
12648 | extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1]; | |
12649 | #endif | |
7f947b68 | 12650 | |
7175a77f CR |
12651 | #if defined S_ISLNK && defined S_IFREG |
12652 | extern char c3[S_ISLNK (S_IFREG) ? -1 : 1]; | |
12653 | #endif | |
7f947b68 | 12654 | |
7175a77f CR |
12655 | #if defined S_ISSOCK && defined S_IFREG |
12656 | extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1]; | |
12657 | #endif | |
7f947b68 | 12658 | |
7175a77f | 12659 | _ACEOF |
1b1fe467 | 12660 | if ac_fn_c_try_compile "$LINENO"; then : |
7175a77f | 12661 | ac_cv_header_stat_broken=no |
2dead0c4 | 12662 | else |
1b1fe467 | 12663 | ac_cv_header_stat_broken=yes |
7175a77f | 12664 | fi |
7175a77f CR |
12665 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
12666 | fi | |
1b1fe467 | 12667 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5 |
7175a77f CR |
12668 | $as_echo "$ac_cv_header_stat_broken" >&6; } |
12669 | if test $ac_cv_header_stat_broken = yes; then | |
12670 | ||
1b1fe467 | 12671 | $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h |
2dead0c4 | 12672 | |
7f947b68 CR |
12673 | fi |
12674 | ||
e3db237e | 12675 | |
1b1fe467 | 12676 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether #! works in shell scripts" >&5 |
7175a77f | 12677 | $as_echo_n "checking whether #! works in shell scripts... " >&6; } |
1b1fe467 | 12678 | if ${ac_cv_sys_interpreter+:} false; then : |
7175a77f CR |
12679 | $as_echo_n "(cached) " >&6 |
12680 | else | |
12681 | echo '#! /bin/cat | |
12682 | exit 69 | |
12683 | ' >conftest | |
12684 | chmod u+x conftest | |
12685 | (SHELL=/bin/sh; export SHELL; ./conftest >/dev/null 2>&1) | |
12686 | if test $? -ne 69; then | |
12687 | ac_cv_sys_interpreter=yes | |
7f947b68 | 12688 | else |
7175a77f CR |
12689 | ac_cv_sys_interpreter=no |
12690 | fi | |
12691 | rm -f conftest | |
12692 | fi | |
1b1fe467 | 12693 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_interpreter" >&5 |
7175a77f CR |
12694 | $as_echo "$ac_cv_sys_interpreter" >&6; } |
12695 | interpval=$ac_cv_sys_interpreter | |
7f947b68 | 12696 | |
7175a77f | 12697 | if test $ac_cv_sys_interpreter = yes; then |
1b1fe467 | 12698 | $as_echo "#define HAVE_HASH_BANG_EXEC 1" >>confdefs.h |
7f947b68 CR |
12699 | |
12700 | fi | |
12701 | ||
7175a77f | 12702 | if test "$ac_cv_func_lstat" = "no"; then |
1b1fe467 | 12703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lstat" >&5 |
7175a77f | 12704 | $as_echo_n "checking for lstat... " >&6; } |
1b1fe467 | 12705 | if ${bash_cv_func_lstat+:} false; then : |
7175a77f | 12706 | $as_echo_n "(cached) " >&6 |
7f947b68 | 12707 | else |
1b1fe467 | 12708 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 12709 | /* end confdefs.h. */ |
7f947b68 | 12710 | |
7175a77f CR |
12711 | #include <sys/types.h> |
12712 | #include <sys/stat.h> | |
abe2eb5b | 12713 | |
7175a77f CR |
12714 | int |
12715 | main () | |
12716 | { | |
12717 | lstat(".",(struct stat *)0); | |
12718 | ; | |
12719 | return 0; | |
12720 | } | |
7f947b68 | 12721 | _ACEOF |
1b1fe467 | 12722 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f CR |
12723 | bash_cv_func_lstat=yes |
12724 | else | |
1b1fe467 | 12725 | bash_cv_func_lstat=no |
e3db237e | 12726 | fi |
1b1fe467 CR |
12727 | rm -f core conftest.err conftest.$ac_objext \ |
12728 | conftest$ac_exeext conftest.$ac_ext | |
e3db237e | 12729 | fi |
1b1fe467 | 12730 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_lstat" >&5 |
7175a77f CR |
12731 | $as_echo "$bash_cv_func_lstat" >&6; } |
12732 | if test $bash_cv_func_lstat = yes; then | |
1b1fe467 | 12733 | $as_echo "#define HAVE_LSTAT 1" >>confdefs.h |
2dead0c4 CR |
12734 | |
12735 | fi | |
e3db237e | 12736 | |
7f947b68 | 12737 | fi |
e3db237e | 12738 | |
e3db237e | 12739 | |
1b1fe467 | 12740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the ctype macros accept non-ascii characters" >&5 |
7175a77f | 12741 | $as_echo_n "checking whether the ctype macros accept non-ascii characters... " >&6; } |
1b1fe467 | 12742 | if ${bash_cv_func_ctype_nonascii+:} false; then : |
7175a77f | 12743 | $as_echo_n "(cached) " >&6 |
7f947b68 | 12744 | else |
1b1fe467 CR |
12745 | if test "$cross_compiling" = yes; then : |
12746 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&5 | |
7175a77f CR |
12747 | $as_echo "$as_me: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&2;} |
12748 | bash_cv_func_ctype_nonascii=no | |
e3db237e | 12749 | |
7175a77f | 12750 | else |
1b1fe467 | 12751 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 12752 | /* end confdefs.h. */ |
e3db237e | 12753 | |
7175a77f CR |
12754 | #ifdef HAVE_LOCALE_H |
12755 | #include <locale.h> | |
12756 | #endif | |
12757 | #include <stdio.h> | |
12758 | #include <ctype.h> | |
7f947b68 | 12759 | |
7175a77f CR |
12760 | main(c, v) |
12761 | int c; | |
12762 | char *v[]; | |
12763 | { | |
12764 | char *deflocale; | |
12765 | unsigned char x; | |
12766 | int r1, r2; | |
7f947b68 | 12767 | |
7175a77f CR |
12768 | #ifdef HAVE_SETLOCALE |
12769 | /* We take a shot here. If that locale is not known, try the | |
12770 | system default. We try this one because '\342' (226) is | |
12771 | known to be a printable character in that locale. */ | |
12772 | deflocale = setlocale(LC_ALL, "en_US.ISO8859-1"); | |
12773 | if (deflocale == 0) | |
12774 | deflocale = setlocale(LC_ALL, ""); | |
12775 | #endif | |
e3db237e | 12776 | |
7175a77f CR |
12777 | x = '\342'; |
12778 | r1 = isprint(x); | |
12779 | x -= 128; | |
12780 | r2 = isprint(x); | |
12781 | exit (r1 == 0 || r2 == 0); | |
12782 | } | |
abe2eb5b | 12783 | |
7f947b68 | 12784 | _ACEOF |
1b1fe467 | 12785 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f CR |
12786 | bash_cv_func_ctype_nonascii=yes |
12787 | else | |
1b1fe467 | 12788 | bash_cv_func_ctype_nonascii=no |
7175a77f | 12789 | fi |
1b1fe467 CR |
12790 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12791 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
e3db237e CR |
12792 | fi |
12793 | ||
7175a77f | 12794 | fi |
2dead0c4 | 12795 | |
1b1fe467 | 12796 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_ctype_nonascii" >&5 |
7175a77f CR |
12797 | $as_echo "$bash_cv_func_ctype_nonascii" >&6; } |
12798 | if test $bash_cv_func_ctype_nonascii = yes; then | |
1b1fe467 | 12799 | $as_echo "#define CTYPE_NON_ASCII 1" >>confdefs.h |
abe2eb5b | 12800 | |
c920c360 CR |
12801 | fi |
12802 | ||
1b1fe467 | 12803 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dup2 fails to clear the close-on-exec flag" >&5 |
7175a77f | 12804 | $as_echo_n "checking if dup2 fails to clear the close-on-exec flag... " >&6; } |
1b1fe467 | 12805 | if ${bash_cv_dup2_broken+:} false; then : |
7175a77f | 12806 | $as_echo_n "(cached) " >&6 |
7f947b68 | 12807 | else |
1b1fe467 CR |
12808 | if test "$cross_compiling" = yes; then : |
12809 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&5 | |
7175a77f CR |
12810 | $as_echo "$as_me: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&2;} |
12811 | bash_cv_dup2_broken=no | |
7f947b68 | 12812 | else |
1b1fe467 | 12813 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
12814 | /* end confdefs.h. */ |
12815 | ||
12816 | #include <sys/types.h> | |
12817 | #include <fcntl.h> | |
12818 | main() | |
12819 | { | |
12820 | int fd1, fd2, fl; | |
12821 | fd1 = open("/dev/null", 2); | |
12822 | if (fcntl(fd1, 2, 1) < 0) | |
12823 | exit(1); | |
12824 | fd2 = dup2(fd1, 1); | |
12825 | if (fd2 < 0) | |
12826 | exit(2); | |
12827 | fl = fcntl(fd2, 1, 0); | |
12828 | /* fl will be 1 if dup2 did not reset the close-on-exec flag. */ | |
12829 | exit(fl != 1); | |
12830 | } | |
7f947b68 | 12831 | |
abe2eb5b | 12832 | _ACEOF |
1b1fe467 | 12833 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f CR |
12834 | bash_cv_dup2_broken=yes |
12835 | else | |
1b1fe467 | 12836 | bash_cv_dup2_broken=no |
2dead0c4 | 12837 | fi |
1b1fe467 CR |
12838 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12839 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7f947b68 CR |
12840 | fi |
12841 | ||
12842 | ||
7175a77f | 12843 | fi |
2dead0c4 | 12844 | |
1b1fe467 | 12845 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dup2_broken" >&5 |
7175a77f CR |
12846 | $as_echo "$bash_cv_dup2_broken" >&6; } |
12847 | if test $bash_cv_dup2_broken = yes; then | |
1b1fe467 | 12848 | $as_echo "#define DUP2_BROKEN 1" >>confdefs.h |
e3db237e | 12849 | |
7f947b68 | 12850 | fi |
71412226 | 12851 | |
abe2eb5b | 12852 | |
1b1fe467 | 12853 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pgrps need synchronization" >&5 |
7175a77f | 12854 | $as_echo_n "checking whether pgrps need synchronization... " >&6; } |
1b1fe467 | 12855 | if ${bash_cv_pgrp_pipe+:} false; then : |
7175a77f | 12856 | $as_echo_n "(cached) " >&6 |
7f947b68 | 12857 | else |
1b1fe467 CR |
12858 | if test "$cross_compiling" = yes; then : |
12859 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&5 | |
7175a77f CR |
12860 | $as_echo "$as_me: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&2;} |
12861 | bash_cv_pgrp_pipe=no | |
12862 | else | |
1b1fe467 | 12863 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 12864 | /* end confdefs.h. */ |
ccc6cda3 | 12865 | |
7175a77f CR |
12866 | #ifdef HAVE_UNISTD_H |
12867 | # include <unistd.h> | |
12868 | #endif | |
12869 | main() | |
12870 | { | |
12871 | # ifdef GETPGRP_VOID | |
12872 | # define getpgID() getpgrp() | |
12873 | # else | |
12874 | # define getpgID() getpgrp(0) | |
12875 | # define setpgid(x,y) setpgrp(x,y) | |
12876 | # endif | |
12877 | int pid1, pid2, fds[2]; | |
12878 | int status; | |
12879 | char ok; | |
c920c360 | 12880 | |
7175a77f CR |
12881 | switch (pid1 = fork()) { |
12882 | case -1: | |
12883 | exit(1); | |
12884 | case 0: | |
12885 | setpgid(0, getpid()); | |
12886 | exit(0); | |
12887 | } | |
12888 | setpgid(pid1, pid1); | |
12889 | ||
12890 | sleep(2); /* let first child die */ | |
abe2eb5b | 12891 | |
7175a77f CR |
12892 | if (pipe(fds) < 0) |
12893 | exit(2); | |
12894 | ||
12895 | switch (pid2 = fork()) { | |
12896 | case -1: | |
12897 | exit(3); | |
12898 | case 0: | |
12899 | setpgid(0, pid1); | |
12900 | ok = getpgID() == pid1; | |
12901 | write(fds[1], &ok, 1); | |
12902 | exit(0); | |
12903 | } | |
12904 | setpgid(pid2, pid1); | |
12905 | ||
12906 | close(fds[1]); | |
12907 | if (read(fds[0], &ok, 1) != 1) | |
12908 | exit(4); | |
12909 | wait(&status); | |
12910 | wait(&status); | |
12911 | exit(ok ? 0 : 5); | |
12912 | } | |
12913 | ||
1b1fe467 CR |
12914 | _ACEOF |
12915 | if ac_fn_c_try_run "$LINENO"; then : | |
12916 | bash_cv_pgrp_pipe=no | |
12917 | else | |
12918 | bash_cv_pgrp_pipe=yes | |
7f947b68 | 12919 | fi |
1b1fe467 CR |
12920 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12921 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7f947b68 CR |
12922 | fi |
12923 | ||
c920c360 | 12924 | |
7175a77f | 12925 | fi |
abe2eb5b | 12926 | |
1b1fe467 | 12927 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_pgrp_pipe" >&5 |
7175a77f CR |
12928 | $as_echo "$bash_cv_pgrp_pipe" >&6; } |
12929 | if test $bash_cv_pgrp_pipe = yes; then | |
1b1fe467 | 12930 | $as_echo "#define PGRP_PIPE 1" >>confdefs.h |
71412226 | 12931 | |
c920c360 | 12932 | fi |
abe2eb5b | 12933 | |
71412226 | 12934 | |
1b1fe467 | 12935 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for type of signal functions" >&5 |
7175a77f | 12936 | $as_echo_n "checking for type of signal functions... " >&6; } |
1b1fe467 | 12937 | if ${bash_cv_signal_vintage+:} false; then : |
7175a77f | 12938 | $as_echo_n "(cached) " >&6 |
7f947b68 | 12939 | else |
abe2eb5b | 12940 | |
1b1fe467 | 12941 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
12942 | /* end confdefs.h. */ |
12943 | #include <signal.h> | |
12944 | int | |
12945 | main () | |
12946 | { | |
7610e0c5 | 12947 | |
7175a77f CR |
12948 | sigset_t ss; |
12949 | struct sigaction sa; | |
12950 | sigemptyset(&ss); sigsuspend(&ss); | |
12951 | sigaction(SIGINT, &sa, (struct sigaction *) 0); | |
12952 | sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0); | |
f73dda09 | 12953 | |
7175a77f CR |
12954 | ; |
12955 | return 0; | |
12956 | } | |
12957 | _ACEOF | |
1b1fe467 | 12958 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f | 12959 | bash_cv_signal_vintage=posix |
7f947b68 | 12960 | else |
a82a04b3 | 12961 | |
1b1fe467 | 12962 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
12963 | /* end confdefs.h. */ |
12964 | #include <signal.h> | |
12965 | int | |
12966 | main () | |
12967 | { | |
2dead0c4 | 12968 | |
7175a77f CR |
12969 | int mask = sigmask(SIGINT); |
12970 | sigsetmask(mask); sigblock(mask); sigpause(mask); | |
7f947b68 | 12971 | |
7175a77f CR |
12972 | ; |
12973 | return 0; | |
12974 | } | |
12975 | _ACEOF | |
1b1fe467 | 12976 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f | 12977 | bash_cv_signal_vintage=4.2bsd |
7f947b68 CR |
12978 | else |
12979 | ||
1b1fe467 | 12980 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 12981 | /* end confdefs.h. */ |
2dead0c4 | 12982 | |
7175a77f CR |
12983 | #include <signal.h> |
12984 | RETSIGTYPE foo() { } | |
12985 | int | |
12986 | main () | |
12987 | { | |
2dead0c4 | 12988 | |
7175a77f CR |
12989 | int mask = sigmask(SIGINT); |
12990 | sigset(SIGINT, foo); sigrelse(SIGINT); | |
12991 | sighold(SIGINT); sigpause(SIGINT); | |
7f947b68 | 12992 | |
7175a77f CR |
12993 | ; |
12994 | return 0; | |
12995 | } | |
e3db237e | 12996 | _ACEOF |
1b1fe467 | 12997 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f CR |
12998 | bash_cv_signal_vintage=svr3 |
12999 | else | |
1b1fe467 | 13000 | bash_cv_signal_vintage=v7 |
abe2eb5b | 13001 | |
2dead0c4 | 13002 | fi |
1b1fe467 CR |
13003 | rm -f core conftest.err conftest.$ac_objext \ |
13004 | conftest$ac_exeext conftest.$ac_ext | |
7f947b68 | 13005 | |
7175a77f | 13006 | fi |
1b1fe467 CR |
13007 | rm -f core conftest.err conftest.$ac_objext \ |
13008 | conftest$ac_exeext conftest.$ac_ext | |
7f947b68 | 13009 | |
7175a77f | 13010 | fi |
1b1fe467 CR |
13011 | rm -f core conftest.err conftest.$ac_objext \ |
13012 | conftest$ac_exeext conftest.$ac_ext | |
7610e0c5 | 13013 | |
2dead0c4 | 13014 | fi |
7610e0c5 | 13015 | |
1b1fe467 | 13016 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_signal_vintage" >&5 |
7175a77f CR |
13017 | $as_echo "$bash_cv_signal_vintage" >&6; } |
13018 | if test "$bash_cv_signal_vintage" = posix; then | |
1b1fe467 | 13019 | $as_echo "#define HAVE_POSIX_SIGNALS 1" >>confdefs.h |
2dead0c4 | 13020 | |
7175a77f | 13021 | elif test "$bash_cv_signal_vintage" = "4.2bsd"; then |
1b1fe467 | 13022 | $as_echo "#define HAVE_BSD_SIGNALS 1" >>confdefs.h |
e3db237e | 13023 | |
7175a77f | 13024 | elif test "$bash_cv_signal_vintage" = svr3; then |
1b1fe467 | 13025 | $as_echo "#define HAVE_USG_SIGHOLD 1" >>confdefs.h |
abe2eb5b | 13026 | |
c920c360 CR |
13027 | fi |
13028 | ||
abe2eb5b | 13029 | |
1b1fe467 | 13030 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_errlist and sys_nerr" >&5 |
7175a77f | 13031 | $as_echo_n "checking for sys_errlist and sys_nerr... " >&6; } |
1b1fe467 | 13032 | if ${bash_cv_sys_errlist+:} false; then : |
7175a77f | 13033 | $as_echo_n "(cached) " >&6 |
7f947b68 | 13034 | else |
1b1fe467 | 13035 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
13036 | /* end confdefs.h. */ |
13037 | #include <errno.h> | |
13038 | int | |
13039 | main () | |
13040 | { | |
13041 | extern char *sys_errlist[]; | |
13042 | extern int sys_nerr; | |
13043 | char *msg = sys_errlist[sys_nerr - 1]; | |
13044 | ; | |
13045 | return 0; | |
13046 | } | |
13047 | _ACEOF | |
1b1fe467 | 13048 | if ac_fn_c_try_link "$LINENO"; then : |
7175a77f | 13049 | bash_cv_sys_errlist=yes |
2dead0c4 | 13050 | else |
1b1fe467 | 13051 | bash_cv_sys_errlist=no |
7175a77f | 13052 | fi |
1b1fe467 CR |
13053 | rm -f core conftest.err conftest.$ac_objext \ |
13054 | conftest$ac_exeext conftest.$ac_ext | |
2dead0c4 | 13055 | fi |
1b1fe467 | 13056 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_errlist" >&5 |
7175a77f CR |
13057 | $as_echo "$bash_cv_sys_errlist" >&6; } |
13058 | if test $bash_cv_sys_errlist = yes; then | |
1b1fe467 | 13059 | $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h |
2dead0c4 CR |
13060 | |
13061 | fi | |
13062 | ||
13063 | ||
1b1fe467 | 13064 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_siglist in system C library" >&5 |
7175a77f | 13065 | $as_echo_n "checking for sys_siglist in system C library... " >&6; } |
1b1fe467 | 13066 | if ${bash_cv_sys_siglist+:} false; then : |
2dead0c4 CR |
13067 | $as_echo_n "(cached) " >&6 |
13068 | else | |
1b1fe467 CR |
13069 | if test "$cross_compiling" = yes; then : |
13070 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&5 | |
7175a77f CR |
13071 | $as_echo "$as_me: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&2;} |
13072 | bash_cv_sys_siglist=no | |
13073 | else | |
1b1fe467 | 13074 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 13075 | /* end confdefs.h. */ |
7f947b68 | 13076 | |
7175a77f CR |
13077 | #include <sys/types.h> |
13078 | #include <signal.h> | |
13079 | #ifdef HAVE_UNISTD_H | |
13080 | #include <unistd.h> | |
7f947b68 | 13081 | #endif |
7175a77f CR |
13082 | #if !HAVE_DECL_SYS_SIGLIST |
13083 | extern char *sys_siglist[]; | |
7f947b68 | 13084 | #endif |
7175a77f CR |
13085 | main() |
13086 | { | |
13087 | char *msg = sys_siglist[2]; | |
13088 | exit(msg == 0); | |
13089 | } | |
5e4a95c7 | 13090 | _ACEOF |
1b1fe467 | 13091 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f | 13092 | bash_cv_sys_siglist=yes |
f73dda09 | 13093 | else |
1b1fe467 | 13094 | bash_cv_sys_siglist=no |
7175a77f | 13095 | fi |
1b1fe467 CR |
13096 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13097 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
e3db237e CR |
13098 | fi |
13099 | ||
7f947b68 | 13100 | fi |
7f947b68 | 13101 | |
1b1fe467 | 13102 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_siglist" >&5 |
7175a77f CR |
13103 | $as_echo "$bash_cv_sys_siglist" >&6; } |
13104 | if test $bash_cv_sys_siglist = yes; then | |
1b1fe467 | 13105 | $as_echo "#define HAVE_SYS_SIGLIST 1" >>confdefs.h |
e3db237e | 13106 | |
2dead0c4 | 13107 | fi |
e3db237e | 13108 | |
1b1fe467 | 13109 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in signal.h or unistd.h" >&5 |
7175a77f | 13110 | $as_echo_n "checking for _sys_siglist in signal.h or unistd.h... " >&6; } |
1b1fe467 | 13111 | if ${bash_cv_decl_under_sys_siglist+:} false; then : |
2dead0c4 CR |
13112 | $as_echo_n "(cached) " >&6 |
13113 | else | |
1b1fe467 | 13114 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 13115 | /* end confdefs.h. */ |
7f947b68 | 13116 | |
2dead0c4 | 13117 | #include <sys/types.h> |
7175a77f CR |
13118 | #include <signal.h> |
13119 | #ifdef HAVE_UNISTD_H | |
13120 | #include <unistd.h> | |
13121 | #endif | |
e3db237e CR |
13122 | int |
13123 | main () | |
13124 | { | |
7175a77f | 13125 | char *msg = _sys_siglist[2]; |
e3db237e CR |
13126 | ; |
13127 | return 0; | |
13128 | } | |
13129 | _ACEOF | |
1b1fe467 | 13130 | if ac_fn_c_try_compile "$LINENO"; then : |
7175a77f | 13131 | bash_cv_decl_under_sys_siglist=yes |
e3db237e | 13132 | else |
1b1fe467 | 13133 | bash_cv_decl_under_sys_siglist=no |
2dead0c4 | 13134 | fi |
7175a77f | 13135 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e3db237e | 13136 | fi |
1b1fe467 | 13137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_under_sys_siglist" >&5 |
7175a77f CR |
13138 | $as_echo "$bash_cv_decl_under_sys_siglist" >&6; } |
13139 | if test $bash_cv_decl_under_sys_siglist = yes; then | |
1b1fe467 | 13140 | $as_echo "#define UNDER_SYS_SIGLIST_DECLARED 1" >>confdefs.h |
e3db237e | 13141 | |
7f947b68 | 13142 | fi |
2dead0c4 CR |
13143 | |
13144 | ||
1b1fe467 | 13145 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in system C library" >&5 |
7175a77f | 13146 | $as_echo_n "checking for _sys_siglist in system C library... " >&6; } |
1b1fe467 | 13147 | if ${bash_cv_under_sys_siglist+:} false; then : |
2dead0c4 | 13148 | $as_echo_n "(cached) " >&6 |
e3db237e | 13149 | else |
1b1fe467 CR |
13150 | if test "$cross_compiling" = yes; then : |
13151 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&5 | |
7175a77f CR |
13152 | $as_echo "$as_me: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&2;} |
13153 | bash_cv_under_sys_siglist=no | |
7f947b68 | 13154 | else |
1b1fe467 | 13155 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2dead0c4 | 13156 | /* end confdefs.h. */ |
7f947b68 | 13157 | |
7175a77f CR |
13158 | #include <sys/types.h> |
13159 | #include <signal.h> | |
13160 | #ifdef HAVE_UNISTD_H | |
13161 | #include <unistd.h> | |
2dead0c4 | 13162 | #endif |
7175a77f CR |
13163 | #ifndef UNDER_SYS_SIGLIST_DECLARED |
13164 | extern char *_sys_siglist[]; | |
2dead0c4 | 13165 | #endif |
7175a77f CR |
13166 | main() |
13167 | { | |
13168 | char *msg = (char *)_sys_siglist[2]; | |
13169 | exit(msg == 0); | |
7f947b68 | 13170 | } |
2dead0c4 | 13171 | _ACEOF |
1b1fe467 | 13172 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f | 13173 | bash_cv_under_sys_siglist=yes |
2dead0c4 | 13174 | else |
1b1fe467 | 13175 | bash_cv_under_sys_siglist=no |
71412226 | 13176 | fi |
1b1fe467 CR |
13177 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13178 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e4a95c7 | 13179 | fi |
b709b946 | 13180 | |
abe2eb5b CR |
13181 | fi |
13182 | ||
1b1fe467 | 13183 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_under_sys_siglist" >&5 |
7175a77f CR |
13184 | $as_echo "$bash_cv_under_sys_siglist" >&6; } |
13185 | if test $bash_cv_under_sys_siglist = yes; then | |
1b1fe467 | 13186 | $as_echo "#define HAVE_UNDER_SYS_SIGLIST 1" >>confdefs.h |
abe2eb5b | 13187 | |
7f947b68 | 13188 | fi |
abe2eb5b | 13189 | |
7175a77f | 13190 | |
1b1fe467 | 13191 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signal handlers are of type void" >&5 |
7175a77f | 13192 | $as_echo_n "checking whether signal handlers are of type void... " >&6; } |
1b1fe467 | 13193 | if ${bash_cv_void_sighandler+:} false; then : |
abe2eb5b CR |
13194 | $as_echo_n "(cached) " >&6 |
13195 | else | |
1b1fe467 | 13196 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b CR |
13197 | /* end confdefs.h. */ |
13198 | #include <sys/types.h> | |
7175a77f CR |
13199 | #include <signal.h> |
13200 | #ifdef signal | |
13201 | #undef signal | |
13202 | #endif | |
13203 | #ifdef __cplusplus | |
13204 | extern "C" | |
13205 | #endif | |
13206 | void (*signal ()) (); | |
13207 | int | |
13208 | main () | |
7f947b68 | 13209 | { |
7175a77f CR |
13210 | int i; |
13211 | ; | |
13212 | return 0; | |
7f947b68 | 13213 | } |
abe2eb5b | 13214 | _ACEOF |
1b1fe467 | 13215 | if ac_fn_c_try_compile "$LINENO"; then : |
7175a77f | 13216 | bash_cv_void_sighandler=yes |
abe2eb5b | 13217 | else |
1b1fe467 | 13218 | bash_cv_void_sighandler=no |
abe2eb5b | 13219 | fi |
7175a77f | 13220 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
1b1fe467 CR |
13221 | fi |
13222 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_void_sighandler" >&5 | |
13223 | $as_echo "$bash_cv_void_sighandler" >&6; } | |
13224 | if test $bash_cv_void_sighandler = yes; then | |
13225 | $as_echo "#define VOID_SIGHANDLER 1" >>confdefs.h | |
2dead0c4 | 13226 | |
7175a77f | 13227 | fi |
2dead0c4 CR |
13228 | |
13229 | ||
c920c360 | 13230 | |
1b1fe467 CR |
13231 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5 |
13232 | $as_echo_n "checking for clock_t... " >&6; } | |
13233 | if ${bash_cv_type_clock_t+:} false; then : | |
7175a77f | 13234 | $as_echo_n "(cached) " >&6 |
c920c360 | 13235 | else |
1b1fe467 | 13236 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f CR |
13237 | /* end confdefs.h. */ |
13238 | #include <sys/types.h> | |
13239 | #if STDC_HEADERS | |
13240 | #include <stdlib.h> | |
13241 | #include <stddef.h> | |
13242 | #endif | |
13243 | #if HAVE_INTTYPES_H | |
13244 | #include <inttypes.h> | |
13245 | #endif | |
13246 | #if HAVE_STDINT_H | |
13247 | #include <stdint.h> | |
13248 | #endif | |
1b1fe467 | 13249 | #include <sys/times.h> |
e3db237e | 13250 | |
7175a77f CR |
13251 | _ACEOF |
13252 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 CR |
13253 | $EGREP "clock_t" >/dev/null 2>&1; then : |
13254 | bash_cv_type_clock_t=yes | |
7175a77f | 13255 | else |
1b1fe467 | 13256 | bash_cv_type_clock_t=no |
7f947b68 | 13257 | fi |
7175a77f | 13258 | rm -f conftest* |
71412226 | 13259 | |
2dead0c4 | 13260 | fi |
71412226 | 13261 | |
1b1fe467 CR |
13262 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_clock_t" >&5 |
13263 | $as_echo "$bash_cv_type_clock_t" >&6; } | |
7f947b68 | 13264 | |
1b1fe467 | 13265 | if test $bash_cv_type_clock_t = no; then |
7175a77f | 13266 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 13267 | #define clock_t long |
7175a77f | 13268 | _ACEOF |
7f947b68 | 13269 | |
abe2eb5b | 13270 | fi |
7f947b68 CR |
13271 | |
13272 | ||
7175a77f | 13273 | |
1b1fe467 CR |
13274 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigset_t" >&5 |
13275 | $as_echo_n "checking for sigset_t... " >&6; } | |
13276 | if ${bash_cv_type_sigset_t+:} false; then : | |
c920c360 CR |
13277 | $as_echo_n "(cached) " >&6 |
13278 | else | |
1b1fe467 | 13279 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
c920c360 | 13280 | /* end confdefs.h. */ |
7175a77f CR |
13281 | #include <sys/types.h> |
13282 | #if STDC_HEADERS | |
13283 | #include <stdlib.h> | |
13284 | #include <stddef.h> | |
13285 | #endif | |
13286 | #if HAVE_INTTYPES_H | |
13287 | #include <inttypes.h> | |
13288 | #endif | |
13289 | #if HAVE_STDINT_H | |
13290 | #include <stdint.h> | |
13291 | #endif | |
1b1fe467 | 13292 | #include <signal.h> |
7175a77f | 13293 | |
abe2eb5b | 13294 | _ACEOF |
7175a77f | 13295 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 CR |
13296 | $EGREP "sigset_t" >/dev/null 2>&1; then : |
13297 | bash_cv_type_sigset_t=yes | |
abe2eb5b | 13298 | else |
1b1fe467 | 13299 | bash_cv_type_sigset_t=no |
7f947b68 | 13300 | fi |
7175a77f CR |
13301 | rm -f conftest* |
13302 | ||
7f947b68 | 13303 | fi |
7175a77f | 13304 | |
1b1fe467 CR |
13305 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sigset_t" >&5 |
13306 | $as_echo "$bash_cv_type_sigset_t" >&6; } | |
7175a77f | 13307 | |
1b1fe467 | 13308 | if test $bash_cv_type_sigset_t = no; then |
7175a77f | 13309 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 13310 | #define sigset_t int |
7175a77f | 13311 | _ACEOF |
e3db237e | 13312 | |
7f947b68 | 13313 | fi |
e3db237e | 13314 | |
7175a77f | 13315 | |
7f947b68 | 13316 | |
73a146be CR |
13317 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t" >&5 |
13318 | $as_echo_n "checking for sig_atomic_t... " >&6; } | |
13319 | if ${bash_cv_type_sig_atomic_t+:} false; then : | |
13320 | $as_echo_n "(cached) " >&6 | |
13321 | else | |
13322 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13323 | /* end confdefs.h. */ | |
13324 | #include <sys/types.h> | |
13325 | #if STDC_HEADERS | |
13326 | #include <stdlib.h> | |
13327 | #include <stddef.h> | |
13328 | #endif | |
13329 | #if HAVE_INTTYPES_H | |
13330 | #include <inttypes.h> | |
13331 | #endif | |
13332 | #if HAVE_STDINT_H | |
13333 | #include <stdint.h> | |
13334 | #endif | |
13335 | #include <signal.h> | |
13336 | ||
13337 | _ACEOF | |
13338 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13339 | $EGREP "sig_atomic_t" >/dev/null 2>&1; then : | |
13340 | bash_cv_type_sig_atomic_t=yes | |
13341 | else | |
13342 | bash_cv_type_sig_atomic_t=no | |
13343 | fi | |
13344 | rm -f conftest* | |
13345 | ||
13346 | fi | |
13347 | ||
13348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sig_atomic_t" >&5 | |
13349 | $as_echo "$bash_cv_type_sig_atomic_t" >&6; } | |
13350 | ||
13351 | if test $bash_cv_type_sig_atomic_t = no; then | |
13352 | cat >>confdefs.h <<_ACEOF | |
13353 | #define sig_atomic_t int | |
13354 | _ACEOF | |
13355 | ||
13356 | fi | |
13357 | ||
13358 | ||
13359 | ||
1b1fe467 CR |
13360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for quad_t" >&5 |
13361 | $as_echo_n "checking for quad_t... " >&6; } | |
13362 | if ${bash_cv_type_quad_t+:} false; then : | |
7f947b68 | 13363 | $as_echo_n "(cached) " >&6 |
abe2eb5b | 13364 | else |
1b1fe467 | 13365 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 13366 | /* end confdefs.h. */ |
abe2eb5b | 13367 | #include <sys/types.h> |
7175a77f CR |
13368 | #if STDC_HEADERS |
13369 | #include <stdlib.h> | |
13370 | #include <stddef.h> | |
7f947b68 | 13371 | #endif |
7175a77f CR |
13372 | #if HAVE_INTTYPES_H |
13373 | #include <inttypes.h> | |
7f947b68 | 13374 | #endif |
7175a77f CR |
13375 | #if HAVE_STDINT_H |
13376 | #include <stdint.h> | |
13377 | #endif | |
1b1fe467 | 13378 | |
7175a77f | 13379 | |
abe2eb5b | 13380 | _ACEOF |
7175a77f | 13381 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 CR |
13382 | $EGREP "quad_t" >/dev/null 2>&1; then : |
13383 | bash_cv_type_quad_t=yes | |
7610e0c5 | 13384 | else |
1b1fe467 | 13385 | bash_cv_type_quad_t=no |
2dead0c4 | 13386 | fi |
7175a77f | 13387 | rm -f conftest* |
2dead0c4 | 13388 | |
abe2eb5b CR |
13389 | fi |
13390 | ||
1b1fe467 CR |
13391 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_quad_t" >&5 |
13392 | $as_echo "$bash_cv_type_quad_t" >&6; } | |
13393 | if test $bash_cv_type_quad_t = yes; then | |
13394 | $as_echo "#define HAVE_QUAD_T 1" >>confdefs.h | |
7175a77f CR |
13395 | |
13396 | fi | |
1b1fe467 | 13397 | if test $bash_cv_type_quad_t = no; then |
7175a77f | 13398 | cat >>confdefs.h <<_ACEOF |
1b1fe467 | 13399 | #define quad_t long |
7175a77f | 13400 | _ACEOF |
2dead0c4 | 13401 | |
abe2eb5b | 13402 | fi |
2dead0c4 | 13403 | |
7f947b68 CR |
13404 | |
13405 | ||
1b1fe467 CR |
13406 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5 |
13407 | $as_echo_n "checking for intmax_t... " >&6; } | |
13408 | if ${bash_cv_type_intmax_t+:} false; then : | |
13409 | $as_echo_n "(cached) " >&6 | |
7f947b68 | 13410 | else |
1b1fe467 | 13411 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 13412 | /* end confdefs.h. */ |
7f947b68 | 13413 | #include <sys/types.h> |
1b1fe467 CR |
13414 | #if STDC_HEADERS |
13415 | #include <stdlib.h> | |
13416 | #include <stddef.h> | |
13417 | #endif | |
13418 | #if HAVE_INTTYPES_H | |
13419 | #include <inttypes.h> | |
13420 | #endif | |
13421 | #if HAVE_STDINT_H | |
13422 | #include <stdint.h> | |
7175a77f | 13423 | #endif |
7175a77f CR |
13424 | |
13425 | ||
1b1fe467 CR |
13426 | _ACEOF |
13427 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13428 | $EGREP "intmax_t" >/dev/null 2>&1; then : | |
13429 | bash_cv_type_intmax_t=yes | |
13430 | else | |
13431 | bash_cv_type_intmax_t=no | |
7f947b68 | 13432 | fi |
1b1fe467 | 13433 | rm -f conftest* |
7175a77f | 13434 | |
abe2eb5b CR |
13435 | fi |
13436 | ||
1b1fe467 CR |
13437 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_intmax_t" >&5 |
13438 | $as_echo "$bash_cv_type_intmax_t" >&6; } | |
7175a77f | 13439 | |
1b1fe467 CR |
13440 | if test $bash_cv_type_intmax_t = no; then |
13441 | cat >>confdefs.h <<_ACEOF | |
13442 | #define intmax_t $bash_cv_type_long_long | |
7175a77f | 13443 | _ACEOF |
abe2eb5b | 13444 | |
7f947b68 | 13445 | fi |
abe2eb5b | 13446 | |
7f947b68 | 13447 | |
71412226 | 13448 | |
1b1fe467 CR |
13449 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uintmax_t" >&5 |
13450 | $as_echo_n "checking for uintmax_t... " >&6; } | |
13451 | if ${bash_cv_type_uintmax_t+:} false; then : | |
13452 | $as_echo_n "(cached) " >&6 | |
7175a77f | 13453 | else |
1b1fe467 | 13454 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7175a77f | 13455 | /* end confdefs.h. */ |
1b1fe467 CR |
13456 | #include <sys/types.h> |
13457 | #if STDC_HEADERS | |
13458 | #include <stdlib.h> | |
13459 | #include <stddef.h> | |
13460 | #endif | |
13461 | #if HAVE_INTTYPES_H | |
13462 | #include <inttypes.h> | |
13463 | #endif | |
13464 | #if HAVE_STDINT_H | |
13465 | #include <stdint.h> | |
13466 | #endif | |
7f947b68 CR |
13467 | |
13468 | ||
1b1fe467 CR |
13469 | _ACEOF |
13470 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13471 | $EGREP "uintmax_t" >/dev/null 2>&1; then : | |
13472 | bash_cv_type_uintmax_t=yes | |
7f947b68 | 13473 | else |
1b1fe467 | 13474 | bash_cv_type_uintmax_t=no |
7f947b68 | 13475 | fi |
1b1fe467 | 13476 | rm -f conftest* |
c920c360 CR |
13477 | |
13478 | fi | |
13479 | ||
1b1fe467 CR |
13480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_uintmax_t" >&5 |
13481 | $as_echo "$bash_cv_type_uintmax_t" >&6; } | |
7f947b68 | 13482 | |
1b1fe467 CR |
13483 | if test $bash_cv_type_uintmax_t = no; then |
13484 | cat >>confdefs.h <<_ACEOF | |
13485 | #define uintmax_t $bash_cv_type_unsigned_long_long | |
abe2eb5b | 13486 | _ACEOF |
7f947b68 CR |
13487 | |
13488 | fi | |
13489 | ||
1b1fe467 CR |
13490 | if test "$ac_cv_header_sys_socket_h" = "yes"; then |
13491 | ||
13492 | ||
13493 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 | |
13494 | $as_echo_n "checking for socklen_t... " >&6; } | |
13495 | if ${bash_cv_type_socklen_t+:} false; then : | |
13496 | $as_echo_n "(cached) " >&6 | |
7f947b68 | 13497 | else |
1b1fe467 | 13498 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 13499 | /* end confdefs.h. */ |
1b1fe467 CR |
13500 | #include <sys/types.h> |
13501 | #if STDC_HEADERS | |
2dead0c4 | 13502 | #include <stdlib.h> |
1b1fe467 CR |
13503 | #include <stddef.h> |
13504 | #endif | |
13505 | #if HAVE_INTTYPES_H | |
13506 | #include <inttypes.h> | |
13507 | #endif | |
13508 | #if HAVE_STDINT_H | |
13509 | #include <stdint.h> | |
13510 | #endif | |
13511 | #include <sys/socket.h> | |
2dead0c4 CR |
13512 | |
13513 | _ACEOF | |
1b1fe467 CR |
13514 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13515 | $EGREP "socklen_t" >/dev/null 2>&1; then : | |
13516 | bash_cv_type_socklen_t=yes | |
2dead0c4 | 13517 | else |
1b1fe467 | 13518 | bash_cv_type_socklen_t=no |
7175a77f | 13519 | fi |
1b1fe467 | 13520 | rm -f conftest* |
2dead0c4 | 13521 | |
1b1fe467 | 13522 | fi |
abe2eb5b | 13523 | |
1b1fe467 CR |
13524 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_socklen_t" >&5 |
13525 | $as_echo "$bash_cv_type_socklen_t" >&6; } | |
13526 | if test $bash_cv_type_socklen_t = yes; then | |
13527 | $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h | |
7175a77f | 13528 | |
1b1fe467 CR |
13529 | fi |
13530 | if test $bash_cv_type_socklen_t = no; then | |
13531 | cat >>confdefs.h <<_ACEOF | |
c2fa6583 | 13532 | #define socklen_t unsigned int |
2dead0c4 | 13533 | _ACEOF |
c920c360 | 13534 | |
1b1fe467 | 13535 | fi |
c920c360 | 13536 | |
1b1fe467 CR |
13537 | fi |
13538 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for size and type of struct rlimit fields" >&5 | |
13539 | $as_echo_n "checking for size and type of struct rlimit fields... " >&6; } | |
13540 | if ${bash_cv_type_rlimit+:} false; then : | |
2dead0c4 CR |
13541 | $as_echo_n "(cached) " >&6 |
13542 | else | |
1b1fe467 | 13543 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2dead0c4 CR |
13544 | /* end confdefs.h. */ |
13545 | #include <sys/types.h> | |
1b1fe467 | 13546 | #include <sys/resource.h> |
7175a77f CR |
13547 | int |
13548 | main () | |
13549 | { | |
1b1fe467 | 13550 | rlim_t xxx; |
7175a77f CR |
13551 | ; |
13552 | return 0; | |
13553 | } | |
7610e0c5 | 13554 | _ACEOF |
1b1fe467 CR |
13555 | if ac_fn_c_try_compile "$LINENO"; then : |
13556 | bash_cv_type_rlimit=rlim_t | |
e3db237e | 13557 | else |
71412226 | 13558 | |
1b1fe467 CR |
13559 | if test "$cross_compiling" = yes; then : |
13560 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&5 | |
13561 | $as_echo "$as_me: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&2;} | |
13562 | bash_cv_type_rlimit=long | |
13563 | else | |
13564 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7f947b68 | 13565 | /* end confdefs.h. */ |
7175a77f | 13566 | |
c920c360 | 13567 | #include <sys/types.h> |
1b1fe467 CR |
13568 | #include <sys/time.h> |
13569 | #include <sys/resource.h> | |
13570 | main() | |
7175a77f | 13571 | { |
1b1fe467 CR |
13572 | #ifdef HAVE_QUAD_T |
13573 | struct rlimit rl; | |
13574 | if (sizeof(rl.rlim_cur) == sizeof(quad_t)) | |
13575 | exit(0); | |
13576 | #endif | |
13577 | exit(1); | |
7175a77f | 13578 | } |
e3db237e | 13579 | _ACEOF |
1b1fe467 CR |
13580 | if ac_fn_c_try_run "$LINENO"; then : |
13581 | bash_cv_type_rlimit=quad_t | |
e3db237e | 13582 | else |
1b1fe467 | 13583 | bash_cv_type_rlimit=long |
e3db237e | 13584 | fi |
1b1fe467 CR |
13585 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13586 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7175a77f | 13587 | fi |
7f947b68 | 13588 | |
7175a77f | 13589 | fi |
1b1fe467 | 13590 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2dead0c4 CR |
13591 | |
13592 | fi | |
13593 | ||
1b1fe467 CR |
13594 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_rlimit" >&5 |
13595 | $as_echo "$bash_cv_type_rlimit" >&6; } | |
13596 | if test $bash_cv_type_rlimit = quad_t; then | |
13597 | $as_echo "#define RLIMTYPE quad_t" >>confdefs.h | |
2dead0c4 | 13598 | |
1b1fe467 CR |
13599 | elif test $bash_cv_type_rlimit = rlim_t; then |
13600 | $as_echo "#define RLIMTYPE rlim_t" >>confdefs.h | |
2dead0c4 | 13601 | |
1b1fe467 | 13602 | fi |
7f947b68 | 13603 | |
2dead0c4 | 13604 | |
1b1fe467 CR |
13605 | # The cast to long int works around a bug in the HP C Compiler |
13606 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
13607 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
13608 | # This bug is HP SR number 8606223364. | |
13609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5 | |
13610 | $as_echo_n "checking size of intmax_t... " >&6; } | |
13611 | if ${ac_cv_sizeof_intmax_t+:} false; then : | |
13612 | $as_echo_n "(cached) " >&6 | |
13613 | else | |
13614 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"; then : | |
2dead0c4 | 13615 | |
abe2eb5b | 13616 | else |
1b1fe467 CR |
13617 | if test "$ac_cv_type_intmax_t" = yes; then |
13618 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
13619 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
13620 | as_fn_error 77 "cannot compute sizeof (intmax_t) | |
13621 | See \`config.log' for more details" "$LINENO" 5; } | |
13622 | else | |
13623 | ac_cv_sizeof_intmax_t=0 | |
13624 | fi | |
13625 | fi | |
c920c360 | 13626 | |
1b1fe467 CR |
13627 | fi |
13628 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5 | |
13629 | $as_echo "$ac_cv_sizeof_intmax_t" >&6; } | |
2dead0c4 | 13630 | |
7175a77f CR |
13631 | |
13632 | ||
1b1fe467 CR |
13633 | cat >>confdefs.h <<_ACEOF |
13634 | #define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t | |
13635 | _ACEOF | |
7f947b68 | 13636 | |
7f947b68 | 13637 | |
7f947b68 | 13638 | |
1b1fe467 CR |
13639 | |
13640 | ac_fn_c_check_member "$LINENO" "struct termios" "c_line" "ac_cv_member_struct_termios_c_line" " | |
13641 | #include <sys/types.h> | |
13642 | #include <termios.h> | |
13643 | ||
13644 | " | |
13645 | if test "x$ac_cv_member_struct_termios_c_line" = xyes; then : | |
13646 | $as_echo "#define TERMIOS_LDISC 1" >>confdefs.h | |
13647 | ||
7175a77f | 13648 | fi |
1b1fe467 CR |
13649 | |
13650 | ||
13651 | ||
13652 | ac_fn_c_check_member "$LINENO" "struct termio" "c_line" "ac_cv_member_struct_termio_c_line" " | |
13653 | #include <sys/types.h> | |
13654 | #include <termio.h> | |
13655 | ||
13656 | " | |
13657 | if test "x$ac_cv_member_struct_termio_c_line" = xyes; then : | |
13658 | $as_echo "#define TERMIO_LDISC 1" >>confdefs.h | |
7f947b68 | 13659 | |
ccc6cda3 JA |
13660 | fi |
13661 | ||
a82a04b3 CR |
13662 | |
13663 | ||
1b1fe467 | 13664 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_ino" >&5 |
dd4f3dd8 | 13665 | $as_echo_n "checking for struct dirent.d_ino... " >&6; } |
1b1fe467 | 13666 | if ${bash_cv_dirent_has_dino+:} false; then : |
dd4f3dd8 | 13667 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13668 | else |
1b1fe467 | 13669 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13670 | /* end confdefs.h. */ |
ccc6cda3 JA |
13671 | |
13672 | #include <stdio.h> | |
13673 | #include <sys/types.h> | |
13674 | #ifdef HAVE_UNISTD_H | |
13675 | # include <unistd.h> | |
13676 | #endif /* HAVE_UNISTD_H */ | |
13677 | #if defined(HAVE_DIRENT_H) | |
13678 | # include <dirent.h> | |
13679 | #else | |
13680 | # define dirent direct | |
13681 | # ifdef HAVE_SYS_NDIR_H | |
13682 | # include <sys/ndir.h> | |
13683 | # endif /* SYSNDIR */ | |
13684 | # ifdef HAVE_SYS_DIR_H | |
13685 | # include <sys/dir.h> | |
13686 | # endif /* SYSDIR */ | |
13687 | # ifdef HAVE_NDIR_H | |
13688 | # include <ndir.h> | |
13689 | # endif | |
13690 | #endif /* HAVE_DIRENT_H */ | |
13691 | ||
f73dda09 JA |
13692 | int |
13693 | main () | |
13694 | { | |
ccc6cda3 JA |
13695 | |
13696 | struct dirent d; int z; z = d.d_ino; | |
13697 | ||
f73dda09 JA |
13698 | ; |
13699 | return 0; | |
13700 | } | |
13701 | _ACEOF | |
1b1fe467 | 13702 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
13703 | bash_cv_dirent_has_dino=yes |
13704 | else | |
1b1fe467 | 13705 | bash_cv_dirent_has_dino=no |
ccc6cda3 | 13706 | fi |
b709b946 | 13707 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
13708 | fi |
13709 | ||
1b1fe467 | 13710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_dino" >&5 |
dd4f3dd8 | 13711 | $as_echo "$bash_cv_dirent_has_dino" >&6; } |
ccc6cda3 | 13712 | if test $bash_cv_dirent_has_dino = yes; then |
1b1fe467 | 13713 | $as_echo "#define HAVE_STRUCT_DIRENT_D_INO 1" >>confdefs.h |
ccc6cda3 JA |
13714 | |
13715 | fi | |
13716 | ||
a82a04b3 | 13717 | |
1b1fe467 | 13718 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_fileno" >&5 |
dd4f3dd8 | 13719 | $as_echo_n "checking for struct dirent.d_fileno... " >&6; } |
1b1fe467 | 13720 | if ${bash_cv_dirent_has_d_fileno+:} false; then : |
dd4f3dd8 | 13721 | $as_echo_n "(cached) " >&6 |
d166f048 | 13722 | else |
1b1fe467 | 13723 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13724 | /* end confdefs.h. */ |
d166f048 JA |
13725 | |
13726 | #include <stdio.h> | |
13727 | #include <sys/types.h> | |
13728 | #ifdef HAVE_UNISTD_H | |
13729 | # include <unistd.h> | |
13730 | #endif /* HAVE_UNISTD_H */ | |
13731 | #if defined(HAVE_DIRENT_H) | |
13732 | # include <dirent.h> | |
13733 | #else | |
13734 | # define dirent direct | |
13735 | # ifdef HAVE_SYS_NDIR_H | |
13736 | # include <sys/ndir.h> | |
13737 | # endif /* SYSNDIR */ | |
13738 | # ifdef HAVE_SYS_DIR_H | |
13739 | # include <sys/dir.h> | |
13740 | # endif /* SYSDIR */ | |
13741 | # ifdef HAVE_NDIR_H | |
13742 | # include <ndir.h> | |
13743 | # endif | |
13744 | #endif /* HAVE_DIRENT_H */ | |
13745 | ||
f73dda09 JA |
13746 | int |
13747 | main () | |
13748 | { | |
d166f048 JA |
13749 | |
13750 | struct dirent d; int z; z = d.d_fileno; | |
13751 | ||
f73dda09 JA |
13752 | ; |
13753 | return 0; | |
13754 | } | |
5c26afb8 | 13755 | _ACEOF |
1b1fe467 | 13756 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
13757 | bash_cv_dirent_has_d_fileno=yes |
13758 | else | |
1b1fe467 | 13759 | bash_cv_dirent_has_d_fileno=no |
d166f048 | 13760 | fi |
b709b946 | 13761 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13762 | fi |
13763 | ||
1b1fe467 | 13764 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_fileno" >&5 |
dd4f3dd8 | 13765 | $as_echo "$bash_cv_dirent_has_d_fileno" >&6; } |
d166f048 | 13766 | if test $bash_cv_dirent_has_d_fileno = yes; then |
1b1fe467 | 13767 | $as_echo "#define HAVE_STRUCT_DIRENT_D_FILENO 1" >>confdefs.h |
4931aca6 CR |
13768 | |
13769 | fi | |
13770 | ||
a82a04b3 | 13771 | |
1b1fe467 | 13772 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_namlen" >&5 |
dd4f3dd8 | 13773 | $as_echo_n "checking for struct dirent.d_namlen... " >&6; } |
1b1fe467 | 13774 | if ${bash_cv_dirent_has_d_namlen+:} false; then : |
dd4f3dd8 | 13775 | $as_echo_n "(cached) " >&6 |
4931aca6 | 13776 | else |
1b1fe467 | 13777 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13778 | /* end confdefs.h. */ |
4931aca6 CR |
13779 | |
13780 | #include <stdio.h> | |
13781 | #include <sys/types.h> | |
13782 | #ifdef HAVE_UNISTD_H | |
13783 | # include <unistd.h> | |
13784 | #endif /* HAVE_UNISTD_H */ | |
13785 | #if defined(HAVE_DIRENT_H) | |
13786 | # include <dirent.h> | |
13787 | #else | |
13788 | # define dirent direct | |
13789 | # ifdef HAVE_SYS_NDIR_H | |
13790 | # include <sys/ndir.h> | |
13791 | # endif /* SYSNDIR */ | |
13792 | # ifdef HAVE_SYS_DIR_H | |
13793 | # include <sys/dir.h> | |
13794 | # endif /* SYSDIR */ | |
13795 | # ifdef HAVE_NDIR_H | |
13796 | # include <ndir.h> | |
13797 | # endif | |
13798 | #endif /* HAVE_DIRENT_H */ | |
13799 | ||
13800 | int | |
13801 | main () | |
13802 | { | |
13803 | ||
13804 | struct dirent d; int z; z = d.d_namlen; | |
13805 | ||
13806 | ; | |
13807 | return 0; | |
13808 | } | |
13809 | _ACEOF | |
1b1fe467 | 13810 | if ac_fn_c_try_compile "$LINENO"; then : |
4931aca6 CR |
13811 | bash_cv_dirent_has_d_namlen=yes |
13812 | else | |
1b1fe467 | 13813 | bash_cv_dirent_has_d_namlen=no |
4931aca6 | 13814 | fi |
b709b946 | 13815 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4931aca6 CR |
13816 | fi |
13817 | ||
1b1fe467 | 13818 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_namlen" >&5 |
dd4f3dd8 | 13819 | $as_echo "$bash_cv_dirent_has_d_namlen" >&6; } |
4931aca6 | 13820 | if test $bash_cv_dirent_has_d_namlen = yes; then |
1b1fe467 | 13821 | $as_echo "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" >>confdefs.h |
d166f048 JA |
13822 | |
13823 | fi | |
13824 | ||
1b1fe467 | 13825 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct winsize in sys/ioctl.h and termios.h" >&5 |
dd4f3dd8 | 13826 | $as_echo_n "checking for struct winsize in sys/ioctl.h and termios.h... " >&6; } |
1b1fe467 | 13827 | if ${bash_cv_struct_winsize_header+:} false; then : |
dd4f3dd8 | 13828 | $as_echo_n "(cached) " >&6 |
d166f048 | 13829 | else |
1b1fe467 | 13830 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13831 | /* end confdefs.h. */ |
d166f048 JA |
13832 | #include <sys/types.h> |
13833 | #include <sys/ioctl.h> | |
f73dda09 JA |
13834 | int |
13835 | main () | |
13836 | { | |
d166f048 | 13837 | struct winsize x; |
f73dda09 JA |
13838 | ; |
13839 | return 0; | |
13840 | } | |
13841 | _ACEOF | |
1b1fe467 | 13842 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc JA |
13843 | bash_cv_struct_winsize_header=ioctl_h |
13844 | else | |
1b1fe467 | 13845 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13846 | /* end confdefs.h. */ |
cce855bc JA |
13847 | #include <sys/types.h> |
13848 | #include <termios.h> | |
f73dda09 JA |
13849 | int |
13850 | main () | |
13851 | { | |
cce855bc | 13852 | struct winsize x; |
f73dda09 JA |
13853 | ; |
13854 | return 0; | |
13855 | } | |
13856 | _ACEOF | |
1b1fe467 | 13857 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc | 13858 | bash_cv_struct_winsize_header=termios_h |
d166f048 | 13859 | else |
1b1fe467 | 13860 | bash_cv_struct_winsize_header=other |
cce855bc | 13861 | fi |
b709b946 | 13862 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
cce855bc | 13863 | |
d166f048 | 13864 | fi |
b709b946 | 13865 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13866 | fi |
13867 | ||
cce855bc | 13868 | if test $bash_cv_struct_winsize_header = ioctl_h; then |
1b1fe467 | 13869 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: sys/ioctl.h" >&5 |
dd4f3dd8 | 13870 | $as_echo "sys/ioctl.h" >&6; } |
1b1fe467 | 13871 | $as_echo "#define STRUCT_WINSIZE_IN_SYS_IOCTL 1" >>confdefs.h |
d166f048 | 13872 | |
cce855bc | 13873 | elif test $bash_cv_struct_winsize_header = termios_h; then |
1b1fe467 | 13874 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: termios.h" >&5 |
dd4f3dd8 | 13875 | $as_echo "termios.h" >&6; } |
1b1fe467 | 13876 | $as_echo "#define STRUCT_WINSIZE_IN_TERMIOS 1" >>confdefs.h |
cce855bc JA |
13877 | |
13878 | else | |
1b1fe467 | 13879 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 |
dd4f3dd8 | 13880 | $as_echo "not found" >&6; } |
d166f048 JA |
13881 | fi |
13882 | ||
1b1fe467 | 13883 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval in sys/time.h and time.h" >&5 |
dd4f3dd8 | 13884 | $as_echo_n "checking for struct timeval in sys/time.h and time.h... " >&6; } |
1b1fe467 | 13885 | if ${bash_cv_struct_timeval+:} false; then : |
dd4f3dd8 | 13886 | $as_echo_n "(cached) " >&6 |
bb70624e | 13887 | else |
f73dda09 | 13888 | |
1b1fe467 | 13889 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13890 | /* end confdefs.h. */ |
bb70624e | 13891 | #include <sys/time.h> |
f73dda09 JA |
13892 | |
13893 | _ACEOF | |
bb70624e | 13894 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 | 13895 | $EGREP "struct timeval" >/dev/null 2>&1; then : |
bb70624e JA |
13896 | bash_cv_struct_timeval=yes |
13897 | else | |
1b1fe467 | 13898 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13899 | /* end confdefs.h. */ |
bb70624e | 13900 | #include <time.h> |
f73dda09 JA |
13901 | |
13902 | _ACEOF | |
bb70624e | 13903 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 | 13904 | $EGREP "struct timeval" >/dev/null 2>&1; then : |
bb70624e JA |
13905 | bash_cv_struct_timeval=yes |
13906 | else | |
bb70624e JA |
13907 | bash_cv_struct_timeval=no |
13908 | fi | |
13909 | rm -f conftest* | |
13910 | ||
13911 | fi | |
13912 | rm -f conftest* | |
13913 | ||
a82a04b3 | 13914 | |
bb70624e JA |
13915 | fi |
13916 | ||
1b1fe467 | 13917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timeval" >&5 |
dd4f3dd8 | 13918 | $as_echo "$bash_cv_struct_timeval" >&6; } |
bb70624e | 13919 | if test $bash_cv_struct_timeval = yes; then |
1b1fe467 | 13920 | $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h |
7175a77f | 13921 | |
7175a77f | 13922 | fi |
b709b946 | 13923 | |
1b1fe467 CR |
13924 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
13925 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : | |
f73dda09 | 13926 | |
a82a04b3 | 13927 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 13928 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
a82a04b3 CR |
13929 | _ACEOF |
13930 | ||
f73dda09 JA |
13931 | |
13932 | fi | |
d166f048 | 13933 | |
1b1fe467 | 13934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
dd4f3dd8 | 13935 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
1b1fe467 | 13936 | if ${ac_cv_struct_tm+:} false; then : |
dd4f3dd8 | 13937 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 13938 | else |
1b1fe467 | 13939 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13940 | /* end confdefs.h. */ |
7117c2d2 JA |
13941 | #include <sys/types.h> |
13942 | #include <time.h> | |
13943 | ||
13944 | int | |
13945 | main () | |
13946 | { | |
dd4f3dd8 CR |
13947 | struct tm tm; |
13948 | int *p = &tm.tm_sec; | |
13949 | return !p; | |
7117c2d2 JA |
13950 | ; |
13951 | return 0; | |
13952 | } | |
13953 | _ACEOF | |
1b1fe467 | 13954 | if ac_fn_c_try_compile "$LINENO"; then : |
7117c2d2 JA |
13955 | ac_cv_struct_tm=time.h |
13956 | else | |
1b1fe467 | 13957 | ac_cv_struct_tm=sys/time.h |
7117c2d2 | 13958 | fi |
b709b946 | 13959 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7117c2d2 | 13960 | fi |
1b1fe467 | 13961 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
dd4f3dd8 | 13962 | $as_echo "$ac_cv_struct_tm" >&6; } |
7117c2d2 JA |
13963 | if test $ac_cv_struct_tm = sys/time.h; then |
13964 | ||
1b1fe467 | 13965 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
7175a77f CR |
13966 | |
13967 | fi | |
13968 | ||
1b1fe467 | 13969 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> |
7175a77f CR |
13970 | #include <$ac_cv_struct_tm> |
13971 | ||
1b1fe467 CR |
13972 | " |
13973 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : | |
7175a77f CR |
13974 | |
13975 | cat >>confdefs.h <<_ACEOF | |
13976 | #define HAVE_STRUCT_TM_TM_ZONE 1 | |
13977 | _ACEOF | |
13978 | ||
13979 | ||
13980 | fi | |
13981 | ||
1b1fe467 CR |
13982 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then |
13983 | ||
13984 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h | |
d3ad40de | 13985 | |
1b1fe467 CR |
13986 | else |
13987 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> | |
13988 | " | |
13989 | if test "x$ac_cv_have_decl_tzname" = xyes; then : | |
13990 | ac_have_decl=1 | |
13991 | else | |
13992 | ac_have_decl=0 | |
abe2eb5b CR |
13993 | fi |
13994 | ||
1b1fe467 CR |
13995 | cat >>confdefs.h <<_ACEOF |
13996 | #define HAVE_DECL_TZNAME $ac_have_decl | |
13997 | _ACEOF | |
9d6e5e30 | 13998 | |
1b1fe467 | 13999 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
dd4f3dd8 | 14000 | $as_echo_n "checking for tzname... " >&6; } |
1b1fe467 | 14001 | if ${ac_cv_var_tzname+:} false; then : |
dd4f3dd8 | 14002 | $as_echo_n "(cached) " >&6 |
9d6e5e30 | 14003 | else |
1b1fe467 | 14004 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
9d6e5e30 CR |
14005 | /* end confdefs.h. */ |
14006 | #include <time.h> | |
b709b946 CR |
14007 | #if !HAVE_DECL_TZNAME |
14008 | extern char *tzname[]; | |
14009 | #endif | |
9d6e5e30 | 14010 | |
b709b946 CR |
14011 | int |
14012 | main () | |
14013 | { | |
14014 | return tzname[0][0]; | |
14015 | ; | |
14016 | return 0; | |
14017 | } | |
14018 | _ACEOF | |
1b1fe467 | 14019 | if ac_fn_c_try_link "$LINENO"; then : |
b709b946 CR |
14020 | ac_cv_var_tzname=yes |
14021 | else | |
1b1fe467 | 14022 | ac_cv_var_tzname=no |
b709b946 | 14023 | fi |
1b1fe467 CR |
14024 | rm -f core conftest.err conftest.$ac_objext \ |
14025 | conftest$ac_exeext conftest.$ac_ext | |
b709b946 | 14026 | fi |
1b1fe467 | 14027 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
dd4f3dd8 | 14028 | $as_echo "$ac_cv_var_tzname" >&6; } |
b709b946 CR |
14029 | if test $ac_cv_var_tzname = yes; then |
14030 | ||
1b1fe467 | 14031 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
b709b946 CR |
14032 | |
14033 | fi | |
14034 | fi | |
14035 | ||
1b1fe467 | 14036 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timezone in sys/time.h and time.h" >&5 |
dd4f3dd8 | 14037 | $as_echo_n "checking for struct timezone in sys/time.h and time.h... " >&6; } |
1b1fe467 | 14038 | if ${bash_cv_struct_timezone+:} false; then : |
dd4f3dd8 | 14039 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
14040 | else |
14041 | ||
1b1fe467 | 14042 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b709b946 CR |
14043 | /* end confdefs.h. */ |
14044 | #include <sys/time.h> | |
14045 | ||
14046 | _ACEOF | |
14047 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 14048 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
b709b946 CR |
14049 | bash_cv_struct_timezone=yes |
14050 | else | |
1b1fe467 | 14051 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b709b946 CR |
14052 | /* end confdefs.h. */ |
14053 | #include <time.h> | |
14054 | ||
14055 | _ACEOF | |
14056 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 14057 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
d3a24ed2 CR |
14058 | bash_cv_struct_timezone=yes |
14059 | else | |
14060 | bash_cv_struct_timezone=no | |
14061 | fi | |
14062 | rm -f conftest* | |
14063 | ||
14064 | fi | |
14065 | rm -f conftest* | |
14066 | ||
a82a04b3 | 14067 | |
d3a24ed2 CR |
14068 | fi |
14069 | ||
1b1fe467 | 14070 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timezone" >&5 |
dd4f3dd8 | 14071 | $as_echo "$bash_cv_struct_timezone" >&6; } |
d3a24ed2 | 14072 | if test $bash_cv_struct_timezone = yes; then |
1b1fe467 | 14073 | $as_echo "#define HAVE_STRUCT_TIMEZONE 1" >>confdefs.h |
d3a24ed2 CR |
14074 | |
14075 | fi | |
14076 | ||
a82a04b3 | 14077 | |
1b1fe467 | 14078 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for offset of exit status in return status from wait" >&5 |
7d92f73f | 14079 | $as_echo_n "checking for offset of exit status in return status from wait... " >&6; } |
1b1fe467 | 14080 | if ${bash_cv_wexitstatus_offset+:} false; then : |
7d92f73f CR |
14081 | $as_echo_n "(cached) " >&6 |
14082 | else | |
1b1fe467 CR |
14083 | if test "$cross_compiling" = yes; then : |
14084 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&5 | |
7d92f73f CR |
14085 | $as_echo "$as_me: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&2;} |
14086 | bash_cv_wexitstatus_offset=0 | |
14087 | ||
14088 | else | |
1b1fe467 | 14089 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
71412226 | 14090 | /* end confdefs.h. */ |
7d92f73f CR |
14091 | |
14092 | #include <stdlib.h> | |
14093 | #include <unistd.h> | |
14094 | ||
14095 | #include <sys/wait.h> | |
14096 | ||
14097 | main(c, v) | |
14098 | int c; | |
14099 | char **v; | |
14100 | { | |
14101 | pid_t pid, p; | |
14102 | int s, i, n; | |
14103 | ||
14104 | s = 0; | |
14105 | pid = fork(); | |
14106 | if (pid == 0) | |
14107 | exit (42); | |
14108 | ||
14109 | /* wait for the process */ | |
14110 | p = wait(&s); | |
14111 | if (p != pid) | |
14112 | exit (255); | |
14113 | ||
14114 | /* crack s */ | |
14115 | for (i = 0; i < (sizeof(s) - 8); i++) | |
14116 | { | |
14117 | n = (s >> i) & 0xff; | |
14118 | if (n == 42) | |
14119 | exit (i); | |
14120 | } | |
14121 | ||
7175a77f CR |
14122 | exit (254); |
14123 | } | |
14124 | ||
14125 | _ACEOF | |
1b1fe467 | 14126 | if ac_fn_c_try_run "$LINENO"; then : |
7175a77f CR |
14127 | bash_cv_wexitstatus_offset=0 |
14128 | else | |
1b1fe467 | 14129 | bash_cv_wexitstatus_offset=$? |
7175a77f | 14130 | fi |
1b1fe467 CR |
14131 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14132 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7175a77f CR |
14133 | fi |
14134 | ||
7175a77f CR |
14135 | fi |
14136 | ||
14137 | if test "$bash_cv_wexitstatus_offset" -gt 32 ; then | |
1b1fe467 CR |
14138 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: bad exit status from test program -- defaulting to 0" >&5 |
14139 | $as_echo "$as_me: WARNING: bad exit status from test program -- defaulting to 0" >&2;} | |
14140 | bash_cv_wexitstatus_offset=0 | |
7d92f73f | 14141 | fi |
1b1fe467 CR |
14142 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wexitstatus_offset" >&5 |
14143 | $as_echo "$bash_cv_wexitstatus_offset" >&6; } | |
7d92f73f CR |
14144 | |
14145 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 14146 | #define WEXITSTATUS_OFFSET $bash_cv_wexitstatus_offset |
7d92f73f CR |
14147 | _ACEOF |
14148 | ||
1b1fe467 CR |
14149 | |
14150 | ||
14151 | ||
14152 | ||
14153 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5 | |
14154 | $as_echo_n "checking for struct timespec in <time.h>... " >&6; } | |
14155 | if ${bash_cv_sys_struct_timespec_in_time_h+:} false; then : | |
278286c9 CR |
14156 | $as_echo_n "(cached) " >&6 |
14157 | else | |
1b1fe467 | 14158 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
278286c9 | 14159 | /* end confdefs.h. */ |
1b1fe467 | 14160 | #include <time.h> |
278286c9 CR |
14161 | |
14162 | int | |
14163 | main () | |
14164 | { | |
1b1fe467 | 14165 | static struct timespec x; x.tv_sec = x.tv_nsec; |
278286c9 CR |
14166 | ; |
14167 | return 0; | |
14168 | } | |
14169 | _ACEOF | |
1b1fe467 CR |
14170 | if ac_fn_c_try_compile "$LINENO"; then : |
14171 | bash_cv_sys_struct_timespec_in_time_h=yes | |
278286c9 | 14172 | else |
1b1fe467 | 14173 | bash_cv_sys_struct_timespec_in_time_h=no |
278286c9 CR |
14174 | fi |
14175 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14176 | fi | |
1b1fe467 CR |
14177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_time_h" >&5 |
14178 | $as_echo "$bash_cv_sys_struct_timespec_in_time_h" >&6; } | |
278286c9 | 14179 | |
1b1fe467 CR |
14180 | HAVE_STRUCT_TIMESPEC=0 |
14181 | TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
14182 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
14183 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0 | |
14184 | if test $bash_cv_sys_struct_timespec_in_time_h = yes; then | |
14185 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
278286c9 | 14186 | |
1b1fe467 CR |
14187 | $as_echo "#define TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h |
14188 | ||
14189 | TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
14190 | else | |
14191 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5 | |
14192 | $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; } | |
14193 | if ${bash_cv_sys_struct_timespec_in_sys_time_h+:} false; then : | |
278286c9 CR |
14194 | $as_echo_n "(cached) " >&6 |
14195 | else | |
1b1fe467 | 14196 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
278286c9 | 14197 | /* end confdefs.h. */ |
1b1fe467 | 14198 | #include <sys/time.h> |
278286c9 CR |
14199 | |
14200 | int | |
14201 | main () | |
14202 | { | |
1b1fe467 | 14203 | static struct timespec x; x.tv_sec = x.tv_nsec; |
278286c9 CR |
14204 | ; |
14205 | return 0; | |
14206 | } | |
14207 | _ACEOF | |
1b1fe467 CR |
14208 | if ac_fn_c_try_compile "$LINENO"; then : |
14209 | bash_cv_sys_struct_timespec_in_sys_time_h=yes | |
278286c9 | 14210 | else |
1b1fe467 CR |
14211 | bash_cv_sys_struct_timespec_in_sys_time_h=no |
14212 | fi | |
14213 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14214 | fi | |
14215 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_sys_time_h" >&5 | |
14216 | $as_echo "$bash_cv_sys_struct_timespec_in_sys_time_h" >&6; } | |
14217 | if test $bash_cv_sys_struct_timespec_in_sys_time_h = yes; then | |
14218 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
14219 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
278286c9 | 14220 | |
1b1fe467 CR |
14221 | $as_echo "#define SYS_TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h |
14222 | ||
14223 | else | |
14224 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5 | |
14225 | $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; } | |
14226 | if ${bash_cv_sys_struct_timespec_in_pthread_h+:} false; then : | |
14227 | $as_echo_n "(cached) " >&6 | |
14228 | else | |
14229 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
278286c9 | 14230 | /* end confdefs.h. */ |
1b1fe467 | 14231 | #include <pthread.h> |
278286c9 CR |
14232 | |
14233 | int | |
14234 | main () | |
14235 | { | |
1b1fe467 | 14236 | static struct timespec x; x.tv_sec = x.tv_nsec; |
278286c9 CR |
14237 | ; |
14238 | return 0; | |
14239 | } | |
14240 | _ACEOF | |
1b1fe467 CR |
14241 | if ac_fn_c_try_compile "$LINENO"; then : |
14242 | bash_cv_sys_struct_timespec_in_pthread_h=yes | |
278286c9 | 14243 | else |
1b1fe467 | 14244 | bash_cv_sys_struct_timespec_in_pthread_h=no |
278286c9 CR |
14245 | fi |
14246 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14247 | fi | |
1b1fe467 CR |
14248 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_pthread_h" >&5 |
14249 | $as_echo "$bash_cv_sys_struct_timespec_in_pthread_h" >&6; } | |
14250 | if test $bash_cv_sys_struct_timespec_in_pthread_h = yes; then | |
14251 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 | |
14252 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
14253 | ||
14254 | $as_echo "#define PTHREAD_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
14255 | ||
14256 | fi | |
14257 | fi | |
14258 | fi | |
14259 | ||
14260 | ||
14261 | ||
278286c9 | 14262 | |
1b1fe467 CR |
14263 | |
14264 | ||
14265 | ||
14266 | ||
14267 | ||
14268 | 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> | |
14269 | #include <sys/stat.h> | |
14270 | " | |
14271 | if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then : | |
278286c9 CR |
14272 | |
14273 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 14274 | #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1 |
278286c9 CR |
14275 | _ACEOF |
14276 | ||
1b1fe467 CR |
14277 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5 |
14278 | $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; } | |
14279 | if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then : | |
278286c9 CR |
14280 | $as_echo_n "(cached) " >&6 |
14281 | else | |
1b1fe467 | 14282 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
278286c9 | 14283 | /* end confdefs.h. */ |
1b1fe467 CR |
14284 | |
14285 | #include <sys/types.h> | |
14286 | #include <sys/stat.h> | |
14287 | #if HAVE_SYS_TIME_H | |
14288 | # include <sys/time.h> | |
14289 | #endif | |
14290 | #include <time.h> | |
14291 | struct timespec ts; | |
14292 | struct stat st; | |
278286c9 CR |
14293 | |
14294 | int | |
14295 | main () | |
14296 | { | |
14297 | ||
1b1fe467 | 14298 | st.st_atim = ts; |
278286c9 CR |
14299 | |
14300 | ; | |
14301 | return 0; | |
14302 | } | |
14303 | _ACEOF | |
1b1fe467 CR |
14304 | if ac_fn_c_try_compile "$LINENO"; then : |
14305 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes | |
278286c9 | 14306 | else |
1b1fe467 | 14307 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no |
278286c9 CR |
14308 | fi |
14309 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14310 | fi | |
1b1fe467 CR |
14311 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5 |
14312 | $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; } | |
14313 | if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then | |
278286c9 | 14314 | |
1b1fe467 CR |
14315 | $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h |
14316 | ||
14317 | fi | |
14318 | else | |
14319 | 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> | |
14320 | #include <sys/stat.h> | |
14321 | " | |
14322 | if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then : | |
7175a77f CR |
14323 | |
14324 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 14325 | #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1 |
7175a77f CR |
14326 | _ACEOF |
14327 | ||
278286c9 | 14328 | |
278286c9 | 14329 | else |
1b1fe467 CR |
14330 | ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h> |
14331 | #include <sys/stat.h> | |
14332 | " | |
14333 | if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then : | |
278286c9 | 14334 | |
1b1fe467 CR |
14335 | cat >>confdefs.h <<_ACEOF |
14336 | #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1 | |
278286c9 CR |
14337 | _ACEOF |
14338 | ||
14339 | ||
14340 | else | |
1b1fe467 CR |
14341 | 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> |
14342 | #include <sys/stat.h> | |
14343 | " | |
14344 | if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then : | |
278286c9 CR |
14345 | |
14346 | cat >>confdefs.h <<_ACEOF | |
14347 | #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1 | |
14348 | _ACEOF | |
14349 | ||
14350 | ||
14351 | fi | |
14352 | ||
14353 | fi | |
14354 | ||
14355 | fi | |
14356 | ||
14357 | fi | |
14358 | ||
14359 | ||
14360 | ||
1b1fe467 | 14361 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the existence of strsignal" >&5 |
dd4f3dd8 | 14362 | $as_echo_n "checking for the existence of strsignal... " >&6; } |
1b1fe467 | 14363 | if ${bash_cv_have_strsignal+:} false; then : |
dd4f3dd8 | 14364 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14365 | else |
1b1fe467 | 14366 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14367 | /* end confdefs.h. */ |
ccc6cda3 JA |
14368 | #include <sys/types.h> |
14369 | #include <signal.h> | |
f73dda09 JA |
14370 | int |
14371 | main () | |
14372 | { | |
ccc6cda3 | 14373 | char *s = (char *)strsignal(2); |
1b1fe467 CR |
14374 | ; |
14375 | return 0; | |
14376 | } | |
14377 | _ACEOF | |
14378 | if ac_fn_c_try_link "$LINENO"; then : | |
ccc6cda3 JA |
14379 | bash_cv_have_strsignal=yes |
14380 | else | |
1b1fe467 | 14381 | bash_cv_have_strsignal=no |
ccc6cda3 | 14382 | fi |
1b1fe467 CR |
14383 | rm -f core conftest.err conftest.$ac_objext \ |
14384 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 JA |
14385 | fi |
14386 | ||
1b1fe467 | 14387 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_strsignal" >&5 |
dd4f3dd8 | 14388 | $as_echo "$bash_cv_have_strsignal" >&6; } |
ccc6cda3 | 14389 | if test $bash_cv_have_strsignal = yes; then |
1b1fe467 | 14390 | $as_echo "#define HAVE_STRSIGNAL 1" >>confdefs.h |
ccc6cda3 JA |
14391 | |
14392 | fi | |
14393 | ||
1b1fe467 | 14394 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if opendir() opens non-directories" >&5 |
dd4f3dd8 | 14395 | $as_echo_n "checking if opendir() opens non-directories... " >&6; } |
1b1fe467 | 14396 | if ${bash_cv_opendir_not_robust+:} false; then : |
dd4f3dd8 | 14397 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14398 | else |
1b1fe467 CR |
14399 | if test "$cross_compiling" = yes; then : |
14400 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14401 | $as_echo "$as_me: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14402 | bash_cv_opendir_not_robust=no |
14403 | ||
ccc6cda3 | 14404 | else |
1b1fe467 | 14405 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14406 | /* end confdefs.h. */ |
ccc6cda3 JA |
14407 | |
14408 | #include <stdio.h> | |
14409 | #include <sys/types.h> | |
14410 | #include <fcntl.h> | |
14411 | #ifdef HAVE_UNISTD_H | |
14412 | # include <unistd.h> | |
14413 | #endif /* HAVE_UNISTD_H */ | |
14414 | #if defined(HAVE_DIRENT_H) | |
14415 | # include <dirent.h> | |
14416 | #else | |
14417 | # define dirent direct | |
14418 | # ifdef HAVE_SYS_NDIR_H | |
14419 | # include <sys/ndir.h> | |
14420 | # endif /* SYSNDIR */ | |
14421 | # ifdef HAVE_SYS_DIR_H | |
14422 | # include <sys/dir.h> | |
14423 | # endif /* SYSDIR */ | |
14424 | # ifdef HAVE_NDIR_H | |
14425 | # include <ndir.h> | |
14426 | # endif | |
14427 | #endif /* HAVE_DIRENT_H */ | |
14428 | main() | |
14429 | { | |
14430 | DIR *dir; | |
bb70624e | 14431 | int fd, err; |
30915f17 | 14432 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
14433 | if (err < 0) { |
14434 | perror("mkdir"); | |
14435 | exit(1); | |
14436 | } | |
30915f17 CR |
14437 | unlink("bash-aclocal/not_a_directory"); |
14438 | fd = open("bash-aclocal/not_a_directory", O_WRONLY|O_CREAT|O_EXCL, 0666); | |
ccc6cda3 JA |
14439 | write(fd, "\n", 1); |
14440 | close(fd); | |
30915f17 CR |
14441 | dir = opendir("bash-aclocal/not_a_directory"); |
14442 | unlink("bash-aclocal/not_a_directory"); | |
14443 | rmdir("bash-aclocal"); | |
ccc6cda3 JA |
14444 | exit (dir == 0); |
14445 | } | |
f73dda09 | 14446 | _ACEOF |
1b1fe467 | 14447 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14448 | bash_cv_opendir_not_robust=yes |
14449 | else | |
1b1fe467 | 14450 | bash_cv_opendir_not_robust=no |
ccc6cda3 | 14451 | fi |
1b1fe467 CR |
14452 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14453 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14454 | fi |
b709b946 | 14455 | |
ccc6cda3 JA |
14456 | fi |
14457 | ||
1b1fe467 | 14458 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_opendir_not_robust" >&5 |
dd4f3dd8 | 14459 | $as_echo "$bash_cv_opendir_not_robust" >&6; } |
ccc6cda3 | 14460 | if test $bash_cv_opendir_not_robust = yes; then |
1b1fe467 | 14461 | $as_echo "#define OPENDIR_NOT_ROBUST 1" >>confdefs.h |
ccc6cda3 JA |
14462 | |
14463 | fi | |
14464 | ||
1b1fe467 | 14465 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ulimit can substitute for getdtablesize" >&5 |
dd4f3dd8 | 14466 | $as_echo_n "checking whether ulimit can substitute for getdtablesize... " >&6; } |
1b1fe467 | 14467 | if ${bash_cv_ulimit_maxfds+:} false; then : |
dd4f3dd8 | 14468 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14469 | else |
1b1fe467 CR |
14470 | if test "$cross_compiling" = yes; then : |
14471 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14472 | $as_echo "$as_me: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14473 | bash_cv_ulimit_maxfds=no |
14474 | ||
ccc6cda3 | 14475 | else |
1b1fe467 | 14476 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14477 | /* end confdefs.h. */ |
ccc6cda3 JA |
14478 | |
14479 | main() | |
14480 | { | |
14481 | long maxfds = ulimit(4, 0L); | |
14482 | exit (maxfds == -1L); | |
14483 | } | |
14484 | ||
f73dda09 | 14485 | _ACEOF |
1b1fe467 | 14486 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14487 | bash_cv_ulimit_maxfds=yes |
14488 | else | |
1b1fe467 | 14489 | bash_cv_ulimit_maxfds=no |
547ef914 | 14490 | fi |
1b1fe467 CR |
14491 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14492 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
09767ff0 CR |
14493 | fi |
14494 | ||
09767ff0 | 14495 | fi |
547ef914 | 14496 | |
1b1fe467 | 14497 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_ulimit_maxfds" >&5 |
dd4f3dd8 | 14498 | $as_echo "$bash_cv_ulimit_maxfds" >&6; } |
2e4498b3 | 14499 | if test $bash_cv_ulimit_maxfds = yes; then |
1b1fe467 | 14500 | $as_echo "#define ULIMIT_MAXFDS 1" >>confdefs.h |
2e4498b3 CR |
14501 | |
14502 | fi | |
14503 | ||
14504 | ||
14505 | ||
14506 | ||
14507 | ||
53ac45a3 CR |
14508 | |
14509 | ||
14510 | ||
1b1fe467 CR |
14511 | ac_fn_c_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h> |
14512 | " | |
14513 | if test "x$ac_cv_have_decl_fpurge" = xyes; then : | |
14514 | ac_have_decl=1 | |
53ac45a3 | 14515 | else |
1b1fe467 | 14516 | ac_have_decl=0 |
53ac45a3 | 14517 | fi |
53ac45a3 CR |
14518 | |
14519 | cat >>confdefs.h <<_ACEOF | |
1b1fe467 | 14520 | #define HAVE_DECL_FPURGE $ac_have_decl |
7175a77f CR |
14521 | _ACEOF |
14522 | ||
14523 | ||
1b1fe467 | 14524 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if getenv can be redefined" >&5 |
dd4f3dd8 | 14525 | $as_echo_n "checking to see if getenv can be redefined... " >&6; } |
1b1fe467 | 14526 | if ${bash_cv_getenv_redef+:} false; then : |
dd4f3dd8 | 14527 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14528 | else |
1b1fe467 CR |
14529 | if test "$cross_compiling" = yes; then : |
14530 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&5 | |
dd4f3dd8 | 14531 | $as_echo "$as_me: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&2;} |
cce855bc JA |
14532 | bash_cv_getenv_redef=yes |
14533 | ||
ccc6cda3 | 14534 | else |
1b1fe467 | 14535 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14536 | /* end confdefs.h. */ |
ccc6cda3 JA |
14537 | |
14538 | #ifdef HAVE_UNISTD_H | |
14539 | # include <unistd.h> | |
14540 | #endif | |
14541 | #ifndef __STDC__ | |
14542 | # ifndef const | |
14543 | # define const | |
14544 | # endif | |
14545 | #endif | |
14546 | char * | |
14547 | getenv (name) | |
14548 | #if defined (__linux__) || defined (__bsdi__) || defined (convex) | |
14549 | const char *name; | |
14550 | #else | |
14551 | char const *name; | |
14552 | #endif /* !__linux__ && !__bsdi__ && !convex */ | |
14553 | { | |
14554 | return "42"; | |
14555 | } | |
14556 | main() | |
14557 | { | |
14558 | char *s; | |
14559 | /* The next allows this program to run, but does not allow bash to link | |
14560 | when it redefines getenv. I'm not really interested in figuring out | |
14561 | why not. */ | |
14562 | #if defined (NeXT) | |
14563 | exit(1); | |
14564 | #endif | |
14565 | s = getenv("ABCDE"); | |
14566 | exit(s == 0); /* force optimizer to leave getenv in */ | |
14567 | } | |
14568 | ||
f73dda09 | 14569 | _ACEOF |
1b1fe467 | 14570 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14571 | bash_cv_getenv_redef=yes |
14572 | else | |
1b1fe467 | 14573 | bash_cv_getenv_redef=no |
ccc6cda3 | 14574 | fi |
1b1fe467 CR |
14575 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14576 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14577 | fi |
b709b946 | 14578 | |
ccc6cda3 JA |
14579 | fi |
14580 | ||
1b1fe467 | 14581 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getenv_redef" >&5 |
dd4f3dd8 | 14582 | $as_echo "$bash_cv_getenv_redef" >&6; } |
ccc6cda3 | 14583 | if test $bash_cv_getenv_redef = yes; then |
1b1fe467 | 14584 | $as_echo "#define CAN_REDEFINE_GETENV 1" >>confdefs.h |
ccc6cda3 JA |
14585 | |
14586 | fi | |
14587 | ||
7117c2d2 | 14588 | if test "$ac_cv_func_getcwd" = "yes"; then |
1b1fe467 | 14589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getcwd() will dynamically allocate memory with 0 size" >&5 |
dd4f3dd8 | 14590 | $as_echo_n "checking if getcwd() will dynamically allocate memory with 0 size... " >&6; } |
1b1fe467 | 14591 | if ${bash_cv_getcwd_malloc+:} false; then : |
dd4f3dd8 | 14592 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14593 | else |
1b1fe467 CR |
14594 | if test "$cross_compiling" = yes; then : |
14595 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14596 | $as_echo "$as_me: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&2;} |
f085a21f | 14597 | bash_cv_getcwd_malloc=no |
cce855bc | 14598 | |
ccc6cda3 | 14599 | else |
1b1fe467 | 14600 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14601 | /* end confdefs.h. */ |
ccc6cda3 JA |
14602 | |
14603 | #include <stdio.h> | |
14604 | #ifdef HAVE_UNISTD_H | |
14605 | #include <unistd.h> | |
14606 | #endif | |
14607 | ||
ccc6cda3 JA |
14608 | main() |
14609 | { | |
f085a21f CR |
14610 | char *xpwd; |
14611 | xpwd = getcwd(0, 0); | |
14612 | exit (xpwd == 0); | |
ccc6cda3 JA |
14613 | } |
14614 | ||
f73dda09 | 14615 | _ACEOF |
1b1fe467 | 14616 | if ac_fn_c_try_run "$LINENO"; then : |
f085a21f | 14617 | bash_cv_getcwd_malloc=yes |
ccc6cda3 | 14618 | else |
1b1fe467 | 14619 | bash_cv_getcwd_malloc=no |
ccc6cda3 | 14620 | fi |
1b1fe467 CR |
14621 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14622 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14623 | fi |
b709b946 | 14624 | |
ccc6cda3 JA |
14625 | fi |
14626 | ||
1b1fe467 | 14627 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getcwd_malloc" >&5 |
dd4f3dd8 | 14628 | $as_echo "$bash_cv_getcwd_malloc" >&6; } |
f085a21f | 14629 | if test $bash_cv_getcwd_malloc = no; then |
1b1fe467 | 14630 | $as_echo "#define GETCWD_BROKEN 1" >>confdefs.h |
a82a04b3 | 14631 | |
b709b946 | 14632 | case " $LIBOBJS " in |
5e4a95c7 | 14633 | *" getcwd.$ac_objext "* ) ;; |
b709b946 CR |
14634 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
14635 | ;; | |
5e4a95c7 CR |
14636 | esac |
14637 | ||
ccc6cda3 JA |
14638 | fi |
14639 | ||
ccc6cda3 JA |
14640 | fi |
14641 | ||
1b1fe467 | 14642 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5 |
dd4f3dd8 | 14643 | $as_echo_n "checking for presence of POSIX-style sigsetjmp/siglongjmp... " >&6; } |
1b1fe467 | 14644 | if ${bash_cv_func_sigsetjmp+:} false; then : |
dd4f3dd8 | 14645 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14646 | else |
1b1fe467 CR |
14647 | if test "$cross_compiling" = yes; then : |
14648 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 14649 | $as_echo "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
14650 | bash_cv_func_sigsetjmp=missing |
14651 | ||
ccc6cda3 | 14652 | else |
1b1fe467 | 14653 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14654 | /* end confdefs.h. */ |
ccc6cda3 JA |
14655 | |
14656 | #ifdef HAVE_UNISTD_H | |
14657 | #include <unistd.h> | |
14658 | #endif | |
14659 | #include <sys/types.h> | |
14660 | #include <signal.h> | |
14661 | #include <setjmp.h> | |
14662 | ||
14663 | main() | |
14664 | { | |
14665 | #if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS) | |
14666 | exit (1); | |
14667 | #else | |
14668 | ||
14669 | int code; | |
14670 | sigset_t set, oset; | |
14671 | sigjmp_buf xx; | |
14672 | ||
14673 | /* get the mask */ | |
14674 | sigemptyset(&set); | |
14675 | sigemptyset(&oset); | |
14676 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set); | |
14677 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset); | |
14678 | ||
14679 | /* save it */ | |
14680 | code = sigsetjmp(xx, 1); | |
14681 | if (code) | |
14682 | exit(0); /* could get sigmask and compare to oset here. */ | |
14683 | ||
14684 | /* change it */ | |
14685 | sigaddset(&set, SIGINT); | |
14686 | sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL); | |
14687 | ||
14688 | /* and siglongjmp */ | |
14689 | siglongjmp(xx, 10); | |
14690 | exit(1); | |
14691 | #endif | |
14692 | } | |
f73dda09 | 14693 | _ACEOF |
1b1fe467 | 14694 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14695 | bash_cv_func_sigsetjmp=present |
14696 | else | |
1b1fe467 | 14697 | bash_cv_func_sigsetjmp=missing |
ccc6cda3 | 14698 | fi |
1b1fe467 CR |
14699 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14700 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14701 | fi |
b709b946 | 14702 | |
ccc6cda3 JA |
14703 | fi |
14704 | ||
1b1fe467 | 14705 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_sigsetjmp" >&5 |
dd4f3dd8 | 14706 | $as_echo "$bash_cv_func_sigsetjmp" >&6; } |
ccc6cda3 | 14707 | if test $bash_cv_func_sigsetjmp = present; then |
1b1fe467 | 14708 | $as_echo "#define HAVE_POSIX_SIGSETJMP 1" >>confdefs.h |
ccc6cda3 JA |
14709 | |
14710 | fi | |
14711 | ||
a82a04b3 | 14712 | |
1b1fe467 | 14713 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not strcoll and strcmp differ" >&5 |
dd4f3dd8 | 14714 | $as_echo_n "checking whether or not strcoll and strcmp differ... " >&6; } |
1b1fe467 | 14715 | if ${bash_cv_func_strcoll_broken+:} false; then : |
dd4f3dd8 | 14716 | $as_echo_n "(cached) " >&6 |
d166f048 | 14717 | else |
1b1fe467 CR |
14718 | if test "$cross_compiling" = yes; then : |
14719 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14720 | $as_echo "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14721 | bash_cv_func_strcoll_broken=no |
14722 | ||
d166f048 | 14723 | else |
1b1fe467 | 14724 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14725 | /* end confdefs.h. */ |
d166f048 JA |
14726 | |
14727 | #include <stdio.h> | |
14728 | #if defined (HAVE_LOCALE_H) | |
14729 | #include <locale.h> | |
14730 | #endif | |
14731 | ||
14732 | main(c, v) | |
14733 | int c; | |
14734 | char *v[]; | |
14735 | { | |
14736 | int r1, r2; | |
14737 | char *deflocale, *defcoll; | |
14738 | ||
14739 | #ifdef HAVE_SETLOCALE | |
14740 | deflocale = setlocale(LC_ALL, ""); | |
14741 | defcoll = setlocale(LC_COLLATE, ""); | |
14742 | #endif | |
14743 | ||
14744 | #ifdef HAVE_STRCOLL | |
14745 | /* These two values are taken from tests/glob-test. */ | |
14746 | r1 = strcoll("abd", "aXd"); | |
14747 | #else | |
14748 | r1 = 0; | |
14749 | #endif | |
14750 | r2 = strcmp("abd", "aXd"); | |
14751 | ||
14752 | /* These two should both be greater than 0. It is permissible for | |
14753 | a system to return different values, as long as the sign is the | |
14754 | same. */ | |
14755 | ||
14756 | /* Exit with 1 (failure) if these two values are both > 0, since | |
14757 | this tests whether strcoll(3) is broken with respect to strcmp(3) | |
14758 | in the default locale. */ | |
14759 | exit (r1 > 0 && r2 > 0); | |
14760 | } | |
14761 | ||
f73dda09 | 14762 | _ACEOF |
1b1fe467 | 14763 | if ac_fn_c_try_run "$LINENO"; then : |
d166f048 JA |
14764 | bash_cv_func_strcoll_broken=yes |
14765 | else | |
1b1fe467 | 14766 | bash_cv_func_strcoll_broken=no |
d166f048 | 14767 | fi |
1b1fe467 CR |
14768 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14769 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
d166f048 | 14770 | fi |
b709b946 | 14771 | |
d166f048 JA |
14772 | fi |
14773 | ||
1b1fe467 | 14774 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_strcoll_broken" >&5 |
dd4f3dd8 | 14775 | $as_echo "$bash_cv_func_strcoll_broken" >&6; } |
d166f048 | 14776 | if test $bash_cv_func_strcoll_broken = yes; then |
1b1fe467 | 14777 | $as_echo "#define STRCOLL_BROKEN 1" >>confdefs.h |
d166f048 JA |
14778 | |
14779 | fi | |
14780 | ||
a82a04b3 CR |
14781 | |
14782 | ||
cd0ef727 CR |
14783 | |
14784 | ||
cd0ef727 | 14785 | if test X$ac_cv_func_snprintf = Xyes; then |
1b1fe467 | 14786 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant snprintf" >&5 |
cd0ef727 | 14787 | $as_echo_n "checking for standard-conformant snprintf... " >&6; } |
1b1fe467 | 14788 | if ${bash_cv_func_snprintf+:} false; then : |
cd0ef727 CR |
14789 | $as_echo_n "(cached) " >&6 |
14790 | else | |
1b1fe467 CR |
14791 | if test "$cross_compiling" = yes; then : |
14792 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard snprintf if cross-compiling" >&5 | |
cd0ef727 CR |
14793 | $as_echo "$as_me: WARNING: cannot check standard snprintf if cross-compiling" >&2;} |
14794 | bash_cv_func_snprintf=yes | |
14795 | ||
14796 | else | |
1b1fe467 | 14797 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
cd0ef727 CR |
14798 | /* end confdefs.h. */ |
14799 | ||
14800 | #include <stdio.h> | |
14801 | ||
14802 | main() | |
14803 | { | |
14804 | int n; | |
14805 | n = snprintf (0, 0, "%s", "0123456"); | |
14806 | exit(n != 7); | |
14807 | } | |
14808 | ||
14809 | _ACEOF | |
1b1fe467 | 14810 | if ac_fn_c_try_run "$LINENO"; then : |
cd0ef727 CR |
14811 | bash_cv_func_snprintf=yes |
14812 | else | |
1b1fe467 | 14813 | bash_cv_func_snprintf=no |
cd0ef727 | 14814 | fi |
1b1fe467 CR |
14815 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14816 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cd0ef727 CR |
14817 | fi |
14818 | ||
cd0ef727 | 14819 | fi |
1b1fe467 | 14820 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_snprintf" >&5 |
cd0ef727 CR |
14821 | $as_echo "$bash_cv_func_snprintf" >&6; } |
14822 | if test $bash_cv_func_snprintf = no; then | |
14823 | ac_cv_func_snprintf=no | |
14824 | fi | |
14825 | fi | |
14826 | if test $ac_cv_func_snprintf = no; then | |
14827 | ||
1b1fe467 | 14828 | $as_echo "#define HAVE_SNPRINTF 0" >>confdefs.h |
cd0ef727 CR |
14829 | |
14830 | fi | |
14831 | ||
14832 | ||
14833 | ||
14834 | ||
14835 | ||
cd0ef727 | 14836 | if test X$ac_cv_func_vsnprintf = Xyes; then |
1b1fe467 | 14837 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant vsnprintf" >&5 |
cd0ef727 | 14838 | $as_echo_n "checking for standard-conformant vsnprintf... " >&6; } |
1b1fe467 | 14839 | if ${bash_cv_func_vsnprintf+:} false; then : |
cd0ef727 CR |
14840 | $as_echo_n "(cached) " >&6 |
14841 | else | |
1b1fe467 CR |
14842 | if test "$cross_compiling" = yes; then : |
14843 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard vsnprintf if cross-compiling" >&5 | |
cd0ef727 CR |
14844 | $as_echo "$as_me: WARNING: cannot check standard vsnprintf if cross-compiling" >&2;} |
14845 | bash_cv_func_vsnprintf=yes | |
14846 | ||
14847 | else | |
1b1fe467 | 14848 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
cd0ef727 CR |
14849 | /* end confdefs.h. */ |
14850 | ||
14851 | #if HAVE_STDARG_H | |
14852 | #include <stdarg.h> | |
14853 | #else | |
14854 | #include <varargs.h> | |
14855 | #endif | |
14856 | #include <stdio.h> | |
14857 | #include <stdlib.h> | |
14858 | ||
14859 | static int | |
14860 | #if HAVE_STDARG_H | |
14861 | foo(const char *fmt, ...) | |
14862 | #else | |
14863 | foo(format, va_alist) | |
14864 | const char *format; | |
14865 | va_dcl | |
14866 | #endif | |
14867 | { | |
14868 | va_list args; | |
14869 | int n; | |
14870 | ||
14871 | #if HAVE_STDARG_H | |
14872 | va_start(args, fmt); | |
14873 | #else | |
14874 | va_start(args); | |
14875 | #endif | |
14876 | n = vsnprintf(0, 0, fmt, args); | |
14877 | va_end (args); | |
14878 | return n; | |
14879 | } | |
14880 | ||
14881 | main() | |
14882 | { | |
14883 | int n; | |
14884 | n = foo("%s", "0123456"); | |
14885 | exit(n != 7); | |
14886 | } | |
14887 | ||
14888 | _ACEOF | |
1b1fe467 | 14889 | if ac_fn_c_try_run "$LINENO"; then : |
cd0ef727 CR |
14890 | bash_cv_func_vsnprintf=yes |
14891 | else | |
1b1fe467 | 14892 | bash_cv_func_vsnprintf=no |
cd0ef727 | 14893 | fi |
1b1fe467 CR |
14894 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14895 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cd0ef727 CR |
14896 | fi |
14897 | ||
cd0ef727 | 14898 | fi |
1b1fe467 | 14899 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_vsnprintf" >&5 |
cd0ef727 CR |
14900 | $as_echo "$bash_cv_func_vsnprintf" >&6; } |
14901 | if test $bash_cv_func_vsnprintf = no; then | |
14902 | ac_cv_func_vsnprintf=no | |
14903 | fi | |
14904 | fi | |
14905 | if test $ac_cv_func_vsnprintf = no; then | |
14906 | ||
1b1fe467 | 14907 | $as_echo "#define HAVE_VSNPRINTF 0" >>confdefs.h |
cd0ef727 CR |
14908 | |
14909 | fi | |
14910 | ||
14911 | ||
14912 | ||
7117c2d2 JA |
14913 | if test "$ac_cv_func_putenv" = "yes"; then |
14914 | ||
a82a04b3 CR |
14915 | |
14916 | ||
1b1fe467 | 14917 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant putenv declaration" >&5 |
dd4f3dd8 | 14918 | $as_echo_n "checking for standard-conformant putenv declaration... " >&6; } |
1b1fe467 | 14919 | if ${bash_cv_std_putenv+:} false; then : |
dd4f3dd8 | 14920 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14921 | else |
1b1fe467 | 14922 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14923 | /* end confdefs.h. */ |
7117c2d2 JA |
14924 | |
14925 | #if STDC_HEADERS | |
14926 | #include <stdlib.h> | |
14927 | #include <stddef.h> | |
14928 | #endif | |
14929 | #ifndef __STDC__ | |
14930 | # ifndef const | |
14931 | # define const | |
14932 | # endif | |
14933 | #endif | |
14934 | #ifdef PROTOTYPES | |
14935 | extern int putenv (char *); | |
14936 | #else | |
14937 | extern int putenv (); | |
14938 | #endif | |
14939 | ||
14940 | int | |
14941 | main () | |
14942 | { | |
14943 | return (putenv == 0); | |
14944 | ; | |
14945 | return 0; | |
14946 | } | |
14947 | _ACEOF | |
1b1fe467 | 14948 | if ac_fn_c_try_link "$LINENO"; then : |
7117c2d2 JA |
14949 | bash_cv_std_putenv=yes |
14950 | else | |
1b1fe467 | 14951 | bash_cv_std_putenv=no |
7117c2d2 JA |
14952 | |
14953 | fi | |
1b1fe467 CR |
14954 | rm -f core conftest.err conftest.$ac_objext \ |
14955 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 14956 | fi |
1b1fe467 | 14957 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_putenv" >&5 |
dd4f3dd8 | 14958 | $as_echo "$bash_cv_std_putenv" >&6; } |
7117c2d2 | 14959 | if test $bash_cv_std_putenv = yes; then |
1b1fe467 | 14960 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
14961 | |
14962 | fi | |
14963 | ||
14964 | else | |
1b1fe467 | 14965 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
14966 | |
14967 | fi | |
14968 | if test "$ac_cv_func_unsetenv" = "yes"; then | |
14969 | ||
a82a04b3 CR |
14970 | |
14971 | ||
1b1fe467 | 14972 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant unsetenv declaration" >&5 |
dd4f3dd8 | 14973 | $as_echo_n "checking for standard-conformant unsetenv declaration... " >&6; } |
1b1fe467 | 14974 | if ${bash_cv_std_unsetenv+:} false; then : |
dd4f3dd8 | 14975 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14976 | else |
1b1fe467 | 14977 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14978 | /* end confdefs.h. */ |
7117c2d2 JA |
14979 | |
14980 | #if STDC_HEADERS | |
14981 | #include <stdlib.h> | |
14982 | #include <stddef.h> | |
14983 | #endif | |
14984 | #ifndef __STDC__ | |
14985 | # ifndef const | |
14986 | # define const | |
14987 | # endif | |
14988 | #endif | |
14989 | #ifdef PROTOTYPES | |
14990 | extern int unsetenv (const char *); | |
14991 | #else | |
14992 | extern int unsetenv (); | |
14993 | #endif | |
1b1fe467 CR |
14994 | |
14995 | int | |
14996 | main () | |
14997 | { | |
14998 | return (unsetenv == 0); | |
14999 | ; | |
15000 | return 0; | |
15001 | } | |
15002 | _ACEOF | |
15003 | if ac_fn_c_try_link "$LINENO"; then : | |
7117c2d2 JA |
15004 | bash_cv_std_unsetenv=yes |
15005 | else | |
1b1fe467 | 15006 | bash_cv_std_unsetenv=no |
7117c2d2 JA |
15007 | |
15008 | fi | |
1b1fe467 CR |
15009 | rm -f core conftest.err conftest.$ac_objext \ |
15010 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 15011 | fi |
1b1fe467 | 15012 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_unsetenv" >&5 |
dd4f3dd8 | 15013 | $as_echo "$bash_cv_std_unsetenv" >&6; } |
7117c2d2 | 15014 | if test $bash_cv_std_unsetenv = yes; then |
1b1fe467 | 15015 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
15016 | |
15017 | fi | |
15018 | ||
15019 | else | |
1b1fe467 | 15020 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
15021 | |
15022 | fi | |
15023 | ||
1b1fe467 | 15024 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf floating point output in hex notation" >&5 |
dd4f3dd8 | 15025 | $as_echo_n "checking for printf floating point output in hex notation... " >&6; } |
1b1fe467 | 15026 | if ${bash_cv_printf_a_format+:} false; then : |
dd4f3dd8 | 15027 | $as_echo_n "(cached) " >&6 |
f73dda09 | 15028 | else |
1b1fe467 CR |
15029 | if test "$cross_compiling" = yes; then : |
15030 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check printf if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 15031 | $as_echo "$as_me: WARNING: cannot check printf if cross compiling -- defaulting to no" >&2;} |
f73dda09 JA |
15032 | bash_cv_printf_a_format=no |
15033 | ||
15034 | else | |
1b1fe467 | 15035 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15036 | /* end confdefs.h. */ |
f73dda09 JA |
15037 | |
15038 | #include <stdio.h> | |
15039 | #include <string.h> | |
15040 | ||
15041 | int | |
15042 | main() | |
15043 | { | |
15044 | double y = 0.0; | |
15045 | char abuf[1024]; | |
15046 | ||
15047 | sprintf(abuf, "%A", y); | |
15048 | exit(strchr(abuf, 'P') == (char *)0); | |
15049 | } | |
15050 | ||
15051 | _ACEOF | |
1b1fe467 | 15052 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
15053 | bash_cv_printf_a_format=yes |
15054 | else | |
1b1fe467 | 15055 | bash_cv_printf_a_format=no |
f73dda09 | 15056 | fi |
1b1fe467 CR |
15057 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15058 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 15059 | fi |
b709b946 | 15060 | |
f73dda09 | 15061 | fi |
d166f048 | 15062 | |
1b1fe467 | 15063 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_printf_a_format" >&5 |
dd4f3dd8 | 15064 | $as_echo "$bash_cv_printf_a_format" >&6; } |
f73dda09 | 15065 | if test $bash_cv_printf_a_format = yes; then |
1b1fe467 | 15066 | $as_echo "#define HAVE_PRINTF_A_FORMAT 1" >>confdefs.h |
d166f048 | 15067 | |
f73dda09 | 15068 | fi |
ccc6cda3 | 15069 | |
a82a04b3 CR |
15070 | |
15071 | ||
15072 | ||
1b1fe467 | 15073 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal handlers must be reinstalled when invoked" >&5 |
dd4f3dd8 | 15074 | $as_echo_n "checking if signal handlers must be reinstalled when invoked... " >&6; } |
1b1fe467 | 15075 | if ${bash_cv_must_reinstall_sighandlers+:} false; then : |
dd4f3dd8 | 15076 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15077 | else |
1b1fe467 CR |
15078 | if test "$cross_compiling" = yes; then : |
15079 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 15080 | $as_echo "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
15081 | bash_cv_must_reinstall_sighandlers=no |
15082 | ||
ccc6cda3 | 15083 | else |
1b1fe467 | 15084 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15085 | /* end confdefs.h. */ |
ccc6cda3 JA |
15086 | |
15087 | #include <signal.h> | |
15088 | #ifdef HAVE_UNISTD_H | |
15089 | #include <unistd.h> | |
15090 | #endif | |
15091 | ||
15092 | typedef RETSIGTYPE sigfunc(); | |
15093 | ||
15094 | int nsigint; | |
15095 | ||
15096 | #ifdef HAVE_POSIX_SIGNALS | |
15097 | sigfunc * | |
15098 | set_signal_handler(sig, handler) | |
15099 | int sig; | |
15100 | sigfunc *handler; | |
15101 | { | |
15102 | struct sigaction act, oact; | |
15103 | act.sa_handler = handler; | |
15104 | act.sa_flags = 0; | |
15105 | sigemptyset (&act.sa_mask); | |
15106 | sigemptyset (&oact.sa_mask); | |
15107 | sigaction (sig, &act, &oact); | |
15108 | return (oact.sa_handler); | |
15109 | } | |
15110 | #else | |
15111 | #define set_signal_handler(s, h) signal(s, h) | |
15112 | #endif | |
15113 | ||
15114 | RETSIGTYPE | |
15115 | sigint(s) | |
15116 | int s; | |
15117 | { | |
15118 | nsigint++; | |
15119 | } | |
15120 | ||
15121 | main() | |
15122 | { | |
15123 | nsigint = 0; | |
15124 | set_signal_handler(SIGINT, sigint); | |
15125 | kill((int)getpid(), SIGINT); | |
15126 | kill((int)getpid(), SIGINT); | |
15127 | exit(nsigint != 2); | |
15128 | } | |
15129 | ||
f73dda09 | 15130 | _ACEOF |
1b1fe467 | 15131 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
15132 | bash_cv_must_reinstall_sighandlers=no |
15133 | else | |
1b1fe467 | 15134 | bash_cv_must_reinstall_sighandlers=yes |
ccc6cda3 | 15135 | fi |
1b1fe467 CR |
15136 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15137 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15138 | fi |
b709b946 | 15139 | |
ccc6cda3 JA |
15140 | fi |
15141 | ||
1b1fe467 | 15142 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_must_reinstall_sighandlers" >&5 |
dd4f3dd8 | 15143 | $as_echo "$bash_cv_must_reinstall_sighandlers" >&6; } |
ccc6cda3 | 15144 | if test $bash_cv_must_reinstall_sighandlers = yes; then |
1b1fe467 | 15145 | $as_echo "#define MUST_REINSTALL_SIGHANDLERS 1" >>confdefs.h |
ccc6cda3 JA |
15146 | |
15147 | fi | |
15148 | ||
a82a04b3 | 15149 | |
1b1fe467 | 15150 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of necessary job control definitions" >&5 |
dd4f3dd8 | 15151 | $as_echo_n "checking for presence of necessary job control definitions... " >&6; } |
1b1fe467 | 15152 | if ${bash_cv_job_control_missing+:} false; then : |
dd4f3dd8 | 15153 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15154 | else |
1b1fe467 CR |
15155 | if test "$cross_compiling" = yes; then : |
15156 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 15157 | $as_echo "$as_me: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
15158 | bash_cv_job_control_missing=missing |
15159 | ||
ccc6cda3 | 15160 | else |
1b1fe467 | 15161 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15162 | /* end confdefs.h. */ |
ccc6cda3 JA |
15163 | |
15164 | #include <sys/types.h> | |
15165 | #ifdef HAVE_SYS_WAIT_H | |
15166 | #include <sys/wait.h> | |
15167 | #endif | |
15168 | #ifdef HAVE_UNISTD_H | |
15169 | #include <unistd.h> | |
15170 | #endif | |
15171 | #include <signal.h> | |
15172 | ||
15173 | /* Add more tests in here as appropriate. */ | |
15174 | main() | |
15175 | { | |
15176 | /* signal type */ | |
15177 | #if !defined (HAVE_POSIX_SIGNALS) && !defined (HAVE_BSD_SIGNALS) | |
15178 | exit(1); | |
15179 | #endif | |
15180 | ||
15181 | /* signals and tty control. */ | |
15182 | #if !defined (SIGTSTP) || !defined (SIGSTOP) || !defined (SIGCONT) | |
15183 | exit (1); | |
15184 | #endif | |
15185 | ||
15186 | /* process control */ | |
f73dda09 | 15187 | #if !defined (WNOHANG) || !defined (WUNTRACED) |
ccc6cda3 JA |
15188 | exit(1); |
15189 | #endif | |
15190 | ||
15191 | /* Posix systems have tcgetpgrp and waitpid. */ | |
15192 | #if defined (_POSIX_VERSION) && !defined (HAVE_TCGETPGRP) | |
15193 | exit(1); | |
15194 | #endif | |
15195 | ||
15196 | #if defined (_POSIX_VERSION) && !defined (HAVE_WAITPID) | |
15197 | exit(1); | |
15198 | #endif | |
15199 | ||
15200 | /* Other systems have TIOCSPGRP/TIOCGPRGP and wait3. */ | |
15201 | #if !defined (_POSIX_VERSION) && !defined (HAVE_WAIT3) | |
15202 | exit(1); | |
15203 | #endif | |
15204 | ||
15205 | exit(0); | |
15206 | } | |
f73dda09 | 15207 | _ACEOF |
1b1fe467 | 15208 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
15209 | bash_cv_job_control_missing=present |
15210 | else | |
1b1fe467 | 15211 | bash_cv_job_control_missing=missing |
ccc6cda3 | 15212 | fi |
1b1fe467 CR |
15213 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15214 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15215 | fi |
b709b946 | 15216 | |
ccc6cda3 JA |
15217 | fi |
15218 | ||
1b1fe467 | 15219 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_job_control_missing" >&5 |
dd4f3dd8 | 15220 | $as_echo "$bash_cv_job_control_missing" >&6; } |
ccc6cda3 | 15221 | if test $bash_cv_job_control_missing = missing; then |
1b1fe467 | 15222 | $as_echo "#define JOB_CONTROL_MISSING 1" >>confdefs.h |
ccc6cda3 JA |
15223 | |
15224 | fi | |
15225 | ||
1b1fe467 | 15226 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of named pipes" >&5 |
dd4f3dd8 | 15227 | $as_echo_n "checking for presence of named pipes... " >&6; } |
1b1fe467 | 15228 | if ${bash_cv_sys_named_pipes+:} false; then : |
dd4f3dd8 | 15229 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15230 | else |
1b1fe467 CR |
15231 | if test "$cross_compiling" = yes; then : |
15232 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 15233 | $as_echo "$as_me: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
15234 | bash_cv_sys_named_pipes=missing |
15235 | ||
ccc6cda3 | 15236 | else |
1b1fe467 | 15237 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15238 | /* end confdefs.h. */ |
ccc6cda3 JA |
15239 | |
15240 | #include <sys/types.h> | |
15241 | #include <sys/stat.h> | |
15242 | #ifdef HAVE_UNISTD_H | |
15243 | #include <unistd.h> | |
15244 | #endif | |
15245 | ||
15246 | /* Add more tests in here as appropriate. */ | |
15247 | main() | |
15248 | { | |
bb70624e | 15249 | int fd, err; |
ccc6cda3 JA |
15250 | |
15251 | #if defined (HAVE_MKFIFO) | |
15252 | exit (0); | |
15253 | #endif | |
15254 | ||
15255 | #if !defined (S_IFIFO) && (defined (_POSIX_VERSION) && !defined (S_ISFIFO)) | |
15256 | exit (1); | |
15257 | #endif | |
15258 | ||
15259 | #if defined (NeXT) | |
15260 | exit (1); | |
15261 | #endif | |
30915f17 | 15262 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
15263 | if (err < 0) { |
15264 | perror ("mkdir"); | |
15265 | exit(1); | |
15266 | } | |
30915f17 | 15267 | fd = mknod ("bash-aclocal/sh-np-autoconf", 0666 | S_IFIFO, 0); |
bb70624e | 15268 | if (fd == -1) { |
30915f17 | 15269 | rmdir ("bash-aclocal"); |
ccc6cda3 | 15270 | exit (1); |
bb70624e | 15271 | } |
ccc6cda3 | 15272 | close(fd); |
30915f17 CR |
15273 | unlink ("bash-aclocal/sh-np-autoconf"); |
15274 | rmdir ("bash-aclocal"); | |
ccc6cda3 JA |
15275 | exit(0); |
15276 | } | |
f73dda09 | 15277 | _ACEOF |
1b1fe467 | 15278 | if ac_fn_c_try_run "$LINENO"; then : |
5e4a95c7 | 15279 | bash_cv_sys_named_pipes=present |
ccc6cda3 | 15280 | else |
1b1fe467 | 15281 | bash_cv_sys_named_pipes=missing |
5e4a95c7 | 15282 | fi |
1b1fe467 CR |
15283 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15284 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15285 | fi |
b709b946 | 15286 | |
ccc6cda3 JA |
15287 | fi |
15288 | ||
1b1fe467 | 15289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_named_pipes" >&5 |
dd4f3dd8 | 15290 | $as_echo "$bash_cv_sys_named_pipes" >&6; } |
5e4a95c7 | 15291 | if test $bash_cv_sys_named_pipes = missing; then |
1b1fe467 | 15292 | $as_echo "#define NAMED_PIPES_MISSING 1" >>confdefs.h |
5e4a95c7 CR |
15293 | |
15294 | fi | |
15295 | ||
15296 | ||
1b1fe467 | 15297 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether termios.h defines TIOCGWINSZ" >&5 |
dd4f3dd8 | 15298 | $as_echo_n "checking whether termios.h defines TIOCGWINSZ... " >&6; } |
1b1fe467 | 15299 | if ${ac_cv_sys_tiocgwinsz_in_termios_h+:} false; then : |
dd4f3dd8 | 15300 | $as_echo_n "(cached) " >&6 |
f73dda09 | 15301 | else |
1b1fe467 | 15302 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15303 | /* end confdefs.h. */ |
f73dda09 JA |
15304 | #include <sys/types.h> |
15305 | #include <termios.h> | |
15306 | #ifdef TIOCGWINSZ | |
15307 | yes | |
15308 | #endif | |
15309 | ||
15310 | _ACEOF | |
15311 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 15312 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 JA |
15313 | ac_cv_sys_tiocgwinsz_in_termios_h=yes |
15314 | else | |
15315 | ac_cv_sys_tiocgwinsz_in_termios_h=no | |
15316 | fi | |
15317 | rm -f conftest* | |
15318 | ||
15319 | fi | |
1b1fe467 | 15320 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5 |
dd4f3dd8 | 15321 | $as_echo "$ac_cv_sys_tiocgwinsz_in_termios_h" >&6; } |
d166f048 | 15322 | |
f73dda09 | 15323 | if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then |
1b1fe467 | 15324 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5 |
dd4f3dd8 | 15325 | $as_echo_n "checking whether sys/ioctl.h defines TIOCGWINSZ... " >&6; } |
1b1fe467 | 15326 | if ${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+:} false; then : |
dd4f3dd8 | 15327 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15328 | else |
1b1fe467 | 15329 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15330 | /* end confdefs.h. */ |
ccc6cda3 JA |
15331 | #include <sys/types.h> |
15332 | #include <sys/ioctl.h> | |
f73dda09 JA |
15333 | #ifdef TIOCGWINSZ |
15334 | yes | |
15335 | #endif | |
15336 | ||
15337 | _ACEOF | |
15338 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
1b1fe467 | 15339 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 | 15340 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes |
ccc6cda3 | 15341 | else |
f73dda09 | 15342 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no |
ccc6cda3 JA |
15343 | fi |
15344 | rm -f conftest* | |
f73dda09 | 15345 | |
ccc6cda3 | 15346 | fi |
1b1fe467 | 15347 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5 |
dd4f3dd8 | 15348 | $as_echo "$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6; } |
f73dda09 JA |
15349 | |
15350 | if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then | |
ccc6cda3 | 15351 | |
1b1fe467 | 15352 | $as_echo "#define GWINSZ_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 | 15353 | |
f73dda09 | 15354 | fi |
ccc6cda3 JA |
15355 | fi |
15356 | ||
1b1fe467 | 15357 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIOCSTAT in sys/ioctl.h" >&5 |
dd4f3dd8 | 15358 | $as_echo_n "checking for TIOCSTAT in sys/ioctl.h... " >&6; } |
1b1fe467 | 15359 | if ${bash_cv_tiocstat_in_ioctl+:} false; then : |
dd4f3dd8 | 15360 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15361 | else |
1b1fe467 | 15362 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15363 | /* end confdefs.h. */ |
ccc6cda3 JA |
15364 | #include <sys/types.h> |
15365 | #include <sys/ioctl.h> | |
f73dda09 JA |
15366 | int |
15367 | main () | |
15368 | { | |
ccc6cda3 | 15369 | int x = TIOCSTAT; |
f73dda09 JA |
15370 | ; |
15371 | return 0; | |
15372 | } | |
15373 | _ACEOF | |
1b1fe467 | 15374 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15375 | bash_cv_tiocstat_in_ioctl=yes |
15376 | else | |
1b1fe467 | 15377 | bash_cv_tiocstat_in_ioctl=no |
ccc6cda3 | 15378 | fi |
b709b946 | 15379 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15380 | fi |
15381 | ||
1b1fe467 | 15382 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_tiocstat_in_ioctl" >&5 |
dd4f3dd8 | 15383 | $as_echo "$bash_cv_tiocstat_in_ioctl" >&6; } |
f73dda09 | 15384 | if test $bash_cv_tiocstat_in_ioctl = yes; then |
1b1fe467 | 15385 | $as_echo "#define TIOCSTAT_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15386 | |
15387 | fi | |
15388 | ||
1b1fe467 | 15389 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIONREAD in sys/ioctl.h" >&5 |
dd4f3dd8 | 15390 | $as_echo_n "checking for FIONREAD in sys/ioctl.h... " >&6; } |
1b1fe467 | 15391 | if ${bash_cv_fionread_in_ioctl+:} false; then : |
dd4f3dd8 | 15392 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15393 | else |
1b1fe467 | 15394 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15395 | /* end confdefs.h. */ |
ccc6cda3 JA |
15396 | #include <sys/types.h> |
15397 | #include <sys/ioctl.h> | |
f73dda09 JA |
15398 | int |
15399 | main () | |
15400 | { | |
ccc6cda3 | 15401 | int x = FIONREAD; |
f73dda09 JA |
15402 | ; |
15403 | return 0; | |
15404 | } | |
15405 | _ACEOF | |
1b1fe467 | 15406 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15407 | bash_cv_fionread_in_ioctl=yes |
15408 | else | |
1b1fe467 | 15409 | bash_cv_fionread_in_ioctl=no |
ccc6cda3 | 15410 | fi |
b709b946 | 15411 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15412 | fi |
15413 | ||
1b1fe467 | 15414 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_fionread_in_ioctl" >&5 |
dd4f3dd8 | 15415 | $as_echo "$bash_cv_fionread_in_ioctl" >&6; } |
f73dda09 | 15416 | if test $bash_cv_fionread_in_ioctl = yes; then |
1b1fe467 | 15417 | $as_echo "#define FIONREAD_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15418 | |
15419 | fi | |
15420 | ||
a82a04b3 CR |
15421 | |
15422 | ||
1b1fe467 | 15423 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WCONTINUED flag to waitpid is unavailable or available but broken" >&5 |
dd4f3dd8 | 15424 | $as_echo_n "checking whether WCONTINUED flag to waitpid is unavailable or available but broken... " >&6; } |
1b1fe467 | 15425 | if ${bash_cv_wcontinued_broken+:} false; then : |
dd4f3dd8 | 15426 | $as_echo_n "(cached) " >&6 |
cac4cdbf | 15427 | else |
1b1fe467 CR |
15428 | if test "$cross_compiling" = yes; then : |
15429 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 15430 | $as_echo "$as_me: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&2;} |
cac4cdbf CR |
15431 | bash_cv_wcontinued_broken=no |
15432 | ||
15433 | else | |
1b1fe467 | 15434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15435 | /* end confdefs.h. */ |
cac4cdbf CR |
15436 | |
15437 | #include <sys/types.h> | |
15438 | #include <sys/wait.h> | |
15439 | #include <unistd.h> | |
15440 | #include <errno.h> | |
15441 | ||
15442 | #ifndef errno | |
15443 | extern int errno; | |
15444 | #endif | |
15445 | main() | |
15446 | { | |
15447 | int x; | |
15448 | ||
15449 | x = waitpid(-1, (int *)0, WNOHANG|WCONTINUED); | |
15450 | if (x == -1 && errno == EINVAL) | |
15451 | exit (1); | |
15452 | else | |
15453 | exit (0); | |
15454 | } | |
15455 | ||
15456 | _ACEOF | |
1b1fe467 | 15457 | if ac_fn_c_try_run "$LINENO"; then : |
cac4cdbf CR |
15458 | bash_cv_wcontinued_broken=no |
15459 | else | |
1b1fe467 | 15460 | bash_cv_wcontinued_broken=yes |
cac4cdbf | 15461 | fi |
1b1fe467 CR |
15462 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15463 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cac4cdbf | 15464 | fi |
b709b946 | 15465 | |
cac4cdbf CR |
15466 | fi |
15467 | ||
1b1fe467 | 15468 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcontinued_broken" >&5 |
dd4f3dd8 | 15469 | $as_echo "$bash_cv_wcontinued_broken" >&6; } |
cac4cdbf | 15470 | if test $bash_cv_wcontinued_broken = yes; then |
1b1fe467 | 15471 | $as_echo "#define WCONTINUED_BROKEN 1" >>confdefs.h |
cac4cdbf CR |
15472 | |
15473 | fi | |
15474 | ||
a82a04b3 | 15475 | |
1b1fe467 | 15476 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t in sys/types.h" >&5 |
dd4f3dd8 | 15477 | $as_echo_n "checking for speed_t in sys/types.h... " >&6; } |
1b1fe467 | 15478 | if ${bash_cv_speed_t_in_sys_types+:} false; then : |
dd4f3dd8 | 15479 | $as_echo_n "(cached) " >&6 |
d166f048 | 15480 | else |
1b1fe467 | 15481 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15482 | /* end confdefs.h. */ |
d166f048 | 15483 | #include <sys/types.h> |
f73dda09 JA |
15484 | int |
15485 | main () | |
15486 | { | |
d166f048 | 15487 | speed_t x; |
f73dda09 JA |
15488 | ; |
15489 | return 0; | |
15490 | } | |
15491 | _ACEOF | |
1b1fe467 | 15492 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
15493 | bash_cv_speed_t_in_sys_types=yes |
15494 | else | |
1b1fe467 | 15495 | bash_cv_speed_t_in_sys_types=no |
d166f048 | 15496 | fi |
b709b946 | 15497 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
15498 | fi |
15499 | ||
1b1fe467 | 15500 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_speed_t_in_sys_types" >&5 |
dd4f3dd8 | 15501 | $as_echo "$bash_cv_speed_t_in_sys_types" >&6; } |
f73dda09 | 15502 | if test $bash_cv_speed_t_in_sys_types = yes; then |
1b1fe467 | 15503 | $as_echo "#define SPEED_T_IN_SYS_TYPES 1" >>confdefs.h |
d166f048 JA |
15504 | |
15505 | fi | |
15506 | ||
1b1fe467 | 15507 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpw functions are declared in pwd.h" >&5 |
dd4f3dd8 | 15508 | $as_echo_n "checking whether getpw functions are declared in pwd.h... " >&6; } |
1b1fe467 | 15509 | if ${bash_cv_getpw_declared+:} false; then : |
dd4f3dd8 | 15510 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15511 | else |
1b1fe467 | 15512 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15513 | /* end confdefs.h. */ |
28ef6c31 | 15514 | |
ccc6cda3 | 15515 | #include <sys/types.h> |
28ef6c31 JA |
15516 | #ifdef HAVE_UNISTD_H |
15517 | # include <unistd.h> | |
15518 | #endif | |
ccc6cda3 | 15519 | #include <pwd.h> |
28ef6c31 | 15520 | |
f73dda09 | 15521 | _ACEOF |
28ef6c31 | 15522 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
1b1fe467 | 15523 | $EGREP "getpwuid" >/dev/null 2>&1; then : |
28ef6c31 | 15524 | bash_cv_getpw_declared=yes |
ccc6cda3 | 15525 | else |
28ef6c31 | 15526 | bash_cv_getpw_declared=no |
ccc6cda3 JA |
15527 | fi |
15528 | rm -f conftest* | |
28ef6c31 | 15529 | |
ccc6cda3 JA |
15530 | fi |
15531 | ||
1b1fe467 | 15532 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getpw_declared" >&5 |
dd4f3dd8 | 15533 | $as_echo "$bash_cv_getpw_declared" >&6; } |
28ef6c31 | 15534 | if test $bash_cv_getpw_declared = yes; then |
1b1fe467 | 15535 | $as_echo "#define HAVE_GETPW_DECLS 1" >>confdefs.h |
ccc6cda3 JA |
15536 | |
15537 | fi | |
15538 | ||
1b1fe467 | 15539 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unusable real-time signals due to large values" >&5 |
dd4f3dd8 | 15540 | $as_echo_n "checking for unusable real-time signals due to large values... " >&6; } |
1b1fe467 | 15541 | if ${bash_cv_unusable_rtsigs+:} false; then : |
dd4f3dd8 | 15542 | $as_echo_n "(cached) " >&6 |
28ef6c31 | 15543 | else |
1b1fe467 CR |
15544 | if test "$cross_compiling" = yes; then : |
15545 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&5 | |
dd4f3dd8 | 15546 | $as_echo "$as_me: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&2;} |
28ef6c31 JA |
15547 | bash_cv_unusable_rtsigs=yes |
15548 | ||
15549 | else | |
1b1fe467 | 15550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15551 | /* end confdefs.h. */ |
28ef6c31 JA |
15552 | |
15553 | #include <sys/types.h> | |
15554 | #include <signal.h> | |
15555 | ||
15556 | #ifndef NSIG | |
15557 | # define NSIG 64 | |
15558 | #endif | |
15559 | ||
15560 | main () | |
15561 | { | |
15562 | int n_sigs = 2 * NSIG; | |
15563 | #ifdef SIGRTMIN | |
15564 | int rtmin = SIGRTMIN; | |
15565 | #else | |
15566 | int rtmin = 0; | |
15567 | #endif | |
15568 | ||
15569 | exit(rtmin < n_sigs); | |
15570 | } | |
f73dda09 | 15571 | _ACEOF |
1b1fe467 | 15572 | if ac_fn_c_try_run "$LINENO"; then : |
28ef6c31 JA |
15573 | bash_cv_unusable_rtsigs=yes |
15574 | else | |
1b1fe467 | 15575 | bash_cv_unusable_rtsigs=no |
28ef6c31 | 15576 | fi |
1b1fe467 CR |
15577 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15578 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
28ef6c31 | 15579 | fi |
b709b946 | 15580 | |
28ef6c31 JA |
15581 | fi |
15582 | ||
1b1fe467 | 15583 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_unusable_rtsigs" >&5 |
dd4f3dd8 | 15584 | $as_echo "$bash_cv_unusable_rtsigs" >&6; } |
28ef6c31 | 15585 | if test $bash_cv_unusable_rtsigs = yes; then |
1b1fe467 | 15586 | $as_echo "#define UNUSABLE_RT_SIGNALS 1" >>confdefs.h |
28ef6c31 JA |
15587 | |
15588 | fi | |
15589 | ||
a82a04b3 CR |
15590 | |
15591 | ||
15592 | ||
15593 | ||
f73dda09 JA |
15594 | if test "$bash_cv_sys_siglist" = no && test "$bash_cv_under_sys_siglist" = no && test "$bash_cv_have_strsignal" = no; then |
15595 | SIGLIST_O=siglist.o | |
15596 | else | |
15597 | SIGLIST_O= | |
15598 | fi | |
ccc6cda3 | 15599 | |
a82a04b3 CR |
15600 | |
15601 | ||
ccc6cda3 | 15602 | case "$host_os" in |
1b1fe467 | 15603 | hpux*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $host_os needs _KERNEL for RLIMIT defines" >&5 |
dd4f3dd8 | 15604 | $as_echo_n "checking whether $host_os needs _KERNEL for RLIMIT defines... " >&6; } |
1b1fe467 | 15605 | if ${bash_cv_kernel_rlimit+:} false; then : |
dd4f3dd8 | 15606 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15607 | else |
1b1fe467 | 15608 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15609 | /* end confdefs.h. */ |
ccc6cda3 JA |
15610 | |
15611 | #include <sys/types.h> | |
15612 | #include <sys/resource.h> | |
15613 | ||
f73dda09 JA |
15614 | int |
15615 | main () | |
15616 | { | |
ccc6cda3 JA |
15617 | |
15618 | int f; | |
15619 | f = RLIMIT_DATA; | |
15620 | ||
f73dda09 JA |
15621 | ; |
15622 | return 0; | |
15623 | } | |
15624 | _ACEOF | |
1b1fe467 | 15625 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15626 | bash_cv_kernel_rlimit=no |
15627 | else | |
1b1fe467 | 15628 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15629 | /* end confdefs.h. */ |
ccc6cda3 | 15630 | |
cce855bc JA |
15631 | #include <sys/types.h> |
15632 | #define _KERNEL | |
15633 | #include <sys/resource.h> | |
15634 | #undef _KERNEL | |
15635 | ||
f73dda09 JA |
15636 | int |
15637 | main () | |
15638 | { | |
ccc6cda3 JA |
15639 | |
15640 | int f; | |
15641 | f = RLIMIT_DATA; | |
cce855bc | 15642 | |
f73dda09 JA |
15643 | ; |
15644 | return 0; | |
15645 | } | |
15646 | _ACEOF | |
1b1fe467 | 15647 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15648 | bash_cv_kernel_rlimit=yes |
15649 | else | |
1b1fe467 | 15650 | bash_cv_kernel_rlimit=no |
ccc6cda3 | 15651 | fi |
b709b946 | 15652 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15653 | |
15654 | fi | |
b709b946 | 15655 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15656 | fi |
15657 | ||
1b1fe467 | 15658 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_kernel_rlimit" >&5 |
dd4f3dd8 | 15659 | $as_echo "$bash_cv_kernel_rlimit" >&6; } |
ccc6cda3 | 15660 | if test $bash_cv_kernel_rlimit = yes; then |
1b1fe467 | 15661 | $as_echo "#define RLIMIT_NEEDS_KERNEL 1" >>confdefs.h |
ccc6cda3 JA |
15662 | |
15663 | fi | |
15664 | ;; | |
15665 | esac | |
15666 | ||
15667 | if test "$opt_readline" = yes; then | |
d166f048 JA |
15668 | case "$host_os" in |
15669 | aix*) prefer_curses=yes ;; | |
15670 | esac | |
ccc6cda3 JA |
15671 | |
15672 | if test "X$bash_cv_termcap_lib" = "X"; then | |
15673 | _bash_needmsg=yes | |
15674 | else | |
1b1fe467 | 15675 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 15676 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 JA |
15677 | _bash_needmsg= |
15678 | fi | |
1b1fe467 CR |
15679 | if ${bash_cv_termcap_lib+:} false; then : |
15680 | $as_echo_n "(cached) " >&6 | |
15681 | else | |
15682 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" | |
15683 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
d3a24ed2 CR |
15684 | bash_cv_termcap_lib=libc |
15685 | else | |
1b1fe467 | 15686 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 |
dd4f3dd8 | 15687 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } |
1b1fe467 | 15688 | if ${ac_cv_lib_termcap_tgetent+:} false; then : |
dd4f3dd8 | 15689 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15690 | else |
f73dda09 | 15691 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15692 | LIBS="-ltermcap $LIBS" |
1b1fe467 | 15693 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15694 | /* end confdefs.h. */ |
f73dda09 | 15695 | |
b709b946 CR |
15696 | /* Override any GCC internal prototype to avoid an error. |
15697 | Use char because int might match the return type of a GCC | |
15698 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15699 | #ifdef __cplusplus |
15700 | extern "C" | |
15701 | #endif | |
f73dda09 JA |
15702 | char tgetent (); |
15703 | int | |
15704 | main () | |
15705 | { | |
b709b946 | 15706 | return tgetent (); |
f73dda09 JA |
15707 | ; |
15708 | return 0; | |
15709 | } | |
15710 | _ACEOF | |
1b1fe467 | 15711 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15712 | ac_cv_lib_termcap_tgetent=yes |
15713 | else | |
1b1fe467 | 15714 | ac_cv_lib_termcap_tgetent=no |
f73dda09 | 15715 | fi |
1b1fe467 CR |
15716 | rm -f core conftest.err conftest.$ac_objext \ |
15717 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15718 | LIBS=$ac_check_lib_save_LIBS |
15719 | fi | |
1b1fe467 | 15720 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
dd4f3dd8 | 15721 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } |
1b1fe467 | 15722 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : |
ccc6cda3 JA |
15723 | bash_cv_termcap_lib=libtermcap |
15724 | else | |
1b1fe467 | 15725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
dd4f3dd8 | 15726 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } |
1b1fe467 | 15727 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : |
dd4f3dd8 | 15728 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15729 | else |
f73dda09 JA |
15730 | ac_check_lib_save_LIBS=$LIBS |
15731 | LIBS="-ltinfo $LIBS" | |
1b1fe467 | 15732 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15733 | /* end confdefs.h. */ |
f73dda09 | 15734 | |
b709b946 CR |
15735 | /* Override any GCC internal prototype to avoid an error. |
15736 | Use char because int might match the return type of a GCC | |
15737 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15738 | #ifdef __cplusplus |
15739 | extern "C" | |
15740 | #endif | |
f73dda09 JA |
15741 | char tgetent (); |
15742 | int | |
15743 | main () | |
15744 | { | |
b709b946 | 15745 | return tgetent (); |
f73dda09 JA |
15746 | ; |
15747 | return 0; | |
15748 | } | |
15749 | _ACEOF | |
1b1fe467 | 15750 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15751 | ac_cv_lib_tinfo_tgetent=yes |
15752 | else | |
1b1fe467 | 15753 | ac_cv_lib_tinfo_tgetent=no |
f73dda09 | 15754 | fi |
1b1fe467 CR |
15755 | rm -f core conftest.err conftest.$ac_objext \ |
15756 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15757 | LIBS=$ac_check_lib_save_LIBS |
15758 | fi | |
1b1fe467 | 15759 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
dd4f3dd8 | 15760 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
1b1fe467 | 15761 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
7117c2d2 | 15762 | bash_cv_termcap_lib=libtinfo |
f73dda09 | 15763 | else |
1b1fe467 | 15764 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
dd4f3dd8 | 15765 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
1b1fe467 | 15766 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
dd4f3dd8 | 15767 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
15768 | else |
15769 | ac_check_lib_save_LIBS=$LIBS | |
15770 | LIBS="-lcurses $LIBS" | |
1b1fe467 | 15771 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15772 | /* end confdefs.h. */ |
ccc6cda3 | 15773 | |
b709b946 CR |
15774 | /* Override any GCC internal prototype to avoid an error. |
15775 | Use char because int might match the return type of a GCC | |
15776 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15777 | #ifdef __cplusplus |
15778 | extern "C" | |
15779 | #endif | |
f73dda09 JA |
15780 | char tgetent (); |
15781 | int | |
15782 | main () | |
15783 | { | |
b709b946 | 15784 | return tgetent (); |
f73dda09 JA |
15785 | ; |
15786 | return 0; | |
15787 | } | |
15788 | _ACEOF | |
1b1fe467 | 15789 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15790 | ac_cv_lib_curses_tgetent=yes |
15791 | else | |
1b1fe467 | 15792 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 15793 | fi |
1b1fe467 CR |
15794 | rm -f core conftest.err conftest.$ac_objext \ |
15795 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15796 | LIBS=$ac_check_lib_save_LIBS |
15797 | fi | |
1b1fe467 | 15798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
dd4f3dd8 | 15799 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
1b1fe467 | 15800 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
ccc6cda3 JA |
15801 | bash_cv_termcap_lib=libcurses |
15802 | else | |
1b1fe467 | 15803 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
dd4f3dd8 | 15804 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
1b1fe467 | 15805 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
dd4f3dd8 | 15806 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15807 | else |
f73dda09 | 15808 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15809 | LIBS="-lncurses $LIBS" |
1b1fe467 | 15810 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15811 | /* end confdefs.h. */ |
f73dda09 | 15812 | |
b709b946 CR |
15813 | /* Override any GCC internal prototype to avoid an error. |
15814 | Use char because int might match the return type of a GCC | |
15815 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15816 | #ifdef __cplusplus |
15817 | extern "C" | |
15818 | #endif | |
f73dda09 JA |
15819 | char tgetent (); |
15820 | int | |
15821 | main () | |
15822 | { | |
b709b946 | 15823 | return tgetent (); |
f73dda09 JA |
15824 | ; |
15825 | return 0; | |
15826 | } | |
15827 | _ACEOF | |
1b1fe467 | 15828 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15829 | ac_cv_lib_ncurses_tgetent=yes |
15830 | else | |
1b1fe467 | 15831 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 15832 | fi |
1b1fe467 CR |
15833 | rm -f core conftest.err conftest.$ac_objext \ |
15834 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15835 | LIBS=$ac_check_lib_save_LIBS |
15836 | fi | |
1b1fe467 | 15837 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
dd4f3dd8 | 15838 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
1b1fe467 | 15839 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 15840 | bash_cv_termcap_lib=libncurses |
ccc6cda3 | 15841 | else |
f73dda09 | 15842 | bash_cv_termcap_lib=gnutermcap |
ccc6cda3 | 15843 | fi |
ccc6cda3 | 15844 | |
ccc6cda3 JA |
15845 | fi |
15846 | ||
15847 | fi | |
15848 | ||
15849 | fi | |
15850 | ||
15851 | fi | |
15852 | ||
d3a24ed2 CR |
15853 | fi |
15854 | ||
ccc6cda3 | 15855 | if test "X$_bash_needmsg" = "Xyes"; then |
1b1fe467 | 15856 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 15857 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 | 15858 | fi |
1b1fe467 | 15859 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
dd4f3dd8 | 15860 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
cce855bc | 15861 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15862 | LDFLAGS="$LDFLAGS -L./lib/termcap" |
15863 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
15864 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
d166f048 | 15865 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15866 | TERMCAP_LIB=-ltermcap |
15867 | TERMCAP_DEP= | |
f73dda09 JA |
15868 | elif test $bash_cv_termcap_lib = libtinfo; then |
15869 | TERMCAP_LIB=-ltinfo | |
15870 | TERMCAP_DEP= | |
ccc6cda3 JA |
15871 | elif test $bash_cv_termcap_lib = libncurses; then |
15872 | TERMCAP_LIB=-lncurses | |
15873 | TERMCAP_DEP= | |
d3a24ed2 CR |
15874 | elif test $bash_cv_termcap_lib = libc; then |
15875 | TERMCAP_LIB= | |
15876 | TERMCAP_DEP= | |
ccc6cda3 JA |
15877 | else |
15878 | TERMCAP_LIB=-lcurses | |
15879 | TERMCAP_DEP= | |
15880 | fi | |
15881 | ||
15882 | fi | |
15883 | ||
a82a04b3 CR |
15884 | |
15885 | ||
1b1fe467 | 15886 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/fd is available" >&5 |
dd4f3dd8 | 15887 | $as_echo_n "checking whether /dev/fd is available... " >&6; } |
1b1fe467 | 15888 | if ${bash_cv_dev_fd+:} false; then : |
dd4f3dd8 | 15889 | $as_echo_n "(cached) " >&6 |
d166f048 | 15890 | else |
d3ad40de CR |
15891 | bash_cv_dev_fd="" |
15892 | if test -d /dev/fd && (exec test -r /dev/fd/0 < /dev/null) ; then | |
de3341d1 | 15893 | # check for systems like FreeBSD 5 that only provide /dev/fd/[012] |
d3ad40de | 15894 | if (exec test -r /dev/fd/3 3</dev/null) ; then |
de3341d1 CR |
15895 | bash_cv_dev_fd=standard |
15896 | else | |
15897 | bash_cv_dev_fd=absent | |
15898 | fi | |
d3ad40de CR |
15899 | fi |
15900 | if test -z "$bash_cv_dev_fd" ; then | |
15901 | if test -d /proc/self/fd && (exec test -r /proc/self/fd/0 < /dev/null) ; then | |
15902 | bash_cv_dev_fd=whacky | |
15903 | else | |
15904 | bash_cv_dev_fd=absent | |
15905 | fi | |
15906 | fi | |
d166f048 JA |
15907 | |
15908 | fi | |
15909 | ||
1b1fe467 | 15910 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_fd" >&5 |
dd4f3dd8 | 15911 | $as_echo "$bash_cv_dev_fd" >&6; } |
d166f048 | 15912 | if test $bash_cv_dev_fd = "standard"; then |
1b1fe467 | 15913 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15914 | |
1b1fe467 | 15915 | $as_echo "#define DEV_FD_PREFIX \"/dev/fd/\"" >>confdefs.h |
d166f048 JA |
15916 | |
15917 | elif test $bash_cv_dev_fd = "whacky"; then | |
1b1fe467 | 15918 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15919 | |
1b1fe467 | 15920 | $as_echo "#define DEV_FD_PREFIX \"/proc/self/fd/\"" >>confdefs.h |
d166f048 JA |
15921 | |
15922 | fi | |
15923 | ||
1b1fe467 | 15924 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/stdin stdout stderr are available" >&5 |
dd4f3dd8 | 15925 | $as_echo_n "checking whether /dev/stdin stdout stderr are available... " >&6; } |
1b1fe467 | 15926 | if ${bash_cv_dev_stdin+:} false; then : |
dd4f3dd8 | 15927 | $as_echo_n "(cached) " >&6 |
bb70624e | 15928 | else |
d3ad40de | 15929 | if test -d /dev/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e | 15930 | bash_cv_dev_stdin=present |
d3ad40de | 15931 | elif test -d /proc/self/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e JA |
15932 | bash_cv_dev_stdin=present |
15933 | else | |
15934 | bash_cv_dev_stdin=absent | |
15935 | fi | |
15936 | ||
15937 | fi | |
15938 | ||
1b1fe467 | 15939 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_stdin" >&5 |
dd4f3dd8 | 15940 | $as_echo "$bash_cv_dev_stdin" >&6; } |
bb70624e | 15941 | if test $bash_cv_dev_stdin = "present"; then |
1b1fe467 | 15942 | $as_echo "#define HAVE_DEV_STDIN 1" >>confdefs.h |
bb70624e JA |
15943 | |
15944 | fi | |
15945 | ||
1b1fe467 | 15946 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default mail directory" >&5 |
dd4f3dd8 | 15947 | $as_echo_n "checking for default mail directory... " >&6; } |
1b1fe467 | 15948 | if ${bash_cv_mail_dir+:} false; then : |
dd4f3dd8 | 15949 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
15950 | else |
15951 | if test -d /var/mail; then | |
15952 | bash_cv_mail_dir=/var/mail | |
ccc6cda3 JA |
15953 | elif test -d /var/spool/mail; then |
15954 | bash_cv_mail_dir=/var/spool/mail | |
7117c2d2 JA |
15955 | elif test -d /usr/mail; then |
15956 | bash_cv_mail_dir=/usr/mail | |
e8ce775d JA |
15957 | elif test -d /usr/spool/mail; then |
15958 | bash_cv_mail_dir=/usr/spool/mail | |
ccc6cda3 JA |
15959 | else |
15960 | bash_cv_mail_dir=unknown | |
15961 | fi | |
15962 | ||
15963 | fi | |
15964 | ||
1b1fe467 | 15965 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_mail_dir" >&5 |
dd4f3dd8 | 15966 | $as_echo "$bash_cv_mail_dir" >&6; } |
a82a04b3 | 15967 | cat >>confdefs.h <<_ACEOF |
7117c2d2 | 15968 | #define DEFAULT_MAIL_DIRECTORY "$bash_cv_mail_dir" |
a82a04b3 CR |
15969 | _ACEOF |
15970 | ||
15971 | ||
ccc6cda3 | 15972 | |
ccc6cda3 JA |
15973 | if test "$bash_cv_job_control_missing" = missing; then |
15974 | opt_job_control=no | |
15975 | fi | |
15976 | ||
15977 | if test "$opt_job_control" = yes; then | |
1b1fe467 | 15978 | $as_echo "#define JOB_CONTROL 1" >>confdefs.h |
ccc6cda3 JA |
15979 | |
15980 | JOBS_O=jobs.o | |
15981 | else | |
15982 | JOBS_O=nojobs.o | |
15983 | fi | |
15984 | ||
a82a04b3 CR |
15985 | |
15986 | ||
15987 | ||
d166f048 JA |
15988 | LOCAL_DEFS=-DSHELL |
15989 | ||
a82a04b3 | 15990 | |
b72432fd | 15991 | case "${host_os}" in |
1b1fe467 | 15992 | sysv4.2*) $as_echo "#define SVR4_2 1" >>confdefs.h |
ccc6cda3 | 15993 | |
1b1fe467 | 15994 | $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 15995 | ;; |
1b1fe467 | 15996 | sysv4*) $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 15997 | ;; |
1b1fe467 | 15998 | sysv5*) $as_echo "#define SVR5 1" >>confdefs.h |
b72432fd JA |
15999 | ;; |
16000 | hpux9*) LOCAL_CFLAGS="-DHPUX9 -DHPUX" ;; | |
ccc6cda3 JA |
16001 | hpux*) LOCAL_CFLAGS=-DHPUX ;; |
16002 | dgux*) LOCAL_CFLAGS=-D_DGUX_SOURCE; LOCAL_LIBS=-ldgc ;; | |
bb70624e JA |
16003 | isc*) LOCAL_CFLAGS=-Disc386 ;; |
16004 | rhapsody*) LOCAL_CFLAGS=-DRHAPSODY ;; | |
f73dda09 | 16005 | darwin*) LOCAL_CFLAGS=-DMACOSX ;; |
7117c2d2 JA |
16006 | sco3.2v5*) LOCAL_CFLAGS="-b elf -DWAITPID_BROKEN -DPATH_MAX=1024" ;; |
16007 | sco3.2v4*) LOCAL_CFLAGS="-DMUST_UNBLOCK_CHLD -DPATH_MAX=1024" ;; | |
ccc6cda3 | 16008 | sco3.2*) LOCAL_CFLAGS=-DMUST_UNBLOCK_CHLD ;; |
d166f048 | 16009 | sunos4*) LOCAL_CFLAGS=-DSunOS4 ;; |
d3ad40de | 16010 | solaris2.5*) LOCAL_CFLAGS="-DSunOS5 -DSOLARIS" ;; |
db31fb26 CR |
16011 | solaris2.8*) LOCAL_CFLAGS=-DSOLARIS ;; |
16012 | solaris2.9*) LOCAL_CFLAGS=-DSOLARIS ;; | |
16013 | solaris2.10*) LOCAL_CFLAGS=-DSOLARIS ;; | |
d3ad40de | 16014 | solaris2*) LOCAL_CFLAGS=-DSOLARIS ;; |
b72432fd | 16015 | lynxos*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
3ffb039a CR |
16016 | linux*) LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
16017 | case "`uname -r`" in | |
3bf257a5 | 16018 | 2.[456789]*|[34]*) $as_echo "#define PGRP_PIPE 1" >>confdefs.h |
3ffb039a CR |
16019 | ;; |
16020 | esac ;; | |
fd3925f1 | 16021 | *qnx6*) LOCAL_CFLAGS="-Dqnx -Dqnx6" LOCAL_LIBS="-lncurses" ;; |
7117c2d2 | 16022 | *qnx*) LOCAL_CFLAGS="-Dqnx -F -3s" LOCAL_LDFLAGS="-3s" LOCAL_LIBS="-lunix -lncurses" ;; |
b72432fd | 16023 | powerux*) LOCAL_LIBS="-lgen" ;; |
d3a24ed2 | 16024 | cygwin*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
fd58d46e | 16025 | opennt*|interix*) LOCAL_CFLAGS="-DNO_MAIN_ENV_ARG -DBROKEN_DIRENT_D_INO -D_POSIX_SOURCE -D_ALL_SOURCE -DRECYCLES_PIDS" ;; |
10e78433 | 16026 | *openstep*) LOCAL_CFLAGS="-D__APPLE_CC__" ;; |
b72432fd JA |
16027 | esac |
16028 | ||
16029 | case "${host_os}-${CC}" in | |
16030 | aix4.2*-*gcc*) LOCAL_LDFLAGS="-Xlinker -bexpall -Xlinker -brtl" ;; | |
16031 | aix4.2*) LOCAL_LDFLAGS="-bexpall -brtl" ;; | |
16032 | bsdi4*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux | |
690150f9 CR |
16033 | bsdi5*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux |
16034 | hpux11*-gcc*) LOCAL_LDFLAGS="-Wl,-E" ;; # allow dynamic loading | |
ccc6cda3 JA |
16035 | esac |
16036 | ||
bb70624e | 16037 | case "${host_os}" in |
28ef6c31 JA |
16038 | freebsd[3-9]*) |
16039 | if test -x /usr/bin/objformat && test "`/usr/bin/objformat`" = "elf" ; then | |
bb70624e JA |
16040 | LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
16041 | fi ;; | |
28ef6c31 | 16042 | freebsdelf*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
798a67db | 16043 | dragonfly*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
bb70624e JA |
16044 | esac |
16045 | ||
ccc6cda3 JA |
16046 | case "$host_cpu" in |
16047 | *cray*) LOCAL_CFLAGS="-DCRAY" ;; # shell var so config.h can use it | |
16048 | esac | |
16049 | ||
16050 | case "$host_cpu-$host_os" in | |
16051 | ibmrt-*bsd4*) LOCAL_CFLAGS="-ma -U__STDC__" ;; | |
16052 | esac | |
16053 | ||
16054 | case "$host_cpu-$host_vendor-$host_os" in | |
16055 | m88k-motorola-sysv3) LOCAL_CFLAGS=-DWAITPID_BROKEN ;; | |
16056 | mips-pyramid-sysv4) LOCAL_CFLAGS=-Xa ;; | |
16057 | esac | |
16058 | ||
b72432fd JA |
16059 | # |
16060 | # Shared object configuration section. These values are generated by | |
16061 | # ${srcdir}/support/shobj-conf | |
16062 | # | |
16063 | if test "$ac_cv_func_dlopen" = "yes" && test -f ${srcdir}/support/shobj-conf | |
16064 | then | |
1b1fe467 | 16065 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking shared object configuration for loadable builtins" >&5 |
dd4f3dd8 | 16066 | $as_echo_n "checking shared object configuration for loadable builtins... " >&6; } |
28ef6c31 | 16067 | eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c "${host_cpu}" -o "${host_os}" -v "${host_vendor}"` |
f73dda09 | 16068 | |
a82a04b3 CR |
16069 | |
16070 | ||
16071 | ||
16072 | ||
16073 | ||
16074 | ||
1b1fe467 | 16075 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHOBJ_STATUS" >&5 |
dd4f3dd8 | 16076 | $as_echo "$SHOBJ_STATUS" >&6; } |
b72432fd JA |
16077 | fi |
16078 | ||
ccc6cda3 JA |
16079 | # try to create a directory tree if the source is elsewhere |
16080 | # this should be packaged into a script accessible via ${srcdir}/support | |
16081 | case "$srcdir" in | |
16082 | .) ;; | |
cce855bc | 16083 | *) for d in doc tests support lib examples; do # dirs |
ccc6cda3 JA |
16084 | test -d $d || mkdir $d |
16085 | done | |
cce855bc | 16086 | for ld in readline glob tilde malloc sh termcap; do # libdirs |
ccc6cda3 JA |
16087 | test -d lib/$ld || mkdir lib/$ld |
16088 | done | |
cce855bc | 16089 | test -d examples/loadables || mkdir examples/loadables # loadable builtins |
bb70624e | 16090 | test -d examples/loadables/perl || mkdir examples/loadables/perl |
ccc6cda3 JA |
16091 | ;; |
16092 | esac | |
16093 | ||
16094 | BUILD_DIR=`pwd` | |
10590446 CR |
16095 | case "$BUILD_DIR" in |
16096 | *\ *) BUILD_DIR=`echo "$BUILD_DIR" | sed 's: :\\\\ :g'` ;; | |
16097 | *) ;; | |
16098 | esac | |
ccc6cda3 | 16099 | |
c184f645 CR |
16100 | if test -z "$localedir"; then |
16101 | localedir='${datarootdir}/locale' | |
16102 | fi | |
16103 | if test -z "$datarootdir"; then | |
16104 | datarootdir='${prefix}/share' | |
16105 | fi | |
a82a04b3 CR |
16106 | |
16107 | ||
16108 | ||
16109 | ||
16110 | ||
16111 | ||
c184f645 CR |
16112 | # Some versions of autoconf don't substitute these automatically |
16113 | ||
a82a04b3 CR |
16114 | |
16115 | ||
54a5fbe1 CR |
16116 | # directory where we install dynamically loadable builtins |
16117 | if test -z "$loadablesdir"; then | |
16118 | loadablesdir='${libdir}/bash' | |
16119 | fi | |
16120 | ||
16121 | if test -z "$headersdir"; then | |
16122 | headersdir='$(includedir)/$(PACKAGE_NAME)' | |
16123 | fi | |
16124 | ||
16125 | ||
a82a04b3 CR |
16126 | |
16127 | ||
16128 | ||
16129 | ||
16130 | ||
16131 | ||
16132 | ||
16133 | ||
16134 | ||
16135 | ||
16136 | ||
16137 | ||
16138 | ||
16139 | ||
16140 | ||
d166f048 | 16141 | |
d3ad40de | 16142 | |
d3ad40de | 16143 | |
c184f645 CR |
16144 | #AC_SUBST(ALLOCA_SOURCE) |
16145 | #AC_SUBST(ALLOCA_OBJECT) | |
16146 | ||
54a5fbe1 | 16147 | 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" |
b709b946 CR |
16148 | |
16149 | ac_config_commands="$ac_config_commands default" | |
16150 | ||
f73dda09 | 16151 | cat >confcache <<\_ACEOF |
ccc6cda3 JA |
16152 | # This file is a shell script that caches the results of configure |
16153 | # tests run on this system so they can be shared between configure | |
f73dda09 JA |
16154 | # scripts and configure runs, see configure's option --config-cache. |
16155 | # It is not useful on other systems. If it contains results you don't | |
16156 | # want to keep, you may remove or edit it. | |
726f6388 | 16157 | # |
f73dda09 JA |
16158 | # config.status only pays attention to the cache file if you give it |
16159 | # the --recheck option to rerun configure. | |
ccc6cda3 | 16160 | # |
5e4a95c7 | 16161 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
f73dda09 JA |
16162 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
16163 | # following values. | |
16164 | ||
16165 | _ACEOF | |
16166 | ||
ccc6cda3 JA |
16167 | # The following way of writing the cache mishandles newlines in values, |
16168 | # but we know of no workaround that is simple, portable, and efficient. | |
b709b946 | 16169 | # So, we kill variables containing newlines. |
ccc6cda3 JA |
16170 | # Ultrix sh set writes to stderr and can't be redirected directly, |
16171 | # and sets the high bit in the cache file unless we assign to the vars. | |
b709b946 CR |
16172 | ( |
16173 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
16174 | eval ac_val=\$$ac_var | |
16175 | case $ac_val in #( | |
16176 | *${as_nl}*) | |
16177 | case $ac_var in #( | |
1b1fe467 | 16178 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
af98a2a6 | 16179 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
b709b946 CR |
16180 | esac |
16181 | case $ac_var in #( | |
16182 | _ | IFS | as_nl) ;; #( | |
dd4f3dd8 | 16183 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
1b1fe467 | 16184 | *) { eval $ac_var=; unset $ac_var;} ;; |
b709b946 CR |
16185 | esac ;; |
16186 | esac | |
16187 | done | |
16188 | ||
f73dda09 | 16189 | (set) 2>&1 | |
b709b946 CR |
16190 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
16191 | *${as_nl}ac_space=\ *) | |
1b1fe467 CR |
16192 | # `set' does not quote correctly, so add quotes: double-quote |
16193 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
f73dda09 | 16194 | sed -n \ |
5e4a95c7 CR |
16195 | "s/'/'\\\\''/g; |
16196 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
b709b946 | 16197 | ;; #( |
f73dda09 JA |
16198 | *) |
16199 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
b709b946 | 16200 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
f73dda09 | 16201 | ;; |
b709b946 CR |
16202 | esac | |
16203 | sort | |
16204 | ) | | |
f73dda09 | 16205 | sed ' |
b709b946 | 16206 | /^ac_cv_env_/b end |
f73dda09 | 16207 | t clear |
b709b946 | 16208 | :clear |
f73dda09 JA |
16209 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
16210 | t end | |
b709b946 CR |
16211 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
16212 | :end' >>confcache | |
16213 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
16214 | if test -w "$cache_file"; then | |
1b1fe467 CR |
16215 | if test "x$cache_file" != "x/dev/null"; then |
16216 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 | |
dd4f3dd8 | 16217 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
1b1fe467 CR |
16218 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
16219 | cat confcache >"$cache_file" | |
16220 | else | |
16221 | case $cache_file in #( | |
16222 | */* | ?:*) | |
16223 | mv -f confcache "$cache_file"$$ && | |
16224 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
16225 | *) | |
16226 | mv -f confcache "$cache_file" ;; | |
16227 | esac | |
16228 | fi | |
16229 | fi | |
ccc6cda3 | 16230 | else |
1b1fe467 | 16231 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
dd4f3dd8 | 16232 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
ccc6cda3 JA |
16233 | fi |
16234 | fi | |
16235 | rm -f confcache | |
16236 | ||
ccc6cda3 JA |
16237 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
16238 | # Let make expand exec_prefix. | |
16239 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
16240 | ||
ccc6cda3 JA |
16241 | DEFS=-DHAVE_CONFIG_H |
16242 | ||
5e4a95c7 CR |
16243 | ac_libobjs= |
16244 | ac_ltlibobjs= | |
1b1fe467 | 16245 | U= |
5e4a95c7 CR |
16246 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
16247 | # 1. Remove the extension, and $U if already installed. | |
b709b946 | 16248 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
dd4f3dd8 | 16249 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
b709b946 CR |
16250 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
16251 | # will be set to the directory where LIBOBJS objects are built. | |
1b1fe467 CR |
16252 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
16253 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
5e4a95c7 CR |
16254 | done |
16255 | LIBOBJS=$ac_libobjs | |
16256 | ||
16257 | LTLIBOBJS=$ac_ltlibobjs | |
16258 | ||
16259 | ||
a82a04b3 | 16260 | |
af98a2a6 | 16261 | |
1b1fe467 | 16262 | : "${CONFIG_STATUS=./config.status}" |
dd4f3dd8 | 16263 | ac_write_fail=0 |
f73dda09 JA |
16264 | ac_clean_files_save=$ac_clean_files |
16265 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
1b1fe467 | 16266 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
dd4f3dd8 | 16267 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
1b1fe467 CR |
16268 | as_write_fail=0 |
16269 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
f73dda09 | 16270 | #! $SHELL |
a82a04b3 | 16271 | # Generated by $as_me. |
ccc6cda3 | 16272 | # Run this file to recreate the current configuration. |
ccc6cda3 | 16273 | # Compiler output produced by configure, useful for debugging |
f73dda09 | 16274 | # configure, is in config.log if it exists. |
ccc6cda3 | 16275 | |
f73dda09 | 16276 | debug=false |
5e4a95c7 CR |
16277 | ac_cs_recheck=false |
16278 | ac_cs_silent=false | |
7175a77f | 16279 | |
1b1fe467 CR |
16280 | SHELL=\${CONFIG_SHELL-$SHELL} |
16281 | export SHELL | |
16282 | _ASEOF | |
16283 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
16284 | ## -------------------- ## | |
16285 | ## M4sh Initialization. ## | |
16286 | ## -------------------- ## | |
a82a04b3 | 16287 | |
dd4f3dd8 CR |
16288 | # Be more Bourne compatible |
16289 | DUALCASE=1; export DUALCASE # for MKS sh | |
1b1fe467 | 16290 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
f73dda09 JA |
16291 | emulate sh |
16292 | NULLCMD=: | |
dd4f3dd8 | 16293 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
5e4a95c7 CR |
16294 | # is contrary to our usage. Disable this feature. |
16295 | alias -g '${1+"$@"}'='"$@"' | |
b709b946 CR |
16296 | setopt NO_GLOB_SUBST |
16297 | else | |
1b1fe467 CR |
16298 | case `(set -o) 2>/dev/null` in #( |
16299 | *posix*) : | |
16300 | set -o posix ;; #( | |
16301 | *) : | |
16302 | ;; | |
dd4f3dd8 | 16303 | esac |
f73dda09 | 16304 | fi |
dd4f3dd8 CR |
16305 | |
16306 | ||
dd4f3dd8 CR |
16307 | as_nl=' |
16308 | ' | |
16309 | export as_nl | |
16310 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
16311 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
16312 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
16313 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
1b1fe467 CR |
16314 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
16315 | # but without wasting forks for bash or zsh. | |
16316 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
16317 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
16318 | as_echo='print -r --' | |
16319 | as_echo_n='print -rn --' | |
16320 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
dd4f3dd8 CR |
16321 | as_echo='printf %s\n' |
16322 | as_echo_n='printf %s' | |
16323 | else | |
16324 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
16325 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
16326 | as_echo_n='/usr/ucb/echo -n' | |
b709b946 | 16327 | else |
dd4f3dd8 CR |
16328 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
16329 | as_echo_n_body='eval | |
16330 | arg=$1; | |
1b1fe467 | 16331 | case $arg in #( |
dd4f3dd8 CR |
16332 | *"$as_nl"*) |
16333 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
16334 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
16335 | esac; | |
16336 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
16337 | ' | |
16338 | export as_echo_n_body | |
16339 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
b709b946 | 16340 | fi |
dd4f3dd8 CR |
16341 | export as_echo_body |
16342 | as_echo='sh -c $as_echo_body as_echo' | |
16343 | fi | |
16344 | ||
16345 | # The user is always right. | |
16346 | if test "${PATH_SEPARATOR+set}" != set; then | |
16347 | PATH_SEPARATOR=: | |
16348 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
16349 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
16350 | PATH_SEPARATOR=';' | |
16351 | } | |
b709b946 CR |
16352 | fi |
16353 | ||
5e4a95c7 | 16354 | |
b709b946 CR |
16355 | # IFS |
16356 | # We need space, tab and new line, in precisely that order. Quoting is | |
16357 | # there to prevent editors from complaining about space-tab. | |
16358 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
16359 | # splitting by setting IFS to empty value.) | |
b709b946 CR |
16360 | IFS=" "" $as_nl" |
16361 | ||
16362 | # Find who we are. Look in the path if we contain no directory separator. | |
1b1fe467 CR |
16363 | as_myself= |
16364 | case $0 in #(( | |
b709b946 CR |
16365 | *[\\/]* ) as_myself=$0 ;; |
16366 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
16367 | for as_dir in $PATH | |
16368 | do | |
16369 | IFS=$as_save_IFS | |
16370 | test -z "$as_dir" && as_dir=. | |
1b1fe467 CR |
16371 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
16372 | done | |
b709b946 CR |
16373 | IFS=$as_save_IFS |
16374 | ||
16375 | ;; | |
16376 | esac | |
16377 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
16378 | # in which case we are not to be found in the path. | |
16379 | if test "x$as_myself" = x; then | |
16380 | as_myself=$0 | |
16381 | fi | |
16382 | if test ! -f "$as_myself"; then | |
dd4f3dd8 | 16383 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
1b1fe467 | 16384 | exit 1 |
b709b946 CR |
16385 | fi |
16386 | ||
1b1fe467 CR |
16387 | # Unset variables that we do not need and which cause bugs (e.g. in |
16388 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
16389 | # suppresses any "Segmentation fault" message there. '((' could | |
16390 | # trigger a bug in pdksh 5.2.14. | |
16391 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
16392 | do eval test x\${$as_var+set} = xset \ | |
16393 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
b709b946 | 16394 | done |
5e4a95c7 CR |
16395 | PS1='$ ' |
16396 | PS2='> ' | |
16397 | PS4='+ ' | |
16398 | ||
16399 | # NLS nuisances. | |
dd4f3dd8 CR |
16400 | LC_ALL=C |
16401 | export LC_ALL | |
16402 | LANGUAGE=C | |
16403 | export LANGUAGE | |
5e4a95c7 | 16404 | |
1b1fe467 CR |
16405 | # CDPATH. |
16406 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
16407 | ||
16408 | ||
16409 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
16410 | # ---------------------------------------- | |
16411 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
16412 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
16413 | # script with STATUS, using 1 if that was 0. | |
16414 | as_fn_error () | |
16415 | { | |
16416 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
16417 | if test "$4"; then | |
16418 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
16419 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
16420 | fi | |
16421 | $as_echo "$as_me: error: $2" >&2 | |
16422 | as_fn_exit $as_status | |
16423 | } # as_fn_error | |
16424 | ||
16425 | ||
16426 | # as_fn_set_status STATUS | |
16427 | # ----------------------- | |
16428 | # Set $? to STATUS, without forking. | |
16429 | as_fn_set_status () | |
16430 | { | |
16431 | return $1 | |
16432 | } # as_fn_set_status | |
16433 | ||
16434 | # as_fn_exit STATUS | |
16435 | # ----------------- | |
16436 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
16437 | as_fn_exit () | |
16438 | { | |
16439 | set +e | |
16440 | as_fn_set_status $1 | |
16441 | exit $1 | |
16442 | } # as_fn_exit | |
16443 | ||
16444 | # as_fn_unset VAR | |
16445 | # --------------- | |
16446 | # Portably unset VAR. | |
16447 | as_fn_unset () | |
16448 | { | |
16449 | { eval $1=; unset $1;} | |
16450 | } | |
16451 | as_unset=as_fn_unset | |
16452 | # as_fn_append VAR VALUE | |
16453 | # ---------------------- | |
16454 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
16455 | # advantage of any shell optimizations that allow amortized linear growth over | |
16456 | # repeated appends, instead of the typical quadratic growth present in naive | |
16457 | # implementations. | |
16458 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
16459 | eval 'as_fn_append () | |
16460 | { | |
16461 | eval $1+=\$2 | |
16462 | }' | |
16463 | else | |
16464 | as_fn_append () | |
16465 | { | |
16466 | eval $1=\$$1\$2 | |
16467 | } | |
16468 | fi # as_fn_append | |
16469 | ||
16470 | # as_fn_arith ARG... | |
16471 | # ------------------ | |
16472 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
16473 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
16474 | # must be portable across $(()) and expr. | |
16475 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
16476 | eval 'as_fn_arith () | |
16477 | { | |
16478 | as_val=$(( $* )) | |
16479 | }' | |
16480 | else | |
16481 | as_fn_arith () | |
16482 | { | |
16483 | as_val=`expr "$@" || test $? -eq 1` | |
16484 | } | |
16485 | fi # as_fn_arith | |
16486 | ||
16487 | ||
b709b946 CR |
16488 | if expr a : '\(a\)' >/dev/null 2>&1 && |
16489 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
5e4a95c7 CR |
16490 | as_expr=expr |
16491 | else | |
16492 | as_expr=false | |
16493 | fi | |
16494 | ||
b709b946 | 16495 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
5e4a95c7 CR |
16496 | as_basename=basename |
16497 | else | |
16498 | as_basename=false | |
16499 | fi | |
a82a04b3 | 16500 | |
1b1fe467 CR |
16501 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
16502 | as_dirname=dirname | |
16503 | else | |
16504 | as_dirname=false | |
16505 | fi | |
f73dda09 | 16506 | |
b709b946 | 16507 | as_me=`$as_basename -- "$0" || |
a82a04b3 CR |
16508 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
16509 | X"$0" : 'X\(//\)$' \| \ | |
b709b946 | 16510 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 16511 | $as_echo X/"$0" | |
b709b946 CR |
16512 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
16513 | s//\1/ | |
16514 | q | |
16515 | } | |
16516 | /^X\/\(\/\/\)$/{ | |
16517 | s//\1/ | |
16518 | q | |
16519 | } | |
16520 | /^X\/\(\/\).*/{ | |
16521 | s//\1/ | |
16522 | q | |
16523 | } | |
16524 | s/.*/./; q'` | |
a82a04b3 | 16525 | |
1b1fe467 CR |
16526 | # Avoid depending upon Character Ranges. |
16527 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
16528 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
16529 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
16530 | as_cr_digits='0123456789' | |
16531 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
b709b946 CR |
16532 | |
16533 | ECHO_C= ECHO_N= ECHO_T= | |
1b1fe467 | 16534 | case `echo -n x` in #((((( |
b709b946 | 16535 | -n*) |
1b1fe467 | 16536 | case `echo 'xy\c'` in |
b709b946 | 16537 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
1b1fe467 CR |
16538 | xy) ECHO_C='\c';; |
16539 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
16540 | ECHO_T=' ';; | |
b709b946 CR |
16541 | esac;; |
16542 | *) | |
16543 | ECHO_N='-n';; | |
a82a04b3 | 16544 | esac |
f73dda09 JA |
16545 | |
16546 | rm -f conf$$ conf$$.exe conf$$.file | |
b709b946 CR |
16547 | if test -d conf$$.dir; then |
16548 | rm -f conf$$.dir/conf$$.file | |
16549 | else | |
16550 | rm -f conf$$.dir | |
dd4f3dd8 CR |
16551 | mkdir conf$$.dir 2>/dev/null |
16552 | fi | |
16553 | if (echo >conf$$.file) 2>/dev/null; then | |
16554 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
16555 | as_ln_s='ln -s' | |
16556 | # ... but there are two gotchas: | |
16557 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
16558 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
0ee50808 | 16559 | # In both cases, we have to default to `cp -pR'. |
dd4f3dd8 | 16560 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
0ee50808 | 16561 | as_ln_s='cp -pR' |
dd4f3dd8 CR |
16562 | elif ln conf$$.file conf$$ 2>/dev/null; then |
16563 | as_ln_s=ln | |
16564 | else | |
0ee50808 | 16565 | as_ln_s='cp -pR' |
dd4f3dd8 | 16566 | fi |
f73dda09 | 16567 | else |
0ee50808 | 16568 | as_ln_s='cp -pR' |
f73dda09 | 16569 | fi |
b709b946 CR |
16570 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
16571 | rmdir conf$$.dir 2>/dev/null | |
f73dda09 | 16572 | |
1b1fe467 CR |
16573 | |
16574 | # as_fn_mkdir_p | |
16575 | # ------------- | |
16576 | # Create "$as_dir" as a directory, including parents if necessary. | |
16577 | as_fn_mkdir_p () | |
16578 | { | |
16579 | ||
16580 | case $as_dir in #( | |
16581 | -*) as_dir=./$as_dir;; | |
16582 | esac | |
16583 | test -d "$as_dir" || eval $as_mkdir_p || { | |
16584 | as_dirs= | |
16585 | while :; do | |
16586 | case $as_dir in #( | |
16587 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
16588 | *) as_qdir=$as_dir;; | |
16589 | esac | |
16590 | as_dirs="'$as_qdir' $as_dirs" | |
16591 | as_dir=`$as_dirname -- "$as_dir" || | |
16592 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
16593 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
16594 | X"$as_dir" : 'X\(//\)$' \| \ | |
16595 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
16596 | $as_echo X"$as_dir" | | |
16597 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
16598 | s//\1/ | |
16599 | q | |
16600 | } | |
16601 | /^X\(\/\/\)[^/].*/{ | |
16602 | s//\1/ | |
16603 | q | |
16604 | } | |
16605 | /^X\(\/\/\)$/{ | |
16606 | s//\1/ | |
16607 | q | |
16608 | } | |
16609 | /^X\(\/\).*/{ | |
16610 | s//\1/ | |
16611 | q | |
16612 | } | |
16613 | s/.*/./; q'` | |
16614 | test -d "$as_dir" && break | |
16615 | done | |
16616 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
16617 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
16618 | ||
16619 | ||
16620 | } # as_fn_mkdir_p | |
5e4a95c7 | 16621 | if mkdir -p . 2>/dev/null; then |
1b1fe467 | 16622 | as_mkdir_p='mkdir -p "$as_dir"' |
5e4a95c7 CR |
16623 | else |
16624 | test -d ./-p && rmdir ./-p | |
16625 | as_mkdir_p=false | |
16626 | fi | |
16627 | ||
0ee50808 CR |
16628 | |
16629 | # as_fn_executable_p FILE | |
16630 | # ----------------------- | |
16631 | # Test if FILE is an executable regular file. | |
16632 | as_fn_executable_p () | |
16633 | { | |
16634 | test -f "$1" && test -x "$1" | |
16635 | } # as_fn_executable_p | |
16636 | as_test_x='test -x' | |
16637 | as_executable_p=as_fn_executable_p | |
a82a04b3 CR |
16638 | |
16639 | # Sed expression to map a string onto a valid CPP name. | |
5e4a95c7 | 16640 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
a82a04b3 CR |
16641 | |
16642 | # Sed expression to map a string onto a valid variable name. | |
5e4a95c7 | 16643 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
a82a04b3 | 16644 | |
f73dda09 | 16645 | |
f73dda09 | 16646 | exec 6>&1 |
1b1fe467 CR |
16647 | ## ----------------------------------- ## |
16648 | ## Main body of $CONFIG_STATUS script. ## | |
16649 | ## ----------------------------------- ## | |
16650 | _ASEOF | |
16651 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
f73dda09 | 16652 | |
1b1fe467 CR |
16653 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16654 | # Save the log message, to keep $0 and so on meaningful, and to | |
a82a04b3 | 16655 | # report actual input values of CONFIG_FILES etc. instead of their |
b709b946 CR |
16656 | # values after options handling. |
16657 | ac_log=" | |
690150f9 | 16658 | This file was extended by bash $as_me 4.4-rc1, which was |
0ee50808 | 16659 | generated by GNU Autoconf 2.69. Invocation command line was |
a82a04b3 CR |
16660 | |
16661 | CONFIG_FILES = $CONFIG_FILES | |
16662 | CONFIG_HEADERS = $CONFIG_HEADERS | |
16663 | CONFIG_LINKS = $CONFIG_LINKS | |
16664 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
16665 | $ $0 $@ | |
16666 | ||
b709b946 CR |
16667 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
16668 | " | |
16669 | ||
f73dda09 JA |
16670 | _ACEOF |
16671 | ||
af98a2a6 CR |
16672 | case $ac_config_files in *" |
16673 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
16674 | esac | |
16675 | ||
16676 | case $ac_config_headers in *" | |
16677 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
16678 | esac | |
16679 | ||
16680 | ||
dd4f3dd8 | 16681 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
f73dda09 | 16682 | # Files that config.status was made for. |
b709b946 CR |
16683 | config_files="$ac_config_files" |
16684 | config_headers="$ac_config_headers" | |
16685 | config_commands="$ac_config_commands" | |
c184f645 | 16686 | |
b709b946 | 16687 | _ACEOF |
f73dda09 | 16688 | |
dd4f3dd8 | 16689 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 | 16690 | ac_cs_usage="\ |
1b1fe467 CR |
16691 | \`$as_me' instantiates files and other configuration actions |
16692 | from templates according to the current configuration. Unless the files | |
16693 | and actions are specified as TAGs, all are instantiated by default. | |
f73dda09 | 16694 | |
1b1fe467 | 16695 | Usage: $0 [OPTION]... [TAG]... |
f73dda09 JA |
16696 | |
16697 | -h, --help print this help, then exit | |
dd4f3dd8 | 16698 | -V, --version print version number and configuration settings, then exit |
1b1fe467 | 16699 | --config print configuration, then exit |
af98a2a6 CR |
16700 | -q, --quiet, --silent |
16701 | do not print progress messages | |
f73dda09 JA |
16702 | -d, --debug don't remove temporary files |
16703 | --recheck update $as_me by reconfiguring in the same conditions | |
af98a2a6 | 16704 | --file=FILE[:TEMPLATE] |
dd4f3dd8 | 16705 | instantiate the configuration file FILE |
af98a2a6 | 16706 | --header=FILE[:TEMPLATE] |
dd4f3dd8 | 16707 | instantiate the configuration header FILE |
f73dda09 JA |
16708 | |
16709 | Configuration files: | |
16710 | $config_files | |
16711 | ||
16712 | Configuration headers: | |
16713 | $config_headers | |
16714 | ||
16715 | Configuration commands: | |
16716 | $config_commands | |
16717 | ||
1b1fe467 | 16718 | Report bugs to <bug-bash@gnu.org>." |
c184f645 | 16719 | |
b709b946 | 16720 | _ACEOF |
dd4f3dd8 | 16721 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
1b1fe467 | 16722 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
f73dda09 | 16723 | ac_cs_version="\\ |
690150f9 | 16724 | bash config.status 4.4-rc1 |
0ee50808 | 16725 | configured by $0, generated by GNU Autoconf 2.69, |
1b1fe467 | 16726 | with options \\"\$ac_cs_config\\" |
f73dda09 | 16727 | |
0ee50808 | 16728 | Copyright (C) 2012 Free Software Foundation, Inc. |
f73dda09 JA |
16729 | This config.status script is free software; the Free Software Foundation |
16730 | gives unlimited permission to copy, distribute and modify it." | |
b709b946 CR |
16731 | |
16732 | ac_pwd='$ac_pwd' | |
16733 | srcdir='$srcdir' | |
16734 | INSTALL='$INSTALL' | |
dd4f3dd8 | 16735 | test -n "\$AWK" || AWK=awk |
a82a04b3 | 16736 | _ACEOF |
f73dda09 | 16737 | |
dd4f3dd8 CR |
16738 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16739 | # The default lists apply if the user does not specify any file. | |
f73dda09 JA |
16740 | ac_need_defaults=: |
16741 | while test $# != 0 | |
ccc6cda3 | 16742 | do |
f73dda09 | 16743 | case $1 in |
1b1fe467 | 16744 | --*=?*) |
b709b946 CR |
16745 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
16746 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
5e4a95c7 CR |
16747 | ac_shift=: |
16748 | ;; | |
1b1fe467 CR |
16749 | --*=) |
16750 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
16751 | ac_optarg= | |
16752 | ac_shift=: | |
16753 | ;; | |
b709b946 | 16754 | *) |
5e4a95c7 CR |
16755 | ac_option=$1 |
16756 | ac_optarg=$2 | |
16757 | ac_shift=shift | |
f73dda09 | 16758 | ;; |
f73dda09 JA |
16759 | esac |
16760 | ||
5e4a95c7 | 16761 | case $ac_option in |
f73dda09 | 16762 | # Handling of the options. |
5e4a95c7 CR |
16763 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
16764 | ac_cs_recheck=: ;; | |
b709b946 | 16765 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
dd4f3dd8 | 16766 | $as_echo "$ac_cs_version"; exit ;; |
1b1fe467 CR |
16767 | --config | --confi | --conf | --con | --co | --c ) |
16768 | $as_echo "$ac_cs_config"; exit ;; | |
b709b946 | 16769 | --debug | --debu | --deb | --de | --d | -d ) |
f73dda09 JA |
16770 | debug=: ;; |
16771 | --file | --fil | --fi | --f ) | |
5e4a95c7 | 16772 | $ac_shift |
dd4f3dd8 CR |
16773 | case $ac_optarg in |
16774 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
1b1fe467 | 16775 | '') as_fn_error $? "missing file argument" ;; |
dd4f3dd8 | 16776 | esac |
1b1fe467 | 16777 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
f73dda09 JA |
16778 | ac_need_defaults=false;; |
16779 | --header | --heade | --head | --hea ) | |
5e4a95c7 | 16780 | $ac_shift |
dd4f3dd8 CR |
16781 | case $ac_optarg in |
16782 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
16783 | esac | |
1b1fe467 | 16784 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
f73dda09 | 16785 | ac_need_defaults=false;; |
b709b946 CR |
16786 | --he | --h) |
16787 | # Conflict between --help and --header | |
1b1fe467 CR |
16788 | as_fn_error $? "ambiguous option: \`$1' |
16789 | Try \`$0 --help' for more information.";; | |
b709b946 | 16790 | --help | --hel | -h ) |
dd4f3dd8 | 16791 | $as_echo "$ac_cs_usage"; exit ;; |
5e4a95c7 CR |
16792 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
16793 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
16794 | ac_cs_silent=: ;; | |
f73dda09 JA |
16795 | |
16796 | # This is an error. | |
1b1fe467 CR |
16797 | -*) as_fn_error $? "unrecognized option: \`$1' |
16798 | Try \`$0 --help' for more information." ;; | |
f73dda09 | 16799 | |
1b1fe467 | 16800 | *) as_fn_append ac_config_targets " $1" |
b709b946 | 16801 | ac_need_defaults=false ;; |
f73dda09 | 16802 | |
ccc6cda3 | 16803 | esac |
f73dda09 | 16804 | shift |
ccc6cda3 JA |
16805 | done |
16806 | ||
5e4a95c7 CR |
16807 | ac_configure_extra_args= |
16808 | ||
16809 | if $ac_cs_silent; then | |
16810 | exec 6>/dev/null | |
16811 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
16812 | fi | |
16813 | ||
16814 | _ACEOF | |
dd4f3dd8 | 16815 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
5e4a95c7 | 16816 | if \$ac_cs_recheck; then |
0ee50808 | 16817 | set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
dd4f3dd8 CR |
16818 | shift |
16819 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
16820 | CONFIG_SHELL='$SHELL' | |
b709b946 | 16821 | export CONFIG_SHELL |
dd4f3dd8 | 16822 | exec "\$@" |
5e4a95c7 CR |
16823 | fi |
16824 | ||
f73dda09 | 16825 | _ACEOF |
dd4f3dd8 | 16826 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
16827 | exec 5>>config.log |
16828 | { | |
16829 | echo | |
16830 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
16831 | ## Running $as_me. ## | |
16832 | _ASBOX | |
dd4f3dd8 | 16833 | $as_echo "$ac_log" |
b709b946 | 16834 | } >&5 |
ccc6cda3 | 16835 | |
b709b946 | 16836 | _ACEOF |
dd4f3dd8 | 16837 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
5e13499c | 16838 | # |
b709b946 | 16839 | # INIT-COMMANDS |
5e13499c | 16840 | # |
5e13499c CR |
16841 | # Capture the value of obsolete ALL_LINGUAS because we need it to compute |
16842 | # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it | |
16843 | # from automake. | |
16844 | eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' | |
16845 | # Capture the value of LINGUAS because we need it to compute CATALOGS. | |
16846 | LINGUAS="${LINGUAS-%UNSET%}" | |
16847 | ||
5e13499c | 16848 | |
a82a04b3 CR |
16849 | _ACEOF |
16850 | ||
dd4f3dd8 | 16851 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
16852 | |
16853 | # Handling of arguments. | |
f73dda09 JA |
16854 | for ac_config_target in $ac_config_targets |
16855 | do | |
b709b946 CR |
16856 | case $ac_config_target in |
16857 | "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; | |
16858 | "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; | |
16859 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; | |
16860 | "builtins/Makefile") CONFIG_FILES="$CONFIG_FILES builtins/Makefile" ;; | |
16861 | "lib/readline/Makefile") CONFIG_FILES="$CONFIG_FILES lib/readline/Makefile" ;; | |
16862 | "lib/glob/Makefile") CONFIG_FILES="$CONFIG_FILES lib/glob/Makefile" ;; | |
16863 | "lib/intl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/intl/Makefile" ;; | |
16864 | "lib/malloc/Makefile") CONFIG_FILES="$CONFIG_FILES lib/malloc/Makefile" ;; | |
16865 | "lib/sh/Makefile") CONFIG_FILES="$CONFIG_FILES lib/sh/Makefile" ;; | |
16866 | "lib/termcap/Makefile") CONFIG_FILES="$CONFIG_FILES lib/termcap/Makefile" ;; | |
16867 | "lib/tilde/Makefile") CONFIG_FILES="$CONFIG_FILES lib/tilde/Makefile" ;; | |
16868 | "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;; | |
16869 | "support/Makefile") CONFIG_FILES="$CONFIG_FILES support/Makefile" ;; | |
16870 | "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; | |
16871 | "examples/loadables/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile" ;; | |
54a5fbe1 | 16872 | "examples/loadables/Makefile.inc") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile.inc" ;; |
b709b946 | 16873 | "examples/loadables/perl/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/perl/Makefile" ;; |
54a5fbe1 | 16874 | "support/bash.pc") CONFIG_FILES="$CONFIG_FILES support/bash.pc" ;; |
b709b946 CR |
16875 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; |
16876 | ||
1b1fe467 | 16877 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
f73dda09 JA |
16878 | esac |
16879 | done | |
16880 | ||
b709b946 | 16881 | |
f73dda09 JA |
16882 | # If the user did not use the arguments to specify the items to instantiate, |
16883 | # then the envvar interface is used. Set only those that are not. | |
16884 | # We use the long form for the default assignment because of an extremely | |
16885 | # bizarre bug on SunOS 4.1.3. | |
16886 | if $ac_need_defaults; then | |
16887 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
16888 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
16889 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
16890 | fi | |
16891 | ||
5e4a95c7 | 16892 | # Have a temporary directory for convenience. Make it in the build tree |
b709b946 | 16893 | # simply because there is no reason against having it here, and in addition, |
5e4a95c7 | 16894 | # creating and moving files from /tmp can sometimes cause problems. |
b709b946 CR |
16895 | # Hook for its removal unless debugging. |
16896 | # Note that there is a small window in which the directory will not be cleaned: | |
16897 | # after its creation but before its name has been assigned to `$tmp'. | |
f73dda09 JA |
16898 | $debug || |
16899 | { | |
1b1fe467 | 16900 | tmp= ac_tmp= |
b709b946 | 16901 | trap 'exit_status=$? |
1b1fe467 CR |
16902 | : "${ac_tmp:=$tmp}" |
16903 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
b709b946 | 16904 | ' 0 |
1b1fe467 | 16905 | trap 'as_fn_exit 1' 1 2 13 15 |
f73dda09 | 16906 | } |
f73dda09 | 16907 | # Create a (secure) tmp directory for tmp files. |
5e4a95c7 | 16908 | |
f73dda09 | 16909 | { |
b709b946 | 16910 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
1b1fe467 | 16911 | test -d "$tmp" |
f73dda09 JA |
16912 | } || |
16913 | { | |
b709b946 CR |
16914 | tmp=./conf$$-$RANDOM |
16915 | (umask 077 && mkdir "$tmp") | |
1b1fe467 CR |
16916 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
16917 | ac_tmp=$tmp | |
ccc6cda3 | 16918 | |
dd4f3dd8 CR |
16919 | # Set up the scripts for CONFIG_FILES section. |
16920 | # No need to generate them if there are no CONFIG_FILES. | |
16921 | # This happens for instance with `./config.status config.h'. | |
b709b946 CR |
16922 | if test -n "$CONFIG_FILES"; then |
16923 | ||
b709b946 | 16924 | |
1b1fe467 CR |
16925 | ac_cr=`echo X | tr X '\015'` |
16926 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
16927 | # But we know of no other shell where ac_cr would be empty at this | |
16928 | # point, so we can use a bashism as a fallback. | |
16929 | if test "x$ac_cr" = x; then | |
16930 | eval ac_cr=\$\'\\r\' | |
16931 | fi | |
dd4f3dd8 CR |
16932 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
16933 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
16934 | ac_cs_awk_cr='\\r' | |
16935 | else | |
16936 | ac_cs_awk_cr=$ac_cr | |
b709b946 CR |
16937 | fi |
16938 | ||
1b1fe467 | 16939 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
b709b946 CR |
16940 | _ACEOF |
16941 | ||
16942 | ||
dd4f3dd8 CR |
16943 | { |
16944 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
16945 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
16946 | echo "_ACEOF" | |
16947 | } >conf$$subs.sh || | |
1b1fe467 CR |
16948 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
16949 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
b709b946 CR |
16950 | ac_delim='%!_!# ' |
16951 | for ac_last_try in false false false false false :; do | |
dd4f3dd8 | 16952 | . ./conf$$subs.sh || |
1b1fe467 | 16953 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
dd4f3dd8 | 16954 | |
af98a2a6 CR |
16955 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
16956 | if test $ac_delim_n = $ac_delim_num; then | |
b709b946 CR |
16957 | break |
16958 | elif $ac_last_try; then | |
1b1fe467 | 16959 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
b709b946 CR |
16960 | else |
16961 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
16962 | fi | |
16963 | done | |
dd4f3dd8 CR |
16964 | rm -f conf$$subs.sh |
16965 | ||
16966 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
1b1fe467 | 16967 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
dd4f3dd8 CR |
16968 | _ACEOF |
16969 | sed -n ' | |
16970 | h | |
16971 | s/^/S["/; s/!.*/"]=/ | |
16972 | p | |
16973 | g | |
16974 | s/^[^!]*!// | |
16975 | :repl | |
16976 | t repl | |
16977 | s/'"$ac_delim"'$// | |
16978 | t delim | |
16979 | :nl | |
16980 | h | |
1b1fe467 | 16981 | s/\(.\{148\}\)..*/\1/ |
dd4f3dd8 CR |
16982 | t more1 |
16983 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
16984 | p | |
16985 | n | |
16986 | b repl | |
16987 | :more1 | |
16988 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
16989 | p | |
16990 | g | |
16991 | s/.\{148\}// | |
16992 | t nl | |
16993 | :delim | |
16994 | h | |
1b1fe467 | 16995 | s/\(.\{148\}\)..*/\1/ |
dd4f3dd8 CR |
16996 | t more2 |
16997 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
16998 | p | |
16999 | b | |
17000 | :more2 | |
17001 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
17002 | p | |
17003 | g | |
17004 | s/.\{148\}// | |
17005 | t delim | |
17006 | ' <conf$$subs.awk | sed ' | |
17007 | /^[^""]/{ | |
17008 | N | |
17009 | s/\n// | |
17010 | } | |
17011 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
17012 | rm -f conf$$subs.awk | |
17013 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17014 | _ACAWK | |
1b1fe467 | 17015 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
dd4f3dd8 CR |
17016 | for (key in S) S_is_set[key] = 1 |
17017 | FS = "\a" | |
17018 | ||
17019 | } | |
17020 | { | |
17021 | line = $ 0 | |
17022 | nfields = split(line, field, "@") | |
17023 | substed = 0 | |
17024 | len = length(field[1]) | |
17025 | for (i = 2; i < nfields; i++) { | |
17026 | key = field[i] | |
17027 | keylen = length(key) | |
17028 | if (S_is_set[key]) { | |
17029 | value = S[key] | |
17030 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
17031 | len += length(value) + length(field[++i]) | |
17032 | substed = 1 | |
17033 | } else | |
17034 | len += 1 + keylen | |
17035 | } | |
b709b946 | 17036 | |
dd4f3dd8 CR |
17037 | print line |
17038 | } | |
d3ad40de | 17039 | |
dd4f3dd8 | 17040 | _ACAWK |
b709b946 | 17041 | _ACEOF |
dd4f3dd8 CR |
17042 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
17043 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
17044 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
17045 | else | |
17046 | cat | |
1b1fe467 CR |
17047 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
17048 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 | |
a82a04b3 | 17049 | _ACEOF |
b709b946 | 17050 | |
1b1fe467 CR |
17051 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
17052 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
b709b946 CR |
17053 | # trailing colons and then remove the whole line if VPATH becomes empty |
17054 | # (actually we leave an empty line to preserve line numbers). | |
17055 | if test "x$srcdir" = x.; then | |
1b1fe467 CR |
17056 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
17057 | h | |
17058 | s/// | |
17059 | s/^/:/ | |
17060 | s/[ ]*$/:/ | |
17061 | s/:\$(srcdir):/:/g | |
17062 | s/:\${srcdir}:/:/g | |
17063 | s/:@srcdir@:/:/g | |
17064 | s/^:*// | |
b709b946 | 17065 | s/:*$// |
1b1fe467 CR |
17066 | x |
17067 | s/\(=[ ]*\).*/\1/ | |
17068 | G | |
17069 | s/\n// | |
b709b946 CR |
17070 | s/^[^=]*=[ ]*$// |
17071 | }' | |
17072 | fi | |
17073 | ||
dd4f3dd8 | 17074 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
17075 | fi # test -n "$CONFIG_FILES" |
17076 | ||
dd4f3dd8 CR |
17077 | # Set up the scripts for CONFIG_HEADERS section. |
17078 | # No need to generate them if there are no CONFIG_HEADERS. | |
17079 | # This happens for instance with `./config.status Makefile'. | |
17080 | if test -n "$CONFIG_HEADERS"; then | |
1b1fe467 | 17081 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
dd4f3dd8 CR |
17082 | BEGIN { |
17083 | _ACEOF | |
17084 | ||
17085 | # Transform confdefs.h into an awk script `defines.awk', embedded as | |
17086 | # here-document in config.status, that substitutes the proper values into | |
17087 | # config.h.in to produce config.h. | |
17088 | ||
17089 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
17090 | # handling of long lines. | |
17091 | ac_delim='%!_!# ' | |
17092 | for ac_last_try in false false :; do | |
1b1fe467 CR |
17093 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
17094 | if test -z "$ac_tt"; then | |
dd4f3dd8 CR |
17095 | break |
17096 | elif $ac_last_try; then | |
1b1fe467 | 17097 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
dd4f3dd8 CR |
17098 | else |
17099 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
17100 | fi | |
17101 | done | |
17102 | ||
17103 | # For the awk script, D is an array of macro values keyed by name, | |
17104 | # likewise P contains macro parameters if any. Preserve backslash | |
17105 | # newline sequences. | |
17106 | ||
17107 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
17108 | sed -n ' | |
17109 | s/.\{148\}/&'"$ac_delim"'/g | |
17110 | t rset | |
17111 | :rset | |
17112 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
17113 | t def | |
17114 | d | |
17115 | :def | |
17116 | s/\\$// | |
17117 | t bsnl | |
17118 | s/["\\]/\\&/g | |
17119 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
17120 | D["\1"]=" \3"/p | |
17121 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
17122 | d | |
17123 | :bsnl | |
17124 | s/["\\]/\\&/g | |
17125 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
17126 | D["\1"]=" \3\\\\\\n"\\/p | |
17127 | t cont | |
17128 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
17129 | t cont | |
17130 | d | |
17131 | :cont | |
17132 | n | |
17133 | s/.\{148\}/&'"$ac_delim"'/g | |
17134 | t clear | |
17135 | :clear | |
17136 | s/\\$// | |
17137 | t bsnlc | |
17138 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
17139 | d | |
17140 | :bsnlc | |
17141 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
17142 | b cont | |
17143 | ' <confdefs.h | sed ' | |
17144 | s/'"$ac_delim"'/"\\\ | |
17145 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
17146 | ||
17147 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
17148 | for (key in D) D_is_set[key] = 1 | |
17149 | FS = "\a" | |
17150 | } | |
17151 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
17152 | line = \$ 0 | |
17153 | split(line, arg, " ") | |
17154 | if (arg[1] == "#") { | |
17155 | defundef = arg[2] | |
17156 | mac1 = arg[3] | |
17157 | } else { | |
17158 | defundef = substr(arg[1], 2) | |
17159 | mac1 = arg[2] | |
17160 | } | |
17161 | split(mac1, mac2, "(") #) | |
17162 | macro = mac2[1] | |
af98a2a6 | 17163 | prefix = substr(line, 1, index(line, defundef) - 1) |
dd4f3dd8 CR |
17164 | if (D_is_set[macro]) { |
17165 | # Preserve the white space surrounding the "#". | |
dd4f3dd8 CR |
17166 | print prefix "define", macro P[macro] D[macro] |
17167 | next | |
17168 | } else { | |
17169 | # Replace #undef with comments. This is necessary, for example, | |
17170 | # in the case of _POSIX_SOURCE, which is predefined and required | |
17171 | # on some systems where configure will not decide to define it. | |
17172 | if (defundef == "undef") { | |
af98a2a6 | 17173 | print "/*", prefix defundef, macro, "*/" |
dd4f3dd8 CR |
17174 | next |
17175 | } | |
17176 | } | |
17177 | } | |
17178 | { print } | |
17179 | _ACAWK | |
17180 | _ACEOF | |
17181 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
1b1fe467 | 17182 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
dd4f3dd8 CR |
17183 | fi # test -n "$CONFIG_HEADERS" |
17184 | ||
b709b946 | 17185 | |
dd4f3dd8 CR |
17186 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" |
17187 | shift | |
17188 | for ac_tag | |
b709b946 CR |
17189 | do |
17190 | case $ac_tag in | |
17191 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
9d6e5e30 | 17192 | esac |
b709b946 CR |
17193 | case $ac_mode$ac_tag in |
17194 | :[FHL]*:*);; | |
1b1fe467 | 17195 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
b709b946 CR |
17196 | :[FH]-) ac_tag=-:-;; |
17197 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
17198 | esac | |
17199 | ac_save_IFS=$IFS | |
17200 | IFS=: | |
17201 | set x $ac_tag | |
17202 | IFS=$ac_save_IFS | |
17203 | shift | |
17204 | ac_file=$1 | |
17205 | shift | |
17206 | ||
17207 | case $ac_mode in | |
17208 | :L) ac_source=$1;; | |
17209 | :[FH]) | |
17210 | ac_file_inputs= | |
17211 | for ac_f | |
17212 | do | |
17213 | case $ac_f in | |
1b1fe467 | 17214 | -) ac_f="$ac_tmp/stdin";; |
b709b946 CR |
17215 | *) # Look for the file first in the build tree, then in the source tree |
17216 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
17217 | # because $ac_f cannot contain `:'. | |
17218 | test -f "$ac_f" || | |
17219 | case $ac_f in | |
17220 | [\\/$]*) false;; | |
17221 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
17222 | esac || | |
1b1fe467 | 17223 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
b709b946 | 17224 | esac |
dd4f3dd8 | 17225 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
1b1fe467 | 17226 | as_fn_append ac_file_inputs " '$ac_f'" |
b709b946 | 17227 | done |
9d6e5e30 | 17228 | |
b709b946 CR |
17229 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
17230 | # use $as_me), people would be surprised to read: | |
17231 | # /* config.h. Generated by config.status. */ | |
dd4f3dd8 CR |
17232 | configure_input='Generated from '` |
17233 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
17234 | `' by configure.' | |
b709b946 CR |
17235 | if test x"$ac_file" != x-; then |
17236 | configure_input="$ac_file. $configure_input" | |
1b1fe467 | 17237 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
dd4f3dd8 | 17238 | $as_echo "$as_me: creating $ac_file" >&6;} |
b709b946 | 17239 | fi |
dd4f3dd8 CR |
17240 | # Neutralize special characters interpreted by sed in replacement strings. |
17241 | case $configure_input in #( | |
17242 | *\&* | *\|* | *\\* ) | |
17243 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
17244 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
17245 | *) ac_sed_conf_input=$configure_input;; | |
17246 | esac | |
b709b946 CR |
17247 | |
17248 | case $ac_tag in | |
1b1fe467 CR |
17249 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
17250 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
b709b946 CR |
17251 | esac |
17252 | ;; | |
17253 | esac | |
17254 | ||
17255 | ac_dir=`$as_dirname -- "$ac_file" || | |
a82a04b3 | 17256 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
5e4a95c7 CR |
17257 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
17258 | X"$ac_file" : 'X\(//\)$' \| \ | |
b709b946 | 17259 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 17260 | $as_echo X"$ac_file" | |
b709b946 CR |
17261 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
17262 | s//\1/ | |
17263 | q | |
17264 | } | |
17265 | /^X\(\/\/\)[^/].*/{ | |
17266 | s//\1/ | |
17267 | q | |
17268 | } | |
17269 | /^X\(\/\/\)$/{ | |
17270 | s//\1/ | |
17271 | q | |
17272 | } | |
17273 | /^X\(\/\).*/{ | |
17274 | s//\1/ | |
17275 | q | |
17276 | } | |
17277 | s/.*/./; q'` | |
1b1fe467 | 17278 | as_dir="$ac_dir"; as_fn_mkdir_p |
a82a04b3 CR |
17279 | ac_builddir=. |
17280 | ||
b709b946 CR |
17281 | case "$ac_dir" in |
17282 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17283 | *) | |
dd4f3dd8 | 17284 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
b709b946 | 17285 | # A ".." for each directory in $ac_dir_suffix. |
dd4f3dd8 | 17286 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
b709b946 CR |
17287 | case $ac_top_builddir_sub in |
17288 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17289 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
17290 | esac ;; | |
17291 | esac | |
17292 | ac_abs_top_builddir=$ac_pwd | |
17293 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
17294 | # for backward compatibility: | |
17295 | ac_top_builddir=$ac_top_build_prefix | |
a82a04b3 CR |
17296 | |
17297 | case $srcdir in | |
b709b946 | 17298 | .) # We are building in place. |
a82a04b3 | 17299 | ac_srcdir=. |
b709b946 CR |
17300 | ac_top_srcdir=$ac_top_builddir_sub |
17301 | ac_abs_top_srcdir=$ac_pwd ;; | |
17302 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
a82a04b3 | 17303 | ac_srcdir=$srcdir$ac_dir_suffix; |
b709b946 CR |
17304 | ac_top_srcdir=$srcdir |
17305 | ac_abs_top_srcdir=$srcdir ;; | |
17306 | *) # Relative name. | |
17307 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
17308 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
17309 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
a82a04b3 | 17310 | esac |
b709b946 | 17311 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
5e4a95c7 | 17312 | |
a82a04b3 | 17313 | |
b709b946 CR |
17314 | case $ac_mode in |
17315 | :F) | |
17316 | # | |
17317 | # CONFIG_FILE | |
17318 | # | |
ccc6cda3 | 17319 | |
f73dda09 JA |
17320 | case $INSTALL in |
17321 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
b709b946 | 17322 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
ccc6cda3 | 17323 | esac |
b709b946 | 17324 | _ACEOF |
ccc6cda3 | 17325 | |
dd4f3dd8 | 17326 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
17327 | # If the template does not know about datarootdir, expand it. |
17328 | # FIXME: This hack should be removed a few years after 2.60. | |
17329 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
dd4f3dd8 CR |
17330 | ac_sed_dataroot=' |
17331 | /datarootdir/ { | |
b709b946 CR |
17332 | p |
17333 | q | |
17334 | } | |
17335 | /@datadir@/p | |
17336 | /@docdir@/p | |
17337 | /@infodir@/p | |
17338 | /@localedir@/p | |
1b1fe467 | 17339 | /@mandir@/p' |
dd4f3dd8 | 17340 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
b709b946 CR |
17341 | *datarootdir*) ac_datarootdir_seen=yes;; |
17342 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
1b1fe467 | 17343 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
dd4f3dd8 | 17344 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
9d6e5e30 | 17345 | _ACEOF |
dd4f3dd8 | 17346 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
b709b946 CR |
17347 | ac_datarootdir_hack=' |
17348 | s&@datadir@&$datadir&g | |
17349 | s&@docdir@&$docdir&g | |
17350 | s&@infodir@&$infodir&g | |
17351 | s&@localedir@&$localedir&g | |
17352 | s&@mandir@&$mandir&g | |
1b1fe467 | 17353 | s&\\\${datarootdir}&$datarootdir&g' ;; |
b709b946 CR |
17354 | esac |
17355 | _ACEOF | |
17356 | ||
17357 | # Neutralize VPATH when `$srcdir' = `.'. | |
17358 | # Shell code in configure.ac might set extrasub. | |
17359 | # FIXME: do we really want to maintain this feature? | |
dd4f3dd8 CR |
17360 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
17361 | ac_sed_extra="$ac_vpsub | |
f73dda09 | 17362 | $extrasub |
a82a04b3 | 17363 | _ACEOF |
dd4f3dd8 | 17364 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 JA |
17365 | :t |
17366 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
dd4f3dd8 | 17367 | s|@configure_input@|$ac_sed_conf_input|;t t |
b709b946 | 17368 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
dd4f3dd8 | 17369 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
b709b946 CR |
17370 | s&@srcdir@&$ac_srcdir&;t t |
17371 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
17372 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
17373 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
17374 | s&@builddir@&$ac_builddir&;t t | |
17375 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
17376 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
17377 | s&@INSTALL@&$ac_INSTALL&;t t | |
17378 | $ac_datarootdir_hack | |
dd4f3dd8 | 17379 | " |
1b1fe467 CR |
17380 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
17381 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
b709b946 CR |
17382 | |
17383 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
1b1fe467 CR |
17384 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
17385 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
17386 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
17387 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
17388 | which seems to be undefined. Please make sure it is defined" >&5 | |
dd4f3dd8 | 17389 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
1b1fe467 | 17390 | which seems to be undefined. Please make sure it is defined" >&2;} |
b709b946 | 17391 | |
1b1fe467 | 17392 | rm -f "$ac_tmp/stdin" |
f73dda09 | 17393 | case $ac_file in |
1b1fe467 CR |
17394 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
17395 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
dd4f3dd8 | 17396 | esac \ |
1b1fe467 | 17397 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
b709b946 CR |
17398 | ;; |
17399 | :H) | |
17400 | # | |
17401 | # CONFIG_HEADER | |
17402 | # | |
f73dda09 | 17403 | if test x"$ac_file" != x-; then |
dd4f3dd8 CR |
17404 | { |
17405 | $as_echo "/* $configure_input */" \ | |
1b1fe467 CR |
17406 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
17407 | } >"$ac_tmp/config.h" \ | |
17408 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
17409 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then | |
17410 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 | |
dd4f3dd8 | 17411 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
f73dda09 | 17412 | else |
dd4f3dd8 | 17413 | rm -f "$ac_file" |
1b1fe467 CR |
17414 | mv "$ac_tmp/config.h" "$ac_file" \ |
17415 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
ccc6cda3 | 17416 | fi |
f73dda09 | 17417 | else |
dd4f3dd8 | 17418 | $as_echo "/* $configure_input */" \ |
1b1fe467 CR |
17419 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
17420 | || as_fn_error $? "could not create -" "$LINENO" 5 | |
ccc6cda3 | 17421 | fi |
b709b946 | 17422 | ;; |
c184f645 | 17423 | |
1b1fe467 | 17424 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
dd4f3dd8 | 17425 | $as_echo "$as_me: executing $ac_file commands" >&6;} |
b709b946 CR |
17426 | ;; |
17427 | esac | |
a82a04b3 | 17428 | |
ccc6cda3 | 17429 | |
b709b946 CR |
17430 | case $ac_file$ac_mode in |
17431 | "default-1":C) | |
5e13499c CR |
17432 | for ac_file in $CONFIG_FILES; do |
17433 | # Support "outfile[:infile[:infile...]]" | |
17434 | case "$ac_file" in | |
17435 | *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
17436 | esac | |
17437 | # PO directories have a Makefile.in generated from Makefile.in.in. | |
17438 | case "$ac_file" in */Makefile.in) | |
17439 | # Adjust a relative srcdir. | |
17440 | ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` | |
17441 | ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" | |
17442 | ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` | |
17443 | # In autoconf-2.13 it is called $ac_given_srcdir. | |
17444 | # In autoconf-2.50 it is called $srcdir. | |
17445 | test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" | |
17446 | case "$ac_given_srcdir" in | |
17447 | .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; | |
17448 | /*) top_srcdir="$ac_given_srcdir" ;; | |
17449 | *) top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
17450 | esac | |
17451 | if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then | |
17452 | rm -f "$ac_dir/POTFILES" | |
17453 | test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" | |
17454 | cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" | |
17455 | POMAKEFILEDEPS="POTFILES.in" | |
17456 | # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend | |
17457 | # on $ac_dir but don't depend on user-specified configuration | |
17458 | # parameters. | |
17459 | if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then | |
17460 | # The LINGUAS file contains the set of available languages. | |
17461 | if test -n "$OBSOLETE_ALL_LINGUAS"; then | |
17462 | test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" | |
17463 | fi | |
17464 | ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` | |
17465 | # Hide the ALL_LINGUAS assigment from automake. | |
17466 | eval 'ALL_LINGUAS''=$ALL_LINGUAS_' | |
17467 | POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" | |
17468 | else | |
17469 | # The set of available languages was given in configure.in. | |
17470 | eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' | |
17471 | fi | |
17472 | case "$ac_given_srcdir" in | |
17473 | .) srcdirpre= ;; | |
17474 | *) srcdirpre='$(srcdir)/' ;; | |
17475 | esac | |
17476 | POFILES= | |
17477 | GMOFILES= | |
17478 | UPDATEPOFILES= | |
17479 | DUMMYPOFILES= | |
17480 | for lang in $ALL_LINGUAS; do | |
17481 | POFILES="$POFILES $srcdirpre$lang.po" | |
17482 | GMOFILES="$GMOFILES $srcdirpre$lang.gmo" | |
17483 | UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" | |
17484 | DUMMYPOFILES="$DUMMYPOFILES $lang.nop" | |
17485 | done | |
17486 | # CATALOGS depends on both $ac_dir and the user's LINGUAS | |
17487 | # environment variable. | |
17488 | INST_LINGUAS= | |
17489 | if test -n "$ALL_LINGUAS"; then | |
17490 | for presentlang in $ALL_LINGUAS; do | |
17491 | useit=no | |
17492 | if test "%UNSET%" != "$LINGUAS"; then | |
17493 | desiredlanguages="$LINGUAS" | |
17494 | else | |
17495 | desiredlanguages="$ALL_LINGUAS" | |
17496 | fi | |
17497 | for desiredlang in $desiredlanguages; do | |
17498 | # Use the presentlang catalog if desiredlang is | |
17499 | # a. equal to presentlang, or | |
17500 | # b. a variant of presentlang (because in this case, | |
17501 | # presentlang can be used as a fallback for messages | |
17502 | # which are not translated in the desiredlang catalog). | |
17503 | case "$desiredlang" in | |
17504 | "$presentlang"*) useit=yes;; | |
17505 | esac | |
17506 | done | |
17507 | if test $useit = yes; then | |
17508 | INST_LINGUAS="$INST_LINGUAS $presentlang" | |
17509 | fi | |
17510 | done | |
17511 | fi | |
17512 | CATALOGS= | |
17513 | if test -n "$INST_LINGUAS"; then | |
17514 | for lang in $INST_LINGUAS; do | |
17515 | CATALOGS="$CATALOGS $lang.gmo" | |
17516 | done | |
17517 | fi | |
17518 | test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" | |
17519 | 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" | |
17520 | for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do | |
17521 | if test -f "$f"; then | |
17522 | case "$f" in | |
17523 | *.orig | *.bak | *~) ;; | |
17524 | *) cat "$f" >> "$ac_dir/Makefile" ;; | |
17525 | esac | |
17526 | fi | |
17527 | done | |
17528 | fi | |
17529 | ;; | |
17530 | esac | |
17531 | done ;; | |
b709b946 | 17532 | "default":C) |
ccc6cda3 JA |
17533 | # Makefile uses this timestamp file to record whether config.h is up to date. |
17534 | echo timestamp > stamp-h | |
f73dda09 | 17535 | ;; |
b709b946 | 17536 | |
f73dda09 | 17537 | esac |
b709b946 | 17538 | done # for ac_tag |
ccc6cda3 | 17539 | |
f73dda09 | 17540 | |
1b1fe467 | 17541 | as_fn_exit 0 |
a82a04b3 | 17542 | _ACEOF |
f73dda09 JA |
17543 | ac_clean_files=$ac_clean_files_save |
17544 | ||
dd4f3dd8 | 17545 | test $ac_write_fail = 0 || |
1b1fe467 | 17546 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
dd4f3dd8 | 17547 | |
a82a04b3 | 17548 | |
f73dda09 JA |
17549 | # configure is writing to config.log, and then calls config.status. |
17550 | # config.status does its own redirection, appending to config.log. | |
17551 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
17552 | # by configure, so config.status won't be able to write to it; its | |
17553 | # output is simply discarded. So we exec the FD to /dev/null, | |
17554 | # effectively closing config.log, so it can be properly (re)opened and | |
17555 | # appended to by config.status. When coming back to configure, we | |
17556 | # need to make the FD available again. | |
17557 | if test "$no_create" != yes; then | |
17558 | ac_cs_success=: | |
5e4a95c7 CR |
17559 | ac_config_status_args= |
17560 | test "$silent" = yes && | |
17561 | ac_config_status_args="$ac_config_status_args --quiet" | |
f73dda09 | 17562 | exec 5>/dev/null |
5e4a95c7 | 17563 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false |
f73dda09 JA |
17564 | exec 5>>config.log |
17565 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
17566 | # would make configure fail if this is the last instruction. | |
1b1fe467 | 17567 | $ac_cs_success || as_fn_exit 1 |
f73dda09 | 17568 | fi |
dd4f3dd8 | 17569 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
1b1fe467 | 17570 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
af98a2a6 | 17571 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
dd4f3dd8 | 17572 | fi |
bc7bed50 | 17573 |