]>
Commit | Line | Data |
---|---|---|
ccc6cda3 | 1 | #! /bin/sh |
f14388d3 | 2 | # From configure.ac for Bash 4.2, version 4.052. |
f73dda09 | 3 | # Guess values for system-dependent variables and create Makefiles. |
7f947b68 | 4 | # Generated by GNU Autoconf 2.68 for bash 4.2-maint. |
f73dda09 JA |
5 | # |
6 | # Report bugs to <bug-bash@gnu.org>. | |
7 | # | |
7f947b68 | 8 | # |
b709b946 | 9 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, |
7f947b68 CR |
10 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software |
11 | # Foundation, Inc. | |
12 | # | |
13 | # | |
f73dda09 JA |
14 | # This configure script is free software; the Free Software Foundation |
15 | # gives unlimited permission to copy, distribute and modify it. | |
7f947b68 CR |
16 | ## -------------------- ## |
17 | ## M4sh Initialization. ## | |
18 | ## -------------------- ## | |
ccc6cda3 | 19 | |
dd4f3dd8 CR |
20 | # Be more Bourne compatible |
21 | DUALCASE=1; export DUALCASE # for MKS sh | |
7f947b68 | 22 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
a82a04b3 CR |
23 | emulate sh |
24 | NULLCMD=: | |
dd4f3dd8 | 25 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
5e4a95c7 CR |
26 | # is contrary to our usage. Disable this feature. |
27 | alias -g '${1+"$@"}'='"$@"' | |
b709b946 CR |
28 | setopt NO_GLOB_SUBST |
29 | else | |
7f947b68 CR |
30 | case `(set -o) 2>/dev/null` in #( |
31 | *posix*) : | |
32 | set -o posix ;; #( | |
33 | *) : | |
34 | ;; | |
dd4f3dd8 | 35 | esac |
a82a04b3 | 36 | fi |
dd4f3dd8 CR |
37 | |
38 | ||
dd4f3dd8 CR |
39 | as_nl=' |
40 | ' | |
41 | export as_nl | |
42 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
43 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
44 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
45 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
7f947b68 CR |
46 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
47 | # but without wasting forks for bash or zsh. | |
48 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
49 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
50 | as_echo='print -r --' | |
51 | as_echo_n='print -rn --' | |
52 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
dd4f3dd8 CR |
53 | as_echo='printf %s\n' |
54 | as_echo_n='printf %s' | |
55 | else | |
56 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
57 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
58 | as_echo_n='/usr/ucb/echo -n' | |
b709b946 | 59 | else |
dd4f3dd8 CR |
60 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
61 | as_echo_n_body='eval | |
62 | arg=$1; | |
7f947b68 | 63 | case $arg in #( |
dd4f3dd8 CR |
64 | *"$as_nl"*) |
65 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
66 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
67 | esac; | |
68 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
69 | ' | |
70 | export as_echo_n_body | |
71 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
b709b946 | 72 | fi |
dd4f3dd8 CR |
73 | export as_echo_body |
74 | as_echo='sh -c $as_echo_body as_echo' | |
75 | fi | |
76 | ||
77 | # The user is always right. | |
78 | if test "${PATH_SEPARATOR+set}" != set; then | |
79 | PATH_SEPARATOR=: | |
80 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
81 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
82 | PATH_SEPARATOR=';' | |
83 | } | |
b709b946 CR |
84 | fi |
85 | ||
5e4a95c7 | 86 | |
b709b946 CR |
87 | # IFS |
88 | # We need space, tab and new line, in precisely that order. Quoting is | |
89 | # there to prevent editors from complaining about space-tab. | |
90 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
91 | # splitting by setting IFS to empty value.) | |
b709b946 CR |
92 | IFS=" "" $as_nl" |
93 | ||
94 | # Find who we are. Look in the path if we contain no directory separator. | |
7f947b68 CR |
95 | as_myself= |
96 | case $0 in #(( | |
b709b946 CR |
97 | *[\\/]* ) as_myself=$0 ;; |
98 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
99 | for as_dir in $PATH | |
100 | do | |
101 | IFS=$as_save_IFS | |
102 | test -z "$as_dir" && as_dir=. | |
7f947b68 CR |
103 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
104 | done | |
b709b946 CR |
105 | IFS=$as_save_IFS |
106 | ||
107 | ;; | |
108 | esac | |
109 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
110 | # in which case we are not to be found in the path. | |
111 | if test "x$as_myself" = x; then | |
112 | as_myself=$0 | |
113 | fi | |
114 | if test ! -f "$as_myself"; then | |
dd4f3dd8 | 115 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
7f947b68 | 116 | exit 1 |
b709b946 CR |
117 | fi |
118 | ||
7f947b68 CR |
119 | # Unset variables that we do not need and which cause bugs (e.g. in |
120 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
121 | # suppresses any "Segmentation fault" message there. '((' could | |
122 | # trigger a bug in pdksh 5.2.14. | |
123 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
124 | do eval test x\${$as_var+set} = xset \ | |
125 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
b709b946 | 126 | done |
5e4a95c7 CR |
127 | PS1='$ ' |
128 | PS2='> ' | |
129 | PS4='+ ' | |
130 | ||
131 | # NLS nuisances. | |
dd4f3dd8 CR |
132 | LC_ALL=C |
133 | export LC_ALL | |
134 | LANGUAGE=C | |
135 | export LANGUAGE | |
5e4a95c7 | 136 | |
7f947b68 CR |
137 | # CDPATH. |
138 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
139 | ||
140 | if test "x$CONFIG_SHELL" = x; then | |
141 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
142 | emulate sh | |
143 | NULLCMD=: | |
144 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
145 | # is contrary to our usage. Disable this feature. | |
146 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
147 | setopt NO_GLOB_SUBST | |
148 | else | |
149 | case \`(set -o) 2>/dev/null\` in #( | |
150 | *posix*) : | |
151 | set -o posix ;; #( | |
152 | *) : | |
153 | ;; | |
154 | esac | |
155 | fi | |
156 | " | |
157 | as_required="as_fn_return () { (exit \$1); } | |
158 | as_fn_success () { as_fn_return 0; } | |
159 | as_fn_failure () { as_fn_return 1; } | |
160 | as_fn_ret_success () { return 0; } | |
161 | as_fn_ret_failure () { return 1; } | |
162 | ||
163 | exitcode=0 | |
164 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
165 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
166 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
167 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
168 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
169 | ||
170 | else | |
171 | exitcode=1; echo positional parameters were not saved. | |
172 | fi | |
173 | test x\$exitcode = x0 || exit 1" | |
174 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO | |
175 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
176 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
177 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
178 | test \$(( 1 + 1 )) = 2 || exit 1" | |
179 | if (eval "$as_required") 2>/dev/null; then : | |
180 | as_have_required=yes | |
181 | else | |
182 | as_have_required=no | |
183 | fi | |
184 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
185 | ||
186 | else | |
187 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
188 | as_found=false | |
189 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
190 | do | |
191 | IFS=$as_save_IFS | |
192 | test -z "$as_dir" && as_dir=. | |
193 | as_found=: | |
194 | case $as_dir in #( | |
195 | /*) | |
196 | for as_base in sh bash ksh sh5; do | |
197 | # Try only shells that exist, to save several forks. | |
198 | as_shell=$as_dir/$as_base | |
199 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
200 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
201 | CONFIG_SHELL=$as_shell as_have_required=yes | |
202 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
203 | break 2 | |
204 | fi | |
205 | fi | |
206 | done;; | |
207 | esac | |
208 | as_found=false | |
209 | done | |
210 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
211 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
212 | CONFIG_SHELL=$SHELL as_have_required=yes | |
213 | fi; } | |
214 | IFS=$as_save_IFS | |
215 | ||
216 | ||
217 | if test "x$CONFIG_SHELL" != x; then : | |
218 | # We cannot yet assume a decent shell, so we have to provide a | |
219 | # neutralization value for shells without unset; and this also | |
220 | # works around shells that cannot unset nonexistent variables. | |
221 | # Preserve -v and -x to the replacement shell. | |
222 | BASH_ENV=/dev/null | |
223 | ENV=/dev/null | |
224 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
225 | export CONFIG_SHELL | |
226 | case $- in # (((( | |
227 | *v*x* | *x*v* ) as_opts=-vx ;; | |
228 | *v* ) as_opts=-v ;; | |
229 | *x* ) as_opts=-x ;; | |
230 | * ) as_opts= ;; | |
231 | esac | |
232 | exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} | |
233 | fi | |
234 | ||
235 | if test x$as_have_required = xno; then : | |
236 | $as_echo "$0: This script requires a shell more modern than all" | |
237 | $as_echo "$0: the shells that I found on your system." | |
238 | if test x${ZSH_VERSION+set} = xset ; then | |
239 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
240 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
241 | else | |
242 | $as_echo "$0: Please tell bug-autoconf@gnu.org and bug-bash@gnu.org | |
243 | $0: about your system, including any error possibly output | |
244 | $0: before this message. Then install a modern shell, or | |
245 | $0: manually run the script under such a shell if you do | |
246 | $0: have one." | |
247 | fi | |
248 | exit 1 | |
249 | fi | |
250 | fi | |
251 | fi | |
252 | SHELL=${CONFIG_SHELL-/bin/sh} | |
253 | export SHELL | |
254 | # Unset more variables known to interfere with behavior of common tools. | |
255 | CLICOLOR_FORCE= GREP_OPTIONS= | |
256 | unset CLICOLOR_FORCE GREP_OPTIONS | |
257 | ||
258 | ## --------------------- ## | |
259 | ## M4sh Shell Functions. ## | |
260 | ## --------------------- ## | |
261 | # as_fn_unset VAR | |
262 | # --------------- | |
263 | # Portably unset VAR. | |
264 | as_fn_unset () | |
265 | { | |
266 | { eval $1=; unset $1;} | |
267 | } | |
268 | as_unset=as_fn_unset | |
269 | ||
270 | # as_fn_set_status STATUS | |
271 | # ----------------------- | |
272 | # Set $? to STATUS, without forking. | |
273 | as_fn_set_status () | |
274 | { | |
275 | return $1 | |
276 | } # as_fn_set_status | |
277 | ||
278 | # as_fn_exit STATUS | |
279 | # ----------------- | |
280 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
281 | as_fn_exit () | |
282 | { | |
283 | set +e | |
284 | as_fn_set_status $1 | |
285 | exit $1 | |
286 | } # as_fn_exit | |
287 | ||
288 | # as_fn_mkdir_p | |
289 | # ------------- | |
290 | # Create "$as_dir" as a directory, including parents if necessary. | |
291 | as_fn_mkdir_p () | |
292 | { | |
293 | ||
294 | case $as_dir in #( | |
295 | -*) as_dir=./$as_dir;; | |
296 | esac | |
297 | test -d "$as_dir" || eval $as_mkdir_p || { | |
298 | as_dirs= | |
299 | while :; do | |
300 | case $as_dir in #( | |
301 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
302 | *) as_qdir=$as_dir;; | |
303 | esac | |
304 | as_dirs="'$as_qdir' $as_dirs" | |
305 | as_dir=`$as_dirname -- "$as_dir" || | |
306 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
307 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
308 | X"$as_dir" : 'X\(//\)$' \| \ | |
309 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
310 | $as_echo X"$as_dir" | | |
311 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
312 | s//\1/ | |
313 | q | |
314 | } | |
315 | /^X\(\/\/\)[^/].*/{ | |
316 | s//\1/ | |
317 | q | |
318 | } | |
319 | /^X\(\/\/\)$/{ | |
320 | s//\1/ | |
321 | q | |
322 | } | |
323 | /^X\(\/\).*/{ | |
324 | s//\1/ | |
325 | q | |
326 | } | |
327 | s/.*/./; q'` | |
328 | test -d "$as_dir" && break | |
329 | done | |
330 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
331 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
332 | ||
333 | ||
334 | } # as_fn_mkdir_p | |
335 | # as_fn_append VAR VALUE | |
336 | # ---------------------- | |
337 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
338 | # advantage of any shell optimizations that allow amortized linear growth over | |
339 | # repeated appends, instead of the typical quadratic growth present in naive | |
340 | # implementations. | |
341 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
342 | eval 'as_fn_append () | |
343 | { | |
344 | eval $1+=\$2 | |
345 | }' | |
346 | else | |
347 | as_fn_append () | |
348 | { | |
349 | eval $1=\$$1\$2 | |
350 | } | |
351 | fi # as_fn_append | |
352 | ||
353 | # as_fn_arith ARG... | |
354 | # ------------------ | |
355 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
356 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
357 | # must be portable across $(()) and expr. | |
358 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
359 | eval 'as_fn_arith () | |
360 | { | |
361 | as_val=$(( $* )) | |
362 | }' | |
363 | else | |
364 | as_fn_arith () | |
365 | { | |
366 | as_val=`expr "$@" || test $? -eq 1` | |
367 | } | |
368 | fi # as_fn_arith | |
369 | ||
370 | ||
371 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
372 | # ---------------------------------------- | |
373 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
374 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
375 | # script with STATUS, using 1 if that was 0. | |
376 | as_fn_error () | |
377 | { | |
378 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
379 | if test "$4"; then | |
380 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
381 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
382 | fi | |
383 | $as_echo "$as_me: error: $2" >&2 | |
384 | as_fn_exit $as_status | |
385 | } # as_fn_error | |
386 | ||
b709b946 CR |
387 | if expr a : '\(a\)' >/dev/null 2>&1 && |
388 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
5e4a95c7 CR |
389 | as_expr=expr |
390 | else | |
391 | as_expr=false | |
392 | fi | |
393 | ||
b709b946 | 394 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
5e4a95c7 CR |
395 | as_basename=basename |
396 | else | |
397 | as_basename=false | |
398 | fi | |
a82a04b3 | 399 | |
7f947b68 CR |
400 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
401 | as_dirname=dirname | |
402 | else | |
403 | as_dirname=false | |
404 | fi | |
a82a04b3 | 405 | |
b709b946 | 406 | as_me=`$as_basename -- "$0" || |
a82a04b3 CR |
407 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
408 | X"$0" : 'X\(//\)$' \| \ | |
b709b946 | 409 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 410 | $as_echo X/"$0" | |
b709b946 CR |
411 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
412 | s//\1/ | |
413 | q | |
414 | } | |
415 | /^X\/\(\/\/\)$/{ | |
416 | s//\1/ | |
417 | q | |
418 | } | |
419 | /^X\/\(\/\).*/{ | |
420 | s//\1/ | |
421 | q | |
422 | } | |
423 | s/.*/./; q'` | |
9d6e5e30 | 424 | |
7f947b68 CR |
425 | # Avoid depending upon Character Ranges. |
426 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
427 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
428 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
429 | as_cr_digits='0123456789' | |
430 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
9d6e5e30 | 431 | |
9d6e5e30 | 432 | |
7f947b68 CR |
433 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
434 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
435 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
436 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
437 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
438 | sed -n ' | |
439 | p | |
440 | /[$]LINENO/= | |
441 | ' <$as_myself | | |
442 | sed ' | |
443 | s/[$]LINENO.*/&-/ | |
444 | t lineno | |
445 | b | |
446 | :lineno | |
447 | N | |
448 | :loop | |
449 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
450 | t loop | |
451 | s/-\n.*// | |
452 | ' >$as_me.lineno && | |
453 | chmod +x "$as_me.lineno" || | |
454 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
b709b946 | 455 | |
7f947b68 CR |
456 | # Don't try to exec as it changes $[0], causing all sort of problems |
457 | # (the dirname of $[0] is not the place where we might find the | |
458 | # original and so on. Autoconf is especially sensitive to this). | |
459 | . "./$as_me.lineno" | |
460 | # Exit status is that of the last command. | |
461 | exit | |
b709b946 CR |
462 | } |
463 | ||
7f947b68 CR |
464 | ECHO_C= ECHO_N= ECHO_T= |
465 | case `echo -n x` in #((((( | |
466 | -n*) | |
467 | case `echo 'xy\c'` in | |
468 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
469 | xy) ECHO_C='\c';; | |
470 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
471 | ECHO_T=' ';; | |
472 | esac;; | |
473 | *) | |
474 | ECHO_N='-n';; | |
475 | esac | |
abe2eb5b | 476 | |
7f947b68 CR |
477 | rm -f conf$$ conf$$.exe conf$$.file |
478 | if test -d conf$$.dir; then | |
479 | rm -f conf$$.dir/conf$$.file | |
480 | else | |
481 | rm -f conf$$.dir | |
482 | mkdir conf$$.dir 2>/dev/null | |
7610e0c5 | 483 | fi |
7f947b68 CR |
484 | if (echo >conf$$.file) 2>/dev/null; then |
485 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
486 | as_ln_s='ln -s' | |
487 | # ... but there are two gotchas: | |
488 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
489 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
490 | # In both cases, we have to default to `cp -p'. | |
491 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
492 | as_ln_s='cp -p' | |
493 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
494 | as_ln_s=ln | |
495 | else | |
496 | as_ln_s='cp -p' | |
497 | fi | |
2dead0c4 | 498 | else |
7f947b68 | 499 | as_ln_s='cp -p' |
e3db237e | 500 | fi |
7f947b68 CR |
501 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
502 | rmdir conf$$.dir 2>/dev/null | |
e3db237e | 503 | |
7f947b68 CR |
504 | if mkdir -p . 2>/dev/null; then |
505 | as_mkdir_p='mkdir -p "$as_dir"' | |
506 | else | |
507 | test -d ./-p && rmdir ./-p | |
508 | as_mkdir_p=false | |
abe2eb5b CR |
509 | fi |
510 | ||
7f947b68 CR |
511 | if test -x / >/dev/null 2>&1; then |
512 | as_test_x='test -x' | |
b709b946 | 513 | else |
7f947b68 CR |
514 | if ls -dL / >/dev/null 2>&1; then |
515 | as_ls_L_option=L | |
516 | else | |
517 | as_ls_L_option= | |
518 | fi | |
519 | as_test_x=' | |
520 | eval sh -c '\'' | |
521 | if test -d "$1"; then | |
522 | test -d "$1/."; | |
523 | else | |
524 | case $1 in #( | |
525 | -*)set "./$1";; | |
526 | esac; | |
527 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
528 | ???[sx]*):;;*)false;;esac;fi | |
529 | '\'' sh | |
530 | ' | |
b709b946 | 531 | fi |
7f947b68 | 532 | as_executable_p=$as_test_x |
b709b946 | 533 | |
7f947b68 CR |
534 | # Sed expression to map a string onto a valid CPP name. |
535 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" | |
b709b946 | 536 | |
7f947b68 CR |
537 | # Sed expression to map a string onto a valid variable name. |
538 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" | |
b709b946 CR |
539 | |
540 | ||
7f947b68 CR |
541 | test -n "$DJDIR" || exec 7<&0 </dev/null |
542 | exec 6>&1 | |
f73dda09 JA |
543 | |
544 | # Name of the host. | |
7f947b68 | 545 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
f73dda09 JA |
546 | # so uname gets run too. |
547 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
548 | ||
726f6388 | 549 | # |
f73dda09 JA |
550 | # Initializations. |
551 | # | |
ccc6cda3 | 552 | ac_default_prefix=/usr/local |
b709b946 | 553 | ac_clean_files= |
5e4a95c7 | 554 | ac_config_libobj_dir=. |
b709b946 | 555 | LIBOBJS= |
f73dda09 JA |
556 | cross_compiling=no |
557 | subdirs= | |
a82a04b3 CR |
558 | MFLAGS= |
559 | MAKEFLAGS= | |
f73dda09 | 560 | |
a82a04b3 CR |
561 | # Identity of this package. |
562 | PACKAGE_NAME='bash' | |
563 | PACKAGE_TARNAME='bash' | |
e192f341 CR |
564 | PACKAGE_VERSION='4.2-maint' |
565 | PACKAGE_STRING='bash 4.2-maint' | |
a82a04b3 | 566 | PACKAGE_BUGREPORT='bug-bash@gnu.org' |
7f947b68 | 567 | PACKAGE_URL='' |
a82a04b3 | 568 | |
f73dda09 JA |
569 | ac_unique_file="shell.h" |
570 | # Factoring default headers for most tests. | |
571 | ac_includes_default="\ | |
572 | #include <stdio.h> | |
dd4f3dd8 | 573 | #ifdef HAVE_SYS_TYPES_H |
f73dda09 JA |
574 | # include <sys/types.h> |
575 | #endif | |
dd4f3dd8 | 576 | #ifdef HAVE_SYS_STAT_H |
f73dda09 JA |
577 | # include <sys/stat.h> |
578 | #endif | |
dd4f3dd8 | 579 | #ifdef STDC_HEADERS |
f73dda09 JA |
580 | # include <stdlib.h> |
581 | # include <stddef.h> | |
582 | #else | |
dd4f3dd8 | 583 | # ifdef HAVE_STDLIB_H |
f73dda09 JA |
584 | # include <stdlib.h> |
585 | # endif | |
586 | #endif | |
dd4f3dd8 CR |
587 | #ifdef HAVE_STRING_H |
588 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
f73dda09 JA |
589 | # include <memory.h> |
590 | # endif | |
591 | # include <string.h> | |
592 | #endif | |
dd4f3dd8 | 593 | #ifdef HAVE_STRINGS_H |
f73dda09 JA |
594 | # include <strings.h> |
595 | #endif | |
dd4f3dd8 | 596 | #ifdef HAVE_INTTYPES_H |
f73dda09 | 597 | # include <inttypes.h> |
b709b946 | 598 | #endif |
dd4f3dd8 | 599 | #ifdef HAVE_STDINT_H |
b709b946 | 600 | # include <stdint.h> |
f73dda09 | 601 | #endif |
dd4f3dd8 | 602 | #ifdef HAVE_UNISTD_H |
f73dda09 JA |
603 | # include <unistd.h> |
604 | #endif" | |
ccc6cda3 | 605 | |
dd4f3dd8 | 606 | ac_header_list= |
53ac45a3 | 607 | ac_func_list= |
af98a2a6 | 608 | ac_subst_vars='LTLIBOBJS |
691aebcb | 609 | LOCAL_DEFS |
af98a2a6 CR |
610 | LOCAL_LDFLAGS |
611 | LOCAL_CFLAGS | |
612 | LOCAL_LIBS | |
613 | MALLOC_DEBUG | |
614 | DEBUG | |
615 | RELSTATUS | |
616 | BASHVERS | |
617 | ARFLAGS | |
618 | BUILD_DIR | |
619 | incdir | |
620 | PROFILE_FLAGS | |
621 | SHOBJ_STATUS | |
622 | SHOBJ_LIBS | |
623 | SHOBJ_XLDFLAGS | |
624 | SHOBJ_LDFLAGS | |
625 | SHOBJ_LD | |
626 | SHOBJ_CFLAGS | |
627 | SHOBJ_CC | |
628 | JOBS_O | |
629 | TERMCAP_DEP | |
630 | TERMCAP_LIB | |
631 | SIGLIST_O | |
278286c9 CR |
632 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC |
633 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC | |
634 | TIME_H_DEFINES_STRUCT_TIMESPEC | |
af98a2a6 CR |
635 | LIBINTL_H |
636 | INTL_INC | |
637 | INTL_DEP | |
638 | LIBOBJS | |
639 | POSUB | |
640 | LTLIBINTL | |
641 | LIBINTL | |
642 | INTLLIBS | |
643 | INTL_LIBTOOL_SUFFIX_PREFIX | |
644 | INTLOBJS | |
645 | GENCAT | |
646 | INSTOBJEXT | |
647 | DATADIRNAME | |
648 | CATOBJEXT | |
649 | USE_INCLUDED_LIBINTL | |
650 | BUILD_INCLUDED_LIBINTL | |
651 | INTLBISON | |
652 | LTLIBICONV | |
653 | LIBICONV | |
654 | GLIBC21 | |
655 | ALLOCA | |
656 | MSGMERGE | |
657 | XGETTEXT | |
658 | GMSGFMT | |
659 | MSGFMT | |
660 | USE_NLS | |
661 | MKINSTALLDIRS | |
662 | SIZE | |
663 | MAKE_SHELL | |
664 | SET_MAKE | |
665 | YFLAGS | |
666 | YACC | |
667 | RANLIB | |
668 | AR | |
669 | INSTALL_DATA | |
670 | INSTALL_SCRIPT | |
671 | INSTALL_PROGRAM | |
672 | TILDE_LIB | |
673 | HIST_LIBDIR | |
674 | HISTORY_DEP | |
675 | HISTORY_LIB | |
676 | RL_INCLUDE | |
677 | RL_INCLUDEDIR | |
678 | RL_LIBDIR | |
679 | READLINE_DEP | |
680 | READLINE_LIB | |
681 | RL_MINOR | |
682 | RL_MAJOR | |
683 | RL_VERSION | |
7610e0c5 | 684 | LIBS_FOR_BUILD |
af98a2a6 | 685 | STATIC_LD |
af98a2a6 CR |
686 | SIGNAMES_O |
687 | SIGNAMES_H | |
688 | CROSS_COMPILE | |
689 | EGREP | |
690 | GREP | |
691 | CPP | |
692 | OBJEXT | |
693 | EXEEXT | |
694 | ac_ct_CC | |
695 | CPPFLAGS | |
696 | LDFLAGS | |
697 | CFLAGS | |
698 | CC | |
699 | HELPSTRINGS | |
abe2eb5b | 700 | HELPFILES_TARGET |
af98a2a6 CR |
701 | HELPINSTALL |
702 | HELPDIRDEFINE | |
703 | HELPDIR | |
704 | MALLOC_DEP | |
705 | MALLOC_LDFLAGS | |
706 | MALLOC_LIBRARY | |
707 | MALLOC_LIB | |
708 | MALLOC_SRC | |
709 | MALLOC_TARGET | |
710 | PURIFY | |
711 | TESTSCRIPT | |
7610e0c5 CR |
712 | CPPFLAGS_FOR_BUILD |
713 | LDFLAGS_FOR_BUILD | |
714 | CFLAGS_FOR_BUILD | |
715 | CC_FOR_BUILD | |
af98a2a6 | 716 | DEBUGGER_START_FILE |
af98a2a6 CR |
717 | host_os |
718 | host_vendor | |
719 | host_cpu | |
720 | host | |
721 | build_os | |
722 | build_vendor | |
723 | build_cpu | |
724 | build | |
725 | target_alias | |
726 | host_alias | |
727 | build_alias | |
728 | LIBS | |
729 | ECHO_T | |
730 | ECHO_N | |
731 | ECHO_C | |
732 | DEFS | |
733 | mandir | |
734 | localedir | |
735 | libdir | |
736 | psdir | |
737 | pdfdir | |
738 | dvidir | |
739 | htmldir | |
740 | infodir | |
741 | docdir | |
742 | oldincludedir | |
743 | includedir | |
744 | localstatedir | |
745 | sharedstatedir | |
746 | sysconfdir | |
747 | datadir | |
748 | datarootdir | |
749 | libexecdir | |
750 | sbindir | |
751 | bindir | |
752 | program_transform_name | |
753 | prefix | |
754 | exec_prefix | |
7f947b68 | 755 | PACKAGE_URL |
af98a2a6 CR |
756 | PACKAGE_BUGREPORT |
757 | PACKAGE_STRING | |
758 | PACKAGE_VERSION | |
759 | PACKAGE_TARNAME | |
760 | PACKAGE_NAME | |
761 | PATH_SEPARATOR | |
762 | SHELL' | |
5e4a95c7 | 763 | ac_subst_files='' |
dd4f3dd8 CR |
764 | ac_user_opts=' |
765 | enable_option_checking | |
dd4f3dd8 CR |
766 | with_afs |
767 | with_bash_malloc | |
768 | with_curses | |
769 | with_gnu_malloc | |
770 | with_installed_readline | |
771 | with_purecov | |
772 | with_purify | |
773 | enable_minimal_config | |
774 | enable_alias | |
775 | enable_arith_for_command | |
776 | enable_array_variables | |
777 | enable_bang_history | |
778 | enable_brace_expansion | |
779 | enable_casemod_attributes | |
780 | enable_casemod_expansions | |
781 | enable_command_timing | |
782 | enable_cond_command | |
783 | enable_cond_regexp | |
784 | enable_coprocesses | |
785 | enable_debugger | |
f14388d3 | 786 | enable_direxpand_default |
dd4f3dd8 CR |
787 | enable_directory_stack |
788 | enable_disabled_builtins | |
789 | enable_dparen_arithmetic | |
790 | enable_extended_glob | |
691aebcb | 791 | enable_extended_glob_default |
dd4f3dd8 CR |
792 | enable_help_builtin |
793 | enable_history | |
794 | enable_job_control | |
795 | enable_multibyte | |
796 | enable_net_redirections | |
797 | enable_process_substitution | |
798 | enable_progcomp | |
799 | enable_prompt_string_decoding | |
800 | enable_readline | |
801 | enable_restricted | |
802 | enable_select | |
803 | enable_separate_helpfiles | |
804 | enable_single_help_strings | |
805 | enable_strict_posix_default | |
806 | enable_usg_echo_default | |
807 | enable_xpg_echo_default | |
808 | enable_mem_scramble | |
809 | enable_profiling | |
810 | enable_static_link | |
811 | enable_largefile | |
812 | enable_nls | |
813 | with_gnu_ld | |
814 | enable_rpath | |
815 | with_libiconv_prefix | |
816 | with_included_gettext | |
817 | with_libintl_prefix | |
818 | ' | |
b709b946 CR |
819 | ac_precious_vars='build_alias |
820 | host_alias | |
821 | target_alias | |
822 | DEBUGGER_START_FILE | |
7610e0c5 CR |
823 | CC_FOR_BUILD |
824 | CFLAGS_FOR_BUILD | |
825 | LDFLAGS_FOR_BUILD | |
826 | CPPFLAGS_FOR_BUILD | |
b709b946 CR |
827 | CC |
828 | CFLAGS | |
829 | LDFLAGS | |
dd4f3dd8 | 830 | LIBS |
b709b946 CR |
831 | CPPFLAGS |
832 | CPP | |
833 | YACC | |
834 | YFLAGS' | |
835 | ||
a82a04b3 | 836 | |
ccc6cda3 | 837 | # Initialize some variables set by options. |
f73dda09 JA |
838 | ac_init_help= |
839 | ac_init_version=false | |
dd4f3dd8 CR |
840 | ac_unrecognized_opts= |
841 | ac_unrecognized_sep= | |
ccc6cda3 JA |
842 | # The variables have the same names as the options, with |
843 | # dashes changed to underlines. | |
f73dda09 | 844 | cache_file=/dev/null |
ccc6cda3 | 845 | exec_prefix=NONE |
ccc6cda3 | 846 | no_create= |
ccc6cda3 JA |
847 | no_recursion= |
848 | prefix=NONE | |
849 | program_prefix=NONE | |
850 | program_suffix=NONE | |
851 | program_transform_name=s,x,x, | |
852 | silent= | |
853 | site= | |
854 | srcdir= | |
ccc6cda3 JA |
855 | verbose= |
856 | x_includes=NONE | |
857 | x_libraries=NONE | |
f73dda09 JA |
858 | |
859 | # Installation directory options. | |
860 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
861 | # and all the variables that are supposed to be based on exec_prefix | |
862 | # by default will actually change. | |
863 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
b709b946 | 864 | # (The list follows the same order as the GNU Coding Standards.) |
ccc6cda3 JA |
865 | bindir='${exec_prefix}/bin' |
866 | sbindir='${exec_prefix}/sbin' | |
867 | libexecdir='${exec_prefix}/libexec' | |
b709b946 CR |
868 | datarootdir='${prefix}/share' |
869 | datadir='${datarootdir}' | |
ccc6cda3 JA |
870 | sysconfdir='${prefix}/etc' |
871 | sharedstatedir='${prefix}/com' | |
872 | localstatedir='${prefix}/var' | |
ccc6cda3 JA |
873 | includedir='${prefix}/include' |
874 | oldincludedir='/usr/include' | |
b709b946 CR |
875 | docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' |
876 | infodir='${datarootdir}/info' | |
877 | htmldir='${docdir}' | |
878 | dvidir='${docdir}' | |
879 | pdfdir='${docdir}' | |
880 | psdir='${docdir}' | |
881 | libdir='${exec_prefix}/lib' | |
882 | localedir='${datarootdir}/locale' | |
883 | mandir='${datarootdir}/man' | |
ccc6cda3 | 884 | |
ccc6cda3 | 885 | ac_prev= |
b709b946 | 886 | ac_dashdash= |
ccc6cda3 JA |
887 | for ac_option |
888 | do | |
ccc6cda3 JA |
889 | # If the previous option needs an argument, assign it. |
890 | if test -n "$ac_prev"; then | |
b709b946 | 891 | eval $ac_prev=\$ac_option |
ccc6cda3 JA |
892 | ac_prev= |
893 | continue | |
894 | fi | |
895 | ||
b709b946 | 896 | case $ac_option in |
7f947b68 CR |
897 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
898 | *=) ac_optarg= ;; | |
899 | *) ac_optarg=yes ;; | |
b709b946 | 900 | esac |
ccc6cda3 JA |
901 | |
902 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
903 | ||
b709b946 CR |
904 | case $ac_dashdash$ac_option in |
905 | --) | |
906 | ac_dashdash=yes ;; | |
ccc6cda3 JA |
907 | |
908 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
909 | ac_prev=bindir ;; | |
910 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
f73dda09 | 911 | bindir=$ac_optarg ;; |
ccc6cda3 JA |
912 | |
913 | -build | --build | --buil | --bui | --bu) | |
f73dda09 | 914 | ac_prev=build_alias ;; |
ccc6cda3 | 915 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
f73dda09 | 916 | build_alias=$ac_optarg ;; |
ccc6cda3 JA |
917 | |
918 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
919 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
920 | ac_prev=cache_file ;; | |
921 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
922 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
f73dda09 JA |
923 | cache_file=$ac_optarg ;; |
924 | ||
925 | --config-cache | -C) | |
926 | cache_file=config.cache ;; | |
ccc6cda3 | 927 | |
b709b946 | 928 | -datadir | --datadir | --datadi | --datad) |
ccc6cda3 | 929 | ac_prev=datadir ;; |
b709b946 | 930 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
f73dda09 | 931 | datadir=$ac_optarg ;; |
ccc6cda3 | 932 | |
b709b946 CR |
933 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
934 | | --dataroo | --dataro | --datar) | |
935 | ac_prev=datarootdir ;; | |
936 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
937 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
938 | datarootdir=$ac_optarg ;; | |
939 | ||
ccc6cda3 | 940 | -disable-* | --disable-*) |
dd4f3dd8 | 941 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
ccc6cda3 | 942 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 943 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
7f947b68 | 944 | as_fn_error $? "invalid feature name: $ac_useropt" |
dd4f3dd8 CR |
945 | ac_useropt_orig=$ac_useropt |
946 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
947 | case $ac_user_opts in | |
948 | *" | |
949 | "enable_$ac_useropt" | |
950 | "*) ;; | |
951 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
952 | ac_unrecognized_sep=', ';; | |
953 | esac | |
954 | eval enable_$ac_useropt=no ;; | |
b709b946 CR |
955 | |
956 | -docdir | --docdir | --docdi | --doc | --do) | |
957 | ac_prev=docdir ;; | |
958 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
959 | docdir=$ac_optarg ;; | |
960 | ||
961 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
962 | ac_prev=dvidir ;; | |
963 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
964 | dvidir=$ac_optarg ;; | |
ccc6cda3 JA |
965 | |
966 | -enable-* | --enable-*) | |
dd4f3dd8 | 967 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
ccc6cda3 | 968 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 969 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
7f947b68 | 970 | as_fn_error $? "invalid feature name: $ac_useropt" |
dd4f3dd8 CR |
971 | ac_useropt_orig=$ac_useropt |
972 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
973 | case $ac_user_opts in | |
974 | *" | |
975 | "enable_$ac_useropt" | |
976 | "*) ;; | |
977 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
978 | ac_unrecognized_sep=', ';; | |
979 | esac | |
980 | eval enable_$ac_useropt=\$ac_optarg ;; | |
ccc6cda3 JA |
981 | |
982 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
983 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
984 | | --exec | --exe | --ex) | |
985 | ac_prev=exec_prefix ;; | |
986 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
987 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
988 | | --exec=* | --exe=* | --ex=*) | |
f73dda09 | 989 | exec_prefix=$ac_optarg ;; |
ccc6cda3 JA |
990 | |
991 | -gas | --gas | --ga | --g) | |
992 | # Obsolete; use --with-gas. | |
993 | with_gas=yes ;; | |
994 | ||
f73dda09 JA |
995 | -help | --help | --hel | --he | -h) |
996 | ac_init_help=long ;; | |
997 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
998 | ac_init_help=recursive ;; | |
999 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
1000 | ac_init_help=short ;; | |
ccc6cda3 JA |
1001 | |
1002 | -host | --host | --hos | --ho) | |
f73dda09 | 1003 | ac_prev=host_alias ;; |
ccc6cda3 | 1004 | -host=* | --host=* | --hos=* | --ho=*) |
f73dda09 | 1005 | host_alias=$ac_optarg ;; |
ccc6cda3 | 1006 | |
b709b946 CR |
1007 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
1008 | ac_prev=htmldir ;; | |
1009 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
1010 | | --ht=*) | |
1011 | htmldir=$ac_optarg ;; | |
1012 | ||
ccc6cda3 JA |
1013 | -includedir | --includedir | --includedi | --included | --include \ |
1014 | | --includ | --inclu | --incl | --inc) | |
1015 | ac_prev=includedir ;; | |
1016 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
1017 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
f73dda09 | 1018 | includedir=$ac_optarg ;; |
ccc6cda3 JA |
1019 | |
1020 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
1021 | ac_prev=infodir ;; | |
1022 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
f73dda09 | 1023 | infodir=$ac_optarg ;; |
ccc6cda3 JA |
1024 | |
1025 | -libdir | --libdir | --libdi | --libd) | |
1026 | ac_prev=libdir ;; | |
1027 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
f73dda09 | 1028 | libdir=$ac_optarg ;; |
ccc6cda3 JA |
1029 | |
1030 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
1031 | | --libexe | --libex | --libe) | |
1032 | ac_prev=libexecdir ;; | |
1033 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
1034 | | --libexe=* | --libex=* | --libe=*) | |
f73dda09 | 1035 | libexecdir=$ac_optarg ;; |
ccc6cda3 | 1036 | |
b709b946 CR |
1037 | -localedir | --localedir | --localedi | --localed | --locale) |
1038 | ac_prev=localedir ;; | |
1039 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
1040 | localedir=$ac_optarg ;; | |
1041 | ||
ccc6cda3 | 1042 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
b709b946 | 1043 | | --localstate | --localstat | --localsta | --localst | --locals) |
ccc6cda3 JA |
1044 | ac_prev=localstatedir ;; |
1045 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
b709b946 | 1046 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
f73dda09 | 1047 | localstatedir=$ac_optarg ;; |
ccc6cda3 JA |
1048 | |
1049 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
1050 | ac_prev=mandir ;; | |
1051 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
f73dda09 | 1052 | mandir=$ac_optarg ;; |
ccc6cda3 JA |
1053 | |
1054 | -nfp | --nfp | --nf) | |
1055 | # Obsolete; use --without-fp. | |
1056 | with_fp=no ;; | |
1057 | ||
1058 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
a82a04b3 | 1059 | | --no-cr | --no-c | -n) |
ccc6cda3 JA |
1060 | no_create=yes ;; |
1061 | ||
1062 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
1063 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
1064 | no_recursion=yes ;; | |
1065 | ||
1066 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
1067 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
1068 | | --oldin | --oldi | --old | --ol | --o) | |
1069 | ac_prev=oldincludedir ;; | |
1070 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
1071 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
1072 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
f73dda09 | 1073 | oldincludedir=$ac_optarg ;; |
ccc6cda3 JA |
1074 | |
1075 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
1076 | ac_prev=prefix ;; | |
1077 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
f73dda09 | 1078 | prefix=$ac_optarg ;; |
ccc6cda3 JA |
1079 | |
1080 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
1081 | | --program-pre | --program-pr | --program-p) | |
1082 | ac_prev=program_prefix ;; | |
1083 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
1084 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
f73dda09 | 1085 | program_prefix=$ac_optarg ;; |
ccc6cda3 JA |
1086 | |
1087 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
1088 | | --program-suf | --program-su | --program-s) | |
1089 | ac_prev=program_suffix ;; | |
1090 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
1091 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
f73dda09 | 1092 | program_suffix=$ac_optarg ;; |
ccc6cda3 JA |
1093 | |
1094 | -program-transform-name | --program-transform-name \ | |
1095 | | --program-transform-nam | --program-transform-na \ | |
1096 | | --program-transform-n | --program-transform- \ | |
1097 | | --program-transform | --program-transfor \ | |
1098 | | --program-transfo | --program-transf \ | |
1099 | | --program-trans | --program-tran \ | |
1100 | | --progr-tra | --program-tr | --program-t) | |
1101 | ac_prev=program_transform_name ;; | |
1102 | -program-transform-name=* | --program-transform-name=* \ | |
1103 | | --program-transform-nam=* | --program-transform-na=* \ | |
1104 | | --program-transform-n=* | --program-transform-=* \ | |
1105 | | --program-transform=* | --program-transfor=* \ | |
1106 | | --program-transfo=* | --program-transf=* \ | |
1107 | | --program-trans=* | --program-tran=* \ | |
1108 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
f73dda09 | 1109 | program_transform_name=$ac_optarg ;; |
ccc6cda3 | 1110 | |
b709b946 CR |
1111 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
1112 | ac_prev=pdfdir ;; | |
1113 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1114 | pdfdir=$ac_optarg ;; | |
1115 | ||
1116 | -psdir | --psdir | --psdi | --psd | --ps) | |
1117 | ac_prev=psdir ;; | |
1118 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1119 | psdir=$ac_optarg ;; | |
1120 | ||
ccc6cda3 JA |
1121 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
1122 | | -silent | --silent | --silen | --sile | --sil) | |
1123 | silent=yes ;; | |
1124 | ||
1125 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1126 | ac_prev=sbindir ;; | |
1127 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1128 | | --sbi=* | --sb=*) | |
f73dda09 | 1129 | sbindir=$ac_optarg ;; |
ccc6cda3 JA |
1130 | |
1131 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1132 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1133 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1134 | | --sha | --sh) | |
1135 | ac_prev=sharedstatedir ;; | |
1136 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1137 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1138 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1139 | | --sha=* | --sh=*) | |
f73dda09 | 1140 | sharedstatedir=$ac_optarg ;; |
ccc6cda3 JA |
1141 | |
1142 | -site | --site | --sit) | |
1143 | ac_prev=site ;; | |
1144 | -site=* | --site=* | --sit=*) | |
f73dda09 | 1145 | site=$ac_optarg ;; |
ccc6cda3 JA |
1146 | |
1147 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1148 | ac_prev=srcdir ;; | |
1149 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
f73dda09 | 1150 | srcdir=$ac_optarg ;; |
ccc6cda3 JA |
1151 | |
1152 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1153 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1154 | ac_prev=sysconfdir ;; | |
1155 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1156 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
f73dda09 | 1157 | sysconfdir=$ac_optarg ;; |
ccc6cda3 JA |
1158 | |
1159 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
f73dda09 | 1160 | ac_prev=target_alias ;; |
ccc6cda3 | 1161 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
f73dda09 | 1162 | target_alias=$ac_optarg ;; |
ccc6cda3 JA |
1163 | |
1164 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1165 | verbose=yes ;; | |
1166 | ||
f73dda09 JA |
1167 | -version | --version | --versio | --versi | --vers | -V) |
1168 | ac_init_version=: ;; | |
ccc6cda3 JA |
1169 | |
1170 | -with-* | --with-*) | |
dd4f3dd8 | 1171 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
ccc6cda3 | 1172 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 1173 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
7f947b68 | 1174 | as_fn_error $? "invalid package name: $ac_useropt" |
dd4f3dd8 CR |
1175 | ac_useropt_orig=$ac_useropt |
1176 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1177 | case $ac_user_opts in | |
1178 | *" | |
1179 | "with_$ac_useropt" | |
1180 | "*) ;; | |
1181 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1182 | ac_unrecognized_sep=', ';; | |
1183 | esac | |
1184 | eval with_$ac_useropt=\$ac_optarg ;; | |
ccc6cda3 JA |
1185 | |
1186 | -without-* | --without-*) | |
dd4f3dd8 | 1187 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
ccc6cda3 | 1188 | # Reject names that are not valid shell variable names. |
dd4f3dd8 | 1189 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
7f947b68 | 1190 | as_fn_error $? "invalid package name: $ac_useropt" |
dd4f3dd8 CR |
1191 | ac_useropt_orig=$ac_useropt |
1192 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1193 | case $ac_user_opts in | |
1194 | *" | |
1195 | "with_$ac_useropt" | |
1196 | "*) ;; | |
1197 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1198 | ac_unrecognized_sep=', ';; | |
1199 | esac | |
1200 | eval with_$ac_useropt=no ;; | |
ccc6cda3 JA |
1201 | |
1202 | --x) | |
1203 | # Obsolete; use --with-x. | |
1204 | with_x=yes ;; | |
1205 | ||
1206 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1207 | | --x-incl | --x-inc | --x-in | --x-i) | |
1208 | ac_prev=x_includes ;; | |
1209 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1210 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
f73dda09 | 1211 | x_includes=$ac_optarg ;; |
ccc6cda3 JA |
1212 | |
1213 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1214 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1215 | ac_prev=x_libraries ;; | |
1216 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1217 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
f73dda09 | 1218 | x_libraries=$ac_optarg ;; |
ccc6cda3 | 1219 | |
7f947b68 CR |
1220 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
1221 | Try \`$0 --help' for more information" | |
ccc6cda3 JA |
1222 | ;; |
1223 | ||
f73dda09 JA |
1224 | *=*) |
1225 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1226 | # Reject names that are not valid shell variable names. | |
7f947b68 CR |
1227 | case $ac_envvar in #( |
1228 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
1229 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; | |
1230 | esac | |
b709b946 | 1231 | eval $ac_envvar=\$ac_optarg |
f73dda09 JA |
1232 | export $ac_envvar ;; |
1233 | ||
ccc6cda3 | 1234 | *) |
f73dda09 | 1235 | # FIXME: should be removed in autoconf 3.0. |
dd4f3dd8 | 1236 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
f73dda09 | 1237 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
dd4f3dd8 | 1238 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
7f947b68 | 1239 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
ccc6cda3 JA |
1240 | ;; |
1241 | ||
1242 | esac | |
1243 | done | |
1244 | ||
1245 | if test -n "$ac_prev"; then | |
f73dda09 | 1246 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
7f947b68 | 1247 | as_fn_error $? "missing argument to $ac_option" |
ccc6cda3 | 1248 | fi |
ccc6cda3 | 1249 | |
dd4f3dd8 CR |
1250 | if test -n "$ac_unrecognized_opts"; then |
1251 | case $enable_option_checking in | |
1252 | no) ;; | |
7f947b68 | 1253 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
af98a2a6 | 1254 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
dd4f3dd8 CR |
1255 | esac |
1256 | fi | |
1257 | ||
1258 | # Check all directory arguments for consistency. | |
b709b946 CR |
1259 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ |
1260 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1261 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
1262 | libdir localedir mandir | |
c184f645 | 1263 | do |
b709b946 | 1264 | eval ac_val=\$$ac_var |
dd4f3dd8 CR |
1265 | # Remove trailing slashes. |
1266 | case $ac_val in | |
1267 | */ ) | |
1268 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1269 | eval $ac_var=\$ac_val;; | |
1270 | esac | |
1271 | # Be sure to have absolute directory names. | |
c184f645 | 1272 | case $ac_val in |
b709b946 CR |
1273 | [\\/$]* | ?:[\\/]* ) continue;; |
1274 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
ccc6cda3 | 1275 | esac |
7f947b68 | 1276 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
ccc6cda3 JA |
1277 | done |
1278 | ||
f73dda09 JA |
1279 | # There might be people who depend on the old broken behavior: `$host' |
1280 | # used to hold the argument of --host etc. | |
a82a04b3 | 1281 | # FIXME: To remove some day. |
f73dda09 JA |
1282 | build=$build_alias |
1283 | host=$host_alias | |
1284 | target=$target_alias | |
1285 | ||
a82a04b3 | 1286 | # FIXME: To remove some day. |
f73dda09 JA |
1287 | if test "x$host_alias" != x; then |
1288 | if test "x$build_alias" = x; then | |
1289 | cross_compiling=maybe | |
7f947b68 CR |
1290 | $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host. |
1291 | If a cross compiler is detected then cross compile mode will be used" >&2 | |
f73dda09 JA |
1292 | elif test "x$build_alias" != "x$host_alias"; then |
1293 | cross_compiling=yes | |
1294 | fi | |
1295 | fi | |
ccc6cda3 | 1296 | |
f73dda09 JA |
1297 | ac_tool_prefix= |
1298 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
ccc6cda3 | 1299 | |
f73dda09 | 1300 | test "$silent" = yes && exec 6>/dev/null |
ccc6cda3 | 1301 | |
a82a04b3 | 1302 | |
b709b946 CR |
1303 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
1304 | ac_ls_di=`ls -di .` && | |
1305 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
7f947b68 | 1306 | as_fn_error $? "working directory cannot be determined" |
b709b946 | 1307 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
7f947b68 | 1308 | as_fn_error $? "pwd does not report name of working directory" |
b709b946 CR |
1309 | |
1310 | ||
ccc6cda3 JA |
1311 | # Find the source files, if location was not specified. |
1312 | if test -z "$srcdir"; then | |
1313 | ac_srcdir_defaulted=yes | |
b709b946 | 1314 | # Try the directory containing this script, then the parent directory. |
dd4f3dd8 CR |
1315 | ac_confdir=`$as_dirname -- "$as_myself" || |
1316 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1317 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1318 | X"$as_myself" : 'X\(//\)$' \| \ | |
1319 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1320 | $as_echo X"$as_myself" | | |
b709b946 CR |
1321 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
1322 | s//\1/ | |
1323 | q | |
1324 | } | |
1325 | /^X\(\/\/\)[^/].*/{ | |
1326 | s//\1/ | |
1327 | q | |
1328 | } | |
1329 | /^X\(\/\/\)$/{ | |
1330 | s//\1/ | |
1331 | q | |
1332 | } | |
1333 | /^X\(\/\).*/{ | |
1334 | s//\1/ | |
1335 | q | |
1336 | } | |
1337 | s/.*/./; q'` | |
ccc6cda3 | 1338 | srcdir=$ac_confdir |
b709b946 | 1339 | if test ! -r "$srcdir/$ac_unique_file"; then |
ccc6cda3 JA |
1340 | srcdir=.. |
1341 | fi | |
1342 | else | |
1343 | ac_srcdir_defaulted=no | |
1344 | fi | |
b709b946 CR |
1345 | if test ! -r "$srcdir/$ac_unique_file"; then |
1346 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
7f947b68 | 1347 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
c184f645 | 1348 | fi |
b709b946 CR |
1349 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" |
1350 | ac_abs_confdir=`( | |
7f947b68 | 1351 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
b709b946 CR |
1352 | pwd)` |
1353 | # When building in place, set srcdir=. | |
1354 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1355 | srcdir=. | |
1356 | fi | |
1357 | # Remove unnecessary trailing slashes from srcdir. | |
1358 | # Double slashes in file names in object file debugging info | |
1359 | # mess up M-x gdb in Emacs. | |
1360 | case $srcdir in | |
1361 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1362 | esac | |
1363 | for ac_var in $ac_precious_vars; do | |
1364 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1365 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1366 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1367 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1368 | done | |
ccc6cda3 | 1369 | |
f73dda09 JA |
1370 | # |
1371 | # Report the --help message. | |
1372 | # | |
1373 | if test "$ac_init_help" = "long"; then | |
1374 | # Omit some internal or obsolete options to make the list less imposing. | |
1375 | # This message is too long to be a string in the A/UX 3.1 sh. | |
a82a04b3 | 1376 | cat <<_ACEOF |
e192f341 | 1377 | \`configure' configures bash 4.2-maint to adapt to many kinds of systems. |
ccc6cda3 | 1378 | |
f73dda09 | 1379 | Usage: $0 [OPTION]... [VAR=VALUE]... |
ccc6cda3 | 1380 | |
f73dda09 JA |
1381 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
1382 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
1383 | ||
1384 | Defaults for the options are specified in brackets. | |
ccc6cda3 | 1385 | |
f73dda09 JA |
1386 | Configuration: |
1387 | -h, --help display this help and exit | |
1388 | --help=short display options specific to this package | |
1389 | --help=recursive display the short help of all the included packages | |
1390 | -V, --version display version information and exit | |
7f947b68 | 1391 | -q, --quiet, --silent do not print \`checking ...' messages |
f73dda09 JA |
1392 | --cache-file=FILE cache test results in FILE [disabled] |
1393 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1394 | -n, --no-create do not create output files | |
1395 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
ccc6cda3 | 1396 | |
f73dda09 JA |
1397 | Installation directories: |
1398 | --prefix=PREFIX install architecture-independent files in PREFIX | |
dd4f3dd8 | 1399 | [$ac_default_prefix] |
f73dda09 | 1400 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
dd4f3dd8 | 1401 | [PREFIX] |
ccc6cda3 | 1402 | |
f73dda09 JA |
1403 | By default, \`make install' will install all the files in |
1404 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1405 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1406 | for instance \`--prefix=\$HOME'. | |
ccc6cda3 | 1407 | |
f73dda09 | 1408 | For better control, use the options below. |
ccc6cda3 | 1409 | |
f73dda09 | 1410 | Fine tuning of the installation directories: |
dd4f3dd8 CR |
1411 | --bindir=DIR user executables [EPREFIX/bin] |
1412 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1413 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1414 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1415 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1416 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1417 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1418 | --includedir=DIR C header files [PREFIX/include] | |
1419 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1420 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1421 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1422 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1423 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1424 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1425 | --docdir=DIR documentation root [DATAROOTDIR/doc/bash] | |
1426 | --htmldir=DIR html documentation [DOCDIR] | |
1427 | --dvidir=DIR dvi documentation [DOCDIR] | |
1428 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1429 | --psdir=DIR ps documentation [DOCDIR] | |
a82a04b3 | 1430 | _ACEOF |
f73dda09 | 1431 | |
a82a04b3 | 1432 | cat <<\_ACEOF |
f73dda09 JA |
1433 | |
1434 | System types: | |
1435 | --build=BUILD configure for building on BUILD [guessed] | |
a82a04b3 CR |
1436 | --host=HOST cross-compile to build programs to run on HOST [BUILD] |
1437 | _ACEOF | |
ccc6cda3 | 1438 | fi |
ccc6cda3 | 1439 | |
f73dda09 JA |
1440 | if test -n "$ac_init_help"; then |
1441 | case $ac_init_help in | |
e192f341 | 1442 | short | recursive ) echo "Configuration of bash 4.2-maint:";; |
f73dda09 | 1443 | esac |
a82a04b3 | 1444 | cat <<\_ACEOF |
ccc6cda3 | 1445 | |
f73dda09 | 1446 | Optional Features: |
dd4f3dd8 | 1447 | --disable-option-checking ignore unrecognized --enable/--with options |
f73dda09 JA |
1448 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
1449 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
7117c2d2 JA |
1450 | --enable-minimal-config a minimal sh-like configuration |
1451 | --enable-alias enable shell aliases | |
1452 | --enable-arith-for-command | |
1453 | enable arithmetic for command | |
1454 | --enable-array-variables | |
1455 | include shell array variables | |
1456 | --enable-bang-history turn on csh-style history substitution | |
1457 | --enable-brace-expansion | |
1458 | include brace expansion | |
fdf670ea CR |
1459 | --enable-casemod-attributes |
1460 | include case-modifying variable attributes | |
1461 | --enable-casemod-expansions | |
1462 | include case-modifying word expansions | |
7117c2d2 JA |
1463 | --enable-command-timing enable the time reserved word and command timing |
1464 | --enable-cond-command enable the conditional command | |
35ee8ea0 | 1465 | --enable-cond-regexp enable extended regular expression matching in |
d3a24ed2 | 1466 | conditional commands |
09767ff0 CR |
1467 | --enable-coprocesses enable coprocess support and the coproc reserved |
1468 | word | |
d3a24ed2 | 1469 | --enable-debugger enable support for bash debugger |
f14388d3 CR |
1470 | --enable-direxpand-default |
1471 | enable the direxpand shell option by default | |
7117c2d2 JA |
1472 | --enable-directory-stack |
1473 | enable builtins pushd/popd/dirs | |
1474 | --enable-disabled-builtins | |
1475 | allow disabled builtins to still be invoked | |
1476 | --enable-dparen-arithmetic | |
1477 | include ((...)) command | |
1478 | --enable-extended-glob include ksh-style extended pattern matching | |
691aebcb CR |
1479 | --enable-extended-glob-default |
1480 | force extended pattern matching to be enabled by | |
1481 | default | |
7117c2d2 JA |
1482 | --enable-help-builtin include the help builtin |
1483 | --enable-history turn on command history | |
1484 | --enable-job-control enable job control features | |
d3a24ed2 | 1485 | --enable-multibyte enable multibyte characters if OS supports them |
7117c2d2 JA |
1486 | --enable-net-redirections |
1487 | enable /dev/tcp/host/port redirection | |
1488 | --enable-process-substitution | |
1489 | enable process substitution | |
1490 | --enable-progcomp enable programmable completion and the complete | |
1491 | builtin | |
1492 | --enable-prompt-string-decoding | |
1493 | turn on escape character decoding in prompts | |
1494 | --enable-readline turn on command line editing | |
1495 | --enable-restricted enable a restricted shell | |
1496 | --enable-select include select command | |
1497 | --enable-separate-helpfiles | |
1498 | use external files for help builtin documentation | |
01ed5ba4 CR |
1499 | --enable-single-help-strings |
1500 | store help documentation as a single string to ease | |
1501 | translation | |
7790f917 CR |
1502 | --enable-strict-posix-default |
1503 | configure bash to be posix-conformant by default | |
7117c2d2 JA |
1504 | --enable-usg-echo-default |
1505 | a synonym for --enable-xpg-echo-default | |
1506 | --enable-xpg-echo-default | |
1507 | make the echo builtin expand escape sequences by | |
1508 | default | |
1509 | --enable-mem-scramble scramble memory on calls to malloc and free | |
1510 | --enable-profiling allow profiling with gprof | |
1511 | --enable-static-link link bash statically, for use as a root shell | |
f73dda09 | 1512 | --disable-largefile omit support for large files |
5e13499c CR |
1513 | --disable-nls do not use Native Language Support |
1514 | --disable-rpath do not hardcode runtime library paths | |
f73dda09 JA |
1515 | |
1516 | Optional Packages: | |
1517 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
1518 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
7117c2d2 JA |
1519 | --with-afs if you are running AFS |
1520 | --with-bash-malloc use the Bash version of malloc | |
1521 | --with-curses use the curses library instead of the termcap | |
1522 | library | |
1523 | --with-gnu-malloc synonym for --with-bash-malloc | |
1524 | --with-installed-readline | |
1525 | use a version of the readline library that is | |
1526 | already installed | |
1527 | --with-purecov configure to postprocess with pure coverage | |
1528 | --with-purify configure to postprocess with purify | |
5e13499c CR |
1529 | --with-gnu-ld assume the C compiler uses GNU ld default=no |
1530 | --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib | |
1531 | --without-libiconv-prefix don't search for libiconv in includedir and libdir | |
1532 | --with-included-gettext use the GNU gettext library included here | |
1533 | --with-libintl-prefix[=DIR] search for libintl in DIR/include and DIR/lib | |
1534 | --without-libintl-prefix don't search for libintl in includedir and libdir | |
f73dda09 JA |
1535 | |
1536 | Some influential environment variables: | |
d3a24ed2 CR |
1537 | DEBUGGER_START_FILE |
1538 | location of bash debugger initialization file | |
7610e0c5 CR |
1539 | CC_FOR_BUILD |
1540 | C compiler used when compiling binaries used only at build time | |
1541 | CFLAGS_FOR_BUILD | |
1542 | Compliation options (CFLAGS) used when compiling binaries used | |
1543 | only at build time | |
1544 | LDFLAGS_FOR_BUILD | |
1545 | Linker options (LDFLAGS) used when compiling binaries used only | |
1546 | at build time | |
1547 | CPPFLAGS_FOR_BUILD | |
1548 | C preprocessor options (CPPFLAGS) used when compiling binaries | |
1549 | used only at build time | |
f73dda09 JA |
1550 | CC C compiler command |
1551 | CFLAGS C compiler flags | |
1552 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1553 | nonstandard directory <lib dir> | |
dd4f3dd8 | 1554 | LIBS libraries to pass to the linker, e.g. -l<library> |
7f947b68 | 1555 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
b709b946 | 1556 | you have headers in a nonstandard directory <include dir> |
f73dda09 | 1557 | CPP C preprocessor |
7f947b68 CR |
1558 | YACC The `Yet Another Compiler Compiler' implementation to use. |
1559 | Defaults to the first program found out of: `bison -y', `byacc', | |
1560 | `yacc'. | |
b709b946 CR |
1561 | YFLAGS The list of arguments that will be passed by default to $YACC. |
1562 | This script will default YFLAGS to the empty string to avoid a | |
1563 | default value of `-d' given by some make applications. | |
f73dda09 JA |
1564 | |
1565 | Use these variables to override the choices made by `configure' or to help | |
1566 | it to find libraries and programs with nonstandard names/locations. | |
1567 | ||
1568 | Report bugs to <bug-bash@gnu.org>. | |
a82a04b3 | 1569 | _ACEOF |
b709b946 | 1570 | ac_status=$? |
f73dda09 JA |
1571 | fi |
1572 | ||
1573 | if test "$ac_init_help" = "recursive"; then | |
1574 | # If there are subdirs, report their specific --help. | |
a82a04b3 | 1575 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
dd4f3dd8 CR |
1576 | test -d "$ac_dir" || |
1577 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1578 | continue | |
a82a04b3 CR |
1579 | ac_builddir=. |
1580 | ||
b709b946 CR |
1581 | case "$ac_dir" in |
1582 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1583 | *) | |
dd4f3dd8 | 1584 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
b709b946 | 1585 | # A ".." for each directory in $ac_dir_suffix. |
dd4f3dd8 | 1586 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
b709b946 CR |
1587 | case $ac_top_builddir_sub in |
1588 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1589 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1590 | esac ;; | |
1591 | esac | |
1592 | ac_abs_top_builddir=$ac_pwd | |
1593 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1594 | # for backward compatibility: | |
1595 | ac_top_builddir=$ac_top_build_prefix | |
a82a04b3 CR |
1596 | |
1597 | case $srcdir in | |
b709b946 | 1598 | .) # We are building in place. |
a82a04b3 | 1599 | ac_srcdir=. |
b709b946 CR |
1600 | ac_top_srcdir=$ac_top_builddir_sub |
1601 | ac_abs_top_srcdir=$ac_pwd ;; | |
1602 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
a82a04b3 | 1603 | ac_srcdir=$srcdir$ac_dir_suffix; |
b709b946 CR |
1604 | ac_top_srcdir=$srcdir |
1605 | ac_abs_top_srcdir=$srcdir ;; | |
1606 | *) # Relative name. | |
1607 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1608 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1609 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
5e4a95c7 | 1610 | esac |
b709b946 CR |
1611 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
1612 | ||
1613 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1614 | # Check for guested configure. | |
1615 | if test -f "$ac_srcdir/configure.gnu"; then | |
1616 | echo && | |
1617 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1618 | elif test -f "$ac_srcdir/configure"; then | |
1619 | echo && | |
1620 | $SHELL "$ac_srcdir/configure" --help=recursive | |
f73dda09 | 1621 | else |
dd4f3dd8 | 1622 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
b709b946 CR |
1623 | fi || ac_status=$? |
1624 | cd "$ac_pwd" || { ac_status=$?; break; } | |
f73dda09 JA |
1625 | done |
1626 | fi | |
ccc6cda3 | 1627 | |
b709b946 | 1628 | test -n "$ac_init_help" && exit $ac_status |
f73dda09 | 1629 | if $ac_init_version; then |
a82a04b3 | 1630 | cat <<\_ACEOF |
e192f341 | 1631 | bash configure 4.2-maint |
7f947b68 | 1632 | generated by GNU Autoconf 2.68 |
ccc6cda3 | 1633 | |
7f947b68 | 1634 | Copyright (C) 2010 Free Software Foundation, Inc. |
f73dda09 JA |
1635 | This configure script is free software; the Free Software Foundation |
1636 | gives unlimited permission to copy, distribute and modify it. | |
a82a04b3 | 1637 | _ACEOF |
b709b946 | 1638 | exit |
f73dda09 | 1639 | fi |
ccc6cda3 | 1640 | |
7f947b68 CR |
1641 | ## ------------------------ ## |
1642 | ## Autoconf initialization. ## | |
1643 | ## ------------------------ ## | |
2dead0c4 | 1644 | |
7f947b68 CR |
1645 | # ac_fn_c_try_compile LINENO |
1646 | # -------------------------- | |
1647 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1648 | ac_fn_c_try_compile () | |
1649 | { | |
1650 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1651 | rm -f conftest.$ac_objext | |
1652 | if { { ac_try="$ac_compile" | |
1653 | case "(($ac_try" in | |
1654 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1655 | *) ac_try_echo=$ac_try;; | |
1656 | esac | |
1657 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1658 | $as_echo "$ac_try_echo"; } >&5 | |
1659 | (eval "$ac_compile") 2>conftest.err | |
1660 | ac_status=$? | |
1661 | if test -s conftest.err; then | |
1662 | grep -v '^ *+' conftest.err >conftest.er1 | |
1663 | cat conftest.er1 >&5 | |
1664 | mv -f conftest.er1 conftest.err | |
1665 | fi | |
1666 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1667 | test $ac_status = 0; } && { | |
1668 | test -z "$ac_c_werror_flag" || | |
1669 | test ! -s conftest.err | |
1670 | } && test -s conftest.$ac_objext; then : | |
1671 | ac_retval=0 | |
1672 | else | |
1673 | $as_echo "$as_me: failed program was:" >&5 | |
1674 | sed 's/^/| /' conftest.$ac_ext >&5 | |
2dead0c4 | 1675 | |
7f947b68 CR |
1676 | ac_retval=1 |
1677 | fi | |
1678 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1679 | as_fn_set_status $ac_retval | |
1680 | ||
1681 | } # ac_fn_c_try_compile | |
1682 | ||
1683 | # ac_fn_c_try_link LINENO | |
1684 | # ----------------------- | |
1685 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
1686 | ac_fn_c_try_link () | |
71412226 | 1687 | { |
7f947b68 CR |
1688 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
1689 | rm -f conftest.$ac_objext conftest$ac_exeext | |
1690 | if { { ac_try="$ac_link" | |
1691 | case "(($ac_try" in | |
1692 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1693 | *) ac_try_echo=$ac_try;; | |
1694 | esac | |
1695 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1696 | $as_echo "$ac_try_echo"; } >&5 | |
1697 | (eval "$ac_link") 2>conftest.err | |
1698 | ac_status=$? | |
1699 | if test -s conftest.err; then | |
1700 | grep -v '^ *+' conftest.err >conftest.er1 | |
1701 | cat conftest.er1 >&5 | |
1702 | mv -f conftest.er1 conftest.err | |
1703 | fi | |
1704 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1705 | test $ac_status = 0; } && { | |
1706 | test -z "$ac_c_werror_flag" || | |
1707 | test ! -s conftest.err | |
1708 | } && test -s conftest$ac_exeext && { | |
1709 | test "$cross_compiling" = yes || | |
1710 | $as_test_x conftest$ac_exeext | |
1711 | }; then : | |
1712 | ac_retval=0 | |
1713 | else | |
1714 | $as_echo "$as_me: failed program was:" >&5 | |
1715 | sed 's/^/| /' conftest.$ac_ext >&5 | |
bb70624e | 1716 | |
7f947b68 CR |
1717 | ac_retval=1 |
1718 | fi | |
1719 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information | |
1720 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
1721 | # interfere with the next link command; also delete a directory that is | |
1722 | # left behind by Apple's compiler. We do this before executing the actions. | |
1723 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1724 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1725 | as_fn_set_status $ac_retval | |
71412226 | 1726 | |
7f947b68 | 1727 | } # ac_fn_c_try_link |
71412226 | 1728 | |
7f947b68 CR |
1729 | # ac_fn_c_try_cpp LINENO |
1730 | # ---------------------- | |
1731 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
1732 | ac_fn_c_try_cpp () | |
1733 | { | |
1734 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1735 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
1736 | case "(($ac_try" in | |
1737 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1738 | *) ac_try_echo=$ac_try;; | |
1739 | esac | |
1740 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1741 | $as_echo "$ac_try_echo"; } >&5 | |
1742 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
1743 | ac_status=$? | |
1744 | if test -s conftest.err; then | |
1745 | grep -v '^ *+' conftest.err >conftest.er1 | |
1746 | cat conftest.er1 >&5 | |
1747 | mv -f conftest.er1 conftest.err | |
1748 | fi | |
1749 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1750 | test $ac_status = 0; } > conftest.i && { | |
1751 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || | |
1752 | test ! -s conftest.err | |
1753 | }; then : | |
1754 | ac_retval=0 | |
1755 | else | |
1756 | $as_echo "$as_me: failed program was:" >&5 | |
1757 | sed 's/^/| /' conftest.$ac_ext >&5 | |
a82a04b3 | 1758 | |
7f947b68 CR |
1759 | ac_retval=1 |
1760 | fi | |
1761 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1762 | as_fn_set_status $ac_retval | |
a82a04b3 | 1763 | |
7f947b68 | 1764 | } # ac_fn_c_try_cpp |
a82a04b3 | 1765 | |
7f947b68 CR |
1766 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
1767 | # ------------------------------------------------------- | |
1768 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
1769 | # the include files in INCLUDES and setting the cache variable VAR | |
1770 | # accordingly. | |
1771 | ac_fn_c_check_header_mongrel () | |
1772 | { | |
1773 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1774 | if eval \${$3+:} false; then : | |
1775 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1776 | $as_echo_n "checking for $2... " >&6; } | |
1777 | if eval \${$3+:} false; then : | |
1778 | $as_echo_n "(cached) " >&6 | |
1779 | fi | |
1780 | eval ac_res=\$$3 | |
1781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1782 | $as_echo "$ac_res" >&6; } | |
1783 | else | |
1784 | # Is the header compilable? | |
1785 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
1786 | $as_echo_n "checking $2 usability... " >&6; } | |
1787 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1788 | /* end confdefs.h. */ | |
1789 | $4 | |
1790 | #include <$2> | |
abe2eb5b | 1791 | _ACEOF |
7f947b68 CR |
1792 | if ac_fn_c_try_compile "$LINENO"; then : |
1793 | ac_header_compiler=yes | |
1794 | else | |
1795 | ac_header_compiler=no | |
1796 | fi | |
1797 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
1799 | $as_echo "$ac_header_compiler" >&6; } | |
c920c360 | 1800 | |
7f947b68 CR |
1801 | # Is the header present? |
1802 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
1803 | $as_echo_n "checking $2 presence... " >&6; } | |
1804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1805 | /* end confdefs.h. */ | |
1806 | #include <$2> | |
1807 | _ACEOF | |
1808 | if ac_fn_c_try_cpp "$LINENO"; then : | |
1809 | ac_header_preproc=yes | |
1810 | else | |
1811 | ac_header_preproc=no | |
1812 | fi | |
1813 | rm -f conftest.err conftest.i conftest.$ac_ext | |
1814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 | |
1815 | $as_echo "$ac_header_preproc" >&6; } | |
a82a04b3 | 1816 | |
7f947b68 CR |
1817 | # So? What about this header? |
1818 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
1819 | yes:no: ) | |
1820 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
1821 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
1822 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1823 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1824 | ;; | |
1825 | no:yes:* ) | |
1826 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
1827 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
1828 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
1829 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
1830 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
1831 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
1832 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
1833 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
1834 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1835 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1836 | ( $as_echo "## ------------------------------- ## | |
1837 | ## Report this to bug-bash@gnu.org ## | |
1838 | ## ------------------------------- ##" | |
1839 | ) | sed "s/^/$as_me: WARNING: /" >&2 | |
1840 | ;; | |
1841 | esac | |
1842 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1843 | $as_echo_n "checking for $2... " >&6; } | |
1844 | if eval \${$3+:} false; then : | |
1845 | $as_echo_n "(cached) " >&6 | |
1846 | else | |
1847 | eval "$3=\$ac_header_compiler" | |
1848 | fi | |
1849 | eval ac_res=\$$3 | |
1850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1851 | $as_echo "$ac_res" >&6; } | |
1852 | fi | |
1853 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
b709b946 | 1854 | |
7f947b68 | 1855 | } # ac_fn_c_check_header_mongrel |
ccc6cda3 | 1856 | |
7f947b68 CR |
1857 | # ac_fn_c_try_run LINENO |
1858 | # ---------------------- | |
1859 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
1860 | # that executables *can* be run. | |
1861 | ac_fn_c_try_run () | |
1862 | { | |
1863 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1864 | if { { ac_try="$ac_link" | |
1865 | case "(($ac_try" in | |
1866 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1867 | *) ac_try_echo=$ac_try;; | |
1868 | esac | |
1869 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1870 | $as_echo "$ac_try_echo"; } >&5 | |
1871 | (eval "$ac_link") 2>&5 | |
1872 | ac_status=$? | |
1873 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1874 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
1875 | { { case "(($ac_try" in | |
1876 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1877 | *) ac_try_echo=$ac_try;; | |
1878 | esac | |
1879 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1880 | $as_echo "$ac_try_echo"; } >&5 | |
1881 | (eval "$ac_try") 2>&5 | |
1882 | ac_status=$? | |
1883 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1884 | test $ac_status = 0; }; }; then : | |
1885 | ac_retval=0 | |
1886 | else | |
1887 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
1888 | $as_echo "$as_me: failed program was:" >&5 | |
1889 | sed 's/^/| /' conftest.$ac_ext >&5 | |
d166f048 | 1890 | |
7f947b68 CR |
1891 | ac_retval=$ac_status |
1892 | fi | |
1893 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1894 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1895 | as_fn_set_status $ac_retval | |
b709b946 | 1896 | |
7f947b68 | 1897 | } # ac_fn_c_try_run |
d166f048 | 1898 | |
7f947b68 CR |
1899 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
1900 | # ------------------------------------------------------- | |
1901 | # Tests whether HEADER exists and can be compiled using the include files in | |
1902 | # INCLUDES, setting the cache variable VAR accordingly. | |
1903 | ac_fn_c_check_header_compile () | |
1904 | { | |
1905 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1906 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1907 | $as_echo_n "checking for $2... " >&6; } | |
1908 | if eval \${$3+:} false; then : | |
1909 | $as_echo_n "(cached) " >&6 | |
1910 | else | |
1911 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1912 | /* end confdefs.h. */ | |
1913 | $4 | |
1914 | #include <$2> | |
2dead0c4 | 1915 | _ACEOF |
7f947b68 CR |
1916 | if ac_fn_c_try_compile "$LINENO"; then : |
1917 | eval "$3=yes" | |
1918 | else | |
1919 | eval "$3=no" | |
1920 | fi | |
1921 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1922 | fi | |
1923 | eval ac_res=\$$3 | |
1924 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1925 | $as_echo "$ac_res" >&6; } | |
1926 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
a82a04b3 | 1927 | |
7f947b68 | 1928 | } # ac_fn_c_check_header_compile |
ccc6cda3 | 1929 | |
7f947b68 CR |
1930 | # ac_fn_c_check_func LINENO FUNC VAR |
1931 | # ---------------------------------- | |
1932 | # Tests whether FUNC exists, setting the cache variable VAR accordingly | |
1933 | ac_fn_c_check_func () | |
1934 | { | |
1935 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1937 | $as_echo_n "checking for $2... " >&6; } | |
1938 | if eval \${$3+:} false; then : | |
1939 | $as_echo_n "(cached) " >&6 | |
1940 | else | |
1941 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1942 | /* end confdefs.h. */ | |
1943 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. | |
1944 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ | |
1945 | #define $2 innocuous_$2 | |
ccc6cda3 | 1946 | |
7f947b68 CR |
1947 | /* System header to define __stub macros and hopefully few prototypes, |
1948 | which can conflict with char $2 (); below. | |
1949 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
1950 | <limits.h> exists even on freestanding compilers. */ | |
71412226 | 1951 | |
7f947b68 CR |
1952 | #ifdef __STDC__ |
1953 | # include <limits.h> | |
1954 | #else | |
1955 | # include <assert.h> | |
1956 | #endif | |
ccc6cda3 | 1957 | |
7f947b68 | 1958 | #undef $2 |
71412226 | 1959 | |
7f947b68 CR |
1960 | /* Override any GCC internal prototype to avoid an error. |
1961 | Use char because int might match the return type of a GCC | |
1962 | builtin and then its argument prototype would still apply. */ | |
1963 | #ifdef __cplusplus | |
1964 | extern "C" | |
1965 | #endif | |
1966 | char $2 (); | |
1967 | /* The GNU C library defines this for functions which it implements | |
1968 | to always fail with ENOSYS. Some functions are actually named | |
1969 | something starting with __ and the normal name is an alias. */ | |
1970 | #if defined __stub_$2 || defined __stub___$2 | |
1971 | choke me | |
1972 | #endif | |
71412226 | 1973 | |
7f947b68 CR |
1974 | int |
1975 | main () | |
1976 | { | |
1977 | return $2 (); | |
1978 | ; | |
1979 | return 0; | |
1980 | } | |
1981 | _ACEOF | |
1982 | if ac_fn_c_try_link "$LINENO"; then : | |
1983 | eval "$3=yes" | |
2dead0c4 | 1984 | else |
7f947b68 | 1985 | eval "$3=no" |
2dead0c4 | 1986 | fi |
7f947b68 CR |
1987 | rm -f core conftest.err conftest.$ac_objext \ |
1988 | conftest$ac_exeext conftest.$ac_ext | |
2dead0c4 | 1989 | fi |
7f947b68 CR |
1990 | eval ac_res=\$$3 |
1991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1992 | $as_echo "$ac_res" >&6; } | |
1993 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
71412226 | 1994 | |
7f947b68 | 1995 | } # ac_fn_c_check_func |
71412226 | 1996 | |
7f947b68 CR |
1997 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
1998 | # ------------------------------------------- | |
1999 | # Tests whether TYPE exists after having included INCLUDES, setting cache | |
2000 | # variable VAR accordingly. | |
2001 | ac_fn_c_check_type () | |
2002 | { | |
2003 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2004 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2005 | $as_echo_n "checking for $2... " >&6; } | |
2006 | if eval \${$3+:} false; then : | |
2007 | $as_echo_n "(cached) " >&6 | |
2008 | else | |
2009 | eval "$3=no" | |
2010 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2011 | /* end confdefs.h. */ | |
2012 | $4 | |
2013 | int | |
2014 | main () | |
2015 | { | |
2016 | if (sizeof ($2)) | |
2017 | return 0; | |
2018 | ; | |
2019 | return 0; | |
2020 | } | |
2021 | _ACEOF | |
2022 | if ac_fn_c_try_compile "$LINENO"; then : | |
2023 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2024 | /* end confdefs.h. */ | |
2025 | $4 | |
2026 | int | |
2027 | main () | |
2028 | { | |
2029 | if (sizeof (($2))) | |
2030 | return 0; | |
2031 | ; | |
2032 | return 0; | |
2033 | } | |
2034 | _ACEOF | |
2035 | if ac_fn_c_try_compile "$LINENO"; then : | |
71412226 | 2036 | |
7f947b68 CR |
2037 | else |
2038 | eval "$3=yes" | |
2039 | fi | |
2040 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2041 | fi | |
2042 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2043 | fi | |
2044 | eval ac_res=\$$3 | |
2045 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2046 | $as_echo "$ac_res" >&6; } | |
2047 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
71412226 | 2048 | |
7f947b68 | 2049 | } # ac_fn_c_check_type |
71412226 | 2050 | |
7f947b68 CR |
2051 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
2052 | # --------------------------------------------- | |
2053 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR | |
2054 | # accordingly. | |
2055 | ac_fn_c_check_decl () | |
2056 | { | |
2057 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2058 | as_decl_name=`echo $2|sed 's/ *(.*//'` | |
2059 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` | |
2060 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 | |
2061 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } | |
2062 | if eval \${$3+:} false; then : | |
2063 | $as_echo_n "(cached) " >&6 | |
2064 | else | |
2065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2066 | /* end confdefs.h. */ | |
2067 | $4 | |
2068 | int | |
2069 | main () | |
2070 | { | |
2071 | #ifndef $as_decl_name | |
2072 | #ifdef __cplusplus | |
2073 | (void) $as_decl_use; | |
2074 | #else | |
2075 | (void) $as_decl_name; | |
2076 | #endif | |
2077 | #endif | |
7610e0c5 | 2078 | |
7f947b68 CR |
2079 | ; |
2080 | return 0; | |
2081 | } | |
2082 | _ACEOF | |
2083 | if ac_fn_c_try_compile "$LINENO"; then : | |
2084 | eval "$3=yes" | |
2085 | else | |
2086 | eval "$3=no" | |
2087 | fi | |
2088 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2089 | fi | |
2090 | eval ac_res=\$$3 | |
2091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2092 | $as_echo "$ac_res" >&6; } | |
2093 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
7610e0c5 | 2094 | |
7f947b68 | 2095 | } # ac_fn_c_check_decl |
7610e0c5 | 2096 | |
7f947b68 CR |
2097 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
2098 | # -------------------------------------------- | |
2099 | # Tries to find the compile-time value of EXPR in a program that includes | |
2100 | # INCLUDES, setting VAR accordingly. Returns whether the value could be | |
2101 | # computed | |
2102 | ac_fn_c_compute_int () | |
2103 | { | |
2104 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2105 | if test "$cross_compiling" = yes; then | |
2106 | # Depending upon the size, compute the lo and hi bounds. | |
2107 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2108 | /* end confdefs.h. */ | |
2109 | $4 | |
2110 | int | |
2111 | main () | |
2112 | { | |
2113 | static int test_array [1 - 2 * !(($2) >= 0)]; | |
2114 | test_array [0] = 0 | |
7610e0c5 | 2115 | |
7f947b68 CR |
2116 | ; |
2117 | return 0; | |
2118 | } | |
2119 | _ACEOF | |
2120 | if ac_fn_c_try_compile "$LINENO"; then : | |
2121 | ac_lo=0 ac_mid=0 | |
2122 | while :; do | |
2123 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2124 | /* end confdefs.h. */ | |
2125 | $4 | |
2126 | int | |
2127 | main () | |
2128 | { | |
2129 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2130 | test_array [0] = 0 | |
c920c360 | 2131 | |
7f947b68 CR |
2132 | ; |
2133 | return 0; | |
2134 | } | |
2135 | _ACEOF | |
2136 | if ac_fn_c_try_compile "$LINENO"; then : | |
2137 | ac_hi=$ac_mid; break | |
2138 | else | |
2139 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val | |
2140 | if test $ac_lo -le $ac_mid; then | |
2141 | ac_lo= ac_hi= | |
2142 | break | |
2143 | fi | |
2144 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val | |
2145 | fi | |
2146 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2147 | done | |
2148 | else | |
2149 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2150 | /* end confdefs.h. */ | |
2151 | $4 | |
2152 | int | |
2153 | main () | |
2154 | { | |
2155 | static int test_array [1 - 2 * !(($2) < 0)]; | |
2156 | test_array [0] = 0 | |
7610e0c5 | 2157 | |
7f947b68 CR |
2158 | ; |
2159 | return 0; | |
2160 | } | |
2161 | _ACEOF | |
2162 | if ac_fn_c_try_compile "$LINENO"; then : | |
2163 | ac_hi=-1 ac_mid=-1 | |
2164 | while :; do | |
2165 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2166 | /* end confdefs.h. */ | |
2167 | $4 | |
2168 | int | |
2169 | main () | |
2170 | { | |
2171 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; | |
2172 | test_array [0] = 0 | |
71412226 | 2173 | |
7f947b68 CR |
2174 | ; |
2175 | return 0; | |
2176 | } | |
2177 | _ACEOF | |
2178 | if ac_fn_c_try_compile "$LINENO"; then : | |
2179 | ac_lo=$ac_mid; break | |
2180 | else | |
2181 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val | |
2182 | if test $ac_mid -le $ac_hi; then | |
2183 | ac_lo= ac_hi= | |
2184 | break | |
2185 | fi | |
2186 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val | |
2187 | fi | |
2188 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2189 | done | |
2190 | else | |
2191 | ac_lo= ac_hi= | |
2192 | fi | |
2193 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2194 | fi | |
2195 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2196 | # Binary search between lo and hi bounds. | |
2197 | while test "x$ac_lo" != "x$ac_hi"; do | |
2198 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val | |
2199 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2200 | /* end confdefs.h. */ | |
2201 | $4 | |
2202 | int | |
2203 | main () | |
2204 | { | |
2205 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2206 | test_array [0] = 0 | |
c920c360 | 2207 | |
7f947b68 CR |
2208 | ; |
2209 | return 0; | |
2210 | } | |
2211 | _ACEOF | |
2212 | if ac_fn_c_try_compile "$LINENO"; then : | |
2213 | ac_hi=$ac_mid | |
2214 | else | |
2215 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val | |
2216 | fi | |
2217 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2218 | done | |
2219 | case $ac_lo in #(( | |
2220 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; | |
2221 | '') ac_retval=1 ;; | |
2222 | esac | |
2223 | else | |
2224 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2225 | /* end confdefs.h. */ | |
2226 | $4 | |
2227 | static long int longval () { return $2; } | |
2228 | static unsigned long int ulongval () { return $2; } | |
2229 | #include <stdio.h> | |
2230 | #include <stdlib.h> | |
2231 | int | |
2232 | main () | |
2233 | { | |
71412226 | 2234 | |
7f947b68 CR |
2235 | FILE *f = fopen ("conftest.val", "w"); |
2236 | if (! f) | |
2237 | return 1; | |
2238 | if (($2) < 0) | |
2239 | { | |
2240 | long int i = longval (); | |
2241 | if (i != ($2)) | |
2242 | return 1; | |
2243 | fprintf (f, "%ld", i); | |
2244 | } | |
2245 | else | |
2246 | { | |
2247 | unsigned long int i = ulongval (); | |
2248 | if (i != ($2)) | |
2249 | return 1; | |
2250 | fprintf (f, "%lu", i); | |
2251 | } | |
2252 | /* Do not output a trailing newline, as this causes \r\n confusion | |
2253 | on some platforms. */ | |
2254 | return ferror (f) || fclose (f) != 0; | |
c920c360 | 2255 | |
7f947b68 CR |
2256 | ; |
2257 | return 0; | |
2258 | } | |
2259 | _ACEOF | |
2260 | if ac_fn_c_try_run "$LINENO"; then : | |
2261 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 | |
2262 | else | |
2263 | ac_retval=1 | |
2264 | fi | |
2265 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
2266 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2267 | rm -f conftest.val | |
c920c360 | 2268 | |
7f947b68 CR |
2269 | fi |
2270 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
2271 | as_fn_set_status $ac_retval | |
c920c360 | 2272 | |
7f947b68 | 2273 | } # ac_fn_c_compute_int |
c920c360 | 2274 | |
7f947b68 CR |
2275 | # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES |
2276 | # ---------------------------------------------------- | |
2277 | # Tries to find if the field MEMBER exists in type AGGR, after including | |
2278 | # INCLUDES, setting cache variable VAR accordingly. | |
2279 | ac_fn_c_check_member () | |
2280 | { | |
2281 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2282 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5 | |
2283 | $as_echo_n "checking for $2.$3... " >&6; } | |
2284 | if eval \${$4+:} false; then : | |
2dead0c4 CR |
2285 | $as_echo_n "(cached) " >&6 |
2286 | else | |
7f947b68 CR |
2287 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2288 | /* end confdefs.h. */ | |
2289 | $5 | |
2290 | int | |
2291 | main () | |
2292 | { | |
2293 | static $2 ac_aggr; | |
2294 | if (ac_aggr.$3) | |
2295 | return 0; | |
2296 | ; | |
2297 | return 0; | |
2298 | } | |
2299 | _ACEOF | |
2300 | if ac_fn_c_try_compile "$LINENO"; then : | |
2301 | eval "$4=yes" | |
2dead0c4 | 2302 | else |
7f947b68 CR |
2303 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2304 | /* end confdefs.h. */ | |
2305 | $5 | |
2306 | int | |
2307 | main () | |
2308 | { | |
2309 | static $2 ac_aggr; | |
2310 | if (sizeof ac_aggr.$3) | |
2311 | return 0; | |
2312 | ; | |
2313 | return 0; | |
2314 | } | |
2315 | _ACEOF | |
2316 | if ac_fn_c_try_compile "$LINENO"; then : | |
2317 | eval "$4=yes" | |
2dead0c4 | 2318 | else |
7f947b68 | 2319 | eval "$4=no" |
c920c360 | 2320 | fi |
7f947b68 | 2321 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
c920c360 | 2322 | fi |
7f947b68 | 2323 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2dead0c4 | 2324 | fi |
7f947b68 CR |
2325 | eval ac_res=\$$4 |
2326 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2327 | $as_echo "$ac_res" >&6; } | |
2328 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
c920c360 | 2329 | |
7f947b68 CR |
2330 | } # ac_fn_c_check_member |
2331 | cat >config.log <<_ACEOF | |
2332 | This file contains any messages produced by compilers while | |
2333 | running configure, to aid debugging if configure makes a mistake. | |
c920c360 | 2334 | |
7f947b68 CR |
2335 | It was created by bash $as_me 4.2-maint, which was |
2336 | generated by GNU Autoconf 2.68. Invocation command line was | |
c920c360 | 2337 | |
7f947b68 | 2338 | $ $0 $@ |
c920c360 | 2339 | |
7f947b68 CR |
2340 | _ACEOF |
2341 | exec 5>>config.log | |
2342 | { | |
2343 | cat <<_ASUNAME | |
2344 | ## --------- ## | |
2345 | ## Platform. ## | |
2346 | ## --------- ## | |
c920c360 | 2347 | |
7f947b68 CR |
2348 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
2349 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
2350 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
2351 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
2352 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
c920c360 | 2353 | |
7f947b68 CR |
2354 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
2355 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
2dead0c4 | 2356 | |
7f947b68 CR |
2357 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
2358 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
2359 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
2360 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
2361 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
2362 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
2363 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
c920c360 | 2364 | |
7f947b68 | 2365 | _ASUNAME |
c920c360 | 2366 | |
7f947b68 CR |
2367 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2368 | for as_dir in $PATH | |
2369 | do | |
2370 | IFS=$as_save_IFS | |
2371 | test -z "$as_dir" && as_dir=. | |
2372 | $as_echo "PATH: $as_dir" | |
2373 | done | |
2374 | IFS=$as_save_IFS | |
2dead0c4 | 2375 | |
7f947b68 | 2376 | } >&5 |
c920c360 | 2377 | |
7f947b68 | 2378 | cat >&5 <<_ACEOF |
2dead0c4 | 2379 | |
2dead0c4 | 2380 | |
7f947b68 CR |
2381 | ## ----------- ## |
2382 | ## Core tests. ## | |
2383 | ## ----------- ## | |
2dead0c4 | 2384 | |
abe2eb5b | 2385 | _ACEOF |
2dead0c4 | 2386 | |
2dead0c4 | 2387 | |
7f947b68 CR |
2388 | # Keep a trace of the command line. |
2389 | # Strip out --no-create and --no-recursion so they do not pile up. | |
2390 | # Strip out --silent because we don't want to record it for future runs. | |
2391 | # Also quote any args containing shell meta-characters. | |
2392 | # Make two passes to allow for proper duplicate-argument suppression. | |
2393 | ac_configure_args= | |
2394 | ac_configure_args0= | |
2395 | ac_configure_args1= | |
2396 | ac_must_keep_next=false | |
2397 | for ac_pass in 1 2 | |
2398 | do | |
2399 | for ac_arg | |
2400 | do | |
2401 | case $ac_arg in | |
2402 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
2403 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
2404 | | -silent | --silent | --silen | --sile | --sil) | |
2405 | continue ;; | |
2406 | *\'*) | |
2407 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2408 | esac | |
2409 | case $ac_pass in | |
2410 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
2411 | 2) | |
2412 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
2413 | if test $ac_must_keep_next = true; then | |
2414 | ac_must_keep_next=false # Got value, back to normal. | |
2415 | else | |
2416 | case $ac_arg in | |
2417 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
2418 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
2419 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
2420 | | -with-* | --with-* | -without-* | --without-* | --x) | |
2421 | case "$ac_configure_args0 " in | |
2422 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
2423 | esac | |
2424 | ;; | |
2425 | -* ) ac_must_keep_next=true ;; | |
2426 | esac | |
2427 | fi | |
2428 | as_fn_append ac_configure_args " '$ac_arg'" | |
2429 | ;; | |
2430 | esac | |
2431 | done | |
2432 | done | |
2433 | { ac_configure_args0=; unset ac_configure_args0;} | |
2434 | { ac_configure_args1=; unset ac_configure_args1;} | |
c920c360 | 2435 | |
7f947b68 CR |
2436 | # When interrupted or exit'd, cleanup temporary files, and complete |
2437 | # config.log. We remove comments because anyway the quotes in there | |
2438 | # would cause problems or look ugly. | |
2439 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
2440 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
2441 | trap 'exit_status=$? | |
2442 | # Save into config.log some information that might help in debugging. | |
2443 | { | |
2444 | echo | |
2dead0c4 | 2445 | |
7f947b68 CR |
2446 | $as_echo "## ---------------- ## |
2447 | ## Cache variables. ## | |
2448 | ## ---------------- ##" | |
2449 | echo | |
2450 | # The following way of writing the cache mishandles newlines in values, | |
2451 | ( | |
2452 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
2453 | eval ac_val=\$$ac_var | |
2454 | case $ac_val in #( | |
2455 | *${as_nl}*) | |
2456 | case $ac_var in #( | |
2457 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
2458 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
2459 | esac | |
2460 | case $ac_var in #( | |
2461 | _ | IFS | as_nl) ;; #( | |
2462 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
2463 | *) { eval $ac_var=; unset $ac_var;} ;; | |
2464 | esac ;; | |
2465 | esac | |
2466 | done | |
2467 | (set) 2>&1 | | |
2468 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
2469 | *${as_nl}ac_space=\ *) | |
2470 | sed -n \ | |
2471 | "s/'\''/'\''\\\\'\'''\''/g; | |
2472 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
2473 | ;; #( | |
2474 | *) | |
2475 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
2476 | ;; | |
2477 | esac | | |
2478 | sort | |
2479 | ) | |
2480 | echo | |
c920c360 | 2481 | |
7f947b68 CR |
2482 | $as_echo "## ----------------- ## |
2483 | ## Output variables. ## | |
2484 | ## ----------------- ##" | |
2485 | echo | |
2486 | for ac_var in $ac_subst_vars | |
2487 | do | |
2488 | eval ac_val=\$$ac_var | |
2489 | case $ac_val in | |
2490 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2491 | esac | |
2492 | $as_echo "$ac_var='\''$ac_val'\''" | |
2493 | done | sort | |
2494 | echo | |
c920c360 | 2495 | |
7f947b68 CR |
2496 | if test -n "$ac_subst_files"; then |
2497 | $as_echo "## ------------------- ## | |
2498 | ## File substitutions. ## | |
2499 | ## ------------------- ##" | |
2500 | echo | |
2501 | for ac_var in $ac_subst_files | |
2502 | do | |
2503 | eval ac_val=\$$ac_var | |
2504 | case $ac_val in | |
2505 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2506 | esac | |
2507 | $as_echo "$ac_var='\''$ac_val'\''" | |
2508 | done | sort | |
2509 | echo | |
2510 | fi | |
c920c360 | 2511 | |
7f947b68 CR |
2512 | if test -s confdefs.h; then |
2513 | $as_echo "## ----------- ## | |
2514 | ## confdefs.h. ## | |
2515 | ## ----------- ##" | |
2516 | echo | |
2517 | cat confdefs.h | |
2518 | echo | |
2519 | fi | |
2520 | test "$ac_signal" != 0 && | |
2521 | $as_echo "$as_me: caught signal $ac_signal" | |
2522 | $as_echo "$as_me: exit $exit_status" | |
2523 | } >&5 | |
2524 | rm -f core *.core core.conftest.* && | |
2525 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
2526 | exit $exit_status | |
2527 | ' 0 | |
2528 | for ac_signal in 1 2 13 15; do | |
2529 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
2530 | done | |
2531 | ac_signal=0 | |
c920c360 | 2532 | |
7f947b68 CR |
2533 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
2534 | rm -f -r conftest* confdefs.h | |
2dead0c4 | 2535 | |
7f947b68 | 2536 | $as_echo "/* confdefs.h */" > confdefs.h |
2dead0c4 | 2537 | |
7f947b68 | 2538 | # Predefined preprocessor variables. |
2dead0c4 | 2539 | |
7f947b68 CR |
2540 | cat >>confdefs.h <<_ACEOF |
2541 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
2542 | _ACEOF | |
c920c360 | 2543 | |
7f947b68 CR |
2544 | cat >>confdefs.h <<_ACEOF |
2545 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2546 | _ACEOF | |
2dead0c4 | 2547 | |
7f947b68 CR |
2548 | cat >>confdefs.h <<_ACEOF |
2549 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
2550 | _ACEOF | |
c920c360 | 2551 | |
7f947b68 CR |
2552 | cat >>confdefs.h <<_ACEOF |
2553 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
2554 | _ACEOF | |
c920c360 | 2555 | |
7f947b68 CR |
2556 | cat >>confdefs.h <<_ACEOF |
2557 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2558 | _ACEOF | |
c920c360 | 2559 | |
7f947b68 CR |
2560 | cat >>confdefs.h <<_ACEOF |
2561 | #define PACKAGE_URL "$PACKAGE_URL" | |
2562 | _ACEOF | |
c920c360 | 2563 | |
c920c360 | 2564 | |
7f947b68 CR |
2565 | # Let the site file select an alternate cache file if it wants to. |
2566 | # Prefer an explicitly selected file to automatically selected ones. | |
2567 | ac_site_file1=NONE | |
2568 | ac_site_file2=NONE | |
2569 | if test -n "$CONFIG_SITE"; then | |
2570 | # We do not want a PATH search for config.site. | |
2571 | case $CONFIG_SITE in #(( | |
2572 | -*) ac_site_file1=./$CONFIG_SITE;; | |
2573 | */*) ac_site_file1=$CONFIG_SITE;; | |
2574 | *) ac_site_file1=./$CONFIG_SITE;; | |
2575 | esac | |
2576 | elif test "x$prefix" != xNONE; then | |
2577 | ac_site_file1=$prefix/share/config.site | |
2578 | ac_site_file2=$prefix/etc/config.site | |
2579 | else | |
2580 | ac_site_file1=$ac_default_prefix/share/config.site | |
2581 | ac_site_file2=$ac_default_prefix/etc/config.site | |
c920c360 | 2582 | fi |
7f947b68 CR |
2583 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" |
2584 | do | |
2585 | test "x$ac_site_file" = xNONE && continue | |
2586 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then | |
2587 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 | |
2588 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2589 | sed 's/^/| /' "$ac_site_file" >&5 | |
2590 | . "$ac_site_file" \ | |
2591 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2592 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2593 | as_fn_error $? "failed to load site script $ac_site_file | |
2594 | See \`config.log' for more details" "$LINENO" 5; } | |
2595 | fi | |
2596 | done | |
c920c360 | 2597 | |
7f947b68 CR |
2598 | if test -r "$cache_file"; then |
2599 | # Some versions of bash will fail to source /dev/null (special files | |
2600 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. | |
2601 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then | |
2602 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 | |
2603 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2604 | case $cache_file in | |
2605 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2606 | *) . "./$cache_file";; | |
2607 | esac | |
2608 | fi | |
2609 | else | |
2610 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 | |
2611 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2612 | >$cache_file | |
2dead0c4 | 2613 | fi |
c920c360 | 2614 | |
7f947b68 CR |
2615 | as_fn_append ac_header_list " stdlib.h" |
2616 | as_fn_append ac_header_list " unistd.h" | |
2617 | as_fn_append ac_header_list " sys/param.h" | |
2618 | as_fn_append ac_header_list " sys/time.h" | |
2619 | as_fn_append ac_func_list " alarm" | |
2620 | as_fn_append ac_func_list " fpurge" | |
2621 | as_fn_append ac_func_list " __fpurge" | |
2622 | as_fn_append ac_func_list " snprintf" | |
2623 | as_fn_append ac_func_list " vsnprintf" | |
2624 | # Check that the precious variables saved in the cache have kept the same | |
2625 | # value. | |
2626 | ac_cache_corrupted=false | |
2627 | for ac_var in $ac_precious_vars; do | |
2628 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2629 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2630 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2631 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2632 | case $ac_old_set,$ac_new_set in | |
2633 | set,) | |
2634 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2635 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2636 | ac_cache_corrupted=: ;; | |
2637 | ,set) | |
2638 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2639 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2640 | ac_cache_corrupted=: ;; | |
2641 | ,);; | |
2642 | *) | |
2643 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2644 | # differences in whitespace do not lead to failure. | |
2645 | ac_old_val_w=`echo x $ac_old_val` | |
2646 | ac_new_val_w=`echo x $ac_new_val` | |
2647 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2648 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2649 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2650 | ac_cache_corrupted=: | |
2651 | else | |
2652 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2653 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2654 | eval $ac_var=\$ac_old_val | |
2655 | fi | |
2656 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2657 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
2658 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
2659 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
2660 | fi;; | |
2661 | esac | |
2662 | # Pass precious variables to config.status. | |
2663 | if test "$ac_new_set" = set; then | |
2664 | case $ac_new_val in | |
2665 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2666 | *) ac_arg=$ac_var=$ac_new_val ;; | |
2667 | esac | |
2668 | case " $ac_configure_args " in | |
2669 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
2670 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
2671 | esac | |
2672 | fi | |
2673 | done | |
2674 | if $ac_cache_corrupted; then | |
2675 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2676 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2677 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
2678 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
2679 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 | |
c920c360 | 2680 | fi |
7f947b68 CR |
2681 | ## -------------------- ## |
2682 | ## Main body of script. ## | |
2683 | ## -------------------- ## | |
c920c360 | 2684 | |
7f947b68 CR |
2685 | ac_ext=c |
2686 | ac_cpp='$CPP $CPPFLAGS' | |
2687 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2688 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2689 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
c920c360 | 2690 | |
c920c360 | 2691 | |
c920c360 | 2692 | |
c920c360 | 2693 | |
c920c360 | 2694 | |
c920c360 | 2695 | |
7f947b68 CR |
2696 | ac_aux_dir= |
2697 | for ac_dir in ./support "$srcdir"/./support; do | |
2698 | if test -f "$ac_dir/install-sh"; then | |
2699 | ac_aux_dir=$ac_dir | |
2700 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
2701 | break | |
2702 | elif test -f "$ac_dir/install.sh"; then | |
2703 | ac_aux_dir=$ac_dir | |
2704 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
2705 | break | |
2706 | elif test -f "$ac_dir/shtool"; then | |
2707 | ac_aux_dir=$ac_dir | |
2708 | ac_install_sh="$ac_aux_dir/shtool install -c" | |
2709 | break | |
2710 | fi | |
2711 | done | |
2712 | if test -z "$ac_aux_dir"; then | |
2713 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in ./support \"$srcdir\"/./support" "$LINENO" 5 | |
c920c360 | 2714 | fi |
c920c360 | 2715 | |
7f947b68 CR |
2716 | # These three variables are undocumented and unsupported, |
2717 | # and are intended to be withdrawn in a future Autoconf release. | |
2718 | # They can cause serious problems if a builder's source tree is in a directory | |
2719 | # whose full name contains unusual characters. | |
2720 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
2721 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
2722 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
c920c360 | 2723 | |
c920c360 | 2724 | |
7f947b68 | 2725 | ac_config_headers="$ac_config_headers config.h" |
c920c360 | 2726 | |
c920c360 | 2727 | |
7f947b68 CR |
2728 | BASHVERS=4.2 |
2729 | RELSTATUS=maint | |
c920c360 | 2730 | |
7f947b68 CR |
2731 | case "$RELSTATUS" in |
2732 | alp*|bet*|dev*|rc*|maint*) DEBUG='-DDEBUG' MALLOC_DEBUG='-DMALLOC_DEBUG' ;; | |
2733 | *) DEBUG= MALLOC_DEBUG= ;; | |
2734 | esac | |
2dead0c4 | 2735 | |
7f947b68 CR |
2736 | # Make sure we can run config.sub. |
2737 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || | |
2738 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 | |
2dead0c4 | 2739 | |
7f947b68 CR |
2740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 |
2741 | $as_echo_n "checking build system type... " >&6; } | |
2742 | if ${ac_cv_build+:} false; then : | |
2743 | $as_echo_n "(cached) " >&6 | |
2744 | else | |
2745 | ac_build_alias=$build_alias | |
2746 | test "x$ac_build_alias" = x && | |
2747 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
2748 | test "x$ac_build_alias" = x && | |
2749 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 | |
2750 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || | |
2751 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 | |
2dead0c4 | 2752 | |
2dead0c4 | 2753 | fi |
7f947b68 CR |
2754 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 |
2755 | $as_echo "$ac_cv_build" >&6; } | |
2756 | case $ac_cv_build in | |
2757 | *-*-*) ;; | |
2758 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; | |
2759 | esac | |
2760 | build=$ac_cv_build | |
2761 | ac_save_IFS=$IFS; IFS='-' | |
2762 | set x $ac_cv_build | |
2763 | shift | |
2764 | build_cpu=$1 | |
2765 | build_vendor=$2 | |
2766 | shift; shift | |
2767 | # Remember, the first character of IFS is used to create $*, | |
2768 | # except with old shells: | |
2769 | build_os=$* | |
2770 | IFS=$ac_save_IFS | |
2771 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
2dead0c4 | 2772 | |
2dead0c4 | 2773 | |
7f947b68 CR |
2774 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 |
2775 | $as_echo_n "checking host system type... " >&6; } | |
2776 | if ${ac_cv_host+:} false; then : | |
2777 | $as_echo_n "(cached) " >&6 | |
2778 | else | |
2779 | if test "x$host_alias" = x; then | |
2780 | ac_cv_host=$ac_cv_build | |
2781 | else | |
2782 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
2783 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 | |
2dead0c4 CR |
2784 | fi |
2785 | ||
2dead0c4 | 2786 | fi |
7f947b68 CR |
2787 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
2788 | $as_echo "$ac_cv_host" >&6; } | |
2789 | case $ac_cv_host in | |
2790 | *-*-*) ;; | |
2791 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; | |
2792 | esac | |
2793 | host=$ac_cv_host | |
2794 | ac_save_IFS=$IFS; IFS='-' | |
2795 | set x $ac_cv_host | |
2796 | shift | |
2797 | host_cpu=$1 | |
2798 | host_vendor=$2 | |
2799 | shift; shift | |
2800 | # Remember, the first character of IFS is used to create $*, | |
2801 | # except with old shells: | |
2802 | host_os=$* | |
2803 | IFS=$ac_save_IFS | |
2804 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
2dead0c4 | 2805 | |
2dead0c4 | 2806 | |
2dead0c4 | 2807 | |
200aed9a | 2808 | |
7f947b68 CR |
2809 | opt_bash_malloc=yes |
2810 | opt_purify=no | |
2811 | opt_purecov=no | |
2812 | opt_afs=no | |
2813 | opt_curses=no | |
2814 | opt_with_installed_readline=no | |
2dead0c4 | 2815 | |
7f947b68 | 2816 | #htmldir= |
2dead0c4 | 2817 | |
7f947b68 CR |
2818 | case "${host_cpu}-${host_os}" in |
2819 | alpha*-*) opt_bash_malloc=no ;; # alpha running osf/1 or linux | |
2820 | *[Cc]ray*-*) opt_bash_malloc=no ;; # Crays | |
2821 | *-osf1*) opt_bash_malloc=no ;; # other osf/1 machines | |
2822 | sparc-svr4*) opt_bash_malloc=no ;; # sparc SVR4, SVR4.2 | |
2823 | sparc-netbsd*) opt_bash_malloc=no ;; # needs 8-byte alignment | |
2824 | mips-irix6*) opt_bash_malloc=no ;; # needs 8-byte alignment | |
2825 | m68k-sysv) opt_bash_malloc=no ;; # fixes file descriptor leak in closedir | |
2826 | sparc-linux*) opt_bash_malloc=no ;; # sparc running linux; requires ELF | |
2827 | #*-freebsd*-gnu) opt_bash_malloc=no ;; # there's some undetermined problem here | |
2828 | #*-freebsd*) opt_bash_malloc=no ;; # they claim it's better; I disagree | |
2829 | *-openbsd*) opt_bash_malloc=no ;; # they claim it needs eight-bit alignment | |
49cf7828 | 2830 | *-mirbsd*) opt_bash_malloc=no ;; # they claim it needs eight-bit alignment |
7f947b68 CR |
2831 | *-aix*) opt_bash_malloc=no ;; # AIX machines |
2832 | *-nextstep*) opt_bash_malloc=no ;; # NeXT machines running NeXTstep | |
2833 | *-macos*) opt_bash_malloc=no ;; # Apple MacOS X | |
2834 | *-rhapsody*) opt_bash_malloc=no ;; # Apple Rhapsody (MacOS X) | |
2835 | *-darwin*) opt_bash_malloc=no ;; # Apple Darwin (MacOS X) | |
2836 | *-dgux*) opt_bash_malloc=no ;; # DG/UX machines | |
2837 | *-qnx*) opt_bash_malloc=no ;; # QNX 4.2, QNX 6.x | |
2838 | *-machten4) opt_bash_malloc=no ;; # MachTen 4.x | |
2839 | *-bsdi2.1|*-bsdi3.?) opt_bash_malloc=no ; : ${CC:=shlicc2} ;; # for loadable builtins | |
2840 | *-beos*) opt_bash_malloc=no ;; # they say it's suitable | |
2841 | *-cygwin*) opt_bash_malloc=no ;; # Cygnus's CYGWIN environment | |
2842 | *-opennt*|*-interix*) opt_bash_malloc=no ;; # Interix, now owned by Microsoft | |
f14388d3 | 2843 | *-nsk*) opt_bash_malloc=no ;; # HP NonStop |
7f947b68 | 2844 | esac |
2dead0c4 | 2845 | |
7f947b68 CR |
2846 | # memory scrambling on free() |
2847 | case "${host_os}" in | |
2848 | sco3.2v5*|sco3.2v4*) opt_memscramble=no ;; | |
2849 | *) opt_memscramble=yes ;; | |
2850 | esac | |
2dead0c4 CR |
2851 | |
2852 | ||
2dead0c4 | 2853 | |
2dead0c4 | 2854 | |
7f947b68 CR |
2855 | # Check whether --with-afs was given. |
2856 | if test "${with_afs+set}" = set; then : | |
2857 | withval=$with_afs; opt_afs=$withval | |
2dead0c4 CR |
2858 | fi |
2859 | ||
2860 | ||
7f947b68 CR |
2861 | # Check whether --with-bash-malloc was given. |
2862 | if test "${with_bash_malloc+set}" = set; then : | |
2863 | withval=$with_bash_malloc; opt_bash_malloc=$withval | |
2864 | fi | |
2dead0c4 CR |
2865 | |
2866 | ||
7f947b68 CR |
2867 | # Check whether --with-curses was given. |
2868 | if test "${with_curses+set}" = set; then : | |
2869 | withval=$with_curses; opt_curses=$withval | |
2870 | fi | |
2dead0c4 CR |
2871 | |
2872 | ||
7f947b68 CR |
2873 | # Check whether --with-gnu-malloc was given. |
2874 | if test "${with_gnu_malloc+set}" = set; then : | |
2875 | withval=$with_gnu_malloc; opt_bash_malloc=$withval | |
2876 | fi | |
2dead0c4 CR |
2877 | |
2878 | ||
7f947b68 CR |
2879 | # Check whether --with-installed-readline was given. |
2880 | if test "${with_installed_readline+set}" = set; then : | |
2881 | withval=$with_installed_readline; opt_with_installed_readline=$withval | |
2dead0c4 | 2882 | fi |
2dead0c4 | 2883 | |
2dead0c4 | 2884 | |
7f947b68 CR |
2885 | # Check whether --with-purecov was given. |
2886 | if test "${with_purecov+set}" = set; then : | |
2887 | withval=$with_purecov; opt_purecov=$withval | |
2dead0c4 | 2888 | fi |
2dead0c4 | 2889 | |
7f947b68 CR |
2890 | |
2891 | # Check whether --with-purify was given. | |
2892 | if test "${with_purify+set}" = set; then : | |
2893 | withval=$with_purify; opt_purify=$withval | |
2dead0c4 | 2894 | fi |
2dead0c4 | 2895 | |
7f947b68 CR |
2896 | |
2897 | if test "$opt_bash_malloc" = yes; then | |
2898 | MALLOC_TARGET=malloc | |
2899 | MALLOC_SRC=malloc.c | |
2900 | ||
2901 | MALLOC_LIB='-lmalloc' | |
2902 | MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a' | |
2903 | MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)' | |
2904 | MALLOC_DEP='$(MALLOC_LIBRARY)' | |
2905 | ||
2906 | $as_echo "#define USING_BASH_MALLOC 1" >>confdefs.h | |
2907 | ||
2908 | else | |
2909 | MALLOC_LIB= | |
2910 | MALLOC_LIBRARY= | |
2911 | MALLOC_LDFLAGS= | |
2912 | MALLOC_DEP= | |
2dead0c4 | 2913 | fi |
2dead0c4 | 2914 | |
7f947b68 CR |
2915 | if test "$opt_purify" = yes; then |
2916 | PURIFY="purify " | |
2917 | $as_echo "#define DISABLE_MALLOC_WRAPPERS 1" >>confdefs.h | |
2918 | ||
2919 | else | |
2920 | PURIFY= | |
2dead0c4 | 2921 | fi |
2dead0c4 | 2922 | |
7f947b68 CR |
2923 | if test "$opt_purecov" = yes; then |
2924 | PURIFY="${PURIFY}purecov" | |
2dead0c4 | 2925 | fi |
7f947b68 CR |
2926 | |
2927 | if test "$opt_afs" = yes; then | |
2928 | $as_echo "#define AFS 1" >>confdefs.h | |
2dead0c4 CR |
2929 | |
2930 | fi | |
2dead0c4 | 2931 | |
7f947b68 CR |
2932 | if test "$opt_curses" = yes; then |
2933 | prefer_curses=yes | |
2dead0c4 | 2934 | fi |
2dead0c4 | 2935 | |
7f947b68 CR |
2936 | if test -z "${DEBUGGER_START_FILE}"; then |
2937 | DEBUGGER_START_FILE='${datadir}/bashdb/bashdb-main.inc' | |
2dead0c4 | 2938 | fi |
2dead0c4 | 2939 | |
7f947b68 CR |
2940 | opt_minimal_config=no |
2941 | ||
2942 | opt_job_control=yes | |
2943 | opt_alias=yes | |
2944 | opt_readline=yes | |
2945 | opt_history=yes | |
2946 | opt_bang_history=yes | |
2947 | opt_dirstack=yes | |
2948 | opt_restricted=yes | |
2949 | opt_process_subst=yes | |
2950 | opt_prompt_decoding=yes | |
2951 | opt_select=yes | |
2952 | opt_help=yes | |
2953 | opt_array_variables=yes | |
2954 | opt_dparen_arith=yes | |
2955 | opt_extended_glob=yes | |
2956 | opt_brace_expansion=yes | |
2957 | opt_disabled_builtins=no | |
2958 | opt_command_timing=yes | |
2959 | opt_xpg_echo=no | |
2960 | opt_strict_posix=no | |
2961 | opt_cond_command=yes | |
2962 | opt_cond_regexp=yes | |
2963 | opt_coproc=yes | |
2964 | opt_arith_for_command=yes | |
2965 | opt_net_redirs=yes | |
2966 | opt_progcomp=yes | |
2967 | opt_separate_help=no | |
2968 | opt_multibyte=yes | |
2969 | opt_debugger=yes | |
2970 | opt_single_longdoc_strings=yes | |
2971 | opt_casemod_attrs=yes | |
2972 | opt_casemod_expansions=yes | |
2973 | opt_extglob_default=no | |
f14388d3 | 2974 | opt_dircomplete_expand_default=no |
7f947b68 CR |
2975 | |
2976 | opt_static_link=no | |
2977 | opt_profiling=no | |
2978 | ||
2979 | # Check whether --enable-minimal-config was given. | |
2980 | if test "${enable_minimal_config+set}" = set; then : | |
2981 | enableval=$enable_minimal_config; opt_minimal_config=$enableval | |
2dead0c4 | 2982 | fi |
2dead0c4 | 2983 | |
7f947b68 CR |
2984 | |
2985 | if test $opt_minimal_config = yes; then | |
2986 | opt_job_control=no opt_alias=no opt_readline=no | |
2987 | opt_history=no opt_bang_history=no opt_dirstack=no | |
2988 | opt_restricted=no opt_process_subst=no opt_prompt_decoding=no | |
2989 | opt_select=no opt_help=no opt_array_variables=no opt_dparen_arith=no | |
2990 | opt_brace_expansion=no opt_disabled_builtins=no opt_command_timing=no | |
2991 | opt_extended_glob=no opt_cond_command=no opt_arith_for_command=no | |
2992 | opt_net_redirs=no opt_progcomp=no opt_separate_help=no | |
2993 | opt_multibyte=yes opt_cond_regexp=no opt_coproc=no | |
2994 | opt_casemod_attrs=no opt_casemod_expansions=no opt_extglob_default=no | |
2dead0c4 | 2995 | fi |
2dead0c4 | 2996 | |
7f947b68 CR |
2997 | # Check whether --enable-alias was given. |
2998 | if test "${enable_alias+set}" = set; then : | |
2999 | enableval=$enable_alias; opt_alias=$enableval | |
2dead0c4 | 3000 | fi |
2dead0c4 | 3001 | |
7f947b68 CR |
3002 | # Check whether --enable-arith-for-command was given. |
3003 | if test "${enable_arith_for_command+set}" = set; then : | |
3004 | enableval=$enable_arith_for_command; opt_arith_for_command=$enableval | |
2dead0c4 | 3005 | fi |
2dead0c4 | 3006 | |
7f947b68 CR |
3007 | # Check whether --enable-array-variables was given. |
3008 | if test "${enable_array_variables+set}" = set; then : | |
3009 | enableval=$enable_array_variables; opt_array_variables=$enableval | |
2dead0c4 | 3010 | fi |
2dead0c4 | 3011 | |
7f947b68 CR |
3012 | # Check whether --enable-bang-history was given. |
3013 | if test "${enable_bang_history+set}" = set; then : | |
3014 | enableval=$enable_bang_history; opt_bang_history=$enableval | |
3015 | fi | |
2dead0c4 | 3016 | |
7f947b68 CR |
3017 | # Check whether --enable-brace-expansion was given. |
3018 | if test "${enable_brace_expansion+set}" = set; then : | |
3019 | enableval=$enable_brace_expansion; opt_brace_expansion=$enableval | |
2dead0c4 | 3020 | fi |
2dead0c4 | 3021 | |
7f947b68 CR |
3022 | # Check whether --enable-casemod-attributes was given. |
3023 | if test "${enable_casemod_attributes+set}" = set; then : | |
3024 | enableval=$enable_casemod_attributes; opt_casemod_attrs=$enableval | |
2dead0c4 | 3025 | fi |
2dead0c4 | 3026 | |
7f947b68 CR |
3027 | # Check whether --enable-casemod-expansions was given. |
3028 | if test "${enable_casemod_expansions+set}" = set; then : | |
3029 | enableval=$enable_casemod_expansions; opt_casemod_expansions=$enableval | |
2dead0c4 | 3030 | fi |
2dead0c4 | 3031 | |
7f947b68 CR |
3032 | # Check whether --enable-command-timing was given. |
3033 | if test "${enable_command_timing+set}" = set; then : | |
3034 | enableval=$enable_command_timing; opt_command_timing=$enableval | |
2dead0c4 | 3035 | fi |
2dead0c4 | 3036 | |
7f947b68 CR |
3037 | # Check whether --enable-cond-command was given. |
3038 | if test "${enable_cond_command+set}" = set; then : | |
3039 | enableval=$enable_cond_command; opt_cond_command=$enableval | |
2dead0c4 | 3040 | fi |
2dead0c4 | 3041 | |
7f947b68 CR |
3042 | # Check whether --enable-cond-regexp was given. |
3043 | if test "${enable_cond_regexp+set}" = set; then : | |
3044 | enableval=$enable_cond_regexp; opt_cond_regexp=$enableval | |
2dead0c4 | 3045 | fi |
2dead0c4 | 3046 | |
7f947b68 CR |
3047 | # Check whether --enable-coprocesses was given. |
3048 | if test "${enable_coprocesses+set}" = set; then : | |
3049 | enableval=$enable_coprocesses; opt_coproc=$enableval | |
2dead0c4 | 3050 | fi |
2dead0c4 | 3051 | |
7f947b68 CR |
3052 | # Check whether --enable-debugger was given. |
3053 | if test "${enable_debugger+set}" = set; then : | |
3054 | enableval=$enable_debugger; opt_debugger=$enableval | |
2dead0c4 | 3055 | fi |
2dead0c4 | 3056 | |
f14388d3 CR |
3057 | # Check whether --enable-direxpand-default was given. |
3058 | if test "${enable_direxpand_default+set}" = set; then : | |
3059 | enableval=$enable_direxpand_default; opt_dircomplete_expand_default=$enableval | |
3060 | fi | |
3061 | ||
7f947b68 CR |
3062 | # Check whether --enable-directory-stack was given. |
3063 | if test "${enable_directory_stack+set}" = set; then : | |
3064 | enableval=$enable_directory_stack; opt_dirstack=$enableval | |
2dead0c4 | 3065 | fi |
2dead0c4 | 3066 | |
7f947b68 CR |
3067 | # Check whether --enable-disabled-builtins was given. |
3068 | if test "${enable_disabled_builtins+set}" = set; then : | |
3069 | enableval=$enable_disabled_builtins; opt_disabled_builtins=$enableval | |
2dead0c4 | 3070 | fi |
2dead0c4 | 3071 | |
7f947b68 CR |
3072 | # Check whether --enable-dparen-arithmetic was given. |
3073 | if test "${enable_dparen_arithmetic+set}" = set; then : | |
3074 | enableval=$enable_dparen_arithmetic; opt_dparen_arith=$enableval | |
2dead0c4 CR |
3075 | fi |
3076 | ||
7f947b68 CR |
3077 | # Check whether --enable-extended-glob was given. |
3078 | if test "${enable_extended_glob+set}" = set; then : | |
3079 | enableval=$enable_extended_glob; opt_extended_glob=$enableval | |
3080 | fi | |
2dead0c4 | 3081 | |
7f947b68 CR |
3082 | # Check whether --enable-extended-glob-default was given. |
3083 | if test "${enable_extended_glob_default+set}" = set; then : | |
3084 | enableval=$enable_extended_glob_default; opt_extglob_default=$enableval | |
2dead0c4 CR |
3085 | fi |
3086 | ||
7f947b68 CR |
3087 | # Check whether --enable-help-builtin was given. |
3088 | if test "${enable_help_builtin+set}" = set; then : | |
3089 | enableval=$enable_help_builtin; opt_help=$enableval | |
2dead0c4 CR |
3090 | fi |
3091 | ||
7f947b68 CR |
3092 | # Check whether --enable-history was given. |
3093 | if test "${enable_history+set}" = set; then : | |
3094 | enableval=$enable_history; opt_history=$enableval | |
2dead0c4 | 3095 | fi |
7f947b68 CR |
3096 | |
3097 | # Check whether --enable-job-control was given. | |
3098 | if test "${enable_job_control+set}" = set; then : | |
3099 | enableval=$enable_job_control; opt_job_control=$enableval | |
3100 | fi | |
3101 | ||
3102 | # Check whether --enable-multibyte was given. | |
3103 | if test "${enable_multibyte+set}" = set; then : | |
3104 | enableval=$enable_multibyte; opt_multibyte=$enableval | |
3105 | fi | |
3106 | ||
3107 | # Check whether --enable-net-redirections was given. | |
3108 | if test "${enable_net_redirections+set}" = set; then : | |
3109 | enableval=$enable_net_redirections; opt_net_redirs=$enableval | |
3110 | fi | |
3111 | ||
3112 | # Check whether --enable-process-substitution was given. | |
3113 | if test "${enable_process_substitution+set}" = set; then : | |
3114 | enableval=$enable_process_substitution; opt_process_subst=$enableval | |
3115 | fi | |
3116 | ||
3117 | # Check whether --enable-progcomp was given. | |
3118 | if test "${enable_progcomp+set}" = set; then : | |
3119 | enableval=$enable_progcomp; opt_progcomp=$enableval | |
3120 | fi | |
3121 | ||
3122 | # Check whether --enable-prompt-string-decoding was given. | |
3123 | if test "${enable_prompt_string_decoding+set}" = set; then : | |
3124 | enableval=$enable_prompt_string_decoding; opt_prompt_decoding=$enableval | |
3125 | fi | |
3126 | ||
3127 | # Check whether --enable-readline was given. | |
3128 | if test "${enable_readline+set}" = set; then : | |
3129 | enableval=$enable_readline; opt_readline=$enableval | |
3130 | fi | |
3131 | ||
3132 | # Check whether --enable-restricted was given. | |
3133 | if test "${enable_restricted+set}" = set; then : | |
3134 | enableval=$enable_restricted; opt_restricted=$enableval | |
3135 | fi | |
3136 | ||
3137 | # Check whether --enable-select was given. | |
3138 | if test "${enable_select+set}" = set; then : | |
3139 | enableval=$enable_select; opt_select=$enableval | |
3140 | fi | |
3141 | ||
3142 | # Check whether --enable-separate-helpfiles was given. | |
3143 | if test "${enable_separate_helpfiles+set}" = set; then : | |
3144 | enableval=$enable_separate_helpfiles; opt_separate_help=$enableval | |
3145 | fi | |
3146 | ||
3147 | # Check whether --enable-single-help-strings was given. | |
3148 | if test "${enable_single_help_strings+set}" = set; then : | |
3149 | enableval=$enable_single_help_strings; opt_single_longdoc_strings=$enableval | |
3150 | fi | |
3151 | ||
3152 | # Check whether --enable-strict-posix-default was given. | |
3153 | if test "${enable_strict_posix_default+set}" = set; then : | |
3154 | enableval=$enable_strict_posix_default; opt_strict_posix=$enableval | |
3155 | fi | |
3156 | ||
3157 | # Check whether --enable-usg-echo-default was given. | |
3158 | if test "${enable_usg_echo_default+set}" = set; then : | |
3159 | enableval=$enable_usg_echo_default; opt_xpg_echo=$enableval | |
3160 | fi | |
3161 | ||
3162 | # Check whether --enable-xpg-echo-default was given. | |
3163 | if test "${enable_xpg_echo_default+set}" = set; then : | |
3164 | enableval=$enable_xpg_echo_default; opt_xpg_echo=$enableval | |
3165 | fi | |
3166 | ||
3167 | ||
3168 | # Check whether --enable-mem-scramble was given. | |
3169 | if test "${enable_mem_scramble+set}" = set; then : | |
3170 | enableval=$enable_mem_scramble; opt_memscramble=$enableval | |
3171 | fi | |
3172 | ||
3173 | # Check whether --enable-profiling was given. | |
3174 | if test "${enable_profiling+set}" = set; then : | |
3175 | enableval=$enable_profiling; opt_profiling=$enableval | |
3176 | fi | |
3177 | ||
3178 | # Check whether --enable-static-link was given. | |
3179 | if test "${enable_static_link+set}" = set; then : | |
3180 | enableval=$enable_static_link; opt_static_link=$enableval | |
3181 | fi | |
3182 | ||
3183 | ||
3184 | ||
3185 | ||
3186 | ||
3187 | ||
3188 | ||
3189 | ||
3190 | ||
3191 | if test $opt_alias = yes; then | |
3192 | $as_echo "#define ALIAS 1" >>confdefs.h | |
3193 | ||
3194 | fi | |
3195 | if test $opt_dirstack = yes; then | |
3196 | $as_echo "#define PUSHD_AND_POPD 1" >>confdefs.h | |
3197 | ||
3198 | fi | |
3199 | if test $opt_restricted = yes; then | |
3200 | $as_echo "#define RESTRICTED_SHELL 1" >>confdefs.h | |
3201 | ||
3202 | fi | |
3203 | if test $opt_process_subst = yes; then | |
3204 | $as_echo "#define PROCESS_SUBSTITUTION 1" >>confdefs.h | |
3205 | ||
3206 | fi | |
3207 | if test $opt_prompt_decoding = yes; then | |
3208 | $as_echo "#define PROMPT_STRING_DECODE 1" >>confdefs.h | |
3209 | ||
3210 | fi | |
3211 | if test $opt_select = yes; then | |
3212 | $as_echo "#define SELECT_COMMAND 1" >>confdefs.h | |
3213 | ||
3214 | fi | |
3215 | if test $opt_help = yes; then | |
3216 | $as_echo "#define HELP_BUILTIN 1" >>confdefs.h | |
3217 | ||
3218 | fi | |
3219 | if test $opt_array_variables = yes; then | |
3220 | $as_echo "#define ARRAY_VARS 1" >>confdefs.h | |
3221 | ||
3222 | fi | |
3223 | if test $opt_dparen_arith = yes; then | |
3224 | $as_echo "#define DPAREN_ARITHMETIC 1" >>confdefs.h | |
3225 | ||
3226 | fi | |
3227 | if test $opt_brace_expansion = yes; then | |
3228 | $as_echo "#define BRACE_EXPANSION 1" >>confdefs.h | |
3229 | ||
3230 | fi | |
3231 | if test $opt_disabled_builtins = yes; then | |
3232 | $as_echo "#define DISABLED_BUILTINS 1" >>confdefs.h | |
3233 | ||
3234 | fi | |
3235 | if test $opt_command_timing = yes; then | |
3236 | $as_echo "#define COMMAND_TIMING 1" >>confdefs.h | |
3237 | ||
3238 | fi | |
3239 | if test $opt_xpg_echo = yes ; then | |
3240 | $as_echo "#define DEFAULT_ECHO_TO_XPG 1" >>confdefs.h | |
3241 | ||
3242 | fi | |
3243 | if test $opt_strict_posix = yes; then | |
3244 | $as_echo "#define STRICT_POSIX 1" >>confdefs.h | |
3245 | ||
3246 | fi | |
3247 | if test $opt_extended_glob = yes ; then | |
3248 | $as_echo "#define EXTENDED_GLOB 1" >>confdefs.h | |
3249 | ||
3250 | fi | |
3251 | if test $opt_extglob_default = yes; then | |
3252 | $as_echo "#define EXTGLOB_DEFAULT 1" >>confdefs.h | |
3253 | ||
3254 | else | |
3255 | $as_echo "#define EXTGLOB_DEFAULT 0" >>confdefs.h | |
3256 | ||
3257 | fi | |
3258 | if test $opt_cond_command = yes ; then | |
3259 | $as_echo "#define COND_COMMAND 1" >>confdefs.h | |
3260 | ||
3261 | fi | |
3262 | if test $opt_cond_regexp = yes ; then | |
3263 | $as_echo "#define COND_REGEXP 1" >>confdefs.h | |
3264 | ||
3265 | fi | |
3266 | if test $opt_coproc = yes; then | |
3267 | $as_echo "#define COPROCESS_SUPPORT 1" >>confdefs.h | |
3268 | ||
3269 | fi | |
3270 | if test $opt_arith_for_command = yes; then | |
3271 | $as_echo "#define ARITH_FOR_COMMAND 1" >>confdefs.h | |
3272 | ||
3273 | fi | |
3274 | if test $opt_net_redirs = yes; then | |
3275 | $as_echo "#define NETWORK_REDIRECTIONS 1" >>confdefs.h | |
3276 | ||
3277 | fi | |
3278 | if test $opt_progcomp = yes; then | |
3279 | $as_echo "#define PROGRAMMABLE_COMPLETION 1" >>confdefs.h | |
3280 | ||
3281 | fi | |
3282 | if test $opt_multibyte = no; then | |
3283 | $as_echo "#define NO_MULTIBYTE_SUPPORT 1" >>confdefs.h | |
3284 | ||
3285 | fi | |
3286 | if test $opt_debugger = yes; then | |
3287 | $as_echo "#define DEBUGGER 1" >>confdefs.h | |
3288 | ||
3289 | fi | |
3290 | if test $opt_casemod_attrs = yes; then | |
3291 | $as_echo "#define CASEMOD_ATTRS 1" >>confdefs.h | |
3292 | ||
3293 | fi | |
3294 | if test $opt_casemod_expansions = yes; then | |
3295 | $as_echo "#define CASEMOD_EXPANSIONS 1" >>confdefs.h | |
3296 | ||
f14388d3 CR |
3297 | fi |
3298 | if test $opt_dircomplete_expand_default = yes; then | |
3299 | $as_echo "#define DIRCOMPLETE_EXPAND_DEFAULT 1" >>confdefs.h | |
3300 | ||
7f947b68 CR |
3301 | fi |
3302 | ||
3303 | if test $opt_memscramble = yes; then | |
3304 | $as_echo "#define MEMSCRAMBLE 1" >>confdefs.h | |
3305 | ||
3306 | fi | |
3307 | ||
3308 | if test "$opt_minimal_config" = yes; then | |
3309 | TESTSCRIPT=run-minimal | |
3310 | else | |
3311 | TESTSCRIPT=run-all | |
3312 | fi | |
3313 | ||
3314 | HELPDIR= HELPDIRDEFINE= HELPINSTALL= HELPFILES_TARGET= | |
3315 | if test "$opt_separate_help" != no; then | |
3316 | if test "$opt_separate_help" = "yes" ; then | |
3317 | HELPDIR='${datadir}/bash' | |
3318 | else | |
3319 | HELPDIR=$opt_separate_help | |
3320 | fi | |
3321 | HELPDIRDEFINE='-H ${HELPDIR}' | |
3322 | HELPINSTALL='install-help' | |
3323 | HELPFILES_TARGET='helpdoc' | |
3324 | fi | |
3325 | HELPSTRINGS= | |
3326 | if test "$opt_single_longdoc_strings" != "yes"; then | |
3327 | HELPSTRINGS='-S' | |
71412226 CR |
3328 | fi |
3329 | ||
3330 | ||
3331 | ||
3332 | ||
3333 | ||
3334 | ||
3335 | ||
3336 | ||
3337 | ||
3338 | ||
3339 | ||
3340 | ||
3341 | ||
3342 | ||
3343 | ||
3344 | ||
3345 | ||
3346 | ||
abe2eb5b | 3347 | |
71412226 | 3348 | echo "" |
7117c2d2 | 3349 | echo "Beginning configuration for bash-$BASHVERS-$RELSTATUS for ${host_cpu}-${host_vendor}-${host_os}" |
f73dda09 | 3350 | echo "" |
d166f048 | 3351 | |
f73dda09 JA |
3352 | ac_ext=c |
3353 | ac_cpp='$CPP $CPPFLAGS' | |
3354 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3355 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3356 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3357 | if test -n "$ac_tool_prefix"; then | |
3358 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
3359 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
7f947b68 | 3360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3361 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3362 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 3363 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3364 | else |
3365 | if test -n "$CC"; then | |
3366 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3367 | else | |
a82a04b3 CR |
3368 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3369 | for as_dir in $PATH | |
3370 | do | |
3371 | IFS=$as_save_IFS | |
3372 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3373 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3374 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 3375 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
7f947b68 | 3376 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3377 | break 2 |
3378 | fi | |
3379 | done | |
7f947b68 | 3380 | done |
b709b946 | 3381 | IFS=$as_save_IFS |
ccc6cda3 | 3382 | |
f73dda09 JA |
3383 | fi |
3384 | fi | |
3385 | CC=$ac_cv_prog_CC | |
3386 | if test -n "$CC"; then | |
7f947b68 | 3387 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3388 | $as_echo "$CC" >&6; } |
f73dda09 | 3389 | else |
7f947b68 | 3390 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3391 | $as_echo "no" >&6; } |
f73dda09 | 3392 | fi |
ccc6cda3 | 3393 | |
b709b946 | 3394 | |
f73dda09 JA |
3395 | fi |
3396 | if test -z "$ac_cv_prog_CC"; then | |
3397 | ac_ct_CC=$CC | |
3398 | # Extract the first word of "gcc", so it can be a program name with args. | |
3399 | set dummy gcc; ac_word=$2 | |
7f947b68 | 3400 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3401 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3402 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
dd4f3dd8 | 3403 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3404 | else |
3405 | if test -n "$ac_ct_CC"; then | |
3406 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3407 | else | |
a82a04b3 CR |
3408 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3409 | for as_dir in $PATH | |
3410 | do | |
3411 | IFS=$as_save_IFS | |
3412 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3413 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3414 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 3415 | ac_cv_prog_ac_ct_CC="gcc" |
7f947b68 | 3416 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3417 | break 2 |
3418 | fi | |
3419 | done | |
7f947b68 | 3420 | done |
b709b946 | 3421 | IFS=$as_save_IFS |
ccc6cda3 | 3422 | |
f73dda09 JA |
3423 | fi |
3424 | fi | |
3425 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
3426 | if test -n "$ac_ct_CC"; then | |
7f947b68 | 3427 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
dd4f3dd8 | 3428 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3429 | else |
7f947b68 | 3430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3431 | $as_echo "no" >&6; } |
f73dda09 | 3432 | fi |
ccc6cda3 | 3433 | |
b709b946 CR |
3434 | if test "x$ac_ct_CC" = x; then |
3435 | CC="" | |
3436 | else | |
3437 | case $cross_compiling:$ac_tool_warned in | |
3438 | yes:) | |
7f947b68 | 3439 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 3440 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
3441 | ac_tool_warned=yes ;; |
3442 | esac | |
3443 | CC=$ac_ct_CC | |
3444 | fi | |
f73dda09 JA |
3445 | else |
3446 | CC="$ac_cv_prog_CC" | |
3447 | fi | |
bb70624e | 3448 | |
f73dda09 | 3449 | if test -z "$CC"; then |
b709b946 CR |
3450 | if test -n "$ac_tool_prefix"; then |
3451 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
f73dda09 | 3452 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
7f947b68 | 3453 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3454 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3455 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 3456 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
3457 | else |
3458 | if test -n "$CC"; then | |
3459 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3460 | else | |
a82a04b3 CR |
3461 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3462 | for as_dir in $PATH | |
3463 | do | |
3464 | IFS=$as_save_IFS | |
3465 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3466 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3467 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 3468 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
7f947b68 | 3469 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3470 | break 2 |
3471 | fi | |
3472 | done | |
7f947b68 | 3473 | done |
b709b946 | 3474 | IFS=$as_save_IFS |
f73dda09 | 3475 | |
ccc6cda3 JA |
3476 | fi |
3477 | fi | |
f73dda09 | 3478 | CC=$ac_cv_prog_CC |
ccc6cda3 | 3479 | if test -n "$CC"; then |
7f947b68 | 3480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3481 | $as_echo "$CC" >&6; } |
c184f645 | 3482 | else |
7f947b68 | 3483 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3484 | $as_echo "no" >&6; } |
c184f645 CR |
3485 | fi |
3486 | ||
c184f645 | 3487 | |
b709b946 | 3488 | fi |
f73dda09 | 3489 | fi |
ccc6cda3 JA |
3490 | if test -z "$CC"; then |
3491 | # Extract the first word of "cc", so it can be a program name with args. | |
3492 | set dummy cc; ac_word=$2 | |
7f947b68 | 3493 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3494 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3495 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 3496 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
3497 | else |
3498 | if test -n "$CC"; then | |
3499 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3500 | else | |
ccc6cda3 | 3501 | ac_prog_rejected=no |
a82a04b3 CR |
3502 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3503 | for as_dir in $PATH | |
3504 | do | |
3505 | IFS=$as_save_IFS | |
3506 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3507 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3508 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 CR |
3509 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
3510 | ac_prog_rejected=yes | |
3511 | continue | |
3512 | fi | |
3513 | ac_cv_prog_CC="cc" | |
7f947b68 | 3514 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3515 | break 2 |
3516 | fi | |
3517 | done | |
7f947b68 | 3518 | done |
b709b946 | 3519 | IFS=$as_save_IFS |
f73dda09 | 3520 | |
ccc6cda3 JA |
3521 | if test $ac_prog_rejected = yes; then |
3522 | # We found a bogon in the path, so make sure we never use it. | |
3523 | set dummy $ac_cv_prog_CC | |
3524 | shift | |
f73dda09 | 3525 | if test $# != 0; then |
ccc6cda3 JA |
3526 | # We chose a different compiler from the bogus one. |
3527 | # However, it has the same basename, so the bogon will be chosen | |
3528 | # first if we set CC to just the basename; use the full file name. | |
3529 | shift | |
5e4a95c7 | 3530 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
ccc6cda3 JA |
3531 | fi |
3532 | fi | |
3533 | fi | |
3534 | fi | |
f73dda09 | 3535 | CC=$ac_cv_prog_CC |
ccc6cda3 | 3536 | if test -n "$CC"; then |
7f947b68 | 3537 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3538 | $as_echo "$CC" >&6; } |
ccc6cda3 | 3539 | else |
7f947b68 | 3540 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3541 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3542 | fi |
3543 | ||
b709b946 | 3544 | |
f73dda09 JA |
3545 | fi |
3546 | if test -z "$CC"; then | |
3547 | if test -n "$ac_tool_prefix"; then | |
b709b946 | 3548 | for ac_prog in cl.exe |
f73dda09 JA |
3549 | do |
3550 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
3551 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
7f947b68 | 3552 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3553 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3554 | if ${ac_cv_prog_CC+:} false; then : |
dd4f3dd8 | 3555 | $as_echo_n "(cached) " >&6 |
bb70624e JA |
3556 | else |
3557 | if test -n "$CC"; then | |
3558 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3559 | else | |
a82a04b3 CR |
3560 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3561 | for as_dir in $PATH | |
3562 | do | |
3563 | IFS=$as_save_IFS | |
3564 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3565 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3566 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 3567 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
7f947b68 | 3568 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3569 | break 2 |
3570 | fi | |
3571 | done | |
7f947b68 | 3572 | done |
b709b946 | 3573 | IFS=$as_save_IFS |
f73dda09 | 3574 | |
bb70624e JA |
3575 | fi |
3576 | fi | |
f73dda09 | 3577 | CC=$ac_cv_prog_CC |
bb70624e | 3578 | if test -n "$CC"; then |
7f947b68 | 3579 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
dd4f3dd8 | 3580 | $as_echo "$CC" >&6; } |
bb70624e | 3581 | else |
7f947b68 | 3582 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3583 | $as_echo "no" >&6; } |
bb70624e | 3584 | fi |
ccc6cda3 | 3585 | |
b709b946 | 3586 | |
f73dda09 JA |
3587 | test -n "$CC" && break |
3588 | done | |
ccc6cda3 | 3589 | fi |
f73dda09 JA |
3590 | if test -z "$CC"; then |
3591 | ac_ct_CC=$CC | |
b709b946 | 3592 | for ac_prog in cl.exe |
f73dda09 JA |
3593 | do |
3594 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3595 | set dummy $ac_prog; ac_word=$2 | |
7f947b68 | 3596 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 3597 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 3598 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
dd4f3dd8 | 3599 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
3600 | else |
3601 | if test -n "$ac_ct_CC"; then | |
3602 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3603 | else | |
a82a04b3 CR |
3604 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3605 | for as_dir in $PATH | |
3606 | do | |
3607 | IFS=$as_save_IFS | |
3608 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 3609 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 3610 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 3611 | ac_cv_prog_ac_ct_CC="$ac_prog" |
7f947b68 | 3612 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
3613 | break 2 |
3614 | fi | |
3615 | done | |
7f947b68 | 3616 | done |
b709b946 | 3617 | IFS=$as_save_IFS |
ccc6cda3 | 3618 | |
ccc6cda3 | 3619 | fi |
ccc6cda3 | 3620 | fi |
f73dda09 JA |
3621 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
3622 | if test -n "$ac_ct_CC"; then | |
7f947b68 | 3623 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
dd4f3dd8 | 3624 | $as_echo "$ac_ct_CC" >&6; } |
f73dda09 | 3625 | else |
7f947b68 | 3626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 3627 | $as_echo "no" >&6; } |
ccc6cda3 JA |
3628 | fi |
3629 | ||
b709b946 | 3630 | |
f73dda09 JA |
3631 | test -n "$ac_ct_CC" && break |
3632 | done | |
ccc6cda3 | 3633 | |
b709b946 CR |
3634 | if test "x$ac_ct_CC" = x; then |
3635 | CC="" | |
3636 | else | |
3637 | case $cross_compiling:$ac_tool_warned in | |
3638 | yes:) | |
7f947b68 | 3639 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 3640 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
3641 | ac_tool_warned=yes ;; |
3642 | esac | |
3643 | CC=$ac_ct_CC | |
3644 | fi | |
bb70624e JA |
3645 | fi |
3646 | ||
f73dda09 JA |
3647 | fi |
3648 | ||
a82a04b3 | 3649 | |
7f947b68 | 3650 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3651 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
7f947b68 CR |
3652 | as_fn_error $? "no acceptable C compiler found in \$PATH |
3653 | See \`config.log' for more details" "$LINENO" 5; } | |
f73dda09 JA |
3654 | |
3655 | # Provide some information about the compiler. | |
7f947b68 | 3656 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
dd4f3dd8 CR |
3657 | set X $ac_compile |
3658 | ac_compiler=$2 | |
7f947b68 CR |
3659 | for ac_option in --version -v -V -qversion; do |
3660 | { { ac_try="$ac_compiler $ac_option >&5" | |
abe2eb5b CR |
3661 | case "(($ac_try" in |
3662 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3663 | *) ac_try_echo=$ac_try;; | |
3664 | esac | |
7f947b68 CR |
3665 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3666 | $as_echo "$ac_try_echo"; } >&5 | |
3667 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
abe2eb5b | 3668 | ac_status=$? |
7f947b68 CR |
3669 | if test -s conftest.err; then |
3670 | sed '10a\ | |
3671 | ... rest of stderr output deleted ... | |
3672 | 10q' conftest.err >conftest.er1 | |
3673 | cat conftest.er1 >&5 | |
3674 | fi | |
3675 | rm -f conftest.er1 conftest.err | |
3676 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3677 | test $ac_status = 0; } | |
3678 | done | |
f73dda09 | 3679 | |
7f947b68 | 3680 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 3681 | /* end confdefs.h. */ |
f73dda09 JA |
3682 | |
3683 | int | |
3684 | main () | |
3685 | { | |
3686 | ||
3687 | ; | |
3688 | return 0; | |
3689 | } | |
3690 | _ACEOF | |
3691 | ac_clean_files_save=$ac_clean_files | |
dd4f3dd8 | 3692 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
f73dda09 JA |
3693 | # Try to create an executable without -o first, disregard a.out. |
3694 | # It will help us diagnose broken compilers, and finding out an intuition | |
3695 | # of exeext. | |
7f947b68 CR |
3696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
3697 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
dd4f3dd8 CR |
3698 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
3699 | ||
3700 | # The possible output files: | |
3701 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
3702 | ||
b709b946 CR |
3703 | ac_rmfiles= |
3704 | for ac_file in $ac_files | |
3705 | do | |
3706 | case $ac_file in | |
dd4f3dd8 | 3707 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
b709b946 CR |
3708 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; |
3709 | esac | |
3710 | done | |
3711 | rm -f $ac_rmfiles | |
3712 | ||
7f947b68 | 3713 | if { { ac_try="$ac_link_default" |
b709b946 CR |
3714 | case "(($ac_try" in |
3715 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3716 | *) ac_try_echo=$ac_try;; | |
3717 | esac | |
7f947b68 CR |
3718 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3719 | $as_echo "$ac_try_echo"; } >&5 | |
b709b946 | 3720 | (eval "$ac_link_default") 2>&5 |
f73dda09 | 3721 | ac_status=$? |
7f947b68 CR |
3722 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3723 | test $ac_status = 0; }; then : | |
b709b946 CR |
3724 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. |
3725 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
3726 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
3727 | # so that the user can short-circuit this test for compilers unknown to | |
3728 | # Autoconf. | |
dd4f3dd8 | 3729 | for ac_file in $ac_files '' |
5e4a95c7 CR |
3730 | do |
3731 | test -f "$ac_file" || continue | |
f73dda09 | 3732 | case $ac_file in |
dd4f3dd8 | 3733 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
5e4a95c7 CR |
3734 | ;; |
3735 | [ab].out ) | |
3736 | # We found the default executable, but exeext='' is most | |
3737 | # certainly right. | |
3738 | break;; | |
3739 | *.* ) | |
7f947b68 | 3740 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
b709b946 CR |
3741 | then :; else |
3742 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3743 | fi | |
3744 | # We set ac_cv_exeext here because the later test for it is not | |
3745 | # safe: cross compilers may not add the suffix if given an `-o' | |
3746 | # argument, so we may need to know it at that point already. | |
3747 | # Even if this section looks crufty: it has the advantage of | |
3748 | # actually working. | |
5e4a95c7 CR |
3749 | break;; |
3750 | * ) | |
3751 | break;; | |
f73dda09 JA |
3752 | esac |
3753 | done | |
b709b946 CR |
3754 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
3755 | ||
ccc6cda3 | 3756 | else |
dd4f3dd8 CR |
3757 | ac_file='' |
3758 | fi | |
7f947b68 CR |
3759 | if test -z "$ac_file"; then : |
3760 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3761 | $as_echo "no" >&6; } | |
3762 | $as_echo "$as_me: failed program was:" >&5 | |
5e4a95c7 CR |
3763 | sed 's/^/| /' conftest.$ac_ext >&5 |
3764 | ||
7f947b68 | 3765 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3766 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
7f947b68 CR |
3767 | as_fn_error 77 "C compiler cannot create executables |
3768 | See \`config.log' for more details" "$LINENO" 5; } | |
3769 | else | |
3770 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
3771 | $as_echo "yes" >&6; } | |
f73dda09 | 3772 | fi |
7f947b68 CR |
3773 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
3774 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
3775 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
3776 | $as_echo "$ac_file" >&6; } | |
f73dda09 | 3777 | ac_exeext=$ac_cv_exeext |
f73dda09 | 3778 | |
dd4f3dd8 | 3779 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
f73dda09 | 3780 | ac_clean_files=$ac_clean_files_save |
7f947b68 | 3781 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
dd4f3dd8 | 3782 | $as_echo_n "checking for suffix of executables... " >&6; } |
7f947b68 | 3783 | if { { ac_try="$ac_link" |
b709b946 CR |
3784 | case "(($ac_try" in |
3785 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3786 | *) ac_try_echo=$ac_try;; | |
3787 | esac | |
7f947b68 CR |
3788 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3789 | $as_echo "$ac_try_echo"; } >&5 | |
b709b946 | 3790 | (eval "$ac_link") 2>&5 |
f73dda09 | 3791 | ac_status=$? |
7f947b68 CR |
3792 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3793 | test $ac_status = 0; }; then : | |
f73dda09 JA |
3794 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
3795 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
3796 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
3797 | # `rm'. | |
5e4a95c7 CR |
3798 | for ac_file in conftest.exe conftest conftest.*; do |
3799 | test -f "$ac_file" || continue | |
f73dda09 | 3800 | case $ac_file in |
dd4f3dd8 | 3801 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
f73dda09 | 3802 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
5e4a95c7 | 3803 | break;; |
f73dda09 JA |
3804 | * ) break;; |
3805 | esac | |
3806 | done | |
ccc6cda3 | 3807 | else |
7f947b68 | 3808 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 3809 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
7f947b68 CR |
3810 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
3811 | See \`config.log' for more details" "$LINENO" 5; } | |
f73dda09 | 3812 | fi |
7f947b68 CR |
3813 | rm -f conftest conftest$ac_cv_exeext |
3814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
dd4f3dd8 | 3815 | $as_echo "$ac_cv_exeext" >&6; } |
f73dda09 JA |
3816 | |
3817 | rm -f conftest.$ac_ext | |
3818 | EXEEXT=$ac_cv_exeext | |
3819 | ac_exeext=$EXEEXT | |
7f947b68 CR |
3820 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3821 | /* end confdefs.h. */ | |
3822 | #include <stdio.h> | |
3823 | int | |
3824 | main () | |
3825 | { | |
3826 | FILE *f = fopen ("conftest.out", "w"); | |
3827 | return ferror (f) || fclose (f) != 0; | |
3828 | ||
3829 | ; | |
3830 | return 0; | |
3831 | } | |
3832 | _ACEOF | |
3833 | ac_clean_files="$ac_clean_files conftest.out" | |
3834 | # Check that the compiler produces executables we can run. If not, either | |
3835 | # the compiler is broken, or we cross compile. | |
3836 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
3837 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
3838 | if test "$cross_compiling" != yes; then | |
3839 | { { ac_try="$ac_link" | |
3840 | case "(($ac_try" in | |
3841 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3842 | *) ac_try_echo=$ac_try;; | |
3843 | esac | |
3844 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3845 | $as_echo "$ac_try_echo"; } >&5 | |
3846 | (eval "$ac_link") 2>&5 | |
3847 | ac_status=$? | |
3848 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3849 | test $ac_status = 0; } | |
3850 | if { ac_try='./conftest$ac_cv_exeext' | |
3851 | { { case "(($ac_try" in | |
3852 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3853 | *) ac_try_echo=$ac_try;; | |
3854 | esac | |
3855 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3856 | $as_echo "$ac_try_echo"; } >&5 | |
3857 | (eval "$ac_try") 2>&5 | |
3858 | ac_status=$? | |
3859 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3860 | test $ac_status = 0; }; }; then | |
3861 | cross_compiling=no | |
3862 | else | |
3863 | if test "$cross_compiling" = maybe; then | |
3864 | cross_compiling=yes | |
3865 | else | |
3866 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3867 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3868 | as_fn_error $? "cannot run C compiled programs. | |
3869 | If you meant to cross compile, use \`--host'. | |
3870 | See \`config.log' for more details" "$LINENO" 5; } | |
3871 | fi | |
3872 | fi | |
3873 | fi | |
3874 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
3875 | $as_echo "$cross_compiling" >&6; } | |
3876 | ||
3877 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out | |
3878 | ac_clean_files=$ac_clean_files_save | |
3879 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 | |
7610e0c5 | 3880 | $as_echo_n "checking for suffix of object files... " >&6; } |
7f947b68 | 3881 | if ${ac_cv_objext+:} false; then : |
7610e0c5 CR |
3882 | $as_echo_n "(cached) " >&6 |
3883 | else | |
7f947b68 | 3884 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
71412226 | 3885 | /* end confdefs.h. */ |
7610e0c5 | 3886 | |
71412226 CR |
3887 | int |
3888 | main () | |
3889 | { | |
71412226 CR |
3890 | |
3891 | ; | |
3892 | return 0; | |
3893 | } | |
3894 | _ACEOF | |
7610e0c5 | 3895 | rm -f conftest.o conftest.obj |
7f947b68 | 3896 | if { { ac_try="$ac_compile" |
71412226 CR |
3897 | case "(($ac_try" in |
3898 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3899 | *) ac_try_echo=$ac_try;; | |
3900 | esac | |
7f947b68 CR |
3901 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3902 | $as_echo "$ac_try_echo"; } >&5 | |
7610e0c5 | 3903 | (eval "$ac_compile") 2>&5 |
71412226 | 3904 | ac_status=$? |
7f947b68 CR |
3905 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3906 | test $ac_status = 0; }; then : | |
7610e0c5 CR |
3907 | for ac_file in conftest.o conftest.obj conftest.*; do |
3908 | test -f "$ac_file" || continue; | |
3909 | case $ac_file in | |
3910 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; | |
3911 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` | |
3912 | break;; | |
3913 | esac | |
3914 | done | |
3915 | else | |
3916 | $as_echo "$as_me: failed program was:" >&5 | |
3917 | sed 's/^/| /' conftest.$ac_ext >&5 | |
3918 | ||
7f947b68 | 3919 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
71412226 | 3920 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
7f947b68 CR |
3921 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
3922 | See \`config.log' for more details" "$LINENO" 5; } | |
71412226 | 3923 | fi |
f73dda09 | 3924 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
ccc6cda3 | 3925 | fi |
7f947b68 | 3926 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
dd4f3dd8 | 3927 | $as_echo "$ac_cv_objext" >&6; } |
f73dda09 JA |
3928 | OBJEXT=$ac_cv_objext |
3929 | ac_objext=$OBJEXT | |
7f947b68 | 3930 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
dd4f3dd8 | 3931 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } |
7f947b68 | 3932 | if ${ac_cv_c_compiler_gnu+:} false; then : |
dd4f3dd8 | 3933 | $as_echo_n "(cached) " >&6 |
f73dda09 | 3934 | else |
7f947b68 | 3935 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 3936 | /* end confdefs.h. */ |
f73dda09 JA |
3937 | |
3938 | int | |
3939 | main () | |
3940 | { | |
3941 | #ifndef __GNUC__ | |
3942 | choke me | |
3943 | #endif | |
3944 | ||
3945 | ; | |
3946 | return 0; | |
3947 | } | |
3948 | _ACEOF | |
7f947b68 | 3949 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
3950 | ac_compiler_gnu=yes |
3951 | else | |
7f947b68 | 3952 | ac_compiler_gnu=no |
f73dda09 | 3953 | fi |
b709b946 | 3954 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 JA |
3955 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
3956 | ||
3957 | fi | |
7f947b68 | 3958 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
dd4f3dd8 CR |
3959 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } |
3960 | if test $ac_compiler_gnu = yes; then | |
3961 | GCC=yes | |
3962 | else | |
3963 | GCC= | |
3964 | fi | |
f73dda09 JA |
3965 | ac_test_CFLAGS=${CFLAGS+set} |
3966 | ac_save_CFLAGS=$CFLAGS | |
7f947b68 | 3967 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
dd4f3dd8 | 3968 | $as_echo_n "checking whether $CC accepts -g... " >&6; } |
7f947b68 | 3969 | if ${ac_cv_prog_cc_g+:} false; then : |
dd4f3dd8 | 3970 | $as_echo_n "(cached) " >&6 |
f73dda09 | 3971 | else |
b709b946 CR |
3972 | ac_save_c_werror_flag=$ac_c_werror_flag |
3973 | ac_c_werror_flag=yes | |
3974 | ac_cv_prog_cc_g=no | |
3975 | CFLAGS="-g" | |
7f947b68 | 3976 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 3977 | /* end confdefs.h. */ |
f73dda09 JA |
3978 | |
3979 | int | |
3980 | main () | |
3981 | { | |
ccc6cda3 | 3982 | |
f73dda09 JA |
3983 | ; |
3984 | return 0; | |
3985 | } | |
3986 | _ACEOF | |
7f947b68 | 3987 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
3988 | ac_cv_prog_cc_g=yes |
3989 | else | |
7f947b68 CR |
3990 | CFLAGS="" |
3991 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 3992 | /* end confdefs.h. */ |
c184f645 | 3993 | |
c184f645 CR |
3994 | int |
3995 | main () | |
3996 | { | |
b709b946 | 3997 | |
c184f645 CR |
3998 | ; |
3999 | return 0; | |
4000 | } | |
4001 | _ACEOF | |
7f947b68 | 4002 | if ac_fn_c_try_compile "$LINENO"; then : |
abe2eb5b | 4003 | |
7f947b68 CR |
4004 | else |
4005 | ac_c_werror_flag=$ac_save_c_werror_flag | |
b709b946 | 4006 | CFLAGS="-g" |
7f947b68 | 4007 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4008 | /* end confdefs.h. */ |
b709b946 | 4009 | |
f73dda09 JA |
4010 | int |
4011 | main () | |
4012 | { | |
b709b946 | 4013 | |
f73dda09 JA |
4014 | ; |
4015 | return 0; | |
4016 | } | |
4017 | _ACEOF | |
7f947b68 | 4018 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 4019 | ac_cv_prog_cc_g=yes |
d3ad40de | 4020 | fi |
b709b946 CR |
4021 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4022 | fi | |
b709b946 CR |
4023 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4024 | fi | |
b709b946 CR |
4025 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4026 | ac_c_werror_flag=$ac_save_c_werror_flag | |
4027 | fi | |
7f947b68 | 4028 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 |
dd4f3dd8 | 4029 | $as_echo "$ac_cv_prog_cc_g" >&6; } |
b709b946 CR |
4030 | if test "$ac_test_CFLAGS" = set; then |
4031 | CFLAGS=$ac_save_CFLAGS | |
4032 | elif test $ac_cv_prog_cc_g = yes; then | |
4033 | if test "$GCC" = yes; then | |
4034 | CFLAGS="-g -O2" | |
4035 | else | |
4036 | CFLAGS="-g" | |
4037 | fi | |
4038 | else | |
4039 | if test "$GCC" = yes; then | |
4040 | CFLAGS="-O2" | |
4041 | else | |
4042 | CFLAGS= | |
4043 | fi | |
4044 | fi | |
7f947b68 | 4045 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
dd4f3dd8 | 4046 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } |
7f947b68 | 4047 | if ${ac_cv_prog_cc_c89+:} false; then : |
dd4f3dd8 | 4048 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
4049 | else |
4050 | ac_cv_prog_cc_c89=no | |
4051 | ac_save_CC=$CC | |
7f947b68 | 4052 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4053 | /* end confdefs.h. */ |
b709b946 CR |
4054 | #include <stdarg.h> |
4055 | #include <stdio.h> | |
4056 | #include <sys/types.h> | |
4057 | #include <sys/stat.h> | |
4058 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ | |
4059 | struct buf { int x; }; | |
4060 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
4061 | static char *e (p, i) | |
4062 | char **p; | |
4063 | int i; | |
4064 | { | |
4065 | return p[i]; | |
4066 | } | |
4067 | static char *f (char * (*g) (char **, int), char **p, ...) | |
4068 | { | |
4069 | char *s; | |
4070 | va_list v; | |
4071 | va_start (v,p); | |
4072 | s = g (p, va_arg (v,int)); | |
4073 | va_end (v); | |
4074 | return s; | |
4075 | } | |
4076 | ||
4077 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
4078 | function prototypes and stuff, but not '\xHH' hex character constants. | |
4079 | These don't provoke an error unfortunately, instead are silently treated | |
4080 | as 'x'. The following induces an error, until -std is added to get | |
4081 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an | |
4082 | array size at least. It's necessary to write '\x00'==0 to get something | |
4083 | that's true only with -std. */ | |
4084 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; | |
4085 | ||
4086 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters | |
4087 | inside strings and character constants. */ | |
4088 | #define FOO(x) 'x' | |
4089 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
4090 | ||
4091 | int test (int i, double x); | |
4092 | struct s1 {int (*f) (int a);}; | |
4093 | struct s2 {int (*f) (double a);}; | |
4094 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
4095 | int argc; | |
4096 | char **argv; | |
f73dda09 JA |
4097 | int |
4098 | main () | |
4099 | { | |
b709b946 | 4100 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
f73dda09 JA |
4101 | ; |
4102 | return 0; | |
4103 | } | |
4104 | _ACEOF | |
b709b946 CR |
4105 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
4106 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
4107 | do | |
4108 | CC="$ac_save_CC $ac_arg" | |
7f947b68 | 4109 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 4110 | ac_cv_prog_cc_c89=$ac_arg |
f73dda09 | 4111 | fi |
b709b946 CR |
4112 | rm -f core conftest.err conftest.$ac_objext |
4113 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
cce855bc | 4114 | done |
b709b946 CR |
4115 | rm -f conftest.$ac_ext |
4116 | CC=$ac_save_CC | |
4117 | ||
f73dda09 | 4118 | fi |
b709b946 CR |
4119 | # AC_CACHE_VAL |
4120 | case "x$ac_cv_prog_cc_c89" in | |
4121 | x) | |
7f947b68 | 4122 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 |
dd4f3dd8 | 4123 | $as_echo "none needed" >&6; } ;; |
b709b946 | 4124 | xno) |
7f947b68 | 4125 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 |
dd4f3dd8 | 4126 | $as_echo "unsupported" >&6; } ;; |
b709b946 CR |
4127 | *) |
4128 | CC="$CC $ac_cv_prog_cc_c89" | |
7f947b68 | 4129 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 |
dd4f3dd8 | 4130 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; |
b709b946 | 4131 | esac |
7f947b68 | 4132 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
cce855bc | 4133 | |
7f947b68 | 4134 | fi |
5e4a95c7 | 4135 | |
f73dda09 JA |
4136 | ac_ext=c |
4137 | ac_cpp='$CPP $CPPFLAGS' | |
4138 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4139 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4140 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
bb70624e | 4141 | |
a82a04b3 CR |
4142 | |
4143 | ||
4144 | ||
7f947b68 | 4145 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strerror in -lcposix" >&5 |
dd4f3dd8 | 4146 | $as_echo_n "checking for strerror in -lcposix... " >&6; } |
7f947b68 | 4147 | if ${ac_cv_lib_cposix_strerror+:} false; then : |
dd4f3dd8 | 4148 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
4149 | else |
4150 | ac_check_lib_save_LIBS=$LIBS | |
4151 | LIBS="-lcposix $LIBS" | |
7f947b68 | 4152 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4153 | /* end confdefs.h. */ |
ccc6cda3 | 4154 | |
b709b946 CR |
4155 | /* Override any GCC internal prototype to avoid an error. |
4156 | Use char because int might match the return type of a GCC | |
4157 | builtin and then its argument prototype would still apply. */ | |
5e13499c CR |
4158 | #ifdef __cplusplus |
4159 | extern "C" | |
4160 | #endif | |
5e13499c CR |
4161 | char strerror (); |
4162 | int | |
4163 | main () | |
4164 | { | |
b709b946 | 4165 | return strerror (); |
5e13499c CR |
4166 | ; |
4167 | return 0; | |
4168 | } | |
4169 | _ACEOF | |
7f947b68 | 4170 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c | 4171 | ac_cv_lib_cposix_strerror=yes |
ccc6cda3 | 4172 | else |
7f947b68 | 4173 | ac_cv_lib_cposix_strerror=no |
5e13499c | 4174 | fi |
7f947b68 CR |
4175 | rm -f core conftest.err conftest.$ac_objext \ |
4176 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
4177 | LIBS=$ac_check_lib_save_LIBS |
4178 | fi | |
7f947b68 | 4179 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_cposix_strerror" >&5 |
dd4f3dd8 | 4180 | $as_echo "$ac_cv_lib_cposix_strerror" >&6; } |
7f947b68 | 4181 | if test "x$ac_cv_lib_cposix_strerror" = xyes; then : |
5e13499c | 4182 | LIBS="$LIBS -lcposix" |
ccc6cda3 JA |
4183 | fi |
4184 | ||
a82a04b3 CR |
4185 | |
4186 | ||
f73dda09 JA |
4187 | ac_ext=c |
4188 | ac_cpp='$CPP $CPPFLAGS' | |
4189 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4190 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4191 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
7f947b68 | 4192 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 |
dd4f3dd8 | 4193 | $as_echo_n "checking how to run the C preprocessor... " >&6; } |
ccc6cda3 JA |
4194 | # On Suns, sometimes $CPP names a directory. |
4195 | if test -n "$CPP" && test -d "$CPP"; then | |
4196 | CPP= | |
4197 | fi | |
4198 | if test -z "$CPP"; then | |
7f947b68 | 4199 | if ${ac_cv_prog_CPP+:} false; then : |
dd4f3dd8 | 4200 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
4201 | else |
4202 | # Double quotes because CPP needs to be expanded | |
4203 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
4204 | do | |
4205 | ac_preproc_ok=false | |
4206 | for ac_c_preproc_warn_flag in '' yes | |
4207 | do | |
4208 | # Use a header file that comes with gcc, so configuring glibc | |
4209 | # with a fresh cross-compiler works. | |
5e4a95c7 CR |
4210 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
4211 | # <limits.h> exists even on freestanding compilers. | |
ccc6cda3 | 4212 | # On the NeXT, cc -E runs the code through the compiler's parser, |
f73dda09 | 4213 | # not just through cpp. "Syntax error" is here to catch this case. |
7f947b68 | 4214 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
4215 | /* end confdefs.h. */ |
4216 | #ifdef __STDC__ | |
4217 | # include <limits.h> | |
4218 | #else | |
4219 | # include <assert.h> | |
4220 | #endif | |
4221 | Syntax error | |
f73dda09 | 4222 | _ACEOF |
7f947b68 | 4223 | if ac_fn_c_try_cpp "$LINENO"; then : |
abe2eb5b | 4224 | |
7f947b68 | 4225 | else |
f73dda09 JA |
4226 | # Broken: fails on valid input. |
4227 | continue | |
4228 | fi | |
7f947b68 | 4229 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4230 | |
b709b946 | 4231 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4232 | # can be detected and how. |
7f947b68 | 4233 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4234 | /* end confdefs.h. */ |
f73dda09 JA |
4235 | #include <ac_nonexistent.h> |
4236 | _ACEOF | |
7f947b68 | 4237 | if ac_fn_c_try_cpp "$LINENO"; then : |
f73dda09 JA |
4238 | # Broken: success on invalid input. |
4239 | continue | |
bb70624e | 4240 | else |
f73dda09 JA |
4241 | # Passes both tests. |
4242 | ac_preproc_ok=: | |
4243 | break | |
4244 | fi | |
7f947b68 | 4245 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 JA |
4246 | |
4247 | done | |
4248 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
7f947b68 CR |
4249 | rm -f conftest.i conftest.err conftest.$ac_ext |
4250 | if $ac_preproc_ok; then : | |
f73dda09 JA |
4251 | break |
4252 | fi | |
4253 | ||
4254 | done | |
4255 | ac_cv_prog_CPP=$CPP | |
4256 | ||
4257 | fi | |
4258 | CPP=$ac_cv_prog_CPP | |
4259 | else | |
4260 | ac_cv_prog_CPP=$CPP | |
4261 | fi | |
7f947b68 | 4262 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 |
dd4f3dd8 | 4263 | $as_echo "$CPP" >&6; } |
f73dda09 JA |
4264 | ac_preproc_ok=false |
4265 | for ac_c_preproc_warn_flag in '' yes | |
4266 | do | |
4267 | # Use a header file that comes with gcc, so configuring glibc | |
4268 | # with a fresh cross-compiler works. | |
5e4a95c7 CR |
4269 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since |
4270 | # <limits.h> exists even on freestanding compilers. | |
f73dda09 JA |
4271 | # On the NeXT, cc -E runs the code through the compiler's parser, |
4272 | # not just through cpp. "Syntax error" is here to catch this case. | |
7f947b68 | 4273 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
4274 | /* end confdefs.h. */ |
4275 | #ifdef __STDC__ | |
4276 | # include <limits.h> | |
4277 | #else | |
4278 | # include <assert.h> | |
4279 | #endif | |
4280 | Syntax error | |
f73dda09 | 4281 | _ACEOF |
7f947b68 | 4282 | if ac_fn_c_try_cpp "$LINENO"; then : |
abe2eb5b | 4283 | |
7f947b68 | 4284 | else |
f73dda09 JA |
4285 | # Broken: fails on valid input. |
4286 | continue | |
4287 | fi | |
7f947b68 | 4288 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 | 4289 | |
b709b946 | 4290 | # OK, works on sane cases. Now check whether nonexistent headers |
f73dda09 | 4291 | # can be detected and how. |
7f947b68 | 4292 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4293 | /* end confdefs.h. */ |
f73dda09 JA |
4294 | #include <ac_nonexistent.h> |
4295 | _ACEOF | |
7f947b68 | 4296 | if ac_fn_c_try_cpp "$LINENO"; then : |
f73dda09 JA |
4297 | # Broken: success on invalid input. |
4298 | continue | |
4299 | else | |
f73dda09 JA |
4300 | # Passes both tests. |
4301 | ac_preproc_ok=: | |
4302 | break | |
ccc6cda3 | 4303 | fi |
7f947b68 | 4304 | rm -f conftest.err conftest.i conftest.$ac_ext |
f73dda09 JA |
4305 | |
4306 | done | |
4307 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
7f947b68 CR |
4308 | rm -f conftest.i conftest.err conftest.$ac_ext |
4309 | if $ac_preproc_ok; then : | |
4310 | ||
ccc6cda3 | 4311 | else |
7f947b68 | 4312 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
af98a2a6 | 4313 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} |
7f947b68 CR |
4314 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
4315 | See \`config.log' for more details" "$LINENO" 5; } | |
ccc6cda3 | 4316 | fi |
ccc6cda3 | 4317 | |
f73dda09 JA |
4318 | ac_ext=c |
4319 | ac_cpp='$CPP $CPPFLAGS' | |
4320 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4321 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4322 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4323 | ||
a82a04b3 | 4324 | |
7f947b68 | 4325 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
dd4f3dd8 | 4326 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } |
7f947b68 | 4327 | if ${ac_cv_path_GREP+:} false; then : |
dd4f3dd8 | 4328 | $as_echo_n "(cached) " >&6 |
b709b946 | 4329 | else |
dd4f3dd8 | 4330 | if test -z "$GREP"; then |
b709b946 | 4331 | ac_path_GREP_found=false |
dd4f3dd8 CR |
4332 | # Loop through the user's path and test for each of PROGNAME-LIST |
4333 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
b709b946 CR |
4334 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
4335 | do | |
4336 | IFS=$as_save_IFS | |
4337 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 4338 | for ac_prog in grep ggrep; do |
dd4f3dd8 CR |
4339 | for ac_exec_ext in '' $ac_executable_extensions; do |
4340 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
4341 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue | |
4342 | # Check for GNU ac_path_GREP and select it if it is found. | |
b709b946 CR |
4343 | # Check for GNU $ac_path_GREP |
4344 | case `"$ac_path_GREP" --version 2>&1` in | |
4345 | *GNU*) | |
4346 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
4347 | *) | |
4348 | ac_count=0 | |
dd4f3dd8 | 4349 | $as_echo_n 0123456789 >"conftest.in" |
b709b946 CR |
4350 | while : |
4351 | do | |
4352 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4353 | mv "conftest.tmp" "conftest.in" | |
4354 | cp "conftest.in" "conftest.nl" | |
dd4f3dd8 | 4355 | $as_echo 'GREP' >> "conftest.nl" |
b709b946 CR |
4356 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
4357 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
7f947b68 | 4358 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
b709b946 CR |
4359 | if test $ac_count -gt ${ac_path_GREP_max-0}; then |
4360 | # Best one so far, save it but keep looking for a better one | |
4361 | ac_cv_path_GREP="$ac_path_GREP" | |
4362 | ac_path_GREP_max=$ac_count | |
4363 | fi | |
4364 | # 10*(2^10) chars as input seems more than enough | |
4365 | test $ac_count -gt 10 && break | |
4366 | done | |
4367 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4368 | esac | |
4369 | ||
dd4f3dd8 CR |
4370 | $ac_path_GREP_found && break 3 |
4371 | done | |
b709b946 | 4372 | done |
7f947b68 | 4373 | done |
b709b946 | 4374 | IFS=$as_save_IFS |
dd4f3dd8 | 4375 | if test -z "$ac_cv_path_GREP"; then |
7f947b68 | 4376 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
dd4f3dd8 | 4377 | fi |
b709b946 CR |
4378 | else |
4379 | ac_cv_path_GREP=$GREP | |
4380 | fi | |
4381 | ||
b709b946 | 4382 | fi |
7f947b68 | 4383 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
dd4f3dd8 | 4384 | $as_echo "$ac_cv_path_GREP" >&6; } |
b709b946 CR |
4385 | GREP="$ac_cv_path_GREP" |
4386 | ||
4387 | ||
7f947b68 | 4388 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
dd4f3dd8 | 4389 | $as_echo_n "checking for egrep... " >&6; } |
7f947b68 | 4390 | if ${ac_cv_path_EGREP+:} false; then : |
dd4f3dd8 | 4391 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
4392 | else |
4393 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 | |
4394 | then ac_cv_path_EGREP="$GREP -E" | |
4395 | else | |
dd4f3dd8 | 4396 | if test -z "$EGREP"; then |
b709b946 | 4397 | ac_path_EGREP_found=false |
dd4f3dd8 CR |
4398 | # Loop through the user's path and test for each of PROGNAME-LIST |
4399 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
b709b946 CR |
4400 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin |
4401 | do | |
4402 | IFS=$as_save_IFS | |
4403 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 4404 | for ac_prog in egrep; do |
dd4f3dd8 CR |
4405 | for ac_exec_ext in '' $ac_executable_extensions; do |
4406 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
4407 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue | |
4408 | # Check for GNU ac_path_EGREP and select it if it is found. | |
b709b946 CR |
4409 | # Check for GNU $ac_path_EGREP |
4410 | case `"$ac_path_EGREP" --version 2>&1` in | |
4411 | *GNU*) | |
4412 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
4413 | *) | |
4414 | ac_count=0 | |
dd4f3dd8 | 4415 | $as_echo_n 0123456789 >"conftest.in" |
b709b946 CR |
4416 | while : |
4417 | do | |
4418 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4419 | mv "conftest.tmp" "conftest.in" | |
4420 | cp "conftest.in" "conftest.nl" | |
dd4f3dd8 | 4421 | $as_echo 'EGREP' >> "conftest.nl" |
b709b946 CR |
4422 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break |
4423 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
7f947b68 | 4424 | as_fn_arith $ac_count + 1 && ac_count=$as_val |
b709b946 CR |
4425 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then |
4426 | # Best one so far, save it but keep looking for a better one | |
4427 | ac_cv_path_EGREP="$ac_path_EGREP" | |
4428 | ac_path_EGREP_max=$ac_count | |
5e4a95c7 | 4429 | fi |
b709b946 CR |
4430 | # 10*(2^10) chars as input seems more than enough |
4431 | test $ac_count -gt 10 && break | |
4432 | done | |
4433 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4434 | esac | |
4435 | ||
dd4f3dd8 CR |
4436 | $ac_path_EGREP_found && break 3 |
4437 | done | |
b709b946 | 4438 | done |
7f947b68 | 4439 | done |
b709b946 | 4440 | IFS=$as_save_IFS |
dd4f3dd8 | 4441 | if test -z "$ac_cv_path_EGREP"; then |
7f947b68 | 4442 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
dd4f3dd8 | 4443 | fi |
b709b946 CR |
4444 | else |
4445 | ac_cv_path_EGREP=$EGREP | |
4446 | fi | |
4447 | ||
b709b946 | 4448 | fi |
d3ad40de | 4449 | fi |
7f947b68 | 4450 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
dd4f3dd8 | 4451 | $as_echo "$ac_cv_path_EGREP" >&6; } |
b709b946 | 4452 | EGREP="$ac_cv_path_EGREP" |
d3ad40de | 4453 | |
9d6e5e30 | 4454 | |
7f947b68 | 4455 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
dd4f3dd8 | 4456 | $as_echo_n "checking for ANSI C header files... " >&6; } |
7f947b68 | 4457 | if ${ac_cv_header_stdc+:} false; then : |
dd4f3dd8 | 4458 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 4459 | else |
7f947b68 | 4460 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4461 | /* end confdefs.h. */ |
a82a04b3 CR |
4462 | #include <stdlib.h> |
4463 | #include <stdarg.h> | |
4464 | #include <string.h> | |
4465 | #include <float.h> | |
4466 | ||
5e4a95c7 CR |
4467 | int |
4468 | main () | |
4469 | { | |
4470 | ||
4471 | ; | |
4472 | return 0; | |
4473 | } | |
a82a04b3 | 4474 | _ACEOF |
7f947b68 | 4475 | if ac_fn_c_try_compile "$LINENO"; then : |
a82a04b3 | 4476 | ac_cv_header_stdc=yes |
f73dda09 | 4477 | else |
7f947b68 | 4478 | ac_cv_header_stdc=no |
a82a04b3 | 4479 | fi |
b709b946 | 4480 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
a82a04b3 CR |
4481 | |
4482 | if test $ac_cv_header_stdc = yes; then | |
4483 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
7f947b68 | 4484 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4485 | /* end confdefs.h. */ |
a82a04b3 CR |
4486 | #include <string.h> |
4487 | ||
4488 | _ACEOF | |
4489 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 CR |
4490 | $EGREP "memchr" >/dev/null 2>&1; then : |
4491 | ||
a82a04b3 CR |
4492 | else |
4493 | ac_cv_header_stdc=no | |
4494 | fi | |
4495 | rm -f conftest* | |
4496 | ||
4497 | fi | |
4498 | ||
4499 | if test $ac_cv_header_stdc = yes; then | |
4500 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
7f947b68 | 4501 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4502 | /* end confdefs.h. */ |
a82a04b3 CR |
4503 | #include <stdlib.h> |
4504 | ||
4505 | _ACEOF | |
4506 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 CR |
4507 | $EGREP "free" >/dev/null 2>&1; then : |
4508 | ||
a82a04b3 CR |
4509 | else |
4510 | ac_cv_header_stdc=no | |
4511 | fi | |
4512 | rm -f conftest* | |
4513 | ||
4514 | fi | |
4515 | ||
4516 | if test $ac_cv_header_stdc = yes; then | |
4517 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
7f947b68 | 4518 | if test "$cross_compiling" = yes; then : |
a82a04b3 CR |
4519 | : |
4520 | else | |
7f947b68 | 4521 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4522 | /* end confdefs.h. */ |
a82a04b3 | 4523 | #include <ctype.h> |
b709b946 | 4524 | #include <stdlib.h> |
a82a04b3 CR |
4525 | #if ((' ' & 0x0FF) == 0x020) |
4526 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4527 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4528 | #else | |
5e4a95c7 CR |
4529 | # define ISLOWER(c) \ |
4530 | (('a' <= (c) && (c) <= 'i') \ | |
4531 | || ('j' <= (c) && (c) <= 'r') \ | |
4532 | || ('s' <= (c) && (c) <= 'z')) | |
a82a04b3 CR |
4533 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) |
4534 | #endif | |
4535 | ||
4536 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
4537 | int | |
4538 | main () | |
4539 | { | |
4540 | int i; | |
4541 | for (i = 0; i < 256; i++) | |
4542 | if (XOR (islower (i), ISLOWER (i)) | |
5e4a95c7 | 4543 | || toupper (i) != TOUPPER (i)) |
b709b946 CR |
4544 | return 2; |
4545 | return 0; | |
a82a04b3 CR |
4546 | } |
4547 | _ACEOF | |
7f947b68 | 4548 | if ac_fn_c_try_run "$LINENO"; then : |
abe2eb5b | 4549 | |
7f947b68 CR |
4550 | else |
4551 | ac_cv_header_stdc=no | |
a82a04b3 | 4552 | fi |
7f947b68 CR |
4553 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
4554 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
a82a04b3 | 4555 | fi |
b709b946 | 4556 | |
a82a04b3 CR |
4557 | fi |
4558 | fi | |
7f947b68 | 4559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
dd4f3dd8 | 4560 | $as_echo "$ac_cv_header_stdc" >&6; } |
a82a04b3 CR |
4561 | if test $ac_cv_header_stdc = yes; then |
4562 | ||
7f947b68 | 4563 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
2dead0c4 CR |
4564 | |
4565 | fi | |
4566 | ||
abe2eb5b | 4567 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
7f947b68 CR |
4568 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ |
4569 | inttypes.h stdint.h unistd.h | |
4570 | do : | |
4571 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
4572 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
4573 | " | |
4574 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
4575 | cat >>confdefs.h <<_ACEOF | |
4576 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
4577 | _ACEOF | |
4578 | ||
4579 | fi | |
4580 | ||
4581 | done | |
4582 | ||
4583 | ||
71412226 | 4584 | |
7f947b68 CR |
4585 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
4586 | if test "x$ac_cv_header_minix_config_h" = xyes; then : | |
4587 | MINIX=yes | |
4588 | else | |
4589 | MINIX= | |
4590 | fi | |
c920c360 | 4591 | |
c920c360 | 4592 | |
7f947b68 | 4593 | if test "$MINIX" = yes; then |
c920c360 | 4594 | |
7f947b68 | 4595 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
c920c360 | 4596 | |
2dead0c4 | 4597 | |
7f947b68 | 4598 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h |
2dead0c4 | 4599 | |
2dead0c4 | 4600 | |
7f947b68 | 4601 | $as_echo "#define _MINIX 1" >>confdefs.h |
2dead0c4 | 4602 | |
7f947b68 CR |
4603 | fi |
4604 | ||
4605 | ||
4606 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 | |
4607 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } | |
4608 | if ${ac_cv_safe_to_define___extensions__+:} false; then : | |
dd4f3dd8 | 4609 | $as_echo_n "(cached) " >&6 |
a82a04b3 | 4610 | else |
7f947b68 | 4611 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4612 | /* end confdefs.h. */ |
a82a04b3 | 4613 | |
7f947b68 CR |
4614 | # define __EXTENSIONS__ 1 |
4615 | $ac_includes_default | |
4616 | int | |
4617 | main () | |
4618 | { | |
4619 | ||
4620 | ; | |
4621 | return 0; | |
4622 | } | |
a82a04b3 | 4623 | _ACEOF |
7f947b68 CR |
4624 | if ac_fn_c_try_compile "$LINENO"; then : |
4625 | ac_cv_safe_to_define___extensions__=yes | |
7610e0c5 | 4626 | else |
7f947b68 | 4627 | ac_cv_safe_to_define___extensions__=no |
7610e0c5 | 4628 | fi |
7610e0c5 CR |
4629 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4630 | fi | |
7f947b68 CR |
4631 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
4632 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } | |
4633 | test $ac_cv_safe_to_define___extensions__ = yes && | |
4634 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h | |
7610e0c5 | 4635 | |
7f947b68 | 4636 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
2dead0c4 | 4637 | |
7f947b68 | 4638 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
7610e0c5 | 4639 | |
7f947b68 CR |
4640 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
4641 | ||
4642 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
7610e0c5 | 4643 | |
c920c360 | 4644 | |
2dead0c4 | 4645 | |
7f947b68 CR |
4646 | |
4647 | # Check whether --enable-largefile was given. | |
4648 | if test "${enable_largefile+set}" = set; then : | |
4649 | enableval=$enable_largefile; | |
7610e0c5 CR |
4650 | fi |
4651 | ||
7f947b68 | 4652 | if test "$enable_largefile" != no; then |
7610e0c5 | 4653 | |
7f947b68 | 4654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 |
abe2eb5b | 4655 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } |
7f947b68 | 4656 | if ${ac_cv_sys_largefile_CC+:} false; then : |
abe2eb5b CR |
4657 | $as_echo_n "(cached) " >&6 |
4658 | else | |
4659 | ac_cv_sys_largefile_CC=no | |
4660 | if test "$GCC" != yes; then | |
4661 | ac_save_CC=$CC | |
4662 | while :; do | |
4663 | # IRIX 6.2 and later do not support large files by default, | |
4664 | # so use the C compiler's -n32 option if that helps. | |
7f947b68 | 4665 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b CR |
4666 | /* end confdefs.h. */ |
4667 | #include <sys/types.h> | |
4668 | /* Check that off_t can represent 2**63 - 1 correctly. | |
e3db237e CR |
4669 | We can't simply define LARGE_OFF_T to be 9223372036854775807, |
4670 | since some C++ compilers masquerading as C compilers | |
4671 | incorrectly reject 9223372036854775807. */ | |
f73dda09 JA |
4672 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
4673 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4674 | && LARGE_OFF_T % 2147483647 == 1) | |
4675 | ? 1 : -1]; | |
4676 | int | |
4677 | main () | |
4678 | { | |
bb70624e | 4679 | |
f73dda09 JA |
4680 | ; |
4681 | return 0; | |
4682 | } | |
4683 | _ACEOF | |
7f947b68 | 4684 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4685 | break |
f73dda09 | 4686 | fi |
b709b946 CR |
4687 | rm -f core conftest.err conftest.$ac_objext |
4688 | CC="$CC -n32" | |
7f947b68 | 4689 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4690 | ac_cv_sys_largefile_CC=' -n32'; break |
f73dda09 | 4691 | fi |
b709b946 | 4692 | rm -f core conftest.err conftest.$ac_objext |
5e4a95c7 | 4693 | break |
f73dda09 JA |
4694 | done |
4695 | CC=$ac_save_CC | |
4696 | rm -f conftest.$ac_ext | |
4697 | fi | |
bb70624e | 4698 | fi |
7f947b68 | 4699 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 |
dd4f3dd8 | 4700 | $as_echo "$ac_cv_sys_largefile_CC" >&6; } |
f73dda09 JA |
4701 | if test "$ac_cv_sys_largefile_CC" != no; then |
4702 | CC=$CC$ac_cv_sys_largefile_CC | |
4703 | fi | |
bb70624e | 4704 | |
7f947b68 | 4705 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 |
dd4f3dd8 | 4706 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } |
7f947b68 | 4707 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
dd4f3dd8 | 4708 | $as_echo_n "(cached) " >&6 |
bb70624e | 4709 | else |
f73dda09 | 4710 | while :; do |
7f947b68 | 4711 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4712 | /* end confdefs.h. */ |
f73dda09 JA |
4713 | #include <sys/types.h> |
4714 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4715 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4716 | since some C++ compilers masquerading as C compilers | |
4717 | incorrectly reject 9223372036854775807. */ | |
4718 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4719 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4720 | && LARGE_OFF_T % 2147483647 == 1) | |
4721 | ? 1 : -1]; | |
4722 | int | |
4723 | main () | |
4724 | { | |
bb70624e | 4725 | |
f73dda09 JA |
4726 | ; |
4727 | return 0; | |
4728 | } | |
4729 | _ACEOF | |
7f947b68 | 4730 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 4731 | ac_cv_sys_file_offset_bits=no; break |
2e4498b3 | 4732 | fi |
2e4498b3 | 4733 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7f947b68 | 4734 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2e4498b3 | 4735 | /* end confdefs.h. */ |
f73dda09 JA |
4736 | #define _FILE_OFFSET_BITS 64 |
4737 | #include <sys/types.h> | |
4738 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4739 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4740 | since some C++ compilers masquerading as C compilers | |
4741 | incorrectly reject 9223372036854775807. */ | |
4742 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4743 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4744 | && LARGE_OFF_T % 2147483647 == 1) | |
4745 | ? 1 : -1]; | |
4746 | int | |
4747 | main () | |
4748 | { | |
bb70624e | 4749 | |
f73dda09 JA |
4750 | ; |
4751 | return 0; | |
4752 | } | |
4753 | _ACEOF | |
7f947b68 | 4754 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4755 | ac_cv_sys_file_offset_bits=64; break |
f73dda09 | 4756 | fi |
b709b946 | 4757 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 4758 | ac_cv_sys_file_offset_bits=unknown |
f73dda09 JA |
4759 | break |
4760 | done | |
4761 | fi | |
7f947b68 | 4762 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 |
dd4f3dd8 CR |
4763 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } |
4764 | case $ac_cv_sys_file_offset_bits in #( | |
4765 | no | unknown) ;; | |
4766 | *) | |
a82a04b3 | 4767 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4768 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits |
a82a04b3 | 4769 | _ACEOF |
dd4f3dd8 CR |
4770 | ;; |
4771 | esac | |
4772 | rm -rf conftest* | |
4773 | if test $ac_cv_sys_file_offset_bits = unknown; then | |
7f947b68 | 4774 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 |
dd4f3dd8 | 4775 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } |
7f947b68 | 4776 | if ${ac_cv_sys_large_files+:} false; then : |
dd4f3dd8 | 4777 | $as_echo_n "(cached) " >&6 |
bb70624e | 4778 | else |
f73dda09 | 4779 | while :; do |
7f947b68 | 4780 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4781 | /* end confdefs.h. */ |
f73dda09 JA |
4782 | #include <sys/types.h> |
4783 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4784 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4785 | since some C++ compilers masquerading as C compilers | |
4786 | incorrectly reject 9223372036854775807. */ | |
4787 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4788 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4789 | && LARGE_OFF_T % 2147483647 == 1) | |
4790 | ? 1 : -1]; | |
4791 | int | |
4792 | main () | |
4793 | { | |
4794 | ||
4795 | ; | |
4796 | return 0; | |
4797 | } | |
4798 | _ACEOF | |
7f947b68 | 4799 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 4800 | ac_cv_sys_large_files=no; break |
bb70624e | 4801 | fi |
b709b946 | 4802 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7f947b68 | 4803 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4804 | /* end confdefs.h. */ |
f73dda09 JA |
4805 | #define _LARGE_FILES 1 |
4806 | #include <sys/types.h> | |
4807 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4808 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4809 | since some C++ compilers masquerading as C compilers | |
4810 | incorrectly reject 9223372036854775807. */ | |
4811 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) | |
4812 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 | |
4813 | && LARGE_OFF_T % 2147483647 == 1) | |
4814 | ? 1 : -1]; | |
4815 | int | |
4816 | main () | |
4817 | { | |
bb70624e | 4818 | |
f73dda09 JA |
4819 | ; |
4820 | return 0; | |
4821 | } | |
4822 | _ACEOF | |
7f947b68 | 4823 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 4824 | ac_cv_sys_large_files=1; break |
f73dda09 | 4825 | fi |
b709b946 | 4826 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 4827 | ac_cv_sys_large_files=unknown |
f73dda09 JA |
4828 | break |
4829 | done | |
4830 | fi | |
7f947b68 | 4831 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 |
dd4f3dd8 CR |
4832 | $as_echo "$ac_cv_sys_large_files" >&6; } |
4833 | case $ac_cv_sys_large_files in #( | |
4834 | no | unknown) ;; | |
4835 | *) | |
a82a04b3 | 4836 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 4837 | #define _LARGE_FILES $ac_cv_sys_large_files |
a82a04b3 | 4838 | _ACEOF |
dd4f3dd8 CR |
4839 | ;; |
4840 | esac | |
4841 | rm -rf conftest* | |
4842 | fi | |
f73dda09 | 4843 | fi |
cce855bc | 4844 | |
a82a04b3 CR |
4845 | |
4846 | ||
dc8fbaf9 | 4847 | SIGNAMES_O= |
b72432fd JA |
4848 | SIGNAMES_H=lsignames.h |
4849 | ||
a82a04b3 CR |
4850 | |
4851 | ||
d3ad40de | 4852 | CROSS_COMPILE= |
cce855bc JA |
4853 | if test "x$cross_compiling" = "xyes"; then |
4854 | case "${host}" in | |
28ef6c31 | 4855 | *-cygwin*) |
cce855bc | 4856 | cross_cache=${srcdir}/cross-build/cygwin32.cache |
cce855bc | 4857 | ;; |
9607141c CR |
4858 | *-mingw*) |
4859 | cross_cache=${srcdir}/cross-build/cygwin32.cache | |
4860 | ;; | |
b72432fd JA |
4861 | i[3456]86-*-beos*) |
4862 | cross_cache=${srcdir}/cross-build/x86-beos.cache | |
b72432fd JA |
4863 | ;; |
4864 | *) echo "configure: cross-compiling for $host is not supported" >&2 | |
cce855bc JA |
4865 | ;; |
4866 | esac | |
b72432fd JA |
4867 | if test -n "${cross_cache}" && test -r "${cross_cache}"; then |
4868 | echo "loading cross-build cache file ${cross_cache}" | |
4869 | . ${cross_cache} | |
4870 | fi | |
4871 | unset cross_cache | |
dc8fbaf9 | 4872 | SIGNAMES_O='signames.o' |
9607141c CR |
4873 | CROSS_COMPILE='-DCROSS_COMPILING' |
4874 | ||
cce855bc JA |
4875 | fi |
4876 | ||
a82a04b3 | 4877 | |
dc8fbaf9 | 4878 | |
a82a04b3 | 4879 | |
7610e0c5 CR |
4880 | if test -z "$CFLAGS"; then |
4881 | AUTO_CFLAGS="-g ${GCC+-O2}" | |
4882 | AUTO_LDFLAGS="-g ${GCC+-O2}" | |
4883 | else | |
4884 | AUTO_CFLAGS= AUTO_LDFLAGS= | |
4885 | fi | |
ccc6cda3 | 4886 | |
7610e0c5 CR |
4887 | CFLAGS=${CFLAGS-"$AUTO_CFLAGS"} |
4888 | # LDFLAGS=${LDFLAGS="$AUTO_LDFLAGS"} # XXX | |
ccc6cda3 | 4889 | |
cce855bc JA |
4890 | if test "$opt_profiling" = "yes"; then |
4891 | PROFILE_FLAGS=-pg | |
b72432fd JA |
4892 | case "$host_os" in |
4893 | solaris2*) ;; | |
4894 | *) opt_static_link=yes ;; | |
4895 | esac | |
7117c2d2 | 4896 | DEBUG= MALLOC_DEBUG= |
cce855bc JA |
4897 | fi |
4898 | ||
f4f5e1c2 CR |
4899 | prefer_shared=yes |
4900 | prefer_static=no | |
4901 | ||
cce855bc | 4902 | if test "$opt_static_link" = yes; then |
f4f5e1c2 CR |
4903 | prefer_static=yes |
4904 | prefer_shared=no | |
f73dda09 JA |
4905 | # if we're using gcc, add `-static' to LDFLAGS, except on Solaris >= 2 |
4906 | if test -n "$GCC" || test "$ac_cv_c_compiler_gnu" = "yes"; then | |
b72432fd | 4907 | STATIC_LD="-static" |
f73dda09 JA |
4908 | case "$host_os" in |
4909 | solaris2*) ;; | |
4910 | *) LDFLAGS="$LDFLAGS -static" ;; # XXX experimental | |
4911 | esac | |
cce855bc JA |
4912 | fi |
4913 | fi | |
4914 | ||
7610e0c5 | 4915 | # set the appropriate make variables for building the "build tools" |
348a457e CR |
4916 | # modify defaults based on whether or not we are cross compiling, since the |
4917 | # options for the target host may not be appropriate for the build host | |
da5b17cd | 4918 | if test "X$cross_compiling" = "Xno"; then |
7610e0c5 CR |
4919 | CC_FOR_BUILD=${CC_FOR_BUILD-'$(CC)'} |
4920 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-"$CPPFLAGS"} # XXX - should it be '$(CPPFLAGS)' | |
da5b17cd | 4921 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-'$(LDFLAGS)'} |
7610e0c5 CR |
4922 | # CFLAGS set above to default value if not passed in environment |
4923 | CFLAGS_FOR_BUILD=${CFLAGS-'$(CFLAGS)'} | |
4924 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-'$(LIBS)'} | |
da5b17cd | 4925 | else |
7610e0c5 | 4926 | CC_FOR_BUILD=${CC_FOR_BUILD-"gcc"} |
da5b17cd CR |
4927 | CPPFLAGS_FOR_BUILD=${CPPFLAGS_FOR_BUILD-""} |
4928 | LDFLAGS_FOR_BUILD=${LDFLAGS_FOR_BUILD-""} | |
7610e0c5 CR |
4929 | CFLAGS_FOR_BUILD=${CFLAGS_FOR_BUILD="-g"} |
4930 | LIBS_FOR_BUILD=${LIBS_FOR_BUILD-""} | |
da5b17cd CR |
4931 | fi |
4932 | ||
7610e0c5 | 4933 | |
7117c2d2 | 4934 | |
a82a04b3 CR |
4935 | |
4936 | ||
4937 | ||
4938 | ||
4939 | ||
4940 | ||
4941 | ||
4942 | ||
4943 | ||
f73dda09 | 4944 | if test $ac_cv_c_compiler_gnu = yes; then |
7f947b68 | 4945 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 |
dd4f3dd8 | 4946 | $as_echo_n "checking whether $CC needs -traditional... " >&6; } |
7f947b68 | 4947 | if ${ac_cv_prog_gcc_traditional+:} false; then : |
dd4f3dd8 | 4948 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
4949 | else |
4950 | ac_pattern="Autoconf.*'x'" | |
7f947b68 | 4951 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4952 | /* end confdefs.h. */ |
ccc6cda3 JA |
4953 | #include <sgtty.h> |
4954 | Autoconf TIOCGETP | |
f73dda09 | 4955 | _ACEOF |
ccc6cda3 | 4956 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
7f947b68 | 4957 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
4958 | ac_cv_prog_gcc_traditional=yes |
4959 | else | |
ccc6cda3 JA |
4960 | ac_cv_prog_gcc_traditional=no |
4961 | fi | |
4962 | rm -f conftest* | |
4963 | ||
a82a04b3 | 4964 | |
ccc6cda3 | 4965 | if test $ac_cv_prog_gcc_traditional = no; then |
7f947b68 | 4966 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 4967 | /* end confdefs.h. */ |
ccc6cda3 JA |
4968 | #include <termio.h> |
4969 | Autoconf TCGETA | |
f73dda09 | 4970 | _ACEOF |
ccc6cda3 | 4971 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
7f947b68 | 4972 | $EGREP "$ac_pattern" >/dev/null 2>&1; then : |
ccc6cda3 JA |
4973 | ac_cv_prog_gcc_traditional=yes |
4974 | fi | |
4975 | rm -f conftest* | |
4976 | ||
4977 | fi | |
4978 | fi | |
7f947b68 | 4979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_gcc_traditional" >&5 |
dd4f3dd8 | 4980 | $as_echo "$ac_cv_prog_gcc_traditional" >&6; } |
ccc6cda3 JA |
4981 | if test $ac_cv_prog_gcc_traditional = yes; then |
4982 | CC="$CC -traditional" | |
4983 | fi | |
4984 | fi | |
4985 | ||
a82a04b3 CR |
4986 | |
4987 | ||
f73dda09 | 4988 | if test "$opt_readline" = yes && test "$opt_with_installed_readline" != "no" |
b72432fd | 4989 | then |
f73dda09 JA |
4990 | # If the user specified --with-installed-readline=PREFIX and PREFIX |
4991 | # is not `yes', set ac_cv_rl_prefix to PREFIX | |
4992 | test $opt_with_installed_readline != "yes" && ac_cv_rl_prefix=$opt_with_installed_readline | |
b72432fd | 4993 | |
a82a04b3 | 4994 | |
bb70624e JA |
4995 | if test "X$bash_cv_termcap_lib" = "X"; then |
4996 | _bash_needmsg=yes | |
4997 | else | |
7f947b68 | 4998 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 4999 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e JA |
5000 | _bash_needmsg= |
5001 | fi | |
7f947b68 | 5002 | if ${bash_cv_termcap_lib+:} false; then : |
dd4f3dd8 | 5003 | $as_echo_n "(cached) " >&6 |
bb70624e | 5004 | else |
7f947b68 CR |
5005 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" |
5006 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
5007 | bash_cv_termcap_lib=libc | |
5008 | else | |
5009 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 | |
5010 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } | |
5011 | if ${ac_cv_lib_termcap_tgetent+:} false; then : | |
dd4f3dd8 | 5012 | $as_echo_n "(cached) " >&6 |
bb70624e | 5013 | else |
7f947b68 CR |
5014 | ac_check_lib_save_LIBS=$LIBS |
5015 | LIBS="-ltermcap $LIBS" | |
5016 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5e4a95c7 | 5017 | /* end confdefs.h. */ |
f73dda09 | 5018 | |
b709b946 CR |
5019 | /* Override any GCC internal prototype to avoid an error. |
5020 | Use char because int might match the return type of a GCC | |
5021 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5022 | #ifdef __cplusplus |
5023 | extern "C" | |
5024 | #endif | |
f73dda09 JA |
5025 | char tgetent (); |
5026 | int | |
5027 | main () | |
5028 | { | |
b709b946 | 5029 | return tgetent (); |
f73dda09 JA |
5030 | ; |
5031 | return 0; | |
5032 | } | |
5033 | _ACEOF | |
7f947b68 CR |
5034 | if ac_fn_c_try_link "$LINENO"; then : |
5035 | ac_cv_lib_termcap_tgetent=yes | |
e3db237e | 5036 | else |
7f947b68 | 5037 | ac_cv_lib_termcap_tgetent=no |
e3db237e | 5038 | fi |
7f947b68 CR |
5039 | rm -f core conftest.err conftest.$ac_objext \ |
5040 | conftest$ac_exeext conftest.$ac_ext | |
5041 | LIBS=$ac_check_lib_save_LIBS | |
e3db237e | 5042 | fi |
7f947b68 CR |
5043 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
5044 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } | |
5045 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : | |
5046 | bash_cv_termcap_lib=libtermcap | |
e3db237e | 5047 | else |
7f947b68 CR |
5048 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
5049 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } | |
5050 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : | |
e3db237e CR |
5051 | $as_echo_n "(cached) " >&6 |
5052 | else | |
5053 | ac_check_lib_save_LIBS=$LIBS | |
7f947b68 CR |
5054 | LIBS="-ltinfo $LIBS" |
5055 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e CR |
5056 | /* end confdefs.h. */ |
5057 | ||
5058 | /* Override any GCC internal prototype to avoid an error. | |
5059 | Use char because int might match the return type of a GCC | |
5060 | builtin and then its argument prototype would still apply. */ | |
5061 | #ifdef __cplusplus | |
5062 | extern "C" | |
5063 | #endif | |
5064 | char tgetent (); | |
5065 | int | |
5066 | main () | |
5067 | { | |
5068 | return tgetent (); | |
5069 | ; | |
5070 | return 0; | |
5071 | } | |
5072 | _ACEOF | |
7f947b68 CR |
5073 | if ac_fn_c_try_link "$LINENO"; then : |
5074 | ac_cv_lib_tinfo_tgetent=yes | |
abe2eb5b | 5075 | else |
7f947b68 | 5076 | ac_cv_lib_tinfo_tgetent=no |
abe2eb5b | 5077 | fi |
7f947b68 CR |
5078 | rm -f core conftest.err conftest.$ac_objext \ |
5079 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b CR |
5080 | LIBS=$ac_check_lib_save_LIBS |
5081 | fi | |
7f947b68 | 5082 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
abe2eb5b | 5083 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
7f947b68 | 5084 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
abe2eb5b | 5085 | bash_cv_termcap_lib=libtinfo |
bb70624e | 5086 | else |
7f947b68 | 5087 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
dd4f3dd8 | 5088 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
7f947b68 | 5089 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
dd4f3dd8 | 5090 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5091 | else |
5092 | ac_check_lib_save_LIBS=$LIBS | |
5093 | LIBS="-lcurses $LIBS" | |
7f947b68 | 5094 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5095 | /* end confdefs.h. */ |
b72432fd | 5096 | |
b709b946 CR |
5097 | /* Override any GCC internal prototype to avoid an error. |
5098 | Use char because int might match the return type of a GCC | |
5099 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5100 | #ifdef __cplusplus |
5101 | extern "C" | |
5102 | #endif | |
f73dda09 JA |
5103 | char tgetent (); |
5104 | int | |
5105 | main () | |
5106 | { | |
b709b946 | 5107 | return tgetent (); |
f73dda09 JA |
5108 | ; |
5109 | return 0; | |
5110 | } | |
5111 | _ACEOF | |
7f947b68 | 5112 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5113 | ac_cv_lib_curses_tgetent=yes |
5114 | else | |
7f947b68 | 5115 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 5116 | fi |
7f947b68 CR |
5117 | rm -f core conftest.err conftest.$ac_objext \ |
5118 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5119 | LIBS=$ac_check_lib_save_LIBS |
5120 | fi | |
7f947b68 | 5121 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
dd4f3dd8 | 5122 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
7f947b68 | 5123 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
bb70624e JA |
5124 | bash_cv_termcap_lib=libcurses |
5125 | else | |
7f947b68 | 5126 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
dd4f3dd8 | 5127 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
7f947b68 | 5128 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
dd4f3dd8 | 5129 | $as_echo_n "(cached) " >&6 |
bb70624e | 5130 | else |
f73dda09 | 5131 | ac_check_lib_save_LIBS=$LIBS |
bb70624e | 5132 | LIBS="-lncurses $LIBS" |
7f947b68 | 5133 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5134 | /* end confdefs.h. */ |
f73dda09 | 5135 | |
b709b946 CR |
5136 | /* Override any GCC internal prototype to avoid an error. |
5137 | Use char because int might match the return type of a GCC | |
5138 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
5139 | #ifdef __cplusplus |
5140 | extern "C" | |
5141 | #endif | |
f73dda09 JA |
5142 | char tgetent (); |
5143 | int | |
5144 | main () | |
5145 | { | |
b709b946 | 5146 | return tgetent (); |
f73dda09 JA |
5147 | ; |
5148 | return 0; | |
5149 | } | |
5150 | _ACEOF | |
7f947b68 | 5151 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
5152 | ac_cv_lib_ncurses_tgetent=yes |
5153 | else | |
7f947b68 | 5154 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 5155 | fi |
7f947b68 CR |
5156 | rm -f core conftest.err conftest.$ac_objext \ |
5157 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
5158 | LIBS=$ac_check_lib_save_LIBS |
5159 | fi | |
7f947b68 | 5160 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
dd4f3dd8 | 5161 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
7f947b68 | 5162 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 5163 | bash_cv_termcap_lib=libncurses |
bb70624e | 5164 | else |
f73dda09 | 5165 | bash_cv_termcap_lib=gnutermcap |
bb70624e | 5166 | fi |
bb70624e | 5167 | |
bb70624e JA |
5168 | fi |
5169 | ||
5170 | fi | |
5171 | ||
5172 | fi | |
5173 | ||
5174 | fi | |
5175 | ||
d3a24ed2 CR |
5176 | fi |
5177 | ||
bb70624e | 5178 | if test "X$_bash_needmsg" = "Xyes"; then |
7f947b68 | 5179 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 5180 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
bb70624e | 5181 | fi |
7f947b68 | 5182 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
dd4f3dd8 | 5183 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
bb70624e JA |
5184 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
5185 | LDFLAGS="$LDFLAGS -L./lib/termcap" | |
5186 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
5187 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
5188 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then | |
5189 | TERMCAP_LIB=-ltermcap | |
5190 | TERMCAP_DEP= | |
f73dda09 JA |
5191 | elif test $bash_cv_termcap_lib = libtinfo; then |
5192 | TERMCAP_LIB=-ltinfo | |
5193 | TERMCAP_DEP= | |
bb70624e JA |
5194 | elif test $bash_cv_termcap_lib = libncurses; then |
5195 | TERMCAP_LIB=-lncurses | |
5196 | TERMCAP_DEP= | |
d3a24ed2 CR |
5197 | elif test $bash_cv_termcap_lib = libc; then |
5198 | TERMCAP_LIB= | |
5199 | TERMCAP_DEP= | |
bb70624e JA |
5200 | else |
5201 | TERMCAP_LIB=-lcurses | |
5202 | TERMCAP_DEP= | |
5203 | fi | |
5204 | ||
a82a04b3 CR |
5205 | |
5206 | ||
5207 | ||
7f947b68 | 5208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of installed readline library" >&5 |
dd4f3dd8 | 5209 | $as_echo_n "checking version of installed readline library... " >&6; } |
f73dda09 JA |
5210 | |
5211 | # What a pain in the ass this is. | |
5212 | ||
5213 | # save cpp and ld options | |
5214 | _save_CFLAGS="$CFLAGS" | |
5215 | _save_LDFLAGS="$LDFLAGS" | |
5216 | _save_LIBS="$LIBS" | |
5217 | ||
5218 | # Don't set ac_cv_rl_prefix if the caller has already assigned a value. This | |
5219 | # allows the caller to do something like $_rl_prefix=$withval if the user | |
5220 | # specifies --with-installed-readline=PREFIX as an argument to configure | |
5221 | ||
5222 | if test -z "$ac_cv_rl_prefix"; then | |
5223 | test "x$prefix" = xNONE && ac_cv_rl_prefix=$ac_default_prefix || ac_cv_rl_prefix=${prefix} | |
5224 | fi | |
5225 | ||
5226 | eval ac_cv_rl_includedir=${ac_cv_rl_prefix}/include | |
5227 | eval ac_cv_rl_libdir=${ac_cv_rl_prefix}/lib | |
5228 | ||
5229 | LIBS="$LIBS -lreadline ${TERMCAP_LIB}" | |
5230 | CFLAGS="$CFLAGS -I${ac_cv_rl_includedir}" | |
5231 | LDFLAGS="$LDFLAGS -L${ac_cv_rl_libdir}" | |
5232 | ||
7f947b68 | 5233 | if ${ac_cv_rl_version+:} false; then : |
dd4f3dd8 | 5234 | $as_echo_n "(cached) " >&6 |
d3a24ed2 | 5235 | else |
7f947b68 | 5236 | if test "$cross_compiling" = yes; then : |
f73dda09 JA |
5237 | ac_cv_rl_version='4.2' |
5238 | else | |
7f947b68 | 5239 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5240 | /* end confdefs.h. */ |
f73dda09 JA |
5241 | |
5242 | #include <stdio.h> | |
5243 | #include <readline/readline.h> | |
5244 | ||
798a67db CR |
5245 | extern int rl_gnu_readline_p; |
5246 | ||
f73dda09 JA |
5247 | main() |
5248 | { | |
5249 | FILE *fp; | |
5250 | fp = fopen("conftest.rlv", "w"); | |
798a67db CR |
5251 | if (fp == 0) |
5252 | exit(1); | |
5253 | if (rl_gnu_readline_p != 1) | |
5254 | fprintf(fp, "0.0\n"); | |
5255 | else | |
5256 | fprintf(fp, "%s\n", rl_library_version ? rl_library_version : "0.0"); | |
f73dda09 JA |
5257 | fclose(fp); |
5258 | exit(0); | |
5259 | } | |
5260 | ||
5261 | _ACEOF | |
7f947b68 | 5262 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
5263 | ac_cv_rl_version=`cat conftest.rlv` |
5264 | else | |
7f947b68 | 5265 | ac_cv_rl_version='0.0' |
f73dda09 | 5266 | fi |
7f947b68 CR |
5267 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
5268 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 5269 | fi |
b709b946 | 5270 | |
d3a24ed2 | 5271 | fi |
f73dda09 | 5272 | |
a82a04b3 | 5273 | |
f73dda09 JA |
5274 | CFLAGS="$_save_CFLAGS" |
5275 | LDFLAGS="$_save_LDFLAGS" | |
5276 | LIBS="$_save_LIBS" | |
5277 | ||
5278 | RL_MAJOR=0 | |
5279 | RL_MINOR=0 | |
5280 | ||
5281 | # ( | |
5282 | case "$ac_cv_rl_version" in | |
5283 | 2*|3*|4*|5*|6*|7*|8*|9*) | |
5284 | RL_MAJOR=`echo $ac_cv_rl_version | sed 's:\..*$::'` | |
7117c2d2 | 5285 | RL_MINOR=`echo $ac_cv_rl_version | sed -e 's:^.*\.::' -e 's:[a-zA-Z]*$::'` |
f73dda09 JA |
5286 | ;; |
5287 | esac | |
5288 | ||
5289 | # ((( | |
5290 | case $RL_MAJOR in | |
5291 | [0-9][0-9]) _RL_MAJOR=$RL_MAJOR ;; | |
5292 | [0-9]) _RL_MAJOR=0$RL_MAJOR ;; | |
5293 | *) _RL_MAJOR=00 ;; | |
5294 | esac | |
5295 | ||
5296 | # ((( | |
5297 | case $RL_MINOR in | |
5298 | [0-9][0-9]) _RL_MINOR=$RL_MINOR ;; | |
5299 | [0-9]) _RL_MINOR=0$RL_MINOR ;; | |
5300 | *) _RL_MINOR=00 ;; | |
5301 | esac | |
5302 | ||
5303 | RL_VERSION="0x${_RL_MAJOR}${_RL_MINOR}" | |
5304 | ||
5305 | # Readline versions greater than 4.2 have these defines in readline.h | |
5306 | ||
5307 | if test $ac_cv_rl_version = '0.0' ; then | |
7f947b68 | 5308 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not test version of installed readline library." >&5 |
dd4f3dd8 | 5309 | $as_echo "$as_me: WARNING: Could not test version of installed readline library." >&2;} |
f73dda09 JA |
5310 | elif test $RL_MAJOR -gt 4 || { test $RL_MAJOR = 4 && test $RL_MINOR -gt 2 ; } ; then |
5311 | # set these for use by the caller | |
5312 | RL_PREFIX=$ac_cv_rl_prefix | |
5313 | RL_LIBDIR=$ac_cv_rl_libdir | |
5314 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
7f947b68 | 5315 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
dd4f3dd8 | 5316 | $as_echo "$ac_cv_rl_version" >&6; } |
f73dda09 JA |
5317 | else |
5318 | ||
a82a04b3 CR |
5319 | |
5320 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5321 | #define RL_READLINE_VERSION $RL_VERSION |
a82a04b3 | 5322 | _ACEOF |
f73dda09 | 5323 | |
a82a04b3 CR |
5324 | |
5325 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5326 | #define RL_VERSION_MAJOR $RL_MAJOR |
a82a04b3 | 5327 | _ACEOF |
f73dda09 | 5328 | |
a82a04b3 CR |
5329 | |
5330 | cat >>confdefs.h <<_ACEOF | |
f73dda09 | 5331 | #define RL_VERSION_MINOR $RL_MINOR |
a82a04b3 CR |
5332 | _ACEOF |
5333 | ||
5334 | ||
5335 | ||
5336 | ||
5337 | ||
545f34cf CR |
5338 | |
5339 | # set these for use by the caller | |
5340 | RL_PREFIX=$ac_cv_rl_prefix | |
5341 | RL_LIBDIR=$ac_cv_rl_libdir | |
5342 | RL_INCLUDEDIR=$ac_cv_rl_includedir | |
5343 | ||
7f947b68 | 5344 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_rl_version" >&5 |
dd4f3dd8 | 5345 | $as_echo "$ac_cv_rl_version" >&6; } |
bb70624e | 5346 | |
f73dda09 | 5347 | fi |
bb70624e | 5348 | |
a82a04b3 | 5349 | |
f73dda09 | 5350 | case "$ac_cv_rl_version" in |
d3a24ed2 | 5351 | 5*|6*|7*|8*|9*) ;; |
f73dda09 | 5352 | *) opt_with_installed_readline=no |
7f947b68 | 5353 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: installed readline library is too old to be linked with bash" >&5 |
dd4f3dd8 | 5354 | $as_echo "$as_me: WARNING: installed readline library is too old to be linked with bash" >&2;} |
7f947b68 | 5355 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using private bash version" >&5 |
dd4f3dd8 | 5356 | $as_echo "$as_me: WARNING: using private bash version" >&2;} |
bb70624e JA |
5357 | ;; |
5358 | esac | |
bb70624e JA |
5359 | fi |
5360 | ||
fd3925f1 | 5361 | TILDE_LIB=-ltilde |
bb70624e | 5362 | if test $opt_readline = yes; then |
7f947b68 | 5363 | $as_echo "#define READLINE 1" >>confdefs.h |
bb70624e | 5364 | |
f73dda09 | 5365 | if test "$opt_with_installed_readline" != "no" ; then |
d3a24ed2 CR |
5366 | case "$opt_with_installed_readline" in |
5367 | yes) RL_INCLUDE= ;; | |
5368 | *) case "$RL_INCLUDEDIR" in | |
5369 | /usr/include) ;; | |
5370 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5371 | esac | |
5372 | ;; | |
f73dda09 | 5373 | esac |
bb70624e | 5374 | READLINE_DEP= |
233564d2 | 5375 | READLINE_LIB=-lreadline |
fd3925f1 CR |
5376 | # section for OS versions that don't allow unresolved symbols |
5377 | # to be compiled into dynamic libraries. | |
5378 | case "$host_os" in | |
5379 | cygwin*) TILDE_LIB= ;; | |
5380 | esac | |
bb70624e JA |
5381 | else |
5382 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5383 | READLINE_DEP='$(READLINE_LIBRARY)' | |
fd3925f1 | 5384 | # section for OS versions that ship an older/broken version of |
233564d2 CR |
5385 | # readline as a standard dynamic library and don't allow a |
5386 | # static version specified as -llibname to override the | |
5387 | # dynamic version | |
5388 | case "${host_os}" in | |
82a5df63 | 5389 | darwin[89]*|darwin10*) READLINE_LIB='${READLINE_LIBRARY}' ;; |
233564d2 CR |
5390 | *) READLINE_LIB=-lreadline ;; |
5391 | esac | |
bb70624e JA |
5392 | fi |
5393 | else | |
5394 | RL_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5395 | READLINE_LIB= READLINE_DEP= | |
5396 | fi | |
5397 | if test $opt_history = yes || test $opt_bang_history = yes; then | |
5398 | if test $opt_history = yes; then | |
7f947b68 | 5399 | $as_echo "#define HISTORY 1" >>confdefs.h |
bb70624e JA |
5400 | |
5401 | fi | |
5402 | if test $opt_bang_history = yes; then | |
7f947b68 | 5403 | $as_echo "#define BANG_HISTORY 1" >>confdefs.h |
b72432fd JA |
5404 | |
5405 | fi | |
f73dda09 JA |
5406 | if test "$opt_with_installed_readline" != "no"; then |
5407 | HIST_LIBDIR=$RL_LIBDIR | |
b72432fd | 5408 | HISTORY_DEP= |
233564d2 | 5409 | HISTORY_LIB=-lhistory |
d3a24ed2 CR |
5410 | case "$opt_with_installed_readline" in |
5411 | yes) RL_INCLUDE= ;; | |
5412 | *) case "$RL_INCLUDEDIR" in | |
5413 | /usr/include) ;; | |
5414 | *) RL_INCLUDE='-I${RL_INCLUDEDIR}' ;; | |
5415 | esac | |
5416 | ;; | |
f73dda09 | 5417 | esac |
b72432fd JA |
5418 | else |
5419 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5420 | HISTORY_DEP='$(HISTORY_LIBRARY)' | |
233564d2 CR |
5421 | # section for OS versions that ship an older version of |
5422 | # readline as a standard dynamic library and don't allow a | |
5423 | # static version specified as -llibname to override the | |
5424 | # dynamic version | |
5425 | case "${host_os}" in | |
82a5df63 | 5426 | darwin[89]*|darwin10*) HISTORY_LIB='${HISTORY_LIBRARY}' ;; |
233564d2 CR |
5427 | *) HISTORY_LIB=-lhistory ;; |
5428 | esac | |
b72432fd JA |
5429 | fi |
5430 | else | |
5431 | HIST_LIBDIR='$(dot)/$(LIBSUBDIR)/readline' | |
5432 | HISTORY_LIB= HISTORY_DEP= | |
5433 | fi | |
5434 | ||
a82a04b3 CR |
5435 | |
5436 | ||
5437 | ||
5438 | ||
5439 | ||
5440 | ||
5441 | ||
5442 | ||
5443 | ||
fd3925f1 | 5444 | |
ccc6cda3 JA |
5445 | # Find a good install program. We prefer a C program (faster), |
5446 | # so one script is as good as another. But avoid the broken or | |
5447 | # incompatible versions: | |
5448 | # SysV /etc/install, /usr/sbin/install | |
5449 | # SunOS /usr/etc/install | |
5450 | # IRIX /sbin/install | |
5451 | # AIX /bin/install | |
f73dda09 | 5452 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
bb70624e | 5453 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
ccc6cda3 JA |
5454 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args |
5455 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
5e4a95c7 | 5456 | # OS/2's system install, which has a completely different semantic |
ccc6cda3 | 5457 | # ./install, which can be erroneously created by make from ./install.sh. |
dd4f3dd8 | 5458 | # Reject install programs that cannot install multiple files. |
7f947b68 | 5459 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 |
dd4f3dd8 | 5460 | $as_echo_n "checking for a BSD-compatible install... " >&6; } |
ccc6cda3 | 5461 | if test -z "$INSTALL"; then |
7f947b68 | 5462 | if ${ac_cv_path_install+:} false; then : |
dd4f3dd8 | 5463 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5464 | else |
a82a04b3 CR |
5465 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5466 | for as_dir in $PATH | |
5467 | do | |
5468 | IFS=$as_save_IFS | |
5469 | test -z "$as_dir" && as_dir=. | |
7f947b68 CR |
5470 | # Account for people who put trailing slashes in PATH elements. |
5471 | case $as_dir/ in #(( | |
5472 | ./ | .// | /[cC]/* | \ | |
a82a04b3 | 5473 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
7f947b68 | 5474 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
a82a04b3 CR |
5475 | /usr/ucb/* ) ;; |
5476 | *) | |
5477 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
5478 | # Don't use installbsd from OSF since it installs stuff as root | |
5479 | # by default. | |
5480 | for ac_prog in ginstall scoinst install; do | |
5481 | for ac_exec_ext in '' $ac_executable_extensions; do | |
dd4f3dd8 | 5482 | if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then |
5e4a95c7 CR |
5483 | if test $ac_prog = install && |
5484 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5485 | # AIX install. It has an incompatible calling convention. | |
5486 | : | |
5487 | elif test $ac_prog = install && | |
5488 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5489 | # program-specific install script used by HP pwplus--don't use. | |
5490 | : | |
5491 | else | |
dd4f3dd8 CR |
5492 | rm -rf conftest.one conftest.two conftest.dir |
5493 | echo one > conftest.one | |
5494 | echo two > conftest.two | |
5495 | mkdir conftest.dir | |
5496 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
5497 | test -s conftest.one && test -s conftest.two && | |
5498 | test -s conftest.dir/conftest.one && | |
5499 | test -s conftest.dir/conftest.two | |
5500 | then | |
5501 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
5502 | break 3 | |
5503 | fi | |
5e4a95c7 CR |
5504 | fi |
5505 | fi | |
ccc6cda3 | 5506 | done |
a82a04b3 CR |
5507 | done |
5508 | ;; | |
5509 | esac | |
dd4f3dd8 | 5510 | |
7f947b68 | 5511 | done |
b709b946 | 5512 | IFS=$as_save_IFS |
a82a04b3 | 5513 | |
dd4f3dd8 | 5514 | rm -rf conftest.one conftest.two conftest.dir |
ccc6cda3 JA |
5515 | |
5516 | fi | |
5517 | if test "${ac_cv_path_install+set}" = set; then | |
f73dda09 | 5518 | INSTALL=$ac_cv_path_install |
ccc6cda3 | 5519 | else |
b709b946 CR |
5520 | # As a last resort, use the slow shell script. Don't cache a |
5521 | # value for INSTALL within a source directory, because that will | |
ccc6cda3 | 5522 | # break other packages using the cache if that directory is |
b709b946 | 5523 | # removed, or if the value is a relative name. |
f73dda09 | 5524 | INSTALL=$ac_install_sh |
ccc6cda3 JA |
5525 | fi |
5526 | fi | |
7f947b68 | 5527 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
dd4f3dd8 | 5528 | $as_echo "$INSTALL" >&6; } |
ccc6cda3 JA |
5529 | |
5530 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
5531 | # It thinks the first close brace ends the variable substitution. | |
5532 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
5533 | ||
f73dda09 | 5534 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
bb70624e | 5535 | |
ccc6cda3 JA |
5536 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
5537 | ||
5538 | # Extract the first word of "ar", so it can be a program name with args. | |
5539 | set dummy ar; ac_word=$2 | |
7f947b68 | 5540 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5541 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 5542 | if ${ac_cv_prog_AR+:} false; then : |
dd4f3dd8 | 5543 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5544 | else |
5545 | if test -n "$AR"; then | |
5546 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
5547 | else | |
a82a04b3 CR |
5548 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5549 | for as_dir in $PATH | |
5550 | do | |
5551 | IFS=$as_save_IFS | |
5552 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 5553 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 5554 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 5555 | ac_cv_prog_AR="" |
7f947b68 | 5556 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5557 | break 2 |
5558 | fi | |
5559 | done | |
7f947b68 | 5560 | done |
b709b946 | 5561 | IFS=$as_save_IFS |
f73dda09 JA |
5562 | |
5563 | test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="ar" | |
ccc6cda3 JA |
5564 | fi |
5565 | fi | |
f73dda09 | 5566 | AR=$ac_cv_prog_AR |
ccc6cda3 | 5567 | if test -n "$AR"; then |
7f947b68 | 5568 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
dd4f3dd8 | 5569 | $as_echo "$AR" >&6; } |
ccc6cda3 | 5570 | else |
7f947b68 | 5571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5572 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5573 | fi |
5574 | ||
b709b946 | 5575 | |
b72432fd | 5576 | test -n "$ARFLAGS" || ARFLAGS="cr" |
f73dda09 JA |
5577 | if test -n "$ac_tool_prefix"; then |
5578 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
5579 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
7f947b68 | 5580 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5581 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 5582 | if ${ac_cv_prog_RANLIB+:} false; then : |
dd4f3dd8 | 5583 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5584 | else |
5585 | if test -n "$RANLIB"; then | |
5586 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
5587 | else | |
a82a04b3 CR |
5588 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5589 | for as_dir in $PATH | |
5590 | do | |
5591 | IFS=$as_save_IFS | |
5592 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 5593 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 5594 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 5595 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
7f947b68 | 5596 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5597 | break 2 |
5598 | fi | |
5599 | done | |
7f947b68 | 5600 | done |
b709b946 | 5601 | IFS=$as_save_IFS |
f73dda09 | 5602 | |
ccc6cda3 JA |
5603 | fi |
5604 | fi | |
f73dda09 | 5605 | RANLIB=$ac_cv_prog_RANLIB |
ccc6cda3 | 5606 | if test -n "$RANLIB"; then |
7f947b68 | 5607 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
dd4f3dd8 | 5608 | $as_echo "$RANLIB" >&6; } |
f73dda09 | 5609 | else |
7f947b68 | 5610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5611 | $as_echo "no" >&6; } |
f73dda09 JA |
5612 | fi |
5613 | ||
b709b946 | 5614 | |
f73dda09 JA |
5615 | fi |
5616 | if test -z "$ac_cv_prog_RANLIB"; then | |
5617 | ac_ct_RANLIB=$RANLIB | |
5618 | # Extract the first word of "ranlib", so it can be a program name with args. | |
5619 | set dummy ranlib; ac_word=$2 | |
7f947b68 | 5620 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5621 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 5622 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
dd4f3dd8 | 5623 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
5624 | else |
5625 | if test -n "$ac_ct_RANLIB"; then | |
5626 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
5627 | else | |
a82a04b3 CR |
5628 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5629 | for as_dir in $PATH | |
5630 | do | |
5631 | IFS=$as_save_IFS | |
5632 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 5633 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 5634 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 5635 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
7f947b68 | 5636 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5637 | break 2 |
5638 | fi | |
5639 | done | |
7f947b68 | 5640 | done |
b709b946 | 5641 | IFS=$as_save_IFS |
f73dda09 | 5642 | |
f73dda09 JA |
5643 | fi |
5644 | fi | |
5645 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
5646 | if test -n "$ac_ct_RANLIB"; then | |
7f947b68 | 5647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
dd4f3dd8 | 5648 | $as_echo "$ac_ct_RANLIB" >&6; } |
ccc6cda3 | 5649 | else |
7f947b68 | 5650 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5651 | $as_echo "no" >&6; } |
f73dda09 JA |
5652 | fi |
5653 | ||
b709b946 CR |
5654 | if test "x$ac_ct_RANLIB" = x; then |
5655 | RANLIB=":" | |
5656 | else | |
5657 | case $cross_compiling:$ac_tool_warned in | |
5658 | yes:) | |
7f947b68 | 5659 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 |
af98a2a6 | 5660 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} |
b709b946 CR |
5661 | ac_tool_warned=yes ;; |
5662 | esac | |
5663 | RANLIB=$ac_ct_RANLIB | |
5664 | fi | |
f73dda09 JA |
5665 | else |
5666 | RANLIB="$ac_cv_prog_RANLIB" | |
ccc6cda3 JA |
5667 | fi |
5668 | ||
5669 | for ac_prog in 'bison -y' byacc | |
5670 | do | |
f73dda09 | 5671 | # Extract the first word of "$ac_prog", so it can be a program name with args. |
ccc6cda3 | 5672 | set dummy $ac_prog; ac_word=$2 |
7f947b68 | 5673 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 5674 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 5675 | if ${ac_cv_prog_YACC+:} false; then : |
dd4f3dd8 | 5676 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
5677 | else |
5678 | if test -n "$YACC"; then | |
5679 | ac_cv_prog_YACC="$YACC" # Let the user override the test. | |
5680 | else | |
a82a04b3 CR |
5681 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
5682 | for as_dir in $PATH | |
5683 | do | |
5684 | IFS=$as_save_IFS | |
5685 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 5686 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 5687 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 5688 | ac_cv_prog_YACC="$ac_prog" |
7f947b68 | 5689 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
5690 | break 2 |
5691 | fi | |
5692 | done | |
7f947b68 | 5693 | done |
b709b946 | 5694 | IFS=$as_save_IFS |
f73dda09 | 5695 | |
ccc6cda3 JA |
5696 | fi |
5697 | fi | |
f73dda09 | 5698 | YACC=$ac_cv_prog_YACC |
ccc6cda3 | 5699 | if test -n "$YACC"; then |
7f947b68 | 5700 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $YACC" >&5 |
dd4f3dd8 | 5701 | $as_echo "$YACC" >&6; } |
ccc6cda3 | 5702 | else |
7f947b68 | 5703 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5704 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5705 | fi |
5706 | ||
b709b946 | 5707 | |
f73dda09 | 5708 | test -n "$YACC" && break |
ccc6cda3 JA |
5709 | done |
5710 | test -n "$YACC" || YACC="yacc" | |
5711 | ||
7f947b68 | 5712 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 |
dd4f3dd8 CR |
5713 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } |
5714 | set x ${MAKE-make} | |
5715 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
7f947b68 | 5716 | if eval \${ac_cv_prog_make_${ac_make}_set+:} false; then : |
dd4f3dd8 | 5717 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5718 | else |
a82a04b3 | 5719 | cat >conftest.make <<\_ACEOF |
b709b946 | 5720 | SHELL = /bin/sh |
ccc6cda3 | 5721 | all: |
b709b946 | 5722 | @echo '@@@%%%=$(MAKE)=@@@%%%' |
a82a04b3 | 5723 | _ACEOF |
7f947b68 | 5724 | # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. |
b709b946 CR |
5725 | case `${MAKE-make} -f conftest.make 2>/dev/null` in |
5726 | *@@@%%%=?*=@@@%%%*) | |
5727 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
5728 | *) | |
5729 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
5730 | esac | |
f73dda09 | 5731 | rm -f conftest.make |
ccc6cda3 | 5732 | fi |
b709b946 | 5733 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then |
7f947b68 | 5734 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
dd4f3dd8 | 5735 | $as_echo "yes" >&6; } |
ccc6cda3 JA |
5736 | SET_MAKE= |
5737 | else | |
7f947b68 | 5738 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 5739 | $as_echo "no" >&6; } |
ccc6cda3 JA |
5740 | SET_MAKE="MAKE=${MAKE-make}" |
5741 | fi | |
5742 | ||
a82a04b3 | 5743 | |
b72432fd | 5744 | case "$host_os" in |
bb70624e | 5745 | opennt*|interix*) MAKE_SHELL="$INTERIX_ROOT/bin/sh" ;; |
b72432fd JA |
5746 | *) MAKE_SHELL=/bin/sh ;; |
5747 | esac | |
5748 | ||
a82a04b3 | 5749 | |
10590446 CR |
5750 | if test x$SIZE = x; then |
5751 | if test x$ac_tool_prefix = x; then | |
5752 | SIZE=size | |
5753 | else | |
5754 | SIZE=${ac_tool_prefix}size | |
5755 | save_IFS=$IFS ; IFS=: | |
5756 | size_found=0 | |
5757 | for dir in $PATH; do | |
5758 | if test -x $dir/$SIZE ; then | |
5759 | size_found=1 | |
5760 | break | |
5761 | fi | |
5762 | done | |
5763 | if test $size_found -eq 0; then | |
233564d2 | 5764 | SIZE=: |
10590446 CR |
5765 | fi |
5766 | IFS=$save_IFS | |
5767 | fi | |
5768 | fi | |
5769 | ||
e624d0f7 | 5770 | |
278286c9 CR |
5771 | # Checks for stat-related time functions. |
5772 | ||
5773 | # Copyright (C) 1998-1999, 2001, 2003, 2005-2007, 2009-2012 Free Software | |
5774 | # Foundation, Inc. | |
5775 | ||
5776 | # This file is free software; the Free Software Foundation | |
5777 | # gives unlimited permission to copy and/or distribute it, | |
5778 | # with or without modifications, as long as this notice is preserved. | |
5779 | ||
5780 | ||
5781 | # st_atim.tv_nsec - Linux, Solaris, Cygwin | |
5782 | # st_atimespec.tv_nsec - FreeBSD, NetBSD, if ! defined _POSIX_SOURCE | |
5783 | # st_atimensec - FreeBSD, NetBSD, if defined _POSIX_SOURCE | |
5784 | # st_atim.st__tim.tv_nsec - UnixWare (at least 2.1.2 through 7.1) | |
5785 | ||
5786 | # st_birthtimespec - FreeBSD, NetBSD (hidden on OpenBSD 3.9, anyway) | |
5787 | # st_birthtim - Cygwin 1.7.0+ | |
5788 | ||
5789 | ||
5790 | ||
5791 | # Configure checks for struct timespec | |
5792 | ||
5793 | # Copyright (C) 2000-2001, 2003-2007, 2009-2011, 2012 Free Software Foundation, Inc. | |
5794 | ||
5795 | # This file is free software; the Free Software Foundation | |
5796 | # gives unlimited permission to copy and/or distribute it, | |
5797 | # with or without modifications, as long as this notice is preserved. | |
5798 | ||
5799 | # Original written by Paul Eggert and Jim Meyering. | |
5800 | # Modified by Chet Ramey for bash | |
5801 | ||
5802 | ||
5803 | ||
5804 | ||
5805 | ||
7f947b68 | 5806 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h |
ccc6cda3 | 5807 | |
e624d0f7 | 5808 | |
7f947b68 | 5809 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 |
dd4f3dd8 | 5810 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } |
7f947b68 | 5811 | if ${ac_cv_c_const+:} false; then : |
dd4f3dd8 | 5812 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5813 | else |
7f947b68 | 5814 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 CR |
5815 | /* end confdefs.h. */ |
5816 | ||
5817 | int | |
5818 | main () | |
5c26afb8 CR |
5819 | { |
5820 | /* FIXME: Include the comments suggested by Paul. */ | |
5821 | #ifndef __cplusplus | |
5822 | /* Ultrix mips cc rejects this. */ | |
5823 | typedef int charset[2]; | |
dd4f3dd8 | 5824 | const charset cs; |
5c26afb8 | 5825 | /* SunOS 4.1.1 cc rejects this. */ |
dd4f3dd8 CR |
5826 | char const *const *pcpcc; |
5827 | char **ppc; | |
5c26afb8 CR |
5828 | /* NEC SVR4.0.2 mips cc rejects this. */ |
5829 | struct point {int x, y;}; | |
5830 | static struct point const zero = {0,0}; | |
5831 | /* AIX XL C 1.02.0.0 rejects this. | |
5832 | It does not let you subtract one const X* pointer from another in | |
5833 | an arm of an if-expression whose if-part is not a constant | |
5834 | expression */ | |
f73dda09 | 5835 | const char *g = "string"; |
dd4f3dd8 | 5836 | pcpcc = &g + (g ? g-g : 0); |
f73dda09 | 5837 | /* HPUX 7.0 cc rejects these. */ |
dd4f3dd8 CR |
5838 | ++pcpcc; |
5839 | ppc = (char**) pcpcc; | |
5840 | pcpcc = (char const *const *) ppc; | |
f73dda09 JA |
5841 | { /* SCO 3.2v4 cc rejects this. */ |
5842 | char *t; | |
5843 | char const *s = 0 ? (char *) 0 : (char const *) 0; | |
5844 | ||
5845 | *t++ = 0; | |
b709b946 | 5846 | if (s) return 0; |
f73dda09 JA |
5847 | } |
5848 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
5849 | int x[] = {25, 17}; | |
5850 | const int *foo = &x[0]; | |
5851 | ++foo; | |
5852 | } | |
5853 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
5854 | typedef const int *iptr; | |
5855 | iptr p = 0; | |
5856 | ++p; | |
5857 | } | |
5858 | { /* AIX XL C 1.02.0.0 rejects this saying | |
5859 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ | |
5860 | struct s { int j; const int *ap[3]; }; | |
5861 | struct s *b; b->j = 5; | |
5862 | } | |
5863 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
5864 | const int foo = 10; | |
b709b946 | 5865 | if (!foo) return 0; |
f73dda09 | 5866 | } |
dd4f3dd8 | 5867 | return !cs[0] && !zero.x; |
ccc6cda3 JA |
5868 | #endif |
5869 | ||
f73dda09 JA |
5870 | ; |
5871 | return 0; | |
5872 | } | |
5873 | _ACEOF | |
7f947b68 | 5874 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 JA |
5875 | ac_cv_c_const=yes |
5876 | else | |
7f947b68 | 5877 | ac_cv_c_const=no |
f73dda09 | 5878 | fi |
b709b946 | 5879 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f73dda09 | 5880 | fi |
7f947b68 | 5881 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
dd4f3dd8 | 5882 | $as_echo "$ac_cv_c_const" >&6; } |
f73dda09 JA |
5883 | if test $ac_cv_c_const = no; then |
5884 | ||
7f947b68 | 5885 | $as_echo "#define const /**/" >>confdefs.h |
ccc6cda3 JA |
5886 | |
5887 | fi | |
5888 | ||
7f947b68 | 5889 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
dd4f3dd8 | 5890 | $as_echo_n "checking for inline... " >&6; } |
7f947b68 | 5891 | if ${ac_cv_c_inline+:} false; then : |
dd4f3dd8 | 5892 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5893 | else |
f73dda09 JA |
5894 | ac_cv_c_inline=no |
5895 | for ac_kw in inline __inline__ __inline; do | |
7f947b68 | 5896 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5897 | /* end confdefs.h. */ |
f73dda09 | 5898 | #ifndef __cplusplus |
5e4a95c7 CR |
5899 | typedef int foo_t; |
5900 | static $ac_kw foo_t static_foo () {return 0; } | |
5901 | $ac_kw foo_t foo () {return 0; } | |
ccc6cda3 JA |
5902 | #endif |
5903 | ||
f73dda09 | 5904 | _ACEOF |
7f947b68 | 5905 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 5906 | ac_cv_c_inline=$ac_kw |
f73dda09 | 5907 | fi |
b709b946 CR |
5908 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5909 | test "$ac_cv_c_inline" != no && break | |
f73dda09 | 5910 | done |
ccc6cda3 JA |
5911 | |
5912 | fi | |
7f947b68 | 5913 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
dd4f3dd8 | 5914 | $as_echo "$ac_cv_c_inline" >&6; } |
5e4a95c7 | 5915 | |
f73dda09 JA |
5916 | case $ac_cv_c_inline in |
5917 | inline | yes) ;; | |
5e4a95c7 CR |
5918 | *) |
5919 | case $ac_cv_c_inline in | |
5920 | no) ac_val=;; | |
5921 | *) ac_val=$ac_cv_c_inline;; | |
5922 | esac | |
5923 | cat >>confdefs.h <<_ACEOF | |
5924 | #ifndef __cplusplus | |
5925 | #define inline $ac_val | |
5926 | #endif | |
5c26afb8 | 5927 | _ACEOF |
5e4a95c7 | 5928 | ;; |
f73dda09 | 5929 | esac |
ccc6cda3 | 5930 | |
7f947b68 | 5931 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
dd4f3dd8 | 5932 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } |
7f947b68 | 5933 | if ${ac_cv_c_bigendian+:} false; then : |
dd4f3dd8 | 5934 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 5935 | else |
dd4f3dd8 | 5936 | ac_cv_c_bigendian=unknown |
af98a2a6 | 5937 | # See if we're dealing with a universal compiler. |
7f947b68 | 5938 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5939 | /* end confdefs.h. */ |
af98a2a6 CR |
5940 | #ifndef __APPLE_CC__ |
5941 | not a universal capable compiler | |
dd4f3dd8 CR |
5942 | #endif |
5943 | typedef int dummy; | |
ccc6cda3 | 5944 | |
f73dda09 | 5945 | _ACEOF |
7f947b68 | 5946 | if ac_fn_c_try_compile "$LINENO"; then : |
af98a2a6 CR |
5947 | |
5948 | # Check for potential -arch flags. It is not universal unless | |
7f947b68 CR |
5949 | # there are at least two -arch flags with different values. |
5950 | ac_arch= | |
5951 | ac_prev= | |
5952 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
5953 | if test -n "$ac_prev"; then | |
5954 | case $ac_word in | |
5955 | i?86 | x86_64 | ppc | ppc64) | |
5956 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
5957 | ac_arch=$ac_word | |
5958 | else | |
5959 | ac_cv_c_bigendian=universal | |
5960 | break | |
5961 | fi | |
5962 | ;; | |
5963 | esac | |
5964 | ac_prev= | |
5965 | elif test "x$ac_word" = "x-arch"; then | |
5966 | ac_prev=arch | |
5967 | fi | |
5968 | done | |
dd4f3dd8 | 5969 | fi |
dd4f3dd8 CR |
5970 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5971 | if test $ac_cv_c_bigendian = unknown; then | |
5972 | # See if sys/param.h defines the BYTE_ORDER macro. | |
7f947b68 | 5973 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
5974 | /* end confdefs.h. */ |
5975 | #include <sys/types.h> | |
5976 | #include <sys/param.h> | |
5977 | ||
5978 | int | |
5979 | main () | |
5980 | { | |
5981 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ | |
5982 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
5983 | && LITTLE_ENDIAN) | |
5984 | bogus endian macros | |
5985 | #endif | |
5986 | ||
5987 | ; | |
5988 | return 0; | |
5989 | } | |
5990 | _ACEOF | |
7f947b68 | 5991 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 5992 | # It does; now see whether it defined to BIG_ENDIAN or not. |
7f947b68 | 5993 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 5994 | /* end confdefs.h. */ |
f73dda09 | 5995 | #include <sys/types.h> |
dd4f3dd8 | 5996 | #include <sys/param.h> |
ccc6cda3 | 5997 | |
f73dda09 JA |
5998 | int |
5999 | main () | |
6000 | { | |
6001 | #if BYTE_ORDER != BIG_ENDIAN | |
dd4f3dd8 CR |
6002 | not big endian |
6003 | #endif | |
ccc6cda3 | 6004 | |
f73dda09 JA |
6005 | ; |
6006 | return 0; | |
6007 | } | |
6008 | _ACEOF | |
7f947b68 | 6009 | if ac_fn_c_try_compile "$LINENO"; then : |
f73dda09 | 6010 | ac_cv_c_bigendian=yes |
ccc6cda3 | 6011 | else |
7f947b68 | 6012 | ac_cv_c_bigendian=no |
ccc6cda3 | 6013 | fi |
b709b946 | 6014 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 6015 | fi |
dd4f3dd8 CR |
6016 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6017 | fi | |
6018 | if test $ac_cv_c_bigendian = unknown; then | |
6019 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
7f947b68 | 6020 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6021 | /* end confdefs.h. */ |
dd4f3dd8 CR |
6022 | #include <limits.h> |
6023 | ||
a82a04b3 CR |
6024 | int |
6025 | main () | |
6026 | { | |
dd4f3dd8 CR |
6027 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) |
6028 | bogus endian macros | |
6029 | #endif | |
6030 | ||
a82a04b3 CR |
6031 | ; |
6032 | return 0; | |
6033 | } | |
6034 | _ACEOF | |
7f947b68 | 6035 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 | 6036 | # It does; now see whether it defined to _BIG_ENDIAN or not. |
7f947b68 | 6037 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
6038 | /* end confdefs.h. */ |
6039 | #include <limits.h> | |
6040 | ||
6041 | int | |
6042 | main () | |
6043 | { | |
6044 | #ifndef _BIG_ENDIAN | |
6045 | not big endian | |
6046 | #endif | |
6047 | ||
6048 | ; | |
6049 | return 0; | |
6050 | } | |
6051 | _ACEOF | |
7f947b68 | 6052 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 CR |
6053 | ac_cv_c_bigendian=yes |
6054 | else | |
7f947b68 | 6055 | ac_cv_c_bigendian=no |
dd4f3dd8 | 6056 | fi |
dd4f3dd8 | 6057 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd4f3dd8 | 6058 | fi |
dd4f3dd8 CR |
6059 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6060 | fi | |
6061 | if test $ac_cv_c_bigendian = unknown; then | |
6062 | # Compile a test program. | |
7f947b68 | 6063 | if test "$cross_compiling" = yes; then : |
dd4f3dd8 | 6064 | # Try to guess by grepping values from an object file. |
7f947b68 | 6065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd4f3dd8 CR |
6066 | /* end confdefs.h. */ |
6067 | short int ascii_mm[] = | |
6068 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
6069 | short int ascii_ii[] = | |
6070 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
6071 | int use_ascii (int i) { | |
6072 | return ascii_mm[i] + ascii_ii[i]; | |
6073 | } | |
6074 | short int ebcdic_ii[] = | |
6075 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
6076 | short int ebcdic_mm[] = | |
6077 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
6078 | int use_ebcdic (int i) { | |
6079 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
6080 | } | |
6081 | extern int foo; | |
6082 | ||
6083 | int | |
6084 | main () | |
6085 | { | |
6086 | return use_ascii (foo) == use_ebcdic (foo); | |
6087 | ; | |
6088 | return 0; | |
6089 | } | |
6090 | _ACEOF | |
7f947b68 | 6091 | if ac_fn_c_try_compile "$LINENO"; then : |
dd4f3dd8 CR |
6092 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then |
6093 | ac_cv_c_bigendian=yes | |
6094 | fi | |
6095 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
6096 | if test "$ac_cv_c_bigendian" = unknown; then | |
6097 | ac_cv_c_bigendian=no | |
6098 | else | |
6099 | # finding both strings is unlikely to happen, but who knows? | |
6100 | ac_cv_c_bigendian=unknown | |
6101 | fi | |
6102 | fi | |
7610e0c5 | 6103 | fi |
7610e0c5 CR |
6104 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6105 | else | |
7f947b68 | 6106 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
7610e0c5 | 6107 | /* end confdefs.h. */ |
b709b946 | 6108 | $ac_includes_default |
f73dda09 JA |
6109 | int |
6110 | main () | |
ccc6cda3 | 6111 | { |
b709b946 | 6112 | |
dd4f3dd8 CR |
6113 | /* Are we little or big endian? From Harbison&Steele. */ |
6114 | union | |
6115 | { | |
6116 | long int l; | |
6117 | char c[sizeof (long int)]; | |
6118 | } u; | |
6119 | u.l = 1; | |
6120 | return u.c[sizeof (long int) - 1] == 1; | |
b709b946 CR |
6121 | |
6122 | ; | |
6123 | return 0; | |
ccc6cda3 | 6124 | } |
f73dda09 | 6125 | _ACEOF |
7f947b68 | 6126 | if ac_fn_c_try_run "$LINENO"; then : |
abe2eb5b CR |
6127 | ac_cv_c_bigendian=no |
6128 | else | |
7f947b68 | 6129 | ac_cv_c_bigendian=yes |
abe2eb5b | 6130 | fi |
7f947b68 CR |
6131 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6132 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
abe2eb5b CR |
6133 | fi |
6134 | ||
abe2eb5b CR |
6135 | fi |
6136 | fi | |
7f947b68 | 6137 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 |
abe2eb5b CR |
6138 | $as_echo "$ac_cv_c_bigendian" >&6; } |
6139 | case $ac_cv_c_bigendian in #( | |
dd4f3dd8 | 6140 | yes) |
7f947b68 | 6141 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h |
dd4f3dd8 CR |
6142 | ;; #( |
6143 | no) | |
6144 | ;; #( | |
6145 | universal) | |
af98a2a6 | 6146 | |
7f947b68 | 6147 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h |
af98a2a6 CR |
6148 | |
6149 | ;; #( | |
dd4f3dd8 | 6150 | *) |
7f947b68 CR |
6151 | as_fn_error $? "unknown endianness |
6152 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; | |
dd4f3dd8 | 6153 | esac |
ccc6cda3 | 6154 | |
7f947b68 | 6155 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for preprocessor stringizing operator" >&5 |
dd4f3dd8 | 6156 | $as_echo_n "checking for preprocessor stringizing operator... " >&6; } |
7f947b68 | 6157 | if ${ac_cv_c_stringize+:} false; then : |
dd4f3dd8 | 6158 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6159 | else |
7f947b68 | 6160 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6161 | /* end confdefs.h. */ |
f73dda09 | 6162 | #define x(y) #y |
ccc6cda3 | 6163 | |
f73dda09 JA |
6164 | char *s = x(teststring); |
6165 | _ACEOF | |
6166 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 6167 | $EGREP "#teststring" >/dev/null 2>&1; then : |
f73dda09 | 6168 | ac_cv_c_stringize=no |
ccc6cda3 | 6169 | else |
f73dda09 | 6170 | ac_cv_c_stringize=yes |
ccc6cda3 | 6171 | fi |
f73dda09 | 6172 | rm -f conftest* |
ccc6cda3 JA |
6173 | |
6174 | fi | |
7f947b68 | 6175 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stringize" >&5 |
dd4f3dd8 | 6176 | $as_echo "$ac_cv_c_stringize" >&6; } |
f73dda09 | 6177 | if test $ac_cv_c_stringize = yes; then |
ccc6cda3 | 6178 | |
7f947b68 | 6179 | $as_echo "#define HAVE_STRINGIZE 1" >>confdefs.h |
ccc6cda3 JA |
6180 | |
6181 | fi | |
6182 | ||
b709b946 CR |
6183 | |
6184 | ||
7f947b68 | 6185 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long double with more range or precision than double" >&5 |
dd4f3dd8 | 6186 | $as_echo_n "checking for long double with more range or precision than double... " >&6; } |
7f947b68 | 6187 | if ${ac_cv_type_long_double_wider+:} false; then : |
dd4f3dd8 | 6188 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6189 | else |
7f947b68 | 6190 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6191 | /* end confdefs.h. */ |
a82a04b3 | 6192 | #include <float.h> |
b709b946 CR |
6193 | long double const a[] = |
6194 | { | |
6195 | 0.0L, DBL_MIN, DBL_MAX, DBL_EPSILON, | |
6196 | LDBL_MIN, LDBL_MAX, LDBL_EPSILON | |
6197 | }; | |
6198 | long double | |
6199 | f (long double x) | |
6200 | { | |
6201 | return ((x + (unsigned long int) 10) * (-1 / x) + a[0] | |
6202 | + (x ? f (x) : 'c')); | |
6203 | } | |
6204 | ||
f73dda09 JA |
6205 | int |
6206 | main () | |
6207 | { | |
b709b946 CR |
6208 | static int test_array [1 - 2 * !((0 < ((DBL_MAX_EXP < LDBL_MAX_EXP) |
6209 | + (DBL_MANT_DIG < LDBL_MANT_DIG) | |
6210 | - (LDBL_MAX_EXP < DBL_MAX_EXP) | |
6211 | - (LDBL_MANT_DIG < DBL_MANT_DIG))) | |
6212 | && (int) LDBL_EPSILON == 0 | |
6213 | )]; | |
a82a04b3 CR |
6214 | test_array [0] = 0 |
6215 | ||
6216 | ; | |
6217 | return 0; | |
ccc6cda3 | 6218 | } |
f73dda09 | 6219 | _ACEOF |
7f947b68 | 6220 | if ac_fn_c_try_compile "$LINENO"; then : |
b709b946 | 6221 | ac_cv_type_long_double_wider=yes |
ccc6cda3 | 6222 | else |
7f947b68 | 6223 | ac_cv_type_long_double_wider=no |
f73dda09 | 6224 | fi |
b709b946 | 6225 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
e624d0f7 | 6226 | fi |
7f947b68 | 6227 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_double_wider" >&5 |
dd4f3dd8 | 6228 | $as_echo "$ac_cv_type_long_double_wider" >&6; } |
b709b946 CR |
6229 | if test $ac_cv_type_long_double_wider = yes; then |
6230 | ||
7f947b68 | 6231 | $as_echo "#define HAVE_LONG_DOUBLE_WIDER 1" >>confdefs.h |
b709b946 CR |
6232 | |
6233 | fi | |
6234 | ||
6235 | ac_cv_c_long_double=$ac_cv_type_long_double_wider | |
6236 | if test $ac_cv_c_long_double = yes; then | |
ccc6cda3 | 6237 | |
7f947b68 | 6238 | $as_echo "#define HAVE_LONG_DOUBLE 1" >>confdefs.h |
ccc6cda3 | 6239 | |
b709b946 | 6240 | fi |
ccc6cda3 | 6241 | |
7f947b68 | 6242 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for function prototypes" >&5 |
dd4f3dd8 | 6243 | $as_echo_n "checking for function prototypes... " >&6; } |
b709b946 | 6244 | if test "$ac_cv_prog_cc_c89" != no; then |
7f947b68 | 6245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
dd4f3dd8 | 6246 | $as_echo "yes" >&6; } |
ccc6cda3 | 6247 | |
7f947b68 | 6248 | $as_echo "#define PROTOTYPES 1" >>confdefs.h |
ccc6cda3 | 6249 | |
545f34cf | 6250 | |
7f947b68 | 6251 | $as_echo "#define __PROTOTYPES 1" >>confdefs.h |
e624d0f7 | 6252 | |
e624d0f7 | 6253 | else |
7f947b68 | 6254 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6255 | $as_echo "no" >&6; } |
e624d0f7 | 6256 | fi |
e624d0f7 | 6257 | |
7f947b68 | 6258 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether char is unsigned" >&5 |
dd4f3dd8 | 6259 | $as_echo_n "checking whether char is unsigned... " >&6; } |
7f947b68 | 6260 | if ${ac_cv_c_char_unsigned+:} false; then : |
dd4f3dd8 | 6261 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 6262 | else |
7f947b68 | 6263 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6264 | /* end confdefs.h. */ |
545f34cf CR |
6265 | $ac_includes_default |
6266 | int | |
6267 | main () | |
6268 | { | |
a82a04b3 CR |
6269 | static int test_array [1 - 2 * !(((char) -1) < 0)]; |
6270 | test_array [0] = 0 | |
6271 | ||
545f34cf CR |
6272 | ; |
6273 | return 0; | |
6274 | } | |
f73dda09 | 6275 | _ACEOF |
7f947b68 | 6276 | if ac_fn_c_try_compile "$LINENO"; then : |
545f34cf | 6277 | ac_cv_c_char_unsigned=no |
f73dda09 | 6278 | else |
7f947b68 | 6279 | ac_cv_c_char_unsigned=yes |
5e13499c | 6280 | fi |
b709b946 | 6281 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c | 6282 | fi |
7f947b68 | 6283 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_char_unsigned" >&5 |
dd4f3dd8 | 6284 | $as_echo "$ac_cv_c_char_unsigned" >&6; } |
5e13499c | 6285 | if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then |
7f947b68 | 6286 | $as_echo "#define __CHAR_UNSIGNED__ 1" >>confdefs.h |
5e13499c | 6287 | |
a927e029 CR |
6288 | fi |
6289 | ||
7f947b68 | 6290 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working volatile" >&5 |
a927e029 | 6291 | $as_echo_n "checking for working volatile... " >&6; } |
7f947b68 | 6292 | if ${ac_cv_c_volatile+:} false; then : |
a927e029 CR |
6293 | $as_echo_n "(cached) " >&6 |
6294 | else | |
7f947b68 | 6295 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
a927e029 CR |
6296 | /* end confdefs.h. */ |
6297 | ||
6298 | int | |
6299 | main () | |
6300 | { | |
6301 | ||
6302 | volatile int x; | |
6303 | int * volatile y = (int *) 0; | |
6304 | return !x && !y; | |
6305 | ; | |
6306 | return 0; | |
6307 | } | |
6308 | _ACEOF | |
7f947b68 | 6309 | if ac_fn_c_try_compile "$LINENO"; then : |
a927e029 CR |
6310 | ac_cv_c_volatile=yes |
6311 | else | |
7f947b68 | 6312 | ac_cv_c_volatile=no |
a927e029 | 6313 | fi |
a927e029 CR |
6314 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6315 | fi | |
7f947b68 | 6316 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_volatile" >&5 |
a927e029 CR |
6317 | $as_echo "$ac_cv_c_volatile" >&6; } |
6318 | if test $ac_cv_c_volatile = no; then | |
6319 | ||
7f947b68 | 6320 | $as_echo "#define volatile /**/" >>confdefs.h |
a927e029 | 6321 | |
5e13499c CR |
6322 | fi |
6323 | ||
7f947b68 | 6324 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C/C++ restrict keyword" >&5 |
c1d39fb8 | 6325 | $as_echo_n "checking for C/C++ restrict keyword... " >&6; } |
7f947b68 | 6326 | if ${ac_cv_c_restrict+:} false; then : |
c1d39fb8 CR |
6327 | $as_echo_n "(cached) " >&6 |
6328 | else | |
6329 | ac_cv_c_restrict=no | |
6330 | # The order here caters to the fact that C++ does not require restrict. | |
6331 | for ac_kw in __restrict __restrict__ _Restrict restrict; do | |
7f947b68 | 6332 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
c1d39fb8 CR |
6333 | /* end confdefs.h. */ |
6334 | typedef int * int_ptr; | |
6335 | int foo (int_ptr $ac_kw ip) { | |
6336 | return ip[0]; | |
6337 | } | |
6338 | int | |
6339 | main () | |
6340 | { | |
6341 | int s[1]; | |
6342 | int * $ac_kw t = s; | |
6343 | t[0] = 0; | |
6344 | return foo(t) | |
6345 | ; | |
6346 | return 0; | |
6347 | } | |
6348 | _ACEOF | |
7f947b68 | 6349 | if ac_fn_c_try_compile "$LINENO"; then : |
c1d39fb8 | 6350 | ac_cv_c_restrict=$ac_kw |
c1d39fb8 | 6351 | fi |
c1d39fb8 CR |
6352 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
6353 | test "$ac_cv_c_restrict" != no && break | |
6354 | done | |
6355 | ||
6356 | fi | |
7f947b68 | 6357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_restrict" >&5 |
c1d39fb8 CR |
6358 | $as_echo "$ac_cv_c_restrict" >&6; } |
6359 | ||
c1d39fb8 CR |
6360 | case $ac_cv_c_restrict in |
6361 | restrict) ;; | |
7f947b68 | 6362 | no) $as_echo "#define restrict /**/" >>confdefs.h |
c1d39fb8 CR |
6363 | ;; |
6364 | *) cat >>confdefs.h <<_ACEOF | |
6365 | #define restrict $ac_cv_c_restrict | |
6366 | _ACEOF | |
6367 | ;; | |
6368 | esac | |
6369 | ||
a82a04b3 CR |
6370 | |
6371 | ||
5e13499c CR |
6372 | MKINSTALLDIRS= |
6373 | if test -n "$ac_aux_dir"; then | |
6374 | case "$ac_aux_dir" in | |
6375 | /*) MKINSTALLDIRS="$ac_aux_dir/mkinstalldirs" ;; | |
6376 | *) MKINSTALLDIRS="\$(top_builddir)/$ac_aux_dir/mkinstalldirs" ;; | |
6377 | esac | |
6378 | fi | |
6379 | if test -z "$MKINSTALLDIRS"; then | |
6380 | MKINSTALLDIRS="\$(top_srcdir)/mkinstalldirs" | |
6381 | fi | |
6382 | ||
a82a04b3 CR |
6383 | |
6384 | ||
7f947b68 | 6385 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
dd4f3dd8 | 6386 | $as_echo_n "checking whether NLS is requested... " >&6; } |
b709b946 | 6387 | # Check whether --enable-nls was given. |
7f947b68 | 6388 | if test "${enable_nls+set}" = set; then : |
b709b946 | 6389 | enableval=$enable_nls; USE_NLS=$enableval |
5e13499c CR |
6390 | else |
6391 | USE_NLS=yes | |
b709b946 CR |
6392 | fi |
6393 | ||
7f947b68 | 6394 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
dd4f3dd8 | 6395 | $as_echo "$USE_NLS" >&6; } |
5e13499c | 6396 | |
a82a04b3 CR |
6397 | |
6398 | ||
6399 | ||
6400 | ||
6401 | ||
5e13499c CR |
6402 | # Prepare PATH_SEPARATOR. |
6403 | # The user is always right. | |
6404 | if test "${PATH_SEPARATOR+set}" != set; then | |
6405 | echo "#! /bin/sh" >conf$$.sh | |
6406 | echo "exit 0" >>conf$$.sh | |
6407 | chmod +x conf$$.sh | |
6408 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6409 | PATH_SEPARATOR=';' | |
6410 | else | |
6411 | PATH_SEPARATOR=: | |
6412 | fi | |
6413 | rm -f conf$$.sh | |
6414 | fi | |
6415 | ||
6416 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6417 | # as systems may use methods other than mode bits to determine executability. | |
6418 | cat >conf$$.file <<_ASEOF | |
6419 | #! /bin/sh | |
6420 | exit 0 | |
6421 | _ASEOF | |
6422 | chmod +x conf$$.file | |
6423 | if test -x conf$$.file >/dev/null 2>&1; then | |
6424 | ac_executable_p="test -x" | |
6425 | else | |
6426 | ac_executable_p="test -f" | |
6427 | fi | |
6428 | rm -f conf$$.file | |
6429 | ||
6430 | # Extract the first word of "msgfmt", so it can be a program name with args. | |
6431 | set dummy msgfmt; ac_word=$2 | |
7f947b68 | 6432 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6433 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 6434 | if ${ac_cv_path_MSGFMT+:} false; then : |
dd4f3dd8 | 6435 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6436 | else |
6437 | case "$MSGFMT" in | |
6438 | [\\/]* | ?:[\\/]*) | |
6439 | ac_cv_path_MSGFMT="$MSGFMT" # Let the user override the test with a path. | |
6440 | ;; | |
6441 | *) | |
6442 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6443 | for ac_dir in $PATH; do | |
6444 | IFS="$ac_save_IFS" | |
6445 | test -z "$ac_dir" && ac_dir=. | |
6446 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6447 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6448 | if $ac_dir/$ac_word --statistics /dev/null >/dev/null 2>&1 && | |
6449 | (if $ac_dir/$ac_word --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6450 | ac_cv_path_MSGFMT="$ac_dir/$ac_word$ac_exec_ext" | |
6451 | break 2 | |
6452 | fi | |
6453 | fi | |
6454 | done | |
6455 | done | |
6456 | IFS="$ac_save_IFS" | |
6457 | test -z "$ac_cv_path_MSGFMT" && ac_cv_path_MSGFMT=":" | |
6458 | ;; | |
6459 | esac | |
6460 | fi | |
6461 | MSGFMT="$ac_cv_path_MSGFMT" | |
6462 | if test "$MSGFMT" != ":"; then | |
7f947b68 | 6463 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGFMT" >&5 |
dd4f3dd8 | 6464 | $as_echo "$MSGFMT" >&6; } |
5e13499c | 6465 | else |
7f947b68 | 6466 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6467 | $as_echo "no" >&6; } |
5e13499c CR |
6468 | fi |
6469 | ||
6470 | # Extract the first word of "gmsgfmt", so it can be a program name with args. | |
6471 | set dummy gmsgfmt; ac_word=$2 | |
7f947b68 | 6472 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6473 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 6474 | if ${ac_cv_path_GMSGFMT+:} false; then : |
dd4f3dd8 | 6475 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6476 | else |
6477 | case $GMSGFMT in | |
6478 | [\\/]* | ?:[\\/]*) | |
6479 | ac_cv_path_GMSGFMT="$GMSGFMT" # Let the user override the test with a path. | |
6480 | ;; | |
6481 | *) | |
a82a04b3 CR |
6482 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
6483 | for as_dir in $PATH | |
6484 | do | |
6485 | IFS=$as_save_IFS | |
6486 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 6487 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 6488 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 6489 | ac_cv_path_GMSGFMT="$as_dir/$ac_word$ac_exec_ext" |
7f947b68 | 6490 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
6491 | break 2 |
6492 | fi | |
6493 | done | |
7f947b68 | 6494 | done |
b709b946 | 6495 | IFS=$as_save_IFS |
5e13499c CR |
6496 | |
6497 | test -z "$ac_cv_path_GMSGFMT" && ac_cv_path_GMSGFMT="$MSGFMT" | |
6498 | ;; | |
6499 | esac | |
6500 | fi | |
6501 | GMSGFMT=$ac_cv_path_GMSGFMT | |
5e13499c | 6502 | if test -n "$GMSGFMT"; then |
7f947b68 | 6503 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GMSGFMT" >&5 |
dd4f3dd8 | 6504 | $as_echo "$GMSGFMT" >&6; } |
5e13499c | 6505 | else |
7f947b68 | 6506 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6507 | $as_echo "no" >&6; } |
5e13499c CR |
6508 | fi |
6509 | ||
a82a04b3 CR |
6510 | |
6511 | ||
b709b946 | 6512 | |
5e13499c CR |
6513 | # Prepare PATH_SEPARATOR. |
6514 | # The user is always right. | |
6515 | if test "${PATH_SEPARATOR+set}" != set; then | |
6516 | echo "#! /bin/sh" >conf$$.sh | |
6517 | echo "exit 0" >>conf$$.sh | |
6518 | chmod +x conf$$.sh | |
6519 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6520 | PATH_SEPARATOR=';' | |
6521 | else | |
6522 | PATH_SEPARATOR=: | |
6523 | fi | |
6524 | rm -f conf$$.sh | |
6525 | fi | |
6526 | ||
6527 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6528 | # as systems may use methods other than mode bits to determine executability. | |
6529 | cat >conf$$.file <<_ASEOF | |
6530 | #! /bin/sh | |
6531 | exit 0 | |
6532 | _ASEOF | |
6533 | chmod +x conf$$.file | |
6534 | if test -x conf$$.file >/dev/null 2>&1; then | |
6535 | ac_executable_p="test -x" | |
6536 | else | |
6537 | ac_executable_p="test -f" | |
6538 | fi | |
6539 | rm -f conf$$.file | |
6540 | ||
6541 | # Extract the first word of "xgettext", so it can be a program name with args. | |
6542 | set dummy xgettext; ac_word=$2 | |
7f947b68 | 6543 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6544 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 6545 | if ${ac_cv_path_XGETTEXT+:} false; then : |
dd4f3dd8 | 6546 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6547 | else |
6548 | case "$XGETTEXT" in | |
6549 | [\\/]* | ?:[\\/]*) | |
6550 | ac_cv_path_XGETTEXT="$XGETTEXT" # Let the user override the test with a path. | |
6551 | ;; | |
6552 | *) | |
6553 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6554 | for ac_dir in $PATH; do | |
6555 | IFS="$ac_save_IFS" | |
6556 | test -z "$ac_dir" && ac_dir=. | |
6557 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6558 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6559 | if $ac_dir/$ac_word --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6560 | (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 | |
6561 | ac_cv_path_XGETTEXT="$ac_dir/$ac_word$ac_exec_ext" | |
6562 | break 2 | |
6563 | fi | |
6564 | fi | |
6565 | done | |
6566 | done | |
6567 | IFS="$ac_save_IFS" | |
6568 | test -z "$ac_cv_path_XGETTEXT" && ac_cv_path_XGETTEXT=":" | |
6569 | ;; | |
6570 | esac | |
6571 | fi | |
6572 | XGETTEXT="$ac_cv_path_XGETTEXT" | |
6573 | if test "$XGETTEXT" != ":"; then | |
7f947b68 | 6574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XGETTEXT" >&5 |
dd4f3dd8 | 6575 | $as_echo "$XGETTEXT" >&6; } |
5e13499c | 6576 | else |
7f947b68 | 6577 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6578 | $as_echo "no" >&6; } |
5e13499c CR |
6579 | fi |
6580 | ||
6581 | rm -f messages.po | |
6582 | ||
a82a04b3 | 6583 | |
5e13499c CR |
6584 | # Prepare PATH_SEPARATOR. |
6585 | # The user is always right. | |
6586 | if test "${PATH_SEPARATOR+set}" != set; then | |
6587 | echo "#! /bin/sh" >conf$$.sh | |
6588 | echo "exit 0" >>conf$$.sh | |
6589 | chmod +x conf$$.sh | |
6590 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6591 | PATH_SEPARATOR=';' | |
6592 | else | |
6593 | PATH_SEPARATOR=: | |
6594 | fi | |
6595 | rm -f conf$$.sh | |
6596 | fi | |
6597 | ||
6598 | # Find out how to test for executable files. Don't use a zero-byte file, | |
6599 | # as systems may use methods other than mode bits to determine executability. | |
6600 | cat >conf$$.file <<_ASEOF | |
6601 | #! /bin/sh | |
6602 | exit 0 | |
6603 | _ASEOF | |
6604 | chmod +x conf$$.file | |
6605 | if test -x conf$$.file >/dev/null 2>&1; then | |
6606 | ac_executable_p="test -x" | |
6607 | else | |
6608 | ac_executable_p="test -f" | |
6609 | fi | |
6610 | rm -f conf$$.file | |
6611 | ||
6612 | # Extract the first word of "msgmerge", so it can be a program name with args. | |
6613 | set dummy msgmerge; ac_word=$2 | |
7f947b68 | 6614 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 6615 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 6616 | if ${ac_cv_path_MSGMERGE+:} false; then : |
dd4f3dd8 | 6617 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
6618 | else |
6619 | case "$MSGMERGE" in | |
6620 | [\\/]* | ?:[\\/]*) | |
6621 | ac_cv_path_MSGMERGE="$MSGMERGE" # Let the user override the test with a path. | |
6622 | ;; | |
6623 | *) | |
6624 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6625 | for ac_dir in $PATH; do | |
6626 | IFS="$ac_save_IFS" | |
6627 | test -z "$ac_dir" && ac_dir=. | |
6628 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6629 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6630 | if $ac_dir/$ac_word --update -q /dev/null /dev/null >/dev/null 2>&1; then | |
6631 | ac_cv_path_MSGMERGE="$ac_dir/$ac_word$ac_exec_ext" | |
6632 | break 2 | |
6633 | fi | |
6634 | fi | |
6635 | done | |
6636 | done | |
6637 | IFS="$ac_save_IFS" | |
6638 | test -z "$ac_cv_path_MSGMERGE" && ac_cv_path_MSGMERGE=":" | |
6639 | ;; | |
6640 | esac | |
6641 | fi | |
6642 | MSGMERGE="$ac_cv_path_MSGMERGE" | |
6643 | if test "$MSGMERGE" != ":"; then | |
7f947b68 | 6644 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSGMERGE" >&5 |
dd4f3dd8 | 6645 | $as_echo "$MSGMERGE" >&6; } |
5e13499c | 6646 | else |
7f947b68 | 6647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 6648 | $as_echo "no" >&6; } |
5e13499c CR |
6649 | fi |
6650 | ||
a82a04b3 | 6651 | |
5e13499c CR |
6652 | if test "$GMSGFMT" != ":"; then |
6653 | if $GMSGFMT --statistics /dev/null >/dev/null 2>&1 && | |
6654 | (if $GMSGFMT --statistics /dev/null 2>&1 >/dev/null | grep usage >/dev/null; then exit 1; else exit 0; fi); then | |
6655 | : ; | |
6656 | else | |
6657 | GMSGFMT=`echo "$GMSGFMT" | sed -e 's,^.*/,,'` | |
7f947b68 | 6658 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found $GMSGFMT program is not GNU msgfmt; ignore it" >&5 |
dd4f3dd8 | 6659 | $as_echo "found $GMSGFMT program is not GNU msgfmt; ignore it" >&6; } |
5e13499c CR |
6660 | GMSGFMT=":" |
6661 | fi | |
6662 | fi | |
6663 | ||
6664 | if test "$XGETTEXT" != ":"; then | |
6665 | if $XGETTEXT --omit-header --copyright-holder= --msgid-bugs-address= /dev/null >/dev/null 2>&1 && | |
6666 | (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 | |
6667 | : ; | |
6668 | else | |
7f947b68 | 6669 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: found xgettext program is not GNU xgettext; ignore it" >&5 |
dd4f3dd8 | 6670 | $as_echo "found xgettext program is not GNU xgettext; ignore it" >&6; } |
5e13499c CR |
6671 | XGETTEXT=":" |
6672 | fi | |
6673 | rm -f messages.po | |
6674 | fi | |
6675 | ||
b709b946 | 6676 | ac_config_commands="$ac_config_commands default-1" |
a82a04b3 | 6677 | |
5e13499c | 6678 | |
7f947b68 CR |
6679 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
6680 | if test "x$ac_cv_type_off_t" = xyes; then : | |
e3db237e | 6681 | |
5e13499c CR |
6682 | else |
6683 | ||
a82a04b3 | 6684 | cat >>confdefs.h <<_ACEOF |
b709b946 | 6685 | #define off_t long int |
a82a04b3 | 6686 | _ACEOF |
5e13499c CR |
6687 | |
6688 | fi | |
6689 | ||
7f947b68 CR |
6690 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
6691 | if test "x$ac_cv_type_size_t" = xyes; then : | |
abe2eb5b | 6692 | |
5e13499c CR |
6693 | else |
6694 | ||
a82a04b3 | 6695 | cat >>confdefs.h <<_ACEOF |
b709b946 | 6696 | #define size_t unsigned int |
a82a04b3 | 6697 | _ACEOF |
5e13499c CR |
6698 | |
6699 | fi | |
6700 | ||
6701 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
6702 | # for constant arguments. Useless! | |
7f947b68 | 6703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 |
dd4f3dd8 | 6704 | $as_echo_n "checking for working alloca.h... " >&6; } |
7f947b68 | 6705 | if ${ac_cv_working_alloca_h+:} false; then : |
dd4f3dd8 | 6706 | $as_echo_n "(cached) " >&6 |
5e13499c | 6707 | else |
7f947b68 | 6708 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6709 | /* end confdefs.h. */ |
5e13499c CR |
6710 | #include <alloca.h> |
6711 | int | |
6712 | main () | |
6713 | { | |
6714 | char *p = (char *) alloca (2 * sizeof (int)); | |
b709b946 | 6715 | if (p) return 0; |
5e13499c CR |
6716 | ; |
6717 | return 0; | |
6718 | } | |
6719 | _ACEOF | |
7f947b68 | 6720 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
6721 | ac_cv_working_alloca_h=yes |
6722 | else | |
7f947b68 | 6723 | ac_cv_working_alloca_h=no |
5e13499c | 6724 | fi |
7f947b68 CR |
6725 | rm -f core conftest.err conftest.$ac_objext \ |
6726 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 6727 | fi |
7f947b68 | 6728 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 |
dd4f3dd8 | 6729 | $as_echo "$ac_cv_working_alloca_h" >&6; } |
5e13499c CR |
6730 | if test $ac_cv_working_alloca_h = yes; then |
6731 | ||
7f947b68 | 6732 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h |
5e13499c CR |
6733 | |
6734 | fi | |
6735 | ||
7f947b68 | 6736 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
dd4f3dd8 | 6737 | $as_echo_n "checking for alloca... " >&6; } |
7f947b68 | 6738 | if ${ac_cv_func_alloca_works+:} false; then : |
dd4f3dd8 | 6739 | $as_echo_n "(cached) " >&6 |
5e13499c | 6740 | else |
7f947b68 | 6741 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6742 | /* end confdefs.h. */ |
5e13499c CR |
6743 | #ifdef __GNUC__ |
6744 | # define alloca __builtin_alloca | |
6745 | #else | |
6746 | # ifdef _MSC_VER | |
6747 | # include <malloc.h> | |
6748 | # define alloca _alloca | |
6749 | # else | |
dd4f3dd8 | 6750 | # ifdef HAVE_ALLOCA_H |
5e13499c CR |
6751 | # include <alloca.h> |
6752 | # else | |
6753 | # ifdef _AIX | |
6754 | #pragma alloca | |
6755 | # else | |
6756 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
7f947b68 | 6757 | void *alloca (size_t); |
5e13499c CR |
6758 | # endif |
6759 | # endif | |
6760 | # endif | |
6761 | # endif | |
6762 | #endif | |
6763 | ||
6764 | int | |
6765 | main () | |
6766 | { | |
6767 | char *p = (char *) alloca (1); | |
b709b946 | 6768 | if (p) return 0; |
5e13499c CR |
6769 | ; |
6770 | return 0; | |
6771 | } | |
6772 | _ACEOF | |
7f947b68 | 6773 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
6774 | ac_cv_func_alloca_works=yes |
6775 | else | |
7f947b68 | 6776 | ac_cv_func_alloca_works=no |
5e13499c | 6777 | fi |
7f947b68 CR |
6778 | rm -f core conftest.err conftest.$ac_objext \ |
6779 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 6780 | fi |
7f947b68 | 6781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
dd4f3dd8 | 6782 | $as_echo "$ac_cv_func_alloca_works" >&6; } |
5e13499c CR |
6783 | |
6784 | if test $ac_cv_func_alloca_works = yes; then | |
6785 | ||
7f947b68 | 6786 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h |
5e13499c CR |
6787 | |
6788 | else | |
6789 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
6790 | # that cause trouble. Some versions do not even contain alloca or | |
6791 | # contain a buggy version. If you still want to use their alloca, | |
6792 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
6793 | ||
b709b946 | 6794 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext |
5e13499c | 6795 | |
7f947b68 | 6796 | $as_echo "#define C_ALLOCA 1" >>confdefs.h |
a82a04b3 | 6797 | |
545f34cf | 6798 | |
7f947b68 | 6799 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 |
dd4f3dd8 | 6800 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } |
7f947b68 | 6801 | if ${ac_cv_os_cray+:} false; then : |
dd4f3dd8 | 6802 | $as_echo_n "(cached) " >&6 |
5e13499c | 6803 | else |
7f947b68 | 6804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6805 | /* end confdefs.h. */ |
b709b946 | 6806 | #if defined CRAY && ! defined CRAY2 |
5e13499c CR |
6807 | webecray |
6808 | #else | |
6809 | wenotbecray | |
6810 | #endif | |
6811 | ||
6812 | _ACEOF | |
6813 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 6814 | $EGREP "webecray" >/dev/null 2>&1; then : |
5e13499c CR |
6815 | ac_cv_os_cray=yes |
6816 | else | |
6817 | ac_cv_os_cray=no | |
6818 | fi | |
6819 | rm -f conftest* | |
6820 | ||
6821 | fi | |
7f947b68 | 6822 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 |
dd4f3dd8 | 6823 | $as_echo "$ac_cv_os_cray" >&6; } |
5e13499c CR |
6824 | if test $ac_cv_os_cray = yes; then |
6825 | for ac_func in _getb67 GETB67 getb67; do | |
dd4f3dd8 | 6826 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` |
7f947b68 CR |
6827 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" |
6828 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
abe2eb5b CR |
6829 | |
6830 | cat >>confdefs.h <<_ACEOF | |
6831 | #define CRAY_STACKSEG_END $ac_func | |
6832 | _ACEOF | |
6833 | ||
6834 | break | |
6835 | fi | |
6836 | ||
6837 | done | |
6838 | fi | |
6839 | ||
7f947b68 | 6840 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 |
abe2eb5b | 6841 | $as_echo_n "checking stack direction for C alloca... " >&6; } |
7f947b68 | 6842 | if ${ac_cv_c_stack_direction+:} false; then : |
abe2eb5b CR |
6843 | $as_echo_n "(cached) " >&6 |
6844 | else | |
7f947b68 | 6845 | if test "$cross_compiling" = yes; then : |
abe2eb5b CR |
6846 | ac_cv_c_stack_direction=0 |
6847 | else | |
7f947b68 | 6848 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 6849 | /* end confdefs.h. */ |
e3db237e CR |
6850 | $ac_includes_default |
6851 | int | |
6852 | find_stack_direction () | |
6853 | { | |
6854 | static char *addr = 0; | |
6855 | auto char dummy; | |
6856 | if (addr == 0) | |
5e13499c CR |
6857 | { |
6858 | addr = &dummy; | |
6859 | return find_stack_direction (); | |
6860 | } | |
6861 | else | |
6862 | return (&dummy > addr) ? 1 : -1; | |
6863 | } | |
6864 | ||
6865 | int | |
6866 | main () | |
6867 | { | |
b709b946 | 6868 | return find_stack_direction () < 0; |
5e13499c CR |
6869 | } |
6870 | _ACEOF | |
7f947b68 | 6871 | if ac_fn_c_try_run "$LINENO"; then : |
5e13499c CR |
6872 | ac_cv_c_stack_direction=1 |
6873 | else | |
7f947b68 | 6874 | ac_cv_c_stack_direction=-1 |
5e13499c | 6875 | fi |
7f947b68 CR |
6876 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
6877 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e13499c | 6878 | fi |
b709b946 | 6879 | |
5e13499c | 6880 | fi |
7f947b68 | 6881 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 |
dd4f3dd8 | 6882 | $as_echo "$ac_cv_c_stack_direction" >&6; } |
a82a04b3 | 6883 | cat >>confdefs.h <<_ACEOF |
5e13499c | 6884 | #define STACK_DIRECTION $ac_cv_c_stack_direction |
a82a04b3 CR |
6885 | _ACEOF |
6886 | ||
5e13499c CR |
6887 | |
6888 | fi | |
6889 | ||
a82a04b3 CR |
6890 | |
6891 | ||
abe2eb5b | 6892 | |
7f947b68 CR |
6893 | for ac_header in $ac_header_list |
6894 | do : | |
6895 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
6896 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
6897 | " | |
6898 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
2dead0c4 CR |
6899 | cat >>confdefs.h <<_ACEOF |
6900 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
6901 | _ACEOF | |
6902 | ||
e3db237e | 6903 | fi |
2dead0c4 CR |
6904 | |
6905 | done | |
6906 | ||
6907 | ||
6908 | ||
6909 | ||
6910 | ||
6911 | ||
6912 | ||
6913 | ||
7f947b68 CR |
6914 | for ac_func in getpagesize |
6915 | do : | |
6916 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
6917 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
2dead0c4 | 6918 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 6919 | #define HAVE_GETPAGESIZE 1 |
a82a04b3 | 6920 | _ACEOF |
5e13499c CR |
6921 | |
6922 | fi | |
6923 | done | |
6924 | ||
7f947b68 | 6925 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 |
dd4f3dd8 | 6926 | $as_echo_n "checking for working mmap... " >&6; } |
7f947b68 | 6927 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : |
dd4f3dd8 | 6928 | $as_echo_n "(cached) " >&6 |
5e13499c | 6929 | else |
7f947b68 | 6930 | if test "$cross_compiling" = yes; then : |
5e13499c CR |
6931 | ac_cv_func_mmap_fixed_mapped=no |
6932 | else | |
7f947b68 | 6933 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 6934 | /* end confdefs.h. */ |
5e13499c | 6935 | $ac_includes_default |
a82a04b3 CR |
6936 | /* malloc might have been renamed as rpl_malloc. */ |
6937 | #undef malloc | |
6938 | ||
5e13499c CR |
6939 | /* Thanks to Mike Haertel and Jim Avera for this test. |
6940 | Here is a matrix of mmap possibilities: | |
6941 | mmap private not fixed | |
6942 | mmap private fixed at somewhere currently unmapped | |
6943 | mmap private fixed at somewhere already mapped | |
6944 | mmap shared not fixed | |
6945 | mmap shared fixed at somewhere currently unmapped | |
6946 | mmap shared fixed at somewhere already mapped | |
6947 | For private mappings, we should verify that changes cannot be read() | |
6948 | back from the file, nor mmap's back from the file at a different | |
6949 | address. (There have been systems where private was not correctly | |
6950 | implemented like the infamous i386 svr4.0, and systems where the | |
6951 | VM page cache was not coherent with the file system buffer cache | |
6952 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
6953 | For shared mappings, we should conversely verify that changes get | |
a82a04b3 | 6954 | propagated back to all the places they're supposed to be. |
5e13499c CR |
6955 | |
6956 | Grep wants private fixed already mapped. | |
6957 | The main things grep needs to know about mmap are: | |
6958 | * does it exist and is it safe to write into the mmap'd area | |
6959 | * how to use it (BSD variants) */ | |
6960 | ||
6961 | #include <fcntl.h> | |
6962 | #include <sys/mman.h> | |
6963 | ||
dd4f3dd8 | 6964 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H |
5e13499c CR |
6965 | char *malloc (); |
6966 | #endif | |
6967 | ||
6968 | /* This mess was copied from the GNU getpagesize.h. */ | |
dd4f3dd8 | 6969 | #ifndef HAVE_GETPAGESIZE |
5e13499c CR |
6970 | # ifdef _SC_PAGESIZE |
6971 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
6972 | # else /* no _SC_PAGESIZE */ | |
dd4f3dd8 | 6973 | # ifdef HAVE_SYS_PARAM_H |
5e13499c CR |
6974 | # include <sys/param.h> |
6975 | # ifdef EXEC_PAGESIZE | |
6976 | # define getpagesize() EXEC_PAGESIZE | |
6977 | # else /* no EXEC_PAGESIZE */ | |
6978 | # ifdef NBPG | |
6979 | # define getpagesize() NBPG * CLSIZE | |
6980 | # ifndef CLSIZE | |
6981 | # define CLSIZE 1 | |
6982 | # endif /* no CLSIZE */ | |
6983 | # else /* no NBPG */ | |
6984 | # ifdef NBPC | |
6985 | # define getpagesize() NBPC | |
6986 | # else /* no NBPC */ | |
6987 | # ifdef PAGESIZE | |
6988 | # define getpagesize() PAGESIZE | |
6989 | # endif /* PAGESIZE */ | |
6990 | # endif /* no NBPC */ | |
6991 | # endif /* no NBPG */ | |
6992 | # endif /* no EXEC_PAGESIZE */ | |
6993 | # else /* no HAVE_SYS_PARAM_H */ | |
6994 | # define getpagesize() 8192 /* punt totally */ | |
6995 | # endif /* no HAVE_SYS_PARAM_H */ | |
6996 | # endif /* no _SC_PAGESIZE */ | |
6997 | ||
6998 | #endif /* no HAVE_GETPAGESIZE */ | |
6999 | ||
7000 | int | |
7001 | main () | |
7002 | { | |
7003 | char *data, *data2, *data3; | |
7f947b68 | 7004 | const char *cdata2; |
5e13499c | 7005 | int i, pagesize; |
7f947b68 | 7006 | int fd, fd2; |
5e13499c CR |
7007 | |
7008 | pagesize = getpagesize (); | |
7009 | ||
7010 | /* First, make a file with some known garbage in it. */ | |
7011 | data = (char *) malloc (pagesize); | |
7012 | if (!data) | |
b709b946 | 7013 | return 1; |
5e13499c CR |
7014 | for (i = 0; i < pagesize; ++i) |
7015 | *(data + i) = rand (); | |
7016 | umask (0); | |
7017 | fd = creat ("conftest.mmap", 0600); | |
7018 | if (fd < 0) | |
7f947b68 | 7019 | return 2; |
5e13499c | 7020 | if (write (fd, data, pagesize) != pagesize) |
7f947b68 | 7021 | return 3; |
5e13499c CR |
7022 | close (fd); |
7023 | ||
7f947b68 CR |
7024 | /* Next, check that the tail of a page is zero-filled. File must have |
7025 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
7026 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
7027 | if (fd2 < 0) | |
7028 | return 4; | |
7029 | cdata2 = ""; | |
7030 | if (write (fd2, cdata2, 1) != 1) | |
7031 | return 5; | |
7032 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
7033 | if (data2 == MAP_FAILED) | |
7034 | return 6; | |
7035 | for (i = 0; i < pagesize; ++i) | |
7036 | if (*(data2 + i)) | |
7037 | return 7; | |
7038 | close (fd2); | |
7039 | if (munmap (data2, pagesize)) | |
7040 | return 8; | |
7041 | ||
5e13499c CR |
7042 | /* Next, try to mmap the file at a fixed address which already has |
7043 | something else allocated at it. If we can, also make sure that | |
7044 | we see the same garbage. */ | |
7045 | fd = open ("conftest.mmap", O_RDWR); | |
7046 | if (fd < 0) | |
7f947b68 | 7047 | return 9; |
5e13499c | 7048 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, |
5e4a95c7 | 7049 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) |
7f947b68 | 7050 | return 10; |
5e13499c CR |
7051 | for (i = 0; i < pagesize; ++i) |
7052 | if (*(data + i) != *(data2 + i)) | |
7f947b68 | 7053 | return 11; |
5e13499c CR |
7054 | |
7055 | /* Finally, make sure that changes to the mapped area do not | |
7056 | percolate back to the file as seen by read(). (This is a bug on | |
7057 | some variants of i386 svr4.0.) */ | |
7058 | for (i = 0; i < pagesize; ++i) | |
7059 | *(data2 + i) = *(data2 + i) + 1; | |
7060 | data3 = (char *) malloc (pagesize); | |
7061 | if (!data3) | |
7f947b68 | 7062 | return 12; |
5e13499c | 7063 | if (read (fd, data3, pagesize) != pagesize) |
7f947b68 | 7064 | return 13; |
5e13499c CR |
7065 | for (i = 0; i < pagesize; ++i) |
7066 | if (*(data + i) != *(data3 + i)) | |
7f947b68 | 7067 | return 14; |
5e13499c | 7068 | close (fd); |
b709b946 | 7069 | return 0; |
5e13499c CR |
7070 | } |
7071 | _ACEOF | |
7f947b68 | 7072 | if ac_fn_c_try_run "$LINENO"; then : |
5e13499c CR |
7073 | ac_cv_func_mmap_fixed_mapped=yes |
7074 | else | |
7f947b68 | 7075 | ac_cv_func_mmap_fixed_mapped=no |
5e13499c | 7076 | fi |
7f947b68 CR |
7077 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7078 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e13499c | 7079 | fi |
b709b946 | 7080 | |
5e13499c | 7081 | fi |
7f947b68 | 7082 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 |
dd4f3dd8 | 7083 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } |
5e13499c CR |
7084 | if test $ac_cv_func_mmap_fixed_mapped = yes; then |
7085 | ||
7f947b68 | 7086 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
5e13499c CR |
7087 | |
7088 | fi | |
7f947b68 | 7089 | rm -f conftest.mmap conftest.txt |
5e13499c | 7090 | |
a82a04b3 | 7091 | |
7f947b68 | 7092 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C Library 2.1 or newer" >&5 |
dd4f3dd8 | 7093 | $as_echo_n "checking whether we are using the GNU C Library 2.1 or newer... " >&6; } |
7f947b68 | 7094 | if ${ac_cv_gnu_library_2_1+:} false; then : |
dd4f3dd8 | 7095 | $as_echo_n "(cached) " >&6 |
5e13499c | 7096 | else |
7f947b68 | 7097 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7098 | /* end confdefs.h. */ |
5e13499c CR |
7099 | |
7100 | #include <features.h> | |
7101 | #ifdef __GNU_LIBRARY__ | |
7102 | #if (__GLIBC__ == 2 && __GLIBC_MINOR__ >= 1) || (__GLIBC__ > 2) | |
7103 | Lucky GNU user | |
7104 | #endif | |
7105 | #endif | |
7106 | ||
7107 | _ACEOF | |
7108 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 7109 | $EGREP "Lucky GNU user" >/dev/null 2>&1; then : |
5e13499c CR |
7110 | ac_cv_gnu_library_2_1=yes |
7111 | else | |
7112 | ac_cv_gnu_library_2_1=no | |
7113 | fi | |
7114 | rm -f conftest* | |
7115 | ||
a82a04b3 CR |
7116 | |
7117 | ||
5e13499c | 7118 | fi |
7f947b68 | 7119 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_gnu_library_2_1" >&5 |
dd4f3dd8 | 7120 | $as_echo "$ac_cv_gnu_library_2_1" >&6; } |
5e13499c CR |
7121 | |
7122 | GLIBC21="$ac_cv_gnu_library_2_1" | |
7123 | ||
a82a04b3 CR |
7124 | |
7125 | ||
7126 | ||
7f947b68 | 7127 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether integer division by zero raises SIGFPE" >&5 |
dd4f3dd8 | 7128 | $as_echo_n "checking whether integer division by zero raises SIGFPE... " >&6; } |
7f947b68 | 7129 | if ${gt_cv_int_divbyzero_sigfpe+:} false; then : |
dd4f3dd8 | 7130 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7131 | else |
7132 | ||
7f947b68 | 7133 | if test "$cross_compiling" = yes; then : |
5e13499c CR |
7134 | |
7135 | # Guess based on the CPU. | |
7136 | case "$host_cpu" in | |
7137 | alpha* | i3456786 | m68k | s390*) | |
7138 | gt_cv_int_divbyzero_sigfpe="guessing yes";; | |
7139 | *) | |
7140 | gt_cv_int_divbyzero_sigfpe="guessing no";; | |
7141 | esac | |
7142 | ||
7143 | else | |
7f947b68 | 7144 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7145 | /* end confdefs.h. */ |
5e13499c CR |
7146 | |
7147 | #include <stdlib.h> | |
7148 | #include <signal.h> | |
7149 | ||
7150 | static void | |
7151 | #ifdef __cplusplus | |
7152 | sigfpe_handler (int sig) | |
7153 | #else | |
7154 | sigfpe_handler (sig) int sig; | |
7155 | #endif | |
7156 | { | |
7157 | /* Exit with code 0 if SIGFPE, with code 1 if any other signal. */ | |
7158 | exit (sig != SIGFPE); | |
7159 | } | |
7160 | ||
7161 | int x = 1; | |
7162 | int y = 0; | |
7163 | int z; | |
7164 | int nan; | |
7165 | ||
7166 | int main () | |
7167 | { | |
7168 | signal (SIGFPE, sigfpe_handler); | |
7169 | /* IRIX and AIX (when "xlc -qcheck" is used) yield signal SIGTRAP. */ | |
7170 | #if (defined (__sgi) || defined (_AIX)) && defined (SIGTRAP) | |
7171 | signal (SIGTRAP, sigfpe_handler); | |
7172 | #endif | |
7173 | /* Linux/SPARC yields signal SIGILL. */ | |
7174 | #if defined (__sparc__) && defined (__linux__) | |
7175 | signal (SIGILL, sigfpe_handler); | |
7176 | #endif | |
7177 | ||
7178 | z = x / y; | |
7179 | nan = y / y; | |
7180 | exit (1); | |
7181 | } | |
7182 | ||
7183 | _ACEOF | |
7f947b68 | 7184 | if ac_fn_c_try_run "$LINENO"; then : |
5e13499c CR |
7185 | gt_cv_int_divbyzero_sigfpe=yes |
7186 | else | |
7f947b68 | 7187 | gt_cv_int_divbyzero_sigfpe=no |
5e13499c | 7188 | fi |
7f947b68 CR |
7189 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7190 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e13499c CR |
7191 | fi |
7192 | ||
b709b946 | 7193 | |
5e13499c | 7194 | fi |
7f947b68 | 7195 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_int_divbyzero_sigfpe" >&5 |
dd4f3dd8 | 7196 | $as_echo "$gt_cv_int_divbyzero_sigfpe" >&6; } |
5e13499c CR |
7197 | case "$gt_cv_int_divbyzero_sigfpe" in |
7198 | *yes) value=1;; | |
7199 | *) value=0;; | |
7200 | esac | |
7201 | ||
a82a04b3 | 7202 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7203 | #define INTDIV0_RAISES_SIGFPE $value |
a82a04b3 CR |
7204 | _ACEOF |
7205 | ||
545f34cf | 7206 | |
a82a04b3 | 7207 | |
7f947b68 | 7208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
dd4f3dd8 | 7209 | $as_echo_n "checking for inttypes.h... " >&6; } |
7f947b68 | 7210 | if ${jm_ac_cv_header_inttypes_h+:} false; then : |
dd4f3dd8 | 7211 | $as_echo_n "(cached) " >&6 |
5e13499c | 7212 | else |
7f947b68 | 7213 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7214 | /* end confdefs.h. */ |
5e13499c CR |
7215 | #include <sys/types.h> |
7216 | #include <inttypes.h> | |
7217 | int | |
7218 | main () | |
7219 | { | |
7220 | uintmax_t i = (uintmax_t) -1; | |
7221 | ; | |
7222 | return 0; | |
7223 | } | |
7224 | _ACEOF | |
7f947b68 | 7225 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
7226 | jm_ac_cv_header_inttypes_h=yes |
7227 | else | |
7f947b68 | 7228 | jm_ac_cv_header_inttypes_h=no |
5e13499c | 7229 | fi |
b709b946 | 7230 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c | 7231 | fi |
7f947b68 | 7232 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_inttypes_h" >&5 |
dd4f3dd8 | 7233 | $as_echo "$jm_ac_cv_header_inttypes_h" >&6; } |
5e13499c CR |
7234 | if test $jm_ac_cv_header_inttypes_h = yes; then |
7235 | ||
a82a04b3 | 7236 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7237 | #define HAVE_INTTYPES_H_WITH_UINTMAX 1 |
a82a04b3 | 7238 | _ACEOF |
5e13499c CR |
7239 | |
7240 | fi | |
7241 | ||
a82a04b3 | 7242 | |
7f947b68 | 7243 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for stdint.h" >&5 |
dd4f3dd8 | 7244 | $as_echo_n "checking for stdint.h... " >&6; } |
7f947b68 | 7245 | if ${jm_ac_cv_header_stdint_h+:} false; then : |
dd4f3dd8 | 7246 | $as_echo_n "(cached) " >&6 |
5e13499c | 7247 | else |
7f947b68 | 7248 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7249 | /* end confdefs.h. */ |
5e13499c CR |
7250 | #include <sys/types.h> |
7251 | #include <stdint.h> | |
7252 | int | |
7253 | main () | |
7254 | { | |
7255 | uintmax_t i = (uintmax_t) -1; | |
7256 | ; | |
7257 | return 0; | |
7258 | } | |
7259 | _ACEOF | |
7f947b68 | 7260 | if ac_fn_c_try_compile "$LINENO"; then : |
abe2eb5b CR |
7261 | jm_ac_cv_header_stdint_h=yes |
7262 | else | |
7f947b68 | 7263 | jm_ac_cv_header_stdint_h=no |
7610e0c5 | 7264 | fi |
abe2eb5b CR |
7265 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7266 | fi | |
7f947b68 | 7267 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $jm_ac_cv_header_stdint_h" >&5 |
7610e0c5 | 7268 | $as_echo "$jm_ac_cv_header_stdint_h" >&6; } |
5e13499c CR |
7269 | if test $jm_ac_cv_header_stdint_h = yes; then |
7270 | ||
a82a04b3 | 7271 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7272 | #define HAVE_STDINT_H_WITH_UINTMAX 1 |
a82a04b3 | 7273 | _ACEOF |
5e13499c CR |
7274 | |
7275 | fi | |
7276 | ||
a82a04b3 | 7277 | |
7f947b68 | 7278 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 |
dd4f3dd8 | 7279 | $as_echo_n "checking for unsigned long long... " >&6; } |
7f947b68 | 7280 | if ${ac_cv_type_unsigned_long_long+:} false; then : |
dd4f3dd8 | 7281 | $as_echo_n "(cached) " >&6 |
5e13499c | 7282 | else |
7f947b68 | 7283 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7284 | /* end confdefs.h. */ |
5e13499c CR |
7285 | unsigned long long ull = 1; int i = 63; |
7286 | int | |
7287 | main () | |
7288 | { | |
7289 | unsigned long long ullmax = (unsigned long long) -1; | |
7290 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
7291 | ; | |
7292 | return 0; | |
7293 | } | |
7294 | _ACEOF | |
7f947b68 | 7295 | if ac_fn_c_try_link "$LINENO"; then : |
e3db237e | 7296 | ac_cv_type_unsigned_long_long=yes |
5e13499c | 7297 | else |
7f947b68 | 7298 | ac_cv_type_unsigned_long_long=no |
5e13499c | 7299 | fi |
7f947b68 CR |
7300 | rm -f core conftest.err conftest.$ac_objext \ |
7301 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 7302 | fi |
7f947b68 | 7303 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long" >&5 |
dd4f3dd8 | 7304 | $as_echo "$ac_cv_type_unsigned_long_long" >&6; } |
5e13499c CR |
7305 | if test $ac_cv_type_unsigned_long_long = yes; then |
7306 | ||
7f947b68 | 7307 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h |
5e13499c CR |
7308 | |
7309 | fi | |
7310 | ||
a82a04b3 CR |
7311 | |
7312 | ||
7313 | ||
5e13499c CR |
7314 | if test $jm_ac_cv_header_inttypes_h = no && test $jm_ac_cv_header_stdint_h = no; then |
7315 | ||
7316 | test $ac_cv_type_unsigned_long_long = yes \ | |
7317 | && ac_type='unsigned long long' \ | |
7318 | || ac_type='unsigned long' | |
7319 | ||
a82a04b3 | 7320 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7321 | #define uintmax_t $ac_type |
a82a04b3 | 7322 | _ACEOF |
5e13499c CR |
7323 | |
7324 | else | |
7325 | ||
7f947b68 | 7326 | $as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h |
5e13499c CR |
7327 | |
7328 | fi | |
7329 | ||
a82a04b3 | 7330 | |
7f947b68 | 7331 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
dd4f3dd8 | 7332 | $as_echo_n "checking for inttypes.h... " >&6; } |
7f947b68 | 7333 | if ${gt_cv_header_inttypes_h+:} false; then : |
dd4f3dd8 | 7334 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7335 | else |
7336 | ||
7f947b68 | 7337 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7338 | /* end confdefs.h. */ |
5e13499c CR |
7339 | #include <sys/types.h> |
7340 | #include <inttypes.h> | |
7341 | int | |
7342 | main () | |
7343 | { | |
7344 | ||
7345 | ; | |
7346 | return 0; | |
7347 | } | |
7348 | _ACEOF | |
7f947b68 | 7349 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
7350 | gt_cv_header_inttypes_h=yes |
7351 | else | |
7f947b68 | 7352 | gt_cv_header_inttypes_h=no |
5e13499c | 7353 | fi |
b709b946 | 7354 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
7355 | |
7356 | fi | |
7f947b68 | 7357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_header_inttypes_h" >&5 |
dd4f3dd8 | 7358 | $as_echo "$gt_cv_header_inttypes_h" >&6; } |
5e13499c CR |
7359 | if test $gt_cv_header_inttypes_h = yes; then |
7360 | ||
a82a04b3 | 7361 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7362 | #define HAVE_INTTYPES_H 1 |
a82a04b3 | 7363 | _ACEOF |
5e13499c CR |
7364 | |
7365 | fi | |
7366 | ||
a82a04b3 CR |
7367 | |
7368 | ||
5e13499c | 7369 | if test $gt_cv_header_inttypes_h = yes; then |
7f947b68 | 7370 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the inttypes.h PRIxNN macros are broken" >&5 |
dd4f3dd8 | 7371 | $as_echo_n "checking whether the inttypes.h PRIxNN macros are broken... " >&6; } |
7f947b68 | 7372 | if ${gt_cv_inttypes_pri_broken+:} false; then : |
dd4f3dd8 | 7373 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7374 | else |
7375 | ||
7f947b68 | 7376 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 7377 | /* end confdefs.h. */ |
5e13499c CR |
7378 | #include <inttypes.h> |
7379 | #ifdef PRId32 | |
7380 | char *p = PRId32; | |
7381 | #endif | |
7382 | ||
7383 | int | |
7384 | main () | |
7385 | { | |
7386 | ||
7387 | ; | |
7388 | return 0; | |
7389 | } | |
7390 | _ACEOF | |
7f947b68 | 7391 | if ac_fn_c_try_compile "$LINENO"; then : |
2e4498b3 CR |
7392 | gt_cv_inttypes_pri_broken=no |
7393 | else | |
7f947b68 | 7394 | gt_cv_inttypes_pri_broken=yes |
5e13499c | 7395 | fi |
b709b946 | 7396 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
7397 | |
7398 | fi | |
7f947b68 | 7399 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_inttypes_pri_broken" >&5 |
dd4f3dd8 | 7400 | $as_echo "$gt_cv_inttypes_pri_broken" >&6; } |
5e13499c CR |
7401 | fi |
7402 | if test "$gt_cv_inttypes_pri_broken" = yes; then | |
7403 | ||
a82a04b3 | 7404 | cat >>confdefs.h <<_ACEOF |
5e13499c | 7405 | #define PRI_MACROS_BROKEN 1 |
a82a04b3 | 7406 | _ACEOF |
5e13499c CR |
7407 | |
7408 | fi | |
7409 | ||
a82a04b3 | 7410 | |
5e13499c CR |
7411 | if test "X$prefix" = "XNONE"; then |
7412 | acl_final_prefix="$ac_default_prefix" | |
7413 | else | |
7414 | acl_final_prefix="$prefix" | |
7415 | fi | |
7416 | if test "X$exec_prefix" = "XNONE"; then | |
7417 | acl_final_exec_prefix='${prefix}' | |
7418 | else | |
7419 | acl_final_exec_prefix="$exec_prefix" | |
7420 | fi | |
7421 | acl_save_prefix="$prefix" | |
7422 | prefix="$acl_final_prefix" | |
7423 | eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" | |
7424 | prefix="$acl_save_prefix" | |
7425 | ||
a82a04b3 | 7426 | |
b709b946 | 7427 | # Check whether --with-gnu-ld was given. |
7f947b68 | 7428 | if test "${with_gnu_ld+set}" = set; then : |
b709b946 | 7429 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes |
5e13499c CR |
7430 | else |
7431 | with_gnu_ld=no | |
b709b946 CR |
7432 | fi |
7433 | ||
5e13499c CR |
7434 | # Prepare PATH_SEPARATOR. |
7435 | # The user is always right. | |
7436 | if test "${PATH_SEPARATOR+set}" != set; then | |
7437 | echo "#! /bin/sh" >conf$$.sh | |
7438 | echo "exit 0" >>conf$$.sh | |
7439 | chmod +x conf$$.sh | |
7440 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
7441 | PATH_SEPARATOR=';' | |
7442 | else | |
7443 | PATH_SEPARATOR=: | |
7444 | fi | |
7445 | rm -f conf$$.sh | |
7446 | fi | |
7447 | ac_prog=ld | |
7448 | if test "$GCC" = yes; then | |
7449 | # Check if gcc -print-prog-name=ld gives a path. | |
7f947b68 | 7450 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 |
dd4f3dd8 | 7451 | $as_echo_n "checking for ld used by GCC... " >&6; } |
5e13499c CR |
7452 | case $host in |
7453 | *-*-mingw*) | |
7454 | # gcc leaves a trailing carriage return which upsets mingw | |
7455 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
7456 | *) | |
7457 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
7458 | esac | |
7459 | case $ac_prog in | |
7460 | # Accept absolute paths. | |
7461 | [\\/]* | [A-Za-z]:[\\/]*) | |
7462 | re_direlt='/[^/][^/]*/\.\./' | |
7463 | # Canonicalize the path of ld | |
7464 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
7465 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
7466 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
7467 | done | |
7468 | test -z "$LD" && LD="$ac_prog" | |
7469 | ;; | |
7470 | "") | |
7471 | # If it fails, then pretend we aren't using GCC. | |
7472 | ac_prog=ld | |
7473 | ;; | |
7474 | *) | |
7475 | # If it is relative, then search for the first ld in PATH. | |
7476 | with_gnu_ld=unknown | |
7477 | ;; | |
7478 | esac | |
7479 | elif test "$with_gnu_ld" = yes; then | |
7f947b68 | 7480 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
dd4f3dd8 | 7481 | $as_echo_n "checking for GNU ld... " >&6; } |
5e13499c | 7482 | else |
7f947b68 | 7483 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
dd4f3dd8 | 7484 | $as_echo_n "checking for non-GNU ld... " >&6; } |
5e13499c | 7485 | fi |
7f947b68 | 7486 | if ${acl_cv_path_LD+:} false; then : |
dd4f3dd8 | 7487 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7488 | else |
7489 | if test -z "$LD"; then | |
7490 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" | |
7491 | for ac_dir in $PATH; do | |
7492 | test -z "$ac_dir" && ac_dir=. | |
7493 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
7494 | acl_cv_path_LD="$ac_dir/$ac_prog" | |
7495 | # Check to see if the program is GNU ld. I'd rather use --version, | |
7496 | # but apparently some GNU ld's only accept -v. | |
7497 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
7498 | if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then | |
7499 | test "$with_gnu_ld" != no && break | |
7500 | else | |
7501 | test "$with_gnu_ld" != yes && break | |
7502 | fi | |
7503 | fi | |
7504 | done | |
7505 | IFS="$ac_save_ifs" | |
7506 | else | |
7507 | acl_cv_path_LD="$LD" # Let the user override the test with a path. | |
7508 | fi | |
7509 | fi | |
7510 | ||
7511 | LD="$acl_cv_path_LD" | |
7512 | if test -n "$LD"; then | |
7f947b68 | 7513 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
dd4f3dd8 | 7514 | $as_echo "$LD" >&6; } |
5e13499c | 7515 | else |
7f947b68 | 7516 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 7517 | $as_echo "no" >&6; } |
5e13499c | 7518 | fi |
7f947b68 CR |
7519 | test -z "$LD" && as_fn_error $? "no acceptable ld found in \$PATH" "$LINENO" 5 |
7520 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
dd4f3dd8 | 7521 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } |
7f947b68 | 7522 | if ${acl_cv_prog_gnu_ld+:} false; then : |
dd4f3dd8 | 7523 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7524 | else |
7525 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
7526 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then | |
7527 | acl_cv_prog_gnu_ld=yes | |
7528 | else | |
7529 | acl_cv_prog_gnu_ld=no | |
7530 | fi | |
7531 | fi | |
7f947b68 | 7532 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5 |
dd4f3dd8 | 7533 | $as_echo "$acl_cv_prog_gnu_ld" >&6; } |
5e13499c CR |
7534 | with_gnu_ld=$acl_cv_prog_gnu_ld |
7535 | ||
a82a04b3 CR |
7536 | |
7537 | ||
7f947b68 | 7538 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 |
dd4f3dd8 | 7539 | $as_echo_n "checking for shared library run path origin... " >&6; } |
7f947b68 | 7540 | if ${acl_cv_rpath+:} false; then : |
dd4f3dd8 | 7541 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
7542 | else |
7543 | ||
7544 | CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ | |
7545 | ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh | |
7546 | . ./conftest.sh | |
7547 | rm -f ./conftest.sh | |
7548 | acl_cv_rpath=done | |
7549 | ||
7550 | fi | |
7f947b68 | 7551 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 |
dd4f3dd8 | 7552 | $as_echo "$acl_cv_rpath" >&6; } |
5e13499c CR |
7553 | wl="$acl_cv_wl" |
7554 | libext="$acl_cv_libext" | |
7555 | shlibext="$acl_cv_shlibext" | |
7556 | hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" | |
7557 | hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" | |
7558 | hardcode_direct="$acl_cv_hardcode_direct" | |
7559 | hardcode_minus_L="$acl_cv_hardcode_minus_L" | |
b709b946 | 7560 | # Check whether --enable-rpath was given. |
7f947b68 | 7561 | if test "${enable_rpath+set}" = set; then : |
b709b946 | 7562 | enableval=$enable_rpath; : |
5e13499c CR |
7563 | else |
7564 | enable_rpath=yes | |
b709b946 CR |
7565 | fi |
7566 | ||
5e13499c | 7567 | |
a82a04b3 CR |
7568 | |
7569 | ||
7570 | ||
7571 | ||
7572 | ||
7573 | ||
5e13499c CR |
7574 | use_additional=yes |
7575 | ||
7576 | acl_save_prefix="$prefix" | |
7577 | prefix="$acl_final_prefix" | |
7578 | acl_save_exec_prefix="$exec_prefix" | |
7579 | exec_prefix="$acl_final_exec_prefix" | |
7580 | ||
7581 | eval additional_includedir=\"$includedir\" | |
7582 | eval additional_libdir=\"$libdir\" | |
7583 | ||
7584 | exec_prefix="$acl_save_exec_prefix" | |
7585 | prefix="$acl_save_prefix" | |
7586 | ||
a82a04b3 | 7587 | |
b709b946 | 7588 | # Check whether --with-libiconv-prefix was given. |
7f947b68 | 7589 | if test "${with_libiconv_prefix+set}" = set; then : |
b709b946 | 7590 | withval=$with_libiconv_prefix; |
5e13499c CR |
7591 | if test "X$withval" = "Xno"; then |
7592 | use_additional=no | |
7593 | else | |
7594 | if test "X$withval" = "X"; then | |
7595 | ||
7596 | acl_save_prefix="$prefix" | |
7597 | prefix="$acl_final_prefix" | |
7598 | acl_save_exec_prefix="$exec_prefix" | |
7599 | exec_prefix="$acl_final_exec_prefix" | |
7600 | ||
7601 | eval additional_includedir=\"$includedir\" | |
7602 | eval additional_libdir=\"$libdir\" | |
7603 | ||
7604 | exec_prefix="$acl_save_exec_prefix" | |
7605 | prefix="$acl_save_prefix" | |
7606 | ||
7607 | else | |
7608 | additional_includedir="$withval/include" | |
7609 | additional_libdir="$withval/lib" | |
7610 | fi | |
7611 | fi | |
7612 | ||
b709b946 CR |
7613 | fi |
7614 | ||
5e13499c CR |
7615 | LIBICONV= |
7616 | LTLIBICONV= | |
7617 | INCICONV= | |
7618 | rpathdirs= | |
7619 | ltrpathdirs= | |
7620 | names_already_handled= | |
7621 | names_next_round='iconv ' | |
7622 | while test -n "$names_next_round"; do | |
7623 | names_this_round="$names_next_round" | |
7624 | names_next_round= | |
7625 | for name in $names_this_round; do | |
7626 | already_handled= | |
7627 | for n in $names_already_handled; do | |
7628 | if test "$n" = "$name"; then | |
7629 | already_handled=yes | |
7630 | break | |
7631 | fi | |
7632 | done | |
7633 | if test -z "$already_handled"; then | |
7634 | names_already_handled="$names_already_handled $name" | |
7635 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
7636 | eval value=\"\$HAVE_LIB$uppername\" | |
7637 | if test -n "$value"; then | |
7638 | if test "$value" = yes; then | |
7639 | eval value=\"\$LIB$uppername\" | |
7640 | test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" | |
7641 | eval value=\"\$LTLIB$uppername\" | |
7642 | test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" | |
7643 | else | |
7644 | : | |
7645 | fi | |
7646 | else | |
7647 | found_dir= | |
7648 | found_la= | |
7649 | found_so= | |
7650 | found_a= | |
7651 | if test $use_additional = yes; then | |
f4f5e1c2 | 7652 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
5e13499c CR |
7653 | found_dir="$additional_libdir" |
7654 | found_so="$additional_libdir/lib$name.$shlibext" | |
7655 | if test -f "$additional_libdir/lib$name.la"; then | |
7656 | found_la="$additional_libdir/lib$name.la" | |
7657 | fi | |
7658 | else | |
7659 | if test -f "$additional_libdir/lib$name.$libext"; then | |
7660 | found_dir="$additional_libdir" | |
7661 | found_a="$additional_libdir/lib$name.$libext" | |
7662 | if test -f "$additional_libdir/lib$name.la"; then | |
7663 | found_la="$additional_libdir/lib$name.la" | |
7664 | fi | |
7665 | fi | |
7666 | fi | |
7667 | fi | |
7668 | if test "X$found_dir" = "X"; then | |
7669 | for x in $LDFLAGS $LTLIBICONV; do | |
7670 | ||
7671 | acl_save_prefix="$prefix" | |
7672 | prefix="$acl_final_prefix" | |
7673 | acl_save_exec_prefix="$exec_prefix" | |
7674 | exec_prefix="$acl_final_exec_prefix" | |
7675 | eval x=\"$x\" | |
7676 | exec_prefix="$acl_save_exec_prefix" | |
7677 | prefix="$acl_save_prefix" | |
7678 | ||
7679 | case "$x" in | |
7680 | -L*) | |
7681 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
f4f5e1c2 | 7682 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
5e13499c CR |
7683 | found_dir="$dir" |
7684 | found_so="$dir/lib$name.$shlibext" | |
7685 | if test -f "$dir/lib$name.la"; then | |
7686 | found_la="$dir/lib$name.la" | |
7687 | fi | |
7688 | else | |
7689 | if test -f "$dir/lib$name.$libext"; then | |
7690 | found_dir="$dir" | |
7691 | found_a="$dir/lib$name.$libext" | |
7692 | if test -f "$dir/lib$name.la"; then | |
7693 | found_la="$dir/lib$name.la" | |
7694 | fi | |
7695 | fi | |
7696 | fi | |
7697 | ;; | |
7698 | esac | |
7699 | if test "X$found_dir" != "X"; then | |
7700 | break | |
7701 | fi | |
7702 | done | |
7703 | fi | |
7704 | if test "X$found_dir" != "X"; then | |
7705 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" | |
7706 | if test "X$found_so" != "X"; then | |
7707 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
7708 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7709 | else | |
7710 | haveit= | |
7711 | for x in $ltrpathdirs; do | |
7712 | if test "X$x" = "X$found_dir"; then | |
7713 | haveit=yes | |
7714 | break | |
7715 | fi | |
7716 | done | |
7717 | if test -z "$haveit"; then | |
7718 | ltrpathdirs="$ltrpathdirs $found_dir" | |
7719 | fi | |
7720 | if test "$hardcode_direct" = yes; then | |
7721 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7722 | else | |
7723 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
7724 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7725 | haveit= | |
7726 | for x in $rpathdirs; do | |
7727 | if test "X$x" = "X$found_dir"; then | |
7728 | haveit=yes | |
7729 | break | |
7730 | fi | |
7731 | done | |
7732 | if test -z "$haveit"; then | |
7733 | rpathdirs="$rpathdirs $found_dir" | |
7734 | fi | |
7735 | else | |
7736 | haveit= | |
7737 | for x in $LDFLAGS $LIBICONV; do | |
7738 | ||
7739 | acl_save_prefix="$prefix" | |
7740 | prefix="$acl_final_prefix" | |
7741 | acl_save_exec_prefix="$exec_prefix" | |
7742 | exec_prefix="$acl_final_exec_prefix" | |
7743 | eval x=\"$x\" | |
7744 | exec_prefix="$acl_save_exec_prefix" | |
7745 | prefix="$acl_save_prefix" | |
7746 | ||
7747 | if test "X$x" = "X-L$found_dir"; then | |
7748 | haveit=yes | |
7749 | break | |
7750 | fi | |
7751 | done | |
7752 | if test -z "$haveit"; then | |
7753 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" | |
7754 | fi | |
7755 | if test "$hardcode_minus_L" != no; then | |
7756 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
7757 | else | |
7758 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
7759 | fi | |
7760 | fi | |
7761 | fi | |
7762 | fi | |
7763 | else | |
7764 | if test "X$found_a" != "X"; then | |
7765 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" | |
7766 | else | |
7767 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" | |
7768 | fi | |
7769 | fi | |
7770 | additional_includedir= | |
7771 | case "$found_dir" in | |
7772 | */lib | */lib/) | |
7773 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
7774 | additional_includedir="$basedir/include" | |
7775 | ;; | |
7776 | esac | |
7777 | if test "X$additional_includedir" != "X"; then | |
7778 | if test "X$additional_includedir" != "X/usr/include"; then | |
7779 | haveit= | |
7780 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
7781 | if test -n "$GCC"; then | |
7782 | case $host_os in | |
7783 | linux*) haveit=yes;; | |
7784 | esac | |
7785 | fi | |
7786 | fi | |
7787 | if test -z "$haveit"; then | |
7788 | for x in $CPPFLAGS $INCICONV; do | |
7789 | ||
7790 | acl_save_prefix="$prefix" | |
7791 | prefix="$acl_final_prefix" | |
7792 | acl_save_exec_prefix="$exec_prefix" | |
7793 | exec_prefix="$acl_final_exec_prefix" | |
7794 | eval x=\"$x\" | |
7795 | exec_prefix="$acl_save_exec_prefix" | |
7796 | prefix="$acl_save_prefix" | |
7797 | ||
7798 | if test "X$x" = "X-I$additional_includedir"; then | |
7799 | haveit=yes | |
7800 | break | |
7801 | fi | |
7802 | done | |
7803 | if test -z "$haveit"; then | |
7804 | if test -d "$additional_includedir"; then | |
7805 | INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" | |
7806 | fi | |
7807 | fi | |
7808 | fi | |
7809 | fi | |
7810 | fi | |
7811 | if test -n "$found_la"; then | |
7812 | save_libdir="$libdir" | |
7813 | case "$found_la" in | |
7814 | */* | *\\*) . "$found_la" ;; | |
7815 | *) . "./$found_la" ;; | |
7816 | esac | |
7817 | libdir="$save_libdir" | |
7818 | for dep in $dependency_libs; do | |
7819 | case "$dep" in | |
7820 | -L*) | |
7821 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
7822 | if test "X$additional_libdir" != "X/usr/lib"; then | |
7823 | haveit= | |
7824 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
7825 | if test -n "$GCC"; then | |
7826 | case $host_os in | |
7827 | linux*) haveit=yes;; | |
7828 | esac | |
7829 | fi | |
7830 | fi | |
7831 | if test -z "$haveit"; then | |
7832 | haveit= | |
7833 | for x in $LDFLAGS $LIBICONV; do | |
7834 | ||
7835 | acl_save_prefix="$prefix" | |
7836 | prefix="$acl_final_prefix" | |
7837 | acl_save_exec_prefix="$exec_prefix" | |
7838 | exec_prefix="$acl_final_exec_prefix" | |
7839 | eval x=\"$x\" | |
7840 | exec_prefix="$acl_save_exec_prefix" | |
7841 | prefix="$acl_save_prefix" | |
7842 | ||
7843 | if test "X$x" = "X-L$additional_libdir"; then | |
7844 | haveit=yes | |
7845 | break | |
7846 | fi | |
7847 | done | |
7848 | if test -z "$haveit"; then | |
7849 | if test -d "$additional_libdir"; then | |
7850 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" | |
7851 | fi | |
7852 | fi | |
7853 | haveit= | |
7854 | for x in $LDFLAGS $LTLIBICONV; do | |
7855 | ||
7856 | acl_save_prefix="$prefix" | |
7857 | prefix="$acl_final_prefix" | |
7858 | acl_save_exec_prefix="$exec_prefix" | |
7859 | exec_prefix="$acl_final_exec_prefix" | |
7860 | eval x=\"$x\" | |
7861 | exec_prefix="$acl_save_exec_prefix" | |
7862 | prefix="$acl_save_prefix" | |
7863 | ||
7864 | if test "X$x" = "X-L$additional_libdir"; then | |
7865 | haveit=yes | |
7866 | break | |
7867 | fi | |
7868 | done | |
7869 | if test -z "$haveit"; then | |
7870 | if test -d "$additional_libdir"; then | |
7871 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" | |
7872 | fi | |
7873 | fi | |
7874 | fi | |
7875 | fi | |
7876 | ;; | |
7877 | -R*) | |
7878 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
7879 | if test "$enable_rpath" != no; then | |
7880 | haveit= | |
7881 | for x in $rpathdirs; do | |
7882 | if test "X$x" = "X$dir"; then | |
7883 | haveit=yes | |
7884 | break | |
7885 | fi | |
7886 | done | |
7887 | if test -z "$haveit"; then | |
7888 | rpathdirs="$rpathdirs $dir" | |
7889 | fi | |
7890 | haveit= | |
7891 | for x in $ltrpathdirs; do | |
7892 | if test "X$x" = "X$dir"; then | |
7893 | haveit=yes | |
7894 | break | |
7895 | fi | |
7896 | done | |
7897 | if test -z "$haveit"; then | |
7898 | ltrpathdirs="$ltrpathdirs $dir" | |
7899 | fi | |
7900 | fi | |
7901 | ;; | |
7902 | -l*) | |
7903 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
7904 | ;; | |
7905 | *.la) | |
7906 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
7907 | ;; | |
7908 | *) | |
7909 | LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" | |
7910 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" | |
7911 | ;; | |
7912 | esac | |
7913 | done | |
7914 | fi | |
7915 | else | |
7916 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
7917 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" | |
7918 | fi | |
7919 | fi | |
7920 | fi | |
7921 | done | |
7922 | done | |
7923 | if test "X$rpathdirs" != "X"; then | |
7924 | if test -n "$hardcode_libdir_separator"; then | |
7925 | alldirs= | |
7926 | for found_dir in $rpathdirs; do | |
7927 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
7928 | done | |
7929 | acl_save_libdir="$libdir" | |
7930 | libdir="$alldirs" | |
7931 | eval flag=\"$hardcode_libdir_flag_spec\" | |
7932 | libdir="$acl_save_libdir" | |
7933 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
7934 | else | |
7935 | for found_dir in $rpathdirs; do | |
7936 | acl_save_libdir="$libdir" | |
7937 | libdir="$found_dir" | |
7938 | eval flag=\"$hardcode_libdir_flag_spec\" | |
7939 | libdir="$acl_save_libdir" | |
7940 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
7941 | done | |
7942 | fi | |
7943 | fi | |
7944 | if test "X$ltrpathdirs" != "X"; then | |
7945 | for found_dir in $ltrpathdirs; do | |
7946 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" | |
7947 | done | |
7948 | fi | |
7949 | ||
a82a04b3 CR |
7950 | |
7951 | ||
7952 | ||
7f947b68 CR |
7953 | for ac_header in argz.h limits.h locale.h nl_types.h malloc.h stddef.h \ |
7954 | stdlib.h string.h unistd.h sys/param.h | |
7955 | do : | |
7956 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
7957 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
7958 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
7959 | cat >>confdefs.h <<_ACEOF | |
7960 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7961 | _ACEOF | |
abe2eb5b | 7962 | |
7f947b68 | 7963 | fi |
abe2eb5b | 7964 | |
7f947b68 | 7965 | done |
abe2eb5b | 7966 | |
7f947b68 CR |
7967 | for ac_func in feof_unlocked fgets_unlocked getc_unlocked getcwd getegid \ |
7968 | geteuid getgid getuid mempcpy munmap putenv setenv setlocale localeconv stpcpy \ | |
7969 | strcasecmp strdup strtoul tsearch __argz_count __argz_stringify __argz_next \ | |
7970 | __fsetlocking | |
7971 | do : | |
7972 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
7973 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
7974 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
7975 | cat >>confdefs.h <<_ACEOF | |
7976 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7977 | _ACEOF | |
abe2eb5b | 7978 | |
7f947b68 CR |
7979 | fi |
7980 | done | |
5e13499c | 7981 | |
a82a04b3 CR |
7982 | |
7983 | ||
7984 | ||
7985 | ||
7986 | ||
7987 | ||
5e13499c CR |
7988 | am_save_CPPFLAGS="$CPPFLAGS" |
7989 | ||
7990 | for element in $INCICONV; do | |
7991 | haveit= | |
7992 | for x in $CPPFLAGS; do | |
7993 | ||
7994 | acl_save_prefix="$prefix" | |
7995 | prefix="$acl_final_prefix" | |
7996 | acl_save_exec_prefix="$exec_prefix" | |
7997 | exec_prefix="$acl_final_exec_prefix" | |
7998 | eval x=\"$x\" | |
7999 | exec_prefix="$acl_save_exec_prefix" | |
8000 | prefix="$acl_save_prefix" | |
8001 | ||
8002 | if test "X$x" = "X$element"; then | |
8003 | haveit=yes | |
8004 | break | |
8005 | fi | |
8006 | done | |
8007 | if test -z "$haveit"; then | |
8008 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8009 | fi | |
8010 | done | |
8011 | ||
a82a04b3 | 8012 | |
7f947b68 | 8013 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 |
dd4f3dd8 | 8014 | $as_echo_n "checking for iconv... " >&6; } |
7f947b68 | 8015 | if ${am_cv_func_iconv+:} false; then : |
dd4f3dd8 | 8016 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8017 | else |
8018 | ||
8019 | am_cv_func_iconv="no, consider installing GNU libiconv" | |
8020 | am_cv_lib_iconv=no | |
7f947b68 | 8021 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8022 | /* end confdefs.h. */ |
5e13499c CR |
8023 | #include <stdlib.h> |
8024 | #include <iconv.h> | |
8025 | int | |
8026 | main () | |
8027 | { | |
8028 | iconv_t cd = iconv_open("",""); | |
8029 | iconv(cd,NULL,NULL,NULL,NULL); | |
8030 | iconv_close(cd); | |
8031 | ; | |
8032 | return 0; | |
8033 | } | |
8034 | _ACEOF | |
7f947b68 | 8035 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c | 8036 | am_cv_func_iconv=yes |
5e13499c | 8037 | fi |
7f947b68 CR |
8038 | rm -f core conftest.err conftest.$ac_objext \ |
8039 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8040 | if test "$am_cv_func_iconv" != yes; then |
8041 | am_save_LIBS="$LIBS" | |
8042 | LIBS="$LIBS $LIBICONV" | |
7f947b68 | 8043 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8044 | /* end confdefs.h. */ |
5e13499c CR |
8045 | #include <stdlib.h> |
8046 | #include <iconv.h> | |
8047 | int | |
8048 | main () | |
8049 | { | |
8050 | iconv_t cd = iconv_open("",""); | |
8051 | iconv(cd,NULL,NULL,NULL,NULL); | |
8052 | iconv_close(cd); | |
8053 | ; | |
8054 | return 0; | |
8055 | } | |
8056 | _ACEOF | |
7f947b68 | 8057 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8058 | am_cv_lib_iconv=yes |
8059 | am_cv_func_iconv=yes | |
5e13499c | 8060 | fi |
7f947b68 CR |
8061 | rm -f core conftest.err conftest.$ac_objext \ |
8062 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8063 | LIBS="$am_save_LIBS" |
8064 | fi | |
8065 | ||
8066 | fi | |
7f947b68 | 8067 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 |
dd4f3dd8 | 8068 | $as_echo "$am_cv_func_iconv" >&6; } |
5e13499c CR |
8069 | if test "$am_cv_func_iconv" = yes; then |
8070 | ||
7f947b68 | 8071 | $as_echo "#define HAVE_ICONV 1" >>confdefs.h |
5e13499c CR |
8072 | |
8073 | fi | |
8074 | if test "$am_cv_lib_iconv" = yes; then | |
7f947b68 | 8075 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 |
dd4f3dd8 | 8076 | $as_echo_n "checking how to link with libiconv... " >&6; } |
7f947b68 | 8077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 |
dd4f3dd8 | 8078 | $as_echo "$LIBICONV" >&6; } |
5e13499c CR |
8079 | else |
8080 | CPPFLAGS="$am_save_CPPFLAGS" | |
8081 | LIBICONV= | |
8082 | LTLIBICONV= | |
8083 | fi | |
8084 | ||
a82a04b3 CR |
8085 | |
8086 | ||
5e13499c | 8087 | if test "$am_cv_func_iconv" = yes; then |
7f947b68 | 8088 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5 |
dd4f3dd8 | 8089 | $as_echo_n "checking for iconv declaration... " >&6; } |
7f947b68 | 8090 | if ${am_cv_proto_iconv+:} false; then : |
dd4f3dd8 | 8091 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8092 | else |
8093 | ||
7f947b68 | 8094 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8095 | /* end confdefs.h. */ |
5e13499c CR |
8096 | |
8097 | #include <stdlib.h> | |
8098 | #include <iconv.h> | |
8099 | extern | |
8100 | #ifdef __cplusplus | |
8101 | "C" | |
8102 | #endif | |
8103 | #if defined(__STDC__) || defined(__cplusplus) | |
8104 | size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); | |
8105 | #else | |
8106 | size_t iconv(); | |
8107 | #endif | |
8108 | ||
8109 | int | |
8110 | main () | |
8111 | { | |
8112 | ||
8113 | ; | |
8114 | return 0; | |
8115 | } | |
8116 | _ACEOF | |
7f947b68 | 8117 | if ac_fn_c_try_compile "$LINENO"; then : |
5e13499c CR |
8118 | am_cv_proto_iconv_arg1="" |
8119 | else | |
7f947b68 | 8120 | am_cv_proto_iconv_arg1="const" |
5e13499c | 8121 | fi |
b709b946 | 8122 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5e13499c CR |
8123 | 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);" |
8124 | fi | |
8125 | ||
8126 | am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` | |
7f947b68 | 8127 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:- |
5e13499c | 8128 | }$am_cv_proto_iconv" >&5 |
dd4f3dd8 | 8129 | $as_echo "${ac_t:- |
b709b946 | 8130 | }$am_cv_proto_iconv" >&6; } |
5e13499c | 8131 | |
a82a04b3 | 8132 | cat >>confdefs.h <<_ACEOF |
5e13499c | 8133 | #define ICONV_CONST $am_cv_proto_iconv_arg1 |
a82a04b3 | 8134 | _ACEOF |
5e13499c CR |
8135 | |
8136 | fi | |
8137 | ||
a82a04b3 | 8138 | |
7f947b68 | 8139 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
dd4f3dd8 | 8140 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } |
7f947b68 | 8141 | if ${am_cv_langinfo_codeset+:} false; then : |
dd4f3dd8 | 8142 | $as_echo_n "(cached) " >&6 |
5e13499c | 8143 | else |
7f947b68 | 8144 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8145 | /* end confdefs.h. */ |
5e13499c CR |
8146 | #include <langinfo.h> |
8147 | int | |
8148 | main () | |
8149 | { | |
8150 | char* cs = nl_langinfo(CODESET); | |
8151 | ; | |
8152 | return 0; | |
8153 | } | |
8154 | _ACEOF | |
7f947b68 | 8155 | if ac_fn_c_try_link "$LINENO"; then : |
abe2eb5b | 8156 | am_cv_langinfo_codeset=yes |
5e13499c | 8157 | else |
7f947b68 | 8158 | am_cv_langinfo_codeset=no |
5e13499c | 8159 | fi |
7f947b68 CR |
8160 | rm -f core conftest.err conftest.$ac_objext \ |
8161 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c CR |
8162 | |
8163 | fi | |
7f947b68 | 8164 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5 |
dd4f3dd8 | 8165 | $as_echo "$am_cv_langinfo_codeset" >&6; } |
5e13499c CR |
8166 | if test $am_cv_langinfo_codeset = yes; then |
8167 | ||
7f947b68 | 8168 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h |
5e13499c CR |
8169 | |
8170 | fi | |
8171 | ||
8172 | if test $ac_cv_header_locale_h = yes; then | |
8173 | ||
7f947b68 | 8174 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 |
dd4f3dd8 | 8175 | $as_echo_n "checking for LC_MESSAGES... " >&6; } |
7f947b68 | 8176 | if ${am_cv_val_LC_MESSAGES+:} false; then : |
dd4f3dd8 | 8177 | $as_echo_n "(cached) " >&6 |
5e13499c | 8178 | else |
7f947b68 | 8179 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8180 | /* end confdefs.h. */ |
5e13499c CR |
8181 | #include <locale.h> |
8182 | int | |
8183 | main () | |
8184 | { | |
8185 | return LC_MESSAGES | |
8186 | ; | |
8187 | return 0; | |
8188 | } | |
8189 | _ACEOF | |
7f947b68 | 8190 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8191 | am_cv_val_LC_MESSAGES=yes |
8192 | else | |
7f947b68 | 8193 | am_cv_val_LC_MESSAGES=no |
5e13499c | 8194 | fi |
7f947b68 CR |
8195 | rm -f core conftest.err conftest.$ac_objext \ |
8196 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 8197 | fi |
7f947b68 | 8198 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5 |
dd4f3dd8 | 8199 | $as_echo "$am_cv_val_LC_MESSAGES" >&6; } |
5e13499c CR |
8200 | if test $am_cv_val_LC_MESSAGES = yes; then |
8201 | ||
7f947b68 | 8202 | $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h |
5e13499c CR |
8203 | |
8204 | fi | |
8205 | ||
8206 | fi | |
8207 | ||
8208 | for ac_prog in bison | |
8209 | do | |
8210 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
8211 | set dummy $ac_prog; ac_word=$2 | |
7f947b68 | 8212 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
dd4f3dd8 | 8213 | $as_echo_n "checking for $ac_word... " >&6; } |
7f947b68 | 8214 | if ${ac_cv_prog_INTLBISON+:} false; then : |
dd4f3dd8 | 8215 | $as_echo_n "(cached) " >&6 |
5e13499c CR |
8216 | else |
8217 | if test -n "$INTLBISON"; then | |
8218 | ac_cv_prog_INTLBISON="$INTLBISON" # Let the user override the test. | |
8219 | else | |
a82a04b3 CR |
8220 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
8221 | for as_dir in $PATH | |
8222 | do | |
8223 | IFS=$as_save_IFS | |
8224 | test -z "$as_dir" && as_dir=. | |
7f947b68 | 8225 | for ac_exec_ext in '' $ac_executable_extensions; do |
dd4f3dd8 | 8226 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then |
a82a04b3 | 8227 | ac_cv_prog_INTLBISON="$ac_prog" |
7f947b68 | 8228 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
a82a04b3 CR |
8229 | break 2 |
8230 | fi | |
8231 | done | |
7f947b68 | 8232 | done |
b709b946 | 8233 | IFS=$as_save_IFS |
5e13499c CR |
8234 | |
8235 | fi | |
8236 | fi | |
8237 | INTLBISON=$ac_cv_prog_INTLBISON | |
8238 | if test -n "$INTLBISON"; then | |
7f947b68 | 8239 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INTLBISON" >&5 |
dd4f3dd8 | 8240 | $as_echo "$INTLBISON" >&6; } |
5e13499c | 8241 | else |
7f947b68 | 8242 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
dd4f3dd8 | 8243 | $as_echo "no" >&6; } |
5e13499c CR |
8244 | fi |
8245 | ||
b709b946 | 8246 | |
5e13499c CR |
8247 | test -n "$INTLBISON" && break |
8248 | done | |
8249 | ||
8250 | if test -z "$INTLBISON"; then | |
8251 | ac_verc_fail=yes | |
8252 | else | |
7f947b68 | 8253 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking version of bison" >&5 |
dd4f3dd8 | 8254 | $as_echo_n "checking version of bison... " >&6; } |
e624d0f7 CR |
8255 | ac_prog_version=`$INTLBISON --version 2>&1 | sed -n 's/^.*GNU Bison.* \([0-9]*\.[0-9.]*\).*$/\1/p'` |
8256 | case $ac_prog_version in | |
8257 | '') ac_prog_version="v. ?.??, bad"; ac_verc_fail=yes;; | |
8258 | 1.2[6-9]* | 1.[3-9][0-9]* | [2-9].*) | |
8259 | ac_prog_version="$ac_prog_version, ok"; ac_verc_fail=no;; | |
8260 | *) ac_prog_version="$ac_prog_version, bad"; ac_verc_fail=yes;; | |
8261 | esac | |
7f947b68 | 8262 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_prog_version" >&5 |
dd4f3dd8 | 8263 | $as_echo "$ac_prog_version" >&6; } |
e624d0f7 CR |
8264 | fi |
8265 | if test $ac_verc_fail = yes; then | |
8266 | INTLBISON=: | |
8267 | fi | |
545f34cf | 8268 | |
a82a04b3 CR |
8269 | |
8270 | ||
8271 | ||
8272 | ||
8273 | ||
8274 | ||
8275 | ||
8276 | ||
8277 | ||
8278 | ||
8279 | ||
8280 | ||
8281 | ||
8282 | ||
8283 | ||
7f947b68 | 8284 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
dd4f3dd8 | 8285 | $as_echo_n "checking whether NLS is requested... " >&6; } |
b709b946 | 8286 | # Check whether --enable-nls was given. |
7f947b68 | 8287 | if test "${enable_nls+set}" = set; then : |
b709b946 | 8288 | enableval=$enable_nls; USE_NLS=$enableval |
5e13499c CR |
8289 | else |
8290 | USE_NLS=yes | |
b709b946 CR |
8291 | fi |
8292 | ||
7f947b68 | 8293 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 |
dd4f3dd8 | 8294 | $as_echo "$USE_NLS" >&6; } |
5e13499c | 8295 | |
a82a04b3 CR |
8296 | |
8297 | ||
8298 | ||
5e13499c CR |
8299 | BUILD_INCLUDED_LIBINTL=no |
8300 | USE_INCLUDED_LIBINTL=no | |
8301 | ||
8302 | LIBINTL= | |
8303 | LTLIBINTL= | |
8304 | POSUB= | |
8305 | ||
8306 | if test "$USE_NLS" = "yes"; then | |
8307 | gt_use_preinstalled_gnugettext=no | |
8308 | ||
7f947b68 | 8309 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether included gettext is requested" >&5 |
dd4f3dd8 | 8310 | $as_echo_n "checking whether included gettext is requested... " >&6; } |
5e13499c | 8311 | |
b709b946 | 8312 | # Check whether --with-included-gettext was given. |
7f947b68 | 8313 | if test "${with_included_gettext+set}" = set; then : |
b709b946 | 8314 | withval=$with_included_gettext; nls_cv_force_use_gnu_gettext=$withval |
5e13499c CR |
8315 | else |
8316 | nls_cv_force_use_gnu_gettext=no | |
b709b946 CR |
8317 | fi |
8318 | ||
7f947b68 | 8319 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $nls_cv_force_use_gnu_gettext" >&5 |
dd4f3dd8 | 8320 | $as_echo "$nls_cv_force_use_gnu_gettext" >&6; } |
5e13499c CR |
8321 | |
8322 | nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext" | |
8323 | if test "$nls_cv_force_use_gnu_gettext" != "yes"; then | |
8324 | ||
a82a04b3 CR |
8325 | |
8326 | ||
8327 | ||
8328 | ||
8329 | ||
7f947b68 | 8330 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libc" >&5 |
dd4f3dd8 | 8331 | $as_echo_n "checking for GNU gettext in libc... " >&6; } |
7f947b68 | 8332 | if ${gt_cv_func_gnugettext2_libc+:} false; then : |
dd4f3dd8 | 8333 | $as_echo_n "(cached) " >&6 |
5e13499c | 8334 | else |
7f947b68 | 8335 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 8336 | /* end confdefs.h. */ |
5e13499c CR |
8337 | #include <libintl.h> |
8338 | extern int _nl_msg_cat_cntr; | |
8339 | extern int *_nl_domain_bindings; | |
8340 | int | |
8341 | main () | |
8342 | { | |
8343 | bindtextdomain ("", ""); | |
8344 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_domain_bindings | |
8345 | ; | |
8346 | return 0; | |
8347 | } | |
8348 | _ACEOF | |
7f947b68 | 8349 | if ac_fn_c_try_link "$LINENO"; then : |
5e13499c CR |
8350 | gt_cv_func_gnugettext2_libc=yes |
8351 | else | |
7f947b68 | 8352 | gt_cv_func_gnugettext2_libc=no |
5e13499c | 8353 | fi |
7f947b68 CR |
8354 | rm -f core conftest.err conftest.$ac_objext \ |
8355 | conftest$ac_exeext conftest.$ac_ext | |
5e13499c | 8356 | fi |
7f947b68 | 8357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libc" >&5 |
dd4f3dd8 | 8358 | $as_echo "$gt_cv_func_gnugettext2_libc" >&6; } |
5e13499c CR |
8359 | |
8360 | if test "$gt_cv_func_gnugettext2_libc" != "yes"; then | |
8361 | ||
a82a04b3 CR |
8362 | |
8363 | ||
5e13499c CR |
8364 | use_additional=yes |
8365 | ||
8366 | acl_save_prefix="$prefix" | |
8367 | prefix="$acl_final_prefix" | |
8368 | acl_save_exec_prefix="$exec_prefix" | |
8369 | exec_prefix="$acl_final_exec_prefix" | |
8370 | ||
8371 | eval additional_includedir=\"$includedir\" | |
8372 | eval additional_libdir=\"$libdir\" | |
8373 | ||
8374 | exec_prefix="$acl_save_exec_prefix" | |
8375 | prefix="$acl_save_prefix" | |
8376 | ||
a82a04b3 | 8377 | |
b709b946 | 8378 | # Check whether --with-libintl-prefix was given. |
7f947b68 | 8379 | if test "${with_libintl_prefix+set}" = set; then : |
b709b946 | 8380 | withval=$with_libintl_prefix; |
5e13499c CR |
8381 | if test "X$withval" = "Xno"; then |
8382 | use_additional=no | |
8383 | else | |
8384 | if test "X$withval" = "X"; then | |
8385 | ||
8386 | acl_save_prefix="$prefix" | |
8387 | prefix="$acl_final_prefix" | |
8388 | acl_save_exec_prefix="$exec_prefix" | |
8389 | exec_prefix="$acl_final_exec_prefix" | |
8390 | ||
8391 | eval additional_includedir=\"$includedir\" | |
8392 | eval additional_libdir=\"$libdir\" | |
8393 | ||
8394 | exec_prefix="$acl_save_exec_prefix" | |
8395 | prefix="$acl_save_prefix" | |
8396 | ||
8397 | else | |
8398 | additional_includedir="$withval/include" | |
8399 | additional_libdir="$withval/lib" | |
8400 | fi | |
8401 | fi | |
8402 | ||
b709b946 CR |
8403 | fi |
8404 | ||
5e13499c CR |
8405 | LIBINTL= |
8406 | LTLIBINTL= | |
8407 | INCINTL= | |
8408 | rpathdirs= | |
8409 | ltrpathdirs= | |
8410 | names_already_handled= | |
8411 | names_next_round='intl ' | |
8412 | while test -n "$names_next_round"; do | |
8413 | names_this_round="$names_next_round" | |
8414 | names_next_round= | |
8415 | for name in $names_this_round; do | |
8416 | already_handled= | |
8417 | for n in $names_already_handled; do | |
8418 | if test "$n" = "$name"; then | |
8419 | already_handled=yes | |
8420 | break | |
8421 | fi | |
8422 | done | |
8423 | if test -z "$already_handled"; then | |
8424 | names_already_handled="$names_already_handled $name" | |
8425 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
8426 | eval value=\"\$HAVE_LIB$uppername\" | |
8427 | if test -n "$value"; then | |
8428 | if test "$value" = yes; then | |
8429 | eval value=\"\$LIB$uppername\" | |
8430 | test -z "$value" || LIBINTL="${LIBINTL}${LIBINTL:+ }$value" | |
8431 | eval value=\"\$LTLIB$uppername\" | |
8432 | test -z "$value" || LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$value" | |
8433 | else | |
8434 | : | |
8435 | fi | |
8436 | else | |
8437 | found_dir= | |
8438 | found_la= | |
8439 | found_so= | |
8440 | found_a= | |
8441 | if test $use_additional = yes; then | |
f4f5e1c2 | 8442 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then |
5e13499c CR |
8443 | found_dir="$additional_libdir" |
8444 | found_so="$additional_libdir/lib$name.$shlibext" | |
8445 | if test -f "$additional_libdir/lib$name.la"; then | |
8446 | found_la="$additional_libdir/lib$name.la" | |
8447 | fi | |
8448 | else | |
8449 | if test -f "$additional_libdir/lib$name.$libext"; then | |
8450 | found_dir="$additional_libdir" | |
8451 | found_a="$additional_libdir/lib$name.$libext" | |
8452 | if test -f "$additional_libdir/lib$name.la"; then | |
8453 | found_la="$additional_libdir/lib$name.la" | |
8454 | fi | |
8455 | fi | |
8456 | fi | |
8457 | fi | |
8458 | if test "X$found_dir" = "X"; then | |
8459 | for x in $LDFLAGS $LTLIBINTL; do | |
8460 | ||
8461 | acl_save_prefix="$prefix" | |
8462 | prefix="$acl_final_prefix" | |
8463 | acl_save_exec_prefix="$exec_prefix" | |
8464 | exec_prefix="$acl_final_exec_prefix" | |
8465 | eval x=\"$x\" | |
8466 | exec_prefix="$acl_save_exec_prefix" | |
8467 | prefix="$acl_save_prefix" | |
8468 | ||
8469 | case "$x" in | |
8470 | -L*) | |
8471 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
f4f5e1c2 | 8472 | if test "X$prefer_shared" = "Xyes" && test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then |
5e13499c CR |
8473 | found_dir="$dir" |
8474 | found_so="$dir/lib$name.$shlibext" | |
8475 | if test -f "$dir/lib$name.la"; then | |
8476 | found_la="$dir/lib$name.la" | |
8477 | fi | |
8478 | else | |
8479 | if test -f "$dir/lib$name.$libext"; then | |
8480 | found_dir="$dir" | |
8481 | found_a="$dir/lib$name.$libext" | |
8482 | if test -f "$dir/lib$name.la"; then | |
8483 | found_la="$dir/lib$name.la" | |
8484 | fi | |
8485 | fi | |
8486 | fi | |
8487 | ;; | |
8488 | esac | |
8489 | if test "X$found_dir" != "X"; then | |
8490 | break | |
8491 | fi | |
8492 | done | |
8493 | fi | |
8494 | if test "X$found_dir" != "X"; then | |
8495 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$found_dir -l$name" | |
8496 | if test "X$found_so" != "X"; then | |
8497 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
8498 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8499 | else | |
8500 | haveit= | |
8501 | for x in $ltrpathdirs; do | |
8502 | if test "X$x" = "X$found_dir"; then | |
8503 | haveit=yes | |
8504 | break | |
8505 | fi | |
8506 | done | |
8507 | if test -z "$haveit"; then | |
8508 | ltrpathdirs="$ltrpathdirs $found_dir" | |
8509 | fi | |
8510 | if test "$hardcode_direct" = yes; then | |
8511 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8512 | else | |
8513 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
8514 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8515 | haveit= | |
8516 | for x in $rpathdirs; do | |
8517 | if test "X$x" = "X$found_dir"; then | |
8518 | haveit=yes | |
8519 | break | |
8520 | fi | |
8521 | done | |
8522 | if test -z "$haveit"; then | |
8523 | rpathdirs="$rpathdirs $found_dir" | |
8524 | fi | |
8525 | else | |
8526 | haveit= | |
8527 | for x in $LDFLAGS $LIBINTL; do | |
8528 | ||
8529 | acl_save_prefix="$prefix" | |
8530 | prefix="$acl_final_prefix" | |
8531 | acl_save_exec_prefix="$exec_prefix" | |
8532 | exec_prefix="$acl_final_exec_prefix" | |
8533 | eval x=\"$x\" | |
8534 | exec_prefix="$acl_save_exec_prefix" | |
8535 | prefix="$acl_save_prefix" | |
8536 | ||
8537 | if test "X$x" = "X-L$found_dir"; then | |
8538 | haveit=yes | |
8539 | break | |
8540 | fi | |
8541 | done | |
8542 | if test -z "$haveit"; then | |
8543 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir" | |
8544 | fi | |
8545 | if test "$hardcode_minus_L" != no; then | |
8546 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_so" | |
8547 | else | |
8548 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8549 | fi | |
8550 | fi | |
8551 | fi | |
8552 | fi | |
8553 | else | |
8554 | if test "X$found_a" != "X"; then | |
8555 | LIBINTL="${LIBINTL}${LIBINTL:+ }$found_a" | |
8556 | else | |
8557 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$found_dir -l$name" | |
8558 | fi | |
8559 | fi | |
8560 | additional_includedir= | |
8561 | case "$found_dir" in | |
8562 | */lib | */lib/) | |
8563 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
8564 | additional_includedir="$basedir/include" | |
8565 | ;; | |
8566 | esac | |
8567 | if test "X$additional_includedir" != "X"; then | |
8568 | if test "X$additional_includedir" != "X/usr/include"; then | |
8569 | haveit= | |
8570 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
8571 | if test -n "$GCC"; then | |
8572 | case $host_os in | |
8573 | linux*) haveit=yes;; | |
8574 | esac | |
8575 | fi | |
8576 | fi | |
8577 | if test -z "$haveit"; then | |
8578 | for x in $CPPFLAGS $INCINTL; do | |
8579 | ||
8580 | acl_save_prefix="$prefix" | |
8581 | prefix="$acl_final_prefix" | |
8582 | acl_save_exec_prefix="$exec_prefix" | |
8583 | exec_prefix="$acl_final_exec_prefix" | |
8584 | eval x=\"$x\" | |
8585 | exec_prefix="$acl_save_exec_prefix" | |
8586 | prefix="$acl_save_prefix" | |
8587 | ||
8588 | if test "X$x" = "X-I$additional_includedir"; then | |
8589 | haveit=yes | |
8590 | break | |
8591 | fi | |
8592 | done | |
8593 | if test -z "$haveit"; then | |
8594 | if test -d "$additional_includedir"; then | |
8595 | INCINTL="${INCINTL}${INCINTL:+ }-I$additional_includedir" | |
8596 | fi | |
8597 | fi | |
8598 | fi | |
8599 | fi | |
8600 | fi | |
8601 | if test -n "$found_la"; then | |
8602 | save_libdir="$libdir" | |
8603 | case "$found_la" in | |
8604 | */* | *\\*) . "$found_la" ;; | |
8605 | *) . "./$found_la" ;; | |
8606 | esac | |
8607 | libdir="$save_libdir" | |
8608 | for dep in $dependency_libs; do | |
8609 | case "$dep" in | |
8610 | -L*) | |
8611 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
8612 | if test "X$additional_libdir" != "X/usr/lib"; then | |
8613 | haveit= | |
8614 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
8615 | if test -n "$GCC"; then | |
8616 | case $host_os in | |
8617 | linux*) haveit=yes;; | |
8618 | esac | |
8619 | fi | |
8620 | fi | |
8621 | if test -z "$haveit"; then | |
8622 | haveit= | |
8623 | for x in $LDFLAGS $LIBINTL; do | |
8624 | ||
8625 | acl_save_prefix="$prefix" | |
8626 | prefix="$acl_final_prefix" | |
8627 | acl_save_exec_prefix="$exec_prefix" | |
8628 | exec_prefix="$acl_final_exec_prefix" | |
8629 | eval x=\"$x\" | |
8630 | exec_prefix="$acl_save_exec_prefix" | |
8631 | prefix="$acl_save_prefix" | |
8632 | ||
8633 | if test "X$x" = "X-L$additional_libdir"; then | |
8634 | haveit=yes | |
8635 | break | |
8636 | fi | |
8637 | done | |
8638 | if test -z "$haveit"; then | |
8639 | if test -d "$additional_libdir"; then | |
8640 | LIBINTL="${LIBINTL}${LIBINTL:+ }-L$additional_libdir" | |
8641 | fi | |
8642 | fi | |
8643 | haveit= | |
8644 | for x in $LDFLAGS $LTLIBINTL; do | |
8645 | ||
8646 | acl_save_prefix="$prefix" | |
8647 | prefix="$acl_final_prefix" | |
8648 | acl_save_exec_prefix="$exec_prefix" | |
8649 | exec_prefix="$acl_final_exec_prefix" | |
8650 | eval x=\"$x\" | |
8651 | exec_prefix="$acl_save_exec_prefix" | |
8652 | prefix="$acl_save_prefix" | |
8653 | ||
8654 | if test "X$x" = "X-L$additional_libdir"; then | |
8655 | haveit=yes | |
8656 | break | |
8657 | fi | |
8658 | done | |
8659 | if test -z "$haveit"; then | |
8660 | if test -d "$additional_libdir"; then | |
8661 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-L$additional_libdir" | |
8662 | fi | |
8663 | fi | |
8664 | fi | |
8665 | fi | |
8666 | ;; | |
8667 | -R*) | |
8668 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
8669 | if test "$enable_rpath" != no; then | |
8670 | haveit= | |
8671 | for x in $rpathdirs; do | |
8672 | if test "X$x" = "X$dir"; then | |
8673 | haveit=yes | |
8674 | break | |
8675 | fi | |
8676 | done | |
8677 | if test -z "$haveit"; then | |
8678 | rpathdirs="$rpathdirs $dir" | |
8679 | fi | |
8680 | haveit= | |
8681 | for x in $ltrpathdirs; do | |
8682 | if test "X$x" = "X$dir"; then | |
8683 | haveit=yes | |
8684 | break | |
8685 | fi | |
8686 | done | |
8687 | if test -z "$haveit"; then | |
8688 | ltrpathdirs="$ltrpathdirs $dir" | |
8689 | fi | |
8690 | fi | |
8691 | ;; | |
8692 | -l*) | |
8693 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
8694 | ;; | |
7f947b68 CR |
8695 | *.la) |
8696 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
8697 | ;; | |
8698 | *) | |
8699 | LIBINTL="${LIBINTL}${LIBINTL:+ }$dep" | |
8700 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }$dep" | |
8701 | ;; | |
8702 | esac | |
8703 | done | |
8704 | fi | |
8705 | else | |
8706 | LIBINTL="${LIBINTL}${LIBINTL:+ }-l$name" | |
8707 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-l$name" | |
8708 | fi | |
8709 | fi | |
8710 | fi | |
8711 | done | |
8712 | done | |
8713 | if test "X$rpathdirs" != "X"; then | |
8714 | if test -n "$hardcode_libdir_separator"; then | |
8715 | alldirs= | |
8716 | for found_dir in $rpathdirs; do | |
8717 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
8718 | done | |
8719 | acl_save_libdir="$libdir" | |
8720 | libdir="$alldirs" | |
8721 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8722 | libdir="$acl_save_libdir" | |
8723 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8724 | else | |
8725 | for found_dir in $rpathdirs; do | |
8726 | acl_save_libdir="$libdir" | |
8727 | libdir="$found_dir" | |
8728 | eval flag=\"$hardcode_libdir_flag_spec\" | |
8729 | libdir="$acl_save_libdir" | |
8730 | LIBINTL="${LIBINTL}${LIBINTL:+ }$flag" | |
8731 | done | |
8732 | fi | |
8733 | fi | |
8734 | if test "X$ltrpathdirs" != "X"; then | |
8735 | for found_dir in $ltrpathdirs; do | |
8736 | LTLIBINTL="${LTLIBINTL}${LTLIBINTL:+ }-R$found_dir" | |
8737 | done | |
8738 | fi | |
2dead0c4 | 8739 | |
7f947b68 CR |
8740 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU gettext in libintl" >&5 |
8741 | $as_echo_n "checking for GNU gettext in libintl... " >&6; } | |
8742 | if ${gt_cv_func_gnugettext2_libintl+:} false; then : | |
2dead0c4 CR |
8743 | $as_echo_n "(cached) " >&6 |
8744 | else | |
7f947b68 CR |
8745 | gt_save_CPPFLAGS="$CPPFLAGS" |
8746 | CPPFLAGS="$CPPFLAGS $INCINTL" | |
8747 | gt_save_LIBS="$LIBS" | |
8748 | LIBS="$LIBS $LIBINTL" | |
8749 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 8750 | /* end confdefs.h. */ |
7f947b68 CR |
8751 | #include <libintl.h> |
8752 | extern int _nl_msg_cat_cntr; | |
8753 | extern | |
8754 | #ifdef __cplusplus | |
8755 | "C" | |
8756 | #endif | |
8757 | const char *_nl_expand_alias (); | |
e3db237e CR |
8758 | int |
8759 | main () | |
8760 | { | |
7f947b68 CR |
8761 | bindtextdomain ("", ""); |
8762 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
e3db237e CR |
8763 | ; |
8764 | return 0; | |
8765 | } | |
8766 | _ACEOF | |
7f947b68 CR |
8767 | if ac_fn_c_try_link "$LINENO"; then : |
8768 | gt_cv_func_gnugettext2_libintl=yes | |
8769 | else | |
8770 | gt_cv_func_gnugettext2_libintl=no | |
8771 | fi | |
8772 | rm -f core conftest.err conftest.$ac_objext \ | |
8773 | conftest$ac_exeext conftest.$ac_ext | |
8774 | if test "$gt_cv_func_gnugettext2_libintl" != yes && test -n "$LIBICONV"; then | |
8775 | LIBS="$LIBS $LIBICONV" | |
8776 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 8777 | /* end confdefs.h. */ |
7f947b68 CR |
8778 | #include <libintl.h> |
8779 | extern int _nl_msg_cat_cntr; | |
8780 | extern | |
8781 | #ifdef __cplusplus | |
8782 | "C" | |
8783 | #endif | |
8784 | const char *_nl_expand_alias (); | |
abe2eb5b CR |
8785 | int |
8786 | main () | |
8787 | { | |
7f947b68 CR |
8788 | bindtextdomain ("", ""); |
8789 | return (int) gettext ("") + (int) ngettext ("", "", 0) + _nl_msg_cat_cntr + *_nl_expand_alias (0) | |
abe2eb5b CR |
8790 | ; |
8791 | return 0; | |
8792 | } | |
e3db237e | 8793 | _ACEOF |
7f947b68 CR |
8794 | if ac_fn_c_try_link "$LINENO"; then : |
8795 | LIBINTL="$LIBINTL $LIBICONV" | |
8796 | LTLIBINTL="$LTLIBINTL $LTLIBICONV" | |
8797 | gt_cv_func_gnugettext2_libintl=yes | |
71412226 | 8798 | |
ccc6cda3 | 8799 | fi |
7f947b68 CR |
8800 | rm -f core conftest.err conftest.$ac_objext \ |
8801 | conftest$ac_exeext conftest.$ac_ext | |
8802 | fi | |
8803 | CPPFLAGS="$gt_save_CPPFLAGS" | |
8804 | LIBS="$gt_save_LIBS" | |
8805 | fi | |
8806 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_cv_func_gnugettext2_libintl" >&5 | |
8807 | $as_echo "$gt_cv_func_gnugettext2_libintl" >&6; } | |
8808 | fi | |
71412226 | 8809 | |
7f947b68 CR |
8810 | if test "$gt_cv_func_gnugettext2_libc" = "yes" \ |
8811 | || { test "$gt_cv_func_gnugettext2_libintl" = "yes" \ | |
8812 | && test "$PACKAGE" != gettext-runtime \ | |
8813 | && test "$PACKAGE" != gettext-tools; }; then | |
8814 | gt_use_preinstalled_gnugettext=yes | |
8815 | else | |
8816 | LIBINTL= | |
8817 | LTLIBINTL= | |
8818 | INCINTL= | |
8819 | fi | |
8820 | ||
8821 | ||
8822 | if test "$gt_use_preinstalled_gnugettext" != "yes"; then | |
8823 | nls_cv_use_gnu_gettext=yes | |
8824 | fi | |
8825 | fi | |
8826 | ||
8827 | if test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8828 | BUILD_INCLUDED_LIBINTL=yes | |
8829 | USE_INCLUDED_LIBINTL=yes | |
8830 | LIBINTL="lib/intl/libintl.a $LIBICONV" | |
8831 | LTLIBINTL="lib/intl/libintl.a $LTLIBICONV" | |
8832 | LIBS=`echo " $LIBS " | sed -e 's/ -lintl / /' -e 's/^ //' -e 's/ $//'` | |
8833 | fi | |
8834 | ||
8835 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ | |
8836 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8837 | CATOBJEXT=.gmo | |
8838 | fi | |
8839 | ||
8840 | ||
8841 | if test "$gt_use_preinstalled_gnugettext" = "yes" \ | |
8842 | || test "$nls_cv_use_gnu_gettext" = "yes"; then | |
8843 | ||
8844 | $as_echo "#define ENABLE_NLS 1" >>confdefs.h | |
8845 | ||
8846 | else | |
8847 | USE_NLS=no | |
8848 | fi | |
8849 | fi | |
8850 | ||
8851 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use NLS" >&5 | |
8852 | $as_echo_n "checking whether to use NLS... " >&6; } | |
8853 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $USE_NLS" >&5 | |
8854 | $as_echo "$USE_NLS" >&6; } | |
8855 | if test "$USE_NLS" = "yes"; then | |
8856 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking where the gettext function comes from" >&5 | |
8857 | $as_echo_n "checking where the gettext function comes from... " >&6; } | |
8858 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then | |
8859 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8860 | gt_source="external libintl" | |
8861 | else | |
8862 | gt_source="libc" | |
8863 | fi | |
8864 | else | |
8865 | gt_source="included intl directory" | |
8866 | fi | |
8867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gt_source" >&5 | |
8868 | $as_echo "$gt_source" >&6; } | |
8869 | fi | |
8870 | ||
8871 | if test "$USE_NLS" = "yes"; then | |
8872 | ||
8873 | if test "$gt_use_preinstalled_gnugettext" = "yes"; then | |
8874 | if test "$gt_cv_func_gnugettext2_libintl" = "yes"; then | |
8875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libintl" >&5 | |
8876 | $as_echo_n "checking how to link with libintl... " >&6; } | |
8877 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBINTL" >&5 | |
8878 | $as_echo "$LIBINTL" >&6; } | |
8879 | ||
8880 | for element in $INCINTL; do | |
8881 | haveit= | |
8882 | for x in $CPPFLAGS; do | |
8883 | ||
8884 | acl_save_prefix="$prefix" | |
8885 | prefix="$acl_final_prefix" | |
8886 | acl_save_exec_prefix="$exec_prefix" | |
8887 | exec_prefix="$acl_final_exec_prefix" | |
8888 | eval x=\"$x\" | |
8889 | exec_prefix="$acl_save_exec_prefix" | |
8890 | prefix="$acl_save_prefix" | |
8891 | ||
8892 | if test "X$x" = "X$element"; then | |
8893 | haveit=yes | |
8894 | break | |
8895 | fi | |
8896 | done | |
8897 | if test -z "$haveit"; then | |
8898 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
8899 | fi | |
abe2eb5b | 8900 | done |
2dead0c4 | 8901 | |
7f947b68 | 8902 | fi |
abe2eb5b | 8903 | |
abe2eb5b | 8904 | |
7f947b68 CR |
8905 | $as_echo "#define HAVE_GETTEXT 1" >>confdefs.h |
8906 | ||
8907 | ||
8908 | $as_echo "#define HAVE_DCGETTEXT 1" >>confdefs.h | |
8909 | ||
8910 | fi | |
8911 | ||
8912 | POSUB=po | |
8913 | fi | |
8914 | ||
8915 | ||
8916 | if test "$PACKAGE" = gettext-runtime || test "$PACKAGE" = gettext-tools; then | |
8917 | BUILD_INCLUDED_LIBINTL=yes | |
8918 | fi | |
8919 | ||
8920 | ||
8921 | ||
8922 | ||
8923 | ||
8924 | nls_cv_header_intl= | |
8925 | nls_cv_header_libgt= | |
8926 | ||
8927 | DATADIRNAME=share | |
8928 | ||
abe2eb5b | 8929 | |
7f947b68 | 8930 | INSTOBJEXT=.mo |
ccc6cda3 | 8931 | |
ccc6cda3 | 8932 | |
7f947b68 | 8933 | GENCAT=gencat |
c920c360 | 8934 | |
2dead0c4 | 8935 | |
7f947b68 CR |
8936 | if test "$USE_INCLUDED_LIBINTL" = yes; then |
8937 | INTLOBJS="\$(GETTOBJS)" | |
8938 | fi | |
8939 | ||
8940 | ||
8941 | INTL_LIBTOOL_SUFFIX_PREFIX= | |
8942 | ||
8943 | ||
8944 | ||
8945 | INTLLIBS="$LIBINTL" | |
8946 | ||
8947 | ||
8948 | ||
8949 | ||
8950 | ||
8951 | ||
8952 | ||
8953 | ac_header_dirent=no | |
8954 | for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do | |
8955 | as_ac_Header=`$as_echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh` | |
8956 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_hdr that defines DIR" >&5 | |
8957 | $as_echo_n "checking for $ac_hdr that defines DIR... " >&6; } | |
8958 | if eval \${$as_ac_Header+:} false; then : | |
8959 | $as_echo_n "(cached) " >&6 | |
8960 | else | |
8961 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7610e0c5 | 8962 | /* end confdefs.h. */ |
7f947b68 CR |
8963 | #include <sys/types.h> |
8964 | #include <$ac_hdr> | |
8965 | ||
abe2eb5b CR |
8966 | int |
8967 | main () | |
2dead0c4 | 8968 | { |
7f947b68 CR |
8969 | if ((DIR *) 0) |
8970 | return 0; | |
abe2eb5b CR |
8971 | ; |
8972 | return 0; | |
2dead0c4 | 8973 | } |
abe2eb5b | 8974 | _ACEOF |
7f947b68 CR |
8975 | if ac_fn_c_try_compile "$LINENO"; then : |
8976 | eval "$as_ac_Header=yes" | |
abe2eb5b | 8977 | else |
7f947b68 CR |
8978 | eval "$as_ac_Header=no" |
8979 | fi | |
8980 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8981 | fi | |
8982 | eval ac_res=\$$as_ac_Header | |
8983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
8984 | $as_echo "$ac_res" >&6; } | |
8985 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
8986 | cat >>confdefs.h <<_ACEOF | |
8987 | #define `$as_echo "HAVE_$ac_hdr" | $as_tr_cpp` 1 | |
8988 | _ACEOF | |
abe2eb5b | 8989 | |
7f947b68 | 8990 | ac_header_dirent=$ac_hdr; break |
abe2eb5b | 8991 | fi |
2dead0c4 | 8992 | |
abe2eb5b | 8993 | done |
7f947b68 CR |
8994 | # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix. |
8995 | if test $ac_header_dirent = dirent.h; then | |
8996 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
8997 | $as_echo_n "checking for library containing opendir... " >&6; } | |
8998 | if ${ac_cv_search_opendir+:} false; then : | |
8999 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 9000 | else |
7f947b68 CR |
9001 | ac_func_search_save_LIBS=$LIBS |
9002 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 9003 | /* end confdefs.h. */ |
7f947b68 CR |
9004 | |
9005 | /* Override any GCC internal prototype to avoid an error. | |
9006 | Use char because int might match the return type of a GCC | |
9007 | builtin and then its argument prototype would still apply. */ | |
9008 | #ifdef __cplusplus | |
9009 | extern "C" | |
9010 | #endif | |
9011 | char opendir (); | |
e3db237e CR |
9012 | int |
9013 | main () | |
9014 | { | |
7f947b68 | 9015 | return opendir (); |
abe2eb5b CR |
9016 | ; |
9017 | return 0; | |
e3db237e | 9018 | } |
71412226 | 9019 | _ACEOF |
7f947b68 CR |
9020 | for ac_lib in '' dir; do |
9021 | if test -z "$ac_lib"; then | |
9022 | ac_res="none required" | |
9023 | else | |
9024 | ac_res=-l$ac_lib | |
9025 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9026 | fi | |
9027 | if ac_fn_c_try_link "$LINENO"; then : | |
9028 | ac_cv_search_opendir=$ac_res | |
ccc6cda3 | 9029 | fi |
7f947b68 CR |
9030 | rm -f core conftest.err conftest.$ac_objext \ |
9031 | conftest$ac_exeext | |
9032 | if ${ac_cv_search_opendir+:} false; then : | |
9033 | break | |
e3db237e | 9034 | fi |
7f947b68 CR |
9035 | done |
9036 | if ${ac_cv_search_opendir+:} false; then : | |
2dead0c4 | 9037 | |
7f947b68 CR |
9038 | else |
9039 | ac_cv_search_opendir=no | |
9040 | fi | |
9041 | rm conftest.$ac_ext | |
9042 | LIBS=$ac_func_search_save_LIBS | |
9043 | fi | |
9044 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 | |
9045 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9046 | ac_res=$ac_cv_search_opendir | |
9047 | if test "$ac_res" != no; then : | |
9048 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
f73dda09 | 9049 | |
7f947b68 | 9050 | fi |
c920c360 | 9051 | |
7f947b68 CR |
9052 | else |
9053 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing opendir" >&5 | |
9054 | $as_echo_n "checking for library containing opendir... " >&6; } | |
9055 | if ${ac_cv_search_opendir+:} false; then : | |
7610e0c5 CR |
9056 | $as_echo_n "(cached) " >&6 |
9057 | else | |
7f947b68 CR |
9058 | ac_func_search_save_LIBS=$LIBS |
9059 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 9060 | /* end confdefs.h. */ |
2dead0c4 | 9061 | |
7f947b68 CR |
9062 | /* Override any GCC internal prototype to avoid an error. |
9063 | Use char because int might match the return type of a GCC | |
9064 | builtin and then its argument prototype would still apply. */ | |
9065 | #ifdef __cplusplus | |
9066 | extern "C" | |
9067 | #endif | |
9068 | char opendir (); | |
abe2eb5b CR |
9069 | int |
9070 | main () | |
9071 | { | |
7f947b68 | 9072 | return opendir (); |
abe2eb5b | 9073 | ; |
e3db237e CR |
9074 | return 0; |
9075 | } | |
9076 | _ACEOF | |
7f947b68 CR |
9077 | for ac_lib in '' x; do |
9078 | if test -z "$ac_lib"; then | |
9079 | ac_res="none required" | |
9080 | else | |
9081 | ac_res=-l$ac_lib | |
9082 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
9083 | fi | |
9084 | if ac_fn_c_try_link "$LINENO"; then : | |
9085 | ac_cv_search_opendir=$ac_res | |
9086 | fi | |
9087 | rm -f core conftest.err conftest.$ac_objext \ | |
9088 | conftest$ac_exeext | |
9089 | if ${ac_cv_search_opendir+:} false; then : | |
9090 | break | |
71412226 | 9091 | fi |
7f947b68 CR |
9092 | done |
9093 | if ${ac_cv_search_opendir+:} false; then : | |
5e4a95c7 | 9094 | |
abe2eb5b | 9095 | else |
7f947b68 CR |
9096 | ac_cv_search_opendir=no |
9097 | fi | |
9098 | rm conftest.$ac_ext | |
9099 | LIBS=$ac_func_search_save_LIBS | |
9100 | fi | |
9101 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_opendir" >&5 | |
9102 | $as_echo "$ac_cv_search_opendir" >&6; } | |
9103 | ac_res=$ac_cv_search_opendir | |
9104 | if test "$ac_res" != no; then : | |
9105 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
9106 | ||
9107 | fi | |
b709b946 | 9108 | |
7f947b68 | 9109 | fi |
f73dda09 | 9110 | |
7f947b68 CR |
9111 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
9112 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
9113 | if ${ac_cv_header_time+:} false; then : | |
9114 | $as_echo_n "(cached) " >&6 | |
9115 | else | |
9116 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 9117 | /* end confdefs.h. */ |
7f947b68 CR |
9118 | #include <sys/types.h> |
9119 | #include <sys/time.h> | |
9120 | #include <time.h> | |
9121 | ||
abe2eb5b CR |
9122 | int |
9123 | main () | |
9124 | { | |
7f947b68 CR |
9125 | if ((struct tm *) 0) |
9126 | return 0; | |
abe2eb5b CR |
9127 | ; |
9128 | return 0; | |
9129 | } | |
9130 | _ACEOF | |
7f947b68 CR |
9131 | if ac_fn_c_try_compile "$LINENO"; then : |
9132 | ac_cv_header_time=yes | |
abe2eb5b | 9133 | else |
7f947b68 CR |
9134 | ac_cv_header_time=no |
9135 | fi | |
9136 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9137 | fi | |
9138 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 | |
9139 | $as_echo "$ac_cv_header_time" >&6; } | |
9140 | if test $ac_cv_header_time = yes; then | |
9141 | ||
9142 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h | |
2dead0c4 | 9143 | |
e3db237e | 9144 | fi |
b709b946 | 9145 | |
2dead0c4 | 9146 | |
7f947b68 CR |
9147 | |
9148 | for ac_header in inttypes.h | |
9149 | do : | |
9150 | ac_fn_c_check_header_mongrel "$LINENO" "inttypes.h" "ac_cv_header_inttypes_h" "$ac_includes_default" | |
9151 | if test "x$ac_cv_header_inttypes_h" = xyes; then : | |
9152 | cat >>confdefs.h <<_ACEOF | |
9153 | #define HAVE_INTTYPES_H 1 | |
9154 | _ACEOF | |
9155 | ||
abe2eb5b | 9156 | fi |
2dead0c4 | 9157 | |
7f947b68 CR |
9158 | done |
9159 | ||
9160 | ||
9161 | ||
9162 | for ac_header in unistd.h stdlib.h stdarg.h varargs.h limits.h string.h \ | |
9163 | memory.h locale.h termcap.h termio.h termios.h dlfcn.h \ | |
9164 | stdbool.h stddef.h stdint.h netdb.h pwd.h grp.h strings.h \ | |
9165 | regex.h syslog.h ulimit.h | |
9166 | do : | |
9167 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9168 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9169 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9170 | cat >>confdefs.h <<_ACEOF | |
9171 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
9172 | _ACEOF | |
9173 | ||
abe2eb5b | 9174 | fi |
2dead0c4 | 9175 | |
7f947b68 CR |
9176 | done |
9177 | ||
5e4c7191 | 9178 | for ac_header in sys/pte.h sys/stream.h sys/select.h sys/file.h \ |
7f947b68 CR |
9179 | sys/resource.h sys/param.h sys/socket.h sys/stat.h \ |
9180 | sys/time.h sys/times.h sys/types.h sys/wait.h | |
9181 | do : | |
9182 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9183 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9184 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9185 | cat >>confdefs.h <<_ACEOF | |
9186 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
9187 | _ACEOF | |
9188 | ||
9189 | fi | |
9190 | ||
9191 | done | |
9192 | ||
9193 | for ac_header in netinet/in.h arpa/inet.h | |
9194 | do : | |
9195 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
9196 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
9197 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
9198 | cat >>confdefs.h <<_ACEOF | |
9199 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
abe2eb5b | 9200 | _ACEOF |
7f947b68 CR |
9201 | |
9202 | fi | |
9203 | ||
9204 | done | |
9205 | ||
9206 | ||
9207 | ac_fn_c_check_header_compile "$LINENO" "sys/ptem.h" "ac_cv_header_sys_ptem_h" " | |
9208 | #if HAVE_SYS_STREAM_H | |
9209 | # include <sys/stream.h> | |
9210 | #endif | |
9211 | ||
9212 | " | |
9213 | if test "x$ac_cv_header_sys_ptem_h" = xyes; then : | |
9214 | ||
9215 | fi | |
9216 | ||
9217 | ||
9218 | ||
9219 | # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works | |
9220 | # for constant arguments. Useless! | |
9221 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working alloca.h" >&5 | |
9222 | $as_echo_n "checking for working alloca.h... " >&6; } | |
9223 | if ${ac_cv_working_alloca_h+:} false; then : | |
9224 | $as_echo_n "(cached) " >&6 | |
9225 | else | |
9226 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 9227 | /* end confdefs.h. */ |
7f947b68 | 9228 | #include <alloca.h> |
abe2eb5b CR |
9229 | int |
9230 | main () | |
9231 | { | |
7f947b68 CR |
9232 | char *p = (char *) alloca (2 * sizeof (int)); |
9233 | if (p) return 0; | |
abe2eb5b CR |
9234 | ; |
9235 | return 0; | |
9236 | } | |
71412226 | 9237 | _ACEOF |
7f947b68 CR |
9238 | if ac_fn_c_try_link "$LINENO"; then : |
9239 | ac_cv_working_alloca_h=yes | |
abe2eb5b | 9240 | else |
7f947b68 CR |
9241 | ac_cv_working_alloca_h=no |
9242 | fi | |
9243 | rm -f core conftest.err conftest.$ac_objext \ | |
9244 | conftest$ac_exeext conftest.$ac_ext | |
9245 | fi | |
9246 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_working_alloca_h" >&5 | |
9247 | $as_echo "$ac_cv_working_alloca_h" >&6; } | |
9248 | if test $ac_cv_working_alloca_h = yes; then | |
9249 | ||
9250 | $as_echo "#define HAVE_ALLOCA_H 1" >>confdefs.h | |
d166f048 JA |
9251 | |
9252 | fi | |
b709b946 | 9253 | |
7f947b68 CR |
9254 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for alloca" >&5 |
9255 | $as_echo_n "checking for alloca... " >&6; } | |
9256 | if ${ac_cv_func_alloca_works+:} false; then : | |
9257 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 9258 | else |
7f947b68 | 9259 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 9260 | /* end confdefs.h. */ |
7f947b68 CR |
9261 | #ifdef __GNUC__ |
9262 | # define alloca __builtin_alloca | |
9263 | #else | |
9264 | # ifdef _MSC_VER | |
9265 | # include <malloc.h> | |
9266 | # define alloca _alloca | |
9267 | # else | |
9268 | # ifdef HAVE_ALLOCA_H | |
9269 | # include <alloca.h> | |
9270 | # else | |
9271 | # ifdef _AIX | |
9272 | #pragma alloca | |
9273 | # else | |
9274 | # ifndef alloca /* predefined by HP cc +Olibcalls */ | |
9275 | void *alloca (size_t); | |
9276 | # endif | |
9277 | # endif | |
9278 | # endif | |
9279 | # endif | |
9280 | #endif | |
9281 | ||
abe2eb5b CR |
9282 | int |
9283 | main () | |
9284 | { | |
7f947b68 CR |
9285 | char *p = (char *) alloca (1); |
9286 | if (p) return 0; | |
abe2eb5b CR |
9287 | ; |
9288 | return 0; | |
9289 | } | |
2dead0c4 | 9290 | _ACEOF |
7f947b68 CR |
9291 | if ac_fn_c_try_link "$LINENO"; then : |
9292 | ac_cv_func_alloca_works=yes | |
abe2eb5b | 9293 | else |
7f947b68 | 9294 | ac_cv_func_alloca_works=no |
abe2eb5b | 9295 | fi |
7f947b68 CR |
9296 | rm -f core conftest.err conftest.$ac_objext \ |
9297 | conftest$ac_exeext conftest.$ac_ext | |
e3db237e | 9298 | fi |
7f947b68 CR |
9299 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_alloca_works" >&5 |
9300 | $as_echo "$ac_cv_func_alloca_works" >&6; } | |
9301 | ||
9302 | if test $ac_cv_func_alloca_works = yes; then | |
9303 | ||
9304 | $as_echo "#define HAVE_ALLOCA 1" >>confdefs.h | |
9305 | ||
9306 | else | |
9307 | # The SVR3 libPW and SVR4 libucb both contain incompatible functions | |
9308 | # that cause trouble. Some versions do not even contain alloca or | |
9309 | # contain a buggy version. If you still want to use their alloca, | |
9310 | # use ar to extract alloca.o from them instead of compiling alloca.c. | |
9311 | ||
9312 | ALLOCA=\${LIBOBJDIR}alloca.$ac_objext | |
9313 | ||
9314 | $as_echo "#define C_ALLOCA 1" >>confdefs.h | |
9315 | ||
9316 | ||
9317 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether \`alloca.c' needs Cray hooks" >&5 | |
9318 | $as_echo_n "checking whether \`alloca.c' needs Cray hooks... " >&6; } | |
9319 | if ${ac_cv_os_cray+:} false; then : | |
9320 | $as_echo_n "(cached) " >&6 | |
9321 | else | |
9322 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9323 | /* end confdefs.h. */ | |
9324 | #if defined CRAY && ! defined CRAY2 | |
9325 | webecray | |
9326 | #else | |
9327 | wenotbecray | |
9328 | #endif | |
e3db237e | 9329 | |
7f947b68 CR |
9330 | _ACEOF |
9331 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
9332 | $EGREP "webecray" >/dev/null 2>&1; then : | |
9333 | ac_cv_os_cray=yes | |
9334 | else | |
9335 | ac_cv_os_cray=no | |
9336 | fi | |
9337 | rm -f conftest* | |
c920c360 | 9338 | |
7f947b68 CR |
9339 | fi |
9340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 | |
9341 | $as_echo "$ac_cv_os_cray" >&6; } | |
9342 | if test $ac_cv_os_cray = yes; then | |
9343 | for ac_func in _getb67 GETB67 getb67; do | |
9344 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9345 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9346 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
abe2eb5b CR |
9347 | |
9348 | cat >>confdefs.h <<_ACEOF | |
7f947b68 | 9349 | #define CRAY_STACKSEG_END $ac_func |
2dead0c4 | 9350 | _ACEOF |
c920c360 | 9351 | |
7f947b68 CR |
9352 | break |
9353 | fi | |
9354 | ||
9355 | done | |
9356 | fi | |
d166f048 | 9357 | |
7f947b68 CR |
9358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 |
9359 | $as_echo_n "checking stack direction for C alloca... " >&6; } | |
9360 | if ${ac_cv_c_stack_direction+:} false; then : | |
abe2eb5b CR |
9361 | $as_echo_n "(cached) " >&6 |
9362 | else | |
7f947b68 CR |
9363 | if test "$cross_compiling" = yes; then : |
9364 | ac_cv_c_stack_direction=0 | |
9365 | else | |
9366 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b CR |
9367 | /* end confdefs.h. */ |
9368 | $ac_includes_default | |
9369 | int | |
7f947b68 | 9370 | find_stack_direction () |
abe2eb5b | 9371 | { |
7f947b68 CR |
9372 | static char *addr = 0; |
9373 | auto char dummy; | |
9374 | if (addr == 0) | |
9375 | { | |
9376 | addr = &dummy; | |
9377 | return find_stack_direction (); | |
9378 | } | |
9379 | else | |
9380 | return (&dummy > addr) ? 1 : -1; | |
abe2eb5b | 9381 | } |
7f947b68 | 9382 | |
abe2eb5b CR |
9383 | int |
9384 | main () | |
9385 | { | |
7f947b68 | 9386 | return find_stack_direction () < 0; |
abe2eb5b CR |
9387 | } |
9388 | _ACEOF | |
7f947b68 CR |
9389 | if ac_fn_c_try_run "$LINENO"; then : |
9390 | ac_cv_c_stack_direction=1 | |
abe2eb5b | 9391 | else |
7f947b68 CR |
9392 | ac_cv_c_stack_direction=-1 |
9393 | fi | |
9394 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9395 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9396 | fi | |
d166f048 JA |
9397 | |
9398 | fi | |
7f947b68 CR |
9399 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 |
9400 | $as_echo "$ac_cv_c_stack_direction" >&6; } | |
9401 | cat >>confdefs.h <<_ACEOF | |
9402 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
9403 | _ACEOF | |
d166f048 | 9404 | |
2dead0c4 | 9405 | |
7f947b68 CR |
9406 | fi |
9407 | ||
9408 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5 | |
9409 | $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; } | |
9410 | if ${ac_cv_func_getpgrp_void+:} false; then : | |
9411 | $as_echo_n "(cached) " >&6 | |
9412 | else | |
9413 | # Use it with a single arg. | |
9414 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b CR |
9415 | /* end confdefs.h. */ |
9416 | $ac_includes_default | |
9417 | int | |
9418 | main () | |
9419 | { | |
7f947b68 | 9420 | getpgrp (0); |
abe2eb5b CR |
9421 | ; |
9422 | return 0; | |
9423 | } | |
9424 | _ACEOF | |
7f947b68 CR |
9425 | if ac_fn_c_try_compile "$LINENO"; then : |
9426 | ac_cv_func_getpgrp_void=no | |
9427 | else | |
9428 | ac_cv_func_getpgrp_void=yes | |
9429 | fi | |
9430 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
9431 | ||
9432 | fi | |
9433 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5 | |
9434 | $as_echo "$ac_cv_func_getpgrp_void" >&6; } | |
9435 | if test $ac_cv_func_getpgrp_void = yes; then | |
9436 | ||
9437 | $as_echo "#define GETPGRP_VOID 1" >>confdefs.h | |
9438 | ||
9439 | fi | |
9440 | ||
9441 | if ${ac_cv_func_setvbuf_reversed+:} false; then : | |
9442 | $as_echo_n "(cached) " >&6 | |
9443 | else | |
9444 | ac_cv_func_setvbuf_reversed=no | |
9445 | fi | |
9446 | ||
9447 | ||
9448 | for ac_func in vprintf | |
9449 | do : | |
9450 | ac_fn_c_check_func "$LINENO" "vprintf" "ac_cv_func_vprintf" | |
9451 | if test "x$ac_cv_func_vprintf" = xyes; then : | |
9452 | cat >>confdefs.h <<_ACEOF | |
9453 | #define HAVE_VPRINTF 1 | |
abe2eb5b | 9454 | _ACEOF |
7f947b68 CR |
9455 | |
9456 | ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" | |
9457 | if test "x$ac_cv_func__doprnt" = xyes; then : | |
9458 | ||
9459 | $as_echo "#define HAVE_DOPRNT 1" >>confdefs.h | |
9460 | ||
9461 | fi | |
9462 | ||
9463 | fi | |
9464 | done | |
9465 | ||
9466 | ||
9467 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strcoll" >&5 | |
9468 | $as_echo_n "checking for working strcoll... " >&6; } | |
9469 | if ${ac_cv_func_strcoll_works+:} false; then : | |
9470 | $as_echo_n "(cached) " >&6 | |
9471 | else | |
9472 | if test "$cross_compiling" = yes; then : | |
9473 | ac_cv_func_strcoll_works=no | |
9474 | else | |
9475 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b CR |
9476 | /* end confdefs.h. */ |
9477 | $ac_includes_default | |
9478 | int | |
9479 | main () | |
9480 | { | |
7f947b68 CR |
9481 | return (strcoll ("abc", "def") >= 0 || |
9482 | strcoll ("ABC", "DEF") >= 0 || | |
9483 | strcoll ("123", "456") >= 0) | |
abe2eb5b CR |
9484 | ; |
9485 | return 0; | |
9486 | } | |
9487 | _ACEOF | |
7f947b68 CR |
9488 | if ac_fn_c_try_run "$LINENO"; then : |
9489 | ac_cv_func_strcoll_works=yes | |
abe2eb5b | 9490 | else |
7f947b68 CR |
9491 | ac_cv_func_strcoll_works=no |
9492 | fi | |
9493 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
9494 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
9495 | fi | |
5e4a95c7 | 9496 | |
d166f048 | 9497 | fi |
7f947b68 CR |
9498 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strcoll_works" >&5 |
9499 | $as_echo "$ac_cv_func_strcoll_works" >&6; } | |
9500 | if test $ac_cv_func_strcoll_works = yes; then | |
b709b946 | 9501 | |
7f947b68 | 9502 | $as_echo "#define HAVE_STRCOLL 1" >>confdefs.h |
2dead0c4 CR |
9503 | |
9504 | fi | |
9505 | ||
7f947b68 CR |
9506 | |
9507 | ||
9508 | if test "$ac_cv_func_alloca_works" = "no" && test "$opt_bash_malloc" = "no"; then | |
9509 | MALLOC_TARGET=alloca | |
9510 | MALLOC_SRC=alloca.c | |
9511 | ||
9512 | MALLOC_LIB='-lmalloc' | |
9513 | MALLOC_LIBRARY='$(ALLOC_LIBDIR)/libmalloc.a' | |
9514 | MALLOC_LDFLAGS='-L$(ALLOC_LIBDIR)' | |
9515 | MALLOC_DEP='$(MALLOC_LIBRARY)' | |
2dead0c4 CR |
9516 | fi |
9517 | ||
7f947b68 CR |
9518 | if test "$ac_cv_func_vprintf" = no; then |
9519 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of vprintf in stdio.h" >&5 | |
9520 | $as_echo_n "checking for declaration of vprintf in stdio.h... " >&6; } | |
9521 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 9522 | /* end confdefs.h. */ |
7f947b68 | 9523 | #include <stdio.h> |
2dead0c4 | 9524 | |
abe2eb5b | 9525 | _ACEOF |
7f947b68 CR |
9526 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
9527 | $EGREP "[int[ ]*vprintf[^a-zA-Z0-9]]" >/dev/null 2>&1; then : | |
9528 | ac_cv_func_vprintf=yes | |
9529 | fi | |
9530 | rm -f conftest* | |
9531 | ||
9532 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vprintf" >&5 | |
9533 | $as_echo "$ac_cv_func_vprintf" >&6; } | |
9534 | if test $ac_cv_func_vprintf = yes; then | |
9535 | $as_echo "#define HAVE_VPRINTF 1" >>confdefs.h | |
e3db237e | 9536 | |
7f947b68 | 9537 | fi |
d166f048 | 9538 | fi |
e3db237e | 9539 | |
7f947b68 CR |
9540 | if test "$ac_cv_func_vprintf" = no && test "$ac_cv_func__doprnt" = "yes"; then |
9541 | case " $LIBOBJS " in | |
9542 | *" vprint.$ac_objext "* ) ;; | |
9543 | *) LIBOBJS="$LIBOBJS vprint.$ac_objext" | |
9544 | ;; | |
abe2eb5b | 9545 | esac |
7f947b68 CR |
9546 | |
9547 | fi | |
9548 | ||
9549 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 | |
9550 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
9551 | if ${ac_cv_type_signal+:} false; then : | |
9552 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 9553 | else |
7f947b68 | 9554 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 9555 | /* end confdefs.h. */ |
7f947b68 CR |
9556 | #include <sys/types.h> |
9557 | #include <signal.h> | |
9558 | ||
abe2eb5b CR |
9559 | int |
9560 | main () | |
9561 | { | |
7f947b68 | 9562 | return *(signal (0, 0)) (0) == 1; |
abe2eb5b CR |
9563 | ; |
9564 | return 0; | |
9565 | } | |
9566 | _ACEOF | |
7f947b68 CR |
9567 | if ac_fn_c_try_compile "$LINENO"; then : |
9568 | ac_cv_type_signal=int | |
abe2eb5b | 9569 | else |
7f947b68 | 9570 | ac_cv_type_signal=void |
7610e0c5 | 9571 | fi |
7f947b68 | 9572 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7610e0c5 | 9573 | fi |
7f947b68 CR |
9574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 |
9575 | $as_echo "$ac_cv_type_signal" >&6; } | |
9576 | ||
9577 | cat >>confdefs.h <<_ACEOF | |
9578 | #define RETSIGTYPE $ac_cv_type_signal | |
9579 | _ACEOF | |
9580 | ||
9581 | ||
9582 | ||
9583 | ac_fn_c_check_func "$LINENO" "__setostype" "ac_cv_func___setostype" | |
9584 | if test "x$ac_cv_func___setostype" = xyes; then : | |
9585 | $as_echo "#define HAVE_SETOSTYPE 1" >>confdefs.h | |
9586 | ||
2dead0c4 CR |
9587 | fi |
9588 | ||
7f947b68 CR |
9589 | ac_fn_c_check_func "$LINENO" "wait3" "ac_cv_func_wait3" |
9590 | if test "x$ac_cv_func_wait3" = xyes; then : | |
9591 | $as_echo "#define HAVE_WAIT3 1" >>confdefs.h | |
2dead0c4 | 9592 | |
7f947b68 | 9593 | fi |
2dead0c4 | 9594 | |
7f947b68 CR |
9595 | |
9596 | ac_fn_c_check_func "$LINENO" "mkfifo" "ac_cv_func_mkfifo" | |
9597 | if test "x$ac_cv_func_mkfifo" = xyes; then : | |
9598 | $as_echo "#define HAVE_MKFIFO 1" >>confdefs.h | |
9599 | ||
9600 | else | |
9601 | $as_echo "#define MKFIFO_MISSING 1" >>confdefs.h | |
9602 | ||
9603 | fi | |
9604 | ||
9605 | ||
9606 | for ac_func in dup2 eaccess fcntl getdtablesize getgroups gethostname \ | |
9607 | getpagesize getpeername getrlimit getrusage gettimeofday \ | |
9608 | kill killpg lstat readlink sbrk select setdtablesize \ | |
9609 | setitimer tcgetpgrp uname ulimit waitpid | |
9610 | do : | |
9611 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9612 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9613 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9614 | cat >>confdefs.h <<_ACEOF | |
9615 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
abe2eb5b | 9616 | _ACEOF |
d166f048 | 9617 | |
7f947b68 CR |
9618 | fi |
9619 | done | |
9620 | ||
9621 | ac_fn_c_check_func "$LINENO" "rename" "ac_cv_func_rename" | |
9622 | if test "x$ac_cv_func_rename" = xyes; then : | |
9623 | $as_echo "#define HAVE_RENAME 1" >>confdefs.h | |
d166f048 | 9624 | |
abe2eb5b | 9625 | else |
7f947b68 CR |
9626 | case " $LIBOBJS " in |
9627 | *" rename.$ac_objext "* ) ;; | |
9628 | *) LIBOBJS="$LIBOBJS rename.$ac_objext" | |
9629 | ;; | |
9630 | esac | |
9631 | ||
9632 | fi | |
9633 | ||
9634 | ||
9635 | ||
9636 | for ac_func in bcopy bzero confstr faccessat fnmatch \ | |
9637 | getaddrinfo gethostbyname getservbyname getservent inet_aton \ | |
9638 | imaxdiv memmove pathconf putenv raise regcomp regexec \ | |
9639 | setenv setlinebuf setlocale setvbuf siginterrupt strchr \ | |
9640 | sysconf syslog tcgetattr times ttyname tzset unsetenv | |
9641 | do : | |
9642 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9643 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9644 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9645 | cat >>confdefs.h <<_ACEOF | |
9646 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
abe2eb5b | 9647 | _ACEOF |
2dead0c4 | 9648 | |
7f947b68 CR |
9649 | fi |
9650 | done | |
9651 | ||
9652 | ||
9653 | for ac_func in vasprintf asprintf | |
9654 | do : | |
9655 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9656 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9657 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9658 | cat >>confdefs.h <<_ACEOF | |
9659 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
abe2eb5b | 9660 | _ACEOF |
7f947b68 CR |
9661 | |
9662 | fi | |
9663 | done | |
9664 | ||
9665 | for ac_func in isascii isblank isgraph isprint isspace isxdigit | |
9666 | do : | |
9667 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9668 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9669 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9670 | cat >>confdefs.h <<_ACEOF | |
9671 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
abe2eb5b | 9672 | _ACEOF |
2dead0c4 | 9673 | |
7f947b68 CR |
9674 | fi |
9675 | done | |
9676 | ||
9677 | for ac_func in getpwent getpwnam getpwuid | |
9678 | do : | |
9679 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
9680 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
9681 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
9682 | cat >>confdefs.h <<_ACEOF | |
9683 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
abe2eb5b | 9684 | _ACEOF |
7f947b68 CR |
9685 | |
9686 | fi | |
9687 | done | |
9688 | ||
9689 | ac_fn_c_check_func "$LINENO" "getcwd" "ac_cv_func_getcwd" | |
9690 | if test "x$ac_cv_func_getcwd" = xyes; then : | |
9691 | $as_echo "#define HAVE_GETCWD 1" >>confdefs.h | |
9692 | ||
9693 | else | |
9694 | case " $LIBOBJS " in | |
9695 | *" getcwd.$ac_objext "* ) ;; | |
9696 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" | |
9697 | ;; | |
2dead0c4 | 9698 | esac |
7f947b68 CR |
9699 | |
9700 | fi | |
9701 | ||
9702 | ac_fn_c_check_func "$LINENO" "memset" "ac_cv_func_memset" | |
9703 | if test "x$ac_cv_func_memset" = xyes; then : | |
9704 | $as_echo "#define HAVE_MEMSET 1" >>confdefs.h | |
9705 | ||
abe2eb5b | 9706 | else |
7f947b68 CR |
9707 | case " $LIBOBJS " in |
9708 | *" memset.$ac_objext "* ) ;; | |
9709 | *) LIBOBJS="$LIBOBJS memset.$ac_objext" | |
9710 | ;; | |
9711 | esac | |
2dead0c4 CR |
9712 | |
9713 | fi | |
9714 | ||
7f947b68 CR |
9715 | |
9716 | ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp" | |
9717 | if test "x$ac_cv_func_strcasecmp" = xyes; then : | |
9718 | $as_echo "#define HAVE_STRCASECMP 1" >>confdefs.h | |
9719 | ||
abe2eb5b | 9720 | else |
7f947b68 CR |
9721 | case " $LIBOBJS " in |
9722 | *" strcasecmp.$ac_objext "* ) ;; | |
9723 | *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext" | |
9724 | ;; | |
9725 | esac | |
2dead0c4 | 9726 | |
7f947b68 | 9727 | fi |
2dead0c4 | 9728 | |
7f947b68 CR |
9729 | ac_fn_c_check_func "$LINENO" "strcasestr" "ac_cv_func_strcasestr" |
9730 | if test "x$ac_cv_func_strcasestr" = xyes; then : | |
9731 | $as_echo "#define HAVE_STRCASESTR 1" >>confdefs.h | |
9732 | ||
9733 | else | |
9734 | case " $LIBOBJS " in | |
9735 | *" strcasestr.$ac_objext "* ) ;; | |
9736 | *) LIBOBJS="$LIBOBJS strcasestr.$ac_objext" | |
9737 | ;; | |
abe2eb5b | 9738 | esac |
abe2eb5b | 9739 | |
7f947b68 CR |
9740 | fi |
9741 | ||
9742 | ac_fn_c_check_func "$LINENO" "strerror" "ac_cv_func_strerror" | |
9743 | if test "x$ac_cv_func_strerror" = xyes; then : | |
9744 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
9745 | ||
9746 | else | |
9747 | case " $LIBOBJS " in | |
9748 | *" strerror.$ac_objext "* ) ;; | |
9749 | *) LIBOBJS="$LIBOBJS strerror.$ac_objext" | |
9750 | ;; | |
abe2eb5b | 9751 | esac |
7f947b68 CR |
9752 | |
9753 | fi | |
9754 | ||
9755 | ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime" | |
9756 | if test "x$ac_cv_func_strftime" = xyes; then : | |
9757 | $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h | |
9758 | ||
71412226 | 9759 | else |
7f947b68 CR |
9760 | case " $LIBOBJS " in |
9761 | *" strftime.$ac_objext "* ) ;; | |
9762 | *) LIBOBJS="$LIBOBJS strftime.$ac_objext" | |
9763 | ;; | |
9764 | esac | |
e8ce775d JA |
9765 | |
9766 | fi | |
71412226 | 9767 | |
7f947b68 CR |
9768 | ac_fn_c_check_func "$LINENO" "strnlen" "ac_cv_func_strnlen" |
9769 | if test "x$ac_cv_func_strnlen" = xyes; then : | |
9770 | $as_echo "#define HAVE_STRNLEN 1" >>confdefs.h | |
9771 | ||
abe2eb5b | 9772 | else |
7f947b68 CR |
9773 | case " $LIBOBJS " in |
9774 | *" strnlen.$ac_objext "* ) ;; | |
9775 | *) LIBOBJS="$LIBOBJS strnlen.$ac_objext" | |
9776 | ;; | |
9777 | esac | |
c920c360 | 9778 | |
ccc6cda3 | 9779 | fi |
cce855bc | 9780 | |
7f947b68 CR |
9781 | ac_fn_c_check_func "$LINENO" "strpbrk" "ac_cv_func_strpbrk" |
9782 | if test "x$ac_cv_func_strpbrk" = xyes; then : | |
9783 | $as_echo "#define HAVE_STRPBRK 1" >>confdefs.h | |
9784 | ||
9785 | else | |
9786 | case " $LIBOBJS " in | |
9787 | *" strpbrk.$ac_objext "* ) ;; | |
9788 | *) LIBOBJS="$LIBOBJS strpbrk.$ac_objext" | |
9789 | ;; | |
9790 | esac | |
9791 | ||
abe2eb5b | 9792 | fi |
71412226 | 9793 | |
7f947b68 CR |
9794 | ac_fn_c_check_func "$LINENO" "strstr" "ac_cv_func_strstr" |
9795 | if test "x$ac_cv_func_strstr" = xyes; then : | |
9796 | $as_echo "#define HAVE_STRSTR 1" >>confdefs.h | |
abe2eb5b | 9797 | |
7f947b68 CR |
9798 | else |
9799 | case " $LIBOBJS " in | |
9800 | *" strstr.$ac_objext "* ) ;; | |
9801 | *) LIBOBJS="$LIBOBJS strstr.$ac_objext" | |
9802 | ;; | |
abe2eb5b | 9803 | esac |
7f947b68 CR |
9804 | |
9805 | fi | |
9806 | ||
9807 | ||
9808 | ac_fn_c_check_func "$LINENO" "strtod" "ac_cv_func_strtod" | |
9809 | if test "x$ac_cv_func_strtod" = xyes; then : | |
9810 | $as_echo "#define HAVE_STRTOD 1" >>confdefs.h | |
9811 | ||
2dead0c4 | 9812 | else |
7f947b68 CR |
9813 | case " $LIBOBJS " in |
9814 | *" strtod.$ac_objext "* ) ;; | |
9815 | *) LIBOBJS="$LIBOBJS strtod.$ac_objext" | |
9816 | ;; | |
9817 | esac | |
2dead0c4 CR |
9818 | |
9819 | fi | |
9820 | ||
7f947b68 CR |
9821 | ac_fn_c_check_func "$LINENO" "strtol" "ac_cv_func_strtol" |
9822 | if test "x$ac_cv_func_strtol" = xyes; then : | |
9823 | $as_echo "#define HAVE_STRTOL 1" >>confdefs.h | |
9824 | ||
2dead0c4 | 9825 | else |
7f947b68 CR |
9826 | case " $LIBOBJS " in |
9827 | *" strtol.$ac_objext "* ) ;; | |
9828 | *) LIBOBJS="$LIBOBJS strtol.$ac_objext" | |
9829 | ;; | |
9830 | esac | |
2dead0c4 | 9831 | |
7f947b68 | 9832 | fi |
2dead0c4 | 9833 | |
7f947b68 CR |
9834 | ac_fn_c_check_func "$LINENO" "strtoul" "ac_cv_func_strtoul" |
9835 | if test "x$ac_cv_func_strtoul" = xyes; then : | |
9836 | $as_echo "#define HAVE_STRTOUL 1" >>confdefs.h | |
9837 | ||
9838 | else | |
9839 | case " $LIBOBJS " in | |
9840 | *" strtoul.$ac_objext "* ) ;; | |
9841 | *) LIBOBJS="$LIBOBJS strtoul.$ac_objext" | |
9842 | ;; | |
abe2eb5b | 9843 | esac |
7f947b68 CR |
9844 | |
9845 | fi | |
9846 | ||
9847 | ac_fn_c_check_func "$LINENO" "strtoll" "ac_cv_func_strtoll" | |
9848 | if test "x$ac_cv_func_strtoll" = xyes; then : | |
9849 | $as_echo "#define HAVE_STRTOLL 1" >>confdefs.h | |
9850 | ||
71412226 | 9851 | else |
7f947b68 CR |
9852 | case " $LIBOBJS " in |
9853 | *" strtoll.$ac_objext "* ) ;; | |
9854 | *) LIBOBJS="$LIBOBJS strtoll.$ac_objext" | |
9855 | ;; | |
9856 | esac | |
abe2eb5b | 9857 | |
2dead0c4 | 9858 | fi |
7f947b68 CR |
9859 | |
9860 | ac_fn_c_check_func "$LINENO" "strtoull" "ac_cv_func_strtoull" | |
9861 | if test "x$ac_cv_func_strtoull" = xyes; then : | |
9862 | $as_echo "#define HAVE_STRTOULL 1" >>confdefs.h | |
9863 | ||
9864 | else | |
9865 | case " $LIBOBJS " in | |
9866 | *" strtoull.$ac_objext "* ) ;; | |
9867 | *) LIBOBJS="$LIBOBJS strtoull.$ac_objext" | |
9868 | ;; | |
9869 | esac | |
9870 | ||
2dead0c4 | 9871 | fi |
7f947b68 CR |
9872 | |
9873 | ac_fn_c_check_func "$LINENO" "strtoimax" "ac_cv_func_strtoimax" | |
9874 | if test "x$ac_cv_func_strtoimax" = xyes; then : | |
9875 | $as_echo "#define HAVE_STRTOIMAX 1" >>confdefs.h | |
9876 | ||
9877 | else | |
9878 | case " $LIBOBJS " in | |
9879 | *" strtoimax.$ac_objext "* ) ;; | |
9880 | *) LIBOBJS="$LIBOBJS strtoimax.$ac_objext" | |
9881 | ;; | |
9882 | esac | |
9883 | ||
abe2eb5b | 9884 | fi |
2dead0c4 | 9885 | |
7f947b68 CR |
9886 | ac_fn_c_check_func "$LINENO" "strtoumax" "ac_cv_func_strtoumax" |
9887 | if test "x$ac_cv_func_strtoumax" = xyes; then : | |
9888 | $as_echo "#define HAVE_STRTOUMAX 1" >>confdefs.h | |
c920c360 | 9889 | |
7f947b68 CR |
9890 | else |
9891 | case " $LIBOBJS " in | |
9892 | *" strtoumax.$ac_objext "* ) ;; | |
9893 | *) LIBOBJS="$LIBOBJS strtoumax.$ac_objext" | |
9894 | ;; | |
9895 | esac | |
ccc6cda3 | 9896 | |
7f947b68 | 9897 | fi |
abe2eb5b CR |
9898 | |
9899 | ||
7f947b68 CR |
9900 | ac_fn_c_check_func "$LINENO" "dprintf" "ac_cv_func_dprintf" |
9901 | if test "x$ac_cv_func_dprintf" = xyes; then : | |
9902 | $as_echo "#define HAVE_DPRINTF 1" >>confdefs.h | |
abe2eb5b | 9903 | |
ccc6cda3 | 9904 | else |
7f947b68 CR |
9905 | case " $LIBOBJS " in |
9906 | *" dprintf.$ac_objext "* ) ;; | |
9907 | *) LIBOBJS="$LIBOBJS dprintf.$ac_objext" | |
9908 | ;; | |
abe2eb5b | 9909 | esac |
2dead0c4 CR |
9910 | |
9911 | fi | |
9912 | ||
2dead0c4 | 9913 | |
7f947b68 CR |
9914 | ac_fn_c_check_func "$LINENO" "strchrnul" "ac_cv_func_strchrnul" |
9915 | if test "x$ac_cv_func_strchrnul" = xyes; then : | |
9916 | $as_echo "#define HAVE_STRCHRNUL 1" >>confdefs.h | |
7610e0c5 | 9917 | |
7f947b68 CR |
9918 | else |
9919 | case " $LIBOBJS " in | |
9920 | *" strchrnul.$ac_objext "* ) ;; | |
9921 | *) LIBOBJS="$LIBOBJS strchrnul.$ac_objext" | |
9922 | ;; | |
9923 | esac | |
2dead0c4 CR |
9924 | |
9925 | fi | |
7f947b68 CR |
9926 | |
9927 | ||
9928 | ||
9929 | ac_fn_c_check_decl "$LINENO" "AUDIT_USER_TTY" "ac_cv_have_decl_AUDIT_USER_TTY" "#include <linux/audit.h> | |
9930 | " | |
9931 | if test "x$ac_cv_have_decl_AUDIT_USER_TTY" = xyes; then : | |
9932 | ac_have_decl=1 | |
abe2eb5b | 9933 | else |
7f947b68 CR |
9934 | ac_have_decl=0 |
9935 | fi | |
c920c360 | 9936 | |
abe2eb5b | 9937 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 9938 | #define HAVE_DECL_AUDIT_USER_TTY $ac_have_decl |
2dead0c4 | 9939 | _ACEOF |
c920c360 | 9940 | |
c920c360 | 9941 | |
7f947b68 CR |
9942 | ac_fn_c_check_decl "$LINENO" "confstr" "ac_cv_have_decl_confstr" "$ac_includes_default" |
9943 | if test "x$ac_cv_have_decl_confstr" = xyes; then : | |
9944 | ac_have_decl=1 | |
c920c360 | 9945 | else |
7f947b68 CR |
9946 | ac_have_decl=0 |
9947 | fi | |
9948 | ||
9949 | cat >>confdefs.h <<_ACEOF | |
9950 | #define HAVE_DECL_CONFSTR $ac_have_decl | |
2dead0c4 | 9951 | _ACEOF |
c920c360 | 9952 | |
7f947b68 CR |
9953 | ac_fn_c_check_decl "$LINENO" "printf" "ac_cv_have_decl_printf" "$ac_includes_default" |
9954 | if test "x$ac_cv_have_decl_printf" = xyes; then : | |
9955 | ac_have_decl=1 | |
9956 | else | |
9957 | ac_have_decl=0 | |
e3db237e | 9958 | fi |
c920c360 | 9959 | |
7f947b68 CR |
9960 | cat >>confdefs.h <<_ACEOF |
9961 | #define HAVE_DECL_PRINTF $ac_have_decl | |
9962 | _ACEOF | |
9963 | ||
9964 | ac_fn_c_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default" | |
9965 | if test "x$ac_cv_have_decl_sbrk" = xyes; then : | |
9966 | ac_have_decl=1 | |
abe2eb5b | 9967 | else |
7f947b68 CR |
9968 | ac_have_decl=0 |
9969 | fi | |
2dead0c4 | 9970 | |
7f947b68 CR |
9971 | cat >>confdefs.h <<_ACEOF |
9972 | #define HAVE_DECL_SBRK $ac_have_decl | |
9973 | _ACEOF | |
2dead0c4 | 9974 | |
7f947b68 CR |
9975 | ac_fn_c_check_decl "$LINENO" "setregid" "ac_cv_have_decl_setregid" "$ac_includes_default" |
9976 | if test "x$ac_cv_have_decl_setregid" = xyes; then : | |
9977 | ac_have_decl=1 | |
9978 | else | |
9979 | ac_have_decl=0 | |
2dead0c4 | 9980 | fi |
71412226 | 9981 | |
7f947b68 CR |
9982 | cat >>confdefs.h <<_ACEOF |
9983 | #define HAVE_DECL_SETREGID $ac_have_decl | |
9984 | _ACEOF | |
9985 | ||
9986 | ac_fn_c_check_decl "$LINENO" "strcpy" "ac_cv_have_decl_strcpy" "$ac_includes_default" | |
9987 | if test "x$ac_cv_have_decl_strcpy" = xyes; then : | |
9988 | ac_have_decl=1 | |
abe2eb5b | 9989 | else |
7f947b68 CR |
9990 | ac_have_decl=0 |
9991 | fi | |
abe2eb5b | 9992 | |
e3db237e | 9993 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 9994 | #define HAVE_DECL_STRCPY $ac_have_decl |
e3db237e | 9995 | _ACEOF |
71412226 | 9996 | |
7f947b68 CR |
9997 | ac_fn_c_check_decl "$LINENO" "strsignal" "ac_cv_have_decl_strsignal" "$ac_includes_default" |
9998 | if test "x$ac_cv_have_decl_strsignal" = xyes; then : | |
9999 | ac_have_decl=1 | |
10000 | else | |
10001 | ac_have_decl=0 | |
abe2eb5b | 10002 | fi |
71412226 | 10003 | |
7f947b68 CR |
10004 | cat >>confdefs.h <<_ACEOF |
10005 | #define HAVE_DECL_STRSIGNAL $ac_have_decl | |
10006 | _ACEOF | |
71412226 | 10007 | |
ccc6cda3 | 10008 | |
7f947b68 CR |
10009 | ac_fn_c_check_decl "$LINENO" "strtold" "ac_cv_have_decl_strtold" "$ac_includes_default" |
10010 | if test "x$ac_cv_have_decl_strtold" = xyes; then : | |
10011 | ac_have_decl=1 | |
e3db237e | 10012 | else |
7f947b68 CR |
10013 | ac_have_decl=0 |
10014 | fi | |
10015 | ||
10016 | cat >>confdefs.h <<_ACEOF | |
10017 | #define HAVE_DECL_STRTOLD $ac_have_decl | |
abe2eb5b | 10018 | _ACEOF |
7f947b68 CR |
10019 | if test $ac_have_decl = 1; then : |
10020 | ||
10021 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken strtold" >&5 | |
10022 | $as_echo_n "checking for broken strtold... " >&6; } | |
10023 | if ${bash_cv_strtold_broken+:} false; then : | |
10024 | $as_echo_n "(cached) " >&6 | |
10025 | else | |
10026 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 10027 | /* end confdefs.h. */ |
7f947b68 | 10028 | #include <stdlib.h> |
abe2eb5b | 10029 | int |
7f947b68 CR |
10030 | main () |
10031 | { | |
10032 | int main() { long double r; char *foo, bar; r = strtold(foo, &bar);} | |
10033 | ; | |
10034 | return 0; | |
10035 | } | |
10036 | _ACEOF | |
10037 | if ac_fn_c_try_compile "$LINENO"; then : | |
10038 | bash_cv_strtold_broken=no | |
e3db237e | 10039 | else |
7f947b68 | 10040 | bash_cv_strtold_broken=yes |
e3db237e | 10041 | fi |
abe2eb5b | 10042 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
abe2eb5b | 10043 | |
7610e0c5 | 10044 | |
2dead0c4 | 10045 | fi |
c920c360 | 10046 | |
7f947b68 CR |
10047 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_strtold_broken" >&5 |
10048 | $as_echo "$bash_cv_strtold_broken" >&6; } | |
10049 | if test "$bash_cv_strtold_broken" = "yes" ; then | |
10050 | $as_echo "#define STRTOLD_BROKEN 1" >>confdefs.h | |
ccc6cda3 | 10051 | |
7f947b68 | 10052 | fi |
abe2eb5b CR |
10053 | |
10054 | fi | |
10055 | ||
7f947b68 CR |
10056 | |
10057 | ||
10058 | ||
10059 | ||
10060 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoimax" >&5 | |
10061 | $as_echo_n "checking for declaration of strtoimax... " >&6; } | |
10062 | if ${bash_cv_decl_strtoimax+:} false; then : | |
e3db237e | 10063 | $as_echo_n "(cached) " >&6 |
c920c360 | 10064 | else |
7f947b68 | 10065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 10066 | /* end confdefs.h. */ |
7f947b68 CR |
10067 | |
10068 | #if STDC_HEADERS | |
10069 | # include <stdlib.h> | |
10070 | #endif | |
10071 | #if HAVE_INTTYPES_H | |
10072 | # include <inttypes.h> | |
10073 | #endif | |
10074 | ||
e3db237e CR |
10075 | int |
10076 | main () | |
10077 | { | |
7f947b68 | 10078 | return !strtoimax; |
e3db237e CR |
10079 | ; |
10080 | return 0; | |
10081 | } | |
10082 | _ACEOF | |
7f947b68 CR |
10083 | if ac_fn_c_try_link "$LINENO"; then : |
10084 | bash_cv_decl_strtoimax=yes | |
10085 | else | |
10086 | bash_cv_decl_strtoimax=no | |
10087 | fi | |
10088 | rm -f core conftest.err conftest.$ac_objext \ | |
10089 | conftest$ac_exeext conftest.$ac_ext | |
10090 | fi | |
10091 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoimax" >&5 | |
10092 | $as_echo "$bash_cv_decl_strtoimax" >&6; } | |
10093 | bash_tr_func=HAVE_DECL_`echo strtoimax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10094 | if test $bash_cv_decl_strtoimax = yes; then | |
10095 | cat >>confdefs.h <<_ACEOF | |
10096 | #define $bash_tr_func 1 | |
10097 | _ACEOF | |
10098 | ||
10099 | else | |
10100 | cat >>confdefs.h <<_ACEOF | |
10101 | #define $bash_tr_func 0 | |
abe2eb5b | 10102 | _ACEOF |
7f947b68 CR |
10103 | |
10104 | fi | |
10105 | ||
10106 | ||
10107 | ||
10108 | ||
10109 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtol" >&5 | |
10110 | $as_echo_n "checking for declaration of strtol... " >&6; } | |
10111 | if ${bash_cv_decl_strtol+:} false; then : | |
10112 | $as_echo_n "(cached) " >&6 | |
10113 | else | |
10114 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 10115 | /* end confdefs.h. */ |
7f947b68 CR |
10116 | |
10117 | #if STDC_HEADERS | |
10118 | # include <stdlib.h> | |
10119 | #endif | |
10120 | #if HAVE_INTTYPES_H | |
10121 | # include <inttypes.h> | |
10122 | #endif | |
10123 | ||
e3db237e CR |
10124 | int |
10125 | main () | |
10126 | { | |
7f947b68 | 10127 | return !strtol; |
e3db237e CR |
10128 | ; |
10129 | return 0; | |
10130 | } | |
7610e0c5 | 10131 | _ACEOF |
7f947b68 CR |
10132 | if ac_fn_c_try_link "$LINENO"; then : |
10133 | bash_cv_decl_strtol=yes | |
e3db237e | 10134 | else |
7f947b68 | 10135 | bash_cv_decl_strtol=no |
2dead0c4 | 10136 | fi |
7f947b68 CR |
10137 | rm -f core conftest.err conftest.$ac_objext \ |
10138 | conftest$ac_exeext conftest.$ac_ext | |
10139 | fi | |
10140 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtol" >&5 | |
10141 | $as_echo "$bash_cv_decl_strtol" >&6; } | |
10142 | bash_tr_func=HAVE_DECL_`echo strtol | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10143 | if test $bash_cv_decl_strtol = yes; then | |
10144 | cat >>confdefs.h <<_ACEOF | |
10145 | #define $bash_tr_func 1 | |
10146 | _ACEOF | |
abe2eb5b | 10147 | |
e3db237e | 10148 | else |
7f947b68 CR |
10149 | cat >>confdefs.h <<_ACEOF |
10150 | #define $bash_tr_func 0 | |
10151 | _ACEOF | |
abe2eb5b | 10152 | |
e3db237e | 10153 | fi |
c920c360 | 10154 | |
abe2eb5b | 10155 | |
71412226 | 10156 | |
abe2eb5b | 10157 | |
7f947b68 CR |
10158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoll" >&5 |
10159 | $as_echo_n "checking for declaration of strtoll... " >&6; } | |
10160 | if ${bash_cv_decl_strtoll+:} false; then : | |
2dead0c4 CR |
10161 | $as_echo_n "(cached) " >&6 |
10162 | else | |
7f947b68 | 10163 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 10164 | /* end confdefs.h. */ |
7f947b68 CR |
10165 | |
10166 | #if STDC_HEADERS | |
10167 | # include <stdlib.h> | |
10168 | #endif | |
10169 | #if HAVE_INTTYPES_H | |
10170 | # include <inttypes.h> | |
10171 | #endif | |
10172 | ||
e3db237e CR |
10173 | int |
10174 | main () | |
10175 | { | |
7f947b68 | 10176 | return !strtoll; |
e3db237e CR |
10177 | ; |
10178 | return 0; | |
10179 | } | |
f73dda09 | 10180 | _ACEOF |
7f947b68 CR |
10181 | if ac_fn_c_try_link "$LINENO"; then : |
10182 | bash_cv_decl_strtoll=yes | |
10183 | else | |
10184 | bash_cv_decl_strtoll=no | |
10185 | fi | |
10186 | rm -f core conftest.err conftest.$ac_objext \ | |
10187 | conftest$ac_exeext conftest.$ac_ext | |
10188 | fi | |
10189 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoll" >&5 | |
10190 | $as_echo "$bash_cv_decl_strtoll" >&6; } | |
10191 | bash_tr_func=HAVE_DECL_`echo strtoll | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10192 | if test $bash_cv_decl_strtoll = yes; then | |
10193 | cat >>confdefs.h <<_ACEOF | |
10194 | #define $bash_tr_func 1 | |
10195 | _ACEOF | |
10196 | ||
10197 | else | |
10198 | cat >>confdefs.h <<_ACEOF | |
10199 | #define $bash_tr_func 0 | |
abe2eb5b | 10200 | _ACEOF |
7f947b68 CR |
10201 | |
10202 | fi | |
10203 | ||
10204 | ||
10205 | ||
10206 | ||
10207 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoul" >&5 | |
10208 | $as_echo_n "checking for declaration of strtoul... " >&6; } | |
10209 | if ${bash_cv_decl_strtoul+:} false; then : | |
10210 | $as_echo_n "(cached) " >&6 | |
10211 | else | |
10212 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 10213 | /* end confdefs.h. */ |
7f947b68 CR |
10214 | |
10215 | #if STDC_HEADERS | |
10216 | # include <stdlib.h> | |
10217 | #endif | |
10218 | #if HAVE_INTTYPES_H | |
10219 | # include <inttypes.h> | |
10220 | #endif | |
10221 | ||
abe2eb5b CR |
10222 | int |
10223 | main () | |
10224 | { | |
7f947b68 | 10225 | return !strtoul; |
abe2eb5b CR |
10226 | ; |
10227 | return 0; | |
10228 | } | |
10229 | _ACEOF | |
7f947b68 CR |
10230 | if ac_fn_c_try_link "$LINENO"; then : |
10231 | bash_cv_decl_strtoul=yes | |
e3db237e | 10232 | else |
7f947b68 | 10233 | bash_cv_decl_strtoul=no |
2dead0c4 | 10234 | fi |
7f947b68 CR |
10235 | rm -f core conftest.err conftest.$ac_objext \ |
10236 | conftest$ac_exeext conftest.$ac_ext | |
c920c360 | 10237 | fi |
7f947b68 CR |
10238 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoul" >&5 |
10239 | $as_echo "$bash_cv_decl_strtoul" >&6; } | |
10240 | bash_tr_func=HAVE_DECL_`echo strtoul | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10241 | if test $bash_cv_decl_strtoul = yes; then | |
10242 | cat >>confdefs.h <<_ACEOF | |
10243 | #define $bash_tr_func 1 | |
10244 | _ACEOF | |
c920c360 | 10245 | |
abe2eb5b | 10246 | else |
7f947b68 CR |
10247 | cat >>confdefs.h <<_ACEOF |
10248 | #define $bash_tr_func 0 | |
abe2eb5b | 10249 | _ACEOF |
c920c360 | 10250 | |
ccc6cda3 | 10251 | fi |
c920c360 | 10252 | |
abe2eb5b CR |
10253 | |
10254 | ||
7f947b68 CR |
10255 | |
10256 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoull" >&5 | |
10257 | $as_echo_n "checking for declaration of strtoull... " >&6; } | |
10258 | if ${bash_cv_decl_strtoull+:} false; then : | |
e3db237e | 10259 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 10260 | else |
7f947b68 | 10261 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 10262 | /* end confdefs.h. */ |
7f947b68 CR |
10263 | |
10264 | #if STDC_HEADERS | |
10265 | # include <stdlib.h> | |
10266 | #endif | |
10267 | #if HAVE_INTTYPES_H | |
10268 | # include <inttypes.h> | |
10269 | #endif | |
10270 | ||
e3db237e CR |
10271 | int |
10272 | main () | |
10273 | { | |
7f947b68 | 10274 | return !strtoull; |
e3db237e CR |
10275 | ; |
10276 | return 0; | |
10277 | } | |
10278 | _ACEOF | |
7f947b68 CR |
10279 | if ac_fn_c_try_link "$LINENO"; then : |
10280 | bash_cv_decl_strtoull=yes | |
10281 | else | |
10282 | bash_cv_decl_strtoull=no | |
10283 | fi | |
10284 | rm -f core conftest.err conftest.$ac_objext \ | |
10285 | conftest$ac_exeext conftest.$ac_ext | |
10286 | fi | |
10287 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoull" >&5 | |
10288 | $as_echo "$bash_cv_decl_strtoull" >&6; } | |
10289 | bash_tr_func=HAVE_DECL_`echo strtoull | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10290 | if test $bash_cv_decl_strtoull = yes; then | |
10291 | cat >>confdefs.h <<_ACEOF | |
10292 | #define $bash_tr_func 1 | |
10293 | _ACEOF | |
10294 | ||
10295 | else | |
10296 | cat >>confdefs.h <<_ACEOF | |
10297 | #define $bash_tr_func 0 | |
abe2eb5b | 10298 | _ACEOF |
7f947b68 CR |
10299 | |
10300 | fi | |
10301 | ||
10302 | ||
10303 | ||
10304 | ||
10305 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for declaration of strtoumax" >&5 | |
10306 | $as_echo_n "checking for declaration of strtoumax... " >&6; } | |
10307 | if ${bash_cv_decl_strtoumax+:} false; then : | |
10308 | $as_echo_n "(cached) " >&6 | |
10309 | else | |
10310 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 10311 | /* end confdefs.h. */ |
7f947b68 CR |
10312 | |
10313 | #if STDC_HEADERS | |
10314 | # include <stdlib.h> | |
10315 | #endif | |
10316 | #if HAVE_INTTYPES_H | |
10317 | # include <inttypes.h> | |
10318 | #endif | |
10319 | ||
abe2eb5b CR |
10320 | int |
10321 | main () | |
10322 | { | |
7f947b68 | 10323 | return !strtoumax; |
abe2eb5b CR |
10324 | ; |
10325 | return 0; | |
10326 | } | |
10327 | _ACEOF | |
7f947b68 CR |
10328 | if ac_fn_c_try_link "$LINENO"; then : |
10329 | bash_cv_decl_strtoumax=yes | |
e3db237e | 10330 | else |
7f947b68 CR |
10331 | bash_cv_decl_strtoumax=no |
10332 | fi | |
10333 | rm -f core conftest.err conftest.$ac_objext \ | |
10334 | conftest$ac_exeext conftest.$ac_ext | |
2dead0c4 | 10335 | fi |
7f947b68 CR |
10336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_strtoumax" >&5 |
10337 | $as_echo "$bash_cv_decl_strtoumax" >&6; } | |
10338 | bash_tr_func=HAVE_DECL_`echo strtoumax | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
10339 | if test $bash_cv_decl_strtoumax = yes; then | |
10340 | cat >>confdefs.h <<_ACEOF | |
10341 | #define $bash_tr_func 1 | |
10342 | _ACEOF | |
a82a04b3 | 10343 | |
abe2eb5b | 10344 | else |
7f947b68 CR |
10345 | cat >>confdefs.h <<_ACEOF |
10346 | #define $bash_tr_func 0 | |
10347 | _ACEOF | |
f73dda09 | 10348 | |
c920c360 | 10349 | fi |
2dead0c4 | 10350 | |
7610e0c5 | 10351 | |
7f947b68 CR |
10352 | |
10353 | ||
10354 | ||
10355 | ||
10356 | ||
10357 | for ac_func in $ac_func_list | |
10358 | do : | |
10359 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10360 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
10361 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
10362 | cat >>confdefs.h <<_ACEOF | |
10363 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
c920c360 | 10364 | _ACEOF |
2dead0c4 CR |
10365 | |
10366 | fi | |
7f947b68 | 10367 | done |
2dead0c4 | 10368 | |
7f947b68 CR |
10369 | |
10370 | ||
10371 | ||
10372 | ||
10373 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mktime" >&5 | |
10374 | $as_echo_n "checking for working mktime... " >&6; } | |
10375 | if ${ac_cv_func_working_mktime+:} false; then : | |
e3db237e CR |
10376 | $as_echo_n "(cached) " >&6 |
10377 | else | |
7f947b68 CR |
10378 | if test "$cross_compiling" = yes; then : |
10379 | ac_cv_func_working_mktime=no | |
10380 | else | |
10381 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 10382 | /* end confdefs.h. */ |
7f947b68 CR |
10383 | /* Test program from Paul Eggert and Tony Leneis. */ |
10384 | #ifdef TIME_WITH_SYS_TIME | |
10385 | # include <sys/time.h> | |
10386 | # include <time.h> | |
10387 | #else | |
10388 | # ifdef HAVE_SYS_TIME_H | |
10389 | # include <sys/time.h> | |
10390 | # else | |
10391 | # include <time.h> | |
10392 | # endif | |
10393 | #endif | |
10394 | ||
10395 | #include <limits.h> | |
10396 | #include <stdlib.h> | |
10397 | ||
10398 | #ifdef HAVE_UNISTD_H | |
10399 | # include <unistd.h> | |
10400 | #endif | |
10401 | ||
10402 | #ifndef HAVE_ALARM | |
10403 | # define alarm(X) /* empty */ | |
10404 | #endif | |
10405 | ||
10406 | /* Work around redefinition to rpl_putenv by other config tests. */ | |
10407 | #undef putenv | |
10408 | ||
10409 | static time_t time_t_max; | |
10410 | static time_t time_t_min; | |
10411 | ||
10412 | /* Values we'll use to set the TZ environment variable. */ | |
10413 | static const char *tz_strings[] = { | |
10414 | (const char *) 0, "TZ=GMT0", "TZ=JST-9", | |
10415 | "TZ=EST+3EDT+2,M10.1.0/00:00:00,M2.3.0/00:00:00" | |
10416 | }; | |
10417 | #define N_STRINGS (sizeof (tz_strings) / sizeof (tz_strings[0])) | |
10418 | ||
10419 | /* Return 0 if mktime fails to convert a date in the spring-forward gap. | |
10420 | Based on a problem report from Andreas Jaeger. */ | |
10421 | static int | |
10422 | spring_forward_gap () | |
e3db237e | 10423 | { |
7f947b68 CR |
10424 | /* glibc (up to about 1998-10-07) failed this test. */ |
10425 | struct tm tm; | |
10426 | ||
10427 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10428 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10429 | on systems that don't support the Olson extension, or don't have the | |
10430 | full zoneinfo tables installed. */ | |
10431 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
10432 | ||
10433 | tm.tm_year = 98; | |
10434 | tm.tm_mon = 3; | |
10435 | tm.tm_mday = 5; | |
10436 | tm.tm_hour = 2; | |
10437 | tm.tm_min = 0; | |
10438 | tm.tm_sec = 0; | |
10439 | tm.tm_isdst = -1; | |
10440 | return mktime (&tm) != (time_t) -1; | |
e3db237e | 10441 | } |
7f947b68 CR |
10442 | |
10443 | static int | |
10444 | mktime_test1 (time_t now) | |
10445 | { | |
10446 | struct tm *lt; | |
10447 | return ! (lt = localtime (&now)) || mktime (lt) == now; | |
10448 | } | |
10449 | ||
10450 | static int | |
10451 | mktime_test (time_t now) | |
10452 | { | |
10453 | return (mktime_test1 (now) | |
10454 | && mktime_test1 ((time_t) (time_t_max - now)) | |
10455 | && mktime_test1 ((time_t) (time_t_min + now))); | |
10456 | } | |
10457 | ||
10458 | static int | |
10459 | irix_6_4_bug () | |
10460 | { | |
10461 | /* Based on code from Ariel Faigon. */ | |
10462 | struct tm tm; | |
10463 | tm.tm_year = 96; | |
10464 | tm.tm_mon = 3; | |
10465 | tm.tm_mday = 0; | |
10466 | tm.tm_hour = 0; | |
10467 | tm.tm_min = 0; | |
10468 | tm.tm_sec = 0; | |
10469 | tm.tm_isdst = -1; | |
10470 | mktime (&tm); | |
10471 | return tm.tm_mon == 2 && tm.tm_mday == 31; | |
10472 | } | |
10473 | ||
10474 | static int | |
10475 | bigtime_test (int j) | |
10476 | { | |
10477 | struct tm tm; | |
10478 | time_t now; | |
10479 | tm.tm_year = tm.tm_mon = tm.tm_mday = tm.tm_hour = tm.tm_min = tm.tm_sec = j; | |
10480 | now = mktime (&tm); | |
10481 | if (now != (time_t) -1) | |
10482 | { | |
10483 | struct tm *lt = localtime (&now); | |
10484 | if (! (lt | |
10485 | && lt->tm_year == tm.tm_year | |
10486 | && lt->tm_mon == tm.tm_mon | |
10487 | && lt->tm_mday == tm.tm_mday | |
10488 | && lt->tm_hour == tm.tm_hour | |
10489 | && lt->tm_min == tm.tm_min | |
10490 | && lt->tm_sec == tm.tm_sec | |
10491 | && lt->tm_yday == tm.tm_yday | |
10492 | && lt->tm_wday == tm.tm_wday | |
10493 | && ((lt->tm_isdst < 0 ? -1 : 0 < lt->tm_isdst) | |
10494 | == (tm.tm_isdst < 0 ? -1 : 0 < tm.tm_isdst)))) | |
10495 | return 0; | |
10496 | } | |
10497 | return 1; | |
10498 | } | |
10499 | ||
10500 | static int | |
10501 | year_2050_test () | |
10502 | { | |
10503 | /* The correct answer for 2050-02-01 00:00:00 in Pacific time, | |
10504 | ignoring leap seconds. */ | |
10505 | unsigned long int answer = 2527315200UL; | |
10506 | ||
10507 | struct tm tm; | |
10508 | time_t t; | |
10509 | tm.tm_year = 2050 - 1900; | |
10510 | tm.tm_mon = 2 - 1; | |
10511 | tm.tm_mday = 1; | |
10512 | tm.tm_hour = tm.tm_min = tm.tm_sec = 0; | |
10513 | tm.tm_isdst = -1; | |
10514 | ||
10515 | /* Use the portable POSIX.1 specification "TZ=PST8PDT,M4.1.0,M10.5.0" | |
10516 | instead of "TZ=America/Vancouver" in order to detect the bug even | |
10517 | on systems that don't support the Olson extension, or don't have the | |
10518 | full zoneinfo tables installed. */ | |
10519 | putenv ((char*) "TZ=PST8PDT,M4.1.0,M10.5.0"); | |
10520 | ||
10521 | t = mktime (&tm); | |
10522 | ||
10523 | /* Check that the result is either a failure, or close enough | |
10524 | to the correct answer that we can assume the discrepancy is | |
10525 | due to leap seconds. */ | |
10526 | return (t == (time_t) -1 | |
10527 | || (0 < t && answer - 120 <= t && t <= answer + 120)); | |
10528 | } | |
10529 | ||
abe2eb5b CR |
10530 | int |
10531 | main () | |
10532 | { | |
7f947b68 CR |
10533 | time_t t, delta; |
10534 | int i, j; | |
10535 | ||
10536 | /* This test makes some buggy mktime implementations loop. | |
10537 | Give up after 60 seconds; a mktime slower than that | |
10538 | isn't worth using anyway. */ | |
10539 | alarm (60); | |
10540 | ||
10541 | for (;;) | |
10542 | { | |
10543 | t = (time_t_max << 1) + 1; | |
10544 | if (t <= time_t_max) | |
10545 | break; | |
10546 | time_t_max = t; | |
10547 | } | |
10548 | time_t_min = - ((time_t) ~ (time_t) 0 == (time_t) -1) - time_t_max; | |
10549 | ||
10550 | delta = time_t_max / 997; /* a suitable prime number */ | |
10551 | for (i = 0; i < N_STRINGS; i++) | |
10552 | { | |
10553 | if (tz_strings[i]) | |
10554 | putenv ((char*) tz_strings[i]); | |
10555 | ||
10556 | for (t = 0; t <= time_t_max - delta; t += delta) | |
10557 | if (! mktime_test (t)) | |
10558 | return 1; | |
10559 | if (! (mktime_test ((time_t) 1) | |
10560 | && mktime_test ((time_t) (60 * 60)) | |
10561 | && mktime_test ((time_t) (60 * 60 * 24)))) | |
10562 | return 1; | |
10563 | ||
10564 | for (j = 1; ; j <<= 1) | |
10565 | if (! bigtime_test (j)) | |
10566 | return 1; | |
10567 | else if (INT_MAX / 2 < j) | |
10568 | break; | |
10569 | if (! bigtime_test (INT_MAX)) | |
10570 | return 1; | |
10571 | } | |
10572 | return ! (irix_6_4_bug () && spring_forward_gap () && year_2050_test ()); | |
abe2eb5b | 10573 | } |
c920c360 | 10574 | _ACEOF |
7f947b68 CR |
10575 | if ac_fn_c_try_run "$LINENO"; then : |
10576 | ac_cv_func_working_mktime=yes | |
10577 | else | |
10578 | ac_cv_func_working_mktime=no | |
10579 | fi | |
10580 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
10581 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
10582 | fi | |
10583 | ||
10584 | fi | |
10585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_working_mktime" >&5 | |
10586 | $as_echo "$ac_cv_func_working_mktime" >&6; } | |
10587 | if test $ac_cv_func_working_mktime = no; then | |
10588 | case " $LIBOBJS " in | |
10589 | *" mktime.$ac_objext "* ) ;; | |
10590 | *) LIBOBJS="$LIBOBJS mktime.$ac_objext" | |
10591 | ;; | |
abe2eb5b | 10592 | esac |
7610e0c5 | 10593 | |
f73dda09 | 10594 | fi |
a82a04b3 | 10595 | |
71412226 | 10596 | |
f73dda09 | 10597 | |
7f947b68 CR |
10598 | for ac_header in argz.h errno.h fcntl.h malloc.h stdio_ext.h |
10599 | do : | |
10600 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
10601 | ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" | |
10602 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : | |
10603 | cat >>confdefs.h <<_ACEOF | |
10604 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
10605 | _ACEOF | |
a82a04b3 | 10606 | |
abe2eb5b | 10607 | fi |
7610e0c5 | 10608 | |
7f947b68 CR |
10609 | done |
10610 | ||
10611 | ||
10612 | ||
10613 | for ac_func in getpagesize | |
10614 | do : | |
10615 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
10616 | if test "x$ac_cv_func_getpagesize" = xyes; then : | |
10617 | cat >>confdefs.h <<_ACEOF | |
10618 | #define HAVE_GETPAGESIZE 1 | |
2dead0c4 | 10619 | _ACEOF |
f73dda09 | 10620 | |
2dead0c4 | 10621 | fi |
7f947b68 | 10622 | done |
2dead0c4 | 10623 | |
7f947b68 CR |
10624 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 |
10625 | $as_echo_n "checking for working mmap... " >&6; } | |
10626 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : | |
e3db237e CR |
10627 | $as_echo_n "(cached) " >&6 |
10628 | else | |
7f947b68 CR |
10629 | if test "$cross_compiling" = yes; then : |
10630 | ac_cv_func_mmap_fixed_mapped=no | |
10631 | else | |
10632 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b CR |
10633 | /* end confdefs.h. */ |
10634 | $ac_includes_default | |
7f947b68 CR |
10635 | /* malloc might have been renamed as rpl_malloc. */ |
10636 | #undef malloc | |
10637 | ||
10638 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
10639 | Here is a matrix of mmap possibilities: | |
10640 | mmap private not fixed | |
10641 | mmap private fixed at somewhere currently unmapped | |
10642 | mmap private fixed at somewhere already mapped | |
10643 | mmap shared not fixed | |
10644 | mmap shared fixed at somewhere currently unmapped | |
10645 | mmap shared fixed at somewhere already mapped | |
10646 | For private mappings, we should verify that changes cannot be read() | |
10647 | back from the file, nor mmap's back from the file at a different | |
10648 | address. (There have been systems where private was not correctly | |
10649 | implemented like the infamous i386 svr4.0, and systems where the | |
10650 | VM page cache was not coherent with the file system buffer cache | |
10651 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
10652 | For shared mappings, we should conversely verify that changes get | |
10653 | propagated back to all the places they're supposed to be. | |
10654 | ||
10655 | Grep wants private fixed already mapped. | |
10656 | The main things grep needs to know about mmap are: | |
10657 | * does it exist and is it safe to write into the mmap'd area | |
10658 | * how to use it (BSD variants) */ | |
10659 | ||
10660 | #include <fcntl.h> | |
10661 | #include <sys/mman.h> | |
10662 | ||
10663 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H | |
10664 | char *malloc (); | |
10665 | #endif | |
10666 | ||
10667 | /* This mess was copied from the GNU getpagesize.h. */ | |
10668 | #ifndef HAVE_GETPAGESIZE | |
10669 | # ifdef _SC_PAGESIZE | |
10670 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
10671 | # else /* no _SC_PAGESIZE */ | |
10672 | # ifdef HAVE_SYS_PARAM_H | |
10673 | # include <sys/param.h> | |
10674 | # ifdef EXEC_PAGESIZE | |
10675 | # define getpagesize() EXEC_PAGESIZE | |
10676 | # else /* no EXEC_PAGESIZE */ | |
10677 | # ifdef NBPG | |
10678 | # define getpagesize() NBPG * CLSIZE | |
10679 | # ifndef CLSIZE | |
10680 | # define CLSIZE 1 | |
10681 | # endif /* no CLSIZE */ | |
10682 | # else /* no NBPG */ | |
10683 | # ifdef NBPC | |
10684 | # define getpagesize() NBPC | |
10685 | # else /* no NBPC */ | |
10686 | # ifdef PAGESIZE | |
10687 | # define getpagesize() PAGESIZE | |
10688 | # endif /* PAGESIZE */ | |
10689 | # endif /* no NBPC */ | |
10690 | # endif /* no NBPG */ | |
10691 | # endif /* no EXEC_PAGESIZE */ | |
10692 | # else /* no HAVE_SYS_PARAM_H */ | |
10693 | # define getpagesize() 8192 /* punt totally */ | |
10694 | # endif /* no HAVE_SYS_PARAM_H */ | |
10695 | # endif /* no _SC_PAGESIZE */ | |
10696 | ||
10697 | #endif /* no HAVE_GETPAGESIZE */ | |
10698 | ||
abe2eb5b CR |
10699 | int |
10700 | main () | |
10701 | { | |
7f947b68 CR |
10702 | char *data, *data2, *data3; |
10703 | const char *cdata2; | |
10704 | int i, pagesize; | |
10705 | int fd, fd2; | |
10706 | ||
10707 | pagesize = getpagesize (); | |
10708 | ||
10709 | /* First, make a file with some known garbage in it. */ | |
10710 | data = (char *) malloc (pagesize); | |
10711 | if (!data) | |
10712 | return 1; | |
10713 | for (i = 0; i < pagesize; ++i) | |
10714 | *(data + i) = rand (); | |
10715 | umask (0); | |
10716 | fd = creat ("conftest.mmap", 0600); | |
10717 | if (fd < 0) | |
10718 | return 2; | |
10719 | if (write (fd, data, pagesize) != pagesize) | |
10720 | return 3; | |
10721 | close (fd); | |
10722 | ||
10723 | /* Next, check that the tail of a page is zero-filled. File must have | |
10724 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
10725 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
10726 | if (fd2 < 0) | |
10727 | return 4; | |
10728 | cdata2 = ""; | |
10729 | if (write (fd2, cdata2, 1) != 1) | |
10730 | return 5; | |
10731 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
10732 | if (data2 == MAP_FAILED) | |
10733 | return 6; | |
10734 | for (i = 0; i < pagesize; ++i) | |
10735 | if (*(data2 + i)) | |
10736 | return 7; | |
10737 | close (fd2); | |
10738 | if (munmap (data2, pagesize)) | |
10739 | return 8; | |
10740 | ||
10741 | /* Next, try to mmap the file at a fixed address which already has | |
10742 | something else allocated at it. If we can, also make sure that | |
10743 | we see the same garbage. */ | |
10744 | fd = open ("conftest.mmap", O_RDWR); | |
10745 | if (fd < 0) | |
10746 | return 9; | |
10747 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, | |
10748 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
10749 | return 10; | |
10750 | for (i = 0; i < pagesize; ++i) | |
10751 | if (*(data + i) != *(data2 + i)) | |
10752 | return 11; | |
10753 | ||
10754 | /* Finally, make sure that changes to the mapped area do not | |
10755 | percolate back to the file as seen by read(). (This is a bug on | |
10756 | some variants of i386 svr4.0.) */ | |
10757 | for (i = 0; i < pagesize; ++i) | |
10758 | *(data2 + i) = *(data2 + i) + 1; | |
10759 | data3 = (char *) malloc (pagesize); | |
10760 | if (!data3) | |
10761 | return 12; | |
10762 | if (read (fd, data3, pagesize) != pagesize) | |
10763 | return 13; | |
10764 | for (i = 0; i < pagesize; ++i) | |
10765 | if (*(data + i) != *(data3 + i)) | |
10766 | return 14; | |
10767 | close (fd); | |
abe2eb5b CR |
10768 | return 0; |
10769 | } | |
10770 | _ACEOF | |
7f947b68 CR |
10771 | if ac_fn_c_try_run "$LINENO"; then : |
10772 | ac_cv_func_mmap_fixed_mapped=yes | |
e3db237e | 10773 | else |
7f947b68 CR |
10774 | ac_cv_func_mmap_fixed_mapped=no |
10775 | fi | |
10776 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
10777 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
10778 | fi | |
f73dda09 | 10779 | |
c920c360 | 10780 | fi |
7f947b68 CR |
10781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 |
10782 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } | |
10783 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
7610e0c5 | 10784 | |
7f947b68 CR |
10785 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h |
10786 | ||
10787 | fi | |
10788 | rm -f conftest.mmap conftest.txt | |
7610e0c5 | 10789 | |
7f947b68 CR |
10790 | for ac_func in __argz_count __argz_next __argz_stringify dcgettext mempcpy \ |
10791 | munmap stpcpy strcspn strdup | |
10792 | do : | |
10793 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10794 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
10795 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
10796 | cat >>confdefs.h <<_ACEOF | |
10797 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
10798 | _ACEOF | |
f73dda09 | 10799 | |
e3db237e | 10800 | fi |
7f947b68 | 10801 | done |
2dead0c4 | 10802 | |
7f947b68 CR |
10803 | |
10804 | INTL_DEP= INTL_INC= LIBINTL_H= | |
10805 | if test "x$USE_INCLUDED_LIBINTL" = "xyes"; then | |
10806 | INTL_DEP='${INTL_LIBDIR}/libintl.a' | |
10807 | INTL_INC='-I${INTL_LIBSRC} -I${INTL_BUILDDIR}' | |
10808 | LIBINTL_H='${INTL_BUILDDIR}/libintl.h' | |
abe2eb5b | 10809 | fi |
7610e0c5 | 10810 | |
7f947b68 CR |
10811 | |
10812 | ||
10813 | ||
10814 | ||
10815 | ||
10816 | for ac_header in wctype.h | |
10817 | do : | |
10818 | ac_fn_c_check_header_mongrel "$LINENO" "wctype.h" "ac_cv_header_wctype_h" "$ac_includes_default" | |
10819 | if test "x$ac_cv_header_wctype_h" = xyes; then : | |
10820 | cat >>confdefs.h <<_ACEOF | |
10821 | #define HAVE_WCTYPE_H 1 | |
c920c360 | 10822 | _ACEOF |
f73dda09 | 10823 | |
71412226 | 10824 | fi |
7610e0c5 | 10825 | |
7f947b68 CR |
10826 | done |
10827 | ||
10828 | for ac_header in wchar.h | |
10829 | do : | |
10830 | ac_fn_c_check_header_mongrel "$LINENO" "wchar.h" "ac_cv_header_wchar_h" "$ac_includes_default" | |
10831 | if test "x$ac_cv_header_wchar_h" = xyes; then : | |
10832 | cat >>confdefs.h <<_ACEOF | |
10833 | #define HAVE_WCHAR_H 1 | |
10834 | _ACEOF | |
10835 | ||
abe2eb5b CR |
10836 | fi |
10837 | ||
7f947b68 | 10838 | done |
2dead0c4 | 10839 | |
7f947b68 CR |
10840 | for ac_header in langinfo.h |
10841 | do : | |
10842 | ac_fn_c_check_header_mongrel "$LINENO" "langinfo.h" "ac_cv_header_langinfo_h" "$ac_includes_default" | |
10843 | if test "x$ac_cv_header_langinfo_h" = xyes; then : | |
10844 | cat >>confdefs.h <<_ACEOF | |
10845 | #define HAVE_LANGINFO_H 1 | |
10846 | _ACEOF | |
2dead0c4 | 10847 | |
c920c360 | 10848 | fi |
71412226 | 10849 | |
7f947b68 CR |
10850 | done |
10851 | ||
c920c360 | 10852 | |
7f947b68 CR |
10853 | ac_fn_c_check_func "$LINENO" "mbrlen" "ac_cv_func_mbrlen" |
10854 | if test "x$ac_cv_func_mbrlen" = xyes; then : | |
10855 | $as_echo "#define HAVE_MBRLEN 1" >>confdefs.h | |
71412226 | 10856 | |
f73dda09 | 10857 | fi |
71412226 | 10858 | |
7f947b68 CR |
10859 | ac_fn_c_check_func "$LINENO" "mbscasecmp" "ac_cv_func_mbscasecmp" |
10860 | if test "x$ac_cv_func_mbscasecmp" = xyes; then : | |
10861 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
10862 | ||
abe2eb5b | 10863 | fi |
c920c360 | 10864 | |
7f947b68 CR |
10865 | ac_fn_c_check_func "$LINENO" "mbscmp" "ac_cv_func_mbscmp" |
10866 | if test "x$ac_cv_func_mbscmp" = xyes; then : | |
10867 | $as_echo "#define HAVE_MBSCMP 1" >>confdefs.h | |
7610e0c5 | 10868 | |
71412226 | 10869 | fi |
7610e0c5 | 10870 | |
7f947b68 CR |
10871 | ac_fn_c_check_func "$LINENO" "mbsnrtowcs" "ac_cv_func_mbsnrtowcs" |
10872 | if test "x$ac_cv_func_mbsnrtowcs" = xyes; then : | |
10873 | $as_echo "#define HAVE_MBSNRTOWCS 1" >>confdefs.h | |
10874 | ||
10875 | fi | |
10876 | ||
10877 | ac_fn_c_check_func "$LINENO" "mbsrtowcs" "ac_cv_func_mbsrtowcs" | |
10878 | if test "x$ac_cv_func_mbsrtowcs" = xyes; then : | |
10879 | $as_echo "#define HAVE_MBSRTOWCS 1" >>confdefs.h | |
10880 | ||
10881 | fi | |
10882 | ||
10883 | ||
10884 | ac_fn_c_check_func "$LINENO" "mbschr" "ac_cv_func_mbschr" | |
10885 | if test "x$ac_cv_func_mbschr" = xyes; then : | |
10886 | $as_echo "#define HAVE_MBSCHR 1" >>confdefs.h | |
10887 | ||
e3db237e | 10888 | else |
7f947b68 CR |
10889 | case " $LIBOBJS " in |
10890 | *" mbschr.$ac_objext "* ) ;; | |
10891 | *) LIBOBJS="$LIBOBJS mbschr.$ac_objext" | |
10892 | ;; | |
abe2eb5b | 10893 | esac |
abe2eb5b | 10894 | |
71412226 | 10895 | fi |
abe2eb5b | 10896 | |
abe2eb5b CR |
10897 | |
10898 | ||
7f947b68 CR |
10899 | ac_fn_c_check_func "$LINENO" "wcrtomb" "ac_cv_func_wcrtomb" |
10900 | if test "x$ac_cv_func_wcrtomb" = xyes; then : | |
10901 | $as_echo "#define HAVE_WCRTOMB 1" >>confdefs.h | |
10902 | ||
e3db237e | 10903 | fi |
c920c360 | 10904 | |
7f947b68 CR |
10905 | ac_fn_c_check_func "$LINENO" "wcscoll" "ac_cv_func_wcscoll" |
10906 | if test "x$ac_cv_func_wcscoll" = xyes; then : | |
10907 | $as_echo "#define HAVE_WCSCOLL 1" >>confdefs.h | |
10908 | ||
e3db237e | 10909 | fi |
abe2eb5b | 10910 | |
7f947b68 CR |
10911 | ac_fn_c_check_func "$LINENO" "wcsdup" "ac_cv_func_wcsdup" |
10912 | if test "x$ac_cv_func_wcsdup" = xyes; then : | |
10913 | $as_echo "#define HAVE_WCSDUP 1" >>confdefs.h | |
10914 | ||
10915 | fi | |
10916 | ||
10917 | ac_fn_c_check_func "$LINENO" "wcwidth" "ac_cv_func_wcwidth" | |
10918 | if test "x$ac_cv_func_wcwidth" = xyes; then : | |
10919 | $as_echo "#define HAVE_WCWIDTH 1" >>confdefs.h | |
10920 | ||
10921 | fi | |
10922 | ||
10923 | ac_fn_c_check_func "$LINENO" "wctype" "ac_cv_func_wctype" | |
10924 | if test "x$ac_cv_func_wctype" = xyes; then : | |
10925 | $as_echo "#define HAVE_WCTYPE 1" >>confdefs.h | |
5e4a95c7 | 10926 | |
abe2eb5b | 10927 | fi |
f73dda09 | 10928 | |
7f947b68 CR |
10929 | |
10930 | ac_fn_c_check_func "$LINENO" "wcswidth" "ac_cv_func_wcswidth" | |
10931 | if test "x$ac_cv_func_wcswidth" = xyes; then : | |
10932 | $as_echo "#define HAVE_WCSWIDTH 1" >>confdefs.h | |
10933 | ||
abe2eb5b | 10934 | else |
7f947b68 CR |
10935 | case " $LIBOBJS " in |
10936 | *" wcswidth.$ac_objext "* ) ;; | |
10937 | *) LIBOBJS="$LIBOBJS wcswidth.$ac_objext" | |
10938 | ;; | |
10939 | esac | |
10940 | ||
10941 | fi | |
10942 | ||
10943 | ||
10944 | ||
10945 | ||
10946 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbrtowc and mbstate_t are properly declared" >&5 | |
10947 | $as_echo_n "checking whether mbrtowc and mbstate_t are properly declared... " >&6; } | |
10948 | if ${ac_cv_func_mbrtowc+:} false; then : | |
e3db237e CR |
10949 | $as_echo_n "(cached) " >&6 |
10950 | else | |
7f947b68 | 10951 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 10952 | /* end confdefs.h. */ |
7f947b68 | 10953 | #include <wchar.h> |
e3db237e CR |
10954 | int |
10955 | main () | |
10956 | { | |
7f947b68 CR |
10957 | wchar_t wc; |
10958 | char const s[] = ""; | |
10959 | size_t n = 1; | |
10960 | mbstate_t state; | |
10961 | return ! (sizeof state && (mbrtowc) (&wc, s, n, &state)); | |
e3db237e CR |
10962 | ; |
10963 | return 0; | |
10964 | } | |
10965 | _ACEOF | |
7f947b68 CR |
10966 | if ac_fn_c_try_link "$LINENO"; then : |
10967 | ac_cv_func_mbrtowc=yes | |
c920c360 | 10968 | else |
7f947b68 CR |
10969 | ac_cv_func_mbrtowc=no |
10970 | fi | |
10971 | rm -f core conftest.err conftest.$ac_objext \ | |
10972 | conftest$ac_exeext conftest.$ac_ext | |
e3db237e | 10973 | fi |
7f947b68 CR |
10974 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mbrtowc" >&5 |
10975 | $as_echo "$ac_cv_func_mbrtowc" >&6; } | |
10976 | if test $ac_cv_func_mbrtowc = yes; then | |
2dead0c4 | 10977 | |
7f947b68 | 10978 | $as_echo "#define HAVE_MBRTOWC 1" >>confdefs.h |
7610e0c5 | 10979 | |
7f947b68 | 10980 | fi |
7610e0c5 | 10981 | |
7f947b68 CR |
10982 | if test $ac_cv_func_mbrtowc = yes; then |
10983 | $as_echo "#define HAVE_MBSTATE_T 1" >>confdefs.h | |
71412226 CR |
10984 | |
10985 | fi | |
c920c360 | 10986 | |
7f947b68 CR |
10987 | for ac_func in iswlower iswupper towlower towupper iswctype |
10988 | do : | |
10989 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
10990 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
10991 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
10992 | cat >>confdefs.h <<_ACEOF | |
10993 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
5f8cde23 | 10994 | _ACEOF |
2dead0c4 | 10995 | |
71412226 | 10996 | fi |
7f947b68 | 10997 | done |
5f8cde23 | 10998 | |
c920c360 | 10999 | |
7f947b68 CR |
11000 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
11001 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } | |
11002 | if ${bash_cv_langinfo_codeset+:} false; then : | |
c920c360 CR |
11003 | $as_echo_n "(cached) " >&6 |
11004 | else | |
7f947b68 | 11005 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11006 | /* end confdefs.h. */ |
7f947b68 | 11007 | #include <langinfo.h> |
abe2eb5b CR |
11008 | int |
11009 | main () | |
11010 | { | |
7f947b68 | 11011 | char* cs = nl_langinfo(CODESET); |
abe2eb5b CR |
11012 | ; |
11013 | return 0; | |
11014 | } | |
11015 | _ACEOF | |
7f947b68 CR |
11016 | if ac_fn_c_try_link "$LINENO"; then : |
11017 | bash_cv_langinfo_codeset=yes | |
11018 | else | |
11019 | bash_cv_langinfo_codeset=no | |
11020 | fi | |
11021 | rm -f core conftest.err conftest.$ac_objext \ | |
11022 | conftest$ac_exeext conftest.$ac_ext | |
11023 | fi | |
11024 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_langinfo_codeset" >&5 | |
11025 | $as_echo "$bash_cv_langinfo_codeset" >&6; } | |
11026 | if test $bash_cv_langinfo_codeset = yes; then | |
11027 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h | |
11028 | ||
11029 | fi | |
11030 | ||
11031 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wchar_t in wchar.h" >&5 | |
11032 | $as_echo_n "checking for wchar_t in wchar.h... " >&6; } | |
11033 | if ${bash_cv_type_wchar_t+:} false; then : | |
11034 | $as_echo_n "(cached) " >&6 | |
11035 | else | |
11036 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11037 | /* end confdefs.h. */ |
7f947b68 CR |
11038 | #include <wchar.h> |
11039 | ||
abe2eb5b CR |
11040 | int |
11041 | main () | |
11042 | { | |
7f947b68 CR |
11043 | |
11044 | wchar_t foo; | |
11045 | foo = 0; | |
11046 | ||
abe2eb5b CR |
11047 | ; |
11048 | return 0; | |
11049 | } | |
11050 | _ACEOF | |
7f947b68 CR |
11051 | if ac_fn_c_try_compile "$LINENO"; then : |
11052 | bash_cv_type_wchar_t=yes | |
c920c360 | 11053 | else |
7f947b68 CR |
11054 | bash_cv_type_wchar_t=no |
11055 | fi | |
11056 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11057 | fi | |
11058 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wchar_t" >&5 | |
11059 | $as_echo "$bash_cv_type_wchar_t" >&6; } | |
11060 | if test $bash_cv_type_wchar_t = yes; then | |
11061 | ||
11062 | $as_echo "#define HAVE_WCHAR_T 1" >>confdefs.h | |
2dead0c4 | 11063 | |
c920c360 | 11064 | fi |
5f8cde23 | 11065 | |
7f947b68 CR |
11066 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wctype_t in wctype.h" >&5 |
11067 | $as_echo_n "checking for wctype_t in wctype.h... " >&6; } | |
11068 | if ${bash_cv_type_wctype_t+:} false; then : | |
11069 | $as_echo_n "(cached) " >&6 | |
71412226 | 11070 | else |
7f947b68 CR |
11071 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
11072 | /* end confdefs.h. */ | |
11073 | #include <wctype.h> | |
11074 | int | |
11075 | main () | |
11076 | { | |
c920c360 | 11077 | |
7f947b68 CR |
11078 | wctype_t foo; |
11079 | foo = 0; | |
c920c360 | 11080 | |
7f947b68 CR |
11081 | ; |
11082 | return 0; | |
11083 | } | |
11084 | _ACEOF | |
11085 | if ac_fn_c_try_compile "$LINENO"; then : | |
11086 | bash_cv_type_wctype_t=yes | |
11087 | else | |
11088 | bash_cv_type_wctype_t=no | |
2dead0c4 | 11089 | fi |
abe2eb5b CR |
11090 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
11091 | fi | |
7f947b68 CR |
11092 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wctype_t" >&5 |
11093 | $as_echo "$bash_cv_type_wctype_t" >&6; } | |
11094 | if test $bash_cv_type_wctype_t = yes; then | |
2dead0c4 | 11095 | |
7f947b68 | 11096 | $as_echo "#define HAVE_WCTYPE_T 1" >>confdefs.h |
2dead0c4 | 11097 | |
abe2eb5b | 11098 | fi |
2dead0c4 | 11099 | |
7f947b68 CR |
11100 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wint_t in wctype.h" >&5 |
11101 | $as_echo_n "checking for wint_t in wctype.h... " >&6; } | |
11102 | if ${bash_cv_type_wint_t+:} false; then : | |
2dead0c4 | 11103 | $as_echo_n "(cached) " >&6 |
5f8cde23 | 11104 | else |
7f947b68 | 11105 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11106 | /* end confdefs.h. */ |
7f947b68 | 11107 | #include <wctype.h> |
abe2eb5b CR |
11108 | int |
11109 | main () | |
11110 | { | |
7f947b68 CR |
11111 | |
11112 | wint_t foo; | |
11113 | foo = 0; | |
11114 | ||
abe2eb5b CR |
11115 | ; |
11116 | return 0; | |
11117 | } | |
11118 | _ACEOF | |
7f947b68 CR |
11119 | if ac_fn_c_try_compile "$LINENO"; then : |
11120 | bash_cv_type_wint_t=yes | |
11121 | else | |
11122 | bash_cv_type_wint_t=no | |
11123 | fi | |
11124 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11125 | fi | |
11126 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_wint_t" >&5 | |
11127 | $as_echo "$bash_cv_type_wint_t" >&6; } | |
11128 | if test $bash_cv_type_wint_t = yes; then | |
11129 | ||
11130 | $as_echo "#define HAVE_WINT_T 1" >>confdefs.h | |
11131 | ||
11132 | fi | |
11133 | ||
11134 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for wcwidth broken with unicode combining characters" >&5 | |
11135 | $as_echo_n "checking for wcwidth broken with unicode combining characters... " >&6; } | |
11136 | if ${bash_cv_wcwidth_broken+:} false; then : | |
11137 | $as_echo_n "(cached) " >&6 | |
11138 | else | |
11139 | if test "$cross_compiling" = yes; then : | |
11140 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
11141 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
11142 | as_fn_error $? "cannot run test program while cross compiling | |
11143 | See \`config.log' for more details" "$LINENO" 5; } | |
11144 | else | |
11145 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11146 | /* end confdefs.h. */ |
7f947b68 CR |
11147 | |
11148 | #include <unistd.h> | |
11149 | #include <stdlib.h> | |
11150 | #include <stdio.h> | |
11151 | ||
11152 | #include <locale.h> | |
11153 | #include <wchar.h> | |
11154 | ||
11155 | main(c, v) | |
11156 | int c; | |
11157 | char **v; | |
abe2eb5b | 11158 | { |
7f947b68 CR |
11159 | int w; |
11160 | ||
11161 | setlocale(LC_ALL, "en_US.UTF-8"); | |
11162 | w = wcwidth (0x0301); | |
11163 | exit (w == 0); /* exit 0 if wcwidth broken */ | |
abe2eb5b | 11164 | } |
7f947b68 | 11165 | |
abe2eb5b | 11166 | _ACEOF |
7f947b68 CR |
11167 | if ac_fn_c_try_run "$LINENO"; then : |
11168 | bash_cv_wcwidth_broken=yes | |
2dead0c4 | 11169 | else |
7f947b68 CR |
11170 | bash_cv_wcwdith_broken=no |
11171 | fi | |
11172 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11173 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11174 | fi | |
e3db237e | 11175 | |
71412226 | 11176 | fi |
7f947b68 CR |
11177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcwidth_broken" >&5 |
11178 | $as_echo "$bash_cv_wcwidth_broken" >&6; } | |
11179 | if test $bash_cv_wcwidth_broken = yes; then | |
abe2eb5b | 11180 | |
7f947b68 CR |
11181 | $as_echo "#define WCWIDTH_BROKEN 1" >>confdefs.h |
11182 | ||
11183 | fi | |
2dead0c4 | 11184 | |
7f947b68 CR |
11185 | if test "$am_cv_func_iconv" = yes; then |
11186 | OLDLIBS="$LIBS" | |
11187 | LIBS="$LIBS $LIBICONV" | |
11188 | for ac_func in locale_charset | |
11189 | do : | |
11190 | ac_fn_c_check_func "$LINENO" "locale_charset" "ac_cv_func_locale_charset" | |
11191 | if test "x$ac_cv_func_locale_charset" = xyes; then : | |
11192 | cat >>confdefs.h <<_ACEOF | |
11193 | #define HAVE_LOCALE_CHARSET 1 | |
11194 | _ACEOF | |
2dead0c4 | 11195 | |
abe2eb5b | 11196 | fi |
7f947b68 | 11197 | done |
abe2eb5b | 11198 | |
7f947b68 | 11199 | LIBS="$OLDLIBS" |
abe2eb5b | 11200 | fi |
2dead0c4 | 11201 | |
5f8cde23 | 11202 | |
2dead0c4 | 11203 | |
7f947b68 CR |
11204 | if test "$opt_static_link" != yes; then |
11205 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 | |
11206 | $as_echo_n "checking for dlopen in -ldl... " >&6; } | |
11207 | if ${ac_cv_lib_dl_dlopen+:} false; then : | |
2dead0c4 CR |
11208 | $as_echo_n "(cached) " >&6 |
11209 | else | |
7f947b68 CR |
11210 | ac_check_lib_save_LIBS=$LIBS |
11211 | LIBS="-ldl $LIBS" | |
11212 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11213 | /* end confdefs.h. */ |
7f947b68 CR |
11214 | |
11215 | /* Override any GCC internal prototype to avoid an error. | |
11216 | Use char because int might match the return type of a GCC | |
11217 | builtin and then its argument prototype would still apply. */ | |
11218 | #ifdef __cplusplus | |
11219 | extern "C" | |
11220 | #endif | |
11221 | char dlopen (); | |
abe2eb5b CR |
11222 | int |
11223 | main () | |
11224 | { | |
7f947b68 | 11225 | return dlopen (); |
abe2eb5b CR |
11226 | ; |
11227 | return 0; | |
11228 | } | |
11229 | _ACEOF | |
7f947b68 CR |
11230 | if ac_fn_c_try_link "$LINENO"; then : |
11231 | ac_cv_lib_dl_dlopen=yes | |
2dead0c4 | 11232 | else |
7f947b68 CR |
11233 | ac_cv_lib_dl_dlopen=no |
11234 | fi | |
11235 | rm -f core conftest.err conftest.$ac_objext \ | |
11236 | conftest$ac_exeext conftest.$ac_ext | |
11237 | LIBS=$ac_check_lib_save_LIBS | |
c920c360 | 11238 | fi |
7f947b68 CR |
11239 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
11240 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } | |
11241 | if test "x$ac_cv_lib_dl_dlopen" = xyes; then : | |
11242 | cat >>confdefs.h <<_ACEOF | |
11243 | #define HAVE_LIBDL 1 | |
11244 | _ACEOF | |
71412226 | 11245 | |
7f947b68 CR |
11246 | LIBS="-ldl $LIBS" |
11247 | ||
11248 | fi | |
2dead0c4 | 11249 | |
7f947b68 CR |
11250 | for ac_func in dlopen dlclose dlsym |
11251 | do : | |
11252 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
11253 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
11254 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : | |
11255 | cat >>confdefs.h <<_ACEOF | |
11256 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
11257 | _ACEOF | |
2dead0c4 | 11258 | |
abe2eb5b | 11259 | fi |
7f947b68 | 11260 | done |
2dead0c4 | 11261 | |
abe2eb5b | 11262 | fi |
7f947b68 CR |
11263 | |
11264 | ac_fn_c_check_decl "$LINENO" "sys_siglist" "ac_cv_have_decl_sys_siglist" "#include <signal.h> | |
11265 | /* NetBSD declares sys_siglist in unistd.h. */ | |
11266 | #ifdef HAVE_UNISTD_H | |
11267 | # include <unistd.h> | |
11268 | #endif | |
11269 | ||
11270 | " | |
11271 | if test "x$ac_cv_have_decl_sys_siglist" = xyes; then : | |
11272 | ac_have_decl=1 | |
5f8cde23 | 11273 | else |
7f947b68 CR |
11274 | ac_have_decl=0 |
11275 | fi | |
c920c360 | 11276 | |
abe2eb5b | 11277 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 11278 | #define HAVE_DECL_SYS_SIGLIST $ac_have_decl |
abe2eb5b | 11279 | _ACEOF |
c920c360 | 11280 | |
c920c360 | 11281 | |
c920c360 | 11282 | |
7f947b68 | 11283 | if test "$ac_cv_func_inet_aton" != 'yes'; then |
5f8cde23 | 11284 | |
7f947b68 CR |
11285 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inet_aton" >&5 |
11286 | $as_echo_n "checking for inet_aton... " >&6; } | |
11287 | if ${bash_cv_func_inet_aton+:} false; then : | |
abe2eb5b CR |
11288 | $as_echo_n "(cached) " >&6 |
11289 | else | |
7f947b68 | 11290 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11291 | /* end confdefs.h. */ |
7f947b68 CR |
11292 | |
11293 | #include <sys/types.h> | |
11294 | #include <netinet/in.h> | |
11295 | #include <arpa/inet.h> | |
11296 | struct in_addr ap; | |
abe2eb5b CR |
11297 | int |
11298 | main () | |
11299 | { | |
7f947b68 | 11300 | inet_aton("127.0.0.1", &ap); |
abe2eb5b CR |
11301 | ; |
11302 | return 0; | |
11303 | } | |
71412226 | 11304 | _ACEOF |
7f947b68 CR |
11305 | if ac_fn_c_try_link "$LINENO"; then : |
11306 | bash_cv_func_inet_aton=yes | |
abe2eb5b | 11307 | else |
7f947b68 | 11308 | bash_cv_func_inet_aton=no |
abe2eb5b | 11309 | fi |
7f947b68 CR |
11310 | rm -f core conftest.err conftest.$ac_objext \ |
11311 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b | 11312 | fi |
7f947b68 CR |
11313 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_inet_aton" >&5 |
11314 | $as_echo "$bash_cv_func_inet_aton" >&6; } | |
11315 | if test $bash_cv_func_inet_aton = yes; then | |
11316 | $as_echo "#define HAVE_INET_ATON 1" >>confdefs.h | |
2dead0c4 | 11317 | |
71412226 | 11318 | else |
7f947b68 CR |
11319 | case " $LIBOBJS " in |
11320 | *" inet_aton.$ac_objext "* ) ;; | |
11321 | *) LIBOBJS="$LIBOBJS inet_aton.$ac_objext" | |
11322 | ;; | |
11323 | esac | |
e3db237e | 11324 | |
7f947b68 | 11325 | fi |
2dead0c4 | 11326 | |
5f8cde23 CR |
11327 | fi |
11328 | ||
7f947b68 CR |
11329 | case "$host_os" in |
11330 | irix4*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpwent in -lsun" >&5 | |
11331 | $as_echo_n "checking for getpwent in -lsun... " >&6; } | |
11332 | if ${ac_cv_lib_sun_getpwent+:} false; then : | |
abe2eb5b | 11333 | $as_echo_n "(cached) " >&6 |
2dead0c4 | 11334 | else |
7f947b68 CR |
11335 | ac_check_lib_save_LIBS=$LIBS |
11336 | LIBS="-lsun $LIBS" | |
11337 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11338 | /* end confdefs.h. */ |
7f947b68 CR |
11339 | |
11340 | /* Override any GCC internal prototype to avoid an error. | |
11341 | Use char because int might match the return type of a GCC | |
11342 | builtin and then its argument prototype would still apply. */ | |
11343 | #ifdef __cplusplus | |
11344 | extern "C" | |
11345 | #endif | |
11346 | char getpwent (); | |
abe2eb5b CR |
11347 | int |
11348 | main () | |
11349 | { | |
7f947b68 | 11350 | return getpwent (); |
abe2eb5b CR |
11351 | ; |
11352 | return 0; | |
11353 | } | |
11354 | _ACEOF | |
7f947b68 CR |
11355 | if ac_fn_c_try_link "$LINENO"; then : |
11356 | ac_cv_lib_sun_getpwent=yes | |
11357 | else | |
11358 | ac_cv_lib_sun_getpwent=no | |
11359 | fi | |
11360 | rm -f core conftest.err conftest.$ac_objext \ | |
11361 | conftest$ac_exeext conftest.$ac_ext | |
11362 | LIBS=$ac_check_lib_save_LIBS | |
11363 | fi | |
11364 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_sun_getpwent" >&5 | |
11365 | $as_echo "$ac_cv_lib_sun_getpwent" >&6; } | |
11366 | if test "x$ac_cv_lib_sun_getpwent" = xyes; then : | |
11367 | cat >>confdefs.h <<_ACEOF | |
11368 | #define HAVE_LIBSUN 1 | |
abe2eb5b | 11369 | _ACEOF |
7f947b68 CR |
11370 | |
11371 | LIBS="-lsun $LIBS" | |
11372 | ||
11373 | fi | |
11374 | ;; | |
11375 | esac | |
11376 | ||
11377 | if test "$ac_cv_func_getpeername" = no; then | |
11378 | ||
11379 | if test "X$bash_cv_have_socklib" = "X"; then | |
11380 | _bash_needmsg= | |
11381 | else | |
11382 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket library" >&5 | |
11383 | $as_echo_n "checking for socket library... " >&6; } | |
11384 | _bash_needmsg=yes | |
11385 | fi | |
11386 | if ${bash_cv_have_socklib+:} false; then : | |
11387 | $as_echo_n "(cached) " >&6 | |
11388 | else | |
11389 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpeername in -lsocket" >&5 | |
11390 | $as_echo_n "checking for getpeername in -lsocket... " >&6; } | |
11391 | if ${ac_cv_lib_socket_getpeername+:} false; then : | |
11392 | $as_echo_n "(cached) " >&6 | |
11393 | else | |
11394 | ac_check_lib_save_LIBS=$LIBS | |
11395 | LIBS="-lsocket -lnsl $LIBS" | |
11396 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11397 | /* end confdefs.h. */ |
7f947b68 CR |
11398 | |
11399 | /* Override any GCC internal prototype to avoid an error. | |
11400 | Use char because int might match the return type of a GCC | |
11401 | builtin and then its argument prototype would still apply. */ | |
11402 | #ifdef __cplusplus | |
11403 | extern "C" | |
11404 | #endif | |
11405 | char getpeername (); | |
abe2eb5b CR |
11406 | int |
11407 | main () | |
11408 | { | |
7f947b68 | 11409 | return getpeername (); |
abe2eb5b CR |
11410 | ; |
11411 | return 0; | |
11412 | } | |
e3db237e | 11413 | _ACEOF |
7f947b68 CR |
11414 | if ac_fn_c_try_link "$LINENO"; then : |
11415 | ac_cv_lib_socket_getpeername=yes | |
abe2eb5b | 11416 | else |
7f947b68 | 11417 | ac_cv_lib_socket_getpeername=no |
c920c360 | 11418 | fi |
7f947b68 CR |
11419 | rm -f core conftest.err conftest.$ac_objext \ |
11420 | conftest$ac_exeext conftest.$ac_ext | |
11421 | LIBS=$ac_check_lib_save_LIBS | |
11422 | fi | |
11423 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_getpeername" >&5 | |
11424 | $as_echo "$ac_cv_lib_socket_getpeername" >&6; } | |
11425 | if test "x$ac_cv_lib_socket_getpeername" = xyes; then : | |
11426 | bash_cv_have_socklib=yes | |
abe2eb5b | 11427 | else |
7f947b68 | 11428 | bash_cv_have_socklib=no |
abe2eb5b | 11429 | fi |
2dead0c4 | 11430 | |
abe2eb5b | 11431 | fi |
c920c360 | 11432 | |
7f947b68 CR |
11433 | if test "X$_bash_needmsg" = Xyes; then |
11434 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_socklib" >&5 | |
11435 | $as_echo "$bash_cv_have_socklib" >&6; } | |
11436 | _bash_needmsg= | |
2dead0c4 | 11437 | fi |
7f947b68 CR |
11438 | if test $bash_cv_have_socklib = yes; then |
11439 | # check for libnsl, add it to LIBS if present | |
11440 | if test "X$bash_cv_have_libnsl" = "X"; then | |
11441 | _bash_needmsg= | |
11442 | else | |
11443 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libnsl" >&5 | |
11444 | $as_echo_n "checking for libnsl... " >&6; } | |
11445 | _bash_needmsg=yes | |
11446 | fi | |
11447 | if ${bash_cv_have_libnsl+:} false; then : | |
abe2eb5b | 11448 | $as_echo_n "(cached) " >&6 |
2dead0c4 | 11449 | else |
7f947b68 CR |
11450 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_open in -lnsl" >&5 |
11451 | $as_echo_n "checking for t_open in -lnsl... " >&6; } | |
11452 | if ${ac_cv_lib_nsl_t_open+:} false; then : | |
11453 | $as_echo_n "(cached) " >&6 | |
11454 | else | |
11455 | ac_check_lib_save_LIBS=$LIBS | |
11456 | LIBS="-lnsl $LIBS" | |
11457 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11458 | /* end confdefs.h. */ |
7f947b68 CR |
11459 | |
11460 | /* Override any GCC internal prototype to avoid an error. | |
11461 | Use char because int might match the return type of a GCC | |
11462 | builtin and then its argument prototype would still apply. */ | |
11463 | #ifdef __cplusplus | |
11464 | extern "C" | |
11465 | #endif | |
11466 | char t_open (); | |
abe2eb5b CR |
11467 | int |
11468 | main () | |
11469 | { | |
7f947b68 | 11470 | return t_open (); |
abe2eb5b CR |
11471 | ; |
11472 | return 0; | |
11473 | } | |
7610e0c5 | 11474 | _ACEOF |
7f947b68 CR |
11475 | if ac_fn_c_try_link "$LINENO"; then : |
11476 | ac_cv_lib_nsl_t_open=yes | |
abe2eb5b | 11477 | else |
7f947b68 CR |
11478 | ac_cv_lib_nsl_t_open=no |
11479 | fi | |
11480 | rm -f core conftest.err conftest.$ac_objext \ | |
11481 | conftest$ac_exeext conftest.$ac_ext | |
11482 | LIBS=$ac_check_lib_save_LIBS | |
11483 | fi | |
11484 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_t_open" >&5 | |
11485 | $as_echo "$ac_cv_lib_nsl_t_open" >&6; } | |
11486 | if test "x$ac_cv_lib_nsl_t_open" = xyes; then : | |
11487 | bash_cv_have_libnsl=yes | |
11488 | else | |
11489 | bash_cv_have_libnsl=no | |
11490 | fi | |
2dead0c4 CR |
11491 | |
11492 | fi | |
11493 | ||
7f947b68 CR |
11494 | if test "X$_bash_needmsg" = Xyes; then |
11495 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_libnsl" >&5 | |
11496 | $as_echo "$bash_cv_have_libnsl" >&6; } | |
11497 | _bash_needmsg= | |
11498 | fi | |
11499 | if test $bash_cv_have_libnsl = yes; then | |
11500 | LIBS="-lsocket -lnsl $LIBS" | |
11501 | else | |
11502 | LIBS="-lsocket $LIBS" | |
11503 | fi | |
11504 | $as_echo "#define HAVE_LIBSOCKET 1" >>confdefs.h | |
e3db237e | 11505 | |
7f947b68 | 11506 | $as_echo "#define HAVE_GETPEERNAME 1" >>confdefs.h |
2dead0c4 | 11507 | |
7610e0c5 | 11508 | fi |
2dead0c4 | 11509 | |
7610e0c5 | 11510 | fi |
7f947b68 CR |
11511 | if test "$ac_cv_func_gethostbyname" = no; then |
11512 | if test "X$bash_cv_have_gethostbyname" = "X"; then | |
11513 | _bash_needmsg=yes | |
2dead0c4 | 11514 | else |
7f947b68 CR |
11515 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 |
11516 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11517 | _bash_needmsg= | |
c920c360 | 11518 | fi |
7f947b68 | 11519 | if ${bash_cv_have_gethostbyname+:} false; then : |
abe2eb5b | 11520 | $as_echo_n "(cached) " >&6 |
7610e0c5 | 11521 | else |
7f947b68 | 11522 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11523 | /* end confdefs.h. */ |
7f947b68 | 11524 | #include <netdb.h> |
abe2eb5b CR |
11525 | int |
11526 | main () | |
11527 | { | |
7f947b68 CR |
11528 | struct hostent *hp; |
11529 | hp = gethostbyname("localhost"); | |
11530 | ||
abe2eb5b CR |
11531 | ; |
11532 | return 0; | |
11533 | } | |
11534 | _ACEOF | |
7f947b68 CR |
11535 | if ac_fn_c_try_link "$LINENO"; then : |
11536 | bash_cv_have_gethostbyname=yes | |
abe2eb5b | 11537 | else |
7f947b68 | 11538 | bash_cv_have_gethostbyname=no |
2dead0c4 | 11539 | fi |
7f947b68 CR |
11540 | rm -f core conftest.err conftest.$ac_objext \ |
11541 | conftest$ac_exeext conftest.$ac_ext | |
7610e0c5 | 11542 | |
7f947b68 | 11543 | fi |
7610e0c5 | 11544 | |
7f947b68 CR |
11545 | if test "X$_bash_needmsg" = Xyes; then |
11546 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in socket library" >&5 | |
11547 | $as_echo_n "checking for gethostbyname in socket library... " >&6; } | |
11548 | fi | |
11549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_gethostbyname" >&5 | |
11550 | $as_echo "$bash_cv_have_gethostbyname" >&6; } | |
11551 | if test "$bash_cv_have_gethostbyname" = yes; then | |
11552 | $as_echo "#define HAVE_GETHOSTBYNAME 1" >>confdefs.h | |
7610e0c5 | 11553 | |
2dead0c4 | 11554 | fi |
7610e0c5 | 11555 | |
2dead0c4 | 11556 | fi |
7f947b68 CR |
11557 | |
11558 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 | |
11559 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
11560 | if ${ac_cv_type_uid_t+:} false; then : | |
11561 | $as_echo_n "(cached) " >&6 | |
7610e0c5 | 11562 | else |
7f947b68 CR |
11563 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
11564 | /* end confdefs.h. */ | |
11565 | #include <sys/types.h> | |
e3db237e | 11566 | |
2dead0c4 | 11567 | _ACEOF |
7f947b68 CR |
11568 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11569 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
11570 | ac_cv_type_uid_t=yes | |
11571 | else | |
11572 | ac_cv_type_uid_t=no | |
11573 | fi | |
11574 | rm -f conftest* | |
2dead0c4 | 11575 | |
7610e0c5 | 11576 | fi |
7f947b68 CR |
11577 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
11578 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
11579 | if test $ac_cv_type_uid_t = no; then | |
7610e0c5 | 11580 | |
7f947b68 CR |
11581 | $as_echo "#define uid_t int" >>confdefs.h |
11582 | ||
11583 | ||
11584 | $as_echo "#define gid_t int" >>confdefs.h | |
11585 | ||
11586 | fi | |
11587 | ||
11588 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking type of array argument to getgroups" >&5 | |
11589 | $as_echo_n "checking type of array argument to getgroups... " >&6; } | |
11590 | if ${ac_cv_type_getgroups+:} false; then : | |
abe2eb5b CR |
11591 | $as_echo_n "(cached) " >&6 |
11592 | else | |
7f947b68 CR |
11593 | if test "$cross_compiling" = yes; then : |
11594 | ac_cv_type_getgroups=cross | |
11595 | else | |
11596 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11597 | /* end confdefs.h. */ |
7f947b68 | 11598 | /* Thanks to Mike Rendell for this test. */ |
abe2eb5b | 11599 | $ac_includes_default |
7f947b68 CR |
11600 | #define NGID 256 |
11601 | #undef MAX | |
11602 | #define MAX(x, y) ((x) > (y) ? (x) : (y)) | |
11603 | ||
abe2eb5b CR |
11604 | int |
11605 | main () | |
11606 | { | |
7f947b68 CR |
11607 | gid_t gidset[NGID]; |
11608 | int i, n; | |
11609 | union { gid_t gval; long int lval; } val; | |
11610 | ||
11611 | val.lval = -1; | |
11612 | for (i = 0; i < NGID; i++) | |
11613 | gidset[i] = val.gval; | |
11614 | n = getgroups (sizeof (gidset) / MAX (sizeof (int), sizeof (gid_t)) - 1, | |
11615 | gidset); | |
11616 | /* Exit non-zero if getgroups seems to require an array of ints. This | |
11617 | happens when gid_t is short int but getgroups modifies an array | |
11618 | of ints. */ | |
11619 | return n > 0 && gidset[n] != val.gval; | |
abe2eb5b CR |
11620 | } |
11621 | _ACEOF | |
7f947b68 CR |
11622 | if ac_fn_c_try_run "$LINENO"; then : |
11623 | ac_cv_type_getgroups=gid_t | |
11624 | else | |
11625 | ac_cv_type_getgroups=int | |
11626 | fi | |
11627 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
11628 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
11629 | fi | |
11630 | ||
11631 | if test $ac_cv_type_getgroups = cross; then | |
11632 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11633 | /* end confdefs.h. */ |
7f947b68 CR |
11634 | #include <unistd.h> |
11635 | ||
2dead0c4 | 11636 | _ACEOF |
7f947b68 CR |
11637 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11638 | $EGREP "getgroups.*int.*gid_t" >/dev/null 2>&1; then : | |
11639 | ac_cv_type_getgroups=gid_t | |
abe2eb5b | 11640 | else |
7f947b68 CR |
11641 | ac_cv_type_getgroups=int |
11642 | fi | |
11643 | rm -f conftest* | |
e3db237e | 11644 | |
71412226 | 11645 | fi |
7f947b68 CR |
11646 | fi |
11647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_getgroups" >&5 | |
11648 | $as_echo "$ac_cv_type_getgroups" >&6; } | |
71412226 | 11649 | |
7f947b68 CR |
11650 | cat >>confdefs.h <<_ACEOF |
11651 | #define GETGROUPS_T $ac_cv_type_getgroups | |
11652 | _ACEOF | |
2dead0c4 | 11653 | |
c920c360 | 11654 | |
7f947b68 CR |
11655 | ac_fn_c_check_type "$LINENO" "off_t" "ac_cv_type_off_t" "$ac_includes_default" |
11656 | if test "x$ac_cv_type_off_t" = xyes; then : | |
71412226 | 11657 | |
71412226 | 11658 | else |
c920c360 | 11659 | |
2dead0c4 | 11660 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 11661 | #define off_t long int |
e3db237e | 11662 | _ACEOF |
7610e0c5 | 11663 | |
2dead0c4 | 11664 | fi |
5f8cde23 | 11665 | |
7f947b68 CR |
11666 | ac_fn_c_check_type "$LINENO" "mode_t" "ac_cv_type_mode_t" "$ac_includes_default" |
11667 | if test "x$ac_cv_type_mode_t" = xyes; then : | |
71412226 | 11668 | |
7f947b68 | 11669 | else |
e3db237e | 11670 | |
7f947b68 CR |
11671 | cat >>confdefs.h <<_ACEOF |
11672 | #define mode_t int | |
11673 | _ACEOF | |
71412226 | 11674 | |
7f947b68 CR |
11675 | fi |
11676 | ||
11677 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uid_t in sys/types.h" >&5 | |
11678 | $as_echo_n "checking for uid_t in sys/types.h... " >&6; } | |
11679 | if ${ac_cv_type_uid_t+:} false; then : | |
abe2eb5b CR |
11680 | $as_echo_n "(cached) " >&6 |
11681 | else | |
7f947b68 | 11682 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11683 | /* end confdefs.h. */ |
7f947b68 CR |
11684 | #include <sys/types.h> |
11685 | ||
abe2eb5b | 11686 | _ACEOF |
7f947b68 CR |
11687 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
11688 | $EGREP "uid_t" >/dev/null 2>&1; then : | |
11689 | ac_cv_type_uid_t=yes | |
abe2eb5b | 11690 | else |
7f947b68 CR |
11691 | ac_cv_type_uid_t=no |
11692 | fi | |
11693 | rm -f conftest* | |
71412226 | 11694 | |
2dead0c4 | 11695 | fi |
7f947b68 CR |
11696 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_uid_t" >&5 |
11697 | $as_echo "$ac_cv_type_uid_t" >&6; } | |
11698 | if test $ac_cv_type_uid_t = no; then | |
2dead0c4 | 11699 | |
7f947b68 | 11700 | $as_echo "#define uid_t int" >>confdefs.h |
e3db237e | 11701 | |
e3db237e | 11702 | |
7f947b68 | 11703 | $as_echo "#define gid_t int" >>confdefs.h |
5f8cde23 | 11704 | |
abe2eb5b | 11705 | fi |
7f947b68 CR |
11706 | |
11707 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" | |
11708 | if test "x$ac_cv_type_pid_t" = xyes; then : | |
11709 | ||
2dead0c4 | 11710 | else |
e3db237e | 11711 | |
2dead0c4 | 11712 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 11713 | #define pid_t int |
2dead0c4 | 11714 | _ACEOF |
5f8cde23 | 11715 | |
c920c360 | 11716 | fi |
e3db237e | 11717 | |
7f947b68 CR |
11718 | ac_fn_c_check_type "$LINENO" "size_t" "ac_cv_type_size_t" "$ac_includes_default" |
11719 | if test "x$ac_cv_type_size_t" = xyes; then : | |
11720 | ||
2dead0c4 | 11721 | else |
7f947b68 CR |
11722 | |
11723 | cat >>confdefs.h <<_ACEOF | |
11724 | #define size_t unsigned int | |
abe2eb5b | 11725 | _ACEOF |
c920c360 | 11726 | |
2dead0c4 | 11727 | fi |
c920c360 | 11728 | |
7f947b68 CR |
11729 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
11730 | if test "x$ac_cv_type_ssize_t" = xyes; then : | |
11731 | ||
2dead0c4 CR |
11732 | else |
11733 | ||
7f947b68 CR |
11734 | cat >>confdefs.h <<_ACEOF |
11735 | #define ssize_t int | |
11736 | _ACEOF | |
c920c360 | 11737 | |
7610e0c5 | 11738 | fi |
c920c360 | 11739 | |
7f947b68 CR |
11740 | ac_fn_c_check_type "$LINENO" "time_t" "ac_cv_type_time_t" "$ac_includes_default" |
11741 | if test "x$ac_cv_type_time_t" = xyes; then : | |
11742 | ||
ccc6cda3 | 11743 | else |
2dead0c4 CR |
11744 | |
11745 | cat >>confdefs.h <<_ACEOF | |
7f947b68 | 11746 | #define time_t long |
7610e0c5 | 11747 | _ACEOF |
e3db237e | 11748 | |
c920c360 | 11749 | fi |
e3db237e | 11750 | |
7f947b68 CR |
11751 | |
11752 | ||
11753 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long" >&5 | |
11754 | $as_echo_n "checking for long long... " >&6; } | |
11755 | if ${bash_cv_type_long_long+:} false; then : | |
abe2eb5b CR |
11756 | $as_echo_n "(cached) " >&6 |
11757 | else | |
7f947b68 | 11758 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11759 | /* end confdefs.h. */ |
7f947b68 CR |
11760 | |
11761 | long long ll = 1; int i = 63; | |
abe2eb5b CR |
11762 | int |
11763 | main () | |
11764 | { | |
7f947b68 CR |
11765 | |
11766 | long long llm = (long long) -1; | |
11767 | return ll << i | ll >> i | llm / ll | llm % ll; | |
11768 | ||
abe2eb5b CR |
11769 | ; |
11770 | return 0; | |
11771 | } | |
11772 | _ACEOF | |
7f947b68 CR |
11773 | if ac_fn_c_try_link "$LINENO"; then : |
11774 | bash_cv_type_long_long='long long' | |
11775 | else | |
11776 | bash_cv_type_long_long='long' | |
11777 | fi | |
11778 | rm -f core conftest.err conftest.$ac_objext \ | |
11779 | conftest$ac_exeext conftest.$ac_ext | |
11780 | fi | |
11781 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_long_long" >&5 | |
11782 | $as_echo "$bash_cv_type_long_long" >&6; } | |
11783 | if test "$bash_cv_type_long_long" = 'long long'; then | |
11784 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h | |
11785 | ||
11786 | fi | |
11787 | ||
11788 | ||
11789 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long" >&5 | |
11790 | $as_echo_n "checking for unsigned long long... " >&6; } | |
11791 | if ${bash_cv_type_unsigned_long_long+:} false; then : | |
11792 | $as_echo_n "(cached) " >&6 | |
11793 | else | |
11794 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11795 | /* end confdefs.h. */ |
7f947b68 CR |
11796 | |
11797 | unsigned long long ull = 1; int i = 63; | |
abe2eb5b CR |
11798 | int |
11799 | main () | |
11800 | { | |
7f947b68 CR |
11801 | |
11802 | unsigned long long ullmax = (unsigned long long) -1; | |
11803 | return ull << i | ull >> i | ullmax / ull | ullmax % ull; | |
11804 | ||
abe2eb5b CR |
11805 | ; |
11806 | return 0; | |
11807 | } | |
11808 | _ACEOF | |
7f947b68 CR |
11809 | if ac_fn_c_try_link "$LINENO"; then : |
11810 | bash_cv_type_unsigned_long_long='unsigned long long' | |
abe2eb5b | 11811 | else |
7f947b68 | 11812 | bash_cv_type_unsigned_long_long='unsigned long' |
c920c360 | 11813 | fi |
7f947b68 CR |
11814 | rm -f core conftest.err conftest.$ac_objext \ |
11815 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b | 11816 | fi |
7f947b68 CR |
11817 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_unsigned_long_long" >&5 |
11818 | $as_echo "$bash_cv_type_unsigned_long_long" >&6; } | |
11819 | if test "$bash_cv_type_unsigned_long_long" = 'unsigned long long'; then | |
11820 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG 1" >>confdefs.h | |
2dead0c4 | 11821 | |
abe2eb5b | 11822 | fi |
f73dda09 | 11823 | |
a82a04b3 | 11824 | |
7f947b68 CR |
11825 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking return type of signal handlers" >&5 |
11826 | $as_echo_n "checking return type of signal handlers... " >&6; } | |
11827 | if ${ac_cv_type_signal+:} false; then : | |
abe2eb5b CR |
11828 | $as_echo_n "(cached) " >&6 |
11829 | else | |
7f947b68 | 11830 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 11831 | /* end confdefs.h. */ |
7f947b68 CR |
11832 | #include <sys/types.h> |
11833 | #include <signal.h> | |
11834 | ||
abe2eb5b CR |
11835 | int |
11836 | main () | |
11837 | { | |
7f947b68 | 11838 | return *(signal (0, 0)) (0) == 1; |
abe2eb5b CR |
11839 | ; |
11840 | return 0; | |
11841 | } | |
11842 | _ACEOF | |
7f947b68 CR |
11843 | if ac_fn_c_try_compile "$LINENO"; then : |
11844 | ac_cv_type_signal=int | |
11845 | else | |
11846 | ac_cv_type_signal=void | |
11847 | fi | |
11848 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
11849 | fi | |
11850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_signal" >&5 | |
11851 | $as_echo "$ac_cv_type_signal" >&6; } | |
11852 | ||
11853 | cat >>confdefs.h <<_ACEOF | |
11854 | #define RETSIGTYPE $ac_cv_type_signal | |
7610e0c5 | 11855 | _ACEOF |
7f947b68 CR |
11856 | |
11857 | ||
11858 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sig_atomic_t in signal.h" >&5 | |
11859 | $as_echo_n "checking for sig_atomic_t in signal.h... " >&6; } | |
11860 | if ${ac_cv_have_sig_atomic_t+:} false; then : | |
11861 | $as_echo_n "(cached) " >&6 | |
11862 | else | |
11863 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 11864 | /* end confdefs.h. */ |
7f947b68 CR |
11865 | |
11866 | #include <signal.h> | |
11867 | ||
abe2eb5b CR |
11868 | int |
11869 | main () | |
11870 | { | |
7f947b68 | 11871 | sig_atomic_t x; |
abe2eb5b CR |
11872 | ; |
11873 | return 0; | |
11874 | } | |
11875 | _ACEOF | |
7f947b68 CR |
11876 | if ac_fn_c_try_link "$LINENO"; then : |
11877 | ac_cv_have_sig_atomic_t=yes | |
2dead0c4 | 11878 | else |
7f947b68 | 11879 | ac_cv_have_sig_atomic_t=no |
7610e0c5 | 11880 | fi |
7f947b68 CR |
11881 | rm -f core conftest.err conftest.$ac_objext \ |
11882 | conftest$ac_exeext conftest.$ac_ext | |
abe2eb5b | 11883 | fi |
7f947b68 CR |
11884 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sig_atomic_t" >&5 |
11885 | $as_echo "$ac_cv_have_sig_atomic_t" >&6; } | |
11886 | if test "$ac_cv_have_sig_atomic_t" = "no" | |
11887 | then | |
11888 | ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "$ac_includes_default" | |
11889 | if test "x$ac_cv_type_sig_atomic_t" = xyes; then : | |
11890 | ||
c920c360 | 11891 | else |
e3db237e | 11892 | |
2dead0c4 | 11893 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 11894 | #define sig_atomic_t int |
2dead0c4 | 11895 | _ACEOF |
e3db237e | 11896 | |
c920c360 | 11897 | fi |
c920c360 CR |
11898 | |
11899 | fi | |
11900 | ||
11901 | ||
7f947b68 CR |
11902 | # The cast to long int works around a bug in the HP C Compiler |
11903 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
11904 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
11905 | # This bug is HP SR number 8606223364. | |
11906 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char" >&5 | |
11907 | $as_echo_n "checking size of char... " >&6; } | |
11908 | if ${ac_cv_sizeof_char+:} false; then : | |
c920c360 CR |
11909 | $as_echo_n "(cached) " >&6 |
11910 | else | |
7f947b68 | 11911 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char))" "ac_cv_sizeof_char" "$ac_includes_default"; then : |
2dead0c4 | 11912 | |
7f947b68 CR |
11913 | else |
11914 | if test "$ac_cv_type_char" = yes; then | |
11915 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
11916 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
11917 | as_fn_error 77 "cannot compute sizeof (char) | |
11918 | See \`config.log' for more details" "$LINENO" 5; } | |
11919 | else | |
11920 | ac_cv_sizeof_char=0 | |
11921 | fi | |
11922 | fi | |
2dead0c4 | 11923 | |
7f947b68 CR |
11924 | fi |
11925 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char" >&5 | |
11926 | $as_echo "$ac_cv_sizeof_char" >&6; } | |
2dead0c4 | 11927 | |
2dead0c4 | 11928 | |
2dead0c4 | 11929 | |
7f947b68 CR |
11930 | cat >>confdefs.h <<_ACEOF |
11931 | #define SIZEOF_CHAR $ac_cv_sizeof_char | |
5e4a95c7 | 11932 | _ACEOF |
7f947b68 CR |
11933 | |
11934 | ||
11935 | # The cast to long int works around a bug in the HP C Compiler | |
11936 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
11937 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
11938 | # This bug is HP SR number 8606223364. | |
11939 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 | |
11940 | $as_echo_n "checking size of short... " >&6; } | |
11941 | if ${ac_cv_sizeof_short+:} false; then : | |
11942 | $as_echo_n "(cached) " >&6 | |
f73dda09 | 11943 | else |
7f947b68 | 11944 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : |
abe2eb5b | 11945 | |
7f947b68 CR |
11946 | else |
11947 | if test "$ac_cv_type_short" = yes; then | |
11948 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
11949 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
11950 | as_fn_error 77 "cannot compute sizeof (short) | |
11951 | See \`config.log' for more details" "$LINENO" 5; } | |
11952 | else | |
11953 | ac_cv_sizeof_short=0 | |
11954 | fi | |
c920c360 | 11955 | fi |
abe2eb5b | 11956 | |
c920c360 | 11957 | fi |
7f947b68 CR |
11958 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
11959 | $as_echo "$ac_cv_sizeof_short" >&6; } | |
7610e0c5 | 11960 | |
e3db237e | 11961 | |
7f947b68 CR |
11962 | |
11963 | cat >>confdefs.h <<_ACEOF | |
11964 | #define SIZEOF_SHORT $ac_cv_sizeof_short | |
11965 | _ACEOF | |
7610e0c5 | 11966 | |
2dead0c4 | 11967 | |
7f947b68 CR |
11968 | # The cast to long int works around a bug in the HP C Compiler |
11969 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
11970 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
11971 | # This bug is HP SR number 8606223364. | |
11972 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 | |
11973 | $as_echo_n "checking size of int... " >&6; } | |
11974 | if ${ac_cv_sizeof_int+:} false; then : | |
2dead0c4 CR |
11975 | $as_echo_n "(cached) " >&6 |
11976 | else | |
7f947b68 CR |
11977 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : |
11978 | ||
2dead0c4 | 11979 | else |
7f947b68 CR |
11980 | if test "$ac_cv_type_int" = yes; then |
11981 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
11982 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
11983 | as_fn_error 77 "cannot compute sizeof (int) | |
11984 | See \`config.log' for more details" "$LINENO" 5; } | |
11985 | else | |
11986 | ac_cv_sizeof_int=0 | |
11987 | fi | |
2dead0c4 | 11988 | fi |
7f947b68 | 11989 | |
2dead0c4 | 11990 | fi |
7f947b68 CR |
11991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
11992 | $as_echo "$ac_cv_sizeof_int" >&6; } | |
2dead0c4 | 11993 | |
7f947b68 CR |
11994 | |
11995 | ||
11996 | cat >>confdefs.h <<_ACEOF | |
11997 | #define SIZEOF_INT $ac_cv_sizeof_int | |
abe2eb5b | 11998 | _ACEOF |
7610e0c5 | 11999 | |
7610e0c5 | 12000 | |
7f947b68 CR |
12001 | # The cast to long int works around a bug in the HP C Compiler |
12002 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12003 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12004 | # This bug is HP SR number 8606223364. | |
12005 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 | |
12006 | $as_echo_n "checking size of long... " >&6; } | |
12007 | if ${ac_cv_sizeof_long+:} false; then : | |
c920c360 CR |
12008 | $as_echo_n "(cached) " >&6 |
12009 | else | |
7f947b68 | 12010 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : |
2dead0c4 | 12011 | |
7f947b68 CR |
12012 | else |
12013 | if test "$ac_cv_type_long" = yes; then | |
12014 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12015 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12016 | as_fn_error 77 "cannot compute sizeof (long) | |
12017 | See \`config.log' for more details" "$LINENO" 5; } | |
12018 | else | |
12019 | ac_cv_sizeof_long=0 | |
12020 | fi | |
12021 | fi | |
2dead0c4 | 12022 | |
7f947b68 CR |
12023 | fi |
12024 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 | |
12025 | $as_echo "$ac_cv_sizeof_long" >&6; } | |
12026 | ||
12027 | ||
12028 | ||
12029 | cat >>confdefs.h <<_ACEOF | |
12030 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
7610e0c5 | 12031 | _ACEOF |
7f947b68 CR |
12032 | |
12033 | ||
12034 | # The cast to long int works around a bug in the HP C Compiler | |
12035 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12036 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12037 | # This bug is HP SR number 8606223364. | |
12038 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char *" >&5 | |
12039 | $as_echo_n "checking size of char *... " >&6; } | |
12040 | if ${ac_cv_sizeof_char_p+:} false; then : | |
12041 | $as_echo_n "(cached) " >&6 | |
7610e0c5 | 12042 | else |
7f947b68 | 12043 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char *))" "ac_cv_sizeof_char_p" "$ac_includes_default"; then : |
abe2eb5b | 12044 | |
7f947b68 CR |
12045 | else |
12046 | if test "$ac_cv_type_char_p" = yes; then | |
12047 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12048 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12049 | as_fn_error 77 "cannot compute sizeof (char *) | |
12050 | See \`config.log' for more details" "$LINENO" 5; } | |
12051 | else | |
12052 | ac_cv_sizeof_char_p=0 | |
12053 | fi | |
c920c360 | 12054 | fi |
abe2eb5b | 12055 | |
c920c360 | 12056 | fi |
7f947b68 CR |
12057 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char_p" >&5 |
12058 | $as_echo "$ac_cv_sizeof_char_p" >&6; } | |
12059 | ||
12060 | ||
12061 | ||
12062 | cat >>confdefs.h <<_ACEOF | |
12063 | #define SIZEOF_CHAR_P $ac_cv_sizeof_char_p | |
abe2eb5b | 12064 | _ACEOF |
7610e0c5 | 12065 | |
7f947b68 CR |
12066 | |
12067 | # The cast to long int works around a bug in the HP C Compiler | |
12068 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12069 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12070 | # This bug is HP SR number 8606223364. | |
12071 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of double" >&5 | |
12072 | $as_echo_n "checking size of double... " >&6; } | |
12073 | if ${ac_cv_sizeof_double+:} false; then : | |
12074 | $as_echo_n "(cached) " >&6 | |
12075 | else | |
12076 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (double))" "ac_cv_sizeof_double" "$ac_includes_default"; then : | |
12077 | ||
12078 | else | |
12079 | if test "$ac_cv_type_double" = yes; then | |
12080 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12081 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12082 | as_fn_error 77 "cannot compute sizeof (double) | |
12083 | See \`config.log' for more details" "$LINENO" 5; } | |
12084 | else | |
12085 | ac_cv_sizeof_double=0 | |
12086 | fi | |
7610e0c5 CR |
12087 | fi |
12088 | ||
2dead0c4 | 12089 | fi |
7f947b68 CR |
12090 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_double" >&5 |
12091 | $as_echo "$ac_cv_sizeof_double" >&6; } | |
c920c360 CR |
12092 | |
12093 | ||
7f947b68 CR |
12094 | |
12095 | cat >>confdefs.h <<_ACEOF | |
12096 | #define SIZEOF_DOUBLE $ac_cv_sizeof_double | |
12097 | _ACEOF | |
12098 | ||
12099 | ||
12100 | # The cast to long int works around a bug in the HP C Compiler | |
12101 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
12102 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
12103 | # This bug is HP SR number 8606223364. | |
12104 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 | |
12105 | $as_echo_n "checking size of long long... " >&6; } | |
12106 | if ${ac_cv_sizeof_long_long+:} false; then : | |
c920c360 | 12107 | $as_echo_n "(cached) " >&6 |
7610e0c5 | 12108 | else |
7f947b68 | 12109 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : |
2dead0c4 CR |
12110 | |
12111 | else | |
7f947b68 CR |
12112 | if test "$ac_cv_type_long_long" = yes; then |
12113 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
12114 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
12115 | as_fn_error 77 "cannot compute sizeof (long long) | |
12116 | See \`config.log' for more details" "$LINENO" 5; } | |
12117 | else | |
12118 | ac_cv_sizeof_long_long=0 | |
12119 | fi | |
12120 | fi | |
2dead0c4 | 12121 | |
7f947b68 CR |
12122 | fi |
12123 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 | |
12124 | $as_echo "$ac_cv_sizeof_long_long" >&6; } | |
2dead0c4 | 12125 | |
2dead0c4 | 12126 | |
7610e0c5 | 12127 | |
7f947b68 CR |
12128 | cat >>confdefs.h <<_ACEOF |
12129 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
c920c360 | 12130 | _ACEOF |
7f947b68 CR |
12131 | |
12132 | ||
12133 | ||
12134 | ac_fn_c_check_type "$LINENO" "u_int" "ac_cv_type_u_int" "$ac_includes_default" | |
12135 | if test "x$ac_cv_type_u_int" = xyes; then : | |
12136 | ||
c920c360 | 12137 | else |
abe2eb5b | 12138 | |
7f947b68 CR |
12139 | cat >>confdefs.h <<_ACEOF |
12140 | #define u_int unsigned int | |
12141 | _ACEOF | |
12142 | ||
5e4a95c7 | 12143 | fi |
b709b946 | 12144 | |
7f947b68 CR |
12145 | ac_fn_c_check_type "$LINENO" "u_long" "ac_cv_type_u_long" "$ac_includes_default" |
12146 | if test "x$ac_cv_type_u_long" = xyes; then : | |
abe2eb5b | 12147 | |
7f947b68 | 12148 | else |
e3db237e | 12149 | |
7f947b68 CR |
12150 | cat >>confdefs.h <<_ACEOF |
12151 | #define u_long unsigned long | |
abe2eb5b | 12152 | _ACEOF |
e3db237e | 12153 | |
2dead0c4 | 12154 | fi |
e3db237e | 12155 | |
7f947b68 CR |
12156 | |
12157 | ||
12158 | if test "$ac_cv_sizeof_short" = 2; then | |
12159 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12160 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12161 | ||
2dead0c4 | 12162 | else |
7f947b68 CR |
12163 | |
12164 | cat >>confdefs.h <<_ACEOF | |
12165 | #define bits16_t short | |
abe2eb5b | 12166 | _ACEOF |
2dead0c4 | 12167 | |
7f947b68 CR |
12168 | fi |
12169 | ||
12170 | elif test "$ac_cv_sizeof_char" = 2; then | |
12171 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12172 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
e3db237e | 12173 | |
7f947b68 CR |
12174 | else |
12175 | ||
12176 | cat >>confdefs.h <<_ACEOF | |
12177 | #define bits16_t char | |
e3db237e | 12178 | _ACEOF |
7f947b68 CR |
12179 | |
12180 | fi | |
12181 | ||
12182 | else | |
12183 | ac_fn_c_check_type "$LINENO" "bits16_t" "ac_cv_type_bits16_t" "$ac_includes_default" | |
12184 | if test "x$ac_cv_type_bits16_t" = xyes; then : | |
12185 | ||
e3db237e | 12186 | else |
abe2eb5b | 12187 | |
7f947b68 CR |
12188 | cat >>confdefs.h <<_ACEOF |
12189 | #define bits16_t short | |
12190 | _ACEOF | |
12191 | ||
e3db237e | 12192 | fi |
7f947b68 | 12193 | |
e3db237e CR |
12194 | fi |
12195 | ||
e3db237e | 12196 | |
7f947b68 CR |
12197 | if test "$ac_cv_sizeof_short" = 2; then |
12198 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12199 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
abe2eb5b | 12200 | |
7f947b68 | 12201 | else |
e3db237e | 12202 | |
7f947b68 CR |
12203 | cat >>confdefs.h <<_ACEOF |
12204 | #define u_bits16_t unsigned short | |
abe2eb5b | 12205 | _ACEOF |
2dead0c4 CR |
12206 | |
12207 | fi | |
e3db237e | 12208 | |
7f947b68 CR |
12209 | elif test "$ac_cv_sizeof_char" = 2; then |
12210 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12211 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
e3db237e | 12212 | |
e3db237e | 12213 | else |
7f947b68 CR |
12214 | |
12215 | cat >>confdefs.h <<_ACEOF | |
12216 | #define u_bits16_t unsigned char | |
abe2eb5b | 12217 | _ACEOF |
e3db237e | 12218 | |
7f947b68 | 12219 | fi |
e3db237e | 12220 | |
7f947b68 CR |
12221 | else |
12222 | ac_fn_c_check_type "$LINENO" "u_bits16_t" "ac_cv_type_u_bits16_t" "$ac_includes_default" | |
12223 | if test "x$ac_cv_type_u_bits16_t" = xyes; then : | |
e3db237e | 12224 | |
7f947b68 | 12225 | else |
e3db237e | 12226 | |
7f947b68 CR |
12227 | cat >>confdefs.h <<_ACEOF |
12228 | #define u_bits16_t unsigned short | |
12229 | _ACEOF | |
e3db237e | 12230 | |
7f947b68 | 12231 | fi |
e3db237e | 12232 | |
7f947b68 CR |
12233 | fi |
12234 | ||
12235 | ||
12236 | if test "$ac_cv_sizeof_int" = 4; then | |
12237 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12238 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
e3db237e | 12239 | |
e3db237e | 12240 | else |
abe2eb5b | 12241 | |
7f947b68 CR |
12242 | cat >>confdefs.h <<_ACEOF |
12243 | #define bits32_t int | |
12244 | _ACEOF | |
12245 | ||
e3db237e CR |
12246 | fi |
12247 | ||
7f947b68 CR |
12248 | elif test "$ac_cv_sizeof_long" = 4; then |
12249 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12250 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12251 | ||
12252 | else | |
2dead0c4 | 12253 | |
7f947b68 CR |
12254 | cat >>confdefs.h <<_ACEOF |
12255 | #define bits32_t long | |
12256 | _ACEOF | |
abe2eb5b | 12257 | |
c920c360 CR |
12258 | fi |
12259 | ||
7f947b68 CR |
12260 | else |
12261 | ac_fn_c_check_type "$LINENO" "bits32_t" "ac_cv_type_bits32_t" "$ac_includes_default" | |
12262 | if test "x$ac_cv_type_bits32_t" = xyes; then : | |
12263 | ||
12264 | else | |
12265 | ||
12266 | cat >>confdefs.h <<_ACEOF | |
12267 | #define bits32_t int | |
abe2eb5b | 12268 | _ACEOF |
2dead0c4 CR |
12269 | |
12270 | fi | |
c920c360 | 12271 | |
7f947b68 CR |
12272 | fi |
12273 | ||
12274 | ||
12275 | if test "$ac_cv_sizeof_int" = 4; then | |
12276 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12277 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
c920c360 | 12278 | |
c920c360 | 12279 | else |
2dead0c4 | 12280 | |
7f947b68 CR |
12281 | cat >>confdefs.h <<_ACEOF |
12282 | #define u_bits32_t unsigned int | |
abe2eb5b | 12283 | _ACEOF |
e3db237e | 12284 | |
7f947b68 | 12285 | fi |
71412226 | 12286 | |
7f947b68 CR |
12287 | elif test "$ac_cv_sizeof_long" = 4; then |
12288 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" | |
12289 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
abe2eb5b | 12290 | |
7f947b68 | 12291 | else |
ccc6cda3 | 12292 | |
7f947b68 CR |
12293 | cat >>confdefs.h <<_ACEOF |
12294 | #define u_bits32_t unsigned long | |
abe2eb5b | 12295 | _ACEOF |
ccc6cda3 | 12296 | |
7f947b68 | 12297 | fi |
c920c360 | 12298 | |
2dead0c4 | 12299 | else |
7f947b68 CR |
12300 | ac_fn_c_check_type "$LINENO" "u_bits32_t" "ac_cv_type_u_bits32_t" "$ac_includes_default" |
12301 | if test "x$ac_cv_type_u_bits32_t" = xyes; then : | |
abe2eb5b | 12302 | |
7f947b68 | 12303 | else |
c920c360 | 12304 | |
7f947b68 CR |
12305 | cat >>confdefs.h <<_ACEOF |
12306 | #define u_bits32_t unsigned int | |
abe2eb5b | 12307 | _ACEOF |
c920c360 | 12308 | |
7f947b68 CR |
12309 | fi |
12310 | ||
12311 | fi | |
12312 | ||
c920c360 | 12313 | |
7f947b68 CR |
12314 | if test "$ac_cv_sizeof_char_p" = 8; then |
12315 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12316 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
71412226 | 12317 | |
71412226 | 12318 | else |
abe2eb5b | 12319 | |
7f947b68 CR |
12320 | cat >>confdefs.h <<_ACEOF |
12321 | #define bits64_t char * | |
12322 | _ACEOF | |
71412226 | 12323 | |
c920c360 | 12324 | fi |
abe2eb5b | 12325 | |
7f947b68 CR |
12326 | elif test "$ac_cv_sizeof_double" = 8; then |
12327 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12328 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
71412226 | 12329 | |
7f947b68 | 12330 | else |
abe2eb5b | 12331 | |
7f947b68 CR |
12332 | cat >>confdefs.h <<_ACEOF |
12333 | #define bits64_t double | |
12334 | _ACEOF | |
7610e0c5 | 12335 | |
2dead0c4 | 12336 | fi |
abe2eb5b | 12337 | |
7f947b68 CR |
12338 | elif test -n "$ac_cv_type_long_long" && test "$ac_cv_sizeof_long_long" = 8; then |
12339 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12340 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
f73dda09 | 12341 | |
7f947b68 | 12342 | else |
a82a04b3 | 12343 | |
7f947b68 CR |
12344 | cat >>confdefs.h <<_ACEOF |
12345 | #define bits64_t long long | |
abe2eb5b | 12346 | _ACEOF |
2dead0c4 | 12347 | |
7f947b68 | 12348 | fi |
2dead0c4 | 12349 | |
7f947b68 CR |
12350 | elif test "$ac_cv_sizeof_long" = 8; then |
12351 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12352 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
12353 | ||
12354 | else | |
12355 | ||
12356 | cat >>confdefs.h <<_ACEOF | |
12357 | #define bits64_t long | |
abe2eb5b | 12358 | _ACEOF |
2dead0c4 | 12359 | |
e3db237e | 12360 | fi |
2dead0c4 | 12361 | |
7f947b68 CR |
12362 | else |
12363 | ac_fn_c_check_type "$LINENO" "bits64_t" "ac_cv_type_bits64_t" "$ac_includes_default" | |
12364 | if test "x$ac_cv_type_bits64_t" = xyes; then : | |
2dead0c4 | 12365 | |
71412226 | 12366 | else |
7f947b68 CR |
12367 | |
12368 | cat >>confdefs.h <<_ACEOF | |
12369 | #define bits64_t double | |
e3db237e | 12370 | _ACEOF |
abe2eb5b | 12371 | |
2dead0c4 | 12372 | fi |
abe2eb5b | 12373 | |
2dead0c4 | 12374 | fi |
7f947b68 CR |
12375 | |
12376 | ||
12377 | ||
12378 | if test "$ac_cv_sizeof_int" = "$ac_cv_sizeof_char_p"; then | |
12379 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12380 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
12381 | ||
12382 | else | |
12383 | ||
12384 | cat >>confdefs.h <<_ACEOF | |
12385 | #define ptrdiff_t int | |
abe2eb5b | 12386 | _ACEOF |
7610e0c5 | 12387 | |
2dead0c4 | 12388 | fi |
7610e0c5 | 12389 | |
7f947b68 CR |
12390 | elif test "$ac_cv_sizeof_long" = "$ac_cv_sizeof_char_p"; then |
12391 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12392 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
2dead0c4 | 12393 | |
2dead0c4 | 12394 | else |
e3db237e | 12395 | |
7f947b68 CR |
12396 | cat >>confdefs.h <<_ACEOF |
12397 | #define ptrdiff_t long | |
e3db237e | 12398 | _ACEOF |
abe2eb5b | 12399 | |
c920c360 CR |
12400 | fi |
12401 | ||
7f947b68 CR |
12402 | elif test "$ac_cv_type_long_long" = yes && test "$ac_cv_sizeof_long_long" = "$ac_cv_sizeof_char_p"; then |
12403 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" | |
12404 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
abe2eb5b | 12405 | |
7f947b68 | 12406 | else |
e3db237e | 12407 | |
7f947b68 CR |
12408 | cat >>confdefs.h <<_ACEOF |
12409 | #define ptrdiff_t long long | |
abe2eb5b | 12410 | _ACEOF |
c920c360 | 12411 | |
e3db237e | 12412 | fi |
c920c360 | 12413 | |
c920c360 | 12414 | else |
7f947b68 CR |
12415 | ac_fn_c_check_type "$LINENO" "ptrdiff_t" "ac_cv_type_ptrdiff_t" "$ac_includes_default" |
12416 | if test "x$ac_cv_type_ptrdiff_t" = xyes; then : | |
2dead0c4 | 12417 | |
2dead0c4 | 12418 | else |
abe2eb5b | 12419 | |
7f947b68 CR |
12420 | cat >>confdefs.h <<_ACEOF |
12421 | #define ptrdiff_t int | |
12422 | _ACEOF | |
abe2eb5b | 12423 | |
2dead0c4 | 12424 | fi |
2dead0c4 CR |
12425 | |
12426 | fi | |
12427 | ||
12428 | ||
7f947b68 CR |
12429 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stat file-mode macros are broken" >&5 |
12430 | $as_echo_n "checking whether stat file-mode macros are broken... " >&6; } | |
12431 | if ${ac_cv_header_stat_broken+:} false; then : | |
2dead0c4 CR |
12432 | $as_echo_n "(cached) " >&6 |
12433 | else | |
7f947b68 | 12434 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 12435 | /* end confdefs.h. */ |
2dead0c4 | 12436 | #include <sys/types.h> |
7f947b68 CR |
12437 | #include <sys/stat.h> |
12438 | ||
12439 | #if defined S_ISBLK && defined S_IFDIR | |
12440 | extern char c1[S_ISBLK (S_IFDIR) ? -1 : 1]; | |
2dead0c4 | 12441 | #endif |
7f947b68 CR |
12442 | |
12443 | #if defined S_ISBLK && defined S_IFCHR | |
12444 | extern char c2[S_ISBLK (S_IFCHR) ? -1 : 1]; | |
2dead0c4 | 12445 | #endif |
7f947b68 CR |
12446 | |
12447 | #if defined S_ISLNK && defined S_IFREG | |
12448 | extern char c3[S_ISLNK (S_IFREG) ? -1 : 1]; | |
12449 | #endif | |
12450 | ||
12451 | #if defined S_ISSOCK && defined S_IFREG | |
12452 | extern char c4[S_ISSOCK (S_IFREG) ? -1 : 1]; | |
12453 | #endif | |
12454 | ||
5e4a95c7 | 12455 | _ACEOF |
7f947b68 CR |
12456 | if ac_fn_c_try_compile "$LINENO"; then : |
12457 | ac_cv_header_stat_broken=no | |
f73dda09 | 12458 | else |
7f947b68 | 12459 | ac_cv_header_stat_broken=yes |
2dead0c4 | 12460 | fi |
7f947b68 | 12461 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2dead0c4 | 12462 | fi |
7f947b68 CR |
12463 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stat_broken" >&5 |
12464 | $as_echo "$ac_cv_header_stat_broken" >&6; } | |
12465 | if test $ac_cv_header_stat_broken = yes; then | |
e3db237e | 12466 | |
7f947b68 | 12467 | $as_echo "#define STAT_MACROS_BROKEN 1" >>confdefs.h |
abe2eb5b | 12468 | |
e3db237e CR |
12469 | fi |
12470 | ||
7f947b68 CR |
12471 | |
12472 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether #! works in shell scripts" >&5 | |
12473 | $as_echo_n "checking whether #! works in shell scripts... " >&6; } | |
12474 | if ${ac_cv_sys_interpreter+:} false; then : | |
12475 | $as_echo_n "(cached) " >&6 | |
12476 | else | |
12477 | echo '#! /bin/cat | |
12478 | exit 69 | |
12479 | ' >conftest | |
12480 | chmod u+x conftest | |
12481 | (SHELL=/bin/sh; export SHELL; ./conftest >/dev/null 2>&1) | |
12482 | if test $? -ne 69; then | |
12483 | ac_cv_sys_interpreter=yes | |
12484 | else | |
12485 | ac_cv_sys_interpreter=no | |
12486 | fi | |
12487 | rm -f conftest | |
12488 | fi | |
12489 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_interpreter" >&5 | |
12490 | $as_echo "$ac_cv_sys_interpreter" >&6; } | |
12491 | interpval=$ac_cv_sys_interpreter | |
12492 | ||
12493 | if test $ac_cv_sys_interpreter = yes; then | |
12494 | $as_echo "#define HAVE_HASH_BANG_EXEC 1" >>confdefs.h | |
e3db237e | 12495 | |
2dead0c4 | 12496 | fi |
e3db237e | 12497 | |
7f947b68 CR |
12498 | if test "$ac_cv_func_lstat" = "no"; then |
12499 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for lstat" >&5 | |
12500 | $as_echo_n "checking for lstat... " >&6; } | |
12501 | if ${bash_cv_func_lstat+:} false; then : | |
2dead0c4 CR |
12502 | $as_echo_n "(cached) " >&6 |
12503 | else | |
7f947b68 | 12504 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
e3db237e | 12505 | /* end confdefs.h. */ |
7f947b68 | 12506 | |
2dead0c4 | 12507 | #include <sys/types.h> |
7f947b68 CR |
12508 | #include <sys/stat.h> |
12509 | ||
e3db237e CR |
12510 | int |
12511 | main () | |
12512 | { | |
7f947b68 | 12513 | lstat(".",(struct stat *)0); |
e3db237e CR |
12514 | ; |
12515 | return 0; | |
12516 | } | |
12517 | _ACEOF | |
7f947b68 CR |
12518 | if ac_fn_c_try_link "$LINENO"; then : |
12519 | bash_cv_func_lstat=yes | |
e3db237e | 12520 | else |
7f947b68 | 12521 | bash_cv_func_lstat=no |
2dead0c4 | 12522 | fi |
7f947b68 CR |
12523 | rm -f core conftest.err conftest.$ac_objext \ |
12524 | conftest$ac_exeext conftest.$ac_ext | |
2dead0c4 | 12525 | fi |
7f947b68 CR |
12526 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_lstat" >&5 |
12527 | $as_echo "$bash_cv_func_lstat" >&6; } | |
12528 | if test $bash_cv_func_lstat = yes; then | |
12529 | $as_echo "#define HAVE_LSTAT 1" >>confdefs.h | |
e3db237e | 12530 | |
e3db237e CR |
12531 | fi |
12532 | ||
7f947b68 | 12533 | fi |
2dead0c4 CR |
12534 | |
12535 | ||
7f947b68 CR |
12536 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the ctype macros accept non-ascii characters" >&5 |
12537 | $as_echo_n "checking whether the ctype macros accept non-ascii characters... " >&6; } | |
12538 | if ${bash_cv_func_ctype_nonascii+:} false; then : | |
2dead0c4 | 12539 | $as_echo_n "(cached) " >&6 |
e3db237e | 12540 | else |
7f947b68 CR |
12541 | if test "$cross_compiling" = yes; then : |
12542 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&5 | |
12543 | $as_echo "$as_me: WARNING: cannot check ctype macros if cross compiling -- defaulting to no" >&2;} | |
12544 | bash_cv_func_ctype_nonascii=no | |
12545 | ||
12546 | else | |
12547 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2dead0c4 | 12548 | /* end confdefs.h. */ |
7f947b68 CR |
12549 | |
12550 | #ifdef HAVE_LOCALE_H | |
12551 | #include <locale.h> | |
2dead0c4 | 12552 | #endif |
7f947b68 CR |
12553 | #include <stdio.h> |
12554 | #include <ctype.h> | |
12555 | ||
12556 | main(c, v) | |
12557 | int c; | |
12558 | char *v[]; | |
12559 | { | |
12560 | char *deflocale; | |
12561 | unsigned char x; | |
12562 | int r1, r2; | |
12563 | ||
12564 | #ifdef HAVE_SETLOCALE | |
12565 | /* We take a shot here. If that locale is not known, try the | |
12566 | system default. We try this one because '\342' (226) is | |
12567 | known to be a printable character in that locale. */ | |
12568 | deflocale = setlocale(LC_ALL, "en_US.ISO8859-1"); | |
12569 | if (deflocale == 0) | |
12570 | deflocale = setlocale(LC_ALL, ""); | |
2dead0c4 | 12571 | #endif |
7f947b68 CR |
12572 | |
12573 | x = '\342'; | |
12574 | r1 = isprint(x); | |
12575 | x -= 128; | |
12576 | r2 = isprint(x); | |
12577 | exit (r1 == 0 || r2 == 0); | |
12578 | } | |
e3db237e | 12579 | |
2dead0c4 | 12580 | _ACEOF |
7f947b68 CR |
12581 | if ac_fn_c_try_run "$LINENO"; then : |
12582 | bash_cv_func_ctype_nonascii=yes | |
2dead0c4 | 12583 | else |
7f947b68 | 12584 | bash_cv_func_ctype_nonascii=no |
71412226 | 12585 | fi |
7f947b68 CR |
12586 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12587 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5e4a95c7 | 12588 | fi |
b709b946 | 12589 | |
abe2eb5b CR |
12590 | fi |
12591 | ||
7f947b68 CR |
12592 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_ctype_nonascii" >&5 |
12593 | $as_echo "$bash_cv_func_ctype_nonascii" >&6; } | |
12594 | if test $bash_cv_func_ctype_nonascii = yes; then | |
12595 | $as_echo "#define CTYPE_NON_ASCII 1" >>confdefs.h | |
abe2eb5b | 12596 | |
7f947b68 | 12597 | fi |
abe2eb5b | 12598 | |
7f947b68 CR |
12599 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dup2 fails to clear the close-on-exec flag" >&5 |
12600 | $as_echo_n "checking if dup2 fails to clear the close-on-exec flag... " >&6; } | |
12601 | if ${bash_cv_dup2_broken+:} false; then : | |
abe2eb5b CR |
12602 | $as_echo_n "(cached) " >&6 |
12603 | else | |
7f947b68 CR |
12604 | if test "$cross_compiling" = yes; then : |
12605 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&5 | |
12606 | $as_echo "$as_me: WARNING: cannot check dup2 if cross compiling -- defaulting to no" >&2;} | |
12607 | bash_cv_dup2_broken=no | |
12608 | else | |
12609 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 12610 | /* end confdefs.h. */ |
7f947b68 | 12611 | |
abe2eb5b | 12612 | #include <sys/types.h> |
7f947b68 CR |
12613 | #include <fcntl.h> |
12614 | main() | |
12615 | { | |
12616 | int fd1, fd2, fl; | |
12617 | fd1 = open("/dev/null", 2); | |
12618 | if (fcntl(fd1, 2, 1) < 0) | |
12619 | exit(1); | |
12620 | fd2 = dup2(fd1, 1); | |
12621 | if (fd2 < 0) | |
12622 | exit(2); | |
12623 | fl = fcntl(fd2, 1, 0); | |
12624 | /* fl will be 1 if dup2 did not reset the close-on-exec flag. */ | |
12625 | exit(fl != 1); | |
12626 | } | |
abe2eb5b CR |
12627 | |
12628 | _ACEOF | |
7f947b68 CR |
12629 | if ac_fn_c_try_run "$LINENO"; then : |
12630 | bash_cv_dup2_broken=yes | |
abe2eb5b | 12631 | else |
7f947b68 | 12632 | bash_cv_dup2_broken=no |
abe2eb5b | 12633 | fi |
7f947b68 CR |
12634 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12635 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
abe2eb5b CR |
12636 | fi |
12637 | ||
abe2eb5b CR |
12638 | |
12639 | fi | |
12640 | ||
7f947b68 CR |
12641 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dup2_broken" >&5 |
12642 | $as_echo "$bash_cv_dup2_broken" >&6; } | |
12643 | if test $bash_cv_dup2_broken = yes; then | |
12644 | $as_echo "#define DUP2_BROKEN 1" >>confdefs.h | |
12645 | ||
12646 | fi | |
abe2eb5b CR |
12647 | |
12648 | ||
7f947b68 CR |
12649 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pgrps need synchronization" >&5 |
12650 | $as_echo_n "checking whether pgrps need synchronization... " >&6; } | |
12651 | if ${bash_cv_pgrp_pipe+:} false; then : | |
abe2eb5b CR |
12652 | $as_echo_n "(cached) " >&6 |
12653 | else | |
7f947b68 CR |
12654 | if test "$cross_compiling" = yes; then : |
12655 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&5 | |
12656 | $as_echo "$as_me: WARNING: cannot check pgrp synchronization if cross compiling -- defaulting to no" >&2;} | |
12657 | bash_cv_pgrp_pipe=no | |
abe2eb5b | 12658 | else |
7f947b68 CR |
12659 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
12660 | /* end confdefs.h. */ | |
abe2eb5b | 12661 | |
7f947b68 CR |
12662 | #ifdef HAVE_UNISTD_H |
12663 | # include <unistd.h> | |
12664 | #endif | |
12665 | main() | |
12666 | { | |
12667 | # ifdef GETPGRP_VOID | |
12668 | # define getpgID() getpgrp() | |
12669 | # else | |
12670 | # define getpgID() getpgrp(0) | |
12671 | # define setpgid(x,y) setpgrp(x,y) | |
12672 | # endif | |
12673 | int pid1, pid2, fds[2]; | |
12674 | int status; | |
12675 | char ok; | |
abe2eb5b | 12676 | |
7f947b68 CR |
12677 | switch (pid1 = fork()) { |
12678 | case -1: | |
12679 | exit(1); | |
12680 | case 0: | |
12681 | setpgid(0, getpid()); | |
12682 | exit(0); | |
12683 | } | |
12684 | setpgid(pid1, pid1); | |
abe2eb5b | 12685 | |
7f947b68 | 12686 | sleep(2); /* let first child die */ |
abe2eb5b | 12687 | |
7f947b68 CR |
12688 | if (pipe(fds) < 0) |
12689 | exit(2); | |
abe2eb5b | 12690 | |
7f947b68 CR |
12691 | switch (pid2 = fork()) { |
12692 | case -1: | |
12693 | exit(3); | |
12694 | case 0: | |
12695 | setpgid(0, pid1); | |
12696 | ok = getpgID() == pid1; | |
12697 | write(fds[1], &ok, 1); | |
12698 | exit(0); | |
12699 | } | |
12700 | setpgid(pid2, pid1); | |
abe2eb5b | 12701 | |
7f947b68 CR |
12702 | close(fds[1]); |
12703 | if (read(fds[0], &ok, 1) != 1) | |
12704 | exit(4); | |
12705 | wait(&status); | |
12706 | wait(&status); | |
12707 | exit(ok ? 0 : 5); | |
12708 | } | |
abe2eb5b CR |
12709 | |
12710 | _ACEOF | |
7f947b68 CR |
12711 | if ac_fn_c_try_run "$LINENO"; then : |
12712 | bash_cv_pgrp_pipe=no | |
abe2eb5b | 12713 | else |
7f947b68 | 12714 | bash_cv_pgrp_pipe=yes |
abe2eb5b | 12715 | fi |
7f947b68 CR |
12716 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12717 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
abe2eb5b CR |
12718 | fi |
12719 | ||
7f947b68 | 12720 | |
2dead0c4 CR |
12721 | fi |
12722 | ||
7f947b68 CR |
12723 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_pgrp_pipe" >&5 |
12724 | $as_echo "$bash_cv_pgrp_pipe" >&6; } | |
12725 | if test $bash_cv_pgrp_pipe = yes; then | |
12726 | $as_echo "#define PGRP_PIPE 1" >>confdefs.h | |
12727 | ||
12728 | fi | |
2dead0c4 CR |
12729 | |
12730 | ||
7f947b68 CR |
12731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for type of signal functions" >&5 |
12732 | $as_echo_n "checking for type of signal functions... " >&6; } | |
12733 | if ${bash_cv_signal_vintage+:} false; then : | |
2dead0c4 CR |
12734 | $as_echo_n "(cached) " >&6 |
12735 | else | |
7f947b68 CR |
12736 | |
12737 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 12738 | /* end confdefs.h. */ |
7f947b68 CR |
12739 | #include <signal.h> |
12740 | int | |
12741 | main () | |
12742 | { | |
abe2eb5b | 12743 | |
7f947b68 CR |
12744 | sigset_t ss; |
12745 | struct sigaction sa; | |
12746 | sigemptyset(&ss); sigsuspend(&ss); | |
12747 | sigaction(SIGINT, &sa, (struct sigaction *) 0); | |
12748 | sigprocmask(SIG_BLOCK, &ss, (sigset_t *) 0); | |
c920c360 | 12749 | |
7f947b68 CR |
12750 | ; |
12751 | return 0; | |
12752 | } | |
7610e0c5 | 12753 | _ACEOF |
7f947b68 CR |
12754 | if ac_fn_c_try_link "$LINENO"; then : |
12755 | bash_cv_signal_vintage=posix | |
e3db237e | 12756 | else |
71412226 | 12757 | |
7f947b68 CR |
12758 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
12759 | /* end confdefs.h. */ | |
12760 | #include <signal.h> | |
12761 | int | |
12762 | main () | |
12763 | { | |
71412226 | 12764 | |
7f947b68 CR |
12765 | int mask = sigmask(SIGINT); |
12766 | sigsetmask(mask); sigblock(mask); sigpause(mask); | |
2dead0c4 | 12767 | |
7f947b68 CR |
12768 | ; |
12769 | return 0; | |
12770 | } | |
e3db237e | 12771 | _ACEOF |
7f947b68 CR |
12772 | if ac_fn_c_try_link "$LINENO"; then : |
12773 | bash_cv_signal_vintage=4.2bsd | |
12774 | else | |
2dead0c4 | 12775 | |
7f947b68 CR |
12776 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
12777 | /* end confdefs.h. */ | |
2dead0c4 | 12778 | |
7f947b68 CR |
12779 | #include <signal.h> |
12780 | RETSIGTYPE foo() { } | |
12781 | int | |
12782 | main () | |
12783 | { | |
2dead0c4 | 12784 | |
7f947b68 CR |
12785 | int mask = sigmask(SIGINT); |
12786 | sigset(SIGINT, foo); sigrelse(SIGINT); | |
12787 | sighold(SIGINT); sigpause(SIGINT); | |
c920c360 | 12788 | |
7f947b68 CR |
12789 | ; |
12790 | return 0; | |
12791 | } | |
c920c360 | 12792 | _ACEOF |
7f947b68 CR |
12793 | if ac_fn_c_try_link "$LINENO"; then : |
12794 | bash_cv_signal_vintage=svr3 | |
c920c360 | 12795 | else |
7f947b68 | 12796 | bash_cv_signal_vintage=v7 |
c920c360 | 12797 | |
2dead0c4 | 12798 | fi |
7f947b68 CR |
12799 | rm -f core conftest.err conftest.$ac_objext \ |
12800 | conftest$ac_exeext conftest.$ac_ext | |
c920c360 | 12801 | |
7f947b68 CR |
12802 | fi |
12803 | rm -f core conftest.err conftest.$ac_objext \ | |
12804 | conftest$ac_exeext conftest.$ac_ext | |
e3db237e | 12805 | |
7f947b68 CR |
12806 | fi |
12807 | rm -f core conftest.err conftest.$ac_objext \ | |
12808 | conftest$ac_exeext conftest.$ac_ext | |
71412226 | 12809 | |
2dead0c4 | 12810 | fi |
71412226 | 12811 | |
7f947b68 CR |
12812 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_signal_vintage" >&5 |
12813 | $as_echo "$bash_cv_signal_vintage" >&6; } | |
12814 | if test "$bash_cv_signal_vintage" = posix; then | |
12815 | $as_echo "#define HAVE_POSIX_SIGNALS 1" >>confdefs.h | |
12816 | ||
12817 | elif test "$bash_cv_signal_vintage" = "4.2bsd"; then | |
12818 | $as_echo "#define HAVE_BSD_SIGNALS 1" >>confdefs.h | |
12819 | ||
12820 | elif test "$bash_cv_signal_vintage" = svr3; then | |
12821 | $as_echo "#define HAVE_USG_SIGHOLD 1" >>confdefs.h | |
12822 | ||
abe2eb5b | 12823 | fi |
7f947b68 CR |
12824 | |
12825 | ||
12826 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_errlist and sys_nerr" >&5 | |
12827 | $as_echo_n "checking for sys_errlist and sys_nerr... " >&6; } | |
12828 | if ${bash_cv_sys_errlist+:} false; then : | |
c920c360 CR |
12829 | $as_echo_n "(cached) " >&6 |
12830 | else | |
7f947b68 | 12831 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
c920c360 | 12832 | /* end confdefs.h. */ |
7f947b68 | 12833 | #include <errno.h> |
abe2eb5b CR |
12834 | int |
12835 | main () | |
12836 | { | |
7f947b68 CR |
12837 | extern char *sys_errlist[]; |
12838 | extern int sys_nerr; | |
12839 | char *msg = sys_errlist[sys_nerr - 1]; | |
abe2eb5b CR |
12840 | ; |
12841 | return 0; | |
12842 | } | |
12843 | _ACEOF | |
7f947b68 CR |
12844 | if ac_fn_c_try_link "$LINENO"; then : |
12845 | bash_cv_sys_errlist=yes | |
abe2eb5b | 12846 | else |
7f947b68 CR |
12847 | bash_cv_sys_errlist=no |
12848 | fi | |
12849 | rm -f core conftest.err conftest.$ac_objext \ | |
12850 | conftest$ac_exeext conftest.$ac_ext | |
12851 | fi | |
12852 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_errlist" >&5 | |
12853 | $as_echo "$bash_cv_sys_errlist" >&6; } | |
12854 | if test $bash_cv_sys_errlist = yes; then | |
12855 | $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h | |
e3db237e | 12856 | |
7f947b68 | 12857 | fi |
e3db237e | 12858 | |
7f947b68 CR |
12859 | |
12860 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys_siglist in system C library" >&5 | |
12861 | $as_echo_n "checking for sys_siglist in system C library... " >&6; } | |
12862 | if ${bash_cv_sys_siglist+:} false; then : | |
12863 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 12864 | else |
7f947b68 CR |
12865 | if test "$cross_compiling" = yes; then : |
12866 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&5 | |
12867 | $as_echo "$as_me: WARNING: cannot check for sys_siglist if cross compiling -- defaulting to no" >&2;} | |
12868 | bash_cv_sys_siglist=no | |
12869 | else | |
12870 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b CR |
12871 | /* end confdefs.h. */ |
12872 | ||
12873 | #include <sys/types.h> | |
7f947b68 CR |
12874 | #include <signal.h> |
12875 | #ifdef HAVE_UNISTD_H | |
12876 | #include <unistd.h> | |
12877 | #endif | |
12878 | #if !HAVE_DECL_SYS_SIGLIST | |
12879 | extern char *sys_siglist[]; | |
12880 | #endif | |
abe2eb5b CR |
12881 | main() |
12882 | { | |
7f947b68 CR |
12883 | char *msg = sys_siglist[2]; |
12884 | exit(msg == 0); | |
abe2eb5b CR |
12885 | } |
12886 | _ACEOF | |
7f947b68 CR |
12887 | if ac_fn_c_try_run "$LINENO"; then : |
12888 | bash_cv_sys_siglist=yes | |
7610e0c5 | 12889 | else |
7f947b68 | 12890 | bash_cv_sys_siglist=no |
2dead0c4 | 12891 | fi |
7f947b68 CR |
12892 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
12893 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2dead0c4 CR |
12894 | fi |
12895 | ||
abe2eb5b CR |
12896 | fi |
12897 | ||
7f947b68 CR |
12898 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_siglist" >&5 |
12899 | $as_echo "$bash_cv_sys_siglist" >&6; } | |
12900 | if test $bash_cv_sys_siglist = yes; then | |
12901 | $as_echo "#define HAVE_SYS_SIGLIST 1" >>confdefs.h | |
2dead0c4 | 12902 | |
abe2eb5b | 12903 | fi |
2dead0c4 | 12904 | |
7f947b68 CR |
12905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in signal.h or unistd.h" >&5 |
12906 | $as_echo_n "checking for _sys_siglist in signal.h or unistd.h... " >&6; } | |
12907 | if ${bash_cv_decl_under_sys_siglist+:} false; then : | |
2dead0c4 CR |
12908 | $as_echo_n "(cached) " >&6 |
12909 | else | |
7f947b68 | 12910 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2dead0c4 | 12911 | /* end confdefs.h. */ |
7f947b68 CR |
12912 | |
12913 | #include <sys/types.h> | |
12914 | #include <signal.h> | |
12915 | #ifdef HAVE_UNISTD_H | |
12916 | #include <unistd.h> | |
12917 | #endif | |
abe2eb5b CR |
12918 | int |
12919 | main () | |
12920 | { | |
7f947b68 | 12921 | char *msg = _sys_siglist[2]; |
abe2eb5b CR |
12922 | ; |
12923 | return 0; | |
12924 | } | |
12925 | _ACEOF | |
7f947b68 CR |
12926 | if ac_fn_c_try_compile "$LINENO"; then : |
12927 | bash_cv_decl_under_sys_siglist=yes | |
12928 | else | |
12929 | bash_cv_decl_under_sys_siglist=no | |
12930 | fi | |
12931 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
12932 | fi | |
12933 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_decl_under_sys_siglist" >&5 | |
12934 | $as_echo "$bash_cv_decl_under_sys_siglist" >&6; } | |
12935 | if test $bash_cv_decl_under_sys_siglist = yes; then | |
12936 | $as_echo "#define UNDER_SYS_SIGLIST_DECLARED 1" >>confdefs.h | |
12937 | ||
12938 | fi | |
12939 | ||
12940 | ||
12941 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _sys_siglist in system C library" >&5 | |
12942 | $as_echo_n "checking for _sys_siglist in system C library... " >&6; } | |
12943 | if ${bash_cv_under_sys_siglist+:} false; then : | |
12944 | $as_echo_n "(cached) " >&6 | |
12945 | else | |
12946 | if test "$cross_compiling" = yes; then : | |
12947 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&5 | |
12948 | $as_echo "$as_me: WARNING: cannot check for _sys_siglist if cross compiling -- defaulting to no" >&2;} | |
12949 | bash_cv_under_sys_siglist=no | |
12950 | else | |
12951 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 12952 | /* end confdefs.h. */ |
e3db237e | 12953 | |
7f947b68 CR |
12954 | #include <sys/types.h> |
12955 | #include <signal.h> | |
12956 | #ifdef HAVE_UNISTD_H | |
12957 | #include <unistd.h> | |
12958 | #endif | |
12959 | #ifndef UNDER_SYS_SIGLIST_DECLARED | |
12960 | extern char *_sys_siglist[]; | |
12961 | #endif | |
12962 | main() | |
12963 | { | |
12964 | char *msg = (char *)_sys_siglist[2]; | |
12965 | exit(msg == 0); | |
abe2eb5b | 12966 | } |
7610e0c5 | 12967 | _ACEOF |
7f947b68 CR |
12968 | if ac_fn_c_try_run "$LINENO"; then : |
12969 | bash_cv_under_sys_siglist=yes | |
7610e0c5 | 12970 | else |
7f947b68 CR |
12971 | bash_cv_under_sys_siglist=no |
12972 | fi | |
12973 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
12974 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
12975 | fi | |
abe2eb5b | 12976 | |
abe2eb5b CR |
12977 | fi |
12978 | ||
7f947b68 CR |
12979 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_under_sys_siglist" >&5 |
12980 | $as_echo "$bash_cv_under_sys_siglist" >&6; } | |
12981 | if test $bash_cv_under_sys_siglist = yes; then | |
12982 | $as_echo "#define HAVE_UNDER_SYS_SIGLIST 1" >>confdefs.h | |
abe2eb5b | 12983 | |
7f947b68 | 12984 | fi |
abe2eb5b | 12985 | |
7f947b68 CR |
12986 | |
12987 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether signal handlers are of type void" >&5 | |
12988 | $as_echo_n "checking whether signal handlers are of type void... " >&6; } | |
12989 | if ${bash_cv_void_sighandler+:} false; then : | |
12990 | $as_echo_n "(cached) " >&6 | |
12991 | else | |
12992 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 12993 | /* end confdefs.h. */ |
7f947b68 CR |
12994 | #include <sys/types.h> |
12995 | #include <signal.h> | |
12996 | #ifdef signal | |
12997 | #undef signal | |
12998 | #endif | |
12999 | #ifdef __cplusplus | |
13000 | extern "C" | |
13001 | #endif | |
13002 | void (*signal ()) (); | |
abe2eb5b CR |
13003 | int |
13004 | main () | |
13005 | { | |
7f947b68 | 13006 | int i; |
abe2eb5b CR |
13007 | ; |
13008 | return 0; | |
13009 | } | |
13010 | _ACEOF | |
7f947b68 CR |
13011 | if ac_fn_c_try_compile "$LINENO"; then : |
13012 | bash_cv_void_sighandler=yes | |
abe2eb5b | 13013 | else |
7f947b68 CR |
13014 | bash_cv_void_sighandler=no |
13015 | fi | |
13016 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13017 | fi | |
13018 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_void_sighandler" >&5 | |
13019 | $as_echo "$bash_cv_void_sighandler" >&6; } | |
13020 | if test $bash_cv_void_sighandler = yes; then | |
13021 | $as_echo "#define VOID_SIGHANDLER 1" >>confdefs.h | |
abe2eb5b | 13022 | |
abe2eb5b CR |
13023 | fi |
13024 | ||
7f947b68 CR |
13025 | |
13026 | ||
13027 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5 | |
13028 | $as_echo_n "checking for clock_t... " >&6; } | |
13029 | if ${bash_cv_type_clock_t+:} false; then : | |
13030 | $as_echo_n "(cached) " >&6 | |
abe2eb5b | 13031 | else |
7f947b68 CR |
13032 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
13033 | /* end confdefs.h. */ | |
13034 | #include <sys/types.h> | |
13035 | #if STDC_HEADERS | |
13036 | #include <stdlib.h> | |
13037 | #include <stddef.h> | |
13038 | #endif | |
13039 | #if HAVE_INTTYPES_H | |
13040 | #include <inttypes.h> | |
13041 | #endif | |
13042 | #if HAVE_STDINT_H | |
13043 | #include <stdint.h> | |
13044 | #endif | |
13045 | #include <sys/times.h> | |
abe2eb5b | 13046 | |
7f947b68 CR |
13047 | _ACEOF |
13048 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13049 | $EGREP "clock_t" >/dev/null 2>&1; then : | |
13050 | bash_cv_type_clock_t=yes | |
13051 | else | |
13052 | bash_cv_type_clock_t=no | |
c920c360 | 13053 | fi |
7f947b68 | 13054 | rm -f conftest* |
c920c360 | 13055 | |
7610e0c5 | 13056 | fi |
71412226 | 13057 | |
7f947b68 CR |
13058 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_clock_t" >&5 |
13059 | $as_echo "$bash_cv_type_clock_t" >&6; } | |
13060 | ||
13061 | if test $bash_cv_type_clock_t = no; then | |
13062 | cat >>confdefs.h <<_ACEOF | |
13063 | #define clock_t long | |
abe2eb5b | 13064 | _ACEOF |
7f947b68 CR |
13065 | |
13066 | fi | |
13067 | ||
13068 | ||
13069 | ||
13070 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sigset_t" >&5 | |
13071 | $as_echo_n "checking for sigset_t... " >&6; } | |
13072 | if ${bash_cv_type_sigset_t+:} false; then : | |
13073 | $as_echo_n "(cached) " >&6 | |
13074 | else | |
13075 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 13076 | /* end confdefs.h. */ |
7f947b68 CR |
13077 | #include <sys/types.h> |
13078 | #if STDC_HEADERS | |
13079 | #include <stdlib.h> | |
13080 | #include <stddef.h> | |
13081 | #endif | |
13082 | #if HAVE_INTTYPES_H | |
13083 | #include <inttypes.h> | |
13084 | #endif | |
13085 | #if HAVE_STDINT_H | |
13086 | #include <stdint.h> | |
13087 | #endif | |
13088 | #include <signal.h> | |
2dead0c4 | 13089 | |
e3db237e | 13090 | _ACEOF |
7f947b68 CR |
13091 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13092 | $EGREP "sigset_t" >/dev/null 2>&1; then : | |
13093 | bash_cv_type_sigset_t=yes | |
abe2eb5b | 13094 | else |
7f947b68 CR |
13095 | bash_cv_type_sigset_t=no |
13096 | fi | |
13097 | rm -f conftest* | |
c920c360 CR |
13098 | |
13099 | fi | |
13100 | ||
7f947b68 CR |
13101 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_sigset_t" >&5 |
13102 | $as_echo "$bash_cv_type_sigset_t" >&6; } | |
13103 | ||
13104 | if test $bash_cv_type_sigset_t = no; then | |
13105 | cat >>confdefs.h <<_ACEOF | |
13106 | #define sigset_t int | |
abe2eb5b | 13107 | _ACEOF |
7f947b68 CR |
13108 | |
13109 | fi | |
13110 | ||
13111 | ||
13112 | ||
13113 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for quad_t" >&5 | |
13114 | $as_echo_n "checking for quad_t... " >&6; } | |
13115 | if ${bash_cv_type_quad_t+:} false; then : | |
13116 | $as_echo_n "(cached) " >&6 | |
13117 | else | |
13118 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
e3db237e | 13119 | /* end confdefs.h. */ |
7f947b68 CR |
13120 | #include <sys/types.h> |
13121 | #if STDC_HEADERS | |
2dead0c4 | 13122 | #include <stdlib.h> |
7f947b68 CR |
13123 | #include <stddef.h> |
13124 | #endif | |
13125 | #if HAVE_INTTYPES_H | |
13126 | #include <inttypes.h> | |
13127 | #endif | |
13128 | #if HAVE_STDINT_H | |
13129 | #include <stdint.h> | |
13130 | #endif | |
abe2eb5b | 13131 | |
2dead0c4 CR |
13132 | |
13133 | _ACEOF | |
7f947b68 CR |
13134 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13135 | $EGREP "quad_t" >/dev/null 2>&1; then : | |
13136 | bash_cv_type_quad_t=yes | |
2dead0c4 | 13137 | else |
7f947b68 | 13138 | bash_cv_type_quad_t=no |
2dead0c4 | 13139 | fi |
7f947b68 | 13140 | rm -f conftest* |
2dead0c4 | 13141 | |
7f947b68 | 13142 | fi |
2dead0c4 | 13143 | |
7f947b68 CR |
13144 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_quad_t" >&5 |
13145 | $as_echo "$bash_cv_type_quad_t" >&6; } | |
13146 | if test $bash_cv_type_quad_t = yes; then | |
13147 | $as_echo "#define HAVE_QUAD_T 1" >>confdefs.h | |
abe2eb5b | 13148 | |
7f947b68 CR |
13149 | fi |
13150 | if test $bash_cv_type_quad_t = no; then | |
13151 | cat >>confdefs.h <<_ACEOF | |
13152 | #define quad_t long | |
2dead0c4 | 13153 | _ACEOF |
c920c360 | 13154 | |
7f947b68 | 13155 | fi |
c920c360 | 13156 | |
abe2eb5b CR |
13157 | |
13158 | ||
7f947b68 CR |
13159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intmax_t" >&5 |
13160 | $as_echo_n "checking for intmax_t... " >&6; } | |
13161 | if ${bash_cv_type_intmax_t+:} false; then : | |
2dead0c4 CR |
13162 | $as_echo_n "(cached) " >&6 |
13163 | else | |
7f947b68 | 13164 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2dead0c4 CR |
13165 | /* end confdefs.h. */ |
13166 | #include <sys/types.h> | |
7f947b68 CR |
13167 | #if STDC_HEADERS |
13168 | #include <stdlib.h> | |
13169 | #include <stddef.h> | |
13170 | #endif | |
13171 | #if HAVE_INTTYPES_H | |
13172 | #include <inttypes.h> | |
13173 | #endif | |
13174 | #if HAVE_STDINT_H | |
13175 | #include <stdint.h> | |
13176 | #endif | |
abe2eb5b CR |
13177 | |
13178 | ||
7610e0c5 | 13179 | _ACEOF |
7f947b68 CR |
13180 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13181 | $EGREP "intmax_t" >/dev/null 2>&1; then : | |
13182 | bash_cv_type_intmax_t=yes | |
e3db237e | 13183 | else |
7f947b68 CR |
13184 | bash_cv_type_intmax_t=no |
13185 | fi | |
13186 | rm -f conftest* | |
13187 | ||
13188 | fi | |
13189 | ||
13190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_intmax_t" >&5 | |
13191 | $as_echo "$bash_cv_type_intmax_t" >&6; } | |
71412226 | 13192 | |
7f947b68 CR |
13193 | if test $bash_cv_type_intmax_t = no; then |
13194 | cat >>confdefs.h <<_ACEOF | |
13195 | #define intmax_t $bash_cv_type_long_long | |
abe2eb5b | 13196 | _ACEOF |
c920c360 | 13197 | |
7f947b68 CR |
13198 | fi |
13199 | ||
13200 | ||
13201 | ||
13202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uintmax_t" >&5 | |
13203 | $as_echo_n "checking for uintmax_t... " >&6; } | |
13204 | if ${bash_cv_type_uintmax_t+:} false; then : | |
13205 | $as_echo_n "(cached) " >&6 | |
13206 | else | |
13207 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13208 | /* end confdefs.h. */ | |
c920c360 | 13209 | #include <sys/types.h> |
7f947b68 CR |
13210 | #if STDC_HEADERS |
13211 | #include <stdlib.h> | |
13212 | #include <stddef.h> | |
13213 | #endif | |
13214 | #if HAVE_INTTYPES_H | |
13215 | #include <inttypes.h> | |
13216 | #endif | |
13217 | #if HAVE_STDINT_H | |
13218 | #include <stdint.h> | |
13219 | #endif | |
abe2eb5b CR |
13220 | |
13221 | ||
e3db237e | 13222 | _ACEOF |
7f947b68 CR |
13223 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
13224 | $EGREP "uintmax_t" >/dev/null 2>&1; then : | |
13225 | bash_cv_type_uintmax_t=yes | |
e3db237e | 13226 | else |
7f947b68 | 13227 | bash_cv_type_uintmax_t=no |
2dead0c4 | 13228 | fi |
7f947b68 | 13229 | rm -f conftest* |
2dead0c4 | 13230 | |
e3db237e | 13231 | fi |
c920c360 | 13232 | |
7f947b68 CR |
13233 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_uintmax_t" >&5 |
13234 | $as_echo "$bash_cv_type_uintmax_t" >&6; } | |
13235 | ||
13236 | if test $bash_cv_type_uintmax_t = no; then | |
13237 | cat >>confdefs.h <<_ACEOF | |
13238 | #define uintmax_t $bash_cv_type_unsigned_long_long | |
abe2eb5b | 13239 | _ACEOF |
2dead0c4 CR |
13240 | |
13241 | fi | |
13242 | ||
7f947b68 | 13243 | if test "$ac_cv_header_sys_socket_h" = "yes"; then |
2dead0c4 | 13244 | |
2dead0c4 | 13245 | |
7f947b68 CR |
13246 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t" >&5 |
13247 | $as_echo_n "checking for socklen_t... " >&6; } | |
13248 | if ${bash_cv_type_socklen_t+:} false; then : | |
abe2eb5b | 13249 | $as_echo_n "(cached) " >&6 |
2dead0c4 | 13250 | else |
7f947b68 | 13251 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
abe2eb5b | 13252 | /* end confdefs.h. */ |
abe2eb5b | 13253 | #include <sys/types.h> |
7f947b68 CR |
13254 | #if STDC_HEADERS |
13255 | #include <stdlib.h> | |
13256 | #include <stddef.h> | |
13257 | #endif | |
13258 | #if HAVE_INTTYPES_H | |
13259 | #include <inttypes.h> | |
13260 | #endif | |
13261 | #if HAVE_STDINT_H | |
13262 | #include <stdint.h> | |
13263 | #endif | |
13264 | #include <sys/socket.h> | |
13265 | ||
13266 | _ACEOF | |
13267 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
13268 | $EGREP "socklen_t" >/dev/null 2>&1; then : | |
13269 | bash_cv_type_socklen_t=yes | |
13270 | else | |
13271 | bash_cv_type_socklen_t=no | |
13272 | fi | |
13273 | rm -f conftest* | |
13274 | ||
13275 | fi | |
13276 | ||
13277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_socklen_t" >&5 | |
13278 | $as_echo "$bash_cv_type_socklen_t" >&6; } | |
13279 | if test $bash_cv_type_socklen_t = yes; then | |
13280 | $as_echo "#define HAVE_SOCKLEN_T 1" >>confdefs.h | |
13281 | ||
13282 | fi | |
13283 | if test $bash_cv_type_socklen_t = no; then | |
13284 | cat >>confdefs.h <<_ACEOF | |
13285 | #define socklen_t int | |
13286 | _ACEOF | |
2dead0c4 | 13287 | |
7f947b68 | 13288 | fi |
2dead0c4 | 13289 | |
7f947b68 CR |
13290 | fi |
13291 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for size and type of struct rlimit fields" >&5 | |
13292 | $as_echo_n "checking for size and type of struct rlimit fields... " >&6; } | |
13293 | if ${bash_cv_type_rlimit+:} false; then : | |
13294 | $as_echo_n "(cached) " >&6 | |
13295 | else | |
13296 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13297 | /* end confdefs.h. */ | |
13298 | #include <sys/types.h> | |
13299 | #include <sys/resource.h> | |
abe2eb5b CR |
13300 | int |
13301 | main () | |
13302 | { | |
7f947b68 | 13303 | rlim_t xxx; |
abe2eb5b CR |
13304 | ; |
13305 | return 0; | |
13306 | } | |
e3db237e | 13307 | _ACEOF |
7f947b68 CR |
13308 | if ac_fn_c_try_compile "$LINENO"; then : |
13309 | bash_cv_type_rlimit=rlim_t | |
abe2eb5b | 13310 | else |
c920c360 | 13311 | |
7f947b68 CR |
13312 | if test "$cross_compiling" = yes; then : |
13313 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&5 | |
13314 | $as_echo "$as_me: WARNING: cannot check quad_t if cross compiling -- defaulting to long" >&2;} | |
13315 | bash_cv_type_rlimit=long | |
13316 | else | |
13317 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
abe2eb5b | 13318 | /* end confdefs.h. */ |
2dead0c4 | 13319 | |
2dead0c4 | 13320 | #include <sys/types.h> |
7f947b68 CR |
13321 | #include <sys/time.h> |
13322 | #include <sys/resource.h> | |
13323 | main() | |
abe2eb5b | 13324 | { |
7f947b68 CR |
13325 | #ifdef HAVE_QUAD_T |
13326 | struct rlimit rl; | |
13327 | if (sizeof(rl.rlim_cur) == sizeof(quad_t)) | |
13328 | exit(0); | |
13329 | #endif | |
13330 | exit(1); | |
abe2eb5b CR |
13331 | } |
13332 | _ACEOF | |
7f947b68 CR |
13333 | if ac_fn_c_try_run "$LINENO"; then : |
13334 | bash_cv_type_rlimit=quad_t | |
abe2eb5b | 13335 | else |
7f947b68 CR |
13336 | bash_cv_type_rlimit=long |
13337 | fi | |
13338 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
13339 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
abe2eb5b | 13340 | fi |
2dead0c4 | 13341 | |
7f947b68 | 13342 | fi |
abe2eb5b | 13343 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7f947b68 | 13344 | |
abe2eb5b | 13345 | fi |
2dead0c4 | 13346 | |
7f947b68 CR |
13347 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_type_rlimit" >&5 |
13348 | $as_echo "$bash_cv_type_rlimit" >&6; } | |
13349 | if test $bash_cv_type_rlimit = quad_t; then | |
13350 | $as_echo "#define RLIMTYPE quad_t" >>confdefs.h | |
13351 | ||
13352 | elif test $bash_cv_type_rlimit = rlim_t; then | |
13353 | $as_echo "#define RLIMTYPE rlim_t" >>confdefs.h | |
13354 | ||
13355 | fi | |
13356 | ||
13357 | ||
13358 | # The cast to long int works around a bug in the HP C Compiler | |
13359 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
13360 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
13361 | # This bug is HP SR number 8606223364. | |
13362 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of intmax_t" >&5 | |
13363 | $as_echo_n "checking size of intmax_t... " >&6; } | |
13364 | if ${ac_cv_sizeof_intmax_t+:} false; then : | |
13365 | $as_echo_n "(cached) " >&6 | |
13366 | else | |
13367 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (intmax_t))" "ac_cv_sizeof_intmax_t" "$ac_includes_default"; then : | |
13368 | ||
13369 | else | |
13370 | if test "$ac_cv_type_intmax_t" = yes; then | |
13371 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
13372 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
13373 | as_fn_error 77 "cannot compute sizeof (intmax_t) | |
13374 | See \`config.log' for more details" "$LINENO" 5; } | |
13375 | else | |
13376 | ac_cv_sizeof_intmax_t=0 | |
13377 | fi | |
abe2eb5b | 13378 | fi |
7f947b68 CR |
13379 | |
13380 | fi | |
13381 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_intmax_t" >&5 | |
13382 | $as_echo "$ac_cv_sizeof_intmax_t" >&6; } | |
13383 | ||
13384 | ||
13385 | ||
13386 | cat >>confdefs.h <<_ACEOF | |
13387 | #define SIZEOF_INTMAX_T $ac_cv_sizeof_intmax_t | |
abe2eb5b | 13388 | _ACEOF |
2dead0c4 | 13389 | |
7f947b68 CR |
13390 | |
13391 | ||
13392 | ||
13393 | ac_fn_c_check_member "$LINENO" "struct termios" "c_line" "ac_cv_member_struct_termios_c_line" " | |
13394 | #include <sys/types.h> | |
13395 | #include <termios.h> | |
13396 | ||
13397 | " | |
13398 | if test "x$ac_cv_member_struct_termios_c_line" = xyes; then : | |
13399 | $as_echo "#define TERMIOS_LDISC 1" >>confdefs.h | |
13400 | ||
13401 | fi | |
13402 | ||
13403 | ||
13404 | ||
13405 | ac_fn_c_check_member "$LINENO" "struct termio" "c_line" "ac_cv_member_struct_termio_c_line" " | |
13406 | #include <sys/types.h> | |
13407 | #include <termio.h> | |
13408 | ||
13409 | " | |
13410 | if test "x$ac_cv_member_struct_termio_c_line" = xyes; then : | |
13411 | $as_echo "#define TERMIO_LDISC 1" >>confdefs.h | |
13412 | ||
ccc6cda3 JA |
13413 | fi |
13414 | ||
a82a04b3 CR |
13415 | |
13416 | ||
7f947b68 | 13417 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_ino" >&5 |
dd4f3dd8 | 13418 | $as_echo_n "checking for struct dirent.d_ino... " >&6; } |
7f947b68 | 13419 | if ${bash_cv_dirent_has_dino+:} false; then : |
dd4f3dd8 | 13420 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 13421 | else |
7f947b68 | 13422 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13423 | /* end confdefs.h. */ |
ccc6cda3 JA |
13424 | |
13425 | #include <stdio.h> | |
13426 | #include <sys/types.h> | |
13427 | #ifdef HAVE_UNISTD_H | |
13428 | # include <unistd.h> | |
13429 | #endif /* HAVE_UNISTD_H */ | |
13430 | #if defined(HAVE_DIRENT_H) | |
13431 | # include <dirent.h> | |
13432 | #else | |
13433 | # define dirent direct | |
13434 | # ifdef HAVE_SYS_NDIR_H | |
13435 | # include <sys/ndir.h> | |
13436 | # endif /* SYSNDIR */ | |
13437 | # ifdef HAVE_SYS_DIR_H | |
13438 | # include <sys/dir.h> | |
13439 | # endif /* SYSDIR */ | |
13440 | # ifdef HAVE_NDIR_H | |
13441 | # include <ndir.h> | |
13442 | # endif | |
13443 | #endif /* HAVE_DIRENT_H */ | |
13444 | ||
f73dda09 JA |
13445 | int |
13446 | main () | |
13447 | { | |
ccc6cda3 JA |
13448 | |
13449 | struct dirent d; int z; z = d.d_ino; | |
13450 | ||
f73dda09 JA |
13451 | ; |
13452 | return 0; | |
13453 | } | |
13454 | _ACEOF | |
7f947b68 | 13455 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
13456 | bash_cv_dirent_has_dino=yes |
13457 | else | |
7f947b68 | 13458 | bash_cv_dirent_has_dino=no |
ccc6cda3 | 13459 | fi |
b709b946 | 13460 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
13461 | fi |
13462 | ||
7f947b68 | 13463 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_dino" >&5 |
dd4f3dd8 | 13464 | $as_echo "$bash_cv_dirent_has_dino" >&6; } |
ccc6cda3 | 13465 | if test $bash_cv_dirent_has_dino = yes; then |
7f947b68 | 13466 | $as_echo "#define HAVE_STRUCT_DIRENT_D_INO 1" >>confdefs.h |
ccc6cda3 JA |
13467 | |
13468 | fi | |
13469 | ||
a82a04b3 | 13470 | |
7f947b68 | 13471 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_fileno" >&5 |
dd4f3dd8 | 13472 | $as_echo_n "checking for struct dirent.d_fileno... " >&6; } |
7f947b68 | 13473 | if ${bash_cv_dirent_has_d_fileno+:} false; then : |
dd4f3dd8 | 13474 | $as_echo_n "(cached) " >&6 |
d166f048 | 13475 | else |
7f947b68 | 13476 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13477 | /* end confdefs.h. */ |
d166f048 JA |
13478 | |
13479 | #include <stdio.h> | |
13480 | #include <sys/types.h> | |
13481 | #ifdef HAVE_UNISTD_H | |
13482 | # include <unistd.h> | |
13483 | #endif /* HAVE_UNISTD_H */ | |
13484 | #if defined(HAVE_DIRENT_H) | |
13485 | # include <dirent.h> | |
13486 | #else | |
13487 | # define dirent direct | |
13488 | # ifdef HAVE_SYS_NDIR_H | |
13489 | # include <sys/ndir.h> | |
13490 | # endif /* SYSNDIR */ | |
13491 | # ifdef HAVE_SYS_DIR_H | |
13492 | # include <sys/dir.h> | |
13493 | # endif /* SYSDIR */ | |
13494 | # ifdef HAVE_NDIR_H | |
13495 | # include <ndir.h> | |
13496 | # endif | |
13497 | #endif /* HAVE_DIRENT_H */ | |
13498 | ||
f73dda09 JA |
13499 | int |
13500 | main () | |
13501 | { | |
d166f048 JA |
13502 | |
13503 | struct dirent d; int z; z = d.d_fileno; | |
13504 | ||
f73dda09 JA |
13505 | ; |
13506 | return 0; | |
13507 | } | |
5c26afb8 | 13508 | _ACEOF |
7f947b68 | 13509 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
13510 | bash_cv_dirent_has_d_fileno=yes |
13511 | else | |
7f947b68 | 13512 | bash_cv_dirent_has_d_fileno=no |
d166f048 | 13513 | fi |
b709b946 | 13514 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13515 | fi |
13516 | ||
7f947b68 | 13517 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_fileno" >&5 |
dd4f3dd8 | 13518 | $as_echo "$bash_cv_dirent_has_d_fileno" >&6; } |
d166f048 | 13519 | if test $bash_cv_dirent_has_d_fileno = yes; then |
7f947b68 | 13520 | $as_echo "#define HAVE_STRUCT_DIRENT_D_FILENO 1" >>confdefs.h |
4931aca6 CR |
13521 | |
13522 | fi | |
13523 | ||
a82a04b3 | 13524 | |
7f947b68 | 13525 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct dirent.d_namlen" >&5 |
dd4f3dd8 | 13526 | $as_echo_n "checking for struct dirent.d_namlen... " >&6; } |
7f947b68 | 13527 | if ${bash_cv_dirent_has_d_namlen+:} false; then : |
dd4f3dd8 | 13528 | $as_echo_n "(cached) " >&6 |
4931aca6 | 13529 | else |
7f947b68 | 13530 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13531 | /* end confdefs.h. */ |
4931aca6 CR |
13532 | |
13533 | #include <stdio.h> | |
13534 | #include <sys/types.h> | |
13535 | #ifdef HAVE_UNISTD_H | |
13536 | # include <unistd.h> | |
13537 | #endif /* HAVE_UNISTD_H */ | |
13538 | #if defined(HAVE_DIRENT_H) | |
13539 | # include <dirent.h> | |
13540 | #else | |
13541 | # define dirent direct | |
13542 | # ifdef HAVE_SYS_NDIR_H | |
13543 | # include <sys/ndir.h> | |
13544 | # endif /* SYSNDIR */ | |
13545 | # ifdef HAVE_SYS_DIR_H | |
13546 | # include <sys/dir.h> | |
13547 | # endif /* SYSDIR */ | |
13548 | # ifdef HAVE_NDIR_H | |
13549 | # include <ndir.h> | |
13550 | # endif | |
13551 | #endif /* HAVE_DIRENT_H */ | |
13552 | ||
13553 | int | |
13554 | main () | |
13555 | { | |
13556 | ||
13557 | struct dirent d; int z; z = d.d_namlen; | |
13558 | ||
13559 | ; | |
13560 | return 0; | |
13561 | } | |
13562 | _ACEOF | |
7f947b68 | 13563 | if ac_fn_c_try_compile "$LINENO"; then : |
4931aca6 CR |
13564 | bash_cv_dirent_has_d_namlen=yes |
13565 | else | |
7f947b68 | 13566 | bash_cv_dirent_has_d_namlen=no |
4931aca6 | 13567 | fi |
b709b946 | 13568 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4931aca6 CR |
13569 | fi |
13570 | ||
7f947b68 | 13571 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dirent_has_d_namlen" >&5 |
dd4f3dd8 | 13572 | $as_echo "$bash_cv_dirent_has_d_namlen" >&6; } |
4931aca6 | 13573 | if test $bash_cv_dirent_has_d_namlen = yes; then |
7f947b68 | 13574 | $as_echo "#define HAVE_STRUCT_DIRENT_D_NAMLEN 1" >>confdefs.h |
d166f048 JA |
13575 | |
13576 | fi | |
13577 | ||
7f947b68 | 13578 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct winsize in sys/ioctl.h and termios.h" >&5 |
dd4f3dd8 | 13579 | $as_echo_n "checking for struct winsize in sys/ioctl.h and termios.h... " >&6; } |
7f947b68 | 13580 | if ${bash_cv_struct_winsize_header+:} false; then : |
dd4f3dd8 | 13581 | $as_echo_n "(cached) " >&6 |
d166f048 | 13582 | else |
7f947b68 | 13583 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13584 | /* end confdefs.h. */ |
d166f048 JA |
13585 | #include <sys/types.h> |
13586 | #include <sys/ioctl.h> | |
f73dda09 JA |
13587 | int |
13588 | main () | |
13589 | { | |
d166f048 | 13590 | struct winsize x; |
f73dda09 JA |
13591 | ; |
13592 | return 0; | |
13593 | } | |
13594 | _ACEOF | |
7f947b68 | 13595 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc JA |
13596 | bash_cv_struct_winsize_header=ioctl_h |
13597 | else | |
7f947b68 | 13598 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13599 | /* end confdefs.h. */ |
cce855bc JA |
13600 | #include <sys/types.h> |
13601 | #include <termios.h> | |
f73dda09 JA |
13602 | int |
13603 | main () | |
13604 | { | |
cce855bc | 13605 | struct winsize x; |
f73dda09 JA |
13606 | ; |
13607 | return 0; | |
13608 | } | |
13609 | _ACEOF | |
7f947b68 | 13610 | if ac_fn_c_try_compile "$LINENO"; then : |
cce855bc | 13611 | bash_cv_struct_winsize_header=termios_h |
d166f048 | 13612 | else |
7f947b68 | 13613 | bash_cv_struct_winsize_header=other |
cce855bc | 13614 | fi |
b709b946 | 13615 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
cce855bc | 13616 | |
d166f048 | 13617 | fi |
b709b946 | 13618 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
13619 | fi |
13620 | ||
cce855bc | 13621 | if test $bash_cv_struct_winsize_header = ioctl_h; then |
7f947b68 | 13622 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: sys/ioctl.h" >&5 |
dd4f3dd8 | 13623 | $as_echo "sys/ioctl.h" >&6; } |
7f947b68 | 13624 | $as_echo "#define STRUCT_WINSIZE_IN_SYS_IOCTL 1" >>confdefs.h |
d166f048 | 13625 | |
cce855bc | 13626 | elif test $bash_cv_struct_winsize_header = termios_h; then |
7f947b68 | 13627 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: termios.h" >&5 |
dd4f3dd8 | 13628 | $as_echo "termios.h" >&6; } |
7f947b68 | 13629 | $as_echo "#define STRUCT_WINSIZE_IN_TERMIOS 1" >>confdefs.h |
cce855bc JA |
13630 | |
13631 | else | |
7f947b68 | 13632 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 |
dd4f3dd8 | 13633 | $as_echo "not found" >&6; } |
d166f048 JA |
13634 | fi |
13635 | ||
7f947b68 | 13636 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval in sys/time.h and time.h" >&5 |
dd4f3dd8 | 13637 | $as_echo_n "checking for struct timeval in sys/time.h and time.h... " >&6; } |
7f947b68 | 13638 | if ${bash_cv_struct_timeval+:} false; then : |
dd4f3dd8 | 13639 | $as_echo_n "(cached) " >&6 |
bb70624e | 13640 | else |
f73dda09 | 13641 | |
7f947b68 | 13642 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13643 | /* end confdefs.h. */ |
bb70624e | 13644 | #include <sys/time.h> |
f73dda09 JA |
13645 | |
13646 | _ACEOF | |
bb70624e | 13647 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
7f947b68 | 13648 | $EGREP "struct timeval" >/dev/null 2>&1; then : |
bb70624e JA |
13649 | bash_cv_struct_timeval=yes |
13650 | else | |
7f947b68 | 13651 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13652 | /* end confdefs.h. */ |
bb70624e | 13653 | #include <time.h> |
f73dda09 JA |
13654 | |
13655 | _ACEOF | |
bb70624e | 13656 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
7f947b68 | 13657 | $EGREP "struct timeval" >/dev/null 2>&1; then : |
bb70624e JA |
13658 | bash_cv_struct_timeval=yes |
13659 | else | |
bb70624e JA |
13660 | bash_cv_struct_timeval=no |
13661 | fi | |
13662 | rm -f conftest* | |
13663 | ||
13664 | fi | |
13665 | rm -f conftest* | |
13666 | ||
a82a04b3 | 13667 | |
bb70624e JA |
13668 | fi |
13669 | ||
7f947b68 | 13670 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timeval" >&5 |
dd4f3dd8 | 13671 | $as_echo "$bash_cv_struct_timeval" >&6; } |
bb70624e | 13672 | if test $bash_cv_struct_timeval = yes; then |
7f947b68 | 13673 | $as_echo "#define HAVE_TIMEVAL 1" >>confdefs.h |
b709b946 | 13674 | |
5e4a95c7 | 13675 | fi |
b709b946 | 13676 | |
7f947b68 CR |
13677 | ac_fn_c_check_member "$LINENO" "struct stat" "st_blocks" "ac_cv_member_struct_stat_st_blocks" "$ac_includes_default" |
13678 | if test "x$ac_cv_member_struct_stat_st_blocks" = xyes; then : | |
f73dda09 | 13679 | |
a82a04b3 | 13680 | cat >>confdefs.h <<_ACEOF |
f73dda09 | 13681 | #define HAVE_STRUCT_STAT_ST_BLOCKS 1 |
a82a04b3 CR |
13682 | _ACEOF |
13683 | ||
f73dda09 JA |
13684 | |
13685 | fi | |
d166f048 | 13686 | |
7f947b68 | 13687 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct tm is in sys/time.h or time.h" >&5 |
dd4f3dd8 | 13688 | $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; } |
7f947b68 | 13689 | if ${ac_cv_struct_tm+:} false; then : |
dd4f3dd8 | 13690 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 13691 | else |
7f947b68 | 13692 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 13693 | /* end confdefs.h. */ |
7117c2d2 JA |
13694 | #include <sys/types.h> |
13695 | #include <time.h> | |
13696 | ||
13697 | int | |
13698 | main () | |
13699 | { | |
dd4f3dd8 CR |
13700 | struct tm tm; |
13701 | int *p = &tm.tm_sec; | |
13702 | return !p; | |
7117c2d2 JA |
13703 | ; |
13704 | return 0; | |
13705 | } | |
13706 | _ACEOF | |
7f947b68 | 13707 | if ac_fn_c_try_compile "$LINENO"; then : |
7117c2d2 JA |
13708 | ac_cv_struct_tm=time.h |
13709 | else | |
7f947b68 | 13710 | ac_cv_struct_tm=sys/time.h |
7117c2d2 | 13711 | fi |
b709b946 | 13712 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
7117c2d2 | 13713 | fi |
7f947b68 | 13714 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tm" >&5 |
dd4f3dd8 | 13715 | $as_echo "$ac_cv_struct_tm" >&6; } |
7117c2d2 JA |
13716 | if test $ac_cv_struct_tm = sys/time.h; then |
13717 | ||
7f947b68 | 13718 | $as_echo "#define TM_IN_SYS_TIME 1" >>confdefs.h |
7117c2d2 JA |
13719 | |
13720 | fi | |
13721 | ||
7f947b68 | 13722 | ac_fn_c_check_member "$LINENO" "struct tm" "tm_zone" "ac_cv_member_struct_tm_tm_zone" "#include <sys/types.h> |
abe2eb5b CR |
13723 | #include <$ac_cv_struct_tm> |
13724 | ||
7f947b68 CR |
13725 | " |
13726 | if test "x$ac_cv_member_struct_tm_tm_zone" = xyes; then : | |
d3ad40de CR |
13727 | |
13728 | cat >>confdefs.h <<_ACEOF | |
13729 | #define HAVE_STRUCT_TM_TM_ZONE 1 | |
13730 | _ACEOF | |
13731 | ||
13732 | ||
13733 | fi | |
13734 | ||
13735 | if test "$ac_cv_member_struct_tm_tm_zone" = yes; then | |
13736 | ||
7f947b68 | 13737 | $as_echo "#define HAVE_TM_ZONE 1" >>confdefs.h |
d3ad40de CR |
13738 | |
13739 | else | |
7f947b68 CR |
13740 | ac_fn_c_check_decl "$LINENO" "tzname" "ac_cv_have_decl_tzname" "#include <time.h> |
13741 | " | |
13742 | if test "x$ac_cv_have_decl_tzname" = xyes; then : | |
13743 | ac_have_decl=1 | |
7117c2d2 | 13744 | else |
7f947b68 | 13745 | ac_have_decl=0 |
abe2eb5b CR |
13746 | fi |
13747 | ||
b709b946 | 13748 | cat >>confdefs.h <<_ACEOF |
7f947b68 | 13749 | #define HAVE_DECL_TZNAME $ac_have_decl |
9d6e5e30 | 13750 | _ACEOF |
9d6e5e30 | 13751 | |
7f947b68 | 13752 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tzname" >&5 |
dd4f3dd8 | 13753 | $as_echo_n "checking for tzname... " >&6; } |
7f947b68 | 13754 | if ${ac_cv_var_tzname+:} false; then : |
dd4f3dd8 | 13755 | $as_echo_n "(cached) " >&6 |
9d6e5e30 | 13756 | else |
7f947b68 | 13757 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
9d6e5e30 CR |
13758 | /* end confdefs.h. */ |
13759 | #include <time.h> | |
b709b946 CR |
13760 | #if !HAVE_DECL_TZNAME |
13761 | extern char *tzname[]; | |
13762 | #endif | |
9d6e5e30 | 13763 | |
b709b946 CR |
13764 | int |
13765 | main () | |
13766 | { | |
13767 | return tzname[0][0]; | |
13768 | ; | |
13769 | return 0; | |
13770 | } | |
13771 | _ACEOF | |
7f947b68 | 13772 | if ac_fn_c_try_link "$LINENO"; then : |
b709b946 CR |
13773 | ac_cv_var_tzname=yes |
13774 | else | |
7f947b68 | 13775 | ac_cv_var_tzname=no |
b709b946 | 13776 | fi |
7f947b68 CR |
13777 | rm -f core conftest.err conftest.$ac_objext \ |
13778 | conftest$ac_exeext conftest.$ac_ext | |
b709b946 | 13779 | fi |
7f947b68 | 13780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_var_tzname" >&5 |
dd4f3dd8 | 13781 | $as_echo "$ac_cv_var_tzname" >&6; } |
b709b946 CR |
13782 | if test $ac_cv_var_tzname = yes; then |
13783 | ||
7f947b68 | 13784 | $as_echo "#define HAVE_TZNAME 1" >>confdefs.h |
b709b946 CR |
13785 | |
13786 | fi | |
13787 | fi | |
13788 | ||
7f947b68 | 13789 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timezone in sys/time.h and time.h" >&5 |
dd4f3dd8 | 13790 | $as_echo_n "checking for struct timezone in sys/time.h and time.h... " >&6; } |
7f947b68 | 13791 | if ${bash_cv_struct_timezone+:} false; then : |
dd4f3dd8 | 13792 | $as_echo_n "(cached) " >&6 |
b709b946 CR |
13793 | else |
13794 | ||
7f947b68 | 13795 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b709b946 CR |
13796 | /* end confdefs.h. */ |
13797 | #include <sys/time.h> | |
13798 | ||
13799 | _ACEOF | |
13800 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 13801 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
b709b946 CR |
13802 | bash_cv_struct_timezone=yes |
13803 | else | |
7f947b68 | 13804 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b709b946 CR |
13805 | /* end confdefs.h. */ |
13806 | #include <time.h> | |
13807 | ||
13808 | _ACEOF | |
13809 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 13810 | $EGREP "struct timezone" >/dev/null 2>&1; then : |
d3a24ed2 CR |
13811 | bash_cv_struct_timezone=yes |
13812 | else | |
13813 | bash_cv_struct_timezone=no | |
13814 | fi | |
13815 | rm -f conftest* | |
13816 | ||
13817 | fi | |
13818 | rm -f conftest* | |
13819 | ||
a82a04b3 | 13820 | |
d3a24ed2 CR |
13821 | fi |
13822 | ||
7f947b68 | 13823 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_struct_timezone" >&5 |
dd4f3dd8 | 13824 | $as_echo "$bash_cv_struct_timezone" >&6; } |
d3a24ed2 | 13825 | if test $bash_cv_struct_timezone = yes; then |
7f947b68 | 13826 | $as_echo "#define HAVE_STRUCT_TIMEZONE 1" >>confdefs.h |
d3a24ed2 CR |
13827 | |
13828 | fi | |
13829 | ||
a82a04b3 | 13830 | |
7f947b68 | 13831 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for offset of exit status in return status from wait" >&5 |
7d92f73f | 13832 | $as_echo_n "checking for offset of exit status in return status from wait... " >&6; } |
7f947b68 | 13833 | if ${bash_cv_wexitstatus_offset+:} false; then : |
7d92f73f CR |
13834 | $as_echo_n "(cached) " >&6 |
13835 | else | |
7f947b68 CR |
13836 | if test "$cross_compiling" = yes; then : |
13837 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&5 | |
7d92f73f CR |
13838 | $as_echo "$as_me: WARNING: cannot check WEXITSTATUS offset if cross compiling -- defaulting to 0" >&2;} |
13839 | bash_cv_wexitstatus_offset=0 | |
13840 | ||
13841 | else | |
7f947b68 | 13842 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
71412226 | 13843 | /* end confdefs.h. */ |
7d92f73f CR |
13844 | |
13845 | #include <stdlib.h> | |
13846 | #include <unistd.h> | |
13847 | ||
13848 | #include <sys/wait.h> | |
13849 | ||
13850 | main(c, v) | |
13851 | int c; | |
13852 | char **v; | |
13853 | { | |
13854 | pid_t pid, p; | |
13855 | int s, i, n; | |
13856 | ||
13857 | s = 0; | |
13858 | pid = fork(); | |
13859 | if (pid == 0) | |
13860 | exit (42); | |
13861 | ||
13862 | /* wait for the process */ | |
13863 | p = wait(&s); | |
13864 | if (p != pid) | |
13865 | exit (255); | |
13866 | ||
13867 | /* crack s */ | |
13868 | for (i = 0; i < (sizeof(s) - 8); i++) | |
13869 | { | |
13870 | n = (s >> i) & 0xff; | |
13871 | if (n == 42) | |
13872 | exit (i); | |
13873 | } | |
13874 | ||
13875 | exit (254); | |
13876 | } | |
13877 | ||
13878 | _ACEOF | |
7f947b68 | 13879 | if ac_fn_c_try_run "$LINENO"; then : |
7d92f73f CR |
13880 | bash_cv_wexitstatus_offset=0 |
13881 | else | |
7f947b68 | 13882 | bash_cv_wexitstatus_offset=$? |
7d92f73f | 13883 | fi |
7f947b68 CR |
13884 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
13885 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7d92f73f CR |
13886 | fi |
13887 | ||
7d92f73f CR |
13888 | fi |
13889 | ||
13890 | if test "$bash_cv_wexitstatus_offset" -gt 32 ; then | |
7f947b68 | 13891 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: bad exit status from test program -- defaulting to 0" >&5 |
7d92f73f CR |
13892 | $as_echo "$as_me: WARNING: bad exit status from test program -- defaulting to 0" >&2;} |
13893 | bash_cv_wexitstatus_offset=0 | |
13894 | fi | |
7f947b68 | 13895 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wexitstatus_offset" >&5 |
7d92f73f CR |
13896 | $as_echo "$bash_cv_wexitstatus_offset" >&6; } |
13897 | ||
13898 | cat >>confdefs.h <<_ACEOF | |
13899 | #define WEXITSTATUS_OFFSET $bash_cv_wexitstatus_offset | |
13900 | _ACEOF | |
13901 | ||
13902 | ||
13903 | ||
278286c9 CR |
13904 | |
13905 | ||
13906 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <time.h>" >&5 | |
13907 | $as_echo_n "checking for struct timespec in <time.h>... " >&6; } | |
13908 | if ${bash_cv_sys_struct_timespec_in_time_h+:} false; then : | |
13909 | $as_echo_n "(cached) " >&6 | |
13910 | else | |
13911 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13912 | /* end confdefs.h. */ | |
13913 | #include <time.h> | |
13914 | ||
13915 | int | |
13916 | main () | |
13917 | { | |
13918 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
13919 | ; | |
13920 | return 0; | |
13921 | } | |
13922 | _ACEOF | |
13923 | if ac_fn_c_try_compile "$LINENO"; then : | |
13924 | bash_cv_sys_struct_timespec_in_time_h=yes | |
13925 | else | |
13926 | bash_cv_sys_struct_timespec_in_time_h=no | |
13927 | fi | |
13928 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13929 | fi | |
13930 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_time_h" >&5 | |
13931 | $as_echo "$bash_cv_sys_struct_timespec_in_time_h" >&6; } | |
13932 | ||
13933 | HAVE_STRUCT_TIMESPEC=0 | |
13934 | TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
13935 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=0 | |
13936 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=0 | |
13937 | if test $bash_cv_sys_struct_timespec_in_time_h = yes; then | |
13938 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
13939 | ||
13940 | $as_echo "#define TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
13941 | ||
13942 | TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
13943 | else | |
13944 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <sys/time.h>" >&5 | |
13945 | $as_echo_n "checking for struct timespec in <sys/time.h>... " >&6; } | |
13946 | if ${bash_cv_sys_struct_timespec_in_sys_time_h+:} false; then : | |
13947 | $as_echo_n "(cached) " >&6 | |
13948 | else | |
13949 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13950 | /* end confdefs.h. */ | |
13951 | #include <sys/time.h> | |
13952 | ||
13953 | int | |
13954 | main () | |
13955 | { | |
13956 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
13957 | ; | |
13958 | return 0; | |
13959 | } | |
13960 | _ACEOF | |
13961 | if ac_fn_c_try_compile "$LINENO"; then : | |
13962 | bash_cv_sys_struct_timespec_in_sys_time_h=yes | |
13963 | else | |
13964 | bash_cv_sys_struct_timespec_in_sys_time_h=no | |
13965 | fi | |
13966 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
13967 | fi | |
13968 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_sys_time_h" >&5 | |
13969 | $as_echo "$bash_cv_sys_struct_timespec_in_sys_time_h" >&6; } | |
13970 | if test $bash_cv_sys_struct_timespec_in_sys_time_h = yes; then | |
13971 | SYS_TIME_H_DEFINES_STRUCT_TIMESPEC=1 | |
13972 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
13973 | ||
13974 | $as_echo "#define SYS_TIME_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
13975 | ||
13976 | else | |
13977 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timespec in <pthread.h>" >&5 | |
13978 | $as_echo_n "checking for struct timespec in <pthread.h>... " >&6; } | |
13979 | if ${bash_cv_sys_struct_timespec_in_pthread_h+:} false; then : | |
13980 | $as_echo_n "(cached) " >&6 | |
13981 | else | |
13982 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
13983 | /* end confdefs.h. */ | |
13984 | #include <pthread.h> | |
13985 | ||
13986 | int | |
13987 | main () | |
13988 | { | |
13989 | static struct timespec x; x.tv_sec = x.tv_nsec; | |
13990 | ; | |
13991 | return 0; | |
13992 | } | |
13993 | _ACEOF | |
13994 | if ac_fn_c_try_compile "$LINENO"; then : | |
13995 | bash_cv_sys_struct_timespec_in_pthread_h=yes | |
13996 | else | |
13997 | bash_cv_sys_struct_timespec_in_pthread_h=no | |
13998 | fi | |
13999 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14000 | fi | |
14001 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_struct_timespec_in_pthread_h" >&5 | |
14002 | $as_echo "$bash_cv_sys_struct_timespec_in_pthread_h" >&6; } | |
14003 | if test $bash_cv_sys_struct_timespec_in_pthread_h = yes; then | |
14004 | PTHREAD_H_DEFINES_STRUCT_TIMESPEC=1 | |
14005 | $as_echo "#define HAVE_STRUCT_TIMESPEC 1" >>confdefs.h | |
14006 | ||
14007 | $as_echo "#define PTHREAD_H_DEFINES_STRUCT_TIMESPEC 1" >>confdefs.h | |
14008 | ||
14009 | fi | |
14010 | fi | |
14011 | fi | |
14012 | ||
14013 | ||
14014 | ||
14015 | ||
14016 | ||
14017 | ||
14018 | ||
14019 | ||
14020 | ||
14021 | 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> | |
14022 | #include <sys/stat.h> | |
14023 | " | |
14024 | if test "x$ac_cv_member_struct_stat_st_atim_tv_nsec" = xyes; then : | |
14025 | ||
14026 | cat >>confdefs.h <<_ACEOF | |
14027 | #define HAVE_STRUCT_STAT_ST_ATIM_TV_NSEC 1 | |
14028 | _ACEOF | |
14029 | ||
14030 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct stat.st_atim is of type struct timespec" >&5 | |
14031 | $as_echo_n "checking whether struct stat.st_atim is of type struct timespec... " >&6; } | |
14032 | if ${ac_cv_typeof_struct_stat_st_atim_is_struct_timespec+:} false; then : | |
14033 | $as_echo_n "(cached) " >&6 | |
14034 | else | |
14035 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
14036 | /* end confdefs.h. */ | |
14037 | ||
14038 | #include <sys/types.h> | |
14039 | #include <sys/stat.h> | |
14040 | #if HAVE_SYS_TIME_H | |
14041 | # include <sys/time.h> | |
14042 | #endif | |
14043 | #include <time.h> | |
14044 | struct timespec ts; | |
14045 | struct stat st; | |
14046 | ||
14047 | int | |
14048 | main () | |
14049 | { | |
14050 | ||
14051 | st.st_atim = ts; | |
14052 | ||
14053 | ; | |
14054 | return 0; | |
14055 | } | |
14056 | _ACEOF | |
14057 | if ac_fn_c_try_compile "$LINENO"; then : | |
14058 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=yes | |
14059 | else | |
14060 | ac_cv_typeof_struct_stat_st_atim_is_struct_timespec=no | |
14061 | fi | |
14062 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
14063 | fi | |
14064 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&5 | |
14065 | $as_echo "$ac_cv_typeof_struct_stat_st_atim_is_struct_timespec" >&6; } | |
14066 | if test $ac_cv_typeof_struct_stat_st_atim_is_struct_timespec = yes; then | |
14067 | ||
14068 | $as_echo "#define TYPEOF_STRUCT_STAT_ST_ATIM_IS_STRUCT_TIMESPEC 1" >>confdefs.h | |
14069 | ||
14070 | fi | |
14071 | else | |
14072 | 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> | |
14073 | #include <sys/stat.h> | |
14074 | " | |
14075 | if test "x$ac_cv_member_struct_stat_st_atimespec_tv_nsec" = xyes; then : | |
14076 | ||
14077 | cat >>confdefs.h <<_ACEOF | |
14078 | #define HAVE_STRUCT_STAT_ST_ATIMESPEC_TV_NSEC 1 | |
14079 | _ACEOF | |
14080 | ||
14081 | ||
14082 | else | |
14083 | ac_fn_c_check_member "$LINENO" "struct stat" "st_atimensec" "ac_cv_member_struct_stat_st_atimensec" "#include <sys/types.h> | |
14084 | #include <sys/stat.h> | |
14085 | " | |
14086 | if test "x$ac_cv_member_struct_stat_st_atimensec" = xyes; then : | |
14087 | ||
14088 | cat >>confdefs.h <<_ACEOF | |
14089 | #define HAVE_STRUCT_STAT_ST_ATIMENSEC 1 | |
14090 | _ACEOF | |
14091 | ||
14092 | ||
14093 | else | |
14094 | 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> | |
14095 | #include <sys/stat.h> | |
14096 | " | |
14097 | if test "x$ac_cv_member_struct_stat_st_atim_st__tim_tv_nsec" = xyes; then : | |
14098 | ||
14099 | cat >>confdefs.h <<_ACEOF | |
14100 | #define HAVE_STRUCT_STAT_ST_ATIM_ST__TIM_TV_NSEC 1 | |
14101 | _ACEOF | |
14102 | ||
14103 | ||
14104 | fi | |
14105 | ||
14106 | fi | |
14107 | ||
14108 | fi | |
14109 | ||
14110 | fi | |
14111 | ||
14112 | ||
14113 | ||
7f947b68 | 14114 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for the existence of strsignal" >&5 |
dd4f3dd8 | 14115 | $as_echo_n "checking for the existence of strsignal... " >&6; } |
7f947b68 | 14116 | if ${bash_cv_have_strsignal+:} false; then : |
dd4f3dd8 | 14117 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14118 | else |
7f947b68 | 14119 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14120 | /* end confdefs.h. */ |
ccc6cda3 JA |
14121 | #include <sys/types.h> |
14122 | #include <signal.h> | |
f73dda09 JA |
14123 | int |
14124 | main () | |
14125 | { | |
ccc6cda3 | 14126 | char *s = (char *)strsignal(2); |
7f947b68 CR |
14127 | ; |
14128 | return 0; | |
14129 | } | |
14130 | _ACEOF | |
14131 | if ac_fn_c_try_link "$LINENO"; then : | |
ccc6cda3 JA |
14132 | bash_cv_have_strsignal=yes |
14133 | else | |
7f947b68 | 14134 | bash_cv_have_strsignal=no |
ccc6cda3 | 14135 | fi |
7f947b68 CR |
14136 | rm -f core conftest.err conftest.$ac_objext \ |
14137 | conftest$ac_exeext conftest.$ac_ext | |
ccc6cda3 JA |
14138 | fi |
14139 | ||
7f947b68 | 14140 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_have_strsignal" >&5 |
dd4f3dd8 | 14141 | $as_echo "$bash_cv_have_strsignal" >&6; } |
ccc6cda3 | 14142 | if test $bash_cv_have_strsignal = yes; then |
7f947b68 | 14143 | $as_echo "#define HAVE_STRSIGNAL 1" >>confdefs.h |
ccc6cda3 JA |
14144 | |
14145 | fi | |
14146 | ||
7f947b68 | 14147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if opendir() opens non-directories" >&5 |
dd4f3dd8 | 14148 | $as_echo_n "checking if opendir() opens non-directories... " >&6; } |
7f947b68 | 14149 | if ${bash_cv_opendir_not_robust+:} false; then : |
dd4f3dd8 | 14150 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14151 | else |
7f947b68 CR |
14152 | if test "$cross_compiling" = yes; then : |
14153 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14154 | $as_echo "$as_me: WARNING: cannot check opendir if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14155 | bash_cv_opendir_not_robust=no |
14156 | ||
ccc6cda3 | 14157 | else |
7f947b68 | 14158 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14159 | /* end confdefs.h. */ |
ccc6cda3 JA |
14160 | |
14161 | #include <stdio.h> | |
14162 | #include <sys/types.h> | |
14163 | #include <fcntl.h> | |
14164 | #ifdef HAVE_UNISTD_H | |
14165 | # include <unistd.h> | |
14166 | #endif /* HAVE_UNISTD_H */ | |
14167 | #if defined(HAVE_DIRENT_H) | |
14168 | # include <dirent.h> | |
14169 | #else | |
14170 | # define dirent direct | |
14171 | # ifdef HAVE_SYS_NDIR_H | |
14172 | # include <sys/ndir.h> | |
14173 | # endif /* SYSNDIR */ | |
14174 | # ifdef HAVE_SYS_DIR_H | |
14175 | # include <sys/dir.h> | |
14176 | # endif /* SYSDIR */ | |
14177 | # ifdef HAVE_NDIR_H | |
14178 | # include <ndir.h> | |
14179 | # endif | |
14180 | #endif /* HAVE_DIRENT_H */ | |
14181 | main() | |
14182 | { | |
14183 | DIR *dir; | |
bb70624e | 14184 | int fd, err; |
30915f17 | 14185 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
14186 | if (err < 0) { |
14187 | perror("mkdir"); | |
14188 | exit(1); | |
14189 | } | |
30915f17 CR |
14190 | unlink("bash-aclocal/not_a_directory"); |
14191 | fd = open("bash-aclocal/not_a_directory", O_WRONLY|O_CREAT|O_EXCL, 0666); | |
ccc6cda3 JA |
14192 | write(fd, "\n", 1); |
14193 | close(fd); | |
30915f17 CR |
14194 | dir = opendir("bash-aclocal/not_a_directory"); |
14195 | unlink("bash-aclocal/not_a_directory"); | |
14196 | rmdir("bash-aclocal"); | |
ccc6cda3 JA |
14197 | exit (dir == 0); |
14198 | } | |
f73dda09 | 14199 | _ACEOF |
7f947b68 | 14200 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14201 | bash_cv_opendir_not_robust=yes |
14202 | else | |
7f947b68 | 14203 | bash_cv_opendir_not_robust=no |
ccc6cda3 | 14204 | fi |
7f947b68 CR |
14205 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14206 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14207 | fi |
b709b946 | 14208 | |
ccc6cda3 JA |
14209 | fi |
14210 | ||
7f947b68 | 14211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_opendir_not_robust" >&5 |
dd4f3dd8 | 14212 | $as_echo "$bash_cv_opendir_not_robust" >&6; } |
ccc6cda3 | 14213 | if test $bash_cv_opendir_not_robust = yes; then |
7f947b68 | 14214 | $as_echo "#define OPENDIR_NOT_ROBUST 1" >>confdefs.h |
ccc6cda3 JA |
14215 | |
14216 | fi | |
14217 | ||
7f947b68 | 14218 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ulimit can substitute for getdtablesize" >&5 |
dd4f3dd8 | 14219 | $as_echo_n "checking whether ulimit can substitute for getdtablesize... " >&6; } |
7f947b68 | 14220 | if ${bash_cv_ulimit_maxfds+:} false; then : |
dd4f3dd8 | 14221 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14222 | else |
7f947b68 CR |
14223 | if test "$cross_compiling" = yes; then : |
14224 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14225 | $as_echo "$as_me: WARNING: cannot check ulimit if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14226 | bash_cv_ulimit_maxfds=no |
14227 | ||
ccc6cda3 | 14228 | else |
7f947b68 | 14229 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14230 | /* end confdefs.h. */ |
ccc6cda3 JA |
14231 | |
14232 | main() | |
14233 | { | |
14234 | long maxfds = ulimit(4, 0L); | |
14235 | exit (maxfds == -1L); | |
14236 | } | |
14237 | ||
f73dda09 | 14238 | _ACEOF |
7f947b68 | 14239 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14240 | bash_cv_ulimit_maxfds=yes |
14241 | else | |
7f947b68 | 14242 | bash_cv_ulimit_maxfds=no |
547ef914 | 14243 | fi |
7f947b68 CR |
14244 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14245 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
09767ff0 CR |
14246 | fi |
14247 | ||
09767ff0 | 14248 | fi |
547ef914 | 14249 | |
7f947b68 | 14250 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_ulimit_maxfds" >&5 |
dd4f3dd8 | 14251 | $as_echo "$bash_cv_ulimit_maxfds" >&6; } |
2e4498b3 | 14252 | if test $bash_cv_ulimit_maxfds = yes; then |
7f947b68 | 14253 | $as_echo "#define ULIMIT_MAXFDS 1" >>confdefs.h |
2e4498b3 CR |
14254 | |
14255 | fi | |
14256 | ||
14257 | ||
14258 | ||
14259 | ||
14260 | ||
53ac45a3 CR |
14261 | |
14262 | ||
14263 | ||
7f947b68 CR |
14264 | ac_fn_c_check_decl "$LINENO" "fpurge" "ac_cv_have_decl_fpurge" "#include <stdio.h> |
14265 | " | |
14266 | if test "x$ac_cv_have_decl_fpurge" = xyes; then : | |
14267 | ac_have_decl=1 | |
53ac45a3 | 14268 | else |
7f947b68 | 14269 | ac_have_decl=0 |
53ac45a3 | 14270 | fi |
53ac45a3 CR |
14271 | |
14272 | cat >>confdefs.h <<_ACEOF | |
7f947b68 | 14273 | #define HAVE_DECL_FPURGE $ac_have_decl |
abe2eb5b CR |
14274 | _ACEOF |
14275 | ||
14276 | ||
7f947b68 | 14277 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking to see if getenv can be redefined" >&5 |
dd4f3dd8 | 14278 | $as_echo_n "checking to see if getenv can be redefined... " >&6; } |
7f947b68 | 14279 | if ${bash_cv_getenv_redef+:} false; then : |
dd4f3dd8 | 14280 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14281 | else |
7f947b68 CR |
14282 | if test "$cross_compiling" = yes; then : |
14283 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&5 | |
dd4f3dd8 | 14284 | $as_echo "$as_me: WARNING: cannot check getenv redefinition if cross compiling -- defaulting to yes" >&2;} |
cce855bc JA |
14285 | bash_cv_getenv_redef=yes |
14286 | ||
ccc6cda3 | 14287 | else |
7f947b68 | 14288 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14289 | /* end confdefs.h. */ |
ccc6cda3 JA |
14290 | |
14291 | #ifdef HAVE_UNISTD_H | |
14292 | # include <unistd.h> | |
14293 | #endif | |
14294 | #ifndef __STDC__ | |
14295 | # ifndef const | |
14296 | # define const | |
14297 | # endif | |
14298 | #endif | |
14299 | char * | |
14300 | getenv (name) | |
14301 | #if defined (__linux__) || defined (__bsdi__) || defined (convex) | |
14302 | const char *name; | |
14303 | #else | |
14304 | char const *name; | |
14305 | #endif /* !__linux__ && !__bsdi__ && !convex */ | |
14306 | { | |
14307 | return "42"; | |
14308 | } | |
14309 | main() | |
14310 | { | |
14311 | char *s; | |
14312 | /* The next allows this program to run, but does not allow bash to link | |
14313 | when it redefines getenv. I'm not really interested in figuring out | |
14314 | why not. */ | |
14315 | #if defined (NeXT) | |
14316 | exit(1); | |
14317 | #endif | |
14318 | s = getenv("ABCDE"); | |
14319 | exit(s == 0); /* force optimizer to leave getenv in */ | |
14320 | } | |
14321 | ||
f73dda09 | 14322 | _ACEOF |
7f947b68 | 14323 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14324 | bash_cv_getenv_redef=yes |
14325 | else | |
7f947b68 | 14326 | bash_cv_getenv_redef=no |
ccc6cda3 | 14327 | fi |
7f947b68 CR |
14328 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14329 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14330 | fi |
b709b946 | 14331 | |
ccc6cda3 JA |
14332 | fi |
14333 | ||
7f947b68 | 14334 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getenv_redef" >&5 |
dd4f3dd8 | 14335 | $as_echo "$bash_cv_getenv_redef" >&6; } |
ccc6cda3 | 14336 | if test $bash_cv_getenv_redef = yes; then |
7f947b68 | 14337 | $as_echo "#define CAN_REDEFINE_GETENV 1" >>confdefs.h |
ccc6cda3 JA |
14338 | |
14339 | fi | |
14340 | ||
7117c2d2 | 14341 | if test "$ac_cv_func_getcwd" = "yes"; then |
7f947b68 | 14342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getcwd() will dynamically allocate memory with 0 size" >&5 |
dd4f3dd8 | 14343 | $as_echo_n "checking if getcwd() will dynamically allocate memory with 0 size... " >&6; } |
7f947b68 | 14344 | if ${bash_cv_getcwd_malloc+:} false; then : |
dd4f3dd8 | 14345 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14346 | else |
7f947b68 CR |
14347 | if test "$cross_compiling" = yes; then : |
14348 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14349 | $as_echo "$as_me: WARNING: cannot check whether getcwd allocates memory when cross-compiling -- defaulting to no" >&2;} |
f085a21f | 14350 | bash_cv_getcwd_malloc=no |
cce855bc | 14351 | |
ccc6cda3 | 14352 | else |
7f947b68 | 14353 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14354 | /* end confdefs.h. */ |
ccc6cda3 JA |
14355 | |
14356 | #include <stdio.h> | |
14357 | #ifdef HAVE_UNISTD_H | |
14358 | #include <unistd.h> | |
14359 | #endif | |
14360 | ||
ccc6cda3 JA |
14361 | main() |
14362 | { | |
f085a21f CR |
14363 | char *xpwd; |
14364 | xpwd = getcwd(0, 0); | |
14365 | exit (xpwd == 0); | |
ccc6cda3 JA |
14366 | } |
14367 | ||
f73dda09 | 14368 | _ACEOF |
7f947b68 | 14369 | if ac_fn_c_try_run "$LINENO"; then : |
f085a21f | 14370 | bash_cv_getcwd_malloc=yes |
ccc6cda3 | 14371 | else |
7f947b68 | 14372 | bash_cv_getcwd_malloc=no |
ccc6cda3 | 14373 | fi |
7f947b68 CR |
14374 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14375 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14376 | fi |
b709b946 | 14377 | |
ccc6cda3 JA |
14378 | fi |
14379 | ||
7f947b68 | 14380 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getcwd_malloc" >&5 |
dd4f3dd8 | 14381 | $as_echo "$bash_cv_getcwd_malloc" >&6; } |
f085a21f | 14382 | if test $bash_cv_getcwd_malloc = no; then |
7f947b68 | 14383 | $as_echo "#define GETCWD_BROKEN 1" >>confdefs.h |
a82a04b3 | 14384 | |
b709b946 | 14385 | case " $LIBOBJS " in |
5e4a95c7 | 14386 | *" getcwd.$ac_objext "* ) ;; |
b709b946 CR |
14387 | *) LIBOBJS="$LIBOBJS getcwd.$ac_objext" |
14388 | ;; | |
5e4a95c7 CR |
14389 | esac |
14390 | ||
ccc6cda3 JA |
14391 | fi |
14392 | ||
ccc6cda3 JA |
14393 | fi |
14394 | ||
7f947b68 | 14395 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of POSIX-style sigsetjmp/siglongjmp" >&5 |
dd4f3dd8 | 14396 | $as_echo_n "checking for presence of POSIX-style sigsetjmp/siglongjmp... " >&6; } |
7f947b68 | 14397 | if ${bash_cv_func_sigsetjmp+:} false; then : |
dd4f3dd8 | 14398 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14399 | else |
7f947b68 CR |
14400 | if test "$cross_compiling" = yes; then : |
14401 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 14402 | $as_echo "$as_me: WARNING: cannot check for sigsetjmp/siglongjmp if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
14403 | bash_cv_func_sigsetjmp=missing |
14404 | ||
ccc6cda3 | 14405 | else |
7f947b68 | 14406 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14407 | /* end confdefs.h. */ |
ccc6cda3 JA |
14408 | |
14409 | #ifdef HAVE_UNISTD_H | |
14410 | #include <unistd.h> | |
14411 | #endif | |
14412 | #include <sys/types.h> | |
14413 | #include <signal.h> | |
14414 | #include <setjmp.h> | |
14415 | ||
14416 | main() | |
14417 | { | |
14418 | #if !defined (_POSIX_VERSION) || !defined (HAVE_POSIX_SIGNALS) | |
14419 | exit (1); | |
14420 | #else | |
14421 | ||
14422 | int code; | |
14423 | sigset_t set, oset; | |
14424 | sigjmp_buf xx; | |
14425 | ||
14426 | /* get the mask */ | |
14427 | sigemptyset(&set); | |
14428 | sigemptyset(&oset); | |
14429 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &set); | |
14430 | sigprocmask(SIG_BLOCK, (sigset_t *)NULL, &oset); | |
14431 | ||
14432 | /* save it */ | |
14433 | code = sigsetjmp(xx, 1); | |
14434 | if (code) | |
14435 | exit(0); /* could get sigmask and compare to oset here. */ | |
14436 | ||
14437 | /* change it */ | |
14438 | sigaddset(&set, SIGINT); | |
14439 | sigprocmask(SIG_BLOCK, &set, (sigset_t *)NULL); | |
14440 | ||
14441 | /* and siglongjmp */ | |
14442 | siglongjmp(xx, 10); | |
14443 | exit(1); | |
14444 | #endif | |
14445 | } | |
f73dda09 | 14446 | _ACEOF |
7f947b68 | 14447 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14448 | bash_cv_func_sigsetjmp=present |
14449 | else | |
7f947b68 | 14450 | bash_cv_func_sigsetjmp=missing |
ccc6cda3 | 14451 | fi |
7f947b68 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 | ||
7f947b68 | 14458 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_sigsetjmp" >&5 |
dd4f3dd8 | 14459 | $as_echo "$bash_cv_func_sigsetjmp" >&6; } |
ccc6cda3 | 14460 | if test $bash_cv_func_sigsetjmp = present; then |
7f947b68 | 14461 | $as_echo "#define HAVE_POSIX_SIGSETJMP 1" >>confdefs.h |
ccc6cda3 JA |
14462 | |
14463 | fi | |
14464 | ||
a82a04b3 | 14465 | |
7f947b68 | 14466 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether or not strcoll and strcmp differ" >&5 |
dd4f3dd8 | 14467 | $as_echo_n "checking whether or not strcoll and strcmp differ... " >&6; } |
7f947b68 | 14468 | if ${bash_cv_func_strcoll_broken+:} false; then : |
dd4f3dd8 | 14469 | $as_echo_n "(cached) " >&6 |
d166f048 | 14470 | else |
7f947b68 CR |
14471 | if test "$cross_compiling" = yes; then : |
14472 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14473 | $as_echo "$as_me: WARNING: cannot check strcoll if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14474 | bash_cv_func_strcoll_broken=no |
14475 | ||
d166f048 | 14476 | else |
7f947b68 | 14477 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14478 | /* end confdefs.h. */ |
d166f048 JA |
14479 | |
14480 | #include <stdio.h> | |
14481 | #if defined (HAVE_LOCALE_H) | |
14482 | #include <locale.h> | |
14483 | #endif | |
14484 | ||
14485 | main(c, v) | |
14486 | int c; | |
14487 | char *v[]; | |
14488 | { | |
14489 | int r1, r2; | |
14490 | char *deflocale, *defcoll; | |
14491 | ||
14492 | #ifdef HAVE_SETLOCALE | |
14493 | deflocale = setlocale(LC_ALL, ""); | |
14494 | defcoll = setlocale(LC_COLLATE, ""); | |
14495 | #endif | |
14496 | ||
14497 | #ifdef HAVE_STRCOLL | |
14498 | /* These two values are taken from tests/glob-test. */ | |
14499 | r1 = strcoll("abd", "aXd"); | |
14500 | #else | |
14501 | r1 = 0; | |
14502 | #endif | |
14503 | r2 = strcmp("abd", "aXd"); | |
14504 | ||
14505 | /* These two should both be greater than 0. It is permissible for | |
14506 | a system to return different values, as long as the sign is the | |
14507 | same. */ | |
14508 | ||
14509 | /* Exit with 1 (failure) if these two values are both > 0, since | |
14510 | this tests whether strcoll(3) is broken with respect to strcmp(3) | |
14511 | in the default locale. */ | |
14512 | exit (r1 > 0 && r2 > 0); | |
14513 | } | |
14514 | ||
f73dda09 | 14515 | _ACEOF |
7f947b68 | 14516 | if ac_fn_c_try_run "$LINENO"; then : |
d166f048 JA |
14517 | bash_cv_func_strcoll_broken=yes |
14518 | else | |
7f947b68 | 14519 | bash_cv_func_strcoll_broken=no |
d166f048 | 14520 | fi |
7f947b68 CR |
14521 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14522 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
d166f048 | 14523 | fi |
b709b946 | 14524 | |
d166f048 JA |
14525 | fi |
14526 | ||
7f947b68 | 14527 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_strcoll_broken" >&5 |
dd4f3dd8 | 14528 | $as_echo "$bash_cv_func_strcoll_broken" >&6; } |
d166f048 | 14529 | if test $bash_cv_func_strcoll_broken = yes; then |
7f947b68 | 14530 | $as_echo "#define STRCOLL_BROKEN 1" >>confdefs.h |
d166f048 JA |
14531 | |
14532 | fi | |
14533 | ||
a82a04b3 CR |
14534 | |
14535 | ||
cd0ef727 CR |
14536 | |
14537 | ||
cd0ef727 | 14538 | if test X$ac_cv_func_snprintf = Xyes; then |
7f947b68 | 14539 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant snprintf" >&5 |
cd0ef727 | 14540 | $as_echo_n "checking for standard-conformant snprintf... " >&6; } |
7f947b68 | 14541 | if ${bash_cv_func_snprintf+:} false; then : |
cd0ef727 CR |
14542 | $as_echo_n "(cached) " >&6 |
14543 | else | |
7f947b68 CR |
14544 | if test "$cross_compiling" = yes; then : |
14545 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard snprintf if cross-compiling" >&5 | |
cd0ef727 CR |
14546 | $as_echo "$as_me: WARNING: cannot check standard snprintf if cross-compiling" >&2;} |
14547 | bash_cv_func_snprintf=yes | |
14548 | ||
14549 | else | |
7f947b68 | 14550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
cd0ef727 CR |
14551 | /* end confdefs.h. */ |
14552 | ||
14553 | #include <stdio.h> | |
14554 | ||
14555 | main() | |
14556 | { | |
14557 | int n; | |
14558 | n = snprintf (0, 0, "%s", "0123456"); | |
14559 | exit(n != 7); | |
14560 | } | |
14561 | ||
14562 | _ACEOF | |
7f947b68 | 14563 | if ac_fn_c_try_run "$LINENO"; then : |
cd0ef727 CR |
14564 | bash_cv_func_snprintf=yes |
14565 | else | |
7f947b68 | 14566 | bash_cv_func_snprintf=no |
cd0ef727 | 14567 | fi |
7f947b68 CR |
14568 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14569 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cd0ef727 CR |
14570 | fi |
14571 | ||
cd0ef727 | 14572 | fi |
7f947b68 | 14573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_snprintf" >&5 |
cd0ef727 CR |
14574 | $as_echo "$bash_cv_func_snprintf" >&6; } |
14575 | if test $bash_cv_func_snprintf = no; then | |
14576 | ac_cv_func_snprintf=no | |
14577 | fi | |
14578 | fi | |
14579 | if test $ac_cv_func_snprintf = no; then | |
14580 | ||
7f947b68 | 14581 | $as_echo "#define HAVE_SNPRINTF 0" >>confdefs.h |
cd0ef727 CR |
14582 | |
14583 | fi | |
14584 | ||
14585 | ||
14586 | ||
14587 | ||
14588 | ||
cd0ef727 | 14589 | if test X$ac_cv_func_vsnprintf = Xyes; then |
7f947b68 | 14590 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant vsnprintf" >&5 |
cd0ef727 | 14591 | $as_echo_n "checking for standard-conformant vsnprintf... " >&6; } |
7f947b68 | 14592 | if ${bash_cv_func_vsnprintf+:} false; then : |
cd0ef727 CR |
14593 | $as_echo_n "(cached) " >&6 |
14594 | else | |
7f947b68 CR |
14595 | if test "$cross_compiling" = yes; then : |
14596 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check standard vsnprintf if cross-compiling" >&5 | |
cd0ef727 CR |
14597 | $as_echo "$as_me: WARNING: cannot check standard vsnprintf if cross-compiling" >&2;} |
14598 | bash_cv_func_vsnprintf=yes | |
14599 | ||
14600 | else | |
7f947b68 | 14601 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
cd0ef727 CR |
14602 | /* end confdefs.h. */ |
14603 | ||
14604 | #if HAVE_STDARG_H | |
14605 | #include <stdarg.h> | |
14606 | #else | |
14607 | #include <varargs.h> | |
14608 | #endif | |
14609 | #include <stdio.h> | |
14610 | #include <stdlib.h> | |
14611 | ||
14612 | static int | |
14613 | #if HAVE_STDARG_H | |
14614 | foo(const char *fmt, ...) | |
14615 | #else | |
14616 | foo(format, va_alist) | |
14617 | const char *format; | |
14618 | va_dcl | |
14619 | #endif | |
14620 | { | |
14621 | va_list args; | |
14622 | int n; | |
14623 | ||
14624 | #if HAVE_STDARG_H | |
14625 | va_start(args, fmt); | |
14626 | #else | |
14627 | va_start(args); | |
14628 | #endif | |
14629 | n = vsnprintf(0, 0, fmt, args); | |
14630 | va_end (args); | |
14631 | return n; | |
14632 | } | |
14633 | ||
14634 | main() | |
14635 | { | |
14636 | int n; | |
14637 | n = foo("%s", "0123456"); | |
14638 | exit(n != 7); | |
14639 | } | |
14640 | ||
14641 | _ACEOF | |
7f947b68 | 14642 | if ac_fn_c_try_run "$LINENO"; then : |
cd0ef727 CR |
14643 | bash_cv_func_vsnprintf=yes |
14644 | else | |
7f947b68 | 14645 | bash_cv_func_vsnprintf=no |
cd0ef727 | 14646 | fi |
7f947b68 CR |
14647 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14648 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cd0ef727 CR |
14649 | fi |
14650 | ||
cd0ef727 | 14651 | fi |
7f947b68 | 14652 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_func_vsnprintf" >&5 |
cd0ef727 CR |
14653 | $as_echo "$bash_cv_func_vsnprintf" >&6; } |
14654 | if test $bash_cv_func_vsnprintf = no; then | |
14655 | ac_cv_func_vsnprintf=no | |
14656 | fi | |
14657 | fi | |
14658 | if test $ac_cv_func_vsnprintf = no; then | |
14659 | ||
7f947b68 | 14660 | $as_echo "#define HAVE_VSNPRINTF 0" >>confdefs.h |
cd0ef727 CR |
14661 | |
14662 | fi | |
14663 | ||
14664 | ||
14665 | ||
7117c2d2 JA |
14666 | if test "$ac_cv_func_putenv" = "yes"; then |
14667 | ||
a82a04b3 CR |
14668 | |
14669 | ||
7f947b68 | 14670 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant putenv declaration" >&5 |
dd4f3dd8 | 14671 | $as_echo_n "checking for standard-conformant putenv declaration... " >&6; } |
7f947b68 | 14672 | if ${bash_cv_std_putenv+:} false; then : |
dd4f3dd8 | 14673 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14674 | else |
7f947b68 | 14675 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14676 | /* end confdefs.h. */ |
7117c2d2 JA |
14677 | |
14678 | #if STDC_HEADERS | |
14679 | #include <stdlib.h> | |
14680 | #include <stddef.h> | |
14681 | #endif | |
14682 | #ifndef __STDC__ | |
14683 | # ifndef const | |
14684 | # define const | |
14685 | # endif | |
14686 | #endif | |
14687 | #ifdef PROTOTYPES | |
14688 | extern int putenv (char *); | |
14689 | #else | |
14690 | extern int putenv (); | |
14691 | #endif | |
14692 | ||
14693 | int | |
14694 | main () | |
14695 | { | |
14696 | return (putenv == 0); | |
14697 | ; | |
14698 | return 0; | |
14699 | } | |
14700 | _ACEOF | |
7f947b68 | 14701 | if ac_fn_c_try_link "$LINENO"; then : |
7117c2d2 JA |
14702 | bash_cv_std_putenv=yes |
14703 | else | |
7f947b68 | 14704 | bash_cv_std_putenv=no |
7117c2d2 JA |
14705 | |
14706 | fi | |
7f947b68 CR |
14707 | rm -f core conftest.err conftest.$ac_objext \ |
14708 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 14709 | fi |
7f947b68 | 14710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_putenv" >&5 |
dd4f3dd8 | 14711 | $as_echo "$bash_cv_std_putenv" >&6; } |
7117c2d2 | 14712 | if test $bash_cv_std_putenv = yes; then |
7f947b68 | 14713 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
14714 | |
14715 | fi | |
14716 | ||
14717 | else | |
7f947b68 | 14718 | $as_echo "#define HAVE_STD_PUTENV 1" >>confdefs.h |
7117c2d2 JA |
14719 | |
14720 | fi | |
14721 | if test "$ac_cv_func_unsetenv" = "yes"; then | |
14722 | ||
a82a04b3 CR |
14723 | |
14724 | ||
7f947b68 | 14725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for standard-conformant unsetenv declaration" >&5 |
dd4f3dd8 | 14726 | $as_echo_n "checking for standard-conformant unsetenv declaration... " >&6; } |
7f947b68 | 14727 | if ${bash_cv_std_unsetenv+:} false; then : |
dd4f3dd8 | 14728 | $as_echo_n "(cached) " >&6 |
7117c2d2 | 14729 | else |
7f947b68 | 14730 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14731 | /* end confdefs.h. */ |
7117c2d2 JA |
14732 | |
14733 | #if STDC_HEADERS | |
14734 | #include <stdlib.h> | |
14735 | #include <stddef.h> | |
14736 | #endif | |
14737 | #ifndef __STDC__ | |
14738 | # ifndef const | |
14739 | # define const | |
14740 | # endif | |
14741 | #endif | |
14742 | #ifdef PROTOTYPES | |
14743 | extern int unsetenv (const char *); | |
14744 | #else | |
14745 | extern int unsetenv (); | |
14746 | #endif | |
7f947b68 CR |
14747 | |
14748 | int | |
14749 | main () | |
14750 | { | |
14751 | return (unsetenv == 0); | |
14752 | ; | |
14753 | return 0; | |
14754 | } | |
14755 | _ACEOF | |
14756 | if ac_fn_c_try_link "$LINENO"; then : | |
7117c2d2 JA |
14757 | bash_cv_std_unsetenv=yes |
14758 | else | |
7f947b68 | 14759 | bash_cv_std_unsetenv=no |
7117c2d2 JA |
14760 | |
14761 | fi | |
7f947b68 CR |
14762 | rm -f core conftest.err conftest.$ac_objext \ |
14763 | conftest$ac_exeext conftest.$ac_ext | |
7117c2d2 | 14764 | fi |
7f947b68 | 14765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_std_unsetenv" >&5 |
dd4f3dd8 | 14766 | $as_echo "$bash_cv_std_unsetenv" >&6; } |
7117c2d2 | 14767 | if test $bash_cv_std_unsetenv = yes; then |
7f947b68 | 14768 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
14769 | |
14770 | fi | |
14771 | ||
14772 | else | |
7f947b68 | 14773 | $as_echo "#define HAVE_STD_UNSETENV 1" >>confdefs.h |
7117c2d2 JA |
14774 | |
14775 | fi | |
14776 | ||
7f947b68 | 14777 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for printf floating point output in hex notation" >&5 |
dd4f3dd8 | 14778 | $as_echo_n "checking for printf floating point output in hex notation... " >&6; } |
7f947b68 | 14779 | if ${bash_cv_printf_a_format+:} false; then : |
dd4f3dd8 | 14780 | $as_echo_n "(cached) " >&6 |
f73dda09 | 14781 | else |
7f947b68 CR |
14782 | if test "$cross_compiling" = yes; then : |
14783 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check printf if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14784 | $as_echo "$as_me: WARNING: cannot check printf if cross compiling -- defaulting to no" >&2;} |
f73dda09 JA |
14785 | bash_cv_printf_a_format=no |
14786 | ||
14787 | else | |
7f947b68 | 14788 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14789 | /* end confdefs.h. */ |
f73dda09 JA |
14790 | |
14791 | #include <stdio.h> | |
14792 | #include <string.h> | |
14793 | ||
14794 | int | |
14795 | main() | |
14796 | { | |
14797 | double y = 0.0; | |
14798 | char abuf[1024]; | |
14799 | ||
14800 | sprintf(abuf, "%A", y); | |
14801 | exit(strchr(abuf, 'P') == (char *)0); | |
14802 | } | |
14803 | ||
14804 | _ACEOF | |
7f947b68 | 14805 | if ac_fn_c_try_run "$LINENO"; then : |
f73dda09 JA |
14806 | bash_cv_printf_a_format=yes |
14807 | else | |
7f947b68 | 14808 | bash_cv_printf_a_format=no |
f73dda09 | 14809 | fi |
7f947b68 CR |
14810 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14811 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
f73dda09 | 14812 | fi |
b709b946 | 14813 | |
f73dda09 | 14814 | fi |
d166f048 | 14815 | |
7f947b68 | 14816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_printf_a_format" >&5 |
dd4f3dd8 | 14817 | $as_echo "$bash_cv_printf_a_format" >&6; } |
f73dda09 | 14818 | if test $bash_cv_printf_a_format = yes; then |
7f947b68 | 14819 | $as_echo "#define HAVE_PRINTF_A_FORMAT 1" >>confdefs.h |
d166f048 | 14820 | |
f73dda09 | 14821 | fi |
ccc6cda3 | 14822 | |
a82a04b3 CR |
14823 | |
14824 | ||
14825 | ||
7f947b68 | 14826 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if signal handlers must be reinstalled when invoked" >&5 |
dd4f3dd8 | 14827 | $as_echo_n "checking if signal handlers must be reinstalled when invoked... " >&6; } |
7f947b68 | 14828 | if ${bash_cv_must_reinstall_sighandlers+:} false; then : |
dd4f3dd8 | 14829 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14830 | else |
7f947b68 CR |
14831 | if test "$cross_compiling" = yes; then : |
14832 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 14833 | $as_echo "$as_me: WARNING: cannot check signal handling if cross compiling -- defaulting to no" >&2;} |
cce855bc JA |
14834 | bash_cv_must_reinstall_sighandlers=no |
14835 | ||
ccc6cda3 | 14836 | else |
7f947b68 | 14837 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14838 | /* end confdefs.h. */ |
ccc6cda3 JA |
14839 | |
14840 | #include <signal.h> | |
14841 | #ifdef HAVE_UNISTD_H | |
14842 | #include <unistd.h> | |
14843 | #endif | |
14844 | ||
14845 | typedef RETSIGTYPE sigfunc(); | |
14846 | ||
14847 | int nsigint; | |
14848 | ||
14849 | #ifdef HAVE_POSIX_SIGNALS | |
14850 | sigfunc * | |
14851 | set_signal_handler(sig, handler) | |
14852 | int sig; | |
14853 | sigfunc *handler; | |
14854 | { | |
14855 | struct sigaction act, oact; | |
14856 | act.sa_handler = handler; | |
14857 | act.sa_flags = 0; | |
14858 | sigemptyset (&act.sa_mask); | |
14859 | sigemptyset (&oact.sa_mask); | |
14860 | sigaction (sig, &act, &oact); | |
14861 | return (oact.sa_handler); | |
14862 | } | |
14863 | #else | |
14864 | #define set_signal_handler(s, h) signal(s, h) | |
14865 | #endif | |
14866 | ||
14867 | RETSIGTYPE | |
14868 | sigint(s) | |
14869 | int s; | |
14870 | { | |
14871 | nsigint++; | |
14872 | } | |
14873 | ||
14874 | main() | |
14875 | { | |
14876 | nsigint = 0; | |
14877 | set_signal_handler(SIGINT, sigint); | |
14878 | kill((int)getpid(), SIGINT); | |
14879 | kill((int)getpid(), SIGINT); | |
14880 | exit(nsigint != 2); | |
14881 | } | |
14882 | ||
f73dda09 | 14883 | _ACEOF |
7f947b68 | 14884 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14885 | bash_cv_must_reinstall_sighandlers=no |
14886 | else | |
7f947b68 | 14887 | bash_cv_must_reinstall_sighandlers=yes |
ccc6cda3 | 14888 | fi |
7f947b68 CR |
14889 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14890 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14891 | fi |
b709b946 | 14892 | |
ccc6cda3 JA |
14893 | fi |
14894 | ||
7f947b68 | 14895 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_must_reinstall_sighandlers" >&5 |
dd4f3dd8 | 14896 | $as_echo "$bash_cv_must_reinstall_sighandlers" >&6; } |
ccc6cda3 | 14897 | if test $bash_cv_must_reinstall_sighandlers = yes; then |
7f947b68 | 14898 | $as_echo "#define MUST_REINSTALL_SIGHANDLERS 1" >>confdefs.h |
ccc6cda3 JA |
14899 | |
14900 | fi | |
14901 | ||
a82a04b3 | 14902 | |
7f947b68 | 14903 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of necessary job control definitions" >&5 |
dd4f3dd8 | 14904 | $as_echo_n "checking for presence of necessary job control definitions... " >&6; } |
7f947b68 | 14905 | if ${bash_cv_job_control_missing+:} false; then : |
dd4f3dd8 | 14906 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14907 | else |
7f947b68 CR |
14908 | if test "$cross_compiling" = yes; then : |
14909 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 14910 | $as_echo "$as_me: WARNING: cannot check job control if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
14911 | bash_cv_job_control_missing=missing |
14912 | ||
ccc6cda3 | 14913 | else |
7f947b68 | 14914 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14915 | /* end confdefs.h. */ |
ccc6cda3 JA |
14916 | |
14917 | #include <sys/types.h> | |
14918 | #ifdef HAVE_SYS_WAIT_H | |
14919 | #include <sys/wait.h> | |
14920 | #endif | |
14921 | #ifdef HAVE_UNISTD_H | |
14922 | #include <unistd.h> | |
14923 | #endif | |
14924 | #include <signal.h> | |
14925 | ||
14926 | /* Add more tests in here as appropriate. */ | |
14927 | main() | |
14928 | { | |
14929 | /* signal type */ | |
14930 | #if !defined (HAVE_POSIX_SIGNALS) && !defined (HAVE_BSD_SIGNALS) | |
14931 | exit(1); | |
14932 | #endif | |
14933 | ||
14934 | /* signals and tty control. */ | |
14935 | #if !defined (SIGTSTP) || !defined (SIGSTOP) || !defined (SIGCONT) | |
14936 | exit (1); | |
14937 | #endif | |
14938 | ||
14939 | /* process control */ | |
f73dda09 | 14940 | #if !defined (WNOHANG) || !defined (WUNTRACED) |
ccc6cda3 JA |
14941 | exit(1); |
14942 | #endif | |
14943 | ||
14944 | /* Posix systems have tcgetpgrp and waitpid. */ | |
14945 | #if defined (_POSIX_VERSION) && !defined (HAVE_TCGETPGRP) | |
14946 | exit(1); | |
14947 | #endif | |
14948 | ||
14949 | #if defined (_POSIX_VERSION) && !defined (HAVE_WAITPID) | |
14950 | exit(1); | |
14951 | #endif | |
14952 | ||
14953 | /* Other systems have TIOCSPGRP/TIOCGPRGP and wait3. */ | |
14954 | #if !defined (_POSIX_VERSION) && !defined (HAVE_WAIT3) | |
14955 | exit(1); | |
14956 | #endif | |
14957 | ||
14958 | exit(0); | |
14959 | } | |
f73dda09 | 14960 | _ACEOF |
7f947b68 | 14961 | if ac_fn_c_try_run "$LINENO"; then : |
ccc6cda3 JA |
14962 | bash_cv_job_control_missing=present |
14963 | else | |
7f947b68 | 14964 | bash_cv_job_control_missing=missing |
ccc6cda3 | 14965 | fi |
7f947b68 CR |
14966 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
14967 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 14968 | fi |
b709b946 | 14969 | |
ccc6cda3 JA |
14970 | fi |
14971 | ||
7f947b68 | 14972 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_job_control_missing" >&5 |
dd4f3dd8 | 14973 | $as_echo "$bash_cv_job_control_missing" >&6; } |
ccc6cda3 | 14974 | if test $bash_cv_job_control_missing = missing; then |
7f947b68 | 14975 | $as_echo "#define JOB_CONTROL_MISSING 1" >>confdefs.h |
ccc6cda3 JA |
14976 | |
14977 | fi | |
14978 | ||
7f947b68 | 14979 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of named pipes" >&5 |
dd4f3dd8 | 14980 | $as_echo_n "checking for presence of named pipes... " >&6; } |
7f947b68 | 14981 | if ${bash_cv_sys_named_pipes+:} false; then : |
dd4f3dd8 | 14982 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 14983 | else |
7f947b68 CR |
14984 | if test "$cross_compiling" = yes; then : |
14985 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&5 | |
dd4f3dd8 | 14986 | $as_echo "$as_me: WARNING: cannot check for named pipes if cross-compiling -- defaulting to missing" >&2;} |
cce855bc JA |
14987 | bash_cv_sys_named_pipes=missing |
14988 | ||
ccc6cda3 | 14989 | else |
7f947b68 | 14990 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 14991 | /* end confdefs.h. */ |
ccc6cda3 JA |
14992 | |
14993 | #include <sys/types.h> | |
14994 | #include <sys/stat.h> | |
14995 | #ifdef HAVE_UNISTD_H | |
14996 | #include <unistd.h> | |
14997 | #endif | |
14998 | ||
14999 | /* Add more tests in here as appropriate. */ | |
15000 | main() | |
15001 | { | |
bb70624e | 15002 | int fd, err; |
ccc6cda3 JA |
15003 | |
15004 | #if defined (HAVE_MKFIFO) | |
15005 | exit (0); | |
15006 | #endif | |
15007 | ||
15008 | #if !defined (S_IFIFO) && (defined (_POSIX_VERSION) && !defined (S_ISFIFO)) | |
15009 | exit (1); | |
15010 | #endif | |
15011 | ||
15012 | #if defined (NeXT) | |
15013 | exit (1); | |
15014 | #endif | |
30915f17 | 15015 | err = mkdir("bash-aclocal", 0700); |
bb70624e JA |
15016 | if (err < 0) { |
15017 | perror ("mkdir"); | |
15018 | exit(1); | |
15019 | } | |
30915f17 | 15020 | fd = mknod ("bash-aclocal/sh-np-autoconf", 0666 | S_IFIFO, 0); |
bb70624e | 15021 | if (fd == -1) { |
30915f17 | 15022 | rmdir ("bash-aclocal"); |
ccc6cda3 | 15023 | exit (1); |
bb70624e | 15024 | } |
ccc6cda3 | 15025 | close(fd); |
30915f17 CR |
15026 | unlink ("bash-aclocal/sh-np-autoconf"); |
15027 | rmdir ("bash-aclocal"); | |
ccc6cda3 JA |
15028 | exit(0); |
15029 | } | |
f73dda09 | 15030 | _ACEOF |
7f947b68 | 15031 | if ac_fn_c_try_run "$LINENO"; then : |
5e4a95c7 | 15032 | bash_cv_sys_named_pipes=present |
ccc6cda3 | 15033 | else |
7f947b68 | 15034 | bash_cv_sys_named_pipes=missing |
5e4a95c7 | 15035 | fi |
7f947b68 CR |
15036 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15037 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ccc6cda3 | 15038 | fi |
b709b946 | 15039 | |
ccc6cda3 JA |
15040 | fi |
15041 | ||
7f947b68 | 15042 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_sys_named_pipes" >&5 |
dd4f3dd8 | 15043 | $as_echo "$bash_cv_sys_named_pipes" >&6; } |
5e4a95c7 | 15044 | if test $bash_cv_sys_named_pipes = missing; then |
7f947b68 | 15045 | $as_echo "#define NAMED_PIPES_MISSING 1" >>confdefs.h |
5e4a95c7 CR |
15046 | |
15047 | fi | |
15048 | ||
15049 | ||
7f947b68 | 15050 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether termios.h defines TIOCGWINSZ" >&5 |
dd4f3dd8 | 15051 | $as_echo_n "checking whether termios.h defines TIOCGWINSZ... " >&6; } |
7f947b68 | 15052 | if ${ac_cv_sys_tiocgwinsz_in_termios_h+:} false; then : |
dd4f3dd8 | 15053 | $as_echo_n "(cached) " >&6 |
f73dda09 | 15054 | else |
7f947b68 | 15055 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15056 | /* end confdefs.h. */ |
f73dda09 JA |
15057 | #include <sys/types.h> |
15058 | #include <termios.h> | |
15059 | #ifdef TIOCGWINSZ | |
15060 | yes | |
15061 | #endif | |
15062 | ||
15063 | _ACEOF | |
15064 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 15065 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 JA |
15066 | ac_cv_sys_tiocgwinsz_in_termios_h=yes |
15067 | else | |
15068 | ac_cv_sys_tiocgwinsz_in_termios_h=no | |
15069 | fi | |
15070 | rm -f conftest* | |
15071 | ||
15072 | fi | |
7f947b68 | 15073 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_termios_h" >&5 |
dd4f3dd8 | 15074 | $as_echo "$ac_cv_sys_tiocgwinsz_in_termios_h" >&6; } |
d166f048 | 15075 | |
f73dda09 | 15076 | if test $ac_cv_sys_tiocgwinsz_in_termios_h != yes; then |
7f947b68 | 15077 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether sys/ioctl.h defines TIOCGWINSZ" >&5 |
dd4f3dd8 | 15078 | $as_echo_n "checking whether sys/ioctl.h defines TIOCGWINSZ... " >&6; } |
7f947b68 | 15079 | if ${ac_cv_sys_tiocgwinsz_in_sys_ioctl_h+:} false; then : |
dd4f3dd8 | 15080 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15081 | else |
7f947b68 | 15082 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15083 | /* end confdefs.h. */ |
ccc6cda3 JA |
15084 | #include <sys/types.h> |
15085 | #include <sys/ioctl.h> | |
f73dda09 JA |
15086 | #ifdef TIOCGWINSZ |
15087 | yes | |
15088 | #endif | |
15089 | ||
15090 | _ACEOF | |
15091 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
7f947b68 | 15092 | $EGREP "yes" >/dev/null 2>&1; then : |
f73dda09 | 15093 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=yes |
ccc6cda3 | 15094 | else |
f73dda09 | 15095 | ac_cv_sys_tiocgwinsz_in_sys_ioctl_h=no |
ccc6cda3 JA |
15096 | fi |
15097 | rm -f conftest* | |
f73dda09 | 15098 | |
ccc6cda3 | 15099 | fi |
7f947b68 | 15100 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&5 |
dd4f3dd8 | 15101 | $as_echo "$ac_cv_sys_tiocgwinsz_in_sys_ioctl_h" >&6; } |
f73dda09 JA |
15102 | |
15103 | if test $ac_cv_sys_tiocgwinsz_in_sys_ioctl_h = yes; then | |
ccc6cda3 | 15104 | |
7f947b68 | 15105 | $as_echo "#define GWINSZ_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 | 15106 | |
f73dda09 | 15107 | fi |
ccc6cda3 JA |
15108 | fi |
15109 | ||
7f947b68 | 15110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIOCSTAT in sys/ioctl.h" >&5 |
dd4f3dd8 | 15111 | $as_echo_n "checking for TIOCSTAT in sys/ioctl.h... " >&6; } |
7f947b68 | 15112 | if ${bash_cv_tiocstat_in_ioctl+:} false; then : |
dd4f3dd8 | 15113 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15114 | else |
7f947b68 | 15115 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15116 | /* end confdefs.h. */ |
ccc6cda3 JA |
15117 | #include <sys/types.h> |
15118 | #include <sys/ioctl.h> | |
f73dda09 JA |
15119 | int |
15120 | main () | |
15121 | { | |
ccc6cda3 | 15122 | int x = TIOCSTAT; |
f73dda09 JA |
15123 | ; |
15124 | return 0; | |
15125 | } | |
15126 | _ACEOF | |
7f947b68 | 15127 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15128 | bash_cv_tiocstat_in_ioctl=yes |
15129 | else | |
7f947b68 | 15130 | bash_cv_tiocstat_in_ioctl=no |
ccc6cda3 | 15131 | fi |
b709b946 | 15132 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15133 | fi |
15134 | ||
7f947b68 | 15135 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_tiocstat_in_ioctl" >&5 |
dd4f3dd8 | 15136 | $as_echo "$bash_cv_tiocstat_in_ioctl" >&6; } |
f73dda09 | 15137 | if test $bash_cv_tiocstat_in_ioctl = yes; then |
7f947b68 | 15138 | $as_echo "#define TIOCSTAT_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15139 | |
15140 | fi | |
15141 | ||
7f947b68 | 15142 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIONREAD in sys/ioctl.h" >&5 |
dd4f3dd8 | 15143 | $as_echo_n "checking for FIONREAD in sys/ioctl.h... " >&6; } |
7f947b68 | 15144 | if ${bash_cv_fionread_in_ioctl+:} false; then : |
dd4f3dd8 | 15145 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15146 | else |
7f947b68 | 15147 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15148 | /* end confdefs.h. */ |
ccc6cda3 JA |
15149 | #include <sys/types.h> |
15150 | #include <sys/ioctl.h> | |
f73dda09 JA |
15151 | int |
15152 | main () | |
15153 | { | |
ccc6cda3 | 15154 | int x = FIONREAD; |
f73dda09 JA |
15155 | ; |
15156 | return 0; | |
15157 | } | |
15158 | _ACEOF | |
7f947b68 | 15159 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15160 | bash_cv_fionread_in_ioctl=yes |
15161 | else | |
7f947b68 | 15162 | bash_cv_fionread_in_ioctl=no |
ccc6cda3 | 15163 | fi |
b709b946 | 15164 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15165 | fi |
15166 | ||
7f947b68 | 15167 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_fionread_in_ioctl" >&5 |
dd4f3dd8 | 15168 | $as_echo "$bash_cv_fionread_in_ioctl" >&6; } |
f73dda09 | 15169 | if test $bash_cv_fionread_in_ioctl = yes; then |
7f947b68 | 15170 | $as_echo "#define FIONREAD_IN_SYS_IOCTL 1" >>confdefs.h |
ccc6cda3 JA |
15171 | |
15172 | fi | |
15173 | ||
a82a04b3 CR |
15174 | |
15175 | ||
7f947b68 | 15176 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether WCONTINUED flag to waitpid is unavailable or available but broken" >&5 |
dd4f3dd8 | 15177 | $as_echo_n "checking whether WCONTINUED flag to waitpid is unavailable or available but broken... " >&6; } |
7f947b68 | 15178 | if ${bash_cv_wcontinued_broken+:} false; then : |
dd4f3dd8 | 15179 | $as_echo_n "(cached) " >&6 |
cac4cdbf | 15180 | else |
7f947b68 CR |
15181 | if test "$cross_compiling" = yes; then : |
15182 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&5 | |
dd4f3dd8 | 15183 | $as_echo "$as_me: WARNING: cannot check WCONTINUED if cross compiling -- defaulting to no" >&2;} |
cac4cdbf CR |
15184 | bash_cv_wcontinued_broken=no |
15185 | ||
15186 | else | |
7f947b68 | 15187 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15188 | /* end confdefs.h. */ |
cac4cdbf CR |
15189 | |
15190 | #include <sys/types.h> | |
15191 | #include <sys/wait.h> | |
15192 | #include <unistd.h> | |
15193 | #include <errno.h> | |
15194 | ||
15195 | #ifndef errno | |
15196 | extern int errno; | |
15197 | #endif | |
15198 | main() | |
15199 | { | |
15200 | int x; | |
15201 | ||
15202 | x = waitpid(-1, (int *)0, WNOHANG|WCONTINUED); | |
15203 | if (x == -1 && errno == EINVAL) | |
15204 | exit (1); | |
15205 | else | |
15206 | exit (0); | |
15207 | } | |
15208 | ||
15209 | _ACEOF | |
7f947b68 | 15210 | if ac_fn_c_try_run "$LINENO"; then : |
cac4cdbf CR |
15211 | bash_cv_wcontinued_broken=no |
15212 | else | |
7f947b68 | 15213 | bash_cv_wcontinued_broken=yes |
cac4cdbf | 15214 | fi |
7f947b68 CR |
15215 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15216 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
cac4cdbf | 15217 | fi |
b709b946 | 15218 | |
cac4cdbf CR |
15219 | fi |
15220 | ||
7f947b68 | 15221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_wcontinued_broken" >&5 |
dd4f3dd8 | 15222 | $as_echo "$bash_cv_wcontinued_broken" >&6; } |
cac4cdbf | 15223 | if test $bash_cv_wcontinued_broken = yes; then |
7f947b68 | 15224 | $as_echo "#define WCONTINUED_BROKEN 1" >>confdefs.h |
cac4cdbf CR |
15225 | |
15226 | fi | |
15227 | ||
a82a04b3 | 15228 | |
7f947b68 | 15229 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for speed_t in sys/types.h" >&5 |
dd4f3dd8 | 15230 | $as_echo_n "checking for speed_t in sys/types.h... " >&6; } |
7f947b68 | 15231 | if ${bash_cv_speed_t_in_sys_types+:} false; then : |
dd4f3dd8 | 15232 | $as_echo_n "(cached) " >&6 |
d166f048 | 15233 | else |
7f947b68 | 15234 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15235 | /* end confdefs.h. */ |
d166f048 | 15236 | #include <sys/types.h> |
f73dda09 JA |
15237 | int |
15238 | main () | |
15239 | { | |
d166f048 | 15240 | speed_t x; |
f73dda09 JA |
15241 | ; |
15242 | return 0; | |
15243 | } | |
15244 | _ACEOF | |
7f947b68 | 15245 | if ac_fn_c_try_compile "$LINENO"; then : |
d166f048 JA |
15246 | bash_cv_speed_t_in_sys_types=yes |
15247 | else | |
7f947b68 | 15248 | bash_cv_speed_t_in_sys_types=no |
d166f048 | 15249 | fi |
b709b946 | 15250 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
d166f048 JA |
15251 | fi |
15252 | ||
7f947b68 | 15253 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_speed_t_in_sys_types" >&5 |
dd4f3dd8 | 15254 | $as_echo "$bash_cv_speed_t_in_sys_types" >&6; } |
f73dda09 | 15255 | if test $bash_cv_speed_t_in_sys_types = yes; then |
7f947b68 | 15256 | $as_echo "#define SPEED_T_IN_SYS_TYPES 1" >>confdefs.h |
d166f048 JA |
15257 | |
15258 | fi | |
15259 | ||
7f947b68 | 15260 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpw functions are declared in pwd.h" >&5 |
dd4f3dd8 | 15261 | $as_echo_n "checking whether getpw functions are declared in pwd.h... " >&6; } |
7f947b68 | 15262 | if ${bash_cv_getpw_declared+:} false; then : |
dd4f3dd8 | 15263 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15264 | else |
7f947b68 | 15265 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15266 | /* end confdefs.h. */ |
28ef6c31 | 15267 | |
ccc6cda3 | 15268 | #include <sys/types.h> |
28ef6c31 JA |
15269 | #ifdef HAVE_UNISTD_H |
15270 | # include <unistd.h> | |
15271 | #endif | |
ccc6cda3 | 15272 | #include <pwd.h> |
28ef6c31 | 15273 | |
f73dda09 | 15274 | _ACEOF |
28ef6c31 | 15275 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
7f947b68 | 15276 | $EGREP "getpwuid" >/dev/null 2>&1; then : |
28ef6c31 | 15277 | bash_cv_getpw_declared=yes |
ccc6cda3 | 15278 | else |
28ef6c31 | 15279 | bash_cv_getpw_declared=no |
ccc6cda3 JA |
15280 | fi |
15281 | rm -f conftest* | |
28ef6c31 | 15282 | |
ccc6cda3 JA |
15283 | fi |
15284 | ||
7f947b68 | 15285 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_getpw_declared" >&5 |
dd4f3dd8 | 15286 | $as_echo "$bash_cv_getpw_declared" >&6; } |
28ef6c31 | 15287 | if test $bash_cv_getpw_declared = yes; then |
7f947b68 | 15288 | $as_echo "#define HAVE_GETPW_DECLS 1" >>confdefs.h |
ccc6cda3 JA |
15289 | |
15290 | fi | |
15291 | ||
7f947b68 | 15292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unusable real-time signals due to large values" >&5 |
dd4f3dd8 | 15293 | $as_echo_n "checking for unusable real-time signals due to large values... " >&6; } |
7f947b68 | 15294 | if ${bash_cv_unusable_rtsigs+:} false; then : |
dd4f3dd8 | 15295 | $as_echo_n "(cached) " >&6 |
28ef6c31 | 15296 | else |
7f947b68 CR |
15297 | if test "$cross_compiling" = yes; then : |
15298 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&5 | |
dd4f3dd8 | 15299 | $as_echo "$as_me: WARNING: cannot check real-time signals if cross compiling -- defaulting to yes" >&2;} |
28ef6c31 JA |
15300 | bash_cv_unusable_rtsigs=yes |
15301 | ||
15302 | else | |
7f947b68 | 15303 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15304 | /* end confdefs.h. */ |
28ef6c31 JA |
15305 | |
15306 | #include <sys/types.h> | |
15307 | #include <signal.h> | |
15308 | ||
15309 | #ifndef NSIG | |
15310 | # define NSIG 64 | |
15311 | #endif | |
15312 | ||
15313 | main () | |
15314 | { | |
15315 | int n_sigs = 2 * NSIG; | |
15316 | #ifdef SIGRTMIN | |
15317 | int rtmin = SIGRTMIN; | |
15318 | #else | |
15319 | int rtmin = 0; | |
15320 | #endif | |
15321 | ||
15322 | exit(rtmin < n_sigs); | |
15323 | } | |
f73dda09 | 15324 | _ACEOF |
7f947b68 | 15325 | if ac_fn_c_try_run "$LINENO"; then : |
28ef6c31 JA |
15326 | bash_cv_unusable_rtsigs=yes |
15327 | else | |
7f947b68 | 15328 | bash_cv_unusable_rtsigs=no |
28ef6c31 | 15329 | fi |
7f947b68 CR |
15330 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
15331 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
28ef6c31 | 15332 | fi |
b709b946 | 15333 | |
28ef6c31 JA |
15334 | fi |
15335 | ||
7f947b68 | 15336 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_unusable_rtsigs" >&5 |
dd4f3dd8 | 15337 | $as_echo "$bash_cv_unusable_rtsigs" >&6; } |
28ef6c31 | 15338 | if test $bash_cv_unusable_rtsigs = yes; then |
7f947b68 | 15339 | $as_echo "#define UNUSABLE_RT_SIGNALS 1" >>confdefs.h |
28ef6c31 JA |
15340 | |
15341 | fi | |
15342 | ||
a82a04b3 CR |
15343 | |
15344 | ||
15345 | ||
15346 | ||
f73dda09 JA |
15347 | if test "$bash_cv_sys_siglist" = no && test "$bash_cv_under_sys_siglist" = no && test "$bash_cv_have_strsignal" = no; then |
15348 | SIGLIST_O=siglist.o | |
15349 | else | |
15350 | SIGLIST_O= | |
15351 | fi | |
ccc6cda3 | 15352 | |
a82a04b3 CR |
15353 | |
15354 | ||
ccc6cda3 | 15355 | case "$host_os" in |
7f947b68 | 15356 | hpux*) { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $host_os needs _KERNEL for RLIMIT defines" >&5 |
dd4f3dd8 | 15357 | $as_echo_n "checking whether $host_os needs _KERNEL for RLIMIT defines... " >&6; } |
7f947b68 | 15358 | if ${bash_cv_kernel_rlimit+:} false; then : |
dd4f3dd8 | 15359 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15360 | else |
7f947b68 | 15361 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15362 | /* end confdefs.h. */ |
ccc6cda3 JA |
15363 | |
15364 | #include <sys/types.h> | |
15365 | #include <sys/resource.h> | |
15366 | ||
f73dda09 JA |
15367 | int |
15368 | main () | |
15369 | { | |
ccc6cda3 JA |
15370 | |
15371 | int f; | |
15372 | f = RLIMIT_DATA; | |
15373 | ||
f73dda09 JA |
15374 | ; |
15375 | return 0; | |
15376 | } | |
15377 | _ACEOF | |
7f947b68 | 15378 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15379 | bash_cv_kernel_rlimit=no |
15380 | else | |
7f947b68 | 15381 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15382 | /* end confdefs.h. */ |
ccc6cda3 | 15383 | |
cce855bc JA |
15384 | #include <sys/types.h> |
15385 | #define _KERNEL | |
15386 | #include <sys/resource.h> | |
15387 | #undef _KERNEL | |
15388 | ||
f73dda09 JA |
15389 | int |
15390 | main () | |
15391 | { | |
ccc6cda3 JA |
15392 | |
15393 | int f; | |
15394 | f = RLIMIT_DATA; | |
cce855bc | 15395 | |
f73dda09 JA |
15396 | ; |
15397 | return 0; | |
15398 | } | |
15399 | _ACEOF | |
7f947b68 | 15400 | if ac_fn_c_try_compile "$LINENO"; then : |
ccc6cda3 JA |
15401 | bash_cv_kernel_rlimit=yes |
15402 | else | |
7f947b68 | 15403 | bash_cv_kernel_rlimit=no |
ccc6cda3 | 15404 | fi |
b709b946 | 15405 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15406 | |
15407 | fi | |
b709b946 | 15408 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ccc6cda3 JA |
15409 | fi |
15410 | ||
7f947b68 | 15411 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_kernel_rlimit" >&5 |
dd4f3dd8 | 15412 | $as_echo "$bash_cv_kernel_rlimit" >&6; } |
ccc6cda3 | 15413 | if test $bash_cv_kernel_rlimit = yes; then |
7f947b68 | 15414 | $as_echo "#define RLIMIT_NEEDS_KERNEL 1" >>confdefs.h |
ccc6cda3 JA |
15415 | |
15416 | fi | |
15417 | ;; | |
15418 | esac | |
15419 | ||
15420 | if test "$opt_readline" = yes; then | |
d166f048 JA |
15421 | case "$host_os" in |
15422 | aix*) prefer_curses=yes ;; | |
15423 | esac | |
ccc6cda3 JA |
15424 | |
15425 | if test "X$bash_cv_termcap_lib" = "X"; then | |
15426 | _bash_needmsg=yes | |
15427 | else | |
7f947b68 | 15428 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 15429 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 JA |
15430 | _bash_needmsg= |
15431 | fi | |
7f947b68 CR |
15432 | if ${bash_cv_termcap_lib+:} false; then : |
15433 | $as_echo_n "(cached) " >&6 | |
15434 | else | |
15435 | ac_fn_c_check_func "$LINENO" "tgetent" "ac_cv_func_tgetent" | |
15436 | if test "x$ac_cv_func_tgetent" = xyes; then : | |
d3a24ed2 CR |
15437 | bash_cv_termcap_lib=libc |
15438 | else | |
7f947b68 | 15439 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltermcap" >&5 |
dd4f3dd8 | 15440 | $as_echo_n "checking for tgetent in -ltermcap... " >&6; } |
7f947b68 | 15441 | if ${ac_cv_lib_termcap_tgetent+:} false; then : |
dd4f3dd8 | 15442 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15443 | else |
f73dda09 | 15444 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15445 | LIBS="-ltermcap $LIBS" |
7f947b68 | 15446 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15447 | /* end confdefs.h. */ |
f73dda09 | 15448 | |
b709b946 CR |
15449 | /* Override any GCC internal prototype to avoid an error. |
15450 | Use char because int might match the return type of a GCC | |
15451 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15452 | #ifdef __cplusplus |
15453 | extern "C" | |
15454 | #endif | |
f73dda09 JA |
15455 | char tgetent (); |
15456 | int | |
15457 | main () | |
15458 | { | |
b709b946 | 15459 | return tgetent (); |
f73dda09 JA |
15460 | ; |
15461 | return 0; | |
15462 | } | |
15463 | _ACEOF | |
7f947b68 | 15464 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15465 | ac_cv_lib_termcap_tgetent=yes |
15466 | else | |
7f947b68 | 15467 | ac_cv_lib_termcap_tgetent=no |
f73dda09 | 15468 | fi |
7f947b68 CR |
15469 | rm -f core conftest.err conftest.$ac_objext \ |
15470 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15471 | LIBS=$ac_check_lib_save_LIBS |
15472 | fi | |
7f947b68 | 15473 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_termcap_tgetent" >&5 |
dd4f3dd8 | 15474 | $as_echo "$ac_cv_lib_termcap_tgetent" >&6; } |
7f947b68 | 15475 | if test "x$ac_cv_lib_termcap_tgetent" = xyes; then : |
ccc6cda3 JA |
15476 | bash_cv_termcap_lib=libtermcap |
15477 | else | |
7f947b68 | 15478 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -ltinfo" >&5 |
dd4f3dd8 | 15479 | $as_echo_n "checking for tgetent in -ltinfo... " >&6; } |
7f947b68 | 15480 | if ${ac_cv_lib_tinfo_tgetent+:} false; then : |
dd4f3dd8 | 15481 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15482 | else |
f73dda09 JA |
15483 | ac_check_lib_save_LIBS=$LIBS |
15484 | LIBS="-ltinfo $LIBS" | |
7f947b68 | 15485 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15486 | /* end confdefs.h. */ |
f73dda09 | 15487 | |
b709b946 CR |
15488 | /* Override any GCC internal prototype to avoid an error. |
15489 | Use char because int might match the return type of a GCC | |
15490 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15491 | #ifdef __cplusplus |
15492 | extern "C" | |
15493 | #endif | |
f73dda09 JA |
15494 | char tgetent (); |
15495 | int | |
15496 | main () | |
15497 | { | |
b709b946 | 15498 | return tgetent (); |
f73dda09 JA |
15499 | ; |
15500 | return 0; | |
15501 | } | |
15502 | _ACEOF | |
7f947b68 | 15503 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15504 | ac_cv_lib_tinfo_tgetent=yes |
15505 | else | |
7f947b68 | 15506 | ac_cv_lib_tinfo_tgetent=no |
f73dda09 | 15507 | fi |
7f947b68 CR |
15508 | rm -f core conftest.err conftest.$ac_objext \ |
15509 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15510 | LIBS=$ac_check_lib_save_LIBS |
15511 | fi | |
7f947b68 | 15512 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgetent" >&5 |
dd4f3dd8 | 15513 | $as_echo "$ac_cv_lib_tinfo_tgetent" >&6; } |
7f947b68 | 15514 | if test "x$ac_cv_lib_tinfo_tgetent" = xyes; then : |
7117c2d2 | 15515 | bash_cv_termcap_lib=libtinfo |
f73dda09 | 15516 | else |
7f947b68 | 15517 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lcurses" >&5 |
dd4f3dd8 | 15518 | $as_echo_n "checking for tgetent in -lcurses... " >&6; } |
7f947b68 | 15519 | if ${ac_cv_lib_curses_tgetent+:} false; then : |
dd4f3dd8 | 15520 | $as_echo_n "(cached) " >&6 |
f73dda09 JA |
15521 | else |
15522 | ac_check_lib_save_LIBS=$LIBS | |
15523 | LIBS="-lcurses $LIBS" | |
7f947b68 | 15524 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15525 | /* end confdefs.h. */ |
ccc6cda3 | 15526 | |
b709b946 CR |
15527 | /* Override any GCC internal prototype to avoid an error. |
15528 | Use char because int might match the return type of a GCC | |
15529 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15530 | #ifdef __cplusplus |
15531 | extern "C" | |
15532 | #endif | |
f73dda09 JA |
15533 | char tgetent (); |
15534 | int | |
15535 | main () | |
15536 | { | |
b709b946 | 15537 | return tgetent (); |
f73dda09 JA |
15538 | ; |
15539 | return 0; | |
15540 | } | |
15541 | _ACEOF | |
7f947b68 | 15542 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15543 | ac_cv_lib_curses_tgetent=yes |
15544 | else | |
7f947b68 | 15545 | ac_cv_lib_curses_tgetent=no |
f73dda09 | 15546 | fi |
7f947b68 CR |
15547 | rm -f core conftest.err conftest.$ac_objext \ |
15548 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15549 | LIBS=$ac_check_lib_save_LIBS |
15550 | fi | |
7f947b68 | 15551 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_curses_tgetent" >&5 |
dd4f3dd8 | 15552 | $as_echo "$ac_cv_lib_curses_tgetent" >&6; } |
7f947b68 | 15553 | if test "x$ac_cv_lib_curses_tgetent" = xyes; then : |
ccc6cda3 JA |
15554 | bash_cv_termcap_lib=libcurses |
15555 | else | |
7f947b68 | 15556 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgetent in -lncurses" >&5 |
dd4f3dd8 | 15557 | $as_echo_n "checking for tgetent in -lncurses... " >&6; } |
7f947b68 | 15558 | if ${ac_cv_lib_ncurses_tgetent+:} false; then : |
dd4f3dd8 | 15559 | $as_echo_n "(cached) " >&6 |
ccc6cda3 | 15560 | else |
f73dda09 | 15561 | ac_check_lib_save_LIBS=$LIBS |
ccc6cda3 | 15562 | LIBS="-lncurses $LIBS" |
7f947b68 | 15563 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5e4a95c7 | 15564 | /* end confdefs.h. */ |
f73dda09 | 15565 | |
b709b946 CR |
15566 | /* Override any GCC internal prototype to avoid an error. |
15567 | Use char because int might match the return type of a GCC | |
15568 | builtin and then its argument prototype would still apply. */ | |
f73dda09 JA |
15569 | #ifdef __cplusplus |
15570 | extern "C" | |
15571 | #endif | |
f73dda09 JA |
15572 | char tgetent (); |
15573 | int | |
15574 | main () | |
15575 | { | |
b709b946 | 15576 | return tgetent (); |
f73dda09 JA |
15577 | ; |
15578 | return 0; | |
15579 | } | |
15580 | _ACEOF | |
7f947b68 | 15581 | if ac_fn_c_try_link "$LINENO"; then : |
f73dda09 JA |
15582 | ac_cv_lib_ncurses_tgetent=yes |
15583 | else | |
7f947b68 | 15584 | ac_cv_lib_ncurses_tgetent=no |
f73dda09 | 15585 | fi |
7f947b68 CR |
15586 | rm -f core conftest.err conftest.$ac_objext \ |
15587 | conftest$ac_exeext conftest.$ac_ext | |
f73dda09 JA |
15588 | LIBS=$ac_check_lib_save_LIBS |
15589 | fi | |
7f947b68 | 15590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_tgetent" >&5 |
dd4f3dd8 | 15591 | $as_echo "$ac_cv_lib_ncurses_tgetent" >&6; } |
7f947b68 | 15592 | if test "x$ac_cv_lib_ncurses_tgetent" = xyes; then : |
f73dda09 | 15593 | bash_cv_termcap_lib=libncurses |
ccc6cda3 | 15594 | else |
f73dda09 | 15595 | bash_cv_termcap_lib=gnutermcap |
ccc6cda3 | 15596 | fi |
ccc6cda3 | 15597 | |
ccc6cda3 JA |
15598 | fi |
15599 | ||
15600 | fi | |
15601 | ||
15602 | fi | |
15603 | ||
15604 | fi | |
15605 | ||
d3a24ed2 CR |
15606 | fi |
15607 | ||
ccc6cda3 | 15608 | if test "X$_bash_needmsg" = "Xyes"; then |
7f947b68 | 15609 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking which library has the termcap functions" >&5 |
dd4f3dd8 | 15610 | $as_echo_n "checking which library has the termcap functions... " >&6; } |
ccc6cda3 | 15611 | fi |
7f947b68 | 15612 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: using $bash_cv_termcap_lib" >&5 |
dd4f3dd8 | 15613 | $as_echo "using $bash_cv_termcap_lib" >&6; } |
cce855bc | 15614 | if test $bash_cv_termcap_lib = gnutermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15615 | LDFLAGS="$LDFLAGS -L./lib/termcap" |
15616 | TERMCAP_LIB="./lib/termcap/libtermcap.a" | |
15617 | TERMCAP_DEP="./lib/termcap/libtermcap.a" | |
d166f048 | 15618 | elif test $bash_cv_termcap_lib = libtermcap && test -z "$prefer_curses"; then |
ccc6cda3 JA |
15619 | TERMCAP_LIB=-ltermcap |
15620 | TERMCAP_DEP= | |
f73dda09 JA |
15621 | elif test $bash_cv_termcap_lib = libtinfo; then |
15622 | TERMCAP_LIB=-ltinfo | |
15623 | TERMCAP_DEP= | |
ccc6cda3 JA |
15624 | elif test $bash_cv_termcap_lib = libncurses; then |
15625 | TERMCAP_LIB=-lncurses | |
15626 | TERMCAP_DEP= | |
d3a24ed2 CR |
15627 | elif test $bash_cv_termcap_lib = libc; then |
15628 | TERMCAP_LIB= | |
15629 | TERMCAP_DEP= | |
ccc6cda3 JA |
15630 | else |
15631 | TERMCAP_LIB=-lcurses | |
15632 | TERMCAP_DEP= | |
15633 | fi | |
15634 | ||
15635 | fi | |
15636 | ||
a82a04b3 CR |
15637 | |
15638 | ||
7f947b68 | 15639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/fd is available" >&5 |
dd4f3dd8 | 15640 | $as_echo_n "checking whether /dev/fd is available... " >&6; } |
7f947b68 | 15641 | if ${bash_cv_dev_fd+:} false; then : |
dd4f3dd8 | 15642 | $as_echo_n "(cached) " >&6 |
d166f048 | 15643 | else |
d3ad40de CR |
15644 | bash_cv_dev_fd="" |
15645 | if test -d /dev/fd && (exec test -r /dev/fd/0 < /dev/null) ; then | |
de3341d1 | 15646 | # check for systems like FreeBSD 5 that only provide /dev/fd/[012] |
d3ad40de | 15647 | if (exec test -r /dev/fd/3 3</dev/null) ; then |
de3341d1 CR |
15648 | bash_cv_dev_fd=standard |
15649 | else | |
15650 | bash_cv_dev_fd=absent | |
15651 | fi | |
d3ad40de CR |
15652 | fi |
15653 | if test -z "$bash_cv_dev_fd" ; then | |
15654 | if test -d /proc/self/fd && (exec test -r /proc/self/fd/0 < /dev/null) ; then | |
15655 | bash_cv_dev_fd=whacky | |
15656 | else | |
15657 | bash_cv_dev_fd=absent | |
15658 | fi | |
15659 | fi | |
d166f048 JA |
15660 | |
15661 | fi | |
15662 | ||
7f947b68 | 15663 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_fd" >&5 |
dd4f3dd8 | 15664 | $as_echo "$bash_cv_dev_fd" >&6; } |
d166f048 | 15665 | if test $bash_cv_dev_fd = "standard"; then |
7f947b68 | 15666 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15667 | |
7f947b68 | 15668 | $as_echo "#define DEV_FD_PREFIX \"/dev/fd/\"" >>confdefs.h |
d166f048 JA |
15669 | |
15670 | elif test $bash_cv_dev_fd = "whacky"; then | |
7f947b68 | 15671 | $as_echo "#define HAVE_DEV_FD 1" >>confdefs.h |
d166f048 | 15672 | |
7f947b68 | 15673 | $as_echo "#define DEV_FD_PREFIX \"/proc/self/fd/\"" >>confdefs.h |
d166f048 JA |
15674 | |
15675 | fi | |
15676 | ||
7f947b68 | 15677 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether /dev/stdin stdout stderr are available" >&5 |
dd4f3dd8 | 15678 | $as_echo_n "checking whether /dev/stdin stdout stderr are available... " >&6; } |
7f947b68 | 15679 | if ${bash_cv_dev_stdin+:} false; then : |
dd4f3dd8 | 15680 | $as_echo_n "(cached) " >&6 |
bb70624e | 15681 | else |
d3ad40de | 15682 | if test -d /dev/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e | 15683 | bash_cv_dev_stdin=present |
d3ad40de | 15684 | elif test -d /proc/self/fd && (exec test -r /dev/stdin < /dev/null) ; then |
bb70624e JA |
15685 | bash_cv_dev_stdin=present |
15686 | else | |
15687 | bash_cv_dev_stdin=absent | |
15688 | fi | |
15689 | ||
15690 | fi | |
15691 | ||
7f947b68 | 15692 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_dev_stdin" >&5 |
dd4f3dd8 | 15693 | $as_echo "$bash_cv_dev_stdin" >&6; } |
bb70624e | 15694 | if test $bash_cv_dev_stdin = "present"; then |
7f947b68 | 15695 | $as_echo "#define HAVE_DEV_STDIN 1" >>confdefs.h |
bb70624e JA |
15696 | |
15697 | fi | |
15698 | ||
7f947b68 | 15699 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for default mail directory" >&5 |
dd4f3dd8 | 15700 | $as_echo_n "checking for default mail directory... " >&6; } |
7f947b68 | 15701 | if ${bash_cv_mail_dir+:} false; then : |
dd4f3dd8 | 15702 | $as_echo_n "(cached) " >&6 |
ccc6cda3 JA |
15703 | else |
15704 | if test -d /var/mail; then | |
15705 | bash_cv_mail_dir=/var/mail | |
ccc6cda3 JA |
15706 | elif test -d /var/spool/mail; then |
15707 | bash_cv_mail_dir=/var/spool/mail | |
7117c2d2 JA |
15708 | elif test -d /usr/mail; then |
15709 | bash_cv_mail_dir=/usr/mail | |
e8ce775d JA |
15710 | elif test -d /usr/spool/mail; then |
15711 | bash_cv_mail_dir=/usr/spool/mail | |
ccc6cda3 JA |
15712 | else |
15713 | bash_cv_mail_dir=unknown | |
15714 | fi | |
15715 | ||
15716 | fi | |
15717 | ||
7f947b68 | 15718 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $bash_cv_mail_dir" >&5 |
dd4f3dd8 | 15719 | $as_echo "$bash_cv_mail_dir" >&6; } |
a82a04b3 | 15720 | cat >>confdefs.h <<_ACEOF |
7117c2d2 | 15721 | #define DEFAULT_MAIL_DIRECTORY "$bash_cv_mail_dir" |
a82a04b3 CR |
15722 | _ACEOF |
15723 | ||
15724 | ||
ccc6cda3 | 15725 | |
ccc6cda3 JA |
15726 | if test "$bash_cv_job_control_missing" = missing; then |
15727 | opt_job_control=no | |
15728 | fi | |
15729 | ||
15730 | if test "$opt_job_control" = yes; then | |
7f947b68 | 15731 | $as_echo "#define JOB_CONTROL 1" >>confdefs.h |
ccc6cda3 JA |
15732 | |
15733 | JOBS_O=jobs.o | |
15734 | else | |
15735 | JOBS_O=nojobs.o | |
15736 | fi | |
15737 | ||
a82a04b3 CR |
15738 | |
15739 | ||
15740 | ||
d166f048 JA |
15741 | LOCAL_DEFS=-DSHELL |
15742 | ||
a82a04b3 | 15743 | |
b72432fd | 15744 | case "${host_os}" in |
7f947b68 | 15745 | sysv4.2*) $as_echo "#define SVR4_2 1" >>confdefs.h |
ccc6cda3 | 15746 | |
7f947b68 | 15747 | $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 15748 | ;; |
7f947b68 | 15749 | sysv4*) $as_echo "#define SVR4 1" >>confdefs.h |
ccc6cda3 | 15750 | ;; |
7f947b68 | 15751 | sysv5*) $as_echo "#define SVR5 1" >>confdefs.h |
b72432fd JA |
15752 | ;; |
15753 | hpux9*) LOCAL_CFLAGS="-DHPUX9 -DHPUX" ;; | |
ccc6cda3 JA |
15754 | hpux*) LOCAL_CFLAGS=-DHPUX ;; |
15755 | dgux*) LOCAL_CFLAGS=-D_DGUX_SOURCE; LOCAL_LIBS=-ldgc ;; | |
bb70624e JA |
15756 | isc*) LOCAL_CFLAGS=-Disc386 ;; |
15757 | rhapsody*) LOCAL_CFLAGS=-DRHAPSODY ;; | |
f73dda09 | 15758 | darwin*) LOCAL_CFLAGS=-DMACOSX ;; |
7117c2d2 JA |
15759 | sco3.2v5*) LOCAL_CFLAGS="-b elf -DWAITPID_BROKEN -DPATH_MAX=1024" ;; |
15760 | sco3.2v4*) LOCAL_CFLAGS="-DMUST_UNBLOCK_CHLD -DPATH_MAX=1024" ;; | |
ccc6cda3 | 15761 | sco3.2*) LOCAL_CFLAGS=-DMUST_UNBLOCK_CHLD ;; |
d166f048 | 15762 | sunos4*) LOCAL_CFLAGS=-DSunOS4 ;; |
d3ad40de | 15763 | solaris2.5*) LOCAL_CFLAGS="-DSunOS5 -DSOLARIS" ;; |
db31fb26 CR |
15764 | solaris2.8*) LOCAL_CFLAGS=-DSOLARIS ;; |
15765 | solaris2.9*) LOCAL_CFLAGS=-DSOLARIS ;; | |
15766 | solaris2.10*) LOCAL_CFLAGS=-DSOLARIS ;; | |
d3ad40de | 15767 | solaris2*) LOCAL_CFLAGS=-DSOLARIS ;; |
b72432fd | 15768 | lynxos*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
3ffb039a CR |
15769 | linux*) LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
15770 | case "`uname -r`" in | |
7f947b68 | 15771 | 2.[456789]*|3*) $as_echo "#define PGRP_PIPE 1" >>confdefs.h |
3ffb039a CR |
15772 | ;; |
15773 | esac ;; | |
fd3925f1 | 15774 | *qnx6*) LOCAL_CFLAGS="-Dqnx -Dqnx6" LOCAL_LIBS="-lncurses" ;; |
7117c2d2 | 15775 | *qnx*) LOCAL_CFLAGS="-Dqnx -F -3s" LOCAL_LDFLAGS="-3s" LOCAL_LIBS="-lunix -lncurses" ;; |
b72432fd | 15776 | powerux*) LOCAL_LIBS="-lgen" ;; |
d3a24ed2 | 15777 | cygwin*) LOCAL_CFLAGS=-DRECYCLES_PIDS ;; |
fd58d46e | 15778 | opennt*|interix*) LOCAL_CFLAGS="-DNO_MAIN_ENV_ARG -DBROKEN_DIRENT_D_INO -D_POSIX_SOURCE -D_ALL_SOURCE -DRECYCLES_PIDS" ;; |
b72432fd JA |
15779 | esac |
15780 | ||
15781 | case "${host_os}-${CC}" in | |
15782 | aix4.2*-*gcc*) LOCAL_LDFLAGS="-Xlinker -bexpall -Xlinker -brtl" ;; | |
15783 | aix4.2*) LOCAL_LDFLAGS="-bexpall -brtl" ;; | |
15784 | bsdi4*-*gcc*) LOCAL_LDFLAGS="-rdynamic" ;; # allow dynamic loading, like Linux | |
ccc6cda3 JA |
15785 | esac |
15786 | ||
bb70624e | 15787 | case "${host_os}" in |
28ef6c31 JA |
15788 | freebsd[3-9]*) |
15789 | if test -x /usr/bin/objformat && test "`/usr/bin/objformat`" = "elf" ; then | |
bb70624e JA |
15790 | LOCAL_LDFLAGS=-rdynamic # allow dynamic loading |
15791 | fi ;; | |
28ef6c31 | 15792 | freebsdelf*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
798a67db | 15793 | dragonfly*) LOCAL_LDFLAGS=-rdynamic ;; # allow dynamic loading |
bb70624e JA |
15794 | esac |
15795 | ||
ccc6cda3 JA |
15796 | case "$host_cpu" in |
15797 | *cray*) LOCAL_CFLAGS="-DCRAY" ;; # shell var so config.h can use it | |
15798 | esac | |
15799 | ||
15800 | case "$host_cpu-$host_os" in | |
15801 | ibmrt-*bsd4*) LOCAL_CFLAGS="-ma -U__STDC__" ;; | |
15802 | esac | |
15803 | ||
15804 | case "$host_cpu-$host_vendor-$host_os" in | |
15805 | m88k-motorola-sysv3) LOCAL_CFLAGS=-DWAITPID_BROKEN ;; | |
15806 | mips-pyramid-sysv4) LOCAL_CFLAGS=-Xa ;; | |
15807 | esac | |
15808 | ||
b72432fd JA |
15809 | # |
15810 | # Shared object configuration section. These values are generated by | |
15811 | # ${srcdir}/support/shobj-conf | |
15812 | # | |
15813 | if test "$ac_cv_func_dlopen" = "yes" && test -f ${srcdir}/support/shobj-conf | |
15814 | then | |
7f947b68 | 15815 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking shared object configuration for loadable builtins" >&5 |
dd4f3dd8 | 15816 | $as_echo_n "checking shared object configuration for loadable builtins... " >&6; } |
28ef6c31 | 15817 | eval `${CONFIG_SHELL-/bin/sh} ${srcdir}/support/shobj-conf -C "${CC}" -c "${host_cpu}" -o "${host_os}" -v "${host_vendor}"` |
f73dda09 | 15818 | |
a82a04b3 CR |
15819 | |
15820 | ||
15821 | ||
15822 | ||
15823 | ||
15824 | ||
7f947b68 | 15825 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SHOBJ_STATUS" >&5 |
dd4f3dd8 | 15826 | $as_echo "$SHOBJ_STATUS" >&6; } |
b72432fd JA |
15827 | fi |
15828 | ||
ccc6cda3 JA |
15829 | # try to create a directory tree if the source is elsewhere |
15830 | # this should be packaged into a script accessible via ${srcdir}/support | |
15831 | case "$srcdir" in | |
15832 | .) ;; | |
cce855bc | 15833 | *) for d in doc tests support lib examples; do # dirs |
ccc6cda3 JA |
15834 | test -d $d || mkdir $d |
15835 | done | |
cce855bc | 15836 | for ld in readline glob tilde malloc sh termcap; do # libdirs |
ccc6cda3 JA |
15837 | test -d lib/$ld || mkdir lib/$ld |
15838 | done | |
cce855bc | 15839 | test -d examples/loadables || mkdir examples/loadables # loadable builtins |
bb70624e | 15840 | test -d examples/loadables/perl || mkdir examples/loadables/perl |
ccc6cda3 JA |
15841 | ;; |
15842 | esac | |
15843 | ||
15844 | BUILD_DIR=`pwd` | |
10590446 CR |
15845 | case "$BUILD_DIR" in |
15846 | *\ *) BUILD_DIR=`echo "$BUILD_DIR" | sed 's: :\\\\ :g'` ;; | |
15847 | *) ;; | |
15848 | esac | |
ccc6cda3 | 15849 | |
c184f645 CR |
15850 | if test -z "$localedir"; then |
15851 | localedir='${datarootdir}/locale' | |
15852 | fi | |
15853 | if test -z "$datarootdir"; then | |
15854 | datarootdir='${prefix}/share' | |
15855 | fi | |
a82a04b3 CR |
15856 | |
15857 | ||
15858 | ||
15859 | ||
15860 | ||
15861 | ||
c184f645 CR |
15862 | # Some versions of autoconf don't substitute these automatically |
15863 | ||
a82a04b3 CR |
15864 | |
15865 | ||
15866 | ||
15867 | ||
15868 | ||
15869 | ||
15870 | ||
15871 | ||
15872 | ||
15873 | ||
15874 | ||
15875 | ||
15876 | ||
15877 | ||
15878 | ||
15879 | ||
15880 | ||
d166f048 | 15881 | |
d3ad40de | 15882 | |
d3ad40de | 15883 | |
c184f645 CR |
15884 | #AC_SUBST(ALLOCA_SOURCE) |
15885 | #AC_SUBST(ALLOCA_OBJECT) | |
15886 | ||
b709b946 CR |
15887 | 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/perl/Makefile" |
15888 | ||
15889 | ac_config_commands="$ac_config_commands default" | |
15890 | ||
f73dda09 | 15891 | cat >confcache <<\_ACEOF |
ccc6cda3 JA |
15892 | # This file is a shell script that caches the results of configure |
15893 | # tests run on this system so they can be shared between configure | |
f73dda09 JA |
15894 | # scripts and configure runs, see configure's option --config-cache. |
15895 | # It is not useful on other systems. If it contains results you don't | |
15896 | # want to keep, you may remove or edit it. | |
726f6388 | 15897 | # |
f73dda09 JA |
15898 | # config.status only pays attention to the cache file if you give it |
15899 | # the --recheck option to rerun configure. | |
ccc6cda3 | 15900 | # |
5e4a95c7 | 15901 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
f73dda09 JA |
15902 | # loading this file, other *unset* `ac_cv_foo' will be assigned the |
15903 | # following values. | |
15904 | ||
15905 | _ACEOF | |
15906 | ||
ccc6cda3 JA |
15907 | # The following way of writing the cache mishandles newlines in values, |
15908 | # but we know of no workaround that is simple, portable, and efficient. | |
b709b946 | 15909 | # So, we kill variables containing newlines. |
ccc6cda3 JA |
15910 | # Ultrix sh set writes to stderr and can't be redirected directly, |
15911 | # and sets the high bit in the cache file unless we assign to the vars. | |
b709b946 CR |
15912 | ( |
15913 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
15914 | eval ac_val=\$$ac_var | |
15915 | case $ac_val in #( | |
15916 | *${as_nl}*) | |
15917 | case $ac_var in #( | |
7f947b68 | 15918 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 |
af98a2a6 | 15919 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; |
b709b946 CR |
15920 | esac |
15921 | case $ac_var in #( | |
15922 | _ | IFS | as_nl) ;; #( | |
dd4f3dd8 | 15923 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( |
7f947b68 | 15924 | *) { eval $ac_var=; unset $ac_var;} ;; |
b709b946 CR |
15925 | esac ;; |
15926 | esac | |
15927 | done | |
15928 | ||
f73dda09 | 15929 | (set) 2>&1 | |
b709b946 CR |
15930 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
15931 | *${as_nl}ac_space=\ *) | |
7f947b68 CR |
15932 | # `set' does not quote correctly, so add quotes: double-quote |
15933 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
f73dda09 | 15934 | sed -n \ |
5e4a95c7 CR |
15935 | "s/'/'\\\\''/g; |
15936 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
b709b946 | 15937 | ;; #( |
f73dda09 JA |
15938 | *) |
15939 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
b709b946 | 15940 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
f73dda09 | 15941 | ;; |
b709b946 CR |
15942 | esac | |
15943 | sort | |
15944 | ) | | |
f73dda09 | 15945 | sed ' |
b709b946 | 15946 | /^ac_cv_env_/b end |
f73dda09 | 15947 | t clear |
b709b946 | 15948 | :clear |
f73dda09 JA |
15949 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
15950 | t end | |
b709b946 CR |
15951 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
15952 | :end' >>confcache | |
15953 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
15954 | if test -w "$cache_file"; then | |
7f947b68 CR |
15955 | if test "x$cache_file" != "x/dev/null"; then |
15956 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 | |
dd4f3dd8 | 15957 | $as_echo "$as_me: updating cache $cache_file" >&6;} |
7f947b68 CR |
15958 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
15959 | cat confcache >"$cache_file" | |
15960 | else | |
15961 | case $cache_file in #( | |
15962 | */* | ?:*) | |
15963 | mv -f confcache "$cache_file"$$ && | |
15964 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
15965 | *) | |
15966 | mv -f confcache "$cache_file" ;; | |
15967 | esac | |
15968 | fi | |
15969 | fi | |
ccc6cda3 | 15970 | else |
7f947b68 | 15971 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
dd4f3dd8 | 15972 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} |
ccc6cda3 JA |
15973 | fi |
15974 | fi | |
15975 | rm -f confcache | |
15976 | ||
ccc6cda3 JA |
15977 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
15978 | # Let make expand exec_prefix. | |
15979 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
15980 | ||
ccc6cda3 JA |
15981 | DEFS=-DHAVE_CONFIG_H |
15982 | ||
5e4a95c7 CR |
15983 | ac_libobjs= |
15984 | ac_ltlibobjs= | |
7f947b68 | 15985 | U= |
5e4a95c7 CR |
15986 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
15987 | # 1. Remove the extension, and $U if already installed. | |
b709b946 | 15988 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
dd4f3dd8 | 15989 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` |
b709b946 CR |
15990 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR |
15991 | # will be set to the directory where LIBOBJS objects are built. | |
7f947b68 CR |
15992 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" |
15993 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
5e4a95c7 CR |
15994 | done |
15995 | LIBOBJS=$ac_libobjs | |
15996 | ||
15997 | LTLIBOBJS=$ac_ltlibobjs | |
15998 | ||
15999 | ||
a82a04b3 | 16000 | |
af98a2a6 | 16001 | |
7f947b68 | 16002 | : "${CONFIG_STATUS=./config.status}" |
dd4f3dd8 | 16003 | ac_write_fail=0 |
f73dda09 JA |
16004 | ac_clean_files_save=$ac_clean_files |
16005 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
7f947b68 | 16006 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
dd4f3dd8 | 16007 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} |
7f947b68 CR |
16008 | as_write_fail=0 |
16009 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
f73dda09 | 16010 | #! $SHELL |
a82a04b3 | 16011 | # Generated by $as_me. |
ccc6cda3 | 16012 | # Run this file to recreate the current configuration. |
ccc6cda3 | 16013 | # Compiler output produced by configure, useful for debugging |
f73dda09 | 16014 | # configure, is in config.log if it exists. |
ccc6cda3 | 16015 | |
f73dda09 | 16016 | debug=false |
5e4a95c7 CR |
16017 | ac_cs_recheck=false |
16018 | ac_cs_silent=false | |
abe2eb5b | 16019 | |
7f947b68 CR |
16020 | SHELL=\${CONFIG_SHELL-$SHELL} |
16021 | export SHELL | |
16022 | _ASEOF | |
16023 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
16024 | ## -------------------- ## | |
16025 | ## M4sh Initialization. ## | |
16026 | ## -------------------- ## | |
a82a04b3 | 16027 | |
dd4f3dd8 CR |
16028 | # Be more Bourne compatible |
16029 | DUALCASE=1; export DUALCASE # for MKS sh | |
7f947b68 | 16030 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : |
f73dda09 JA |
16031 | emulate sh |
16032 | NULLCMD=: | |
dd4f3dd8 | 16033 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
5e4a95c7 CR |
16034 | # is contrary to our usage. Disable this feature. |
16035 | alias -g '${1+"$@"}'='"$@"' | |
b709b946 CR |
16036 | setopt NO_GLOB_SUBST |
16037 | else | |
7f947b68 CR |
16038 | case `(set -o) 2>/dev/null` in #( |
16039 | *posix*) : | |
16040 | set -o posix ;; #( | |
16041 | *) : | |
16042 | ;; | |
dd4f3dd8 | 16043 | esac |
f73dda09 | 16044 | fi |
dd4f3dd8 CR |
16045 | |
16046 | ||
dd4f3dd8 CR |
16047 | as_nl=' |
16048 | ' | |
16049 | export as_nl | |
16050 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
16051 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
16052 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
16053 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
7f947b68 CR |
16054 | # Prefer a ksh shell builtin over an external printf program on Solaris, |
16055 | # but without wasting forks for bash or zsh. | |
16056 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
16057 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
16058 | as_echo='print -r --' | |
16059 | as_echo_n='print -rn --' | |
16060 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
dd4f3dd8 CR |
16061 | as_echo='printf %s\n' |
16062 | as_echo_n='printf %s' | |
16063 | else | |
16064 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
16065 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
16066 | as_echo_n='/usr/ucb/echo -n' | |
b709b946 | 16067 | else |
dd4f3dd8 CR |
16068 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' |
16069 | as_echo_n_body='eval | |
16070 | arg=$1; | |
7f947b68 | 16071 | case $arg in #( |
dd4f3dd8 CR |
16072 | *"$as_nl"*) |
16073 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
16074 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
16075 | esac; | |
16076 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
16077 | ' | |
16078 | export as_echo_n_body | |
16079 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
b709b946 | 16080 | fi |
dd4f3dd8 CR |
16081 | export as_echo_body |
16082 | as_echo='sh -c $as_echo_body as_echo' | |
16083 | fi | |
16084 | ||
16085 | # The user is always right. | |
16086 | if test "${PATH_SEPARATOR+set}" != set; then | |
16087 | PATH_SEPARATOR=: | |
16088 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
16089 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
16090 | PATH_SEPARATOR=';' | |
16091 | } | |
b709b946 CR |
16092 | fi |
16093 | ||
5e4a95c7 | 16094 | |
b709b946 CR |
16095 | # IFS |
16096 | # We need space, tab and new line, in precisely that order. Quoting is | |
16097 | # there to prevent editors from complaining about space-tab. | |
16098 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
16099 | # splitting by setting IFS to empty value.) | |
b709b946 CR |
16100 | IFS=" "" $as_nl" |
16101 | ||
16102 | # Find who we are. Look in the path if we contain no directory separator. | |
7f947b68 CR |
16103 | as_myself= |
16104 | case $0 in #(( | |
b709b946 CR |
16105 | *[\\/]* ) as_myself=$0 ;; |
16106 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
16107 | for as_dir in $PATH | |
16108 | do | |
16109 | IFS=$as_save_IFS | |
16110 | test -z "$as_dir" && as_dir=. | |
7f947b68 CR |
16111 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break |
16112 | done | |
b709b946 CR |
16113 | IFS=$as_save_IFS |
16114 | ||
16115 | ;; | |
16116 | esac | |
16117 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
16118 | # in which case we are not to be found in the path. | |
16119 | if test "x$as_myself" = x; then | |
16120 | as_myself=$0 | |
16121 | fi | |
16122 | if test ! -f "$as_myself"; then | |
dd4f3dd8 | 16123 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 |
7f947b68 | 16124 | exit 1 |
b709b946 CR |
16125 | fi |
16126 | ||
7f947b68 CR |
16127 | # Unset variables that we do not need and which cause bugs (e.g. in |
16128 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
16129 | # suppresses any "Segmentation fault" message there. '((' could | |
16130 | # trigger a bug in pdksh 5.2.14. | |
16131 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
16132 | do eval test x\${$as_var+set} = xset \ | |
16133 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
b709b946 | 16134 | done |
5e4a95c7 CR |
16135 | PS1='$ ' |
16136 | PS2='> ' | |
16137 | PS4='+ ' | |
16138 | ||
16139 | # NLS nuisances. | |
dd4f3dd8 CR |
16140 | LC_ALL=C |
16141 | export LC_ALL | |
16142 | LANGUAGE=C | |
16143 | export LANGUAGE | |
5e4a95c7 | 16144 | |
7f947b68 CR |
16145 | # CDPATH. |
16146 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
16147 | ||
16148 | ||
16149 | # as_fn_error STATUS ERROR [LINENO LOG_FD] | |
16150 | # ---------------------------------------- | |
16151 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
16152 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
16153 | # script with STATUS, using 1 if that was 0. | |
16154 | as_fn_error () | |
16155 | { | |
16156 | as_status=$1; test $as_status -eq 0 && as_status=1 | |
16157 | if test "$4"; then | |
16158 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
16159 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
16160 | fi | |
16161 | $as_echo "$as_me: error: $2" >&2 | |
16162 | as_fn_exit $as_status | |
16163 | } # as_fn_error | |
16164 | ||
16165 | ||
16166 | # as_fn_set_status STATUS | |
16167 | # ----------------------- | |
16168 | # Set $? to STATUS, without forking. | |
16169 | as_fn_set_status () | |
16170 | { | |
16171 | return $1 | |
16172 | } # as_fn_set_status | |
16173 | ||
16174 | # as_fn_exit STATUS | |
16175 | # ----------------- | |
16176 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
16177 | as_fn_exit () | |
16178 | { | |
16179 | set +e | |
16180 | as_fn_set_status $1 | |
16181 | exit $1 | |
16182 | } # as_fn_exit | |
16183 | ||
16184 | # as_fn_unset VAR | |
16185 | # --------------- | |
16186 | # Portably unset VAR. | |
16187 | as_fn_unset () | |
16188 | { | |
16189 | { eval $1=; unset $1;} | |
16190 | } | |
16191 | as_unset=as_fn_unset | |
16192 | # as_fn_append VAR VALUE | |
16193 | # ---------------------- | |
16194 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
16195 | # advantage of any shell optimizations that allow amortized linear growth over | |
16196 | # repeated appends, instead of the typical quadratic growth present in naive | |
16197 | # implementations. | |
16198 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
16199 | eval 'as_fn_append () | |
16200 | { | |
16201 | eval $1+=\$2 | |
16202 | }' | |
16203 | else | |
16204 | as_fn_append () | |
16205 | { | |
16206 | eval $1=\$$1\$2 | |
16207 | } | |
16208 | fi # as_fn_append | |
16209 | ||
16210 | # as_fn_arith ARG... | |
16211 | # ------------------ | |
16212 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
16213 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
16214 | # must be portable across $(()) and expr. | |
16215 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
16216 | eval 'as_fn_arith () | |
16217 | { | |
16218 | as_val=$(( $* )) | |
16219 | }' | |
16220 | else | |
16221 | as_fn_arith () | |
16222 | { | |
16223 | as_val=`expr "$@" || test $? -eq 1` | |
16224 | } | |
16225 | fi # as_fn_arith | |
16226 | ||
16227 | ||
b709b946 CR |
16228 | if expr a : '\(a\)' >/dev/null 2>&1 && |
16229 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
5e4a95c7 CR |
16230 | as_expr=expr |
16231 | else | |
16232 | as_expr=false | |
16233 | fi | |
16234 | ||
b709b946 | 16235 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
5e4a95c7 CR |
16236 | as_basename=basename |
16237 | else | |
16238 | as_basename=false | |
16239 | fi | |
a82a04b3 | 16240 | |
7f947b68 CR |
16241 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
16242 | as_dirname=dirname | |
16243 | else | |
16244 | as_dirname=false | |
16245 | fi | |
f73dda09 | 16246 | |
b709b946 | 16247 | as_me=`$as_basename -- "$0" || |
a82a04b3 CR |
16248 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
16249 | X"$0" : 'X\(//\)$' \| \ | |
b709b946 | 16250 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 16251 | $as_echo X/"$0" | |
b709b946 CR |
16252 | sed '/^.*\/\([^/][^/]*\)\/*$/{ |
16253 | s//\1/ | |
16254 | q | |
16255 | } | |
16256 | /^X\/\(\/\/\)$/{ | |
16257 | s//\1/ | |
16258 | q | |
16259 | } | |
16260 | /^X\/\(\/\).*/{ | |
16261 | s//\1/ | |
16262 | q | |
16263 | } | |
16264 | s/.*/./; q'` | |
a82a04b3 | 16265 | |
7f947b68 CR |
16266 | # Avoid depending upon Character Ranges. |
16267 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
16268 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
16269 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
16270 | as_cr_digits='0123456789' | |
16271 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
b709b946 CR |
16272 | |
16273 | ECHO_C= ECHO_N= ECHO_T= | |
7f947b68 | 16274 | case `echo -n x` in #((((( |
b709b946 | 16275 | -n*) |
7f947b68 | 16276 | case `echo 'xy\c'` in |
b709b946 | 16277 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. |
7f947b68 CR |
16278 | xy) ECHO_C='\c';; |
16279 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
16280 | ECHO_T=' ';; | |
b709b946 CR |
16281 | esac;; |
16282 | *) | |
16283 | ECHO_N='-n';; | |
a82a04b3 | 16284 | esac |
f73dda09 JA |
16285 | |
16286 | rm -f conf$$ conf$$.exe conf$$.file | |
b709b946 CR |
16287 | if test -d conf$$.dir; then |
16288 | rm -f conf$$.dir/conf$$.file | |
16289 | else | |
16290 | rm -f conf$$.dir | |
dd4f3dd8 CR |
16291 | mkdir conf$$.dir 2>/dev/null |
16292 | fi | |
16293 | if (echo >conf$$.file) 2>/dev/null; then | |
16294 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
16295 | as_ln_s='ln -s' | |
16296 | # ... but there are two gotchas: | |
16297 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
16298 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
16299 | # In both cases, we have to default to `cp -p'. | |
16300 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
16301 | as_ln_s='cp -p' | |
16302 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
16303 | as_ln_s=ln | |
16304 | else | |
f73dda09 | 16305 | as_ln_s='cp -p' |
dd4f3dd8 | 16306 | fi |
f73dda09 JA |
16307 | else |
16308 | as_ln_s='cp -p' | |
16309 | fi | |
b709b946 CR |
16310 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
16311 | rmdir conf$$.dir 2>/dev/null | |
f73dda09 | 16312 | |
7f947b68 CR |
16313 | |
16314 | # as_fn_mkdir_p | |
16315 | # ------------- | |
16316 | # Create "$as_dir" as a directory, including parents if necessary. | |
16317 | as_fn_mkdir_p () | |
16318 | { | |
16319 | ||
16320 | case $as_dir in #( | |
16321 | -*) as_dir=./$as_dir;; | |
16322 | esac | |
16323 | test -d "$as_dir" || eval $as_mkdir_p || { | |
16324 | as_dirs= | |
16325 | while :; do | |
16326 | case $as_dir in #( | |
16327 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
16328 | *) as_qdir=$as_dir;; | |
16329 | esac | |
16330 | as_dirs="'$as_qdir' $as_dirs" | |
16331 | as_dir=`$as_dirname -- "$as_dir" || | |
16332 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
16333 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
16334 | X"$as_dir" : 'X\(//\)$' \| \ | |
16335 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
16336 | $as_echo X"$as_dir" | | |
16337 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
16338 | s//\1/ | |
16339 | q | |
16340 | } | |
16341 | /^X\(\/\/\)[^/].*/{ | |
16342 | s//\1/ | |
16343 | q | |
16344 | } | |
16345 | /^X\(\/\/\)$/{ | |
16346 | s//\1/ | |
16347 | q | |
16348 | } | |
16349 | /^X\(\/\).*/{ | |
16350 | s//\1/ | |
16351 | q | |
16352 | } | |
16353 | s/.*/./; q'` | |
16354 | test -d "$as_dir" && break | |
16355 | done | |
16356 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
16357 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" | |
16358 | ||
16359 | ||
16360 | } # as_fn_mkdir_p | |
5e4a95c7 | 16361 | if mkdir -p . 2>/dev/null; then |
7f947b68 | 16362 | as_mkdir_p='mkdir -p "$as_dir"' |
5e4a95c7 CR |
16363 | else |
16364 | test -d ./-p && rmdir ./-p | |
16365 | as_mkdir_p=false | |
16366 | fi | |
16367 | ||
dd4f3dd8 CR |
16368 | if test -x / >/dev/null 2>&1; then |
16369 | as_test_x='test -x' | |
b709b946 | 16370 | else |
dd4f3dd8 CR |
16371 | if ls -dL / >/dev/null 2>&1; then |
16372 | as_ls_L_option=L | |
16373 | else | |
16374 | as_ls_L_option= | |
16375 | fi | |
16376 | as_test_x=' | |
16377 | eval sh -c '\'' | |
16378 | if test -d "$1"; then | |
16379 | test -d "$1/."; | |
16380 | else | |
7f947b68 | 16381 | case $1 in #( |
dd4f3dd8 CR |
16382 | -*)set "./$1";; |
16383 | esac; | |
7f947b68 | 16384 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( |
dd4f3dd8 CR |
16385 | ???[sx]*):;;*)false;;esac;fi |
16386 | '\'' sh | |
16387 | ' | |
b709b946 | 16388 | fi |
dd4f3dd8 | 16389 | as_executable_p=$as_test_x |
a82a04b3 CR |
16390 | |
16391 | # Sed expression to map a string onto a valid CPP name. | |
5e4a95c7 | 16392 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
a82a04b3 CR |
16393 | |
16394 | # Sed expression to map a string onto a valid variable name. | |
5e4a95c7 | 16395 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
a82a04b3 | 16396 | |
f73dda09 | 16397 | |
f73dda09 | 16398 | exec 6>&1 |
7f947b68 CR |
16399 | ## ----------------------------------- ## |
16400 | ## Main body of $CONFIG_STATUS script. ## | |
16401 | ## ----------------------------------- ## | |
16402 | _ASEOF | |
16403 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
f73dda09 | 16404 | |
7f947b68 CR |
16405 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16406 | # Save the log message, to keep $0 and so on meaningful, and to | |
a82a04b3 | 16407 | # report actual input values of CONFIG_FILES etc. instead of their |
b709b946 CR |
16408 | # values after options handling. |
16409 | ac_log=" | |
e192f341 | 16410 | This file was extended by bash $as_me 4.2-maint, which was |
7f947b68 | 16411 | generated by GNU Autoconf 2.68. Invocation command line was |
a82a04b3 CR |
16412 | |
16413 | CONFIG_FILES = $CONFIG_FILES | |
16414 | CONFIG_HEADERS = $CONFIG_HEADERS | |
16415 | CONFIG_LINKS = $CONFIG_LINKS | |
16416 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
16417 | $ $0 $@ | |
16418 | ||
b709b946 CR |
16419 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
16420 | " | |
16421 | ||
f73dda09 JA |
16422 | _ACEOF |
16423 | ||
af98a2a6 CR |
16424 | case $ac_config_files in *" |
16425 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
16426 | esac | |
16427 | ||
16428 | case $ac_config_headers in *" | |
16429 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
16430 | esac | |
16431 | ||
16432 | ||
dd4f3dd8 | 16433 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
f73dda09 | 16434 | # Files that config.status was made for. |
b709b946 CR |
16435 | config_files="$ac_config_files" |
16436 | config_headers="$ac_config_headers" | |
16437 | config_commands="$ac_config_commands" | |
c184f645 | 16438 | |
b709b946 | 16439 | _ACEOF |
f73dda09 | 16440 | |
dd4f3dd8 | 16441 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 | 16442 | ac_cs_usage="\ |
7f947b68 CR |
16443 | \`$as_me' instantiates files and other configuration actions |
16444 | from templates according to the current configuration. Unless the files | |
16445 | and actions are specified as TAGs, all are instantiated by default. | |
f73dda09 | 16446 | |
7f947b68 | 16447 | Usage: $0 [OPTION]... [TAG]... |
f73dda09 JA |
16448 | |
16449 | -h, --help print this help, then exit | |
dd4f3dd8 | 16450 | -V, --version print version number and configuration settings, then exit |
7f947b68 | 16451 | --config print configuration, then exit |
af98a2a6 CR |
16452 | -q, --quiet, --silent |
16453 | do not print progress messages | |
f73dda09 JA |
16454 | -d, --debug don't remove temporary files |
16455 | --recheck update $as_me by reconfiguring in the same conditions | |
af98a2a6 | 16456 | --file=FILE[:TEMPLATE] |
dd4f3dd8 | 16457 | instantiate the configuration file FILE |
af98a2a6 | 16458 | --header=FILE[:TEMPLATE] |
dd4f3dd8 | 16459 | instantiate the configuration header FILE |
f73dda09 JA |
16460 | |
16461 | Configuration files: | |
16462 | $config_files | |
16463 | ||
16464 | Configuration headers: | |
16465 | $config_headers | |
16466 | ||
16467 | Configuration commands: | |
16468 | $config_commands | |
16469 | ||
7f947b68 | 16470 | Report bugs to <bug-bash@gnu.org>." |
c184f645 | 16471 | |
b709b946 | 16472 | _ACEOF |
dd4f3dd8 | 16473 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
7f947b68 | 16474 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
f73dda09 | 16475 | ac_cs_version="\\ |
e192f341 | 16476 | bash config.status 4.2-maint |
7f947b68 CR |
16477 | configured by $0, generated by GNU Autoconf 2.68, |
16478 | with options \\"\$ac_cs_config\\" | |
f73dda09 | 16479 | |
7f947b68 | 16480 | Copyright (C) 2010 Free Software Foundation, Inc. |
f73dda09 JA |
16481 | This config.status script is free software; the Free Software Foundation |
16482 | gives unlimited permission to copy, distribute and modify it." | |
b709b946 CR |
16483 | |
16484 | ac_pwd='$ac_pwd' | |
16485 | srcdir='$srcdir' | |
16486 | INSTALL='$INSTALL' | |
dd4f3dd8 | 16487 | test -n "\$AWK" || AWK=awk |
a82a04b3 | 16488 | _ACEOF |
f73dda09 | 16489 | |
dd4f3dd8 CR |
16490 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16491 | # The default lists apply if the user does not specify any file. | |
f73dda09 JA |
16492 | ac_need_defaults=: |
16493 | while test $# != 0 | |
ccc6cda3 | 16494 | do |
f73dda09 | 16495 | case $1 in |
7f947b68 | 16496 | --*=?*) |
b709b946 CR |
16497 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
16498 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
5e4a95c7 CR |
16499 | ac_shift=: |
16500 | ;; | |
7f947b68 CR |
16501 | --*=) |
16502 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
16503 | ac_optarg= | |
16504 | ac_shift=: | |
16505 | ;; | |
b709b946 | 16506 | *) |
5e4a95c7 CR |
16507 | ac_option=$1 |
16508 | ac_optarg=$2 | |
16509 | ac_shift=shift | |
f73dda09 | 16510 | ;; |
f73dda09 JA |
16511 | esac |
16512 | ||
5e4a95c7 | 16513 | case $ac_option in |
f73dda09 | 16514 | # Handling of the options. |
5e4a95c7 CR |
16515 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
16516 | ac_cs_recheck=: ;; | |
b709b946 | 16517 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
dd4f3dd8 | 16518 | $as_echo "$ac_cs_version"; exit ;; |
7f947b68 CR |
16519 | --config | --confi | --conf | --con | --co | --c ) |
16520 | $as_echo "$ac_cs_config"; exit ;; | |
b709b946 | 16521 | --debug | --debu | --deb | --de | --d | -d ) |
f73dda09 JA |
16522 | debug=: ;; |
16523 | --file | --fil | --fi | --f ) | |
5e4a95c7 | 16524 | $ac_shift |
dd4f3dd8 CR |
16525 | case $ac_optarg in |
16526 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
7f947b68 | 16527 | '') as_fn_error $? "missing file argument" ;; |
dd4f3dd8 | 16528 | esac |
7f947b68 | 16529 | as_fn_append CONFIG_FILES " '$ac_optarg'" |
f73dda09 JA |
16530 | ac_need_defaults=false;; |
16531 | --header | --heade | --head | --hea ) | |
5e4a95c7 | 16532 | $ac_shift |
dd4f3dd8 CR |
16533 | case $ac_optarg in |
16534 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
16535 | esac | |
7f947b68 | 16536 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" |
f73dda09 | 16537 | ac_need_defaults=false;; |
b709b946 CR |
16538 | --he | --h) |
16539 | # Conflict between --help and --header | |
7f947b68 CR |
16540 | as_fn_error $? "ambiguous option: \`$1' |
16541 | Try \`$0 --help' for more information.";; | |
b709b946 | 16542 | --help | --hel | -h ) |
dd4f3dd8 | 16543 | $as_echo "$ac_cs_usage"; exit ;; |
5e4a95c7 CR |
16544 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
16545 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
16546 | ac_cs_silent=: ;; | |
f73dda09 JA |
16547 | |
16548 | # This is an error. | |
7f947b68 CR |
16549 | -*) as_fn_error $? "unrecognized option: \`$1' |
16550 | Try \`$0 --help' for more information." ;; | |
f73dda09 | 16551 | |
7f947b68 | 16552 | *) as_fn_append ac_config_targets " $1" |
b709b946 | 16553 | ac_need_defaults=false ;; |
f73dda09 | 16554 | |
ccc6cda3 | 16555 | esac |
f73dda09 | 16556 | shift |
ccc6cda3 JA |
16557 | done |
16558 | ||
5e4a95c7 CR |
16559 | ac_configure_extra_args= |
16560 | ||
16561 | if $ac_cs_silent; then | |
16562 | exec 6>/dev/null | |
16563 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
16564 | fi | |
16565 | ||
16566 | _ACEOF | |
dd4f3dd8 | 16567 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
5e4a95c7 | 16568 | if \$ac_cs_recheck; then |
dd4f3dd8 CR |
16569 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
16570 | shift | |
16571 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
16572 | CONFIG_SHELL='$SHELL' | |
b709b946 | 16573 | export CONFIG_SHELL |
dd4f3dd8 | 16574 | exec "\$@" |
5e4a95c7 CR |
16575 | fi |
16576 | ||
f73dda09 | 16577 | _ACEOF |
dd4f3dd8 | 16578 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
16579 | exec 5>>config.log |
16580 | { | |
16581 | echo | |
16582 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
16583 | ## Running $as_me. ## | |
16584 | _ASBOX | |
dd4f3dd8 | 16585 | $as_echo "$ac_log" |
b709b946 | 16586 | } >&5 |
ccc6cda3 | 16587 | |
b709b946 | 16588 | _ACEOF |
dd4f3dd8 | 16589 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
5e13499c | 16590 | # |
b709b946 | 16591 | # INIT-COMMANDS |
5e13499c | 16592 | # |
5e13499c CR |
16593 | # Capture the value of obsolete ALL_LINGUAS because we need it to compute |
16594 | # POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES, CATALOGS. But hide it | |
16595 | # from automake. | |
16596 | eval 'OBSOLETE_ALL_LINGUAS''="$ALL_LINGUAS"' | |
16597 | # Capture the value of LINGUAS because we need it to compute CATALOGS. | |
16598 | LINGUAS="${LINGUAS-%UNSET%}" | |
16599 | ||
5e13499c | 16600 | |
a82a04b3 CR |
16601 | _ACEOF |
16602 | ||
dd4f3dd8 | 16603 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
16604 | |
16605 | # Handling of arguments. | |
f73dda09 JA |
16606 | for ac_config_target in $ac_config_targets |
16607 | do | |
b709b946 CR |
16608 | case $ac_config_target in |
16609 | "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;; | |
16610 | "default-1") CONFIG_COMMANDS="$CONFIG_COMMANDS default-1" ;; | |
16611 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; | |
16612 | "builtins/Makefile") CONFIG_FILES="$CONFIG_FILES builtins/Makefile" ;; | |
16613 | "lib/readline/Makefile") CONFIG_FILES="$CONFIG_FILES lib/readline/Makefile" ;; | |
16614 | "lib/glob/Makefile") CONFIG_FILES="$CONFIG_FILES lib/glob/Makefile" ;; | |
16615 | "lib/intl/Makefile") CONFIG_FILES="$CONFIG_FILES lib/intl/Makefile" ;; | |
16616 | "lib/malloc/Makefile") CONFIG_FILES="$CONFIG_FILES lib/malloc/Makefile" ;; | |
16617 | "lib/sh/Makefile") CONFIG_FILES="$CONFIG_FILES lib/sh/Makefile" ;; | |
16618 | "lib/termcap/Makefile") CONFIG_FILES="$CONFIG_FILES lib/termcap/Makefile" ;; | |
16619 | "lib/tilde/Makefile") CONFIG_FILES="$CONFIG_FILES lib/tilde/Makefile" ;; | |
16620 | "doc/Makefile") CONFIG_FILES="$CONFIG_FILES doc/Makefile" ;; | |
16621 | "support/Makefile") CONFIG_FILES="$CONFIG_FILES support/Makefile" ;; | |
16622 | "po/Makefile.in") CONFIG_FILES="$CONFIG_FILES po/Makefile.in" ;; | |
16623 | "examples/loadables/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/Makefile" ;; | |
16624 | "examples/loadables/perl/Makefile") CONFIG_FILES="$CONFIG_FILES examples/loadables/perl/Makefile" ;; | |
16625 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; | |
16626 | ||
7f947b68 | 16627 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
f73dda09 JA |
16628 | esac |
16629 | done | |
16630 | ||
b709b946 | 16631 | |
f73dda09 JA |
16632 | # If the user did not use the arguments to specify the items to instantiate, |
16633 | # then the envvar interface is used. Set only those that are not. | |
16634 | # We use the long form for the default assignment because of an extremely | |
16635 | # bizarre bug on SunOS 4.1.3. | |
16636 | if $ac_need_defaults; then | |
16637 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
16638 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
16639 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
16640 | fi | |
16641 | ||
5e4a95c7 | 16642 | # Have a temporary directory for convenience. Make it in the build tree |
b709b946 | 16643 | # simply because there is no reason against having it here, and in addition, |
5e4a95c7 | 16644 | # creating and moving files from /tmp can sometimes cause problems. |
b709b946 CR |
16645 | # Hook for its removal unless debugging. |
16646 | # Note that there is a small window in which the directory will not be cleaned: | |
16647 | # after its creation but before its name has been assigned to `$tmp'. | |
f73dda09 JA |
16648 | $debug || |
16649 | { | |
7f947b68 | 16650 | tmp= ac_tmp= |
b709b946 | 16651 | trap 'exit_status=$? |
7f947b68 CR |
16652 | : "${ac_tmp:=$tmp}" |
16653 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
b709b946 | 16654 | ' 0 |
7f947b68 | 16655 | trap 'as_fn_exit 1' 1 2 13 15 |
f73dda09 | 16656 | } |
f73dda09 | 16657 | # Create a (secure) tmp directory for tmp files. |
5e4a95c7 | 16658 | |
f73dda09 | 16659 | { |
b709b946 | 16660 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
7f947b68 | 16661 | test -d "$tmp" |
f73dda09 JA |
16662 | } || |
16663 | { | |
b709b946 CR |
16664 | tmp=./conf$$-$RANDOM |
16665 | (umask 077 && mkdir "$tmp") | |
7f947b68 CR |
16666 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
16667 | ac_tmp=$tmp | |
ccc6cda3 | 16668 | |
dd4f3dd8 CR |
16669 | # Set up the scripts for CONFIG_FILES section. |
16670 | # No need to generate them if there are no CONFIG_FILES. | |
16671 | # This happens for instance with `./config.status config.h'. | |
b709b946 CR |
16672 | if test -n "$CONFIG_FILES"; then |
16673 | ||
b709b946 | 16674 | |
7f947b68 CR |
16675 | ac_cr=`echo X | tr X '\015'` |
16676 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
16677 | # But we know of no other shell where ac_cr would be empty at this | |
16678 | # point, so we can use a bashism as a fallback. | |
16679 | if test "x$ac_cr" = x; then | |
16680 | eval ac_cr=\$\'\\r\' | |
16681 | fi | |
dd4f3dd8 CR |
16682 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` |
16683 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
16684 | ac_cs_awk_cr='\\r' | |
16685 | else | |
16686 | ac_cs_awk_cr=$ac_cr | |
b709b946 CR |
16687 | fi |
16688 | ||
7f947b68 | 16689 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
b709b946 CR |
16690 | _ACEOF |
16691 | ||
16692 | ||
dd4f3dd8 CR |
16693 | { |
16694 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
16695 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
16696 | echo "_ACEOF" | |
16697 | } >conf$$subs.sh || | |
7f947b68 CR |
16698 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
16699 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
b709b946 CR |
16700 | ac_delim='%!_!# ' |
16701 | for ac_last_try in false false false false false :; do | |
dd4f3dd8 | 16702 | . ./conf$$subs.sh || |
7f947b68 | 16703 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
dd4f3dd8 | 16704 | |
af98a2a6 CR |
16705 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` |
16706 | if test $ac_delim_n = $ac_delim_num; then | |
b709b946 CR |
16707 | break |
16708 | elif $ac_last_try; then | |
7f947b68 | 16709 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
b709b946 CR |
16710 | else |
16711 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
16712 | fi | |
16713 | done | |
dd4f3dd8 CR |
16714 | rm -f conf$$subs.sh |
16715 | ||
16716 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
7f947b68 | 16717 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
dd4f3dd8 CR |
16718 | _ACEOF |
16719 | sed -n ' | |
16720 | h | |
16721 | s/^/S["/; s/!.*/"]=/ | |
16722 | p | |
16723 | g | |
16724 | s/^[^!]*!// | |
16725 | :repl | |
16726 | t repl | |
16727 | s/'"$ac_delim"'$// | |
16728 | t delim | |
16729 | :nl | |
16730 | h | |
7f947b68 | 16731 | s/\(.\{148\}\)..*/\1/ |
dd4f3dd8 CR |
16732 | t more1 |
16733 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
16734 | p | |
16735 | n | |
16736 | b repl | |
16737 | :more1 | |
16738 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
16739 | p | |
16740 | g | |
16741 | s/.\{148\}// | |
16742 | t nl | |
16743 | :delim | |
16744 | h | |
7f947b68 | 16745 | s/\(.\{148\}\)..*/\1/ |
dd4f3dd8 CR |
16746 | t more2 |
16747 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
16748 | p | |
16749 | b | |
16750 | :more2 | |
16751 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
16752 | p | |
16753 | g | |
16754 | s/.\{148\}// | |
16755 | t delim | |
16756 | ' <conf$$subs.awk | sed ' | |
16757 | /^[^""]/{ | |
16758 | N | |
16759 | s/\n// | |
16760 | } | |
16761 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
16762 | rm -f conf$$subs.awk | |
16763 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
16764 | _ACAWK | |
7f947b68 | 16765 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
dd4f3dd8 CR |
16766 | for (key in S) S_is_set[key] = 1 |
16767 | FS = "\a" | |
16768 | ||
16769 | } | |
16770 | { | |
16771 | line = $ 0 | |
16772 | nfields = split(line, field, "@") | |
16773 | substed = 0 | |
16774 | len = length(field[1]) | |
16775 | for (i = 2; i < nfields; i++) { | |
16776 | key = field[i] | |
16777 | keylen = length(key) | |
16778 | if (S_is_set[key]) { | |
16779 | value = S[key] | |
16780 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
16781 | len += length(value) + length(field[++i]) | |
16782 | substed = 1 | |
16783 | } else | |
16784 | len += 1 + keylen | |
16785 | } | |
b709b946 | 16786 | |
dd4f3dd8 CR |
16787 | print line |
16788 | } | |
d3ad40de | 16789 | |
dd4f3dd8 | 16790 | _ACAWK |
b709b946 | 16791 | _ACEOF |
dd4f3dd8 CR |
16792 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
16793 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
16794 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
16795 | else | |
16796 | cat | |
7f947b68 CR |
16797 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
16798 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 | |
a82a04b3 | 16799 | _ACEOF |
b709b946 | 16800 | |
7f947b68 CR |
16801 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
16802 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
b709b946 CR |
16803 | # trailing colons and then remove the whole line if VPATH becomes empty |
16804 | # (actually we leave an empty line to preserve line numbers). | |
16805 | if test "x$srcdir" = x.; then | |
7f947b68 CR |
16806 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
16807 | h | |
16808 | s/// | |
16809 | s/^/:/ | |
16810 | s/[ ]*$/:/ | |
16811 | s/:\$(srcdir):/:/g | |
16812 | s/:\${srcdir}:/:/g | |
16813 | s/:@srcdir@:/:/g | |
16814 | s/^:*// | |
b709b946 | 16815 | s/:*$// |
7f947b68 CR |
16816 | x |
16817 | s/\(=[ ]*\).*/\1/ | |
16818 | G | |
16819 | s/\n// | |
b709b946 CR |
16820 | s/^[^=]*=[ ]*$// |
16821 | }' | |
16822 | fi | |
16823 | ||
dd4f3dd8 | 16824 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
16825 | fi # test -n "$CONFIG_FILES" |
16826 | ||
dd4f3dd8 CR |
16827 | # Set up the scripts for CONFIG_HEADERS section. |
16828 | # No need to generate them if there are no CONFIG_HEADERS. | |
16829 | # This happens for instance with `./config.status Makefile'. | |
16830 | if test -n "$CONFIG_HEADERS"; then | |
7f947b68 | 16831 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
dd4f3dd8 CR |
16832 | BEGIN { |
16833 | _ACEOF | |
16834 | ||
16835 | # Transform confdefs.h into an awk script `defines.awk', embedded as | |
16836 | # here-document in config.status, that substitutes the proper values into | |
16837 | # config.h.in to produce config.h. | |
16838 | ||
16839 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
16840 | # handling of long lines. | |
16841 | ac_delim='%!_!# ' | |
16842 | for ac_last_try in false false :; do | |
7f947b68 CR |
16843 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
16844 | if test -z "$ac_tt"; then | |
dd4f3dd8 CR |
16845 | break |
16846 | elif $ac_last_try; then | |
7f947b68 | 16847 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
dd4f3dd8 CR |
16848 | else |
16849 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
16850 | fi | |
16851 | done | |
16852 | ||
16853 | # For the awk script, D is an array of macro values keyed by name, | |
16854 | # likewise P contains macro parameters if any. Preserve backslash | |
16855 | # newline sequences. | |
16856 | ||
16857 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
16858 | sed -n ' | |
16859 | s/.\{148\}/&'"$ac_delim"'/g | |
16860 | t rset | |
16861 | :rset | |
16862 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
16863 | t def | |
16864 | d | |
16865 | :def | |
16866 | s/\\$// | |
16867 | t bsnl | |
16868 | s/["\\]/\\&/g | |
16869 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
16870 | D["\1"]=" \3"/p | |
16871 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
16872 | d | |
16873 | :bsnl | |
16874 | s/["\\]/\\&/g | |
16875 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
16876 | D["\1"]=" \3\\\\\\n"\\/p | |
16877 | t cont | |
16878 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
16879 | t cont | |
16880 | d | |
16881 | :cont | |
16882 | n | |
16883 | s/.\{148\}/&'"$ac_delim"'/g | |
16884 | t clear | |
16885 | :clear | |
16886 | s/\\$// | |
16887 | t bsnlc | |
16888 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
16889 | d | |
16890 | :bsnlc | |
16891 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
16892 | b cont | |
16893 | ' <confdefs.h | sed ' | |
16894 | s/'"$ac_delim"'/"\\\ | |
16895 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
16896 | ||
16897 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
16898 | for (key in D) D_is_set[key] = 1 | |
16899 | FS = "\a" | |
16900 | } | |
16901 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
16902 | line = \$ 0 | |
16903 | split(line, arg, " ") | |
16904 | if (arg[1] == "#") { | |
16905 | defundef = arg[2] | |
16906 | mac1 = arg[3] | |
16907 | } else { | |
16908 | defundef = substr(arg[1], 2) | |
16909 | mac1 = arg[2] | |
16910 | } | |
16911 | split(mac1, mac2, "(") #) | |
16912 | macro = mac2[1] | |
af98a2a6 | 16913 | prefix = substr(line, 1, index(line, defundef) - 1) |
dd4f3dd8 CR |
16914 | if (D_is_set[macro]) { |
16915 | # Preserve the white space surrounding the "#". | |
dd4f3dd8 CR |
16916 | print prefix "define", macro P[macro] D[macro] |
16917 | next | |
16918 | } else { | |
16919 | # Replace #undef with comments. This is necessary, for example, | |
16920 | # in the case of _POSIX_SOURCE, which is predefined and required | |
16921 | # on some systems where configure will not decide to define it. | |
16922 | if (defundef == "undef") { | |
af98a2a6 | 16923 | print "/*", prefix defundef, macro, "*/" |
dd4f3dd8 CR |
16924 | next |
16925 | } | |
16926 | } | |
16927 | } | |
16928 | { print } | |
16929 | _ACAWK | |
16930 | _ACEOF | |
16931 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
7f947b68 | 16932 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
dd4f3dd8 CR |
16933 | fi # test -n "$CONFIG_HEADERS" |
16934 | ||
b709b946 | 16935 | |
dd4f3dd8 CR |
16936 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" |
16937 | shift | |
16938 | for ac_tag | |
b709b946 CR |
16939 | do |
16940 | case $ac_tag in | |
16941 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
9d6e5e30 | 16942 | esac |
b709b946 CR |
16943 | case $ac_mode$ac_tag in |
16944 | :[FHL]*:*);; | |
7f947b68 | 16945 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
b709b946 CR |
16946 | :[FH]-) ac_tag=-:-;; |
16947 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
16948 | esac | |
16949 | ac_save_IFS=$IFS | |
16950 | IFS=: | |
16951 | set x $ac_tag | |
16952 | IFS=$ac_save_IFS | |
16953 | shift | |
16954 | ac_file=$1 | |
16955 | shift | |
16956 | ||
16957 | case $ac_mode in | |
16958 | :L) ac_source=$1;; | |
16959 | :[FH]) | |
16960 | ac_file_inputs= | |
16961 | for ac_f | |
16962 | do | |
16963 | case $ac_f in | |
7f947b68 | 16964 | -) ac_f="$ac_tmp/stdin";; |
b709b946 CR |
16965 | *) # Look for the file first in the build tree, then in the source tree |
16966 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
16967 | # because $ac_f cannot contain `:'. | |
16968 | test -f "$ac_f" || | |
16969 | case $ac_f in | |
16970 | [\\/$]*) false;; | |
16971 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
16972 | esac || | |
7f947b68 | 16973 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
b709b946 | 16974 | esac |
dd4f3dd8 | 16975 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac |
7f947b68 | 16976 | as_fn_append ac_file_inputs " '$ac_f'" |
b709b946 | 16977 | done |
9d6e5e30 | 16978 | |
b709b946 CR |
16979 | # Let's still pretend it is `configure' which instantiates (i.e., don't |
16980 | # use $as_me), people would be surprised to read: | |
16981 | # /* config.h. Generated by config.status. */ | |
dd4f3dd8 CR |
16982 | configure_input='Generated from '` |
16983 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
16984 | `' by configure.' | |
b709b946 CR |
16985 | if test x"$ac_file" != x-; then |
16986 | configure_input="$ac_file. $configure_input" | |
7f947b68 | 16987 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 |
dd4f3dd8 | 16988 | $as_echo "$as_me: creating $ac_file" >&6;} |
b709b946 | 16989 | fi |
dd4f3dd8 CR |
16990 | # Neutralize special characters interpreted by sed in replacement strings. |
16991 | case $configure_input in #( | |
16992 | *\&* | *\|* | *\\* ) | |
16993 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
16994 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
16995 | *) ac_sed_conf_input=$configure_input;; | |
16996 | esac | |
b709b946 CR |
16997 | |
16998 | case $ac_tag in | |
7f947b68 CR |
16999 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
17000 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
b709b946 CR |
17001 | esac |
17002 | ;; | |
17003 | esac | |
17004 | ||
17005 | ac_dir=`$as_dirname -- "$ac_file" || | |
a82a04b3 | 17006 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
5e4a95c7 CR |
17007 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
17008 | X"$ac_file" : 'X\(//\)$' \| \ | |
b709b946 | 17009 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
dd4f3dd8 | 17010 | $as_echo X"$ac_file" | |
b709b946 CR |
17011 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ |
17012 | s//\1/ | |
17013 | q | |
17014 | } | |
17015 | /^X\(\/\/\)[^/].*/{ | |
17016 | s//\1/ | |
17017 | q | |
17018 | } | |
17019 | /^X\(\/\/\)$/{ | |
17020 | s//\1/ | |
17021 | q | |
17022 | } | |
17023 | /^X\(\/\).*/{ | |
17024 | s//\1/ | |
17025 | q | |
17026 | } | |
17027 | s/.*/./; q'` | |
7f947b68 | 17028 | as_dir="$ac_dir"; as_fn_mkdir_p |
a82a04b3 CR |
17029 | ac_builddir=. |
17030 | ||
b709b946 CR |
17031 | case "$ac_dir" in |
17032 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17033 | *) | |
dd4f3dd8 | 17034 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` |
b709b946 | 17035 | # A ".." for each directory in $ac_dir_suffix. |
dd4f3dd8 | 17036 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` |
b709b946 CR |
17037 | case $ac_top_builddir_sub in |
17038 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
17039 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
17040 | esac ;; | |
17041 | esac | |
17042 | ac_abs_top_builddir=$ac_pwd | |
17043 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
17044 | # for backward compatibility: | |
17045 | ac_top_builddir=$ac_top_build_prefix | |
a82a04b3 CR |
17046 | |
17047 | case $srcdir in | |
b709b946 | 17048 | .) # We are building in place. |
a82a04b3 | 17049 | ac_srcdir=. |
b709b946 CR |
17050 | ac_top_srcdir=$ac_top_builddir_sub |
17051 | ac_abs_top_srcdir=$ac_pwd ;; | |
17052 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
a82a04b3 | 17053 | ac_srcdir=$srcdir$ac_dir_suffix; |
b709b946 CR |
17054 | ac_top_srcdir=$srcdir |
17055 | ac_abs_top_srcdir=$srcdir ;; | |
17056 | *) # Relative name. | |
17057 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
17058 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
17059 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
a82a04b3 | 17060 | esac |
b709b946 | 17061 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
5e4a95c7 | 17062 | |
a82a04b3 | 17063 | |
b709b946 CR |
17064 | case $ac_mode in |
17065 | :F) | |
17066 | # | |
17067 | # CONFIG_FILE | |
17068 | # | |
ccc6cda3 | 17069 | |
f73dda09 JA |
17070 | case $INSTALL in |
17071 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
b709b946 | 17072 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
ccc6cda3 | 17073 | esac |
b709b946 | 17074 | _ACEOF |
ccc6cda3 | 17075 | |
dd4f3dd8 | 17076 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
b709b946 CR |
17077 | # If the template does not know about datarootdir, expand it. |
17078 | # FIXME: This hack should be removed a few years after 2.60. | |
17079 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
dd4f3dd8 CR |
17080 | ac_sed_dataroot=' |
17081 | /datarootdir/ { | |
b709b946 CR |
17082 | p |
17083 | q | |
17084 | } | |
17085 | /@datadir@/p | |
17086 | /@docdir@/p | |
17087 | /@infodir@/p | |
17088 | /@localedir@/p | |
7f947b68 | 17089 | /@mandir@/p' |
dd4f3dd8 | 17090 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in |
b709b946 CR |
17091 | *datarootdir*) ac_datarootdir_seen=yes;; |
17092 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
7f947b68 | 17093 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 |
dd4f3dd8 | 17094 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} |
9d6e5e30 | 17095 | _ACEOF |
dd4f3dd8 | 17096 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
b709b946 CR |
17097 | ac_datarootdir_hack=' |
17098 | s&@datadir@&$datadir&g | |
17099 | s&@docdir@&$docdir&g | |
17100 | s&@infodir@&$infodir&g | |
17101 | s&@localedir@&$localedir&g | |
17102 | s&@mandir@&$mandir&g | |
7f947b68 | 17103 | s&\\\${datarootdir}&$datarootdir&g' ;; |
b709b946 CR |
17104 | esac |
17105 | _ACEOF | |
17106 | ||
17107 | # Neutralize VPATH when `$srcdir' = `.'. | |
17108 | # Shell code in configure.ac might set extrasub. | |
17109 | # FIXME: do we really want to maintain this feature? | |
dd4f3dd8 CR |
17110 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
17111 | ac_sed_extra="$ac_vpsub | |
f73dda09 | 17112 | $extrasub |
a82a04b3 | 17113 | _ACEOF |
dd4f3dd8 | 17114 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
f73dda09 JA |
17115 | :t |
17116 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
dd4f3dd8 | 17117 | s|@configure_input@|$ac_sed_conf_input|;t t |
b709b946 | 17118 | s&@top_builddir@&$ac_top_builddir_sub&;t t |
dd4f3dd8 | 17119 | s&@top_build_prefix@&$ac_top_build_prefix&;t t |
b709b946 CR |
17120 | s&@srcdir@&$ac_srcdir&;t t |
17121 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
17122 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
17123 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
17124 | s&@builddir@&$ac_builddir&;t t | |
17125 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
17126 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
17127 | s&@INSTALL@&$ac_INSTALL&;t t | |
17128 | $ac_datarootdir_hack | |
dd4f3dd8 | 17129 | " |
7f947b68 CR |
17130 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
17131 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
b709b946 CR |
17132 | |
17133 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
7f947b68 CR |
17134 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
17135 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
17136 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
17137 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
17138 | which seems to be undefined. Please make sure it is defined" >&5 | |
dd4f3dd8 | 17139 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
7f947b68 | 17140 | which seems to be undefined. Please make sure it is defined" >&2;} |
b709b946 | 17141 | |
7f947b68 | 17142 | rm -f "$ac_tmp/stdin" |
f73dda09 | 17143 | case $ac_file in |
7f947b68 CR |
17144 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
17145 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
dd4f3dd8 | 17146 | esac \ |
7f947b68 | 17147 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
b709b946 CR |
17148 | ;; |
17149 | :H) | |
17150 | # | |
17151 | # CONFIG_HEADER | |
17152 | # | |
f73dda09 | 17153 | if test x"$ac_file" != x-; then |
dd4f3dd8 CR |
17154 | { |
17155 | $as_echo "/* $configure_input */" \ | |
7f947b68 CR |
17156 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
17157 | } >"$ac_tmp/config.h" \ | |
17158 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
17159 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then | |
17160 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 | |
dd4f3dd8 | 17161 | $as_echo "$as_me: $ac_file is unchanged" >&6;} |
f73dda09 | 17162 | else |
dd4f3dd8 | 17163 | rm -f "$ac_file" |
7f947b68 CR |
17164 | mv "$ac_tmp/config.h" "$ac_file" \ |
17165 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
ccc6cda3 | 17166 | fi |
f73dda09 | 17167 | else |
dd4f3dd8 | 17168 | $as_echo "/* $configure_input */" \ |
7f947b68 CR |
17169 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
17170 | || as_fn_error $? "could not create -" "$LINENO" 5 | |
ccc6cda3 | 17171 | fi |
b709b946 | 17172 | ;; |
c184f645 | 17173 | |
7f947b68 | 17174 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
dd4f3dd8 | 17175 | $as_echo "$as_me: executing $ac_file commands" >&6;} |
b709b946 CR |
17176 | ;; |
17177 | esac | |
a82a04b3 | 17178 | |
ccc6cda3 | 17179 | |
b709b946 CR |
17180 | case $ac_file$ac_mode in |
17181 | "default-1":C) | |
5e13499c CR |
17182 | for ac_file in $CONFIG_FILES; do |
17183 | # Support "outfile[:infile[:infile...]]" | |
17184 | case "$ac_file" in | |
17185 | *:*) ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;; | |
17186 | esac | |
17187 | # PO directories have a Makefile.in generated from Makefile.in.in. | |
17188 | case "$ac_file" in */Makefile.in) | |
17189 | # Adjust a relative srcdir. | |
17190 | ac_dir=`echo "$ac_file"|sed 's%/[^/][^/]*$%%'` | |
17191 | ac_dir_suffix="/`echo "$ac_dir"|sed 's%^\./%%'`" | |
17192 | ac_dots=`echo "$ac_dir_suffix"|sed 's%/[^/]*%../%g'` | |
17193 | # In autoconf-2.13 it is called $ac_given_srcdir. | |
17194 | # In autoconf-2.50 it is called $srcdir. | |
17195 | test -n "$ac_given_srcdir" || ac_given_srcdir="$srcdir" | |
17196 | case "$ac_given_srcdir" in | |
17197 | .) top_srcdir=`echo $ac_dots|sed 's%/$%%'` ;; | |
17198 | /*) top_srcdir="$ac_given_srcdir" ;; | |
17199 | *) top_srcdir="$ac_dots$ac_given_srcdir" ;; | |
17200 | esac | |
17201 | if test -f "$ac_given_srcdir/$ac_dir/POTFILES.in"; then | |
17202 | rm -f "$ac_dir/POTFILES" | |
17203 | test -n "$as_me" && echo "$as_me: creating $ac_dir/POTFILES" || echo "creating $ac_dir/POTFILES" | |
17204 | cat "$ac_given_srcdir/$ac_dir/POTFILES.in" | sed -e "/^#/d" -e "/^[ ]*\$/d" -e "s,.*, $top_srcdir/& \\\\," | sed -e "\$s/\(.*\) \\\\/\1/" > "$ac_dir/POTFILES" | |
17205 | POMAKEFILEDEPS="POTFILES.in" | |
17206 | # ALL_LINGUAS, POFILES, GMOFILES, UPDATEPOFILES, DUMMYPOFILES depend | |
17207 | # on $ac_dir but don't depend on user-specified configuration | |
17208 | # parameters. | |
17209 | if test -f "$ac_given_srcdir/$ac_dir/LINGUAS"; then | |
17210 | # The LINGUAS file contains the set of available languages. | |
17211 | if test -n "$OBSOLETE_ALL_LINGUAS"; then | |
17212 | test -n "$as_me" && echo "$as_me: setting ALL_LINGUAS in configure.in is obsolete" || echo "setting ALL_LINGUAS in configure.in is obsolete" | |
17213 | fi | |
17214 | ALL_LINGUAS_=`sed -e "/^#/d" "$ac_given_srcdir/$ac_dir/LINGUAS"` | |
17215 | # Hide the ALL_LINGUAS assigment from automake. | |
17216 | eval 'ALL_LINGUAS''=$ALL_LINGUAS_' | |
17217 | POMAKEFILEDEPS="$POMAKEFILEDEPS LINGUAS" | |
17218 | else | |
17219 | # The set of available languages was given in configure.in. | |
17220 | eval 'ALL_LINGUAS''=$OBSOLETE_ALL_LINGUAS' | |
17221 | fi | |
17222 | case "$ac_given_srcdir" in | |
17223 | .) srcdirpre= ;; | |
17224 | *) srcdirpre='$(srcdir)/' ;; | |
17225 | esac | |
17226 | POFILES= | |
17227 | GMOFILES= | |
17228 | UPDATEPOFILES= | |
17229 | DUMMYPOFILES= | |
17230 | for lang in $ALL_LINGUAS; do | |
17231 | POFILES="$POFILES $srcdirpre$lang.po" | |
17232 | GMOFILES="$GMOFILES $srcdirpre$lang.gmo" | |
17233 | UPDATEPOFILES="$UPDATEPOFILES $lang.po-update" | |
17234 | DUMMYPOFILES="$DUMMYPOFILES $lang.nop" | |
17235 | done | |
17236 | # CATALOGS depends on both $ac_dir and the user's LINGUAS | |
17237 | # environment variable. | |
17238 | INST_LINGUAS= | |
17239 | if test -n "$ALL_LINGUAS"; then | |
17240 | for presentlang in $ALL_LINGUAS; do | |
17241 | useit=no | |
17242 | if test "%UNSET%" != "$LINGUAS"; then | |
17243 | desiredlanguages="$LINGUAS" | |
17244 | else | |
17245 | desiredlanguages="$ALL_LINGUAS" | |
17246 | fi | |
17247 | for desiredlang in $desiredlanguages; do | |
17248 | # Use the presentlang catalog if desiredlang is | |
17249 | # a. equal to presentlang, or | |
17250 | # b. a variant of presentlang (because in this case, | |
17251 | # presentlang can be used as a fallback for messages | |
17252 | # which are not translated in the desiredlang catalog). | |
17253 | case "$desiredlang" in | |
17254 | "$presentlang"*) useit=yes;; | |
17255 | esac | |
17256 | done | |
17257 | if test $useit = yes; then | |
17258 | INST_LINGUAS="$INST_LINGUAS $presentlang" | |
17259 | fi | |
17260 | done | |
17261 | fi | |
17262 | CATALOGS= | |
17263 | if test -n "$INST_LINGUAS"; then | |
17264 | for lang in $INST_LINGUAS; do | |
17265 | CATALOGS="$CATALOGS $lang.gmo" | |
17266 | done | |
17267 | fi | |
17268 | test -n "$as_me" && echo "$as_me: creating $ac_dir/Makefile" || echo "creating $ac_dir/Makefile" | |
17269 | 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" | |
17270 | for f in "$ac_given_srcdir/$ac_dir"/Rules-*; do | |
17271 | if test -f "$f"; then | |
17272 | case "$f" in | |
17273 | *.orig | *.bak | *~) ;; | |
17274 | *) cat "$f" >> "$ac_dir/Makefile" ;; | |
17275 | esac | |
17276 | fi | |
17277 | done | |
17278 | fi | |
17279 | ;; | |
17280 | esac | |
17281 | done ;; | |
b709b946 | 17282 | "default":C) |
ccc6cda3 JA |
17283 | # Makefile uses this timestamp file to record whether config.h is up to date. |
17284 | echo timestamp > stamp-h | |
f73dda09 | 17285 | ;; |
b709b946 | 17286 | |
f73dda09 | 17287 | esac |
b709b946 | 17288 | done # for ac_tag |
ccc6cda3 | 17289 | |
f73dda09 | 17290 | |
7f947b68 | 17291 | as_fn_exit 0 |
a82a04b3 | 17292 | _ACEOF |
f73dda09 JA |
17293 | ac_clean_files=$ac_clean_files_save |
17294 | ||
dd4f3dd8 | 17295 | test $ac_write_fail = 0 || |
7f947b68 | 17296 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
dd4f3dd8 | 17297 | |
a82a04b3 | 17298 | |
f73dda09 JA |
17299 | # configure is writing to config.log, and then calls config.status. |
17300 | # config.status does its own redirection, appending to config.log. | |
17301 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
17302 | # by configure, so config.status won't be able to write to it; its | |
17303 | # output is simply discarded. So we exec the FD to /dev/null, | |
17304 | # effectively closing config.log, so it can be properly (re)opened and | |
17305 | # appended to by config.status. When coming back to configure, we | |
17306 | # need to make the FD available again. | |
17307 | if test "$no_create" != yes; then | |
17308 | ac_cs_success=: | |
5e4a95c7 CR |
17309 | ac_config_status_args= |
17310 | test "$silent" = yes && | |
17311 | ac_config_status_args="$ac_config_status_args --quiet" | |
f73dda09 | 17312 | exec 5>/dev/null |
5e4a95c7 | 17313 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false |
f73dda09 JA |
17314 | exec 5>>config.log |
17315 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
17316 | # would make configure fail if this is the last instruction. | |
7f947b68 | 17317 | $ac_cs_success || as_fn_exit 1 |
f73dda09 | 17318 | fi |
dd4f3dd8 | 17319 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then |
7f947b68 | 17320 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 |
af98a2a6 | 17321 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} |
dd4f3dd8 | 17322 | fi |
bc7bed50 | 17323 |