]>
Commit | Line | Data |
---|---|---|
0bc0cd11 | 1 | #! /bin/sh |
0bc0cd11 | 2 | # Guess values for system-dependent variables and create Makefiles. |
22e05272 JM |
3 | # Generated by GNU Autoconf 2.69. |
4 | # | |
5 | # | |
6 | # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. | |
5213506e | 7 | # |
0bc0cd11 JL |
8 | # |
9 | # This configure script is free software; the Free Software Foundation | |
10 | # gives unlimited permission to copy, distribute and modify it. | |
5213506e RW |
11 | ## -------------------- ## |
12 | ## M4sh Initialization. ## | |
13 | ## -------------------- ## | |
238235ef | 14 | |
5213506e RW |
15 | # Be more Bourne compatible |
16 | DUALCASE=1; export DUALCASE # for MKS sh | |
17 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
238235ef DJ |
18 | emulate sh |
19 | NULLCMD=: | |
5213506e | 20 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
238235ef DJ |
21 | # is contrary to our usage. Disable this feature. |
22 | alias -g '${1+"$@"}'='"$@"' | |
5213506e RW |
23 | setopt NO_GLOB_SUBST |
24 | else | |
25 | case `(set -o) 2>/dev/null` in #( | |
26 | *posix*) : | |
27 | set -o posix ;; #( | |
28 | *) : | |
29 | ;; | |
30 | esac | |
238235ef DJ |
31 | fi |
32 | ||
5213506e RW |
33 | |
34 | as_nl=' | |
35 | ' | |
36 | export as_nl | |
37 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
38 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
39 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
40 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
41 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
42 | # but without wasting forks for bash or zsh. | |
43 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
44 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
45 | as_echo='print -r --' | |
46 | as_echo_n='print -rn --' | |
47 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
48 | as_echo='printf %s\n' | |
49 | as_echo_n='printf %s' | |
50 | else | |
51 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
52 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
53 | as_echo_n='/usr/ucb/echo -n' | |
54 | else | |
55 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
56 | as_echo_n_body='eval | |
57 | arg=$1; | |
58 | case $arg in #( | |
59 | *"$as_nl"*) | |
60 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
61 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
62 | esac; | |
63 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
64 | ' | |
65 | export as_echo_n_body | |
66 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
67 | fi | |
68 | export as_echo_body | |
69 | as_echo='sh -c $as_echo_body as_echo' | |
70 | fi | |
71 | ||
72 | # The user is always right. | |
73 | if test "${PATH_SEPARATOR+set}" != set; then | |
74 | PATH_SEPARATOR=: | |
75 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
76 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
77 | PATH_SEPARATOR=';' | |
78 | } | |
238235ef DJ |
79 | fi |
80 | ||
81 | ||
5213506e RW |
82 | # IFS |
83 | # We need space, tab and new line, in precisely that order. Quoting is | |
84 | # there to prevent editors from complaining about space-tab. | |
85 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
86 | # splitting by setting IFS to empty value.) | |
87 | IFS=" "" $as_nl" | |
88 | ||
89 | # Find who we are. Look in the path if we contain no directory separator. | |
22e05272 | 90 | as_myself= |
5213506e RW |
91 | case $0 in #(( |
92 | *[\\/]* ) as_myself=$0 ;; | |
93 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
94 | for as_dir in $PATH | |
95 | do | |
96 | IFS=$as_save_IFS | |
97 | test -z "$as_dir" && as_dir=. | |
98 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
99 | done | |
100 | IFS=$as_save_IFS | |
101 | ||
102 | ;; | |
103 | esac | |
104 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
105 | # in which case we are not to be found in the path. | |
106 | if test "x$as_myself" = x; then | |
107 | as_myself=$0 | |
108 | fi | |
109 | if test ! -f "$as_myself"; then | |
110 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
111 | exit 1 | |
112 | fi | |
113 | ||
114 | # Unset variables that we do not need and which cause bugs (e.g. in | |
115 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
116 | # suppresses any "Segmentation fault" message there. '((' could | |
117 | # trigger a bug in pdksh 5.2.14. | |
118 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
119 | do eval test x\${$as_var+set} = xset \ | |
120 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
121 | done | |
238235ef DJ |
122 | PS1='$ ' |
123 | PS2='> ' | |
124 | PS4='+ ' | |
125 | ||
126 | # NLS nuisances. | |
5213506e RW |
127 | LC_ALL=C |
128 | export LC_ALL | |
129 | LANGUAGE=C | |
130 | export LANGUAGE | |
131 | ||
132 | # CDPATH. | |
133 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
134 | ||
22e05272 JM |
135 | # Use a proper internal environment variable to ensure we don't fall |
136 | # into an infinite loop, continuously re-executing ourselves. | |
137 | if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then | |
138 | _as_can_reexec=no; export _as_can_reexec; | |
139 | # We cannot yet assume a decent shell, so we have to provide a | |
140 | # neutralization value for shells without unset; and this also | |
141 | # works around shells that cannot unset nonexistent variables. | |
142 | # Preserve -v and -x to the replacement shell. | |
143 | BASH_ENV=/dev/null | |
144 | ENV=/dev/null | |
145 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
146 | case $- in # (((( | |
147 | *v*x* | *x*v* ) as_opts=-vx ;; | |
148 | *v* ) as_opts=-v ;; | |
149 | *x* ) as_opts=-x ;; | |
150 | * ) as_opts= ;; | |
151 | esac | |
152 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} | |
153 | # Admittedly, this is quite paranoid, since all the known shells bail | |
154 | # out after a failed `exec'. | |
155 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 | |
156 | as_fn_exit 255 | |
157 | fi | |
158 | # We don't want this to propagate to other subprocesses. | |
159 | { _as_can_reexec=; unset _as_can_reexec;} | |
5213506e RW |
160 | if test "x$CONFIG_SHELL" = x; then |
161 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
162 | emulate sh | |
163 | NULLCMD=: | |
164 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
165 | # is contrary to our usage. Disable this feature. | |
166 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
167 | setopt NO_GLOB_SUBST | |
168 | else | |
169 | case \`(set -o) 2>/dev/null\` in #( | |
170 | *posix*) : | |
171 | set -o posix ;; #( | |
172 | *) : | |
173 | ;; | |
174 | esac | |
175 | fi | |
176 | " | |
177 | as_required="as_fn_return () { (exit \$1); } | |
178 | as_fn_success () { as_fn_return 0; } | |
179 | as_fn_failure () { as_fn_return 1; } | |
180 | as_fn_ret_success () { return 0; } | |
181 | as_fn_ret_failure () { return 1; } | |
182 | ||
183 | exitcode=0 | |
184 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
185 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
186 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
187 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
188 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
189 | ||
190 | else | |
191 | exitcode=1; echo positional parameters were not saved. | |
192 | fi | |
22e05272 JM |
193 | test x\$exitcode = x0 || exit 1 |
194 | test -x / || exit 1" | |
5213506e RW |
195 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO |
196 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
197 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
198 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
199 | test \$(( 1 + 1 )) = 2 || exit 1" | |
200 | if (eval "$as_required") 2>/dev/null; then : | |
201 | as_have_required=yes | |
202 | else | |
203 | as_have_required=no | |
204 | fi | |
205 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
206 | ||
207 | else | |
208 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
209 | as_found=false | |
210 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
238235ef | 211 | do |
5213506e RW |
212 | IFS=$as_save_IFS |
213 | test -z "$as_dir" && as_dir=. | |
214 | as_found=: | |
215 | case $as_dir in #( | |
216 | /*) | |
217 | for as_base in sh bash ksh sh5; do | |
218 | # Try only shells that exist, to save several forks. | |
219 | as_shell=$as_dir/$as_base | |
220 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
221 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
222 | CONFIG_SHELL=$as_shell as_have_required=yes | |
223 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
224 | break 2 | |
225 | fi | |
226 | fi | |
227 | done;; | |
228 | esac | |
229 | as_found=false | |
230 | done | |
231 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
232 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
233 | CONFIG_SHELL=$SHELL as_have_required=yes | |
234 | fi; } | |
235 | IFS=$as_save_IFS | |
236 | ||
237 | ||
238 | if test "x$CONFIG_SHELL" != x; then : | |
22e05272 JM |
239 | export CONFIG_SHELL |
240 | # We cannot yet assume a decent shell, so we have to provide a | |
241 | # neutralization value for shells without unset; and this also | |
242 | # works around shells that cannot unset nonexistent variables. | |
243 | # Preserve -v and -x to the replacement shell. | |
244 | BASH_ENV=/dev/null | |
245 | ENV=/dev/null | |
246 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
247 | case $- in # (((( | |
248 | *v*x* | *x*v* ) as_opts=-vx ;; | |
249 | *v* ) as_opts=-v ;; | |
250 | *x* ) as_opts=-x ;; | |
251 | * ) as_opts= ;; | |
252 | esac | |
253 | exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} | |
254 | # Admittedly, this is quite paranoid, since all the known shells bail | |
255 | # out after a failed `exec'. | |
256 | $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 | |
257 | exit 255 | |
5213506e RW |
258 | fi |
259 | ||
260 | if test x$as_have_required = xno; then : | |
261 | $as_echo "$0: This script requires a shell more modern than all" | |
262 | $as_echo "$0: the shells that I found on your system." | |
263 | if test x${ZSH_VERSION+set} = xset ; then | |
264 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
265 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
238235ef | 266 | else |
5213506e RW |
267 | $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, |
268 | $0: including any error possibly output before this | |
269 | $0: message. Then install a modern shell, or manually run | |
270 | $0: the script under such a shell if you do have one." | |
238235ef | 271 | fi |
5213506e RW |
272 | exit 1 |
273 | fi | |
274 | fi | |
275 | fi | |
276 | SHELL=${CONFIG_SHELL-/bin/sh} | |
277 | export SHELL | |
278 | # Unset more variables known to interfere with behavior of common tools. | |
279 | CLICOLOR_FORCE= GREP_OPTIONS= | |
280 | unset CLICOLOR_FORCE GREP_OPTIONS | |
281 | ||
282 | ## --------------------- ## | |
283 | ## M4sh Shell Functions. ## | |
284 | ## --------------------- ## | |
285 | # as_fn_unset VAR | |
286 | # --------------- | |
287 | # Portably unset VAR. | |
288 | as_fn_unset () | |
289 | { | |
290 | { eval $1=; unset $1;} | |
291 | } | |
292 | as_unset=as_fn_unset | |
293 | ||
294 | # as_fn_set_status STATUS | |
295 | # ----------------------- | |
296 | # Set $? to STATUS, without forking. | |
297 | as_fn_set_status () | |
298 | { | |
299 | return $1 | |
300 | } # as_fn_set_status | |
301 | ||
302 | # as_fn_exit STATUS | |
303 | # ----------------- | |
304 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
305 | as_fn_exit () | |
306 | { | |
307 | set +e | |
308 | as_fn_set_status $1 | |
309 | exit $1 | |
310 | } # as_fn_exit | |
311 | ||
312 | # as_fn_mkdir_p | |
313 | # ------------- | |
314 | # Create "$as_dir" as a directory, including parents if necessary. | |
315 | as_fn_mkdir_p () | |
316 | { | |
317 | ||
318 | case $as_dir in #( | |
319 | -*) as_dir=./$as_dir;; | |
320 | esac | |
321 | test -d "$as_dir" || eval $as_mkdir_p || { | |
322 | as_dirs= | |
323 | while :; do | |
324 | case $as_dir in #( | |
325 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
326 | *) as_qdir=$as_dir;; | |
327 | esac | |
328 | as_dirs="'$as_qdir' $as_dirs" | |
329 | as_dir=`$as_dirname -- "$as_dir" || | |
330 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
331 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
332 | X"$as_dir" : 'X\(//\)$' \| \ | |
333 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
334 | $as_echo X"$as_dir" | | |
335 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
336 | s//\1/ | |
337 | q | |
338 | } | |
339 | /^X\(\/\/\)[^/].*/{ | |
340 | s//\1/ | |
341 | q | |
342 | } | |
343 | /^X\(\/\/\)$/{ | |
344 | s//\1/ | |
345 | q | |
346 | } | |
347 | /^X\(\/\).*/{ | |
348 | s//\1/ | |
349 | q | |
350 | } | |
351 | s/.*/./; q'` | |
352 | test -d "$as_dir" && break | |
353 | done | |
354 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
22e05272 | 355 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
5213506e RW |
356 | |
357 | ||
358 | } # as_fn_mkdir_p | |
22e05272 JM |
359 | |
360 | # as_fn_executable_p FILE | |
361 | # ----------------------- | |
362 | # Test if FILE is an executable regular file. | |
363 | as_fn_executable_p () | |
364 | { | |
365 | test -f "$1" && test -x "$1" | |
366 | } # as_fn_executable_p | |
5213506e RW |
367 | # as_fn_append VAR VALUE |
368 | # ---------------------- | |
369 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
370 | # advantage of any shell optimizations that allow amortized linear growth over | |
371 | # repeated appends, instead of the typical quadratic growth present in naive | |
372 | # implementations. | |
373 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
374 | eval 'as_fn_append () | |
375 | { | |
376 | eval $1+=\$2 | |
377 | }' | |
378 | else | |
379 | as_fn_append () | |
380 | { | |
381 | eval $1=\$$1\$2 | |
382 | } | |
383 | fi # as_fn_append | |
384 | ||
385 | # as_fn_arith ARG... | |
386 | # ------------------ | |
387 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
388 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
389 | # must be portable across $(()) and expr. | |
390 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
391 | eval 'as_fn_arith () | |
392 | { | |
393 | as_val=$(( $* )) | |
394 | }' | |
395 | else | |
396 | as_fn_arith () | |
397 | { | |
398 | as_val=`expr "$@" || test $? -eq 1` | |
399 | } | |
400 | fi # as_fn_arith | |
401 | ||
402 | ||
22e05272 JM |
403 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
404 | # ---------------------------------------- | |
5213506e RW |
405 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
406 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
22e05272 | 407 | # script with STATUS, using 1 if that was 0. |
5213506e RW |
408 | as_fn_error () |
409 | { | |
22e05272 JM |
410 | as_status=$1; test $as_status -eq 0 && as_status=1 |
411 | if test "$4"; then | |
412 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
413 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
5213506e | 414 | fi |
22e05272 | 415 | $as_echo "$as_me: error: $2" >&2 |
5213506e RW |
416 | as_fn_exit $as_status |
417 | } # as_fn_error | |
238235ef | 418 | |
5213506e RW |
419 | if expr a : '\(a\)' >/dev/null 2>&1 && |
420 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
238235ef DJ |
421 | as_expr=expr |
422 | else | |
423 | as_expr=false | |
424 | fi | |
425 | ||
5213506e | 426 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
238235ef DJ |
427 | as_basename=basename |
428 | else | |
429 | as_basename=false | |
430 | fi | |
431 | ||
5213506e RW |
432 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
433 | as_dirname=dirname | |
434 | else | |
435 | as_dirname=false | |
436 | fi | |
238235ef | 437 | |
5213506e | 438 | as_me=`$as_basename -- "$0" || |
238235ef DJ |
439 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
440 | X"$0" : 'X\(//\)$' \| \ | |
5213506e RW |
441 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
442 | $as_echo X/"$0" | | |
443 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
444 | s//\1/ | |
445 | q | |
446 | } | |
447 | /^X\/\(\/\/\)$/{ | |
448 | s//\1/ | |
449 | q | |
450 | } | |
451 | /^X\/\(\/\).*/{ | |
452 | s//\1/ | |
453 | q | |
454 | } | |
455 | s/.*/./; q'` | |
238235ef | 456 | |
238235ef DJ |
457 | # Avoid depending upon Character Ranges. |
458 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
459 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
460 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
461 | as_cr_digits='0123456789' | |
462 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
463 | ||
238235ef | 464 | |
5213506e RW |
465 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
466 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
467 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
468 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
469 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
470 | sed -n ' | |
471 | p | |
472 | /[$]LINENO/= | |
473 | ' <$as_myself | | |
238235ef | 474 | sed ' |
5213506e RW |
475 | s/[$]LINENO.*/&-/ |
476 | t lineno | |
477 | b | |
478 | :lineno | |
238235ef | 479 | N |
5213506e RW |
480 | :loop |
481 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
238235ef | 482 | t loop |
5213506e | 483 | s/-\n.*// |
238235ef | 484 | ' >$as_me.lineno && |
5213506e RW |
485 | chmod +x "$as_me.lineno" || |
486 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
238235ef | 487 | |
22e05272 JM |
488 | # If we had to re-execute with $CONFIG_SHELL, we're ensured to have |
489 | # already done that, so ensure we don't try to do so again and fall | |
490 | # in an infinite loop. This has already happened in practice. | |
491 | _as_can_reexec=no; export _as_can_reexec | |
238235ef DJ |
492 | # Don't try to exec as it changes $[0], causing all sort of problems |
493 | # (the dirname of $[0] is not the place where we might find the | |
5213506e RW |
494 | # original and so on. Autoconf is especially sensitive to this). |
495 | . "./$as_me.lineno" | |
238235ef DJ |
496 | # Exit status is that of the last command. |
497 | exit | |
498 | } | |
499 | ||
5213506e RW |
500 | ECHO_C= ECHO_N= ECHO_T= |
501 | case `echo -n x` in #((((( | |
502 | -n*) | |
503 | case `echo 'xy\c'` in | |
504 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
505 | xy) ECHO_C='\c';; | |
506 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
507 | ECHO_T=' ';; | |
508 | esac;; | |
509 | *) | |
510 | ECHO_N='-n';; | |
238235ef DJ |
511 | esac |
512 | ||
5213506e RW |
513 | rm -f conf$$ conf$$.exe conf$$.file |
514 | if test -d conf$$.dir; then | |
515 | rm -f conf$$.dir/conf$$.file | |
238235ef | 516 | else |
5213506e RW |
517 | rm -f conf$$.dir |
518 | mkdir conf$$.dir 2>/dev/null | |
238235ef | 519 | fi |
5213506e RW |
520 | if (echo >conf$$.file) 2>/dev/null; then |
521 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
238235ef | 522 | as_ln_s='ln -s' |
5213506e RW |
523 | # ... but there are two gotchas: |
524 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
525 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
22e05272 | 526 | # In both cases, we have to default to `cp -pR'. |
5213506e | 527 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
22e05272 | 528 | as_ln_s='cp -pR' |
5213506e RW |
529 | elif ln conf$$.file conf$$ 2>/dev/null; then |
530 | as_ln_s=ln | |
531 | else | |
22e05272 | 532 | as_ln_s='cp -pR' |
238235ef | 533 | fi |
238235ef | 534 | else |
22e05272 | 535 | as_ln_s='cp -pR' |
238235ef | 536 | fi |
5213506e RW |
537 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
538 | rmdir conf$$.dir 2>/dev/null | |
238235ef DJ |
539 | |
540 | if mkdir -p . 2>/dev/null; then | |
5213506e | 541 | as_mkdir_p='mkdir -p "$as_dir"' |
238235ef | 542 | else |
3beb1315 | 543 | test -d ./-p && rmdir ./-p |
238235ef DJ |
544 | as_mkdir_p=false |
545 | fi | |
546 | ||
22e05272 JM |
547 | as_test_x='test -x' |
548 | as_executable_p=as_fn_executable_p | |
238235ef DJ |
549 | |
550 | # Sed expression to map a string onto a valid CPP name. | |
3beb1315 | 551 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
238235ef DJ |
552 | |
553 | # Sed expression to map a string onto a valid variable name. | |
3beb1315 | 554 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
238235ef DJ |
555 | |
556 | ||
22e05272 JM |
557 | test -n "$DJDIR" || exec 7<&0 </dev/null |
558 | exec 6>&1 | |
238235ef DJ |
559 | |
560 | # Name of the host. | |
22e05272 | 561 | # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, |
238235ef DJ |
562 | # so uname gets run too. |
563 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
564 | ||
238235ef DJ |
565 | # |
566 | # Initializations. | |
567 | # | |
0bc0cd11 | 568 | ac_default_prefix=/usr/local |
5213506e | 569 | ac_clean_files= |
238235ef | 570 | ac_config_libobj_dir=. |
5213506e | 571 | LIBOBJS= |
238235ef DJ |
572 | cross_compiling=no |
573 | subdirs= | |
574 | MFLAGS= | |
575 | MAKEFLAGS= | |
238235ef DJ |
576 | |
577 | # Identity of this package. | |
578 | PACKAGE_NAME= | |
579 | PACKAGE_TARNAME= | |
580 | PACKAGE_VERSION= | |
581 | PACKAGE_STRING= | |
582 | PACKAGE_BUGREPORT= | |
5213506e | 583 | PACKAGE_URL= |
238235ef DJ |
584 | |
585 | ac_unique_file="xmalloc.c" | |
586 | # Factoring default headers for most tests. | |
587 | ac_includes_default="\ | |
588 | #include <stdio.h> | |
5213506e | 589 | #ifdef HAVE_SYS_TYPES_H |
238235ef DJ |
590 | # include <sys/types.h> |
591 | #endif | |
5213506e | 592 | #ifdef HAVE_SYS_STAT_H |
238235ef DJ |
593 | # include <sys/stat.h> |
594 | #endif | |
5213506e | 595 | #ifdef STDC_HEADERS |
238235ef DJ |
596 | # include <stdlib.h> |
597 | # include <stddef.h> | |
598 | #else | |
5213506e | 599 | # ifdef HAVE_STDLIB_H |
238235ef DJ |
600 | # include <stdlib.h> |
601 | # endif | |
602 | #endif | |
5213506e RW |
603 | #ifdef HAVE_STRING_H |
604 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
238235ef DJ |
605 | # include <memory.h> |
606 | # endif | |
607 | # include <string.h> | |
608 | #endif | |
5213506e | 609 | #ifdef HAVE_STRINGS_H |
238235ef DJ |
610 | # include <strings.h> |
611 | #endif | |
5213506e | 612 | #ifdef HAVE_INTTYPES_H |
238235ef | 613 | # include <inttypes.h> |
238235ef | 614 | #endif |
5213506e RW |
615 | #ifdef HAVE_STDINT_H |
616 | # include <stdint.h> | |
617 | #endif | |
618 | #ifdef HAVE_UNISTD_H | |
238235ef DJ |
619 | # include <unistd.h> |
620 | #endif" | |
621 | ||
22e05272 | 622 | ac_header_list= |
5213506e RW |
623 | ac_subst_vars='LTLIBOBJS |
624 | INSTALL_DEST | |
625 | pexecute | |
626 | target_header_dir | |
627 | CHECK | |
628 | LIBOBJS | |
f2c52c0d RO |
629 | HWCAP_CFLAGS |
630 | target_os | |
631 | target_vendor | |
632 | target_cpu | |
633 | target | |
8fc8bf80 | 634 | CET_HOST_FLAGS |
4f148bbc | 635 | NOASANFLAG |
5213506e RW |
636 | PICFLAG |
637 | INSTALL_DATA | |
638 | INSTALL_SCRIPT | |
639 | INSTALL_PROGRAM | |
5213506e RW |
640 | OUTPUT_OPTION |
641 | NO_MINUS_C_MINUS_O | |
642 | ac_libiberty_warn_cflags | |
f50f17e6 YJ |
643 | EGREP |
644 | GREP | |
5213506e RW |
645 | CPP |
646 | OBJEXT | |
647 | EXEEXT | |
648 | ac_ct_CC | |
649 | CPPFLAGS | |
650 | LDFLAGS | |
651 | CFLAGS | |
652 | CC | |
126f707e L |
653 | RANLIB_PLUGIN_OPTION |
654 | AR_PLUGIN_OPTION | |
5213506e RW |
655 | RANLIB |
656 | AR | |
657 | host_os | |
658 | host_vendor | |
659 | host_cpu | |
660 | host | |
661 | build_os | |
662 | build_vendor | |
663 | build_cpu | |
664 | build | |
665 | HAVE_PERL | |
666 | PERL | |
667 | BUILD_INFO | |
668 | MAKEINFO | |
909b30a1 | 669 | ETAGS |
5213506e RW |
670 | NOTMAINT |
671 | MAINT | |
672 | libiberty_topdir | |
673 | target_alias | |
674 | host_alias | |
675 | build_alias | |
676 | LIBS | |
677 | ECHO_T | |
678 | ECHO_N | |
679 | ECHO_C | |
680 | DEFS | |
681 | mandir | |
682 | localedir | |
683 | libdir | |
684 | psdir | |
685 | pdfdir | |
686 | dvidir | |
687 | htmldir | |
688 | infodir | |
689 | docdir | |
690 | oldincludedir | |
691 | includedir | |
692 | localstatedir | |
693 | sharedstatedir | |
694 | sysconfdir | |
695 | datadir | |
696 | datarootdir | |
697 | libexecdir | |
698 | sbindir | |
699 | bindir | |
700 | program_transform_name | |
701 | prefix | |
702 | exec_prefix | |
703 | PACKAGE_URL | |
704 | PACKAGE_BUGREPORT | |
705 | PACKAGE_STRING | |
706 | PACKAGE_VERSION | |
707 | PACKAGE_TARNAME | |
708 | PACKAGE_NAME | |
709 | PATH_SEPARATOR | |
710 | SHELL' | |
238235ef | 711 | ac_subst_files='host_makefile_frag' |
5213506e RW |
712 | ac_user_opts=' |
713 | enable_option_checking | |
714 | with_target_subdir | |
715 | with_build_subdir | |
716 | with_cross_host | |
717 | with_newlib | |
718 | enable_maintainer_mode | |
719 | enable_multilib | |
5213506e | 720 | enable_install_libiberty |
8c9fddf4 | 721 | enable_largefile |
8fc8bf80 | 722 | enable_cet |
5213506e RW |
723 | ' |
724 | ac_precious_vars='build_alias | |
725 | host_alias | |
726 | target_alias | |
727 | CC | |
728 | CFLAGS | |
729 | LDFLAGS | |
730 | LIBS | |
731 | CPPFLAGS | |
732 | CPP' | |
733 | ||
0bc0cd11 JL |
734 | |
735 | # Initialize some variables set by options. | |
238235ef DJ |
736 | ac_init_help= |
737 | ac_init_version=false | |
5213506e RW |
738 | ac_unrecognized_opts= |
739 | ac_unrecognized_sep= | |
0bc0cd11 JL |
740 | # The variables have the same names as the options, with |
741 | # dashes changed to underlines. | |
238235ef | 742 | cache_file=/dev/null |
0bc0cd11 | 743 | exec_prefix=NONE |
0bc0cd11 | 744 | no_create= |
0bc0cd11 JL |
745 | no_recursion= |
746 | prefix=NONE | |
747 | program_prefix=NONE | |
748 | program_suffix=NONE | |
749 | program_transform_name=s,x,x, | |
750 | silent= | |
751 | site= | |
752 | srcdir= | |
0bc0cd11 JL |
753 | verbose= |
754 | x_includes=NONE | |
755 | x_libraries=NONE | |
238235ef DJ |
756 | |
757 | # Installation directory options. | |
758 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
759 | # and all the variables that are supposed to be based on exec_prefix | |
760 | # by default will actually change. | |
761 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
5213506e | 762 | # (The list follows the same order as the GNU Coding Standards.) |
0bc0cd11 JL |
763 | bindir='${exec_prefix}/bin' |
764 | sbindir='${exec_prefix}/sbin' | |
765 | libexecdir='${exec_prefix}/libexec' | |
5213506e RW |
766 | datarootdir='${prefix}/share' |
767 | datadir='${datarootdir}' | |
0bc0cd11 JL |
768 | sysconfdir='${prefix}/etc' |
769 | sharedstatedir='${prefix}/com' | |
770 | localstatedir='${prefix}/var' | |
0bc0cd11 JL |
771 | includedir='${prefix}/include' |
772 | oldincludedir='/usr/include' | |
5213506e RW |
773 | docdir='${datarootdir}/doc/${PACKAGE}' |
774 | infodir='${datarootdir}/info' | |
775 | htmldir='${docdir}' | |
776 | dvidir='${docdir}' | |
777 | pdfdir='${docdir}' | |
778 | psdir='${docdir}' | |
779 | libdir='${exec_prefix}/lib' | |
780 | localedir='${datarootdir}/locale' | |
781 | mandir='${datarootdir}/man' | |
0bc0cd11 | 782 | |
0bc0cd11 | 783 | ac_prev= |
5213506e | 784 | ac_dashdash= |
0bc0cd11 JL |
785 | for ac_option |
786 | do | |
0bc0cd11 JL |
787 | # If the previous option needs an argument, assign it. |
788 | if test -n "$ac_prev"; then | |
5213506e | 789 | eval $ac_prev=\$ac_option |
0bc0cd11 JL |
790 | ac_prev= |
791 | continue | |
792 | fi | |
793 | ||
5213506e | 794 | case $ac_option in |
22e05272 JM |
795 | *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; |
796 | *=) ac_optarg= ;; | |
797 | *) ac_optarg=yes ;; | |
5213506e | 798 | esac |
0bc0cd11 JL |
799 | |
800 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
801 | ||
5213506e RW |
802 | case $ac_dashdash$ac_option in |
803 | --) | |
804 | ac_dashdash=yes ;; | |
0bc0cd11 JL |
805 | |
806 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
807 | ac_prev=bindir ;; | |
808 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
238235ef | 809 | bindir=$ac_optarg ;; |
0bc0cd11 JL |
810 | |
811 | -build | --build | --buil | --bui | --bu) | |
238235ef | 812 | ac_prev=build_alias ;; |
0bc0cd11 | 813 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
238235ef | 814 | build_alias=$ac_optarg ;; |
0bc0cd11 JL |
815 | |
816 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
817 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
818 | ac_prev=cache_file ;; | |
819 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
820 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
238235ef DJ |
821 | cache_file=$ac_optarg ;; |
822 | ||
823 | --config-cache | -C) | |
824 | cache_file=config.cache ;; | |
0bc0cd11 | 825 | |
5213506e | 826 | -datadir | --datadir | --datadi | --datad) |
0bc0cd11 | 827 | ac_prev=datadir ;; |
5213506e | 828 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
238235ef | 829 | datadir=$ac_optarg ;; |
0bc0cd11 | 830 | |
5213506e RW |
831 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
832 | | --dataroo | --dataro | --datar) | |
833 | ac_prev=datarootdir ;; | |
834 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
835 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
836 | datarootdir=$ac_optarg ;; | |
837 | ||
0bc0cd11 | 838 | -disable-* | --disable-*) |
5213506e | 839 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
0bc0cd11 | 840 | # Reject names that are not valid shell variable names. |
5213506e | 841 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
22e05272 | 842 | as_fn_error $? "invalid feature name: $ac_useropt" |
5213506e RW |
843 | ac_useropt_orig=$ac_useropt |
844 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
845 | case $ac_user_opts in | |
846 | *" | |
847 | "enable_$ac_useropt" | |
848 | "*) ;; | |
849 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
850 | ac_unrecognized_sep=', ';; | |
851 | esac | |
852 | eval enable_$ac_useropt=no ;; | |
853 | ||
854 | -docdir | --docdir | --docdi | --doc | --do) | |
855 | ac_prev=docdir ;; | |
856 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
857 | docdir=$ac_optarg ;; | |
858 | ||
859 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
860 | ac_prev=dvidir ;; | |
861 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
862 | dvidir=$ac_optarg ;; | |
0bc0cd11 JL |
863 | |
864 | -enable-* | --enable-*) | |
5213506e | 865 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
0bc0cd11 | 866 | # Reject names that are not valid shell variable names. |
5213506e | 867 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
22e05272 | 868 | as_fn_error $? "invalid feature name: $ac_useropt" |
5213506e RW |
869 | ac_useropt_orig=$ac_useropt |
870 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
871 | case $ac_user_opts in | |
872 | *" | |
873 | "enable_$ac_useropt" | |
874 | "*) ;; | |
875 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
876 | ac_unrecognized_sep=', ';; | |
0bc0cd11 | 877 | esac |
5213506e | 878 | eval enable_$ac_useropt=\$ac_optarg ;; |
0bc0cd11 JL |
879 | |
880 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
881 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
882 | | --exec | --exe | --ex) | |
883 | ac_prev=exec_prefix ;; | |
884 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
885 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
886 | | --exec=* | --exe=* | --ex=*) | |
238235ef | 887 | exec_prefix=$ac_optarg ;; |
0bc0cd11 JL |
888 | |
889 | -gas | --gas | --ga | --g) | |
890 | # Obsolete; use --with-gas. | |
891 | with_gas=yes ;; | |
892 | ||
238235ef DJ |
893 | -help | --help | --hel | --he | -h) |
894 | ac_init_help=long ;; | |
895 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
896 | ac_init_help=recursive ;; | |
897 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
898 | ac_init_help=short ;; | |
0bc0cd11 JL |
899 | |
900 | -host | --host | --hos | --ho) | |
238235ef | 901 | ac_prev=host_alias ;; |
0bc0cd11 | 902 | -host=* | --host=* | --hos=* | --ho=*) |
238235ef | 903 | host_alias=$ac_optarg ;; |
0bc0cd11 | 904 | |
5213506e RW |
905 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
906 | ac_prev=htmldir ;; | |
907 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
908 | | --ht=*) | |
909 | htmldir=$ac_optarg ;; | |
910 | ||
0bc0cd11 JL |
911 | -includedir | --includedir | --includedi | --included | --include \ |
912 | | --includ | --inclu | --incl | --inc) | |
913 | ac_prev=includedir ;; | |
914 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
915 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
238235ef | 916 | includedir=$ac_optarg ;; |
0bc0cd11 JL |
917 | |
918 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
919 | ac_prev=infodir ;; | |
920 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
238235ef | 921 | infodir=$ac_optarg ;; |
0bc0cd11 JL |
922 | |
923 | -libdir | --libdir | --libdi | --libd) | |
924 | ac_prev=libdir ;; | |
925 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
238235ef | 926 | libdir=$ac_optarg ;; |
0bc0cd11 JL |
927 | |
928 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
929 | | --libexe | --libex | --libe) | |
930 | ac_prev=libexecdir ;; | |
931 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
932 | | --libexe=* | --libex=* | --libe=*) | |
238235ef | 933 | libexecdir=$ac_optarg ;; |
0bc0cd11 | 934 | |
5213506e RW |
935 | -localedir | --localedir | --localedi | --localed | --locale) |
936 | ac_prev=localedir ;; | |
937 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
938 | localedir=$ac_optarg ;; | |
939 | ||
0bc0cd11 | 940 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
5213506e | 941 | | --localstate | --localstat | --localsta | --localst | --locals) |
0bc0cd11 JL |
942 | ac_prev=localstatedir ;; |
943 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
5213506e | 944 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
238235ef | 945 | localstatedir=$ac_optarg ;; |
0bc0cd11 JL |
946 | |
947 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
948 | ac_prev=mandir ;; | |
949 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
238235ef | 950 | mandir=$ac_optarg ;; |
0bc0cd11 JL |
951 | |
952 | -nfp | --nfp | --nf) | |
953 | # Obsolete; use --without-fp. | |
954 | with_fp=no ;; | |
955 | ||
956 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
238235ef | 957 | | --no-cr | --no-c | -n) |
0bc0cd11 JL |
958 | no_create=yes ;; |
959 | ||
960 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
961 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
962 | no_recursion=yes ;; | |
963 | ||
964 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
965 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
966 | | --oldin | --oldi | --old | --ol | --o) | |
967 | ac_prev=oldincludedir ;; | |
968 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
969 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
970 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
238235ef | 971 | oldincludedir=$ac_optarg ;; |
0bc0cd11 JL |
972 | |
973 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
974 | ac_prev=prefix ;; | |
975 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
238235ef | 976 | prefix=$ac_optarg ;; |
0bc0cd11 JL |
977 | |
978 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
979 | | --program-pre | --program-pr | --program-p) | |
980 | ac_prev=program_prefix ;; | |
981 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
982 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
238235ef | 983 | program_prefix=$ac_optarg ;; |
0bc0cd11 JL |
984 | |
985 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
986 | | --program-suf | --program-su | --program-s) | |
987 | ac_prev=program_suffix ;; | |
988 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
989 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
238235ef | 990 | program_suffix=$ac_optarg ;; |
0bc0cd11 JL |
991 | |
992 | -program-transform-name | --program-transform-name \ | |
993 | | --program-transform-nam | --program-transform-na \ | |
994 | | --program-transform-n | --program-transform- \ | |
995 | | --program-transform | --program-transfor \ | |
996 | | --program-transfo | --program-transf \ | |
997 | | --program-trans | --program-tran \ | |
998 | | --progr-tra | --program-tr | --program-t) | |
999 | ac_prev=program_transform_name ;; | |
1000 | -program-transform-name=* | --program-transform-name=* \ | |
1001 | | --program-transform-nam=* | --program-transform-na=* \ | |
1002 | | --program-transform-n=* | --program-transform-=* \ | |
1003 | | --program-transform=* | --program-transfor=* \ | |
1004 | | --program-transfo=* | --program-transf=* \ | |
1005 | | --program-trans=* | --program-tran=* \ | |
1006 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
238235ef | 1007 | program_transform_name=$ac_optarg ;; |
0bc0cd11 | 1008 | |
5213506e RW |
1009 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
1010 | ac_prev=pdfdir ;; | |
1011 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1012 | pdfdir=$ac_optarg ;; | |
1013 | ||
1014 | -psdir | --psdir | --psdi | --psd | --ps) | |
1015 | ac_prev=psdir ;; | |
1016 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1017 | psdir=$ac_optarg ;; | |
1018 | ||
0bc0cd11 JL |
1019 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
1020 | | -silent | --silent | --silen | --sile | --sil) | |
1021 | silent=yes ;; | |
1022 | ||
1023 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1024 | ac_prev=sbindir ;; | |
1025 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1026 | | --sbi=* | --sb=*) | |
238235ef | 1027 | sbindir=$ac_optarg ;; |
0bc0cd11 JL |
1028 | |
1029 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1030 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1031 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1032 | | --sha | --sh) | |
1033 | ac_prev=sharedstatedir ;; | |
1034 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1035 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1036 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1037 | | --sha=* | --sh=*) | |
238235ef | 1038 | sharedstatedir=$ac_optarg ;; |
0bc0cd11 JL |
1039 | |
1040 | -site | --site | --sit) | |
1041 | ac_prev=site ;; | |
1042 | -site=* | --site=* | --sit=*) | |
238235ef | 1043 | site=$ac_optarg ;; |
0bc0cd11 JL |
1044 | |
1045 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1046 | ac_prev=srcdir ;; | |
1047 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
238235ef | 1048 | srcdir=$ac_optarg ;; |
0bc0cd11 JL |
1049 | |
1050 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1051 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1052 | ac_prev=sysconfdir ;; | |
1053 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1054 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
238235ef | 1055 | sysconfdir=$ac_optarg ;; |
0bc0cd11 JL |
1056 | |
1057 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
238235ef | 1058 | ac_prev=target_alias ;; |
0bc0cd11 | 1059 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
238235ef | 1060 | target_alias=$ac_optarg ;; |
0bc0cd11 JL |
1061 | |
1062 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1063 | verbose=yes ;; | |
1064 | ||
238235ef DJ |
1065 | -version | --version | --versio | --versi | --vers | -V) |
1066 | ac_init_version=: ;; | |
0bc0cd11 JL |
1067 | |
1068 | -with-* | --with-*) | |
5213506e | 1069 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
0bc0cd11 | 1070 | # Reject names that are not valid shell variable names. |
5213506e | 1071 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
22e05272 | 1072 | as_fn_error $? "invalid package name: $ac_useropt" |
5213506e RW |
1073 | ac_useropt_orig=$ac_useropt |
1074 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1075 | case $ac_user_opts in | |
1076 | *" | |
1077 | "with_$ac_useropt" | |
1078 | "*) ;; | |
1079 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1080 | ac_unrecognized_sep=', ';; | |
0bc0cd11 | 1081 | esac |
5213506e | 1082 | eval with_$ac_useropt=\$ac_optarg ;; |
0bc0cd11 JL |
1083 | |
1084 | -without-* | --without-*) | |
5213506e | 1085 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
0bc0cd11 | 1086 | # Reject names that are not valid shell variable names. |
5213506e | 1087 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
22e05272 | 1088 | as_fn_error $? "invalid package name: $ac_useropt" |
5213506e RW |
1089 | ac_useropt_orig=$ac_useropt |
1090 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1091 | case $ac_user_opts in | |
1092 | *" | |
1093 | "with_$ac_useropt" | |
1094 | "*) ;; | |
1095 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1096 | ac_unrecognized_sep=', ';; | |
1097 | esac | |
1098 | eval with_$ac_useropt=no ;; | |
0bc0cd11 JL |
1099 | |
1100 | --x) | |
1101 | # Obsolete; use --with-x. | |
1102 | with_x=yes ;; | |
1103 | ||
1104 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1105 | | --x-incl | --x-inc | --x-in | --x-i) | |
1106 | ac_prev=x_includes ;; | |
1107 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1108 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
238235ef | 1109 | x_includes=$ac_optarg ;; |
0bc0cd11 JL |
1110 | |
1111 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1112 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1113 | ac_prev=x_libraries ;; | |
1114 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1115 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
238235ef | 1116 | x_libraries=$ac_optarg ;; |
0bc0cd11 | 1117 | |
22e05272 JM |
1118 | -*) as_fn_error $? "unrecognized option: \`$ac_option' |
1119 | Try \`$0 --help' for more information" | |
0bc0cd11 JL |
1120 | ;; |
1121 | ||
238235ef DJ |
1122 | *=*) |
1123 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1124 | # Reject names that are not valid shell variable names. | |
5213506e RW |
1125 | case $ac_envvar in #( |
1126 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
22e05272 | 1127 | as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; |
5213506e RW |
1128 | esac |
1129 | eval $ac_envvar=\$ac_optarg | |
238235ef DJ |
1130 | export $ac_envvar ;; |
1131 | ||
0bc0cd11 | 1132 | *) |
238235ef | 1133 | # FIXME: should be removed in autoconf 3.0. |
5213506e | 1134 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
238235ef | 1135 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
5213506e | 1136 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
22e05272 | 1137 | : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" |
0bc0cd11 JL |
1138 | ;; |
1139 | ||
1140 | esac | |
1141 | done | |
1142 | ||
1143 | if test -n "$ac_prev"; then | |
238235ef | 1144 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
22e05272 | 1145 | as_fn_error $? "missing argument to $ac_option" |
0bc0cd11 | 1146 | fi |
0bc0cd11 | 1147 | |
5213506e RW |
1148 | if test -n "$ac_unrecognized_opts"; then |
1149 | case $enable_option_checking in | |
1150 | no) ;; | |
22e05272 | 1151 | fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; |
5213506e | 1152 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; |
238235ef | 1153 | esac |
5213506e | 1154 | fi |
0bc0cd11 | 1155 | |
5213506e RW |
1156 | # Check all directory arguments for consistency. |
1157 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ | |
1158 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1159 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
fbb334a6 | 1160 | libdir localedir mandir |
0bc0cd11 | 1161 | do |
5213506e RW |
1162 | eval ac_val=\$$ac_var |
1163 | # Remove trailing slashes. | |
238235ef | 1164 | case $ac_val in |
5213506e RW |
1165 | */ ) |
1166 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1167 | eval $ac_var=\$ac_val;; | |
0bc0cd11 | 1168 | esac |
5213506e RW |
1169 | # Be sure to have absolute directory names. |
1170 | case $ac_val in | |
1171 | [\\/$]* | ?:[\\/]* ) continue;; | |
1172 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
1173 | esac | |
22e05272 | 1174 | as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" |
0bc0cd11 JL |
1175 | done |
1176 | ||
238235ef DJ |
1177 | # There might be people who depend on the old broken behavior: `$host' |
1178 | # used to hold the argument of --host etc. | |
1179 | # FIXME: To remove some day. | |
1180 | build=$build_alias | |
1181 | host=$host_alias | |
1182 | target=$target_alias | |
1183 | ||
1184 | # FIXME: To remove some day. | |
1185 | if test "x$host_alias" != x; then | |
1186 | if test "x$build_alias" = x; then | |
1187 | cross_compiling=maybe | |
238235ef DJ |
1188 | elif test "x$build_alias" != "x$host_alias"; then |
1189 | cross_compiling=yes | |
1190 | fi | |
1191 | fi | |
0bc0cd11 | 1192 | |
238235ef DJ |
1193 | ac_tool_prefix= |
1194 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
1195 | ||
1196 | test "$silent" = yes && exec 6>/dev/null | |
0bc0cd11 | 1197 | |
0bc0cd11 | 1198 | |
5213506e RW |
1199 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
1200 | ac_ls_di=`ls -di .` && | |
1201 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
22e05272 | 1202 | as_fn_error $? "working directory cannot be determined" |
5213506e | 1203 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || |
22e05272 | 1204 | as_fn_error $? "pwd does not report name of working directory" |
5213506e RW |
1205 | |
1206 | ||
0bc0cd11 JL |
1207 | # Find the source files, if location was not specified. |
1208 | if test -z "$srcdir"; then | |
1209 | ac_srcdir_defaulted=yes | |
5213506e RW |
1210 | # Try the directory containing this script, then the parent directory. |
1211 | ac_confdir=`$as_dirname -- "$as_myself" || | |
1212 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1213 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1214 | X"$as_myself" : 'X\(//\)$' \| \ | |
1215 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1216 | $as_echo X"$as_myself" | | |
1217 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
1218 | s//\1/ | |
1219 | q | |
1220 | } | |
1221 | /^X\(\/\/\)[^/].*/{ | |
1222 | s//\1/ | |
1223 | q | |
1224 | } | |
1225 | /^X\(\/\/\)$/{ | |
1226 | s//\1/ | |
1227 | q | |
1228 | } | |
1229 | /^X\(\/\).*/{ | |
1230 | s//\1/ | |
1231 | q | |
1232 | } | |
1233 | s/.*/./; q'` | |
0bc0cd11 | 1234 | srcdir=$ac_confdir |
5213506e | 1235 | if test ! -r "$srcdir/$ac_unique_file"; then |
0bc0cd11 JL |
1236 | srcdir=.. |
1237 | fi | |
1238 | else | |
1239 | ac_srcdir_defaulted=no | |
1240 | fi | |
5213506e RW |
1241 | if test ! -r "$srcdir/$ac_unique_file"; then |
1242 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
22e05272 | 1243 | as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" |
5213506e RW |
1244 | fi |
1245 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" | |
1246 | ac_abs_confdir=`( | |
22e05272 | 1247 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" |
5213506e RW |
1248 | pwd)` |
1249 | # When building in place, set srcdir=. | |
1250 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1251 | srcdir=. | |
1252 | fi | |
1253 | # Remove unnecessary trailing slashes from srcdir. | |
1254 | # Double slashes in file names in object file debugging info | |
1255 | # mess up M-x gdb in Emacs. | |
1256 | case $srcdir in | |
1257 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1258 | esac | |
1259 | for ac_var in $ac_precious_vars; do | |
1260 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1261 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1262 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1263 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1264 | done | |
238235ef DJ |
1265 | |
1266 | # | |
1267 | # Report the --help message. | |
1268 | # | |
1269 | if test "$ac_init_help" = "long"; then | |
1270 | # Omit some internal or obsolete options to make the list less imposing. | |
1271 | # This message is too long to be a string in the A/UX 3.1 sh. | |
1272 | cat <<_ACEOF | |
1273 | \`configure' configures this package to adapt to many kinds of systems. | |
1274 | ||
1275 | Usage: $0 [OPTION]... [VAR=VALUE]... | |
1276 | ||
1277 | To assign environment variables (e.g., CC, CFLAGS...), specify them as | |
1278 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
1279 | ||
1280 | Defaults for the options are specified in brackets. | |
1281 | ||
1282 | Configuration: | |
1283 | -h, --help display this help and exit | |
1284 | --help=short display options specific to this package | |
1285 | --help=recursive display the short help of all the included packages | |
1286 | -V, --version display version information and exit | |
22e05272 | 1287 | -q, --quiet, --silent do not print \`checking ...' messages |
238235ef DJ |
1288 | --cache-file=FILE cache test results in FILE [disabled] |
1289 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1290 | -n, --no-create do not create output files | |
1291 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
1292 | ||
238235ef DJ |
1293 | Installation directories: |
1294 | --prefix=PREFIX install architecture-independent files in PREFIX | |
5213506e | 1295 | [$ac_default_prefix] |
238235ef | 1296 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
5213506e | 1297 | [PREFIX] |
238235ef DJ |
1298 | |
1299 | By default, \`make install' will install all the files in | |
1300 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1301 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1302 | for instance \`--prefix=\$HOME'. | |
1303 | ||
1304 | For better control, use the options below. | |
1305 | ||
1306 | Fine tuning of the installation directories: | |
5213506e RW |
1307 | --bindir=DIR user executables [EPREFIX/bin] |
1308 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1309 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1310 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1311 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1312 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1313 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1314 | --includedir=DIR C header files [PREFIX/include] | |
1315 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1316 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1317 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1318 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1319 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1320 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1321 | --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] | |
1322 | --htmldir=DIR html documentation [DOCDIR] | |
1323 | --dvidir=DIR dvi documentation [DOCDIR] | |
1324 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1325 | --psdir=DIR ps documentation [DOCDIR] | |
238235ef DJ |
1326 | _ACEOF |
1327 | ||
1328 | cat <<\_ACEOF | |
1329 | ||
1330 | System types: | |
1331 | --build=BUILD configure for building on BUILD [guessed] | |
1332 | --host=HOST cross-compile to build programs to run on HOST [BUILD] | |
f2c52c0d | 1333 | --target=TARGET configure for building compilers for TARGET [HOST] |
238235ef DJ |
1334 | _ACEOF |
1335 | fi | |
1336 | ||
1337 | if test -n "$ac_init_help"; then | |
1338 | ||
1339 | cat <<\_ACEOF | |
1340 | ||
1341 | Optional Features: | |
5213506e | 1342 | --disable-option-checking ignore unrecognized --enable/--with options |
238235ef DJ |
1343 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
1344 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
1345 | --enable-maintainer-mode | |
1346 | enable make rules and dependencies not useful | |
1347 | (and sometimes confusing) to the casual installer | |
abea993f | 1348 | --enable-multilib build many library versions (default) |
8c9fddf4 | 1349 | --enable-install-libiberty Install headers and library for end users |
d208e2d2 | 1350 | --disable-largefile omit support for large files |
8fc8bf80 | 1351 | --enable-cet enable Intel CET in host libraries [default=auto] |
238235ef DJ |
1352 | |
1353 | Optional Packages: | |
1354 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
1355 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
1356 | --with-target-subdir=SUBDIR Configuring in a subdirectory for target | |
1357 | --with-build-subdir=SUBDIR Configuring in a subdirectory for build | |
1358 | --with-cross-host=HOST Configuring with a cross compiler | |
1359 | --with-newlib Configuring with newlib | |
1360 | ||
1361 | Some influential environment variables: | |
1362 | CC C compiler command | |
1363 | CFLAGS C compiler flags | |
1364 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1365 | nonstandard directory <lib dir> | |
5213506e | 1366 | LIBS libraries to pass to the linker, e.g. -l<library> |
22e05272 | 1367 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if |
5213506e | 1368 | you have headers in a nonstandard directory <include dir> |
238235ef DJ |
1369 | CPP C preprocessor |
1370 | ||
1371 | Use these variables to override the choices made by `configure' or to help | |
1372 | it to find libraries and programs with nonstandard names/locations. | |
1373 | ||
5213506e | 1374 | Report bugs to the package provider. |
238235ef | 1375 | _ACEOF |
5213506e | 1376 | ac_status=$? |
238235ef DJ |
1377 | fi |
1378 | ||
1379 | if test "$ac_init_help" = "recursive"; then | |
1380 | # If there are subdirs, report their specific --help. | |
238235ef | 1381 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
5213506e RW |
1382 | test -d "$ac_dir" || |
1383 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1384 | continue | |
238235ef DJ |
1385 | ac_builddir=. |
1386 | ||
5213506e RW |
1387 | case "$ac_dir" in |
1388 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1389 | *) | |
1390 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
1391 | # A ".." for each directory in $ac_dir_suffix. | |
1392 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
1393 | case $ac_top_builddir_sub in | |
1394 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1395 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1396 | esac ;; | |
1397 | esac | |
1398 | ac_abs_top_builddir=$ac_pwd | |
1399 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1400 | # for backward compatibility: | |
1401 | ac_top_builddir=$ac_top_build_prefix | |
238235ef DJ |
1402 | |
1403 | case $srcdir in | |
5213506e | 1404 | .) # We are building in place. |
238235ef | 1405 | ac_srcdir=. |
5213506e RW |
1406 | ac_top_srcdir=$ac_top_builddir_sub |
1407 | ac_abs_top_srcdir=$ac_pwd ;; | |
1408 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
238235ef | 1409 | ac_srcdir=$srcdir$ac_dir_suffix; |
5213506e RW |
1410 | ac_top_srcdir=$srcdir |
1411 | ac_abs_top_srcdir=$srcdir ;; | |
1412 | *) # Relative name. | |
1413 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1414 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1415 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
3beb1315 | 1416 | esac |
5213506e RW |
1417 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
1418 | ||
1419 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1420 | # Check for guested configure. | |
1421 | if test -f "$ac_srcdir/configure.gnu"; then | |
1422 | echo && | |
1423 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1424 | elif test -f "$ac_srcdir/configure"; then | |
1425 | echo && | |
1426 | $SHELL "$ac_srcdir/configure" --help=recursive | |
238235ef | 1427 | else |
5213506e RW |
1428 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
1429 | fi || ac_status=$? | |
1430 | cd "$ac_pwd" || { ac_status=$?; break; } | |
238235ef DJ |
1431 | done |
1432 | fi | |
1433 | ||
5213506e | 1434 | test -n "$ac_init_help" && exit $ac_status |
238235ef DJ |
1435 | if $ac_init_version; then |
1436 | cat <<\_ACEOF | |
5213506e | 1437 | configure |
22e05272 | 1438 | generated by GNU Autoconf 2.69 |
238235ef | 1439 | |
22e05272 | 1440 | Copyright (C) 2012 Free Software Foundation, Inc. |
238235ef DJ |
1441 | This configure script is free software; the Free Software Foundation |
1442 | gives unlimited permission to copy, distribute and modify it. | |
1443 | _ACEOF | |
5213506e | 1444 | exit |
238235ef | 1445 | fi |
238235ef | 1446 | |
5213506e RW |
1447 | ## ------------------------ ## |
1448 | ## Autoconf initialization. ## | |
1449 | ## ------------------------ ## | |
238235ef | 1450 | |
5213506e RW |
1451 | # ac_fn_c_try_compile LINENO |
1452 | # -------------------------- | |
1453 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1454 | ac_fn_c_try_compile () | |
238235ef | 1455 | { |
5213506e RW |
1456 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
1457 | rm -f conftest.$ac_objext | |
1458 | if { { ac_try="$ac_compile" | |
1459 | case "(($ac_try" in | |
1460 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1461 | *) ac_try_echo=$ac_try;; | |
1462 | esac | |
1463 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1464 | $as_echo "$ac_try_echo"; } >&5 | |
1465 | (eval "$ac_compile") 2>conftest.err | |
1466 | ac_status=$? | |
1467 | if test -s conftest.err; then | |
1468 | grep -v '^ *+' conftest.err >conftest.er1 | |
1469 | cat conftest.er1 >&5 | |
1470 | mv -f conftest.er1 conftest.err | |
1471 | fi | |
1472 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1473 | test $ac_status = 0; } && { | |
1474 | test -z "$ac_c_werror_flag" || | |
1475 | test ! -s conftest.err | |
1476 | } && test -s conftest.$ac_objext; then : | |
1477 | ac_retval=0 | |
1478 | else | |
1479 | $as_echo "$as_me: failed program was:" >&5 | |
1480 | sed 's/^/| /' conftest.$ac_ext >&5 | |
238235ef | 1481 | |
5213506e RW |
1482 | ac_retval=1 |
1483 | fi | |
22e05272 JM |
1484 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
1485 | as_fn_set_status $ac_retval | |
238235ef | 1486 | |
5213506e | 1487 | } # ac_fn_c_try_compile |
238235ef | 1488 | |
5213506e RW |
1489 | # ac_fn_c_try_cpp LINENO |
1490 | # ---------------------- | |
1491 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
1492 | ac_fn_c_try_cpp () | |
1493 | { | |
1494 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1495 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
1496 | case "(($ac_try" in | |
1497 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1498 | *) ac_try_echo=$ac_try;; | |
1499 | esac | |
1500 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1501 | $as_echo "$ac_try_echo"; } >&5 | |
1502 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
1503 | ac_status=$? | |
1504 | if test -s conftest.err; then | |
1505 | grep -v '^ *+' conftest.err >conftest.er1 | |
1506 | cat conftest.er1 >&5 | |
1507 | mv -f conftest.er1 conftest.err | |
1508 | fi | |
1509 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
22e05272 | 1510 | test $ac_status = 0; } > conftest.i && { |
5213506e RW |
1511 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || |
1512 | test ! -s conftest.err | |
1513 | }; then : | |
1514 | ac_retval=0 | |
1515 | else | |
1516 | $as_echo "$as_me: failed program was:" >&5 | |
1517 | sed 's/^/| /' conftest.$ac_ext >&5 | |
238235ef | 1518 | |
5213506e RW |
1519 | ac_retval=1 |
1520 | fi | |
22e05272 JM |
1521 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
1522 | as_fn_set_status $ac_retval | |
238235ef | 1523 | |
5213506e | 1524 | } # ac_fn_c_try_cpp |
238235ef | 1525 | |
f50f17e6 YJ |
1526 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
1527 | # ------------------------------------------------------- | |
1528 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
1529 | # the include files in INCLUDES and setting the cache variable VAR | |
1530 | # accordingly. | |
1531 | ac_fn_c_check_header_mongrel () | |
1532 | { | |
1533 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
22e05272 | 1534 | if eval \${$3+:} false; then : |
f50f17e6 YJ |
1535 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 |
1536 | $as_echo_n "checking for $2... " >&6; } | |
22e05272 | 1537 | if eval \${$3+:} false; then : |
f50f17e6 YJ |
1538 | $as_echo_n "(cached) " >&6 |
1539 | fi | |
1540 | eval ac_res=\$$3 | |
1541 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1542 | $as_echo "$ac_res" >&6; } | |
1543 | else | |
1544 | # Is the header compilable? | |
1545 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
1546 | $as_echo_n "checking $2 usability... " >&6; } | |
1547 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1548 | /* end confdefs.h. */ | |
1549 | $4 | |
1550 | #include <$2> | |
1551 | _ACEOF | |
1552 | if ac_fn_c_try_compile "$LINENO"; then : | |
1553 | ac_header_compiler=yes | |
1554 | else | |
1555 | ac_header_compiler=no | |
1556 | fi | |
1557 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1558 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
1559 | $as_echo "$ac_header_compiler" >&6; } | |
1560 | ||
1561 | # Is the header present? | |
1562 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
1563 | $as_echo_n "checking $2 presence... " >&6; } | |
1564 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1565 | /* end confdefs.h. */ | |
1566 | #include <$2> | |
1567 | _ACEOF | |
1568 | if ac_fn_c_try_cpp "$LINENO"; then : | |
1569 | ac_header_preproc=yes | |
1570 | else | |
1571 | ac_header_preproc=no | |
1572 | fi | |
22e05272 | 1573 | rm -f conftest.err conftest.i conftest.$ac_ext |
f50f17e6 YJ |
1574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 |
1575 | $as_echo "$ac_header_preproc" >&6; } | |
1576 | ||
1577 | # So? What about this header? | |
1578 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
1579 | yes:no: ) | |
1580 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
1581 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
1582 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1583 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1584 | ;; | |
1585 | no:yes:* ) | |
1586 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
1587 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
1588 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
1589 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
1590 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
1591 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
1592 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
1593 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
1594 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1595 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1596 | ;; | |
1597 | esac | |
1598 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1599 | $as_echo_n "checking for $2... " >&6; } | |
22e05272 | 1600 | if eval \${$3+:} false; then : |
f50f17e6 YJ |
1601 | $as_echo_n "(cached) " >&6 |
1602 | else | |
1603 | eval "$3=\$ac_header_compiler" | |
1604 | fi | |
1605 | eval ac_res=\$$3 | |
1606 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1607 | $as_echo "$ac_res" >&6; } | |
1608 | fi | |
22e05272 | 1609 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
f50f17e6 YJ |
1610 | |
1611 | } # ac_fn_c_check_header_mongrel | |
1612 | ||
5213506e RW |
1613 | # ac_fn_c_try_run LINENO |
1614 | # ---------------------- | |
1615 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
1616 | # that executables *can* be run. | |
1617 | ac_fn_c_try_run () | |
1618 | { | |
1619 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1620 | if { { ac_try="$ac_link" | |
1621 | case "(($ac_try" in | |
1622 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1623 | *) ac_try_echo=$ac_try;; | |
1624 | esac | |
1625 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1626 | $as_echo "$ac_try_echo"; } >&5 | |
1627 | (eval "$ac_link") 2>&5 | |
1628 | ac_status=$? | |
1629 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1630 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
1631 | { { case "(($ac_try" in | |
1632 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1633 | *) ac_try_echo=$ac_try;; | |
1634 | esac | |
1635 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1636 | $as_echo "$ac_try_echo"; } >&5 | |
1637 | (eval "$ac_try") 2>&5 | |
1638 | ac_status=$? | |
1639 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1640 | test $ac_status = 0; }; }; then : | |
1641 | ac_retval=0 | |
1642 | else | |
1643 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
1644 | $as_echo "$as_me: failed program was:" >&5 | |
1645 | sed 's/^/| /' conftest.$ac_ext >&5 | |
238235ef | 1646 | |
5213506e RW |
1647 | ac_retval=$ac_status |
1648 | fi | |
1649 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
22e05272 JM |
1650 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
1651 | as_fn_set_status $ac_retval | |
238235ef | 1652 | |
5213506e | 1653 | } # ac_fn_c_try_run |
0bc0cd11 | 1654 | |
f50f17e6 YJ |
1655 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
1656 | # ------------------------------------------------------- | |
1657 | # Tests whether HEADER exists and can be compiled using the include files in | |
1658 | # INCLUDES, setting the cache variable VAR accordingly. | |
1659 | ac_fn_c_check_header_compile () | |
1660 | { | |
1661 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1662 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1663 | $as_echo_n "checking for $2... " >&6; } | |
22e05272 | 1664 | if eval \${$3+:} false; then : |
f50f17e6 YJ |
1665 | $as_echo_n "(cached) " >&6 |
1666 | else | |
1667 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1668 | /* end confdefs.h. */ | |
1669 | $4 | |
1670 | #include <$2> | |
1671 | _ACEOF | |
1672 | if ac_fn_c_try_compile "$LINENO"; then : | |
1673 | eval "$3=yes" | |
1674 | else | |
1675 | eval "$3=no" | |
1676 | fi | |
1677 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1678 | fi | |
1679 | eval ac_res=\$$3 | |
1680 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1681 | $as_echo "$ac_res" >&6; } | |
22e05272 | 1682 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
f50f17e6 YJ |
1683 | |
1684 | } # ac_fn_c_check_header_compile | |
1685 | ||
eedc73a2 L |
1686 | # ac_fn_c_try_link LINENO |
1687 | # ----------------------- | |
1688 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
1689 | ac_fn_c_try_link () | |
1690 | { | |
1691 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1692 | rm -f conftest.$ac_objext conftest$ac_exeext | |
1693 | if { { ac_try="$ac_link" | |
1694 | case "(($ac_try" in | |
1695 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1696 | *) ac_try_echo=$ac_try;; | |
1697 | esac | |
1698 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1699 | $as_echo "$ac_try_echo"; } >&5 | |
1700 | (eval "$ac_link") 2>conftest.err | |
1701 | ac_status=$? | |
1702 | if test -s conftest.err; then | |
1703 | grep -v '^ *+' conftest.err >conftest.er1 | |
1704 | cat conftest.er1 >&5 | |
1705 | mv -f conftest.er1 conftest.err | |
1706 | fi | |
1707 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1708 | test $ac_status = 0; } && { | |
1709 | test -z "$ac_c_werror_flag" || | |
1710 | test ! -s conftest.err | |
1711 | } && test -s conftest$ac_exeext && { | |
1712 | test "$cross_compiling" = yes || | |
1713 | test -x conftest$ac_exeext | |
1714 | }; then : | |
1715 | ac_retval=0 | |
1716 | else | |
1717 | $as_echo "$as_me: failed program was:" >&5 | |
1718 | sed 's/^/| /' conftest.$ac_ext >&5 | |
1719 | ||
1720 | ac_retval=1 | |
1721 | fi | |
1722 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information | |
1723 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
1724 | # interfere with the next link command; also delete a directory that is | |
1725 | # left behind by Apple's compiler. We do this before executing the actions. | |
1726 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1727 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno | |
1728 | as_fn_set_status $ac_retval | |
1729 | ||
1730 | } # ac_fn_c_try_link | |
1731 | ||
5213506e RW |
1732 | # ac_fn_c_check_header_preproc LINENO HEADER VAR |
1733 | # ---------------------------------------------- | |
1734 | # Tests whether HEADER is present, setting the cache variable VAR accordingly. | |
1735 | ac_fn_c_check_header_preproc () | |
1736 | { | |
1737 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1738 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1739 | $as_echo_n "checking for $2... " >&6; } | |
22e05272 | 1740 | if eval \${$3+:} false; then : |
5213506e RW |
1741 | $as_echo_n "(cached) " >&6 |
1742 | else | |
1743 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1744 | /* end confdefs.h. */ | |
1745 | #include <$2> | |
238235ef | 1746 | _ACEOF |
5213506e RW |
1747 | if ac_fn_c_try_cpp "$LINENO"; then : |
1748 | eval "$3=yes" | |
1749 | else | |
1750 | eval "$3=no" | |
1751 | fi | |
22e05272 | 1752 | rm -f conftest.err conftest.i conftest.$ac_ext |
5213506e RW |
1753 | fi |
1754 | eval ac_res=\$$3 | |
1755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1756 | $as_echo "$ac_res" >&6; } | |
22e05272 | 1757 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
238235ef | 1758 | |
5213506e | 1759 | } # ac_fn_c_check_header_preproc |
238235ef | 1760 | |
5213506e RW |
1761 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
1762 | # -------------------------------------------- | |
1763 | # Tries to find the compile-time value of EXPR in a program that includes | |
1764 | # INCLUDES, setting VAR accordingly. Returns whether the value could be | |
1765 | # computed | |
1766 | ac_fn_c_compute_int () | |
1767 | { | |
1768 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1769 | if test "$cross_compiling" = yes; then | |
1770 | # Depending upon the size, compute the lo and hi bounds. | |
1771 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1772 | /* end confdefs.h. */ | |
1773 | $4 | |
1774 | int | |
1775 | main () | |
1776 | { | |
1777 | static int test_array [1 - 2 * !(($2) >= 0)]; | |
22e05272 JM |
1778 | test_array [0] = 0; |
1779 | return test_array [0]; | |
238235ef | 1780 | |
5213506e RW |
1781 | ; |
1782 | return 0; | |
1783 | } | |
1784 | _ACEOF | |
1785 | if ac_fn_c_try_compile "$LINENO"; then : | |
1786 | ac_lo=0 ac_mid=0 | |
1787 | while :; do | |
1788 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1789 | /* end confdefs.h. */ | |
1790 | $4 | |
1791 | int | |
1792 | main () | |
238235ef | 1793 | { |
5213506e | 1794 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; |
22e05272 JM |
1795 | test_array [0] = 0; |
1796 | return test_array [0]; | |
5213506e RW |
1797 | |
1798 | ; | |
1799 | return 0; | |
238235ef | 1800 | } |
5213506e RW |
1801 | _ACEOF |
1802 | if ac_fn_c_try_compile "$LINENO"; then : | |
1803 | ac_hi=$ac_mid; break | |
1804 | else | |
1805 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val | |
1806 | if test $ac_lo -le $ac_mid; then | |
1807 | ac_lo= ac_hi= | |
1808 | break | |
1809 | fi | |
1810 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val | |
1811 | fi | |
1812 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1813 | done | |
1814 | else | |
1815 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1816 | /* end confdefs.h. */ | |
1817 | $4 | |
1818 | int | |
1819 | main () | |
1820 | { | |
1821 | static int test_array [1 - 2 * !(($2) < 0)]; | |
22e05272 JM |
1822 | test_array [0] = 0; |
1823 | return test_array [0]; | |
238235ef | 1824 | |
5213506e RW |
1825 | ; |
1826 | return 0; | |
1827 | } | |
1828 | _ACEOF | |
1829 | if ac_fn_c_try_compile "$LINENO"; then : | |
1830 | ac_hi=-1 ac_mid=-1 | |
1831 | while :; do | |
1832 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1833 | /* end confdefs.h. */ | |
1834 | $4 | |
1835 | int | |
1836 | main () | |
1837 | { | |
1838 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; | |
22e05272 JM |
1839 | test_array [0] = 0; |
1840 | return test_array [0]; | |
238235ef | 1841 | |
5213506e RW |
1842 | ; |
1843 | return 0; | |
1844 | } | |
1845 | _ACEOF | |
1846 | if ac_fn_c_try_compile "$LINENO"; then : | |
1847 | ac_lo=$ac_mid; break | |
1848 | else | |
1849 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val | |
1850 | if test $ac_mid -le $ac_hi; then | |
1851 | ac_lo= ac_hi= | |
1852 | break | |
1853 | fi | |
1854 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val | |
1855 | fi | |
1856 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1857 | done | |
1858 | else | |
1859 | ac_lo= ac_hi= | |
1860 | fi | |
1861 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1862 | fi | |
1863 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1864 | # Binary search between lo and hi bounds. | |
1865 | while test "x$ac_lo" != "x$ac_hi"; do | |
1866 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val | |
1867 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1868 | /* end confdefs.h. */ | |
1869 | $4 | |
1870 | int | |
1871 | main () | |
1872 | { | |
1873 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
22e05272 JM |
1874 | test_array [0] = 0; |
1875 | return test_array [0]; | |
238235ef | 1876 | |
5213506e RW |
1877 | ; |
1878 | return 0; | |
1879 | } | |
1880 | _ACEOF | |
1881 | if ac_fn_c_try_compile "$LINENO"; then : | |
1882 | ac_hi=$ac_mid | |
1883 | else | |
1884 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val | |
1885 | fi | |
1886 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
238235ef | 1887 | done |
5213506e RW |
1888 | case $ac_lo in #(( |
1889 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; | |
1890 | '') ac_retval=1 ;; | |
1891 | esac | |
1892 | else | |
1893 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1894 | /* end confdefs.h. */ | |
1895 | $4 | |
1896 | static long int longval () { return $2; } | |
1897 | static unsigned long int ulongval () { return $2; } | |
1898 | #include <stdio.h> | |
1899 | #include <stdlib.h> | |
1900 | int | |
1901 | main () | |
1902 | { | |
238235ef | 1903 | |
5213506e RW |
1904 | FILE *f = fopen ("conftest.val", "w"); |
1905 | if (! f) | |
1906 | return 1; | |
1907 | if (($2) < 0) | |
1908 | { | |
1909 | long int i = longval (); | |
1910 | if (i != ($2)) | |
1911 | return 1; | |
1912 | fprintf (f, "%ld", i); | |
1913 | } | |
1914 | else | |
1915 | { | |
1916 | unsigned long int i = ulongval (); | |
1917 | if (i != ($2)) | |
1918 | return 1; | |
1919 | fprintf (f, "%lu", i); | |
1920 | } | |
1921 | /* Do not output a trailing newline, as this causes \r\n confusion | |
1922 | on some platforms. */ | |
1923 | return ferror (f) || fclose (f) != 0; | |
238235ef | 1924 | |
5213506e RW |
1925 | ; |
1926 | return 0; | |
1927 | } | |
238235ef | 1928 | _ACEOF |
5213506e RW |
1929 | if ac_fn_c_try_run "$LINENO"; then : |
1930 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 | |
1931 | else | |
1932 | ac_retval=1 | |
1933 | fi | |
1934 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
1935 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
1936 | rm -f conftest.val | |
238235ef | 1937 | |
5213506e | 1938 | fi |
22e05272 JM |
1939 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
1940 | as_fn_set_status $ac_retval | |
238235ef | 1941 | |
5213506e | 1942 | } # ac_fn_c_compute_int |
238235ef | 1943 | |
5213506e RW |
1944 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
1945 | # ------------------------------------------- | |
1946 | # Tests whether TYPE exists after having included INCLUDES, setting cache | |
1947 | # variable VAR accordingly. | |
1948 | ac_fn_c_check_type () | |
1949 | { | |
1950 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1951 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1952 | $as_echo_n "checking for $2... " >&6; } | |
22e05272 | 1953 | if eval \${$3+:} false; then : |
5213506e RW |
1954 | $as_echo_n "(cached) " >&6 |
1955 | else | |
1956 | eval "$3=no" | |
1957 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1958 | /* end confdefs.h. */ | |
1959 | $4 | |
1960 | int | |
1961 | main () | |
1962 | { | |
1963 | if (sizeof ($2)) | |
1964 | return 0; | |
1965 | ; | |
1966 | return 0; | |
1967 | } | |
238235ef | 1968 | _ACEOF |
5213506e RW |
1969 | if ac_fn_c_try_compile "$LINENO"; then : |
1970 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1971 | /* end confdefs.h. */ | |
1972 | $4 | |
1973 | int | |
1974 | main () | |
1975 | { | |
1976 | if (sizeof (($2))) | |
1977 | return 0; | |
1978 | ; | |
1979 | return 0; | |
1980 | } | |
238235ef | 1981 | _ACEOF |
5213506e | 1982 | if ac_fn_c_try_compile "$LINENO"; then : |
238235ef | 1983 | |
5213506e RW |
1984 | else |
1985 | eval "$3=yes" | |
1986 | fi | |
1987 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1988 | fi | |
1989 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1990 | fi | |
1991 | eval ac_res=\$$3 | |
1992 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1993 | $as_echo "$ac_res" >&6; } | |
22e05272 | 1994 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
238235ef | 1995 | |
5213506e | 1996 | } # ac_fn_c_check_type |
238235ef | 1997 | |
5213506e RW |
1998 | # ac_fn_c_check_func LINENO FUNC VAR |
1999 | # ---------------------------------- | |
2000 | # Tests whether FUNC exists, setting the cache variable VAR accordingly | |
2001 | ac_fn_c_check_func () | |
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; } | |
22e05272 | 2006 | if eval \${$3+:} false; then : |
5213506e | 2007 | $as_echo_n "(cached) " >&6 |
0bc0cd11 | 2008 | else |
5213506e | 2009 | if test x$gcc_no_link = xyes; then |
22e05272 | 2010 | as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5 |
238235ef | 2011 | fi |
5213506e RW |
2012 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2013 | /* end confdefs.h. */ | |
0e0f02ff RW |
2014 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. |
2015 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ | |
2016 | #define $2 innocuous_$2 | |
2017 | ||
5213506e RW |
2018 | /* System header to define __stub macros and hopefully few prototypes, |
2019 | which can conflict with char $2 (); below. | |
2020 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
0e0f02ff RW |
2021 | <limits.h> exists even on freestanding compilers. */ |
2022 | ||
2023 | #ifdef __STDC__ | |
5213506e RW |
2024 | # include <limits.h> |
2025 | #else | |
2026 | # include <assert.h> | |
2027 | #endif | |
0e0f02ff RW |
2028 | |
2029 | #undef $2 | |
2030 | ||
2031 | /* Override any GCC internal prototype to avoid an error. | |
2032 | Use char because int might match the return type of a GCC | |
2033 | builtin and then its argument prototype would still apply. */ | |
5213506e RW |
2034 | #ifdef __cplusplus |
2035 | extern "C" | |
5213506e | 2036 | #endif |
5213506e RW |
2037 | char $2 (); |
2038 | /* The GNU C library defines this for functions which it implements | |
2039 | to always fail with ENOSYS. Some functions are actually named | |
2040 | something starting with __ and the normal name is an alias. */ | |
0e0f02ff | 2041 | #if defined __stub_$2 || defined __stub___$2 |
5213506e | 2042 | choke me |
5213506e | 2043 | #endif |
238235ef | 2044 | |
5213506e RW |
2045 | int |
2046 | main () | |
2047 | { | |
0e0f02ff | 2048 | return $2 (); |
5213506e RW |
2049 | ; |
2050 | return 0; | |
2051 | } | |
2052 | _ACEOF | |
2053 | if ac_fn_c_try_link "$LINENO"; then : | |
2054 | eval "$3=yes" | |
2055 | else | |
2056 | eval "$3=no" | |
0bc0cd11 | 2057 | fi |
5213506e RW |
2058 | rm -f core conftest.err conftest.$ac_objext \ |
2059 | conftest$ac_exeext conftest.$ac_ext | |
2060 | fi | |
2061 | eval ac_res=\$$3 | |
2062 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2063 | $as_echo "$ac_res" >&6; } | |
22e05272 | 2064 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
0bc0cd11 | 2065 | |
5213506e | 2066 | } # ac_fn_c_check_func |
0bc0cd11 | 2067 | |
22e05272 JM |
2068 | # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES |
2069 | # --------------------------------------------- | |
2070 | # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR | |
2071 | # accordingly. | |
5213506e RW |
2072 | ac_fn_c_check_decl () |
2073 | { | |
2074 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
c3f247f4 RW |
2075 | as_decl_name=`echo $2|sed 's/ *(.*//'` |
2076 | as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'` | |
2077 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5 | |
2078 | $as_echo_n "checking whether $as_decl_name is declared... " >&6; } | |
22e05272 | 2079 | if eval \${$3+:} false; then : |
5213506e RW |
2080 | $as_echo_n "(cached) " >&6 |
2081 | else | |
2082 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2083 | /* end confdefs.h. */ | |
2084 | $4 | |
2085 | int | |
2086 | main () | |
2087 | { | |
c3f247f4 RW |
2088 | #ifndef $as_decl_name |
2089 | #ifdef __cplusplus | |
2090 | (void) $as_decl_use; | |
2091 | #else | |
2092 | (void) $as_decl_name; | |
2093 | #endif | |
5213506e | 2094 | #endif |
0bc0cd11 | 2095 | |
5213506e RW |
2096 | ; |
2097 | return 0; | |
2098 | } | |
2099 | _ACEOF | |
2100 | if ac_fn_c_try_compile "$LINENO"; then : | |
2101 | eval "$3=yes" | |
2102 | else | |
2103 | eval "$3=no" | |
2104 | fi | |
2105 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2106 | fi | |
2107 | eval ac_res=\$$3 | |
2108 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2109 | $as_echo "$ac_res" >&6; } | |
22e05272 | 2110 | eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno |
0bc0cd11 | 2111 | |
5213506e RW |
2112 | } # ac_fn_c_check_decl |
2113 | cat >config.log <<_ACEOF | |
2114 | This file contains any messages produced by compilers while | |
2115 | running configure, to aid debugging if configure makes a mistake. | |
6706f116 | 2116 | |
5213506e | 2117 | It was created by $as_me, which was |
22e05272 | 2118 | generated by GNU Autoconf 2.69. Invocation command line was |
0bc0cd11 | 2119 | |
5213506e | 2120 | $ $0 $@ |
238235ef | 2121 | |
5213506e RW |
2122 | _ACEOF |
2123 | exec 5>>config.log | |
2124 | { | |
2125 | cat <<_ASUNAME | |
2126 | ## --------- ## | |
2127 | ## Platform. ## | |
2128 | ## --------- ## | |
238235ef | 2129 | |
5213506e RW |
2130 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
2131 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
2132 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
2133 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
2134 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
238235ef | 2135 | |
5213506e RW |
2136 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
2137 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
238235ef | 2138 | |
5213506e RW |
2139 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
2140 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
2141 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
2142 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
2143 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
2144 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
2145 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
238235ef | 2146 | |
5213506e | 2147 | _ASUNAME |
238235ef | 2148 | |
5213506e RW |
2149 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2150 | for as_dir in $PATH | |
2151 | do | |
2152 | IFS=$as_save_IFS | |
2153 | test -z "$as_dir" && as_dir=. | |
2154 | $as_echo "PATH: $as_dir" | |
2155 | done | |
2156 | IFS=$as_save_IFS | |
238235ef | 2157 | |
5213506e | 2158 | } >&5 |
238235ef | 2159 | |
5213506e | 2160 | cat >&5 <<_ACEOF |
238235ef DJ |
2161 | |
2162 | ||
5213506e RW |
2163 | ## ----------- ## |
2164 | ## Core tests. ## | |
2165 | ## ----------- ## | |
238235ef | 2166 | |
5213506e | 2167 | _ACEOF |
238235ef | 2168 | |
18c04407 | 2169 | |
5213506e RW |
2170 | # Keep a trace of the command line. |
2171 | # Strip out --no-create and --no-recursion so they do not pile up. | |
2172 | # Strip out --silent because we don't want to record it for future runs. | |
2173 | # Also quote any args containing shell meta-characters. | |
2174 | # Make two passes to allow for proper duplicate-argument suppression. | |
2175 | ac_configure_args= | |
2176 | ac_configure_args0= | |
2177 | ac_configure_args1= | |
2178 | ac_must_keep_next=false | |
2179 | for ac_pass in 1 2 | |
2180 | do | |
2181 | for ac_arg | |
2182 | do | |
2183 | case $ac_arg in | |
2184 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
2185 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
2186 | | -silent | --silent | --silen | --sile | --sil) | |
2187 | continue ;; | |
2188 | *\'*) | |
2189 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2190 | esac | |
2191 | case $ac_pass in | |
2192 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
2193 | 2) | |
2194 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
2195 | if test $ac_must_keep_next = true; then | |
2196 | ac_must_keep_next=false # Got value, back to normal. | |
2197 | else | |
2198 | case $ac_arg in | |
2199 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
2200 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
2201 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
2202 | | -with-* | --with-* | -without-* | --without-* | --x) | |
2203 | case "$ac_configure_args0 " in | |
2204 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
2205 | esac | |
2206 | ;; | |
2207 | -* ) ac_must_keep_next=true ;; | |
2208 | esac | |
2209 | fi | |
2210 | as_fn_append ac_configure_args " '$ac_arg'" | |
2211 | ;; | |
2212 | esac | |
2213 | done | |
2214 | done | |
2215 | { ac_configure_args0=; unset ac_configure_args0;} | |
2216 | { ac_configure_args1=; unset ac_configure_args1;} | |
18c04407 | 2217 | |
5213506e RW |
2218 | # When interrupted or exit'd, cleanup temporary files, and complete |
2219 | # config.log. We remove comments because anyway the quotes in there | |
2220 | # would cause problems or look ugly. | |
2221 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
2222 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
2223 | trap 'exit_status=$? | |
2224 | # Save into config.log some information that might help in debugging. | |
2225 | { | |
2226 | echo | |
18c04407 | 2227 | |
22e05272 | 2228 | $as_echo "## ---------------- ## |
5213506e | 2229 | ## Cache variables. ## |
22e05272 | 2230 | ## ---------------- ##" |
5213506e RW |
2231 | echo |
2232 | # The following way of writing the cache mishandles newlines in values, | |
2233 | ( | |
2234 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
2235 | eval ac_val=\$$ac_var | |
2236 | case $ac_val in #( | |
2237 | *${as_nl}*) | |
2238 | case $ac_var in #( | |
2239 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
2240 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
2241 | esac | |
2242 | case $ac_var in #( | |
2243 | _ | IFS | as_nl) ;; #( | |
2244 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
2245 | *) { eval $ac_var=; unset $ac_var;} ;; | |
2246 | esac ;; | |
2247 | esac | |
2248 | done | |
2249 | (set) 2>&1 | | |
2250 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
2251 | *${as_nl}ac_space=\ *) | |
2252 | sed -n \ | |
2253 | "s/'\''/'\''\\\\'\'''\''/g; | |
2254 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
2255 | ;; #( | |
2256 | *) | |
2257 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
2258 | ;; | |
2259 | esac | | |
2260 | sort | |
2261 | ) | |
2262 | echo | |
238235ef | 2263 | |
22e05272 | 2264 | $as_echo "## ----------------- ## |
5213506e | 2265 | ## Output variables. ## |
22e05272 | 2266 | ## ----------------- ##" |
5213506e RW |
2267 | echo |
2268 | for ac_var in $ac_subst_vars | |
2269 | do | |
2270 | eval ac_val=\$$ac_var | |
2271 | case $ac_val in | |
2272 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2273 | esac | |
2274 | $as_echo "$ac_var='\''$ac_val'\''" | |
2275 | done | sort | |
2276 | echo | |
238235ef | 2277 | |
5213506e | 2278 | if test -n "$ac_subst_files"; then |
22e05272 | 2279 | $as_echo "## ------------------- ## |
5213506e | 2280 | ## File substitutions. ## |
22e05272 | 2281 | ## ------------------- ##" |
5213506e RW |
2282 | echo |
2283 | for ac_var in $ac_subst_files | |
2284 | do | |
2285 | eval ac_val=\$$ac_var | |
2286 | case $ac_val in | |
2287 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2288 | esac | |
2289 | $as_echo "$ac_var='\''$ac_val'\''" | |
2290 | done | sort | |
2291 | echo | |
2292 | fi | |
9bf3c9cc | 2293 | |
5213506e | 2294 | if test -s confdefs.h; then |
22e05272 | 2295 | $as_echo "## ----------- ## |
5213506e | 2296 | ## confdefs.h. ## |
22e05272 | 2297 | ## ----------- ##" |
5213506e RW |
2298 | echo |
2299 | cat confdefs.h | |
2300 | echo | |
2301 | fi | |
2302 | test "$ac_signal" != 0 && | |
2303 | $as_echo "$as_me: caught signal $ac_signal" | |
2304 | $as_echo "$as_me: exit $exit_status" | |
2305 | } >&5 | |
2306 | rm -f core *.core core.conftest.* && | |
2307 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
2308 | exit $exit_status | |
2309 | ' 0 | |
2310 | for ac_signal in 1 2 13 15; do | |
2311 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
2312 | done | |
2313 | ac_signal=0 | |
238235ef | 2314 | |
5213506e RW |
2315 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
2316 | rm -f -r conftest* confdefs.h | |
238235ef | 2317 | |
5213506e | 2318 | $as_echo "/* confdefs.h */" > confdefs.h |
238235ef | 2319 | |
5213506e | 2320 | # Predefined preprocessor variables. |
238235ef | 2321 | |
5213506e RW |
2322 | cat >>confdefs.h <<_ACEOF |
2323 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
2324 | _ACEOF | |
238235ef | 2325 | |
5213506e RW |
2326 | cat >>confdefs.h <<_ACEOF |
2327 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2328 | _ACEOF | |
238235ef | 2329 | |
5213506e RW |
2330 | cat >>confdefs.h <<_ACEOF |
2331 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
2332 | _ACEOF | |
cd862df8 | 2333 | |
5213506e RW |
2334 | cat >>confdefs.h <<_ACEOF |
2335 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
2336 | _ACEOF | |
238235ef | 2337 | |
5213506e RW |
2338 | cat >>confdefs.h <<_ACEOF |
2339 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2340 | _ACEOF | |
ca6b370d | 2341 | |
5213506e RW |
2342 | cat >>confdefs.h <<_ACEOF |
2343 | #define PACKAGE_URL "$PACKAGE_URL" | |
2344 | _ACEOF | |
0bc0cd11 JL |
2345 | |
2346 | ||
5213506e RW |
2347 | # Let the site file select an alternate cache file if it wants to. |
2348 | # Prefer an explicitly selected file to automatically selected ones. | |
2349 | ac_site_file1=NONE | |
2350 | ac_site_file2=NONE | |
2351 | if test -n "$CONFIG_SITE"; then | |
22e05272 JM |
2352 | # We do not want a PATH search for config.site. |
2353 | case $CONFIG_SITE in #(( | |
2354 | -*) ac_site_file1=./$CONFIG_SITE;; | |
2355 | */*) ac_site_file1=$CONFIG_SITE;; | |
2356 | *) ac_site_file1=./$CONFIG_SITE;; | |
2357 | esac | |
5213506e RW |
2358 | elif test "x$prefix" != xNONE; then |
2359 | ac_site_file1=$prefix/share/config.site | |
2360 | ac_site_file2=$prefix/etc/config.site | |
2361 | else | |
2362 | ac_site_file1=$ac_default_prefix/share/config.site | |
2363 | ac_site_file2=$ac_default_prefix/etc/config.site | |
2364 | fi | |
2365 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" | |
2366 | do | |
2367 | test "x$ac_site_file" = xNONE && continue | |
22e05272 | 2368 | if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then |
5213506e RW |
2369 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 |
2370 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2371 | sed 's/^/| /' "$ac_site_file" >&5 | |
22e05272 JM |
2372 | . "$ac_site_file" \ |
2373 | || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2374 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2375 | as_fn_error $? "failed to load site script $ac_site_file | |
2376 | See \`config.log' for more details" "$LINENO" 5; } | |
5213506e RW |
2377 | fi |
2378 | done | |
2379 | ||
2380 | if test -r "$cache_file"; then | |
22e05272 JM |
2381 | # Some versions of bash will fail to source /dev/null (special files |
2382 | # actually), so we avoid doing that. DJGPP emulates it as a regular file. | |
2383 | if test /dev/null != "$cache_file" && test -f "$cache_file"; then | |
5213506e RW |
2384 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 |
2385 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2386 | case $cache_file in | |
2387 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2388 | *) . "./$cache_file";; | |
2389 | esac | |
2390 | fi | |
2391 | else | |
2392 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 | |
2393 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2394 | >$cache_file | |
2395 | fi | |
2396 | ||
22e05272 JM |
2397 | as_fn_append ac_header_list " stdlib.h" |
2398 | as_fn_append ac_header_list " unistd.h" | |
2399 | as_fn_append ac_header_list " sys/param.h" | |
5213506e RW |
2400 | # Check that the precious variables saved in the cache have kept the same |
2401 | # value. | |
2402 | ac_cache_corrupted=false | |
2403 | for ac_var in $ac_precious_vars; do | |
2404 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2405 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2406 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2407 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2408 | case $ac_old_set,$ac_new_set in | |
2409 | set,) | |
2410 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2411 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2412 | ac_cache_corrupted=: ;; | |
2413 | ,set) | |
2414 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2415 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2416 | ac_cache_corrupted=: ;; | |
2417 | ,);; | |
2418 | *) | |
2419 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2420 | # differences in whitespace do not lead to failure. | |
2421 | ac_old_val_w=`echo x $ac_old_val` | |
2422 | ac_new_val_w=`echo x $ac_new_val` | |
2423 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2424 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2425 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2426 | ac_cache_corrupted=: | |
2427 | else | |
2428 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2429 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2430 | eval $ac_var=\$ac_old_val | |
2431 | fi | |
2432 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2433 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
2434 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
2435 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
2436 | fi;; | |
2437 | esac | |
2438 | # Pass precious variables to config.status. | |
2439 | if test "$ac_new_set" = set; then | |
2440 | case $ac_new_val in | |
2441 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2442 | *) ac_arg=$ac_var=$ac_new_val ;; | |
2443 | esac | |
2444 | case " $ac_configure_args " in | |
2445 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
2446 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
2447 | esac | |
2448 | fi | |
2449 | done | |
2450 | if $ac_cache_corrupted; then | |
2451 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2452 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2453 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
2454 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
22e05272 | 2455 | as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 |
5213506e RW |
2456 | fi |
2457 | ## -------------------- ## | |
2458 | ## Main body of script. ## | |
2459 | ## -------------------- ## | |
2460 | ||
2461 | ac_ext=c | |
2462 | ac_cpp='$CPP $CPPFLAGS' | |
2463 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2464 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2465 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
2466 | ||
2467 | ||
2468 | ||
2469 | ||
1f237573 | 2470 | |
f2c52c0d RO |
2471 | |
2472 | ||
2473 | ||
5213506e RW |
2474 | # This works around the fact that libtool configuration may change LD |
2475 | # for this particular configuration, but some shells, instead of | |
2476 | # keeping the changes in LD private, export them just because LD is | |
2477 | # exported. We don't use libtool yet, but some day we might, so... | |
2478 | ORIGINAL_LD_FOR_MULTILIBS=$LD | |
2479 | ||
2480 | ||
2481 | # Check whether --with-target-subdir was given. | |
2482 | if test "${with_target_subdir+set}" = set; then : | |
2483 | withval=$with_target_subdir; | |
2484 | fi | |
2485 | ||
2486 | ||
2487 | # Check whether --with-build-subdir was given. | |
2488 | if test "${with_build_subdir+set}" = set; then : | |
2489 | withval=$with_build_subdir; | |
2490 | fi | |
2491 | ||
2492 | ||
2493 | # Check whether --with-cross-host was given. | |
2494 | if test "${with_cross_host+set}" = set; then : | |
2495 | withval=$with_cross_host; | |
2496 | fi | |
2497 | ||
2498 | ||
2499 | # Check whether --with-newlib was given. | |
2500 | if test "${with_newlib+set}" = set; then : | |
2501 | withval=$with_newlib; | |
2502 | fi | |
2503 | ||
2504 | ||
2505 | if test "${srcdir}" = "."; then | |
2506 | if test -n "${with_build_subdir}"; then | |
2507 | libiberty_topdir="${srcdir}/../.." | |
cd862df8 L |
2508 | with_target_subdir= |
2509 | elif test -z "${with_target_subdir}"; then | |
0bc0cd11 JL |
2510 | libiberty_topdir="${srcdir}/.." |
2511 | else | |
2512 | if test "${with_target_subdir}" != "."; then | |
2513 | libiberty_topdir="${srcdir}/${with_multisrctop}../.." | |
2514 | else | |
2515 | libiberty_topdir="${srcdir}/${with_multisrctop}.." | |
2516 | fi | |
2517 | fi | |
2518 | else | |
2519 | libiberty_topdir="${srcdir}/.." | |
2520 | fi | |
d8c22ce7 | 2521 | |
0bc0cd11 | 2522 | ac_aux_dir= |
5213506e | 2523 | for ac_dir in $libiberty_topdir "$srcdir"/$libiberty_topdir; do |
22e05272 JM |
2524 | if test -f "$ac_dir/install-sh"; then |
2525 | ac_aux_dir=$ac_dir | |
2526 | ac_install_sh="$ac_aux_dir/install-sh -c" | |
2527 | break | |
2528 | elif test -f "$ac_dir/install.sh"; then | |
2529 | ac_aux_dir=$ac_dir | |
2530 | ac_install_sh="$ac_aux_dir/install.sh -c" | |
2531 | break | |
2532 | elif test -f "$ac_dir/shtool"; then | |
2533 | ac_aux_dir=$ac_dir | |
2534 | ac_install_sh="$ac_aux_dir/shtool install -c" | |
2535 | break | |
2536 | fi | |
0bc0cd11 JL |
2537 | done |
2538 | if test -z "$ac_aux_dir"; then | |
22e05272 | 2539 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in $libiberty_topdir \"$srcdir\"/$libiberty_topdir" "$LINENO" 5 |
0bc0cd11 | 2540 | fi |
0bc0cd11 | 2541 | |
5213506e RW |
2542 | # These three variables are undocumented and unsupported, |
2543 | # and are intended to be withdrawn in a future Autoconf release. | |
2544 | # They can cause serious problems if a builder's source tree is in a directory | |
2545 | # whose full name contains unusual characters. | |
2546 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
2547 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
2548 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
0bc0cd11 JL |
2549 | |
2550 | ||
5213506e RW |
2551 | |
2552 | ||
2553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 | |
2554 | $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } | |
2555 | # Check whether --enable-maintainer-mode was given. | |
2556 | if test "${enable_maintainer_mode+set}" = set; then : | |
2557 | enableval=$enable_maintainer_mode; maintainer_mode=$enableval | |
aaa5f039 DD |
2558 | else |
2559 | maintainer_mode=no | |
5213506e | 2560 | fi |
aaa5f039 | 2561 | |
5213506e RW |
2562 | |
2563 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $maintainer_mode" >&5 | |
2564 | $as_echo "$maintainer_mode" >&6; } | |
aaa5f039 DD |
2565 | |
2566 | if test "$maintainer_mode" = "yes"; then | |
2567 | MAINT='' | |
2568 | NOTMAINT='#' | |
2569 | else | |
2570 | MAINT='#' | |
2571 | NOTMAINT='' | |
2572 | fi | |
2573 | ||
909b30a1 EG |
2574 | if test -z "$ETAGS"; then |
2575 | ETAGS=etags | |
2576 | fi | |
2577 | ||
2578 | ||
0e30ffc5 DD |
2579 | # Do we have a single-tree copy of texinfo? Even if we do, we can't |
2580 | # rely on it - libiberty is built before texinfo. | |
2581 | # Extract the first word of "makeinfo", so it can be a program name with args. | |
aaa5f039 | 2582 | set dummy makeinfo; ac_word=$2 |
5213506e RW |
2583 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2584 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2585 | if ${ac_cv_prog_MAKEINFO+:} false; then : |
5213506e | 2586 | $as_echo_n "(cached) " >&6 |
aaa5f039 DD |
2587 | else |
2588 | if test -n "$MAKEINFO"; then | |
2589 | ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test. | |
2590 | else | |
238235ef DJ |
2591 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2592 | for as_dir in $PATH | |
2593 | do | |
2594 | IFS=$as_save_IFS | |
2595 | test -z "$as_dir" && as_dir=. | |
5213506e | 2596 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2597 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2598 | ac_cv_prog_MAKEINFO="makeinfo" |
5213506e | 2599 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2600 | break 2 |
2601 | fi | |
2602 | done | |
5213506e RW |
2603 | done |
2604 | IFS=$as_save_IFS | |
238235ef | 2605 | |
aaa5f039 DD |
2606 | fi |
2607 | fi | |
238235ef | 2608 | MAKEINFO=$ac_cv_prog_MAKEINFO |
aaa5f039 | 2609 | if test -n "$MAKEINFO"; then |
5213506e RW |
2610 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5 |
2611 | $as_echo "$MAKEINFO" >&6; } | |
aaa5f039 | 2612 | else |
5213506e RW |
2613 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2614 | $as_echo "no" >&6; } | |
aaa5f039 DD |
2615 | fi |
2616 | ||
5213506e | 2617 | |
f749bd83 AM |
2618 | if test "x$MAKEINFO" = "x"; then |
2619 | MAKEINFO="@echo makeinfo missing; true" | |
0e30ffc5 | 2620 | BUILD_INFO= |
f749bd83 AM |
2621 | else |
2622 | BUILD_INFO=info | |
c0590bfd L |
2623 | case "$MAKEINFO" in |
2624 | */missing\ makeinfo*) | |
f749bd83 | 2625 | BUILD_INFO= |
5213506e | 2626 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
c0590bfd | 2627 | *** Makeinfo is missing. Info documentation will not be built." >&5 |
5213506e | 2628 | $as_echo "$as_me: WARNING: |
c0590bfd L |
2629 | *** Makeinfo is missing. Info documentation will not be built." >&2;} |
2630 | ;; | |
2631 | *) | |
2632 | case x"`$MAKEINFO --version | grep 'GNU texinfo'`" in | |
2633 | x*\ [1-3].* ) | |
2634 | MAKEINFO="@echo $MAKEINFO is too old, 4.0 or newer required; true" | |
2635 | BUILD_INFO= | |
5213506e | 2636 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
238235ef | 2637 | *** Makeinfo is too old. Info documentation will not be built." >&5 |
5213506e | 2638 | $as_echo "$as_me: WARNING: |
238235ef | 2639 | *** Makeinfo is too old. Info documentation will not be built." >&2;} |
c0590bfd L |
2640 | ;; |
2641 | esac | |
f749bd83 AM |
2642 | ;; |
2643 | esac | |
2644 | fi | |
0e30ffc5 | 2645 | |
aaa5f039 DD |
2646 | |
2647 | ||
2648 | # Extract the first word of "perl", so it can be a program name with args. | |
2649 | set dummy perl; ac_word=$2 | |
5213506e RW |
2650 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2651 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2652 | if ${ac_cv_prog_PERL+:} false; then : |
5213506e | 2653 | $as_echo_n "(cached) " >&6 |
aaa5f039 DD |
2654 | else |
2655 | if test -n "$PERL"; then | |
2656 | ac_cv_prog_PERL="$PERL" # Let the user override the test. | |
2657 | else | |
238235ef DJ |
2658 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2659 | for as_dir in $PATH | |
2660 | do | |
2661 | IFS=$as_save_IFS | |
2662 | test -z "$as_dir" && as_dir=. | |
5213506e | 2663 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2664 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2665 | ac_cv_prog_PERL="perl" |
5213506e | 2666 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2667 | break 2 |
2668 | fi | |
2669 | done | |
5213506e RW |
2670 | done |
2671 | IFS=$as_save_IFS | |
238235ef | 2672 | |
aaa5f039 DD |
2673 | fi |
2674 | fi | |
238235ef | 2675 | PERL=$ac_cv_prog_PERL |
aaa5f039 | 2676 | if test -n "$PERL"; then |
5213506e RW |
2677 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5 |
2678 | $as_echo "$PERL" >&6; } | |
aaa5f039 | 2679 | else |
5213506e RW |
2680 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2681 | $as_echo "no" >&6; } | |
aaa5f039 DD |
2682 | fi |
2683 | ||
5213506e | 2684 | |
aaa5f039 DD |
2685 | if test x"$PERL" = x""; then |
2686 | HAVE_PERL='#' | |
2687 | else | |
2688 | HAVE_PERL='' | |
2689 | fi | |
2690 | ||
2691 | ||
0bc0cd11 | 2692 | # Make sure we can run config.sub. |
5213506e | 2693 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || |
22e05272 | 2694 | as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 |
5213506e RW |
2695 | |
2696 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 | |
2697 | $as_echo_n "checking build system type... " >&6; } | |
22e05272 | 2698 | if ${ac_cv_build+:} false; then : |
5213506e RW |
2699 | $as_echo_n "(cached) " >&6 |
2700 | else | |
2701 | ac_build_alias=$build_alias | |
2702 | test "x$ac_build_alias" = x && | |
2703 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
2704 | test "x$ac_build_alias" = x && | |
22e05272 | 2705 | as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 |
5213506e | 2706 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || |
22e05272 | 2707 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 |
5213506e RW |
2708 | |
2709 | fi | |
2710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 | |
2711 | $as_echo "$ac_cv_build" >&6; } | |
2712 | case $ac_cv_build in | |
2713 | *-*-*) ;; | |
22e05272 | 2714 | *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; |
5213506e | 2715 | esac |
238235ef | 2716 | build=$ac_cv_build |
5213506e RW |
2717 | ac_save_IFS=$IFS; IFS='-' |
2718 | set x $ac_cv_build | |
2719 | shift | |
2720 | build_cpu=$1 | |
2721 | build_vendor=$2 | |
2722 | shift; shift | |
2723 | # Remember, the first character of IFS is used to create $*, | |
2724 | # except with old shells: | |
2725 | build_os=$* | |
2726 | IFS=$ac_save_IFS | |
2727 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
0bc0cd11 JL |
2728 | |
2729 | ||
5213506e RW |
2730 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 |
2731 | $as_echo_n "checking host system type... " >&6; } | |
22e05272 | 2732 | if ${ac_cv_host+:} false; then : |
5213506e | 2733 | $as_echo_n "(cached) " >&6 |
238235ef | 2734 | else |
5213506e RW |
2735 | if test "x$host_alias" = x; then |
2736 | ac_cv_host=$ac_cv_build | |
2737 | else | |
2738 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
22e05272 | 2739 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 |
5213506e | 2740 | fi |
0bc0cd11 | 2741 | |
238235ef | 2742 | fi |
5213506e RW |
2743 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
2744 | $as_echo "$ac_cv_host" >&6; } | |
2745 | case $ac_cv_host in | |
2746 | *-*-*) ;; | |
22e05272 | 2747 | *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; |
5213506e | 2748 | esac |
238235ef | 2749 | host=$ac_cv_host |
5213506e RW |
2750 | ac_save_IFS=$IFS; IFS='-' |
2751 | set x $ac_cv_host | |
2752 | shift | |
2753 | host_cpu=$1 | |
2754 | host_vendor=$2 | |
2755 | shift; shift | |
2756 | # Remember, the first character of IFS is used to create $*, | |
2757 | # except with old shells: | |
2758 | host_os=$* | |
2759 | IFS=$ac_save_IFS | |
2760 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
0bc0cd11 | 2761 | |
0bc0cd11 | 2762 | |
0bc0cd11 | 2763 | |
0bc0cd11 | 2764 | |
238235ef DJ |
2765 | if test -n "$ac_tool_prefix"; then |
2766 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
0bc0cd11 | 2767 | set dummy ${ac_tool_prefix}ar; ac_word=$2 |
5213506e RW |
2768 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2769 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2770 | if ${ac_cv_prog_AR+:} false; then : |
5213506e | 2771 | $as_echo_n "(cached) " >&6 |
0bc0cd11 JL |
2772 | else |
2773 | if test -n "$AR"; then | |
2774 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
2775 | else | |
238235ef DJ |
2776 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2777 | for as_dir in $PATH | |
2778 | do | |
2779 | IFS=$as_save_IFS | |
2780 | test -z "$as_dir" && as_dir=. | |
5213506e | 2781 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2782 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2783 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
5213506e | 2784 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2785 | break 2 |
2786 | fi | |
2787 | done | |
5213506e RW |
2788 | done |
2789 | IFS=$as_save_IFS | |
238235ef | 2790 | |
0bc0cd11 JL |
2791 | fi |
2792 | fi | |
238235ef | 2793 | AR=$ac_cv_prog_AR |
0bc0cd11 | 2794 | if test -n "$AR"; then |
5213506e RW |
2795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
2796 | $as_echo "$AR" >&6; } | |
0bc0cd11 | 2797 | else |
5213506e RW |
2798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2799 | $as_echo "no" >&6; } | |
238235ef DJ |
2800 | fi |
2801 | ||
5213506e | 2802 | |
0bc0cd11 | 2803 | fi |
238235ef DJ |
2804 | if test -z "$ac_cv_prog_AR"; then |
2805 | ac_ct_AR=$AR | |
2806 | # Extract the first word of "ar", so it can be a program name with args. | |
2807 | set dummy ar; ac_word=$2 | |
5213506e RW |
2808 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2809 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2810 | if ${ac_cv_prog_ac_ct_AR+:} false; then : |
5213506e | 2811 | $as_echo_n "(cached) " >&6 |
238235ef DJ |
2812 | else |
2813 | if test -n "$ac_ct_AR"; then | |
2814 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
2815 | else | |
2816 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2817 | for as_dir in $PATH | |
2818 | do | |
2819 | IFS=$as_save_IFS | |
2820 | test -z "$as_dir" && as_dir=. | |
5213506e | 2821 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2822 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2823 | ac_cv_prog_ac_ct_AR="ar" |
5213506e | 2824 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2825 | break 2 |
2826 | fi | |
2827 | done | |
5213506e RW |
2828 | done |
2829 | IFS=$as_save_IFS | |
0bc0cd11 | 2830 | |
238235ef DJ |
2831 | fi |
2832 | fi | |
2833 | ac_ct_AR=$ac_cv_prog_ac_ct_AR | |
2834 | if test -n "$ac_ct_AR"; then | |
5213506e RW |
2835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 |
2836 | $as_echo "$ac_ct_AR" >&6; } | |
238235ef | 2837 | else |
5213506e RW |
2838 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2839 | $as_echo "no" >&6; } | |
238235ef | 2840 | fi |
0bc0cd11 | 2841 | |
5213506e RW |
2842 | if test "x$ac_ct_AR" = x; then |
2843 | AR="" | |
2844 | else | |
2845 | case $cross_compiling:$ac_tool_warned in | |
2846 | yes:) | |
2847 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
2848 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
2849 | ac_tool_warned=yes ;; | |
2850 | esac | |
2851 | AR=$ac_ct_AR | |
2852 | fi | |
238235ef DJ |
2853 | else |
2854 | AR="$ac_cv_prog_AR" | |
2855 | fi | |
0bc0cd11 | 2856 | |
238235ef DJ |
2857 | if test -n "$ac_tool_prefix"; then |
2858 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
0bc0cd11 | 2859 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 |
5213506e RW |
2860 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2861 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2862 | if ${ac_cv_prog_RANLIB+:} false; then : |
5213506e | 2863 | $as_echo_n "(cached) " >&6 |
0bc0cd11 JL |
2864 | else |
2865 | if test -n "$RANLIB"; then | |
2866 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
2867 | else | |
238235ef DJ |
2868 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2869 | for as_dir in $PATH | |
2870 | do | |
2871 | IFS=$as_save_IFS | |
2872 | test -z "$as_dir" && as_dir=. | |
5213506e | 2873 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2874 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2875 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
5213506e | 2876 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2877 | break 2 |
2878 | fi | |
2879 | done | |
5213506e RW |
2880 | done |
2881 | IFS=$as_save_IFS | |
238235ef | 2882 | |
0bc0cd11 JL |
2883 | fi |
2884 | fi | |
238235ef | 2885 | RANLIB=$ac_cv_prog_RANLIB |
0bc0cd11 | 2886 | if test -n "$RANLIB"; then |
5213506e RW |
2887 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
2888 | $as_echo "$RANLIB" >&6; } | |
0bc0cd11 | 2889 | else |
5213506e RW |
2890 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2891 | $as_echo "no" >&6; } | |
0bc0cd11 JL |
2892 | fi |
2893 | ||
5213506e | 2894 | |
238235ef | 2895 | fi |
0bc0cd11 | 2896 | if test -z "$ac_cv_prog_RANLIB"; then |
238235ef | 2897 | ac_ct_RANLIB=$RANLIB |
0bc0cd11 JL |
2898 | # Extract the first word of "ranlib", so it can be a program name with args. |
2899 | set dummy ranlib; ac_word=$2 | |
5213506e RW |
2900 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
2901 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 2902 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : |
5213506e | 2903 | $as_echo_n "(cached) " >&6 |
0bc0cd11 | 2904 | else |
238235ef DJ |
2905 | if test -n "$ac_ct_RANLIB"; then |
2906 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
0bc0cd11 | 2907 | else |
238235ef DJ |
2908 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2909 | for as_dir in $PATH | |
2910 | do | |
2911 | IFS=$as_save_IFS | |
2912 | test -z "$as_dir" && as_dir=. | |
5213506e | 2913 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 2914 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 2915 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
5213506e | 2916 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
2917 | break 2 |
2918 | fi | |
2919 | done | |
5213506e RW |
2920 | done |
2921 | IFS=$as_save_IFS | |
238235ef | 2922 | |
0bc0cd11 JL |
2923 | fi |
2924 | fi | |
238235ef DJ |
2925 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
2926 | if test -n "$ac_ct_RANLIB"; then | |
5213506e RW |
2927 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
2928 | $as_echo "$ac_ct_RANLIB" >&6; } | |
0bc0cd11 | 2929 | else |
5213506e RW |
2930 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
2931 | $as_echo "no" >&6; } | |
0bc0cd11 JL |
2932 | fi |
2933 | ||
5213506e RW |
2934 | if test "x$ac_ct_RANLIB" = x; then |
2935 | RANLIB=":" | |
2936 | else | |
2937 | case $cross_compiling:$ac_tool_warned in | |
2938 | yes:) | |
2939 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
2940 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
2941 | ac_tool_warned=yes ;; | |
2942 | esac | |
2943 | RANLIB=$ac_ct_RANLIB | |
2944 | fi | |
0bc0cd11 | 2945 | else |
238235ef | 2946 | RANLIB="$ac_cv_prog_RANLIB" |
0bc0cd11 JL |
2947 | fi |
2948 | ||
2949 | ||
126f707e L |
2950 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -plugin option" >&5 |
2951 | $as_echo_n "checking for -plugin option... " >&6; } | |
2952 | ||
2953 | plugin_names="liblto_plugin.so liblto_plugin-0.dll cyglto_plugin-0.dll" | |
2954 | plugin_option= | |
2955 | for plugin in $plugin_names; do | |
2956 | plugin_so=`${CC} ${CFLAGS} --print-prog-name $plugin` | |
2957 | if test x$plugin_so = x$plugin; then | |
2958 | plugin_so=`${CC} ${CFLAGS} --print-file-name $plugin` | |
2959 | fi | |
2960 | if test x$plugin_so != x$plugin; then | |
2961 | plugin_option="--plugin $plugin_so" | |
2962 | break | |
2963 | fi | |
2964 | done | |
9c7797a8 L |
2965 | if test -n "$ac_tool_prefix"; then |
2966 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
2967 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
2968 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
2969 | $as_echo_n "checking for $ac_word... " >&6; } | |
2970 | if ${ac_cv_prog_AR+:} false; then : | |
2971 | $as_echo_n "(cached) " >&6 | |
2972 | else | |
2973 | if test -n "$AR"; then | |
2974 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
2975 | else | |
2976 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
2977 | for as_dir in $PATH | |
2978 | do | |
2979 | IFS=$as_save_IFS | |
2980 | test -z "$as_dir" && as_dir=. | |
2981 | for ac_exec_ext in '' $ac_executable_extensions; do | |
2982 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
2983 | ac_cv_prog_AR="${ac_tool_prefix}ar" | |
2984 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
2985 | break 2 | |
2986 | fi | |
2987 | done | |
2988 | done | |
2989 | IFS=$as_save_IFS | |
2990 | ||
2991 | fi | |
2992 | fi | |
2993 | AR=$ac_cv_prog_AR | |
2994 | if test -n "$AR"; then | |
2995 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 | |
2996 | $as_echo "$AR" >&6; } | |
2997 | else | |
2998 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
2999 | $as_echo "no" >&6; } | |
3000 | fi | |
3001 | ||
3002 | ||
3003 | fi | |
3004 | if test -z "$ac_cv_prog_AR"; then | |
3005 | ac_ct_AR=$AR | |
3006 | # Extract the first word of "ar", so it can be a program name with args. | |
3007 | set dummy ar; ac_word=$2 | |
3008 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3009 | $as_echo_n "checking for $ac_word... " >&6; } | |
3010 | if ${ac_cv_prog_ac_ct_AR+:} false; then : | |
3011 | $as_echo_n "(cached) " >&6 | |
3012 | else | |
3013 | if test -n "$ac_ct_AR"; then | |
3014 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
3015 | else | |
3016 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3017 | for as_dir in $PATH | |
3018 | do | |
3019 | IFS=$as_save_IFS | |
3020 | test -z "$as_dir" && as_dir=. | |
3021 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3022 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | |
3023 | ac_cv_prog_ac_ct_AR="ar" | |
3024 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3025 | break 2 | |
3026 | fi | |
3027 | done | |
3028 | done | |
3029 | IFS=$as_save_IFS | |
3030 | ||
3031 | fi | |
3032 | fi | |
3033 | ac_ct_AR=$ac_cv_prog_ac_ct_AR | |
3034 | if test -n "$ac_ct_AR"; then | |
3035 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 | |
3036 | $as_echo "$ac_ct_AR" >&6; } | |
3037 | else | |
3038 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3039 | $as_echo "no" >&6; } | |
3040 | fi | |
3041 | ||
3042 | if test "x$ac_ct_AR" = x; then | |
3043 | AR="" | |
3044 | else | |
3045 | case $cross_compiling:$ac_tool_warned in | |
3046 | yes:) | |
3047 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3048 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3049 | ac_tool_warned=yes ;; | |
3050 | esac | |
3051 | AR=$ac_ct_AR | |
3052 | fi | |
3053 | else | |
3054 | AR="$ac_cv_prog_AR" | |
3055 | fi | |
3056 | ||
3057 | if test "${AR}" = "" ; then | |
3058 | as_fn_error $? "Required archive tool 'ar' not found on PATH." "$LINENO" 5 | |
3059 | fi | |
3060 | touch conftest.c | |
3061 | ${AR} $plugin_option rc conftest.a conftest.c | |
3062 | if test "$?" != 0; then | |
3063 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Failed: $AR $plugin_option rc" >&5 | |
3064 | $as_echo "$as_me: WARNING: Failed: $AR $plugin_option rc" >&2;} | |
3065 | plugin_option= | |
3066 | fi | |
3067 | rm -f conftest.* | |
126f707e L |
3068 | if test -n "$plugin_option"; then |
3069 | PLUGIN_OPTION="$plugin_option" | |
3070 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $plugin_option" >&5 | |
3071 | $as_echo "$plugin_option" >&6; } | |
3072 | else | |
3073 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3074 | $as_echo "no" >&6; } | |
3075 | fi | |
3076 | ||
3077 | if test -n "$PLUGIN_OPTION"; then | |
3078 | if $AR --help 2>&1 | grep -q "\--plugin"; then | |
3079 | AR_PLUGIN_OPTION="$PLUGIN_OPTION" | |
3080 | ||
3081 | fi | |
3082 | if $RANLIB --help 2>&1 | grep -q "\--plugin"; then | |
3083 | RANLIB_PLUGIN_OPTION="$PLUGIN_OPTION" | |
3084 | ||
3085 | fi | |
3086 | fi | |
3087 | ||
abea993f GK |
3088 | # Add --enable-multilib to configure. |
3089 | # Default to --enable-multilib | |
5213506e RW |
3090 | # Check whether --enable-multilib was given. |
3091 | if test "${enable_multilib+set}" = set; then : | |
3092 | enableval=$enable_multilib; case "$enableval" in | |
abea993f GK |
3093 | yes) multilib=yes ;; |
3094 | no) multilib=no ;; | |
22e05272 | 3095 | *) as_fn_error $? "bad value $enableval for multilib option" "$LINENO" 5 ;; |
abea993f GK |
3096 | esac |
3097 | else | |
3098 | multilib=yes | |
5213506e RW |
3099 | fi |
3100 | ||
abea993f GK |
3101 | |
3102 | # Even if the default multilib is not a cross compilation, | |
3103 | # it may be that some of the other multilibs are. | |
3104 | if test $cross_compiling = no && test $multilib = yes \ | |
3105 | && test "x${with_multisubdir}" != x ; then | |
3106 | cross_compiling=maybe | |
3107 | fi | |
3108 | ||
8c9fddf4 MB |
3109 | # We may wish to install the target headers somewhere. |
3110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to install libiberty headers and static library" >&5 | |
3111 | $as_echo_n "checking whether to install libiberty headers and static library... " >&6; } | |
3112 | ||
3113 | # Check whether --enable-install-libiberty was given. | |
3114 | if test "${enable_install_libiberty+set}" = set; then : | |
3115 | enableval=$enable_install_libiberty; enable_install_libiberty=$enableval | |
3116 | else | |
3117 | enable_install_libiberty=no | |
3118 | fi | |
3119 | ||
3120 | # Option parsed, now set things appropriately. | |
3121 | case x"$enable_install_libiberty" in | |
3122 | xyes|x) | |
3123 | target_header_dir=libiberty | |
3124 | ;; | |
3125 | xno) | |
3126 | target_header_dir= | |
3127 | ;; | |
3128 | *) | |
3129 | # This could be sanity-checked in various ways... | |
3130 | target_header_dir="${enable_install_libiberty}" | |
3131 | ;; | |
3132 | esac | |
3133 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_install_libiberty" >&5 | |
3134 | $as_echo "$enable_install_libiberty" >&6; } | |
3135 | { $as_echo "$as_me:${as_lineno-$LINENO}: target_header_dir = $target_header_dir" >&5 | |
3136 | $as_echo "$as_me: target_header_dir = $target_header_dir" >&6;} | |
3137 | ||
1eaf7d9c | 3138 | |
238235ef DJ |
3139 | ac_ext=c |
3140 | ac_cpp='$CPP $CPPFLAGS' | |
3141 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3142 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3143 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3144 | if test -n "$ac_tool_prefix"; then | |
3145 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
3146 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
5213506e RW |
3147 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3148 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3149 | if ${ac_cv_prog_CC+:} false; then : |
5213506e | 3150 | $as_echo_n "(cached) " >&6 |
238235ef DJ |
3151 | else |
3152 | if test -n "$CC"; then | |
3153 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3154 | else | |
3155 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3156 | for as_dir in $PATH | |
3157 | do | |
3158 | IFS=$as_save_IFS | |
3159 | test -z "$as_dir" && as_dir=. | |
5213506e | 3160 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3161 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 3162 | ac_cv_prog_CC="${ac_tool_prefix}gcc" |
5213506e | 3163 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
3164 | break 2 |
3165 | fi | |
3166 | done | |
5213506e RW |
3167 | done |
3168 | IFS=$as_save_IFS | |
238235ef DJ |
3169 | |
3170 | fi | |
3171 | fi | |
3172 | CC=$ac_cv_prog_CC | |
3173 | if test -n "$CC"; then | |
5213506e RW |
3174 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3175 | $as_echo "$CC" >&6; } | |
238235ef | 3176 | else |
5213506e RW |
3177 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3178 | $as_echo "no" >&6; } | |
238235ef DJ |
3179 | fi |
3180 | ||
5213506e | 3181 | |
238235ef DJ |
3182 | fi |
3183 | if test -z "$ac_cv_prog_CC"; then | |
3184 | ac_ct_CC=$CC | |
3185 | # Extract the first word of "gcc", so it can be a program name with args. | |
0bc0cd11 | 3186 | set dummy gcc; ac_word=$2 |
5213506e RW |
3187 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3188 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3189 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
5213506e | 3190 | $as_echo_n "(cached) " >&6 |
238235ef DJ |
3191 | else |
3192 | if test -n "$ac_ct_CC"; then | |
3193 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3194 | else | |
3195 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3196 | for as_dir in $PATH | |
3197 | do | |
3198 | IFS=$as_save_IFS | |
3199 | test -z "$as_dir" && as_dir=. | |
5213506e | 3200 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3201 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 3202 | ac_cv_prog_ac_ct_CC="gcc" |
5213506e | 3203 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
3204 | break 2 |
3205 | fi | |
3206 | done | |
5213506e RW |
3207 | done |
3208 | IFS=$as_save_IFS | |
238235ef DJ |
3209 | |
3210 | fi | |
3211 | fi | |
3212 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
3213 | if test -n "$ac_ct_CC"; then | |
5213506e RW |
3214 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
3215 | $as_echo "$ac_ct_CC" >&6; } | |
238235ef | 3216 | else |
5213506e RW |
3217 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3218 | $as_echo "no" >&6; } | |
238235ef DJ |
3219 | fi |
3220 | ||
5213506e RW |
3221 | if test "x$ac_ct_CC" = x; then |
3222 | CC="" | |
3223 | else | |
3224 | case $cross_compiling:$ac_tool_warned in | |
3225 | yes:) | |
3226 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3227 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3228 | ac_tool_warned=yes ;; | |
3229 | esac | |
3230 | CC=$ac_ct_CC | |
3231 | fi | |
238235ef DJ |
3232 | else |
3233 | CC="$ac_cv_prog_CC" | |
3234 | fi | |
3235 | ||
3236 | if test -z "$CC"; then | |
5213506e RW |
3237 | if test -n "$ac_tool_prefix"; then |
3238 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
238235ef | 3239 | set dummy ${ac_tool_prefix}cc; ac_word=$2 |
5213506e RW |
3240 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3241 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3242 | if ${ac_cv_prog_CC+:} false; then : |
5213506e | 3243 | $as_echo_n "(cached) " >&6 |
0bc0cd11 JL |
3244 | else |
3245 | if test -n "$CC"; then | |
3246 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3247 | else | |
238235ef DJ |
3248 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3249 | for as_dir in $PATH | |
3250 | do | |
3251 | IFS=$as_save_IFS | |
3252 | test -z "$as_dir" && as_dir=. | |
5213506e | 3253 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3254 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 3255 | ac_cv_prog_CC="${ac_tool_prefix}cc" |
5213506e | 3256 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
3257 | break 2 |
3258 | fi | |
3259 | done | |
5213506e RW |
3260 | done |
3261 | IFS=$as_save_IFS | |
238235ef | 3262 | |
0bc0cd11 JL |
3263 | fi |
3264 | fi | |
238235ef | 3265 | CC=$ac_cv_prog_CC |
0bc0cd11 | 3266 | if test -n "$CC"; then |
5213506e RW |
3267 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3268 | $as_echo "$CC" >&6; } | |
0bc0cd11 | 3269 | else |
5213506e RW |
3270 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3271 | $as_echo "no" >&6; } | |
0bc0cd11 JL |
3272 | fi |
3273 | ||
238235ef | 3274 | |
5213506e | 3275 | fi |
238235ef | 3276 | fi |
0bc0cd11 JL |
3277 | if test -z "$CC"; then |
3278 | # Extract the first word of "cc", so it can be a program name with args. | |
3279 | set dummy cc; ac_word=$2 | |
5213506e RW |
3280 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3281 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3282 | if ${ac_cv_prog_CC+:} false; then : |
5213506e | 3283 | $as_echo_n "(cached) " >&6 |
0bc0cd11 JL |
3284 | else |
3285 | if test -n "$CC"; then | |
3286 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3287 | else | |
0bc0cd11 | 3288 | ac_prog_rejected=no |
238235ef DJ |
3289 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3290 | for as_dir in $PATH | |
3291 | do | |
3292 | IFS=$as_save_IFS | |
3293 | test -z "$as_dir" && as_dir=. | |
5213506e | 3294 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3295 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef DJ |
3296 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then |
3297 | ac_prog_rejected=yes | |
3298 | continue | |
3299 | fi | |
3300 | ac_cv_prog_CC="cc" | |
5213506e | 3301 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
3302 | break 2 |
3303 | fi | |
3304 | done | |
5213506e RW |
3305 | done |
3306 | IFS=$as_save_IFS | |
238235ef | 3307 | |
0bc0cd11 JL |
3308 | if test $ac_prog_rejected = yes; then |
3309 | # We found a bogon in the path, so make sure we never use it. | |
3310 | set dummy $ac_cv_prog_CC | |
3311 | shift | |
238235ef | 3312 | if test $# != 0; then |
0bc0cd11 JL |
3313 | # We chose a different compiler from the bogus one. |
3314 | # However, it has the same basename, so the bogon will be chosen | |
3315 | # first if we set CC to just the basename; use the full file name. | |
3316 | shift | |
238235ef | 3317 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" |
0bc0cd11 JL |
3318 | fi |
3319 | fi | |
3320 | fi | |
3321 | fi | |
238235ef | 3322 | CC=$ac_cv_prog_CC |
0bc0cd11 | 3323 | if test -n "$CC"; then |
5213506e RW |
3324 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3325 | $as_echo "$CC" >&6; } | |
0bc0cd11 | 3326 | else |
5213506e RW |
3327 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3328 | $as_echo "no" >&6; } | |
0bc0cd11 JL |
3329 | fi |
3330 | ||
5213506e | 3331 | |
0bc0cd11 | 3332 | fi |
238235ef DJ |
3333 | if test -z "$CC"; then |
3334 | if test -n "$ac_tool_prefix"; then | |
5213506e | 3335 | for ac_prog in cl.exe |
238235ef DJ |
3336 | do |
3337 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
3338 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
5213506e RW |
3339 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3340 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3341 | if ${ac_cv_prog_CC+:} false; then : |
5213506e | 3342 | $as_echo_n "(cached) " >&6 |
0bc0cd11 | 3343 | else |
238235ef DJ |
3344 | if test -n "$CC"; then |
3345 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
0bc0cd11 | 3346 | else |
238235ef DJ |
3347 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3348 | for as_dir in $PATH | |
3349 | do | |
3350 | IFS=$as_save_IFS | |
3351 | test -z "$as_dir" && as_dir=. | |
5213506e | 3352 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3353 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 3354 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" |
5213506e | 3355 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef DJ |
3356 | break 2 |
3357 | fi | |
3358 | done | |
5213506e RW |
3359 | done |
3360 | IFS=$as_save_IFS | |
238235ef | 3361 | |
0bc0cd11 JL |
3362 | fi |
3363 | fi | |
238235ef DJ |
3364 | CC=$ac_cv_prog_CC |
3365 | if test -n "$CC"; then | |
5213506e RW |
3366 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 |
3367 | $as_echo "$CC" >&6; } | |
0bc0cd11 | 3368 | else |
5213506e RW |
3369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3370 | $as_echo "no" >&6; } | |
0bc0cd11 | 3371 | fi |
0bc0cd11 | 3372 | |
5213506e | 3373 | |
238235ef DJ |
3374 | test -n "$CC" && break |
3375 | done | |
0bc0cd11 | 3376 | fi |
238235ef DJ |
3377 | if test -z "$CC"; then |
3378 | ac_ct_CC=$CC | |
5213506e | 3379 | for ac_prog in cl.exe |
238235ef DJ |
3380 | do |
3381 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3382 | set dummy $ac_prog; ac_word=$2 | |
5213506e RW |
3383 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
3384 | $as_echo_n "checking for $ac_word... " >&6; } | |
22e05272 | 3385 | if ${ac_cv_prog_ac_ct_CC+:} false; then : |
5213506e | 3386 | $as_echo_n "(cached) " >&6 |
238235ef DJ |
3387 | else |
3388 | if test -n "$ac_ct_CC"; then | |
3389 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3390 | else | |
3391 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3392 | for as_dir in $PATH | |
3393 | do | |
3394 | IFS=$as_save_IFS | |
3395 | test -z "$as_dir" && as_dir=. | |
5213506e | 3396 | for ac_exec_ext in '' $ac_executable_extensions; do |
22e05272 | 3397 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then |
238235ef | 3398 | ac_cv_prog_ac_ct_CC="$ac_prog" |
5213506e | 3399 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
238235ef | 3400 | break 2 |
0bc0cd11 | 3401 | fi |
238235ef | 3402 | done |
5213506e RW |
3403 | done |
3404 | IFS=$as_save_IFS | |
238235ef DJ |
3405 | |
3406 | fi | |
3407 | fi | |
3408 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
3409 | if test -n "$ac_ct_CC"; then | |
5213506e RW |
3410 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 |
3411 | $as_echo "$ac_ct_CC" >&6; } | |
0bc0cd11 | 3412 | else |
5213506e RW |
3413 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3414 | $as_echo "no" >&6; } | |
0bc0cd11 JL |
3415 | fi |
3416 | ||
5213506e | 3417 | |
238235ef DJ |
3418 | test -n "$ac_ct_CC" && break |
3419 | done | |
0bc0cd11 | 3420 | |
5213506e RW |
3421 | if test "x$ac_ct_CC" = x; then |
3422 | CC="" | |
3423 | else | |
3424 | case $cross_compiling:$ac_tool_warned in | |
3425 | yes:) | |
3426 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3427 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3428 | ac_tool_warned=yes ;; | |
3429 | esac | |
3430 | CC=$ac_ct_CC | |
3431 | fi | |
238235ef DJ |
3432 | fi |
3433 | ||
3434 | fi | |
3435 | ||
3436 | ||
5213506e RW |
3437 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3438 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
3439 | as_fn_error $? "no acceptable C compiler found in \$PATH |
3440 | See \`config.log' for more details" "$LINENO" 5; } | |
238235ef DJ |
3441 | |
3442 | # Provide some information about the compiler. | |
5213506e RW |
3443 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 |
3444 | set X $ac_compile | |
3445 | ac_compiler=$2 | |
3446 | for ac_option in --version -v -V -qversion; do | |
3447 | { { ac_try="$ac_compiler $ac_option >&5" | |
3448 | case "(($ac_try" in | |
3449 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3450 | *) ac_try_echo=$ac_try;; | |
3451 | esac | |
3452 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3453 | $as_echo "$ac_try_echo"; } >&5 | |
3454 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
238235ef | 3455 | ac_status=$? |
5213506e RW |
3456 | if test -s conftest.err; then |
3457 | sed '10a\ | |
3458 | ... rest of stderr output deleted ... | |
3459 | 10q' conftest.err >conftest.er1 | |
3460 | cat conftest.er1 >&5 | |
5213506e | 3461 | fi |
22e05272 | 3462 | rm -f conftest.er1 conftest.err |
5213506e RW |
3463 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3464 | test $ac_status = 0; } | |
3465 | done | |
238235ef | 3466 | |
5213506e | 3467 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef | 3468 | /* end confdefs.h. */ |
02ce382c | 3469 | #include <stdio.h> |
238235ef DJ |
3470 | int |
3471 | main () | |
3472 | { | |
02ce382c | 3473 | printf ("hello world\n"); |
238235ef DJ |
3474 | ; |
3475 | return 0; | |
3476 | } | |
3477 | _ACEOF | |
3478 | # FIXME: Cleanup? | |
5213506e | 3479 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 |
238235ef DJ |
3480 | (eval $ac_link) 2>&5 |
3481 | ac_status=$? | |
5213506e RW |
3482 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3483 | test $ac_status = 0; }; then : | |
238235ef DJ |
3484 | gcc_no_link=no |
3485 | else | |
3486 | gcc_no_link=yes | |
3487 | fi | |
238235ef DJ |
3488 | if test x$gcc_no_link = xyes; then |
3489 | # Setting cross_compile will disable run tests; it will | |
3490 | # also disable AC_CHECK_FILE but that's generally | |
3491 | # correct if we can't link. | |
3492 | cross_compiling=yes | |
3493 | EXEEXT= | |
3494 | else | |
5213506e | 3495 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef DJ |
3496 | /* end confdefs.h. */ |
3497 | ||
3498 | int | |
3499 | main () | |
3500 | { | |
3501 | ||
3502 | ; | |
3503 | return 0; | |
3504 | } | |
3505 | _ACEOF | |
3506 | ac_clean_files_save=$ac_clean_files | |
22e05272 | 3507 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" |
238235ef DJ |
3508 | # Try to create an executable without -o first, disregard a.out. |
3509 | # It will help us diagnose broken compilers, and finding out an intuition | |
3510 | # of exeext. | |
22e05272 JM |
3511 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 |
3512 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
5213506e RW |
3513 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` |
3514 | ||
3515 | # The possible output files: | |
3516 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
3517 | ||
3518 | ac_rmfiles= | |
3519 | for ac_file in $ac_files | |
3520 | do | |
3521 | case $ac_file in | |
3522 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3523 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; | |
3524 | esac | |
3525 | done | |
3526 | rm -f $ac_rmfiles | |
3527 | ||
3528 | if { { ac_try="$ac_link_default" | |
3529 | case "(($ac_try" in | |
3530 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3531 | *) ac_try_echo=$ac_try;; | |
3532 | esac | |
3533 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3534 | $as_echo "$ac_try_echo"; } >&5 | |
3535 | (eval "$ac_link_default") 2>&5 | |
3536 | ac_status=$? | |
3537 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3538 | test $ac_status = 0; }; then : | |
3539 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. | |
3540 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
3541 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
3542 | # so that the user can short-circuit this test for compilers unknown to | |
3543 | # Autoconf. | |
3544 | for ac_file in $ac_files '' | |
238235ef DJ |
3545 | do |
3546 | test -f "$ac_file" || continue | |
3547 | case $ac_file in | |
5213506e | 3548 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) |
3beb1315 | 3549 | ;; |
238235ef | 3550 | [ab].out ) |
3beb1315 HPN |
3551 | # We found the default executable, but exeext='' is most |
3552 | # certainly right. | |
3553 | break;; | |
238235ef | 3554 | *.* ) |
5213506e RW |
3555 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; |
3556 | then :; else | |
3557 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3558 | fi | |
3559 | # We set ac_cv_exeext here because the later test for it is not | |
3560 | # safe: cross compilers may not add the suffix if given an `-o' | |
3561 | # argument, so we may need to know it at that point already. | |
3562 | # Even if this section looks crufty: it has the advantage of | |
3563 | # actually working. | |
3beb1315 | 3564 | break;; |
238235ef | 3565 | * ) |
3beb1315 | 3566 | break;; |
238235ef DJ |
3567 | esac |
3568 | done | |
5213506e RW |
3569 | test "$ac_cv_exeext" = no && ac_cv_exeext= |
3570 | ||
7fda878c | 3571 | else |
5213506e RW |
3572 | ac_file='' |
3573 | fi | |
5213506e | 3574 | if test -z "$ac_file"; then : |
22e05272 JM |
3575 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3576 | $as_echo "no" >&6; } | |
3577 | $as_echo "$as_me: failed program was:" >&5 | |
238235ef DJ |
3578 | sed 's/^/| /' conftest.$ac_ext >&5 |
3579 | ||
5213506e RW |
3580 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3581 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
3582 | as_fn_error 77 "C compiler cannot create executables |
3583 | See \`config.log' for more details" "$LINENO" 5; } | |
3584 | else | |
3585 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
3586 | $as_echo "yes" >&6; } | |
238235ef | 3587 | fi |
22e05272 JM |
3588 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 |
3589 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
3590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
3591 | $as_echo "$ac_file" >&6; } | |
238235ef | 3592 | ac_exeext=$ac_cv_exeext |
238235ef | 3593 | |
22e05272 | 3594 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out |
238235ef | 3595 | ac_clean_files=$ac_clean_files_save |
5213506e RW |
3596 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 |
3597 | $as_echo_n "checking for suffix of executables... " >&6; } | |
3598 | if { { ac_try="$ac_link" | |
3599 | case "(($ac_try" in | |
3600 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3601 | *) ac_try_echo=$ac_try;; | |
3602 | esac | |
3603 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3604 | $as_echo "$ac_try_echo"; } >&5 | |
3605 | (eval "$ac_link") 2>&5 | |
238235ef | 3606 | ac_status=$? |
5213506e RW |
3607 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
3608 | test $ac_status = 0; }; then : | |
238235ef DJ |
3609 | # If both `conftest.exe' and `conftest' are `present' (well, observable) |
3610 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
3611 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
3612 | # `rm'. | |
3613 | for ac_file in conftest.exe conftest conftest.*; do | |
3614 | test -f "$ac_file" || continue | |
3615 | case $ac_file in | |
5213506e | 3616 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; |
238235ef | 3617 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` |
3beb1315 | 3618 | break;; |
238235ef DJ |
3619 | * ) break;; |
3620 | esac | |
3621 | done | |
7fda878c | 3622 | else |
5213506e RW |
3623 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3624 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
3625 | as_fn_error $? "cannot compute suffix of executables: cannot compile and link |
3626 | See \`config.log' for more details" "$LINENO" 5; } | |
7fda878c | 3627 | fi |
22e05272 | 3628 | rm -f conftest conftest$ac_cv_exeext |
5213506e RW |
3629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 |
3630 | $as_echo "$ac_cv_exeext" >&6; } | |
238235ef DJ |
3631 | |
3632 | rm -f conftest.$ac_ext | |
3633 | EXEEXT=$ac_cv_exeext | |
3634 | ac_exeext=$EXEEXT | |
22e05272 JM |
3635 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
3636 | /* end confdefs.h. */ | |
3637 | #include <stdio.h> | |
3638 | int | |
3639 | main () | |
3640 | { | |
3641 | FILE *f = fopen ("conftest.out", "w"); | |
3642 | return ferror (f) || fclose (f) != 0; | |
3643 | ||
3644 | ; | |
3645 | return 0; | |
3646 | } | |
3647 | _ACEOF | |
3648 | ac_clean_files="$ac_clean_files conftest.out" | |
3649 | # Check that the compiler produces executables we can run. If not, either | |
3650 | # the compiler is broken, or we cross compile. | |
3651 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
3652 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
3653 | if test "$cross_compiling" != yes; then | |
3654 | { { ac_try="$ac_link" | |
3655 | case "(($ac_try" in | |
3656 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3657 | *) ac_try_echo=$ac_try;; | |
3658 | esac | |
3659 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3660 | $as_echo "$ac_try_echo"; } >&5 | |
3661 | (eval "$ac_link") 2>&5 | |
3662 | ac_status=$? | |
3663 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3664 | test $ac_status = 0; } | |
3665 | if { ac_try='./conftest$ac_cv_exeext' | |
3666 | { { case "(($ac_try" in | |
3667 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3668 | *) ac_try_echo=$ac_try;; | |
3669 | esac | |
3670 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3671 | $as_echo "$ac_try_echo"; } >&5 | |
3672 | (eval "$ac_try") 2>&5 | |
3673 | ac_status=$? | |
3674 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3675 | test $ac_status = 0; }; }; then | |
3676 | cross_compiling=no | |
3677 | else | |
3678 | if test "$cross_compiling" = maybe; then | |
3679 | cross_compiling=yes | |
3680 | else | |
3681 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3682 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3683 | as_fn_error $? "cannot run C compiled programs. | |
3684 | If you meant to cross compile, use \`--host'. | |
3685 | See \`config.log' for more details" "$LINENO" 5; } | |
3686 | fi | |
3687 | fi | |
3688 | fi | |
3689 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
3690 | $as_echo "$cross_compiling" >&6; } | |
3691 | ||
3692 | rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out | |
3693 | ac_clean_files=$ac_clean_files_save | |
7fda878c | 3694 | fi |
5213506e RW |
3695 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 |
3696 | $as_echo_n "checking for suffix of object files... " >&6; } | |
22e05272 | 3697 | if ${ac_cv_objext+:} false; then : |
5213506e | 3698 | $as_echo_n "(cached) " >&6 |
7fda878c | 3699 | else |
5213506e | 3700 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef | 3701 | /* end confdefs.h. */ |
7fda878c | 3702 | |
238235ef DJ |
3703 | int |
3704 | main () | |
3705 | { | |
7fda878c | 3706 | |
238235ef DJ |
3707 | ; |
3708 | return 0; | |
3709 | } | |
3710 | _ACEOF | |
3711 | rm -f conftest.o conftest.obj | |
5213506e RW |
3712 | if { { ac_try="$ac_compile" |
3713 | case "(($ac_try" in | |
3714 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3715 | *) ac_try_echo=$ac_try;; | |
3716 | esac | |
3717 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3718 | $as_echo "$ac_try_echo"; } >&5 | |
3719 | (eval "$ac_compile") 2>&5 | |
3720 | ac_status=$? | |
3721 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3722 | test $ac_status = 0; }; then : | |
3723 | for ac_file in conftest.o conftest.obj conftest.*; do | |
3724 | test -f "$ac_file" || continue; | |
238235ef | 3725 | case $ac_file in |
5213506e | 3726 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; |
238235ef DJ |
3727 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` |
3728 | break;; | |
3729 | esac | |
3730 | done | |
7fda878c | 3731 | else |
5213506e | 3732 | $as_echo "$as_me: failed program was:" >&5 |
238235ef DJ |
3733 | sed 's/^/| /' conftest.$ac_ext >&5 |
3734 | ||
5213506e RW |
3735 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3736 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
3737 | as_fn_error $? "cannot compute suffix of object files: cannot compile |
3738 | See \`config.log' for more details" "$LINENO" 5; } | |
238235ef | 3739 | fi |
238235ef | 3740 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
7fda878c | 3741 | fi |
5213506e RW |
3742 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
3743 | $as_echo "$ac_cv_objext" >&6; } | |
238235ef DJ |
3744 | OBJEXT=$ac_cv_objext |
3745 | ac_objext=$OBJEXT | |
5213506e RW |
3746 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 |
3747 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } | |
22e05272 | 3748 | if ${ac_cv_c_compiler_gnu+:} false; then : |
5213506e | 3749 | $as_echo_n "(cached) " >&6 |
238235ef | 3750 | else |
5213506e | 3751 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef DJ |
3752 | /* end confdefs.h. */ |
3753 | ||
3754 | int | |
3755 | main () | |
3756 | { | |
3757 | #ifndef __GNUC__ | |
3758 | choke me | |
3759 | #endif | |
7fda878c | 3760 | |
238235ef DJ |
3761 | ; |
3762 | return 0; | |
3763 | } | |
3764 | _ACEOF | |
5213506e | 3765 | if ac_fn_c_try_compile "$LINENO"; then : |
238235ef DJ |
3766 | ac_compiler_gnu=yes |
3767 | else | |
5213506e | 3768 | ac_compiler_gnu=no |
238235ef | 3769 | fi |
5213506e | 3770 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
238235ef DJ |
3771 | ac_cv_c_compiler_gnu=$ac_compiler_gnu |
3772 | ||
3773 | fi | |
5213506e RW |
3774 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 |
3775 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } | |
3776 | if test $ac_compiler_gnu = yes; then | |
3777 | GCC=yes | |
3778 | else | |
3779 | GCC= | |
3780 | fi | |
238235ef DJ |
3781 | ac_test_CFLAGS=${CFLAGS+set} |
3782 | ac_save_CFLAGS=$CFLAGS | |
5213506e RW |
3783 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 |
3784 | $as_echo_n "checking whether $CC accepts -g... " >&6; } | |
22e05272 | 3785 | if ${ac_cv_prog_cc_g+:} false; then : |
5213506e RW |
3786 | $as_echo_n "(cached) " >&6 |
3787 | else | |
3788 | ac_save_c_werror_flag=$ac_c_werror_flag | |
3789 | ac_c_werror_flag=yes | |
3790 | ac_cv_prog_cc_g=no | |
3791 | CFLAGS="-g" | |
3792 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
238235ef | 3793 | /* end confdefs.h. */ |
7fda878c | 3794 | |
238235ef DJ |
3795 | int |
3796 | main () | |
3797 | { | |
7fda878c | 3798 | |
238235ef DJ |
3799 | ; |
3800 | return 0; | |
3801 | } | |
3802 | _ACEOF | |
5213506e | 3803 | if ac_fn_c_try_compile "$LINENO"; then : |
238235ef DJ |
3804 | ac_cv_prog_cc_g=yes |
3805 | else | |
5213506e RW |
3806 | CFLAGS="" |
3807 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3808 | /* end confdefs.h. */ | |
3809 | ||
3810 | int | |
3811 | main () | |
3812 | { | |
3813 | ||
3814 | ; | |
3815 | return 0; | |
3816 | } | |
3817 | _ACEOF | |
3818 | if ac_fn_c_try_compile "$LINENO"; then : | |
3819 | ||
3820 | else | |
3821 | ac_c_werror_flag=$ac_save_c_werror_flag | |
3822 | CFLAGS="-g" | |
3823 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3824 | /* end confdefs.h. */ | |
3825 | ||
3826 | int | |
3827 | main () | |
3828 | { | |
0bc0cd11 | 3829 | |
5213506e RW |
3830 | ; |
3831 | return 0; | |
3832 | } | |
3833 | _ACEOF | |
3834 | if ac_fn_c_try_compile "$LINENO"; then : | |
3835 | ac_cv_prog_cc_g=yes | |
3836 | fi | |
3837 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
238235ef | 3838 | fi |
5213506e | 3839 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
238235ef | 3840 | fi |
5213506e RW |
3841 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3842 | ac_c_werror_flag=$ac_save_c_werror_flag | |
3843 | fi | |
3844 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 | |
3845 | $as_echo "$ac_cv_prog_cc_g" >&6; } | |
238235ef DJ |
3846 | if test "$ac_test_CFLAGS" = set; then |
3847 | CFLAGS=$ac_save_CFLAGS | |
3848 | elif test $ac_cv_prog_cc_g = yes; then | |
0bc0cd11 | 3849 | if test "$GCC" = yes; then |
238235ef | 3850 | CFLAGS="-g -O2" |
0bc0cd11 | 3851 | else |
238235ef | 3852 | CFLAGS="-g" |
0bc0cd11 JL |
3853 | fi |
3854 | else | |
238235ef DJ |
3855 | if test "$GCC" = yes; then |
3856 | CFLAGS="-O2" | |
3857 | else | |
3858 | CFLAGS= | |
3859 | fi | |
0bc0cd11 | 3860 | fi |
5213506e RW |
3861 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 |
3862 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } | |
22e05272 | 3863 | if ${ac_cv_prog_cc_c89+:} false; then : |
5213506e | 3864 | $as_echo_n "(cached) " >&6 |
238235ef | 3865 | else |
5213506e | 3866 | ac_cv_prog_cc_c89=no |
238235ef | 3867 | ac_save_CC=$CC |
5213506e | 3868 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef DJ |
3869 | /* end confdefs.h. */ |
3870 | #include <stdarg.h> | |
3871 | #include <stdio.h> | |
22e05272 | 3872 | struct stat; |
238235ef DJ |
3873 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ |
3874 | struct buf { int x; }; | |
3875 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
3876 | static char *e (p, i) | |
3877 | char **p; | |
3878 | int i; | |
3879 | { | |
3880 | return p[i]; | |
d1209685 | 3881 | } |
238235ef DJ |
3882 | static char *f (char * (*g) (char **, int), char **p, ...) |
3883 | { | |
3884 | char *s; | |
3885 | va_list v; | |
3886 | va_start (v,p); | |
3887 | s = g (p, va_arg (v,int)); | |
3888 | va_end (v); | |
3889 | return s; | |
d1209685 | 3890 | } |
3beb1315 HPN |
3891 | |
3892 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
3893 | function prototypes and stuff, but not '\xHH' hex character constants. | |
3894 | These don't provoke an error unfortunately, instead are silently treated | |
5213506e | 3895 | as 'x'. The following induces an error, until -std is added to get |
3beb1315 HPN |
3896 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an |
3897 | array size at least. It's necessary to write '\x00'==0 to get something | |
5213506e | 3898 | that's true only with -std. */ |
3beb1315 HPN |
3899 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; |
3900 | ||
5213506e RW |
3901 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters |
3902 | inside strings and character constants. */ | |
3903 | #define FOO(x) 'x' | |
3904 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
3905 | ||
238235ef DJ |
3906 | int test (int i, double x); |
3907 | struct s1 {int (*f) (int a);}; | |
3908 | struct s2 {int (*f) (double a);}; | |
3909 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
3910 | int argc; | |
3911 | char **argv; | |
3912 | int | |
3913 | main () | |
3914 | { | |
3915 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; | |
3916 | ; | |
3917 | return 0; | |
d1209685 | 3918 | } |
238235ef | 3919 | _ACEOF |
5213506e RW |
3920 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
3921 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
238235ef DJ |
3922 | do |
3923 | CC="$ac_save_CC $ac_arg" | |
5213506e RW |
3924 | if ac_fn_c_try_compile "$LINENO"; then : |
3925 | ac_cv_prog_cc_c89=$ac_arg | |
238235ef | 3926 | fi |
5213506e RW |
3927 | rm -f core conftest.err conftest.$ac_objext |
3928 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
238235ef | 3929 | done |
5213506e | 3930 | rm -f conftest.$ac_ext |
238235ef DJ |
3931 | CC=$ac_save_CC |
3932 | ||
3933 | fi | |
5213506e RW |
3934 | # AC_CACHE_VAL |
3935 | case "x$ac_cv_prog_cc_c89" in | |
3936 | x) | |
3937 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 | |
3938 | $as_echo "none needed" >&6; } ;; | |
3939 | xno) | |
3940 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 | |
3941 | $as_echo "unsupported" >&6; } ;; | |
238235ef | 3942 | *) |
5213506e RW |
3943 | CC="$CC $ac_cv_prog_cc_c89" |
3944 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 | |
3945 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; | |
238235ef | 3946 | esac |
5213506e | 3947 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
238235ef | 3948 | |
238235ef DJ |
3949 | fi |
3950 | ||
238235ef DJ |
3951 | ac_ext=c |
3952 | ac_cpp='$CPP $CPPFLAGS' | |
3953 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3954 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3955 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3956 | ||
d208e2d2 | 3957 | |
f50f17e6 YJ |
3958 | ac_ext=c |
3959 | ac_cpp='$CPP $CPPFLAGS' | |
3960 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3961 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3962 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
3963 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
3964 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
3965 | # On Suns, sometimes $CPP names a directory. | |
3966 | if test -n "$CPP" && test -d "$CPP"; then | |
3967 | CPP= | |
5213506e | 3968 | fi |
f50f17e6 | 3969 | if test -z "$CPP"; then |
22e05272 | 3970 | if ${ac_cv_prog_CPP+:} false; then : |
5213506e | 3971 | $as_echo_n "(cached) " >&6 |
d208e2d2 | 3972 | else |
f50f17e6 YJ |
3973 | # Double quotes because CPP needs to be expanded |
3974 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
3975 | do | |
3976 | ac_preproc_ok=false | |
3977 | for ac_c_preproc_warn_flag in '' yes | |
3978 | do | |
3979 | # Use a header file that comes with gcc, so configuring glibc | |
3980 | # with a fresh cross-compiler works. | |
3981 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
3982 | # <limits.h> exists even on freestanding compilers. | |
3983 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
3984 | # not just through cpp. "Syntax error" is here to catch this case. | |
3985 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
d208e2d2 | 3986 | /* end confdefs.h. */ |
f50f17e6 YJ |
3987 | #ifdef __STDC__ |
3988 | # include <limits.h> | |
3989 | #else | |
3990 | # include <assert.h> | |
3991 | #endif | |
3992 | Syntax error | |
d208e2d2 | 3993 | _ACEOF |
f50f17e6 YJ |
3994 | if ac_fn_c_try_cpp "$LINENO"; then : |
3995 | ||
3996 | else | |
3997 | # Broken: fails on valid input. | |
3998 | continue | |
d208e2d2 | 3999 | fi |
22e05272 | 4000 | rm -f conftest.err conftest.i conftest.$ac_ext |
f50f17e6 YJ |
4001 | |
4002 | # OK, works on sane cases. Now check whether nonexistent headers | |
4003 | # can be detected and how. | |
4004 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4005 | /* end confdefs.h. */ | |
4006 | #include <ac_nonexistent.h> | |
4007 | _ACEOF | |
4008 | if ac_fn_c_try_cpp "$LINENO"; then : | |
4009 | # Broken: success on invalid input. | |
4010 | continue | |
4011 | else | |
4012 | # Passes both tests. | |
4013 | ac_preproc_ok=: | |
4014 | break | |
d208e2d2 | 4015 | fi |
22e05272 | 4016 | rm -f conftest.err conftest.i conftest.$ac_ext |
f50f17e6 YJ |
4017 | |
4018 | done | |
4019 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
22e05272 | 4020 | rm -f conftest.i conftest.err conftest.$ac_ext |
f50f17e6 YJ |
4021 | if $ac_preproc_ok; then : |
4022 | break | |
d208e2d2 | 4023 | fi |
d208e2d2 | 4024 | |
f50f17e6 YJ |
4025 | done |
4026 | ac_cv_prog_CPP=$CPP | |
4027 | ||
4028 | fi | |
4029 | CPP=$ac_cv_prog_CPP | |
d208e2d2 | 4030 | else |
f50f17e6 YJ |
4031 | ac_cv_prog_CPP=$CPP |
4032 | fi | |
4033 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
4034 | $as_echo "$CPP" >&6; } | |
4035 | ac_preproc_ok=false | |
4036 | for ac_c_preproc_warn_flag in '' yes | |
4037 | do | |
4038 | # Use a header file that comes with gcc, so configuring glibc | |
4039 | # with a fresh cross-compiler works. | |
4040 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
4041 | # <limits.h> exists even on freestanding compilers. | |
4042 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
4043 | # not just through cpp. "Syntax error" is here to catch this case. | |
5213506e | 4044 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
d208e2d2 | 4045 | /* end confdefs.h. */ |
f50f17e6 YJ |
4046 | #ifdef __STDC__ |
4047 | # include <limits.h> | |
4048 | #else | |
4049 | # include <assert.h> | |
4050 | #endif | |
4051 | Syntax error | |
d208e2d2 | 4052 | _ACEOF |
f50f17e6 YJ |
4053 | if ac_fn_c_try_cpp "$LINENO"; then : |
4054 | ||
4055 | else | |
4056 | # Broken: fails on valid input. | |
4057 | continue | |
d208e2d2 | 4058 | fi |
22e05272 | 4059 | rm -f conftest.err conftest.i conftest.$ac_ext |
f50f17e6 YJ |
4060 | |
4061 | # OK, works on sane cases. Now check whether nonexistent headers | |
4062 | # can be detected and how. | |
5213506e | 4063 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
d208e2d2 | 4064 | /* end confdefs.h. */ |
f50f17e6 | 4065 | #include <ac_nonexistent.h> |
b033df90 | 4066 | _ACEOF |
5213506e | 4067 | if ac_fn_c_try_cpp "$LINENO"; then : |
b033df90 DJ |
4068 | # Broken: success on invalid input. |
4069 | continue | |
4070 | else | |
b033df90 DJ |
4071 | # Passes both tests. |
4072 | ac_preproc_ok=: | |
4073 | break | |
4074 | fi | |
22e05272 | 4075 | rm -f conftest.err conftest.i conftest.$ac_ext |
b033df90 DJ |
4076 | |
4077 | done | |
4078 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
22e05272 | 4079 | rm -f conftest.i conftest.err conftest.$ac_ext |
5213506e RW |
4080 | if $ac_preproc_ok; then : |
4081 | ||
b033df90 | 4082 | else |
5213506e RW |
4083 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
4084 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
4085 | as_fn_error $? "C preprocessor \"$CPP\" fails sanity check |
4086 | See \`config.log' for more details" "$LINENO" 5; } | |
b033df90 DJ |
4087 | fi |
4088 | ||
4089 | ac_ext=c | |
4090 | ac_cpp='$CPP $CPPFLAGS' | |
4091 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4092 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4093 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4094 | ||
4095 | ||
f50f17e6 YJ |
4096 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
4097 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } | |
22e05272 | 4098 | if ${ac_cv_path_GREP+:} false; then : |
5213506e | 4099 | $as_echo_n "(cached) " >&6 |
e8f9ec35 | 4100 | else |
f50f17e6 YJ |
4101 | if test -z "$GREP"; then |
4102 | ac_path_GREP_found=false | |
4103 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4104 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4105 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4106 | do | |
4107 | IFS=$as_save_IFS | |
4108 | test -z "$as_dir" && as_dir=. | |
4109 | for ac_prog in grep ggrep; do | |
4110 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4111 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
22e05272 | 4112 | as_fn_executable_p "$ac_path_GREP" || continue |
f50f17e6 YJ |
4113 | # Check for GNU ac_path_GREP and select it if it is found. |
4114 | # Check for GNU $ac_path_GREP | |
4115 | case `"$ac_path_GREP" --version 2>&1` in | |
4116 | *GNU*) | |
4117 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
4118 | *) | |
4119 | ac_count=0 | |
4120 | $as_echo_n 0123456789 >"conftest.in" | |
4121 | while : | |
4122 | do | |
4123 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4124 | mv "conftest.tmp" "conftest.in" | |
4125 | cp "conftest.in" "conftest.nl" | |
4126 | $as_echo 'GREP' >> "conftest.nl" | |
4127 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4128 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
4129 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
4130 | if test $ac_count -gt ${ac_path_GREP_max-0}; then | |
4131 | # Best one so far, save it but keep looking for a better one | |
4132 | ac_cv_path_GREP="$ac_path_GREP" | |
4133 | ac_path_GREP_max=$ac_count | |
4134 | fi | |
4135 | # 10*(2^10) chars as input seems more than enough | |
4136 | test $ac_count -gt 10 && break | |
4137 | done | |
4138 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4139 | esac | |
4140 | ||
4141 | $ac_path_GREP_found && break 3 | |
4142 | done | |
4143 | done | |
4144 | done | |
4145 | IFS=$as_save_IFS | |
4146 | if test -z "$ac_cv_path_GREP"; then | |
22e05272 | 4147 | as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
f50f17e6 | 4148 | fi |
aa2480c5 | 4149 | else |
f50f17e6 YJ |
4150 | ac_cv_path_GREP=$GREP |
4151 | fi | |
4152 | ||
4153 | fi | |
4154 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 | |
4155 | $as_echo "$ac_cv_path_GREP" >&6; } | |
4156 | GREP="$ac_cv_path_GREP" | |
4157 | ||
4158 | ||
4159 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 | |
4160 | $as_echo_n "checking for egrep... " >&6; } | |
22e05272 | 4161 | if ${ac_cv_path_EGREP+:} false; then : |
f50f17e6 YJ |
4162 | $as_echo_n "(cached) " >&6 |
4163 | else | |
4164 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 | |
4165 | then ac_cv_path_EGREP="$GREP -E" | |
4166 | else | |
4167 | if test -z "$EGREP"; then | |
4168 | ac_path_EGREP_found=false | |
4169 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4170 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4171 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4172 | do | |
4173 | IFS=$as_save_IFS | |
4174 | test -z "$as_dir" && as_dir=. | |
4175 | for ac_prog in egrep; do | |
4176 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4177 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
22e05272 | 4178 | as_fn_executable_p "$ac_path_EGREP" || continue |
f50f17e6 YJ |
4179 | # Check for GNU ac_path_EGREP and select it if it is found. |
4180 | # Check for GNU $ac_path_EGREP | |
4181 | case `"$ac_path_EGREP" --version 2>&1` in | |
4182 | *GNU*) | |
4183 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
4184 | *) | |
4185 | ac_count=0 | |
4186 | $as_echo_n 0123456789 >"conftest.in" | |
4187 | while : | |
4188 | do | |
4189 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
4190 | mv "conftest.tmp" "conftest.in" | |
4191 | cp "conftest.in" "conftest.nl" | |
4192 | $as_echo 'EGREP' >> "conftest.nl" | |
4193 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
4194 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
4195 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
4196 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then | |
4197 | # Best one so far, save it but keep looking for a better one | |
4198 | ac_cv_path_EGREP="$ac_path_EGREP" | |
4199 | ac_path_EGREP_max=$ac_count | |
4200 | fi | |
4201 | # 10*(2^10) chars as input seems more than enough | |
4202 | test $ac_count -gt 10 && break | |
4203 | done | |
4204 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
4205 | esac | |
4206 | ||
4207 | $ac_path_EGREP_found && break 3 | |
4208 | done | |
4209 | done | |
4210 | done | |
4211 | IFS=$as_save_IFS | |
4212 | if test -z "$ac_cv_path_EGREP"; then | |
22e05272 | 4213 | as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 |
f50f17e6 YJ |
4214 | fi |
4215 | else | |
4216 | ac_cv_path_EGREP=$EGREP | |
4217 | fi | |
4218 | ||
4219 | fi | |
4220 | fi | |
4221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 | |
4222 | $as_echo "$ac_cv_path_EGREP" >&6; } | |
4223 | EGREP="$ac_cv_path_EGREP" | |
4224 | ||
4225 | ||
4226 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 | |
4227 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
22e05272 | 4228 | if ${ac_cv_header_stdc+:} false; then : |
f50f17e6 YJ |
4229 | $as_echo_n "(cached) " >&6 |
4230 | else | |
4231 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
aa2480c5 | 4232 | /* end confdefs.h. */ |
f50f17e6 YJ |
4233 | #include <stdlib.h> |
4234 | #include <stdarg.h> | |
4235 | #include <string.h> | |
4236 | #include <float.h> | |
aa2480c5 PB |
4237 | |
4238 | int | |
4239 | main () | |
4240 | { | |
4241 | ||
4242 | ; | |
4243 | return 0; | |
4244 | } | |
4245 | _ACEOF | |
5213506e | 4246 | if ac_fn_c_try_compile "$LINENO"; then : |
f50f17e6 | 4247 | ac_cv_header_stdc=yes |
aa2480c5 | 4248 | else |
f50f17e6 | 4249 | ac_cv_header_stdc=no |
aa2480c5 | 4250 | fi |
5213506e | 4251 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f50f17e6 YJ |
4252 | |
4253 | if test $ac_cv_header_stdc = yes; then | |
4254 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
4255 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4256 | /* end confdefs.h. */ | |
4257 | #include <string.h> | |
4258 | ||
4259 | _ACEOF | |
4260 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4261 | $EGREP "memchr" >/dev/null 2>&1; then : | |
4262 | ||
4263 | else | |
4264 | ac_cv_header_stdc=no | |
aa2480c5 | 4265 | fi |
f50f17e6 | 4266 | rm -f conftest* |
aa2480c5 | 4267 | |
aa2480c5 PB |
4268 | fi |
4269 | ||
f50f17e6 YJ |
4270 | if test $ac_cv_header_stdc = yes; then |
4271 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
4272 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4273 | /* end confdefs.h. */ | |
4274 | #include <stdlib.h> | |
4275 | ||
4276 | _ACEOF | |
4277 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
4278 | $EGREP "free" >/dev/null 2>&1; then : | |
aa2480c5 | 4279 | |
24f2cabb | 4280 | else |
f50f17e6 | 4281 | ac_cv_header_stdc=no |
24f2cabb | 4282 | fi |
f50f17e6 YJ |
4283 | rm -f conftest* |
4284 | ||
4285 | fi | |
4286 | ||
4287 | if test $ac_cv_header_stdc = yes; then | |
4288 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
4289 | if test "$cross_compiling" = yes; then : | |
4290 | : | |
24f2cabb | 4291 | else |
5213506e | 4292 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
24f2cabb | 4293 | /* end confdefs.h. */ |
f50f17e6 YJ |
4294 | #include <ctype.h> |
4295 | #include <stdlib.h> | |
4296 | #if ((' ' & 0x0FF) == 0x020) | |
4297 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
4298 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
4299 | #else | |
4300 | # define ISLOWER(c) \ | |
4301 | (('a' <= (c) && (c) <= 'i') \ | |
4302 | || ('j' <= (c) && (c) <= 'r') \ | |
4303 | || ('s' <= (c) && (c) <= 'z')) | |
4304 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
4305 | #endif | |
24f2cabb | 4306 | |
f50f17e6 | 4307 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) |
24f2cabb L |
4308 | int |
4309 | main () | |
4310 | { | |
f50f17e6 YJ |
4311 | int i; |
4312 | for (i = 0; i < 256; i++) | |
4313 | if (XOR (islower (i), ISLOWER (i)) | |
4314 | || toupper (i) != TOUPPER (i)) | |
4315 | return 2; | |
24f2cabb L |
4316 | return 0; |
4317 | } | |
4318 | _ACEOF | |
f50f17e6 YJ |
4319 | if ac_fn_c_try_run "$LINENO"; then : |
4320 | ||
24f2cabb | 4321 | else |
f50f17e6 YJ |
4322 | ac_cv_header_stdc=no |
4323 | fi | |
4324 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
4325 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
24f2cabb | 4326 | fi |
24f2cabb L |
4327 | |
4328 | fi | |
f50f17e6 YJ |
4329 | fi |
4330 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 | |
4331 | $as_echo "$ac_cv_header_stdc" >&6; } | |
4332 | if test $ac_cv_header_stdc = yes; then | |
24f2cabb | 4333 | |
f50f17e6 | 4334 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
24f2cabb L |
4335 | |
4336 | fi | |
4337 | ||
f50f17e6 YJ |
4338 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. |
4339 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ | |
4340 | inttypes.h stdint.h unistd.h | |
4341 | do : | |
4342 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
4343 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
4344 | " | |
22e05272 | 4345 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
f50f17e6 YJ |
4346 | cat >>confdefs.h <<_ACEOF |
4347 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
4348 | _ACEOF | |
4349 | ||
4350 | fi | |
4351 | ||
4352 | done | |
4353 | ||
4354 | ||
4355 | ||
4356 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" | |
22e05272 | 4357 | if test "x$ac_cv_header_minix_config_h" = xyes; then : |
f50f17e6 | 4358 | MINIX=yes |
24f2cabb | 4359 | else |
f50f17e6 | 4360 | MINIX= |
24f2cabb L |
4361 | fi |
4362 | ||
4363 | ||
f50f17e6 | 4364 | if test "$MINIX" = yes; then |
24f2cabb | 4365 | |
f50f17e6 YJ |
4366 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h |
4367 | ||
4368 | ||
4369 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h | |
4370 | ||
4371 | ||
4372 | $as_echo "#define _MINIX 1" >>confdefs.h | |
4373 | ||
4374 | fi | |
4375 | ||
4376 | ||
4377 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 | |
4378 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } | |
22e05272 | 4379 | if ${ac_cv_safe_to_define___extensions__+:} false; then : |
5213506e | 4380 | $as_echo_n "(cached) " >&6 |
207db768 | 4381 | else |
5213506e | 4382 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ad49d865 L |
4383 | /* end confdefs.h. */ |
4384 | ||
22e05272 JM |
4385 | # define __EXTENSIONS__ 1 |
4386 | $ac_includes_default | |
ad49d865 L |
4387 | int |
4388 | main () | |
4389 | { | |
ad49d865 L |
4390 | |
4391 | ; | |
4392 | return 0; | |
4393 | } | |
4394 | _ACEOF | |
5213506e | 4395 | if ac_fn_c_try_compile "$LINENO"; then : |
f50f17e6 | 4396 | ac_cv_safe_to_define___extensions__=yes |
207db768 | 4397 | else |
f50f17e6 | 4398 | ac_cv_safe_to_define___extensions__=no |
207db768 | 4399 | fi |
5213506e | 4400 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
207db768 | 4401 | fi |
f50f17e6 YJ |
4402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
4403 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } | |
4404 | test $ac_cv_safe_to_define___extensions__ = yes && | |
4405 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h | |
4406 | ||
4407 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h | |
4408 | ||
4409 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h | |
4410 | ||
4411 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h | |
4412 | ||
4413 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
4414 | ||
ad49d865 | 4415 | |
207db768 | 4416 | |
f50f17e6 YJ |
4417 | # Check whether --enable-largefile was given. |
4418 | if test "${enable_largefile+set}" = set; then : | |
4419 | enableval=$enable_largefile; | |
207db768 | 4420 | fi |
ad49d865 | 4421 | |
f50f17e6 YJ |
4422 | if test "$enable_largefile" != no; then |
4423 | ||
4424 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 | |
4425 | $as_echo_n "checking for special C compiler options needed for large files... " >&6; } | |
22e05272 | 4426 | if ${ac_cv_sys_largefile_CC+:} false; then : |
5213506e | 4427 | $as_echo_n "(cached) " >&6 |
207db768 | 4428 | else |
f50f17e6 YJ |
4429 | ac_cv_sys_largefile_CC=no |
4430 | if test "$GCC" != yes; then | |
4431 | ac_save_CC=$CC | |
4432 | while :; do | |
4433 | # IRIX 6.2 and later do not support large files by default, | |
4434 | # so use the C compiler's -n32 option if that helps. | |
4435 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4436 | /* end confdefs.h. */ | |
4437 | #include <sys/types.h> | |
4438 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4439 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4440 | since some C++ compilers masquerading as C compilers | |
4441 | incorrectly reject 9223372036854775807. */ | |
fbb334a6 | 4442 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
f50f17e6 YJ |
4443 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
4444 | && LARGE_OFF_T % 2147483647 == 1) | |
4445 | ? 1 : -1]; | |
4446 | int | |
4447 | main () | |
4448 | { | |
4449 | ||
4450 | ; | |
4451 | return 0; | |
4452 | } | |
4453 | _ACEOF | |
4454 | if ac_fn_c_try_compile "$LINENO"; then : | |
4455 | break | |
4456 | fi | |
4457 | rm -f core conftest.err conftest.$ac_objext | |
4458 | CC="$CC -n32" | |
4459 | if ac_fn_c_try_compile "$LINENO"; then : | |
4460 | ac_cv_sys_largefile_CC=' -n32'; break | |
4461 | fi | |
4462 | rm -f core conftest.err conftest.$ac_objext | |
4463 | break | |
4464 | done | |
4465 | CC=$ac_save_CC | |
4466 | rm -f conftest.$ac_ext | |
4467 | fi | |
4468 | fi | |
4469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5 | |
4470 | $as_echo "$ac_cv_sys_largefile_CC" >&6; } | |
4471 | if test "$ac_cv_sys_largefile_CC" != no; then | |
4472 | CC=$CC$ac_cv_sys_largefile_CC | |
4473 | fi | |
4474 | ||
4475 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 | |
4476 | $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } | |
22e05272 | 4477 | if ${ac_cv_sys_file_offset_bits+:} false; then : |
f50f17e6 YJ |
4478 | $as_echo_n "(cached) " >&6 |
4479 | else | |
4480 | while :; do | |
5213506e | 4481 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ad49d865 | 4482 | /* end confdefs.h. */ |
f50f17e6 YJ |
4483 | #include <sys/types.h> |
4484 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4485 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4486 | since some C++ compilers masquerading as C compilers | |
4487 | incorrectly reject 9223372036854775807. */ | |
fbb334a6 | 4488 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
f50f17e6 YJ |
4489 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
4490 | && LARGE_OFF_T % 2147483647 == 1) | |
4491 | ? 1 : -1]; | |
4492 | int | |
4493 | main () | |
4494 | { | |
238235ef | 4495 | |
f50f17e6 YJ |
4496 | ; |
4497 | return 0; | |
4498 | } | |
ad49d865 | 4499 | _ACEOF |
5213506e | 4500 | if ac_fn_c_try_compile "$LINENO"; then : |
f50f17e6 | 4501 | ac_cv_sys_file_offset_bits=no; break |
207db768 | 4502 | fi |
5213506e | 4503 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f50f17e6 YJ |
4504 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
4505 | /* end confdefs.h. */ | |
4506 | #define _FILE_OFFSET_BITS 64 | |
4507 | #include <sys/types.h> | |
4508 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4509 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4510 | since some C++ compilers masquerading as C compilers | |
4511 | incorrectly reject 9223372036854775807. */ | |
fbb334a6 | 4512 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
f50f17e6 YJ |
4513 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
4514 | && LARGE_OFF_T % 2147483647 == 1) | |
4515 | ? 1 : -1]; | |
4516 | int | |
4517 | main () | |
4518 | { | |
ad49d865 | 4519 | |
f50f17e6 YJ |
4520 | ; |
4521 | return 0; | |
4522 | } | |
4523 | _ACEOF | |
4524 | if ac_fn_c_try_compile "$LINENO"; then : | |
4525 | ac_cv_sys_file_offset_bits=64; break | |
207db768 | 4526 | fi |
f50f17e6 YJ |
4527 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4528 | ac_cv_sys_file_offset_bits=unknown | |
4529 | break | |
4530 | done | |
4531 | fi | |
4532 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5 | |
4533 | $as_echo "$ac_cv_sys_file_offset_bits" >&6; } | |
4534 | case $ac_cv_sys_file_offset_bits in #( | |
4535 | no | unknown) ;; | |
4536 | *) | |
4537 | cat >>confdefs.h <<_ACEOF | |
4538 | #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits | |
ad49d865 | 4539 | _ACEOF |
f50f17e6 | 4540 | ;; |
ad49d865 | 4541 | esac |
f50f17e6 YJ |
4542 | rm -rf conftest* |
4543 | if test $ac_cv_sys_file_offset_bits = unknown; then | |
4544 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 | |
4545 | $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } | |
22e05272 | 4546 | if ${ac_cv_sys_large_files+:} false; then : |
f50f17e6 YJ |
4547 | $as_echo_n "(cached) " >&6 |
4548 | else | |
4549 | while :; do | |
4550 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4551 | /* end confdefs.h. */ | |
4552 | #include <sys/types.h> | |
4553 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4554 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4555 | since some C++ compilers masquerading as C compilers | |
4556 | incorrectly reject 9223372036854775807. */ | |
fbb334a6 | 4557 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
f50f17e6 YJ |
4558 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
4559 | && LARGE_OFF_T % 2147483647 == 1) | |
4560 | ? 1 : -1]; | |
4561 | int | |
4562 | main () | |
4563 | { | |
207db768 | 4564 | |
f50f17e6 YJ |
4565 | ; |
4566 | return 0; | |
4567 | } | |
4568 | _ACEOF | |
4569 | if ac_fn_c_try_compile "$LINENO"; then : | |
4570 | ac_cv_sys_large_files=no; break | |
4571 | fi | |
4572 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4573 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4574 | /* end confdefs.h. */ | |
4575 | #define _LARGE_FILES 1 | |
4576 | #include <sys/types.h> | |
4577 | /* Check that off_t can represent 2**63 - 1 correctly. | |
4578 | We can't simply define LARGE_OFF_T to be 9223372036854775807, | |
4579 | since some C++ compilers masquerading as C compilers | |
4580 | incorrectly reject 9223372036854775807. */ | |
fbb334a6 | 4581 | #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62)) |
f50f17e6 YJ |
4582 | int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721 |
4583 | && LARGE_OFF_T % 2147483647 == 1) | |
4584 | ? 1 : -1]; | |
4585 | int | |
4586 | main () | |
4587 | { | |
5213506e | 4588 | |
f50f17e6 YJ |
4589 | ; |
4590 | return 0; | |
4591 | } | |
4592 | _ACEOF | |
4593 | if ac_fn_c_try_compile "$LINENO"; then : | |
4594 | ac_cv_sys_large_files=1; break | |
4595 | fi | |
4596 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4597 | ac_cv_sys_large_files=unknown | |
4598 | break | |
4599 | done | |
4600 | fi | |
4601 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5 | |
4602 | $as_echo "$ac_cv_sys_large_files" >&6; } | |
4603 | case $ac_cv_sys_large_files in #( | |
4604 | no | unknown) ;; | |
4605 | *) | |
4606 | cat >>confdefs.h <<_ACEOF | |
4607 | #define _LARGE_FILES $ac_cv_sys_large_files | |
4608 | _ACEOF | |
4609 | ;; | |
4610 | esac | |
4611 | rm -rf conftest* | |
4612 | fi | |
22e05272 JM |
4613 | |
4614 | ||
f50f17e6 YJ |
4615 | fi |
4616 | ||
4617 | ||
4618 | ac_c_preproc_warn_flag=yes | |
4619 | ||
126e0b6b AM |
4620 | ac_ext=c |
4621 | ac_cpp='$CPP $CPPFLAGS' | |
4622 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4623 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4624 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4625 | ||
f50f17e6 YJ |
4626 | ac_libiberty_warn_cflags= |
4627 | save_CFLAGS="$CFLAGS" | |
4628 | for real_option in -W -Wall -Wwrite-strings -Wc++-compat \ | |
3eb89071 MW |
4629 | -Wstrict-prototypes \ |
4630 | -Wshadow=local; do | |
f50f17e6 YJ |
4631 | # Do the check with the no- prefix removed since gcc silently |
4632 | # accepts any -Wno-* option on purpose | |
4633 | case $real_option in | |
4634 | -Wno-*) option=-W`expr x$real_option : 'x-Wno-\(.*\)'` ;; | |
4635 | *) option=$real_option ;; | |
4636 | esac | |
4637 | as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh` | |
4638 | ||
4639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5 | |
4640 | $as_echo_n "checking whether $CC supports $option... " >&6; } | |
22e05272 | 4641 | if eval \${$as_acx_Woption+:} false; then : |
5213506e | 4642 | $as_echo_n "(cached) " >&6 |
207db768 | 4643 | else |
f50f17e6 YJ |
4644 | CFLAGS="$option" |
4645 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4646 | /* end confdefs.h. */ | |
5213506e | 4647 | |
f50f17e6 YJ |
4648 | int |
4649 | main () | |
4650 | { | |
4651 | ||
4652 | ; | |
4653 | return 0; | |
4654 | } | |
4655 | _ACEOF | |
4656 | if ac_fn_c_try_compile "$LINENO"; then : | |
4657 | eval "$as_acx_Woption=yes" | |
4658 | else | |
4659 | eval "$as_acx_Woption=no" | |
4660 | fi | |
4661 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4662 | ||
4663 | fi | |
4664 | eval ac_res=\$$as_acx_Woption | |
4665 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
4666 | $as_echo "$ac_res" >&6; } | |
4667 | if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then : | |
4668 | ac_libiberty_warn_cflags="$ac_libiberty_warn_cflags${ac_libiberty_warn_cflags:+ }$real_option" | |
4669 | fi | |
5213506e | 4670 | done |
f50f17e6 | 4671 | CFLAGS="$save_CFLAGS" |
126e0b6b AM |
4672 | ac_ext=c |
4673 | ac_cpp='$CPP $CPPFLAGS' | |
4674 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4675 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4676 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4677 | ||
4678 | ||
4679 | ac_ext=c | |
4680 | ac_cpp='$CPP $CPPFLAGS' | |
4681 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4682 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4683 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
f50f17e6 YJ |
4684 | |
4685 | # Do the check with the no- prefix removed from the warning options | |
4686 | # since gcc silently accepts any -Wno-* option on purpose | |
4687 | if test "$GCC" = yes; then : | |
4688 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pedantic " >&5 | |
4689 | $as_echo_n "checking whether $CC supports -pedantic ... " >&6; } | |
22e05272 | 4690 | if ${acx_cv_prog_cc_pedantic_+:} false; then : |
f50f17e6 | 4691 | $as_echo_n "(cached) " >&6 |
5213506e | 4692 | else |
f50f17e6 YJ |
4693 | save_CFLAGS="$CFLAGS" |
4694 | CFLAGS="-pedantic " | |
4695 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4696 | /* end confdefs.h. */ | |
4697 | ||
4698 | int | |
4699 | main () | |
4700 | { | |
4701 | ||
4702 | ; | |
4703 | return 0; | |
4704 | } | |
4705 | _ACEOF | |
4706 | if ac_fn_c_try_compile "$LINENO"; then : | |
4707 | acx_cv_prog_cc_pedantic_=yes | |
4708 | else | |
4709 | acx_cv_prog_cc_pedantic_=no | |
4710 | fi | |
4711 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4712 | CFLAGS="$save_CFLAGS" | |
4713 | fi | |
4714 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_prog_cc_pedantic_" >&5 | |
4715 | $as_echo "$acx_cv_prog_cc_pedantic_" >&6; } | |
4716 | if test $acx_cv_prog_cc_pedantic_ = yes; then : | |
4717 | ac_libiberty_warn_cflags="$ac_libiberty_warn_cflags${ac_libiberty_warn_cflags:+ }-pedantic " | |
5213506e RW |
4718 | fi |
4719 | ||
4720 | fi | |
126e0b6b AM |
4721 | ac_ext=c |
4722 | ac_cpp='$CPP $CPPFLAGS' | |
4723 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4724 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4725 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4726 | ||
5213506e RW |
4727 | |
4728 | ||
f50f17e6 YJ |
4729 | if test "x$CC" != xcc; then |
4730 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 | |
4731 | $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } | |
4732 | else | |
4733 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 | |
4734 | $as_echo_n "checking whether cc understands -c and -o together... " >&6; } | |
4735 | fi | |
4736 | set dummy $CC; ac_cc=`$as_echo "$2" | | |
4737 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` | |
22e05272 | 4738 | if eval \${ac_cv_prog_cc_${ac_cc}_c_o+:} false; then : |
5213506e RW |
4739 | $as_echo_n "(cached) " >&6 |
4740 | else | |
f50f17e6 YJ |
4741 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
4742 | /* end confdefs.h. */ | |
4743 | ||
4744 | int | |
4745 | main () | |
4746 | { | |
4747 | ||
4748 | ; | |
4749 | return 0; | |
4750 | } | |
4751 | _ACEOF | |
4752 | # Make sure it works both with $CC and with simple cc. | |
4753 | # We do the test twice because some compilers refuse to overwrite an | |
4754 | # existing .o file with -o, though they will create one. | |
4755 | ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
4756 | rm -f conftest2.* | |
4757 | if { { case "(($ac_try" in | |
4758 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4759 | *) ac_try_echo=$ac_try;; | |
4760 | esac | |
4761 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4762 | $as_echo "$ac_try_echo"; } >&5 | |
4763 | (eval "$ac_try") 2>&5 | |
4764 | ac_status=$? | |
4765 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4766 | test $ac_status = 0; } && | |
4767 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
4768 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4769 | *) ac_try_echo=$ac_try;; | |
4770 | esac | |
4771 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4772 | $as_echo "$ac_try_echo"; } >&5 | |
4773 | (eval "$ac_try") 2>&5 | |
4774 | ac_status=$? | |
4775 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4776 | test $ac_status = 0; }; | |
4777 | then | |
4778 | eval ac_cv_prog_cc_${ac_cc}_c_o=yes | |
4779 | if test "x$CC" != xcc; then | |
4780 | # Test first that cc exists at all. | |
4781 | if { ac_try='cc -c conftest.$ac_ext >&5' | |
4782 | { { case "(($ac_try" in | |
4783 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4784 | *) ac_try_echo=$ac_try;; | |
5213506e | 4785 | esac |
f50f17e6 YJ |
4786 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
4787 | $as_echo "$ac_try_echo"; } >&5 | |
4788 | (eval "$ac_try") 2>&5 | |
4789 | ac_status=$? | |
4790 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4791 | test $ac_status = 0; }; }; then | |
4792 | ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
4793 | rm -f conftest2.* | |
4794 | if { { case "(($ac_try" in | |
4795 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4796 | *) ac_try_echo=$ac_try;; | |
4797 | esac | |
4798 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4799 | $as_echo "$ac_try_echo"; } >&5 | |
4800 | (eval "$ac_try") 2>&5 | |
4801 | ac_status=$? | |
4802 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4803 | test $ac_status = 0; } && | |
4804 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
4805 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4806 | *) ac_try_echo=$ac_try;; | |
4807 | esac | |
4808 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4809 | $as_echo "$ac_try_echo"; } >&5 | |
4810 | (eval "$ac_try") 2>&5 | |
4811 | ac_status=$? | |
4812 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4813 | test $ac_status = 0; }; | |
4814 | then | |
4815 | # cc works too. | |
4816 | : | |
4817 | else | |
4818 | # cc exists but doesn't like -o. | |
4819 | eval ac_cv_prog_cc_${ac_cc}_c_o=no | |
4820 | fi | |
4821 | fi | |
5213506e RW |
4822 | fi |
4823 | else | |
f50f17e6 | 4824 | eval ac_cv_prog_cc_${ac_cc}_c_o=no |
5213506e | 4825 | fi |
f50f17e6 | 4826 | rm -f core conftest* |
5213506e | 4827 | |
5213506e | 4828 | fi |
f50f17e6 YJ |
4829 | if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then |
4830 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
4831 | $as_echo "yes" >&6; } | |
4832 | else | |
4833 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4834 | $as_echo "no" >&6; } | |
4835 | ||
4836 | $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h | |
5213506e | 4837 | |
f50f17e6 | 4838 | fi |
5213506e | 4839 | |
f50f17e6 YJ |
4840 | # autoconf is lame and doesn't give us any substitution variable for this. |
4841 | if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then | |
4842 | NO_MINUS_C_MINUS_O=yes | |
4843 | else | |
4844 | OUTPUT_OPTION='-o $@' | |
4845 | fi | |
4846 | ||
4847 | ||
4848 | ||
4849 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for an ANSI C-conforming const" >&5 | |
4850 | $as_echo_n "checking for an ANSI C-conforming const... " >&6; } | |
22e05272 | 4851 | if ${ac_cv_c_const+:} false; then : |
5213506e RW |
4852 | $as_echo_n "(cached) " >&6 |
4853 | else | |
4854 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ad49d865 | 4855 | /* end confdefs.h. */ |
fbc1bc09 | 4856 | |
ad49d865 L |
4857 | int |
4858 | main () | |
4859 | { | |
22e05272 | 4860 | |
f50f17e6 | 4861 | #ifndef __cplusplus |
22e05272 | 4862 | /* Ultrix mips cc rejects this sort of thing. */ |
f50f17e6 | 4863 | typedef int charset[2]; |
22e05272 | 4864 | const charset cs = { 0, 0 }; |
f50f17e6 YJ |
4865 | /* SunOS 4.1.1 cc rejects this. */ |
4866 | char const *const *pcpcc; | |
4867 | char **ppc; | |
4868 | /* NEC SVR4.0.2 mips cc rejects this. */ | |
4869 | struct point {int x, y;}; | |
4870 | static struct point const zero = {0,0}; | |
4871 | /* AIX XL C 1.02.0.0 rejects this. | |
4872 | It does not let you subtract one const X* pointer from another in | |
4873 | an arm of an if-expression whose if-part is not a constant | |
4874 | expression */ | |
4875 | const char *g = "string"; | |
4876 | pcpcc = &g + (g ? g-g : 0); | |
4877 | /* HPUX 7.0 cc rejects these. */ | |
4878 | ++pcpcc; | |
4879 | ppc = (char**) pcpcc; | |
4880 | pcpcc = (char const *const *) ppc; | |
22e05272 JM |
4881 | { /* SCO 3.2v4 cc rejects this sort of thing. */ |
4882 | char tx; | |
4883 | char *t = &tx; | |
f50f17e6 YJ |
4884 | char const *s = 0 ? (char *) 0 : (char const *) 0; |
4885 | ||
4886 | *t++ = 0; | |
4887 | if (s) return 0; | |
4888 | } | |
4889 | { /* Someone thinks the Sun supposedly-ANSI compiler will reject this. */ | |
4890 | int x[] = {25, 17}; | |
4891 | const int *foo = &x[0]; | |
4892 | ++foo; | |
4893 | } | |
4894 | { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */ | |
4895 | typedef const int *iptr; | |
4896 | iptr p = 0; | |
4897 | ++p; | |
4898 | } | |
22e05272 | 4899 | { /* AIX XL C 1.02.0.0 rejects this sort of thing, saying |
f50f17e6 | 4900 | "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */ |
22e05272 JM |
4901 | struct s { int j; const int *ap[3]; } bx; |
4902 | struct s *b = &bx; b->j = 5; | |
f50f17e6 YJ |
4903 | } |
4904 | { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */ | |
4905 | const int foo = 10; | |
4906 | if (!foo) return 0; | |
4907 | } | |
4908 | return !cs[0] && !zero.x; | |
4909 | #endif | |
fbc1bc09 | 4910 | |
ad49d865 L |
4911 | ; |
4912 | return 0; | |
4913 | } | |
4914 | _ACEOF | |
5213506e | 4915 | if ac_fn_c_try_compile "$LINENO"; then : |
f50f17e6 | 4916 | ac_cv_c_const=yes |
5213506e | 4917 | else |
f50f17e6 | 4918 | ac_cv_c_const=no |
5213506e RW |
4919 | fi |
4920 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5213506e | 4921 | fi |
f50f17e6 YJ |
4922 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_const" >&5 |
4923 | $as_echo "$ac_cv_c_const" >&6; } | |
4924 | if test $ac_cv_c_const = no; then | |
5213506e | 4925 | |
f50f17e6 | 4926 | $as_echo "#define const /**/" >>confdefs.h |
5213506e RW |
4927 | |
4928 | fi | |
4929 | ||
f50f17e6 YJ |
4930 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 |
4931 | $as_echo_n "checking for inline... " >&6; } | |
22e05272 | 4932 | if ${ac_cv_c_inline+:} false; then : |
f50f17e6 | 4933 | $as_echo_n "(cached) " >&6 |
5213506e | 4934 | else |
f50f17e6 YJ |
4935 | ac_cv_c_inline=no |
4936 | for ac_kw in inline __inline__ __inline; do | |
5213506e RW |
4937 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
4938 | /* end confdefs.h. */ | |
f50f17e6 YJ |
4939 | #ifndef __cplusplus |
4940 | typedef int foo_t; | |
4941 | static $ac_kw foo_t static_foo () {return 0; } | |
4942 | $ac_kw foo_t foo () {return 0; } | |
24f2cabb | 4943 | #endif |
fbc1bc09 | 4944 | |
238235ef | 4945 | _ACEOF |
f50f17e6 YJ |
4946 | if ac_fn_c_try_compile "$LINENO"; then : |
4947 | ac_cv_c_inline=$ac_kw | |
5213506e | 4948 | fi |
f50f17e6 YJ |
4949 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4950 | test "$ac_cv_c_inline" != no && break | |
4951 | done | |
5213506e RW |
4952 | |
4953 | fi | |
f50f17e6 YJ |
4954 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 |
4955 | $as_echo "$ac_cv_c_inline" >&6; } | |
5213506e | 4956 | |
f50f17e6 YJ |
4957 | case $ac_cv_c_inline in |
4958 | inline | yes) ;; | |
4959 | *) | |
4960 | case $ac_cv_c_inline in | |
4961 | no) ac_val=;; | |
4962 | *) ac_val=$ac_cv_c_inline;; | |
4963 | esac | |
4964 | cat >>confdefs.h <<_ACEOF | |
4965 | #ifndef __cplusplus | |
4966 | #define inline $ac_val | |
4967 | #endif | |
5213506e | 4968 | _ACEOF |
f50f17e6 YJ |
4969 | ;; |
4970 | esac | |
5213506e RW |
4971 | |
4972 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 | |
4973 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } | |
22e05272 | 4974 | if ${ac_cv_c_bigendian+:} false; then : |
5213506e RW |
4975 | $as_echo_n "(cached) " >&6 |
4976 | else | |
fbc1bc09 | 4977 | ac_cv_c_bigendian=unknown |
5213506e RW |
4978 | # See if we're dealing with a universal compiler. |
4979 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4980 | /* end confdefs.h. */ | |
4981 | #ifndef __APPLE_CC__ | |
4982 | not a universal capable compiler | |
4983 | #endif | |
4984 | typedef int dummy; | |
4985 | ||
4986 | _ACEOF | |
4987 | if ac_fn_c_try_compile "$LINENO"; then : | |
4988 | ||
4989 | # Check for potential -arch flags. It is not universal unless | |
4990 | # there are at least two -arch flags with different values. | |
4991 | ac_arch= | |
4992 | ac_prev= | |
4993 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
4994 | if test -n "$ac_prev"; then | |
4995 | case $ac_word in | |
4996 | i?86 | x86_64 | ppc | ppc64) | |
4997 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
4998 | ac_arch=$ac_word | |
4999 | else | |
5000 | ac_cv_c_bigendian=universal | |
5001 | break | |
5002 | fi | |
5003 | ;; | |
5004 | esac | |
5005 | ac_prev= | |
5006 | elif test "x$ac_word" = "x-arch"; then | |
5007 | ac_prev=arch | |
5008 | fi | |
5009 | done | |
5010 | fi | |
5011 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5012 | if test $ac_cv_c_bigendian = unknown; then | |
5013 | # See if sys/param.h defines the BYTE_ORDER macro. | |
5014 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5015 | /* end confdefs.h. */ | |
5016 | #include <sys/types.h> | |
5017 | #include <sys/param.h> | |
5018 | ||
5019 | int | |
5020 | main () | |
5021 | { | |
5022 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ | |
5023 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
5024 | && LITTLE_ENDIAN) | |
5025 | bogus endian macros | |
5026 | #endif | |
5027 | ||
5028 | ; | |
5029 | return 0; | |
5030 | } | |
fbc1bc09 | 5031 | _ACEOF |
5213506e RW |
5032 | if ac_fn_c_try_compile "$LINENO"; then : |
5033 | # It does; now see whether it defined to BIG_ENDIAN or not. | |
5034 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
fbc1bc09 | 5035 | /* end confdefs.h. */ |
5213506e RW |
5036 | #include <sys/types.h> |
5037 | #include <sys/param.h> | |
5038 | ||
fbc1bc09 KC |
5039 | int |
5040 | main () | |
5041 | { | |
5213506e RW |
5042 | #if BYTE_ORDER != BIG_ENDIAN |
5043 | not big endian | |
5044 | #endif | |
5045 | ||
fbc1bc09 KC |
5046 | ; |
5047 | return 0; | |
5048 | } | |
5049 | _ACEOF | |
5213506e | 5050 | if ac_fn_c_try_compile "$LINENO"; then : |
fbc1bc09 | 5051 | ac_cv_c_bigendian=yes |
5213506e RW |
5052 | else |
5053 | ac_cv_c_bigendian=no | |
fbc1bc09 | 5054 | fi |
5213506e | 5055 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
fbc1bc09 | 5056 | fi |
5213506e RW |
5057 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5058 | fi | |
5059 | if test $ac_cv_c_bigendian = unknown; then | |
5060 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
5061 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5062 | /* end confdefs.h. */ | |
5063 | #include <limits.h> | |
fbc1bc09 | 5064 | |
5213506e RW |
5065 | int |
5066 | main () | |
5067 | { | |
5068 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) | |
5069 | bogus endian macros | |
5070 | #endif | |
5071 | ||
5072 | ; | |
5073 | return 0; | |
5074 | } | |
24f2cabb | 5075 | _ACEOF |
5213506e RW |
5076 | if ac_fn_c_try_compile "$LINENO"; then : |
5077 | # It does; now see whether it defined to _BIG_ENDIAN or not. | |
5078 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
24f2cabb | 5079 | /* end confdefs.h. */ |
5213506e RW |
5080 | #include <limits.h> |
5081 | ||
fbc1bc09 KC |
5082 | int |
5083 | main () | |
5084 | { | |
5213506e RW |
5085 | #ifndef _BIG_ENDIAN |
5086 | not big endian | |
5087 | #endif | |
5088 | ||
5089 | ; | |
5090 | return 0; | |
24f2cabb | 5091 | } |
238235ef | 5092 | _ACEOF |
5213506e RW |
5093 | if ac_fn_c_try_compile "$LINENO"; then : |
5094 | ac_cv_c_bigendian=yes | |
24f2cabb | 5095 | else |
5213506e | 5096 | ac_cv_c_bigendian=no |
5cc5a0d0 | 5097 | fi |
5213506e | 5098 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
24f2cabb | 5099 | fi |
5213506e RW |
5100 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
5101 | fi | |
5102 | if test $ac_cv_c_bigendian = unknown; then | |
5103 | # Compile a test program. | |
5104 | if test "$cross_compiling" = yes; then : | |
5105 | # Try to guess by grepping values from an object file. | |
5106 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5107 | /* end confdefs.h. */ | |
5108 | short int ascii_mm[] = | |
5109 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
5110 | short int ascii_ii[] = | |
5111 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
5112 | int use_ascii (int i) { | |
5113 | return ascii_mm[i] + ascii_ii[i]; | |
5114 | } | |
5115 | short int ebcdic_ii[] = | |
5116 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
5117 | short int ebcdic_mm[] = | |
5118 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
5119 | int use_ebcdic (int i) { | |
5120 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
5121 | } | |
5122 | extern int foo; | |
5123 | ||
5124 | int | |
5125 | main () | |
5126 | { | |
5127 | return use_ascii (foo) == use_ebcdic (foo); | |
5128 | ; | |
5129 | return 0; | |
5130 | } | |
5131 | _ACEOF | |
5132 | if ac_fn_c_try_compile "$LINENO"; then : | |
5133 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then | |
5134 | ac_cv_c_bigendian=yes | |
5135 | fi | |
5136 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
5137 | if test "$ac_cv_c_bigendian" = unknown; then | |
5138 | ac_cv_c_bigendian=no | |
5139 | else | |
5140 | # finding both strings is unlikely to happen, but who knows? | |
5141 | ac_cv_c_bigendian=unknown | |
5142 | fi | |
5143 | fi | |
5144 | fi | |
5145 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5146 | else | |
5147 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5148 | /* end confdefs.h. */ | |
5149 | $ac_includes_default | |
5150 | int | |
5151 | main () | |
5152 | { | |
5153 | ||
5154 | /* Are we little or big endian? From Harbison&Steele. */ | |
5155 | union | |
5156 | { | |
5157 | long int l; | |
5158 | char c[sizeof (long int)]; | |
5159 | } u; | |
5160 | u.l = 1; | |
5161 | return u.c[sizeof (long int) - 1] == 1; | |
5162 | ||
5163 | ; | |
5164 | return 0; | |
5165 | } | |
5166 | _ACEOF | |
5167 | if ac_fn_c_try_run "$LINENO"; then : | |
5168 | ac_cv_c_bigendian=no | |
5169 | else | |
5170 | ac_cv_c_bigendian=yes | |
24f2cabb | 5171 | fi |
5213506e RW |
5172 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
5173 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
24f2cabb | 5174 | fi |
238235ef | 5175 | |
5213506e RW |
5176 | fi |
5177 | fi | |
5178 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 | |
5179 | $as_echo "$ac_cv_c_bigendian" >&6; } | |
5180 | case $ac_cv_c_bigendian in #( | |
5181 | yes) | |
5182 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h | |
5183 | ;; #( | |
5184 | no) | |
5185 | ;; #( | |
5186 | universal) | |
5187 | ||
5188 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h | |
5189 | ||
5190 | ;; #( | |
5191 | *) | |
22e05272 | 5192 | as_fn_error $? "unknown endianness |
5213506e RW |
5193 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; |
5194 | esac | |
5cc5a0d0 | 5195 | |
0bc0cd11 JL |
5196 | |
5197 | ||
5198 | ||
5213506e | 5199 | ac_config_headers="$ac_config_headers config.h:config.in" |
0bc0cd11 JL |
5200 | |
5201 | ||
5202 | ||
5203 | # Find a good install program. We prefer a C program (faster), | |
5204 | # so one script is as good as another. But avoid the broken or | |
5205 | # incompatible versions: | |
5206 | # SysV /etc/install, /usr/sbin/install | |
5207 | # SunOS /usr/etc/install | |
5208 | # IRIX /sbin/install | |
5209 | # AIX /bin/install | |
238235ef | 5210 | # AmigaOS /C/install, which installs bootblocks on floppy discs |
0bc0cd11 JL |
5211 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag |
5212 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
5213 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
3beb1315 | 5214 | # OS/2's system install, which has a completely different semantic |
0bc0cd11 | 5215 | # ./install, which can be erroneously created by make from ./install.sh. |
5213506e RW |
5216 | # Reject install programs that cannot install multiple files. |
5217 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 | |
5218 | $as_echo_n "checking for a BSD-compatible install... " >&6; } | |
0bc0cd11 | 5219 | if test -z "$INSTALL"; then |
22e05272 | 5220 | if ${ac_cv_path_install+:} false; then : |
5213506e | 5221 | $as_echo_n "(cached) " >&6 |
238235ef DJ |
5222 | else |
5223 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5224 | for as_dir in $PATH | |
5225 | do | |
5226 | IFS=$as_save_IFS | |
5227 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
5228 | # Account for people who put trailing slashes in PATH elements. |
5229 | case $as_dir/ in #(( | |
5230 | ./ | .// | /[cC]/* | \ | |
238235ef | 5231 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ |
5213506e | 5232 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ |
238235ef DJ |
5233 | /usr/ucb/* ) ;; |
5234 | *) | |
5235 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
5236 | # Don't use installbsd from OSF since it installs stuff as root | |
5237 | # by default. | |
5238 | for ac_prog in ginstall scoinst install; do | |
5239 | for ac_exec_ext in '' $ac_executable_extensions; do | |
22e05272 | 5240 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then |
3beb1315 HPN |
5241 | if test $ac_prog = install && |
5242 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5243 | # AIX install. It has an incompatible calling convention. | |
5244 | : | |
5245 | elif test $ac_prog = install && | |
5246 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | |
5247 | # program-specific install script used by HP pwplus--don't use. | |
5248 | : | |
5249 | else | |
5213506e RW |
5250 | rm -rf conftest.one conftest.two conftest.dir |
5251 | echo one > conftest.one | |
5252 | echo two > conftest.two | |
5253 | mkdir conftest.dir | |
5254 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | |
5255 | test -s conftest.one && test -s conftest.two && | |
5256 | test -s conftest.dir/conftest.one && | |
5257 | test -s conftest.dir/conftest.two | |
5258 | then | |
5259 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | |
5260 | break 3 | |
5261 | fi | |
3beb1315 HPN |
5262 | fi |
5263 | fi | |
0bc0cd11 | 5264 | done |
238235ef DJ |
5265 | done |
5266 | ;; | |
5267 | esac | |
238235ef | 5268 | |
5213506e RW |
5269 | done |
5270 | IFS=$as_save_IFS | |
5271 | ||
5272 | rm -rf conftest.one conftest.two conftest.dir | |
0bc0cd11 JL |
5273 | |
5274 | fi | |
5275 | if test "${ac_cv_path_install+set}" = set; then | |
238235ef | 5276 | INSTALL=$ac_cv_path_install |
0bc0cd11 | 5277 | else |
5213506e RW |
5278 | # As a last resort, use the slow shell script. Don't cache a |
5279 | # value for INSTALL within a source directory, because that will | |
0bc0cd11 | 5280 | # break other packages using the cache if that directory is |
5213506e | 5281 | # removed, or if the value is a relative name. |
238235ef | 5282 | INSTALL=$ac_install_sh |
0bc0cd11 JL |
5283 | fi |
5284 | fi | |
5213506e RW |
5285 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
5286 | $as_echo "$INSTALL" >&6; } | |
0bc0cd11 JL |
5287 | |
5288 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
5289 | # It thinks the first close brace ends the variable substitution. | |
5290 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
5291 | ||
238235ef | 5292 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' |
687361c8 | 5293 | |
0bc0cd11 JL |
5294 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' |
5295 | ||
5296 | ||
769b009e KC |
5297 | # Don't build the shared library for build. |
5298 | if [ -n "${with_build_subdir}" ]; then | |
5299 | enable_shared=no | |
5300 | fi | |
5301 | ||
5302 | frag= | |
5303 | case "${host}" in | |
5304 | rs6000-ibm-aix3.1 | rs6000-ibm-aix) | |
5305 | frag=mh-aix ;; | |
5306 | *-*-cxux7*) frag=mh-cxux7 ;; | |
5307 | *-*-freebsd2.1.*) frag=mh-fbsd21 ;; | |
5308 | *-*-freebsd2.2.[012]) frag=mh-fbsd21 ;; | |
5309 | i370-*-opened*) frag=mh-openedition ;; | |
5310 | i[34567]86-*-windows*) frag=mh-windows ;; | |
5311 | esac | |
5312 | ||
5313 | if [ -n "${frag}" ]; then | |
c91c9c2e | 5314 | frag=${libiberty_topdir}/libiberty/config/$frag |
769b009e KC |
5315 | fi |
5316 | ||
e3aa9eba RO |
5317 | |
5318 | ||
5319 | ||
5320 | ||
5321 | case "${host}" in | |
5322 | # PIC is the default on some targets or must not be used. | |
5323 | *-*-darwin*) | |
cacf1f59 JJ |
5324 | # For darwin, common symbols are not allowed in MH_DYLIB files |
5325 | case "${CFLAGS}" in | |
5326 | # If we are using a compiler supporting mdynamic-no-pic | |
5327 | # and the option has been tested as safe to add, then cancel | |
5328 | # it here, since the code generated is incompatible with shared | |
8f56cb51 | 5329 | # libs. |
cacf1f59 JJ |
5330 | *-mdynamic-no-pic*) PICFLAG='-fno-common -mno-dynamic-no-pic' ;; |
5331 | *) PICFLAG=-fno-common ;; | |
5332 | esac | |
e3aa9eba RO |
5333 | ;; |
5334 | alpha*-dec-osf5*) | |
5335 | # PIC is the default. | |
5336 | ;; | |
5337 | hppa*64*-*-hpux*) | |
5338 | # PIC is the default for 64-bit PA HP-UX. | |
5339 | ;; | |
071928d9 KT |
5340 | i[34567]86-*-cygwin* | x86_64-*-cygwin*) |
5341 | ;; | |
5342 | i[34567]86-*-mingw* | x86_64-*-mingw*) | |
e3aa9eba | 5343 | ;; |
2b601678 MK |
5344 | i[34567]86-*-interix[3-9]*) |
5345 | # Interix 3.x gcc -fpic/-fPIC options generate broken code. | |
5346 | # Instead, we relocate shared libraries at runtime. | |
5347 | ;; | |
e3aa9eba RO |
5348 | i[34567]86-*-nto-qnx*) |
5349 | # QNX uses GNU C++, but need to define -shared option too, otherwise | |
5350 | # it will coredump. | |
5351 | PICFLAG='-fPIC -shared' | |
5352 | ;; | |
5353 | i[34567]86-pc-msdosdjgpp*) | |
5354 | # DJGPP does not support shared libraries at all. | |
5355 | ;; | |
5356 | ia64*-*-hpux*) | |
5357 | # On IA64 HP-UX, PIC is the default but the pic flag | |
5358 | # sets the default TLS model and affects inlining. | |
5359 | PICFLAG=-fPIC | |
5360 | ;; | |
b1a3d2b7 ML |
5361 | loongarch*-*-*) |
5362 | PICFLAG=-fpic | |
5363 | ;; | |
e3aa9eba RO |
5364 | mips-sgi-irix6*) |
5365 | # PIC is the default. | |
5366 | ;; | |
5367 | rs6000-ibm-aix* | powerpc-ibm-aix*) | |
5368 | # All AIX code is PIC. | |
5369 | ;; | |
5370 | ||
5371 | # Some targets support both -fPIC and -fpic, but prefer the latter. | |
5372 | # FIXME: Why? | |
5373 | i[34567]86-*-* | x86_64-*-*) | |
5374 | PICFLAG=-fpic | |
5375 | ;; | |
e3aa9eba RO |
5376 | # FIXME: Override -fPIC default in libgcc only? |
5377 | sh-*-linux* | sh[2346lbe]*-*-linux*) | |
5378 | PICFLAG=-fpic | |
5379 | ;; | |
9fc0ae60 | 5380 | sh*-*-netbsd*) |
e3aa9eba RO |
5381 | PICFLAG=-fpic |
5382 | ;; | |
5383 | # Default to -fPIC unless specified otherwise. | |
5384 | *) | |
5385 | PICFLAG=-fPIC | |
5386 | ;; | |
5387 | esac | |
5388 | ||
5389 | # If the user explicitly uses -fpic/-fPIC, keep that. | |
5390 | case "${CFLAGS}" in | |
5391 | *-fpic*) | |
5392 | PICFLAG=-fpic | |
5393 | ;; | |
5394 | *-fPIC*) | |
5395 | PICFLAG=-fPIC | |
5396 | ;; | |
5397 | esac | |
5398 | ||
5399 | ||
769b009e KC |
5400 | # If they didn't specify --enable-shared, don't generate shared libs. |
5401 | case "${enable_shared}" in | |
5402 | yes) shared=yes ;; | |
5403 | no) shared=no ;; | |
5404 | "") shared=no ;; | |
5405 | *) shared=yes ;; | |
5406 | esac | |
459260ec | 5407 | |
b6cb10af MP |
5408 | # ...unless --enable-host-{shared,pie} was passed from top-level config: |
5409 | if [ "${enable_host_shared}" = "yes" ] || [ "${enable_host_pie}" = "yes" ]; then | |
459260ec DM |
5410 | shared=yes |
5411 | fi | |
5412 | ||
e3aa9eba RO |
5413 | if [ "${shared}" != "yes" ]; then |
5414 | PICFLAG= | |
769b009e KC |
5415 | fi |
5416 | ||
c91c9c2e | 5417 | |
4f148bbc JJ |
5418 | NOASANFLAG= |
5419 | case " ${CFLAGS} " in | |
5420 | *\ -fsanitize=address\ *) NOASANFLAG=-fno-sanitize=address ;; | |
170e618e | 5421 | *\ -fsanitize=hwaddress\ *) NOASANFLAG=-fno-sanitize=hwaddress ;; |
4f148bbc JJ |
5422 | esac |
5423 | ||
5424 | ||
8fc8bf80 L |
5425 | # Check whether --enable-cet was given. |
5426 | if test "${enable_cet+set}" = set; then : | |
5427 | enableval=$enable_cet; | |
5428 | case "$enableval" in | |
5429 | yes|no|auto) ;; | |
5430 | *) as_fn_error $? "Unknown argument to enable/disable cet" "$LINENO" 5 ;; | |
5431 | esac | |
5432 | ||
5433 | else | |
5434 | enable_cet=auto | |
5435 | fi | |
5436 | ||
5437 | ||
5438 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CET support" >&5 | |
5439 | $as_echo_n "checking for CET support... " >&6; } | |
5440 | ||
5441 | case "$host" in | |
5442 | i[34567]86-*-linux* | x86_64-*-linux*) | |
5443 | may_have_cet=yes | |
9051b548 | 5444 | cet_save_CFLAGS="$CFLAGS" |
8fc8bf80 L |
5445 | CFLAGS="$CFLAGS -fcf-protection" |
5446 | case "$enable_cet" in | |
5447 | auto) | |
5448 | # Check if target supports multi-byte NOPs | |
4712bde3 | 5449 | # and if compiler and assembler support CET. |
8fc8bf80 L |
5450 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5451 | /* end confdefs.h. */ | |
5452 | ||
5453 | int | |
5454 | main () | |
5455 | { | |
5456 | ||
5457 | #if !defined(__SSE2__) | |
5458 | #error target does not support multi-byte NOPs | |
5459 | #else | |
5460 | asm ("setssbsy"); | |
5461 | #endif | |
5462 | ||
5463 | ; | |
5464 | return 0; | |
5465 | } | |
5466 | _ACEOF | |
5467 | if ac_fn_c_try_compile "$LINENO"; then : | |
5468 | enable_cet=yes | |
5469 | else | |
5470 | enable_cet=no | |
5471 | fi | |
5472 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5473 | ;; | |
5474 | yes) | |
4712bde3 | 5475 | # Check if compiler and assembler support CET. |
8fc8bf80 L |
5476 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5477 | /* end confdefs.h. */ | |
5478 | ||
5479 | int | |
5480 | main () | |
5481 | { | |
5482 | asm ("setssbsy"); | |
5483 | ; | |
5484 | return 0; | |
5485 | } | |
5486 | _ACEOF | |
5487 | if ac_fn_c_try_compile "$LINENO"; then : | |
4712bde3 | 5488 | support_cet=yes |
8fc8bf80 | 5489 | else |
4712bde3 | 5490 | support_cet=no |
8fc8bf80 L |
5491 | fi |
5492 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4712bde3 L |
5493 | if test $support_cet = "no"; then |
5494 | if test x$enable_bootstrap != xno \ | |
5495 | && test -z "${with_build_subdir}" \ | |
5496 | && (test ! -f ../stage_current \ | |
5497 | || test `cat ../stage_current` != "stage1"); then | |
5498 | # Require CET support only for the final GCC build. | |
5499 | as_fn_error $? "compiler and assembler with CET support are required for --enable-cet" "$LINENO" 5 | |
5500 | else | |
5501 | # Don't enable CET without CET support for non-bootstrap | |
5502 | # build, in stage1 nor for build support. | |
5503 | enable_cet=no | |
5504 | fi | |
5505 | fi | |
8fc8bf80 L |
5506 | ;; |
5507 | esac | |
9051b548 | 5508 | CFLAGS="$cet_save_CFLAGS" |
8fc8bf80 L |
5509 | ;; |
5510 | *) | |
5511 | may_have_cet=no | |
5512 | enable_cet=no | |
5513 | ;; | |
5514 | esac | |
5515 | ||
9051b548 | 5516 | cet_save_CFLAGS="$CFLAGS" |
eedc73a2 | 5517 | CFLAGS="$CFLAGS -fcf-protection=none" |
9051b548 | 5518 | cet_save_LDFLAGS="$LDFLAGS" |
eedc73a2 L |
5519 | LDFLAGS="$LDFLAGS -Wl,-z,ibt,-z,shstk" |
5520 | if test x$may_have_cet = xyes; then | |
5521 | # Check whether -fcf-protection=none -Wl,-z,ibt,-z,shstk work. | |
5522 | if test x$gcc_no_link = xyes; then | |
5523 | as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5 | |
5524 | fi | |
5525 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5526 | /* end confdefs.h. */ | |
5527 | ||
5528 | int | |
5529 | main () | |
5530 | { | |
5531 | return 0; | |
5532 | ; | |
5533 | return 0; | |
5534 | } | |
5535 | _ACEOF | |
5536 | if ac_fn_c_try_link "$LINENO"; then : | |
5537 | may_have_cet=yes | |
5538 | else | |
5539 | may_have_cet=no | |
5540 | fi | |
5541 | rm -f core conftest.err conftest.$ac_objext \ | |
5542 | conftest$ac_exeext conftest.$ac_ext | |
5543 | fi | |
5544 | ||
8fc8bf80 | 5545 | if test x$may_have_cet = xyes; then |
d17cdc17 L |
5546 | if test x$cross_compiling = xno; then |
5547 | if test "$cross_compiling" = yes; then : | |
8fc8bf80 L |
5548 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
5549 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5550 | as_fn_error $? "cannot run test program while cross compiling | |
5551 | See \`config.log' for more details" "$LINENO" 5; } | |
5552 | else | |
5553 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5554 | /* end confdefs.h. */ | |
5555 | ||
fd7eb4bc L |
5556 | int |
5557 | main () | |
5558 | { | |
5559 | asm ("endbr32"); | |
5560 | return 0; | |
5561 | } | |
5562 | ||
5563 | _ACEOF | |
5564 | if ac_fn_c_try_run "$LINENO"; then : | |
5565 | have_multi_byte_nop=yes | |
5566 | else | |
5567 | have_multi_byte_nop=no | |
5568 | fi | |
5569 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
5570 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5571 | fi | |
5572 | ||
5573 | have_cet=no | |
5574 | if test x$have_multi_byte_nop = xyes; then | |
5575 | if test "$cross_compiling" = yes; then : | |
5576 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5577 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5578 | as_fn_error $? "cannot run test program while cross compiling | |
5579 | See \`config.log' for more details" "$LINENO" 5; } | |
5580 | else | |
5581 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5582 | /* end confdefs.h. */ | |
5583 | ||
8fc8bf80 L |
5584 | static void |
5585 | foo (void) | |
5586 | { | |
5587 | } | |
5588 | ||
5589 | static void | |
5590 | __attribute__ ((noinline, noclone)) | |
5591 | xxx (void (*f) (void)) | |
5592 | { | |
5593 | f (); | |
5594 | } | |
5595 | ||
5596 | static void | |
5597 | __attribute__ ((noinline, noclone)) | |
5598 | bar (void) | |
5599 | { | |
5600 | xxx (foo); | |
5601 | } | |
5602 | ||
5603 | int | |
5604 | main () | |
5605 | { | |
5606 | bar (); | |
5607 | return 0; | |
5608 | } | |
5609 | ||
5610 | _ACEOF | |
5611 | if ac_fn_c_try_run "$LINENO"; then : | |
5612 | have_cet=no | |
5613 | else | |
5614 | have_cet=yes | |
5615 | fi | |
5616 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
5617 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5618 | fi | |
5619 | ||
fd7eb4bc | 5620 | fi |
d17cdc17 L |
5621 | if test x$enable_cet = xno -a x$have_cet = xyes; then |
5622 | as_fn_error $? "Intel CET must be enabled on Intel CET enabled host" "$LINENO" 5 | |
5623 | fi | |
8fc8bf80 | 5624 | fi |
d17cdc17 L |
5625 | else |
5626 | # Enable CET in cross compiler if possible so that it will run on both | |
5627 | # CET and non-CET hosts. | |
5628 | have_cet=yes | |
8fc8bf80 L |
5629 | fi |
5630 | if test x$enable_cet = xyes; then | |
5631 | CET_HOST_FLAGS="-fcf-protection" | |
5632 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
5633 | $as_echo "yes" >&6; } | |
5634 | else | |
5635 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
5636 | $as_echo "no" >&6; } | |
5637 | fi | |
9051b548 L |
5638 | CFLAGS="$cet_save_CFLAGS" |
5639 | LDFLAGS="$cet_save_LDFLAGS" | |
8fc8bf80 L |
5640 | |
5641 | ||
5642 | ||
f2c52c0d RO |
5643 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 |
5644 | $as_echo_n "checking target system type... " >&6; } | |
5645 | if ${ac_cv_target+:} false; then : | |
5646 | $as_echo_n "(cached) " >&6 | |
5647 | else | |
5648 | if test "x$target_alias" = x; then | |
5649 | ac_cv_target=$ac_cv_host | |
5650 | else | |
5651 | ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || | |
5652 | as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 | |
5653 | fi | |
5654 | ||
5655 | fi | |
5656 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 | |
5657 | $as_echo "$ac_cv_target" >&6; } | |
5658 | case $ac_cv_target in | |
5659 | *-*-*) ;; | |
5660 | *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; | |
5661 | esac | |
5662 | target=$ac_cv_target | |
5663 | ac_save_IFS=$IFS; IFS='-' | |
5664 | set x $ac_cv_target | |
5665 | shift | |
5666 | target_cpu=$1 | |
5667 | target_vendor=$2 | |
5668 | shift; shift | |
5669 | # Remember, the first character of IFS is used to create $*, | |
5670 | # except with old shells: | |
5671 | target_os=$* | |
5672 | IFS=$ac_save_IFS | |
5673 | case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac | |
5674 | ||
5675 | ||
5676 | # The aliases save the names the user supplied, while $host etc. | |
5677 | # will get canonicalized. | |
5678 | test -n "$target_alias" && | |
5679 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
5680 | NONENONEs,x,x, && | |
5681 | program_prefix=${target_alias}- | |
5682 | ||
5683 | test -z "$HWCAP_CFLAGS" && HWCAP_CFLAGS='' | |
5684 | ||
5685 | ||
5686 | # Restrict the test to Solaris, other assemblers (e.g. AIX as) have -nH | |
5687 | # with a different meaning. | |
5688 | case ${target_os} in | |
5689 | solaris2*) | |
5690 | ac_save_CFLAGS="$CFLAGS" | |
5691 | CFLAGS="$CFLAGS -Wa,-nH" | |
5692 | ||
5693 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for as that supports -Wa,-nH" >&5 | |
5694 | $as_echo_n "checking for as that supports -Wa,-nH... " >&6; } | |
5695 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5696 | /* end confdefs.h. */ | |
5697 | ||
5698 | int | |
5699 | main () | |
5700 | { | |
5701 | return 0; | |
5702 | ; | |
5703 | return 0; | |
5704 | } | |
5705 | _ACEOF | |
5706 | if ac_fn_c_try_compile "$LINENO"; then : | |
5707 | ac_hwcap_flags=yes | |
5708 | else | |
5709 | ac_hwcap_flags=no | |
5710 | fi | |
5711 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5712 | if test "$ac_hwcap_flags" = "yes"; then | |
5713 | HWCAP_CFLAGS="-Wa,-nH $HWCAP_CFLAGS" | |
5714 | fi | |
5715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_hwcap_flags" >&5 | |
5716 | $as_echo "$ac_hwcap_flags" >&6; } | |
5717 | ||
5718 | CFLAGS="$ac_save_CFLAGS" | |
5719 | ;; | |
5720 | esac | |
5721 | ||
5722 | ||
5723 | ||
5724 | ||
769b009e KC |
5725 | echo "# Warning: this fragment is automatically generated" > temp-frag |
5726 | ||
c91c9c2e PB |
5727 | if [ -n "${frag}" ] && [ -f "${frag}" ]; then |
5728 | echo "Appending ${frag} to xhost-mkfrag" | |
5729 | echo "# Following fragment copied from ${frag}" >> temp-frag | |
5730 | cat ${frag} >> temp-frag | |
5731 | fi | |
769b009e KC |
5732 | |
5733 | # record if we want to build shared libs. | |
5734 | if [ "${shared}" = "yes" ]; then | |
5735 | echo enable_shared = yes >> temp-frag | |
5736 | else | |
5737 | echo enable_shared = no >> temp-frag | |
5738 | fi | |
5739 | ||
5740 | frag=xhost-mkfrag | |
5741 | ${CONFIG_SHELL-/bin/sh} ${libiberty_topdir}/move-if-change temp-frag xhost-mkfrag | |
5742 | ||
0bc0cd11 JL |
5743 | host_makefile_frag=${frag} |
5744 | ||
5745 | ||
5746 | # It's OK to check for header files. Although the compiler may not be | |
5747 | # able to link anything, it had better be able to at least compile | |
5748 | # something. | |
879cf9ff | 5749 | for ac_header in sys/file.h sys/param.h limits.h stdlib.h malloc.h string.h unistd.h strings.h sys/time.h time.h sys/resource.h sys/stat.h sys/mman.h fcntl.h alloca.h sys/pstat.h sys/sysmp.h sys/sysinfo.h machine/hal_sysinfo.h sys/table.h sys/sysctl.h sys/systemcfg.h stdint.h stdio_ext.h process.h sys/prctl.h spawn.h |
5213506e RW |
5750 | do : |
5751 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
5752 | ac_fn_c_check_header_preproc "$LINENO" "$ac_header" "$as_ac_Header" | |
22e05272 | 5753 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
238235ef | 5754 | cat >>confdefs.h <<_ACEOF |
5213506e | 5755 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
238235ef DJ |
5756 | _ACEOF |
5757 | ||
5758 | fi | |
238235ef DJ |
5759 | done |
5760 | ||
5213506e RW |
5761 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5 |
5762 | $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; } | |
22e05272 | 5763 | if ${ac_cv_header_sys_wait_h+:} false; then : |
5213506e | 5764 | $as_echo_n "(cached) " >&6 |
238235ef | 5765 | else |
5213506e | 5766 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
238235ef | 5767 | /* end confdefs.h. */ |
d3982b71 | 5768 | #include <sys/types.h> |
238235ef DJ |
5769 | #include <sys/wait.h> |
5770 | #ifndef WEXITSTATUS | |
5213506e | 5771 | # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) |
fdfc290b | 5772 | #endif |
238235ef DJ |
5773 | #ifndef WIFEXITED |
5774 | # define WIFEXITED(stat_val) (((stat_val) & 255) == 0) | |
5775 | #endif | |
5776 | ||
5777 | int | |
5778 | main () | |
5779 | { | |
5780 | int s; | |
5781 | wait (&s); | |
5782 | s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; | |
5783 | ; | |
5784 | return 0; | |
5785 | } | |
5786 | _ACEOF | |
5213506e | 5787 | if ac_fn_c_try_compile "$LINENO"; then : |
238235ef | 5788 | ac_cv_header_sys_wait_h=yes |
d3982b71 | 5789 | else |
5213506e | 5790 | ac_cv_header_sys_wait_h=no |
d3982b71 | 5791 | fi |
5213506e | 5792 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
238235ef | 5793 | fi |
5213506e RW |
5794 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5 |
5795 | $as_echo "$ac_cv_header_sys_wait_h" >&6; } | |
238235ef DJ |
5796 | if test $ac_cv_header_sys_wait_h = yes; then |
5797 | ||
5213506e | 5798 | $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h |
b033df90 DJ |
5799 | |
5800 | fi | |
5801 | ||
5213506e RW |
5802 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
5803 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
22e05272 | 5804 | if ${ac_cv_header_time+:} false; then : |
5213506e | 5805 | $as_echo_n "(cached) " >&6 |
b033df90 | 5806 | else |
5213506e | 5807 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b033df90 DJ |
5808 | /* end confdefs.h. */ |
5809 | #include <sys/types.h> | |
5810 | #include <sys/time.h> | |
5811 | #include <time.h> | |
5812 | ||
5813 | int | |
5814 | main () | |
5815 | { | |
5816 | if ((struct tm *) 0) | |
5817 | return 0; | |
5818 | ; | |
5819 | return 0; | |
5820 | } | |
5821 | _ACEOF | |
5213506e | 5822 | if ac_fn_c_try_compile "$LINENO"; then : |
b033df90 DJ |
5823 | ac_cv_header_time=yes |
5824 | else | |
5213506e | 5825 | ac_cv_header_time=no |
b033df90 | 5826 | fi |
5213506e | 5827 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b033df90 | 5828 | fi |
5213506e RW |
5829 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
5830 | $as_echo "$ac_cv_header_time" >&6; } | |
b033df90 DJ |
5831 | if test $ac_cv_header_time = yes; then |
5832 | ||
5213506e | 5833 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
b033df90 DJ |
5834 | |
5835 | fi | |
5836 | ||
5837 | ||
2b601678 MK |
5838 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether errno must be declared" >&5 |
5839 | $as_echo_n "checking whether errno must be declared... " >&6; } | |
22e05272 | 5840 | if ${libiberty_cv_declare_errno+:} false; then : |
2b601678 MK |
5841 | $as_echo_n "(cached) " >&6 |
5842 | else | |
5843 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5844 | /* end confdefs.h. */ | |
5845 | #include <errno.h> | |
5846 | int | |
5847 | main () | |
5848 | { | |
5849 | int x = errno; | |
5850 | ; | |
5851 | return 0; | |
5852 | } | |
5853 | _ACEOF | |
5854 | if ac_fn_c_try_compile "$LINENO"; then : | |
5855 | libiberty_cv_declare_errno=no | |
5856 | else | |
5857 | libiberty_cv_declare_errno=yes | |
5858 | fi | |
5859 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5860 | fi | |
5861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libiberty_cv_declare_errno" >&5 | |
5862 | $as_echo "$libiberty_cv_declare_errno" >&6; } | |
5863 | if test $libiberty_cv_declare_errno = yes | |
5864 | then | |
5865 | $as_echo "#define NEED_DECLARATION_ERRNO 1" >>confdefs.h | |
5866 | ||
5867 | fi | |
5868 | ||
b033df90 | 5869 | |
ea41822a | 5870 | # Determine sizes of some types. |
5213506e RW |
5871 | # The cast to long int works around a bug in the HP C Compiler |
5872 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5873 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5874 | # This bug is HP SR number 8606223364. | |
5875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 | |
5876 | $as_echo_n "checking size of int... " >&6; } | |
22e05272 | 5877 | if ${ac_cv_sizeof_int+:} false; then : |
5213506e RW |
5878 | $as_echo_n "(cached) " >&6 |
5879 | else | |
5880 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : | |
5881 | ||
5882 | else | |
5883 | if test "$ac_cv_type_int" = yes; then | |
5884 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5885 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
5886 | as_fn_error 77 "cannot compute sizeof (int) |
5887 | See \`config.log' for more details" "$LINENO" 5; } | |
5213506e RW |
5888 | else |
5889 | ac_cv_sizeof_int=0 | |
5890 | fi | |
b033df90 | 5891 | fi |
b033df90 | 5892 | |
5213506e RW |
5893 | fi |
5894 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 | |
5895 | $as_echo "$ac_cv_sizeof_int" >&6; } | |
b033df90 | 5896 | |
b033df90 | 5897 | |
b033df90 | 5898 | |
5213506e RW |
5899 | cat >>confdefs.h <<_ACEOF |
5900 | #define SIZEOF_INT $ac_cv_sizeof_int | |
b033df90 | 5901 | _ACEOF |
b033df90 | 5902 | |
b033df90 | 5903 | |
ea41822a YG |
5904 | # The cast to long int works around a bug in the HP C Compiler |
5905 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5906 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5907 | # This bug is HP SR number 8606223364. | |
5908 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 | |
5909 | $as_echo_n "checking size of long... " >&6; } | |
22e05272 | 5910 | if ${ac_cv_sizeof_long+:} false; then : |
ea41822a YG |
5911 | $as_echo_n "(cached) " >&6 |
5912 | else | |
5913 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : | |
5914 | ||
5915 | else | |
5916 | if test "$ac_cv_type_long" = yes; then | |
5917 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5918 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
5919 | as_fn_error 77 "cannot compute sizeof (long) |
5920 | See \`config.log' for more details" "$LINENO" 5; } | |
ea41822a YG |
5921 | else |
5922 | ac_cv_sizeof_long=0 | |
5923 | fi | |
5924 | fi | |
5925 | ||
5926 | fi | |
5927 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 | |
5928 | $as_echo "$ac_cv_sizeof_long" >&6; } | |
5929 | ||
5930 | ||
5931 | ||
5932 | cat >>confdefs.h <<_ACEOF | |
5933 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
5934 | _ACEOF | |
5935 | ||
5936 | ||
126e0b6b AM |
5937 | # The cast to long int works around a bug in the HP C Compiler |
5938 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5939 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5940 | # This bug is HP SR number 8606223364. | |
5941 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of size_t" >&5 | |
5942 | $as_echo_n "checking size of size_t... " >&6; } | |
22e05272 | 5943 | if ${ac_cv_sizeof_size_t+:} false; then : |
126e0b6b AM |
5944 | $as_echo_n "(cached) " >&6 |
5945 | else | |
5946 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (size_t))" "ac_cv_sizeof_size_t" "$ac_includes_default"; then : | |
5947 | ||
5948 | else | |
5949 | if test "$ac_cv_type_size_t" = yes; then | |
5950 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5951 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
5952 | as_fn_error 77 "cannot compute sizeof (size_t) |
5953 | See \`config.log' for more details" "$LINENO" 5; } | |
126e0b6b AM |
5954 | else |
5955 | ac_cv_sizeof_size_t=0 | |
5956 | fi | |
5957 | fi | |
5958 | ||
5959 | fi | |
5960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_size_t" >&5 | |
5961 | $as_echo "$ac_cv_sizeof_size_t" >&6; } | |
5962 | ||
5963 | ||
5964 | ||
5965 | cat >>confdefs.h <<_ACEOF | |
5966 | #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t | |
5967 | _ACEOF | |
5968 | ||
5969 | ||
ea41822a YG |
5970 | |
5971 | # Check for presense of long long | |
5972 | ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" | |
22e05272 | 5973 | if test "x$ac_cv_type_long_long" = xyes; then : |
ea41822a YG |
5974 | |
5975 | $as_echo "#define HAVE_LONG_LONG 1" >>confdefs.h | |
5976 | # The cast to long int works around a bug in the HP C Compiler | |
5977 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5978 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5979 | # This bug is HP SR number 8606223364. | |
5980 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 | |
5981 | $as_echo_n "checking size of long long... " >&6; } | |
22e05272 | 5982 | if ${ac_cv_sizeof_long_long+:} false; then : |
ea41822a YG |
5983 | $as_echo_n "(cached) " >&6 |
5984 | else | |
5985 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : | |
5986 | ||
5987 | else | |
5988 | if test "$ac_cv_type_long_long" = yes; then | |
5989 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5990 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
22e05272 JM |
5991 | as_fn_error 77 "cannot compute sizeof (long long) |
5992 | See \`config.log' for more details" "$LINENO" 5; } | |
ea41822a YG |
5993 | else |
5994 | ac_cv_sizeof_long_long=0 | |
5995 | fi | |
5996 | fi | |
5997 | ||
5998 | fi | |
5999 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 | |
6000 | $as_echo "$ac_cv_sizeof_long_long" >&6; } | |
6001 | ||
6002 | ||
6003 | ||
6004 | cat >>confdefs.h <<_ACEOF | |
6005 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
6006 | _ACEOF | |
6007 | ||
6008 | ||
6009 | fi | |
6010 | ||
b033df90 | 6011 | |
5213506e RW |
6012 | # Look for a 64-bit type. |
6013 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a 64-bit type" >&5 | |
6014 | $as_echo_n "checking for a 64-bit type... " >&6; } | |
22e05272 | 6015 | if ${liberty_cv_uint64+:} false; then : |
5213506e | 6016 | $as_echo_n "(cached) " >&6 |
238235ef | 6017 | else |
5213506e RW |
6018 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
6019 | /* end confdefs.h. */ | |
6020 | #ifdef HAVE_STDINT_H | |
6021 | #include <stdint.h> | |
6022 | #endif | |
6023 | int | |
6024 | main () | |
6025 | { | |
6026 | extern uint64_t foo; | |
6027 | ; | |
6028 | return 0; | |
6029 | } | |
238235ef | 6030 | _ACEOF |
5213506e RW |
6031 | if ac_fn_c_try_compile "$LINENO"; then : |
6032 | liberty_cv_uint64=uint64_t | |
6033 | else | |
6034 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
238235ef | 6035 | /* end confdefs.h. */ |
5213506e RW |
6036 | #ifdef HAVE_LIMITS_H |
6037 | #include <limits.h> | |
6038 | #endif | |
6039 | #ifndef CHAR_BIT | |
6040 | #define CHAR_BIT 8 | |
b033df90 | 6041 | #endif |
238235ef DJ |
6042 | int |
6043 | main () | |
6044 | { | |
5213506e RW |
6045 | extern char foo[sizeof(long) * CHAR_BIT >= 64 ? 1 : -1]; |
6046 | ; | |
6047 | return 0; | |
238235ef DJ |
6048 | } |
6049 | _ACEOF | |
5213506e RW |
6050 | if ac_fn_c_try_compile "$LINENO"; then : |
6051 | liberty_cv_uint64="unsigned long" | |
238235ef | 6052 | else |
5213506e RW |
6053 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
6054 | /* end confdefs.h. */ | |
6055 | #ifdef HAVE_LIMITS_H | |
6056 | #include <limits.h> | |
6057 | #endif | |
6058 | #ifndef CHAR_BIT | |
6059 | #define CHAR_BIT 8 | |
6060 | #endif | |
6061 | int | |
6062 | main () | |
6063 | { | |
6064 | extern char foo[sizeof(long long) * CHAR_BIT >= 64 ? 1 : -1]; | |
6065 | ; | |
6066 | return 0; | |
6067 | } | |
6068 | _ACEOF | |
6069 | if ac_fn_c_try_compile "$LINENO"; then : | |
6070 | liberty_cv_uint64="unsigned long long" | |
6071 | else | |
6072 | liberty_cv_uint64=none | |
238235ef | 6073 | fi |
5213506e | 6074 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
238235ef | 6075 | fi |
5213506e | 6076 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b033df90 | 6077 | fi |
5213506e | 6078 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b033df90 | 6079 | fi |
238235ef | 6080 | |
5213506e RW |
6081 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $liberty_cv_uint64" >&5 |
6082 | $as_echo "$liberty_cv_uint64" >&6; } | |
6083 | if test "$liberty_cv_uint64" != none; then | |
6084 | ||
6085 | cat >>confdefs.h <<_ACEOF | |
6086 | #define UNSIGNED_64BIT_TYPE $liberty_cv_uint64 | |
238235ef DJ |
6087 | _ACEOF |
6088 | ||
6089 | fi | |
6090 | ||
0e497905 OS |
6091 | |
6092 | ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" | |
22e05272 | 6093 | if test "x$ac_cv_type_intptr_t" = xyes; then : |
0e497905 OS |
6094 | |
6095 | $as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h | |
6096 | ||
6097 | else | |
6098 | for ac_type in 'int' 'long int' 'long long int'; do | |
6099 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6100 | /* end confdefs.h. */ | |
6101 | $ac_includes_default | |
6102 | int | |
6103 | main () | |
6104 | { | |
6105 | static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; | |
22e05272 JM |
6106 | test_array [0] = 0; |
6107 | return test_array [0]; | |
0e497905 OS |
6108 | |
6109 | ; | |
6110 | return 0; | |
6111 | } | |
6112 | _ACEOF | |
6113 | if ac_fn_c_try_compile "$LINENO"; then : | |
6114 | ||
6115 | cat >>confdefs.h <<_ACEOF | |
6116 | #define intptr_t $ac_type | |
6117 | _ACEOF | |
6118 | ||
6119 | ac_type= | |
6120 | fi | |
6121 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6122 | test -z "$ac_type" && break | |
6123 | done | |
6124 | fi | |
6125 | ||
6126 | ||
6127 | ||
6128 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" | |
22e05272 | 6129 | if test "x$ac_cv_type_uintptr_t" = xyes; then : |
0e497905 OS |
6130 | |
6131 | $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h | |
6132 | ||
6133 | else | |
6134 | for ac_type in 'unsigned int' 'unsigned long int' \ | |
6135 | 'unsigned long long int'; do | |
6136 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6137 | /* end confdefs.h. */ | |
6138 | $ac_includes_default | |
6139 | int | |
6140 | main () | |
6141 | { | |
6142 | static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; | |
22e05272 JM |
6143 | test_array [0] = 0; |
6144 | return test_array [0]; | |
0e497905 OS |
6145 | |
6146 | ; | |
6147 | return 0; | |
6148 | } | |
6149 | _ACEOF | |
6150 | if ac_fn_c_try_compile "$LINENO"; then : | |
6151 | ||
6152 | cat >>confdefs.h <<_ACEOF | |
6153 | #define uintptr_t $ac_type | |
6154 | _ACEOF | |
6155 | ||
6156 | ac_type= | |
6157 | fi | |
6158 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6159 | test -z "$ac_type" && break | |
6160 | done | |
6161 | fi | |
6162 | ||
6163 | ||
1cfabf34 | 6164 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
22e05272 | 6165 | if test "x$ac_cv_type_ssize_t" = xyes; then : |
1cfabf34 ILT |
6166 | |
6167 | else | |
6168 | ||
6169 | cat >>confdefs.h <<_ACEOF | |
6170 | #define ssize_t int | |
6171 | _ACEOF | |
6172 | ||
6173 | fi | |
6174 | ||
0e497905 | 6175 | |
5213506e RW |
6176 | # Given the above check, we always have uintptr_t or a fallback |
6177 | # definition. So define HAVE_UINTPTR_T in case any imported code | |
6178 | # relies on it. | |
238235ef | 6179 | |
5213506e | 6180 | $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h |
b033df90 DJ |
6181 | |
6182 | ||
5213506e | 6183 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
22e05272 | 6184 | if test "x$ac_cv_type_pid_t" = xyes; then : |
b033df90 | 6185 | |
5213506e | 6186 | else |
b033df90 | 6187 | |
5213506e RW |
6188 | cat >>confdefs.h <<_ACEOF |
6189 | #define pid_t int | |
6190 | _ACEOF | |
b033df90 | 6191 | |
5213506e | 6192 | fi |
b033df90 DJ |
6193 | |
6194 | ||
5213506e RW |
6195 | # This is the list of functions which libiberty will provide if they |
6196 | # are not available on the host. | |
b033df90 | 6197 | |
5213506e RW |
6198 | funcs="asprintf" |
6199 | funcs="$funcs atexit" | |
6200 | funcs="$funcs basename" | |
6201 | funcs="$funcs bcmp" | |
6202 | funcs="$funcs bcopy" | |
6203 | funcs="$funcs bsearch" | |
6204 | funcs="$funcs bzero" | |
6205 | funcs="$funcs calloc" | |
6206 | funcs="$funcs clock" | |
6207 | funcs="$funcs ffs" | |
6208 | funcs="$funcs getcwd" | |
6209 | funcs="$funcs getpagesize" | |
6210 | funcs="$funcs gettimeofday" | |
6211 | funcs="$funcs index" | |
6212 | funcs="$funcs insque" | |
6213 | funcs="$funcs memchr" | |
6214 | funcs="$funcs memcmp" | |
6215 | funcs="$funcs memcpy" | |
6216 | funcs="$funcs memmem" | |
6217 | funcs="$funcs memmove" | |
6218 | funcs="$funcs mempcpy" | |
6219 | funcs="$funcs memset" | |
6220 | funcs="$funcs mkstemps" | |
6221 | funcs="$funcs putenv" | |
6222 | funcs="$funcs random" | |
6223 | funcs="$funcs rename" | |
6224 | funcs="$funcs rindex" | |
6225 | funcs="$funcs setenv" | |
6226 | funcs="$funcs snprintf" | |
6227 | funcs="$funcs sigsetmask" | |
6228 | funcs="$funcs stpcpy" | |
6229 | funcs="$funcs stpncpy" | |
6230 | funcs="$funcs strcasecmp" | |
6231 | funcs="$funcs strchr" | |
6232 | funcs="$funcs strdup" | |
6233 | funcs="$funcs strncasecmp" | |
6234 | funcs="$funcs strndup" | |
9a9baa52 | 6235 | funcs="$funcs strnlen" |
5213506e RW |
6236 | funcs="$funcs strrchr" |
6237 | funcs="$funcs strstr" | |
6238 | funcs="$funcs strtod" | |
6239 | funcs="$funcs strtol" | |
6240 | funcs="$funcs strtoul" | |
ea41822a YG |
6241 | funcs="$funcs strtoll" |
6242 | funcs="$funcs strtoull" | |
5213506e RW |
6243 | funcs="$funcs strverscmp" |
6244 | funcs="$funcs tmpnam" | |
6245 | funcs="$funcs vasprintf" | |
6246 | funcs="$funcs vfprintf" | |
6247 | funcs="$funcs vprintf" | |
6248 | funcs="$funcs vsnprintf" | |
6249 | funcs="$funcs vsprintf" | |
6250 | funcs="$funcs waitpid" | |
6e9bd0f8 | 6251 | funcs="$funcs setproctitle" |
238235ef | 6252 | |
5213506e RW |
6253 | # Also in the old function.def file: alloca, vfork, getopt. |
6254 | ||
6255 | vars="sys_errlist sys_nerr sys_siglist" | |
6256 | ||
d423df48 | 6257 | checkfuncs="__fsetlocking canonicalize_file_name dup3 getrlimit getrusage \ |
879cf9ff BS |
6258 | getsysinfo gettimeofday on_exit pipe2 posix_spawn posix_spawnp psignal \ |
6259 | pstat_getdynamic pstat_getstatic \ | |
fbb334a6 | 6260 | realpath setrlimit spawnve spawnvpe strerror strsignal sysconf sysctl \ |
d423df48 | 6261 | sysmp table times wait3 wait4" |
5213506e | 6262 | |
fbb334a6 IS |
6263 | #Â Darwin has sbrk, but it is deprecated and that produces build-time warnings |
6264 | #Â so do not check for it. | |
6265 | case "${host}" in | |
6266 | *-*-darwin*) ;; | |
6267 | *) checkfuncs="$checkfuncs sbrk" | |
6268 | esac | |
6269 | ||
5213506e RW |
6270 | # These are neither executed nor required, but they help keep |
6271 | # autoheader happy without adding a bunch of text to acconfig.h. | |
6272 | if test "x" = "y"; then | |
59a8dc25 BE |
6273 | for ac_func in asprintf atexit \ |
6274 | basename bcmp bcopy bsearch bzero \ | |
6275 | calloc canonicalize_file_name clock \ | |
3b63ca7e | 6276 | dup3 \ |
59a8dc25 | 6277 | ffs __fsetlocking \ |
d423df48 | 6278 | getcwd getpagesize getrlimit getrusage getsysinfo gettimeofday \ |
59a8dc25 BE |
6279 | index insque \ |
6280 | memchr memcmp memcpy memmem memmove memset mkstemps \ | |
6281 | on_exit \ | |
879cf9ff BS |
6282 | pipe2 posix_spawn posix_spawnp psignal \ |
6283 | pstat_getdynamic pstat_getstatic putenv \ | |
59a8dc25 | 6284 | random realpath rename rindex \ |
d423df48 | 6285 | sbrk setenv setproctitle setrlimit sigsetmask snprintf spawnve spawnvpe \ |
3b63ca7e | 6286 | stpcpy stpncpy strcasecmp strchr strdup \ |
9a9baa52 | 6287 | strerror strncasecmp strndup strnlen strrchr strsignal strstr strtod \ |
ea41822a | 6288 | strtol strtoul strtoll strtoull strverscmp sysconf sysctl sysmp \ |
59a8dc25 BE |
6289 | table times tmpnam \ |
6290 | vasprintf vfprintf vprintf vsprintf \ | |
6291 | wait3 wait4 waitpid | |
5213506e RW |
6292 | do : |
6293 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
6294 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
22e05272 | 6295 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
b033df90 | 6296 | cat >>confdefs.h <<_ACEOF |
5213506e | 6297 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
238235ef DJ |
6298 | _ACEOF |
6299 | ||
6300 | fi | |
b033df90 | 6301 | done |
238235ef | 6302 | |
22e05272 JM |
6303 | as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh` |
6304 | ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default" | |
6305 | if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then : | |
5213506e | 6306 | ac_have_decl=1 |
d49d0907 | 6307 | else |
5213506e RW |
6308 | ac_have_decl=0 |
6309 | fi | |
6310 | ||
6311 | cat >>confdefs.h <<_ACEOF | |
6312 | #define HAVE_DECL_BASENAME $ac_have_decl | |
d49d0907 | 6313 | _ACEOF |
5213506e | 6314 | ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default" |
22e05272 | 6315 | if test "x$ac_cv_have_decl_ffs" = xyes; then : |
5213506e | 6316 | ac_have_decl=1 |
d49d0907 | 6317 | else |
5213506e | 6318 | ac_have_decl=0 |
d49d0907 | 6319 | fi |
5213506e RW |
6320 | |
6321 | cat >>confdefs.h <<_ACEOF | |
6322 | #define HAVE_DECL_FFS $ac_have_decl | |
6323 | _ACEOF | |
6324 | ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default" | |
22e05272 | 6325 | if test "x$ac_cv_have_decl_asprintf" = xyes; then : |
5213506e RW |
6326 | ac_have_decl=1 |
6327 | else | |
6328 | ac_have_decl=0 | |
d49d0907 | 6329 | fi |
d49d0907 | 6330 | |
5213506e RW |
6331 | cat >>confdefs.h <<_ACEOF |
6332 | #define HAVE_DECL_ASPRINTF $ac_have_decl | |
6333 | _ACEOF | |
6334 | ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default" | |
22e05272 | 6335 | if test "x$ac_cv_have_decl_vasprintf" = xyes; then : |
5213506e | 6336 | ac_have_decl=1 |
d49d0907 | 6337 | else |
5213506e RW |
6338 | ac_have_decl=0 |
6339 | fi | |
6340 | ||
6341 | cat >>confdefs.h <<_ACEOF | |
6342 | #define HAVE_DECL_VASPRINTF $ac_have_decl | |
d49d0907 | 6343 | _ACEOF |
5213506e | 6344 | ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default" |
22e05272 | 6345 | if test "x$ac_cv_have_decl_snprintf" = xyes; then : |
5213506e RW |
6346 | ac_have_decl=1 |
6347 | else | |
6348 | ac_have_decl=0 | |
6349 | fi | |
d49d0907 | 6350 | |
5213506e RW |
6351 | cat >>confdefs.h <<_ACEOF |
6352 | #define HAVE_DECL_SNPRINTF $ac_have_decl | |
d49d0907 | 6353 | _ACEOF |
5213506e | 6354 | ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default" |
22e05272 | 6355 | if test "x$ac_cv_have_decl_vsnprintf" = xyes; then : |
5213506e RW |
6356 | ac_have_decl=1 |
6357 | else | |
6358 | ac_have_decl=0 | |
6359 | fi | |
6360 | ||
6361 | cat >>confdefs.h <<_ACEOF | |
6362 | #define HAVE_DECL_VSNPRINTF $ac_have_decl | |
d49d0907 | 6363 | _ACEOF |
ea41822a | 6364 | ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default" |
22e05272 | 6365 | if test "x$ac_cv_have_decl_strtol" = xyes; then : |
ea41822a YG |
6366 | ac_have_decl=1 |
6367 | else | |
6368 | ac_have_decl=0 | |
6369 | fi | |
6370 | ||
6371 | cat >>confdefs.h <<_ACEOF | |
6372 | #define HAVE_DECL_STRTOL $ac_have_decl | |
6373 | _ACEOF | |
6374 | ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default" | |
22e05272 | 6375 | if test "x$ac_cv_have_decl_strtoul" = xyes; then : |
ea41822a YG |
6376 | ac_have_decl=1 |
6377 | else | |
6378 | ac_have_decl=0 | |
6379 | fi | |
6380 | ||
6381 | cat >>confdefs.h <<_ACEOF | |
6382 | #define HAVE_DECL_STRTOUL $ac_have_decl | |
6383 | _ACEOF | |
6384 | ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default" | |
22e05272 | 6385 | if test "x$ac_cv_have_decl_strtoll" = xyes; then : |
ea41822a YG |
6386 | ac_have_decl=1 |
6387 | else | |
6388 | ac_have_decl=0 | |
6389 | fi | |
6390 | ||
6391 | cat >>confdefs.h <<_ACEOF | |
6392 | #define HAVE_DECL_STRTOLL $ac_have_decl | |
6393 | _ACEOF | |
6394 | ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default" | |
22e05272 | 6395 | if test "x$ac_cv_have_decl_strtoull" = xyes; then : |
ea41822a YG |
6396 | ac_have_decl=1 |
6397 | else | |
6398 | ac_have_decl=0 | |
6399 | fi | |
6400 | ||
6401 | cat >>confdefs.h <<_ACEOF | |
6402 | #define HAVE_DECL_STRTOULL $ac_have_decl | |
6403 | _ACEOF | |
63d9caf9 | 6404 | ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default" |
22e05272 | 6405 | if test "x$ac_cv_have_decl_strnlen" = xyes; then : |
63d9caf9 DD |
6406 | ac_have_decl=1 |
6407 | else | |
6408 | ac_have_decl=0 | |
6409 | fi | |
6410 | ||
6411 | cat >>confdefs.h <<_ACEOF | |
6412 | #define HAVE_DECL_STRNLEN $ac_have_decl | |
6413 | _ACEOF | |
d49d0907 | 6414 | |
d49d0907 | 6415 | |
5213506e | 6416 | $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h |
d49d0907 | 6417 | |
d49d0907 | 6418 | |
5213506e | 6419 | $as_echo "#define HAVE_SYS_NERR 1" >>confdefs.h |
d49d0907 | 6420 | |
d49d0907 | 6421 | |
5213506e | 6422 | $as_echo "#define HAVE_SYS_SIGLIST 1" >>confdefs.h |
d49d0907 | 6423 | |
d49d0907 | 6424 | fi |
d49d0907 | 6425 | |
5213506e RW |
6426 | # For each of these functions, if the host does not provide the |
6427 | # function we want to put FN.o in LIBOBJS, and if the host does | |
6428 | # provide the function, we want to define HAVE_FN in config.h. | |
d49d0907 | 6429 | |
5213506e RW |
6430 | setobjs= |
6431 | CHECK= | |
5213506e | 6432 | if test -n "${with_target_subdir}"; then |
d49d0907 | 6433 | |
5213506e RW |
6434 | # We are being configured as a target library. AC_REPLACE_FUNCS |
6435 | # may not work correctly, because the compiler may not be able to | |
6436 | # link executables. Note that we may still be being configured | |
6437 | # native. | |
d49d0907 | 6438 | |
5213506e RW |
6439 | # If we are being configured for newlib, we know which functions |
6440 | # newlib provide and which ones we will be expected to provide. | |
d49d0907 | 6441 | |
5213506e RW |
6442 | if test "x${with_newlib}" = "xyes"; then |
6443 | case " $LIBOBJS " in | |
6444 | *" asprintf.$ac_objext "* ) ;; | |
6445 | *) LIBOBJS="$LIBOBJS asprintf.$ac_objext" | |
6446 | ;; | |
6447 | esac | |
d49d0907 | 6448 | |
5213506e RW |
6449 | case " $LIBOBJS " in |
6450 | *" basename.$ac_objext "* ) ;; | |
6451 | *) LIBOBJS="$LIBOBJS basename.$ac_objext" | |
6452 | ;; | |
6453 | esac | |
d49d0907 | 6454 | |
5213506e RW |
6455 | case " $LIBOBJS " in |
6456 | *" insque.$ac_objext "* ) ;; | |
6457 | *) LIBOBJS="$LIBOBJS insque.$ac_objext" | |
6458 | ;; | |
6459 | esac | |
d49d0907 | 6460 | |
5213506e RW |
6461 | case " $LIBOBJS " in |
6462 | *" random.$ac_objext "* ) ;; | |
6463 | *) LIBOBJS="$LIBOBJS random.$ac_objext" | |
6464 | ;; | |
6465 | esac | |
d3982b71 | 6466 | |
5213506e RW |
6467 | case " $LIBOBJS " in |
6468 | *" strdup.$ac_objext "* ) ;; | |
6469 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" | |
6470 | ;; | |
6471 | esac | |
238235ef | 6472 | |
5213506e RW |
6473 | case " $LIBOBJS " in |
6474 | *" vasprintf.$ac_objext "* ) ;; | |
6475 | *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext" | |
6476 | ;; | |
6477 | esac | |
6478 | ||
6479 | ||
6480 | for f in $funcs; do | |
6481 | case "$f" in | |
6482 | asprintf | basename | insque | random | strdup | vasprintf) | |
6483 | ;; | |
6484 | *) | |
6485 | n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6486 | cat >>confdefs.h <<_ACEOF | |
6487 | #define $n 1 | |
238235ef | 6488 | _ACEOF |
fdfc290b | 6489 | |
5213506e RW |
6490 | ;; |
6491 | esac | |
6492 | done | |
238235ef | 6493 | |
5213506e RW |
6494 | # newlib doesnt provide any of the variables in $vars, so we |
6495 | # dont have to check them here. | |
238235ef | 6496 | |
5213506e RW |
6497 | # Of the functions in $checkfuncs, newlib only has strerror. |
6498 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
238235ef DJ |
6499 | |
6500 | ||
5213506e | 6501 | setobjs=yes |
238235ef | 6502 | |
5213506e | 6503 | fi |
238235ef | 6504 | |
5213506e RW |
6505 | # If we are being configured for Mingw, we know which functions |
6506 | # Mingw provides and which ones we will be expected to provide. | |
238235ef | 6507 | |
5213506e RW |
6508 | case "${host}" in |
6509 | *-*-mingw*) | |
6510 | case " $LIBOBJS " in | |
6511 | *" asprintf.$ac_objext "* ) ;; | |
6512 | *) LIBOBJS="$LIBOBJS asprintf.$ac_objext" | |
6513 | ;; | |
6514 | esac | |
238235ef | 6515 | |
5213506e RW |
6516 | case " $LIBOBJS " in |
6517 | *" basename.$ac_objext "* ) ;; | |
6518 | *) LIBOBJS="$LIBOBJS basename.$ac_objext" | |
6519 | ;; | |
6520 | esac | |
238235ef | 6521 | |
5213506e RW |
6522 | case " $LIBOBJS " in |
6523 | *" bcmp.$ac_objext "* ) ;; | |
6524 | *) LIBOBJS="$LIBOBJS bcmp.$ac_objext" | |
6525 | ;; | |
6526 | esac | |
238235ef | 6527 | |
5213506e RW |
6528 | case " $LIBOBJS " in |
6529 | *" bcopy.$ac_objext "* ) ;; | |
6530 | *) LIBOBJS="$LIBOBJS bcopy.$ac_objext" | |
6531 | ;; | |
6532 | esac | |
238235ef | 6533 | |
5213506e RW |
6534 | case " $LIBOBJS " in |
6535 | *" bzero.$ac_objext "* ) ;; | |
6536 | *) LIBOBJS="$LIBOBJS bzero.$ac_objext" | |
6537 | ;; | |
6538 | esac | |
238235ef | 6539 | |
5213506e RW |
6540 | case " $LIBOBJS " in |
6541 | *" clock.$ac_objext "* ) ;; | |
6542 | *) LIBOBJS="$LIBOBJS clock.$ac_objext" | |
6543 | ;; | |
6544 | esac | |
238235ef | 6545 | |
5213506e RW |
6546 | case " $LIBOBJS " in |
6547 | *" ffs.$ac_objext "* ) ;; | |
6548 | *) LIBOBJS="$LIBOBJS ffs.$ac_objext" | |
6549 | ;; | |
6550 | esac | |
238235ef | 6551 | |
5213506e RW |
6552 | case " $LIBOBJS " in |
6553 | *" getpagesize.$ac_objext "* ) ;; | |
6554 | *) LIBOBJS="$LIBOBJS getpagesize.$ac_objext" | |
6555 | ;; | |
6556 | esac | |
238235ef | 6557 | |
5213506e RW |
6558 | case " $LIBOBJS " in |
6559 | *" index.$ac_objext "* ) ;; | |
6560 | *) LIBOBJS="$LIBOBJS index.$ac_objext" | |
6561 | ;; | |
6562 | esac | |
238235ef | 6563 | |
5213506e RW |
6564 | case " $LIBOBJS " in |
6565 | *" insque.$ac_objext "* ) ;; | |
6566 | *) LIBOBJS="$LIBOBJS insque.$ac_objext" | |
6567 | ;; | |
6568 | esac | |
238235ef | 6569 | |
5213506e RW |
6570 | case " $LIBOBJS " in |
6571 | *" mempcpy.$ac_objext "* ) ;; | |
6572 | *) LIBOBJS="$LIBOBJS mempcpy.$ac_objext" | |
6573 | ;; | |
6574 | esac | |
238235ef | 6575 | |
5213506e RW |
6576 | case " $LIBOBJS " in |
6577 | *" mkstemps.$ac_objext "* ) ;; | |
6578 | *) LIBOBJS="$LIBOBJS mkstemps.$ac_objext" | |
6579 | ;; | |
6580 | esac | |
238235ef | 6581 | |
5213506e RW |
6582 | case " $LIBOBJS " in |
6583 | *" random.$ac_objext "* ) ;; | |
6584 | *) LIBOBJS="$LIBOBJS random.$ac_objext" | |
6585 | ;; | |
6586 | esac | |
238235ef | 6587 | |
5213506e RW |
6588 | case " $LIBOBJS " in |
6589 | *" rindex.$ac_objext "* ) ;; | |
6590 | *) LIBOBJS="$LIBOBJS rindex.$ac_objext" | |
6591 | ;; | |
6592 | esac | |
238235ef | 6593 | |
5213506e RW |
6594 | case " $LIBOBJS " in |
6595 | *" sigsetmask.$ac_objext "* ) ;; | |
6596 | *) LIBOBJS="$LIBOBJS sigsetmask.$ac_objext" | |
6597 | ;; | |
6598 | esac | |
238235ef | 6599 | |
5213506e RW |
6600 | case " $LIBOBJS " in |
6601 | *" stpcpy.$ac_objext "* ) ;; | |
6602 | *) LIBOBJS="$LIBOBJS stpcpy.$ac_objext" | |
6603 | ;; | |
6604 | esac | |
238235ef | 6605 | |
5213506e RW |
6606 | case " $LIBOBJS " in |
6607 | *" stpncpy.$ac_objext "* ) ;; | |
6608 | *) LIBOBJS="$LIBOBJS stpncpy.$ac_objext" | |
6609 | ;; | |
6610 | esac | |
238235ef | 6611 | |
5213506e RW |
6612 | case " $LIBOBJS " in |
6613 | *" strndup.$ac_objext "* ) ;; | |
6614 | *) LIBOBJS="$LIBOBJS strndup.$ac_objext" | |
6615 | ;; | |
6616 | esac | |
238235ef | 6617 | |
9a9baa52 ILT |
6618 | case " $LIBOBJS " in |
6619 | *" strnlen.$ac_objext "* ) ;; | |
6620 | *) LIBOBJS="$LIBOBJS strnlen.$ac_objext" | |
6621 | ;; | |
6622 | esac | |
6623 | ||
5213506e RW |
6624 | case " $LIBOBJS " in |
6625 | *" strverscmp.$ac_objext "* ) ;; | |
6626 | *) LIBOBJS="$LIBOBJS strverscmp.$ac_objext" | |
6627 | ;; | |
6628 | esac | |
238235ef | 6629 | |
5213506e RW |
6630 | case " $LIBOBJS " in |
6631 | *" vasprintf.$ac_objext "* ) ;; | |
6632 | *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext" | |
6633 | ;; | |
6634 | esac | |
238235ef | 6635 | |
5213506e RW |
6636 | case " $LIBOBJS " in |
6637 | *" waitpid.$ac_objext "* ) ;; | |
6638 | *) LIBOBJS="$LIBOBJS waitpid.$ac_objext" | |
6639 | ;; | |
6640 | esac | |
238235ef DJ |
6641 | |
6642 | ||
5213506e RW |
6643 | for f in $funcs; do |
6644 | case "$f" in | |
9a9baa52 | 6645 | asprintf | basename | bcmp | bcopy | bzero | clock | ffs | getpagesize | index | insque | mempcpy | mkstemps | random | rindex | sigsetmask | stpcpy | stpncpy | strdup | strndup | strnlen | strverscmp | vasprintf | waitpid) |
5213506e RW |
6646 | ;; |
6647 | *) | |
6648 | n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6649 | cat >>confdefs.h <<_ACEOF | |
6650 | #define $n 1 | |
6651 | _ACEOF | |
238235ef | 6652 | |
5213506e RW |
6653 | ;; |
6654 | esac | |
6655 | done | |
238235ef | 6656 | |
5213506e RW |
6657 | # Mingw doesnt provide any of the variables in $vars, so we |
6658 | # dont have to check them here. | |
238235ef | 6659 | |
5213506e RW |
6660 | # Of the functions in $checkfuncs, Mingw only has strerror. |
6661 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
238235ef DJ |
6662 | |
6663 | ||
5213506e RW |
6664 | setobjs=yes |
6665 | ;; | |
238235ef | 6666 | |
5213506e RW |
6667 | *-*-msdosdjgpp) |
6668 | case " $LIBOBJS " in | |
6669 | *" vasprintf.$ac_objext "* ) ;; | |
6670 | *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext" | |
6671 | ;; | |
6672 | esac | |
238235ef | 6673 | |
5213506e RW |
6674 | case " $LIBOBJS " in |
6675 | *" vsnprintf.$ac_objext "* ) ;; | |
6676 | *) LIBOBJS="$LIBOBJS vsnprintf.$ac_objext" | |
6677 | ;; | |
6678 | esac | |
238235ef | 6679 | |
5213506e RW |
6680 | case " $LIBOBJS " in |
6681 | *" snprintf.$ac_objext "* ) ;; | |
6682 | *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" | |
6683 | ;; | |
6684 | esac | |
238235ef | 6685 | |
5213506e RW |
6686 | case " $LIBOBJS " in |
6687 | *" asprintf.$ac_objext "* ) ;; | |
6688 | *) LIBOBJS="$LIBOBJS asprintf.$ac_objext" | |
6689 | ;; | |
6690 | esac | |
238235ef DJ |
6691 | |
6692 | ||
5213506e RW |
6693 | for f in atexit basename bcmp bcopy bsearch bzero calloc clock ffs \ |
6694 | getcwd getpagesize getrusage gettimeofday \ | |
6695 | index insque memchr memcmp memcpy memmove memset psignal \ | |
6696 | putenv random rename rindex sbrk setenv stpcpy strcasecmp \ | |
6697 | strchr strdup strerror strncasecmp strrchr strstr strtod \ | |
6698 | strtol strtoul sysconf times tmpnam vfprintf vprintf \ | |
6699 | vsprintf waitpid | |
6700 | do | |
6701 | n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6702 | cat >>confdefs.h <<_ACEOF | |
6703 | #define $n 1 | |
6704 | _ACEOF | |
238235ef | 6705 | |
5213506e | 6706 | done |
238235ef | 6707 | |
17998b22 | 6708 | |
5213506e RW |
6709 | setobjs=yes |
6710 | ;; | |
17998b22 | 6711 | |
5213506e | 6712 | esac |
f9a9ac80 | 6713 | |
0bc0cd11 | 6714 | else |
238235ef | 6715 | |
5213506e RW |
6716 | # Not a target library, so we set things up to run the test suite. |
6717 | CHECK=really-check | |
0bc0cd11 JL |
6718 | |
6719 | fi | |
6720 | ||
238235ef | 6721 | |
238235ef | 6722 | |
238235ef | 6723 | |
5213506e RW |
6724 | case "${host}" in |
6725 | *-*-cygwin* | *-*-mingw*) | |
6726 | $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h | |
238235ef | 6727 | |
5213506e | 6728 | $as_echo "#define HAVE_SYS_NERR 1" >>confdefs.h |
238235ef | 6729 | |
5213506e RW |
6730 | ;; |
6731 | esac | |
0bc0cd11 | 6732 | |
5213506e RW |
6733 | if test -z "${setobjs}"; then |
6734 | case "${host}" in | |
0bc0cd11 | 6735 | |
5213506e RW |
6736 | *-*-vxworks*) |
6737 | # Handle VxWorks configuration specially, since on VxWorks the | |
6738 | # libraries are actually on the target board, not in the file | |
6739 | # system. | |
6740 | case " $LIBOBJS " in | |
6741 | *" basename.$ac_objext "* ) ;; | |
6742 | *) LIBOBJS="$LIBOBJS basename.$ac_objext" | |
6743 | ;; | |
3beb1315 HPN |
6744 | esac |
6745 | ||
5213506e RW |
6746 | case " $LIBOBJS " in |
6747 | *" getpagesize.$ac_objext "* ) ;; | |
6748 | *) LIBOBJS="$LIBOBJS getpagesize.$ac_objext" | |
6749 | ;; | |
6750 | esac | |
238235ef | 6751 | |
5213506e RW |
6752 | case " $LIBOBJS " in |
6753 | *" insque.$ac_objext "* ) ;; | |
6754 | *) LIBOBJS="$LIBOBJS insque.$ac_objext" | |
6755 | ;; | |
6756 | esac | |
e490616e | 6757 | |
5213506e RW |
6758 | case " $LIBOBJS " in |
6759 | *" random.$ac_objext "* ) ;; | |
6760 | *) LIBOBJS="$LIBOBJS random.$ac_objext" | |
6761 | ;; | |
6762 | esac | |
238235ef | 6763 | |
5213506e RW |
6764 | case " $LIBOBJS " in |
6765 | *" strcasecmp.$ac_objext "* ) ;; | |
6766 | *) LIBOBJS="$LIBOBJS strcasecmp.$ac_objext" | |
6767 | ;; | |
6768 | esac | |
238235ef | 6769 | |
5213506e RW |
6770 | case " $LIBOBJS " in |
6771 | *" strncasecmp.$ac_objext "* ) ;; | |
6772 | *) LIBOBJS="$LIBOBJS strncasecmp.$ac_objext" | |
6773 | ;; | |
3beb1315 HPN |
6774 | esac |
6775 | ||
5213506e RW |
6776 | case " $LIBOBJS " in |
6777 | *" strdup.$ac_objext "* ) ;; | |
6778 | *) LIBOBJS="$LIBOBJS strdup.$ac_objext" | |
6779 | ;; | |
6780 | esac | |
e490616e | 6781 | |
5213506e RW |
6782 | case " $LIBOBJS " in |
6783 | *" vfork.$ac_objext "* ) ;; | |
6784 | *) LIBOBJS="$LIBOBJS vfork.$ac_objext" | |
6785 | ;; | |
6786 | esac | |
e490616e | 6787 | |
5213506e RW |
6788 | case " $LIBOBJS " in |
6789 | *" waitpid.$ac_objext "* ) ;; | |
6790 | *) LIBOBJS="$LIBOBJS waitpid.$ac_objext" | |
6791 | ;; | |
6792 | esac | |
238235ef | 6793 | |
5213506e RW |
6794 | case " $LIBOBJS " in |
6795 | *" vasprintf.$ac_objext "* ) ;; | |
6796 | *) LIBOBJS="$LIBOBJS vasprintf.$ac_objext" | |
6797 | ;; | |
6798 | esac | |
9ce3f7e5 | 6799 | |
5213506e RW |
6800 | for f in $funcs; do |
6801 | case "$f" in | |
6802 | basename | getpagesize | insque | random | strcasecmp) | |
6803 | ;; | |
6804 | strncasecmp | strdup | vfork | waitpid | vasprintf) | |
6805 | ;; | |
6806 | *) | |
6807 | n=HAVE_`echo $f | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
6808 | cat >>confdefs.h <<_ACEOF | |
6809 | #define $n 1 | |
238235ef | 6810 | _ACEOF |
238235ef | 6811 | |
5213506e RW |
6812 | ;; |
6813 | esac | |
6814 | done | |
9ce3f7e5 | 6815 | |
5213506e RW |
6816 | # VxWorks doesn't provide any of the variables in $vars, so we |
6817 | # don't have to check them here. | |
9ce3f7e5 | 6818 | |
5213506e RW |
6819 | # Of the functions in $checkfuncs, VxWorks only has strerror. |
6820 | $as_echo "#define HAVE_STRERROR 1" >>confdefs.h | |
e490616e | 6821 | |
238235ef | 6822 | |
5213506e RW |
6823 | setobjs=yes |
6824 | ;; | |
6825 | ||
6826 | esac | |
0bc0cd11 JL |
6827 | fi |
6828 | ||
5213506e | 6829 | if test -z "${setobjs}"; then |
0bc0cd11 | 6830 | |
5213506e | 6831 | case "${host}" in |
aa9dc53d | 6832 | |
41fdbd54 JB |
6833 | *-*-android*) |
6834 | # On android, getpagesize is defined in unistd.h as a static inline | |
6835 | # function, which AC_CHECK_FUNCS does not handle properly. | |
6836 | ac_cv_func_getpagesize=yes | |
6837 | ;; | |
6838 | ||
a0864ce8 JDA |
6839 | hppa*-*-hpux*) |
6840 | # Replace system snprintf and vsnprintf with libiberty implementations. | |
6841 | case " $LIBOBJS " in | |
6842 | *" snprintf.$ac_objext "* ) ;; | |
6843 | *) LIBOBJS="$LIBOBJS snprintf.$ac_objext" | |
6844 | ;; | |
6845 | esac | |
6846 | ||
6847 | case " $LIBOBJS " in | |
6848 | *" vsnprintf.$ac_objext "* ) ;; | |
6849 | *) LIBOBJS="$LIBOBJS vsnprintf.$ac_objext" | |
6850 | ;; | |
6851 | esac | |
6852 | ||
6853 | ;; | |
6854 | ||
5213506e RW |
6855 | *-*-mingw32*) |
6856 | # Under mingw32, sys_nerr and sys_errlist exist, but they are | |
6857 | # macros, so the test below won't find them. | |
6858 | libiberty_cv_var_sys_nerr=yes | |
6859 | libiberty_cv_var_sys_errlist=yes | |
6860 | ;; | |
238235ef | 6861 | |
5213506e RW |
6862 | *-*-msdosdjgpp*) |
6863 | # vfork and fork are stubs. | |
6864 | ac_cv_func_vfork_works=no | |
6865 | ;; | |
aa9dc53d | 6866 | |
5213506e RW |
6867 | *-*-uwin*) |
6868 | # Under some versions of uwin, vfork is notoriously buggy and the test | |
6869 | # can hang configure; on other versions, vfork exists just as a stub. | |
6870 | # FIXME: This should be removed once vfork in uwin's runtime is fixed. | |
6871 | ac_cv_func_vfork_works=no | |
6872 | # Under uwin 2.0+, sys_nerr and sys_errlist exist, but they are | |
6873 | # macros (actually, these are imported from a DLL, but the end effect | |
6874 | # is the same), so the test below won't find them. | |
6875 | libiberty_cv_var_sys_nerr=yes | |
6876 | libiberty_cv_var_sys_errlist=yes | |
6877 | ;; | |
238235ef | 6878 | |
5213506e RW |
6879 | *-*-*vms*) |
6880 | # Under VMS, vfork works very different than on Unix. The standard test | |
6881 | # won't work, and it isn't easily adaptable. It makes more sense to | |
6882 | # just force it. | |
6883 | ac_cv_func_vfork_works=yes | |
6884 | ;; | |
238235ef | 6885 | |
5213506e | 6886 | esac |
aa9dc53d | 6887 | |
5213506e RW |
6888 | # We haven't set the list of objects yet. Use the standard autoconf |
6889 | # tests. This will only work if the compiler works. | |
6890 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5 | |
6891 | $as_echo_n "checking for library containing strerror... " >&6; } | |
22e05272 | 6892 | if ${ac_cv_search_strerror+:} false; then : |
5213506e | 6893 | $as_echo_n "(cached) " >&6 |
238235ef | 6894 | else |
5213506e RW |
6895 | ac_func_search_save_LIBS=$LIBS |
6896 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
238235ef | 6897 | /* end confdefs.h. */ |
5213506e RW |
6898 | |
6899 | /* Override any GCC internal prototype to avoid an error. | |
6900 | Use char because int might match the return type of a GCC | |
238235ef | 6901 | builtin and then its argument prototype would still apply. */ |
238235ef | 6902 | #ifdef __cplusplus |
5213506e | 6903 | extern "C" |
0bc0cd11 | 6904 | #endif |
5213506e | 6905 | char strerror (); |
238235ef DJ |
6906 | int |
6907 | main () | |
6908 | { | |
5213506e | 6909 | return strerror (); |
238235ef DJ |
6910 | ; |
6911 | return 0; | |
6912 | } | |
6913 | _ACEOF | |
5213506e RW |
6914 | for ac_lib in '' cposix; do |
6915 | if test -z "$ac_lib"; then | |
6916 | ac_res="none required" | |
6917 | else | |
6918 | ac_res=-l$ac_lib | |
6919 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
6920 | fi | |
6921 | if test x$gcc_no_link = xyes; then | |
22e05272 | 6922 | as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5 |
5213506e RW |
6923 | fi |
6924 | if ac_fn_c_try_link "$LINENO"; then : | |
6925 | ac_cv_search_strerror=$ac_res | |
6926 | fi | |
6927 | rm -f core conftest.err conftest.$ac_objext \ | |
6928 | conftest$ac_exeext | |
22e05272 | 6929 | if ${ac_cv_search_strerror+:} false; then : |
5213506e RW |
6930 | break |
6931 | fi | |
6932 | done | |
22e05272 | 6933 | if ${ac_cv_search_strerror+:} false; then : |
238235ef | 6934 | |
5213506e RW |
6935 | else |
6936 | ac_cv_search_strerror=no | |
238235ef | 6937 | fi |
5213506e RW |
6938 | rm conftest.$ac_ext |
6939 | LIBS=$ac_func_search_save_LIBS | |
6940 | fi | |
6941 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_strerror" >&5 | |
6942 | $as_echo "$ac_cv_search_strerror" >&6; } | |
6943 | ac_res=$ac_cv_search_strerror | |
6944 | if test "$ac_res" != no; then : | |
6945 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
6946 | ||
238235ef | 6947 | fi |
5213506e RW |
6948 | |
6949 | for ac_func in $funcs | |
6950 | do : | |
6951 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
6952 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
22e05272 | 6953 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
238235ef | 6954 | cat >>confdefs.h <<_ACEOF |
5213506e | 6955 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
238235ef | 6956 | _ACEOF |
0bc0cd11 | 6957 | |
5213506e RW |
6958 | else |
6959 | case " $LIBOBJS " in | |
6960 | *" $ac_func.$ac_objext "* ) ;; | |
6961 | *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext" | |
6962 | ;; | |
6963 | esac | |
6964 | ||
0bc0cd11 JL |
6965 | fi |
6966 | done | |
6967 | ||
2b601678 MK |
6968 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether alloca needs Cray hooks" >&5 |
6969 | $as_echo_n "checking whether alloca needs Cray hooks... " >&6; } | |
22e05272 | 6970 | if ${ac_cv_os_cray+:} false; then : |
2b601678 MK |
6971 | $as_echo_n "(cached) " >&6 |
6972 | else | |
6973 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6974 | /* end confdefs.h. */ | |
6975 | #if defined(CRAY) && ! defined(CRAY2) | |
6976 | webecray | |
6977 | #else | |
6978 | wenotbecray | |
6979 | #endif | |
6980 | ||
6981 | _ACEOF | |
6982 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
6983 | $EGREP "webecray" >/dev/null 2>&1; then : | |
6984 | ac_cv_os_cray=yes | |
6985 | else | |
6986 | ac_cv_os_cray=no | |
6987 | fi | |
6988 | rm -f conftest* | |
6989 | ||
6990 | fi | |
6991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_os_cray" >&5 | |
6992 | $as_echo "$ac_cv_os_cray" >&6; } | |
6993 | if test $ac_cv_os_cray = yes; then | |
6994 | for ac_func in _getb67 GETB67 getb67; do | |
6995 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
6996 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
22e05272 | 6997 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
2b601678 MK |
6998 | |
6999 | cat >>confdefs.h <<_ACEOF | |
7000 | #define CRAY_STACKSEG_END $ac_func | |
7001 | _ACEOF | |
7002 | break | |
7003 | fi | |
7004 | ||
7005 | done | |
7006 | fi | |
7007 | ||
7008 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking stack direction for C alloca" >&5 | |
7009 | $as_echo_n "checking stack direction for C alloca... " >&6; } | |
22e05272 | 7010 | if ${ac_cv_c_stack_direction+:} false; then : |
2b601678 MK |
7011 | $as_echo_n "(cached) " >&6 |
7012 | else | |
7013 | if test "$cross_compiling" = yes; then : | |
7014 | ac_cv_c_stack_direction=0 | |
7015 | else | |
7016 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7017 | /* end confdefs.h. */ | |
885b6660 FW |
7018 | #include <stdlib.h> |
7019 | ||
7020 | int | |
7021 | find_stack_direction (void) | |
2b601678 MK |
7022 | { |
7023 | static char *addr = 0; | |
7024 | auto char dummy; | |
7025 | if (addr == 0) | |
7026 | { | |
7027 | addr = &dummy; | |
7028 | return find_stack_direction (); | |
7029 | } | |
7030 | else | |
7031 | return (&dummy > addr) ? 1 : -1; | |
7032 | } | |
885b6660 FW |
7033 | |
7034 | int | |
7035 | main (void) | |
2b601678 MK |
7036 | { |
7037 | exit (find_stack_direction() < 0); | |
7038 | } | |
7039 | _ACEOF | |
7040 | if ac_fn_c_try_run "$LINENO"; then : | |
7041 | ac_cv_c_stack_direction=1 | |
7042 | else | |
7043 | ac_cv_c_stack_direction=-1 | |
7044 | fi | |
7045 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
7046 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7047 | fi | |
7048 | ||
7049 | fi | |
7050 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_stack_direction" >&5 | |
7051 | $as_echo "$ac_cv_c_stack_direction" >&6; } | |
7052 | ||
7053 | cat >>confdefs.h <<_ACEOF | |
7054 | #define STACK_DIRECTION $ac_cv_c_stack_direction | |
7055 | _ACEOF | |
7056 | ||
7057 | ||
5213506e RW |
7058 | for ac_header in vfork.h |
7059 | do : | |
7060 | ac_fn_c_check_header_preproc "$LINENO" "vfork.h" "ac_cv_header_vfork_h" | |
22e05272 | 7061 | if test "x$ac_cv_header_vfork_h" = xyes; then : |
3c60ae5a | 7062 | cat >>confdefs.h <<_ACEOF |
5213506e | 7063 | #define HAVE_VFORK_H 1 |
3c60ae5a GDR |
7064 | _ACEOF |
7065 | ||
5213506e RW |
7066 | fi |
7067 | done | |
7068 | ||
7069 | for ac_func in fork vfork | |
7070 | do : | |
7071 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
7072 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
22e05272 | 7073 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
5213506e RW |
7074 | cat >>confdefs.h <<_ACEOF |
7075 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 | |
7076 | _ACEOF | |
3c60ae5a GDR |
7077 | |
7078 | fi | |
5213506e RW |
7079 | done |
7080 | ||
7081 | if test "x$ac_cv_func_fork" = xyes; then | |
7082 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 | |
7083 | $as_echo_n "checking for working fork... " >&6; } | |
22e05272 | 7084 | if ${ac_cv_func_fork_works+:} false; then : |
5213506e | 7085 | $as_echo_n "(cached) " >&6 |
3c60ae5a | 7086 | else |
5213506e RW |
7087 | if test "$cross_compiling" = yes; then : |
7088 | ac_cv_func_fork_works=cross | |
7089 | else | |
7090 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3c60ae5a GDR |
7091 | /* end confdefs.h. */ |
7092 | $ac_includes_default | |
7093 | int | |
7094 | main () | |
7095 | { | |
5213506e RW |
7096 | |
7097 | /* By Ruediger Kuhlmann. */ | |
7098 | return fork () < 0; | |
3c60ae5a GDR |
7099 | |
7100 | ; | |
7101 | return 0; | |
7102 | } | |
7103 | _ACEOF | |
5213506e RW |
7104 | if ac_fn_c_try_run "$LINENO"; then : |
7105 | ac_cv_func_fork_works=yes | |
3c60ae5a | 7106 | else |
5213506e | 7107 | ac_cv_func_fork_works=no |
3c60ae5a | 7108 | fi |
5213506e RW |
7109 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7110 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
3c60ae5a | 7111 | fi |
3c60ae5a | 7112 | |
5213506e RW |
7113 | fi |
7114 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 | |
7115 | $as_echo "$ac_cv_func_fork_works" >&6; } | |
3c60ae5a GDR |
7116 | |
7117 | else | |
5213506e RW |
7118 | ac_cv_func_fork_works=$ac_cv_func_fork |
7119 | fi | |
7120 | if test "x$ac_cv_func_fork_works" = xcross; then | |
7121 | case $host in | |
7122 | *-*-amigaos* | *-*-msdosdjgpp*) | |
7123 | # Override, as these systems have only a dummy fork() stub | |
7124 | ac_cv_func_fork_works=no | |
7125 | ;; | |
7126 | *) | |
7127 | ac_cv_func_fork_works=yes | |
7128 | ;; | |
7129 | esac | |
7130 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 | |
7131 | $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} | |
3c60ae5a | 7132 | fi |
5213506e RW |
7133 | ac_cv_func_vfork_works=$ac_cv_func_vfork |
7134 | if test "x$ac_cv_func_vfork" = xyes; then | |
7135 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 | |
7136 | $as_echo_n "checking for working vfork... " >&6; } | |
22e05272 | 7137 | if ${ac_cv_func_vfork_works+:} false; then : |
5213506e | 7138 | $as_echo_n "(cached) " >&6 |
3c60ae5a | 7139 | else |
5213506e RW |
7140 | if test "$cross_compiling" = yes; then : |
7141 | ac_cv_func_vfork_works=cross | |
7142 | else | |
7143 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
3c60ae5a | 7144 | /* end confdefs.h. */ |
5213506e | 7145 | /* Thanks to Paul Eggert for this test. */ |
3c60ae5a | 7146 | $ac_includes_default |
5213506e RW |
7147 | #include <sys/wait.h> |
7148 | #ifdef HAVE_VFORK_H | |
7149 | # include <vfork.h> | |
7150 | #endif | |
7151 | /* On some sparc systems, changes by the child to local and incoming | |
7152 | argument registers are propagated back to the parent. The compiler | |
7153 | is told about this with #include <vfork.h>, but some compilers | |
7154 | (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a | |
7155 | static variable whose address is put into a register that is | |
7156 | clobbered by the vfork. */ | |
7157 | static void | |
7158 | #ifdef __cplusplus | |
7159 | sparc_address_test (int arg) | |
7160 | # else | |
7161 | sparc_address_test (arg) int arg; | |
7162 | #endif | |
7163 | { | |
7164 | static pid_t child; | |
7165 | if (!child) { | |
7166 | child = vfork (); | |
7167 | if (child < 0) { | |
7168 | perror ("vfork"); | |
7169 | _exit(2); | |
7170 | } | |
7171 | if (!child) { | |
7172 | arg = getpid(); | |
7173 | write(-1, "", 0); | |
7174 | _exit (arg); | |
7175 | } | |
7176 | } | |
7177 | } | |
7178 | ||
3c60ae5a GDR |
7179 | int |
7180 | main () | |
7181 | { | |
5213506e RW |
7182 | pid_t parent = getpid (); |
7183 | pid_t child; | |
3c60ae5a | 7184 | |
5213506e | 7185 | sparc_address_test (0); |
3c60ae5a | 7186 | |
5213506e | 7187 | child = vfork (); |
3c60ae5a | 7188 | |
5213506e RW |
7189 | if (child == 0) { |
7190 | /* Here is another test for sparc vfork register problems. This | |
7191 | test uses lots of local variables, at least as many local | |
7192 | variables as main has allocated so far including compiler | |
7193 | temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris | |
7194 | 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should | |
7195 | reuse the register of parent for one of the local variables, | |
7196 | since it will think that parent can't possibly be used any more | |
7197 | in this routine. Assigning to the local variable will thus | |
7198 | munge parent in the parent process. */ | |
7199 | pid_t | |
7200 | p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), | |
7201 | p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); | |
7202 | /* Convince the compiler that p..p7 are live; otherwise, it might | |
7203 | use the same hardware register for all 8 local variables. */ | |
7204 | if (p != p1 || p != p2 || p != p3 || p != p4 | |
7205 | || p != p5 || p != p6 || p != p7) | |
7206 | _exit(1); | |
3c60ae5a | 7207 | |
5213506e RW |
7208 | /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent |
7209 | from child file descriptors. If the child closes a descriptor | |
7210 | before it execs or exits, this munges the parent's descriptor | |
7211 | as well. Test for this by closing stdout in the child. */ | |
7212 | _exit(close(fileno(stdout)) != 0); | |
7213 | } else { | |
7214 | int status; | |
7215 | struct stat st; | |
3c60ae5a | 7216 | |
5213506e RW |
7217 | while (wait(&status) != child) |
7218 | ; | |
7219 | return ( | |
7220 | /* Was there some problem with vforking? */ | |
7221 | child < 0 | |
3c60ae5a | 7222 | |
5213506e RW |
7223 | /* Did the child fail? (This shouldn't happen.) */ |
7224 | || status | |
3c60ae5a | 7225 | |
5213506e RW |
7226 | /* Did the vfork/compiler bug occur? */ |
7227 | || parent != getpid() | |
ddcf783b | 7228 | |
5213506e RW |
7229 | /* Did the file descriptor bug occur? */ |
7230 | || fstat(fileno(stdout), &st) != 0 | |
7231 | ); | |
7232 | } | |
ddcf783b EZ |
7233 | } |
7234 | _ACEOF | |
5213506e RW |
7235 | if ac_fn_c_try_run "$LINENO"; then : |
7236 | ac_cv_func_vfork_works=yes | |
ddcf783b | 7237 | else |
5213506e RW |
7238 | ac_cv_func_vfork_works=no |
7239 | fi | |
7240 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
7241 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7242 | fi | |
ddcf783b | 7243 | |
ddcf783b | 7244 | fi |
5213506e RW |
7245 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 |
7246 | $as_echo "$ac_cv_func_vfork_works" >&6; } | |
7247 | ||
7248 | fi; | |
7249 | if test "x$ac_cv_func_fork_works" = xcross; then | |
7250 | ac_cv_func_vfork_works=$ac_cv_func_vfork | |
7251 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 | |
7252 | $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} | |
ddcf783b | 7253 | fi |
ddcf783b | 7254 | |
5213506e | 7255 | if test "x$ac_cv_func_vfork_works" = xyes; then |
ddcf783b | 7256 | |
5213506e | 7257 | $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h |
ddcf783b EZ |
7258 | |
7259 | else | |
ddcf783b | 7260 | |
5213506e | 7261 | $as_echo "#define vfork fork" >>confdefs.h |
ddcf783b EZ |
7262 | |
7263 | fi | |
5213506e | 7264 | if test "x$ac_cv_func_fork_works" = xyes; then |
ddcf783b | 7265 | |
5213506e | 7266 | $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h |
ddcf783b | 7267 | |
ddcf783b | 7268 | fi |
ddcf783b | 7269 | |
5213506e RW |
7270 | if test $ac_cv_func_vfork_works = no; then |
7271 | case " $LIBOBJS " in | |
7272 | *" vfork.$ac_objext "* ) ;; | |
7273 | *) LIBOBJS="$LIBOBJS vfork.$ac_objext" | |
7274 | ;; | |
7275 | esac | |
ddcf783b | 7276 | |
5213506e RW |
7277 | fi |
7278 | # We only need _doprnt if we might use it to implement v*printf. | |
7279 | if test $ac_cv_func_vprintf != yes \ | |
7280 | || test $ac_cv_func_vfprintf != yes \ | |
7281 | || test $ac_cv_func_vsprintf != yes; then | |
22e05272 JM |
7282 | ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" |
7283 | if test "x$ac_cv_func__doprnt" = xyes; then : | |
7284 | $as_echo "#define HAVE__DOPRNT 1" >>confdefs.h | |
ddcf783b | 7285 | |
5213506e RW |
7286 | else |
7287 | case " $LIBOBJS " in | |
22e05272 JM |
7288 | *" _doprnt.$ac_objext "* ) ;; |
7289 | *) LIBOBJS="$LIBOBJS _doprnt.$ac_objext" | |
5213506e RW |
7290 | ;; |
7291 | esac | |
ddcf783b | 7292 | |
d7cf8390 GDR |
7293 | fi |
7294 | ||
7295 | ||
5213506e RW |
7296 | else |
7297 | for ac_func in _doprnt | |
7298 | do : | |
7299 | ac_fn_c_check_func "$LINENO" "_doprnt" "ac_cv_func__doprnt" | |
22e05272 | 7300 | if test "x$ac_cv_func__doprnt" = xyes; then : |
5213506e RW |
7301 | cat >>confdefs.h <<_ACEOF |
7302 | #define HAVE__DOPRNT 1 | |
d7cf8390 | 7303 | _ACEOF |
d7cf8390 | 7304 | |
d7cf8390 | 7305 | fi |
5213506e | 7306 | done |
d7cf8390 | 7307 | |
5213506e | 7308 | fi |
d7cf8390 | 7309 | |
5213506e RW |
7310 | for v in $vars; do |
7311 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $v" >&5 | |
7312 | $as_echo_n "checking for $v... " >&6; } | |
22e05272 | 7313 | if eval \${libiberty_cv_var_$v+:} false; then : |
5213506e | 7314 | $as_echo_n "(cached) " >&6 |
d7cf8390 | 7315 | else |
5213506e | 7316 | if test x$gcc_no_link = xyes; then |
22e05272 | 7317 | as_fn_error $? "Link tests are not allowed after GCC_NO_EXECUTABLES." "$LINENO" 5 |
d7cf8390 | 7318 | fi |
5213506e | 7319 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
d7cf8390 | 7320 | /* end confdefs.h. */ |
f418bc3c | 7321 | extern int $v []; |
d7cf8390 GDR |
7322 | int |
7323 | main () | |
7324 | { | |
f418bc3c | 7325 | if ($v [0]) return 1; |
d7cf8390 GDR |
7326 | ; |
7327 | return 0; | |
7328 | } | |
7329 | _ACEOF | |
5213506e RW |
7330 | if ac_fn_c_try_link "$LINENO"; then : |
7331 | eval "libiberty_cv_var_$v=yes" | |
d7cf8390 | 7332 | else |
5213506e | 7333 | eval "libiberty_cv_var_$v=no" |
d7cf8390 | 7334 | fi |
5213506e RW |
7335 | rm -f core conftest.err conftest.$ac_objext \ |
7336 | conftest$ac_exeext conftest.$ac_ext | |
d7cf8390 | 7337 | fi |
d7cf8390 | 7338 | |
5213506e RW |
7339 | if eval "test \"`echo '$libiberty_cv_var_'$v`\" = yes"; then |
7340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
7341 | $as_echo "yes" >&6; } | |
7342 | n=HAVE_`echo $v | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` | |
7343 | cat >>confdefs.h <<_ACEOF | |
7344 | #define $n 1 | |
d7cf8390 GDR |
7345 | _ACEOF |
7346 | ||
5213506e RW |
7347 | else |
7348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
7349 | $as_echo "no" >&6; } | |
7350 | fi | |
7351 | done | |
d7cf8390 | 7352 | |
5213506e RW |
7353 | # special check for _system_configuration because AIX <4.3.2 do not |
7354 | # contain the `physmem' member. | |
7355 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for external symbol _system_configuration" >&5 | |
7356 | $as_echo_n "checking for external symbol _system_configuration... " >&6; } | |
7357 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8b82b724 | 7358 | /* end confdefs.h. */ |
5213506e | 7359 | #include <sys/systemcfg.h> |
8b82b724 BE |
7360 | int |
7361 | main () | |
7362 | { | |
5213506e | 7363 | double x = _system_configuration.physmem; |
8b82b724 BE |
7364 | ; |
7365 | return 0; | |
7366 | } | |
7367 | _ACEOF | |
5213506e RW |
7368 | if ac_fn_c_try_compile "$LINENO"; then : |
7369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
7370 | $as_echo "yes" >&6; } | |
8b82b724 | 7371 | |
5213506e | 7372 | $as_echo "#define HAVE__SYSTEM_CONFIGURATION 1" >>confdefs.h |
8b82b724 BE |
7373 | |
7374 | else | |
5213506e RW |
7375 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7376 | $as_echo "no" >&6; } | |
7377 | fi | |
7378 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7379 | ||
7380 | for ac_func in $checkfuncs | |
7381 | do : | |
7382 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
7383 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
22e05272 | 7384 | if eval test \"x\$"$as_ac_var"\" = x"yes"; then : |
8b82b724 | 7385 | cat >>confdefs.h <<_ACEOF |
5213506e | 7386 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
8b82b724 BE |
7387 | _ACEOF |
7388 | ||
d7cf8390 | 7389 | fi |
5213506e | 7390 | done |
d7cf8390 | 7391 | |
22e05272 JM |
7392 | as_ac_Symbol=`$as_echo "ac_cv_have_decl_basename(char *)" | $as_tr_sh` |
7393 | ac_fn_c_check_decl "$LINENO" "basename(char *)" "$as_ac_Symbol" "$ac_includes_default" | |
7394 | if eval test \"x\$"$as_ac_Symbol"\" = x"yes"; then : | |
5213506e | 7395 | ac_have_decl=1 |
d7cf8390 | 7396 | else |
5213506e | 7397 | ac_have_decl=0 |
d7cf8390 | 7398 | fi |
d7cf8390 GDR |
7399 | |
7400 | cat >>confdefs.h <<_ACEOF | |
5213506e | 7401 | #define HAVE_DECL_BASENAME $ac_have_decl |
d7cf8390 | 7402 | _ACEOF |
5213506e | 7403 | ac_fn_c_check_decl "$LINENO" "ffs" "ac_cv_have_decl_ffs" "$ac_includes_default" |
22e05272 | 7404 | if test "x$ac_cv_have_decl_ffs" = xyes; then : |
5213506e | 7405 | ac_have_decl=1 |
d7cf8390 | 7406 | else |
5213506e | 7407 | ac_have_decl=0 |
d7cf8390 | 7408 | fi |
d7cf8390 | 7409 | |
5213506e RW |
7410 | cat >>confdefs.h <<_ACEOF |
7411 | #define HAVE_DECL_FFS $ac_have_decl | |
d7cf8390 | 7412 | _ACEOF |
5213506e | 7413 | ac_fn_c_check_decl "$LINENO" "asprintf" "ac_cv_have_decl_asprintf" "$ac_includes_default" |
22e05272 | 7414 | if test "x$ac_cv_have_decl_asprintf" = xyes; then : |
5213506e | 7415 | ac_have_decl=1 |
d7cf8390 | 7416 | else |
5213506e | 7417 | ac_have_decl=0 |
d7cf8390 | 7418 | fi |
d7cf8390 GDR |
7419 | |
7420 | cat >>confdefs.h <<_ACEOF | |
5213506e | 7421 | #define HAVE_DECL_ASPRINTF $ac_have_decl |
d7cf8390 | 7422 | _ACEOF |
5213506e | 7423 | ac_fn_c_check_decl "$LINENO" "vasprintf" "ac_cv_have_decl_vasprintf" "$ac_includes_default" |
22e05272 | 7424 | if test "x$ac_cv_have_decl_vasprintf" = xyes; then : |
5213506e | 7425 | ac_have_decl=1 |
d7cf8390 | 7426 | else |
5213506e | 7427 | ac_have_decl=0 |
d7cf8390 | 7428 | fi |
d7cf8390 | 7429 | |
5213506e RW |
7430 | cat >>confdefs.h <<_ACEOF |
7431 | #define HAVE_DECL_VASPRINTF $ac_have_decl | |
d7cf8390 | 7432 | _ACEOF |
5213506e | 7433 | ac_fn_c_check_decl "$LINENO" "snprintf" "ac_cv_have_decl_snprintf" "$ac_includes_default" |
22e05272 | 7434 | if test "x$ac_cv_have_decl_snprintf" = xyes; then : |
5213506e | 7435 | ac_have_decl=1 |
d7cf8390 | 7436 | else |
5213506e | 7437 | ac_have_decl=0 |
d7cf8390 | 7438 | fi |
d7cf8390 GDR |
7439 | |
7440 | cat >>confdefs.h <<_ACEOF | |
5213506e | 7441 | #define HAVE_DECL_SNPRINTF $ac_have_decl |
d7cf8390 | 7442 | _ACEOF |
5213506e | 7443 | ac_fn_c_check_decl "$LINENO" "vsnprintf" "ac_cv_have_decl_vsnprintf" "$ac_includes_default" |
22e05272 | 7444 | if test "x$ac_cv_have_decl_vsnprintf" = xyes; then : |
5213506e | 7445 | ac_have_decl=1 |
d7cf8390 | 7446 | else |
5213506e | 7447 | ac_have_decl=0 |
83fbfe42 GK |
7448 | fi |
7449 | ||
5213506e RW |
7450 | cat >>confdefs.h <<_ACEOF |
7451 | #define HAVE_DECL_VSNPRINTF $ac_have_decl | |
7452 | _ACEOF | |
83fbfe42 | 7453 | |
5213506e | 7454 | ac_fn_c_check_decl "$LINENO" "calloc" "ac_cv_have_decl_calloc" "$ac_includes_default" |
22e05272 | 7455 | if test "x$ac_cv_have_decl_calloc" = xyes; then : |
5213506e RW |
7456 | ac_have_decl=1 |
7457 | else | |
7458 | ac_have_decl=0 | |
83fbfe42 | 7459 | fi |
5213506e RW |
7460 | |
7461 | cat >>confdefs.h <<_ACEOF | |
7462 | #define HAVE_DECL_CALLOC $ac_have_decl | |
7463 | _ACEOF | |
7464 | ac_fn_c_check_decl "$LINENO" "getenv" "ac_cv_have_decl_getenv" "$ac_includes_default" | |
22e05272 | 7465 | if test "x$ac_cv_have_decl_getenv" = xyes; then : |
5213506e RW |
7466 | ac_have_decl=1 |
7467 | else | |
7468 | ac_have_decl=0 | |
83fbfe42 | 7469 | fi |
83fbfe42 GK |
7470 | |
7471 | cat >>confdefs.h <<_ACEOF | |
5213506e | 7472 | #define HAVE_DECL_GETENV $ac_have_decl |
83fbfe42 | 7473 | _ACEOF |
5213506e | 7474 | ac_fn_c_check_decl "$LINENO" "getopt" "ac_cv_have_decl_getopt" "$ac_includes_default" |
22e05272 | 7475 | if test "x$ac_cv_have_decl_getopt" = xyes; then : |
5213506e RW |
7476 | ac_have_decl=1 |
7477 | else | |
7478 | ac_have_decl=0 | |
7479 | fi | |
83fbfe42 | 7480 | |
5213506e RW |
7481 | cat >>confdefs.h <<_ACEOF |
7482 | #define HAVE_DECL_GETOPT $ac_have_decl | |
7483 | _ACEOF | |
7484 | ac_fn_c_check_decl "$LINENO" "malloc" "ac_cv_have_decl_malloc" "$ac_includes_default" | |
22e05272 | 7485 | if test "x$ac_cv_have_decl_malloc" = xyes; then : |
5213506e RW |
7486 | ac_have_decl=1 |
7487 | else | |
7488 | ac_have_decl=0 | |
7489 | fi | |
83fbfe42 | 7490 | |
5213506e RW |
7491 | cat >>confdefs.h <<_ACEOF |
7492 | #define HAVE_DECL_MALLOC $ac_have_decl | |
7493 | _ACEOF | |
7494 | ac_fn_c_check_decl "$LINENO" "realloc" "ac_cv_have_decl_realloc" "$ac_includes_default" | |
22e05272 | 7495 | if test "x$ac_cv_have_decl_realloc" = xyes; then : |
5213506e | 7496 | ac_have_decl=1 |
83fbfe42 | 7497 | else |
5213506e RW |
7498 | ac_have_decl=0 |
7499 | fi | |
7500 | ||
7501 | cat >>confdefs.h <<_ACEOF | |
7502 | #define HAVE_DECL_REALLOC $ac_have_decl | |
83fbfe42 | 7503 | _ACEOF |
fbb334a6 IS |
7504 | |
7505 | case "${host}" in | |
7506 | *-*-darwin*) ;; # Darwin's sbrk implementation is deprecated. | |
7507 | *) ac_fn_c_check_decl "$LINENO" "sbrk" "ac_cv_have_decl_sbrk" "$ac_includes_default" | |
22e05272 | 7508 | if test "x$ac_cv_have_decl_sbrk" = xyes; then : |
5213506e RW |
7509 | ac_have_decl=1 |
7510 | else | |
7511 | ac_have_decl=0 | |
7512 | fi | |
83fbfe42 | 7513 | |
5213506e RW |
7514 | cat >>confdefs.h <<_ACEOF |
7515 | #define HAVE_DECL_SBRK $ac_have_decl | |
2d3a2063 | 7516 | _ACEOF |
fbb334a6 IS |
7517 | ;; |
7518 | esac | |
2d3a2063 | 7519 | ac_fn_c_check_decl "$LINENO" "strtol" "ac_cv_have_decl_strtol" "$ac_includes_default" |
22e05272 | 7520 | if test "x$ac_cv_have_decl_strtol" = xyes; then : |
2d3a2063 JDA |
7521 | ac_have_decl=1 |
7522 | else | |
7523 | ac_have_decl=0 | |
7524 | fi | |
7525 | ||
7526 | cat >>confdefs.h <<_ACEOF | |
7527 | #define HAVE_DECL_STRTOL $ac_have_decl | |
7528 | _ACEOF | |
7529 | ac_fn_c_check_decl "$LINENO" "strtoul" "ac_cv_have_decl_strtoul" "$ac_includes_default" | |
22e05272 | 7530 | if test "x$ac_cv_have_decl_strtoul" = xyes; then : |
2d3a2063 JDA |
7531 | ac_have_decl=1 |
7532 | else | |
7533 | ac_have_decl=0 | |
7534 | fi | |
7535 | ||
7536 | cat >>confdefs.h <<_ACEOF | |
7537 | #define HAVE_DECL_STRTOUL $ac_have_decl | |
7538 | _ACEOF | |
7539 | ac_fn_c_check_decl "$LINENO" "strtoll" "ac_cv_have_decl_strtoll" "$ac_includes_default" | |
22e05272 | 7540 | if test "x$ac_cv_have_decl_strtoll" = xyes; then : |
2d3a2063 JDA |
7541 | ac_have_decl=1 |
7542 | else | |
7543 | ac_have_decl=0 | |
7544 | fi | |
7545 | ||
7546 | cat >>confdefs.h <<_ACEOF | |
7547 | #define HAVE_DECL_STRTOLL $ac_have_decl | |
7548 | _ACEOF | |
7549 | ac_fn_c_check_decl "$LINENO" "strtoull" "ac_cv_have_decl_strtoull" "$ac_includes_default" | |
22e05272 | 7550 | if test "x$ac_cv_have_decl_strtoull" = xyes; then : |
2d3a2063 JDA |
7551 | ac_have_decl=1 |
7552 | else | |
7553 | ac_have_decl=0 | |
7554 | fi | |
7555 | ||
7556 | cat >>confdefs.h <<_ACEOF | |
7557 | #define HAVE_DECL_STRTOULL $ac_have_decl | |
5213506e | 7558 | _ACEOF |
83fbfe42 | 7559 | |
5213506e | 7560 | ac_fn_c_check_decl "$LINENO" "strverscmp" "ac_cv_have_decl_strverscmp" "$ac_includes_default" |
22e05272 | 7561 | if test "x$ac_cv_have_decl_strverscmp" = xyes; then : |
5213506e RW |
7562 | ac_have_decl=1 |
7563 | else | |
7564 | ac_have_decl=0 | |
3c60ae5a GDR |
7565 | fi |
7566 | ||
5213506e RW |
7567 | cat >>confdefs.h <<_ACEOF |
7568 | #define HAVE_DECL_STRVERSCMP $ac_have_decl | |
63d9caf9 DD |
7569 | _ACEOF |
7570 | ||
7571 | ac_fn_c_check_decl "$LINENO" "strnlen" "ac_cv_have_decl_strnlen" "$ac_includes_default" | |
22e05272 | 7572 | if test "x$ac_cv_have_decl_strnlen" = xyes; then : |
63d9caf9 DD |
7573 | ac_have_decl=1 |
7574 | else | |
7575 | ac_have_decl=0 | |
7576 | fi | |
7577 | ||
7578 | cat >>confdefs.h <<_ACEOF | |
7579 | #define HAVE_DECL_STRNLEN $ac_have_decl | |
5213506e | 7580 | _ACEOF |
3c60ae5a | 7581 | |
2b601678 MK |
7582 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether canonicalize_file_name must be declared" >&5 |
7583 | $as_echo_n "checking whether canonicalize_file_name must be declared... " >&6; } | |
22e05272 | 7584 | if ${libiberty_cv_decl_needed_canonicalize_file_name+:} false; then : |
2b601678 MK |
7585 | $as_echo_n "(cached) " >&6 |
7586 | else | |
7587 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7588 | /* end confdefs.h. */ | |
7589 | ||
7590 | #include "confdefs.h" | |
7591 | #include <stdio.h> | |
7592 | #ifdef HAVE_STRING_H | |
7593 | #include <string.h> | |
7594 | #else | |
7595 | #ifdef HAVE_STRINGS_H | |
7596 | #include <strings.h> | |
7597 | #endif | |
7598 | #endif | |
7599 | #ifdef HAVE_STDLIB_H | |
7600 | #include <stdlib.h> | |
7601 | #endif | |
7602 | #ifdef HAVE_UNISTD_H | |
7603 | #include <unistd.h> | |
7604 | #endif | |
7605 | int | |
7606 | main () | |
7607 | { | |
7608 | char *(*pfn) = (char *(*)) canonicalize_file_name | |
7609 | ; | |
7610 | return 0; | |
7611 | } | |
7612 | _ACEOF | |
7613 | if ac_fn_c_try_compile "$LINENO"; then : | |
7614 | libiberty_cv_decl_needed_canonicalize_file_name=no | |
7615 | else | |
7616 | libiberty_cv_decl_needed_canonicalize_file_name=yes | |
7617 | fi | |
7618 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7619 | fi | |
7620 | ||
7621 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $libiberty_cv_decl_needed_canonicalize_file_name" >&5 | |
7622 | $as_echo "$libiberty_cv_decl_needed_canonicalize_file_name" >&6; } | |
7623 | if test $libiberty_cv_decl_needed_canonicalize_file_name = yes; then | |
7624 | ||
7625 | $as_echo "#define NEED_DECLARATION_CANONICALIZE_FILE_NAME 1" >>confdefs.h | |
7626 | ||
7627 | fi | |
7628 | ||
0bc0cd11 JL |
7629 | fi |
7630 | ||
55d0e5e0 ZW |
7631 | # Figure out which version of pexecute to use. |
7632 | case "${host}" in | |
16f60fcb TG |
7633 | *-*-mingw* | *-*-winnt*) pexecute=pex-win32 ;; |
7634 | *-*-msdosdjgpp*) pexecute=pex-djgpp ;; | |
7635 | *-*-msdos*) pexecute=pex-msdos ;; | |
7636 | *) pexecute=pex-unix ;; | |
55d0e5e0 ZW |
7637 | esac |
7638 | ||
7639 | ||
bf4f40cc JJ |
7640 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SHA1 HW acceleration support" >&5 |
7641 | $as_echo_n "checking for SHA1 HW acceleration support... " >&6; } | |
7642 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7643 | /* end confdefs.h. */ | |
7644 | ||
7645 | #include <x86intrin.h> | |
7646 | #include <cpuid.h> | |
7647 | ||
7648 | __attribute__((__target__ ("sse4.1,sha"))) | |
7649 | void foo (__m128i *buf, unsigned int e, __m128i msg0, __m128i msg1) | |
7650 | { | |
7651 | __m128i abcd = _mm_loadu_si128 ((const __m128i *) buf); | |
7652 | __m128i e0 = _mm_set_epi32 (e, 0, 0, 0); | |
7653 | abcd = _mm_shuffle_epi32 (abcd, 0x1b); | |
7654 | const __m128i shuf_mask = _mm_set_epi64x (0x0001020304050607ULL, 0x08090a0b0c0d0e0fULL); | |
7655 | abcd = _mm_shuffle_epi8 (abcd, shuf_mask); | |
7656 | e0 = _mm_sha1nexte_epu32 (e0, msg1); | |
7657 | abcd = _mm_sha1rnds4_epu32 (abcd, e0, 0); | |
7658 | msg0 = _mm_sha1msg1_epu32 (msg0, msg1); | |
7659 | msg0 = _mm_sha1msg2_epu32 (msg0, msg1); | |
7660 | msg0 = _mm_xor_si128 (msg0, msg1); | |
7661 | e0 = _mm_add_epi32 (e0, msg0); | |
7662 | e0 = abcd; | |
7663 | _mm_storeu_si128 (buf, abcd); | |
7664 | e = _mm_extract_epi32 (e0, 3); | |
7665 | } | |
7666 | ||
7667 | int bar (void) | |
7668 | { | |
7669 | unsigned int eax, ebx, ecx, edx; | |
7670 | if (__get_cpuid_count (7, 0, &eax, &ebx, &ecx, &edx) | |
7671 | && (ebx & bit_SHA) != 0 | |
7672 | && __get_cpuid (1, &eax, &ebx, &ecx, &edx) | |
7673 | && (ecx & bit_SSE4_1) != 0) | |
7674 | return 1; | |
7675 | return 0; | |
7676 | } | |
7677 | ||
7678 | int | |
7679 | main () | |
7680 | { | |
7681 | bar (); | |
7682 | ; | |
7683 | return 0; | |
7684 | } | |
7685 | _ACEOF | |
7686 | if ac_fn_c_try_compile "$LINENO"; then : | |
7687 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: x86 SHA1" >&5 | |
7688 | $as_echo "x86 SHA1" >&6; } | |
7689 | ||
7690 | $as_echo "#define HAVE_X86_SHA1_HW_SUPPORT 1" >>confdefs.h | |
7691 | ||
7692 | else | |
7693 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
7694 | $as_echo "no" >&6; } | |
7695 | fi | |
7696 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7697 | ||
22e05272 JM |
7698 | |
7699 | ||
7700 | ||
7701 | for ac_header in $ac_header_list | |
2b601678 MK |
7702 | do : |
7703 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
7704 | ac_fn_c_check_header_preproc "$LINENO" "$ac_header" "$as_ac_Header" | |
22e05272 | 7705 | if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : |
2b601678 MK |
7706 | cat >>confdefs.h <<_ACEOF |
7707 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
7708 | _ACEOF | |
7709 | ||
7710 | fi | |
7711 | done | |
7712 | ||
22e05272 JM |
7713 | |
7714 | ||
7715 | ||
7716 | ||
7717 | ||
7718 | ||
7719 | if test x$gcc_no_link = xyes; then | |
7720 | if test "x${ac_cv_func_mmap_fixed_mapped+set}" != xset; then | |
7721 | ac_cv_func_mmap_fixed_mapped=no | |
7722 | fi | |
7723 | fi | |
7724 | if test "x${ac_cv_func_mmap_fixed_mapped}" != xno; then | |
7725 | ||
2b601678 MK |
7726 | for ac_func in getpagesize |
7727 | do : | |
7728 | ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize" | |
22e05272 | 7729 | if test "x$ac_cv_func_getpagesize" = xyes; then : |
2b601678 MK |
7730 | cat >>confdefs.h <<_ACEOF |
7731 | #define HAVE_GETPAGESIZE 1 | |
7732 | _ACEOF | |
7733 | ||
7734 | fi | |
7735 | done | |
7736 | ||
7737 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working mmap" >&5 | |
7738 | $as_echo_n "checking for working mmap... " >&6; } | |
22e05272 | 7739 | if ${ac_cv_func_mmap_fixed_mapped+:} false; then : |
2b601678 MK |
7740 | $as_echo_n "(cached) " >&6 |
7741 | else | |
7742 | if test "$cross_compiling" = yes; then : | |
7743 | ac_cv_func_mmap_fixed_mapped=no | |
7744 | else | |
7745 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7746 | /* end confdefs.h. */ | |
7747 | $ac_includes_default | |
7748 | /* malloc might have been renamed as rpl_malloc. */ | |
7749 | #undef malloc | |
7750 | ||
7751 | /* Thanks to Mike Haertel and Jim Avera for this test. | |
7752 | Here is a matrix of mmap possibilities: | |
7753 | mmap private not fixed | |
7754 | mmap private fixed at somewhere currently unmapped | |
7755 | mmap private fixed at somewhere already mapped | |
7756 | mmap shared not fixed | |
7757 | mmap shared fixed at somewhere currently unmapped | |
7758 | mmap shared fixed at somewhere already mapped | |
7759 | For private mappings, we should verify that changes cannot be read() | |
7760 | back from the file, nor mmap's back from the file at a different | |
7761 | address. (There have been systems where private was not correctly | |
7762 | implemented like the infamous i386 svr4.0, and systems where the | |
7763 | VM page cache was not coherent with the file system buffer cache | |
7764 | like early versions of FreeBSD and possibly contemporary NetBSD.) | |
7765 | For shared mappings, we should conversely verify that changes get | |
7766 | propagated back to all the places they're supposed to be. | |
7767 | ||
7768 | Grep wants private fixed already mapped. | |
7769 | The main things grep needs to know about mmap are: | |
7770 | * does it exist and is it safe to write into the mmap'd area | |
7771 | * how to use it (BSD variants) */ | |
7772 | ||
7773 | #include <fcntl.h> | |
7774 | #include <sys/mman.h> | |
7775 | ||
7776 | #if !defined STDC_HEADERS && !defined HAVE_STDLIB_H | |
7777 | char *malloc (); | |
7778 | #endif | |
7779 | ||
7780 | /* This mess was copied from the GNU getpagesize.h. */ | |
7781 | #ifndef HAVE_GETPAGESIZE | |
2b601678 MK |
7782 | # ifdef _SC_PAGESIZE |
7783 | # define getpagesize() sysconf(_SC_PAGESIZE) | |
7784 | # else /* no _SC_PAGESIZE */ | |
7785 | # ifdef HAVE_SYS_PARAM_H | |
7786 | # include <sys/param.h> | |
7787 | # ifdef EXEC_PAGESIZE | |
7788 | # define getpagesize() EXEC_PAGESIZE | |
7789 | # else /* no EXEC_PAGESIZE */ | |
7790 | # ifdef NBPG | |
7791 | # define getpagesize() NBPG * CLSIZE | |
7792 | # ifndef CLSIZE | |
7793 | # define CLSIZE 1 | |
7794 | # endif /* no CLSIZE */ | |
7795 | # else /* no NBPG */ | |
7796 | # ifdef NBPC | |
7797 | # define getpagesize() NBPC | |
7798 | # else /* no NBPC */ | |
7799 | # ifdef PAGESIZE | |
7800 | # define getpagesize() PAGESIZE | |
7801 | # endif /* PAGESIZE */ | |
7802 | # endif /* no NBPC */ | |
7803 | # endif /* no NBPG */ | |
7804 | # endif /* no EXEC_PAGESIZE */ | |
7805 | # else /* no HAVE_SYS_PARAM_H */ | |
7806 | # define getpagesize() 8192 /* punt totally */ | |
7807 | # endif /* no HAVE_SYS_PARAM_H */ | |
7808 | # endif /* no _SC_PAGESIZE */ | |
7809 | ||
7810 | #endif /* no HAVE_GETPAGESIZE */ | |
7811 | ||
7812 | int | |
7813 | main () | |
7814 | { | |
7815 | char *data, *data2, *data3; | |
22e05272 | 7816 | const char *cdata2; |
2b601678 | 7817 | int i, pagesize; |
22e05272 | 7818 | int fd, fd2; |
2b601678 MK |
7819 | |
7820 | pagesize = getpagesize (); | |
7821 | ||
7822 | /* First, make a file with some known garbage in it. */ | |
7823 | data = (char *) malloc (pagesize); | |
7824 | if (!data) | |
7825 | return 1; | |
7826 | for (i = 0; i < pagesize; ++i) | |
7827 | *(data + i) = rand (); | |
7828 | umask (0); | |
7829 | fd = creat ("conftest.mmap", 0600); | |
7830 | if (fd < 0) | |
22e05272 | 7831 | return 2; |
2b601678 | 7832 | if (write (fd, data, pagesize) != pagesize) |
22e05272 | 7833 | return 3; |
2b601678 MK |
7834 | close (fd); |
7835 | ||
22e05272 JM |
7836 | /* Next, check that the tail of a page is zero-filled. File must have |
7837 | non-zero length, otherwise we risk SIGBUS for entire page. */ | |
7838 | fd2 = open ("conftest.txt", O_RDWR | O_CREAT | O_TRUNC, 0600); | |
7839 | if (fd2 < 0) | |
7840 | return 4; | |
7841 | cdata2 = ""; | |
7842 | if (write (fd2, cdata2, 1) != 1) | |
7843 | return 5; | |
7844 | data2 = (char *) mmap (0, pagesize, PROT_READ | PROT_WRITE, MAP_SHARED, fd2, 0L); | |
7845 | if (data2 == MAP_FAILED) | |
7846 | return 6; | |
7847 | for (i = 0; i < pagesize; ++i) | |
7848 | if (*(data2 + i)) | |
7849 | return 7; | |
7850 | close (fd2); | |
7851 | if (munmap (data2, pagesize)) | |
7852 | return 8; | |
7853 | ||
2b601678 MK |
7854 | /* Next, try to mmap the file at a fixed address which already has |
7855 | something else allocated at it. If we can, also make sure that | |
7856 | we see the same garbage. */ | |
7857 | fd = open ("conftest.mmap", O_RDWR); | |
7858 | if (fd < 0) | |
22e05272 | 7859 | return 9; |
2b601678 MK |
7860 | if (data2 != mmap (data2, pagesize, PROT_READ | PROT_WRITE, |
7861 | MAP_PRIVATE | MAP_FIXED, fd, 0L)) | |
22e05272 | 7862 | return 10; |
2b601678 MK |
7863 | for (i = 0; i < pagesize; ++i) |
7864 | if (*(data + i) != *(data2 + i)) | |
22e05272 | 7865 | return 11; |
2b601678 MK |
7866 | |
7867 | /* Finally, make sure that changes to the mapped area do not | |
7868 | percolate back to the file as seen by read(). (This is a bug on | |
7869 | some variants of i386 svr4.0.) */ | |
7870 | for (i = 0; i < pagesize; ++i) | |
7871 | *(data2 + i) = *(data2 + i) + 1; | |
7872 | data3 = (char *) malloc (pagesize); | |
7873 | if (!data3) | |
22e05272 | 7874 | return 12; |
2b601678 | 7875 | if (read (fd, data3, pagesize) != pagesize) |
22e05272 | 7876 | return 13; |
2b601678 MK |
7877 | for (i = 0; i < pagesize; ++i) |
7878 | if (*(data + i) != *(data3 + i)) | |
22e05272 | 7879 | return 14; |
2b601678 MK |
7880 | close (fd); |
7881 | return 0; | |
7882 | } | |
7883 | _ACEOF | |
7884 | if ac_fn_c_try_run "$LINENO"; then : | |
7885 | ac_cv_func_mmap_fixed_mapped=yes | |
7886 | else | |
7887 | ac_cv_func_mmap_fixed_mapped=no | |
7888 | fi | |
7889 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
7890 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7891 | fi | |
7892 | ||
7893 | fi | |
7894 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_mmap_fixed_mapped" >&5 | |
7895 | $as_echo "$ac_cv_func_mmap_fixed_mapped" >&6; } | |
7896 | if test $ac_cv_func_mmap_fixed_mapped = yes; then | |
7897 | ||
7898 | $as_echo "#define HAVE_MMAP 1" >>confdefs.h | |
7899 | ||
7900 | fi | |
22e05272 | 7901 | rm -f conftest.mmap conftest.txt |
2b601678 MK |
7902 | |
7903 | fi | |
7904 | ||
7905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working strncmp" >&5 | |
7906 | $as_echo_n "checking for working strncmp... " >&6; } | |
22e05272 | 7907 | if ${ac_cv_func_strncmp_works+:} false; then : |
2b601678 MK |
7908 | $as_echo_n "(cached) " >&6 |
7909 | else | |
7910 | if test "$cross_compiling" = yes; then : | |
7911 | ac_cv_func_strncmp_works=yes | |
7912 | else | |
7913 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7914 | /* end confdefs.h. */ | |
7915 | ||
7916 | /* Test by Jim Wilson and Kaveh Ghazi. | |
7917 | Check whether strncmp reads past the end of its string parameters. */ | |
885b6660 FW |
7918 | #include <stdlib.h> |
7919 | #include <string.h> | |
2b601678 MK |
7920 | #include <sys/types.h> |
7921 | ||
7922 | #ifdef HAVE_FCNTL_H | |
7923 | #include <fcntl.h> | |
7924 | #endif | |
7925 | ||
7926 | #ifdef HAVE_SYS_MMAN_H | |
7927 | #include <sys/mman.h> | |
7928 | #endif | |
7929 | ||
7930 | #ifndef MAP_ANON | |
7931 | #ifdef MAP_ANONYMOUS | |
7932 | #define MAP_ANON MAP_ANONYMOUS | |
7933 | #else | |
7934 | #define MAP_ANON MAP_FILE | |
7935 | #endif | |
7936 | #endif | |
7937 | ||
7938 | #ifndef MAP_FILE | |
7939 | #define MAP_FILE 0 | |
7940 | #endif | |
7941 | #ifndef O_RDONLY | |
7942 | #define O_RDONLY 0 | |
7943 | #endif | |
7944 | ||
7945 | #define MAP_LEN 0x10000 | |
7946 | ||
885b6660 FW |
7947 | int |
7948 | main (void) | |
2b601678 MK |
7949 | { |
7950 | #if defined(HAVE_MMAP) || defined(HAVE_MMAP_ANYWHERE) | |
7951 | char *p; | |
7952 | int dev_zero; | |
7953 | ||
7954 | dev_zero = open ("/dev/zero", O_RDONLY); | |
7955 | if (dev_zero < 0) | |
7956 | exit (1); | |
7957 | ||
7958 | p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE, | |
7959 | MAP_ANON|MAP_PRIVATE, dev_zero, 0); | |
7960 | if (p == (char *)-1) | |
7961 | p = (char *) mmap (0, MAP_LEN, PROT_READ|PROT_WRITE, | |
7962 | MAP_ANON|MAP_PRIVATE, -1, 0); | |
7963 | if (p == (char *)-1) | |
7964 | exit (2); | |
7965 | else | |
7966 | { | |
7967 | char *string = "__si_type_info"; | |
7968 | char *q = (char *) p + MAP_LEN - strlen (string) - 2; | |
7969 | char *r = (char *) p + 0xe; | |
7970 | ||
7971 | strcpy (q, string); | |
7972 | strcpy (r, string); | |
7973 | strncmp (r, q, 14); | |
7974 | } | |
7975 | #endif /* HAVE_MMAP || HAVE_MMAP_ANYWHERE */ | |
7976 | exit (0); | |
7977 | } | |
7978 | ||
7979 | _ACEOF | |
7980 | if ac_fn_c_try_run "$LINENO"; then : | |
7981 | ac_cv_func_strncmp_works=yes | |
7982 | else | |
7983 | ac_cv_func_strncmp_works=no | |
7984 | fi | |
7985 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
7986 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
7987 | fi | |
7988 | ||
7989 | rm -f core core.* *.core | |
7990 | fi | |
7991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_strncmp_works" >&5 | |
7992 | $as_echo "$ac_cv_func_strncmp_works" >&6; } | |
7993 | if test $ac_cv_func_strncmp_works = no ; then | |
7994 | case " $LIBOBJS " in | |
7995 | *" strncmp.$ac_objext "* ) ;; | |
7996 | *) LIBOBJS="$LIBOBJS strncmp.$ac_objext" | |
7997 | ;; | |
7998 | esac | |
7999 | ||
8000 | fi | |
8001 | ||
a9266bfa | 8002 | |
0bc0cd11 JL |
8003 | # Install a library built with a cross compiler in $(tooldir) rather |
8004 | # than $(libdir). | |
ca6b370d | 8005 | if test -z "${with_cross_host}"; then |
0bc0cd11 JL |
8006 | INSTALL_DEST=libdir |
8007 | else | |
8008 | INSTALL_DEST=tooldir | |
8009 | fi | |
8010 | ||
8011 | ||
ad49d865 L |
8012 | |
8013 | L="" | |
8014 | for l in x $LIBOBJS; do | |
8015 | case $l in | |
8016 | x) ;; | |
8017 | *) L="$L ./$l" ;; | |
8018 | esac | |
8019 | done | |
8020 | LIBOBJS="$L" | |
8021 | ||
cf61af07 CD |
8022 | |
8023 | ||
8024 | ||
8025 | ||
0bc0cd11 | 8026 | # We need multilib support, but only if configuring for the target. |
5213506e | 8027 | ac_config_files="$ac_config_files Makefile testsuite/Makefile" |
9bf3c9cc | 8028 | |
5213506e | 8029 | ac_config_commands="$ac_config_commands default" |
9bf3c9cc | 8030 | |
238235ef | 8031 | cat >confcache <<\_ACEOF |
0bc0cd11 JL |
8032 | # This file is a shell script that caches the results of configure |
8033 | # tests run on this system so they can be shared between configure | |
238235ef DJ |
8034 | # scripts and configure runs, see configure's option --config-cache. |
8035 | # It is not useful on other systems. If it contains results you don't | |
8036 | # want to keep, you may remove or edit it. | |
0bc0cd11 | 8037 | # |
238235ef DJ |
8038 | # config.status only pays attention to the cache file if you give it |
8039 | # the --recheck option to rerun configure. | |
0bc0cd11 | 8040 | # |
238235ef DJ |
8041 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
8042 | # loading this file, other *unset* `ac_cv_foo' will be assigned the | |
8043 | # following values. | |
8044 | ||
8045 | _ACEOF | |
8046 | ||
0bc0cd11 JL |
8047 | # The following way of writing the cache mishandles newlines in values, |
8048 | # but we know of no workaround that is simple, portable, and efficient. | |
5213506e | 8049 | # So, we kill variables containing newlines. |
0bc0cd11 JL |
8050 | # Ultrix sh set writes to stderr and can't be redirected directly, |
8051 | # and sets the high bit in the cache file unless we assign to the vars. | |
5213506e RW |
8052 | ( |
8053 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
8054 | eval ac_val=\$$ac_var | |
8055 | case $ac_val in #( | |
8056 | *${as_nl}*) | |
8057 | case $ac_var in #( | |
8058 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
8059 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
8060 | esac | |
8061 | case $ac_var in #( | |
8062 | _ | IFS | as_nl) ;; #( | |
8063 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
8064 | *) { eval $ac_var=; unset $ac_var;} ;; | |
8065 | esac ;; | |
8066 | esac | |
8067 | done | |
8068 | ||
238235ef | 8069 | (set) 2>&1 | |
5213506e RW |
8070 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
8071 | *${as_nl}ac_space=\ *) | |
8072 | # `set' does not quote correctly, so add quotes: double-quote | |
8073 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
238235ef | 8074 | sed -n \ |
3beb1315 HPN |
8075 | "s/'/'\\\\''/g; |
8076 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
5213506e | 8077 | ;; #( |
238235ef DJ |
8078 | *) |
8079 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
5213506e | 8080 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
238235ef | 8081 | ;; |
5213506e RW |
8082 | esac | |
8083 | sort | |
8084 | ) | | |
238235ef | 8085 | sed ' |
5213506e | 8086 | /^ac_cv_env_/b end |
238235ef | 8087 | t clear |
5213506e | 8088 | :clear |
238235ef DJ |
8089 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
8090 | t end | |
5213506e RW |
8091 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
8092 | :end' >>confcache | |
8093 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
8094 | if test -w "$cache_file"; then | |
22e05272 | 8095 | if test "x$cache_file" != "x/dev/null"; then |
5213506e RW |
8096 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 |
8097 | $as_echo "$as_me: updating cache $cache_file" >&6;} | |
22e05272 JM |
8098 | if test ! -f "$cache_file" || test -h "$cache_file"; then |
8099 | cat confcache >"$cache_file" | |
8100 | else | |
8101 | case $cache_file in #( | |
8102 | */* | ?:*) | |
8103 | mv -f confcache "$cache_file"$$ && | |
8104 | mv -f "$cache_file"$$ "$cache_file" ;; #( | |
8105 | *) | |
8106 | mv -f confcache "$cache_file" ;; | |
8107 | esac | |
8108 | fi | |
8109 | fi | |
0bc0cd11 | 8110 | else |
5213506e RW |
8111 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
8112 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} | |
0bc0cd11 JL |
8113 | fi |
8114 | fi | |
8115 | rm -f confcache | |
8116 | ||
0bc0cd11 JL |
8117 | test "x$prefix" = xNONE && prefix=$ac_default_prefix |
8118 | # Let make expand exec_prefix. | |
8119 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
8120 | ||
0bc0cd11 JL |
8121 | DEFS=-DHAVE_CONFIG_H |
8122 | ||
238235ef DJ |
8123 | ac_libobjs= |
8124 | ac_ltlibobjs= | |
22e05272 | 8125 | U= |
238235ef DJ |
8126 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue |
8127 | # 1. Remove the extension, and $U if already installed. | |
5213506e RW |
8128 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
8129 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` | |
8130 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR | |
8131 | # will be set to the directory where LIBOBJS objects are built. | |
8132 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" | |
8133 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
238235ef DJ |
8134 | done |
8135 | LIBOBJS=$ac_libobjs | |
0bc0cd11 | 8136 | |
238235ef DJ |
8137 | LTLIBOBJS=$ac_ltlibobjs |
8138 | ||
8139 | ||
8140 | ||
5213506e | 8141 | |
22e05272 | 8142 | : "${CONFIG_STATUS=./config.status}" |
5213506e | 8143 | ac_write_fail=0 |
238235ef DJ |
8144 | ac_clean_files_save=$ac_clean_files |
8145 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
5213506e RW |
8146 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
8147 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} | |
8148 | as_write_fail=0 | |
8149 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
238235ef DJ |
8150 | #! $SHELL |
8151 | # Generated by $as_me. | |
0bc0cd11 | 8152 | # Run this file to recreate the current configuration. |
0bc0cd11 | 8153 | # Compiler output produced by configure, useful for debugging |
238235ef | 8154 | # configure, is in config.log if it exists. |
0bc0cd11 | 8155 | |
238235ef DJ |
8156 | debug=false |
8157 | ac_cs_recheck=false | |
8158 | ac_cs_silent=false | |
238235ef | 8159 | |
5213506e RW |
8160 | SHELL=\${CONFIG_SHELL-$SHELL} |
8161 | export SHELL | |
8162 | _ASEOF | |
8163 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
8164 | ## -------------------- ## | |
8165 | ## M4sh Initialization. ## | |
8166 | ## -------------------- ## | |
8167 | ||
8168 | # Be more Bourne compatible | |
8169 | DUALCASE=1; export DUALCASE # for MKS sh | |
8170 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
238235ef DJ |
8171 | emulate sh |
8172 | NULLCMD=: | |
5213506e | 8173 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
238235ef DJ |
8174 | # is contrary to our usage. Disable this feature. |
8175 | alias -g '${1+"$@"}'='"$@"' | |
5213506e RW |
8176 | setopt NO_GLOB_SUBST |
8177 | else | |
8178 | case `(set -o) 2>/dev/null` in #( | |
8179 | *posix*) : | |
8180 | set -o posix ;; #( | |
8181 | *) : | |
8182 | ;; | |
8183 | esac | |
238235ef DJ |
8184 | fi |
8185 | ||
5213506e RW |
8186 | |
8187 | as_nl=' | |
8188 | ' | |
8189 | export as_nl | |
8190 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
8191 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
8192 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
8193 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
8194 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
8195 | # but without wasting forks for bash or zsh. | |
8196 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
8197 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
8198 | as_echo='print -r --' | |
8199 | as_echo_n='print -rn --' | |
8200 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
8201 | as_echo='printf %s\n' | |
8202 | as_echo_n='printf %s' | |
8203 | else | |
8204 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
8205 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
8206 | as_echo_n='/usr/ucb/echo -n' | |
8207 | else | |
8208 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
8209 | as_echo_n_body='eval | |
8210 | arg=$1; | |
8211 | case $arg in #( | |
8212 | *"$as_nl"*) | |
8213 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
8214 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
8215 | esac; | |
8216 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
8217 | ' | |
8218 | export as_echo_n_body | |
8219 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
8220 | fi | |
8221 | export as_echo_body | |
8222 | as_echo='sh -c $as_echo_body as_echo' | |
8223 | fi | |
8224 | ||
8225 | # The user is always right. | |
8226 | if test "${PATH_SEPARATOR+set}" != set; then | |
8227 | PATH_SEPARATOR=: | |
8228 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
8229 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
8230 | PATH_SEPARATOR=';' | |
8231 | } | |
238235ef DJ |
8232 | fi |
8233 | ||
8234 | ||
5213506e RW |
8235 | # IFS |
8236 | # We need space, tab and new line, in precisely that order. Quoting is | |
8237 | # there to prevent editors from complaining about space-tab. | |
8238 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
8239 | # splitting by setting IFS to empty value.) | |
8240 | IFS=" "" $as_nl" | |
8241 | ||
8242 | # Find who we are. Look in the path if we contain no directory separator. | |
22e05272 | 8243 | as_myself= |
5213506e RW |
8244 | case $0 in #(( |
8245 | *[\\/]* ) as_myself=$0 ;; | |
8246 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
8247 | for as_dir in $PATH | |
8248 | do | |
8249 | IFS=$as_save_IFS | |
8250 | test -z "$as_dir" && as_dir=. | |
8251 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
8252 | done | |
8253 | IFS=$as_save_IFS | |
8254 | ||
8255 | ;; | |
8256 | esac | |
8257 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
8258 | # in which case we are not to be found in the path. | |
8259 | if test "x$as_myself" = x; then | |
8260 | as_myself=$0 | |
8261 | fi | |
8262 | if test ! -f "$as_myself"; then | |
8263 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
8264 | exit 1 | |
8265 | fi | |
8266 | ||
8267 | # Unset variables that we do not need and which cause bugs (e.g. in | |
8268 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
8269 | # suppresses any "Segmentation fault" message there. '((' could | |
8270 | # trigger a bug in pdksh 5.2.14. | |
8271 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
8272 | do eval test x\${$as_var+set} = xset \ | |
8273 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
8274 | done | |
238235ef DJ |
8275 | PS1='$ ' |
8276 | PS2='> ' | |
8277 | PS4='+ ' | |
8278 | ||
8279 | # NLS nuisances. | |
5213506e RW |
8280 | LC_ALL=C |
8281 | export LC_ALL | |
8282 | LANGUAGE=C | |
8283 | export LANGUAGE | |
8284 | ||
8285 | # CDPATH. | |
8286 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
8287 | ||
8288 | ||
22e05272 JM |
8289 | # as_fn_error STATUS ERROR [LINENO LOG_FD] |
8290 | # ---------------------------------------- | |
5213506e RW |
8291 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are |
8292 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
22e05272 | 8293 | # script with STATUS, using 1 if that was 0. |
5213506e RW |
8294 | as_fn_error () |
8295 | { | |
22e05272 JM |
8296 | as_status=$1; test $as_status -eq 0 && as_status=1 |
8297 | if test "$4"; then | |
8298 | as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
8299 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 | |
238235ef | 8300 | fi |
22e05272 | 8301 | $as_echo "$as_me: error: $2" >&2 |
5213506e RW |
8302 | as_fn_exit $as_status |
8303 | } # as_fn_error | |
8304 | ||
8305 | ||
8306 | # as_fn_set_status STATUS | |
8307 | # ----------------------- | |
8308 | # Set $? to STATUS, without forking. | |
8309 | as_fn_set_status () | |
8310 | { | |
8311 | return $1 | |
8312 | } # as_fn_set_status | |
8313 | ||
8314 | # as_fn_exit STATUS | |
8315 | # ----------------- | |
8316 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
8317 | as_fn_exit () | |
8318 | { | |
8319 | set +e | |
8320 | as_fn_set_status $1 | |
8321 | exit $1 | |
8322 | } # as_fn_exit | |
8323 | ||
8324 | # as_fn_unset VAR | |
8325 | # --------------- | |
8326 | # Portably unset VAR. | |
8327 | as_fn_unset () | |
8328 | { | |
8329 | { eval $1=; unset $1;} | |
8330 | } | |
8331 | as_unset=as_fn_unset | |
8332 | # as_fn_append VAR VALUE | |
8333 | # ---------------------- | |
8334 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
8335 | # advantage of any shell optimizations that allow amortized linear growth over | |
8336 | # repeated appends, instead of the typical quadratic growth present in naive | |
8337 | # implementations. | |
8338 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
8339 | eval 'as_fn_append () | |
8340 | { | |
8341 | eval $1+=\$2 | |
8342 | }' | |
8343 | else | |
8344 | as_fn_append () | |
8345 | { | |
8346 | eval $1=\$$1\$2 | |
8347 | } | |
8348 | fi # as_fn_append | |
8349 | ||
8350 | # as_fn_arith ARG... | |
8351 | # ------------------ | |
8352 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
8353 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
8354 | # must be portable across $(()) and expr. | |
8355 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
8356 | eval 'as_fn_arith () | |
8357 | { | |
8358 | as_val=$(( $* )) | |
8359 | }' | |
8360 | else | |
8361 | as_fn_arith () | |
8362 | { | |
8363 | as_val=`expr "$@" || test $? -eq 1` | |
8364 | } | |
8365 | fi # as_fn_arith | |
8366 | ||
0bc0cd11 | 8367 | |
5213506e RW |
8368 | if expr a : '\(a\)' >/dev/null 2>&1 && |
8369 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
238235ef DJ |
8370 | as_expr=expr |
8371 | else | |
8372 | as_expr=false | |
8373 | fi | |
0bc0cd11 | 8374 | |
5213506e | 8375 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
238235ef DJ |
8376 | as_basename=basename |
8377 | else | |
8378 | as_basename=false | |
8379 | fi | |
0bc0cd11 | 8380 | |
5213506e RW |
8381 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
8382 | as_dirname=dirname | |
8383 | else | |
8384 | as_dirname=false | |
8385 | fi | |
0bc0cd11 | 8386 | |
5213506e | 8387 | as_me=`$as_basename -- "$0" || |
238235ef DJ |
8388 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
8389 | X"$0" : 'X\(//\)$' \| \ | |
5213506e RW |
8390 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
8391 | $as_echo X/"$0" | | |
8392 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
8393 | s//\1/ | |
8394 | q | |
8395 | } | |
8396 | /^X\/\(\/\/\)$/{ | |
8397 | s//\1/ | |
8398 | q | |
8399 | } | |
8400 | /^X\/\(\/\).*/{ | |
8401 | s//\1/ | |
8402 | q | |
8403 | } | |
8404 | s/.*/./; q'` | |
238235ef | 8405 | |
238235ef DJ |
8406 | # Avoid depending upon Character Ranges. |
8407 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
8408 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
8409 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
8410 | as_cr_digits='0123456789' | |
8411 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
0bc0cd11 | 8412 | |
5213506e RW |
8413 | ECHO_C= ECHO_N= ECHO_T= |
8414 | case `echo -n x` in #((((( | |
8415 | -n*) | |
8416 | case `echo 'xy\c'` in | |
8417 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
8418 | xy) ECHO_C='\c';; | |
8419 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
8420 | ECHO_T=' ';; | |
8421 | esac;; | |
8422 | *) | |
8423 | ECHO_N='-n';; | |
238235ef DJ |
8424 | esac |
8425 | ||
5213506e RW |
8426 | rm -f conf$$ conf$$.exe conf$$.file |
8427 | if test -d conf$$.dir; then | |
8428 | rm -f conf$$.dir/conf$$.file | |
238235ef | 8429 | else |
5213506e RW |
8430 | rm -f conf$$.dir |
8431 | mkdir conf$$.dir 2>/dev/null | |
238235ef | 8432 | fi |
5213506e RW |
8433 | if (echo >conf$$.file) 2>/dev/null; then |
8434 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
238235ef | 8435 | as_ln_s='ln -s' |
5213506e RW |
8436 | # ... but there are two gotchas: |
8437 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
8438 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
22e05272 | 8439 | # In both cases, we have to default to `cp -pR'. |
5213506e | 8440 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || |
22e05272 | 8441 | as_ln_s='cp -pR' |
5213506e RW |
8442 | elif ln conf$$.file conf$$ 2>/dev/null; then |
8443 | as_ln_s=ln | |
8444 | else | |
22e05272 | 8445 | as_ln_s='cp -pR' |
0bc0cd11 | 8446 | fi |
238235ef | 8447 | else |
22e05272 | 8448 | as_ln_s='cp -pR' |
238235ef | 8449 | fi |
5213506e RW |
8450 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
8451 | rmdir conf$$.dir 2>/dev/null | |
8452 | ||
8453 | ||
8454 | # as_fn_mkdir_p | |
8455 | # ------------- | |
8456 | # Create "$as_dir" as a directory, including parents if necessary. | |
8457 | as_fn_mkdir_p () | |
8458 | { | |
8459 | ||
8460 | case $as_dir in #( | |
8461 | -*) as_dir=./$as_dir;; | |
8462 | esac | |
8463 | test -d "$as_dir" || eval $as_mkdir_p || { | |
8464 | as_dirs= | |
8465 | while :; do | |
8466 | case $as_dir in #( | |
8467 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
8468 | *) as_qdir=$as_dir;; | |
8469 | esac | |
8470 | as_dirs="'$as_qdir' $as_dirs" | |
8471 | as_dir=`$as_dirname -- "$as_dir" || | |
8472 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
8473 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
8474 | X"$as_dir" : 'X\(//\)$' \| \ | |
8475 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
8476 | $as_echo X"$as_dir" | | |
8477 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
8478 | s//\1/ | |
8479 | q | |
8480 | } | |
8481 | /^X\(\/\/\)[^/].*/{ | |
8482 | s//\1/ | |
8483 | q | |
8484 | } | |
8485 | /^X\(\/\/\)$/{ | |
8486 | s//\1/ | |
8487 | q | |
8488 | } | |
8489 | /^X\(\/\).*/{ | |
8490 | s//\1/ | |
8491 | q | |
8492 | } | |
8493 | s/.*/./; q'` | |
8494 | test -d "$as_dir" && break | |
8495 | done | |
8496 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
22e05272 | 8497 | } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" |
238235ef | 8498 | |
5213506e RW |
8499 | |
8500 | } # as_fn_mkdir_p | |
238235ef | 8501 | if mkdir -p . 2>/dev/null; then |
5213506e | 8502 | as_mkdir_p='mkdir -p "$as_dir"' |
238235ef | 8503 | else |
3beb1315 | 8504 | test -d ./-p && rmdir ./-p |
238235ef DJ |
8505 | as_mkdir_p=false |
8506 | fi | |
8507 | ||
22e05272 JM |
8508 | |
8509 | # as_fn_executable_p FILE | |
8510 | # ----------------------- | |
8511 | # Test if FILE is an executable regular file. | |
8512 | as_fn_executable_p () | |
8513 | { | |
8514 | test -f "$1" && test -x "$1" | |
8515 | } # as_fn_executable_p | |
8516 | as_test_x='test -x' | |
8517 | as_executable_p=as_fn_executable_p | |
238235ef DJ |
8518 | |
8519 | # Sed expression to map a string onto a valid CPP name. | |
3beb1315 | 8520 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
238235ef DJ |
8521 | |
8522 | # Sed expression to map a string onto a valid variable name. | |
3beb1315 | 8523 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
238235ef DJ |
8524 | |
8525 | ||
238235ef | 8526 | exec 6>&1 |
5213506e RW |
8527 | ## ----------------------------------- ## |
8528 | ## Main body of $CONFIG_STATUS script. ## | |
8529 | ## ----------------------------------- ## | |
8530 | _ASEOF | |
8531 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
8532 | ||
8533 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
8534 | # Save the log message, to keep $0 and so on meaningful, and to | |
238235ef | 8535 | # report actual input values of CONFIG_FILES etc. instead of their |
5213506e RW |
8536 | # values after options handling. |
8537 | ac_log=" | |
238235ef | 8538 | This file was extended by $as_me, which was |
22e05272 | 8539 | generated by GNU Autoconf 2.69. Invocation command line was |
238235ef DJ |
8540 | |
8541 | CONFIG_FILES = $CONFIG_FILES | |
8542 | CONFIG_HEADERS = $CONFIG_HEADERS | |
8543 | CONFIG_LINKS = $CONFIG_LINKS | |
8544 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
8545 | $ $0 $@ | |
8546 | ||
5213506e RW |
8547 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
8548 | " | |
8549 | ||
238235ef DJ |
8550 | _ACEOF |
8551 | ||
5213506e RW |
8552 | case $ac_config_files in *" |
8553 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
8554 | esac | |
238235ef | 8555 | |
5213506e RW |
8556 | case $ac_config_headers in *" |
8557 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
8558 | esac | |
238235ef | 8559 | |
238235ef | 8560 | |
5213506e RW |
8561 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
8562 | # Files that config.status was made for. | |
8563 | config_files="$ac_config_files" | |
8564 | config_headers="$ac_config_headers" | |
8565 | config_commands="$ac_config_commands" | |
238235ef | 8566 | |
5213506e | 8567 | _ACEOF |
238235ef | 8568 | |
5213506e | 8569 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
238235ef | 8570 | ac_cs_usage="\ |
5213506e RW |
8571 | \`$as_me' instantiates files and other configuration actions |
8572 | from templates according to the current configuration. Unless the files | |
8573 | and actions are specified as TAGs, all are instantiated by default. | |
238235ef | 8574 | |
5213506e | 8575 | Usage: $0 [OPTION]... [TAG]... |
238235ef DJ |
8576 | |
8577 | -h, --help print this help, then exit | |
5213506e | 8578 | -V, --version print version number and configuration settings, then exit |
22e05272 | 8579 | --config print configuration, then exit |
5213506e RW |
8580 | -q, --quiet, --silent |
8581 | do not print progress messages | |
238235ef DJ |
8582 | -d, --debug don't remove temporary files |
8583 | --recheck update $as_me by reconfiguring in the same conditions | |
5213506e RW |
8584 | --file=FILE[:TEMPLATE] |
8585 | instantiate the configuration file FILE | |
8586 | --header=FILE[:TEMPLATE] | |
8587 | instantiate the configuration header FILE | |
238235ef DJ |
8588 | |
8589 | Configuration files: | |
8590 | $config_files | |
8591 | ||
8592 | Configuration headers: | |
8593 | $config_headers | |
8594 | ||
8595 | Configuration commands: | |
8596 | $config_commands | |
8597 | ||
5213506e | 8598 | Report bugs to the package provider." |
238235ef | 8599 | |
5213506e RW |
8600 | _ACEOF |
8601 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
22e05272 | 8602 | ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" |
238235ef DJ |
8603 | ac_cs_version="\\ |
8604 | config.status | |
22e05272 JM |
8605 | configured by $0, generated by GNU Autoconf 2.69, |
8606 | with options \\"\$ac_cs_config\\" | |
238235ef | 8607 | |
22e05272 | 8608 | Copyright (C) 2012 Free Software Foundation, Inc. |
238235ef DJ |
8609 | This config.status script is free software; the Free Software Foundation |
8610 | gives unlimited permission to copy, distribute and modify it." | |
5213506e RW |
8611 | |
8612 | ac_pwd='$ac_pwd' | |
8613 | srcdir='$srcdir' | |
8614 | INSTALL='$INSTALL' | |
8615 | test -n "\$AWK" || AWK=awk | |
238235ef DJ |
8616 | _ACEOF |
8617 | ||
5213506e RW |
8618 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
8619 | # The default lists apply if the user does not specify any file. | |
238235ef DJ |
8620 | ac_need_defaults=: |
8621 | while test $# != 0 | |
8622 | do | |
8623 | case $1 in | |
22e05272 | 8624 | --*=?*) |
5213506e RW |
8625 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
8626 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
238235ef DJ |
8627 | ac_shift=: |
8628 | ;; | |
22e05272 JM |
8629 | --*=) |
8630 | ac_option=`expr "X$1" : 'X\([^=]*\)='` | |
8631 | ac_optarg= | |
8632 | ac_shift=: | |
8633 | ;; | |
5213506e | 8634 | *) |
238235ef DJ |
8635 | ac_option=$1 |
8636 | ac_optarg=$2 | |
8637 | ac_shift=shift | |
8638 | ;; | |
238235ef DJ |
8639 | esac |
8640 | ||
8641 | case $ac_option in | |
8642 | # Handling of the options. | |
238235ef DJ |
8643 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
8644 | ac_cs_recheck=: ;; | |
5213506e RW |
8645 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
8646 | $as_echo "$ac_cs_version"; exit ;; | |
22e05272 JM |
8647 | --config | --confi | --conf | --con | --co | --c ) |
8648 | $as_echo "$ac_cs_config"; exit ;; | |
5213506e | 8649 | --debug | --debu | --deb | --de | --d | -d ) |
238235ef DJ |
8650 | debug=: ;; |
8651 | --file | --fil | --fi | --f ) | |
8652 | $ac_shift | |
5213506e RW |
8653 | case $ac_optarg in |
8654 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
22e05272 | 8655 | '') as_fn_error $? "missing file argument" ;; |
5213506e RW |
8656 | esac |
8657 | as_fn_append CONFIG_FILES " '$ac_optarg'" | |
238235ef DJ |
8658 | ac_need_defaults=false;; |
8659 | --header | --heade | --head | --hea ) | |
8660 | $ac_shift | |
5213506e RW |
8661 | case $ac_optarg in |
8662 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
8663 | esac | |
8664 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" | |
238235ef | 8665 | ac_need_defaults=false;; |
5213506e RW |
8666 | --he | --h) |
8667 | # Conflict between --help and --header | |
22e05272 | 8668 | as_fn_error $? "ambiguous option: \`$1' |
5213506e RW |
8669 | Try \`$0 --help' for more information.";; |
8670 | --help | --hel | -h ) | |
8671 | $as_echo "$ac_cs_usage"; exit ;; | |
238235ef DJ |
8672 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
8673 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
8674 | ac_cs_silent=: ;; | |
8675 | ||
8676 | # This is an error. | |
22e05272 | 8677 | -*) as_fn_error $? "unrecognized option: \`$1' |
5213506e | 8678 | Try \`$0 --help' for more information." ;; |
238235ef | 8679 | |
5213506e RW |
8680 | *) as_fn_append ac_config_targets " $1" |
8681 | ac_need_defaults=false ;; | |
238235ef DJ |
8682 | |
8683 | esac | |
8684 | shift | |
0bc0cd11 | 8685 | done |
238235ef DJ |
8686 | |
8687 | ac_configure_extra_args= | |
8688 | ||
8689 | if $ac_cs_silent; then | |
8690 | exec 6>/dev/null | |
8691 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
0bc0cd11 | 8692 | fi |
0bc0cd11 | 8693 | |
238235ef | 8694 | _ACEOF |
5213506e | 8695 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
238235ef | 8696 | if \$ac_cs_recheck; then |
22e05272 | 8697 | set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
5213506e RW |
8698 | shift |
8699 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
8700 | CONFIG_SHELL='$SHELL' | |
8701 | export CONFIG_SHELL | |
8702 | exec "\$@" | |
238235ef | 8703 | fi |
0bc0cd11 | 8704 | |
238235ef | 8705 | _ACEOF |
5213506e RW |
8706 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
8707 | exec 5>>config.log | |
8708 | { | |
8709 | echo | |
8710 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
8711 | ## Running $as_me. ## | |
8712 | _ASBOX | |
8713 | $as_echo "$ac_log" | |
8714 | } >&5 | |
238235ef | 8715 | |
5213506e RW |
8716 | _ACEOF |
8717 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
238235ef | 8718 | # |
5213506e | 8719 | # INIT-COMMANDS |
238235ef | 8720 | # |
238235ef DJ |
8721 | srcdir=${srcdir} |
8722 | host=${host} | |
8723 | target=${target} | |
8724 | with_target_subdir=${with_target_subdir} | |
238235ef DJ |
8725 | with_multisubdir=${with_multisubdir} |
8726 | ac_configure_args="--enable-multilib ${ac_configure_args}" | |
8727 | CONFIG_SHELL=${CONFIG_SHELL-/bin/sh} | |
8728 | ORIGINAL_LD_FOR_MULTILIBS="${ORIGINAL_LD_FOR_MULTILIBS}" | |
8729 | libiberty_topdir=${libiberty_topdir} | |
8730 | ||
8731 | ||
8732 | _ACEOF | |
8733 | ||
5213506e | 8734 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
238235ef | 8735 | |
5213506e | 8736 | # Handling of arguments. |
238235ef DJ |
8737 | for ac_config_target in $ac_config_targets |
8738 | do | |
5213506e RW |
8739 | case $ac_config_target in |
8740 | "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h:config.in" ;; | |
8741 | "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;; | |
8742 | "testsuite/Makefile") CONFIG_FILES="$CONFIG_FILES testsuite/Makefile" ;; | |
8743 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; | |
8744 | ||
22e05272 | 8745 | *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; |
0bc0cd11 | 8746 | esac |
238235ef | 8747 | done |
0bc0cd11 | 8748 | |
5213506e | 8749 | |
238235ef DJ |
8750 | # If the user did not use the arguments to specify the items to instantiate, |
8751 | # then the envvar interface is used. Set only those that are not. | |
8752 | # We use the long form for the default assignment because of an extremely | |
8753 | # bizarre bug on SunOS 4.1.3. | |
8754 | if $ac_need_defaults; then | |
8755 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
8756 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
8757 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
8758 | fi | |
8759 | ||
8760 | # Have a temporary directory for convenience. Make it in the build tree | |
5213506e | 8761 | # simply because there is no reason against having it here, and in addition, |
238235ef | 8762 | # creating and moving files from /tmp can sometimes cause problems. |
5213506e RW |
8763 | # Hook for its removal unless debugging. |
8764 | # Note that there is a small window in which the directory will not be cleaned: | |
8765 | # after its creation but before its name has been assigned to `$tmp'. | |
238235ef DJ |
8766 | $debug || |
8767 | { | |
22e05272 | 8768 | tmp= ac_tmp= |
5213506e | 8769 | trap 'exit_status=$? |
22e05272 JM |
8770 | : "${ac_tmp:=$tmp}" |
8771 | { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status | |
5213506e RW |
8772 | ' 0 |
8773 | trap 'as_fn_exit 1' 1 2 13 15 | |
238235ef | 8774 | } |
238235ef DJ |
8775 | # Create a (secure) tmp directory for tmp files. |
8776 | ||
8777 | { | |
5213506e | 8778 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
22e05272 | 8779 | test -d "$tmp" |
238235ef DJ |
8780 | } || |
8781 | { | |
5213506e RW |
8782 | tmp=./conf$$-$RANDOM |
8783 | (umask 077 && mkdir "$tmp") | |
22e05272 JM |
8784 | } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 |
8785 | ac_tmp=$tmp | |
5213506e RW |
8786 | |
8787 | # Set up the scripts for CONFIG_FILES section. | |
8788 | # No need to generate them if there are no CONFIG_FILES. | |
8789 | # This happens for instance with `./config.status config.h'. | |
8790 | if test -n "$CONFIG_FILES"; then | |
8791 | ||
8792 | if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then | |
8793 | ac_cs_awk_getline=: | |
8794 | ac_cs_awk_pipe_init= | |
8795 | ac_cs_awk_read_file=' | |
8796 | while ((getline aline < (F[key])) > 0) | |
8797 | print(aline) | |
8798 | close(F[key])' | |
8799 | ac_cs_awk_pipe_fini= | |
8800 | else | |
8801 | ac_cs_awk_getline=false | |
8802 | ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\"" | |
8803 | ac_cs_awk_read_file=' | |
8804 | print "|#_!!_#|" | |
8805 | print "cat " F[key] " &&" | |
8806 | '$ac_cs_awk_pipe_init | |
8807 | # The final `:' finishes the AND list. | |
8808 | ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }' | |
8809 | fi | |
8810 | ac_cr=`echo X | tr X '\015'` | |
8811 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
8812 | # But we know of no other shell where ac_cr would be empty at this | |
8813 | # point, so we can use a bashism as a fallback. | |
8814 | if test "x$ac_cr" = x; then | |
8815 | eval ac_cr=\$\'\\r\' | |
8816 | fi | |
8817 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` | |
8818 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
22e05272 | 8819 | ac_cs_awk_cr='\\r' |
5213506e RW |
8820 | else |
8821 | ac_cs_awk_cr=$ac_cr | |
8822 | fi | |
8823 | ||
22e05272 | 8824 | echo 'BEGIN {' >"$ac_tmp/subs1.awk" && |
5213506e RW |
8825 | _ACEOF |
8826 | ||
8827 | # Create commands to substitute file output variables. | |
8828 | { | |
8829 | echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" && | |
22e05272 | 8830 | echo 'cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK &&' && |
5213506e RW |
8831 | echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' && |
8832 | echo "_ACAWK" && | |
8833 | echo "_ACEOF" | |
8834 | } >conf$$files.sh && | |
8835 | . ./conf$$files.sh || | |
22e05272 | 8836 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
5213506e RW |
8837 | rm -f conf$$files.sh |
8838 | ||
238235ef | 8839 | { |
5213506e RW |
8840 | echo "cat >conf$$subs.awk <<_ACEOF" && |
8841 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
8842 | echo "_ACEOF" | |
8843 | } >conf$$subs.sh || | |
22e05272 JM |
8844 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
8845 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` | |
5213506e RW |
8846 | ac_delim='%!_!# ' |
8847 | for ac_last_try in false false false false false :; do | |
8848 | . ./conf$$subs.sh || | |
22e05272 | 8849 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
5213506e RW |
8850 | |
8851 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` | |
8852 | if test $ac_delim_n = $ac_delim_num; then | |
8853 | break | |
8854 | elif $ac_last_try; then | |
22e05272 | 8855 | as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 |
5213506e RW |
8856 | else |
8857 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
8858 | fi | |
8859 | done | |
8860 | rm -f conf$$subs.sh | |
8861 | ||
8862 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
22e05272 | 8863 | cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && |
5213506e RW |
8864 | _ACEOF |
8865 | sed -n ' | |
8866 | h | |
8867 | s/^/S["/; s/!.*/"]=/ | |
8868 | p | |
8869 | g | |
8870 | s/^[^!]*!// | |
8871 | :repl | |
8872 | t repl | |
8873 | s/'"$ac_delim"'$// | |
8874 | t delim | |
8875 | :nl | |
8876 | h | |
22e05272 | 8877 | s/\(.\{148\}\)..*/\1/ |
5213506e RW |
8878 | t more1 |
8879 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
8880 | p | |
8881 | n | |
8882 | b repl | |
8883 | :more1 | |
8884 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
8885 | p | |
8886 | g | |
8887 | s/.\{148\}// | |
8888 | t nl | |
8889 | :delim | |
8890 | h | |
22e05272 | 8891 | s/\(.\{148\}\)..*/\1/ |
5213506e RW |
8892 | t more2 |
8893 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
8894 | p | |
8895 | b | |
8896 | :more2 | |
8897 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
8898 | p | |
8899 | g | |
8900 | s/.\{148\}// | |
8901 | t delim | |
8902 | ' <conf$$subs.awk | sed ' | |
8903 | /^[^""]/{ | |
8904 | N | |
8905 | s/\n// | |
238235ef | 8906 | } |
5213506e RW |
8907 | ' >>$CONFIG_STATUS || ac_write_fail=1 |
8908 | rm -f conf$$subs.awk | |
8909 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
8910 | _ACAWK | |
22e05272 | 8911 | cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && |
5213506e RW |
8912 | for (key in S) S_is_set[key] = 1 |
8913 | FS = "\a" | |
8914 | \$ac_cs_awk_pipe_init | |
8915 | } | |
8916 | { | |
8917 | line = $ 0 | |
8918 | nfields = split(line, field, "@") | |
8919 | substed = 0 | |
8920 | len = length(field[1]) | |
8921 | for (i = 2; i < nfields; i++) { | |
8922 | key = field[i] | |
8923 | keylen = length(key) | |
8924 | if (S_is_set[key]) { | |
8925 | value = S[key] | |
8926 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
8927 | len += length(value) + length(field[++i]) | |
8928 | substed = 1 | |
8929 | } else | |
8930 | len += 1 + keylen | |
8931 | } | |
8932 | if (nfields == 3 && !substed) { | |
8933 | key = field[2] | |
8934 | if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) { | |
8935 | \$ac_cs_awk_read_file | |
8936 | next | |
8937 | } | |
8938 | } | |
8939 | print line | |
8940 | } | |
8941 | \$ac_cs_awk_pipe_fini | |
8942 | _ACAWK | |
8943 | _ACEOF | |
8944 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
8945 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
8946 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
8947 | else | |
8948 | cat | |
22e05272 JM |
8949 | fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ |
8950 | || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 | |
238235ef DJ |
8951 | _ACEOF |
8952 | ||
22e05272 JM |
8953 | # VPATH may cause trouble with some makes, so we remove sole $(srcdir), |
8954 | # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and | |
5213506e RW |
8955 | # trailing colons and then remove the whole line if VPATH becomes empty |
8956 | # (actually we leave an empty line to preserve line numbers). | |
8957 | if test "x$srcdir" = x.; then | |
22e05272 JM |
8958 | ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ |
8959 | h | |
8960 | s/// | |
8961 | s/^/:/ | |
8962 | s/[ ]*$/:/ | |
8963 | s/:\$(srcdir):/:/g | |
8964 | s/:\${srcdir}:/:/g | |
8965 | s/:@srcdir@:/:/g | |
8966 | s/^:*// | |
5213506e | 8967 | s/:*$// |
22e05272 JM |
8968 | x |
8969 | s/\(=[ ]*\).*/\1/ | |
8970 | G | |
8971 | s/\n// | |
5213506e RW |
8972 | s/^[^=]*=[ ]*$// |
8973 | }' | |
8974 | fi | |
238235ef | 8975 | |
5213506e RW |
8976 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
8977 | fi # test -n "$CONFIG_FILES" | |
238235ef | 8978 | |
5213506e RW |
8979 | # Set up the scripts for CONFIG_HEADERS section. |
8980 | # No need to generate them if there are no CONFIG_HEADERS. | |
8981 | # This happens for instance with `./config.status Makefile'. | |
8982 | if test -n "$CONFIG_HEADERS"; then | |
22e05272 | 8983 | cat >"$ac_tmp/defines.awk" <<\_ACAWK || |
5213506e RW |
8984 | BEGIN { |
8985 | _ACEOF | |
8986 | ||
8987 | # Transform confdefs.h into an awk script `defines.awk', embedded as | |
8988 | # here-document in config.status, that substitutes the proper values into | |
8989 | # config.h.in to produce config.h. | |
8990 | ||
8991 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
8992 | # handling of long lines. | |
8993 | ac_delim='%!_!# ' | |
8994 | for ac_last_try in false false :; do | |
22e05272 JM |
8995 | ac_tt=`sed -n "/$ac_delim/p" confdefs.h` |
8996 | if test -z "$ac_tt"; then | |
5213506e RW |
8997 | break |
8998 | elif $ac_last_try; then | |
22e05272 | 8999 | as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5 |
5213506e RW |
9000 | else |
9001 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
0bc0cd11 | 9002 | fi |
5213506e | 9003 | done |
0bc0cd11 | 9004 | |
5213506e RW |
9005 | # For the awk script, D is an array of macro values keyed by name, |
9006 | # likewise P contains macro parameters if any. Preserve backslash | |
9007 | # newline sequences. | |
9008 | ||
9009 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
9010 | sed -n ' | |
9011 | s/.\{148\}/&'"$ac_delim"'/g | |
9012 | t rset | |
9013 | :rset | |
9014 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
9015 | t def | |
9016 | d | |
9017 | :def | |
9018 | s/\\$// | |
9019 | t bsnl | |
9020 | s/["\\]/\\&/g | |
9021 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
9022 | D["\1"]=" \3"/p | |
9023 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
9024 | d | |
9025 | :bsnl | |
9026 | s/["\\]/\\&/g | |
9027 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
9028 | D["\1"]=" \3\\\\\\n"\\/p | |
9029 | t cont | |
9030 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
9031 | t cont | |
9032 | d | |
9033 | :cont | |
9034 | n | |
9035 | s/.\{148\}/&'"$ac_delim"'/g | |
9036 | t clear | |
9037 | :clear | |
9038 | s/\\$// | |
9039 | t bsnlc | |
9040 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
9041 | d | |
9042 | :bsnlc | |
9043 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
9044 | b cont | |
9045 | ' <confdefs.h | sed ' | |
9046 | s/'"$ac_delim"'/"\\\ | |
9047 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
9048 | ||
9049 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
9050 | for (key in D) D_is_set[key] = 1 | |
9051 | FS = "\a" | |
9052 | } | |
9053 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
9054 | line = \$ 0 | |
9055 | split(line, arg, " ") | |
9056 | if (arg[1] == "#") { | |
9057 | defundef = arg[2] | |
9058 | mac1 = arg[3] | |
9059 | } else { | |
9060 | defundef = substr(arg[1], 2) | |
9061 | mac1 = arg[2] | |
9062 | } | |
9063 | split(mac1, mac2, "(") #) | |
9064 | macro = mac2[1] | |
9065 | prefix = substr(line, 1, index(line, defundef) - 1) | |
9066 | if (D_is_set[macro]) { | |
9067 | # Preserve the white space surrounding the "#". | |
9068 | print prefix "define", macro P[macro] D[macro] | |
9069 | next | |
9070 | } else { | |
9071 | # Replace #undef with comments. This is necessary, for example, | |
9072 | # in the case of _POSIX_SOURCE, which is predefined and required | |
9073 | # on some systems where configure will not decide to define it. | |
9074 | if (defundef == "undef") { | |
9075 | print "/*", prefix defundef, macro, "*/" | |
9076 | next | |
9077 | } | |
9078 | } | |
9079 | } | |
9080 | { print } | |
9081 | _ACAWK | |
238235ef | 9082 | _ACEOF |
5213506e | 9083 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
22e05272 | 9084 | as_fn_error $? "could not setup config headers machinery" "$LINENO" 5 |
5213506e RW |
9085 | fi # test -n "$CONFIG_HEADERS" |
9086 | ||
9087 | ||
9088 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" | |
9089 | shift | |
9090 | for ac_tag | |
9091 | do | |
9092 | case $ac_tag in | |
9093 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
9094 | esac | |
9095 | case $ac_mode$ac_tag in | |
9096 | :[FHL]*:*);; | |
22e05272 | 9097 | :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; |
5213506e RW |
9098 | :[FH]-) ac_tag=-:-;; |
9099 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
9100 | esac | |
9101 | ac_save_IFS=$IFS | |
9102 | IFS=: | |
9103 | set x $ac_tag | |
9104 | IFS=$ac_save_IFS | |
9105 | shift | |
9106 | ac_file=$1 | |
9107 | shift | |
9108 | ||
9109 | case $ac_mode in | |
9110 | :L) ac_source=$1;; | |
9111 | :[FH]) | |
9112 | ac_file_inputs= | |
9113 | for ac_f | |
9114 | do | |
9115 | case $ac_f in | |
22e05272 | 9116 | -) ac_f="$ac_tmp/stdin";; |
5213506e RW |
9117 | *) # Look for the file first in the build tree, then in the source tree |
9118 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
9119 | # because $ac_f cannot contain `:'. | |
9120 | test -f "$ac_f" || | |
9121 | case $ac_f in | |
9122 | [\\/$]*) false;; | |
9123 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
9124 | esac || | |
22e05272 | 9125 | as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; |
5213506e RW |
9126 | esac |
9127 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac | |
9128 | as_fn_append ac_file_inputs " '$ac_f'" | |
9129 | done | |
9130 | ||
9131 | # Let's still pretend it is `configure' which instantiates (i.e., don't | |
9132 | # use $as_me), people would be surprised to read: | |
9133 | # /* config.h. Generated by config.status. */ | |
9134 | configure_input='Generated from '` | |
9135 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
9136 | `' by configure.' | |
9137 | if test x"$ac_file" != x-; then | |
9138 | configure_input="$ac_file. $configure_input" | |
9139 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 | |
9140 | $as_echo "$as_me: creating $ac_file" >&6;} | |
9141 | fi | |
9142 | # Neutralize special characters interpreted by sed in replacement strings. | |
9143 | case $configure_input in #( | |
9144 | *\&* | *\|* | *\\* ) | |
9145 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
9146 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
9147 | *) ac_sed_conf_input=$configure_input;; | |
9148 | esac | |
9149 | ||
9150 | case $ac_tag in | |
22e05272 JM |
9151 | *:-:* | *:-) cat >"$ac_tmp/stdin" \ |
9152 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; | |
5213506e RW |
9153 | esac |
9154 | ;; | |
0bc0cd11 JL |
9155 | esac |
9156 | ||
5213506e | 9157 | ac_dir=`$as_dirname -- "$ac_file" || |
238235ef | 9158 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
3beb1315 HPN |
9159 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
9160 | X"$ac_file" : 'X\(//\)$' \| \ | |
5213506e RW |
9161 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
9162 | $as_echo X"$ac_file" | | |
9163 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
9164 | s//\1/ | |
9165 | q | |
9166 | } | |
9167 | /^X\(\/\/\)[^/].*/{ | |
9168 | s//\1/ | |
9169 | q | |
9170 | } | |
9171 | /^X\(\/\/\)$/{ | |
9172 | s//\1/ | |
9173 | q | |
9174 | } | |
9175 | /^X\(\/\).*/{ | |
9176 | s//\1/ | |
9177 | q | |
9178 | } | |
9179 | s/.*/./; q'` | |
9180 | as_dir="$ac_dir"; as_fn_mkdir_p | |
238235ef | 9181 | ac_builddir=. |
0bc0cd11 | 9182 | |
5213506e RW |
9183 | case "$ac_dir" in |
9184 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
9185 | *) | |
9186 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
9187 | # A ".." for each directory in $ac_dir_suffix. | |
9188 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
9189 | case $ac_top_builddir_sub in | |
9190 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
9191 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
9192 | esac ;; | |
9193 | esac | |
9194 | ac_abs_top_builddir=$ac_pwd | |
9195 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
9196 | # for backward compatibility: | |
9197 | ac_top_builddir=$ac_top_build_prefix | |
238235ef DJ |
9198 | |
9199 | case $srcdir in | |
5213506e | 9200 | .) # We are building in place. |
238235ef | 9201 | ac_srcdir=. |
5213506e RW |
9202 | ac_top_srcdir=$ac_top_builddir_sub |
9203 | ac_abs_top_srcdir=$ac_pwd ;; | |
9204 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
238235ef | 9205 | ac_srcdir=$srcdir$ac_dir_suffix; |
5213506e RW |
9206 | ac_top_srcdir=$srcdir |
9207 | ac_abs_top_srcdir=$srcdir ;; | |
9208 | *) # Relative name. | |
9209 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
9210 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
9211 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
238235ef | 9212 | esac |
5213506e | 9213 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
a4f74b58 | 9214 | |
238235ef | 9215 | |
5213506e RW |
9216 | case $ac_mode in |
9217 | :F) | |
9218 | # | |
9219 | # CONFIG_FILE | |
9220 | # | |
238235ef DJ |
9221 | |
9222 | case $INSTALL in | |
9223 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | |
5213506e | 9224 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; |
0bc0cd11 | 9225 | esac |
5213506e | 9226 | _ACEOF |
0bc0cd11 | 9227 | |
5213506e RW |
9228 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
9229 | # If the template does not know about datarootdir, expand it. | |
9230 | # FIXME: This hack should be removed a few years after 2.60. | |
9231 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
9232 | ac_sed_dataroot=' | |
9233 | /datarootdir/ { | |
9234 | p | |
9235 | q | |
9236 | } | |
9237 | /@datadir@/p | |
9238 | /@docdir@/p | |
9239 | /@infodir@/p | |
9240 | /@localedir@/p | |
9241 | /@mandir@/p' | |
9242 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in | |
9243 | *datarootdir*) ac_datarootdir_seen=yes;; | |
9244 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
9245 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 | |
9246 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} | |
9247 | _ACEOF | |
9248 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
9249 | ac_datarootdir_hack=' | |
9250 | s&@datadir@&$datadir&g | |
9251 | s&@docdir@&$docdir&g | |
9252 | s&@infodir@&$infodir&g | |
9253 | s&@localedir@&$localedir&g | |
9254 | s&@mandir@&$mandir&g | |
9255 | s&\\\${datarootdir}&$datarootdir&g' ;; | |
9256 | esac | |
238235ef | 9257 | _ACEOF |
5213506e RW |
9258 | |
9259 | # Neutralize VPATH when `$srcdir' = `.'. | |
9260 | # Shell code in configure.ac might set extrasub. | |
9261 | # FIXME: do we really want to maintain this feature? | |
9262 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
9263 | ac_sed_extra="$ac_vpsub | |
238235ef DJ |
9264 | $extrasub |
9265 | _ACEOF | |
5213506e | 9266 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
238235ef DJ |
9267 | :t |
9268 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
5213506e RW |
9269 | s|@configure_input@|$ac_sed_conf_input|;t t |
9270 | s&@top_builddir@&$ac_top_builddir_sub&;t t | |
9271 | s&@top_build_prefix@&$ac_top_build_prefix&;t t | |
9272 | s&@srcdir@&$ac_srcdir&;t t | |
9273 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
9274 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
9275 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
9276 | s&@builddir@&$ac_builddir&;t t | |
9277 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
9278 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
9279 | s&@INSTALL@&$ac_INSTALL&;t t | |
9280 | $ac_datarootdir_hack | |
9281 | " | |
9282 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | | |
9283 | if $ac_cs_awk_getline; then | |
22e05272 | 9284 | $AWK -f "$ac_tmp/subs.awk" |
5213506e | 9285 | else |
22e05272 JM |
9286 | $AWK -f "$ac_tmp/subs.awk" | $SHELL |
9287 | fi \ | |
9288 | >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
5213506e RW |
9289 | |
9290 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
22e05272 JM |
9291 | { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && |
9292 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ | |
9293 | "$ac_tmp/out"`; test -z "$ac_out"; } && | |
5213506e | 9294 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
22e05272 | 9295 | which seems to be undefined. Please make sure it is defined" >&5 |
5213506e | 9296 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' |
22e05272 | 9297 | which seems to be undefined. Please make sure it is defined" >&2;} |
5213506e | 9298 | |
22e05272 | 9299 | rm -f "$ac_tmp/stdin" |
238235ef | 9300 | case $ac_file in |
22e05272 JM |
9301 | -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; |
9302 | *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; | |
5213506e | 9303 | esac \ |
22e05272 | 9304 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 |
5213506e RW |
9305 | ;; |
9306 | :H) | |
9307 | # | |
9308 | # CONFIG_HEADER | |
9309 | # | |
238235ef | 9310 | if test x"$ac_file" != x-; then |
5213506e RW |
9311 | { |
9312 | $as_echo "/* $configure_input */" \ | |
22e05272 JM |
9313 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" |
9314 | } >"$ac_tmp/config.h" \ | |
9315 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
9316 | if diff "$ac_file" "$ac_tmp/config.h" >/dev/null 2>&1; then | |
5213506e RW |
9317 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 |
9318 | $as_echo "$as_me: $ac_file is unchanged" >&6;} | |
238235ef | 9319 | else |
5213506e | 9320 | rm -f "$ac_file" |
22e05272 JM |
9321 | mv "$ac_tmp/config.h" "$ac_file" \ |
9322 | || as_fn_error $? "could not create $ac_file" "$LINENO" 5 | |
238235ef DJ |
9323 | fi |
9324 | else | |
5213506e | 9325 | $as_echo "/* $configure_input */" \ |
22e05272 JM |
9326 | && eval '$AWK -f "$ac_tmp/defines.awk"' "$ac_file_inputs" \ |
9327 | || as_fn_error $? "could not create -" "$LINENO" 5 | |
238235ef | 9328 | fi |
5213506e | 9329 | ;; |
a4f74b58 | 9330 | |
5213506e RW |
9331 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
9332 | $as_echo "$as_me: executing $ac_file commands" >&6;} | |
9333 | ;; | |
9334 | esac | |
238235ef DJ |
9335 | |
9336 | ||
5213506e RW |
9337 | case $ac_file$ac_mode in |
9338 | "default":C) test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h | |
0bc0cd11 | 9339 | if test -n "$CONFIG_FILES"; then |
7b3ed47d | 9340 | if test -n "${with_target_subdir}"; then |
0bc0cd11 JL |
9341 | # FIXME: We shouldn't need to set ac_file |
9342 | ac_file=Makefile | |
6706f116 | 9343 | LD="${ORIGINAL_LD_FOR_MULTILIBS}" |
0bc0cd11 JL |
9344 | . ${libiberty_topdir}/config-ml.in |
9345 | fi | |
238235ef | 9346 | fi ;; |
5213506e | 9347 | |
238235ef | 9348 | esac |
5213506e | 9349 | done # for ac_tag |
238235ef | 9350 | |
238235ef | 9351 | |
5213506e | 9352 | as_fn_exit 0 |
238235ef | 9353 | _ACEOF |
238235ef DJ |
9354 | ac_clean_files=$ac_clean_files_save |
9355 | ||
5213506e | 9356 | test $ac_write_fail = 0 || |
22e05272 | 9357 | as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 |
5213506e | 9358 | |
238235ef DJ |
9359 | |
9360 | # configure is writing to config.log, and then calls config.status. | |
9361 | # config.status does its own redirection, appending to config.log. | |
9362 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
9363 | # by configure, so config.status won't be able to write to it; its | |
9364 | # output is simply discarded. So we exec the FD to /dev/null, | |
9365 | # effectively closing config.log, so it can be properly (re)opened and | |
9366 | # appended to by config.status. When coming back to configure, we | |
9367 | # need to make the FD available again. | |
9368 | if test "$no_create" != yes; then | |
9369 | ac_cs_success=: | |
9370 | ac_config_status_args= | |
9371 | test "$silent" = yes && | |
9372 | ac_config_status_args="$ac_config_status_args --quiet" | |
9373 | exec 5>/dev/null | |
9374 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false | |
9375 | exec 5>>config.log | |
9376 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
9377 | # would make configure fail if this is the last instruction. | |
22e05272 | 9378 | $ac_cs_success || as_fn_exit 1 |
5213506e RW |
9379 | fi |
9380 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then | |
9381 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 | |
9382 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} | |
238235ef | 9383 | fi |
0bc0cd11 | 9384 |