]>
Commit | Line | Data |
---|---|---|
005537df | 1 | #! /bin/sh |
861bb6c1 | 2 | # Guess values for system-dependent variables and create Makefiles. |
5213506e RW |
3 | # Generated by GNU Autoconf 2.64. |
4 | # | |
5 | # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, | |
6 | # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 Free Software | |
7 | # Foundation, Inc. | |
861bb6c1 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 | ## -------------------- ## | |
ba479fd2 | 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 : | |
ba479fd2 NN |
18 | emulate sh |
19 | NULLCMD=: | |
5213506e | 20 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
ba479fd2 NN |
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 | |
ba479fd2 NN |
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 | } | |
ba479fd2 NN |
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. | |
90 | case $0 in #(( | |
91 | *[\\/]* ) as_myself=$0 ;; | |
92 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
93 | for as_dir in $PATH | |
94 | do | |
95 | IFS=$as_save_IFS | |
96 | test -z "$as_dir" && as_dir=. | |
97 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
98 | done | |
99 | IFS=$as_save_IFS | |
100 | ||
101 | ;; | |
102 | esac | |
103 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
104 | # in which case we are not to be found in the path. | |
105 | if test "x$as_myself" = x; then | |
106 | as_myself=$0 | |
107 | fi | |
108 | if test ! -f "$as_myself"; then | |
109 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
110 | exit 1 | |
111 | fi | |
112 | ||
113 | # Unset variables that we do not need and which cause bugs (e.g. in | |
114 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
115 | # suppresses any "Segmentation fault" message there. '((' could | |
116 | # trigger a bug in pdksh 5.2.14. | |
117 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
118 | do eval test x\${$as_var+set} = xset \ | |
119 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
120 | done | |
ba479fd2 NN |
121 | PS1='$ ' |
122 | PS2='> ' | |
123 | PS4='+ ' | |
124 | ||
125 | # NLS nuisances. | |
5213506e RW |
126 | LC_ALL=C |
127 | export LC_ALL | |
128 | LANGUAGE=C | |
129 | export LANGUAGE | |
130 | ||
131 | # CDPATH. | |
132 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
133 | ||
134 | if test "x$CONFIG_SHELL" = x; then | |
135 | as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : | |
136 | emulate sh | |
137 | NULLCMD=: | |
138 | # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which | |
139 | # is contrary to our usage. Disable this feature. | |
140 | alias -g '\${1+\"\$@\"}'='\"\$@\"' | |
141 | setopt NO_GLOB_SUBST | |
142 | else | |
143 | case \`(set -o) 2>/dev/null\` in #( | |
144 | *posix*) : | |
145 | set -o posix ;; #( | |
146 | *) : | |
147 | ;; | |
148 | esac | |
149 | fi | |
150 | " | |
151 | as_required="as_fn_return () { (exit \$1); } | |
152 | as_fn_success () { as_fn_return 0; } | |
153 | as_fn_failure () { as_fn_return 1; } | |
154 | as_fn_ret_success () { return 0; } | |
155 | as_fn_ret_failure () { return 1; } | |
156 | ||
157 | exitcode=0 | |
158 | as_fn_success || { exitcode=1; echo as_fn_success failed.; } | |
159 | as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } | |
160 | as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } | |
161 | as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } | |
162 | if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : | |
163 | ||
164 | else | |
165 | exitcode=1; echo positional parameters were not saved. | |
166 | fi | |
167 | test x\$exitcode = x0 || exit 1" | |
168 | as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO | |
169 | as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO | |
170 | eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && | |
171 | test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 | |
43e02a8a RW |
172 | test \$(( 1 + 1 )) = 2 || exit 1 |
173 | ||
174 | test -n \"\${ZSH_VERSION+set}\${BASH_VERSION+set}\" || ( | |
175 | ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
176 | ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO | |
177 | ECHO=\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO\$ECHO | |
178 | PATH=/empty FPATH=/empty; export PATH FPATH | |
179 | test \"X\`printf %s \$ECHO\`\" = \"X\$ECHO\" \\ | |
180 | || test \"X\`print -r -- \$ECHO\`\" = \"X\$ECHO\" ) || exit 1" | |
5213506e RW |
181 | if (eval "$as_required") 2>/dev/null; then : |
182 | as_have_required=yes | |
183 | else | |
184 | as_have_required=no | |
185 | fi | |
186 | if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : | |
187 | ||
188 | else | |
189 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
190 | as_found=false | |
191 | for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH | |
ba479fd2 | 192 | do |
5213506e RW |
193 | IFS=$as_save_IFS |
194 | test -z "$as_dir" && as_dir=. | |
195 | as_found=: | |
196 | case $as_dir in #( | |
197 | /*) | |
198 | for as_base in sh bash ksh sh5; do | |
199 | # Try only shells that exist, to save several forks. | |
200 | as_shell=$as_dir/$as_base | |
201 | if { test -f "$as_shell" || test -f "$as_shell.exe"; } && | |
202 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
203 | CONFIG_SHELL=$as_shell as_have_required=yes | |
204 | if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : | |
205 | break 2 | |
206 | fi | |
207 | fi | |
208 | done;; | |
209 | esac | |
210 | as_found=false | |
211 | done | |
212 | $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && | |
213 | { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : | |
214 | CONFIG_SHELL=$SHELL as_have_required=yes | |
215 | fi; } | |
216 | IFS=$as_save_IFS | |
217 | ||
218 | ||
219 | if test "x$CONFIG_SHELL" != x; then : | |
220 | # We cannot yet assume a decent shell, so we have to provide a | |
221 | # neutralization value for shells without unset; and this also | |
222 | # works around shells that cannot unset nonexistent variables. | |
223 | BASH_ENV=/dev/null | |
224 | ENV=/dev/null | |
225 | (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV | |
226 | export CONFIG_SHELL | |
227 | exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} | |
228 | fi | |
229 | ||
230 | if test x$as_have_required = xno; then : | |
231 | $as_echo "$0: This script requires a shell more modern than all" | |
232 | $as_echo "$0: the shells that I found on your system." | |
233 | if test x${ZSH_VERSION+set} = xset ; then | |
234 | $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" | |
235 | $as_echo "$0: be upgraded to zsh 4.3.4 or later." | |
ba479fd2 | 236 | else |
5213506e RW |
237 | $as_echo "$0: Please tell bug-autoconf@gnu.org about your system, |
238 | $0: including any error possibly output before this | |
239 | $0: message. Then install a modern shell, or manually run | |
240 | $0: the script under such a shell if you do have one." | |
ba479fd2 | 241 | fi |
5213506e RW |
242 | exit 1 |
243 | fi | |
244 | fi | |
245 | fi | |
246 | SHELL=${CONFIG_SHELL-/bin/sh} | |
247 | export SHELL | |
248 | # Unset more variables known to interfere with behavior of common tools. | |
249 | CLICOLOR_FORCE= GREP_OPTIONS= | |
250 | unset CLICOLOR_FORCE GREP_OPTIONS | |
251 | ||
252 | ## --------------------- ## | |
253 | ## M4sh Shell Functions. ## | |
254 | ## --------------------- ## | |
255 | # as_fn_unset VAR | |
256 | # --------------- | |
257 | # Portably unset VAR. | |
258 | as_fn_unset () | |
259 | { | |
260 | { eval $1=; unset $1;} | |
261 | } | |
262 | as_unset=as_fn_unset | |
263 | ||
264 | # as_fn_set_status STATUS | |
265 | # ----------------------- | |
266 | # Set $? to STATUS, without forking. | |
267 | as_fn_set_status () | |
268 | { | |
269 | return $1 | |
270 | } # as_fn_set_status | |
271 | ||
272 | # as_fn_exit STATUS | |
273 | # ----------------- | |
274 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
275 | as_fn_exit () | |
276 | { | |
277 | set +e | |
278 | as_fn_set_status $1 | |
279 | exit $1 | |
280 | } # as_fn_exit | |
281 | ||
282 | # as_fn_mkdir_p | |
283 | # ------------- | |
284 | # Create "$as_dir" as a directory, including parents if necessary. | |
285 | as_fn_mkdir_p () | |
286 | { | |
287 | ||
288 | case $as_dir in #( | |
289 | -*) as_dir=./$as_dir;; | |
290 | esac | |
291 | test -d "$as_dir" || eval $as_mkdir_p || { | |
292 | as_dirs= | |
293 | while :; do | |
294 | case $as_dir in #( | |
295 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
296 | *) as_qdir=$as_dir;; | |
297 | esac | |
298 | as_dirs="'$as_qdir' $as_dirs" | |
299 | as_dir=`$as_dirname -- "$as_dir" || | |
300 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
301 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
302 | X"$as_dir" : 'X\(//\)$' \| \ | |
303 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
304 | $as_echo X"$as_dir" | | |
305 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
306 | s//\1/ | |
307 | q | |
308 | } | |
309 | /^X\(\/\/\)[^/].*/{ | |
310 | s//\1/ | |
311 | q | |
312 | } | |
313 | /^X\(\/\/\)$/{ | |
314 | s//\1/ | |
315 | q | |
316 | } | |
317 | /^X\(\/\).*/{ | |
318 | s//\1/ | |
319 | q | |
320 | } | |
321 | s/.*/./; q'` | |
322 | test -d "$as_dir" && break | |
323 | done | |
324 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
325 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" | |
326 | ||
327 | ||
328 | } # as_fn_mkdir_p | |
329 | # as_fn_append VAR VALUE | |
330 | # ---------------------- | |
331 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
332 | # advantage of any shell optimizations that allow amortized linear growth over | |
333 | # repeated appends, instead of the typical quadratic growth present in naive | |
334 | # implementations. | |
335 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
336 | eval 'as_fn_append () | |
337 | { | |
338 | eval $1+=\$2 | |
339 | }' | |
340 | else | |
341 | as_fn_append () | |
342 | { | |
343 | eval $1=\$$1\$2 | |
344 | } | |
345 | fi # as_fn_append | |
346 | ||
347 | # as_fn_arith ARG... | |
348 | # ------------------ | |
349 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
350 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
351 | # must be portable across $(()) and expr. | |
352 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
353 | eval 'as_fn_arith () | |
354 | { | |
355 | as_val=$(( $* )) | |
356 | }' | |
357 | else | |
358 | as_fn_arith () | |
359 | { | |
360 | as_val=`expr "$@" || test $? -eq 1` | |
361 | } | |
362 | fi # as_fn_arith | |
363 | ||
ba479fd2 | 364 | |
5213506e RW |
365 | # as_fn_error ERROR [LINENO LOG_FD] |
366 | # --------------------------------- | |
367 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
368 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
369 | # script with status $?, using 1 if that was 0. | |
370 | as_fn_error () | |
371 | { | |
372 | as_status=$?; test $as_status -eq 0 && as_status=1 | |
373 | if test "$3"; then | |
374 | as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
375 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 | |
376 | fi | |
377 | $as_echo "$as_me: error: $1" >&2 | |
378 | as_fn_exit $as_status | |
379 | } # as_fn_error | |
380 | ||
381 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
382 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
ba479fd2 NN |
383 | as_expr=expr |
384 | else | |
385 | as_expr=false | |
386 | fi | |
387 | ||
5213506e | 388 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
ba479fd2 NN |
389 | as_basename=basename |
390 | else | |
391 | as_basename=false | |
392 | fi | |
393 | ||
5213506e RW |
394 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
395 | as_dirname=dirname | |
396 | else | |
397 | as_dirname=false | |
398 | fi | |
ba479fd2 | 399 | |
5213506e | 400 | as_me=`$as_basename -- "$0" || |
ba479fd2 NN |
401 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
402 | X"$0" : 'X\(//\)$' \| \ | |
5213506e RW |
403 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
404 | $as_echo X/"$0" | | |
405 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
406 | s//\1/ | |
407 | q | |
408 | } | |
409 | /^X\/\(\/\/\)$/{ | |
410 | s//\1/ | |
411 | q | |
412 | } | |
413 | /^X\/\(\/\).*/{ | |
414 | s//\1/ | |
415 | q | |
416 | } | |
417 | s/.*/./; q'` | |
ab22c1fa | 418 | |
b61ff9c8 BS |
419 | # Avoid depending upon Character Ranges. |
420 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
421 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
422 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
423 | as_cr_digits='0123456789' | |
424 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
1a4b763e | 425 | |
ba479fd2 | 426 | |
5213506e RW |
427 | as_lineno_1=$LINENO as_lineno_1a=$LINENO |
428 | as_lineno_2=$LINENO as_lineno_2a=$LINENO | |
429 | eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && | |
430 | test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { | |
431 | # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) | |
432 | sed -n ' | |
433 | p | |
434 | /[$]LINENO/= | |
435 | ' <$as_myself | | |
ba479fd2 | 436 | sed ' |
5213506e RW |
437 | s/[$]LINENO.*/&-/ |
438 | t lineno | |
439 | b | |
440 | :lineno | |
ba479fd2 | 441 | N |
5213506e RW |
442 | :loop |
443 | s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ | |
ba479fd2 | 444 | t loop |
5213506e | 445 | s/-\n.*// |
ba479fd2 | 446 | ' >$as_me.lineno && |
5213506e RW |
447 | chmod +x "$as_me.lineno" || |
448 | { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } | |
ba479fd2 NN |
449 | |
450 | # Don't try to exec as it changes $[0], causing all sort of problems | |
451 | # (the dirname of $[0] is not the place where we might find the | |
5213506e RW |
452 | # original and so on. Autoconf is especially sensitive to this). |
453 | . "./$as_me.lineno" | |
ba479fd2 NN |
454 | # Exit status is that of the last command. |
455 | exit | |
456 | } | |
457 | ||
5213506e RW |
458 | ECHO_C= ECHO_N= ECHO_T= |
459 | case `echo -n x` in #((((( | |
460 | -n*) | |
461 | case `echo 'xy\c'` in | |
462 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
463 | xy) ECHO_C='\c';; | |
464 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
465 | ECHO_T=' ';; | |
466 | esac;; | |
467 | *) | |
468 | ECHO_N='-n';; | |
ba479fd2 NN |
469 | esac |
470 | ||
5213506e RW |
471 | rm -f conf$$ conf$$.exe conf$$.file |
472 | if test -d conf$$.dir; then | |
473 | rm -f conf$$.dir/conf$$.file | |
ba479fd2 | 474 | else |
5213506e RW |
475 | rm -f conf$$.dir |
476 | mkdir conf$$.dir 2>/dev/null | |
ba479fd2 | 477 | fi |
5213506e RW |
478 | if (echo >conf$$.file) 2>/dev/null; then |
479 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
b61ff9c8 | 480 | as_ln_s='ln -s' |
5213506e RW |
481 | # ... but there are two gotchas: |
482 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
483 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
484 | # In both cases, we have to default to `cp -p'. | |
485 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
486 | as_ln_s='cp -p' | |
487 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
488 | as_ln_s=ln | |
489 | else | |
490 | as_ln_s='cp -p' | |
b61ff9c8 | 491 | fi |
ba479fd2 NN |
492 | else |
493 | as_ln_s='cp -p' | |
494 | fi | |
5213506e RW |
495 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
496 | rmdir conf$$.dir 2>/dev/null | |
861bb6c1 | 497 | |
ba479fd2 | 498 | if mkdir -p . 2>/dev/null; then |
5213506e | 499 | as_mkdir_p='mkdir -p "$as_dir"' |
ba479fd2 | 500 | else |
86da66b5 | 501 | test -d ./-p && rmdir ./-p |
ba479fd2 NN |
502 | as_mkdir_p=false |
503 | fi | |
504 | ||
5213506e RW |
505 | if test -x / >/dev/null 2>&1; then |
506 | as_test_x='test -x' | |
507 | else | |
508 | if ls -dL / >/dev/null 2>&1; then | |
509 | as_ls_L_option=L | |
510 | else | |
511 | as_ls_L_option= | |
512 | fi | |
513 | as_test_x=' | |
514 | eval sh -c '\'' | |
515 | if test -d "$1"; then | |
516 | test -d "$1/."; | |
517 | else | |
518 | case $1 in #( | |
519 | -*)set "./$1";; | |
520 | esac; | |
521 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
522 | ???[sx]*):;;*)false;;esac;fi | |
523 | '\'' sh | |
524 | ' | |
525 | fi | |
526 | as_executable_p=$as_test_x | |
ba479fd2 NN |
527 | |
528 | # Sed expression to map a string onto a valid CPP name. | |
86da66b5 | 529 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
ba479fd2 NN |
530 | |
531 | # Sed expression to map a string onto a valid variable name. | |
86da66b5 | 532 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
ba479fd2 | 533 | |
da0f6381 PB |
534 | SHELL=${CONFIG_SHELL-/bin/sh} |
535 | ||
da0f6381 | 536 | |
5213506e RW |
537 | exec 7<&0 </dev/null 6>&1 |
538 | ||
ba479fd2 NN |
539 | # Name of the host. |
540 | # hostname on some systems (SVR3.2, Linux) returns a bogus exit status, | |
541 | # so uname gets run too. | |
542 | ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` | |
543 | ||
ba479fd2 NN |
544 | # |
545 | # Initializations. | |
546 | # | |
861bb6c1 | 547 | ac_default_prefix=/usr/local |
5213506e | 548 | ac_clean_files= |
ba479fd2 | 549 | ac_config_libobj_dir=. |
5213506e | 550 | LIBOBJS= |
ba479fd2 NN |
551 | cross_compiling=no |
552 | subdirs= | |
553 | MFLAGS= | |
554 | MAKEFLAGS= | |
b61ff9c8 | 555 | |
ba479fd2 NN |
556 | # Identity of this package. |
557 | PACKAGE_NAME= | |
558 | PACKAGE_TARNAME= | |
559 | PACKAGE_VERSION= | |
560 | PACKAGE_STRING= | |
561 | PACKAGE_BUGREPORT= | |
5213506e | 562 | PACKAGE_URL= |
ba479fd2 NN |
563 | |
564 | ac_unique_file="tree.c" | |
565 | # Factoring default headers for most tests. | |
566 | ac_includes_default="\ | |
567 | #include <stdio.h> | |
5213506e | 568 | #ifdef HAVE_SYS_TYPES_H |
ba479fd2 NN |
569 | # include <sys/types.h> |
570 | #endif | |
5213506e | 571 | #ifdef HAVE_SYS_STAT_H |
ba479fd2 NN |
572 | # include <sys/stat.h> |
573 | #endif | |
5213506e | 574 | #ifdef STDC_HEADERS |
ba479fd2 NN |
575 | # include <stdlib.h> |
576 | # include <stddef.h> | |
577 | #else | |
5213506e | 578 | # ifdef HAVE_STDLIB_H |
ba479fd2 NN |
579 | # include <stdlib.h> |
580 | # endif | |
581 | #endif | |
5213506e RW |
582 | #ifdef HAVE_STRING_H |
583 | # if !defined STDC_HEADERS && defined HAVE_MEMORY_H | |
ba479fd2 NN |
584 | # include <memory.h> |
585 | # endif | |
586 | # include <string.h> | |
587 | #endif | |
5213506e | 588 | #ifdef HAVE_STRINGS_H |
ba479fd2 NN |
589 | # include <strings.h> |
590 | #endif | |
5213506e | 591 | #ifdef HAVE_INTTYPES_H |
ba479fd2 | 592 | # include <inttypes.h> |
ba479fd2 | 593 | #endif |
5213506e RW |
594 | #ifdef HAVE_STDINT_H |
595 | # include <stdint.h> | |
596 | #endif | |
597 | #ifdef HAVE_UNISTD_H | |
ba479fd2 NN |
598 | # include <unistd.h> |
599 | #endif" | |
600 | ||
5213506e RW |
601 | ac_subst_vars='LTLIBOBJS |
602 | LIBOBJS | |
603 | enable_plugin | |
604 | pluginlibs | |
d7f09764 DN |
605 | LIBELFINC |
606 | LIBELFLIBS | |
5213506e RW |
607 | CLOOGINC |
608 | CLOOGLIBS | |
609 | PPLINC | |
610 | PPLLIBS | |
611 | GMPINC | |
612 | GMPLIBS | |
613 | target_cpu_default | |
614 | fortran_target_objs | |
615 | cxx_target_objs | |
616 | c_target_objs | |
617 | use_gcc_stdint | |
618 | xm_defines | |
619 | xm_include_list | |
620 | xm_file_list | |
621 | tm_p_include_list | |
622 | tm_p_file_list | |
623 | tm_defines | |
624 | tm_include_list | |
625 | tm_file_list | |
626 | thread_file | |
627 | out_object_file | |
628 | out_file | |
629 | objc_boehm_gc | |
630 | md_file | |
631 | local_prefix | |
632 | lang_tree_files | |
633 | lang_specs_files | |
634 | lang_opt_files | |
635 | install | |
636 | out_host_hook_obj | |
637 | host_xm_defines | |
638 | host_xm_include_list | |
639 | host_xm_file_list | |
640 | host_exeext | |
641 | gcc_gxx_include_dir | |
642 | gcc_config_arguments | |
643 | float_h_file | |
644 | extra_programs | |
645 | extra_passes | |
646 | extra_parts | |
647 | extra_objs | |
648 | extra_headers_list | |
649 | extra_gcc_objs | |
650 | TM_MULTILIB_EXCEPTIONS_CONFIG | |
651 | TM_MULTILIB_CONFIG | |
652 | TM_ENDIAN_CONFIG | |
653 | tmake_file | |
654 | xmake_file | |
655 | cpp_install_dir | |
656 | check_languages | |
657 | build_file_translate | |
658 | build_xm_defines | |
659 | build_xm_include_list | |
660 | build_xm_file_list | |
661 | build_install_headers_dir | |
662 | build_exeext | |
663 | all_selected_languages | |
664 | all_languages | |
665 | all_lang_makefiles | |
666 | all_lang_makefrags | |
667 | all_gtfiles | |
668 | all_compilers | |
669 | srcdir | |
670 | subdirs | |
671 | slibdir | |
672 | dollar | |
673 | gcc_tooldir | |
d7f09764 | 674 | enable_lto |
5213506e RW |
675 | MAINT |
676 | zlibinc | |
677 | zlibdir | |
678 | HOST_LIBS | |
679 | GGC | |
680 | libgcc_visibility | |
681 | gcc_cv_readelf | |
682 | gcc_cv_objdump | |
683 | ORIGINAL_NM_FOR_TARGET | |
684 | gcc_cv_nm | |
685 | ORIGINAL_LD_FOR_TARGET | |
5938f74d | 686 | ORIGINAL_PLUGIN_LD_FOR_TARGET |
5213506e RW |
687 | gcc_cv_ld |
688 | ORIGINAL_AS_FOR_TARGET | |
689 | gcc_cv_as | |
690 | enable_fast_install | |
691 | objdir | |
692 | CXXCPP | |
693 | OTOOL64 | |
694 | OTOOL | |
695 | LIPO | |
696 | NMEDIT | |
697 | DSYMUTIL | |
5213506e RW |
698 | STRIP |
699 | OBJDUMP | |
700 | ac_ct_DUMPBIN | |
701 | DUMPBIN | |
702 | LD | |
703 | FGREP | |
704 | SED | |
705 | LIBTOOL | |
706 | collect2 | |
707 | STMP_FIXINC | |
708 | BUILD_LDFLAGS | |
709 | BUILD_CFLAGS | |
710 | CC_FOR_BUILD | |
711 | inhibit_libc | |
712 | SYSTEM_HEADER_DIR | |
713 | ALL | |
714 | CROSS | |
715 | CATOBJEXT | |
716 | GENCAT | |
717 | INSTOBJEXT | |
718 | DATADIRNAME | |
719 | CATALOGS | |
720 | POSUB | |
721 | GMSGFMT | |
722 | XGETTEXT | |
723 | INCINTL | |
724 | LIBINTL_DEP | |
725 | LIBINTL | |
726 | USE_NLS | |
727 | extra_opt_files | |
728 | extra_modes_file | |
729 | gthread_flags | |
730 | objext | |
731 | manext | |
732 | LIBICONV_DEP | |
733 | LTLIBICONV | |
734 | LIBICONV | |
735 | LDEXP_LIB | |
736 | GNAT_LIBEXC | |
737 | COLLECT2_LIBS | |
738 | AR | |
739 | NM | |
740 | BISON | |
741 | FLEX | |
742 | GENERATED_MANPAGES | |
743 | BUILD_INFO | |
744 | MAKEINFO | |
745 | have_mktemp_command | |
746 | make_compare_target | |
747 | INSTALL_DATA | |
748 | INSTALL_PROGRAM | |
749 | INSTALL | |
750 | ranlib_flags | |
751 | RANLIB | |
752 | LN | |
753 | LN_S | |
754 | AWK | |
755 | SET_MAKE | |
756 | REPORT_BUGS_TEXI | |
757 | REPORT_BUGS_TO | |
758 | PKGVERSION | |
759 | onestep | |
e11ddaf5 | 760 | CONFIGURE_SPECS |
5213506e RW |
761 | CROSS_SYSTEM_HEADER_DIR |
762 | TARGET_SYSTEM_ROOT_DEFINE | |
763 | TARGET_SYSTEM_ROOT | |
764 | enable_shared | |
765 | enable_fixed_point | |
766 | enable_decimal_float | |
767 | enable_multilib | |
768 | ENABLE_BUILD_WITH_CXX | |
769 | coverage_flags | |
770 | valgrind_command | |
771 | valgrind_path_defines | |
772 | valgrind_path | |
773 | TREEBROWSER | |
774 | nocommon_flag | |
775 | warn_cxxflags | |
776 | warn_cflags | |
777 | c_strict_warn | |
778 | strict_warn | |
779 | c_loose_warn | |
780 | loose_warn | |
781 | EGREP | |
782 | GREP | |
783 | CPP | |
784 | OUTPUT_OPTION | |
785 | NO_MINUS_C_MINUS_O | |
786 | GNATMAKE | |
787 | GNATBIND | |
788 | ac_ct_CXX | |
789 | CXXFLAGS | |
790 | CXX | |
791 | OBJEXT | |
792 | EXEEXT | |
793 | ac_ct_CC | |
794 | CPPFLAGS | |
795 | LDFLAGS | |
796 | CFLAGS | |
797 | CC | |
798 | GENINSRC | |
799 | target_subdir | |
800 | host_subdir | |
801 | build_subdir | |
802 | build_libsubdir | |
803 | target_noncanonical | |
804 | target_os | |
805 | target_vendor | |
806 | target_cpu | |
807 | target | |
808 | host_os | |
809 | host_vendor | |
810 | host_cpu | |
811 | host | |
812 | build_os | |
813 | build_vendor | |
814 | build_cpu | |
815 | build | |
816 | target_alias | |
817 | host_alias | |
818 | build_alias | |
819 | LIBS | |
820 | ECHO_T | |
821 | ECHO_N | |
822 | ECHO_C | |
823 | DEFS | |
824 | mandir | |
825 | localedir | |
826 | libdir | |
827 | psdir | |
828 | pdfdir | |
829 | dvidir | |
830 | htmldir | |
831 | infodir | |
832 | docdir | |
833 | oldincludedir | |
834 | includedir | |
835 | localstatedir | |
836 | sharedstatedir | |
837 | sysconfdir | |
838 | datadir | |
839 | datarootdir | |
840 | libexecdir | |
841 | sbindir | |
842 | bindir | |
843 | program_transform_name | |
844 | prefix | |
845 | exec_prefix | |
846 | PACKAGE_URL | |
847 | PACKAGE_BUGREPORT | |
848 | PACKAGE_STRING | |
849 | PACKAGE_VERSION | |
850 | PACKAGE_TARNAME | |
851 | PACKAGE_NAME | |
852 | PATH_SEPARATOR | |
853 | SHELL' | |
ba479fd2 | 854 | ac_subst_files='language_hooks' |
5213506e RW |
855 | ac_user_opts=' |
856 | enable_option_checking | |
857 | with_build_libsubdir | |
858 | with_local_prefix | |
859 | with_gxx_include_dir | |
860 | with_cpp_install_dir | |
861 | enable_generated_files_in_srcdir | |
862 | with_gnu_ld | |
863 | with_ld | |
864 | with_demangler_in_ld | |
865 | with_gnu_as | |
866 | with_as | |
867 | enable_werror_always | |
868 | enable_checking | |
869 | enable_coverage | |
870 | enable_gather_detailed_mem_stats | |
871 | enable_build_with_cxx | |
872 | with_stabs | |
873 | enable_multilib | |
874 | enable___cxa_atexit | |
875 | enable_decimal_float | |
876 | enable_fixed_point | |
877 | enable_threads | |
878 | enable_tls | |
879 | enable_objc_gc | |
880 | with_dwarf2 | |
881 | enable_shared | |
882 | with_build_sysroot | |
883 | with_sysroot | |
e11ddaf5 | 884 | with_specs |
5213506e RW |
885 | enable_intermodule |
886 | with_pkgversion | |
887 | with_bugurl | |
888 | enable_languages | |
889 | with_multilib_list | |
890 | enable_rpath | |
891 | with_libiconv_prefix | |
892 | enable_initfini_array | |
893 | enable_sjlj_exceptions | |
894 | with_system_libunwind | |
895 | enable_secureplt | |
896 | enable_cld | |
897 | enable_win32_registry | |
898 | enable_static | |
899 | with_pic | |
900 | enable_fast_install | |
901 | enable_libtool_lock | |
5938f74d | 902 | with_plugin_ld |
5213506e RW |
903 | enable_gnu_unique_object |
904 | enable_linker_build_id | |
905 | with_long_double_128 | |
906 | with_gc | |
907 | with_system_zlib | |
908 | enable_maintainer_mode | |
909 | enable_version_specific_runtime_libs | |
910 | with_slibdir | |
5213506e RW |
911 | enable_plugin |
912 | ' | |
913 | ac_precious_vars='build_alias | |
914 | host_alias | |
915 | target_alias | |
916 | CC | |
917 | CFLAGS | |
918 | LDFLAGS | |
919 | LIBS | |
920 | CPPFLAGS | |
921 | CXX | |
922 | CXXFLAGS | |
923 | CCC | |
924 | CPP | |
925 | CXXCPP | |
926 | GMPLIBS | |
927 | GMPINC | |
928 | PPLLIBS | |
929 | PPLINC | |
930 | CLOOGLIBS | |
d7f09764 DN |
931 | CLOOGINC |
932 | LIBELFLIBS | |
933 | LIBELFINC' | |
5213506e | 934 | |
861bb6c1 JL |
935 | |
936 | # Initialize some variables set by options. | |
ba479fd2 NN |
937 | ac_init_help= |
938 | ac_init_version=false | |
5213506e RW |
939 | ac_unrecognized_opts= |
940 | ac_unrecognized_sep= | |
861bb6c1 JL |
941 | # The variables have the same names as the options, with |
942 | # dashes changed to underlines. | |
ba479fd2 | 943 | cache_file=/dev/null |
861bb6c1 | 944 | exec_prefix=NONE |
861bb6c1 | 945 | no_create= |
861bb6c1 JL |
946 | no_recursion= |
947 | prefix=NONE | |
948 | program_prefix=NONE | |
949 | program_suffix=NONE | |
950 | program_transform_name=s,x,x, | |
951 | silent= | |
952 | site= | |
953 | srcdir= | |
861bb6c1 JL |
954 | verbose= |
955 | x_includes=NONE | |
956 | x_libraries=NONE | |
ba479fd2 NN |
957 | |
958 | # Installation directory options. | |
959 | # These are left unexpanded so users can "make install exec_prefix=/foo" | |
960 | # and all the variables that are supposed to be based on exec_prefix | |
961 | # by default will actually change. | |
962 | # Use braces instead of parens because sh, perl, etc. also accept them. | |
5213506e | 963 | # (The list follows the same order as the GNU Coding Standards.) |
861bb6c1 JL |
964 | bindir='${exec_prefix}/bin' |
965 | sbindir='${exec_prefix}/sbin' | |
966 | libexecdir='${exec_prefix}/libexec' | |
5213506e RW |
967 | datarootdir='${prefix}/share' |
968 | datadir='${datarootdir}' | |
861bb6c1 JL |
969 | sysconfdir='${prefix}/etc' |
970 | sharedstatedir='${prefix}/com' | |
971 | localstatedir='${prefix}/var' | |
861bb6c1 JL |
972 | includedir='${prefix}/include' |
973 | oldincludedir='/usr/include' | |
5213506e RW |
974 | docdir='${datarootdir}/doc/${PACKAGE}' |
975 | infodir='${datarootdir}/info' | |
976 | htmldir='${docdir}' | |
977 | dvidir='${docdir}' | |
978 | pdfdir='${docdir}' | |
979 | psdir='${docdir}' | |
980 | libdir='${exec_prefix}/lib' | |
981 | localedir='${datarootdir}/locale' | |
982 | mandir='${datarootdir}/man' | |
861bb6c1 | 983 | |
861bb6c1 | 984 | ac_prev= |
5213506e | 985 | ac_dashdash= |
861bb6c1 JL |
986 | for ac_option |
987 | do | |
861bb6c1 JL |
988 | # If the previous option needs an argument, assign it. |
989 | if test -n "$ac_prev"; then | |
5213506e | 990 | eval $ac_prev=\$ac_option |
861bb6c1 JL |
991 | ac_prev= |
992 | continue | |
993 | fi | |
994 | ||
5213506e RW |
995 | case $ac_option in |
996 | *=*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; | |
997 | *) ac_optarg=yes ;; | |
998 | esac | |
861bb6c1 JL |
999 | |
1000 | # Accept the important Cygnus configure options, so we can diagnose typos. | |
1001 | ||
5213506e RW |
1002 | case $ac_dashdash$ac_option in |
1003 | --) | |
1004 | ac_dashdash=yes ;; | |
861bb6c1 JL |
1005 | |
1006 | -bindir | --bindir | --bindi | --bind | --bin | --bi) | |
1007 | ac_prev=bindir ;; | |
1008 | -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) | |
ba479fd2 | 1009 | bindir=$ac_optarg ;; |
861bb6c1 JL |
1010 | |
1011 | -build | --build | --buil | --bui | --bu) | |
ba479fd2 | 1012 | ac_prev=build_alias ;; |
861bb6c1 | 1013 | -build=* | --build=* | --buil=* | --bui=* | --bu=*) |
ba479fd2 | 1014 | build_alias=$ac_optarg ;; |
861bb6c1 JL |
1015 | |
1016 | -cache-file | --cache-file | --cache-fil | --cache-fi \ | |
1017 | | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) | |
1018 | ac_prev=cache_file ;; | |
1019 | -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ | |
1020 | | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) | |
ba479fd2 NN |
1021 | cache_file=$ac_optarg ;; |
1022 | ||
1023 | --config-cache | -C) | |
1024 | cache_file=config.cache ;; | |
861bb6c1 | 1025 | |
5213506e | 1026 | -datadir | --datadir | --datadi | --datad) |
861bb6c1 | 1027 | ac_prev=datadir ;; |
5213506e | 1028 | -datadir=* | --datadir=* | --datadi=* | --datad=*) |
ba479fd2 | 1029 | datadir=$ac_optarg ;; |
861bb6c1 | 1030 | |
5213506e RW |
1031 | -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ |
1032 | | --dataroo | --dataro | --datar) | |
1033 | ac_prev=datarootdir ;; | |
1034 | -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ | |
1035 | | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) | |
1036 | datarootdir=$ac_optarg ;; | |
1037 | ||
861bb6c1 | 1038 | -disable-* | --disable-*) |
5213506e | 1039 | ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` |
861bb6c1 | 1040 | # Reject names that are not valid shell variable names. |
5213506e RW |
1041 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1042 | as_fn_error "invalid feature name: $ac_useropt" | |
1043 | ac_useropt_orig=$ac_useropt | |
1044 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1045 | case $ac_user_opts in | |
1046 | *" | |
1047 | "enable_$ac_useropt" | |
1048 | "*) ;; | |
1049 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" | |
1050 | ac_unrecognized_sep=', ';; | |
1051 | esac | |
1052 | eval enable_$ac_useropt=no ;; | |
1053 | ||
1054 | -docdir | --docdir | --docdi | --doc | --do) | |
1055 | ac_prev=docdir ;; | |
1056 | -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) | |
1057 | docdir=$ac_optarg ;; | |
1058 | ||
1059 | -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) | |
1060 | ac_prev=dvidir ;; | |
1061 | -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) | |
1062 | dvidir=$ac_optarg ;; | |
861bb6c1 JL |
1063 | |
1064 | -enable-* | --enable-*) | |
5213506e | 1065 | ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` |
861bb6c1 | 1066 | # Reject names that are not valid shell variable names. |
5213506e RW |
1067 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1068 | as_fn_error "invalid feature name: $ac_useropt" | |
1069 | ac_useropt_orig=$ac_useropt | |
1070 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1071 | case $ac_user_opts in | |
1072 | *" | |
1073 | "enable_$ac_useropt" | |
1074 | "*) ;; | |
1075 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" | |
1076 | ac_unrecognized_sep=', ';; | |
b61ff9c8 | 1077 | esac |
5213506e | 1078 | eval enable_$ac_useropt=\$ac_optarg ;; |
861bb6c1 JL |
1079 | |
1080 | -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ | |
1081 | | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ | |
1082 | | --exec | --exe | --ex) | |
1083 | ac_prev=exec_prefix ;; | |
1084 | -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ | |
1085 | | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ | |
1086 | | --exec=* | --exe=* | --ex=*) | |
ba479fd2 | 1087 | exec_prefix=$ac_optarg ;; |
861bb6c1 JL |
1088 | |
1089 | -gas | --gas | --ga | --g) | |
1090 | # Obsolete; use --with-gas. | |
1091 | with_gas=yes ;; | |
1092 | ||
ba479fd2 NN |
1093 | -help | --help | --hel | --he | -h) |
1094 | ac_init_help=long ;; | |
1095 | -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) | |
1096 | ac_init_help=recursive ;; | |
1097 | -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) | |
1098 | ac_init_help=short ;; | |
861bb6c1 JL |
1099 | |
1100 | -host | --host | --hos | --ho) | |
ba479fd2 | 1101 | ac_prev=host_alias ;; |
861bb6c1 | 1102 | -host=* | --host=* | --hos=* | --ho=*) |
ba479fd2 | 1103 | host_alias=$ac_optarg ;; |
861bb6c1 | 1104 | |
5213506e RW |
1105 | -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) |
1106 | ac_prev=htmldir ;; | |
1107 | -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ | |
1108 | | --ht=*) | |
1109 | htmldir=$ac_optarg ;; | |
1110 | ||
861bb6c1 JL |
1111 | -includedir | --includedir | --includedi | --included | --include \ |
1112 | | --includ | --inclu | --incl | --inc) | |
1113 | ac_prev=includedir ;; | |
1114 | -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ | |
1115 | | --includ=* | --inclu=* | --incl=* | --inc=*) | |
ba479fd2 | 1116 | includedir=$ac_optarg ;; |
861bb6c1 JL |
1117 | |
1118 | -infodir | --infodir | --infodi | --infod | --info | --inf) | |
1119 | ac_prev=infodir ;; | |
1120 | -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) | |
ba479fd2 | 1121 | infodir=$ac_optarg ;; |
861bb6c1 JL |
1122 | |
1123 | -libdir | --libdir | --libdi | --libd) | |
1124 | ac_prev=libdir ;; | |
1125 | -libdir=* | --libdir=* | --libdi=* | --libd=*) | |
ba479fd2 | 1126 | libdir=$ac_optarg ;; |
861bb6c1 JL |
1127 | |
1128 | -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ | |
1129 | | --libexe | --libex | --libe) | |
1130 | ac_prev=libexecdir ;; | |
1131 | -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ | |
1132 | | --libexe=* | --libex=* | --libe=*) | |
ba479fd2 | 1133 | libexecdir=$ac_optarg ;; |
861bb6c1 | 1134 | |
5213506e RW |
1135 | -localedir | --localedir | --localedi | --localed | --locale) |
1136 | ac_prev=localedir ;; | |
1137 | -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) | |
1138 | localedir=$ac_optarg ;; | |
1139 | ||
861bb6c1 | 1140 | -localstatedir | --localstatedir | --localstatedi | --localstated \ |
5213506e | 1141 | | --localstate | --localstat | --localsta | --localst | --locals) |
861bb6c1 JL |
1142 | ac_prev=localstatedir ;; |
1143 | -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ | |
5213506e | 1144 | | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) |
ba479fd2 | 1145 | localstatedir=$ac_optarg ;; |
861bb6c1 JL |
1146 | |
1147 | -mandir | --mandir | --mandi | --mand | --man | --ma | --m) | |
1148 | ac_prev=mandir ;; | |
1149 | -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) | |
ba479fd2 | 1150 | mandir=$ac_optarg ;; |
861bb6c1 JL |
1151 | |
1152 | -nfp | --nfp | --nf) | |
1153 | # Obsolete; use --without-fp. | |
1154 | with_fp=no ;; | |
1155 | ||
1156 | -no-create | --no-create | --no-creat | --no-crea | --no-cre \ | |
ba479fd2 | 1157 | | --no-cr | --no-c | -n) |
861bb6c1 JL |
1158 | no_create=yes ;; |
1159 | ||
1160 | -no-recursion | --no-recursion | --no-recursio | --no-recursi \ | |
1161 | | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) | |
1162 | no_recursion=yes ;; | |
1163 | ||
1164 | -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ | |
1165 | | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ | |
1166 | | --oldin | --oldi | --old | --ol | --o) | |
1167 | ac_prev=oldincludedir ;; | |
1168 | -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ | |
1169 | | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ | |
1170 | | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) | |
ba479fd2 | 1171 | oldincludedir=$ac_optarg ;; |
861bb6c1 JL |
1172 | |
1173 | -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) | |
1174 | ac_prev=prefix ;; | |
1175 | -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) | |
ba479fd2 | 1176 | prefix=$ac_optarg ;; |
861bb6c1 JL |
1177 | |
1178 | -program-prefix | --program-prefix | --program-prefi | --program-pref \ | |
1179 | | --program-pre | --program-pr | --program-p) | |
1180 | ac_prev=program_prefix ;; | |
1181 | -program-prefix=* | --program-prefix=* | --program-prefi=* \ | |
1182 | | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) | |
ba479fd2 | 1183 | program_prefix=$ac_optarg ;; |
861bb6c1 JL |
1184 | |
1185 | -program-suffix | --program-suffix | --program-suffi | --program-suff \ | |
1186 | | --program-suf | --program-su | --program-s) | |
1187 | ac_prev=program_suffix ;; | |
1188 | -program-suffix=* | --program-suffix=* | --program-suffi=* \ | |
1189 | | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) | |
ba479fd2 | 1190 | program_suffix=$ac_optarg ;; |
861bb6c1 JL |
1191 | |
1192 | -program-transform-name | --program-transform-name \ | |
1193 | | --program-transform-nam | --program-transform-na \ | |
1194 | | --program-transform-n | --program-transform- \ | |
1195 | | --program-transform | --program-transfor \ | |
1196 | | --program-transfo | --program-transf \ | |
1197 | | --program-trans | --program-tran \ | |
1198 | | --progr-tra | --program-tr | --program-t) | |
1199 | ac_prev=program_transform_name ;; | |
1200 | -program-transform-name=* | --program-transform-name=* \ | |
1201 | | --program-transform-nam=* | --program-transform-na=* \ | |
1202 | | --program-transform-n=* | --program-transform-=* \ | |
1203 | | --program-transform=* | --program-transfor=* \ | |
1204 | | --program-transfo=* | --program-transf=* \ | |
1205 | | --program-trans=* | --program-tran=* \ | |
1206 | | --progr-tra=* | --program-tr=* | --program-t=*) | |
ba479fd2 | 1207 | program_transform_name=$ac_optarg ;; |
861bb6c1 | 1208 | |
5213506e RW |
1209 | -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) |
1210 | ac_prev=pdfdir ;; | |
1211 | -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) | |
1212 | pdfdir=$ac_optarg ;; | |
1213 | ||
1214 | -psdir | --psdir | --psdi | --psd | --ps) | |
1215 | ac_prev=psdir ;; | |
1216 | -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) | |
1217 | psdir=$ac_optarg ;; | |
1218 | ||
861bb6c1 JL |
1219 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
1220 | | -silent | --silent | --silen | --sile | --sil) | |
1221 | silent=yes ;; | |
1222 | ||
1223 | -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) | |
1224 | ac_prev=sbindir ;; | |
1225 | -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ | |
1226 | | --sbi=* | --sb=*) | |
ba479fd2 | 1227 | sbindir=$ac_optarg ;; |
861bb6c1 JL |
1228 | |
1229 | -sharedstatedir | --sharedstatedir | --sharedstatedi \ | |
1230 | | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ | |
1231 | | --sharedst | --shareds | --shared | --share | --shar \ | |
1232 | | --sha | --sh) | |
1233 | ac_prev=sharedstatedir ;; | |
1234 | -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ | |
1235 | | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ | |
1236 | | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ | |
1237 | | --sha=* | --sh=*) | |
ba479fd2 | 1238 | sharedstatedir=$ac_optarg ;; |
861bb6c1 JL |
1239 | |
1240 | -site | --site | --sit) | |
1241 | ac_prev=site ;; | |
1242 | -site=* | --site=* | --sit=*) | |
ba479fd2 | 1243 | site=$ac_optarg ;; |
861bb6c1 JL |
1244 | |
1245 | -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) | |
1246 | ac_prev=srcdir ;; | |
1247 | -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) | |
ba479fd2 | 1248 | srcdir=$ac_optarg ;; |
861bb6c1 JL |
1249 | |
1250 | -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ | |
1251 | | --syscon | --sysco | --sysc | --sys | --sy) | |
1252 | ac_prev=sysconfdir ;; | |
1253 | -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ | |
1254 | | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) | |
ba479fd2 | 1255 | sysconfdir=$ac_optarg ;; |
861bb6c1 JL |
1256 | |
1257 | -target | --target | --targe | --targ | --tar | --ta | --t) | |
ba479fd2 | 1258 | ac_prev=target_alias ;; |
861bb6c1 | 1259 | -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) |
ba479fd2 | 1260 | target_alias=$ac_optarg ;; |
861bb6c1 JL |
1261 | |
1262 | -v | -verbose | --verbose | --verbos | --verbo | --verb) | |
1263 | verbose=yes ;; | |
1264 | ||
ba479fd2 NN |
1265 | -version | --version | --versio | --versi | --vers | -V) |
1266 | ac_init_version=: ;; | |
861bb6c1 JL |
1267 | |
1268 | -with-* | --with-*) | |
5213506e | 1269 | ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` |
861bb6c1 | 1270 | # Reject names that are not valid shell variable names. |
5213506e RW |
1271 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1272 | as_fn_error "invalid package name: $ac_useropt" | |
1273 | ac_useropt_orig=$ac_useropt | |
1274 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1275 | case $ac_user_opts in | |
1276 | *" | |
1277 | "with_$ac_useropt" | |
1278 | "*) ;; | |
1279 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" | |
1280 | ac_unrecognized_sep=', ';; | |
b61ff9c8 | 1281 | esac |
5213506e | 1282 | eval with_$ac_useropt=\$ac_optarg ;; |
861bb6c1 JL |
1283 | |
1284 | -without-* | --without-*) | |
5213506e | 1285 | ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` |
861bb6c1 | 1286 | # Reject names that are not valid shell variable names. |
5213506e RW |
1287 | expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && |
1288 | as_fn_error "invalid package name: $ac_useropt" | |
1289 | ac_useropt_orig=$ac_useropt | |
1290 | ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` | |
1291 | case $ac_user_opts in | |
1292 | *" | |
1293 | "with_$ac_useropt" | |
1294 | "*) ;; | |
1295 | *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" | |
1296 | ac_unrecognized_sep=', ';; | |
1297 | esac | |
1298 | eval with_$ac_useropt=no ;; | |
861bb6c1 JL |
1299 | |
1300 | --x) | |
1301 | # Obsolete; use --with-x. | |
1302 | with_x=yes ;; | |
1303 | ||
1304 | -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ | |
1305 | | --x-incl | --x-inc | --x-in | --x-i) | |
1306 | ac_prev=x_includes ;; | |
1307 | -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ | |
1308 | | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) | |
ba479fd2 | 1309 | x_includes=$ac_optarg ;; |
861bb6c1 JL |
1310 | |
1311 | -x-libraries | --x-libraries | --x-librarie | --x-librari \ | |
1312 | | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) | |
1313 | ac_prev=x_libraries ;; | |
1314 | -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ | |
1315 | | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) | |
ba479fd2 | 1316 | x_libraries=$ac_optarg ;; |
861bb6c1 | 1317 | |
5213506e RW |
1318 | -*) as_fn_error "unrecognized option: \`$ac_option' |
1319 | Try \`$0 --help' for more information." | |
861bb6c1 JL |
1320 | ;; |
1321 | ||
ba479fd2 NN |
1322 | *=*) |
1323 | ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` | |
1324 | # Reject names that are not valid shell variable names. | |
5213506e RW |
1325 | case $ac_envvar in #( |
1326 | '' | [0-9]* | *[!_$as_cr_alnum]* ) | |
1327 | as_fn_error "invalid variable name: \`$ac_envvar'" ;; | |
1328 | esac | |
1329 | eval $ac_envvar=\$ac_optarg | |
ba479fd2 NN |
1330 | export $ac_envvar ;; |
1331 | ||
861bb6c1 | 1332 | *) |
ba479fd2 | 1333 | # FIXME: should be removed in autoconf 3.0. |
5213506e | 1334 | $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 |
ba479fd2 | 1335 | expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && |
5213506e | 1336 | $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 |
ba479fd2 | 1337 | : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} |
861bb6c1 JL |
1338 | ;; |
1339 | ||
1340 | esac | |
1341 | done | |
1342 | ||
1343 | if test -n "$ac_prev"; then | |
ba479fd2 | 1344 | ac_option=--`echo $ac_prev | sed 's/_/-/g'` |
5213506e | 1345 | as_fn_error "missing argument to $ac_option" |
63cf211a | 1346 | fi |
63cf211a | 1347 | |
5213506e RW |
1348 | if test -n "$ac_unrecognized_opts"; then |
1349 | case $enable_option_checking in | |
1350 | no) ;; | |
1351 | fatal) as_fn_error "unrecognized options: $ac_unrecognized_opts" ;; | |
1352 | *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; | |
2f41c1d6 | 1353 | esac |
5213506e | 1354 | fi |
2f41c1d6 | 1355 | |
5213506e RW |
1356 | # Check all directory arguments for consistency. |
1357 | for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ | |
1358 | datadir sysconfdir sharedstatedir localstatedir includedir \ | |
1359 | oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ | |
1360 | libdir localedir mandir | |
b61ff9c8 | 1361 | do |
5213506e RW |
1362 | eval ac_val=\$$ac_var |
1363 | # Remove trailing slashes. | |
1364 | case $ac_val in | |
1365 | */ ) | |
1366 | ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` | |
1367 | eval $ac_var=\$ac_val;; | |
1368 | esac | |
1369 | # Be sure to have absolute directory names. | |
b61ff9c8 | 1370 | case $ac_val in |
5213506e RW |
1371 | [\\/$]* | ?:[\\/]* ) continue;; |
1372 | NONE | '' ) case $ac_var in *prefix ) continue;; esac;; | |
b61ff9c8 | 1373 | esac |
5213506e | 1374 | as_fn_error "expected an absolute directory name for --$ac_var: $ac_val" |
b61ff9c8 BS |
1375 | done |
1376 | ||
1377 | # There might be people who depend on the old broken behavior: `$host' | |
1378 | # used to hold the argument of --host etc. | |
1379 | # FIXME: To remove some day. | |
1380 | build=$build_alias | |
1381 | host=$host_alias | |
ba479fd2 NN |
1382 | target=$target_alias |
1383 | ||
1384 | # FIXME: To remove some day. | |
1385 | if test "x$host_alias" != x; then | |
1386 | if test "x$build_alias" = x; then | |
1387 | cross_compiling=maybe | |
5213506e | 1388 | $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host. |
ba479fd2 NN |
1389 | If a cross compiler is detected then cross compile mode will be used." >&2 |
1390 | elif test "x$build_alias" != "x$host_alias"; then | |
1391 | cross_compiling=yes | |
1392 | fi | |
1393 | fi | |
6e3f3080 | 1394 | |
ba479fd2 NN |
1395 | ac_tool_prefix= |
1396 | test -n "$host_alias" && ac_tool_prefix=$host_alias- | |
1397 | ||
1398 | test "$silent" = yes && exec 6>/dev/null | |
861bb6c1 | 1399 | |
861bb6c1 | 1400 | |
5213506e RW |
1401 | ac_pwd=`pwd` && test -n "$ac_pwd" && |
1402 | ac_ls_di=`ls -di .` && | |
1403 | ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || | |
1404 | as_fn_error "working directory cannot be determined" | |
1405 | test "X$ac_ls_di" = "X$ac_pwd_ls_di" || | |
1406 | as_fn_error "pwd does not report name of working directory" | |
1407 | ||
1408 | ||
861bb6c1 JL |
1409 | # Find the source files, if location was not specified. |
1410 | if test -z "$srcdir"; then | |
1411 | ac_srcdir_defaulted=yes | |
5213506e RW |
1412 | # Try the directory containing this script, then the parent directory. |
1413 | ac_confdir=`$as_dirname -- "$as_myself" || | |
1414 | $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
1415 | X"$as_myself" : 'X\(//\)[^/]' \| \ | |
1416 | X"$as_myself" : 'X\(//\)$' \| \ | |
1417 | X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || | |
1418 | $as_echo X"$as_myself" | | |
1419 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
1420 | s//\1/ | |
1421 | q | |
1422 | } | |
1423 | /^X\(\/\/\)[^/].*/{ | |
1424 | s//\1/ | |
1425 | q | |
1426 | } | |
1427 | /^X\(\/\/\)$/{ | |
1428 | s//\1/ | |
1429 | q | |
1430 | } | |
1431 | /^X\(\/\).*/{ | |
1432 | s//\1/ | |
1433 | q | |
1434 | } | |
1435 | s/.*/./; q'` | |
861bb6c1 | 1436 | srcdir=$ac_confdir |
5213506e | 1437 | if test ! -r "$srcdir/$ac_unique_file"; then |
861bb6c1 JL |
1438 | srcdir=.. |
1439 | fi | |
1440 | else | |
1441 | ac_srcdir_defaulted=no | |
1442 | fi | |
5213506e RW |
1443 | if test ! -r "$srcdir/$ac_unique_file"; then |
1444 | test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." | |
1445 | as_fn_error "cannot find sources ($ac_unique_file) in $srcdir" | |
1446 | fi | |
1447 | ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" | |
1448 | ac_abs_confdir=`( | |
1449 | cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error "$ac_msg" | |
1450 | pwd)` | |
1451 | # When building in place, set srcdir=. | |
1452 | if test "$ac_abs_confdir" = "$ac_pwd"; then | |
1453 | srcdir=. | |
1454 | fi | |
1455 | # Remove unnecessary trailing slashes from srcdir. | |
1456 | # Double slashes in file names in object file debugging info | |
1457 | # mess up M-x gdb in Emacs. | |
1458 | case $srcdir in | |
1459 | */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; | |
1460 | esac | |
1461 | for ac_var in $ac_precious_vars; do | |
1462 | eval ac_env_${ac_var}_set=\${${ac_var}+set} | |
1463 | eval ac_env_${ac_var}_value=\$${ac_var} | |
1464 | eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} | |
1465 | eval ac_cv_env_${ac_var}_value=\$${ac_var} | |
1466 | done | |
63cf211a | 1467 | |
ba479fd2 NN |
1468 | # |
1469 | # Report the --help message. | |
1470 | # | |
1471 | if test "$ac_init_help" = "long"; then | |
1472 | # Omit some internal or obsolete options to make the list less imposing. | |
1473 | # This message is too long to be a string in the A/UX 3.1 sh. | |
1474 | cat <<_ACEOF | |
1475 | \`configure' configures this package to adapt to many kinds of systems. | |
861bb6c1 | 1476 | |
ba479fd2 | 1477 | Usage: $0 [OPTION]... [VAR=VALUE]... |
861bb6c1 | 1478 | |
ba479fd2 NN |
1479 | To assign environment variables (e.g., CC, CFLAGS...), specify them as |
1480 | VAR=VALUE. See below for descriptions of some of the useful variables. | |
861bb6c1 | 1481 | |
ba479fd2 | 1482 | Defaults for the options are specified in brackets. |
861bb6c1 | 1483 | |
ba479fd2 NN |
1484 | Configuration: |
1485 | -h, --help display this help and exit | |
1486 | --help=short display options specific to this package | |
1487 | --help=recursive display the short help of all the included packages | |
1488 | -V, --version display version information and exit | |
1489 | -q, --quiet, --silent do not print \`checking...' messages | |
1490 | --cache-file=FILE cache test results in FILE [disabled] | |
1491 | -C, --config-cache alias for \`--cache-file=config.cache' | |
1492 | -n, --no-create do not create output files | |
1493 | --srcdir=DIR find the sources in DIR [configure dir or \`..'] | |
1494 | ||
ba479fd2 NN |
1495 | Installation directories: |
1496 | --prefix=PREFIX install architecture-independent files in PREFIX | |
5213506e | 1497 | [$ac_default_prefix] |
ba479fd2 | 1498 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX |
5213506e | 1499 | [PREFIX] |
861bb6c1 | 1500 | |
ba479fd2 NN |
1501 | By default, \`make install' will install all the files in |
1502 | \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify | |
1503 | an installation prefix other than \`$ac_default_prefix' using \`--prefix', | |
1504 | for instance \`--prefix=\$HOME'. | |
13c22933 | 1505 | |
ba479fd2 | 1506 | For better control, use the options below. |
13c22933 | 1507 | |
ba479fd2 | 1508 | Fine tuning of the installation directories: |
5213506e RW |
1509 | --bindir=DIR user executables [EPREFIX/bin] |
1510 | --sbindir=DIR system admin executables [EPREFIX/sbin] | |
1511 | --libexecdir=DIR program executables [EPREFIX/libexec] | |
1512 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc] | |
1513 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] | |
1514 | --localstatedir=DIR modifiable single-machine data [PREFIX/var] | |
1515 | --libdir=DIR object code libraries [EPREFIX/lib] | |
1516 | --includedir=DIR C header files [PREFIX/include] | |
1517 | --oldincludedir=DIR C header files for non-gcc [/usr/include] | |
1518 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] | |
1519 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR] | |
1520 | --infodir=DIR info documentation [DATAROOTDIR/info] | |
1521 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale] | |
1522 | --mandir=DIR man documentation [DATAROOTDIR/man] | |
1523 | --docdir=DIR documentation root [DATAROOTDIR/doc/PACKAGE] | |
1524 | --htmldir=DIR html documentation [DOCDIR] | |
1525 | --dvidir=DIR dvi documentation [DOCDIR] | |
1526 | --pdfdir=DIR pdf documentation [DOCDIR] | |
1527 | --psdir=DIR ps documentation [DOCDIR] | |
ba479fd2 | 1528 | _ACEOF |
13c22933 | 1529 | |
ba479fd2 | 1530 | cat <<\_ACEOF |
13c22933 | 1531 | |
ba479fd2 NN |
1532 | Program names: |
1533 | --program-prefix=PREFIX prepend PREFIX to installed program names | |
1534 | --program-suffix=SUFFIX append SUFFIX to installed program names | |
1535 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names | |
13c22933 | 1536 | |
ba479fd2 NN |
1537 | System types: |
1538 | --build=BUILD configure for building on BUILD [guessed] | |
1539 | --host=HOST cross-compile to build programs to run on HOST [BUILD] | |
1540 | --target=TARGET configure for building compilers for TARGET [HOST] | |
1541 | _ACEOF | |
13c22933 JJ |
1542 | fi |
1543 | ||
ba479fd2 | 1544 | if test -n "$ac_init_help"; then |
13c22933 | 1545 | |
ba479fd2 | 1546 | cat <<\_ACEOF |
13c22933 | 1547 | |
ba479fd2 | 1548 | Optional Features: |
5213506e | 1549 | --disable-option-checking ignore unrecognized --enable/--with options |
ba479fd2 NN |
1550 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) |
1551 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes] | |
03787dfd KC |
1552 | --enable-generated-files-in-srcdir |
1553 | put copies of generated files in source dir | |
1554 | intended for creating source tarballs for users | |
1555 | without texinfo bison or flex. | |
3bbd5a19 | 1556 | --enable-werror-always enable -Werror despite compiler version |
ba479fd2 NN |
1557 | --enable-checking=LIST |
1558 | enable expensive run-time checks. With LIST, | |
1559 | enable only specific categories of checks. | |
cdce5c16 | 1560 | Categories are: yes,no,all,none,release. |
726a989a | 1561 | Flags are: assert,df,fold,gc,gcac,gimple,misc, |
7e98624c | 1562 | rtlflag,rtl,runtime,tree,valgrind,types. |
ba479fd2 | 1563 | --enable-coverage=LEVEL |
fb38008e | 1564 | enable compiler's code coverage collection. |
ba479fd2 NN |
1565 | Use to measure compiler performance and locate |
1566 | unused parts of the compiler. With LEVEL, specify | |
1567 | optimization. Values are opt, noopt, | |
1568 | default is noopt | |
1569 | --enable-gather-detailed-mem-stats enable detailed memory allocation stats gathering | |
00020c16 | 1570 | --enable-build-with-cxx build with C++ compiler instead of C compiler |
ba479fd2 NN |
1571 | --enable-multilib enable library support for multiple ABIs |
1572 | --enable-__cxa_atexit enable __cxa_atexit for C++ | |
79b87c74 MM |
1573 | --enable-decimal-float={no,yes,bid,dpd} |
1574 | enable decimal float extension to C. Selecting 'bid' | |
1575 | or 'dpd' choses which decimal floating point format | |
1576 | to use | |
ab22c1fa | 1577 | --enable-fixed-point enable fixed-point arithmetic extension to C |
ba479fd2 NN |
1578 | --enable-threads enable thread usage for target GCC |
1579 | --enable-threads=LIB use LIB thread package for target GCC | |
8dea1cca DD |
1580 | --enable-tls enable or disable generation of tls code |
1581 | overriding the assembler check for tls support | |
ba479fd2 NN |
1582 | --enable-objc-gc enable the use of Boehm's garbage collector with |
1583 | the GNU Objective-C runtime | |
1584 | --disable-shared don't provide a shared libgcc | |
1585 | --enable-intermodule build the compiler in one step | |
f3c9f174 | 1586 | --enable-languages=LIST specify which front-ends to build |
dfb77e37 | 1587 | --disable-rpath do not hardcode runtime library paths |
ba479fd2 NN |
1588 | --enable-initfini-array use .init_array/.fini_array sections |
1589 | --enable-sjlj-exceptions | |
1590 | arrange to use setjmp/longjmp exception handling | |
7f970b70 | 1591 | --enable-secureplt enable -msecure-plt by default for PowerPC |
922e3e33 | 1592 | --enable-cld enable -mcld by default for 32bit x86 |
ba479fd2 NN |
1593 | --disable-win32-registry |
1594 | disable lookup of installation paths in the | |
1595 | Registry on Windows hosts | |
1596 | --enable-win32-registry enable registry lookup (default) | |
1597 | --enable-win32-registry=KEY | |
1598 | use KEY instead of GCC version as the last portion | |
1599 | of the registry key | |
5213506e RW |
1600 | --enable-shared[=PKGS] build shared libraries [default=yes] |
1601 | --enable-static[=PKGS] build static libraries [default=yes] | |
da0f6381 PB |
1602 | --enable-fast-install[=PKGS] |
1603 | optimize for fast installation [default=yes] | |
1604 | --disable-libtool-lock avoid locking (might break parallel builds) | |
e31bcd1b JM |
1605 | --enable-gnu-unique-object enable the use of the @gnu_unique_object ELF extension on |
1606 | glibc systems | |
cd533689 PP |
1607 | --enable-linker-build-id |
1608 | compiler will always pass --build-id to linker | |
ba479fd2 NN |
1609 | --enable-maintainer-mode |
1610 | enable make rules and dependencies not useful | |
1611 | (and sometimes confusing) to the casual installer | |
1612 | --enable-version-specific-runtime-libs | |
1613 | specify that runtime libraries should be | |
1614 | installed in a compiler-specific directory | |
68a607d8 | 1615 | --enable-plugin enable plugin support |
093e61a6 | 1616 | |
ba479fd2 NN |
1617 | Optional Packages: |
1618 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] | |
1619 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) | |
1546bb64 | 1620 | --with-build-libsubdir=DIR Directory where to find libraries for build system |
ba479fd2 NN |
1621 | --with-local-prefix=DIR specifies directory to put local include |
1622 | --with-gxx-include-dir=DIR | |
1623 | specifies directory to put g++ header files | |
1624 | --with-cpp-install-dir=DIR | |
1625 | install the user visible C preprocessor in DIR | |
1626 | (relative to PREFIX) as well as PREFIX/bin | |
1627 | --with-gnu-ld arrange to work with GNU ld. | |
1628 | --with-ld arrange to use the specified ld (full pathname) | |
d594623a | 1629 | --with-demangler-in-ld try to use demangler in GNU ld. |
ba479fd2 NN |
1630 | --with-gnu-as arrange to work with GNU as |
1631 | --with-as arrange to use the specified as (full pathname) | |
1632 | --with-stabs arrange to use stabs instead of host debug format | |
1633 | --with-dwarf2 force the default debug format to be DWARF 2 | |
160633c6 MM |
1634 | --with-build-sysroot=sysroot |
1635 | use sysroot as the system root during the build | |
ba479fd2 | 1636 | --with-sysroot=DIR Search for usr/lib, usr/include, et al, within DIR. |
e11ddaf5 | 1637 | --with-specs=SPECS add SPECS to driver command-line processing |
2f41c1d6 PB |
1638 | --with-pkgversion=PKG Use PKG in the version string in place of "GCC" |
1639 | --with-bugurl=URL Direct users to URL to report a bug | |
aca600aa | 1640 | --with-multilib-list Select multilibs (SH only) |
dfb77e37 KC |
1641 | --with-gnu-ld assume the C compiler uses GNU ld default=no |
1642 | --with-libiconv-prefix[=DIR] search for libiconv in DIR/include and DIR/lib | |
1643 | --without-libiconv-prefix don't search for libiconv in includedir and libdir | |
443728bb | 1644 | --with-system-libunwind use installed libunwind |
da0f6381 PB |
1645 | --with-pic try to use only PIC/non-PIC objects [default=use |
1646 | both] | |
1647 | --with-gnu-ld assume the C compiler uses GNU ld [default=no] | |
5938f74d | 1648 | --with-plugin-ld=[ARG] specify the plugin linker |
ed965309 | 1649 | --with-long-double-128 Use 128-bit long double by default. |
59415997 | 1650 | --with-gc={page,zone} choose the garbage collection mechanism to use |
ba479fd2 NN |
1651 | with the compiler |
1652 | --with-system-zlib use installed libz | |
22482f74 | 1653 | --with-slibdir=DIR shared libraries in DIR [LIBDIR] |
13c22933 | 1654 | |
ba479fd2 NN |
1655 | Some influential environment variables: |
1656 | CC C compiler command | |
1657 | CFLAGS C compiler flags | |
1658 | LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a | |
1659 | nonstandard directory <lib dir> | |
5213506e RW |
1660 | LIBS libraries to pass to the linker, e.g. -l<library> |
1661 | CPPFLAGS C/C++/Objective C preprocessor flags, e.g. -I<include dir> if | |
1662 | you have headers in a nonstandard directory <include dir> | |
00020c16 ILT |
1663 | CXX C++ compiler command |
1664 | CXXFLAGS C++ compiler flags | |
ba479fd2 | 1665 | CPP C preprocessor |
00020c16 | 1666 | CXXCPP C++ preprocessor |
6de9cd9a DN |
1667 | GMPLIBS How to link GMP |
1668 | GMPINC How to find GMP include files | |
f8bf9252 SP |
1669 | PPLLIBS How to link PPL |
1670 | PPLINC How to find PPL include files | |
1671 | CLOOGLIBS How to link CLOOG | |
1672 | CLOOGINC How to find CLOOG include files | |
d7f09764 DN |
1673 | LIBELFLIBS How to link libelf |
1674 | LIBELFINC How to find libelf include files | |
13c22933 | 1675 | |
ba479fd2 NN |
1676 | Use these variables to override the choices made by `configure' or to help |
1677 | it to find libraries and programs with nonstandard names/locations. | |
73458fb7 | 1678 | |
5213506e | 1679 | Report bugs to the package provider. |
ba479fd2 | 1680 | _ACEOF |
5213506e | 1681 | ac_status=$? |
ba479fd2 | 1682 | fi |
6e3f3080 | 1683 | |
ba479fd2 NN |
1684 | if test "$ac_init_help" = "recursive"; then |
1685 | # If there are subdirs, report their specific --help. | |
ba479fd2 | 1686 | for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue |
5213506e RW |
1687 | test -d "$ac_dir" || |
1688 | { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || | |
1689 | continue | |
ba479fd2 NN |
1690 | ac_builddir=. |
1691 | ||
5213506e RW |
1692 | case "$ac_dir" in |
1693 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1694 | *) | |
1695 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
1696 | # A ".." for each directory in $ac_dir_suffix. | |
1697 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
1698 | case $ac_top_builddir_sub in | |
1699 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
1700 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
1701 | esac ;; | |
1702 | esac | |
1703 | ac_abs_top_builddir=$ac_pwd | |
1704 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
1705 | # for backward compatibility: | |
1706 | ac_top_builddir=$ac_top_build_prefix | |
ba479fd2 NN |
1707 | |
1708 | case $srcdir in | |
5213506e | 1709 | .) # We are building in place. |
ba479fd2 | 1710 | ac_srcdir=. |
5213506e RW |
1711 | ac_top_srcdir=$ac_top_builddir_sub |
1712 | ac_abs_top_srcdir=$ac_pwd ;; | |
1713 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
ba479fd2 | 1714 | ac_srcdir=$srcdir$ac_dir_suffix; |
5213506e RW |
1715 | ac_top_srcdir=$srcdir |
1716 | ac_abs_top_srcdir=$srcdir ;; | |
1717 | *) # Relative name. | |
1718 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
1719 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
1720 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
86da66b5 | 1721 | esac |
5213506e RW |
1722 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
1723 | ||
1724 | cd "$ac_dir" || { ac_status=$?; continue; } | |
1725 | # Check for guested configure. | |
1726 | if test -f "$ac_srcdir/configure.gnu"; then | |
1727 | echo && | |
1728 | $SHELL "$ac_srcdir/configure.gnu" --help=recursive | |
1729 | elif test -f "$ac_srcdir/configure"; then | |
1730 | echo && | |
1731 | $SHELL "$ac_srcdir/configure" --help=recursive | |
ba479fd2 | 1732 | else |
5213506e RW |
1733 | $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 |
1734 | fi || ac_status=$? | |
1735 | cd "$ac_pwd" || { ac_status=$?; break; } | |
ba479fd2 NN |
1736 | done |
1737 | fi | |
1738 | ||
5213506e | 1739 | test -n "$ac_init_help" && exit $ac_status |
ba479fd2 NN |
1740 | if $ac_init_version; then |
1741 | cat <<\_ACEOF | |
5213506e RW |
1742 | configure |
1743 | generated by GNU Autoconf 2.64 | |
ba479fd2 | 1744 | |
5213506e | 1745 | Copyright (C) 2009 Free Software Foundation, Inc. |
ba479fd2 NN |
1746 | This configure script is free software; the Free Software Foundation |
1747 | gives unlimited permission to copy, distribute and modify it. | |
1748 | _ACEOF | |
5213506e | 1749 | exit |
ba479fd2 | 1750 | fi |
ba479fd2 | 1751 | |
5213506e RW |
1752 | ## ------------------------ ## |
1753 | ## Autoconf initialization. ## | |
1754 | ## ------------------------ ## | |
ba479fd2 | 1755 | |
5213506e RW |
1756 | # ac_fn_c_try_compile LINENO |
1757 | # -------------------------- | |
1758 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1759 | ac_fn_c_try_compile () | |
ba479fd2 | 1760 | { |
5213506e RW |
1761 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
1762 | rm -f conftest.$ac_objext | |
1763 | if { { ac_try="$ac_compile" | |
1764 | case "(($ac_try" in | |
1765 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1766 | *) ac_try_echo=$ac_try;; | |
1767 | esac | |
1768 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1769 | $as_echo "$ac_try_echo"; } >&5 | |
1770 | (eval "$ac_compile") 2>conftest.err | |
1771 | ac_status=$? | |
1772 | if test -s conftest.err; then | |
1773 | grep -v '^ *+' conftest.err >conftest.er1 | |
1774 | cat conftest.er1 >&5 | |
1775 | mv -f conftest.er1 conftest.err | |
1776 | fi | |
1777 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1778 | test $ac_status = 0; } && { | |
1779 | test -z "$ac_c_werror_flag" || | |
1780 | test ! -s conftest.err | |
1781 | } && test -s conftest.$ac_objext; then : | |
1782 | ac_retval=0 | |
1783 | else | |
1784 | $as_echo "$as_me: failed program was:" >&5 | |
1785 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 1786 | |
5213506e RW |
1787 | ac_retval=1 |
1788 | fi | |
1789 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
1790 | return $ac_retval | |
ba479fd2 | 1791 | |
5213506e | 1792 | } # ac_fn_c_try_compile |
ba479fd2 | 1793 | |
5213506e RW |
1794 | # ac_fn_cxx_try_compile LINENO |
1795 | # ---------------------------- | |
1796 | # Try to compile conftest.$ac_ext, and return whether this succeeded. | |
1797 | ac_fn_cxx_try_compile () | |
1798 | { | |
1799 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1800 | rm -f conftest.$ac_objext | |
1801 | if { { ac_try="$ac_compile" | |
1802 | case "(($ac_try" in | |
1803 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1804 | *) ac_try_echo=$ac_try;; | |
1805 | esac | |
1806 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1807 | $as_echo "$ac_try_echo"; } >&5 | |
1808 | (eval "$ac_compile") 2>conftest.err | |
1809 | ac_status=$? | |
1810 | if test -s conftest.err; then | |
1811 | grep -v '^ *+' conftest.err >conftest.er1 | |
1812 | cat conftest.er1 >&5 | |
1813 | mv -f conftest.er1 conftest.err | |
1814 | fi | |
1815 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1816 | test $ac_status = 0; } && { | |
1817 | test -z "$ac_cxx_werror_flag" || | |
1818 | test ! -s conftest.err | |
1819 | } && test -s conftest.$ac_objext; then : | |
1820 | ac_retval=0 | |
1821 | else | |
1822 | $as_echo "$as_me: failed program was:" >&5 | |
1823 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 1824 | |
5213506e RW |
1825 | ac_retval=1 |
1826 | fi | |
1827 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
1828 | return $ac_retval | |
ba479fd2 | 1829 | |
5213506e | 1830 | } # ac_fn_cxx_try_compile |
ba479fd2 | 1831 | |
5213506e RW |
1832 | # ac_fn_c_try_cpp LINENO |
1833 | # ---------------------- | |
1834 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
1835 | ac_fn_c_try_cpp () | |
1836 | { | |
1837 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1838 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
1839 | case "(($ac_try" in | |
1840 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1841 | *) ac_try_echo=$ac_try;; | |
1842 | esac | |
1843 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1844 | $as_echo "$ac_try_echo"; } >&5 | |
1845 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
1846 | ac_status=$? | |
1847 | if test -s conftest.err; then | |
1848 | grep -v '^ *+' conftest.err >conftest.er1 | |
1849 | cat conftest.er1 >&5 | |
1850 | mv -f conftest.er1 conftest.err | |
1851 | fi | |
1852 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1853 | test $ac_status = 0; } >/dev/null && { | |
1854 | test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || | |
1855 | test ! -s conftest.err | |
1856 | }; then : | |
1857 | ac_retval=0 | |
1858 | else | |
1859 | $as_echo "$as_me: failed program was:" >&5 | |
1860 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 1861 | |
5213506e RW |
1862 | ac_retval=1 |
1863 | fi | |
1864 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
1865 | return $ac_retval | |
ba479fd2 | 1866 | |
5213506e | 1867 | } # ac_fn_c_try_cpp |
ba479fd2 | 1868 | |
5213506e RW |
1869 | # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES |
1870 | # ------------------------------------------------------- | |
1871 | # Tests whether HEADER exists, giving a warning if it cannot be compiled using | |
1872 | # the include files in INCLUDES and setting the cache variable VAR | |
1873 | # accordingly. | |
1874 | ac_fn_c_check_header_mongrel () | |
1875 | { | |
1876 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
1877 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
1878 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1879 | $as_echo_n "checking for $2... " >&6; } | |
1880 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
1881 | $as_echo_n "(cached) " >&6 | |
1882 | fi | |
1883 | eval ac_res=\$$3 | |
1884 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1885 | $as_echo "$ac_res" >&6; } | |
1886 | else | |
1887 | # Is the header compilable? | |
1888 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 | |
1889 | $as_echo_n "checking $2 usability... " >&6; } | |
1890 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1891 | /* end confdefs.h. */ | |
1892 | $4 | |
1893 | #include <$2> | |
ba479fd2 | 1894 | _ACEOF |
5213506e RW |
1895 | if ac_fn_c_try_compile "$LINENO"; then : |
1896 | ac_header_compiler=yes | |
1897 | else | |
1898 | ac_header_compiler=no | |
1899 | fi | |
1900 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
1901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 | |
1902 | $as_echo "$ac_header_compiler" >&6; } | |
ba479fd2 | 1903 | |
5213506e RW |
1904 | # Is the header present? |
1905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 | |
1906 | $as_echo_n "checking $2 presence... " >&6; } | |
1907 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
1908 | /* end confdefs.h. */ | |
1909 | #include <$2> | |
1910 | _ACEOF | |
1911 | if ac_fn_c_try_cpp "$LINENO"; then : | |
1912 | ac_header_preproc=yes | |
1913 | else | |
1914 | ac_header_preproc=no | |
1915 | fi | |
1916 | rm -f conftest.err conftest.$ac_ext | |
1917 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 | |
1918 | $as_echo "$ac_header_preproc" >&6; } | |
ba479fd2 | 1919 | |
5213506e RW |
1920 | # So? What about this header? |
1921 | case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #(( | |
1922 | yes:no: ) | |
1923 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 | |
1924 | $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} | |
1925 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1926 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1927 | ;; | |
1928 | no:yes:* ) | |
1929 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 | |
1930 | $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} | |
1931 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 | |
1932 | $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} | |
1933 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 | |
1934 | $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} | |
1935 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 | |
1936 | $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} | |
1937 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 | |
1938 | $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} | |
1939 | ;; | |
1940 | esac | |
1941 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
1942 | $as_echo_n "checking for $2... " >&6; } | |
1943 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
1944 | $as_echo_n "(cached) " >&6 | |
1945 | else | |
1946 | eval "$3=\$ac_header_compiler" | |
1947 | fi | |
1948 | eval ac_res=\$$3 | |
1949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
1950 | $as_echo "$ac_res" >&6; } | |
1951 | fi | |
1952 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
ba479fd2 | 1953 | |
5213506e | 1954 | } # ac_fn_c_check_header_mongrel |
ba479fd2 | 1955 | |
5213506e RW |
1956 | # ac_fn_c_try_run LINENO |
1957 | # ---------------------- | |
1958 | # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes | |
1959 | # that executables *can* be run. | |
1960 | ac_fn_c_try_run () | |
b61ff9c8 | 1961 | { |
5213506e RW |
1962 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack |
1963 | if { { ac_try="$ac_link" | |
1964 | case "(($ac_try" in | |
1965 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1966 | *) ac_try_echo=$ac_try;; | |
1967 | esac | |
1968 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1969 | $as_echo "$ac_try_echo"; } >&5 | |
1970 | (eval "$ac_link") 2>&5 | |
1971 | ac_status=$? | |
1972 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1973 | test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' | |
1974 | { { case "(($ac_try" in | |
1975 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
1976 | *) ac_try_echo=$ac_try;; | |
1977 | esac | |
1978 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
1979 | $as_echo "$ac_try_echo"; } >&5 | |
1980 | (eval "$ac_try") 2>&5 | |
1981 | ac_status=$? | |
1982 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
1983 | test $ac_status = 0; }; }; then : | |
1984 | ac_retval=0 | |
1985 | else | |
1986 | $as_echo "$as_me: program exited with status $ac_status" >&5 | |
1987 | $as_echo "$as_me: failed program was:" >&5 | |
1988 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 1989 | |
5213506e RW |
1990 | ac_retval=$ac_status |
1991 | fi | |
1992 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
1993 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
1994 | return $ac_retval | |
ba479fd2 | 1995 | |
5213506e | 1996 | } # ac_fn_c_try_run |
ba479fd2 | 1997 | |
5213506e RW |
1998 | # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES |
1999 | # ------------------------------------------------------- | |
2000 | # Tests whether HEADER exists and can be compiled using the include files in | |
2001 | # INCLUDES, setting the cache variable VAR accordingly. | |
2002 | ac_fn_c_check_header_compile () | |
2003 | { | |
2004 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2005 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2006 | $as_echo_n "checking for $2... " >&6; } | |
2007 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
2008 | $as_echo_n "(cached) " >&6 | |
2009 | else | |
2010 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2011 | /* end confdefs.h. */ | |
2012 | $4 | |
2013 | #include <$2> | |
ba479fd2 | 2014 | _ACEOF |
5213506e RW |
2015 | if ac_fn_c_try_compile "$LINENO"; then : |
2016 | eval "$3=yes" | |
2017 | else | |
2018 | eval "$3=no" | |
2019 | fi | |
2020 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2021 | fi | |
2022 | eval ac_res=\$$3 | |
2023 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2024 | $as_echo "$ac_res" >&6; } | |
2025 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
ba479fd2 | 2026 | |
5213506e | 2027 | } # ac_fn_c_check_header_compile |
ba479fd2 | 2028 | |
5213506e RW |
2029 | # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES |
2030 | # -------------------------------------------- | |
2031 | # Tries to find the compile-time value of EXPR in a program that includes | |
2032 | # INCLUDES, setting VAR accordingly. Returns whether the value could be | |
2033 | # computed | |
2034 | ac_fn_c_compute_int () | |
2035 | { | |
2036 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2037 | if test "$cross_compiling" = yes; then | |
2038 | # Depending upon the size, compute the lo and hi bounds. | |
2039 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2040 | /* end confdefs.h. */ | |
2041 | $4 | |
2042 | int | |
2043 | main () | |
2044 | { | |
2045 | static int test_array [1 - 2 * !(($2) >= 0)]; | |
2046 | test_array [0] = 0 | |
ba479fd2 | 2047 | |
5213506e RW |
2048 | ; |
2049 | return 0; | |
2050 | } | |
ba479fd2 | 2051 | _ACEOF |
5213506e RW |
2052 | if ac_fn_c_try_compile "$LINENO"; then : |
2053 | ac_lo=0 ac_mid=0 | |
2054 | while :; do | |
2055 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2056 | /* end confdefs.h. */ | |
2057 | $4 | |
2058 | int | |
2059 | main () | |
2060 | { | |
2061 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2062 | test_array [0] = 0 | |
ba479fd2 | 2063 | |
5213506e RW |
2064 | ; |
2065 | return 0; | |
2066 | } | |
ba479fd2 | 2067 | _ACEOF |
5213506e RW |
2068 | if ac_fn_c_try_compile "$LINENO"; then : |
2069 | ac_hi=$ac_mid; break | |
2070 | else | |
2071 | as_fn_arith $ac_mid + 1 && ac_lo=$as_val | |
2072 | if test $ac_lo -le $ac_mid; then | |
2073 | ac_lo= ac_hi= | |
2074 | break | |
2075 | fi | |
2076 | as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val | |
2077 | fi | |
2078 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2079 | done | |
2080 | else | |
2081 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2082 | /* end confdefs.h. */ | |
2083 | $4 | |
2084 | int | |
2085 | main () | |
2086 | { | |
2087 | static int test_array [1 - 2 * !(($2) < 0)]; | |
2088 | test_array [0] = 0 | |
ba479fd2 | 2089 | |
5213506e RW |
2090 | ; |
2091 | return 0; | |
2092 | } | |
ba479fd2 | 2093 | _ACEOF |
5213506e RW |
2094 | if ac_fn_c_try_compile "$LINENO"; then : |
2095 | ac_hi=-1 ac_mid=-1 | |
2096 | while :; do | |
2097 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2098 | /* end confdefs.h. */ | |
2099 | $4 | |
2100 | int | |
2101 | main () | |
2102 | { | |
2103 | static int test_array [1 - 2 * !(($2) >= $ac_mid)]; | |
2104 | test_array [0] = 0 | |
ba479fd2 | 2105 | |
5213506e RW |
2106 | ; |
2107 | return 0; | |
2108 | } | |
2109 | _ACEOF | |
2110 | if ac_fn_c_try_compile "$LINENO"; then : | |
2111 | ac_lo=$ac_mid; break | |
2112 | else | |
2113 | as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val | |
2114 | if test $ac_mid -le $ac_hi; then | |
2115 | ac_lo= ac_hi= | |
2116 | break | |
2117 | fi | |
2118 | as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val | |
ba479fd2 | 2119 | fi |
5213506e RW |
2120 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2121 | done | |
ba479fd2 | 2122 | else |
5213506e | 2123 | ac_lo= ac_hi= |
ba479fd2 | 2124 | fi |
5213506e RW |
2125 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2126 | fi | |
2127 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2128 | # Binary search between lo and hi bounds. | |
2129 | while test "x$ac_lo" != "x$ac_hi"; do | |
2130 | as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val | |
2131 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2132 | /* end confdefs.h. */ | |
2133 | $4 | |
2134 | int | |
2135 | main () | |
2136 | { | |
2137 | static int test_array [1 - 2 * !(($2) <= $ac_mid)]; | |
2138 | test_array [0] = 0 | |
ba479fd2 | 2139 | |
5213506e RW |
2140 | ; |
2141 | return 0; | |
2142 | } | |
2143 | _ACEOF | |
2144 | if ac_fn_c_try_compile "$LINENO"; then : | |
2145 | ac_hi=$ac_mid | |
2146 | else | |
2147 | as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val | |
ba479fd2 | 2148 | fi |
5213506e RW |
2149 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2150 | done | |
2151 | case $ac_lo in #(( | |
2152 | ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; | |
2153 | '') ac_retval=1 ;; | |
2154 | esac | |
2155 | else | |
2156 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2157 | /* end confdefs.h. */ | |
2158 | $4 | |
2159 | static long int longval () { return $2; } | |
2160 | static unsigned long int ulongval () { return $2; } | |
2161 | #include <stdio.h> | |
2162 | #include <stdlib.h> | |
2163 | int | |
2164 | main () | |
2165 | { | |
ba479fd2 | 2166 | |
5213506e RW |
2167 | FILE *f = fopen ("conftest.val", "w"); |
2168 | if (! f) | |
2169 | return 1; | |
2170 | if (($2) < 0) | |
2171 | { | |
2172 | long int i = longval (); | |
2173 | if (i != ($2)) | |
2174 | return 1; | |
2175 | fprintf (f, "%ld", i); | |
2176 | } | |
2177 | else | |
2178 | { | |
2179 | unsigned long int i = ulongval (); | |
2180 | if (i != ($2)) | |
2181 | return 1; | |
2182 | fprintf (f, "%lu", i); | |
2183 | } | |
2184 | /* Do not output a trailing newline, as this causes \r\n confusion | |
2185 | on some platforms. */ | |
2186 | return ferror (f) || fclose (f) != 0; | |
ba479fd2 | 2187 | |
5213506e RW |
2188 | ; |
2189 | return 0; | |
2190 | } | |
2191 | _ACEOF | |
2192 | if ac_fn_c_try_run "$LINENO"; then : | |
2193 | echo >>conftest.val; read $3 <conftest.val; ac_retval=0 | |
2194 | else | |
2195 | ac_retval=1 | |
2196 | fi | |
2197 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
2198 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
2199 | rm -f conftest.val | |
ba479fd2 | 2200 | |
5213506e RW |
2201 | fi |
2202 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
2203 | return $ac_retval | |
ba479fd2 | 2204 | |
5213506e | 2205 | } # ac_fn_c_compute_int |
ba479fd2 | 2206 | |
5213506e RW |
2207 | # ac_fn_c_check_type LINENO TYPE VAR INCLUDES |
2208 | # ------------------------------------------- | |
2209 | # Tests whether TYPE exists after having included INCLUDES, setting cache | |
2210 | # variable VAR accordingly. | |
2211 | ac_fn_c_check_type () | |
2212 | { | |
2213 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2214 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2215 | $as_echo_n "checking for $2... " >&6; } | |
2216 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
2217 | $as_echo_n "(cached) " >&6 | |
2218 | else | |
2219 | eval "$3=no" | |
2220 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2221 | /* end confdefs.h. */ | |
2222 | $4 | |
2223 | int | |
2224 | main () | |
2225 | { | |
2226 | if (sizeof ($2)) | |
2227 | return 0; | |
2228 | ; | |
2229 | return 0; | |
2230 | } | |
2231 | _ACEOF | |
2232 | if ac_fn_c_try_compile "$LINENO"; then : | |
2233 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2234 | /* end confdefs.h. */ | |
2235 | $4 | |
2236 | int | |
2237 | main () | |
2238 | { | |
2239 | if (sizeof (($2))) | |
2240 | return 0; | |
2241 | ; | |
2242 | return 0; | |
2243 | } | |
2244 | _ACEOF | |
2245 | if ac_fn_c_try_compile "$LINENO"; then : | |
ba479fd2 | 2246 | |
5213506e RW |
2247 | else |
2248 | eval "$3=yes" | |
2249 | fi | |
2250 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2251 | fi | |
2252 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2253 | fi | |
2254 | eval ac_res=\$$3 | |
2255 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2256 | $as_echo "$ac_res" >&6; } | |
2257 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
ba479fd2 | 2258 | |
5213506e | 2259 | } # ac_fn_c_check_type |
ba479fd2 | 2260 | |
fa802374 KT |
2261 | # ac_fn_c_find_intX_t LINENO BITS VAR |
2262 | # ----------------------------------- | |
2263 | # Finds a signed integer type with width BITS, setting cache variable VAR | |
2264 | # accordingly. | |
2265 | ac_fn_c_find_intX_t () | |
5213506e RW |
2266 | { |
2267 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
fa802374 KT |
2268 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int$2_t" >&5 |
2269 | $as_echo_n "checking for int$2_t... " >&6; } | |
5213506e RW |
2270 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : |
2271 | $as_echo_n "(cached) " >&6 | |
2272 | else | |
fa802374 KT |
2273 | eval "$3=no" |
2274 | for ac_type in int$2_t 'int' 'long int' \ | |
2275 | 'long long int' 'short int' 'signed char'; do | |
2276 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2277 | /* end confdefs.h. */ | |
2278 | $ac_includes_default | |
2279 | int | |
2280 | main () | |
2281 | { | |
2282 | static int test_array [1 - 2 * !(0 < ($ac_type) (((($ac_type) 1 << ($2 - 2)) - 1) * 2 + 1))]; | |
2283 | test_array [0] = 0 | |
2284 | ||
2285 | ; | |
2286 | return 0; | |
2287 | } | |
2288 | _ACEOF | |
2289 | if ac_fn_c_try_compile "$LINENO"; then : | |
5213506e RW |
2290 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
2291 | /* end confdefs.h. */ | |
fa802374 KT |
2292 | $ac_includes_default |
2293 | int | |
2294 | main () | |
2295 | { | |
2296 | static int test_array [1 - 2 * !(($ac_type) (((($ac_type) 1 << ($2 - 2)) - 1) * 2 + 1) | |
2297 | < ($ac_type) (((($ac_type) 1 << ($2 - 2)) - 1) * 2 + 2))]; | |
2298 | test_array [0] = 0 | |
2299 | ||
2300 | ; | |
2301 | return 0; | |
2302 | } | |
5213506e | 2303 | _ACEOF |
fa802374 KT |
2304 | if ac_fn_c_try_compile "$LINENO"; then : |
2305 | ||
5213506e | 2306 | else |
fa802374 KT |
2307 | case $ac_type in #( |
2308 | int$2_t) : | |
2309 | eval "$3=yes" ;; #( | |
2310 | *) : | |
2311 | eval "$3=\$ac_type" ;; | |
2312 | esac | |
5213506e | 2313 | fi |
fa802374 KT |
2314 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
2315 | fi | |
2316 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2317 | eval as_val=\$$3 | |
2318 | if test "x$as_val" = x""no; then : | |
2319 | ||
2320 | else | |
2321 | break | |
2322 | fi | |
2323 | done | |
5213506e RW |
2324 | fi |
2325 | eval ac_res=\$$3 | |
2326 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2327 | $as_echo "$ac_res" >&6; } | |
2328 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
ba479fd2 | 2329 | |
fa802374 | 2330 | } # ac_fn_c_find_intX_t |
18c04407 | 2331 | |
5213506e RW |
2332 | # ac_fn_c_try_link LINENO |
2333 | # ----------------------- | |
2334 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
2335 | ac_fn_c_try_link () | |
2336 | { | |
2337 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2338 | rm -f conftest.$ac_objext conftest$ac_exeext | |
2339 | if { { ac_try="$ac_link" | |
2340 | case "(($ac_try" in | |
2341 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2342 | *) ac_try_echo=$ac_try;; | |
2343 | esac | |
2344 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2345 | $as_echo "$ac_try_echo"; } >&5 | |
2346 | (eval "$ac_link") 2>conftest.err | |
2347 | ac_status=$? | |
2348 | if test -s conftest.err; then | |
2349 | grep -v '^ *+' conftest.err >conftest.er1 | |
2350 | cat conftest.er1 >&5 | |
2351 | mv -f conftest.er1 conftest.err | |
2352 | fi | |
2353 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2354 | test $ac_status = 0; } && { | |
2355 | test -z "$ac_c_werror_flag" || | |
2356 | test ! -s conftest.err | |
2357 | } && test -s conftest$ac_exeext && { | |
2358 | test "$cross_compiling" = yes || | |
2359 | $as_test_x conftest$ac_exeext | |
2360 | }; then : | |
2361 | ac_retval=0 | |
2362 | else | |
2363 | $as_echo "$as_me: failed program was:" >&5 | |
2364 | sed 's/^/| /' conftest.$ac_ext >&5 | |
18c04407 | 2365 | |
5213506e RW |
2366 | ac_retval=1 |
2367 | fi | |
2368 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information | |
2369 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
2370 | # interfere with the next link command; also delete a directory that is | |
2371 | # left behind by Apple's compiler. We do this before executing the actions. | |
2372 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
2373 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
2374 | return $ac_retval | |
18c04407 | 2375 | |
5213506e | 2376 | } # ac_fn_c_try_link |
ba479fd2 | 2377 | |
fa802374 KT |
2378 | # ac_fn_c_find_uintX_t LINENO BITS VAR |
2379 | # ------------------------------------ | |
2380 | # Finds an unsigned integer type with width BITS, setting cache variable VAR | |
2381 | # accordingly. | |
2382 | ac_fn_c_find_uintX_t () | |
2383 | { | |
2384 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2385 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uint$2_t" >&5 | |
2386 | $as_echo_n "checking for uint$2_t... " >&6; } | |
2387 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
2388 | $as_echo_n "(cached) " >&6 | |
2389 | else | |
2390 | eval "$3=no" | |
2391 | for ac_type in uint$2_t 'unsigned int' 'unsigned long int' \ | |
2392 | 'unsigned long long int' 'unsigned short int' 'unsigned char'; do | |
2393 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2394 | /* end confdefs.h. */ | |
2395 | $ac_includes_default | |
2396 | int | |
2397 | main () | |
2398 | { | |
2399 | static int test_array [1 - 2 * !(($ac_type) -1 >> ($2 - 1) == 1)]; | |
2400 | test_array [0] = 0 | |
2401 | ||
2402 | ; | |
2403 | return 0; | |
2404 | } | |
2405 | _ACEOF | |
2406 | if ac_fn_c_try_compile "$LINENO"; then : | |
2407 | case $ac_type in #( | |
2408 | uint$2_t) : | |
2409 | eval "$3=yes" ;; #( | |
2410 | *) : | |
2411 | eval "$3=\$ac_type" ;; | |
2412 | esac | |
2413 | fi | |
2414 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
2415 | eval as_val=\$$3 | |
2416 | if test "x$as_val" = x""no; then : | |
2417 | ||
2418 | else | |
2419 | break | |
2420 | fi | |
2421 | done | |
2422 | fi | |
2423 | eval ac_res=\$$3 | |
2424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2425 | $as_echo "$ac_res" >&6; } | |
2426 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
2427 | ||
2428 | } # ac_fn_c_find_uintX_t | |
2429 | ||
2430 | # ac_fn_c_check_header_preproc LINENO HEADER VAR | |
2431 | # ---------------------------------------------- | |
2432 | # Tests whether HEADER is present, setting the cache variable VAR accordingly. | |
2433 | ac_fn_c_check_header_preproc () | |
2434 | { | |
2435 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2436 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2437 | $as_echo_n "checking for $2... " >&6; } | |
2438 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
2439 | $as_echo_n "(cached) " >&6 | |
2440 | else | |
2441 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2442 | /* end confdefs.h. */ | |
2443 | #include <$2> | |
2444 | _ACEOF | |
2445 | if ac_fn_c_try_cpp "$LINENO"; then : | |
2446 | eval "$3=yes" | |
2447 | else | |
2448 | eval "$3=no" | |
2449 | fi | |
2450 | rm -f conftest.err conftest.$ac_ext | |
2451 | fi | |
2452 | eval ac_res=\$$3 | |
2453 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2454 | $as_echo "$ac_res" >&6; } | |
2455 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
2456 | ||
2457 | } # ac_fn_c_check_header_preproc | |
2458 | ||
5213506e RW |
2459 | # ac_fn_c_check_func LINENO FUNC VAR |
2460 | # ---------------------------------- | |
2461 | # Tests whether FUNC exists, setting the cache variable VAR accordingly | |
2462 | ac_fn_c_check_func () | |
2463 | { | |
2464 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2465 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 | |
2466 | $as_echo_n "checking for $2... " >&6; } | |
2467 | if { as_var=$3; eval "test \"\${$as_var+set}\" = set"; }; then : | |
2468 | $as_echo_n "(cached) " >&6 | |
2469 | else | |
2470 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
2471 | /* end confdefs.h. */ | |
2472 | /* Define $2 to an innocuous variant, in case <limits.h> declares $2. | |
2473 | For example, HP-UX 11i <limits.h> declares gettimeofday. */ | |
2474 | #define $2 innocuous_$2 | |
ba479fd2 | 2475 | |
5213506e RW |
2476 | /* System header to define __stub macros and hopefully few prototypes, |
2477 | which can conflict with char $2 (); below. | |
2478 | Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
2479 | <limits.h> exists even on freestanding compilers. */ | |
914c5af7 | 2480 | |
5213506e RW |
2481 | #ifdef __STDC__ |
2482 | # include <limits.h> | |
2483 | #else | |
2484 | # include <assert.h> | |
2485 | #endif | |
ba479fd2 | 2486 | |
5213506e | 2487 | #undef $2 |
ba479fd2 | 2488 | |
5213506e RW |
2489 | /* Override any GCC internal prototype to avoid an error. |
2490 | Use char because int might match the return type of a GCC | |
2491 | builtin and then its argument prototype would still apply. */ | |
2492 | #ifdef __cplusplus | |
2493 | extern "C" | |
2494 | #endif | |
2495 | char $2 (); | |
2496 | /* The GNU C library defines this for functions which it implements | |
2497 | to always fail with ENOSYS. Some functions are actually named | |
2498 | something starting with __ and the normal name is an alias. */ | |
2499 | #if defined __stub_$2 || defined __stub___$2 | |
2500 | choke me | |
2501 | #endif | |
9f18db39 | 2502 | |
5213506e RW |
2503 | int |
2504 | main () | |
2505 | { | |
2506 | return $2 (); | |
2507 | ; | |
2508 | return 0; | |
2509 | } | |
2510 | _ACEOF | |
2511 | if ac_fn_c_try_link "$LINENO"; then : | |
2512 | eval "$3=yes" | |
2513 | else | |
2514 | eval "$3=no" | |
ba479fd2 | 2515 | fi |
5213506e RW |
2516 | rm -f core conftest.err conftest.$ac_objext \ |
2517 | conftest$ac_exeext conftest.$ac_ext | |
2518 | fi | |
2519 | eval ac_res=\$$3 | |
2520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
2521 | $as_echo "$ac_res" >&6; } | |
2522 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
b61ff9c8 | 2523 | |
5213506e | 2524 | } # ac_fn_c_check_func |
b61ff9c8 | 2525 | |
5213506e RW |
2526 | # ac_fn_cxx_try_cpp LINENO |
2527 | # ------------------------ | |
2528 | # Try to preprocess conftest.$ac_ext, and return whether this succeeded. | |
2529 | ac_fn_cxx_try_cpp () | |
2530 | { | |
2531 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2532 | if { { ac_try="$ac_cpp conftest.$ac_ext" | |
2533 | case "(($ac_try" in | |
2534 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2535 | *) ac_try_echo=$ac_try;; | |
2536 | esac | |
2537 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2538 | $as_echo "$ac_try_echo"; } >&5 | |
2539 | (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err | |
2540 | ac_status=$? | |
2541 | if test -s conftest.err; then | |
2542 | grep -v '^ *+' conftest.err >conftest.er1 | |
2543 | cat conftest.er1 >&5 | |
2544 | mv -f conftest.er1 conftest.err | |
2545 | fi | |
2546 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2547 | test $ac_status = 0; } >/dev/null && { | |
2548 | test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || | |
2549 | test ! -s conftest.err | |
2550 | }; then : | |
2551 | ac_retval=0 | |
2552 | else | |
2553 | $as_echo "$as_me: failed program was:" >&5 | |
2554 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 2555 | |
5213506e | 2556 | ac_retval=1 |
ba479fd2 | 2557 | fi |
5213506e RW |
2558 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} |
2559 | return $ac_retval | |
b61ff9c8 | 2560 | |
5213506e | 2561 | } # ac_fn_cxx_try_cpp |
b61ff9c8 | 2562 | |
5213506e RW |
2563 | # ac_fn_cxx_try_link LINENO |
2564 | # ------------------------- | |
2565 | # Try to link conftest.$ac_ext, and return whether this succeeded. | |
2566 | ac_fn_cxx_try_link () | |
2567 | { | |
2568 | as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
2569 | rm -f conftest.$ac_objext conftest$ac_exeext | |
2570 | if { { ac_try="$ac_link" | |
2571 | case "(($ac_try" in | |
2572 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
2573 | *) ac_try_echo=$ac_try;; | |
2574 | esac | |
2575 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
2576 | $as_echo "$ac_try_echo"; } >&5 | |
2577 | (eval "$ac_link") 2>conftest.err | |
2578 | ac_status=$? | |
2579 | if test -s conftest.err; then | |
2580 | grep -v '^ *+' conftest.err >conftest.er1 | |
2581 | cat conftest.er1 >&5 | |
2582 | mv -f conftest.er1 conftest.err | |
2583 | fi | |
2584 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
2585 | test $ac_status = 0; } && { | |
2586 | test -z "$ac_cxx_werror_flag" || | |
2587 | test ! -s conftest.err | |
2588 | } && test -s conftest$ac_exeext && { | |
2589 | test "$cross_compiling" = yes || | |
2590 | $as_test_x conftest$ac_exeext | |
2591 | }; then : | |
2592 | ac_retval=0 | |
2593 | else | |
2594 | $as_echo "$as_me: failed program was:" >&5 | |
2595 | sed 's/^/| /' conftest.$ac_ext >&5 | |
ba479fd2 | 2596 | |
5213506e | 2597 | ac_retval=1 |
ba479fd2 | 2598 | fi |
5213506e RW |
2599 | # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information |
2600 | # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would | |
2601 | # interfere with the next link command; also delete a directory that is | |
2602 | # left behind by Apple's compiler. We do this before executing the actions. | |
2603 | rm -rf conftest.dSYM conftest_ipa8_conftest.oo | |
2604 | eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} | |
2605 | return $ac_retval | |
ba479fd2 | 2606 | |
5213506e RW |
2607 | } # ac_fn_cxx_try_link |
2608 | cat >config.log <<_ACEOF | |
2609 | This file contains any messages produced by compilers while | |
2610 | running configure, to aid debugging if configure makes a mistake. | |
ba479fd2 | 2611 | |
5213506e RW |
2612 | It was created by $as_me, which was |
2613 | generated by GNU Autoconf 2.64. Invocation command line was | |
ba479fd2 | 2614 | |
5213506e | 2615 | $ $0 $@ |
18fc9bd4 | 2616 | |
5213506e RW |
2617 | _ACEOF |
2618 | exec 5>>config.log | |
2619 | { | |
2620 | cat <<_ASUNAME | |
2621 | ## --------- ## | |
2622 | ## Platform. ## | |
2623 | ## --------- ## | |
18fc9bd4 | 2624 | |
5213506e RW |
2625 | hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` |
2626 | uname -m = `(uname -m) 2>/dev/null || echo unknown` | |
2627 | uname -r = `(uname -r) 2>/dev/null || echo unknown` | |
2628 | uname -s = `(uname -s) 2>/dev/null || echo unknown` | |
2629 | uname -v = `(uname -v) 2>/dev/null || echo unknown` | |
18fc9bd4 | 2630 | |
5213506e RW |
2631 | /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` |
2632 | /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` | |
18fc9bd4 | 2633 | |
5213506e RW |
2634 | /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` |
2635 | /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` | |
2636 | /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` | |
2637 | /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` | |
2638 | /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` | |
2639 | /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` | |
2640 | /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` | |
18fc9bd4 | 2641 | |
5213506e | 2642 | _ASUNAME |
8f1529e6 | 2643 | |
5213506e RW |
2644 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
2645 | for as_dir in $PATH | |
2646 | do | |
2647 | IFS=$as_save_IFS | |
2648 | test -z "$as_dir" && as_dir=. | |
2649 | $as_echo "PATH: $as_dir" | |
2650 | done | |
2651 | IFS=$as_save_IFS | |
57255173 | 2652 | |
5213506e | 2653 | } >&5 |
57255173 | 2654 | |
5213506e | 2655 | cat >&5 <<_ACEOF |
1546bb64 | 2656 | |
18fc9bd4 | 2657 | |
5213506e RW |
2658 | ## ----------- ## |
2659 | ## Core tests. ## | |
2660 | ## ----------- ## | |
73458fb7 | 2661 | |
ba479fd2 | 2662 | _ACEOF |
13c22933 JJ |
2663 | |
2664 | ||
5213506e RW |
2665 | # Keep a trace of the command line. |
2666 | # Strip out --no-create and --no-recursion so they do not pile up. | |
2667 | # Strip out --silent because we don't want to record it for future runs. | |
2668 | # Also quote any args containing shell meta-characters. | |
2669 | # Make two passes to allow for proper duplicate-argument suppression. | |
2670 | ac_configure_args= | |
2671 | ac_configure_args0= | |
2672 | ac_configure_args1= | |
2673 | ac_must_keep_next=false | |
2674 | for ac_pass in 1 2 | |
00020c16 | 2675 | do |
5213506e RW |
2676 | for ac_arg |
2677 | do | |
2678 | case $ac_arg in | |
2679 | -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; | |
2680 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ | |
2681 | | -silent | --silent | --silen | --sile | --sil) | |
2682 | continue ;; | |
2683 | *\'*) | |
2684 | ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2685 | esac | |
2686 | case $ac_pass in | |
2687 | 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; | |
2688 | 2) | |
2689 | as_fn_append ac_configure_args1 " '$ac_arg'" | |
2690 | if test $ac_must_keep_next = true; then | |
2691 | ac_must_keep_next=false # Got value, back to normal. | |
2692 | else | |
2693 | case $ac_arg in | |
2694 | *=* | --config-cache | -C | -disable-* | --disable-* \ | |
2695 | | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ | |
2696 | | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ | |
2697 | | -with-* | --with-* | -without-* | --without-* | --x) | |
2698 | case "$ac_configure_args0 " in | |
2699 | "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; | |
2700 | esac | |
2701 | ;; | |
2702 | -* ) ac_must_keep_next=true ;; | |
2703 | esac | |
2704 | fi | |
2705 | as_fn_append ac_configure_args " '$ac_arg'" | |
2706 | ;; | |
2707 | esac | |
2708 | done | |
00020c16 | 2709 | done |
5213506e RW |
2710 | { ac_configure_args0=; unset ac_configure_args0;} |
2711 | { ac_configure_args1=; unset ac_configure_args1;} | |
60d26958 | 2712 | |
5213506e RW |
2713 | # When interrupted or exit'd, cleanup temporary files, and complete |
2714 | # config.log. We remove comments because anyway the quotes in there | |
2715 | # would cause problems or look ugly. | |
2716 | # WARNING: Use '\'' to represent an apostrophe within the trap. | |
2717 | # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. | |
2718 | trap 'exit_status=$? | |
2719 | # Save into config.log some information that might help in debugging. | |
2720 | { | |
2721 | echo | |
1a4b763e | 2722 | |
5213506e RW |
2723 | cat <<\_ASBOX |
2724 | ## ---------------- ## | |
2725 | ## Cache variables. ## | |
2726 | ## ---------------- ## | |
2727 | _ASBOX | |
2728 | echo | |
2729 | # The following way of writing the cache mishandles newlines in values, | |
2730 | ( | |
2731 | for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do | |
2732 | eval ac_val=\$$ac_var | |
2733 | case $ac_val in #( | |
2734 | *${as_nl}*) | |
2735 | case $ac_var in #( | |
2736 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
2737 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
2738 | esac | |
2739 | case $ac_var in #( | |
2740 | _ | IFS | as_nl) ;; #( | |
2741 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
2742 | *) { eval $ac_var=; unset $ac_var;} ;; | |
2743 | esac ;; | |
2744 | esac | |
2745 | done | |
2746 | (set) 2>&1 | | |
2747 | case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( | |
2748 | *${as_nl}ac_space=\ *) | |
2749 | sed -n \ | |
2750 | "s/'\''/'\''\\\\'\'''\''/g; | |
2751 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" | |
2752 | ;; #( | |
2753 | *) | |
2754 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" | |
2755 | ;; | |
2756 | esac | | |
2757 | sort | |
2758 | ) | |
2759 | echo | |
1a4b763e | 2760 | |
5213506e RW |
2761 | cat <<\_ASBOX |
2762 | ## ----------------- ## | |
2763 | ## Output variables. ## | |
2764 | ## ----------------- ## | |
2765 | _ASBOX | |
2766 | echo | |
2767 | for ac_var in $ac_subst_vars | |
2768 | do | |
2769 | eval ac_val=\$$ac_var | |
2770 | case $ac_val in | |
2771 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2772 | esac | |
2773 | $as_echo "$ac_var='\''$ac_val'\''" | |
2774 | done | sort | |
2775 | echo | |
60d26958 | 2776 | |
5213506e RW |
2777 | if test -n "$ac_subst_files"; then |
2778 | cat <<\_ASBOX | |
2779 | ## ------------------- ## | |
2780 | ## File substitutions. ## | |
2781 | ## ------------------- ## | |
2782 | _ASBOX | |
2783 | echo | |
2784 | for ac_var in $ac_subst_files | |
2785 | do | |
2786 | eval ac_val=\$$ac_var | |
2787 | case $ac_val in | |
2788 | *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; | |
2789 | esac | |
2790 | $as_echo "$ac_var='\''$ac_val'\''" | |
2791 | done | sort | |
2792 | echo | |
2793 | fi | |
60d26958 | 2794 | |
5213506e RW |
2795 | if test -s confdefs.h; then |
2796 | cat <<\_ASBOX | |
2797 | ## ----------- ## | |
2798 | ## confdefs.h. ## | |
2799 | ## ----------- ## | |
2800 | _ASBOX | |
2801 | echo | |
2802 | cat confdefs.h | |
2803 | echo | |
2804 | fi | |
2805 | test "$ac_signal" != 0 && | |
2806 | $as_echo "$as_me: caught signal $ac_signal" | |
2807 | $as_echo "$as_me: exit $exit_status" | |
2808 | } >&5 | |
2809 | rm -f core *.core core.conftest.* && | |
2810 | rm -f -r conftest* confdefs* conf$$* $ac_clean_files && | |
2811 | exit $exit_status | |
2812 | ' 0 | |
2813 | for ac_signal in 1 2 13 15; do | |
2814 | trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal | |
00020c16 | 2815 | done |
5213506e | 2816 | ac_signal=0 |
00020c16 | 2817 | |
5213506e RW |
2818 | # confdefs.h avoids OS command line length limits that DEFS can exceed. |
2819 | rm -f -r conftest* confdefs.h | |
00020c16 | 2820 | |
5213506e RW |
2821 | $as_echo "/* confdefs.h */" > confdefs.h |
2822 | ||
2823 | # Predefined preprocessor variables. | |
2824 | ||
2825 | cat >>confdefs.h <<_ACEOF | |
2826 | #define PACKAGE_NAME "$PACKAGE_NAME" | |
60d26958 | 2827 | _ACEOF |
60d26958 | 2828 | |
5213506e RW |
2829 | cat >>confdefs.h <<_ACEOF |
2830 | #define PACKAGE_TARNAME "$PACKAGE_TARNAME" | |
2831 | _ACEOF | |
60d26958 | 2832 | |
5213506e RW |
2833 | cat >>confdefs.h <<_ACEOF |
2834 | #define PACKAGE_VERSION "$PACKAGE_VERSION" | |
60d26958 | 2835 | _ACEOF |
5213506e RW |
2836 | |
2837 | cat >>confdefs.h <<_ACEOF | |
2838 | #define PACKAGE_STRING "$PACKAGE_STRING" | |
60d26958 | 2839 | _ACEOF |
60d26958 | 2840 | |
5213506e RW |
2841 | cat >>confdefs.h <<_ACEOF |
2842 | #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" | |
2843 | _ACEOF | |
60d26958 | 2844 | |
5213506e RW |
2845 | cat >>confdefs.h <<_ACEOF |
2846 | #define PACKAGE_URL "$PACKAGE_URL" | |
2847 | _ACEOF | |
00020c16 | 2848 | |
60d26958 | 2849 | |
5213506e RW |
2850 | # Let the site file select an alternate cache file if it wants to. |
2851 | # Prefer an explicitly selected file to automatically selected ones. | |
2852 | ac_site_file1=NONE | |
2853 | ac_site_file2=NONE | |
2854 | if test -n "$CONFIG_SITE"; then | |
2855 | ac_site_file1=$CONFIG_SITE | |
2856 | elif test "x$prefix" != xNONE; then | |
2857 | ac_site_file1=$prefix/share/config.site | |
2858 | ac_site_file2=$prefix/etc/config.site | |
2859 | else | |
2860 | ac_site_file1=$ac_default_prefix/share/config.site | |
2861 | ac_site_file2=$ac_default_prefix/etc/config.site | |
2862 | fi | |
2863 | for ac_site_file in "$ac_site_file1" "$ac_site_file2" | |
00020c16 | 2864 | do |
5213506e RW |
2865 | test "x$ac_site_file" = xNONE && continue |
2866 | if test -r "$ac_site_file"; then | |
2867 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 | |
2868 | $as_echo "$as_me: loading site script $ac_site_file" >&6;} | |
2869 | sed 's/^/| /' "$ac_site_file" >&5 | |
2870 | . "$ac_site_file" | |
60d26958 | 2871 | fi |
5213506e | 2872 | done |
60d26958 | 2873 | |
5213506e RW |
2874 | if test -r "$cache_file"; then |
2875 | # Some versions of bash will fail to source /dev/null (special | |
2876 | # files actually), so we avoid doing that. | |
2877 | if test -f "$cache_file"; then | |
2878 | { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 | |
2879 | $as_echo "$as_me: loading cache $cache_file" >&6;} | |
2880 | case $cache_file in | |
2881 | [\\/]* | ?:[\\/]* ) . "$cache_file";; | |
2882 | *) . "./$cache_file";; | |
2883 | esac | |
60d26958 PB |
2884 | fi |
2885 | else | |
5213506e RW |
2886 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 |
2887 | $as_echo "$as_me: creating cache $cache_file" >&6;} | |
2888 | >$cache_file | |
bf3b7cd3 JD |
2889 | fi |
2890 | ||
5213506e RW |
2891 | # Check that the precious variables saved in the cache have kept the same |
2892 | # value. | |
2893 | ac_cache_corrupted=false | |
2894 | for ac_var in $ac_precious_vars; do | |
2895 | eval ac_old_set=\$ac_cv_env_${ac_var}_set | |
2896 | eval ac_new_set=\$ac_env_${ac_var}_set | |
2897 | eval ac_old_val=\$ac_cv_env_${ac_var}_value | |
2898 | eval ac_new_val=\$ac_env_${ac_var}_value | |
2899 | case $ac_old_set,$ac_new_set in | |
2900 | set,) | |
2901 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 | |
2902 | $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} | |
2903 | ac_cache_corrupted=: ;; | |
2904 | ,set) | |
2905 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 | |
2906 | $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} | |
2907 | ac_cache_corrupted=: ;; | |
2908 | ,);; | |
2909 | *) | |
2910 | if test "x$ac_old_val" != "x$ac_new_val"; then | |
2911 | # differences in whitespace do not lead to failure. | |
2912 | ac_old_val_w=`echo x $ac_old_val` | |
2913 | ac_new_val_w=`echo x $ac_new_val` | |
2914 | if test "$ac_old_val_w" != "$ac_new_val_w"; then | |
2915 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 | |
2916 | $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} | |
2917 | ac_cache_corrupted=: | |
2918 | else | |
2919 | { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 | |
2920 | $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} | |
2921 | eval $ac_var=\$ac_old_val | |
2922 | fi | |
2923 | { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 | |
2924 | $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} | |
2925 | { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 | |
2926 | $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} | |
2927 | fi;; | |
2928 | esac | |
2929 | # Pass precious variables to config.status. | |
2930 | if test "$ac_new_set" = set; then | |
2931 | case $ac_new_val in | |
2932 | *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; | |
2933 | *) ac_arg=$ac_var=$ac_new_val ;; | |
2934 | esac | |
2935 | case " $ac_configure_args " in | |
2936 | *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. | |
2937 | *) as_fn_append ac_configure_args " '$ac_arg'" ;; | |
2938 | esac | |
2939 | fi | |
60d26958 | 2940 | done |
5213506e RW |
2941 | if $ac_cache_corrupted; then |
2942 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
2943 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
2944 | { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 | |
2945 | $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} | |
2946 | as_fn_error "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 | |
60d26958 | 2947 | fi |
5213506e RW |
2948 | ## -------------------- ## |
2949 | ## Main body of script. ## | |
2950 | ## -------------------- ## | |
60d26958 | 2951 | |
00020c16 ILT |
2952 | ac_ext=c |
2953 | ac_cpp='$CPP $CPPFLAGS' | |
2954 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
2955 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
2956 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
60d26958 | 2957 | |
00020c16 | 2958 | |
bf3b7cd3 | 2959 | |
bf3b7cd3 | 2960 | |
00020c16 | 2961 | |
bf3b7cd3 | 2962 | |
5213506e | 2963 | ac_config_headers="$ac_config_headers auto-host.h:config.in" |
bf3b7cd3 | 2964 | |
bf3b7cd3 | 2965 | |
5213506e | 2966 | gcc_version=`cat $srcdir/BASE-VER` |
bf3b7cd3 | 2967 | |
5213506e RW |
2968 | # Determine the host, build, and target systems |
2969 | ac_aux_dir= | |
2970 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do | |
2971 | for ac_t in install-sh install.sh shtool; do | |
2972 | if test -f "$ac_dir/$ac_t"; then | |
2973 | ac_aux_dir=$ac_dir | |
2974 | ac_install_sh="$ac_aux_dir/$ac_t -c" | |
2975 | break 2 | |
2976 | fi | |
2977 | done | |
2978 | done | |
2979 | if test -z "$ac_aux_dir"; then | |
2980 | as_fn_error "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 | |
00020c16 | 2981 | fi |
5213506e RW |
2982 | |
2983 | # These three variables are undocumented and unsupported, | |
2984 | # and are intended to be withdrawn in a future Autoconf release. | |
2985 | # They can cause serious problems if a builder's source tree is in a directory | |
2986 | # whose full name contains unusual characters. | |
2987 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | |
2988 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | |
2989 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | |
2990 | ||
2991 | ||
2992 | # Make sure we can run config.sub. | |
2993 | $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || | |
2994 | as_fn_error "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 | |
2995 | ||
2996 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 | |
2997 | $as_echo_n "checking build system type... " >&6; } | |
2998 | if test "${ac_cv_build+set}" = set; then : | |
2999 | $as_echo_n "(cached) " >&6 | |
3000 | else | |
3001 | ac_build_alias=$build_alias | |
3002 | test "x$ac_build_alias" = x && | |
3003 | ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` | |
3004 | test "x$ac_build_alias" = x && | |
3005 | as_fn_error "cannot guess build type; you must specify one" "$LINENO" 5 | |
3006 | ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || | |
3007 | as_fn_error "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 | |
3008 | ||
3009 | fi | |
3010 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 | |
3011 | $as_echo "$ac_cv_build" >&6; } | |
3012 | case $ac_cv_build in | |
3013 | *-*-*) ;; | |
3014 | *) as_fn_error "invalid value of canonical build" "$LINENO" 5;; | |
3015 | esac | |
3016 | build=$ac_cv_build | |
3017 | ac_save_IFS=$IFS; IFS='-' | |
3018 | set x $ac_cv_build | |
3019 | shift | |
3020 | build_cpu=$1 | |
3021 | build_vendor=$2 | |
3022 | shift; shift | |
3023 | # Remember, the first character of IFS is used to create $*, | |
3024 | # except with old shells: | |
3025 | build_os=$* | |
3026 | IFS=$ac_save_IFS | |
3027 | case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac | |
3028 | ||
3029 | ||
3030 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 | |
3031 | $as_echo_n "checking host system type... " >&6; } | |
3032 | if test "${ac_cv_host+set}" = set; then : | |
3033 | $as_echo_n "(cached) " >&6 | |
3034 | else | |
3035 | if test "x$host_alias" = x; then | |
3036 | ac_cv_host=$ac_cv_build | |
3037 | else | |
3038 | ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || | |
3039 | as_fn_error "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 | |
00020c16 | 3040 | fi |
5213506e | 3041 | |
00020c16 | 3042 | fi |
5213506e RW |
3043 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 |
3044 | $as_echo "$ac_cv_host" >&6; } | |
3045 | case $ac_cv_host in | |
3046 | *-*-*) ;; | |
3047 | *) as_fn_error "invalid value of canonical host" "$LINENO" 5;; | |
3048 | esac | |
3049 | host=$ac_cv_host | |
3050 | ac_save_IFS=$IFS; IFS='-' | |
3051 | set x $ac_cv_host | |
3052 | shift | |
3053 | host_cpu=$1 | |
3054 | host_vendor=$2 | |
3055 | shift; shift | |
3056 | # Remember, the first character of IFS is used to create $*, | |
3057 | # except with old shells: | |
3058 | host_os=$* | |
3059 | IFS=$ac_save_IFS | |
3060 | case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac | |
00020c16 | 3061 | |
bf3b7cd3 | 3062 | |
5213506e RW |
3063 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 |
3064 | $as_echo_n "checking target system type... " >&6; } | |
3065 | if test "${ac_cv_target+set}" = set; then : | |
3066 | $as_echo_n "(cached) " >&6 | |
3067 | else | |
3068 | if test "x$target_alias" = x; then | |
3069 | ac_cv_target=$ac_cv_host | |
3070 | else | |
3071 | ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || | |
3072 | as_fn_error "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 | |
bf3b7cd3 JD |
3073 | fi |
3074 | ||
5213506e RW |
3075 | fi |
3076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 | |
3077 | $as_echo "$ac_cv_target" >&6; } | |
3078 | case $ac_cv_target in | |
3079 | *-*-*) ;; | |
3080 | *) as_fn_error "invalid value of canonical target" "$LINENO" 5;; | |
3081 | esac | |
3082 | target=$ac_cv_target | |
3083 | ac_save_IFS=$IFS; IFS='-' | |
3084 | set x $ac_cv_target | |
3085 | shift | |
3086 | target_cpu=$1 | |
3087 | target_vendor=$2 | |
3088 | shift; shift | |
3089 | # Remember, the first character of IFS is used to create $*, | |
3090 | # except with old shells: | |
3091 | target_os=$* | |
3092 | IFS=$ac_save_IFS | |
3093 | case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac | |
60d26958 | 3094 | |
bf3b7cd3 | 3095 | |
5213506e RW |
3096 | # The aliases save the names the user supplied, while $host etc. |
3097 | # will get canonicalized. | |
3098 | test -n "$target_alias" && | |
3099 | test "$program_prefix$program_suffix$program_transform_name" = \ | |
3100 | NONENONEs,x,x, && | |
3101 | program_prefix=${target_alias}- | |
bf3b7cd3 | 3102 | |
5213506e RW |
3103 | # Determine the noncanonical target name, for directory use. |
3104 | case ${build_alias} in | |
3105 | "") build_noncanonical=${build} ;; | |
3106 | *) build_noncanonical=${build_alias} ;; | |
3107 | esac | |
00020c16 | 3108 | |
5213506e RW |
3109 | case ${host_alias} in |
3110 | "") host_noncanonical=${build_noncanonical} ;; | |
3111 | *) host_noncanonical=${host_alias} ;; | |
3112 | esac | |
00020c16 | 3113 | |
5213506e RW |
3114 | case ${target_alias} in |
3115 | "") target_noncanonical=${host_noncanonical} ;; | |
3116 | *) target_noncanonical=${target_alias} ;; | |
3117 | esac | |
00020c16 ILT |
3118 | |
3119 | ||
3120 | ||
3121 | ||
5213506e | 3122 | # Determine the target- and build-specific subdirectories |
00020c16 | 3123 | |
5213506e RW |
3124 | # post-stage1 host modules use a different CC_FOR_BUILD so, in order to |
3125 | # have matching libraries, they should use host libraries: Makefile.tpl | |
3126 | # arranges to pass --with-build-libsubdir=$(HOST_SUBDIR). | |
3127 | # However, they still use the build modules, because the corresponding | |
3128 | # host modules (e.g. bison) are only built for the host when bootstrap | |
3129 | # finishes. So: | |
3130 | # - build_subdir is where we find build modules, and never changes. | |
3131 | # - build_libsubdir is where we find build libraries, and can be overridden. | |
bf3b7cd3 | 3132 | |
5213506e RW |
3133 | # Prefix 'build-' so this never conflicts with target_subdir. |
3134 | build_subdir="build-${build_noncanonical}" | |
3135 | ||
3136 | # Check whether --with-build-libsubdir was given. | |
3137 | if test "${with_build_libsubdir+set}" = set; then : | |
3138 | withval=$with_build_libsubdir; build_libsubdir="$withval" | |
3139 | else | |
3140 | build_libsubdir="$build_subdir" | |
bf3b7cd3 | 3141 | fi |
bf3b7cd3 | 3142 | |
5213506e RW |
3143 | # --srcdir=. covers the toplevel, while "test -d" covers the subdirectories |
3144 | if ( test $srcdir = . && test -d gcc ) \ | |
3145 | || test -d $srcdir/../host-${host_noncanonical}; then | |
3146 | host_subdir="host-${host_noncanonical}" | |
3147 | else | |
3148 | host_subdir=. | |
00020c16 | 3149 | fi |
5213506e RW |
3150 | # No prefix. |
3151 | target_subdir=${target_noncanonical} | |
00020c16 | 3152 | |
00020c16 | 3153 | |
5213506e RW |
3154 | # Set program_transform_name |
3155 | test "$program_prefix" != NONE && | |
3156 | program_transform_name="s&^&$program_prefix&;$program_transform_name" | |
3157 | # Use a double $ so make ignores it. | |
3158 | test "$program_suffix" != NONE && | |
3159 | program_transform_name="s&\$&$program_suffix&;$program_transform_name" | |
3160 | # Double any \ or $. | |
3161 | # By default was `s,x,x', remove it if useless. | |
3162 | ac_script='s/[\\$]/&&/g;s/;s,x,x,$//' | |
3163 | program_transform_name=`$as_echo "$program_transform_name" | sed "$ac_script"` | |
00020c16 ILT |
3164 | |
3165 | ||
5213506e RW |
3166 | # Check for bogus environment variables. |
3167 | # Test if LIBRARY_PATH contains the notation for the current directory | |
3168 | # since this would lead to problems installing/building glibc. | |
3169 | # LIBRARY_PATH contains the current directory if one of the following | |
3170 | # is true: | |
3171 | # - one of the terminals (":" and ";") is the first or last sign | |
3172 | # - two terminals occur directly after each other | |
3173 | # - the path contains an element with a dot in it | |
3174 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking LIBRARY_PATH variable" >&5 | |
3175 | $as_echo_n "checking LIBRARY_PATH variable... " >&6; } | |
3176 | case ${LIBRARY_PATH} in | |
3177 | [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* ) | |
3178 | library_path_setting="contains current directory" | |
3179 | ;; | |
3180 | *) | |
3181 | library_path_setting="ok" | |
3182 | ;; | |
3183 | esac | |
3184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $library_path_setting" >&5 | |
3185 | $as_echo "$library_path_setting" >&6; } | |
3186 | if test "$library_path_setting" != "ok"; then | |
3187 | as_fn_error " | |
3188 | *** LIBRARY_PATH shouldn't contain the current directory when | |
3189 | *** building gcc. Please change the environment variable | |
3190 | *** and run configure again." "$LINENO" 5 | |
00020c16 | 3191 | fi |
00020c16 | 3192 | |
5213506e RW |
3193 | # Test if GCC_EXEC_PREFIX contains the notation for the current directory |
3194 | # since this would lead to problems installing/building glibc. | |
3195 | # GCC_EXEC_PREFIX contains the current directory if one of the following | |
3196 | # is true: | |
3197 | # - one of the terminals (":" and ";") is the first or last sign | |
3198 | # - two terminals occur directly after each other | |
3199 | # - the path contains an element with a dot in it | |
3200 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking GCC_EXEC_PREFIX variable" >&5 | |
3201 | $as_echo_n "checking GCC_EXEC_PREFIX variable... " >&6; } | |
3202 | case ${GCC_EXEC_PREFIX} in | |
3203 | [:\;]* | *[:\;] | *[:\;][:\;]* | *[:\;]. | .[:\;]*| . | *[:\;].[:\;]* ) | |
3204 | gcc_exec_prefix_setting="contains current directory" | |
3205 | ;; | |
3206 | *) | |
3207 | gcc_exec_prefix_setting="ok" | |
3208 | ;; | |
3209 | esac | |
3210 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_exec_prefix_setting" >&5 | |
3211 | $as_echo "$gcc_exec_prefix_setting" >&6; } | |
3212 | if test "$gcc_exec_prefix_setting" != "ok"; then | |
3213 | as_fn_error " | |
3214 | *** GCC_EXEC_PREFIX shouldn't contain the current directory when | |
3215 | *** building gcc. Please change the environment variable | |
3216 | *** and run configure again." "$LINENO" 5 | |
00020c16 | 3217 | fi |
00020c16 | 3218 | |
5213506e RW |
3219 | # ----------- |
3220 | # Directories | |
3221 | # ----------- | |
3222 | ||
3223 | # Specify the local prefix | |
3224 | local_prefix= | |
3225 | ||
3226 | # Check whether --with-local-prefix was given. | |
3227 | if test "${with_local_prefix+set}" = set; then : | |
3228 | withval=$with_local_prefix; case "${withval}" in | |
3229 | yes) as_fn_error "bad value ${withval} given for local include directory prefix" "$LINENO" 5 ;; | |
3230 | no) ;; | |
3231 | *) local_prefix=$with_local_prefix ;; | |
3232 | esac | |
00020c16 | 3233 | fi |
bf3b7cd3 | 3234 | |
5213506e RW |
3235 | |
3236 | # Default local prefix if it is empty | |
3237 | if test x$local_prefix = x; then | |
3238 | local_prefix=/usr/local | |
bf3b7cd3 | 3239 | fi |
00020c16 | 3240 | |
5213506e RW |
3241 | # Don't set gcc_gxx_include_dir to gxx_include_dir since that's only |
3242 | # passed in by the toplevel make and thus we'd get different behavior | |
3243 | # depending on where we built the sources. | |
3244 | gcc_gxx_include_dir= | |
3245 | # Specify the g++ header file directory | |
3246 | ||
3247 | # Check whether --with-gxx-include-dir was given. | |
3248 | if test "${with_gxx_include_dir+set}" = set; then : | |
3249 | withval=$with_gxx_include_dir; case "${withval}" in | |
3250 | yes) as_fn_error "bad value ${withval} given for g++ include directory" "$LINENO" 5 ;; | |
3251 | no) ;; | |
3252 | *) gcc_gxx_include_dir=$with_gxx_include_dir ;; | |
00020c16 | 3253 | esac |
00020c16 | 3254 | fi |
bf3b7cd3 | 3255 | |
5213506e RW |
3256 | |
3257 | # This logic must match libstdc++-v3/acinclude.m4:GLIBCXX_EXPORT_INSTALL_INFO. | |
3258 | if test x${gcc_gxx_include_dir} = x; then | |
3259 | if test x${enable_version_specific_runtime_libs} = xyes; then | |
3260 | gcc_gxx_include_dir='${libsubdir}/include/c++' | |
3261 | else | |
3262 | libstdcxx_incdir='include/c++/$(version)' | |
3263 | if test x$host != x$target; then | |
3264 | libstdcxx_incdir="$target_alias/$libstdcxx_incdir" | |
3265 | fi | |
3266 | gcc_gxx_include_dir="\$(libsubdir)/\$(libsubdir_to_prefix)$libstdcxx_incdir" | |
3267 | fi | |
00020c16 ILT |
3268 | fi |
3269 | ||
3270 | ||
5213506e RW |
3271 | # Check whether --with-cpp_install_dir was given. |
3272 | if test "${with_cpp_install_dir+set}" = set; then : | |
3273 | withval=$with_cpp_install_dir; if test x$withval = xyes; then | |
3274 | as_fn_error "option --with-cpp-install-dir requires an argument" "$LINENO" 5 | |
3275 | elif test x$withval != xno; then | |
3276 | cpp_install_dir=$withval | |
3277 | fi | |
3278 | fi | |
00020c16 | 3279 | |
00020c16 | 3280 | |
5213506e RW |
3281 | # We would like to our source tree to be readonly. However when releases or |
3282 | # pre-releases are generated, the flex/bison generated files as well as the | |
3283 | # various formats of manuals need to be included along with the rest of the | |
3284 | # sources. Therefore we have --enable-generated-files-in-srcdir to do | |
3285 | # just that. | |
00020c16 | 3286 | |
5213506e RW |
3287 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to place generated files in the source directory" >&5 |
3288 | $as_echo_n "checking whether to place generated files in the source directory... " >&6; } | |
3289 | # Check whether --enable-generated-files-in-srcdir was given. | |
3290 | if test "${enable_generated_files_in_srcdir+set}" = set; then : | |
3291 | enableval=$enable_generated_files_in_srcdir; generated_files_in_srcdir=$enableval | |
3292 | else | |
3293 | generated_files_in_srcdir=no | |
3294 | fi | |
00020c16 ILT |
3295 | |
3296 | ||
5213506e RW |
3297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $generated_files_in_srcdir" >&5 |
3298 | $as_echo "$generated_files_in_srcdir" >&6; } | |
00020c16 | 3299 | |
5213506e RW |
3300 | if test "$generated_files_in_srcdir" = "yes"; then |
3301 | GENINSRC='' | |
3302 | else | |
3303 | GENINSRC='#' | |
3304 | fi | |
00020c16 ILT |
3305 | |
3306 | ||
5213506e RW |
3307 | # ------------------- |
3308 | # Find default linker | |
3309 | # ------------------- | |
3310 | ||
3311 | # With GNU ld | |
00020c16 | 3312 | |
5213506e RW |
3313 | # Check whether --with-gnu-ld was given. |
3314 | if test "${with_gnu_ld+set}" = set; then : | |
3315 | withval=$with_gnu_ld; gnu_ld_flag="$with_gnu_ld" | |
00020c16 | 3316 | else |
5213506e RW |
3317 | gnu_ld_flag=no |
3318 | fi | |
00020c16 | 3319 | |
bf3b7cd3 | 3320 | |
5213506e | 3321 | # With pre-defined ld |
00020c16 | 3322 | |
5213506e RW |
3323 | # Check whether --with-ld was given. |
3324 | if test "${with_ld+set}" = set; then : | |
3325 | withval=$with_ld; DEFAULT_LINKER="$with_ld" | |
00020c16 | 3326 | fi |
00020c16 | 3327 | |
5213506e RW |
3328 | if test x"${DEFAULT_LINKER+set}" = x"set"; then |
3329 | if test ! -x "$DEFAULT_LINKER"; then | |
3330 | as_fn_error "cannot execute: $DEFAULT_LINKER: check --with-ld or env. var. DEFAULT_LINKER" "$LINENO" 5 | |
3331 | elif $DEFAULT_LINKER -v < /dev/null 2>&1 | grep GNU > /dev/null; then | |
3332 | gnu_ld_flag=yes | |
3333 | fi | |
3334 | ||
3335 | cat >>confdefs.h <<_ACEOF | |
3336 | #define DEFAULT_LINKER "$DEFAULT_LINKER" | |
00020c16 ILT |
3337 | _ACEOF |
3338 | ||
5213506e | 3339 | fi |
00020c16 | 3340 | |
5213506e | 3341 | gnu_ld=`if test x"$gnu_ld_flag" = x"yes"; then echo 1; else echo 0; fi` |
00020c16 | 3342 | |
5213506e RW |
3343 | cat >>confdefs.h <<_ACEOF |
3344 | #define HAVE_GNU_LD $gnu_ld | |
00020c16 ILT |
3345 | _ACEOF |
3346 | ||
3347 | ||
5213506e RW |
3348 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a default linker was specified" >&5 |
3349 | $as_echo_n "checking whether a default linker was specified... " >&6; } | |
3350 | if test x"${DEFAULT_LINKER+set}" = x"set"; then | |
3351 | if test x"$gnu_ld_flag" = x"no"; then | |
3352 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DEFAULT_LINKER)" >&5 | |
3353 | $as_echo "yes ($DEFAULT_LINKER)" >&6; } | |
00020c16 | 3354 | else |
5213506e RW |
3355 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DEFAULT_LINKER - GNU ld)" >&5 |
3356 | $as_echo "yes ($DEFAULT_LINKER - GNU ld)" >&6; } | |
00020c16 | 3357 | fi |
bf3b7cd3 | 3358 | else |
5213506e RW |
3359 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3360 | $as_echo "no" >&6; } | |
bf3b7cd3 | 3361 | fi |
bf3b7cd3 | 3362 | |
5213506e | 3363 | # With demangler in GNU ld |
00020c16 | 3364 | |
5213506e RW |
3365 | # Check whether --with-demangler-in-ld was given. |
3366 | if test "${with_demangler_in_ld+set}" = set; then : | |
3367 | withval=$with_demangler_in_ld; demangler_in_ld="$with_demangler_in_ld" | |
00020c16 | 3368 | else |
5213506e | 3369 | demangler_in_ld=no |
00020c16 | 3370 | fi |
bf3b7cd3 | 3371 | |
00020c16 | 3372 | |
5213506e RW |
3373 | # ---------------------- |
3374 | # Find default assembler | |
3375 | # ---------------------- | |
00020c16 | 3376 | |
5213506e | 3377 | # With GNU as |
00020c16 | 3378 | |
5213506e RW |
3379 | # Check whether --with-gnu-as was given. |
3380 | if test "${with_gnu_as+set}" = set; then : | |
3381 | withval=$with_gnu_as; gas_flag="$with_gnu_as" | |
00020c16 | 3382 | else |
5213506e | 3383 | gas_flag=no |
00020c16 | 3384 | fi |
00020c16 | 3385 | |
5213506e RW |
3386 | |
3387 | ||
3388 | # Check whether --with-as was given. | |
3389 | if test "${with_as+set}" = set; then : | |
3390 | withval=$with_as; DEFAULT_ASSEMBLER="$with_as" | |
00020c16 | 3391 | fi |
00020c16 | 3392 | |
5213506e RW |
3393 | if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then |
3394 | if test ! -x "$DEFAULT_ASSEMBLER"; then | |
3395 | as_fn_error "cannot execute: $DEFAULT_ASSEMBLER: check --with-as or env. var. DEFAULT_ASSEMBLER" "$LINENO" 5 | |
3396 | elif $DEFAULT_ASSEMBLER -v < /dev/null 2>&1 | grep GNU > /dev/null; then | |
3397 | gas_flag=yes | |
3398 | fi | |
3399 | ||
3400 | cat >>confdefs.h <<_ACEOF | |
3401 | #define DEFAULT_ASSEMBLER "$DEFAULT_ASSEMBLER" | |
00020c16 | 3402 | _ACEOF |
5213506e RW |
3403 | |
3404 | fi | |
3405 | ||
3406 | gnu_as=`if test x"$gas_flag" = x"yes"; then echo 1; else echo 0; fi` | |
3407 | ||
3408 | cat >>confdefs.h <<_ACEOF | |
3409 | #define HAVE_GNU_AS $gnu_as | |
00020c16 | 3410 | _ACEOF |
5213506e RW |
3411 | |
3412 | ||
3413 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a default assembler was specified" >&5 | |
3414 | $as_echo_n "checking whether a default assembler was specified... " >&6; } | |
3415 | if test x"${DEFAULT_ASSEMBLER+set}" = x"set"; then | |
3416 | if test x"$gas_flag" = x"no"; then | |
3417 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DEFAULT_ASSEMBLER)" >&5 | |
3418 | $as_echo "yes ($DEFAULT_ASSEMBLER)" >&6; } | |
00020c16 | 3419 | else |
5213506e RW |
3420 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes ($DEFAULT_ASSEMBLER - GNU as)" >&5 |
3421 | $as_echo "yes ($DEFAULT_ASSEMBLER - GNU as)" >&6; } | |
00020c16 | 3422 | fi |
bf3b7cd3 | 3423 | else |
5213506e RW |
3424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3425 | $as_echo "no" >&6; } | |
00020c16 | 3426 | fi |
bf3b7cd3 | 3427 | |
5213506e RW |
3428 | # --------------- |
3429 | # Find C compiler | |
3430 | # --------------- | |
00020c16 | 3431 | |
5213506e RW |
3432 | # If a non-executable a.out is present (e.g. created by GNU as above even if |
3433 | # invoked with -v only), the IRIX 6 native ld just overwrites the existing | |
3434 | # file, even when creating an executable, so an execution test fails. | |
3435 | # Remove possible default executable files to avoid this. | |
3436 | # | |
3437 | # FIXME: This really belongs into AC_PROG_CC and can be removed once | |
3438 | # Autoconf includes it. | |
3439 | rm -f a.out a.exe b.out | |
bf3b7cd3 | 3440 | |
5213506e | 3441 | # Find the native compiler |
00020c16 ILT |
3442 | ac_ext=c |
3443 | ac_cpp='$CPP $CPPFLAGS' | |
3444 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
3445 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
3446 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5213506e RW |
3447 | if test -n "$ac_tool_prefix"; then |
3448 | # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args. | |
3449 | set dummy ${ac_tool_prefix}gcc; ac_word=$2 | |
3450 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3451 | $as_echo_n "checking for $ac_word... " >&6; } | |
3452 | if test "${ac_cv_prog_CC+set}" = set; then : | |
3453 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3454 | else |
5213506e RW |
3455 | if test -n "$CC"; then |
3456 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3457 | else | |
3458 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3459 | for as_dir in $PATH | |
3460 | do | |
3461 | IFS=$as_save_IFS | |
3462 | test -z "$as_dir" && as_dir=. | |
3463 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3464 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3465 | ac_cv_prog_CC="${ac_tool_prefix}gcc" | |
3466 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3467 | break 2 | |
3468 | fi | |
3469 | done | |
3470 | done | |
3471 | IFS=$as_save_IFS | |
00020c16 | 3472 | |
5213506e RW |
3473 | fi |
3474 | fi | |
3475 | CC=$ac_cv_prog_CC | |
3476 | if test -n "$CC"; then | |
3477 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
3478 | $as_echo "$CC" >&6; } | |
bf3b7cd3 | 3479 | else |
5213506e RW |
3480 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3481 | $as_echo "no" >&6; } | |
3482 | fi | |
3483 | ||
bf3b7cd3 | 3484 | |
bf3b7cd3 | 3485 | fi |
5213506e RW |
3486 | if test -z "$ac_cv_prog_CC"; then |
3487 | ac_ct_CC=$CC | |
3488 | # Extract the first word of "gcc", so it can be a program name with args. | |
3489 | set dummy gcc; ac_word=$2 | |
3490 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3491 | $as_echo_n "checking for $ac_word... " >&6; } | |
3492 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : | |
3493 | $as_echo_n "(cached) " >&6 | |
3494 | else | |
3495 | if test -n "$ac_ct_CC"; then | |
3496 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3497 | else | |
3498 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3499 | for as_dir in $PATH | |
3500 | do | |
3501 | IFS=$as_save_IFS | |
3502 | test -z "$as_dir" && as_dir=. | |
3503 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3504 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3505 | ac_cv_prog_ac_ct_CC="gcc" | |
3506 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3507 | break 2 | |
3508 | fi | |
00020c16 | 3509 | done |
5213506e RW |
3510 | done |
3511 | IFS=$as_save_IFS | |
00020c16 | 3512 | |
bf3b7cd3 | 3513 | fi |
5213506e RW |
3514 | fi |
3515 | ac_ct_CC=$ac_cv_prog_ac_ct_CC | |
3516 | if test -n "$ac_ct_CC"; then | |
3517 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
3518 | $as_echo "$ac_ct_CC" >&6; } | |
3519 | else | |
3520 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3521 | $as_echo "no" >&6; } | |
3522 | fi | |
00020c16 | 3523 | |
5213506e RW |
3524 | if test "x$ac_ct_CC" = x; then |
3525 | CC="" | |
3526 | else | |
3527 | case $cross_compiling:$ac_tool_warned in | |
3528 | yes:) | |
3529 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3530 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3531 | ac_tool_warned=yes ;; | |
3532 | esac | |
3533 | CC=$ac_ct_CC | |
3534 | fi | |
3535 | else | |
3536 | CC="$ac_cv_prog_CC" | |
3537 | fi | |
00020c16 | 3538 | |
5213506e RW |
3539 | if test -z "$CC"; then |
3540 | if test -n "$ac_tool_prefix"; then | |
3541 | # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args. | |
3542 | set dummy ${ac_tool_prefix}cc; ac_word=$2 | |
3543 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3544 | $as_echo_n "checking for $ac_word... " >&6; } | |
3545 | if test "${ac_cv_prog_CC+set}" = set; then : | |
3546 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3547 | else |
5213506e RW |
3548 | if test -n "$CC"; then |
3549 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
00020c16 | 3550 | else |
5213506e RW |
3551 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
3552 | for as_dir in $PATH | |
3553 | do | |
3554 | IFS=$as_save_IFS | |
3555 | test -z "$as_dir" && as_dir=. | |
3556 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3557 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3558 | ac_cv_prog_CC="${ac_tool_prefix}cc" | |
3559 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3560 | break 2 | |
3561 | fi | |
3562 | done | |
3563 | done | |
3564 | IFS=$as_save_IFS | |
00020c16 | 3565 | |
00020c16 | 3566 | fi |
00020c16 | 3567 | fi |
5213506e RW |
3568 | CC=$ac_cv_prog_CC |
3569 | if test -n "$CC"; then | |
3570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
3571 | $as_echo "$CC" >&6; } | |
00020c16 | 3572 | else |
5213506e RW |
3573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3574 | $as_echo "no" >&6; } | |
3575 | fi | |
bf3b7cd3 | 3576 | |
bf3b7cd3 | 3577 | |
5213506e RW |
3578 | fi |
3579 | fi | |
3580 | if test -z "$CC"; then | |
3581 | # Extract the first word of "cc", so it can be a program name with args. | |
3582 | set dummy cc; ac_word=$2 | |
3583 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3584 | $as_echo_n "checking for $ac_word... " >&6; } | |
3585 | if test "${ac_cv_prog_CC+set}" = set; then : | |
3586 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3587 | else |
5213506e RW |
3588 | if test -n "$CC"; then |
3589 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3590 | else | |
3591 | ac_prog_rejected=no | |
3592 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3593 | for as_dir in $PATH | |
3594 | do | |
3595 | IFS=$as_save_IFS | |
3596 | test -z "$as_dir" && as_dir=. | |
3597 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3598 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3599 | if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then | |
3600 | ac_prog_rejected=yes | |
3601 | continue | |
3602 | fi | |
3603 | ac_cv_prog_CC="cc" | |
3604 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3605 | break 2 | |
3606 | fi | |
3607 | done | |
3608 | done | |
3609 | IFS=$as_save_IFS | |
bf3b7cd3 | 3610 | |
5213506e RW |
3611 | if test $ac_prog_rejected = yes; then |
3612 | # We found a bogon in the path, so make sure we never use it. | |
3613 | set dummy $ac_cv_prog_CC | |
3614 | shift | |
3615 | if test $# != 0; then | |
3616 | # We chose a different compiler from the bogus one. | |
3617 | # However, it has the same basename, so the bogon will be chosen | |
3618 | # first if we set CC to just the basename; use the full file name. | |
3619 | shift | |
3620 | ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@" | |
3621 | fi | |
bf3b7cd3 | 3622 | fi |
5213506e RW |
3623 | fi |
3624 | fi | |
3625 | CC=$ac_cv_prog_CC | |
3626 | if test -n "$CC"; then | |
3627 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
3628 | $as_echo "$CC" >&6; } | |
bf3b7cd3 | 3629 | else |
5213506e RW |
3630 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3631 | $as_echo "no" >&6; } | |
3632 | fi | |
bf3b7cd3 | 3633 | |
bf3b7cd3 | 3634 | |
5213506e RW |
3635 | fi |
3636 | if test -z "$CC"; then | |
3637 | if test -n "$ac_tool_prefix"; then | |
3638 | for ac_prog in cl.exe | |
3639 | do | |
3640 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
3641 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
3642 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3643 | $as_echo_n "checking for $ac_word... " >&6; } | |
3644 | if test "${ac_cv_prog_CC+set}" = set; then : | |
3645 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3646 | else |
5213506e RW |
3647 | if test -n "$CC"; then |
3648 | ac_cv_prog_CC="$CC" # Let the user override the test. | |
3649 | else | |
3650 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3651 | for as_dir in $PATH | |
3652 | do | |
3653 | IFS=$as_save_IFS | |
3654 | test -z "$as_dir" && as_dir=. | |
3655 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3656 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3657 | ac_cv_prog_CC="$ac_tool_prefix$ac_prog" | |
3658 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3659 | break 2 | |
3660 | fi | |
3661 | done | |
3662 | done | |
3663 | IFS=$as_save_IFS | |
bf3b7cd3 | 3664 | |
bf3b7cd3 | 3665 | fi |
5213506e RW |
3666 | fi |
3667 | CC=$ac_cv_prog_CC | |
3668 | if test -n "$CC"; then | |
3669 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 | |
3670 | $as_echo "$CC" >&6; } | |
3671 | else | |
3672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
3673 | $as_echo "no" >&6; } | |
3674 | fi | |
3675 | ||
3676 | ||
3677 | test -n "$CC" && break | |
bf3b7cd3 | 3678 | done |
5213506e RW |
3679 | fi |
3680 | if test -z "$CC"; then | |
3681 | ac_ct_CC=$CC | |
3682 | for ac_prog in cl.exe | |
3683 | do | |
3684 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
3685 | set dummy $ac_prog; ac_word=$2 | |
3686 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
3687 | $as_echo_n "checking for $ac_word... " >&6; } | |
3688 | if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : | |
3689 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3690 | else |
5213506e RW |
3691 | if test -n "$ac_ct_CC"; then |
3692 | ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. | |
3693 | else | |
3694 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
3695 | for as_dir in $PATH | |
3696 | do | |
3697 | IFS=$as_save_IFS | |
3698 | test -z "$as_dir" && as_dir=. | |
3699 | for ac_exec_ext in '' $ac_executable_extensions; do | |
3700 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
3701 | ac_cv_prog_ac_ct_CC="$ac_prog" | |
3702 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
3703 | break 2 | |
3704 | fi | |
3705 | done | |
3706 | done | |
3707 | IFS=$as_save_IFS | |
bf3b7cd3 | 3708 | |
bf3b7cd3 | 3709 | fi |
bf3b7cd3 | 3710 | fi |
5213506e RW |
3711 | ac_ct_CC=$ac_cv_prog_ac_ct_CC |
3712 | if test -n "$ac_ct_CC"; then | |
3713 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 | |
3714 | $as_echo "$ac_ct_CC" >&6; } | |
bf3b7cd3 | 3715 | else |
5213506e RW |
3716 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
3717 | $as_echo "no" >&6; } | |
3718 | fi | |
3719 | ||
3720 | ||
3721 | test -n "$ac_ct_CC" && break | |
3722 | done | |
3723 | ||
3724 | if test "x$ac_ct_CC" = x; then | |
3725 | CC="" | |
3726 | else | |
3727 | case $cross_compiling:$ac_tool_warned in | |
3728 | yes:) | |
3729 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
3730 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
3731 | ac_tool_warned=yes ;; | |
3732 | esac | |
3733 | CC=$ac_ct_CC | |
3734 | fi | |
3735 | fi | |
bf3b7cd3 | 3736 | |
bf3b7cd3 | 3737 | fi |
5213506e RW |
3738 | |
3739 | ||
3740 | test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3741 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3742 | as_fn_error "no acceptable C compiler found in \$PATH | |
3743 | See \`config.log' for more details." "$LINENO" 5; } | |
3744 | ||
3745 | # Provide some information about the compiler. | |
3746 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 | |
3747 | set X $ac_compile | |
3748 | ac_compiler=$2 | |
3749 | for ac_option in --version -v -V -qversion; do | |
3750 | { { ac_try="$ac_compiler $ac_option >&5" | |
3751 | case "(($ac_try" in | |
3752 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3753 | *) ac_try_echo=$ac_try;; | |
bf3b7cd3 | 3754 | esac |
5213506e RW |
3755 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" |
3756 | $as_echo "$ac_try_echo"; } >&5 | |
3757 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
3758 | ac_status=$? | |
3759 | if test -s conftest.err; then | |
3760 | sed '10a\ | |
3761 | ... rest of stderr output deleted ... | |
3762 | 10q' conftest.err >conftest.er1 | |
3763 | cat conftest.er1 >&5 | |
3764 | rm -f conftest.er1 conftest.err | |
3765 | fi | |
3766 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3767 | test $ac_status = 0; } | |
3768 | done | |
3769 | ||
3770 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 3771 | /* end confdefs.h. */ |
5213506e | 3772 | |
bf3b7cd3 JD |
3773 | int |
3774 | main () | |
3775 | { | |
3776 | ||
bf3b7cd3 JD |
3777 | ; |
3778 | return 0; | |
3779 | } | |
3780 | _ACEOF | |
5213506e RW |
3781 | ac_clean_files_save=$ac_clean_files |
3782 | ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out conftest.out" | |
3783 | # Try to create an executable without -o first, disregard a.out. | |
3784 | # It will help us diagnose broken compilers, and finding out an intuition | |
3785 | # of exeext. | |
3786 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 | |
3787 | $as_echo_n "checking for C compiler default output file name... " >&6; } | |
3788 | ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` | |
3789 | ||
3790 | # The possible output files: | |
3791 | ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" | |
3792 | ||
3793 | ac_rmfiles= | |
3794 | for ac_file in $ac_files | |
3795 | do | |
3796 | case $ac_file in | |
3797 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3798 | * ) ac_rmfiles="$ac_rmfiles $ac_file";; | |
3799 | esac | |
3800 | done | |
3801 | rm -f $ac_rmfiles | |
3802 | ||
3803 | if { { ac_try="$ac_link_default" | |
3804 | case "(($ac_try" in | |
3805 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3806 | *) ac_try_echo=$ac_try;; | |
3807 | esac | |
3808 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3809 | $as_echo "$ac_try_echo"; } >&5 | |
3810 | (eval "$ac_link_default") 2>&5 | |
3811 | ac_status=$? | |
3812 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3813 | test $ac_status = 0; }; then : | |
3814 | # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. | |
3815 | # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' | |
3816 | # in a Makefile. We should not override ac_cv_exeext if it was cached, | |
3817 | # so that the user can short-circuit this test for compilers unknown to | |
3818 | # Autoconf. | |
3819 | for ac_file in $ac_files '' | |
3820 | do | |
3821 | test -f "$ac_file" || continue | |
3822 | case $ac_file in | |
3823 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) | |
3824 | ;; | |
3825 | [ab].out ) | |
3826 | # We found the default executable, but exeext='' is most | |
3827 | # certainly right. | |
3828 | break;; | |
3829 | *.* ) | |
3830 | if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; | |
3831 | then :; else | |
3832 | ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3833 | fi | |
3834 | # We set ac_cv_exeext here because the later test for it is not | |
3835 | # safe: cross compilers may not add the suffix if given an `-o' | |
3836 | # argument, so we may need to know it at that point already. | |
3837 | # Even if this section looks crufty: it has the advantage of | |
3838 | # actually working. | |
3839 | break;; | |
3840 | * ) | |
3841 | break;; | |
3842 | esac | |
3843 | done | |
3844 | test "$ac_cv_exeext" = no && ac_cv_exeext= | |
3845 | ||
bf3b7cd3 | 3846 | else |
5213506e RW |
3847 | ac_file='' |
3848 | fi | |
3849 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 | |
3850 | $as_echo "$ac_file" >&6; } | |
3851 | if test -z "$ac_file"; then : | |
3852 | $as_echo "$as_me: failed program was:" >&5 | |
bf3b7cd3 JD |
3853 | sed 's/^/| /' conftest.$ac_ext >&5 |
3854 | ||
5213506e RW |
3855 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3856 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3857 | { as_fn_set_status 77 | |
3858 | as_fn_error "C compiler cannot create executables | |
3859 | See \`config.log' for more details." "$LINENO" 5; }; } | |
bf3b7cd3 | 3860 | fi |
5213506e RW |
3861 | ac_exeext=$ac_cv_exeext |
3862 | ||
3863 | # Check that the compiler produces executables we can run. If not, either | |
3864 | # the compiler is broken, or we cross compile. | |
3865 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 | |
3866 | $as_echo_n "checking whether the C compiler works... " >&6; } | |
3867 | # If not cross compiling, check that we can run a simple program. | |
3868 | if test "$cross_compiling" != yes; then | |
3869 | if { ac_try='./$ac_file' | |
3870 | { { case "(($ac_try" in | |
3871 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3872 | *) ac_try_echo=$ac_try;; | |
3873 | esac | |
3874 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3875 | $as_echo "$ac_try_echo"; } >&5 | |
3876 | (eval "$ac_try") 2>&5 | |
3877 | ac_status=$? | |
3878 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3879 | test $ac_status = 0; }; }; then | |
3880 | cross_compiling=no | |
3881 | else | |
3882 | if test "$cross_compiling" = maybe; then | |
3883 | cross_compiling=yes | |
3884 | else | |
3885 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
3886 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3887 | as_fn_error "cannot run C compiled programs. | |
3888 | If you meant to cross compile, use \`--host'. | |
3889 | See \`config.log' for more details." "$LINENO" 5; } | |
3890 | fi | |
3891 | fi | |
bf3b7cd3 | 3892 | fi |
5213506e RW |
3893 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
3894 | $as_echo "yes" >&6; } | |
3895 | ||
3896 | rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out conftest.out | |
3897 | ac_clean_files=$ac_clean_files_save | |
3898 | # Check that the compiler produces executables we can run. If not, either | |
3899 | # the compiler is broken, or we cross compile. | |
3900 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 | |
3901 | $as_echo_n "checking whether we are cross compiling... " >&6; } | |
3902 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 | |
3903 | $as_echo "$cross_compiling" >&6; } | |
3904 | ||
3905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 | |
3906 | $as_echo_n "checking for suffix of executables... " >&6; } | |
3907 | if { { ac_try="$ac_link" | |
3908 | case "(($ac_try" in | |
3909 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3910 | *) ac_try_echo=$ac_try;; | |
3911 | esac | |
3912 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3913 | $as_echo "$ac_try_echo"; } >&5 | |
3914 | (eval "$ac_link") 2>&5 | |
3915 | ac_status=$? | |
3916 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3917 | test $ac_status = 0; }; then : | |
3918 | # If both `conftest.exe' and `conftest' are `present' (well, observable) | |
3919 | # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will | |
3920 | # work properly (i.e., refer to `conftest.exe'), while it won't with | |
3921 | # `rm'. | |
3922 | for ac_file in conftest.exe conftest conftest.*; do | |
3923 | test -f "$ac_file" || continue | |
3924 | case $ac_file in | |
3925 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; | |
3926 | *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` | |
3927 | break;; | |
3928 | * ) break;; | |
3929 | esac | |
3930 | done | |
b61ff9c8 | 3931 | else |
5213506e RW |
3932 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3933 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3934 | as_fn_error "cannot compute suffix of executables: cannot compile and link | |
3935 | See \`config.log' for more details." "$LINENO" 5; } | |
b61ff9c8 | 3936 | fi |
5213506e RW |
3937 | rm -f conftest$ac_cv_exeext |
3938 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 | |
3939 | $as_echo "$ac_cv_exeext" >&6; } | |
bf3b7cd3 | 3940 | |
5213506e RW |
3941 | rm -f conftest.$ac_ext |
3942 | EXEEXT=$ac_cv_exeext | |
3943 | ac_exeext=$EXEEXT | |
3944 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 | |
3945 | $as_echo_n "checking for suffix of object files... " >&6; } | |
3946 | if test "${ac_cv_objext+set}" = set; then : | |
3947 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3948 | else |
5213506e | 3949 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
bf3b7cd3 | 3950 | /* end confdefs.h. */ |
5213506e | 3951 | |
bf3b7cd3 JD |
3952 | int |
3953 | main () | |
3954 | { | |
5213506e | 3955 | |
bf3b7cd3 JD |
3956 | ; |
3957 | return 0; | |
3958 | } | |
3959 | _ACEOF | |
5213506e RW |
3960 | rm -f conftest.o conftest.obj |
3961 | if { { ac_try="$ac_compile" | |
3962 | case "(($ac_try" in | |
3963 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
3964 | *) ac_try_echo=$ac_try;; | |
3965 | esac | |
3966 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
3967 | $as_echo "$ac_try_echo"; } >&5 | |
3968 | (eval "$ac_compile") 2>&5 | |
3969 | ac_status=$? | |
3970 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
3971 | test $ac_status = 0; }; then : | |
3972 | for ac_file in conftest.o conftest.obj conftest.*; do | |
3973 | test -f "$ac_file" || continue; | |
3974 | case $ac_file in | |
3975 | *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; | |
3976 | *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` | |
3977 | break;; | |
3978 | esac | |
3979 | done | |
bf3b7cd3 | 3980 | else |
5213506e | 3981 | $as_echo "$as_me: failed program was:" >&5 |
bf3b7cd3 JD |
3982 | sed 's/^/| /' conftest.$ac_ext >&5 |
3983 | ||
5213506e RW |
3984 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
3985 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
3986 | as_fn_error "cannot compute suffix of object files: cannot compile | |
3987 | See \`config.log' for more details." "$LINENO" 5; } | |
bf3b7cd3 | 3988 | fi |
5213506e | 3989 | rm -f conftest.$ac_cv_objext conftest.$ac_ext |
bf3b7cd3 | 3990 | fi |
5213506e RW |
3991 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 |
3992 | $as_echo "$ac_cv_objext" >&6; } | |
3993 | OBJEXT=$ac_cv_objext | |
3994 | ac_objext=$OBJEXT | |
3995 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 | |
3996 | $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } | |
3997 | if test "${ac_cv_c_compiler_gnu+set}" = set; then : | |
3998 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 3999 | else |
5213506e | 4000 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
bf3b7cd3 | 4001 | /* end confdefs.h. */ |
5213506e | 4002 | |
bf3b7cd3 JD |
4003 | int |
4004 | main () | |
4005 | { | |
5213506e RW |
4006 | #ifndef __GNUC__ |
4007 | choke me | |
4008 | #endif | |
bf3b7cd3 JD |
4009 | |
4010 | ; | |
4011 | return 0; | |
4012 | } | |
4013 | _ACEOF | |
5213506e RW |
4014 | if ac_fn_c_try_compile "$LINENO"; then : |
4015 | ac_compiler_gnu=yes | |
4016 | else | |
4017 | ac_compiler_gnu=no | |
4018 | fi | |
4019 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4020 | ac_cv_c_compiler_gnu=$ac_compiler_gnu | |
4021 | ||
4022 | fi | |
4023 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 | |
4024 | $as_echo "$ac_cv_c_compiler_gnu" >&6; } | |
4025 | if test $ac_compiler_gnu = yes; then | |
4026 | GCC=yes | |
4027 | else | |
4028 | GCC= | |
4029 | fi | |
4030 | ac_test_CFLAGS=${CFLAGS+set} | |
4031 | ac_save_CFLAGS=$CFLAGS | |
4032 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 | |
4033 | $as_echo_n "checking whether $CC accepts -g... " >&6; } | |
4034 | if test "${ac_cv_prog_cc_g+set}" = set; then : | |
4035 | $as_echo_n "(cached) " >&6 | |
4036 | else | |
4037 | ac_save_c_werror_flag=$ac_c_werror_flag | |
4038 | ac_c_werror_flag=yes | |
4039 | ac_cv_prog_cc_g=no | |
4040 | CFLAGS="-g" | |
4041 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4042 | /* end confdefs.h. */ |
5213506e | 4043 | |
bf3b7cd3 JD |
4044 | int |
4045 | main () | |
4046 | { | |
bf3b7cd3 JD |
4047 | |
4048 | ; | |
4049 | return 0; | |
4050 | } | |
4051 | _ACEOF | |
5213506e RW |
4052 | if ac_fn_c_try_compile "$LINENO"; then : |
4053 | ac_cv_prog_cc_g=yes | |
bf3b7cd3 | 4054 | else |
5213506e RW |
4055 | CFLAGS="" |
4056 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4057 | /* end confdefs.h. */ |
5213506e | 4058 | |
bf3b7cd3 JD |
4059 | int |
4060 | main () | |
4061 | { | |
bf3b7cd3 JD |
4062 | |
4063 | ; | |
4064 | return 0; | |
4065 | } | |
4066 | _ACEOF | |
5213506e RW |
4067 | if ac_fn_c_try_compile "$LINENO"; then : |
4068 | ||
4069 | else | |
4070 | ac_c_werror_flag=$ac_save_c_werror_flag | |
4071 | CFLAGS="-g" | |
4072 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4073 | /* end confdefs.h. */ |
5213506e | 4074 | |
bf3b7cd3 JD |
4075 | int |
4076 | main () | |
4077 | { | |
bf3b7cd3 JD |
4078 | |
4079 | ; | |
4080 | return 0; | |
4081 | } | |
4082 | _ACEOF | |
5213506e RW |
4083 | if ac_fn_c_try_compile "$LINENO"; then : |
4084 | ac_cv_prog_cc_g=yes | |
bf3b7cd3 | 4085 | fi |
5213506e | 4086 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
bf3b7cd3 | 4087 | fi |
5213506e | 4088 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
bf3b7cd3 | 4089 | fi |
5213506e RW |
4090 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4091 | ac_c_werror_flag=$ac_save_c_werror_flag | |
4092 | fi | |
4093 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 | |
4094 | $as_echo "$ac_cv_prog_cc_g" >&6; } | |
4095 | if test "$ac_test_CFLAGS" = set; then | |
4096 | CFLAGS=$ac_save_CFLAGS | |
4097 | elif test $ac_cv_prog_cc_g = yes; then | |
4098 | if test "$GCC" = yes; then | |
4099 | CFLAGS="-g -O2" | |
4100 | else | |
4101 | CFLAGS="-g" | |
4102 | fi | |
4103 | else | |
4104 | if test "$GCC" = yes; then | |
4105 | CFLAGS="-O2" | |
4106 | else | |
4107 | CFLAGS= | |
4108 | fi | |
4109 | fi | |
4110 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 | |
4111 | $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } | |
4112 | if test "${ac_cv_prog_cc_c89+set}" = set; then : | |
4113 | $as_echo_n "(cached) " >&6 | |
4114 | else | |
4115 | ac_cv_prog_cc_c89=no | |
4116 | ac_save_CC=$CC | |
4117 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4118 | /* end confdefs.h. */ |
5213506e RW |
4119 | #include <stdarg.h> |
4120 | #include <stdio.h> | |
4121 | #include <sys/types.h> | |
4122 | #include <sys/stat.h> | |
4123 | /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ | |
4124 | struct buf { int x; }; | |
4125 | FILE * (*rcsopen) (struct buf *, struct stat *, int); | |
4126 | static char *e (p, i) | |
4127 | char **p; | |
4128 | int i; | |
4129 | { | |
4130 | return p[i]; | |
4131 | } | |
4132 | static char *f (char * (*g) (char **, int), char **p, ...) | |
4133 | { | |
4134 | char *s; | |
4135 | va_list v; | |
4136 | va_start (v,p); | |
4137 | s = g (p, va_arg (v,int)); | |
4138 | va_end (v); | |
4139 | return s; | |
4140 | } | |
4141 | ||
4142 | /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has | |
4143 | function prototypes and stuff, but not '\xHH' hex character constants. | |
4144 | These don't provoke an error unfortunately, instead are silently treated | |
4145 | as 'x'. The following induces an error, until -std is added to get | |
4146 | proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an | |
4147 | array size at least. It's necessary to write '\x00'==0 to get something | |
4148 | that's true only with -std. */ | |
4149 | int osf4_cc_array ['\x00' == 0 ? 1 : -1]; | |
4150 | ||
4151 | /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters | |
4152 | inside strings and character constants. */ | |
4153 | #define FOO(x) 'x' | |
4154 | int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; | |
4155 | ||
4156 | int test (int i, double x); | |
4157 | struct s1 {int (*f) (int a);}; | |
4158 | struct s2 {int (*f) (double a);}; | |
4159 | int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); | |
4160 | int argc; | |
4161 | char **argv; | |
bf3b7cd3 JD |
4162 | int |
4163 | main () | |
4164 | { | |
5213506e | 4165 | return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; |
bf3b7cd3 JD |
4166 | ; |
4167 | return 0; | |
4168 | } | |
4169 | _ACEOF | |
5213506e RW |
4170 | for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ |
4171 | -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" | |
4172 | do | |
4173 | CC="$ac_save_CC $ac_arg" | |
4174 | if ac_fn_c_try_compile "$LINENO"; then : | |
4175 | ac_cv_prog_cc_c89=$ac_arg | |
bf3b7cd3 | 4176 | fi |
5213506e RW |
4177 | rm -f core conftest.err conftest.$ac_objext |
4178 | test "x$ac_cv_prog_cc_c89" != "xno" && break | |
bf3b7cd3 | 4179 | done |
5213506e RW |
4180 | rm -f conftest.$ac_ext |
4181 | CC=$ac_save_CC | |
4182 | ||
4183 | fi | |
4184 | # AC_CACHE_VAL | |
4185 | case "x$ac_cv_prog_cc_c89" in | |
4186 | x) | |
4187 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 | |
4188 | $as_echo "none needed" >&6; } ;; | |
4189 | xno) | |
4190 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 | |
4191 | $as_echo "unsupported" >&6; } ;; | |
4192 | *) | |
4193 | CC="$CC $ac_cv_prog_cc_c89" | |
4194 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 | |
4195 | $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; | |
bf3b7cd3 | 4196 | esac |
5213506e RW |
4197 | if test "x$ac_cv_prog_cc_c89" != xno; then : |
4198 | ||
4199 | fi | |
4200 | ||
4201 | ac_ext=c | |
4202 | ac_cpp='$CPP $CPPFLAGS' | |
4203 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4204 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4205 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4206 | ||
4207 | if test "x$CC" != xcc; then | |
4208 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC and cc understand -c and -o together" >&5 | |
4209 | $as_echo_n "checking whether $CC and cc understand -c and -o together... " >&6; } | |
b61ff9c8 | 4210 | else |
5213506e RW |
4211 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether cc understands -c and -o together" >&5 |
4212 | $as_echo_n "checking whether cc understands -c and -o together... " >&6; } | |
4213 | fi | |
4214 | set dummy $CC; ac_cc=`$as_echo "$2" | | |
4215 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` | |
4216 | if { as_var=ac_cv_prog_cc_${ac_cc}_c_o; eval "test \"\${$as_var+set}\" = set"; }; then : | |
4217 | $as_echo_n "(cached) " >&6 | |
4218 | else | |
4219 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4220 | /* end confdefs.h. */ |
5213506e | 4221 | |
bf3b7cd3 JD |
4222 | int |
4223 | main () | |
4224 | { | |
4225 | ||
bf3b7cd3 JD |
4226 | ; |
4227 | return 0; | |
4228 | } | |
4229 | _ACEOF | |
5213506e RW |
4230 | # Make sure it works both with $CC and with simple cc. |
4231 | # We do the test twice because some compilers refuse to overwrite an | |
4232 | # existing .o file with -o, though they will create one. | |
4233 | ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
4234 | rm -f conftest2.* | |
4235 | if { { case "(($ac_try" in | |
4236 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4237 | *) ac_try_echo=$ac_try;; | |
4238 | esac | |
4239 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4240 | $as_echo "$ac_try_echo"; } >&5 | |
4241 | (eval "$ac_try") 2>&5 | |
4242 | ac_status=$? | |
4243 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4244 | test $ac_status = 0; } && | |
4245 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
4246 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4247 | *) ac_try_echo=$ac_try;; | |
4248 | esac | |
4249 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4250 | $as_echo "$ac_try_echo"; } >&5 | |
4251 | (eval "$ac_try") 2>&5 | |
bf3b7cd3 | 4252 | ac_status=$? |
5213506e RW |
4253 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
4254 | test $ac_status = 0; }; | |
4255 | then | |
4256 | eval ac_cv_prog_cc_${ac_cc}_c_o=yes | |
4257 | if test "x$CC" != xcc; then | |
4258 | # Test first that cc exists at all. | |
4259 | if { ac_try='cc -c conftest.$ac_ext >&5' | |
4260 | { { case "(($ac_try" in | |
4261 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4262 | *) ac_try_echo=$ac_try;; | |
4263 | esac | |
4264 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4265 | $as_echo "$ac_try_echo"; } >&5 | |
4266 | (eval "$ac_try") 2>&5 | |
4267 | ac_status=$? | |
4268 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4269 | test $ac_status = 0; }; }; then | |
4270 | ac_try='cc -c conftest.$ac_ext -o conftest2.$ac_objext >&5' | |
4271 | rm -f conftest2.* | |
4272 | if { { case "(($ac_try" in | |
4273 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4274 | *) ac_try_echo=$ac_try;; | |
4275 | esac | |
4276 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4277 | $as_echo "$ac_try_echo"; } >&5 | |
4278 | (eval "$ac_try") 2>&5 | |
4279 | ac_status=$? | |
4280 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4281 | test $ac_status = 0; } && | |
4282 | test -f conftest2.$ac_objext && { { case "(($ac_try" in | |
4283 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4284 | *) ac_try_echo=$ac_try;; | |
4285 | esac | |
4286 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4287 | $as_echo "$ac_try_echo"; } >&5 | |
4288 | (eval "$ac_try") 2>&5 | |
bf3b7cd3 | 4289 | ac_status=$? |
5213506e RW |
4290 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
4291 | test $ac_status = 0; }; | |
4292 | then | |
4293 | # cc works too. | |
4294 | : | |
4295 | else | |
4296 | # cc exists but doesn't like -o. | |
4297 | eval ac_cv_prog_cc_${ac_cc}_c_o=no | |
4298 | fi | |
4299 | fi | |
4300 | fi | |
bf3b7cd3 | 4301 | else |
5213506e RW |
4302 | eval ac_cv_prog_cc_${ac_cc}_c_o=no |
4303 | fi | |
4304 | rm -f core conftest* | |
bf3b7cd3 | 4305 | |
b61ff9c8 | 4306 | fi |
5213506e RW |
4307 | if eval test \$ac_cv_prog_cc_${ac_cc}_c_o = yes; then |
4308 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
4309 | $as_echo "yes" >&6; } | |
4310 | else | |
4311 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4312 | $as_echo "no" >&6; } | |
4313 | ||
4314 | $as_echo "#define NO_MINUS_C_MINUS_O 1" >>confdefs.h | |
4315 | ||
bf3b7cd3 | 4316 | fi |
5213506e RW |
4317 | |
4318 | # expand $ac_aux_dir to an absolute path | |
4319 | am_aux_dir=`cd $ac_aux_dir && pwd` | |
4320 | ||
4321 | # FIXME: we rely on the cache variable name because | |
4322 | # there is no other way. | |
4323 | set dummy $CC | |
4324 | am_cc=`echo $2 | sed 's/[^a-zA-Z0-9_]/_/g;s/^[0-9]/_/'` | |
4325 | eval am_t=\$ac_cv_prog_cc_${am_cc}_c_o | |
4326 | if test "$am_t" != yes; then | |
4327 | # Losing compiler, so override with the script. | |
4328 | # FIXME: It is wrong to rewrite CC. | |
4329 | # But if we don't then we get into trouble of one sort or another. | |
4330 | # A longer-term fix would be to have automake use am__CC in this case, | |
4331 | # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)" | |
4332 | CC="$am_aux_dir/compile $CC" | |
bf3b7cd3 | 4333 | fi |
5213506e RW |
4334 | |
4335 | ||
4336 | ac_ext=cpp | |
4337 | ac_cpp='$CXXCPP $CPPFLAGS' | |
4338 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4339 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4340 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu | |
4341 | if test -z "$CXX"; then | |
4342 | if test -n "$CCC"; then | |
4343 | CXX=$CCC | |
4344 | else | |
4345 | if test -n "$ac_tool_prefix"; then | |
4346 | for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC | |
4347 | do | |
4348 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
4349 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
4350 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4351 | $as_echo_n "checking for $ac_word... " >&6; } | |
4352 | if test "${ac_cv_prog_CXX+set}" = set; then : | |
4353 | $as_echo_n "(cached) " >&6 | |
b61ff9c8 | 4354 | else |
5213506e RW |
4355 | if test -n "$CXX"; then |
4356 | ac_cv_prog_CXX="$CXX" # Let the user override the test. | |
4357 | else | |
4358 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4359 | for as_dir in $PATH | |
4360 | do | |
4361 | IFS=$as_save_IFS | |
4362 | test -z "$as_dir" && as_dir=. | |
4363 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4364 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4365 | ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" | |
4366 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4367 | break 2 | |
4368 | fi | |
4369 | done | |
4370 | done | |
4371 | IFS=$as_save_IFS | |
4372 | ||
bf3b7cd3 | 4373 | fi |
b61ff9c8 | 4374 | fi |
5213506e RW |
4375 | CXX=$ac_cv_prog_CXX |
4376 | if test -n "$CXX"; then | |
4377 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 | |
4378 | $as_echo "$CXX" >&6; } | |
4379 | else | |
4380 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4381 | $as_echo "no" >&6; } | |
4382 | fi | |
bf3b7cd3 JD |
4383 | |
4384 | ||
5213506e RW |
4385 | test -n "$CXX" && break |
4386 | done | |
4387 | fi | |
4388 | if test -z "$CXX"; then | |
4389 | ac_ct_CXX=$CXX | |
4390 | for ac_prog in g++ c++ gpp aCC CC cxx cc++ cl.exe FCC KCC RCC xlC_r xlC | |
4391 | do | |
4392 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
4393 | set dummy $ac_prog; ac_word=$2 | |
4394 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4395 | $as_echo_n "checking for $ac_word... " >&6; } | |
4396 | if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then : | |
4397 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 4398 | else |
5213506e RW |
4399 | if test -n "$ac_ct_CXX"; then |
4400 | ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. | |
bf3b7cd3 | 4401 | else |
5213506e RW |
4402 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
4403 | for as_dir in $PATH | |
4404 | do | |
4405 | IFS=$as_save_IFS | |
4406 | test -z "$as_dir" && as_dir=. | |
4407 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4408 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4409 | ac_cv_prog_ac_ct_CXX="$ac_prog" | |
4410 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4411 | break 2 | |
4412 | fi | |
4413 | done | |
4414 | done | |
4415 | IFS=$as_save_IFS | |
bf3b7cd3 | 4416 | |
bf3b7cd3 | 4417 | fi |
bf3b7cd3 | 4418 | fi |
5213506e RW |
4419 | ac_ct_CXX=$ac_cv_prog_ac_ct_CXX |
4420 | if test -n "$ac_ct_CXX"; then | |
4421 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 | |
4422 | $as_echo "$ac_ct_CXX" >&6; } | |
bf3b7cd3 | 4423 | else |
5213506e RW |
4424 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
4425 | $as_echo "no" >&6; } | |
4426 | fi | |
bf3b7cd3 | 4427 | |
5213506e RW |
4428 | |
4429 | test -n "$ac_ct_CXX" && break | |
4430 | done | |
4431 | ||
4432 | if test "x$ac_ct_CXX" = x; then | |
4433 | CXX="g++" | |
4434 | else | |
4435 | case $cross_compiling:$ac_tool_warned in | |
4436 | yes:) | |
4437 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4438 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4439 | ac_tool_warned=yes ;; | |
4440 | esac | |
4441 | CXX=$ac_ct_CXX | |
4442 | fi | |
4443 | fi | |
4444 | ||
4445 | fi | |
4446 | fi | |
4447 | # Provide some information about the compiler. | |
4448 | $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 | |
4449 | set X $ac_compile | |
4450 | ac_compiler=$2 | |
4451 | for ac_option in --version -v -V -qversion; do | |
4452 | { { ac_try="$ac_compiler $ac_option >&5" | |
4453 | case "(($ac_try" in | |
4454 | *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; | |
4455 | *) ac_try_echo=$ac_try;; | |
4456 | esac | |
4457 | eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" | |
4458 | $as_echo "$ac_try_echo"; } >&5 | |
4459 | (eval "$ac_compiler $ac_option >&5") 2>conftest.err | |
b61ff9c8 | 4460 | ac_status=$? |
5213506e RW |
4461 | if test -s conftest.err; then |
4462 | sed '10a\ | |
4463 | ... rest of stderr output deleted ... | |
4464 | 10q' conftest.err >conftest.er1 | |
4465 | cat conftest.er1 >&5 | |
4466 | rm -f conftest.er1 conftest.err | |
4467 | fi | |
4468 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
4469 | test $ac_status = 0; } | |
4470 | done | |
4471 | ||
4472 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 | |
4473 | $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } | |
4474 | if test "${ac_cv_cxx_compiler_gnu+set}" = set; then : | |
4475 | $as_echo_n "(cached) " >&6 | |
4476 | else | |
4477 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4478 | /* end confdefs.h. */ |
5213506e | 4479 | |
bf3b7cd3 JD |
4480 | int |
4481 | main () | |
4482 | { | |
5213506e RW |
4483 | #ifndef __GNUC__ |
4484 | choke me | |
4485 | #endif | |
bf3b7cd3 JD |
4486 | |
4487 | ; | |
4488 | return 0; | |
4489 | } | |
4490 | _ACEOF | |
5213506e RW |
4491 | if ac_fn_cxx_try_compile "$LINENO"; then : |
4492 | ac_compiler_gnu=yes | |
bf3b7cd3 | 4493 | else |
5213506e RW |
4494 | ac_compiler_gnu=no |
4495 | fi | |
4496 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4497 | ac_cv_cxx_compiler_gnu=$ac_compiler_gnu | |
bf3b7cd3 | 4498 | |
bf3b7cd3 | 4499 | fi |
5213506e RW |
4500 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 |
4501 | $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } | |
4502 | if test $ac_compiler_gnu = yes; then | |
4503 | GXX=yes | |
bf3b7cd3 | 4504 | else |
5213506e RW |
4505 | GXX= |
4506 | fi | |
4507 | ac_test_CXXFLAGS=${CXXFLAGS+set} | |
4508 | ac_save_CXXFLAGS=$CXXFLAGS | |
4509 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 | |
4510 | $as_echo_n "checking whether $CXX accepts -g... " >&6; } | |
4511 | if test "${ac_cv_prog_cxx_g+set}" = set; then : | |
4512 | $as_echo_n "(cached) " >&6 | |
4513 | else | |
4514 | ac_save_cxx_werror_flag=$ac_cxx_werror_flag | |
4515 | ac_cxx_werror_flag=yes | |
4516 | ac_cv_prog_cxx_g=no | |
4517 | CXXFLAGS="-g" | |
4518 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4519 | /* end confdefs.h. */ |
5213506e | 4520 | |
bf3b7cd3 JD |
4521 | int |
4522 | main () | |
4523 | { | |
bf3b7cd3 JD |
4524 | |
4525 | ; | |
4526 | return 0; | |
4527 | } | |
4528 | _ACEOF | |
5213506e RW |
4529 | if ac_fn_cxx_try_compile "$LINENO"; then : |
4530 | ac_cv_prog_cxx_g=yes | |
4531 | else | |
4532 | CXXFLAGS="" | |
4533 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4534 | /* end confdefs.h. */ |
5213506e | 4535 | |
bf3b7cd3 JD |
4536 | int |
4537 | main () | |
4538 | { | |
bf3b7cd3 JD |
4539 | |
4540 | ; | |
4541 | return 0; | |
4542 | } | |
4543 | _ACEOF | |
5213506e | 4544 | if ac_fn_cxx_try_compile "$LINENO"; then : |
bf3b7cd3 | 4545 | |
bf3b7cd3 | 4546 | else |
5213506e RW |
4547 | ac_cxx_werror_flag=$ac_save_cxx_werror_flag |
4548 | CXXFLAGS="-g" | |
4549 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4550 | /* end confdefs.h. */ |
5213506e | 4551 | |
bf3b7cd3 JD |
4552 | int |
4553 | main () | |
4554 | { | |
bf3b7cd3 JD |
4555 | |
4556 | ; | |
4557 | return 0; | |
4558 | } | |
4559 | _ACEOF | |
5213506e RW |
4560 | if ac_fn_cxx_try_compile "$LINENO"; then : |
4561 | ac_cv_prog_cxx_g=yes | |
4562 | fi | |
4563 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4564 | fi | |
4565 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4566 | fi | |
4567 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
4568 | ac_cxx_werror_flag=$ac_save_cxx_werror_flag | |
4569 | fi | |
4570 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 | |
4571 | $as_echo "$ac_cv_prog_cxx_g" >&6; } | |
4572 | if test "$ac_test_CXXFLAGS" = set; then | |
4573 | CXXFLAGS=$ac_save_CXXFLAGS | |
4574 | elif test $ac_cv_prog_cxx_g = yes; then | |
4575 | if test "$GXX" = yes; then | |
4576 | CXXFLAGS="-g -O2" | |
4577 | else | |
4578 | CXXFLAGS="-g" | |
4579 | fi | |
bf3b7cd3 | 4580 | else |
5213506e RW |
4581 | if test "$GXX" = yes; then |
4582 | CXXFLAGS="-O2" | |
4583 | else | |
4584 | CXXFLAGS= | |
4585 | fi | |
4586 | fi | |
4587 | ac_ext=c | |
4588 | ac_cpp='$CPP $CPPFLAGS' | |
4589 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4590 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4591 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4592 | ||
4593 | ||
4594 | ||
4595 | ||
4596 | if test -n "$ac_tool_prefix"; then | |
4597 | # Extract the first word of "${ac_tool_prefix}gnatbind", so it can be a program name with args. | |
4598 | set dummy ${ac_tool_prefix}gnatbind; ac_word=$2 | |
4599 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4600 | $as_echo_n "checking for $ac_word... " >&6; } | |
4601 | if test "${ac_cv_prog_GNATBIND+set}" = set; then : | |
4602 | $as_echo_n "(cached) " >&6 | |
4603 | else | |
4604 | if test -n "$GNATBIND"; then | |
4605 | ac_cv_prog_GNATBIND="$GNATBIND" # Let the user override the test. | |
4606 | else | |
4607 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4608 | for as_dir in $PATH | |
4609 | do | |
4610 | IFS=$as_save_IFS | |
4611 | test -z "$as_dir" && as_dir=. | |
4612 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4613 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4614 | ac_cv_prog_GNATBIND="${ac_tool_prefix}gnatbind" | |
4615 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4616 | break 2 | |
4617 | fi | |
4618 | done | |
4619 | done | |
4620 | IFS=$as_save_IFS | |
4621 | ||
4622 | fi | |
4623 | fi | |
4624 | GNATBIND=$ac_cv_prog_GNATBIND | |
4625 | if test -n "$GNATBIND"; then | |
4626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATBIND" >&5 | |
4627 | $as_echo "$GNATBIND" >&6; } | |
4628 | else | |
4629 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4630 | $as_echo "no" >&6; } | |
4631 | fi | |
4632 | ||
bf3b7cd3 | 4633 | |
bf3b7cd3 | 4634 | fi |
5213506e RW |
4635 | if test -z "$ac_cv_prog_GNATBIND"; then |
4636 | ac_ct_GNATBIND=$GNATBIND | |
4637 | # Extract the first word of "gnatbind", so it can be a program name with args. | |
4638 | set dummy gnatbind; ac_word=$2 | |
4639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4640 | $as_echo_n "checking for $ac_word... " >&6; } | |
4641 | if test "${ac_cv_prog_ac_ct_GNATBIND+set}" = set; then : | |
4642 | $as_echo_n "(cached) " >&6 | |
4643 | else | |
4644 | if test -n "$ac_ct_GNATBIND"; then | |
4645 | ac_cv_prog_ac_ct_GNATBIND="$ac_ct_GNATBIND" # Let the user override the test. | |
4646 | else | |
4647 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4648 | for as_dir in $PATH | |
4649 | do | |
4650 | IFS=$as_save_IFS | |
4651 | test -z "$as_dir" && as_dir=. | |
4652 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4653 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4654 | ac_cv_prog_ac_ct_GNATBIND="gnatbind" | |
4655 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4656 | break 2 | |
4657 | fi | |
bf3b7cd3 | 4658 | done |
5213506e RW |
4659 | done |
4660 | IFS=$as_save_IFS | |
4661 | ||
4662 | fi | |
4663 | fi | |
4664 | ac_ct_GNATBIND=$ac_cv_prog_ac_ct_GNATBIND | |
4665 | if test -n "$ac_ct_GNATBIND"; then | |
4666 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATBIND" >&5 | |
4667 | $as_echo "$ac_ct_GNATBIND" >&6; } | |
4668 | else | |
4669 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4670 | $as_echo "no" >&6; } | |
4671 | fi | |
4672 | ||
4673 | if test "x$ac_ct_GNATBIND" = x; then | |
4674 | GNATBIND="no" | |
4675 | else | |
4676 | case $cross_compiling:$ac_tool_warned in | |
4677 | yes:) | |
4678 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4679 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4680 | ac_tool_warned=yes ;; | |
bf3b7cd3 | 4681 | esac |
5213506e RW |
4682 | GNATBIND=$ac_ct_GNATBIND |
4683 | fi | |
b61ff9c8 | 4684 | else |
5213506e RW |
4685 | GNATBIND="$ac_cv_prog_GNATBIND" |
4686 | fi | |
bf3b7cd3 | 4687 | |
5213506e RW |
4688 | if test -n "$ac_tool_prefix"; then |
4689 | # Extract the first word of "${ac_tool_prefix}gnatmake", so it can be a program name with args. | |
4690 | set dummy ${ac_tool_prefix}gnatmake; ac_word=$2 | |
4691 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4692 | $as_echo_n "checking for $ac_word... " >&6; } | |
4693 | if test "${ac_cv_prog_GNATMAKE+set}" = set; then : | |
4694 | $as_echo_n "(cached) " >&6 | |
4695 | else | |
4696 | if test -n "$GNATMAKE"; then | |
4697 | ac_cv_prog_GNATMAKE="$GNATMAKE" # Let the user override the test. | |
4698 | else | |
4699 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4700 | for as_dir in $PATH | |
4701 | do | |
4702 | IFS=$as_save_IFS | |
4703 | test -z "$as_dir" && as_dir=. | |
4704 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4705 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4706 | ac_cv_prog_GNATMAKE="${ac_tool_prefix}gnatmake" | |
4707 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4708 | break 2 | |
4709 | fi | |
4710 | done | |
4711 | done | |
4712 | IFS=$as_save_IFS | |
4713 | ||
4714 | fi | |
4715 | fi | |
4716 | GNATMAKE=$ac_cv_prog_GNATMAKE | |
4717 | if test -n "$GNATMAKE"; then | |
4718 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNATMAKE" >&5 | |
4719 | $as_echo "$GNATMAKE" >&6; } | |
4720 | else | |
4721 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4722 | $as_echo "no" >&6; } | |
4723 | fi | |
4724 | ||
4725 | ||
4726 | fi | |
4727 | if test -z "$ac_cv_prog_GNATMAKE"; then | |
4728 | ac_ct_GNATMAKE=$GNATMAKE | |
4729 | # Extract the first word of "gnatmake", so it can be a program name with args. | |
4730 | set dummy gnatmake; ac_word=$2 | |
4731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | |
4732 | $as_echo_n "checking for $ac_word... " >&6; } | |
4733 | if test "${ac_cv_prog_ac_ct_GNATMAKE+set}" = set; then : | |
4734 | $as_echo_n "(cached) " >&6 | |
4735 | else | |
4736 | if test -n "$ac_ct_GNATMAKE"; then | |
4737 | ac_cv_prog_ac_ct_GNATMAKE="$ac_ct_GNATMAKE" # Let the user override the test. | |
4738 | else | |
4739 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4740 | for as_dir in $PATH | |
4741 | do | |
4742 | IFS=$as_save_IFS | |
4743 | test -z "$as_dir" && as_dir=. | |
4744 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4745 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
4746 | ac_cv_prog_ac_ct_GNATMAKE="gnatmake" | |
4747 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | |
4748 | break 2 | |
4749 | fi | |
4750 | done | |
4751 | done | |
4752 | IFS=$as_save_IFS | |
4753 | ||
4754 | fi | |
4755 | fi | |
4756 | ac_ct_GNATMAKE=$ac_cv_prog_ac_ct_GNATMAKE | |
4757 | if test -n "$ac_ct_GNATMAKE"; then | |
4758 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_GNATMAKE" >&5 | |
4759 | $as_echo "$ac_ct_GNATMAKE" >&6; } | |
4760 | else | |
4761 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | |
4762 | $as_echo "no" >&6; } | |
4763 | fi | |
4764 | ||
4765 | if test "x$ac_ct_GNATMAKE" = x; then | |
4766 | GNATMAKE="no" | |
bf3b7cd3 | 4767 | else |
5213506e RW |
4768 | case $cross_compiling:$ac_tool_warned in |
4769 | yes:) | |
4770 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
4771 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
4772 | ac_tool_warned=yes ;; | |
4773 | esac | |
4774 | GNATMAKE=$ac_ct_GNATMAKE | |
4775 | fi | |
4776 | else | |
4777 | GNATMAKE="$ac_cv_prog_GNATMAKE" | |
4778 | fi | |
bf3b7cd3 | 4779 | |
5213506e RW |
4780 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether compiler driver understands Ada" >&5 |
4781 | $as_echo_n "checking whether compiler driver understands Ada... " >&6; } | |
4782 | if test "${acx_cv_cc_gcc_supports_ada+set}" = set; then : | |
4783 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 4784 | else |
5213506e RW |
4785 | cat >conftest.adb <<EOF |
4786 | procedure conftest is begin null; end conftest; | |
4787 | EOF | |
4788 | acx_cv_cc_gcc_supports_ada=no | |
4789 | # There is a bug in old released versions of GCC which causes the | |
4790 | # driver to exit successfully when the appropriate language module | |
4791 | # has not been installed. This is fixed in 2.95.4, 3.0.2, and 3.1. | |
4792 | # Therefore we must check for the error message as well as an | |
4793 | # unsuccessful exit. | |
4794 | # Other compilers, like HP Tru64 UNIX cc, exit successfully when | |
4795 | # given a .adb file, but produce no object file. So we must check | |
4796 | # if an object file was really produced to guard against this. | |
4797 | errors=`(${CC} -I"$srcdir"/ada -c conftest.adb) 2>&1 || echo failure` | |
4798 | if test x"$errors" = x && test -f conftest.$ac_objext; then | |
4799 | acx_cv_cc_gcc_supports_ada=yes | |
4800 | fi | |
4801 | rm -f conftest.* | |
4802 | fi | |
4803 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_cc_gcc_supports_ada" >&5 | |
4804 | $as_echo "$acx_cv_cc_gcc_supports_ada" >&6; } | |
bf3b7cd3 | 4805 | |
5213506e RW |
4806 | if test x$GNATBIND != xno && test x$GNATMAKE != xno && test x$acx_cv_cc_gcc_supports_ada != xno; then |
4807 | have_gnat=yes | |
4808 | else | |
4809 | have_gnat=no | |
b61ff9c8 | 4810 | fi |
5213506e RW |
4811 | |
4812 | ||
4813 | # autoconf is lame and doesn't give us any substitution variable for this. | |
4814 | if eval "test \"`echo '$ac_cv_prog_cc_'${ac_cc}_c_o`\" = no"; then | |
4815 | NO_MINUS_C_MINUS_O=yes | |
4816 | else | |
4817 | OUTPUT_OPTION='-o $@' | |
bf3b7cd3 | 4818 | fi |
5213506e RW |
4819 | |
4820 | ||
4821 | ||
4822 | # Remove the -O2: for historical reasons, unless bootstrapping we prefer | |
4823 | # optimizations to be activated explicitly by the toplevel. | |
4824 | case "$CC" in | |
4825 | */prev-gcc/xgcc*) ;; | |
4826 | *) CFLAGS=`echo $CFLAGS | sed "s/-O[s0-9]* *//" ` ;; | |
4827 | esac | |
4828 | ||
4829 | ||
4830 | # ------------------------- | |
4831 | # Check C compiler features | |
4832 | # ------------------------- | |
4833 | ||
4834 | ||
4835 | ac_ext=c | |
4836 | ac_cpp='$CPP $CPPFLAGS' | |
4837 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4838 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4839 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
4840 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
4841 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
4842 | # On Suns, sometimes $CPP names a directory. | |
4843 | if test -n "$CPP" && test -d "$CPP"; then | |
4844 | CPP= | |
bf3b7cd3 | 4845 | fi |
5213506e RW |
4846 | if test -z "$CPP"; then |
4847 | if test "${ac_cv_prog_CPP+set}" = set; then : | |
4848 | $as_echo_n "(cached) " >&6 | |
b61ff9c8 | 4849 | else |
5213506e RW |
4850 | # Double quotes because CPP needs to be expanded |
4851 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
4852 | do | |
4853 | ac_preproc_ok=false | |
4854 | for ac_c_preproc_warn_flag in '' yes | |
4855 | do | |
4856 | # Use a header file that comes with gcc, so configuring glibc | |
4857 | # with a fresh cross-compiler works. | |
4858 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
4859 | # <limits.h> exists even on freestanding compilers. | |
4860 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
4861 | # not just through cpp. "Syntax error" is here to catch this case. | |
4862 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4863 | /* end confdefs.h. */ | |
4864 | #ifdef __STDC__ | |
4865 | # include <limits.h> | |
4866 | #else | |
4867 | # include <assert.h> | |
4868 | #endif | |
4869 | Syntax error | |
bf3b7cd3 | 4870 | _ACEOF |
5213506e | 4871 | if ac_fn_c_try_cpp "$LINENO"; then : |
bf3b7cd3 | 4872 | |
bf3b7cd3 | 4873 | else |
5213506e RW |
4874 | # Broken: fails on valid input. |
4875 | continue | |
4876 | fi | |
4877 | rm -f conftest.err conftest.$ac_ext | |
4878 | ||
4879 | # OK, works on sane cases. Now check whether nonexistent headers | |
4880 | # can be detected and how. | |
4881 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4882 | /* end confdefs.h. */ |
5213506e | 4883 | #include <ac_nonexistent.h> |
bf3b7cd3 | 4884 | _ACEOF |
5213506e RW |
4885 | if ac_fn_c_try_cpp "$LINENO"; then : |
4886 | # Broken: success on invalid input. | |
4887 | continue | |
b61ff9c8 | 4888 | else |
5213506e RW |
4889 | # Passes both tests. |
4890 | ac_preproc_ok=: | |
4891 | break | |
bf3b7cd3 | 4892 | fi |
5213506e | 4893 | rm -f conftest.err conftest.$ac_ext |
bf3b7cd3 | 4894 | |
5213506e RW |
4895 | done |
4896 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
4897 | rm -f conftest.err conftest.$ac_ext | |
4898 | if $ac_preproc_ok; then : | |
4899 | break | |
4900 | fi | |
bf3b7cd3 | 4901 | |
5213506e RW |
4902 | done |
4903 | ac_cv_prog_CPP=$CPP | |
bf3b7cd3 | 4904 | |
8b1f719a | 4905 | fi |
5213506e | 4906 | CPP=$ac_cv_prog_CPP |
8b1f719a | 4907 | else |
5213506e RW |
4908 | ac_cv_prog_CPP=$CPP |
4909 | fi | |
4910 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
4911 | $as_echo "$CPP" >&6; } | |
4912 | ac_preproc_ok=false | |
4913 | for ac_c_preproc_warn_flag in '' yes | |
4914 | do | |
4915 | # Use a header file that comes with gcc, so configuring glibc | |
4916 | # with a fresh cross-compiler works. | |
4917 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
4918 | # <limits.h> exists even on freestanding compilers. | |
4919 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
4920 | # not just through cpp. "Syntax error" is here to catch this case. | |
4921 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4922 | /* end confdefs.h. */ |
5213506e RW |
4923 | #ifdef __STDC__ |
4924 | # include <limits.h> | |
4925 | #else | |
4926 | # include <assert.h> | |
4927 | #endif | |
4928 | Syntax error | |
bf3b7cd3 | 4929 | _ACEOF |
5213506e | 4930 | if ac_fn_c_try_cpp "$LINENO"; then : |
bf3b7cd3 | 4931 | |
bf3b7cd3 | 4932 | else |
5213506e RW |
4933 | # Broken: fails on valid input. |
4934 | continue | |
bf3b7cd3 | 4935 | fi |
5213506e | 4936 | rm -f conftest.err conftest.$ac_ext |
bf3b7cd3 | 4937 | |
5213506e RW |
4938 | # OK, works on sane cases. Now check whether nonexistent headers |
4939 | # can be detected and how. | |
4940 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
bf3b7cd3 | 4941 | /* end confdefs.h. */ |
5213506e | 4942 | #include <ac_nonexistent.h> |
bf3b7cd3 | 4943 | _ACEOF |
5213506e RW |
4944 | if ac_fn_c_try_cpp "$LINENO"; then : |
4945 | # Broken: success on invalid input. | |
4946 | continue | |
bf3b7cd3 | 4947 | else |
5213506e RW |
4948 | # Passes both tests. |
4949 | ac_preproc_ok=: | |
4950 | break | |
bf3b7cd3 | 4951 | fi |
5213506e RW |
4952 | rm -f conftest.err conftest.$ac_ext |
4953 | ||
bf3b7cd3 | 4954 | done |
5213506e RW |
4955 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. |
4956 | rm -f conftest.err conftest.$ac_ext | |
4957 | if $ac_preproc_ok; then : | |
4958 | ||
b61ff9c8 | 4959 | else |
5213506e RW |
4960 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
4961 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
4962 | as_fn_error "C preprocessor \"$CPP\" fails sanity check | |
4963 | See \`config.log' for more details." "$LINENO" 5; } | |
4964 | fi | |
bf3b7cd3 | 4965 | |
5213506e RW |
4966 | ac_ext=c |
4967 | ac_cpp='$CPP $CPPFLAGS' | |
4968 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
4969 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
4970 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
bf3b7cd3 | 4971 | |
bf3b7cd3 | 4972 | |
5213506e RW |
4973 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 |
4974 | $as_echo_n "checking for grep that handles long lines and -e... " >&6; } | |
4975 | if test "${ac_cv_path_GREP+set}" = set; then : | |
4976 | $as_echo_n "(cached) " >&6 | |
4977 | else | |
4978 | if test -z "$GREP"; then | |
4979 | ac_path_GREP_found=false | |
4980 | # Loop through the user's path and test for each of PROGNAME-LIST | |
4981 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
4982 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
4983 | do | |
4984 | IFS=$as_save_IFS | |
4985 | test -z "$as_dir" && as_dir=. | |
4986 | for ac_prog in grep ggrep; do | |
4987 | for ac_exec_ext in '' $ac_executable_extensions; do | |
4988 | ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" | |
4989 | { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue | |
4990 | # Check for GNU ac_path_GREP and select it if it is found. | |
4991 | # Check for GNU $ac_path_GREP | |
4992 | case `"$ac_path_GREP" --version 2>&1` in | |
4993 | *GNU*) | |
4994 | ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; | |
4995 | *) | |
4996 | ac_count=0 | |
4997 | $as_echo_n 0123456789 >"conftest.in" | |
4998 | while : | |
4999 | do | |
5000 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
5001 | mv "conftest.tmp" "conftest.in" | |
5002 | cp "conftest.in" "conftest.nl" | |
5003 | $as_echo 'GREP' >> "conftest.nl" | |
5004 | "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
5005 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
5006 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
5007 | if test $ac_count -gt ${ac_path_GREP_max-0}; then | |
5008 | # Best one so far, save it but keep looking for a better one | |
5009 | ac_cv_path_GREP="$ac_path_GREP" | |
5010 | ac_path_GREP_max=$ac_count | |
5011 | fi | |
5012 | # 10*(2^10) chars as input seems more than enough | |
5013 | test $ac_count -gt 10 && break | |
5014 | done | |
5015 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
5016 | esac | |
5017 | ||
5018 | $ac_path_GREP_found && break 3 | |
5019 | done | |
5020 | done | |
5021 | done | |
5022 | IFS=$as_save_IFS | |
5023 | if test -z "$ac_cv_path_GREP"; then | |
5024 | as_fn_error "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 | |
5025 | fi | |
b61ff9c8 | 5026 | else |
5213506e | 5027 | ac_cv_path_GREP=$GREP |
2f41c1d6 | 5028 | fi |
5213506e | 5029 | |
b61ff9c8 | 5030 | fi |
5213506e RW |
5031 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 |
5032 | $as_echo "$ac_cv_path_GREP" >&6; } | |
5033 | GREP="$ac_cv_path_GREP" | |
bf3b7cd3 JD |
5034 | |
5035 | ||
5213506e RW |
5036 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 |
5037 | $as_echo_n "checking for egrep... " >&6; } | |
5038 | if test "${ac_cv_path_EGREP+set}" = set; then : | |
5039 | $as_echo_n "(cached) " >&6 | |
5ec1c5e6 | 5040 | else |
5213506e RW |
5041 | if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 |
5042 | then ac_cv_path_EGREP="$GREP -E" | |
5043 | else | |
5044 | if test -z "$EGREP"; then | |
5045 | ac_path_EGREP_found=false | |
5046 | # Loop through the user's path and test for each of PROGNAME-LIST | |
5047 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
5048 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
5049 | do | |
5050 | IFS=$as_save_IFS | |
5051 | test -z "$as_dir" && as_dir=. | |
5052 | for ac_prog in egrep; do | |
5053 | for ac_exec_ext in '' $ac_executable_extensions; do | |
5054 | ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" | |
5055 | { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue | |
5056 | # Check for GNU ac_path_EGREP and select it if it is found. | |
5057 | # Check for GNU $ac_path_EGREP | |
5058 | case `"$ac_path_EGREP" --version 2>&1` in | |
5059 | *GNU*) | |
5060 | ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; | |
5061 | *) | |
5062 | ac_count=0 | |
5063 | $as_echo_n 0123456789 >"conftest.in" | |
5064 | while : | |
5065 | do | |
5066 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
5067 | mv "conftest.tmp" "conftest.in" | |
5068 | cp "conftest.in" "conftest.nl" | |
5069 | $as_echo 'EGREP' >> "conftest.nl" | |
5070 | "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
5071 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
5072 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
5073 | if test $ac_count -gt ${ac_path_EGREP_max-0}; then | |
5074 | # Best one so far, save it but keep looking for a better one | |
5075 | ac_cv_path_EGREP="$ac_path_EGREP" | |
5076 | ac_path_EGREP_max=$ac_count | |
5077 | fi | |
5078 | # 10*(2^10) chars as input seems more than enough | |
5079 | test $ac_count -gt 10 && break | |
5080 | done | |
5081 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
5082 | esac | |
5ec1c5e6 | 5083 | |
5213506e RW |
5084 | $ac_path_EGREP_found && break 3 |
5085 | done | |
5086 | done | |
5087 | done | |
5088 | IFS=$as_save_IFS | |
5089 | if test -z "$ac_cv_path_EGREP"; then | |
5090 | as_fn_error "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 | |
5091 | fi | |
5092 | else | |
5093 | ac_cv_path_EGREP=$EGREP | |
5ec1c5e6 | 5094 | fi |
5213506e RW |
5095 | |
5096 | fi | |
5ec1c5e6 | 5097 | fi |
5213506e RW |
5098 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 |
5099 | $as_echo "$ac_cv_path_EGREP" >&6; } | |
5100 | EGREP="$ac_cv_path_EGREP" | |
5ec1c5e6 | 5101 | |
5ec1c5e6 | 5102 | |
5213506e RW |
5103 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
5104 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
5105 | if test "${ac_cv_header_stdc+set}" = set; then : | |
5106 | $as_echo_n "(cached) " >&6 | |
bf3b7cd3 | 5107 | else |
5213506e | 5108 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 5109 | /* end confdefs.h. */ |
5213506e RW |
5110 | #include <stdlib.h> |
5111 | #include <stdarg.h> | |
5112 | #include <string.h> | |
5113 | #include <float.h> | |
5114 | ||
ba479fd2 NN |
5115 | int |
5116 | main () | |
5117 | { | |
5213506e | 5118 | |
ba479fd2 NN |
5119 | ; |
5120 | return 0; | |
5121 | } | |
5122 | _ACEOF | |
5213506e RW |
5123 | if ac_fn_c_try_compile "$LINENO"; then : |
5124 | ac_cv_header_stdc=yes | |
75b6f3fd | 5125 | else |
5213506e | 5126 | ac_cv_header_stdc=no |
75b6f3fd | 5127 | fi |
5213506e | 5128 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
75b6f3fd | 5129 | |
5213506e RW |
5130 | if test $ac_cv_header_stdc = yes; then |
5131 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
5132 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 5133 | /* end confdefs.h. */ |
5213506e | 5134 | #include <string.h> |
bf3b7cd3 | 5135 | |
ba479fd2 | 5136 | _ACEOF |
5213506e RW |
5137 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
5138 | $EGREP "memchr" >/dev/null 2>&1; then : | |
bf3b7cd3 | 5139 | |
75e93faa | 5140 | else |
5213506e RW |
5141 | ac_cv_header_stdc=no |
5142 | fi | |
5143 | rm -f conftest* | |
ba479fd2 | 5144 | |
75e93faa | 5145 | fi |
bf3b7cd3 | 5146 | |
5213506e RW |
5147 | if test $ac_cv_header_stdc = yes; then |
5148 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
5149 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 5150 | /* end confdefs.h. */ |
5213506e | 5151 | #include <stdlib.h> |
bf3b7cd3 | 5152 | |
ba479fd2 | 5153 | _ACEOF |
5213506e RW |
5154 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
5155 | $EGREP "free" >/dev/null 2>&1; then : | |
bf3b7cd3 | 5156 | |
04cabffc | 5157 | else |
5213506e | 5158 | ac_cv_header_stdc=no |
04cabffc | 5159 | fi |
5213506e | 5160 | rm -f conftest* |
04cabffc | 5161 | |
414d23ae | 5162 | fi |
ba479fd2 | 5163 | |
5213506e RW |
5164 | if test $ac_cv_header_stdc = yes; then |
5165 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
5166 | if test "$cross_compiling" = yes; then : | |
5167 | : | |
b61ff9c8 | 5168 | else |
5213506e | 5169 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
bf3b7cd3 | 5170 | /* end confdefs.h. */ |
5213506e | 5171 | #include <ctype.h> |
bf3b7cd3 | 5172 | #include <stdlib.h> |
5213506e RW |
5173 | #if ((' ' & 0x0FF) == 0x020) |
5174 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
5175 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
5176 | #else | |
5177 | # define ISLOWER(c) \ | |
5178 | (('a' <= (c) && (c) <= 'i') \ | |
5179 | || ('j' <= (c) && (c) <= 'r') \ | |
5180 | || ('s' <= (c) && (c) <= 'z')) | |
5181 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
5182 | #endif | |
5183 | ||
5184 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
bf3b7cd3 JD |
5185 | int |
5186 | main () | |
5187 | { | |
5213506e RW |
5188 | int i; |
5189 | for (i = 0; i < 256; i++) | |
5190 | if (XOR (islower (i), ISLOWER (i)) | |
5191 | || toupper (i) != TOUPPER (i)) | |
5192 | return 2; | |
bf3b7cd3 JD |
5193 | return 0; |
5194 | } | |
5195 | _ACEOF | |
5213506e | 5196 | if ac_fn_c_try_run "$LINENO"; then : |
75e93faa | 5197 | |
5213506e RW |
5198 | else |
5199 | ac_cv_header_stdc=no | |
b61ff9c8 | 5200 | fi |
5213506e RW |
5201 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
5202 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
bf3b7cd3 | 5203 | fi |
5213506e | 5204 | |
bf3b7cd3 | 5205 | fi |
bf3b7cd3 | 5206 | fi |
5213506e RW |
5207 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
5208 | $as_echo "$ac_cv_header_stdc" >&6; } | |
5209 | if test $ac_cv_header_stdc = yes; then | |
5210 | ||
5211 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h | |
5212 | ||
b61ff9c8 | 5213 | fi |
5213506e RW |
5214 | |
5215 | # On IRIX 5.3, sys/types and inttypes.h are conflicting. | |
5216 | for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ | |
5217 | inttypes.h stdint.h unistd.h | |
5218 | do : | |
5219 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
5220 | ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default | |
5221 | " | |
5222 | eval as_val=\$$as_ac_Header | |
5223 | if test "x$as_val" = x""yes; then : | |
5224 | cat >>confdefs.h <<_ACEOF | |
5225 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 | |
ba479fd2 | 5226 | _ACEOF |
414d23ae | 5227 | |
5213506e RW |
5228 | fi |
5229 | ||
5230 | done | |
5231 | ||
5232 | ||
cafe096b | 5233 | |
5213506e RW |
5234 | ac_fn_c_check_header_mongrel "$LINENO" "minix/config.h" "ac_cv_header_minix_config_h" "$ac_includes_default" |
5235 | if test "x$ac_cv_header_minix_config_h" = x""yes; then : | |
5236 | MINIX=yes | |
5237 | else | |
5238 | MINIX= | |
414d23ae HPN |
5239 | fi |
5240 | ||
5213506e RW |
5241 | |
5242 | if test "$MINIX" = yes; then | |
5243 | ||
5244 | $as_echo "#define _POSIX_SOURCE 1" >>confdefs.h | |
5245 | ||
5246 | ||
5247 | $as_echo "#define _POSIX_1_SOURCE 2" >>confdefs.h | |
5248 | ||
5249 | ||
5250 | $as_echo "#define _MINIX 1" >>confdefs.h | |
5251 | ||
5252 | fi | |
5253 | ||
5254 | ||
5255 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether it is safe to define __EXTENSIONS__" >&5 | |
5256 | $as_echo_n "checking whether it is safe to define __EXTENSIONS__... " >&6; } | |
5257 | if test "${ac_cv_safe_to_define___extensions__+set}" = set; then : | |
5258 | $as_echo_n "(cached) " >&6 | |
b5472e1d | 5259 | else |
5213506e | 5260 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
b5472e1d | 5261 | /* end confdefs.h. */ |
5213506e RW |
5262 | |
5263 | # define __EXTENSIONS__ 1 | |
5264 | $ac_includes_default | |
3bbd5a19 PB |
5265 | int |
5266 | main () | |
5267 | { | |
5213506e | 5268 | |
3bbd5a19 PB |
5269 | ; |
5270 | return 0; | |
5271 | } | |
b5472e1d | 5272 | _ACEOF |
5213506e RW |
5273 | if ac_fn_c_try_compile "$LINENO"; then : |
5274 | ac_cv_safe_to_define___extensions__=yes | |
b5472e1d | 5275 | else |
5213506e | 5276 | ac_cv_safe_to_define___extensions__=no |
b5472e1d | 5277 | fi |
5213506e | 5278 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
3bbd5a19 | 5279 | fi |
5213506e RW |
5280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_safe_to_define___extensions__" >&5 |
5281 | $as_echo "$ac_cv_safe_to_define___extensions__" >&6; } | |
5282 | test $ac_cv_safe_to_define___extensions__ = yes && | |
5283 | $as_echo "#define __EXTENSIONS__ 1" >>confdefs.h | |
3bbd5a19 | 5284 | |
5213506e RW |
5285 | $as_echo "#define _ALL_SOURCE 1" >>confdefs.h |
5286 | ||
5287 | $as_echo "#define _GNU_SOURCE 1" >>confdefs.h | |
3bbd5a19 | 5288 | |
5213506e RW |
5289 | $as_echo "#define _POSIX_PTHREAD_SEMANTICS 1" >>confdefs.h |
5290 | ||
5291 | $as_echo "#define _TANDEM_SOURCE 1" >>confdefs.h | |
5292 | ||
5293 | ||
5294 | ac_ext=c | |
5295 | ac_cpp='$CPP $CPPFLAGS' | |
5296 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
5297 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
5298 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5299 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 | |
5300 | $as_echo_n "checking how to run the C preprocessor... " >&6; } | |
5301 | # On Suns, sometimes $CPP names a directory. | |
5302 | if test -n "$CPP" && test -d "$CPP"; then | |
5303 | CPP= | |
5304 | fi | |
5305 | if test -z "$CPP"; then | |
5306 | if test "${ac_cv_prog_CPP+set}" = set; then : | |
5307 | $as_echo_n "(cached) " >&6 | |
89a42ac8 | 5308 | else |
5213506e RW |
5309 | # Double quotes because CPP needs to be expanded |
5310 | for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" | |
5311 | do | |
5312 | ac_preproc_ok=false | |
5313 | for ac_c_preproc_warn_flag in '' yes | |
5314 | do | |
5315 | # Use a header file that comes with gcc, so configuring glibc | |
5316 | # with a fresh cross-compiler works. | |
5317 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
5318 | # <limits.h> exists even on freestanding compilers. | |
5319 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
5320 | # not just through cpp. "Syntax error" is here to catch this case. | |
5321 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
89a42ac8 | 5322 | /* end confdefs.h. */ |
5213506e RW |
5323 | #ifdef __STDC__ |
5324 | # include <limits.h> | |
5325 | #else | |
5326 | # include <assert.h> | |
5327 | #endif | |
5328 | Syntax error | |
89a42ac8 | 5329 | _ACEOF |
5213506e RW |
5330 | if ac_fn_c_try_cpp "$LINENO"; then : |
5331 | ||
89a42ac8 | 5332 | else |
5213506e RW |
5333 | # Broken: fails on valid input. |
5334 | continue | |
5335 | fi | |
5336 | rm -f conftest.err conftest.$ac_ext | |
89a42ac8 | 5337 | |
5213506e RW |
5338 | # OK, works on sane cases. Now check whether nonexistent headers |
5339 | # can be detected and how. | |
5340 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5341 | /* end confdefs.h. */ | |
5342 | #include <ac_nonexistent.h> | |
5343 | _ACEOF | |
5344 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5345 | # Broken: success on invalid input. | |
5346 | continue | |
5347 | else | |
5348 | # Passes both tests. | |
5349 | ac_preproc_ok=: | |
5350 | break | |
89a42ac8 | 5351 | fi |
5213506e RW |
5352 | rm -f conftest.err conftest.$ac_ext |
5353 | ||
5354 | done | |
5355 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
5356 | rm -f conftest.err conftest.$ac_ext | |
5357 | if $ac_preproc_ok; then : | |
5358 | break | |
34a86c2b NN |
5359 | fi |
5360 | ||
5213506e RW |
5361 | done |
5362 | ac_cv_prog_CPP=$CPP | |
5363 | ||
5364 | fi | |
5365 | CPP=$ac_cv_prog_CPP | |
643d3bd2 | 5366 | else |
5213506e RW |
5367 | ac_cv_prog_CPP=$CPP |
5368 | fi | |
5369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 | |
5370 | $as_echo "$CPP" >&6; } | |
5371 | ac_preproc_ok=false | |
5372 | for ac_c_preproc_warn_flag in '' yes | |
5373 | do | |
5374 | # Use a header file that comes with gcc, so configuring glibc | |
5375 | # with a fresh cross-compiler works. | |
5376 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
5377 | # <limits.h> exists even on freestanding compilers. | |
5378 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
5379 | # not just through cpp. "Syntax error" is here to catch this case. | |
5380 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
643d3bd2 | 5381 | /* end confdefs.h. */ |
5213506e RW |
5382 | #ifdef __STDC__ |
5383 | # include <limits.h> | |
5384 | #else | |
5385 | # include <assert.h> | |
5386 | #endif | |
5387 | Syntax error | |
00020c16 | 5388 | _ACEOF |
5213506e | 5389 | if ac_fn_c_try_cpp "$LINENO"; then : |
3bbd5a19 | 5390 | |
643d3bd2 | 5391 | else |
5213506e RW |
5392 | # Broken: fails on valid input. |
5393 | continue | |
5394 | fi | |
5395 | rm -f conftest.err conftest.$ac_ext | |
643d3bd2 | 5396 | |
5213506e RW |
5397 | # OK, works on sane cases. Now check whether nonexistent headers |
5398 | # can be detected and how. | |
5399 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5400 | /* end confdefs.h. */ | |
5401 | #include <ac_nonexistent.h> | |
5402 | _ACEOF | |
5403 | if ac_fn_c_try_cpp "$LINENO"; then : | |
5404 | # Broken: success on invalid input. | |
5405 | continue | |
5406 | else | |
5407 | # Passes both tests. | |
5408 | ac_preproc_ok=: | |
5409 | break | |
643d3bd2 | 5410 | fi |
5213506e RW |
5411 | rm -f conftest.err conftest.$ac_ext |
5412 | ||
5413 | done | |
5414 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
5415 | rm -f conftest.err conftest.$ac_ext | |
5416 | if $ac_preproc_ok; then : | |
5417 | ||
09a9c095 | 5418 | else |
5213506e RW |
5419 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 |
5420 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5421 | as_fn_error "C preprocessor \"$CPP\" fails sanity check | |
5422 | See \`config.log' for more details." "$LINENO" 5; } | |
5423 | fi | |
373477bb | 5424 | |
5213506e RW |
5425 | ac_ext=c |
5426 | ac_cpp='$CPP $CPPFLAGS' | |
5427 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
5428 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
5429 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
5430 | ||
5431 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5 | |
5432 | $as_echo_n "checking for inline... " >&6; } | |
5433 | if test "${ac_cv_c_inline+set}" = set; then : | |
5434 | $as_echo_n "(cached) " >&6 | |
5435 | else | |
5436 | ac_cv_c_inline=no | |
5437 | for ac_kw in inline __inline__ __inline; do | |
5438 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
00020c16 | 5439 | /* end confdefs.h. */ |
5213506e RW |
5440 | #ifndef __cplusplus |
5441 | typedef int foo_t; | |
5442 | static $ac_kw foo_t static_foo () {return 0; } | |
5443 | $ac_kw foo_t foo () {return 0; } | |
5444 | #endif | |
373477bb | 5445 | |
00020c16 | 5446 | _ACEOF |
5213506e RW |
5447 | if ac_fn_c_try_compile "$LINENO"; then : |
5448 | ac_cv_c_inline=$ac_kw | |
5449 | fi | |
5450 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5451 | test "$ac_cv_c_inline" != no && break | |
5452 | done | |
5453 | ||
5454 | fi | |
5455 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5 | |
5456 | $as_echo "$ac_cv_c_inline" >&6; } | |
5457 | ||
5458 | case $ac_cv_c_inline in | |
5459 | inline | yes) ;; | |
5460 | *) | |
5461 | case $ac_cv_c_inline in | |
5462 | no) ac_val=;; | |
5463 | *) ac_val=$ac_cv_c_inline;; | |
5464 | esac | |
5465 | cat >>confdefs.h <<_ACEOF | |
5466 | #ifndef __cplusplus | |
5467 | #define inline $ac_val | |
5468 | #endif | |
00020c16 | 5469 | _ACEOF |
5213506e RW |
5470 | ;; |
5471 | esac | |
5472 | ||
5473 | ||
5474 | # sizeof(char) is 1 by definition. | |
5475 | # The cast to long int works around a bug in the HP C Compiler | |
5476 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5477 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5478 | # This bug is HP SR number 8606223364. | |
5479 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of void *" >&5 | |
5480 | $as_echo_n "checking size of void *... " >&6; } | |
5481 | if test "${ac_cv_sizeof_void_p+set}" = set; then : | |
5482 | $as_echo_n "(cached) " >&6 | |
5483 | else | |
5484 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (void *))" "ac_cv_sizeof_void_p" "$ac_includes_default"; then : | |
5485 | ||
5486 | else | |
5487 | if test "$ac_cv_type_void_p" = yes; then | |
5488 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5489 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5490 | { as_fn_set_status 77 | |
5491 | as_fn_error "cannot compute sizeof (void *) | |
5492 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5493 | else | |
5494 | ac_cv_sizeof_void_p=0 | |
5495 | fi | |
5496 | fi | |
5497 | ||
5498 | fi | |
5499 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_void_p" >&5 | |
5500 | $as_echo "$ac_cv_sizeof_void_p" >&6; } | |
414d23ae | 5501 | |
5213506e RW |
5502 | |
5503 | ||
5504 | cat >>confdefs.h <<_ACEOF | |
5505 | #define SIZEOF_VOID_P $ac_cv_sizeof_void_p | |
00020c16 | 5506 | _ACEOF |
5213506e RW |
5507 | |
5508 | ||
5509 | # The cast to long int works around a bug in the HP C Compiler | |
5510 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5511 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5512 | # This bug is HP SR number 8606223364. | |
5513 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short" >&5 | |
5514 | $as_echo_n "checking size of short... " >&6; } | |
5515 | if test "${ac_cv_sizeof_short+set}" = set; then : | |
5516 | $as_echo_n "(cached) " >&6 | |
00020c16 | 5517 | else |
5213506e RW |
5518 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short))" "ac_cv_sizeof_short" "$ac_includes_default"; then : |
5519 | ||
5520 | else | |
5521 | if test "$ac_cv_type_short" = yes; then | |
5522 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5523 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5524 | { as_fn_set_status 77 | |
5525 | as_fn_error "cannot compute sizeof (short) | |
5526 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5527 | else | |
5528 | ac_cv_sizeof_short=0 | |
5529 | fi | |
5530 | fi | |
414d23ae | 5531 | |
a1286ef5 | 5532 | fi |
5213506e RW |
5533 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short" >&5 |
5534 | $as_echo "$ac_cv_sizeof_short" >&6; } | |
5535 | ||
5536 | ||
5537 | ||
5538 | cat >>confdefs.h <<_ACEOF | |
5539 | #define SIZEOF_SHORT $ac_cv_sizeof_short | |
5540 | _ACEOF | |
5541 | ||
5542 | ||
5543 | # The cast to long int works around a bug in the HP C Compiler | |
5544 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5545 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5546 | # This bug is HP SR number 8606223364. | |
5547 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5 | |
5548 | $as_echo_n "checking size of int... " >&6; } | |
5549 | if test "${ac_cv_sizeof_int+set}" = set; then : | |
5550 | $as_echo_n "(cached) " >&6 | |
e1bbfc5c | 5551 | else |
5213506e | 5552 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int" "$ac_includes_default"; then : |
e1bbfc5c | 5553 | |
5213506e RW |
5554 | else |
5555 | if test "$ac_cv_type_int" = yes; then | |
5556 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5557 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5558 | { as_fn_set_status 77 | |
5559 | as_fn_error "cannot compute sizeof (int) | |
5560 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5561 | else | |
5562 | ac_cv_sizeof_int=0 | |
5563 | fi | |
e1bbfc5c | 5564 | fi |
5213506e | 5565 | |
ba479fd2 | 5566 | fi |
5213506e RW |
5567 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5 |
5568 | $as_echo "$ac_cv_sizeof_int" >&6; } | |
00020c16 | 5569 | |
5213506e RW |
5570 | |
5571 | ||
5572 | cat >>confdefs.h <<_ACEOF | |
5573 | #define SIZEOF_INT $ac_cv_sizeof_int | |
ba479fd2 | 5574 | _ACEOF |
5213506e RW |
5575 | |
5576 | ||
5577 | # The cast to long int works around a bug in the HP C Compiler | |
5578 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5579 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5580 | # This bug is HP SR number 8606223364. | |
5581 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long" >&5 | |
5582 | $as_echo_n "checking size of long... " >&6; } | |
5583 | if test "${ac_cv_sizeof_long+set}" = set; then : | |
5584 | $as_echo_n "(cached) " >&6 | |
ba479fd2 | 5585 | else |
5213506e | 5586 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long))" "ac_cv_sizeof_long" "$ac_includes_default"; then : |
ba479fd2 | 5587 | |
00020c16 | 5588 | else |
5213506e RW |
5589 | if test "$ac_cv_type_long" = yes; then |
5590 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5591 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5592 | { as_fn_set_status 77 | |
5593 | as_fn_error "cannot compute sizeof (long) | |
5594 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5595 | else | |
5596 | ac_cv_sizeof_long=0 | |
5597 | fi | |
5598 | fi | |
5599 | ||
5600 | fi | |
5601 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long" >&5 | |
5602 | $as_echo "$ac_cv_sizeof_long" >&6; } | |
5603 | ||
5604 | ||
5605 | ||
5606 | cat >>confdefs.h <<_ACEOF | |
5607 | #define SIZEOF_LONG $ac_cv_sizeof_long | |
ba479fd2 | 5608 | _ACEOF |
00020c16 | 5609 | |
00020c16 | 5610 | |
5213506e RW |
5611 | ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default" |
5612 | if test "x$ac_cv_type_long_long" = x""yes; then : | |
5613 | ||
5614 | cat >>confdefs.h <<_ACEOF | |
5615 | #define HAVE_LONG_LONG 1 | |
ba479fd2 | 5616 | _ACEOF |
5213506e RW |
5617 | |
5618 | # The cast to long int works around a bug in the HP C Compiler | |
5619 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5620 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5621 | # This bug is HP SR number 8606223364. | |
5622 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long" >&5 | |
5623 | $as_echo_n "checking size of long long... " >&6; } | |
5624 | if test "${ac_cv_sizeof_long_long+set}" = set; then : | |
5625 | $as_echo_n "(cached) " >&6 | |
b61ff9c8 | 5626 | else |
5213506e | 5627 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long))" "ac_cv_sizeof_long_long" "$ac_includes_default"; then : |
ba479fd2 | 5628 | |
5213506e RW |
5629 | else |
5630 | if test "$ac_cv_type_long_long" = yes; then | |
5631 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5632 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5633 | { as_fn_set_status 77 | |
5634 | as_fn_error "cannot compute sizeof (long long) | |
5635 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5636 | else | |
5637 | ac_cv_sizeof_long_long=0 | |
5638 | fi | |
ba479fd2 | 5639 | fi |
5213506e | 5640 | |
6938ec6c | 5641 | fi |
5213506e RW |
5642 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long" >&5 |
5643 | $as_echo "$ac_cv_sizeof_long_long" >&6; } | |
5644 | ||
5645 | ||
5646 | ||
5647 | cat >>confdefs.h <<_ACEOF | |
5648 | #define SIZEOF_LONG_LONG $ac_cv_sizeof_long_long | |
5649 | _ACEOF | |
5650 | ||
5651 | ||
6e3f3080 | 5652 | fi |
5213506e RW |
5653 | |
5654 | ac_fn_c_check_type "$LINENO" "__int64" "ac_cv_type___int64" "$ac_includes_default" | |
5655 | if test "x$ac_cv_type___int64" = x""yes; then : | |
5656 | ||
5657 | cat >>confdefs.h <<_ACEOF | |
5658 | #define HAVE___INT64 1 | |
5659 | _ACEOF | |
5660 | ||
5661 | # The cast to long int works around a bug in the HP C Compiler | |
5662 | # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects | |
5663 | # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. | |
5664 | # This bug is HP SR number 8606223364. | |
5665 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of __int64" >&5 | |
5666 | $as_echo_n "checking size of __int64... " >&6; } | |
5667 | if test "${ac_cv_sizeof___int64+set}" = set; then : | |
5668 | $as_echo_n "(cached) " >&6 | |
5669 | else | |
5670 | if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (__int64))" "ac_cv_sizeof___int64" "$ac_includes_default"; then : | |
5671 | ||
6938ec6c | 5672 | else |
5213506e RW |
5673 | if test "$ac_cv_type___int64" = yes; then |
5674 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
5675 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
5676 | { as_fn_set_status 77 | |
5677 | as_fn_error "cannot compute sizeof (__int64) | |
5678 | See \`config.log' for more details." "$LINENO" 5; }; } | |
5679 | else | |
5680 | ac_cv_sizeof___int64=0 | |
5681 | fi | |
6938ec6c | 5682 | fi |
5213506e | 5683 | |
00020c16 | 5684 | fi |
5213506e RW |
5685 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof___int64" >&5 |
5686 | $as_echo "$ac_cv_sizeof___int64" >&6; } | |
5687 | ||
5688 | ||
5689 | ||
00020c16 ILT |
5690 | cat >>confdefs.h <<_ACEOF |
5691 | #define SIZEOF___INT64 $ac_cv_sizeof___int64 | |
5692 | _ACEOF | |
6938ec6c NN |
5693 | |
5694 | ||
00020c16 | 5695 | fi |
ba479fd2 | 5696 | |
fa802374 KT |
5697 | ac_fn_c_find_intX_t "$LINENO" "8" "ac_cv_c_int8_t" |
5698 | case $ac_cv_c_int8_t in #( | |
5699 | no|yes) ;; #( | |
5700 | *) | |
5701 | ||
5702 | cat >>confdefs.h <<_ACEOF | |
5703 | #define int8_t $ac_cv_c_int8_t | |
5704 | _ACEOF | |
5705 | ;; | |
5706 | esac | |
5707 | ||
5708 | ac_fn_c_find_intX_t "$LINENO" "16" "ac_cv_c_int16_t" | |
5709 | case $ac_cv_c_int16_t in #( | |
5710 | no|yes) ;; #( | |
5711 | *) | |
5712 | ||
5713 | cat >>confdefs.h <<_ACEOF | |
5714 | #define int16_t $ac_cv_c_int16_t | |
5715 | _ACEOF | |
5716 | ;; | |
5717 | esac | |
5718 | ||
5719 | ac_fn_c_find_intX_t "$LINENO" "32" "ac_cv_c_int32_t" | |
5720 | case $ac_cv_c_int32_t in #( | |
5721 | no|yes) ;; #( | |
5722 | *) | |
5723 | ||
5724 | cat >>confdefs.h <<_ACEOF | |
5725 | #define int32_t $ac_cv_c_int32_t | |
5726 | _ACEOF | |
5727 | ;; | |
5728 | esac | |
5729 | ||
5730 | ac_fn_c_find_intX_t "$LINENO" "64" "ac_cv_c_int64_t" | |
5731 | case $ac_cv_c_int64_t in #( | |
5732 | no|yes) ;; #( | |
5733 | *) | |
5734 | ||
5735 | cat >>confdefs.h <<_ACEOF | |
5736 | #define int64_t $ac_cv_c_int64_t | |
5737 | _ACEOF | |
5738 | ;; | |
5739 | esac | |
5740 | ||
5741 | ||
5742 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for long long int" >&5 | |
5743 | $as_echo_n "checking for long long int... " >&6; } | |
5744 | if test "${ac_cv_type_long_long_int+set}" = set; then : | |
5745 | $as_echo_n "(cached) " >&6 | |
5746 | else | |
5747 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5748 | /* end confdefs.h. */ | |
5749 | ||
5750 | /* For now, do not test the preprocessor; as of 2007 there are too many | |
5751 | implementations with broken preprocessors. Perhaps this can | |
5752 | be revisited in 2012. In the meantime, code should not expect | |
5753 | #if to work with literals wider than 32 bits. */ | |
5754 | /* Test literals. */ | |
5755 | long long int ll = 9223372036854775807ll; | |
5756 | long long int nll = -9223372036854775807LL; | |
5757 | unsigned long long int ull = 18446744073709551615ULL; | |
5758 | /* Test constant expressions. */ | |
5759 | typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) | |
5760 | ? 1 : -1)]; | |
5761 | typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 | |
5762 | ? 1 : -1)]; | |
5763 | int i = 63; | |
5764 | int | |
5765 | main () | |
5766 | { | |
5767 | /* Test availability of runtime routines for shift and division. */ | |
5768 | long long int llmax = 9223372036854775807ll; | |
5769 | unsigned long long int ullmax = 18446744073709551615ull; | |
5770 | return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) | |
5771 | | (llmax / ll) | (llmax % ll) | |
5772 | | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) | |
5773 | | (ullmax / ull) | (ullmax % ull)); | |
5774 | ; | |
5775 | return 0; | |
5776 | } | |
5777 | ||
5778 | _ACEOF | |
5779 | if ac_fn_c_try_link "$LINENO"; then : | |
5780 | if test "$cross_compiling" = yes; then : | |
5781 | ac_cv_type_long_long_int=yes | |
5782 | else | |
5783 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5784 | /* end confdefs.h. */ | |
5785 | #include <limits.h> | |
5786 | #ifndef LLONG_MAX | |
5787 | # define HALF \ | |
5788 | (1LL << (sizeof (long long int) * CHAR_BIT - 2)) | |
5789 | # define LLONG_MAX (HALF - 1 + HALF) | |
5790 | #endif | |
5791 | int | |
5792 | main () | |
5793 | { | |
5794 | long long int n = 1; | |
5795 | int i; | |
5796 | for (i = 0; ; i++) | |
5797 | { | |
5798 | long long int m = n << i; | |
5799 | if (m >> i != n) | |
5800 | return 1; | |
5801 | if (LLONG_MAX / 2 < m) | |
5802 | break; | |
5803 | } | |
5804 | return 0; | |
5805 | ; | |
5806 | return 0; | |
5807 | } | |
5808 | _ACEOF | |
5809 | if ac_fn_c_try_run "$LINENO"; then : | |
5810 | ac_cv_type_long_long_int=yes | |
5811 | else | |
5812 | ac_cv_type_long_long_int=no | |
5813 | fi | |
5814 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ | |
5815 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
5816 | fi | |
5817 | ||
5818 | else | |
5819 | ac_cv_type_long_long_int=no | |
5820 | fi | |
5821 | rm -f core conftest.err conftest.$ac_objext \ | |
5822 | conftest$ac_exeext conftest.$ac_ext | |
5823 | fi | |
5824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_long_long_int" >&5 | |
5825 | $as_echo "$ac_cv_type_long_long_int" >&6; } | |
5826 | if test $ac_cv_type_long_long_int = yes; then | |
5827 | ||
5828 | $as_echo "#define HAVE_LONG_LONG_INT 1" >>confdefs.h | |
5829 | ||
5830 | fi | |
5831 | ||
5832 | ||
5833 | ||
5834 | ac_fn_c_check_type "$LINENO" "intmax_t" "ac_cv_type_intmax_t" "$ac_includes_default" | |
5835 | if test "x$ac_cv_type_intmax_t" = x""yes; then : | |
5836 | ||
5837 | $as_echo "#define HAVE_INTMAX_T 1" >>confdefs.h | |
5838 | ||
5839 | else | |
5840 | test $ac_cv_type_long_long_int = yes \ | |
5841 | && ac_type='long long int' \ | |
5842 | || ac_type='long int' | |
5843 | ||
5844 | cat >>confdefs.h <<_ACEOF | |
5845 | #define intmax_t $ac_type | |
5846 | _ACEOF | |
5847 | ||
5848 | fi | |
5849 | ||
5850 | ||
5851 | ||
5852 | ac_fn_c_check_type "$LINENO" "intptr_t" "ac_cv_type_intptr_t" "$ac_includes_default" | |
5853 | if test "x$ac_cv_type_intptr_t" = x""yes; then : | |
5854 | ||
5855 | $as_echo "#define HAVE_INTPTR_T 1" >>confdefs.h | |
5856 | ||
5857 | else | |
5858 | for ac_type in 'int' 'long int' 'long long int'; do | |
5859 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5860 | /* end confdefs.h. */ | |
5861 | $ac_includes_default | |
5862 | int | |
5863 | main () | |
5864 | { | |
5865 | static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; | |
5866 | test_array [0] = 0 | |
5867 | ||
5868 | ; | |
5869 | return 0; | |
5870 | } | |
5871 | _ACEOF | |
5872 | if ac_fn_c_try_compile "$LINENO"; then : | |
5873 | ||
5874 | cat >>confdefs.h <<_ACEOF | |
5875 | #define intptr_t $ac_type | |
5876 | _ACEOF | |
5877 | ||
5878 | ac_type= | |
5879 | fi | |
5880 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
5881 | test -z "$ac_type" && break | |
5882 | done | |
5883 | fi | |
5884 | ||
5885 | ||
5886 | ac_fn_c_find_uintX_t "$LINENO" "8" "ac_cv_c_uint8_t" | |
5887 | case $ac_cv_c_uint8_t in #( | |
5888 | no|yes) ;; #( | |
5889 | *) | |
5890 | ||
5891 | $as_echo "#define _UINT8_T 1" >>confdefs.h | |
5892 | ||
5893 | ||
5894 | cat >>confdefs.h <<_ACEOF | |
5895 | #define uint8_t $ac_cv_c_uint8_t | |
5896 | _ACEOF | |
5897 | ;; | |
5898 | esac | |
5899 | ||
5900 | ac_fn_c_find_uintX_t "$LINENO" "16" "ac_cv_c_uint16_t" | |
5901 | case $ac_cv_c_uint16_t in #( | |
5902 | no|yes) ;; #( | |
5903 | *) | |
5904 | ||
5905 | ||
5906 | cat >>confdefs.h <<_ACEOF | |
5907 | #define uint16_t $ac_cv_c_uint16_t | |
5908 | _ACEOF | |
5909 | ;; | |
5910 | esac | |
5911 | ||
5912 | ac_fn_c_find_uintX_t "$LINENO" "32" "ac_cv_c_uint32_t" | |
5913 | case $ac_cv_c_uint32_t in #( | |
5914 | no|yes) ;; #( | |
5915 | *) | |
5916 | ||
5917 | $as_echo "#define _UINT32_T 1" >>confdefs.h | |
5918 | ||
5919 | ||
5920 | cat >>confdefs.h <<_ACEOF | |
5921 | #define uint32_t $ac_cv_c_uint32_t | |
5922 | _ACEOF | |
5923 | ;; | |
5924 | esac | |
5925 | ||
5926 | ac_fn_c_find_uintX_t "$LINENO" "64" "ac_cv_c_uint64_t" | |
5927 | case $ac_cv_c_uint64_t in #( | |
5928 | no|yes) ;; #( | |
5929 | *) | |
5930 | ||
5931 | $as_echo "#define _UINT64_T 1" >>confdefs.h | |
5932 | ||
5933 | ||
5934 | cat >>confdefs.h <<_ACEOF | |
5935 | #define uint64_t $ac_cv_c_uint64_t | |
5936 | _ACEOF | |
5937 | ;; | |
5938 | esac | |
5939 | ||
5940 | ||
5941 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for unsigned long long int" >&5 | |
5942 | $as_echo_n "checking for unsigned long long int... " >&6; } | |
5943 | if test "${ac_cv_type_unsigned_long_long_int+set}" = set; then : | |
5944 | $as_echo_n "(cached) " >&6 | |
5945 | else | |
5946 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
5947 | /* end confdefs.h. */ | |
5948 | ||
5949 | /* For now, do not test the preprocessor; as of 2007 there are too many | |
5950 | implementations with broken preprocessors. Perhaps this can | |
5951 | be revisited in 2012. In the meantime, code should not expect | |
5952 | #if to work with literals wider than 32 bits. */ | |
5953 | /* Test literals. */ | |
5954 | long long int ll = 9223372036854775807ll; | |
5955 | long long int nll = -9223372036854775807LL; | |
5956 | unsigned long long int ull = 18446744073709551615ULL; | |
5957 | /* Test constant expressions. */ | |
5958 | typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll) | |
5959 | ? 1 : -1)]; | |
5960 | typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1 | |
5961 | ? 1 : -1)]; | |
5962 | int i = 63; | |
5963 | int | |
5964 | main () | |
5965 | { | |
5966 | /* Test availability of runtime routines for shift and division. */ | |
5967 | long long int llmax = 9223372036854775807ll; | |
5968 | unsigned long long int ullmax = 18446744073709551615ull; | |
5969 | return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i) | |
5970 | | (llmax / ll) | (llmax % ll) | |
5971 | | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i) | |
5972 | | (ullmax / ull) | (ullmax % ull)); | |
5973 | ; | |
5974 | return 0; | |
5975 | } | |
5976 | ||
5977 | _ACEOF | |
5978 | if ac_fn_c_try_link "$LINENO"; then : | |
5979 | ac_cv_type_unsigned_long_long_int=yes | |
5980 | else | |
5981 | ac_cv_type_unsigned_long_long_int=no | |
5982 | fi | |
5983 | rm -f core conftest.err conftest.$ac_objext \ | |
5984 | conftest$ac_exeext conftest.$ac_ext | |
5985 | fi | |
5986 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_type_unsigned_long_long_int" >&5 | |
5987 | $as_echo "$ac_cv_type_unsigned_long_long_int" >&6; } | |
5988 | if test $ac_cv_type_unsigned_long_long_int = yes; then | |
5989 | ||
5990 | $as_echo "#define HAVE_UNSIGNED_LONG_LONG_INT 1" >>confdefs.h | |
5991 | ||
5992 | fi | |
5993 | ||
5994 | ||
5995 | ||
5996 | ac_fn_c_check_type "$LINENO" "uintmax_t" "ac_cv_type_uintmax_t" "$ac_includes_default" | |
5997 | if test "x$ac_cv_type_uintmax_t" = x""yes; then : | |
5998 | ||
5999 | $as_echo "#define HAVE_UINTMAX_T 1" >>confdefs.h | |
6000 | ||
6001 | else | |
6002 | test $ac_cv_type_unsigned_long_long_int = yes \ | |
6003 | && ac_type='unsigned long long int' \ | |
6004 | || ac_type='unsigned long int' | |
6005 | ||
6006 | cat >>confdefs.h <<_ACEOF | |
6007 | #define uintmax_t $ac_type | |
6008 | _ACEOF | |
6009 | ||
6010 | fi | |
6011 | ||
6012 | ||
6013 | ||
6014 | ac_fn_c_check_type "$LINENO" "uintptr_t" "ac_cv_type_uintptr_t" "$ac_includes_default" | |
6015 | if test "x$ac_cv_type_uintptr_t" = x""yes; then : | |
6016 | ||
6017 | $as_echo "#define HAVE_UINTPTR_T 1" >>confdefs.h | |
6018 | ||
6019 | else | |
6020 | for ac_type in 'unsigned int' 'unsigned long int' \ | |
6021 | 'unsigned long long int'; do | |
6022 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
6023 | /* end confdefs.h. */ | |
6024 | $ac_includes_default | |
6025 | int | |
6026 | main () | |
6027 | { | |
6028 | static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))]; | |
6029 | test_array [0] = 0 | |
6030 | ||
6031 | ; | |
6032 | return 0; | |
6033 | } | |
6034 | _ACEOF | |
6035 | if ac_fn_c_try_compile "$LINENO"; then : | |
6036 | ||
6037 | cat >>confdefs.h <<_ACEOF | |
6038 | #define uintptr_t $ac_type | |
6039 | _ACEOF | |
6040 | ||
6041 | ac_type= | |
6042 | fi | |
6043 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
6044 | test -z "$ac_type" && break | |
6045 | done | |
6046 | fi | |
6047 | ||
6048 | ||
6049 | ||
6050 | ||
6051 | ||
6052 | ||
6053 | ||
6054 | ||
6055 | ||
6056 | ||
6057 | ||
6058 | ||
6059 | ||
6060 | ||
00020c16 ILT |
6061 | |
6062 | # --------------------- | |
6063 | # Warnings and checking | |
6064 | # --------------------- | |
6065 | ||
6066 | # Check $CC warning features (if it's GCC). | |
6067 | # We want to use -pedantic, but we don't want warnings about | |
6068 | # * 'long long' | |
6069 | # * variadic macros | |
6070 | # * overlong strings | |
6071 | # So, we only use -pedantic if we can disable those warnings. | |
6072 | ||
6073 | loose_warn= | |
6074 | save_CFLAGS="$CFLAGS" | |
6075 | for option in -W -Wall -Wwrite-strings -Wcast-qual; do | |
5213506e | 6076 | as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh` |
00020c16 | 6077 | |
5213506e RW |
6078 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5 |
6079 | $as_echo_n "checking whether $CC supports $option... " >&6; } | |
6080 | if { as_var=$as_acx_Woption; eval "test \"\${$as_var+set}\" = set"; }; then : | |
6081 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
6082 | else |
6083 | CFLAGS="$option" | |
5213506e | 6084 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 6085 | /* end confdefs.h. */ |
00020c16 ILT |
6086 | |
6087 | int | |
6088 | main () | |
6089 | { | |
6090 | ||
6091 | ; | |
6092 | return 0; | |
6093 | } | |
ba479fd2 | 6094 | _ACEOF |
5213506e | 6095 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 | 6096 | eval "$as_acx_Woption=yes" |
a207b594 | 6097 | else |
5213506e | 6098 | eval "$as_acx_Woption=no" |
a207b594 | 6099 | fi |
5213506e | 6100 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
00020c16 ILT |
6101 | |
6102 | fi | |
5213506e RW |
6103 | eval ac_res=\$$as_acx_Woption |
6104 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
6105 | $as_echo "$ac_res" >&6; } | |
6106 | if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then : | |
00020c16 ILT |
6107 | loose_warn="$loose_warn${loose_warn:+ }$option" |
6108 | fi | |
00020c16 ILT |
6109 | done |
6110 | CFLAGS="$save_CFLAGS" | |
6111 | ||
6112 | c_loose_warn= | |
6113 | save_CFLAGS="$CFLAGS" | |
6114 | for option in -Wstrict-prototypes -Wmissing-prototypes; do | |
5213506e | 6115 | as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh` |
00020c16 | 6116 | |
5213506e RW |
6117 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5 |
6118 | $as_echo_n "checking whether $CC supports $option... " >&6; } | |
6119 | if { as_var=$as_acx_Woption; eval "test \"\${$as_var+set}\" = set"; }; then : | |
6120 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
6121 | else |
6122 | CFLAGS="$option" | |
5213506e | 6123 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 6124 | /* end confdefs.h. */ |
00020c16 ILT |
6125 | |
6126 | int | |
6127 | main () | |
6128 | { | |
6129 | ||
6130 | ; | |
6131 | return 0; | |
6132 | } | |
ba479fd2 | 6133 | _ACEOF |
5213506e | 6134 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 | 6135 | eval "$as_acx_Woption=yes" |
14011ca4 | 6136 | else |
5213506e | 6137 | eval "$as_acx_Woption=no" |
cafe096b | 6138 | fi |
5213506e | 6139 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ba479fd2 | 6140 | |
56694dd9 | 6141 | fi |
5213506e RW |
6142 | eval ac_res=\$$as_acx_Woption |
6143 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
6144 | $as_echo "$ac_res" >&6; } | |
6145 | if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then : | |
00020c16 | 6146 | c_loose_warn="$c_loose_warn${c_loose_warn:+ }$option" |
56694dd9 | 6147 | fi |
00020c16 ILT |
6148 | done |
6149 | CFLAGS="$save_CFLAGS" | |
6150 | ||
6151 | strict_warn= | |
6152 | save_CFLAGS="$CFLAGS" | |
6153 | for option in -Wmissing-format-attribute; do | |
5213506e | 6154 | as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh` |
00020c16 | 6155 | |
5213506e RW |
6156 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5 |
6157 | $as_echo_n "checking whether $CC supports $option... " >&6; } | |
6158 | if { as_var=$as_acx_Woption; eval "test \"\${$as_var+set}\" = set"; }; then : | |
6159 | $as_echo_n "(cached) " >&6 | |
414d23ae | 6160 | else |
00020c16 | 6161 | CFLAGS="$option" |
5213506e | 6162 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
6163 | /* end confdefs.h. */ |
6164 | ||
6165 | int | |
6166 | main () | |
6167 | { | |
6168 | ||
6169 | ; | |
6170 | return 0; | |
6171 | } | |
6172 | _ACEOF | |
5213506e | 6173 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 | 6174 | eval "$as_acx_Woption=yes" |
414d23ae | 6175 | else |
5213506e | 6176 | eval "$as_acx_Woption=no" |
414d23ae | 6177 | fi |
5213506e | 6178 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
414d23ae | 6179 | |
00020c16 | 6180 | fi |
5213506e RW |
6181 | eval ac_res=\$$as_acx_Woption |
6182 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
6183 | $as_echo "$ac_res" >&6; } | |
6184 | if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then : | |
00020c16 ILT |
6185 | strict_warn="$strict_warn${strict_warn:+ }$option" |
6186 | fi | |
00020c16 ILT |
6187 | done |
6188 | CFLAGS="$save_CFLAGS" | |
75e93faa | 6189 | |
00020c16 ILT |
6190 | c_strict_warn= |
6191 | save_CFLAGS="$CFLAGS" | |
6192 | for option in -Wold-style-definition -Wc++-compat; do | |
5213506e | 6193 | as_acx_Woption=`$as_echo "acx_cv_prog_cc_warning_$option" | $as_tr_sh` |
ba479fd2 | 6194 | |
5213506e RW |
6195 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports $option" >&5 |
6196 | $as_echo_n "checking whether $CC supports $option... " >&6; } | |
6197 | if { as_var=$as_acx_Woption; eval "test \"\${$as_var+set}\" = set"; }; then : | |
6198 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
6199 | else |
6200 | CFLAGS="$option" | |
5213506e | 6201 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 | 6202 | /* end confdefs.h. */ |
a207b594 | 6203 | |
00020c16 ILT |
6204 | int |
6205 | main () | |
6206 | { | |
ba479fd2 | 6207 | |
00020c16 ILT |
6208 | ; |
6209 | return 0; | |
6210 | } | |
ba479fd2 | 6211 | _ACEOF |
5213506e | 6212 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 ILT |
6213 | eval "$as_acx_Woption=yes" |
6214 | else | |
5213506e | 6215 | eval "$as_acx_Woption=no" |
414d23ae | 6216 | fi |
5213506e | 6217 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
75e93faa | 6218 | |
00020c16 | 6219 | fi |
5213506e RW |
6220 | eval ac_res=\$$as_acx_Woption |
6221 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 | |
6222 | $as_echo "$ac_res" >&6; } | |
6223 | if test `eval 'as_val=${'$as_acx_Woption'};$as_echo "$as_val"'` = yes; then : | |
00020c16 ILT |
6224 | c_strict_warn="$c_strict_warn${c_strict_warn:+ }$option" |
6225 | fi | |
00020c16 ILT |
6226 | done |
6227 | CFLAGS="$save_CFLAGS" | |
75e93faa | 6228 | |
5213506e RW |
6229 | if test "$GCC" = yes; then : |
6230 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC supports -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings" >&5 | |
6231 | $as_echo_n "checking whether $CC supports -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings... " >&6; } | |
6232 | if test "${acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings+set}" = set; then : | |
6233 | $as_echo_n "(cached) " >&6 | |
75e93faa | 6234 | else |
00020c16 ILT |
6235 | save_CFLAGS="$CFLAGS" |
6236 | CFLAGS="-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings" | |
5213506e | 6237 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 | 6238 | /* end confdefs.h. */ |
2f41c1d6 | 6239 | |
00020c16 ILT |
6240 | int |
6241 | main () | |
6242 | { | |
b61ff9c8 | 6243 | |
00020c16 ILT |
6244 | ; |
6245 | return 0; | |
6246 | } | |
6247 | _ACEOF | |
5213506e | 6248 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 | 6249 | acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings=yes |
439a7e54 | 6250 | else |
5213506e | 6251 | acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings=no |
00020c16 | 6252 | fi |
5213506e | 6253 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
00020c16 ILT |
6254 | CFLAGS="$save_CFLAGS" |
6255 | fi | |
5213506e RW |
6256 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings" >&5 |
6257 | $as_echo "$acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings" >&6; } | |
6258 | if test $acx_cv_prog_cc_pedantic__Wno_long_long__Wno_variadic_macros__Wno_overlength_strings = yes; then : | |
00020c16 ILT |
6259 | strict_warn="$strict_warn${strict_warn:+ }-pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings" |
6260 | fi | |
ba479fd2 | 6261 | |
439a7e54 DN |
6262 | fi |
6263 | ||
5213506e RW |
6264 | # Check whether --enable-werror-always was given. |
6265 | if test "${enable_werror_always+set}" = set; then : | |
6266 | enableval=$enable_werror_always; | |
34a86c2b | 6267 | else |
00020c16 | 6268 | enable_werror_always=no |
00020c16 | 6269 | fi |
cafe096b | 6270 | |
5213506e RW |
6271 | if test $enable_werror_always = yes; then : |
6272 | strict_warn="$strict_warn${strict_warn:+ }-Werror" | |
6273 | fi | |
b61ff9c8 | 6274 | |
75e93faa | 6275 | |
34a86c2b | 6276 | |
00020c16 ILT |
6277 | # The above macros do nothing if the compiler is not GCC. However, the |
6278 | # Makefile has more goo to add other flags, so these variables are used | |
6279 | # to enable warnings only for GCC. | |
6280 | warn_cflags= | |
6281 | warn_cxxflags= | |
6282 | if test "x$GCC" = "xyes"; then | |
6283 | warn_cflags='$(GCC_WARN_CFLAGS)' | |
6284 | warn_cxxflags='$(GCC_WARN_CXXFLAGS)' | |
6285 | fi | |
75e93faa ZW |
6286 | |
6287 | ||
b61ff9c8 | 6288 | |
00020c16 ILT |
6289 | # Enable expensive internal checks |
6290 | is_release= | |
6291 | if test x"`cat $srcdir/DEV-PHASE`" != xexperimental; then | |
6292 | is_release=yes | |
6293 | fi | |
79b87c74 | 6294 | |
5213506e RW |
6295 | # Check whether --enable-checking was given. |
6296 | if test "${enable_checking+set}" = set; then : | |
6297 | enableval=$enable_checking; ac_checking_flags="${enableval}" | |
79b87c74 MM |
6298 | else |
6299 | ||
00020c16 ILT |
6300 | # Determine the default checks. |
6301 | if test x$is_release = x ; then | |
6302 | ac_checking_flags=yes | |
6303 | else | |
6304 | ac_checking_flags=release | |
6305 | fi | |
5213506e RW |
6306 | fi |
6307 | ||
00020c16 ILT |
6308 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="$IFS," |
6309 | for check in release $ac_checking_flags | |
6310 | do | |
6311 | case $check in | |
6312 | # these set all the flags to specific states | |
6313 | yes) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking= ; | |
6314 | ac_fold_checking= ; ac_gc_checking=1 ; | |
6315 | ac_gc_always_collect= ; ac_gimple_checking=1 ; ac_rtl_checking= ; | |
6316 | ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; | |
6317 | ac_tree_checking=1 ; ac_valgrind_checking= ; | |
6318 | ac_types_checking=1 ;; | |
6319 | no|none) ac_assert_checking= ; ac_checking= ; ac_df_checking= ; | |
6320 | ac_fold_checking= ; ac_gc_checking= ; | |
6321 | ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; | |
6322 | ac_rtlflag_checking= ; ac_runtime_checking= ; | |
6323 | ac_tree_checking= ; ac_valgrind_checking= ; | |
6324 | ac_types_checking= ;; | |
6325 | all) ac_assert_checking=1 ; ac_checking=1 ; ac_df_checking=1 ; | |
6326 | ac_fold_checking=1 ; ac_gc_checking=1 ; | |
6327 | ac_gc_always_collect=1 ; ac_gimple_checking=1 ; ac_rtl_checking=1 ; | |
6328 | ac_rtlflag_checking=1 ; ac_runtime_checking=1 ; | |
6329 | ac_tree_checking=1 ; ac_valgrind_checking= ; | |
6330 | ac_types_checking=1 ;; | |
6331 | release) ac_assert_checking=1 ; ac_checking= ; ac_df_checking= ; | |
6332 | ac_fold_checking= ; ac_gc_checking= ; | |
6333 | ac_gc_always_collect= ; ac_gimple_checking= ; ac_rtl_checking= ; | |
6334 | ac_rtlflag_checking= ; ac_runtime_checking=1 ; | |
6335 | ac_tree_checking= ; ac_valgrind_checking= ; | |
6336 | ac_types_checking= ;; | |
6337 | # these enable particular checks | |
6338 | assert) ac_assert_checking=1 ;; | |
6339 | df) ac_df_checking=1 ;; | |
6340 | fold) ac_fold_checking=1 ;; | |
6341 | gc) ac_gc_checking=1 ;; | |
6342 | gcac) ac_gc_always_collect=1 ;; | |
6343 | gimple) ac_gimple_checking=1 ;; | |
6344 | misc) ac_checking=1 ;; | |
6345 | rtl) ac_rtl_checking=1 ;; | |
6346 | rtlflag) ac_rtlflag_checking=1 ;; | |
6347 | runtime) ac_runtime_checking=1 ;; | |
6348 | tree) ac_tree_checking=1 ;; | |
6349 | types) ac_types_checking=1 ;; | |
6350 | valgrind) ac_valgrind_checking=1 ;; | |
5213506e | 6351 | *) as_fn_error "unknown check category $check" "$LINENO" 5 ;; |
00020c16 ILT |
6352 | esac |
6353 | done | |
6354 | IFS="$ac_save_IFS" | |
486aa804 | 6355 | |
00020c16 ILT |
6356 | nocommon_flag="" |
6357 | if test x$ac_checking != x ; then | |
79b87c74 | 6358 | |
5213506e | 6359 | $as_echo "#define ENABLE_CHECKING 1" >>confdefs.h |
79b87c74 | 6360 | |
00020c16 ILT |
6361 | nocommon_flag=-fno-common |
6362 | fi | |
79b87c74 | 6363 | |
00020c16 | 6364 | if test x$ac_df_checking != x ; then |
486aa804 | 6365 | |
5213506e | 6366 | $as_echo "#define ENABLE_DF_CHECKING 1" >>confdefs.h |
486aa804 | 6367 | |
00020c16 ILT |
6368 | fi |
6369 | if test x$ac_assert_checking != x ; then | |
486aa804 | 6370 | |
5213506e | 6371 | $as_echo "#define ENABLE_ASSERT_CHECKING 1" >>confdefs.h |
486aa804 | 6372 | |
00020c16 ILT |
6373 | fi |
6374 | if test x$ac_gimple_checking != x ; then | |
486aa804 | 6375 | |
5213506e | 6376 | $as_echo "#define ENABLE_GIMPLE_CHECKING 1" >>confdefs.h |
b61ff9c8 | 6377 | |
00020c16 | 6378 | fi |
ab22c1fa | 6379 | |
00020c16 | 6380 | if test x$ac_runtime_checking != x ; then |
ab22c1fa | 6381 | |
5213506e | 6382 | $as_echo "#define ENABLE_RUNTIME_CHECKING 1" >>confdefs.h |
ab22c1fa | 6383 | |
00020c16 ILT |
6384 | fi |
6385 | if test x$ac_tree_checking != x ; then | |
ab22c1fa | 6386 | |
5213506e | 6387 | $as_echo "#define ENABLE_TREE_CHECKING 1" >>confdefs.h |
ab22c1fa | 6388 | |
00020c16 ILT |
6389 | TREEBROWSER=tree-browser.o |
6390 | fi | |
6391 | if test x$ac_types_checking != x ; then | |
ab22c1fa | 6392 | |
5213506e | 6393 | $as_echo "#define ENABLE_TYPES_CHECKING 1" >>confdefs.h |
ab22c1fa | 6394 | |
00020c16 | 6395 | fi |
ab22c1fa | 6396 | |
00020c16 | 6397 | if test x$ac_rtl_checking != x ; then |
2f41c1d6 | 6398 | |
5213506e RW |
6399 | $as_echo "#define ENABLE_RTL_CHECKING 1" >>confdefs.h |
6400 | ||
00020c16 | 6401 | fi |
5213506e RW |
6402 | if test x$ac_rtlflag_checking != x ; then |
6403 | ||
6404 | $as_echo "#define ENABLE_RTL_FLAG_CHECKING 1" >>confdefs.h | |
4977bab6 | 6405 | |
00020c16 | 6406 | fi |
5213506e RW |
6407 | if test x$ac_gc_checking != x ; then |
6408 | ||
6409 | $as_echo "#define ENABLE_GC_CHECKING 1" >>confdefs.h | |
6410 | ||
6411 | fi | |
6412 | if test x$ac_gc_always_collect != x ; then | |
6413 | ||
6414 | $as_echo "#define ENABLE_GC_ALWAYS_COLLECT 1" >>confdefs.h | |
4977bab6 | 6415 | |
00020c16 | 6416 | fi |
5213506e RW |
6417 | if test x$ac_fold_checking != x ; then |
6418 | ||
6419 | $as_echo "#define ENABLE_FOLD_CHECKING 1" >>confdefs.h | |
2f41c1d6 | 6420 | |
00020c16 | 6421 | fi |
5213506e RW |
6422 | valgrind_path_defines= |
6423 | valgrind_command= | |
6424 | ||
6425 | ac_fn_c_check_header_mongrel "$LINENO" "valgrind.h" "ac_cv_header_valgrind_h" "$ac_includes_default" | |
6426 | if test "x$ac_cv_header_valgrind_h" = x""yes; then : | |
00020c16 | 6427 | have_valgrind_h=yes |
2f41c1d6 | 6428 | else |
00020c16 ILT |
6429 | have_valgrind_h=no |
6430 | fi | |
2f41c1d6 | 6431 | |
1a4b763e | 6432 | |
2f41c1d6 | 6433 | |
00020c16 ILT |
6434 | if test x$ac_valgrind_checking != x ; then |
6435 | # It is certainly possible that there's valgrind but no valgrind.h. | |
6436 | # GCC relies on making annotations so we must have both. | |
5213506e RW |
6437 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for VALGRIND_DISCARD in <valgrind/memcheck.h>" >&5 |
6438 | $as_echo_n "checking for VALGRIND_DISCARD in <valgrind/memcheck.h>... " >&6; } | |
6439 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
00020c16 ILT |
6440 | /* end confdefs.h. */ |
6441 | #include <valgrind/memcheck.h> | |
6442 | #ifndef VALGRIND_DISCARD | |
6443 | #error VALGRIND_DISCARD not defined | |
6444 | #endif | |
6445 | _ACEOF | |
5213506e | 6446 | if ac_fn_c_try_cpp "$LINENO"; then : |
00020c16 | 6447 | gcc_cv_header_valgrind_memcheck_h=yes |
aca600aa | 6448 | else |
00020c16 ILT |
6449 | gcc_cv_header_valgrind_memcheck_h=no |
6450 | fi | |
6451 | rm -f conftest.err conftest.$ac_ext | |
5213506e RW |
6452 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_header_valgrind_memcheck_h" >&5 |
6453 | $as_echo "$gcc_cv_header_valgrind_memcheck_h" >&6; } | |
6454 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for VALGRIND_DISCARD in <memcheck.h>" >&5 | |
6455 | $as_echo_n "checking for VALGRIND_DISCARD in <memcheck.h>... " >&6; } | |
6456 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
00020c16 ILT |
6457 | /* end confdefs.h. */ |
6458 | #include <memcheck.h> | |
6459 | #ifndef VALGRIND_DISCARD | |
6460 | #error VALGRIND_DISCARD not defined | |
6461 | #endif | |
6462 | _ACEOF | |
5213506e | 6463 | if ac_fn_c_try_cpp "$LINENO"; then : |
00020c16 | 6464 | gcc_cv_header_memcheck_h=yes |
e9a25f70 | 6465 | else |
00020c16 ILT |
6466 | gcc_cv_header_memcheck_h=no |
6467 | fi | |
6468 | rm -f conftest.err conftest.$ac_ext | |
5213506e RW |
6469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_header_memcheck_h" >&5 |
6470 | $as_echo "$gcc_cv_header_memcheck_h" >&6; } | |
00020c16 ILT |
6471 | |
6472 | # Prepare PATH_SEPARATOR. | |
6473 | # The user is always right. | |
6474 | if test "${PATH_SEPARATOR+set}" != set; then | |
6475 | echo "#! /bin/sh" >conf$$.sh | |
6476 | echo "exit 0" >>conf$$.sh | |
6477 | chmod +x conf$$.sh | |
6478 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
6479 | PATH_SEPARATOR=';' | |
6480 | else | |
6481 | PATH_SEPARATOR=: | |
6482 | fi | |
6483 | rm -f conf$$.sh | |
e9a25f70 JL |
6484 | fi |
6485 | ||
00020c16 ILT |
6486 | # Find out how to test for executable files. Don't use a zero-byte file, |
6487 | # as systems may use methods other than mode bits to determine executability. | |
6488 | cat >conf$$.file <<_ASEOF | |
6489 | #! /bin/sh | |
6490 | exit 0 | |
6491 | _ASEOF | |
6492 | chmod +x conf$$.file | |
6493 | if test -x conf$$.file >/dev/null 2>&1; then | |
6494 | ac_executable_p="test -x" | |
6495 | else | |
6496 | ac_executable_p="test -f" | |
6497 | fi | |
6498 | rm -f conf$$.file | |
e9a25f70 | 6499 | |
00020c16 ILT |
6500 | # Extract the first word of "valgrind", so it can be a program name with args. |
6501 | set dummy valgrind; ac_word=$2 | |
5213506e RW |
6502 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
6503 | $as_echo_n "checking for $ac_word... " >&6; } | |
6504 | if test "${ac_cv_path_valgrind_path+set}" = set; then : | |
6505 | $as_echo_n "(cached) " >&6 | |
861bb6c1 | 6506 | else |
00020c16 ILT |
6507 | case "$valgrind_path" in |
6508 | [\\/]* | ?:[\\/]*) | |
6509 | ac_cv_path_valgrind_path="$valgrind_path" # Let the user override the test with a path. | |
6510 | ;; | |
6511 | *) | |
6512 | ac_save_IFS="$IFS"; IFS=$PATH_SEPARATOR | |
6513 | for ac_dir in $PATH; do | |
6514 | IFS="$ac_save_IFS" | |
6515 | test -z "$ac_dir" && ac_dir=. | |
6516 | for ac_exec_ext in '' $ac_executable_extensions; do | |
6517 | if $ac_executable_p "$ac_dir/$ac_word$ac_exec_ext"; then | |
6518 | if $ac_dir/$ac_word --version | grep valgrind- >/dev/null 2>&1; then | |
6519 | ac_cv_path_valgrind_path="$ac_dir/$ac_word$ac_exec_ext" | |
6520 | break 2 | |
6521 | fi | |
6522 | fi | |
6523 | done | |
6524 | done | |
6525 | IFS="$ac_save_IFS" | |
6526 | ;; | |
6527 | esac | |
861bb6c1 | 6528 | fi |
00020c16 ILT |
6529 | valgrind_path="$ac_cv_path_valgrind_path" |
6530 | if test -n "$valgrind_path"; then | |
5213506e RW |
6531 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $valgrind_path" >&5 |
6532 | $as_echo "$valgrind_path" >&6; } | |
861bb6c1 | 6533 | else |
5213506e RW |
6534 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
6535 | $as_echo "no" >&6; } | |
861bb6c1 JL |
6536 | fi |
6537 | ||
00020c16 ILT |
6538 | if test "x$valgrind_path" = "x" \ |
6539 | || (test $have_valgrind_h = no \ | |
6540 | && test $gcc_cv_header_memcheck_h = no \ | |
6541 | && test $gcc_cv_header_valgrind_memcheck_h = no); then | |
5213506e | 6542 | as_fn_error "*** Can't find both valgrind and valgrind/memcheck.h, memcheck.h or valgrind.h" "$LINENO" 5 |
00020c16 ILT |
6543 | fi |
6544 | valgrind_path_defines=-DVALGRIND_PATH='\"'$valgrind_path'\"' | |
6545 | valgrind_command="$valgrind_path -q" | |
861bb6c1 | 6546 | |
5213506e | 6547 | $as_echo "#define ENABLE_VALGRIND_CHECKING 1" >>confdefs.h |
00020c16 ILT |
6548 | |
6549 | if test $gcc_cv_header_valgrind_memcheck_h = yes; then | |
6550 | ||
5213506e | 6551 | $as_echo "#define HAVE_VALGRIND_MEMCHECK_H 1" >>confdefs.h |
2c4902b9 | 6552 | |
0a4b6309 | 6553 | fi |
00020c16 ILT |
6554 | if test $gcc_cv_header_memcheck_h = yes; then |
6555 | ||
5213506e | 6556 | $as_echo "#define HAVE_MEMCHECK_H 1" >>confdefs.h |
0a4b6309 | 6557 | |
0a4b6309 RL |
6558 | fi |
6559 | fi | |
6560 | ||
18fc9bd4 | 6561 | |
18fc9bd4 | 6562 | |
00020c16 | 6563 | # Enable code coverage collection |
5213506e RW |
6564 | # Check whether --enable-coverage was given. |
6565 | if test "${enable_coverage+set}" = set; then : | |
6566 | enableval=$enable_coverage; case "${enableval}" in | |
00020c16 ILT |
6567 | yes|noopt) |
6568 | coverage_flags="-fprofile-arcs -ftest-coverage -frandom-seed=\$@ -O0" | |
6569 | ;; | |
6570 | opt) | |
6571 | coverage_flags="-fprofile-arcs -ftest-coverage -frandom-seed=\$@ -O2" | |
6572 | ;; | |
6573 | no) | |
6574 | # a.k.a. --disable-coverage | |
6575 | coverage_flags="" | |
6576 | ;; | |
6577 | *) | |
5213506e | 6578 | as_fn_error "unknown coverage setting $enableval" "$LINENO" 5 |
00020c16 ILT |
6579 | ;; |
6580 | esac | |
861bb6c1 | 6581 | else |
00020c16 | 6582 | coverage_flags="" |
5213506e | 6583 | fi |
00020c16 ILT |
6584 | |
6585 | ||
ba479fd2 | 6586 | |
5213506e RW |
6587 | # Check whether --enable-gather-detailed-mem-stats was given. |
6588 | if test "${enable_gather_detailed_mem_stats+set}" = set; then : | |
6589 | enableval=$enable_gather_detailed_mem_stats; | |
ba479fd2 | 6590 | else |
00020c16 | 6591 | enable_gather_detailed_mem_stats=no |
5213506e RW |
6592 | fi |
6593 | ||
00020c16 ILT |
6594 | if test x$enable_gather_detailed_mem_stats = xyes ; then |
6595 | ||
5213506e | 6596 | $as_echo "#define GATHER_STATISTICS 1" >>confdefs.h |
ba479fd2 NN |
6597 | |
6598 | fi | |
00020c16 ILT |
6599 | |
6600 | # ------------------------------- | |
6601 | # Miscenalleous configure options | |
6602 | # ------------------------------- | |
6603 | ||
6604 | # See if we are building gcc with C++. | |
5213506e RW |
6605 | # Check whether --enable-build-with-cxx was given. |
6606 | if test "${enable_build_with_cxx+set}" = set; then : | |
6607 | enableval=$enable_build_with_cxx; ENABLE_BUILD_WITH_CXX=$enableval | |
ba479fd2 | 6608 | else |
00020c16 | 6609 | ENABLE_BUILD_WITH_CXX=no |
5213506e RW |
6610 | fi |
6611 | ||
ba479fd2 | 6612 | |
00020c16 ILT |
6613 | |
6614 | # With stabs | |
6615 | ||
5213506e RW |
6616 | # Check whether --with-stabs was given. |
6617 | if test "${with_stabs+set}" = set; then : | |
6618 | withval=$with_stabs; stabs="$with_stabs" | |
6e3f3080 | 6619 | else |
00020c16 | 6620 | stabs=no |
5213506e | 6621 | fi |
00020c16 | 6622 | |
ba479fd2 | 6623 | |
5213506e RW |
6624 | # Determine whether or not multilibs are enabled. |
6625 | # Check whether --enable-multilib was given. | |
6626 | if test "${enable_multilib+set}" = set; then : | |
6627 | enableval=$enable_multilib; | |
ba479fd2 | 6628 | else |
00020c16 | 6629 | enable_multilib=yes |
5213506e RW |
6630 | fi |
6631 | ||
861bb6c1 | 6632 | |
343a6100 | 6633 | |
00020c16 | 6634 | # Enable __cxa_atexit for C++. |
5213506e RW |
6635 | # Check whether --enable-__cxa_atexit was given. |
6636 | if test "${enable___cxa_atexit+set}" = set; then : | |
6637 | enableval=$enable___cxa_atexit; | |
6638 | fi | |
00020c16 | 6639 | |
00020c16 ILT |
6640 | |
6641 | # Enable C extension for decimal float if target supports it. | |
5213506e RW |
6642 | # Check whether --enable-decimal-float was given. |
6643 | if test "${enable_decimal_float+set}" = set; then : | |
6644 | enableval=$enable_decimal_float; | |
00020c16 ILT |
6645 | case $enable_decimal_float in |
6646 | yes | no | bid | dpd) ;; | |
5213506e RW |
6647 | *) as_fn_error "'$enable_decimal_float' is an invalid value for --enable-decimal-float. |
6648 | Valid choices are 'yes', 'bid', 'dpd', and 'no'." "$LINENO" 5 ;; | |
00020c16 | 6649 | esac |
343a6100 | 6650 | |
0a4b6309 | 6651 | else |
00020c16 ILT |
6652 | |
6653 | case $target in | |
6654 | powerpc*-*-linux* | i?86*-*-linux* | x86_64*-*-linux*) | |
6655 | enable_decimal_float=yes | |
0a4b6309 | 6656 | ;; |
00020c16 | 6657 | *) |
5213506e RW |
6658 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: decimal float is not supported for this target" >&5 |
6659 | $as_echo "$as_me: WARNING: decimal float is not supported for this target" >&2;} | |
00020c16 ILT |
6660 | enable_decimal_float=no |
6661 | ;; | |
6662 | esac | |
6663 | ||
5213506e RW |
6664 | fi |
6665 | ||
00020c16 ILT |
6666 | |
6667 | dfp=`if test $enable_decimal_float != no; then echo 1; else echo 0; fi` | |
6668 | ||
6669 | cat >>confdefs.h <<_ACEOF | |
6670 | #define ENABLE_DECIMAL_FLOAT $dfp | |
6671 | _ACEOF | |
6672 | ||
6673 | ||
6674 | # x86's use BID format instead of DPD | |
6675 | case x$enable_decimal_float in | |
6676 | xyes) | |
6677 | case $target in | |
6678 | i?86*-*-linux* | x86_64*-*-linux*) | |
6679 | enable_decimal_float=bid | |
6680 | ;; | |
6681 | *) | |
6682 | enable_decimal_float=dpd | |
6683 | ;; | |
0a4b6309 | 6684 | esac |
00020c16 ILT |
6685 | ;; |
6686 | xno) | |
6687 | # ENABLE_DECIMAL_FLOAT is set to 0. But we have to have proper | |
6688 | # dependency on libdecnumber. | |
6689 | enable_decimal_float=dpd | |
6690 | ;; | |
6691 | esac | |
0a4b6309 | 6692 | |
0a4b6309 | 6693 | |
00020c16 | 6694 | bid=`if test $enable_decimal_float = bid; then echo 1; else echo 0; fi` |
0a4b6309 | 6695 | |
00020c16 ILT |
6696 | cat >>confdefs.h <<_ACEOF |
6697 | #define ENABLE_DECIMAL_BID_FORMAT $bid | |
6698 | _ACEOF | |
6699 | ||
6700 | ||
6701 | # Enable C extension for fixed-point arithmetic. | |
5213506e RW |
6702 | # Check whether --enable-fixed-point was given. |
6703 | if test "${enable_fixed_point+set}" = set; then : | |
6704 | enableval=$enable_fixed_point; | |
861bb6c1 | 6705 | |
3a000df0 | 6706 | else |
3a000df0 | 6707 | |
00020c16 ILT |
6708 | case $target in |
6709 | mips*-*-*) | |
6710 | case $host in | |
6711 | mips*-sgi-irix*) | |
5213506e RW |
6712 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: fixed-point is not supported on IRIX" >&5 |
6713 | $as_echo "$as_me: WARNING: fixed-point is not supported on IRIX" >&2;} | |
00020c16 ILT |
6714 | enable_fixed_point=no |
6715 | ;; | |
6716 | *) | |
6717 | enable_fixed_point=yes | |
6718 | ;; | |
6719 | esac | |
6720 | ;; | |
6721 | *) | |
5213506e RW |
6722 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: fixed-point is not supported for this target" >&5 |
6723 | $as_echo "$as_me: WARNING: fixed-point is not supported for this target" >&2;} | |
00020c16 ILT |
6724 | enable_fixed_point=no |
6725 | ;; | |
6726 | esac | |
3a000df0 | 6727 | |
5213506e RW |
6728 | fi |
6729 | ||
3a000df0 KC |
6730 | |
6731 | ||
00020c16 | 6732 | fixedpoint=`if test $enable_fixed_point = yes; then echo 1; else echo 0; fi` |
ba479fd2 | 6733 | |
00020c16 ILT |
6734 | cat >>confdefs.h <<_ACEOF |
6735 | #define ENABLE_FIXED_POINT $fixedpoint | |
6736 | _ACEOF | |
73458fb7 NN |
6737 | |
6738 | ||
00020c16 ILT |
6739 | # Enable threads |
6740 | # Pass with no value to take the default | |
6741 | # Pass with a value to specify a thread package | |
5213506e RW |
6742 | # Check whether --enable-threads was given. |
6743 | if test "${enable_threads+set}" = set; then : | |
6744 | enableval=$enable_threads; | |
73458fb7 | 6745 | else |
00020c16 | 6746 | enable_threads='' |
5213506e | 6747 | fi |
00020c16 | 6748 | |
00020c16 | 6749 | |
5213506e RW |
6750 | # Check whether --enable-tls was given. |
6751 | if test "${enable_tls+set}" = set; then : | |
6752 | enableval=$enable_tls; | |
00020c16 ILT |
6753 | case $enable_tls in |
6754 | yes | no) ;; | |
5213506e RW |
6755 | *) as_fn_error "'$enable_tls' is an invalid value for --enable-tls. |
6756 | Valid choices are 'yes' and 'no'." "$LINENO" 5 ;; | |
00020c16 ILT |
6757 | esac |
6758 | ||
73458fb7 | 6759 | else |
00020c16 | 6760 | enable_tls='' |
5213506e | 6761 | fi |
ba479fd2 | 6762 | |
5213506e RW |
6763 | |
6764 | # Check whether --enable-objc-gc was given. | |
6765 | if test "${enable_objc_gc+set}" = set; then : | |
6766 | enableval=$enable_objc_gc; if test x$enable_objc_gc = xno; then | |
00020c16 | 6767 | objc_boehm_gc='' |
73458fb7 | 6768 | else |
00020c16 | 6769 | objc_boehm_gc=1 |
73458fb7 | 6770 | fi |
00020c16 ILT |
6771 | else |
6772 | objc_boehm_gc='' | |
5213506e RW |
6773 | fi |
6774 | ||
73458fb7 | 6775 | |
00020c16 | 6776 | |
5213506e RW |
6777 | # Check whether --with-dwarf2 was given. |
6778 | if test "${with_dwarf2+set}" = set; then : | |
6779 | withval=$with_dwarf2; dwarf2="$with_dwarf2" | |
73458fb7 | 6780 | else |
00020c16 | 6781 | dwarf2=no |
5213506e | 6782 | fi |
3bbd5a19 | 6783 | |
73458fb7 | 6784 | |
5213506e RW |
6785 | # Check whether --enable-shared was given. |
6786 | if test "${enable_shared+set}" = set; then : | |
6787 | enableval=$enable_shared; | |
00020c16 ILT |
6788 | case $enable_shared in |
6789 | yes | no) ;; | |
6790 | *) | |
6791 | enable_shared=no | |
6792 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}:," | |
6793 | for pkg in $enableval; do | |
6794 | if test "X$pkg" = "Xgcc" || test "X$pkg" = "Xlibgcc"; then | |
6795 | enable_shared=yes | |
6796 | fi | |
6797 | done | |
6798 | IFS="$ac_save_ifs" | |
6799 | ;; | |
6800 | esac | |
73458fb7 | 6801 | |
73458fb7 | 6802 | else |
00020c16 | 6803 | enable_shared=yes |
5213506e | 6804 | fi |
73458fb7 | 6805 | |
7c27e184 | 6806 | |
00020c16 | 6807 | |
00020c16 | 6808 | |
5213506e RW |
6809 | # Check whether --with-build-sysroot was given. |
6810 | if test "${with_build_sysroot+set}" = set; then : | |
6811 | withval=$with_build_sysroot; | |
6812 | fi | |
00020c16 ILT |
6813 | |
6814 | ||
00020c16 | 6815 | |
5213506e RW |
6816 | # Check whether --with-sysroot was given. |
6817 | if test "${with_sysroot+set}" = set; then : | |
6818 | withval=$with_sysroot; | |
00020c16 ILT |
6819 | case ${with_sysroot} in |
6820 | yes) TARGET_SYSTEM_ROOT='${exec_prefix}/${target_noncanonical}/sys-root' ;; | |
6821 | *) TARGET_SYSTEM_ROOT=$with_sysroot ;; | |
6822 | esac | |
6823 | ||
6824 | TARGET_SYSTEM_ROOT_DEFINE='-DTARGET_SYSTEM_ROOT=\"$(TARGET_SYSTEM_ROOT)\"' | |
6825 | CROSS_SYSTEM_HEADER_DIR='$(TARGET_SYSTEM_ROOT)$${sysroot_headers_suffix}$(NATIVE_SYSTEM_HEADER_DIR)' | |
6826 | ||
6827 | if test "x$prefix" = xNONE; then | |
6828 | test_prefix=/usr/local | |
6829 | else | |
6830 | test_prefix=$prefix | |
6831 | fi | |
6832 | if test "x$exec_prefix" = xNONE; then | |
6833 | test_exec_prefix=$test_prefix | |
6834 | else | |
6835 | test_exec_prefix=$exec_prefix | |
6836 | fi | |
6837 | case ${TARGET_SYSTEM_ROOT} in | |
6838 | "${test_prefix}"|"${test_prefix}/"*|\ | |
6839 | "${test_exec_prefix}"|"${test_exec_prefix}/"*|\ | |
6840 | '${prefix}'|'${prefix}/'*|\ | |
6841 | '${exec_prefix}'|'${exec_prefix}/'*) | |
6842 | t="$TARGET_SYSTEM_ROOT_DEFINE -DTARGET_SYSTEM_ROOT_RELOCATABLE" | |
6843 | TARGET_SYSTEM_ROOT_DEFINE="$t" | |
6844 | ;; | |
6845 | esac | |
6846 | ||
6847 | else | |
6848 | ||
6849 | TARGET_SYSTEM_ROOT= | |
6850 | TARGET_SYSTEM_ROOT_DEFINE= | |
6851 | CROSS_SYSTEM_HEADER_DIR='$(gcc_tooldir)/sys-include' | |
6852 | ||
5213506e RW |
6853 | fi |
6854 | ||
00020c16 ILT |
6855 | |
6856 | ||
6857 | ||
6858 | ||
e11ddaf5 NS |
6859 | |
6860 | # Check whether --with-specs was given. | |
6861 | if test "${with_specs+set}" = set; then : | |
6862 | withval=$with_specs; CONFIGURE_SPECS=$withval | |
6863 | else | |
6864 | CONFIGURE_SPECS= | |
6865 | ||
6866 | fi | |
6867 | ||
6868 | ||
6869 | ||
00020c16 | 6870 | # Build with intermodule optimisations |
5213506e RW |
6871 | # Check whether --enable-intermodule was given. |
6872 | if test "${enable_intermodule+set}" = set; then : | |
6873 | enableval=$enable_intermodule; case ${enable_intermodule} in | |
00020c16 ILT |
6874 | yes) onestep="-onestep";; |
6875 | *) onestep="";; | |
6876 | esac | |
6877 | else | |
6878 | onestep="" | |
5213506e RW |
6879 | fi |
6880 | ||
00020c16 ILT |
6881 | |
6882 | ||
6883 | ||
6884 | ||
5213506e RW |
6885 | # Check whether --with-pkgversion was given. |
6886 | if test "${with_pkgversion+set}" = set; then : | |
6887 | withval=$with_pkgversion; case "$withval" in | |
6888 | yes) as_fn_error "package version not specified" "$LINENO" 5 ;; | |
00020c16 ILT |
6889 | no) PKGVERSION= ;; |
6890 | *) PKGVERSION="($withval) " ;; | |
6891 | esac | |
6892 | else | |
6893 | PKGVERSION="(GCC) " | |
6894 | ||
5213506e | 6895 | fi |
00020c16 ILT |
6896 | |
6897 | ||
6898 | ||
6899 | ||
5213506e RW |
6900 | |
6901 | # Check whether --with-bugurl was given. | |
6902 | if test "${with_bugurl+set}" = set; then : | |
6903 | withval=$with_bugurl; case "$withval" in | |
6904 | yes) as_fn_error "bug URL not specified" "$LINENO" 5 ;; | |
00020c16 ILT |
6905 | no) BUGURL= |
6906 | ;; | |
6907 | *) BUGURL="$withval" | |
6908 | ;; | |
6909 | esac | |
6910 | else | |
6911 | BUGURL="http://gcc.gnu.org/bugs.html" | |
6912 | ||
5213506e RW |
6913 | fi |
6914 | ||
00020c16 ILT |
6915 | case ${BUGURL} in |
6916 | "") | |
6917 | REPORT_BUGS_TO= | |
6918 | REPORT_BUGS_TEXI= | |
6919 | ;; | |
6920 | *) | |
6921 | REPORT_BUGS_TO="<$BUGURL>" | |
6922 | REPORT_BUGS_TEXI=@uref{`echo "$BUGURL" | sed 's/@/@@/g'`} | |
6923 | ;; | |
6924 | esac; | |
6925 | ||
6926 | ||
6927 | ||
6928 | ||
6929 | # Sanity check enable_languages in case someone does not run the toplevel | |
6930 | # configure # script. | |
5213506e RW |
6931 | # Check whether --enable-languages was given. |
6932 | if test "${enable_languages+set}" = set; then : | |
6933 | enableval=$enable_languages; case ,${enable_languages}, in | |
00020c16 ILT |
6934 | ,,|,yes,) |
6935 | # go safe -- we cannot be much sure without the toplevel | |
6936 | # configure's | |
6937 | # analysis of which target libs are present and usable | |
6938 | enable_languages=c | |
6939 | ;; | |
6940 | *,all,*) | |
5213506e | 6941 | as_fn_error "only the toplevel supports --enable-languages=all" "$LINENO" 5 |
00020c16 ILT |
6942 | ;; |
6943 | *,c,*) | |
6944 | ;; | |
6945 | *) | |
6946 | enable_languages=c,${enable_languages} | |
6947 | ;; | |
6948 | esac | |
6949 | else | |
6950 | enable_languages=c | |
5213506e RW |
6951 | fi |
6952 | ||
00020c16 | 6953 | |
00020c16 | 6954 | |
5213506e RW |
6955 | # Check whether --with-multilib-list was given. |
6956 | if test "${with_multilib_list+set}" = set; then : | |
6957 | withval=$with_multilib_list; : | |
00020c16 ILT |
6958 | else |
6959 | with_multilib_list=default | |
5213506e RW |
6960 | fi |
6961 | ||
00020c16 ILT |
6962 | |
6963 | # ------------------------- | |
6964 | # Checks for other programs | |
6965 | # ------------------------- | |
6966 | ||
5213506e RW |
6967 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ${MAKE-make} sets \$(MAKE)" >&5 |
6968 | $as_echo_n "checking whether ${MAKE-make} sets \$(MAKE)... " >&6; } | |
6969 | set x ${MAKE-make} | |
6970 | ac_make=`$as_echo "$2" | sed 's/+/p/g; s/[^a-zA-Z0-9_]/_/g'` | |
6971 | if { as_var=ac_cv_prog_make_${ac_make}_set; eval "test \"\${$as_var+set}\" = set"; }; then : | |
6972 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
6973 | else |
6974 | cat >conftest.make <<\_ACEOF | |
5213506e | 6975 | SHELL = /bin/sh |
00020c16 | 6976 | all: |
5213506e | 6977 | @echo '@@@%%%=$(MAKE)=@@@%%%' |
00020c16 ILT |
6978 | _ACEOF |
6979 | # GNU make sometimes prints "make[1]: Entering...", which would confuse us. | |
5213506e RW |
6980 | case `${MAKE-make} -f conftest.make 2>/dev/null` in |
6981 | *@@@%%%=?*=@@@%%%*) | |
6982 | eval ac_cv_prog_make_${ac_make}_set=yes;; | |
6983 | *) | |
6984 | eval ac_cv_prog_make_${ac_make}_set=no;; | |
6985 | esac | |
00020c16 ILT |
6986 | rm -f conftest.make |
6987 | fi | |
5213506e RW |
6988 | if eval test \$ac_cv_prog_make_${ac_make}_set = yes; then |
6989 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
6990 | $as_echo "yes" >&6; } | |
00020c16 | 6991 | SET_MAKE= |
73458fb7 | 6992 | else |
5213506e RW |
6993 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
6994 | $as_echo "no" >&6; } | |
00020c16 | 6995 | SET_MAKE="MAKE=${MAKE-make}" |
73458fb7 NN |
6996 | fi |
6997 | ||
7c27e184 | 6998 | |
00020c16 ILT |
6999 | # Find some useful tools |
7000 | for ac_prog in gawk mawk nawk awk | |
7c27e184 PB |
7001 | do |
7002 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
7003 | set dummy $ac_prog; ac_word=$2 | |
5213506e RW |
7004 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7005 | $as_echo_n "checking for $ac_word... " >&6; } | |
7006 | if test "${ac_cv_prog_AWK+set}" = set; then : | |
7007 | $as_echo_n "(cached) " >&6 | |
73458fb7 | 7008 | else |
00020c16 ILT |
7009 | if test -n "$AWK"; then |
7010 | ac_cv_prog_AWK="$AWK" # Let the user override the test. | |
73458fb7 | 7011 | else |
ba479fd2 NN |
7012 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
7013 | for as_dir in $PATH | |
7014 | do | |
7015 | IFS=$as_save_IFS | |
7016 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7017 | for ac_exec_ext in '' $ac_executable_extensions; do |
7018 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7019 | ac_cv_prog_AWK="$ac_prog" |
5213506e | 7020 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
ba479fd2 NN |
7021 | break 2 |
7022 | fi | |
7023 | done | |
5213506e RW |
7024 | done |
7025 | IFS=$as_save_IFS | |
ba479fd2 | 7026 | |
73458fb7 NN |
7027 | fi |
7028 | fi | |
00020c16 ILT |
7029 | AWK=$ac_cv_prog_AWK |
7030 | if test -n "$AWK"; then | |
5213506e RW |
7031 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 |
7032 | $as_echo "$AWK" >&6; } | |
73458fb7 | 7033 | else |
5213506e RW |
7034 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7035 | $as_echo "no" >&6; } | |
73458fb7 NN |
7036 | fi |
7037 | ||
5213506e | 7038 | |
00020c16 | 7039 | test -n "$AWK" && break |
7c27e184 | 7040 | done |
7c27e184 | 7041 | |
00020c16 ILT |
7042 | # We need awk to create options.c and options.h. |
7043 | # Bail out if it's missing. | |
7044 | case ${AWK} in | |
5213506e | 7045 | "") as_fn_error "can't build without awk, bailing out" "$LINENO" 5 ;; |
00020c16 | 7046 | esac |
73458fb7 | 7047 | |
5213506e RW |
7048 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 |
7049 | $as_echo_n "checking whether ln -s works... " >&6; } | |
7050 | if test "${gcc_cv_prog_LN_S+set}" = set; then : | |
7051 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7052 | else |
7053 | rm -f conftestdata_t | |
7054 | echo >conftestdata_f | |
7055 | if ln -s conftestdata_f conftestdata_t 2>/dev/null | |
7056 | then | |
7057 | gcc_cv_prog_LN_S="ln -s" | |
7058 | else | |
7059 | if ln conftestdata_f conftestdata_t 2>/dev/null | |
7060 | then | |
7061 | gcc_cv_prog_LN_S=ln | |
7062 | else | |
7063 | if cp -p conftestdata_f conftestdata_t 2>/dev/null | |
7064 | then | |
7065 | gcc_cv_prog_LN_S="cp -p" | |
7066 | else | |
7067 | gcc_cv_prog_LN_S=cp | |
7068 | fi | |
7069 | fi | |
7070 | fi | |
7071 | rm -f conftestdata_f conftestdata_t | |
7072 | ||
7073 | fi | |
7074 | LN_S="$gcc_cv_prog_LN_S" | |
7075 | if test "$gcc_cv_prog_LN_S" = "ln -s"; then | |
5213506e RW |
7076 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
7077 | $as_echo "yes" >&6; } | |
00020c16 ILT |
7078 | else |
7079 | if test "$gcc_cv_prog_LN_S" = "ln"; then | |
5213506e RW |
7080 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using ln" >&5 |
7081 | $as_echo "no, using ln" >&6; } | |
00020c16 | 7082 | else |
5213506e RW |
7083 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, and neither does ln, so using $gcc_cv_prog_LN_S" >&5 |
7084 | $as_echo "no, and neither does ln, so using $gcc_cv_prog_LN_S" >&6; } | |
00020c16 ILT |
7085 | fi |
7086 | fi | |
7087 | ||
5213506e RW |
7088 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln works" >&5 |
7089 | $as_echo_n "checking whether ln works... " >&6; } | |
7090 | if test "${acx_cv_prog_LN+set}" = set; then : | |
7091 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7092 | else |
7093 | rm -f conftestdata_t | |
7094 | echo >conftestdata_f | |
7095 | if ln conftestdata_f conftestdata_t 2>/dev/null | |
7096 | then | |
7097 | acx_cv_prog_LN=ln | |
7098 | else | |
7099 | acx_cv_prog_LN=no | |
7100 | fi | |
7101 | rm -f conftestdata_f conftestdata_t | |
7102 | ||
7103 | fi | |
7104 | if test $acx_cv_prog_LN = no; then | |
7105 | LN="$LN_S" | |
5213506e RW |
7106 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN" >&5 |
7107 | $as_echo "no, using $LN" >&6; } | |
00020c16 ILT |
7108 | else |
7109 | LN="$acx_cv_prog_LN" | |
5213506e RW |
7110 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
7111 | $as_echo "yes" >&6; } | |
00020c16 ILT |
7112 | fi |
7113 | ||
7114 | if test -n "$ac_tool_prefix"; then | |
7115 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
7116 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
5213506e RW |
7117 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7118 | $as_echo_n "checking for $ac_word... " >&6; } | |
7119 | if test "${ac_cv_prog_RANLIB+set}" = set; then : | |
7120 | $as_echo_n "(cached) " >&6 | |
73458fb7 | 7121 | else |
00020c16 ILT |
7122 | if test -n "$RANLIB"; then |
7123 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
73458fb7 | 7124 | else |
ba479fd2 NN |
7125 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
7126 | for as_dir in $PATH | |
7127 | do | |
7128 | IFS=$as_save_IFS | |
7129 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7130 | for ac_exec_ext in '' $ac_executable_extensions; do |
7131 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7132 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
5213506e | 7133 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
ba479fd2 NN |
7134 | break 2 |
7135 | fi | |
7136 | done | |
5213506e RW |
7137 | done |
7138 | IFS=$as_save_IFS | |
ba479fd2 | 7139 | |
73458fb7 NN |
7140 | fi |
7141 | fi | |
00020c16 ILT |
7142 | RANLIB=$ac_cv_prog_RANLIB |
7143 | if test -n "$RANLIB"; then | |
5213506e RW |
7144 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
7145 | $as_echo "$RANLIB" >&6; } | |
73458fb7 | 7146 | else |
5213506e RW |
7147 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7148 | $as_echo "no" >&6; } | |
73458fb7 NN |
7149 | fi |
7150 | ||
5213506e | 7151 | |
00020c16 ILT |
7152 | fi |
7153 | if test -z "$ac_cv_prog_RANLIB"; then | |
7154 | ac_ct_RANLIB=$RANLIB | |
7155 | # Extract the first word of "ranlib", so it can be a program name with args. | |
7156 | set dummy ranlib; ac_word=$2 | |
5213506e RW |
7157 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7158 | $as_echo_n "checking for $ac_word... " >&6; } | |
7159 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : | |
7160 | $as_echo_n "(cached) " >&6 | |
f6a874ac | 7161 | else |
00020c16 ILT |
7162 | if test -n "$ac_ct_RANLIB"; then |
7163 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
f6a874ac JW |
7164 | else |
7165 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7166 | for as_dir in $PATH | |
7167 | do | |
7168 | IFS=$as_save_IFS | |
7169 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7170 | for ac_exec_ext in '' $ac_executable_extensions; do |
7171 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7172 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
5213506e | 7173 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
f6a874ac JW |
7174 | break 2 |
7175 | fi | |
7176 | done | |
5213506e RW |
7177 | done |
7178 | IFS=$as_save_IFS | |
f6a874ac | 7179 | |
f6a874ac JW |
7180 | fi |
7181 | fi | |
00020c16 ILT |
7182 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB |
7183 | if test -n "$ac_ct_RANLIB"; then | |
5213506e RW |
7184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
7185 | $as_echo "$ac_ct_RANLIB" >&6; } | |
f6a874ac | 7186 | else |
5213506e RW |
7187 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7188 | $as_echo "no" >&6; } | |
f6a874ac JW |
7189 | fi |
7190 | ||
5213506e RW |
7191 | if test "x$ac_ct_RANLIB" = x; then |
7192 | RANLIB=":" | |
7193 | else | |
7194 | case $cross_compiling:$ac_tool_warned in | |
7195 | yes:) | |
7196 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
7197 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
7198 | ac_tool_warned=yes ;; | |
7199 | esac | |
7200 | RANLIB=$ac_ct_RANLIB | |
7201 | fi | |
00020c16 ILT |
7202 | else |
7203 | RANLIB="$ac_cv_prog_RANLIB" | |
f6a874ac JW |
7204 | fi |
7205 | ||
00020c16 ILT |
7206 | case "${host}" in |
7207 | *-*-darwin*) | |
7208 | # By default, the Darwin ranlib will not treat common symbols as | |
7209 | # definitions when building the archive table of contents. Other | |
7210 | # ranlibs do that; pass an option to the Darwin ranlib that makes | |
7211 | # it behave similarly. | |
7212 | ranlib_flags="-c" | |
7213 | ;; | |
7214 | *) | |
7215 | ranlib_flags="" | |
7216 | esac | |
7217 | ||
7218 | ||
7219 | # Find a good install program. We prefer a C program (faster), | |
7220 | # so one script is as good as another. But avoid the broken or | |
7221 | # incompatible versions: | |
7222 | # SysV /etc/install, /usr/sbin/install | |
7223 | # SunOS /usr/etc/install | |
7224 | # IRIX /sbin/install | |
7225 | # AIX /bin/install | |
7226 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | |
7227 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | |
7228 | # ./install, which can be erroneously created by make from ./install.sh. | |
5213506e RW |
7229 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD compatible install" >&5 |
7230 | $as_echo_n "checking for a BSD compatible install... " >&6; } | |
00020c16 | 7231 | if test -z "$INSTALL"; then |
5213506e RW |
7232 | if test "${ac_cv_path_install+set}" = set; then : |
7233 | $as_echo_n "(cached) " >&6 | |
f6a874ac | 7234 | else |
00020c16 ILT |
7235 | IFS="${IFS= }"; ac_save_IFS="$IFS"; IFS="${IFS}:" |
7236 | for ac_dir in $PATH; do | |
7237 | # Account for people who put trailing slashes in PATH elements. | |
7238 | case "$ac_dir/" in | |
7239 | /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;; | |
7240 | *) | |
7241 | # OSF1 and SCO ODT 3.0 have their own names for install. | |
7242 | for ac_prog in ginstall scoinst install; do | |
7243 | if test -f $ac_dir/$ac_prog; then | |
7244 | if test $ac_prog = install && | |
7245 | grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then | |
7246 | # AIX install. It has an incompatible calling convention. | |
7247 | # OSF/1 installbsd also uses dspmsg, but is usable. | |
7248 | : | |
7249 | else | |
7250 | ac_cv_path_install="$ac_dir/$ac_prog -c" | |
7251 | break 2 | |
7252 | fi | |
7253 | fi | |
7254 | done | |
7255 | ;; | |
7256 | esac | |
7257 | done | |
7258 | IFS="$ac_save_IFS" | |
7259 | ||
7260 | fi | |
7261 | if test "${ac_cv_path_install+set}" = set; then | |
7262 | INSTALL="$ac_cv_path_install" | |
7263 | else | |
7264 | # As a last resort, use the slow shell script. We don't cache a | |
7265 | # path for INSTALL within a source directory, because that will | |
7266 | # break other packages using the cache if that directory is | |
7267 | # removed, or if the path is relative. | |
7268 | INSTALL="$ac_install_sh" | |
7269 | fi | |
7270 | fi | |
5213506e RW |
7271 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 |
7272 | $as_echo "$INSTALL" >&6; } | |
00020c16 ILT |
7273 | |
7274 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | |
7275 | # It thinks the first close brace ends the variable substitution. | |
7276 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | |
7277 | ||
7278 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | |
7279 | ||
7280 | ||
7281 | # See if cmp has --ignore-initial. | |
5213506e RW |
7282 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cmp's capabilities" >&5 |
7283 | $as_echo_n "checking for cmp's capabilities... " >&6; } | |
7284 | if test "${gcc_cv_prog_cmp_skip+set}" = set; then : | |
7285 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7286 | else |
7287 | echo abfoo >t1 | |
7288 | echo cdfoo >t2 | |
7289 | gcc_cv_prog_cmp_skip=slowcompare | |
7290 | if cmp --ignore-initial=2 t1 t2 > /dev/null 2>&1; then | |
7291 | if cmp --ignore-initial=1 t1 t2 > /dev/null 2>&1; then | |
7292 | : | |
7293 | else | |
7294 | gcc_cv_prog_cmp_skip=gnucompare | |
7295 | fi | |
7296 | fi | |
7297 | if test $gcc_cv_prog_cmp_skip = slowcompare ; then | |
7298 | if cmp t1 t2 2 2 > /dev/null 2>&1; then | |
7299 | if cmp t1 t2 1 1 > /dev/null 2>&1; then | |
7300 | : | |
7301 | else | |
7302 | gcc_cv_prog_cmp_skip=fastcompare | |
7303 | fi | |
7304 | fi | |
7305 | fi | |
7306 | rm t1 t2 | |
7307 | ||
7308 | fi | |
5213506e RW |
7309 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_cmp_skip" >&5 |
7310 | $as_echo "$gcc_cv_prog_cmp_skip" >&6; } | |
00020c16 ILT |
7311 | make_compare_target=$gcc_cv_prog_cmp_skip |
7312 | ||
7313 | ||
7314 | ||
7315 | # See if we have the mktemp command. | |
7316 | # Extract the first word of "mktemp", so it can be a program name with args. | |
7317 | set dummy mktemp; ac_word=$2 | |
5213506e RW |
7318 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7319 | $as_echo_n "checking for $ac_word... " >&6; } | |
7320 | if test "${ac_cv_prog_have_mktemp_command+set}" = set; then : | |
7321 | $as_echo_n "(cached) " >&6 | |
f6a874ac | 7322 | else |
00020c16 ILT |
7323 | if test -n "$have_mktemp_command"; then |
7324 | ac_cv_prog_have_mktemp_command="$have_mktemp_command" # Let the user override the test. | |
f6a874ac JW |
7325 | else |
7326 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7327 | for as_dir in $PATH | |
7328 | do | |
7329 | IFS=$as_save_IFS | |
7330 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7331 | for ac_exec_ext in '' $ac_executable_extensions; do |
7332 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7333 | ac_cv_prog_have_mktemp_command="yes" |
5213506e | 7334 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
f6a874ac JW |
7335 | break 2 |
7336 | fi | |
7337 | done | |
5213506e RW |
7338 | done |
7339 | IFS=$as_save_IFS | |
f6a874ac | 7340 | |
00020c16 | 7341 | test -z "$ac_cv_prog_have_mktemp_command" && ac_cv_prog_have_mktemp_command="no" |
f6a874ac JW |
7342 | fi |
7343 | fi | |
00020c16 ILT |
7344 | have_mktemp_command=$ac_cv_prog_have_mktemp_command |
7345 | if test -n "$have_mktemp_command"; then | |
5213506e RW |
7346 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_mktemp_command" >&5 |
7347 | $as_echo "$have_mktemp_command" >&6; } | |
f6a874ac | 7348 | else |
5213506e RW |
7349 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7350 | $as_echo "no" >&6; } | |
f6a874ac JW |
7351 | fi |
7352 | ||
f6a874ac | 7353 | |
5213506e | 7354 | |
00020c16 ILT |
7355 | # See if makeinfo has been installed and is modern enough |
7356 | # that we can use it. | |
ca9bc441 | 7357 | |
00020c16 ILT |
7358 | # Extract the first word of "makeinfo", so it can be a program name with args. |
7359 | set dummy makeinfo; ac_word=$2 | |
5213506e RW |
7360 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7361 | $as_echo_n "checking for $ac_word... " >&6; } | |
7362 | if test "${ac_cv_prog_MAKEINFO+set}" = set; then : | |
7363 | $as_echo_n "(cached) " >&6 | |
956d6950 | 7364 | else |
00020c16 ILT |
7365 | if test -n "$MAKEINFO"; then |
7366 | ac_cv_prog_MAKEINFO="$MAKEINFO" # Let the user override the test. | |
956d6950 | 7367 | else |
00020c16 ILT |
7368 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
7369 | for as_dir in $PATH | |
7370 | do | |
7371 | IFS=$as_save_IFS | |
7372 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7373 | for ac_exec_ext in '' $ac_executable_extensions; do |
7374 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7375 | ac_cv_prog_MAKEINFO="makeinfo" |
5213506e | 7376 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
00020c16 ILT |
7377 | break 2 |
7378 | fi | |
7379 | done | |
5213506e RW |
7380 | done |
7381 | IFS=$as_save_IFS | |
ba479fd2 | 7382 | |
956d6950 | 7383 | fi |
00020c16 ILT |
7384 | fi |
7385 | MAKEINFO=$ac_cv_prog_MAKEINFO | |
7386 | if test -n "$MAKEINFO"; then | |
5213506e RW |
7387 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKEINFO" >&5 |
7388 | $as_echo "$MAKEINFO" >&6; } | |
956d6950 | 7389 | else |
5213506e RW |
7390 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7391 | $as_echo "no" >&6; } | |
956d6950 | 7392 | fi |
956d6950 | 7393 | |
5213506e | 7394 | |
00020c16 ILT |
7395 | if test -n "$MAKEINFO"; then |
7396 | # Found it, now check the version. | |
5213506e RW |
7397 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for modern makeinfo" >&5 |
7398 | $as_echo_n "checking for modern makeinfo... " >&6; } | |
7399 | if test "${gcc_cv_prog_makeinfo_modern+set}" = set; then : | |
7400 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7401 | else |
7402 | ac_prog_version=`eval $MAKEINFO --version 2>&1 | | |
7403 | sed -n 's/^.*GNU texinfo.* \([0-9][0-9.]*\).*$/\1/p'` | |
956d6950 | 7404 | |
00020c16 ILT |
7405 | case $ac_prog_version in |
7406 | '') gcc_cv_prog_makeinfo_modern=no;; | |
7407 | 4.[7-9]*|4.[1-9][0-9]*|[5-9]*|[1-9][0-9]*) gcc_cv_prog_makeinfo_modern=yes;; | |
7408 | *) gcc_cv_prog_makeinfo_modern=no;; | |
7409 | esac | |
ba479fd2 | 7410 | |
956d6950 | 7411 | fi |
5213506e RW |
7412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_prog_makeinfo_modern" >&5 |
7413 | $as_echo "$gcc_cv_prog_makeinfo_modern" >&6; } | |
00020c16 ILT |
7414 | else |
7415 | gcc_cv_prog_makeinfo_modern=no | |
7416 | fi | |
7417 | if test $gcc_cv_prog_makeinfo_modern = no; then | |
7418 | MAKEINFO="${CONFIG_SHELL-/bin/sh} $ac_aux_dir/missing makeinfo" | |
7419 | fi | |
956d6950 | 7420 | |
00020c16 | 7421 | if test $gcc_cv_prog_makeinfo_modern = no; then |
5213506e | 7422 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: |
00020c16 ILT |
7423 | *** Makeinfo is missing or too old. |
7424 | *** Info documentation will not be built." >&5 | |
5213506e | 7425 | $as_echo "$as_me: WARNING: |
00020c16 ILT |
7426 | *** Makeinfo is missing or too old. |
7427 | *** Info documentation will not be built." >&2;} | |
7428 | BUILD_INFO= | |
7429 | else | |
7430 | BUILD_INFO=info | |
956d6950 JL |
7431 | fi |
7432 | ||
63cf211a | 7433 | |
00020c16 | 7434 | # Is pod2man recent enough to regenerate manpages? |
5213506e RW |
7435 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for recent Pod::Man" >&5 |
7436 | $as_echo_n "checking for recent Pod::Man... " >&6; } | |
00020c16 | 7437 | if (perl -e 'use 1.10 Pod::Man') >/dev/null 2>&1; then |
5213506e RW |
7438 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
7439 | $as_echo "yes" >&6; } | |
00020c16 | 7440 | GENERATED_MANPAGES=generated-manpages |
956d6950 | 7441 | else |
5213506e RW |
7442 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7443 | $as_echo "no" >&6; } | |
00020c16 | 7444 | GENERATED_MANPAGES= |
956d6950 | 7445 | fi |
ba479fd2 | 7446 | |
956d6950 | 7447 | |
00020c16 | 7448 | MISSING="${CONFIG_SHELL-/bin/sh} $ac_aux_dir/missing" |
956d6950 | 7449 | |
00020c16 ILT |
7450 | # How about lex? |
7451 | for ac_prog in flex | |
7452 | do | |
7453 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
7454 | set dummy $ac_prog; ac_word=$2 | |
5213506e RW |
7455 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7456 | $as_echo_n "checking for $ac_word... " >&6; } | |
7457 | if test "${ac_cv_prog_FLEX+set}" = set; then : | |
7458 | $as_echo_n "(cached) " >&6 | |
956d6950 | 7459 | else |
00020c16 ILT |
7460 | if test -n "$FLEX"; then |
7461 | ac_cv_prog_FLEX="$FLEX" # Let the user override the test. | |
956d6950 | 7462 | else |
00020c16 ILT |
7463 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR |
7464 | for as_dir in $PATH | |
7465 | do | |
7466 | IFS=$as_save_IFS | |
7467 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7468 | for ac_exec_ext in '' $ac_executable_extensions; do |
7469 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7470 | ac_cv_prog_FLEX="$ac_prog" |
5213506e | 7471 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
00020c16 ILT |
7472 | break 2 |
7473 | fi | |
7474 | done | |
5213506e RW |
7475 | done |
7476 | IFS=$as_save_IFS | |
ba479fd2 | 7477 | |
956d6950 | 7478 | fi |
956d6950 | 7479 | fi |
00020c16 ILT |
7480 | FLEX=$ac_cv_prog_FLEX |
7481 | if test -n "$FLEX"; then | |
5213506e RW |
7482 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FLEX" >&5 |
7483 | $as_echo "$FLEX" >&6; } | |
00020c16 | 7484 | else |
5213506e RW |
7485 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7486 | $as_echo "no" >&6; } | |
00020c16 | 7487 | fi |
ba479fd2 | 7488 | |
5213506e | 7489 | |
00020c16 ILT |
7490 | test -n "$FLEX" && break |
7491 | done | |
7492 | test -n "$FLEX" || FLEX="$MISSING flex" | |
7493 | ||
7494 | ||
7495 | # Bison? | |
7496 | for ac_prog in bison | |
7497 | do | |
7498 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
7499 | set dummy $ac_prog; ac_word=$2 | |
5213506e RW |
7500 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7501 | $as_echo_n "checking for $ac_word... " >&6; } | |
7502 | if test "${ac_cv_prog_BISON+set}" = set; then : | |
7503 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7504 | else |
7505 | if test -n "$BISON"; then | |
7506 | ac_cv_prog_BISON="$BISON" # Let the user override the test. | |
7507 | else | |
7508 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7509 | for as_dir in $PATH | |
7510 | do | |
7511 | IFS=$as_save_IFS | |
7512 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7513 | for ac_exec_ext in '' $ac_executable_extensions; do |
7514 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7515 | ac_cv_prog_BISON="$ac_prog" |
5213506e | 7516 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
00020c16 ILT |
7517 | break 2 |
7518 | fi | |
7519 | done | |
5213506e RW |
7520 | done |
7521 | IFS=$as_save_IFS | |
956d6950 | 7522 | |
00020c16 ILT |
7523 | fi |
7524 | fi | |
7525 | BISON=$ac_cv_prog_BISON | |
7526 | if test -n "$BISON"; then | |
5213506e RW |
7527 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BISON" >&5 |
7528 | $as_echo "$BISON" >&6; } | |
00020c16 | 7529 | else |
5213506e RW |
7530 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7531 | $as_echo "no" >&6; } | |
956d6950 JL |
7532 | fi |
7533 | ||
5213506e | 7534 | |
00020c16 ILT |
7535 | test -n "$BISON" && break |
7536 | done | |
7537 | test -n "$BISON" || BISON="$MISSING bison" | |
7538 | ||
7539 | ||
7540 | # Binutils are not build modules, unlike bison/flex/makeinfo. So we | |
7541 | # check for build == host before using them. | |
7542 | ||
7543 | # NM | |
7544 | if test x${build} = x${host} && test -f $srcdir/../binutils/nm.c \ | |
7545 | && test -d ../binutils ; then | |
7546 | NM='$(objdir)/../binutils/nm-new' | |
7547 | else | |
7548 | # Extract the first word of "nm", so it can be a program name with args. | |
7549 | set dummy nm; ac_word=$2 | |
5213506e RW |
7550 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7551 | $as_echo_n "checking for $ac_word... " >&6; } | |
7552 | if test "${ac_cv_prog_NM+set}" = set; then : | |
7553 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7554 | else |
7555 | if test -n "$NM"; then | |
7556 | ac_cv_prog_NM="$NM" # Let the user override the test. | |
7557 | else | |
7558 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7559 | for as_dir in $PATH | |
7560 | do | |
7561 | IFS=$as_save_IFS | |
7562 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7563 | for ac_exec_ext in '' $ac_executable_extensions; do |
7564 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7565 | ac_cv_prog_NM="nm" |
5213506e | 7566 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
00020c16 ILT |
7567 | break 2 |
7568 | fi | |
7569 | done | |
5213506e RW |
7570 | done |
7571 | IFS=$as_save_IFS | |
00020c16 ILT |
7572 | |
7573 | test -z "$ac_cv_prog_NM" && ac_cv_prog_NM="${CONFIG_SHELL-/bin/sh} ${srcdir}/../missing nm" | |
7574 | fi | |
7575 | fi | |
7576 | NM=$ac_cv_prog_NM | |
7577 | if test -n "$NM"; then | |
5213506e RW |
7578 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 |
7579 | $as_echo "$NM" >&6; } | |
00020c16 | 7580 | else |
5213506e RW |
7581 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7582 | $as_echo "no" >&6; } | |
00020c16 ILT |
7583 | fi |
7584 | ||
5213506e | 7585 | |
00020c16 ILT |
7586 | fi |
7587 | ||
7588 | # AR | |
7589 | if test x${build} = x${host} && test -f $srcdir/../binutils/ar.c \ | |
7590 | && test -d ../binutils ; then | |
7591 | AR='$(objdir)/../binutils/ar' | |
7592 | else | |
7593 | # Extract the first word of "ar", so it can be a program name with args. | |
7594 | set dummy ar; ac_word=$2 | |
5213506e RW |
7595 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
7596 | $as_echo_n "checking for $ac_word... " >&6; } | |
7597 | if test "${ac_cv_prog_AR+set}" = set; then : | |
7598 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
7599 | else |
7600 | if test -n "$AR"; then | |
7601 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
7602 | else | |
7603 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
7604 | for as_dir in $PATH | |
7605 | do | |
7606 | IFS=$as_save_IFS | |
7607 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
7608 | for ac_exec_ext in '' $ac_executable_extensions; do |
7609 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
00020c16 | 7610 | ac_cv_prog_AR="ar" |
5213506e | 7611 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
00020c16 ILT |
7612 | break 2 |
7613 | fi | |
7614 | done | |
5213506e RW |
7615 | done |
7616 | IFS=$as_save_IFS | |
00020c16 ILT |
7617 | |
7618 | test -z "$ac_cv_prog_AR" && ac_cv_prog_AR="${CONFIG_SHELL-/bin/sh} ${srcdir}/../missing ar" | |
7619 | fi | |
7620 | fi | |
7621 | AR=$ac_cv_prog_AR | |
7622 | if test -n "$AR"; then | |
5213506e RW |
7623 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
7624 | $as_echo "$AR" >&6; } | |
00020c16 | 7625 | else |
5213506e RW |
7626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
7627 | $as_echo "no" >&6; } | |
00020c16 ILT |
7628 | fi |
7629 | ||
5213506e | 7630 | |
00020c16 ILT |
7631 | fi |
7632 | ||
7633 | ||
7634 | # -------------------- | |
7635 | # Checks for C headers | |
7636 | # -------------------- | |
7637 | ||
7638 | # Need to reject headers which give warnings, so that the -Werror bootstrap | |
7639 | # works later. *sigh* This needs to come before all header checks. | |
7640 | ||
7641 | ac_c_preproc_warn_flag=yes | |
7642 | ||
5213506e RW |
7643 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 |
7644 | $as_echo_n "checking for ANSI C header files... " >&6; } | |
7645 | if test "${ac_cv_header_stdc+set}" = set; then : | |
7646 | $as_echo_n "(cached) " >&6 | |
18fc9bd4 | 7647 | else |
5213506e | 7648 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
18fc9bd4 | 7649 | /* end confdefs.h. */ |
00020c16 ILT |
7650 | #include <stdlib.h> |
7651 | #include <stdarg.h> | |
18fc9bd4 | 7652 | #include <string.h> |
00020c16 ILT |
7653 | #include <float.h> |
7654 | ||
18fc9bd4 RG |
7655 | int |
7656 | main () | |
7657 | { | |
7658 | ||
7659 | ; | |
7660 | return 0; | |
7661 | } | |
7662 | _ACEOF | |
5213506e | 7663 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 | 7664 | ac_cv_header_stdc=yes |
18fc9bd4 | 7665 | else |
5213506e | 7666 | ac_cv_header_stdc=no |
18fc9bd4 | 7667 | fi |
5213506e | 7668 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
18fc9bd4 | 7669 | |
00020c16 ILT |
7670 | if test $ac_cv_header_stdc = yes; then |
7671 | # SunOS 4.x string.h does not declare mem*, contrary to ANSI. | |
5213506e | 7672 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
7673 | /* end confdefs.h. */ |
7674 | #include <string.h> | |
7675 | ||
18fc9bd4 | 7676 | _ACEOF |
00020c16 | 7677 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
5213506e RW |
7678 | $EGREP "memchr" >/dev/null 2>&1; then : |
7679 | ||
00020c16 ILT |
7680 | else |
7681 | ac_cv_header_stdc=no | |
7682 | fi | |
7683 | rm -f conftest* | |
18fc9bd4 RG |
7684 | |
7685 | fi | |
7686 | ||
00020c16 ILT |
7687 | if test $ac_cv_header_stdc = yes; then |
7688 | # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. | |
5213506e | 7689 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 7690 | /* end confdefs.h. */ |
00020c16 ILT |
7691 | #include <stdlib.h> |
7692 | ||
7693 | _ACEOF | |
7694 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | | |
5213506e RW |
7695 | $EGREP "free" >/dev/null 2>&1; then : |
7696 | ||
00020c16 ILT |
7697 | else |
7698 | ac_cv_header_stdc=no | |
7699 | fi | |
7700 | rm -f conftest* | |
7701 | ||
7702 | fi | |
7703 | ||
7704 | if test $ac_cv_header_stdc = yes; then | |
7705 | # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. | |
5213506e | 7706 | if test "$cross_compiling" = yes; then : |
00020c16 ILT |
7707 | : |
7708 | else | |
5213506e | 7709 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
7710 | /* end confdefs.h. */ |
7711 | #include <ctype.h> | |
5213506e | 7712 | #include <stdlib.h> |
00020c16 ILT |
7713 | #if ((' ' & 0x0FF) == 0x020) |
7714 | # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') | |
7715 | # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) | |
7716 | #else | |
7717 | # define ISLOWER(c) \ | |
7718 | (('a' <= (c) && (c) <= 'i') \ | |
7719 | || ('j' <= (c) && (c) <= 'r') \ | |
7720 | || ('s' <= (c) && (c) <= 'z')) | |
7721 | # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) | |
7722 | #endif | |
7723 | ||
7724 | #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) | |
7725 | int | |
7726 | main () | |
7727 | { | |
7728 | int i; | |
7729 | for (i = 0; i < 256; i++) | |
7730 | if (XOR (islower (i), ISLOWER (i)) | |
7731 | || toupper (i) != TOUPPER (i)) | |
5213506e RW |
7732 | return 2; |
7733 | return 0; | |
00020c16 ILT |
7734 | } |
7735 | _ACEOF | |
5213506e | 7736 | if ac_fn_c_try_run "$LINENO"; then : |
00020c16 | 7737 | |
5213506e RW |
7738 | else |
7739 | ac_cv_header_stdc=no | |
00020c16 | 7740 | fi |
5213506e RW |
7741 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
7742 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
00020c16 | 7743 | fi |
5213506e | 7744 | |
00020c16 ILT |
7745 | fi |
7746 | fi | |
5213506e RW |
7747 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 |
7748 | $as_echo "$ac_cv_header_stdc" >&6; } | |
00020c16 ILT |
7749 | if test $ac_cv_header_stdc = yes; then |
7750 | ||
5213506e | 7751 | $as_echo "#define STDC_HEADERS 1" >>confdefs.h |
00020c16 ILT |
7752 | |
7753 | fi | |
7754 | ||
5213506e RW |
7755 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether time.h and sys/time.h may both be included" >&5 |
7756 | $as_echo_n "checking whether time.h and sys/time.h may both be included... " >&6; } | |
7757 | if test "${ac_cv_header_time+set}" = set; then : | |
7758 | $as_echo_n "(cached) " >&6 | |
00020c16 | 7759 | else |
5213506e | 7760 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
7761 | /* end confdefs.h. */ |
7762 | #include <sys/types.h> | |
7763 | #include <sys/time.h> | |
7764 | #include <time.h> | |
7765 | ||
7766 | int | |
7767 | main () | |
7768 | { | |
7769 | if ((struct tm *) 0) | |
7770 | return 0; | |
7771 | ; | |
7772 | return 0; | |
7773 | } | |
7774 | _ACEOF | |
5213506e | 7775 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 ILT |
7776 | ac_cv_header_time=yes |
7777 | else | |
5213506e | 7778 | ac_cv_header_time=no |
00020c16 | 7779 | fi |
5213506e | 7780 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
00020c16 | 7781 | fi |
5213506e RW |
7782 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_time" >&5 |
7783 | $as_echo "$ac_cv_header_time" >&6; } | |
00020c16 ILT |
7784 | if test $ac_cv_header_time = yes; then |
7785 | ||
5213506e | 7786 | $as_echo "#define TIME_WITH_SYS_TIME 1" >>confdefs.h |
00020c16 ILT |
7787 | |
7788 | fi | |
7789 | ||
5213506e RW |
7790 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether string.h and strings.h may both be included" >&5 |
7791 | $as_echo_n "checking whether string.h and strings.h may both be included... " >&6; } | |
7792 | if test "${gcc_cv_header_string+set}" = set; then : | |
7793 | $as_echo_n "(cached) " >&6 | |
00020c16 | 7794 | else |
5213506e | 7795 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
7796 | /* end confdefs.h. */ |
7797 | #include <string.h> | |
7798 | #include <strings.h> | |
7799 | int | |
7800 | main () | |
7801 | { | |
7802 | ||
7803 | ; | |
7804 | return 0; | |
7805 | } | |
7806 | _ACEOF | |
5213506e | 7807 | if ac_fn_c_try_compile "$LINENO"; then : |
00020c16 ILT |
7808 | gcc_cv_header_string=yes |
7809 | else | |
5213506e | 7810 | gcc_cv_header_string=no |
00020c16 | 7811 | fi |
5213506e | 7812 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
00020c16 | 7813 | fi |
5213506e RW |
7814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_header_string" >&5 |
7815 | $as_echo "$gcc_cv_header_string" >&6; } | |
00020c16 ILT |
7816 | if test $gcc_cv_header_string = yes; then |
7817 | ||
5213506e | 7818 | $as_echo "#define STRING_WITH_STRINGS 1" >>confdefs.h |
00020c16 ILT |
7819 | |
7820 | fi | |
7821 | ||
5213506e RW |
7822 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sys/wait.h that is POSIX.1 compatible" >&5 |
7823 | $as_echo_n "checking for sys/wait.h that is POSIX.1 compatible... " >&6; } | |
7824 | if test "${ac_cv_header_sys_wait_h+set}" = set; then : | |
7825 | $as_echo_n "(cached) " >&6 | |
00020c16 | 7826 | else |
5213506e | 7827 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
7828 | /* end confdefs.h. */ |
7829 | #include <sys/types.h> | |
7830 | #include <sys/wait.h> | |
7831 | #ifndef WEXITSTATUS | |
5213506e | 7832 | # define WEXITSTATUS(stat_val) ((unsigned int) (stat_val) >> 8) |
e9831ca0 KG |
7833 | #endif |
7834 | #ifndef WIFEXITED | |
ba479fd2 | 7835 | # define WIFEXITED(stat_val) (((stat_val) & 255) == 0) |
e9831ca0 | 7836 | #endif |
ba479fd2 NN |
7837 | |
7838 | int | |
7839 | main () | |
7840 | { | |
7841 | int s; | |
7842 | wait (&s); | |
5213506e RW |
7843 | s = WIFEXITED (s) ? WEXITSTATUS (s) : 1; |
7844 | ; | |
7845 | return 0; | |
7846 | } | |
7847 | _ACEOF | |
7848 | if ac_fn_c_try_compile "$LINENO"; then : | |
7849 | ac_cv_header_sys_wait_h=yes | |
7850 | else | |
7851 | ac_cv_header_sys_wait_h=no | |
7852 | fi | |
7853 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
7854 | fi | |
7855 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_sys_wait_h" >&5 | |
7856 | $as_echo "$ac_cv_header_sys_wait_h" >&6; } | |
7857 | if test $ac_cv_header_sys_wait_h = yes; then | |
ba479fd2 | 7858 | |
5213506e | 7859 | $as_echo "#define HAVE_SYS_WAIT_H 1" >>confdefs.h |
ba479fd2 | 7860 | |
5213506e | 7861 | fi |
dfb77e37 KC |
7862 | |
7863 | for ac_header in limits.h stddef.h string.h strings.h stdlib.h time.h iconv.h \ | |
1072ec3f | 7864 | fcntl.h unistd.h sys/file.h sys/time.h sys/mman.h \ |
03c41c05 | 7865 | sys/resource.h sys/param.h sys/times.h sys/stat.h \ |
56694dd9 | 7866 | direct.h malloc.h langinfo.h ldfcn.h locale.h wchar.h |
5213506e RW |
7867 | do : |
7868 | as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` | |
7869 | ac_fn_c_check_header_preproc "$LINENO" "$ac_header" "$as_ac_Header" | |
7870 | eval as_val=\$$as_ac_Header | |
7871 | if test "x$as_val" = x""yes; then : | |
ba479fd2 | 7872 | cat >>confdefs.h <<_ACEOF |
5213506e | 7873 | #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 |
ba479fd2 NN |
7874 | _ACEOF |
7875 | ||
956d6950 JL |
7876 | fi |
7877 | done | |
7878 | ||
7879 | ||
f24af81b | 7880 | # Check for thread headers. |
5213506e RW |
7881 | ac_fn_c_check_header_preproc "$LINENO" "thread.h" "ac_cv_header_thread_h" |
7882 | if test "x$ac_cv_header_thread_h" = x""yes; then : | |
f24af81b TT |
7883 | have_thread_h=yes |
7884 | else | |
ba479fd2 | 7885 | have_thread_h= |
f24af81b TT |
7886 | fi |
7887 | ||
5213506e RW |
7888 | ac_fn_c_check_header_preproc "$LINENO" "pthread.h" "ac_cv_header_pthread_h" |
7889 | if test "x$ac_cv_header_pthread_h" = x""yes; then : | |
f24af81b TT |
7890 | have_pthread_h=yes |
7891 | else | |
ba479fd2 | 7892 | have_pthread_h= |
f24af81b TT |
7893 | fi |
7894 | ||
7895 | ||
84c041a1 | 7896 | # These tests can't be done till we know if we have limits.h. |
5213506e RW |
7897 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHAR_BIT" >&5 |
7898 | $as_echo_n "checking for CHAR_BIT... " >&6; } | |
7899 | if test "${gcc_cv_decl_char_bit+set}" = set; then : | |
7900 | $as_echo_n "(cached) " >&6 | |
ba479fd2 | 7901 | else |
5213506e | 7902 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 7903 | /* end confdefs.h. */ |
75e93faa ZW |
7904 | #ifdef HAVE_LIMITS_H |
7905 | #include <limits.h> | |
7906 | #endif | |
7907 | #ifdef CHAR_BIT | |
7908 | found | |
7909 | #endif | |
ba479fd2 | 7910 | _ACEOF |
75e93faa | 7911 | if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | |
5213506e | 7912 | $EGREP "found" >/dev/null 2>&1; then : |
75e93faa ZW |
7913 | gcc_cv_decl_char_bit=yes |
7914 | else | |
75e93faa ZW |
7915 | gcc_cv_decl_char_bit=no |
7916 | fi | |
7917 | rm -f conftest* | |
7918 | ||
7919 | ||
7920 | fi | |
5213506e RW |
7921 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_decl_char_bit" >&5 |
7922 | $as_echo "$gcc_cv_decl_char_bit" >&6; } | |
75e93faa | 7923 | if test $gcc_cv_decl_char_bit = no; then |
5213506e RW |
7924 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking number of bits in a byte" >&5 |
7925 | $as_echo_n "checking number of bits in a byte... " >&6; } | |
7926 | if test "${gcc_cv_c_nbby+set}" = set; then : | |
7927 | $as_echo_n "(cached) " >&6 | |
75e93faa ZW |
7928 | else |
7929 | i=8 | |
7930 | gcc_cv_c_nbby= | |
7931 | while test $i -lt 65; do | |
5213506e | 7932 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 NN |
7933 | /* end confdefs.h. */ |
7934 | ||
7935 | int | |
7936 | main () | |
7937 | { | |
4e70264f ZW |
7938 | switch(0) { |
7939 | case (unsigned char)((unsigned long)1 << $i) == ((unsigned long)1 << $i): | |
7940 | case (unsigned char)((unsigned long)1<<($i-1)) == ((unsigned long)1<<($i-1)): | |
7941 | ; } | |
ba479fd2 NN |
7942 | ; |
7943 | return 0; | |
7944 | } | |
7945 | _ACEOF | |
5213506e | 7946 | if ac_fn_c_try_compile "$LINENO"; then : |
4e70264f | 7947 | gcc_cv_c_nbby=$i; break |
75e93faa | 7948 | fi |
5213506e | 7949 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
75e93faa ZW |
7950 | i=`expr $i + 1` |
7951 | done | |
7952 | test -z "$gcc_cv_c_nbby" && gcc_cv_c_nbby=failed | |
7953 | ||
7954 | fi | |
5213506e RW |
7955 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_c_nbby" >&5 |
7956 | $as_echo "$gcc_cv_c_nbby" >&6; } | |
75e93faa | 7957 | if test $gcc_cv_c_nbby = failed; then |
5213506e | 7958 | as_fn_error "cannot determine number of bits in a byte" "$LINENO" 5 |
75e93faa | 7959 | else |
ba479fd2 NN |
7960 | |
7961 | cat >>confdefs.h <<_ACEOF | |
75e93faa | 7962 | #define CHAR_BIT $gcc_cv_c_nbby |
ba479fd2 | 7963 | _ACEOF |
75e93faa ZW |
7964 | |
7965 | fi | |
7966 | fi | |
5213506e RW |
7967 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 |
7968 | $as_echo_n "checking whether byte ordering is bigendian... " >&6; } | |
7969 | if test "${ac_cv_c_bigendian+set}" = set; then : | |
7970 | $as_echo_n "(cached) " >&6 | |
84c041a1 | 7971 | else |
5213506e RW |
7972 | ac_cv_c_bigendian=unknown |
7973 | # See if we're dealing with a universal compiler. | |
7974 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
7975 | /* end confdefs.h. */ | |
7976 | #ifndef __APPLE_CC__ | |
7977 | not a universal capable compiler | |
7978 | #endif | |
7979 | typedef int dummy; | |
7980 | ||
7981 | _ACEOF | |
7982 | if ac_fn_c_try_compile "$LINENO"; then : | |
7983 | ||
7984 | # Check for potential -arch flags. It is not universal unless | |
7985 | # there are at least two -arch flags with different values. | |
7986 | ac_arch= | |
7987 | ac_prev= | |
7988 | for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do | |
7989 | if test -n "$ac_prev"; then | |
7990 | case $ac_word in | |
7991 | i?86 | x86_64 | ppc | ppc64) | |
7992 | if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then | |
7993 | ac_arch=$ac_word | |
7994 | else | |
7995 | ac_cv_c_bigendian=universal | |
7996 | break | |
7997 | fi | |
7998 | ;; | |
7999 | esac | |
8000 | ac_prev= | |
8001 | elif test "x$ac_word" = "x-arch"; then | |
8002 | ac_prev=arch | |
8003 | fi | |
8004 | done | |
8005 | fi | |
8006 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8007 | if test $ac_cv_c_bigendian = unknown; then | |
8008 | # See if sys/param.h defines the BYTE_ORDER macro. | |
8009 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 8010 | /* end confdefs.h. */ |
4977bab6 | 8011 | #include <sys/types.h> |
5213506e | 8012 | #include <sys/param.h> |
9791c75c | 8013 | |
ba479fd2 NN |
8014 | int |
8015 | main () | |
8016 | { | |
5213506e RW |
8017 | #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ |
8018 | && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ | |
8019 | && LITTLE_ENDIAN) | |
8020 | bogus endian macros | |
8021 | #endif | |
9791c75c | 8022 | |
ba479fd2 NN |
8023 | ; |
8024 | return 0; | |
8025 | } | |
8026 | _ACEOF | |
5213506e | 8027 | if ac_fn_c_try_compile "$LINENO"; then : |
2f41c1d6 | 8028 | # It does; now see whether it defined to BIG_ENDIAN or not. |
5213506e | 8029 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8030 | /* end confdefs.h. */ |
4977bab6 | 8031 | #include <sys/types.h> |
5213506e | 8032 | #include <sys/param.h> |
9791c75c | 8033 | |
ba479fd2 NN |
8034 | int |
8035 | main () | |
8036 | { | |
4977bab6 | 8037 | #if BYTE_ORDER != BIG_ENDIAN |
5213506e RW |
8038 | not big endian |
8039 | #endif | |
9791c75c | 8040 | |
ba479fd2 NN |
8041 | ; |
8042 | return 0; | |
8043 | } | |
8044 | _ACEOF | |
5213506e | 8045 | if ac_fn_c_try_compile "$LINENO"; then : |
b61ff9c8 BS |
8046 | ac_cv_c_bigendian=yes |
8047 | else | |
5213506e | 8048 | ac_cv_c_bigendian=no |
4977bab6 | 8049 | fi |
5213506e RW |
8050 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
8051 | fi | |
8052 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext | |
8053 | fi | |
8054 | if test $ac_cv_c_bigendian = unknown; then | |
8055 | # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). | |
8056 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8057 | /* end confdefs.h. */ | |
8058 | #include <limits.h> | |
ba479fd2 | 8059 | |
5213506e RW |
8060 | int |
8061 | main () | |
8062 | { | |
8063 | #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) | |
8064 | bogus endian macros | |
8065 | #endif | |
8066 | ||
8067 | ; | |
8068 | return 0; | |
8069 | } | |
9791c75c | 8070 | _ACEOF |
5213506e RW |
8071 | if ac_fn_c_try_compile "$LINENO"; then : |
8072 | # It does; now see whether it defined to _BIG_ENDIAN or not. | |
8073 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
9791c75c | 8074 | /* end confdefs.h. */ |
5213506e RW |
8075 | #include <limits.h> |
8076 | ||
9791c75c KC |
8077 | int |
8078 | main () | |
8079 | { | |
5213506e RW |
8080 | #ifndef _BIG_ENDIAN |
8081 | not big endian | |
8082 | #endif | |
8083 | ||
9791c75c KC |
8084 | ; |
8085 | return 0; | |
8086 | } | |
8087 | _ACEOF | |
5213506e | 8088 | if ac_fn_c_try_compile "$LINENO"; then : |
8b1f719a | 8089 | ac_cv_c_bigendian=yes |
5213506e RW |
8090 | else |
8091 | ac_cv_c_bigendian=no | |
8b1f719a | 8092 | fi |
5213506e | 8093 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
9791c75c | 8094 | fi |
5213506e RW |
8095 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
8096 | fi | |
8097 | if test $ac_cv_c_bigendian = unknown; then | |
8098 | # Compile a test program. | |
8099 | if test "$cross_compiling" = yes; then : | |
8100 | # Try to guess by grepping values from an object file. | |
8101 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
8102 | /* end confdefs.h. */ | |
8103 | short int ascii_mm[] = | |
8104 | { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; | |
8105 | short int ascii_ii[] = | |
8106 | { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; | |
8107 | int use_ascii (int i) { | |
8108 | return ascii_mm[i] + ascii_ii[i]; | |
8109 | } | |
8110 | short int ebcdic_ii[] = | |
8111 | { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; | |
8112 | short int ebcdic_mm[] = | |
8113 | { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; | |
8114 | int use_ebcdic (int i) { | |
8115 | return ebcdic_mm[i] + ebcdic_ii[i]; | |
8116 | } | |
8117 | extern int foo; | |
9791c75c | 8118 | |
5213506e RW |
8119 | int |
8120 | main () | |
8121 | { | |
8122 | return use_ascii (foo) == use_ebcdic (foo); | |
8123 | ; | |
8124 | return 0; | |
8125 | } | |
8126 | _ACEOF | |
8127 | if ac_fn_c_try_compile "$LINENO"; then : | |
8128 | if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then | |
8129 | ac_cv_c_bigendian=yes | |
8130 | fi | |
8131 | if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then | |
8132 | if test "$ac_cv_c_bigendian" = unknown; then | |
8133 | ac_cv_c_bigendian=no | |
8134 | else | |
8135 | # finding both strings is unlikely to happen, but who knows? | |
8136 | ac_cv_c_bigendian=unknown | |
8137 | fi | |
8138 | fi | |
4977bab6 | 8139 | fi |
5213506e | 8140 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
ba479fd2 | 8141 | else |
5213506e | 8142 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8143 | /* end confdefs.h. */ |
5213506e | 8144 | $ac_includes_default |
9791c75c KC |
8145 | int |
8146 | main () | |
8147 | { | |
5213506e RW |
8148 | |
8149 | /* Are we little or big endian? From Harbison&Steele. */ | |
8150 | union | |
8151 | { | |
8152 | long int l; | |
8153 | char c[sizeof (long int)]; | |
8154 | } u; | |
8155 | u.l = 1; | |
8156 | return u.c[sizeof (long int) - 1] == 1; | |
8157 | ||
8158 | ; | |
8159 | return 0; | |
4977bab6 | 8160 | } |
ba479fd2 | 8161 | _ACEOF |
5213506e | 8162 | if ac_fn_c_try_run "$LINENO"; then : |
4977bab6 ZW |
8163 | ac_cv_c_bigendian=no |
8164 | else | |
5213506e | 8165 | ac_cv_c_bigendian=yes |
4977bab6 | 8166 | fi |
5213506e RW |
8167 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
8168 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
4977bab6 | 8169 | fi |
ba479fd2 | 8170 | |
5213506e RW |
8171 | fi |
8172 | fi | |
8173 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 | |
8174 | $as_echo "$ac_cv_c_bigendian" >&6; } | |
8175 | case $ac_cv_c_bigendian in #( | |
8176 | yes) | |
8177 | $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h | |
8178 | ;; #( | |
8179 | no) | |
8180 | ;; #( | |
8181 | universal) | |
8182 | ||
8183 | $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h | |
8184 | ||
8185 | ;; #( | |
8186 | *) | |
8187 | as_fn_error "unknown endianness | |
8188 | presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5 ;; | |
8189 | esac | |
84c041a1 | 8190 | |
75e93faa | 8191 | |
73458fb7 NN |
8192 | # -------- |
8193 | # UNSORTED | |
8194 | # -------- | |
1e608388 | 8195 | |
1e608388 | 8196 | |
4e70264f ZW |
8197 | # These libraries may be used by collect2. |
8198 | # We may need a special search path to get them linked. | |
5213506e RW |
8199 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for collect2 libraries" >&5 |
8200 | $as_echo_n "checking for collect2 libraries... " >&6; } | |
8201 | if test "${gcc_cv_collect2_libs+set}" = set; then : | |
8202 | $as_echo_n "(cached) " >&6 | |
4e70264f ZW |
8203 | else |
8204 | save_LIBS="$LIBS" | |
7f2749d4 | 8205 | for libs in '' -lld -lmld \ |
4e70264f ZW |
8206 | '-L/usr/lib/cmplrs/cc2.11 -lmld' \ |
8207 | '-L/usr/lib/cmplrs/cc3.11 -lmld' | |
8208 | do | |
8209 | LIBS="$libs" | |
5213506e | 8210 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 NN |
8211 | /* end confdefs.h. */ |
8212 | ||
5213506e RW |
8213 | /* Override any GCC internal prototype to avoid an error. |
8214 | Use char because int might match the return type of a GCC | |
8215 | builtin and then its argument prototype would still apply. */ | |
ba479fd2 NN |
8216 | #ifdef __cplusplus |
8217 | extern "C" | |
8218 | #endif | |
ba479fd2 NN |
8219 | char ldopen (); |
8220 | int | |
8221 | main () | |
8222 | { | |
5213506e | 8223 | return ldopen (); |
ba479fd2 NN |
8224 | ; |
8225 | return 0; | |
8226 | } | |
8227 | _ACEOF | |
5213506e | 8228 | if ac_fn_c_try_link "$LINENO"; then : |
4e70264f | 8229 | gcc_cv_collect2_libs="$libs"; break |
4e70264f | 8230 | fi |
5213506e RW |
8231 | rm -f core conftest.err conftest.$ac_objext \ |
8232 | conftest$ac_exeext conftest.$ac_ext | |
4e70264f ZW |
8233 | done |
8234 | LIBS="$save_LIBS" | |
8235 | test -z "$gcc_cv_collect2_libs" && gcc_cv_collect2_libs='none required' | |
8236 | fi | |
5213506e RW |
8237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_collect2_libs" >&5 |
8238 | $as_echo "$gcc_cv_collect2_libs" >&6; } | |
4e70264f ZW |
8239 | case $gcc_cv_collect2_libs in |
8240 | "none required") ;; | |
8241 | *) COLLECT2_LIBS=$gcc_cv_collect2_libs ;; | |
8242 | esac | |
8243 | ||
8244 | ||
7f2749d4 RK |
8245 | # When building Ada code on Alpha, we need exc_resume which is usually in |
8246 | # -lexc. So test for it. | |
8247 | save_LIBS="$LIBS" | |
8248 | LIBS= | |
5213506e RW |
8249 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing exc_resume" >&5 |
8250 | $as_echo_n "checking for library containing exc_resume... " >&6; } | |
8251 | if test "${ac_cv_search_exc_resume+set}" = set; then : | |
8252 | $as_echo_n "(cached) " >&6 | |
ba479fd2 NN |
8253 | else |
8254 | ac_func_search_save_LIBS=$LIBS | |
5213506e | 8255 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8256 | /* end confdefs.h. */ |
7f2749d4 | 8257 | |
5213506e RW |
8258 | /* Override any GCC internal prototype to avoid an error. |
8259 | Use char because int might match the return type of a GCC | |
b61ff9c8 | 8260 | builtin and then its argument prototype would still apply. */ |
b61ff9c8 BS |
8261 | #ifdef __cplusplus |
8262 | extern "C" | |
8263 | #endif | |
b61ff9c8 BS |
8264 | char exc_resume (); |
8265 | int | |
8266 | main () | |
8267 | { | |
5213506e | 8268 | return exc_resume (); |
b61ff9c8 BS |
8269 | ; |
8270 | return 0; | |
8271 | } | |
8272 | _ACEOF | |
5213506e RW |
8273 | for ac_lib in '' exc; do |
8274 | if test -z "$ac_lib"; then | |
8275 | ac_res="none required" | |
8276 | else | |
8277 | ac_res=-l$ac_lib | |
8278 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
8279 | fi | |
8280 | if ac_fn_c_try_link "$LINENO"; then : | |
8281 | ac_cv_search_exc_resume=$ac_res | |
b8ec3cc8 | 8282 | fi |
5213506e RW |
8283 | rm -f core conftest.err conftest.$ac_objext \ |
8284 | conftest$ac_exeext | |
8285 | if test "${ac_cv_search_exc_resume+set}" = set; then : | |
8286 | break | |
b8ec3cc8 | 8287 | fi |
5213506e RW |
8288 | done |
8289 | if test "${ac_cv_search_exc_resume+set}" = set; then : | |
8290 | ||
dd7f7a6e | 8291 | else |
5213506e RW |
8292 | ac_cv_search_exc_resume=no |
8293 | fi | |
8294 | rm conftest.$ac_ext | |
8295 | LIBS=$ac_func_search_save_LIBS | |
8296 | fi | |
8297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_exc_resume" >&5 | |
8298 | $as_echo "$ac_cv_search_exc_resume" >&6; } | |
8299 | ac_res=$ac_cv_search_exc_resume | |
8300 | if test "$ac_res" != no; then : | |
8301 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
dd7f7a6e | 8302 | |
1a4b763e | 8303 | fi |
5213506e RW |
8304 | |
8305 | GNAT_LIBEXC="$LIBS" | |
8306 | LIBS="$save_LIBS" | |
8307 | ||
8308 | ||
8309 | # Some systems put ldexp and frexp in libm instead of libc; assume | |
8310 | # they're both in the same place. jcf-dump needs them. | |
8311 | save_LIBS="$LIBS" | |
8312 | LIBS= | |
8313 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing ldexp" >&5 | |
8314 | $as_echo_n "checking for library containing ldexp... " >&6; } | |
8315 | if test "${ac_cv_search_ldexp+set}" = set; then : | |
8316 | $as_echo_n "(cached) " >&6 | |
8317 | else | |
8318 | ac_func_search_save_LIBS=$LIBS | |
8319 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
b61ff9c8 | 8320 | /* end confdefs.h. */ |
2f41c1d6 | 8321 | |
5213506e RW |
8322 | /* Override any GCC internal prototype to avoid an error. |
8323 | Use char because int might match the return type of a GCC | |
8324 | builtin and then its argument prototype would still apply. */ | |
b61ff9c8 BS |
8325 | #ifdef __cplusplus |
8326 | extern "C" | |
8327 | #endif | |
b61ff9c8 BS |
8328 | char ldexp (); |
8329 | int | |
8330 | main () | |
8331 | { | |
5213506e | 8332 | return ldexp (); |
b61ff9c8 BS |
8333 | ; |
8334 | return 0; | |
8335 | } | |
8336 | _ACEOF | |
5213506e RW |
8337 | for ac_lib in '' m; do |
8338 | if test -z "$ac_lib"; then | |
8339 | ac_res="none required" | |
8340 | else | |
8341 | ac_res=-l$ac_lib | |
8342 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
8343 | fi | |
8344 | if ac_fn_c_try_link "$LINENO"; then : | |
8345 | ac_cv_search_ldexp=$ac_res | |
b61ff9c8 | 8346 | fi |
5213506e RW |
8347 | rm -f core conftest.err conftest.$ac_objext \ |
8348 | conftest$ac_exeext | |
8349 | if test "${ac_cv_search_ldexp+set}" = set; then : | |
8350 | break | |
8351 | fi | |
8352 | done | |
8353 | if test "${ac_cv_search_ldexp+set}" = set; then : | |
8354 | ||
8355 | else | |
8356 | ac_cv_search_ldexp=no | |
dd7f7a6e | 8357 | fi |
5213506e | 8358 | rm conftest.$ac_ext |
dd7f7a6e EC |
8359 | LIBS=$ac_func_search_save_LIBS |
8360 | fi | |
5213506e RW |
8361 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_ldexp" >&5 |
8362 | $as_echo "$ac_cv_search_ldexp" >&6; } | |
8363 | ac_res=$ac_cv_search_ldexp | |
8364 | if test "$ac_res" != no; then : | |
8365 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
dd7f7a6e EC |
8366 | |
8367 | fi | |
8368 | ||
8369 | LDEXP_LIB="$LIBS" | |
8370 | LIBS="$save_LIBS" | |
8371 | ||
8372 | ||
8373 | # Use <inttypes.h> only if it exists, | |
8374 | # doesn't clash with <sys/types.h>, and declares intmax_t. | |
5213506e RW |
8375 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inttypes.h" >&5 |
8376 | $as_echo_n "checking for inttypes.h... " >&6; } | |
8377 | if test "${gcc_cv_header_inttypes_h+set}" = set; then : | |
8378 | $as_echo_n "(cached) " >&6 | |
dd7f7a6e | 8379 | else |
5213506e | 8380 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
dd7f7a6e EC |
8381 | /* end confdefs.h. */ |
8382 | #include <sys/types.h> | |
8383 | #include <inttypes.h> | |
8384 | int | |
8385 | main () | |
8386 | { | |
8387 | intmax_t i = -1; | |
8388 | ; | |
8389 | return 0; | |
8390 | } | |
8391 | _ACEOF | |
5213506e | 8392 | if ac_fn_c_try_compile "$LINENO"; then : |
dd7f7a6e EC |
8393 | gcc_cv_header_inttypes_h=yes |
8394 | else | |
5213506e | 8395 | gcc_cv_header_inttypes_h=no |
dd7f7a6e | 8396 | fi |
5213506e | 8397 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
dd7f7a6e EC |
8398 | fi |
8399 | ||
5213506e RW |
8400 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_header_inttypes_h" >&5 |
8401 | $as_echo "$gcc_cv_header_inttypes_h" >&6; } | |
dd7f7a6e EC |
8402 | if test $gcc_cv_header_inttypes_h = yes; then |
8403 | ||
5213506e | 8404 | $as_echo "#define HAVE_INTTYPES_H 1" >>confdefs.h |
dd7f7a6e | 8405 | |
0056a9b5 | 8406 | fi |
956d6950 | 8407 | |
c149cc37 | 8408 | |
ba479fd2 | 8409 | |
52a6edcc | 8410 | for ac_func in times clock kill getrlimit setrlimit atoll atoq \ |
d2e506f2 | 8411 | sysconf strsignal getrusage nl_langinfo \ |
0d667716 KG |
8412 | gettimeofday mbstowcs wcswidth mmap mincore setlocale \ |
8413 | clearerr_unlocked feof_unlocked ferror_unlocked fflush_unlocked fgetc_unlocked fgets_unlocked fileno_unlocked fprintf_unlocked fputc_unlocked fputs_unlocked fread_unlocked fwrite_unlocked getchar_unlocked getc_unlocked putchar_unlocked putc_unlocked | |
5213506e RW |
8414 | do : |
8415 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
8416 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
8417 | eval as_val=\$$as_ac_var | |
8418 | if test "x$as_val" = x""yes; then : | |
ba479fd2 | 8419 | cat >>confdefs.h <<_ACEOF |
5213506e | 8420 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
ba479fd2 | 8421 | _ACEOF |
956d6950 | 8422 | |
956d6950 JL |
8423 | fi |
8424 | done | |
8425 | ||
6885fc87 | 8426 | |
39f6c4c8 | 8427 | if test x$ac_cv_func_mbstowcs = xyes; then |
5213506e RW |
8428 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mbstowcs works" >&5 |
8429 | $as_echo_n "checking whether mbstowcs works... " >&6; } | |
8430 | if test "${gcc_cv_func_mbstowcs_works+set}" = set; then : | |
8431 | $as_echo_n "(cached) " >&6 | |
39f6c4c8 | 8432 | else |
5213506e | 8433 | if test "$cross_compiling" = yes; then : |
39f6c4c8 KW |
8434 | gcc_cv_func_mbstowcs_works=yes |
8435 | else | |
5213506e | 8436 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8437 | /* end confdefs.h. */ |
39f6c4c8 KW |
8438 | #include <stdlib.h> |
8439 | int main() | |
8440 | { | |
8441 | mbstowcs(0, "", 0); | |
8442 | return 0; | |
8443 | } | |
ba479fd2 | 8444 | _ACEOF |
5213506e | 8445 | if ac_fn_c_try_run "$LINENO"; then : |
39f6c4c8 KW |
8446 | gcc_cv_func_mbstowcs_works=yes |
8447 | else | |
5213506e | 8448 | gcc_cv_func_mbstowcs_works=no |
39f6c4c8 | 8449 | fi |
5213506e RW |
8450 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
8451 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
39f6c4c8 | 8452 | fi |
5213506e | 8453 | |
39f6c4c8 | 8454 | fi |
5213506e RW |
8455 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_func_mbstowcs_works" >&5 |
8456 | $as_echo "$gcc_cv_func_mbstowcs_works" >&6; } | |
63cf211a | 8457 | if test x$gcc_cv_func_mbstowcs_works = xyes; then |
ba479fd2 | 8458 | |
5213506e | 8459 | $as_echo "#define HAVE_WORKING_MBSTOWCS 1" >>confdefs.h |
39f6c4c8 KW |
8460 | |
8461 | fi | |
8462 | fi | |
8463 | ||
5213506e RW |
8464 | ac_fn_c_check_type "$LINENO" "ssize_t" "ac_cv_type_ssize_t" "$ac_includes_default" |
8465 | if test "x$ac_cv_type_ssize_t" = x""yes; then : | |
6e3f3080 | 8466 | |
8b4fc07a | 8467 | else |
ba479fd2 | 8468 | |
8b4fc07a | 8469 | cat >>confdefs.h <<_ACEOF |
f12bc141 | 8470 | #define ssize_t int |
ba479fd2 | 8471 | _ACEOF |
f12bc141 ZW |
8472 | |
8473 | fi | |
8474 | ||
5213506e RW |
8475 | ac_fn_c_check_type "$LINENO" "caddr_t" "ac_cv_type_caddr_t" "$ac_includes_default" |
8476 | if test "x$ac_cv_type_caddr_t" = x""yes; then : | |
bba09b5a | 8477 | |
bba09b5a AT |
8478 | else |
8479 | ||
8480 | cat >>confdefs.h <<_ACEOF | |
8481 | #define caddr_t char * | |
8482 | _ACEOF | |
8483 | ||
8484 | fi | |
8485 | ||
0b9d02c6 | 8486 | |
3b0727a0 | 8487 | |
5213506e RW |
8488 | ac_fn_c_check_header_preproc "$LINENO" "sys/mman.h" "ac_cv_header_sys_mman_h" |
8489 | if test "x$ac_cv_header_sys_mman_h" = x""yes; then : | |
3b0727a0 MR |
8490 | gcc_header_sys_mman_h=yes |
8491 | else | |
8492 | gcc_header_sys_mman_h=no | |
8493 | fi | |
5213506e RW |
8494 | |
8495 | ac_fn_c_check_func "$LINENO" "mmap" "ac_cv_func_mmap" | |
8496 | if test "x$ac_cv_func_mmap" = x""yes; then : | |
3b0727a0 MR |
8497 | gcc_func_mmap=yes |
8498 | else | |
8499 | gcc_func_mmap=no | |
8500 | fi | |
8501 | ||
8502 | if test "$gcc_header_sys_mman_h" != yes \ | |
8503 | || test "$gcc_func_mmap" != yes; then | |
1072ec3f ZW |
8504 | gcc_cv_func_mmap_file=no |
8505 | gcc_cv_func_mmap_dev_zero=no | |
8506 | gcc_cv_func_mmap_anon=no | |
8507 | else | |
5213506e RW |
8508 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether read-only mmap of a plain file works" >&5 |
8509 | $as_echo_n "checking whether read-only mmap of a plain file works... " >&6; } | |
8510 | if test "${gcc_cv_func_mmap_file+set}" = set; then : | |
8511 | $as_echo_n "(cached) " >&6 | |
1072ec3f | 8512 | else |
ba479fd2 | 8513 | # Add a system to this blacklist if |
1072ec3f ZW |
8514 | # mmap(0, stat_size, PROT_READ, MAP_PRIVATE, fd, 0) doesn't return a |
8515 | # memory area containing the same data that you'd get if you applied | |
8516 | # read() to the same fd. The only system known to have a problem here | |
8517 | # is VMS, where text files have record structure. | |
8518 | case "$host_os" in | |
ba479fd2 | 8519 | vms* | ultrix*) |
1072ec3f ZW |
8520 | gcc_cv_func_mmap_file=no ;; |
8521 | *) | |
8522 | gcc_cv_func_mmap_file=yes;; | |
8523 | esac | |
8524 | fi | |
5213506e RW |
8525 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_func_mmap_file" >&5 |
8526 | $as_echo "$gcc_cv_func_mmap_file" >&6; } | |
8527 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mmap from /dev/zero works" >&5 | |
8528 | $as_echo_n "checking whether mmap from /dev/zero works... " >&6; } | |
8529 | if test "${gcc_cv_func_mmap_dev_zero+set}" = set; then : | |
8530 | $as_echo_n "(cached) " >&6 | |
1072ec3f ZW |
8531 | else |
8532 | # Add a system to this blacklist if it has mmap() but /dev/zero | |
8533 | # does not exist, or if mmapping /dev/zero does not give anonymous | |
8534 | # zeroed pages with both the following properties: | |
8535 | # 1. If you map N consecutive pages in with one call, and then | |
8536 | # unmap any subset of those pages, the pages that were not | |
8537 | # explicitly unmapped remain accessible. | |
8538 | # 2. If you map two adjacent blocks of memory and then unmap them | |
8539 | # both at once, they must both go away. | |
8540 | # Systems known to be in this category are Windows (all variants), | |
8541 | # VMS, and Darwin. | |
8542 | case "$host_os" in | |
2ce240d3 | 8543 | vms* | cygwin* | pe | mingw* | darwin* | ultrix* | hpux10* | hpux11.00) |
1072ec3f ZW |
8544 | gcc_cv_func_mmap_dev_zero=no ;; |
8545 | *) | |
8546 | gcc_cv_func_mmap_dev_zero=yes;; | |
8547 | esac | |
8548 | fi | |
5213506e RW |
8549 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_func_mmap_dev_zero" >&5 |
8550 | $as_echo "$gcc_cv_func_mmap_dev_zero" >&6; } | |
1072ec3f ZW |
8551 | |
8552 | # Unlike /dev/zero, the MAP_ANON(YMOUS) defines can be probed for. | |
5213506e RW |
8553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAP_ANON(YMOUS)" >&5 |
8554 | $as_echo_n "checking for MAP_ANON(YMOUS)... " >&6; } | |
8555 | if test "${gcc_cv_decl_map_anon+set}" = set; then : | |
8556 | $as_echo_n "(cached) " >&6 | |
ba479fd2 | 8557 | else |
5213506e | 8558 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8559 | /* end confdefs.h. */ |
1072ec3f ZW |
8560 | #include <sys/types.h> |
8561 | #include <sys/mman.h> | |
8562 | #include <unistd.h> | |
8563 | ||
8564 | #ifndef MAP_ANONYMOUS | |
8565 | #define MAP_ANONYMOUS MAP_ANON | |
8566 | #endif | |
8567 | ||
ba479fd2 NN |
8568 | int |
8569 | main () | |
8570 | { | |
1072ec3f | 8571 | int n = MAP_ANONYMOUS; |
ba479fd2 NN |
8572 | ; |
8573 | return 0; | |
8574 | } | |
8575 | _ACEOF | |
5213506e | 8576 | if ac_fn_c_try_compile "$LINENO"; then : |
1072ec3f ZW |
8577 | gcc_cv_decl_map_anon=yes |
8578 | else | |
5213506e | 8579 | gcc_cv_decl_map_anon=no |
1072ec3f | 8580 | fi |
5213506e | 8581 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
1072ec3f | 8582 | fi |
5213506e RW |
8583 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_decl_map_anon" >&5 |
8584 | $as_echo "$gcc_cv_decl_map_anon" >&6; } | |
1072ec3f ZW |
8585 | |
8586 | if test $gcc_cv_decl_map_anon = no; then | |
8587 | gcc_cv_func_mmap_anon=no | |
8588 | else | |
5213506e RW |
8589 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mmap with MAP_ANON(YMOUS) works" >&5 |
8590 | $as_echo_n "checking whether mmap with MAP_ANON(YMOUS) works... " >&6; } | |
8591 | if test "${gcc_cv_func_mmap_anon+set}" = set; then : | |
8592 | $as_echo_n "(cached) " >&6 | |
1072ec3f ZW |
8593 | else |
8594 | # Add a system to this blacklist if it has mmap() and MAP_ANON or | |
8595 | # MAP_ANONYMOUS, but using mmap(..., MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) | |
8596 | # doesn't give anonymous zeroed pages with the same properties listed | |
8597 | # above for use of /dev/zero. | |
8598 | # Systems known to be in this category are Windows, VMS, and SCO Unix. | |
8599 | case "$host_os" in | |
8600 | vms* | cygwin* | pe | mingw* | sco* | udk* ) | |
8601 | gcc_cv_func_mmap_anon=no ;; | |
8602 | *) | |
8603 | gcc_cv_func_mmap_anon=yes;; | |
8604 | esac | |
8605 | fi | |
5213506e RW |
8606 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_func_mmap_anon" >&5 |
8607 | $as_echo "$gcc_cv_func_mmap_anon" >&6; } | |
1072ec3f ZW |
8608 | fi |
8609 | fi | |
8610 | ||
8611 | if test $gcc_cv_func_mmap_file = yes; then | |
ba479fd2 | 8612 | |
5213506e | 8613 | $as_echo "#define HAVE_MMAP_FILE 1" >>confdefs.h |
1072ec3f ZW |
8614 | |
8615 | fi | |
8616 | if test $gcc_cv_func_mmap_dev_zero = yes; then | |
ba479fd2 | 8617 | |
5213506e | 8618 | $as_echo "#define HAVE_MMAP_DEV_ZERO 1" >>confdefs.h |
1072ec3f ZW |
8619 | |
8620 | fi | |
8621 | if test $gcc_cv_func_mmap_anon = yes; then | |
ba479fd2 | 8622 | |
5213506e | 8623 | $as_echo "#define HAVE_MMAP_ANON 1" >>confdefs.h |
1072ec3f ZW |
8624 | |
8625 | fi | |
8626 | ||
b27d2bd5 MK |
8627 | |
8628 | case "${host}" in | |
ee262b6f | 8629 | *-*-*vms*) |
ba479fd2 | 8630 | # Under VMS, vfork works very differently than on Unix. The standard test |
ee262b6f DR |
8631 | # won't work, and it isn't easily adaptable. It makes more sense to |
8632 | # just force it. | |
8633 | ac_cv_func_vfork_works=yes | |
8634 | ;; | |
b27d2bd5 | 8635 | esac |
5213506e RW |
8636 | ac_fn_c_check_type "$LINENO" "pid_t" "ac_cv_type_pid_t" "$ac_includes_default" |
8637 | if test "x$ac_cv_type_pid_t" = x""yes; then : | |
6e3f3080 | 8638 | |
ba479fd2 NN |
8639 | else |
8640 | ||
8641 | cat >>confdefs.h <<_ACEOF | |
c375c43b | 8642 | #define pid_t int |
ba479fd2 | 8643 | _ACEOF |
c375c43b KG |
8644 | |
8645 | fi | |
8646 | ||
5213506e RW |
8647 | for ac_header in vfork.h |
8648 | do : | |
8649 | ac_fn_c_check_header_preproc "$LINENO" "vfork.h" "ac_cv_header_vfork_h" | |
8650 | if test "x$ac_cv_header_vfork_h" = x""yes; then : | |
ba479fd2 | 8651 | cat >>confdefs.h <<_ACEOF |
5213506e | 8652 | #define HAVE_VFORK_H 1 |
ba479fd2 | 8653 | _ACEOF |
6e3f3080 NN |
8654 | |
8655 | fi | |
ba479fd2 NN |
8656 | done |
8657 | ||
ba479fd2 | 8658 | for ac_func in fork vfork |
5213506e RW |
8659 | do : |
8660 | as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh` | |
8661 | ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var" | |
8662 | eval as_val=\$$as_ac_var | |
8663 | if test "x$as_val" = x""yes; then : | |
ba479fd2 | 8664 | cat >>confdefs.h <<_ACEOF |
5213506e | 8665 | #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1 |
ba479fd2 NN |
8666 | _ACEOF |
8667 | ||
c375c43b | 8668 | fi |
ba479fd2 | 8669 | done |
c375c43b | 8670 | |
ba479fd2 | 8671 | if test "x$ac_cv_func_fork" = xyes; then |
5213506e RW |
8672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working fork" >&5 |
8673 | $as_echo_n "checking for working fork... " >&6; } | |
8674 | if test "${ac_cv_func_fork_works+set}" = set; then : | |
8675 | $as_echo_n "(cached) " >&6 | |
c375c43b | 8676 | else |
5213506e | 8677 | if test "$cross_compiling" = yes; then : |
ba479fd2 NN |
8678 | ac_cv_func_fork_works=cross |
8679 | else | |
5213506e RW |
8680 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
8681 | /* end confdefs.h. */ | |
8682 | $ac_includes_default | |
8683 | int | |
8684 | main () | |
8685 | { | |
8686 | ||
8687 | /* By Ruediger Kuhlmann. */ | |
8688 | return fork () < 0; | |
8689 | ||
8690 | ; | |
8691 | return 0; | |
8692 | } | |
1a4b763e | 8693 | _ACEOF |
5213506e | 8694 | if ac_fn_c_try_run "$LINENO"; then : |
ba479fd2 NN |
8695 | ac_cv_func_fork_works=yes |
8696 | else | |
5213506e | 8697 | ac_cv_func_fork_works=no |
ba479fd2 | 8698 | fi |
5213506e RW |
8699 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
8700 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
ba479fd2 | 8701 | fi |
5213506e | 8702 | |
ba479fd2 | 8703 | fi |
5213506e RW |
8704 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_fork_works" >&5 |
8705 | $as_echo "$ac_cv_func_fork_works" >&6; } | |
ba479fd2 NN |
8706 | |
8707 | else | |
8708 | ac_cv_func_fork_works=$ac_cv_func_fork | |
8709 | fi | |
8710 | if test "x$ac_cv_func_fork_works" = xcross; then | |
8711 | case $host in | |
8712 | *-*-amigaos* | *-*-msdosdjgpp*) | |
8713 | # Override, as these systems have only a dummy fork() stub | |
8714 | ac_cv_func_fork_works=no | |
8715 | ;; | |
8716 | *) | |
8717 | ac_cv_func_fork_works=yes | |
8718 | ;; | |
8719 | esac | |
5213506e RW |
8720 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&5 |
8721 | $as_echo "$as_me: WARNING: result $ac_cv_func_fork_works guessed because of cross compilation" >&2;} | |
c375c43b | 8722 | fi |
c375c43b | 8723 | ac_cv_func_vfork_works=$ac_cv_func_vfork |
ba479fd2 | 8724 | if test "x$ac_cv_func_vfork" = xyes; then |
5213506e RW |
8725 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for working vfork" >&5 |
8726 | $as_echo_n "checking for working vfork... " >&6; } | |
8727 | if test "${ac_cv_func_vfork_works+set}" = set; then : | |
8728 | $as_echo_n "(cached) " >&6 | |
c375c43b | 8729 | else |
5213506e | 8730 | if test "$cross_compiling" = yes; then : |
ba479fd2 NN |
8731 | ac_cv_func_vfork_works=cross |
8732 | else | |
5213506e | 8733 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 8734 | /* end confdefs.h. */ |
c375c43b | 8735 | /* Thanks to Paul Eggert for this test. */ |
5213506e | 8736 | $ac_includes_default |
ba479fd2 | 8737 | #include <sys/wait.h> |
5213506e | 8738 | #ifdef HAVE_VFORK_H |
ba479fd2 | 8739 | # include <vfork.h> |
c375c43b KG |
8740 | #endif |
8741 | /* On some sparc systems, changes by the child to local and incoming | |
ba479fd2 NN |
8742 | argument registers are propagated back to the parent. The compiler |
8743 | is told about this with #include <vfork.h>, but some compilers | |
8744 | (e.g. gcc -O) don't grok <vfork.h>. Test for this by using a | |
8745 | static variable whose address is put into a register that is | |
8746 | clobbered by the vfork. */ | |
8747 | static void | |
c375c43b KG |
8748 | #ifdef __cplusplus |
8749 | sparc_address_test (int arg) | |
ba479fd2 | 8750 | # else |
c375c43b KG |
8751 | sparc_address_test (arg) int arg; |
8752 | #endif | |
8753 | { | |
8754 | static pid_t child; | |
8755 | if (!child) { | |
8756 | child = vfork (); | |
8757 | if (child < 0) { | |
8758 | perror ("vfork"); | |
8759 | _exit(2); | |
8760 | } | |
8761 | if (!child) { | |
8762 | arg = getpid(); | |
8763 | write(-1, "", 0); | |
8764 | _exit (arg); | |
8765 | } | |
8766 | } | |
8767 | } | |
ba479fd2 NN |
8768 | |
8769 | int | |
8770 | main () | |
8771 | { | |
c375c43b KG |
8772 | pid_t parent = getpid (); |
8773 | pid_t child; | |
8774 | ||
ba479fd2 | 8775 | sparc_address_test (0); |
c375c43b KG |
8776 | |
8777 | child = vfork (); | |
8778 | ||
8779 | if (child == 0) { | |
ba479fd2 NN |
8780 | /* Here is another test for sparc vfork register problems. This |
8781 | test uses lots of local variables, at least as many local | |
8782 | variables as main has allocated so far including compiler | |
8783 | temporaries. 4 locals are enough for gcc 1.40.3 on a Solaris | |
8784 | 4.1.3 sparc, but we use 8 to be safe. A buggy compiler should | |
8785 | reuse the register of parent for one of the local variables, | |
8786 | since it will think that parent can't possibly be used any more | |
8787 | in this routine. Assigning to the local variable will thus | |
8788 | munge parent in the parent process. */ | |
c375c43b KG |
8789 | pid_t |
8790 | p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(), | |
8791 | p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid(); | |
8792 | /* Convince the compiler that p..p7 are live; otherwise, it might | |
8793 | use the same hardware register for all 8 local variables. */ | |
8794 | if (p != p1 || p != p2 || p != p3 || p != p4 | |
8795 | || p != p5 || p != p6 || p != p7) | |
8796 | _exit(1); | |
8797 | ||
ba479fd2 NN |
8798 | /* On some systems (e.g. IRIX 3.3), vfork doesn't separate parent |
8799 | from child file descriptors. If the child closes a descriptor | |
8800 | before it execs or exits, this munges the parent's descriptor | |
8801 | as well. Test for this by closing stdout in the child. */ | |
c375c43b KG |
8802 | _exit(close(fileno(stdout)) != 0); |
8803 | } else { | |
8804 | int status; | |
8805 | struct stat st; | |
8806 | ||
8807 | while (wait(&status) != child) | |
8808 | ; | |
5213506e | 8809 | return ( |
c375c43b KG |
8810 | /* Was there some problem with vforking? */ |
8811 | child < 0 | |
8812 | ||
8813 | /* Did the child fail? (This shouldn't happen.) */ | |
8814 | || status | |
8815 | ||
8816 | /* Did the vfork/compiler bug occur? */ | |
8817 | || parent != getpid() | |
8818 | ||
8819 | /* Did the file descriptor bug occur? */ | |
8820 | || fstat(fileno(stdout), &st) != 0 | |
8821 | ); | |
8822 | } | |
8823 | } | |
ba479fd2 | 8824 | _ACEOF |
5213506e | 8825 | if ac_fn_c_try_run "$LINENO"; then : |
c375c43b KG |
8826 | ac_cv_func_vfork_works=yes |
8827 | else | |
5213506e | 8828 | ac_cv_func_vfork_works=no |
cafe096b | 8829 | fi |
5213506e RW |
8830 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
8831 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
6e3f3080 | 8832 | fi |
5213506e | 8833 | |
ba479fd2 | 8834 | fi |
5213506e RW |
8835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_vfork_works" >&5 |
8836 | $as_echo "$ac_cv_func_vfork_works" >&6; } | |
c375c43b | 8837 | |
ba479fd2 NN |
8838 | fi; |
8839 | if test "x$ac_cv_func_fork_works" = xcross; then | |
86da66b5 | 8840 | ac_cv_func_vfork_works=$ac_cv_func_vfork |
5213506e RW |
8841 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&5 |
8842 | $as_echo "$as_me: WARNING: result $ac_cv_func_vfork_works guessed because of cross compilation" >&2;} | |
c375c43b KG |
8843 | fi |
8844 | ||
ba479fd2 NN |
8845 | if test "x$ac_cv_func_vfork_works" = xyes; then |
8846 | ||
5213506e | 8847 | $as_echo "#define HAVE_WORKING_VFORK 1" >>confdefs.h |
ba479fd2 NN |
8848 | |
8849 | else | |
8850 | ||
5213506e | 8851 | $as_echo "#define vfork fork" >>confdefs.h |
c375c43b KG |
8852 | |
8853 | fi | |
ba479fd2 NN |
8854 | if test "x$ac_cv_func_fork_works" = xyes; then |
8855 | ||
5213506e | 8856 | $as_echo "#define HAVE_WORKING_FORK 1" >>confdefs.h |
ba479fd2 NN |
8857 | |
8858 | fi | |
8859 | ||
c375c43b | 8860 | |
81bf3d9e | 8861 | |
dfb77e37 KC |
8862 | if test "X$prefix" = "XNONE"; then |
8863 | acl_final_prefix="$ac_default_prefix" | |
8864 | else | |
8865 | acl_final_prefix="$prefix" | |
8866 | fi | |
8867 | if test "X$exec_prefix" = "XNONE"; then | |
8868 | acl_final_exec_prefix='${prefix}' | |
8869 | else | |
8870 | acl_final_exec_prefix="$exec_prefix" | |
8871 | fi | |
8872 | acl_save_prefix="$prefix" | |
8873 | prefix="$acl_final_prefix" | |
8874 | eval acl_final_exec_prefix=\"$acl_final_exec_prefix\" | |
8875 | prefix="$acl_save_prefix" | |
f91abfce TT |
8876 | |
8877 | ||
5213506e RW |
8878 | # Check whether --with-gnu-ld was given. |
8879 | if test "${with_gnu_ld+set}" = set; then : | |
8880 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes | |
ba479fd2 | 8881 | else |
dfb77e37 | 8882 | with_gnu_ld=no |
5213506e RW |
8883 | fi |
8884 | ||
dfb77e37 KC |
8885 | # Prepare PATH_SEPARATOR. |
8886 | # The user is always right. | |
8887 | if test "${PATH_SEPARATOR+set}" != set; then | |
8888 | echo "#! /bin/sh" >conf$$.sh | |
8889 | echo "exit 0" >>conf$$.sh | |
8890 | chmod +x conf$$.sh | |
8891 | if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then | |
8892 | PATH_SEPARATOR=';' | |
ba479fd2 | 8893 | else |
dfb77e37 | 8894 | PATH_SEPARATOR=: |
ba479fd2 | 8895 | fi |
dfb77e37 KC |
8896 | rm -f conf$$.sh |
8897 | fi | |
8898 | ac_prog=ld | |
8899 | if test "$GCC" = yes; then | |
8900 | # Check if gcc -print-prog-name=ld gives a path. | |
5213506e RW |
8901 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by GCC" >&5 |
8902 | $as_echo_n "checking for ld used by GCC... " >&6; } | |
dfb77e37 KC |
8903 | case $host in |
8904 | *-*-mingw*) | |
8905 | # gcc leaves a trailing carriage return which upsets mingw | |
8906 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
8907 | *) | |
8908 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
8909 | esac | |
8910 | case $ac_prog in | |
8911 | # Accept absolute paths. | |
8912 | [\\/]* | [A-Za-z]:[\\/]*) | |
8913 | re_direlt='/[^/][^/]*/\.\./' | |
8914 | # Canonicalize the path of ld | |
8915 | ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'` | |
8916 | while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do | |
8917 | ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"` | |
8918 | done | |
8919 | test -z "$LD" && LD="$ac_prog" | |
8920 | ;; | |
8921 | "") | |
8922 | # If it fails, then pretend we aren't using GCC. | |
8923 | ac_prog=ld | |
8924 | ;; | |
8925 | *) | |
8926 | # If it is relative, then search for the first ld in PATH. | |
8927 | with_gnu_ld=unknown | |
8928 | ;; | |
8929 | esac | |
8930 | elif test "$with_gnu_ld" = yes; then | |
5213506e RW |
8931 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
8932 | $as_echo_n "checking for GNU ld... " >&6; } | |
ba479fd2 | 8933 | else |
5213506e RW |
8934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
8935 | $as_echo_n "checking for non-GNU ld... " >&6; } | |
ba479fd2 | 8936 | fi |
5213506e RW |
8937 | if test "${acl_cv_path_LD+set}" = set; then : |
8938 | $as_echo_n "(cached) " >&6 | |
ba479fd2 | 8939 | else |
dfb77e37 KC |
8940 | if test -z "$LD"; then |
8941 | IFS="${IFS= }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}" | |
8942 | for ac_dir in $PATH; do | |
8943 | test -z "$ac_dir" && ac_dir=. | |
8944 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
8945 | acl_cv_path_LD="$ac_dir/$ac_prog" | |
8946 | # Check to see if the program is GNU ld. I'd rather use --version, | |
8947 | # but apparently some GNU ld's only accept -v. | |
8948 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
18fc9bd4 RG |
8949 | if "$acl_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then |
8950 | test "$with_gnu_ld" != no && break | |
8951 | else | |
8952 | test "$with_gnu_ld" != yes && break | |
8953 | fi | |
dfb77e37 KC |
8954 | fi |
8955 | done | |
8956 | IFS="$ac_save_ifs" | |
8957 | else | |
8958 | acl_cv_path_LD="$LD" # Let the user override the test with a path. | |
8959 | fi | |
8960 | fi | |
ba479fd2 | 8961 | |
dfb77e37 KC |
8962 | LD="$acl_cv_path_LD" |
8963 | if test -n "$LD"; then | |
5213506e RW |
8964 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
8965 | $as_echo "$LD" >&6; } | |
dfb77e37 | 8966 | else |
5213506e RW |
8967 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
8968 | $as_echo "no" >&6; } | |
ba479fd2 | 8969 | fi |
5213506e RW |
8970 | test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 |
8971 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
8972 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } | |
8973 | if test "${acl_cv_prog_gnu_ld+set}" = set; then : | |
8974 | $as_echo_n "(cached) " >&6 | |
dfb77e37 KC |
8975 | else |
8976 | # I'd rather use --version here, but apparently some GNU ld's only accept -v. | |
18fc9bd4 RG |
8977 | if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then |
8978 | acl_cv_prog_gnu_ld=yes | |
8979 | else | |
8980 | acl_cv_prog_gnu_ld=no | |
8981 | fi | |
dfb77e37 | 8982 | fi |
5213506e RW |
8983 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_prog_gnu_ld" >&5 |
8984 | $as_echo "$acl_cv_prog_gnu_ld" >&6; } | |
dfb77e37 KC |
8985 | with_gnu_ld=$acl_cv_prog_gnu_ld |
8986 | ||
8987 | ||
8988 | ||
5213506e RW |
8989 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shared library run path origin" >&5 |
8990 | $as_echo_n "checking for shared library run path origin... " >&6; } | |
8991 | if test "${acl_cv_rpath+set}" = set; then : | |
8992 | $as_echo_n "(cached) " >&6 | |
dfb77e37 KC |
8993 | else |
8994 | ||
8995 | CC="$CC" GCC="$GCC" LDFLAGS="$LDFLAGS" LD="$LD" with_gnu_ld="$with_gnu_ld" \ | |
8996 | ${CONFIG_SHELL-/bin/sh} "$ac_aux_dir/config.rpath" "$host" > conftest.sh | |
8997 | . ./conftest.sh | |
8998 | rm -f ./conftest.sh | |
8999 | acl_cv_rpath=done | |
ba479fd2 | 9000 | |
eb158727 | 9001 | fi |
5213506e RW |
9002 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $acl_cv_rpath" >&5 |
9003 | $as_echo "$acl_cv_rpath" >&6; } | |
dfb77e37 KC |
9004 | wl="$acl_cv_wl" |
9005 | libext="$acl_cv_libext" | |
9006 | shlibext="$acl_cv_shlibext" | |
9007 | hardcode_libdir_flag_spec="$acl_cv_hardcode_libdir_flag_spec" | |
9008 | hardcode_libdir_separator="$acl_cv_hardcode_libdir_separator" | |
9009 | hardcode_direct="$acl_cv_hardcode_direct" | |
9010 | hardcode_minus_L="$acl_cv_hardcode_minus_L" | |
5213506e RW |
9011 | # Check whether --enable-rpath was given. |
9012 | if test "${enable_rpath+set}" = set; then : | |
9013 | enableval=$enable_rpath; : | |
dfb77e37 KC |
9014 | else |
9015 | enable_rpath=yes | |
5213506e RW |
9016 | fi |
9017 | ||
8b1f719a | 9018 | |
a6ccdbab | 9019 | |
dfb77e37 KC |
9020 | |
9021 | ||
9022 | ||
9023 | ||
9024 | ||
b639c3c2 JJ |
9025 | use_additional=yes |
9026 | ||
9027 | acl_save_prefix="$prefix" | |
9028 | prefix="$acl_final_prefix" | |
9029 | acl_save_exec_prefix="$exec_prefix" | |
9030 | exec_prefix="$acl_final_exec_prefix" | |
9031 | ||
9032 | eval additional_includedir=\"$includedir\" | |
9033 | eval additional_libdir=\"$libdir\" | |
9034 | ||
9035 | exec_prefix="$acl_save_exec_prefix" | |
9036 | prefix="$acl_save_prefix" | |
dfb77e37 KC |
9037 | |
9038 | ||
5213506e RW |
9039 | # Check whether --with-libiconv-prefix was given. |
9040 | if test "${with_libiconv_prefix+set}" = set; then : | |
9041 | withval=$with_libiconv_prefix; | |
8b1f719a | 9042 | if test "X$withval" = "Xno"; then |
b639c3c2 | 9043 | use_additional=no |
8b1f719a PB |
9044 | else |
9045 | if test "X$withval" = "X"; then | |
dfb77e37 KC |
9046 | |
9047 | acl_save_prefix="$prefix" | |
9048 | prefix="$acl_final_prefix" | |
9049 | acl_save_exec_prefix="$exec_prefix" | |
9050 | exec_prefix="$acl_final_exec_prefix" | |
9051 | ||
b639c3c2 JJ |
9052 | eval additional_includedir=\"$includedir\" |
9053 | eval additional_libdir=\"$libdir\" | |
dfb77e37 KC |
9054 | |
9055 | exec_prefix="$acl_save_exec_prefix" | |
9056 | prefix="$acl_save_prefix" | |
9057 | ||
8b1f719a | 9058 | else |
b639c3c2 JJ |
9059 | additional_includedir="$withval/include" |
9060 | additional_libdir="$withval/lib" | |
8b1f719a PB |
9061 | fi |
9062 | fi | |
9063 | ||
5213506e RW |
9064 | fi |
9065 | ||
dfb77e37 KC |
9066 | LIBICONV= |
9067 | LTLIBICONV= | |
9068 | INCICONV= | |
9069 | rpathdirs= | |
9070 | ltrpathdirs= | |
9071 | names_already_handled= | |
9072 | names_next_round='iconv ' | |
9073 | while test -n "$names_next_round"; do | |
9074 | names_this_round="$names_next_round" | |
9075 | names_next_round= | |
9076 | for name in $names_this_round; do | |
9077 | already_handled= | |
9078 | for n in $names_already_handled; do | |
9079 | if test "$n" = "$name"; then | |
9080 | already_handled=yes | |
9081 | break | |
9082 | fi | |
9083 | done | |
9084 | if test -z "$already_handled"; then | |
9085 | names_already_handled="$names_already_handled $name" | |
9086 | uppername=`echo "$name" | sed -e 'y|abcdefghijklmnopqrstuvwxyz./-|ABCDEFGHIJKLMNOPQRSTUVWXYZ___|'` | |
9087 | eval value=\"\$HAVE_LIB$uppername\" | |
9088 | if test -n "$value"; then | |
9089 | if test "$value" = yes; then | |
9090 | eval value=\"\$LIB$uppername\" | |
9091 | test -z "$value" || LIBICONV="${LIBICONV}${LIBICONV:+ }$value" | |
9092 | eval value=\"\$LTLIB$uppername\" | |
9093 | test -z "$value" || LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$value" | |
9094 | else | |
9095 | : | |
9096 | fi | |
9097 | else | |
9098 | found_dir= | |
9099 | found_la= | |
9100 | found_so= | |
9101 | found_a= | |
b639c3c2 JJ |
9102 | if test $use_additional = yes; then |
9103 | if test -n "$shlibext" && test -f "$additional_libdir/lib$name.$shlibext"; then | |
9104 | found_dir="$additional_libdir" | |
9105 | found_so="$additional_libdir/lib$name.$shlibext" | |
9106 | if test -f "$additional_libdir/lib$name.la"; then | |
9107 | found_la="$additional_libdir/lib$name.la" | |
dfb77e37 KC |
9108 | fi |
9109 | else | |
b639c3c2 JJ |
9110 | if test -f "$additional_libdir/lib$name.$libext"; then |
9111 | found_dir="$additional_libdir" | |
9112 | found_a="$additional_libdir/lib$name.$libext" | |
9113 | if test -f "$additional_libdir/lib$name.la"; then | |
9114 | found_la="$additional_libdir/lib$name.la" | |
dfb77e37 KC |
9115 | fi |
9116 | fi | |
9117 | fi | |
9118 | fi | |
9119 | if test "X$found_dir" = "X"; then | |
9120 | for x in $LDFLAGS $LTLIBICONV; do | |
9121 | ||
9122 | acl_save_prefix="$prefix" | |
9123 | prefix="$acl_final_prefix" | |
9124 | acl_save_exec_prefix="$exec_prefix" | |
9125 | exec_prefix="$acl_final_exec_prefix" | |
9126 | eval x=\"$x\" | |
9127 | exec_prefix="$acl_save_exec_prefix" | |
9128 | prefix="$acl_save_prefix" | |
9129 | ||
9130 | case "$x" in | |
9131 | -L*) | |
9132 | dir=`echo "X$x" | sed -e 's/^X-L//'` | |
9133 | if test -n "$shlibext" && test -f "$dir/lib$name.$shlibext"; then | |
9134 | found_dir="$dir" | |
9135 | found_so="$dir/lib$name.$shlibext" | |
9136 | if test -f "$dir/lib$name.la"; then | |
9137 | found_la="$dir/lib$name.la" | |
9138 | fi | |
9139 | else | |
9140 | if test -f "$dir/lib$name.$libext"; then | |
9141 | found_dir="$dir" | |
9142 | found_a="$dir/lib$name.$libext" | |
9143 | if test -f "$dir/lib$name.la"; then | |
9144 | found_la="$dir/lib$name.la" | |
9145 | fi | |
9146 | fi | |
9147 | fi | |
9148 | ;; | |
9149 | esac | |
9150 | if test "X$found_dir" != "X"; then | |
9151 | break | |
9152 | fi | |
9153 | done | |
9154 | fi | |
9155 | if test "X$found_dir" != "X"; then | |
9156 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$found_dir -l$name" | |
9157 | if test "X$found_so" != "X"; then | |
9158 | if test "$enable_rpath" = no || test "X$found_dir" = "X/usr/lib"; then | |
9159 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
9160 | else | |
9161 | haveit= | |
9162 | for x in $ltrpathdirs; do | |
9163 | if test "X$x" = "X$found_dir"; then | |
9164 | haveit=yes | |
9165 | break | |
9166 | fi | |
9167 | done | |
9168 | if test -z "$haveit"; then | |
9169 | ltrpathdirs="$ltrpathdirs $found_dir" | |
9170 | fi | |
9171 | if test "$hardcode_direct" = yes; then | |
9172 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
9173 | else | |
9174 | if test -n "$hardcode_libdir_flag_spec" && test "$hardcode_minus_L" = no; then | |
9175 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
9176 | haveit= | |
9177 | for x in $rpathdirs; do | |
9178 | if test "X$x" = "X$found_dir"; then | |
9179 | haveit=yes | |
9180 | break | |
9181 | fi | |
9182 | done | |
9183 | if test -z "$haveit"; then | |
9184 | rpathdirs="$rpathdirs $found_dir" | |
9185 | fi | |
9186 | else | |
9187 | haveit= | |
9188 | for x in $LDFLAGS $LIBICONV; do | |
9189 | ||
9190 | acl_save_prefix="$prefix" | |
9191 | prefix="$acl_final_prefix" | |
9192 | acl_save_exec_prefix="$exec_prefix" | |
9193 | exec_prefix="$acl_final_exec_prefix" | |
9194 | eval x=\"$x\" | |
9195 | exec_prefix="$acl_save_exec_prefix" | |
9196 | prefix="$acl_save_prefix" | |
9197 | ||
9198 | if test "X$x" = "X-L$found_dir"; then | |
9199 | haveit=yes | |
9200 | break | |
9201 | fi | |
9202 | done | |
9203 | if test -z "$haveit"; then | |
9204 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir" | |
9205 | fi | |
9206 | if test "$hardcode_minus_L" != no; then | |
9207 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_so" | |
9208 | else | |
9209 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
9210 | fi | |
9211 | fi | |
9212 | fi | |
9213 | fi | |
9214 | else | |
9215 | if test "X$found_a" != "X"; then | |
9216 | LIBICONV="${LIBICONV}${LIBICONV:+ }$found_a" | |
9217 | else | |
9218 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$found_dir -l$name" | |
9219 | fi | |
9220 | fi | |
9221 | additional_includedir= | |
9222 | case "$found_dir" in | |
9223 | */lib | */lib/) | |
9224 | basedir=`echo "X$found_dir" | sed -e 's,^X,,' -e 's,/lib/*$,,'` | |
9225 | additional_includedir="$basedir/include" | |
9226 | ;; | |
9227 | esac | |
9228 | if test "X$additional_includedir" != "X"; then | |
9229 | if test "X$additional_includedir" != "X/usr/include"; then | |
9230 | haveit= | |
9231 | if test "X$additional_includedir" = "X/usr/local/include"; then | |
9232 | if test -n "$GCC"; then | |
9233 | case $host_os in | |
18fc9bd4 | 9234 | linux*) haveit=yes;; |
dfb77e37 KC |
9235 | esac |
9236 | fi | |
9237 | fi | |
9238 | if test -z "$haveit"; then | |
9239 | for x in $CPPFLAGS $INCICONV; do | |
9240 | ||
9241 | acl_save_prefix="$prefix" | |
9242 | prefix="$acl_final_prefix" | |
9243 | acl_save_exec_prefix="$exec_prefix" | |
9244 | exec_prefix="$acl_final_exec_prefix" | |
9245 | eval x=\"$x\" | |
9246 | exec_prefix="$acl_save_exec_prefix" | |
9247 | prefix="$acl_save_prefix" | |
9248 | ||
9249 | if test "X$x" = "X-I$additional_includedir"; then | |
9250 | haveit=yes | |
9251 | break | |
9252 | fi | |
9253 | done | |
9254 | if test -z "$haveit"; then | |
9255 | if test -d "$additional_includedir"; then | |
9256 | INCICONV="${INCICONV}${INCICONV:+ }-I$additional_includedir" | |
9257 | fi | |
9258 | fi | |
9259 | fi | |
9260 | fi | |
9261 | fi | |
9262 | if test -n "$found_la"; then | |
9263 | save_libdir="$libdir" | |
9264 | case "$found_la" in | |
9265 | */* | *\\*) . "$found_la" ;; | |
9266 | *) . "./$found_la" ;; | |
9267 | esac | |
9268 | libdir="$save_libdir" | |
9269 | for dep in $dependency_libs; do | |
9270 | case "$dep" in | |
9271 | -L*) | |
9272 | additional_libdir=`echo "X$dep" | sed -e 's/^X-L//'` | |
9273 | if test "X$additional_libdir" != "X/usr/lib"; then | |
9274 | haveit= | |
9275 | if test "X$additional_libdir" = "X/usr/local/lib"; then | |
9276 | if test -n "$GCC"; then | |
9277 | case $host_os in | |
18fc9bd4 | 9278 | linux*) haveit=yes;; |
dfb77e37 KC |
9279 | esac |
9280 | fi | |
9281 | fi | |
9282 | if test -z "$haveit"; then | |
9283 | haveit= | |
9284 | for x in $LDFLAGS $LIBICONV; do | |
9285 | ||
9286 | acl_save_prefix="$prefix" | |
9287 | prefix="$acl_final_prefix" | |
9288 | acl_save_exec_prefix="$exec_prefix" | |
9289 | exec_prefix="$acl_final_exec_prefix" | |
9290 | eval x=\"$x\" | |
9291 | exec_prefix="$acl_save_exec_prefix" | |
9292 | prefix="$acl_save_prefix" | |
9293 | ||
9294 | if test "X$x" = "X-L$additional_libdir"; then | |
9295 | haveit=yes | |
9296 | break | |
9297 | fi | |
9298 | done | |
9299 | if test -z "$haveit"; then | |
9300 | if test -d "$additional_libdir"; then | |
9301 | LIBICONV="${LIBICONV}${LIBICONV:+ }-L$additional_libdir" | |
9302 | fi | |
9303 | fi | |
9304 | haveit= | |
9305 | for x in $LDFLAGS $LTLIBICONV; do | |
9306 | ||
9307 | acl_save_prefix="$prefix" | |
9308 | prefix="$acl_final_prefix" | |
9309 | acl_save_exec_prefix="$exec_prefix" | |
9310 | exec_prefix="$acl_final_exec_prefix" | |
9311 | eval x=\"$x\" | |
9312 | exec_prefix="$acl_save_exec_prefix" | |
9313 | prefix="$acl_save_prefix" | |
9314 | ||
9315 | if test "X$x" = "X-L$additional_libdir"; then | |
9316 | haveit=yes | |
9317 | break | |
9318 | fi | |
9319 | done | |
9320 | if test -z "$haveit"; then | |
9321 | if test -d "$additional_libdir"; then | |
9322 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-L$additional_libdir" | |
9323 | fi | |
9324 | fi | |
9325 | fi | |
9326 | fi | |
9327 | ;; | |
9328 | -R*) | |
9329 | dir=`echo "X$dep" | sed -e 's/^X-R//'` | |
9330 | if test "$enable_rpath" != no; then | |
9331 | haveit= | |
9332 | for x in $rpathdirs; do | |
9333 | if test "X$x" = "X$dir"; then | |
9334 | haveit=yes | |
9335 | break | |
9336 | fi | |
9337 | done | |
9338 | if test -z "$haveit"; then | |
9339 | rpathdirs="$rpathdirs $dir" | |
9340 | fi | |
9341 | haveit= | |
9342 | for x in $ltrpathdirs; do | |
9343 | if test "X$x" = "X$dir"; then | |
9344 | haveit=yes | |
9345 | break | |
9346 | fi | |
9347 | done | |
9348 | if test -z "$haveit"; then | |
9349 | ltrpathdirs="$ltrpathdirs $dir" | |
9350 | fi | |
9351 | fi | |
9352 | ;; | |
9353 | -l*) | |
9354 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's/^X-l//'` | |
9355 | ;; | |
9356 | *.la) | |
9357 | names_next_round="$names_next_round "`echo "X$dep" | sed -e 's,^X.*/,,' -e 's,^lib,,' -e 's,\.la$,,'` | |
9358 | ;; | |
9359 | *) | |
9360 | LIBICONV="${LIBICONV}${LIBICONV:+ }$dep" | |
9361 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }$dep" | |
9362 | ;; | |
9363 | esac | |
9364 | done | |
9365 | fi | |
9366 | else | |
9367 | LIBICONV="${LIBICONV}${LIBICONV:+ }-l$name" | |
9368 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-l$name" | |
9369 | fi | |
9370 | fi | |
9371 | fi | |
9372 | done | |
9373 | done | |
9374 | if test "X$rpathdirs" != "X"; then | |
9375 | if test -n "$hardcode_libdir_separator"; then | |
9376 | alldirs= | |
9377 | for found_dir in $rpathdirs; do | |
9378 | alldirs="${alldirs}${alldirs:+$hardcode_libdir_separator}$found_dir" | |
9379 | done | |
9380 | acl_save_libdir="$libdir" | |
9381 | libdir="$alldirs" | |
9382 | eval flag=\"$hardcode_libdir_flag_spec\" | |
9383 | libdir="$acl_save_libdir" | |
9384 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
9385 | else | |
9386 | for found_dir in $rpathdirs; do | |
9387 | acl_save_libdir="$libdir" | |
9388 | libdir="$found_dir" | |
9389 | eval flag=\"$hardcode_libdir_flag_spec\" | |
9390 | libdir="$acl_save_libdir" | |
9391 | LIBICONV="${LIBICONV}${LIBICONV:+ }$flag" | |
9392 | done | |
9393 | fi | |
9394 | fi | |
9395 | if test "X$ltrpathdirs" != "X"; then | |
9396 | for found_dir in $ltrpathdirs; do | |
9397 | LTLIBICONV="${LTLIBICONV}${LTLIBICONV:+ }-R$found_dir" | |
9398 | done | |
9399 | fi | |
9400 | ||
9401 | ||
9402 | ||
9403 | ||
9404 | ||
9405 | ||
9406 | ||
9407 | am_save_CPPFLAGS="$CPPFLAGS" | |
9408 | ||
9409 | for element in $INCICONV; do | |
9410 | haveit= | |
9411 | for x in $CPPFLAGS; do | |
9412 | ||
9413 | acl_save_prefix="$prefix" | |
9414 | prefix="$acl_final_prefix" | |
9415 | acl_save_exec_prefix="$exec_prefix" | |
9416 | exec_prefix="$acl_final_exec_prefix" | |
9417 | eval x=\"$x\" | |
9418 | exec_prefix="$acl_save_exec_prefix" | |
9419 | prefix="$acl_save_prefix" | |
9420 | ||
9421 | if test "X$x" = "X$element"; then | |
9422 | haveit=yes | |
9423 | break | |
9424 | fi | |
9425 | done | |
9426 | if test -z "$haveit"; then | |
9427 | CPPFLAGS="${CPPFLAGS}${CPPFLAGS:+ }$element" | |
9428 | fi | |
9429 | done | |
eb158727 ZW |
9430 | |
9431 | ||
5213506e RW |
9432 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv" >&5 |
9433 | $as_echo_n "checking for iconv... " >&6; } | |
9434 | if test "${am_cv_func_iconv+set}" = set; then : | |
9435 | $as_echo_n "(cached) " >&6 | |
f91abfce | 9436 | else |
ba479fd2 | 9437 | |
f91abfce TT |
9438 | am_cv_func_iconv="no, consider installing GNU libiconv" |
9439 | am_cv_lib_iconv=no | |
5213506e | 9440 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9441 | /* end confdefs.h. */ |
f91abfce TT |
9442 | #include <stdlib.h> |
9443 | #include <iconv.h> | |
ba479fd2 NN |
9444 | int |
9445 | main () | |
9446 | { | |
f91abfce TT |
9447 | iconv_t cd = iconv_open("",""); |
9448 | iconv(cd,NULL,NULL,NULL,NULL); | |
9449 | iconv_close(cd); | |
ba479fd2 NN |
9450 | ; |
9451 | return 0; | |
9452 | } | |
9453 | _ACEOF | |
5213506e | 9454 | if ac_fn_c_try_link "$LINENO"; then : |
f91abfce | 9455 | am_cv_func_iconv=yes |
f91abfce | 9456 | fi |
5213506e RW |
9457 | rm -f core conftest.err conftest.$ac_objext \ |
9458 | conftest$ac_exeext conftest.$ac_ext | |
f91abfce TT |
9459 | if test "$am_cv_func_iconv" != yes; then |
9460 | am_save_LIBS="$LIBS" | |
dfb77e37 | 9461 | LIBS="$LIBS $LIBICONV" |
5213506e | 9462 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9463 | /* end confdefs.h. */ |
f91abfce TT |
9464 | #include <stdlib.h> |
9465 | #include <iconv.h> | |
ba479fd2 NN |
9466 | int |
9467 | main () | |
9468 | { | |
f91abfce TT |
9469 | iconv_t cd = iconv_open("",""); |
9470 | iconv(cd,NULL,NULL,NULL,NULL); | |
9471 | iconv_close(cd); | |
ba479fd2 NN |
9472 | ; |
9473 | return 0; | |
9474 | } | |
9475 | _ACEOF | |
5213506e | 9476 | if ac_fn_c_try_link "$LINENO"; then : |
f91abfce TT |
9477 | am_cv_lib_iconv=yes |
9478 | am_cv_func_iconv=yes | |
f91abfce | 9479 | fi |
5213506e RW |
9480 | rm -f core conftest.err conftest.$ac_objext \ |
9481 | conftest$ac_exeext conftest.$ac_ext | |
f91abfce TT |
9482 | LIBS="$am_save_LIBS" |
9483 | fi | |
6e3f3080 | 9484 | |
ba479fd2 | 9485 | fi |
5213506e RW |
9486 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_func_iconv" >&5 |
9487 | $as_echo "$am_cv_func_iconv" >&6; } | |
63cf211a | 9488 | if test "$am_cv_func_iconv" = yes; then |
ba479fd2 | 9489 | |
5213506e | 9490 | $as_echo "#define HAVE_ICONV 1" >>confdefs.h |
f91abfce | 9491 | |
dfb77e37 KC |
9492 | fi |
9493 | if test "$am_cv_lib_iconv" = yes; then | |
5213506e RW |
9494 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libiconv" >&5 |
9495 | $as_echo_n "checking how to link with libiconv... " >&6; } | |
9496 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBICONV" >&5 | |
9497 | $as_echo "$LIBICONV" >&6; } | |
dfb77e37 KC |
9498 | else |
9499 | CPPFLAGS="$am_save_CPPFLAGS" | |
9500 | LIBICONV= | |
9501 | LTLIBICONV= | |
9502 | fi | |
9503 | ||
9504 | ||
9505 | ||
9506 | if test "$am_cv_func_iconv" = yes; then | |
5213506e RW |
9507 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for iconv declaration" >&5 |
9508 | $as_echo_n "checking for iconv declaration... " >&6; } | |
9509 | if test "${am_cv_proto_iconv+set}" = set; then : | |
9510 | $as_echo_n "(cached) " >&6 | |
f91abfce | 9511 | else |
ba479fd2 | 9512 | |
5213506e | 9513 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9514 | /* end confdefs.h. */ |
f91abfce TT |
9515 | |
9516 | #include <stdlib.h> | |
9517 | #include <iconv.h> | |
9518 | extern | |
9519 | #ifdef __cplusplus | |
9520 | "C" | |
9521 | #endif | |
9522 | #if defined(__STDC__) || defined(__cplusplus) | |
9523 | size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft); | |
9524 | #else | |
9525 | size_t iconv(); | |
9526 | #endif | |
9527 | ||
ba479fd2 NN |
9528 | int |
9529 | main () | |
9530 | { | |
f91abfce | 9531 | |
ba479fd2 NN |
9532 | ; |
9533 | return 0; | |
9534 | } | |
9535 | _ACEOF | |
5213506e | 9536 | if ac_fn_c_try_compile "$LINENO"; then : |
f91abfce TT |
9537 | am_cv_proto_iconv_arg1="" |
9538 | else | |
5213506e | 9539 | am_cv_proto_iconv_arg1="const" |
f91abfce | 9540 | fi |
5213506e | 9541 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
f91abfce TT |
9542 | am_cv_proto_iconv="extern size_t iconv (iconv_t cd, $am_cv_proto_iconv_arg1 char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);" |
9543 | fi | |
9544 | ||
9545 | am_cv_proto_iconv=`echo "$am_cv_proto_iconv" | tr -s ' ' | sed -e 's/( /(/'` | |
5213506e | 9546 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ac_t:- |
ba479fd2 | 9547 | }$am_cv_proto_iconv" >&5 |
5213506e RW |
9548 | $as_echo "${ac_t:- |
9549 | }$am_cv_proto_iconv" >&6; } | |
ba479fd2 NN |
9550 | |
9551 | cat >>confdefs.h <<_ACEOF | |
f91abfce | 9552 | #define ICONV_CONST $am_cv_proto_iconv_arg1 |
ba479fd2 | 9553 | _ACEOF |
f91abfce TT |
9554 | |
9555 | fi | |
f91abfce | 9556 | |
56694dd9 ZW |
9557 | # Until we have in-tree GNU iconv: |
9558 | LIBICONV_DEP= | |
9559 | ||
9560 | ||
18fc9bd4 | 9561 | |
5213506e RW |
9562 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LC_MESSAGES" >&5 |
9563 | $as_echo_n "checking for LC_MESSAGES... " >&6; } | |
9564 | if test "${am_cv_val_LC_MESSAGES+set}" = set; then : | |
9565 | $as_echo_n "(cached) " >&6 | |
18fc9bd4 | 9566 | else |
5213506e | 9567 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
18fc9bd4 RG |
9568 | /* end confdefs.h. */ |
9569 | #include <locale.h> | |
9570 | int | |
9571 | main () | |
9572 | { | |
9573 | return LC_MESSAGES | |
9574 | ; | |
9575 | return 0; | |
9576 | } | |
9577 | _ACEOF | |
5213506e | 9578 | if ac_fn_c_try_link "$LINENO"; then : |
18fc9bd4 RG |
9579 | am_cv_val_LC_MESSAGES=yes |
9580 | else | |
5213506e | 9581 | am_cv_val_LC_MESSAGES=no |
18fc9bd4 | 9582 | fi |
5213506e RW |
9583 | rm -f core conftest.err conftest.$ac_objext \ |
9584 | conftest$ac_exeext conftest.$ac_ext | |
18fc9bd4 | 9585 | fi |
5213506e RW |
9586 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_val_LC_MESSAGES" >&5 |
9587 | $as_echo "$am_cv_val_LC_MESSAGES" >&6; } | |
18fc9bd4 RG |
9588 | if test $am_cv_val_LC_MESSAGES = yes; then |
9589 | ||
5213506e | 9590 | $as_echo "#define HAVE_LC_MESSAGES 1" >>confdefs.h |
18fc9bd4 RG |
9591 | |
9592 | fi | |
9593 | ||
f91abfce | 9594 | |
a03ea89b | 9595 | |
5213506e RW |
9596 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for nl_langinfo and CODESET" >&5 |
9597 | $as_echo_n "checking for nl_langinfo and CODESET... " >&6; } | |
9598 | if test "${am_cv_langinfo_codeset+set}" = set; then : | |
9599 | $as_echo_n "(cached) " >&6 | |
a03ea89b | 9600 | else |
5213506e | 9601 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
a03ea89b BM |
9602 | /* end confdefs.h. */ |
9603 | #include <langinfo.h> | |
9604 | int | |
9605 | main () | |
9606 | { | |
9607 | char* cs = nl_langinfo(CODESET); | |
9608 | ; | |
9609 | return 0; | |
9610 | } | |
9611 | _ACEOF | |
5213506e | 9612 | if ac_fn_c_try_link "$LINENO"; then : |
a03ea89b BM |
9613 | am_cv_langinfo_codeset=yes |
9614 | else | |
5213506e | 9615 | am_cv_langinfo_codeset=no |
a03ea89b | 9616 | fi |
5213506e RW |
9617 | rm -f core conftest.err conftest.$ac_objext \ |
9618 | conftest$ac_exeext conftest.$ac_ext | |
a03ea89b BM |
9619 | |
9620 | fi | |
5213506e RW |
9621 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_langinfo_codeset" >&5 |
9622 | $as_echo "$am_cv_langinfo_codeset" >&6; } | |
a03ea89b BM |
9623 | if test $am_cv_langinfo_codeset = yes; then |
9624 | ||
5213506e | 9625 | $as_echo "#define HAVE_LANGINFO_CODESET 1" >>confdefs.h |
a03ea89b BM |
9626 | |
9627 | fi | |
9628 | ||
9629 | ||
86cf1cbd KG |
9630 | # We will need to find libiberty.h and ansidecl.h |
9631 | saved_CFLAGS="$CFLAGS" | |
9632 | CFLAGS="$CFLAGS -I${srcdir} -I${srcdir}/../include" | |
ed5b9f96 GK |
9633 | for ac_func in getenv atol asprintf sbrk abort atof getcwd getwd \ |
9634 | strsignal strstr strverscmp \ | |
9635 | errno snprintf vsnprintf vasprintf malloc realloc calloc \ | |
367e8319 | 9636 | free basename getopt clock getpagesize clearerr_unlocked feof_unlocked ferror_unlocked fflush_unlocked fgetc_unlocked fgets_unlocked fileno_unlocked fprintf_unlocked fputc_unlocked fputs_unlocked fread_unlocked fwrite_unlocked getchar_unlocked getc_unlocked putchar_unlocked putc_unlocked |
81bf3d9e | 9637 | do |
5213506e RW |
9638 | ac_tr_decl=`$as_echo "HAVE_DECL_$ac_func" | $as_tr_cpp` |
9639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $ac_func is declared" >&5 | |
9640 | $as_echo_n "checking whether $ac_func is declared... " >&6; } | |
9641 | if { as_var=gcc_cv_have_decl_$ac_func; eval "test \"\${$as_var+set}\" = set"; }; then : | |
9642 | $as_echo_n "(cached) " >&6 | |
9643 | else | |
9644 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 9645 | /* end confdefs.h. */ |
7afe8c41 KG |
9646 | #undef $ac_tr_decl |
9647 | #define $ac_tr_decl 1 | |
ba479fd2 | 9648 | |
d02af173 | 9649 | #include "ansidecl.h" |
86cf1cbd | 9650 | #include "system.h" |
f31e826b | 9651 | |
ba479fd2 NN |
9652 | int |
9653 | main () | |
9654 | { | |
86cf1cbd KG |
9655 | #ifndef $ac_func |
9656 | char *(*pfn) = (char *(*)) $ac_func ; | |
9657 | #endif | |
ba479fd2 | 9658 | ; |
5213506e RW |
9659 | return 0; |
9660 | } | |
9661 | _ACEOF | |
9662 | if ac_fn_c_try_compile "$LINENO"; then : | |
f31e826b | 9663 | eval "gcc_cv_have_decl_$ac_func=yes" |
81bf3d9e | 9664 | else |
5213506e | 9665 | eval "gcc_cv_have_decl_$ac_func=no" |
81bf3d9e | 9666 | fi |
5213506e | 9667 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
81bf3d9e RH |
9668 | fi |
9669 | ||
f31e826b | 9670 | if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then |
5213506e RW |
9671 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
9672 | $as_echo "yes" >&6; } ; cat >>confdefs.h <<_ACEOF | |
86cf1cbd | 9673 | #define $ac_tr_decl 1 |
ba479fd2 NN |
9674 | _ACEOF |
9675 | ||
81bf3d9e | 9676 | else |
5213506e RW |
9677 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
9678 | $as_echo "no" >&6; } ; cat >>confdefs.h <<_ACEOF | |
f31e826b | 9679 | #define $ac_tr_decl 0 |
ba479fd2 NN |
9680 | _ACEOF |
9681 | ||
81bf3d9e RH |
9682 | fi |
9683 | ||
9684 | done | |
ba479fd2 | 9685 | |
ba479fd2 | 9686 | |
81bf3d9e RH |
9687 | for ac_func in getrlimit setrlimit getrusage |
9688 | do | |
5213506e RW |
9689 | ac_tr_decl=`$as_echo "HAVE_DECL_$ac_func" | $as_tr_cpp` |
9690 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $ac_func is declared" >&5 | |
9691 | $as_echo_n "checking whether $ac_func is declared... " >&6; } | |
9692 | if { as_var=gcc_cv_have_decl_$ac_func; eval "test \"\${$as_var+set}\" = set"; }; then : | |
9693 | $as_echo_n "(cached) " >&6 | |
9694 | else | |
9695 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 9696 | /* end confdefs.h. */ |
7afe8c41 KG |
9697 | #undef $ac_tr_decl |
9698 | #define $ac_tr_decl 1 | |
ba479fd2 | 9699 | |
d02af173 | 9700 | #include "ansidecl.h" |
86cf1cbd | 9701 | #include "system.h" |
81bf3d9e RH |
9702 | #ifdef HAVE_SYS_RESOURCE_H |
9703 | #include <sys/resource.h> | |
9704 | #endif | |
9705 | ||
f31e826b | 9706 | |
ba479fd2 NN |
9707 | int |
9708 | main () | |
9709 | { | |
86cf1cbd KG |
9710 | #ifndef $ac_func |
9711 | char *(*pfn) = (char *(*)) $ac_func ; | |
9712 | #endif | |
ba479fd2 NN |
9713 | ; |
9714 | return 0; | |
9715 | } | |
9716 | _ACEOF | |
5213506e | 9717 | if ac_fn_c_try_compile "$LINENO"; then : |
f31e826b | 9718 | eval "gcc_cv_have_decl_$ac_func=yes" |
81bf3d9e | 9719 | else |
5213506e | 9720 | eval "gcc_cv_have_decl_$ac_func=no" |
81bf3d9e | 9721 | fi |
5213506e | 9722 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
81bf3d9e RH |
9723 | fi |
9724 | ||
f31e826b | 9725 | if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then |
5213506e RW |
9726 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
9727 | $as_echo "yes" >&6; } ; cat >>confdefs.h <<_ACEOF | |
86cf1cbd | 9728 | #define $ac_tr_decl 1 |
ba479fd2 NN |
9729 | _ACEOF |
9730 | ||
81bf3d9e | 9731 | else |
5213506e RW |
9732 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
9733 | $as_echo "no" >&6; } ; cat >>confdefs.h <<_ACEOF | |
f31e826b | 9734 | #define $ac_tr_decl 0 |
ba479fd2 NN |
9735 | _ACEOF |
9736 | ||
81bf3d9e RH |
9737 | fi |
9738 | ||
9739 | done | |
86cf1cbd | 9740 | |
81bf3d9e | 9741 | |
5213506e | 9742 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9743 | /* end confdefs.h. */ |
b2522d2b HPN |
9744 | |
9745 | #include "ansidecl.h" | |
9746 | #include "system.h" | |
9747 | #ifdef HAVE_SYS_RESOURCE_H | |
9748 | #include <sys/resource.h> | |
9749 | #endif | |
9750 | ||
ba479fd2 NN |
9751 | int |
9752 | main () | |
9753 | { | |
b2522d2b | 9754 | rlim_t l = 0; |
ba479fd2 NN |
9755 | ; |
9756 | return 0; | |
9757 | } | |
9758 | _ACEOF | |
5213506e | 9759 | if ac_fn_c_try_compile "$LINENO"; then : |
ba479fd2 | 9760 | |
5213506e | 9761 | else |
ba479fd2 | 9762 | |
5213506e | 9763 | $as_echo "#define rlim_t long" >>confdefs.h |
b2522d2b HPN |
9764 | |
9765 | fi | |
5213506e | 9766 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
b2522d2b | 9767 | |
2102b2fe RS |
9768 | # On AIX 5.2, <ldfcn.h> conflicts with <fcntl.h>, as both define incompatible |
9769 | # FREAD and FWRITE macros. Fortunately, for GCC's single usage of ldgetname | |
9770 | # in collect2.c, <fcntl.h> isn't visible, but the configure test below needs | |
9771 | # to undef these macros to get the correct value for HAVE_DECL_LDGETNAME. | |
351df804 | 9772 | for ac_func in ldgetname |
c1800ec8 | 9773 | do |
5213506e RW |
9774 | ac_tr_decl=`$as_echo "HAVE_DECL_$ac_func" | $as_tr_cpp` |
9775 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $ac_func is declared" >&5 | |
9776 | $as_echo_n "checking whether $ac_func is declared... " >&6; } | |
9777 | if { as_var=gcc_cv_have_decl_$ac_func; eval "test \"\${$as_var+set}\" = set"; }; then : | |
9778 | $as_echo_n "(cached) " >&6 | |
9779 | else | |
9780 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 9781 | /* end confdefs.h. */ |
c1800ec8 ZW |
9782 | #undef $ac_tr_decl |
9783 | #define $ac_tr_decl 1 | |
ba479fd2 | 9784 | |
351df804 KG |
9785 | #include "ansidecl.h" |
9786 | #include "system.h" | |
9787 | #ifdef HAVE_LDFCN_H | |
2102b2fe RS |
9788 | #undef FREAD |
9789 | #undef FWRITE | |
351df804 KG |
9790 | #include <ldfcn.h> |
9791 | #endif | |
9792 | ||
9793 | ||
ba479fd2 NN |
9794 | int |
9795 | main () | |
9796 | { | |
351df804 KG |
9797 | #ifndef $ac_func |
9798 | char *(*pfn) = (char *(*)) $ac_func ; | |
9799 | #endif | |
ba479fd2 NN |
9800 | ; |
9801 | return 0; | |
9802 | } | |
9803 | _ACEOF | |
5213506e | 9804 | if ac_fn_c_try_compile "$LINENO"; then : |
351df804 KG |
9805 | eval "gcc_cv_have_decl_$ac_func=yes" |
9806 | else | |
5213506e | 9807 | eval "gcc_cv_have_decl_$ac_func=no" |
351df804 | 9808 | fi |
5213506e | 9809 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
351df804 KG |
9810 | fi |
9811 | ||
9812 | if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then | |
5213506e RW |
9813 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
9814 | $as_echo "yes" >&6; } ; cat >>confdefs.h <<_ACEOF | |
351df804 | 9815 | #define $ac_tr_decl 1 |
ba479fd2 NN |
9816 | _ACEOF |
9817 | ||
351df804 | 9818 | else |
5213506e RW |
9819 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
9820 | $as_echo "no" >&6; } ; cat >>confdefs.h <<_ACEOF | |
351df804 | 9821 | #define $ac_tr_decl 0 |
ba479fd2 NN |
9822 | _ACEOF |
9823 | ||
351df804 KG |
9824 | fi |
9825 | ||
9826 | done | |
ba479fd2 | 9827 | |
351df804 | 9828 | |
351df804 KG |
9829 | for ac_func in times |
9830 | do | |
5213506e RW |
9831 | ac_tr_decl=`$as_echo "HAVE_DECL_$ac_func" | $as_tr_cpp` |
9832 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $ac_func is declared" >&5 | |
9833 | $as_echo_n "checking whether $ac_func is declared... " >&6; } | |
9834 | if { as_var=gcc_cv_have_decl_$ac_func; eval "test \"\${$as_var+set}\" = set"; }; then : | |
9835 | $as_echo_n "(cached) " >&6 | |
9836 | else | |
9837 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
ba479fd2 | 9838 | /* end confdefs.h. */ |
351df804 KG |
9839 | #undef $ac_tr_decl |
9840 | #define $ac_tr_decl 1 | |
ba479fd2 | 9841 | |
c1800ec8 ZW |
9842 | #include "ansidecl.h" |
9843 | #include "system.h" | |
9844 | #ifdef HAVE_SYS_TIMES_H | |
9845 | #include <sys/times.h> | |
9846 | #endif | |
9847 | ||
9848 | ||
ba479fd2 NN |
9849 | int |
9850 | main () | |
9851 | { | |
c1800ec8 ZW |
9852 | #ifndef $ac_func |
9853 | char *(*pfn) = (char *(*)) $ac_func ; | |
9854 | #endif | |
ba479fd2 NN |
9855 | ; |
9856 | return 0; | |
9857 | } | |
9858 | _ACEOF | |
5213506e | 9859 | if ac_fn_c_try_compile "$LINENO"; then : |
2f41c1d6 PB |
9860 | eval "gcc_cv_have_decl_$ac_func=yes" |
9861 | else | |
5213506e | 9862 | eval "gcc_cv_have_decl_$ac_func=no" |
2f41c1d6 | 9863 | fi |
5213506e | 9864 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
c1800ec8 ZW |
9865 | fi |
9866 | ||
9867 | if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then | |
5213506e RW |
9868 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
9869 | $as_echo "yes" >&6; } ; cat >>confdefs.h <<_ACEOF | |
c1800ec8 | 9870 | #define $ac_tr_decl 1 |
ba479fd2 NN |
9871 | _ACEOF |
9872 | ||
c1800ec8 | 9873 | else |
5213506e RW |
9874 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
9875 | $as_echo "no" >&6; } ; cat >>confdefs.h <<_ACEOF | |
c1800ec8 | 9876 | #define $ac_tr_decl 0 |
ba479fd2 NN |
9877 | _ACEOF |
9878 | ||
c1800ec8 ZW |
9879 | fi |
9880 | ||
9881 | done | |
c1800ec8 ZW |
9882 | |
9883 | ||
4f6d8cc8 GK |
9884 | for ac_func in sigaltstack |
9885 | do | |
5213506e RW |
9886 | ac_tr_decl=`$as_echo "HAVE_DECL_$ac_func" | $as_tr_cpp` |
9887 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $ac_func is declared" >&5 | |
9888 | $as_echo_n "checking whether $ac_func is declared... " >&6; } | |
9889 | if { as_var=gcc_cv_have_decl_$ac_func; eval "test \"\${$as_var+set}\" = set"; }; then : | |
9890 | $as_echo_n "(cached) " >&6 | |
9891 | else | |
9892 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
4f6d8cc8 GK |
9893 | /* end confdefs.h. */ |
9894 | #undef $ac_tr_decl | |
9895 | #define $ac_tr_decl 1 | |
9896 | ||
9897 | #include "ansidecl.h" | |
9898 | #include "system.h" | |
9899 | #include <signal.h> | |
9900 | ||
9901 | ||
9902 | int | |
9903 | main () | |
9904 | { | |
9905 | #ifndef $ac_func | |
9906 | char *(*pfn) = (char *(*)) $ac_func ; | |
9907 | #endif | |
9908 | ; | |
9909 | return 0; | |
9910 | } | |
9911 | _ACEOF | |
5213506e | 9912 | if ac_fn_c_try_compile "$LINENO"; then : |
8b1f719a PB |
9913 | eval "gcc_cv_have_decl_$ac_func=yes" |
9914 | else | |
5213506e | 9915 | eval "gcc_cv_have_decl_$ac_func=no" |
4f6d8cc8 | 9916 | fi |
5213506e | 9917 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4f6d8cc8 GK |
9918 | fi |
9919 | ||
9920 | if eval "test \"`echo '$gcc_cv_have_decl_'$ac_func`\" = yes"; then | |
5213506e RW |
9921 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
9922 | $as_echo "yes" >&6; } ; cat >>confdefs.h <<_ACEOF | |
4f6d8cc8 GK |
9923 | #define $ac_tr_decl 1 |
9924 | _ACEOF | |
9925 | ||
9926 | else | |
5213506e RW |
9927 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
9928 | $as_echo "no" >&6; } ; cat >>confdefs.h <<_ACEOF | |
4f6d8cc8 GK |
9929 | #define $ac_tr_decl 0 |
9930 | _ACEOF | |
9931 | ||
9932 | fi | |
9933 | ||
9934 | done | |
9935 | ||
9936 | ||
c1800ec8 | 9937 | # More time-related stuff. |
5213506e RW |
9938 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct tms" >&5 |
9939 | $as_echo_n "checking for struct tms... " >&6; } | |
9940 | if test "${ac_cv_struct_tms+set}" = set; then : | |
9941 | $as_echo_n "(cached) " >&6 | |
ba479fd2 NN |
9942 | else |
9943 | ||
5213506e | 9944 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9945 | /* end confdefs.h. */ |
c1800ec8 ZW |
9946 | |
9947 | #include "ansidecl.h" | |
9948 | #include "system.h" | |
9949 | #ifdef HAVE_SYS_TIMES_H | |
9950 | #include <sys/times.h> | |
9951 | #endif | |
9952 | ||
ba479fd2 NN |
9953 | int |
9954 | main () | |
9955 | { | |
c1800ec8 | 9956 | struct tms tms; |
ba479fd2 NN |
9957 | ; |
9958 | return 0; | |
9959 | } | |
9960 | _ACEOF | |
5213506e | 9961 | if ac_fn_c_try_compile "$LINENO"; then : |
c1800ec8 ZW |
9962 | ac_cv_struct_tms=yes |
9963 | else | |
5213506e | 9964 | ac_cv_struct_tms=no |
c1800ec8 | 9965 | fi |
5213506e | 9966 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
c1800ec8 | 9967 | fi |
5213506e RW |
9968 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_struct_tms" >&5 |
9969 | $as_echo "$ac_cv_struct_tms" >&6; } | |
63cf211a | 9970 | if test $ac_cv_struct_tms = yes; then |
ba479fd2 | 9971 | |
5213506e | 9972 | $as_echo "#define HAVE_STRUCT_TMS 1" >>confdefs.h |
c1800ec8 ZW |
9973 | |
9974 | fi | |
9975 | ||
9976 | # use gcc_cv_* here because this doesn't match the behavior of AC_CHECK_TYPE. | |
9977 | # revisit after autoconf 2.50. | |
5213506e RW |
9978 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5 |
9979 | $as_echo_n "checking for clock_t... " >&6; } | |
9980 | if test "${gcc_cv_type_clock_t+set}" = set; then : | |
9981 | $as_echo_n "(cached) " >&6 | |
ba479fd2 NN |
9982 | else |
9983 | ||
5213506e | 9984 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 9985 | /* end confdefs.h. */ |
c1800ec8 ZW |
9986 | |
9987 | #include "ansidecl.h" | |
9988 | #include "system.h" | |
9989 | ||
ba479fd2 NN |
9990 | int |
9991 | main () | |
9992 | { | |
c1800ec8 | 9993 | clock_t x; |
ba479fd2 NN |
9994 | ; |
9995 | return 0; | |
9996 | } | |
9997 | _ACEOF | |
5213506e | 9998 | if ac_fn_c_try_compile "$LINENO"; then : |
c1800ec8 ZW |
9999 | gcc_cv_type_clock_t=yes |
10000 | else | |
5213506e | 10001 | gcc_cv_type_clock_t=no |
c1800ec8 | 10002 | fi |
5213506e | 10003 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
c1800ec8 | 10004 | fi |
5213506e RW |
10005 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_type_clock_t" >&5 |
10006 | $as_echo "$gcc_cv_type_clock_t" >&6; } | |
63cf211a | 10007 | if test $gcc_cv_type_clock_t = yes; then |
ba479fd2 | 10008 | |
5213506e | 10009 | $as_echo "#define HAVE_CLOCK_T 1" >>confdefs.h |
c1800ec8 ZW |
10010 | |
10011 | fi | |
10012 | ||
eb70d86d AS |
10013 | # Restore CFLAGS from before the gcc_AC_NEED_DECLARATIONS tests. |
10014 | CFLAGS="$saved_CFLAGS" | |
10015 | ||
5213506e RW |
10016 | # Check whether --enable-initfini-array was given. |
10017 | if test "${enable_initfini_array+set}" = set; then : | |
10018 | enableval=$enable_initfini_array; | |
07cf4226 | 10019 | else |
ba479fd2 | 10020 | |
5213506e RW |
10021 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for .preinit_array/.init_array/.fini_array support" >&5 |
10022 | $as_echo_n "checking for .preinit_array/.init_array/.fini_array support... " >&6; } | |
10023 | if test "${gcc_cv_initfini_array+set}" = set; then : | |
10024 | $as_echo_n "(cached) " >&6 | |
07cf4226 | 10025 | else |
5213506e | 10026 | if test "$cross_compiling" = yes; then : |
918c4fe4 | 10027 | gcc_cv_initfini_array=no |
eb70d86d | 10028 | else |
5213506e | 10029 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 10030 | /* end confdefs.h. */ |
eb70d86d | 10031 | |
07cf4226 DM |
10032 | static int x = -1; |
10033 | int main (void) { return x; } | |
10034 | int foo (void) { x = 0; } | |
10035 | int (*fp) (void) __attribute__ ((section (".init_array"))) = foo; | |
ba479fd2 | 10036 | _ACEOF |
5213506e | 10037 | if ac_fn_c_try_run "$LINENO"; then : |
918c4fe4 | 10038 | gcc_cv_initfini_array=yes |
eb70d86d | 10039 | else |
5213506e | 10040 | gcc_cv_initfini_array=no |
eb70d86d | 10041 | fi |
5213506e RW |
10042 | rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ |
10043 | conftest.$ac_objext conftest.beam conftest.$ac_ext | |
eb70d86d | 10044 | fi |
5213506e | 10045 | |
07cf4226 | 10046 | fi |
5213506e RW |
10047 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_initfini_array" >&5 |
10048 | $as_echo "$gcc_cv_initfini_array" >&6; } | |
eb70d86d | 10049 | enable_initfini_array=$gcc_cv_initfini_array |
07cf4226 | 10050 | |
5213506e RW |
10051 | fi |
10052 | ||
63cf211a | 10053 | if test $enable_initfini_array = yes; then |
ba479fd2 | 10054 | |
5213506e | 10055 | $as_echo "#define HAVE_INITFINI_ARRAY 1" >>confdefs.h |
07cf4226 | 10056 | |
eb70d86d | 10057 | fi |
81bf3d9e | 10058 | |
ba479fd2 | 10059 | # mkdir takes a single argument on some systems. |
5213506e RW |
10060 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if mkdir takes one argument" >&5 |
10061 | $as_echo_n "checking if mkdir takes one argument... " >&6; } | |
10062 | if test "${gcc_cv_mkdir_takes_one_arg+set}" = set; then : | |
10063 | $as_echo_n "(cached) " >&6 | |
75923b2f | 10064 | else |
5213506e | 10065 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 10066 | /* end confdefs.h. */ |
75923b2f MK |
10067 | |
10068 | #include <sys/types.h> | |
10069 | #ifdef HAVE_SYS_STAT_H | |
10070 | # include <sys/stat.h> | |
10071 | #endif | |
10072 | #ifdef HAVE_UNISTD_H | |
10073 | # include <unistd.h> | |
10074 | #endif | |
10075 | #ifdef HAVE_DIRECT_H | |
10076 | # include <direct.h> | |
10077 | #endif | |
ba479fd2 NN |
10078 | int |
10079 | main () | |
10080 | { | |
75923b2f | 10081 | mkdir ("foo", 0); |
ba479fd2 NN |
10082 | ; |
10083 | return 0; | |
10084 | } | |
10085 | _ACEOF | |
5213506e | 10086 | if ac_fn_c_try_compile "$LINENO"; then : |
75923b2f MK |
10087 | gcc_cv_mkdir_takes_one_arg=no |
10088 | else | |
5213506e | 10089 | gcc_cv_mkdir_takes_one_arg=yes |
75923b2f | 10090 | fi |
5213506e | 10091 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
75923b2f | 10092 | fi |
5213506e RW |
10093 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_mkdir_takes_one_arg" >&5 |
10094 | $as_echo "$gcc_cv_mkdir_takes_one_arg" >&6; } | |
63cf211a | 10095 | if test $gcc_cv_mkdir_takes_one_arg = yes ; then |
ba479fd2 | 10096 | |
5213506e | 10097 | $as_echo "#define MKDIR_TAKES_ONE_ARG 1" >>confdefs.h |
75923b2f MK |
10098 | |
10099 | fi | |
10100 | ||
10101 | ||
861bb6c1 JL |
10102 | # File extensions |
10103 | manext='.1' | |
10104 | objext='.o' | |
10105 | ||
10106 | ||
10107 | ||
4977bab6 | 10108 | # With Setjmp/Longjmp based exception handling. |
5213506e RW |
10109 | # Check whether --enable-sjlj-exceptions was given. |
10110 | if test "${enable_sjlj_exceptions+set}" = set; then : | |
10111 | enableval=$enable_sjlj_exceptions; case $target in | |
399fe3e1 JDA |
10112 | *-*-hpux10*) |
10113 | if test $enableval != yes; then | |
5213506e RW |
10114 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: dwarf2 exceptions not supported, sjlj exceptions forced" >&5 |
10115 | $as_echo "$as_me: WARNING: dwarf2 exceptions not supported, sjlj exceptions forced" >&2;} | |
399fe3e1 JDA |
10116 | enableval=yes |
10117 | fi | |
10118 | ;; | |
10119 | esac | |
10120 | force_sjlj_exceptions=yes | |
10121 | else | |
10122 | case $target in | |
10123 | *-*-hpux10*) | |
10124 | force_sjlj_exceptions=yes | |
10125 | enableval=yes | |
10126 | ;; | |
10127 | *) | |
10128 | force_sjlj_exceptions=no | |
10129 | ;; | |
10130 | esac | |
5213506e RW |
10131 | fi |
10132 | ||
399fe3e1 | 10133 | if test $force_sjlj_exceptions = yes; then |
b61ff9c8 | 10134 | sjlj=`if test $enableval = yes; then echo 1; else echo 0; fi` |
63cf211a | 10135 | |
ba479fd2 NN |
10136 | cat >>confdefs.h <<_ACEOF |
10137 | #define CONFIG_SJLJ_EXCEPTIONS $sjlj | |
10138 | _ACEOF | |
4977bab6 | 10139 | |
399fe3e1 | 10140 | fi |
4977bab6 | 10141 | |
443728bb L |
10142 | # For platforms with the unwind ABI which includes an unwind library, |
10143 | # libunwind, we can choose to use the system libunwind. | |
e61c76c9 SE |
10144 | # config.gcc also contains tests of with_system_libunwind. |
10145 | ||
4977bab6 | 10146 | |
5213506e RW |
10147 | # Check whether --with-system-libunwind was given. |
10148 | if test "${with_system_libunwind+set}" = set; then : | |
10149 | withval=$with_system_libunwind; | |
10150 | fi | |
4977bab6 | 10151 | |
e61c76c9 SE |
10152 | # If system-libunwind was not specifically set, pick a default setting. |
10153 | if test x$with_system_libunwind = x; then | |
10154 | case ${target} in | |
10155 | ia64-*-hpux*) with_system_libunwind=yes ;; | |
10156 | *) with_system_libunwind=no ;; | |
10157 | esac | |
10158 | fi | |
10159 | # Based on system-libunwind and target, do we have ipinfo? | |
10160 | if test x$with_system_libunwind = xyes; then | |
10161 | case ${target} in | |
10162 | ia64-*-*) have_unwind_getipinfo=no ;; | |
10163 | *) have_unwind_getipinfo=yes ;; | |
10164 | esac | |
10165 | else | |
a0e02041 AP |
10166 | # Darwin before version 9 does not have _Unwind_GetIPInfo. |
10167 | ||
10168 | case ${target} in | |
10169 | *-*-darwin[3-8]|*-*-darwin[3-8].*) have_unwind_getipinfo=no ;; | |
10170 | *) have_unwind_getipinfo=yes ;; | |
10171 | esac | |
10172 | ||
e61c76c9 | 10173 | fi |
4977bab6 | 10174 | |
e61c76c9 | 10175 | if test x$have_unwind_getipinfo = xyes; then |
e64f5acf | 10176 | |
5213506e | 10177 | $as_echo "#define HAVE_GETIPINFO 1" >>confdefs.h |
e64f5acf | 10178 | |
e61c76c9 SE |
10179 | fi |
10180 | ||
e64f5acf | 10181 | |
34a86c2b NN |
10182 | # -------------------------------------------------------- |
10183 | # Build, host, and target specific configuration fragments | |
10184 | # -------------------------------------------------------- | |
10185 | ||
5b28c537 NN |
10186 | # Collect build-machine-specific information. |
10187 | . ${srcdir}/config.build | |
10188 | ||
a89ea0df NN |
10189 | # Collect host-machine-specific information. |
10190 | . ${srcdir}/config.host | |
10191 | ||
ef69da62 | 10192 | target_gtfiles= |
a89ea0df NN |
10193 | |
10194 | # Collect target-machine-specific information. | |
8ad9fb33 | 10195 | . ${srcdir}/config.gcc |
861bb6c1 JL |
10196 | |
10197 | extra_objs="${host_extra_objs} ${extra_objs}" | |
30500d84 | 10198 | extra_gcc_objs="${host_extra_gcc_objs} ${extra_gcc_objs}" |
861bb6c1 JL |
10199 | |
10200 | # Default the target-machine variables that were not explicitly set. | |
75bffa71 | 10201 | if test x"$tm_file" = x |
861bb6c1 JL |
10202 | then tm_file=$cpu_type/$cpu_type.h; fi |
10203 | ||
6b2adea9 | 10204 | if test x"$extra_headers" = x |
861bb6c1 JL |
10205 | then extra_headers=; fi |
10206 | ||
75bffa71 | 10207 | if test x$md_file = x |
e98e406f | 10208 | then md_file=$cpu_type/$cpu_type.md; fi |
861bb6c1 | 10209 | |
75bffa71 | 10210 | if test x$out_file = x |
861bb6c1 JL |
10211 | then out_file=$cpu_type/$cpu_type.c; fi |
10212 | ||
75bffa71 | 10213 | if test x"$tmake_file" = x |
861bb6c1 JL |
10214 | then tmake_file=$cpu_type/t-$cpu_type |
10215 | fi | |
10216 | ||
90e6a802 | 10217 | if test x"$dwarf2" = xyes |
756ee602 | 10218 | then tm_file="$tm_file tm-dwarf2.h" |
90e6a802 RL |
10219 | fi |
10220 | ||
861bb6c1 | 10221 | # Say what files are being used for the output code and MD file. |
11642c3a | 10222 | echo "Using \`$srcdir/config/$out_file' for machine-specific logic." |
861bb6c1 JL |
10223 | echo "Using \`$srcdir/config/$md_file' as machine description file." |
10224 | ||
11642c3a | 10225 | # If any of the xm_file variables contain nonexistent files, warn |
4dc0535b ZW |
10226 | # about them and drop them. |
10227 | ||
11642c3a ZW |
10228 | bx= |
10229 | for x in $build_xm_file; do | |
10230 | if test -f $srcdir/config/$x | |
10231 | then bx="$bx $x" | |
5213506e RW |
10232 | else { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $srcdir/config/$x does not exist." >&5 |
10233 | $as_echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;} | |
11642c3a ZW |
10234 | fi |
10235 | done | |
10236 | build_xm_file="$bx" | |
10237 | ||
10238 | hx= | |
10239 | for x in $host_xm_file; do | |
10240 | if test -f $srcdir/config/$x | |
10241 | then hx="$hx $x" | |
5213506e RW |
10242 | else { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $srcdir/config/$x does not exist." >&5 |
10243 | $as_echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;} | |
11642c3a ZW |
10244 | fi |
10245 | done | |
10246 | host_xm_file="$hx" | |
10247 | ||
10248 | tx= | |
10249 | for x in $xm_file; do | |
10250 | if test -f $srcdir/config/$x | |
10251 | then tx="$tx $x" | |
5213506e RW |
10252 | else { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $srcdir/config/$x does not exist." >&5 |
10253 | $as_echo "$as_me: WARNING: $srcdir/config/$x does not exist." >&2;} | |
11642c3a ZW |
10254 | fi |
10255 | done | |
10256 | xm_file="$tx" | |
10257 | ||
861bb6c1 JL |
10258 | count=a |
10259 | for f in $tm_file; do | |
10260 | count=${count}x | |
10261 | done | |
75bffa71 | 10262 | if test $count = ax; then |
861bb6c1 JL |
10263 | echo "Using \`$srcdir/config/$tm_file' as target machine macro file." |
10264 | else | |
10265 | echo "Using the following target machine macro files:" | |
10266 | for f in $tm_file; do | |
10267 | echo " $srcdir/config/$f" | |
10268 | done | |
10269 | fi | |
10270 | ||
4977bab6 | 10271 | if test x$need_64bit_hwint = xyes; then |
ba479fd2 | 10272 | |
5213506e | 10273 | $as_echo "#define NEED_64BIT_HOST_WIDE_INT 1" >>confdefs.h |
4977bab6 ZW |
10274 | |
10275 | fi | |
10276 | ||
99fa8911 AP |
10277 | if test x$use_long_long_for_widest_fast_int = xyes; then |
10278 | ||
5213506e | 10279 | $as_echo "#define USE_LONG_LONG_FOR_WIDEST_FAST_INT 1" >>confdefs.h |
99fa8911 AP |
10280 | |
10281 | fi | |
10282 | ||
861bb6c1 JL |
10283 | count=a |
10284 | for f in $host_xm_file; do | |
10285 | count=${count}x | |
10286 | done | |
11642c3a ZW |
10287 | if test $count = a; then |
10288 | : | |
10289 | elif test $count = ax; then | |
861bb6c1 JL |
10290 | echo "Using \`$srcdir/config/$host_xm_file' as host machine macro file." |
10291 | else | |
10292 | echo "Using the following host machine macro files:" | |
10293 | for f in $host_xm_file; do | |
10294 | echo " $srcdir/config/$f" | |
10295 | done | |
10296 | fi | |
476d9098 | 10297 | echo "Using ${out_host_hook_obj} for host machine hooks." |
861bb6c1 | 10298 | |
75bffa71 | 10299 | if test "$host_xm_file" != "$build_xm_file"; then |
861bb6c1 JL |
10300 | count=a |
10301 | for f in $build_xm_file; do | |
10302 | count=${count}x | |
10303 | done | |
11642c3a ZW |
10304 | if test $count = a; then |
10305 | : | |
10306 | elif test $count = ax; then | |
861bb6c1 JL |
10307 | echo "Using \`$srcdir/config/$build_xm_file' as build machine macro file." |
10308 | else | |
10309 | echo "Using the following build machine macro files:" | |
10310 | for f in $build_xm_file; do | |
10311 | echo " $srcdir/config/$f" | |
10312 | done | |
10313 | fi | |
10314 | fi | |
10315 | ||
4f6d8cc8 | 10316 | case ${host} in |
b8ec3cc8 | 10317 | powerpc*-*-darwin*) |
5213506e RW |
10318 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether mcontext_t fields have underscores" >&5 |
10319 | $as_echo_n "checking whether mcontext_t fields have underscores... " >&6; } | |
10320 | if test "${gcc_cv_mcontext_underscores+set}" = set; then : | |
10321 | $as_echo_n "(cached) " >&6 | |
4f6d8cc8 | 10322 | else |
5213506e RW |
10323 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
10324 | /* end confdefs.h. */ | |
4f6d8cc8 | 10325 | |
ba7da42a | 10326 | #include <sys/cdefs.h> |
de4fb767 | 10327 | #include <sys/signal.h> |
4f6d8cc8 GK |
10328 | #include <ucontext.h> |
10329 | int main() { mcontext_t m; if (m->ss.srr0) return 0; return 0; } | |
10330 | ||
10331 | _ACEOF | |
5213506e | 10332 | if ac_fn_c_try_compile "$LINENO"; then : |
4f6d8cc8 GK |
10333 | gcc_cv_mcontext_underscores=no |
10334 | else | |
5213506e | 10335 | gcc_cv_mcontext_underscores=yes |
4f6d8cc8 | 10336 | fi |
5213506e | 10337 | rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext |
4f6d8cc8 | 10338 | fi |
5213506e RW |
10339 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_mcontext_underscores" >&5 |
10340 | $as_echo "$gcc_cv_mcontext_underscores" >&6; } | |
4f6d8cc8 GK |
10341 | if test $gcc_cv_mcontext_underscores = yes; then |
10342 | ||
5213506e | 10343 | $as_echo "#define HAS_MCONTEXT_T_UNDERSCORES /**/" >>confdefs.h |
4f6d8cc8 GK |
10344 | |
10345 | fi | |
10346 | ;; | |
10347 | esac | |
10348 | ||
8bb915b6 NN |
10349 | # --------- |
10350 | # Threading | |
10351 | # --------- | |
10352 | ||
c2e494a8 | 10353 | # Check if a valid thread package |
615be2cf | 10354 | case ${enable_threads} in |
c2e494a8 NN |
10355 | "" | no) |
10356 | # No threads | |
10357 | target_thread_file='single' | |
10358 | ;; | |
10359 | yes) | |
10360 | # default | |
10361 | target_thread_file='single' | |
10362 | ;; | |
18167442 | 10363 | aix | dce | gnat | irix | posix | posix95 | rtems | \ |
d9dced13 | 10364 | single | solaris | vxworks | win32 | mipssde) |
615be2cf | 10365 | target_thread_file=${enable_threads} |
c2e494a8 NN |
10366 | ;; |
10367 | *) | |
615be2cf | 10368 | echo "${enable_threads} is an unknown thread package" 1>&2 |
c2e494a8 NN |
10369 | exit 1 |
10370 | ;; | |
10371 | esac | |
10372 | ||
10373 | if test x${thread_file} = x; then | |
10374 | # No thread file set by target-specific clauses in config.gcc, | |
10375 | # so use file chosen by default logic above | |
10376 | thread_file=${target_thread_file} | |
861bb6c1 JL |
10377 | fi |
10378 | ||
8bb915b6 NN |
10379 | # Make gthr-default.h if we have a thread file. |
10380 | gthread_flags= | |
10381 | if test $thread_file != single; then | |
b15a9f63 RW |
10382 | echo "#include \"gthr-${thread_file}.h\"" > gthr-default.h-t |
10383 | if diff gthr-default.h-t gthr-default.h 2>/dev/null; then | |
10384 | rm -f gthr-default.h-t | |
10385 | else | |
10386 | mv -f gthr-default.h-t gthr-default.h | |
10387 | fi | |
8bb915b6 NN |
10388 | gthread_flags=-DHAVE_GTHR_DEFAULT |
10389 | fi | |
10390 | ||
10391 | ||
10392 | # -------- | |
10393 | # UNSORTED | |
10394 | # -------- | |
10395 | ||
18fbf599 | 10396 | use_cxa_atexit=no |
2121a768 JT |
10397 | if test x$enable___cxa_atexit = xyes || \ |
10398 | test x$enable___cxa_atexit = x -a x$default_use_cxa_atexit = xyes; then | |
18fbf599 | 10399 | if test x$host = x$target; then |
97388150 DS |
10400 | case $host in |
10401 | # mingw32 doesn't have __cxa_atexit but uses atexit registration | |
10402 | # keyed to flag_use_cxa_atexit | |
10403 | *-*-mingw32*) | |
10404 | use_cxa_atexit=yes | |
10405 | ;; | |
10406 | *) | |
5213506e RW |
10407 | ac_fn_c_check_func "$LINENO" "__cxa_atexit" "ac_cv_func___cxa_atexit" |
10408 | if test "x$ac_cv_func___cxa_atexit" = x""yes; then : | |
18fbf599 PB |
10409 | use_cxa_atexit=yes |
10410 | else | |
10411 | echo "__cxa_atexit can't be enabled on this target" | |
10412 | fi | |
10413 | ||
5f60e48f | 10414 | ;; |
97388150 | 10415 | esac |
18fbf599 PB |
10416 | else |
10417 | # We can't check for __cxa_atexit when building a cross, so assume | |
10418 | # it is available | |
10419 | use_cxa_atexit=yes | |
10420 | fi | |
10421 | if test x$use_cxa_atexit = xyes; then | |
ba479fd2 | 10422 | |
5213506e | 10423 | $as_echo "#define DEFAULT_USE_CXA_ATEXIT 2" >>confdefs.h |
2121a768 | 10424 | |
18fbf599 | 10425 | fi |
2121a768 JT |
10426 | fi |
10427 | ||
a5381466 | 10428 | # Look for a file containing extra machine modes. |
1c0ca89d ZW |
10429 | if test -n "$extra_modes" && test -f $srcdir/config/$extra_modes; then |
10430 | extra_modes_file='$(srcdir)'/config/${extra_modes} | |
ba479fd2 NN |
10431 | |
10432 | ||
10433 | cat >>confdefs.h <<_ACEOF | |
e22340b0 | 10434 | #define EXTRA_MODES_FILE "config/$extra_modes" |
ba479fd2 | 10435 | _ACEOF |
a5381466 ZW |
10436 | |
10437 | fi | |
10438 | ||
75685792 RS |
10439 | # Convert extra_options into a form suitable for Makefile use. |
10440 | extra_opt_files= | |
10441 | for f in $extra_options; do | |
10442 | extra_opt_files="$extra_opt_files \$(srcdir)/config/$f" | |
10443 | done | |
10444 | ||
10445 | ||
b7cb92ad | 10446 | # auto-host.h is the file containing items generated by autoconf and is |
e9a25f70 | 10447 | # the first file included by config.h. |
4977bab6 | 10448 | # If host=build, it is correct to have bconfig include auto-host.h |
ba479fd2 | 10449 | # as well. If host!=build, we are in error and need to do more |
db81d74a | 10450 | # work to find out the build config parameters. |
75bffa71 | 10451 | if test x$host = x$build |
db81d74a | 10452 | then |
eaf4e618 | 10453 | build_auto=auto-host.h |
b7cb92ad JL |
10454 | else |
10455 | # We create a subdir, then run autoconf in the subdir. | |
10456 | # To prevent recursion we set host and build for the new | |
10457 | # invocation of configure to the build for this invocation | |
ba479fd2 | 10458 | # of configure. |
b7cb92ad JL |
10459 | tempdir=build.$$ |
10460 | rm -rf $tempdir | |
10461 | mkdir $tempdir | |
10462 | cd $tempdir | |
10463 | case ${srcdir} in | |
255b8a49 | 10464 | /* | A-Za-z:\\/* ) realsrcdir=${srcdir};; |
b7cb92ad JL |
10465 | *) realsrcdir=../${srcdir};; |
10466 | esac | |
d920e825 L |
10467 | saved_CFLAGS="${CFLAGS}" |
10468 | CC="${CC_FOR_BUILD}" CFLAGS="${CFLAGS_FOR_BUILD}" \ | |
f8c33439 | 10469 | LDFLAGS="${LDFLAGS_FOR_BUILD}" \ |
d920e825 | 10470 | ${realsrcdir}/configure \ |
33e70558 | 10471 | --enable-languages=${enable_languages-all} \ |
534d0cc0 | 10472 | --target=$target_alias --host=$build_alias --build=$build_alias |
d920e825 | 10473 | CFLAGS="${saved_CFLAGS}" |
b7cb92ad JL |
10474 | |
10475 | # We just finished tests for the build machine, so rename | |
10476 | # the file auto-build.h in the gcc directory. | |
10477 | mv auto-host.h ../auto-build.h | |
10478 | cd .. | |
10479 | rm -rf $tempdir | |
eaf4e618 | 10480 | build_auto=auto-build.h |
db81d74a RH |
10481 | fi |
10482 | ||
06f0b04c | 10483 | |
eaf4e618 | 10484 | tm_file="${tm_file} defaults.h" |
4977bab6 ZW |
10485 | tm_p_file="${tm_p_file} tm-preds.h" |
10486 | host_xm_file="auto-host.h ansidecl.h ${host_xm_file}" | |
10487 | build_xm_file="${build_auto} ansidecl.h ${build_xm_file}" | |
49691411 | 10488 | # We don't want ansidecl.h in target files, write code there in ISO/GNU C. |
b4862477 | 10489 | # put this back in temporarily. |
232b67d9 | 10490 | xm_file="auto-host.h ansidecl.h ${xm_file}" |
0056a9b5 | 10491 | |
34a86c2b NN |
10492 | # -------- |
10493 | # UNSORTED | |
10494 | # -------- | |
10495 | ||
cc1e60ea | 10496 | # Compile in configure arguments. |
8105825d | 10497 | if test -f configargs.h ; then |
cc1e60ea | 10498 | # Being re-configured. |
022dae81 | 10499 | gcc_config_arguments=`grep configuration_arguments configargs.h | sed -e 's/.*"\([^"]*\)".*/\1/'` |
cc1e60ea JM |
10500 | gcc_config_arguments="$gcc_config_arguments : (reconfigured) $TOPLEVEL_CONFIGURE_ARGUMENTS" |
10501 | else | |
10502 | gcc_config_arguments="$TOPLEVEL_CONFIGURE_ARGUMENTS" | |
10503 | fi | |
eeae7b41 DJ |
10504 | |
10505 | # Double all backslashes and backslash all quotes to turn | |
10506 | # gcc_config_arguments into a C string. | |
10507 | sed -e 's/\\/\\\\/g; s/"/\\"/g' <<EOF >conftest.out | |
10508 | $gcc_config_arguments | |
10509 | EOF | |
10510 | gcc_config_arguments_str=`cat conftest.out` | |
10511 | rm -f conftest.out | |
10512 | ||
cc1e60ea JM |
10513 | cat > configargs.h <<EOF |
10514 | /* Generated automatically. */ | |
eeae7b41 | 10515 | static const char configuration_arguments[] = "$gcc_config_arguments_str"; |
a6687d2b | 10516 | static const char thread_model[] = "$thread_file"; |
7816bea0 DJ |
10517 | |
10518 | static const struct { | |
10519 | const char *name, *value; | |
10520 | } configure_default_options[] = $configure_default_options; | |
cc1e60ea JM |
10521 | EOF |
10522 | ||
40540e68 RAE |
10523 | gcc_BASEVER=`cat $srcdir/BASE-VER` |
10524 | gcc_DEVPHASE=`cat $srcdir/DEV-PHASE` | |
10525 | gcc_DATESTAMP=`cat $srcdir/DATESTAMP` | |
0c463e16 | 10526 | if test -f $srcdir/REVISION ; then |
40540e68 | 10527 | gcc_REVISION=`cat $srcdir/REVISION` |
0c463e16 RAE |
10528 | else |
10529 | gcc_REVISION="" | |
10530 | fi | |
10531 | cat > plugin-version.h <<EOF | |
10532 | #include "configargs.h" | |
10533 | ||
10534 | static char basever[] = "$gcc_BASEVER"; | |
10535 | static char datestamp[] = "$gcc_DATESTAMP"; | |
10536 | static char devphase[] = "$gcc_DEVPHASE"; | |
10537 | static char revision[] = "$gcc_REVISION"; | |
10538 | ||
10539 | /* FIXME plugins: We should make the version information more precise. | |
10540 | One way to do is to add a checksum. */ | |
10541 | ||
10542 | static struct plugin_gcc_version gcc_version = {basever, datestamp, | |
10543 | devphase, revision, | |
10544 | configuration_arguments}; | |
10545 | EOF | |
10546 | ||
ab87f8c8 | 10547 | # Internationalization |
18fc9bd4 RG |
10548 | # If we haven't got the data from the intl directory, |
10549 | # assume NLS is disabled. | |
10550 | USE_NLS=no | |
10551 | LIBINTL= | |
10552 | LIBINTL_DEP= | |
10553 | INCINTL= | |
10554 | XGETTEXT= | |
10555 | GMSGFMT= | |
10556 | POSUB= | |
10557 | ||
10558 | if test -f ../intl/config.intl; then | |
10559 | . ../intl/config.intl | |
10560 | fi | |
5213506e RW |
10561 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether NLS is requested" >&5 |
10562 | $as_echo_n "checking whether NLS is requested... " >&6; } | |
18fc9bd4 | 10563 | if test x"$USE_NLS" != xyes; then |
5213506e RW |
10564 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
10565 | $as_echo "no" >&6; } | |
18fc9bd4 | 10566 | else |
5213506e RW |
10567 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
10568 | $as_echo "yes" >&6; } | |
18fc9bd4 | 10569 | |
5213506e | 10570 | $as_echo "#define ENABLE_NLS 1" >>confdefs.h |
18fc9bd4 RG |
10571 | |
10572 | ||
5213506e RW |
10573 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for catalogs to be installed" >&5 |
10574 | $as_echo_n "checking for catalogs to be installed... " >&6; } | |
18fc9bd4 RG |
10575 | # Look for .po and .gmo files in the source directory. |
10576 | CATALOGS= | |
10577 | XLINGUAS= | |
10578 | for cat in $srcdir/po/*.gmo $srcdir/po/*.po; do | |
10579 | # If there aren't any .gmo files the shell will give us the | |
10580 | # literal string "../path/to/srcdir/po/*.gmo" which has to be | |
10581 | # weeded out. | |
10582 | case "$cat" in *\**) | |
10583 | continue;; | |
10584 | esac | |
10585 | # The quadruple backslash is collapsed to a double backslash | |
10586 | # by the backticks, then collapsed again by the double quotes, | |
10587 | # leaving us with one backslash in the sed expression (right | |
10588 | # before the dot that mustn't act as a wildcard). | |
10589 | cat=`echo $cat | sed -e "s!$srcdir/po/!!" -e "s!\\\\.po!.gmo!"` | |
10590 | lang=`echo $cat | sed -e "s!\\\\.gmo!!"` | |
10591 | # The user is allowed to set LINGUAS to a list of languages to | |
10592 | # install catalogs for. If it's empty that means "all of them." | |
10593 | if test "x$LINGUAS" = x; then | |
10594 | CATALOGS="$CATALOGS $cat" | |
10595 | XLINGUAS="$XLINGUAS $lang" | |
10596 | else | |
10597 | case "$LINGUAS" in *$lang*) | |
10598 | CATALOGS="$CATALOGS $cat" | |
10599 | XLINGUAS="$XLINGUAS $lang" | |
10600 | ;; | |
10601 | esac | |
10602 | fi | |
10603 | done | |
10604 | LINGUAS="$XLINGUAS" | |
5213506e RW |
10605 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LINGUAS" >&5 |
10606 | $as_echo "$LINGUAS" >&6; } | |
18fc9bd4 RG |
10607 | |
10608 | ||
10609 | DATADIRNAME=share | |
10610 | ||
10611 | INSTOBJEXT=.mo | |
10612 | ||
10613 | GENCAT=gencat | |
10614 | ||
10615 | CATOBJEXT=.gmo | |
10616 | ||
10617 | fi | |
861bb6c1 | 10618 | |
56694dd9 ZW |
10619 | # If LIBINTL contains LIBICONV, then clear LIBICONV so we don't get |
10620 | # -liconv on the link line twice. | |
10621 | case "$LIBINTL" in *$LIBICONV*) | |
10622 | LIBICONV= ;; | |
10623 | esac | |
dc6746e7 | 10624 | |
5213506e RW |
10625 | # Check whether --enable-secureplt was given. |
10626 | if test "${enable_secureplt+set}" = set; then : | |
10627 | enableval=$enable_secureplt; | |
10628 | fi | |
7f970b70 | 10629 | |
922e3e33 | 10630 | |
5213506e RW |
10631 | # Check whether --enable-cld was given. |
10632 | if test "${enable_cld+set}" = set; then : | |
10633 | enableval=$enable_cld; | |
922e3e33 UB |
10634 | else |
10635 | enable_cld=no | |
5213506e RW |
10636 | fi |
10637 | ||
922e3e33 | 10638 | |
56694dd9 | 10639 | # Windows32 Registry support for specifying GCC installation paths. |
5213506e RW |
10640 | # Check whether --enable-win32-registry was given. |
10641 | if test "${enable_win32_registry+set}" = set; then : | |
10642 | enableval=$enable_win32_registry; | |
10643 | fi | |
dc6746e7 | 10644 | |
ba479fd2 | 10645 | |
a1286ef5 ZW |
10646 | case $host_os in |
10647 | win32 | pe | cygwin* | mingw32* | uwin*) | |
10648 | if test "x$enable_win32_registry" != xno; then | |
5213506e RW |
10649 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing RegOpenKeyExA" >&5 |
10650 | $as_echo_n "checking for library containing RegOpenKeyExA... " >&6; } | |
10651 | if test "${ac_cv_search_RegOpenKeyExA+set}" = set; then : | |
10652 | $as_echo_n "(cached) " >&6 | |
ba479fd2 NN |
10653 | else |
10654 | ac_func_search_save_LIBS=$LIBS | |
5213506e | 10655 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
ba479fd2 | 10656 | /* end confdefs.h. */ |
861bb6c1 | 10657 | |
5213506e RW |
10658 | /* Override any GCC internal prototype to avoid an error. |
10659 | Use char because int might match the return type of a GCC | |
10660 | builtin and then its argument prototype would still apply. */ | |
ba479fd2 NN |
10661 | #ifdef __cplusplus |
10662 | extern "C" | |
10663 | #endif | |
ba479fd2 NN |
10664 | char RegOpenKeyExA (); |
10665 | int | |
10666 | main () | |
10667 | { | |
5213506e | 10668 | return RegOpenKeyExA (); |
ba479fd2 NN |
10669 | ; |
10670 | return 0; | |
10671 | } | |
10672 | _ACEOF | |
5213506e RW |
10673 | for ac_lib in '' advapi32; do |
10674 | if test -z "$ac_lib"; then | |
10675 | ac_res="none required" | |
10676 | else | |
10677 | ac_res=-l$ac_lib | |
b61ff9c8 | 10678 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" |
5213506e RW |
10679 | fi |
10680 | if ac_fn_c_try_link "$LINENO"; then : | |
10681 | ac_cv_search_RegOpenKeyExA=$ac_res | |
10682 | fi | |
10683 | rm -f core conftest.err conftest.$ac_objext \ | |
10684 | conftest$ac_exeext | |
10685 | if test "${ac_cv_search_RegOpenKeyExA+set}" = set; then : | |
10686 | break | |
10687 | fi | |
10688 | done | |
10689 | if test "${ac_cv_search_RegOpenKeyExA+set}" = set; then : | |
2f41c1d6 | 10690 | |
1a4b763e | 10691 | else |
5213506e | 10692 | ac_cv_search_RegOpenKeyExA=no |
dd7f7a6e | 10693 | fi |
5213506e | 10694 | rm conftest.$ac_ext |
dd7f7a6e EC |
10695 | LIBS=$ac_func_search_save_LIBS |
10696 | fi | |
5213506e RW |
10697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_RegOpenKeyExA" >&5 |
10698 | $as_echo "$ac_cv_search_RegOpenKeyExA" >&6; } | |
10699 | ac_res=$ac_cv_search_RegOpenKeyExA | |
10700 | if test "$ac_res" != no; then : | |
10701 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
dd7f7a6e EC |
10702 | |
10703 | else | |
10704 | enable_win32_registry=no | |
10705 | fi | |
10706 | ||
10707 | fi | |
10708 | ||
10709 | if test "x$enable_win32_registry" != xno; then | |
10710 | ||
5213506e | 10711 | $as_echo "#define ENABLE_WIN32_REGISTRY 1" >>confdefs.h |
dd7f7a6e EC |
10712 | |
10713 | ||
10714 | if test "x$enable_win32_registry" != xyes \ | |
10715 | && test "x$enable_win32_registry" != x; then | |
10716 | ||
10717 | cat >>confdefs.h <<_ACEOF | |
10718 | #define WIN32_REGISTRY_KEY "$enable_win32_registry" | |
10719 | _ACEOF | |
10720 | ||
10721 | fi | |
10722 | fi | |
10723 | ;; | |
10724 | esac | |
ab87f8c8 | 10725 | |
56694dd9 ZW |
10726 | # Get an absolute path to the GCC top-level source directory |
10727 | holddir=`${PWDCMD-pwd}` | |
10728 | cd $srcdir | |
10729 | topdir=`${PWDCMD-pwd}` | |
10730 | cd $holddir | |
ab87f8c8 | 10731 | |
56694dd9 | 10732 | # Conditionalize the makefile for this host machine. |
2ed26f6b | 10733 | xmake_file= |
c406e779 | 10734 | for f in ${host_xmake_file} |
56694dd9 ZW |
10735 | do |
10736 | if test -f ${srcdir}/config/$f | |
10737 | then | |
2ed26f6b | 10738 | xmake_file="${xmake_file} \$(srcdir)/config/$f" |
56694dd9 ZW |
10739 | fi |
10740 | done | |
093e61a6 | 10741 | |
56694dd9 | 10742 | # Conditionalize the makefile for this target machine. |
2ed26f6b | 10743 | tmake_file_= |
c406e779 | 10744 | for f in ${tmake_file} |
56694dd9 ZW |
10745 | do |
10746 | if test -f ${srcdir}/config/$f | |
10747 | then | |
2ed26f6b | 10748 | tmake_file_="${tmake_file_} \$(srcdir)/config/$f" |
56694dd9 ZW |
10749 | fi |
10750 | done | |
2ed26f6b | 10751 | tmake_file="${tmake_file_}" |
71a94577 | 10752 | |
ab87f8c8 JL |
10753 | out_object_file=`basename $out_file .c`.o |
10754 | ||
75685792 RS |
10755 | tm_file_list="options.h" |
10756 | tm_include_list="options.h" | |
ab87f8c8 | 10757 | for f in $tm_file; do |
64ccbc99 | 10758 | case $f in |
3ca43df7 RS |
10759 | ./* ) |
10760 | f=`echo $f | sed 's/^..//'` | |
10761 | tm_file_list="${tm_file_list} $f" | |
10762 | tm_include_list="${tm_include_list} $f" | |
10763 | ;; | |
d02af173 | 10764 | defaults.h ) |
e22340b0 ZW |
10765 | tm_file_list="${tm_file_list} \$(srcdir)/$f" |
10766 | tm_include_list="${tm_include_list} $f" | |
10767 | ;; | |
10768 | * ) | |
10769 | tm_file_list="${tm_file_list} \$(srcdir)/config/$f" | |
10770 | tm_include_list="${tm_include_list} config/$f" | |
10771 | ;; | |
64ccbc99 | 10772 | esac |
ab87f8c8 JL |
10773 | done |
10774 | ||
11642c3a | 10775 | tm_p_file_list= |
e22340b0 | 10776 | tm_p_include_list= |
11642c3a | 10777 | for f in $tm_p_file; do |
4977bab6 ZW |
10778 | case $f in |
10779 | tm-preds.h ) | |
e22340b0 ZW |
10780 | tm_p_file_list="${tm_p_file_list} $f" |
10781 | tm_p_include_list="${tm_p_include_list} $f" | |
10782 | ;; | |
10783 | * ) | |
10784 | tm_p_file_list="${tm_p_file_list} \$(srcdir)/config/$f" | |
10785 | tm_p_include_list="${tm_p_include_list} config/$f" | |
10786 | esac | |
10787 | done | |
10788 | ||
10789 | xm_file_list= | |
10790 | xm_include_list= | |
10791 | for f in $xm_file; do | |
10792 | case $f in | |
10793 | ansidecl.h ) | |
10794 | xm_file_list="${xm_file_list} \$(srcdir)/../include/$f" | |
10795 | xm_include_list="${xm_include_list} $f" | |
10796 | ;; | |
10797 | auto-host.h ) | |
10798 | xm_file_list="${xm_file_list} $f" | |
10799 | xm_include_list="${xm_include_list} $f" | |
10800 | ;; | |
10801 | * ) | |
10802 | xm_file_list="${xm_file_list} \$(srcdir)/config/$f" | |
10803 | xm_include_list="${xm_include_list} config/$f" | |
10804 | ;; | |
4977bab6 | 10805 | esac |
11642c3a ZW |
10806 | done |
10807 | ||
ab87f8c8 | 10808 | host_xm_file_list= |
e22340b0 | 10809 | host_xm_include_list= |
ab87f8c8 | 10810 | for f in $host_xm_file; do |
64ccbc99 | 10811 | case $f in |
d02af173 | 10812 | ansidecl.h ) |
e22340b0 ZW |
10813 | host_xm_file_list="${host_xm_file_list} \$(srcdir)/../include/$f" |
10814 | host_xm_include_list="${host_xm_include_list} $f" | |
10815 | ;; | |
e2500fed | 10816 | auto-host.h ) |
e22340b0 ZW |
10817 | host_xm_file_list="${host_xm_file_list} $f" |
10818 | host_xm_include_list="${host_xm_include_list} $f" | |
10819 | ;; | |
10820 | * ) | |
10821 | host_xm_file_list="${host_xm_file_list} \$(srcdir)/config/$f" | |
10822 | host_xm_include_list="${host_xm_include_list} config/$f" | |
10823 | ;; | |
64ccbc99 | 10824 | esac |
ab87f8c8 JL |
10825 | done |
10826 | ||
10827 | build_xm_file_list= | |
10828 | for f in $build_xm_file; do | |
64ccbc99 | 10829 | case $f in |
d02af173 | 10830 | ansidecl.h ) |
e22340b0 ZW |
10831 | build_xm_file_list="${build_xm_file_list} \$(srcdir)/../include/$f" |
10832 | build_xm_include_list="${build_xm_include_list} $f" | |
10833 | ;; | |
e2500fed | 10834 | auto-build.h | auto-host.h ) |
e22340b0 ZW |
10835 | build_xm_file_list="${build_xm_file_list} $f" |
10836 | build_xm_include_list="${build_xm_include_list} $f" | |
10837 | ;; | |
10838 | * ) | |
10839 | build_xm_file_list="${build_xm_file_list} \$(srcdir)/config/$f" | |
10840 | build_xm_include_list="${build_xm_include_list} config/$f" | |
10841 | ;; | |
64ccbc99 | 10842 | esac |
ab87f8c8 JL |
10843 | done |
10844 | ||
2989d30c GK |
10845 | # Define macro CROSS_DIRECTORY_STRUCTURE in compilation if this is a |
10846 | # cross-compiler which does not use the native headers and libraries. | |
a078a589 | 10847 | # Also use all.cross instead of all.internal and adjust SYSTEM_HEADER_DIR. |
ba479fd2 NN |
10848 | CROSS= |
10849 | ALL=all.internal | |
10850 | SYSTEM_HEADER_DIR='$(NATIVE_SYSTEM_HEADER_DIR)' | |
b28250ab MM |
10851 | |
10852 | if test "x$with_build_sysroot" != x; then | |
14da6073 | 10853 | build_system_header_dir=$with_build_sysroot'$${sysroot_headers_suffix}$(NATIVE_SYSTEM_HEADER_DIR)' |
b28250ab MM |
10854 | else |
10855 | # This value is used, even on a native system, because | |
10856 | # CROSS_SYSTEM_HEADER_DIR is just | |
10857 | # $(TARGET_SYSTEM_ROOT)$(NATIVE_SYSTEM_HEADER_DIR). | |
10858 | build_system_header_dir='$(CROSS_SYSTEM_HEADER_DIR)' | |
10859 | fi | |
10860 | ||
ab87f8c8 JL |
10861 | if test x$host != x$target |
10862 | then | |
2989d30c | 10863 | CROSS="-DCROSS_DIRECTORY_STRUCTURE" |
a078a589 | 10864 | ALL=all.cross |
160633c6 | 10865 | SYSTEM_HEADER_DIR=$build_system_header_dir |
343f59d9 | 10866 | case "$host","$target" in |
3a7e8b87 GK |
10867 | # Darwin crosses can use the host system's libraries and headers, |
10868 | # because of the fat library support. Of course, it must be the | |
10869 | # same version of Darwin on both sides. Allow the user to | |
10870 | # just say --target=foo-darwin without a version number to mean | |
10871 | # "the version on this system". | |
10872 | *-*-darwin*,*-*-darwin*) | |
10873 | hostos=`echo $host | sed 's/.*-darwin/darwin/'` | |
10874 | targetos=`echo $target | sed 's/.*-darwin/darwin/'` | |
10875 | if test $hostos = $targetos -o $targetos = darwin ; then | |
10876 | CROSS= | |
10877 | SYSTEM_HEADER_DIR='$(NATIVE_SYSTEM_HEADER_DIR)' | |
10878 | with_headers=yes | |
10879 | fi | |
10880 | ;; | |
10881 | ||
343f59d9 AM |
10882 | i?86-*-*,x86_64-*-* \ |
10883 | | powerpc*-*-*,powerpc64*-*-*) | |
10884 | CROSS="$CROSS -DNATIVE_CROSS" ;; | |
10885 | esac | |
7a615b25 | 10886 | elif test "x$TARGET_SYSTEM_ROOT" != x; then |
b28250ab | 10887 | SYSTEM_HEADER_DIR=$build_system_header_dir |
ab87f8c8 JL |
10888 | fi |
10889 | ||
b39d221a EC |
10890 | # If this is a cross-compiler that does not |
10891 | # have its own set of headers then define | |
10892 | # inhibit_libc | |
10893 | ||
dc06db20 R |
10894 | # If this is using newlib, without having the headers available now, |
10895 | # then define inhibit_libc in LIBGCC2_CFLAGS. | |
fecd6201 ZW |
10896 | # This prevents libgcc2 from containing any code which requires libc |
10897 | # support. | |
a929bc28 | 10898 | : ${inhibit_libc=false} |
dc06db20 R |
10899 | if { { test x$host != x$target && test "x$with_sysroot" = x ; } || |
10900 | test x$with_newlib = xyes ; } && | |
e50084fa | 10901 | { test "x$with_headers" = x || test "x$with_headers" = xno ; } ; then |
160633c6 | 10902 | inhibit_libc=true |
b39d221a EC |
10903 | fi |
10904 | ||
10905 | ||
a078a589 ZW |
10906 | # When building gcc with a cross-compiler, we need to adjust things so |
10907 | # that the generator programs are still built with the native compiler. | |
52c0e446 | 10908 | # Also, we cannot run fixincludes. |
a078a589 ZW |
10909 | |
10910 | # These are the normal (build=host) settings: | |
ba479fd2 NN |
10911 | CC_FOR_BUILD='$(CC)' |
10912 | BUILD_CFLAGS='$(ALL_CFLAGS)' | |
f8c33439 | 10913 | BUILD_LDFLAGS='$(LDFLAGS)' |
ba479fd2 | 10914 | STMP_FIXINC=stmp-fixinc |
8ad9fb33 | 10915 | |
83599948 NS |
10916 | # And these apply if build != host, or we are generating coverage data |
10917 | if test x$build != x$host || test "x$coverage_flags" != x | |
ab87f8c8 | 10918 | then |
b11e4747 | 10919 | BUILD_CFLAGS='$(INTERNAL_CFLAGS) $(T_CFLAGS) $(CFLAGS_FOR_BUILD)' |
f8c33439 | 10920 | BUILD_LDFLAGS='$(LDFLAGS_FOR_BUILD)' |
ab87f8c8 JL |
10921 | fi |
10922 | ||
10923 | # Expand extra_headers to include complete path. | |
10924 | # This substitutes for lots of t-* files. | |
10925 | extra_headers_list= | |
b1ef58c8 NN |
10926 | # Prepend $(srcdir)/config/${cpu_type}/ to every entry in extra_headers. |
10927 | for file in ${extra_headers} ; do | |
10928 | extra_headers_list="${extra_headers_list} \$(srcdir)/config/${cpu_type}/${file}" | |
10929 | done | |
ab87f8c8 | 10930 | |
1617e5ee GK |
10931 | # If use_gcc_tgmath is set, append ginclude/tgmath.h. |
10932 | if test x"$use_gcc_tgmath" = xyes | |
10933 | then extra_headers_list="${extra_headers_list} \$(srcdir)/ginclude/tgmath.h" | |
10934 | fi | |
10935 | ||
c38f02df ILT |
10936 | # Define collect2 in Makefile. |
10937 | case $host_can_use_collect2 in | |
10938 | no) collect2= ;; | |
10939 | *) collect2='collect2$(exeext)' ;; | |
10940 | esac | |
10941 | ||
10942 | ||
ab87f8c8 | 10943 | # Add a definition of USE_COLLECT2 if system wants one. |
34a86c2b NN |
10944 | case $use_collect2 in |
10945 | no) use_collect2= ;; | |
10946 | "") ;; | |
ba479fd2 | 10947 | *) |
34a86c2b NN |
10948 | host_xm_defines="${host_xm_defines} USE_COLLECT2" |
10949 | xm_defines="${xm_defines} USE_COLLECT2" | |
c38f02df ILT |
10950 | case $host_can_use_collect2 in |
10951 | no) | |
5213506e | 10952 | as_fn_error "collect2 is required but cannot be built on this system" "$LINENO" 5 |
c38f02df ILT |
10953 | ;; |
10954 | esac | |
34a86c2b NN |
10955 | ;; |
10956 | esac | |
ab87f8c8 | 10957 | |
8bb915b6 NN |
10958 | # --------------------------- |
10959 | # Assembler & linker features | |
10960 | # --------------------------- | |
10961 | ||
da0f6381 PB |
10962 | # During stage 2, ld is actually gcc/collect-ld, which is a small script to |
10963 | # discern between when to use prev-ld/ld-new and when to use ld/ld-new. | |
10964 | # However when ld-new is first executed from the build tree, libtool will | |
10965 | # relink it as .libs/lt-ld-new, so that it can give it an RPATH that refers | |
10966 | # to the build tree. While doing this we need to use the previous-stage | |
10967 | # linker, or we have an infinite loop. The presence of a shell script as | |
10968 | # ld/ld-new, and the fact that the script *uses ld itself*, is what confuses | |
10969 | # the gcc/collect-ld script. So we need to know how libtool works, or | |
10970 | # exec-tool will fail. | |
e8b05380 | 10971 | |
da0f6381 | 10972 | |
5d47bb02 PG |
10973 | case `pwd` in |
10974 | *\ * | *\ *) | |
5213506e RW |
10975 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&5 |
10976 | $as_echo "$as_me: WARNING: Libtool does not cope well with whitespace in \`pwd\`" >&2;} ;; | |
5d47bb02 | 10977 | esac |
da0f6381 PB |
10978 | |
10979 | ||
da0f6381 | 10980 | |
43e02a8a RW |
10981 | macro_version='2.2.7a' |
10982 | macro_revision='1.3134' | |
da0f6381 PB |
10983 | |
10984 | ||
10985 | ||
10986 | ||
10987 | ||
10988 | ||
da0f6381 PB |
10989 | |
10990 | ||
10991 | ||
10992 | ||
10993 | ||
10994 | ||
10995 | ||
5d47bb02 | 10996 | ltmain="$ac_aux_dir/ltmain.sh" |
da0f6381 | 10997 | |
43e02a8a RW |
10998 | # Backslashify metacharacters that are still active within |
10999 | # double-quoted strings. | |
11000 | sed_quote_subst='s/\(["`$\\]\)/\\\1/g' | |
11001 | ||
11002 | # Same as above, but do not quote variable references. | |
11003 | double_quote_subst='s/\(["`\\]\)/\\\1/g' | |
11004 | ||
11005 | # Sed substitution to delay expansion of an escaped shell variable in a | |
11006 | # double_quote_subst'ed string. | |
11007 | delay_variable_subst='s/\\\\\\\\\\\$/\\\\\\$/g' | |
11008 | ||
11009 | # Sed substitution to delay expansion of an escaped single quote. | |
11010 | delay_single_quote_subst='s/'\''/'\'\\\\\\\'\''/g' | |
11011 | ||
11012 | # Sed substitution to avoid accidental globbing in evaled expressions | |
11013 | no_glob_subst='s/\*/\\\*/g' | |
11014 | ||
11015 | ECHO='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
11016 | ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO | |
11017 | ECHO=$ECHO$ECHO$ECHO$ECHO$ECHO$ECHO | |
11018 | ||
11019 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to print strings" >&5 | |
11020 | $as_echo_n "checking how to print strings... " >&6; } | |
11021 | # Test print first, because it will be a builtin if present. | |
11022 | if test "X`print -r -- -n 2>/dev/null`" = X-n && \ | |
11023 | test "X`print -r -- $ECHO 2>/dev/null`" = "X$ECHO"; then | |
11024 | ECHO='print -r --' | |
11025 | elif test "X`printf %s $ECHO 2>/dev/null`" = "X$ECHO"; then | |
11026 | ECHO='printf %s\n' | |
11027 | else | |
11028 | # Use this function as a fallback that always works. | |
11029 | func_fallback_echo () | |
11030 | { | |
11031 | eval 'cat <<_LTECHO_EOF | |
11032 | $1 | |
11033 | _LTECHO_EOF' | |
11034 | } | |
11035 | ECHO='func_fallback_echo' | |
11036 | fi | |
11037 | ||
11038 | # func_echo_all arg... | |
11039 | # Invoke $ECHO with all args, space-separated. | |
11040 | func_echo_all () | |
11041 | { | |
11042 | $ECHO "" | |
11043 | } | |
11044 | ||
11045 | case "$ECHO" in | |
11046 | printf*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: printf" >&5 | |
11047 | $as_echo "printf" >&6; } ;; | |
11048 | print*) { $as_echo "$as_me:${as_lineno-$LINENO}: result: print -r" >&5 | |
11049 | $as_echo "print -r" >&6; } ;; | |
11050 | *) { $as_echo "$as_me:${as_lineno-$LINENO}: result: cat" >&5 | |
11051 | $as_echo "cat" >&6; } ;; | |
11052 | esac | |
11053 | ||
11054 | ||
11055 | ||
11056 | ||
11057 | ||
11058 | ||
11059 | ||
11060 | ||
11061 | ||
11062 | ||
11063 | ||
11064 | ||
11065 | ||
11066 | ||
5213506e RW |
11067 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 |
11068 | $as_echo_n "checking for a sed that does not truncate output... " >&6; } | |
11069 | if test "${ac_cv_path_SED+set}" = set; then : | |
11070 | $as_echo_n "(cached) " >&6 | |
11071 | else | |
11072 | ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ | |
11073 | for ac_i in 1 2 3 4 5 6 7; do | |
11074 | ac_script="$ac_script$as_nl$ac_script" | |
11075 | done | |
11076 | echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed | |
11077 | { ac_script=; unset ac_script;} | |
11078 | if test -z "$SED"; then | |
11079 | ac_path_SED_found=false | |
11080 | # Loop through the user's path and test for each of PROGNAME-LIST | |
11081 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
e8b05380 PB |
11082 | for as_dir in $PATH |
11083 | do | |
11084 | IFS=$as_save_IFS | |
11085 | test -z "$as_dir" && as_dir=. | |
5213506e | 11086 | for ac_prog in sed gsed; do |
da0f6381 | 11087 | for ac_exec_ext in '' $ac_executable_extensions; do |
5213506e RW |
11088 | ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" |
11089 | { test -f "$ac_path_SED" && $as_test_x "$ac_path_SED"; } || continue | |
11090 | # Check for GNU ac_path_SED and select it if it is found. | |
11091 | # Check for GNU $ac_path_SED | |
11092 | case `"$ac_path_SED" --version 2>&1` in | |
11093 | *GNU*) | |
11094 | ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; | |
11095 | *) | |
11096 | ac_count=0 | |
11097 | $as_echo_n 0123456789 >"conftest.in" | |
11098 | while : | |
11099 | do | |
11100 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
11101 | mv "conftest.tmp" "conftest.in" | |
11102 | cp "conftest.in" "conftest.nl" | |
11103 | $as_echo '' >> "conftest.nl" | |
11104 | "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
11105 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
11106 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
11107 | if test $ac_count -gt ${ac_path_SED_max-0}; then | |
11108 | # Best one so far, save it but keep looking for a better one | |
11109 | ac_cv_path_SED="$ac_path_SED" | |
11110 | ac_path_SED_max=$ac_count | |
11111 | fi | |
11112 | # 10*(2^10) chars as input seems more than enough | |
11113 | test $ac_count -gt 10 && break | |
11114 | done | |
11115 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
11116 | esac | |
11117 | ||
11118 | $ac_path_SED_found && break 3 | |
da0f6381 PB |
11119 | done |
11120 | done | |
5213506e | 11121 | done |
da0f6381 | 11122 | IFS=$as_save_IFS |
5213506e RW |
11123 | if test -z "$ac_cv_path_SED"; then |
11124 | as_fn_error "no acceptable sed could be found in \$PATH" "$LINENO" 5 | |
da0f6381 | 11125 | fi |
5213506e RW |
11126 | else |
11127 | ac_cv_path_SED=$SED | |
e8b05380 | 11128 | fi |
b61ff9c8 | 11129 | |
5213506e RW |
11130 | fi |
11131 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 | |
11132 | $as_echo "$ac_cv_path_SED" >&6; } | |
11133 | SED="$ac_cv_path_SED" | |
11134 | rm -f conftest.sed | |
e8b05380 | 11135 | |
da0f6381 PB |
11136 | test -z "$SED" && SED=sed |
11137 | Xsed="$SED -e 1s/^X//" | |
e8b05380 | 11138 | |
e8b05380 PB |
11139 | |
11140 | ||
ad9c4d9f | 11141 | |
da0f6381 PB |
11142 | |
11143 | ||
11144 | ||
11145 | ||
11146 | ||
11147 | ||
11148 | ||
5213506e RW |
11149 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 |
11150 | $as_echo_n "checking for fgrep... " >&6; } | |
11151 | if test "${ac_cv_path_FGREP+set}" = set; then : | |
11152 | $as_echo_n "(cached) " >&6 | |
11153 | else | |
11154 | if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 | |
11155 | then ac_cv_path_FGREP="$GREP -F" | |
11156 | else | |
11157 | if test -z "$FGREP"; then | |
11158 | ac_path_FGREP_found=false | |
11159 | # Loop through the user's path and test for each of PROGNAME-LIST | |
11160 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11161 | for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin | |
11162 | do | |
11163 | IFS=$as_save_IFS | |
11164 | test -z "$as_dir" && as_dir=. | |
11165 | for ac_prog in fgrep; do | |
11166 | for ac_exec_ext in '' $ac_executable_extensions; do | |
11167 | ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" | |
11168 | { test -f "$ac_path_FGREP" && $as_test_x "$ac_path_FGREP"; } || continue | |
11169 | # Check for GNU ac_path_FGREP and select it if it is found. | |
11170 | # Check for GNU $ac_path_FGREP | |
11171 | case `"$ac_path_FGREP" --version 2>&1` in | |
11172 | *GNU*) | |
11173 | ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; | |
11174 | *) | |
11175 | ac_count=0 | |
11176 | $as_echo_n 0123456789 >"conftest.in" | |
11177 | while : | |
11178 | do | |
11179 | cat "conftest.in" "conftest.in" >"conftest.tmp" | |
11180 | mv "conftest.tmp" "conftest.in" | |
11181 | cp "conftest.in" "conftest.nl" | |
11182 | $as_echo 'FGREP' >> "conftest.nl" | |
11183 | "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break | |
11184 | diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break | |
11185 | as_fn_arith $ac_count + 1 && ac_count=$as_val | |
11186 | if test $ac_count -gt ${ac_path_FGREP_max-0}; then | |
11187 | # Best one so far, save it but keep looking for a better one | |
11188 | ac_cv_path_FGREP="$ac_path_FGREP" | |
11189 | ac_path_FGREP_max=$ac_count | |
11190 | fi | |
11191 | # 10*(2^10) chars as input seems more than enough | |
11192 | test $ac_count -gt 10 && break | |
11193 | done | |
11194 | rm -f conftest.in conftest.tmp conftest.nl conftest.out;; | |
11195 | esac | |
11196 | ||
11197 | $ac_path_FGREP_found && break 3 | |
11198 | done | |
11199 | done | |
11200 | done | |
11201 | IFS=$as_save_IFS | |
11202 | if test -z "$ac_cv_path_FGREP"; then | |
11203 | as_fn_error "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 | |
11204 | fi | |
e8b05380 | 11205 | else |
5213506e RW |
11206 | ac_cv_path_FGREP=$FGREP |
11207 | fi | |
11208 | ||
11209 | fi | |
981d4858 | 11210 | fi |
5213506e RW |
11211 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 |
11212 | $as_echo "$ac_cv_path_FGREP" >&6; } | |
11213 | FGREP="$ac_cv_path_FGREP" | |
9e423e6d | 11214 | |
9f18db39 | 11215 | |
da0f6381 | 11216 | test -z "$GREP" && GREP=grep |
9f18db39 | 11217 | |
da0f6381 PB |
11218 | |
11219 | ||
11220 | ||
11221 | ||
11222 | ||
11223 | ||
11224 | ||
11225 | ||
11226 | ||
11227 | ||
11228 | ||
11229 | ||
11230 | ||
11231 | ||
11232 | ||
11233 | ||
11234 | ||
11235 | ||
5213506e RW |
11236 | # Check whether --with-gnu-ld was given. |
11237 | if test "${with_gnu_ld+set}" = set; then : | |
11238 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes | |
da0f6381 PB |
11239 | else |
11240 | with_gnu_ld=no | |
5213506e RW |
11241 | fi |
11242 | ||
da0f6381 PB |
11243 | ac_prog=ld |
11244 | if test "$GCC" = yes; then | |
11245 | # Check if gcc -print-prog-name=ld gives a path. | |
5213506e RW |
11246 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 |
11247 | $as_echo_n "checking for ld used by $CC... " >&6; } | |
da0f6381 PB |
11248 | case $host in |
11249 | *-*-mingw*) | |
11250 | # gcc leaves a trailing carriage return which upsets mingw | |
11251 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
11252 | *) | |
11253 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
11254 | esac | |
11255 | case $ac_prog in | |
11256 | # Accept absolute paths. | |
11257 | [\\/]* | ?:[\\/]*) | |
11258 | re_direlt='/[^/][^/]*/\.\./' | |
11259 | # Canonicalize the pathname of ld | |
11260 | ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` | |
11261 | while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do | |
11262 | ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` | |
11263 | done | |
11264 | test -z "$LD" && LD="$ac_prog" | |
11265 | ;; | |
11266 | "") | |
11267 | # If it fails, then pretend we aren't using GCC. | |
11268 | ac_prog=ld | |
11269 | ;; | |
11270 | *) | |
11271 | # If it is relative, then search for the first ld in PATH. | |
11272 | with_gnu_ld=unknown | |
11273 | ;; | |
11274 | esac | |
11275 | elif test "$with_gnu_ld" = yes; then | |
5213506e RW |
11276 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
11277 | $as_echo_n "checking for GNU ld... " >&6; } | |
da0f6381 | 11278 | else |
5213506e RW |
11279 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
11280 | $as_echo_n "checking for non-GNU ld... " >&6; } | |
da0f6381 | 11281 | fi |
5213506e RW |
11282 | if test "${lt_cv_path_LD+set}" = set; then : |
11283 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11284 | else |
11285 | if test -z "$LD"; then | |
11286 | lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR | |
11287 | for ac_dir in $PATH; do | |
11288 | IFS="$lt_save_ifs" | |
11289 | test -z "$ac_dir" && ac_dir=. | |
11290 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
11291 | lt_cv_path_LD="$ac_dir/$ac_prog" | |
11292 | # Check to see if the program is GNU ld. I'd rather use --version, | |
11293 | # but apparently some variants of GNU ld only accept -v. | |
11294 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
11295 | case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in | |
11296 | *GNU* | *'with BFD'*) | |
11297 | test "$with_gnu_ld" != no && break | |
11298 | ;; | |
11299 | *) | |
11300 | test "$with_gnu_ld" != yes && break | |
11301 | ;; | |
11302 | esac | |
11303 | fi | |
11304 | done | |
11305 | IFS="$lt_save_ifs" | |
11306 | else | |
11307 | lt_cv_path_LD="$LD" # Let the user override the test with a path. | |
11308 | fi | |
11309 | fi | |
11310 | ||
11311 | LD="$lt_cv_path_LD" | |
11312 | if test -n "$LD"; then | |
5213506e RW |
11313 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
11314 | $as_echo "$LD" >&6; } | |
da0f6381 | 11315 | else |
5213506e RW |
11316 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
11317 | $as_echo "no" >&6; } | |
da0f6381 | 11318 | fi |
5213506e RW |
11319 | test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 |
11320 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
11321 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } | |
11322 | if test "${lt_cv_prog_gnu_ld+set}" = set; then : | |
11323 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11324 | else |
11325 | # I'd rather use --version here, but apparently some GNU lds only accept -v. | |
11326 | case `$LD -v 2>&1 </dev/null` in | |
11327 | *GNU* | *'with BFD'*) | |
11328 | lt_cv_prog_gnu_ld=yes | |
11329 | ;; | |
11330 | *) | |
11331 | lt_cv_prog_gnu_ld=no | |
11332 | ;; | |
11333 | esac | |
11334 | fi | |
5213506e RW |
11335 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 |
11336 | $as_echo "$lt_cv_prog_gnu_ld" >&6; } | |
da0f6381 PB |
11337 | with_gnu_ld=$lt_cv_prog_gnu_ld |
11338 | ||
11339 | ||
11340 | ||
11341 | ||
11342 | ||
11343 | ||
11344 | ||
11345 | ||
11346 | ||
5213506e RW |
11347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BSD- or MS-compatible name lister (nm)" >&5 |
11348 | $as_echo_n "checking for BSD- or MS-compatible name lister (nm)... " >&6; } | |
11349 | if test "${lt_cv_path_NM+set}" = set; then : | |
11350 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11351 | else |
11352 | if test -n "$NM"; then | |
11353 | # Let the user override the test. | |
11354 | lt_cv_path_NM="$NM" | |
11355 | else | |
11356 | lt_nm_to_check="${ac_tool_prefix}nm" | |
11357 | if test -n "$ac_tool_prefix" && test "$build" = "$host"; then | |
11358 | lt_nm_to_check="$lt_nm_to_check nm" | |
11359 | fi | |
11360 | for lt_tmp_nm in $lt_nm_to_check; do | |
11361 | lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR | |
11362 | for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do | |
11363 | IFS="$lt_save_ifs" | |
11364 | test -z "$ac_dir" && ac_dir=. | |
11365 | tmp_nm="$ac_dir/$lt_tmp_nm" | |
11366 | if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then | |
11367 | # Check to see if the nm accepts a BSD-compat flag. | |
11368 | # Adding the `sed 1q' prevents false positives on HP-UX, which says: | |
11369 | # nm: unknown option "B" ignored | |
11370 | # Tru64's nm complains that /dev/null is an invalid object file | |
11371 | case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in | |
11372 | */dev/null* | *'Invalid file or object type'*) | |
11373 | lt_cv_path_NM="$tmp_nm -B" | |
11374 | break | |
11375 | ;; | |
11376 | *) | |
11377 | case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in | |
11378 | */dev/null*) | |
11379 | lt_cv_path_NM="$tmp_nm -p" | |
11380 | break | |
11381 | ;; | |
11382 | *) | |
11383 | lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but | |
11384 | continue # so that we can try to find one that supports BSD flags | |
11385 | ;; | |
11386 | esac | |
11387 | ;; | |
11388 | esac | |
11389 | fi | |
11390 | done | |
11391 | IFS="$lt_save_ifs" | |
11392 | done | |
11393 | : ${lt_cv_path_NM=no} | |
11394 | fi | |
11395 | fi | |
5213506e RW |
11396 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_path_NM" >&5 |
11397 | $as_echo "$lt_cv_path_NM" >&6; } | |
da0f6381 PB |
11398 | if test "$lt_cv_path_NM" != "no"; then |
11399 | NM="$lt_cv_path_NM" | |
11400 | else | |
11401 | # Didn't find any BSD compatible name lister, look for dumpbin. | |
43e02a8a RW |
11402 | if test -n "$DUMPBIN"; then : |
11403 | # Let the user override the test. | |
11404 | else | |
11405 | if test -n "$ac_tool_prefix"; then | |
11406 | for ac_prog in dumpbin "link -dump" | |
da0f6381 PB |
11407 | do |
11408 | # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. | |
11409 | set dummy $ac_tool_prefix$ac_prog; ac_word=$2 | |
5213506e RW |
11410 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
11411 | $as_echo_n "checking for $ac_word... " >&6; } | |
11412 | if test "${ac_cv_prog_DUMPBIN+set}" = set; then : | |
11413 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11414 | else |
11415 | if test -n "$DUMPBIN"; then | |
11416 | ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. | |
11417 | else | |
11418 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11419 | for as_dir in $PATH | |
11420 | do | |
11421 | IFS=$as_save_IFS | |
11422 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
11423 | for ac_exec_ext in '' $ac_executable_extensions; do |
11424 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 11425 | ac_cv_prog_DUMPBIN="$ac_tool_prefix$ac_prog" |
5213506e | 11426 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
11427 | break 2 |
11428 | fi | |
11429 | done | |
5213506e RW |
11430 | done |
11431 | IFS=$as_save_IFS | |
da0f6381 PB |
11432 | |
11433 | fi | |
11434 | fi | |
11435 | DUMPBIN=$ac_cv_prog_DUMPBIN | |
11436 | if test -n "$DUMPBIN"; then | |
5213506e RW |
11437 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 |
11438 | $as_echo "$DUMPBIN" >&6; } | |
da0f6381 | 11439 | else |
5213506e RW |
11440 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
11441 | $as_echo "no" >&6; } | |
da0f6381 PB |
11442 | fi |
11443 | ||
5213506e | 11444 | |
da0f6381 PB |
11445 | test -n "$DUMPBIN" && break |
11446 | done | |
11447 | fi | |
11448 | if test -z "$DUMPBIN"; then | |
11449 | ac_ct_DUMPBIN=$DUMPBIN | |
43e02a8a | 11450 | for ac_prog in dumpbin "link -dump" |
da0f6381 PB |
11451 | do |
11452 | # Extract the first word of "$ac_prog", so it can be a program name with args. | |
11453 | set dummy $ac_prog; ac_word=$2 | |
5213506e RW |
11454 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
11455 | $as_echo_n "checking for $ac_word... " >&6; } | |
11456 | if test "${ac_cv_prog_ac_ct_DUMPBIN+set}" = set; then : | |
11457 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11458 | else |
11459 | if test -n "$ac_ct_DUMPBIN"; then | |
11460 | ac_cv_prog_ac_ct_DUMPBIN="$ac_ct_DUMPBIN" # Let the user override the test. | |
11461 | else | |
11462 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11463 | for as_dir in $PATH | |
11464 | do | |
11465 | IFS=$as_save_IFS | |
11466 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
11467 | for ac_exec_ext in '' $ac_executable_extensions; do |
11468 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 11469 | ac_cv_prog_ac_ct_DUMPBIN="$ac_prog" |
5213506e | 11470 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
11471 | break 2 |
11472 | fi | |
11473 | done | |
5213506e RW |
11474 | done |
11475 | IFS=$as_save_IFS | |
da0f6381 PB |
11476 | |
11477 | fi | |
11478 | fi | |
11479 | ac_ct_DUMPBIN=$ac_cv_prog_ac_ct_DUMPBIN | |
11480 | if test -n "$ac_ct_DUMPBIN"; then | |
5213506e RW |
11481 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DUMPBIN" >&5 |
11482 | $as_echo "$ac_ct_DUMPBIN" >&6; } | |
da0f6381 | 11483 | else |
5213506e RW |
11484 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
11485 | $as_echo "no" >&6; } | |
da0f6381 PB |
11486 | fi |
11487 | ||
5213506e | 11488 | |
da0f6381 PB |
11489 | test -n "$ac_ct_DUMPBIN" && break |
11490 | done | |
da0f6381 | 11491 | |
5213506e RW |
11492 | if test "x$ac_ct_DUMPBIN" = x; then |
11493 | DUMPBIN=":" | |
11494 | else | |
11495 | case $cross_compiling:$ac_tool_warned in | |
11496 | yes:) | |
11497 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
11498 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
11499 | ac_tool_warned=yes ;; | |
11500 | esac | |
11501 | DUMPBIN=$ac_ct_DUMPBIN | |
11502 | fi | |
da0f6381 PB |
11503 | fi |
11504 | ||
43e02a8a RW |
11505 | case `$DUMPBIN -symbols /dev/null 2>&1 | sed '1q'` in |
11506 | *COFF*) | |
11507 | DUMPBIN="$DUMPBIN -symbols" | |
11508 | ;; | |
11509 | *) | |
11510 | DUMPBIN=: | |
11511 | ;; | |
11512 | esac | |
11513 | fi | |
da0f6381 PB |
11514 | |
11515 | if test "$DUMPBIN" != ":"; then | |
11516 | NM="$DUMPBIN" | |
11517 | fi | |
11518 | fi | |
11519 | test -z "$NM" && NM=nm | |
11520 | ||
11521 | ||
11522 | ||
11523 | ||
11524 | ||
11525 | ||
5213506e RW |
11526 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking the name lister ($NM) interface" >&5 |
11527 | $as_echo_n "checking the name lister ($NM) interface... " >&6; } | |
11528 | if test "${lt_cv_nm_interface+set}" = set; then : | |
11529 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11530 | else |
11531 | lt_cv_nm_interface="BSD nm" | |
11532 | echo "int some_variable = 0;" > conftest.$ac_ext | |
43e02a8a | 11533 | (eval echo "\"\$as_me:$LINENO: $ac_compile\"" >&5) |
da0f6381 PB |
11534 | (eval "$ac_compile" 2>conftest.err) |
11535 | cat conftest.err >&5 | |
43e02a8a | 11536 | (eval echo "\"\$as_me:$LINENO: $NM \\\"conftest.$ac_objext\\\"\"" >&5) |
da0f6381 PB |
11537 | (eval "$NM \"conftest.$ac_objext\"" 2>conftest.err > conftest.out) |
11538 | cat conftest.err >&5 | |
43e02a8a | 11539 | (eval echo "\"\$as_me:$LINENO: output\"" >&5) |
da0f6381 PB |
11540 | cat conftest.out >&5 |
11541 | if $GREP 'External.*some_variable' conftest.out > /dev/null; then | |
11542 | lt_cv_nm_interface="MS dumpbin" | |
11543 | fi | |
11544 | rm -f conftest* | |
11545 | fi | |
5213506e RW |
11546 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_nm_interface" >&5 |
11547 | $as_echo "$lt_cv_nm_interface" >&6; } | |
da0f6381 | 11548 | |
5213506e RW |
11549 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether ln -s works" >&5 |
11550 | $as_echo_n "checking whether ln -s works... " >&6; } | |
da0f6381 PB |
11551 | LN_S=$as_ln_s |
11552 | if test "$LN_S" = "ln -s"; then | |
5213506e RW |
11553 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
11554 | $as_echo "yes" >&6; } | |
da0f6381 | 11555 | else |
5213506e RW |
11556 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, using $LN_S" >&5 |
11557 | $as_echo "no, using $LN_S" >&6; } | |
da0f6381 PB |
11558 | fi |
11559 | ||
11560 | # find the maximum length of command line arguments | |
5213506e RW |
11561 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking the maximum length of command line arguments" >&5 |
11562 | $as_echo_n "checking the maximum length of command line arguments... " >&6; } | |
11563 | if test "${lt_cv_sys_max_cmd_len+set}" = set; then : | |
11564 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11565 | else |
11566 | i=0 | |
11567 | teststring="ABCD" | |
11568 | ||
11569 | case $build_os in | |
11570 | msdosdjgpp*) | |
11571 | # On DJGPP, this test can blow up pretty badly due to problems in libc | |
11572 | # (any single argument exceeding 2000 bytes causes a buffer overrun | |
11573 | # during glob expansion). Even if it were fixed, the result of this | |
11574 | # check would be larger than it should be. | |
11575 | lt_cv_sys_max_cmd_len=12288; # 12K is about right | |
11576 | ;; | |
11577 | ||
11578 | gnu*) | |
11579 | # Under GNU Hurd, this test is not required because there is | |
11580 | # no limit to the length of command line arguments. | |
11581 | # Libtool will interpret -1 as no limit whatsoever | |
11582 | lt_cv_sys_max_cmd_len=-1; | |
11583 | ;; | |
11584 | ||
5d47bb02 | 11585 | cygwin* | mingw* | cegcc*) |
da0f6381 PB |
11586 | # On Win9x/ME, this test blows up -- it succeeds, but takes |
11587 | # about 5 minutes as the teststring grows exponentially. | |
11588 | # Worse, since 9x/ME are not pre-emptively multitasking, | |
11589 | # you end up with a "frozen" computer, even though with patience | |
11590 | # the test eventually succeeds (with a max line length of 256k). | |
11591 | # Instead, let's just punt: use the minimum linelength reported by | |
11592 | # all of the supported platforms: 8192 (on NT/2K/XP). | |
11593 | lt_cv_sys_max_cmd_len=8192; | |
11594 | ;; | |
11595 | ||
43e02a8a RW |
11596 | mint*) |
11597 | # On MiNT this can take a long time and run out of memory. | |
11598 | lt_cv_sys_max_cmd_len=8192; | |
11599 | ;; | |
11600 | ||
da0f6381 PB |
11601 | amigaos*) |
11602 | # On AmigaOS with pdksh, this test takes hours, literally. | |
11603 | # So we just punt and use a minimum line length of 8192. | |
11604 | lt_cv_sys_max_cmd_len=8192; | |
11605 | ;; | |
11606 | ||
11607 | netbsd* | freebsd* | openbsd* | darwin* | dragonfly*) | |
11608 | # This has been around since 386BSD, at least. Likely further. | |
11609 | if test -x /sbin/sysctl; then | |
11610 | lt_cv_sys_max_cmd_len=`/sbin/sysctl -n kern.argmax` | |
11611 | elif test -x /usr/sbin/sysctl; then | |
11612 | lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax` | |
11613 | else | |
11614 | lt_cv_sys_max_cmd_len=65536 # usable default for all BSDs | |
11615 | fi | |
11616 | # And add a safety zone | |
11617 | lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` | |
11618 | lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` | |
11619 | ;; | |
11620 | ||
11621 | interix*) | |
11622 | # We know the value 262144 and hardcode it with a safety zone (like BSD) | |
11623 | lt_cv_sys_max_cmd_len=196608 | |
11624 | ;; | |
11625 | ||
11626 | osf*) | |
11627 | # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure | |
11628 | # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not | |
11629 | # nice to cause kernel panics so lets avoid the loop below. | |
11630 | # First set a reasonable default. | |
11631 | lt_cv_sys_max_cmd_len=16384 | |
11632 | # | |
11633 | if test -x /sbin/sysconfig; then | |
11634 | case `/sbin/sysconfig -q proc exec_disable_arg_limit` in | |
11635 | *1*) lt_cv_sys_max_cmd_len=-1 ;; | |
11636 | esac | |
11637 | fi | |
11638 | ;; | |
11639 | sco3.2v5*) | |
11640 | lt_cv_sys_max_cmd_len=102400 | |
11641 | ;; | |
11642 | sysv5* | sco5v6* | sysv4.2uw2*) | |
11643 | kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null` | |
11644 | if test -n "$kargmax"; then | |
11645 | lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ ]//'` | |
11646 | else | |
11647 | lt_cv_sys_max_cmd_len=32768 | |
11648 | fi | |
11649 | ;; | |
11650 | *) | |
5d47bb02 PG |
11651 | lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null` |
11652 | if test -n "$lt_cv_sys_max_cmd_len"; then | |
da0f6381 PB |
11653 | lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4` |
11654 | lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3` | |
11655 | else | |
11656 | # Make teststring a little bigger before we do anything with it. | |
11657 | # a 1K string should be a reasonable start. | |
11658 | for i in 1 2 3 4 5 6 7 8 ; do | |
11659 | teststring=$teststring$teststring | |
11660 | done | |
11661 | SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}} | |
11662 | # If test is not a shell built-in, we'll probably end up computing a | |
11663 | # maximum length that is only half of the actual maximum length, but | |
11664 | # we can't tell. | |
43e02a8a RW |
11665 | while { test "X"`func_fallback_echo "$teststring$teststring" 2>/dev/null` \ |
11666 | = "X$teststring$teststring"; } >/dev/null 2>&1 && | |
da0f6381 PB |
11667 | test $i != 17 # 1/2 MB should be enough |
11668 | do | |
11669 | i=`expr $i + 1` | |
11670 | teststring=$teststring$teststring | |
11671 | done | |
11672 | # Only check the string length outside the loop. | |
11673 | lt_cv_sys_max_cmd_len=`expr "X$teststring" : ".*" 2>&1` | |
11674 | teststring= | |
11675 | # Add a significant safety factor because C++ compilers can tack on | |
11676 | # massive amounts of additional arguments before passing them to the | |
11677 | # linker. It appears as though 1/2 is a usable value. | |
11678 | lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2` | |
11679 | fi | |
11680 | ;; | |
11681 | esac | |
11682 | ||
11683 | fi | |
11684 | ||
11685 | if test -n $lt_cv_sys_max_cmd_len ; then | |
5213506e RW |
11686 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_sys_max_cmd_len" >&5 |
11687 | $as_echo "$lt_cv_sys_max_cmd_len" >&6; } | |
da0f6381 | 11688 | else |
5213506e RW |
11689 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: none" >&5 |
11690 | $as_echo "none" >&6; } | |
da0f6381 PB |
11691 | fi |
11692 | max_cmd_len=$lt_cv_sys_max_cmd_len | |
11693 | ||
11694 | ||
11695 | ||
11696 | ||
11697 | ||
11698 | ||
da0f6381 PB |
11699 | : ${CP="cp -f"} |
11700 | : ${MV="mv -f"} | |
11701 | : ${RM="rm -f"} | |
11702 | ||
5213506e RW |
11703 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands some XSI constructs" >&5 |
11704 | $as_echo_n "checking whether the shell understands some XSI constructs... " >&6; } | |
da0f6381 PB |
11705 | # Try some XSI features |
11706 | xsi_shell=no | |
11707 | ( _lt_dummy="a/b/c" | |
11708 | test "${_lt_dummy##*/},${_lt_dummy%/*},"${_lt_dummy%"$_lt_dummy"}, \ | |
5d47bb02 PG |
11709 | = c,a/b,, \ |
11710 | && eval 'test $(( 1 + 1 )) -eq 2 \ | |
11711 | && test "${#_lt_dummy}" -eq 5' ) >/dev/null 2>&1 \ | |
da0f6381 | 11712 | && xsi_shell=yes |
5213506e RW |
11713 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xsi_shell" >&5 |
11714 | $as_echo "$xsi_shell" >&6; } | |
da0f6381 PB |
11715 | |
11716 | ||
5213506e RW |
11717 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the shell understands \"+=\"" >&5 |
11718 | $as_echo_n "checking whether the shell understands \"+=\"... " >&6; } | |
da0f6381 PB |
11719 | lt_shell_append=no |
11720 | ( foo=bar; set foo baz; eval "$1+=\$2" && test "$foo" = barbaz ) \ | |
11721 | >/dev/null 2>&1 \ | |
11722 | && lt_shell_append=yes | |
5213506e RW |
11723 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_shell_append" >&5 |
11724 | $as_echo "$lt_shell_append" >&6; } | |
da0f6381 PB |
11725 | |
11726 | ||
11727 | if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then | |
11728 | lt_unset=unset | |
11729 | else | |
11730 | lt_unset=false | |
11731 | fi | |
11732 | ||
11733 | ||
11734 | ||
11735 | ||
11736 | ||
11737 | # test EBCDIC or ASCII | |
11738 | case `echo X|tr X '\101'` in | |
11739 | A) # ASCII based system | |
11740 | # \n is not interpreted correctly by Solaris 8 /usr/ucb/tr | |
11741 | lt_SP2NL='tr \040 \012' | |
11742 | lt_NL2SP='tr \015\012 \040\040' | |
11743 | ;; | |
11744 | *) # EBCDIC based system | |
11745 | lt_SP2NL='tr \100 \n' | |
11746 | lt_NL2SP='tr \r\n \100\100' | |
11747 | ;; | |
11748 | esac | |
11749 | ||
11750 | ||
11751 | ||
11752 | ||
11753 | ||
11754 | ||
11755 | ||
11756 | ||
11757 | ||
5213506e RW |
11758 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $LD option to reload object files" >&5 |
11759 | $as_echo_n "checking for $LD option to reload object files... " >&6; } | |
11760 | if test "${lt_cv_ld_reload_flag+set}" = set; then : | |
11761 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11762 | else |
11763 | lt_cv_ld_reload_flag='-r' | |
11764 | fi | |
5213506e RW |
11765 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_reload_flag" >&5 |
11766 | $as_echo "$lt_cv_ld_reload_flag" >&6; } | |
da0f6381 PB |
11767 | reload_flag=$lt_cv_ld_reload_flag |
11768 | case $reload_flag in | |
11769 | "" | " "*) ;; | |
11770 | *) reload_flag=" $reload_flag" ;; | |
11771 | esac | |
11772 | reload_cmds='$LD$reload_flag -o $output$reload_objs' | |
11773 | case $host_os in | |
11774 | darwin*) | |
11775 | if test "$GCC" = yes; then | |
11776 | reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs' | |
11777 | else | |
11778 | reload_cmds='$LD$reload_flag -o $output$reload_objs' | |
11779 | fi | |
11780 | ;; | |
11781 | esac | |
11782 | ||
11783 | ||
11784 | ||
11785 | ||
11786 | ||
11787 | ||
11788 | ||
11789 | ||
11790 | ||
5d47bb02 PG |
11791 | if test -n "$ac_tool_prefix"; then |
11792 | # Extract the first word of "${ac_tool_prefix}objdump", so it can be a program name with args. | |
11793 | set dummy ${ac_tool_prefix}objdump; ac_word=$2 | |
5213506e RW |
11794 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
11795 | $as_echo_n "checking for $ac_word... " >&6; } | |
11796 | if test "${ac_cv_prog_OBJDUMP+set}" = set; then : | |
11797 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
11798 | else |
11799 | if test -n "$OBJDUMP"; then | |
11800 | ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. | |
11801 | else | |
11802 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11803 | for as_dir in $PATH | |
11804 | do | |
11805 | IFS=$as_save_IFS | |
11806 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
11807 | for ac_exec_ext in '' $ac_executable_extensions; do |
11808 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 11809 | ac_cv_prog_OBJDUMP="${ac_tool_prefix}objdump" |
5213506e | 11810 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
11811 | break 2 |
11812 | fi | |
11813 | done | |
5213506e RW |
11814 | done |
11815 | IFS=$as_save_IFS | |
5d47bb02 PG |
11816 | |
11817 | fi | |
11818 | fi | |
11819 | OBJDUMP=$ac_cv_prog_OBJDUMP | |
11820 | if test -n "$OBJDUMP"; then | |
5213506e RW |
11821 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 |
11822 | $as_echo "$OBJDUMP" >&6; } | |
5d47bb02 | 11823 | else |
5213506e RW |
11824 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
11825 | $as_echo "no" >&6; } | |
5d47bb02 PG |
11826 | fi |
11827 | ||
5213506e | 11828 | |
5d47bb02 PG |
11829 | fi |
11830 | if test -z "$ac_cv_prog_OBJDUMP"; then | |
11831 | ac_ct_OBJDUMP=$OBJDUMP | |
11832 | # Extract the first word of "objdump", so it can be a program name with args. | |
11833 | set dummy objdump; ac_word=$2 | |
5213506e RW |
11834 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
11835 | $as_echo_n "checking for $ac_word... " >&6; } | |
11836 | if test "${ac_cv_prog_ac_ct_OBJDUMP+set}" = set; then : | |
11837 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
11838 | else |
11839 | if test -n "$ac_ct_OBJDUMP"; then | |
11840 | ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. | |
11841 | else | |
11842 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
11843 | for as_dir in $PATH | |
11844 | do | |
11845 | IFS=$as_save_IFS | |
11846 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
11847 | for ac_exec_ext in '' $ac_executable_extensions; do |
11848 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 11849 | ac_cv_prog_ac_ct_OBJDUMP="objdump" |
5213506e | 11850 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
11851 | break 2 |
11852 | fi | |
11853 | done | |
5213506e RW |
11854 | done |
11855 | IFS=$as_save_IFS | |
5d47bb02 | 11856 | |
5d47bb02 PG |
11857 | fi |
11858 | fi | |
11859 | ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP | |
11860 | if test -n "$ac_ct_OBJDUMP"; then | |
5213506e RW |
11861 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 |
11862 | $as_echo "$ac_ct_OBJDUMP" >&6; } | |
5d47bb02 | 11863 | else |
5213506e RW |
11864 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
11865 | $as_echo "no" >&6; } | |
5d47bb02 PG |
11866 | fi |
11867 | ||
5213506e RW |
11868 | if test "x$ac_ct_OBJDUMP" = x; then |
11869 | OBJDUMP="false" | |
11870 | else | |
11871 | case $cross_compiling:$ac_tool_warned in | |
11872 | yes:) | |
11873 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
11874 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
11875 | ac_tool_warned=yes ;; | |
11876 | esac | |
11877 | OBJDUMP=$ac_ct_OBJDUMP | |
11878 | fi | |
5d47bb02 PG |
11879 | else |
11880 | OBJDUMP="$ac_cv_prog_OBJDUMP" | |
11881 | fi | |
11882 | ||
11883 | test -z "$OBJDUMP" && OBJDUMP=objdump | |
11884 | ||
11885 | ||
11886 | ||
11887 | ||
11888 | ||
11889 | ||
11890 | ||
11891 | ||
da0f6381 | 11892 | |
5213506e RW |
11893 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to recognize dependent libraries" >&5 |
11894 | $as_echo_n "checking how to recognize dependent libraries... " >&6; } | |
11895 | if test "${lt_cv_deplibs_check_method+set}" = set; then : | |
11896 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
11897 | else |
11898 | lt_cv_file_magic_cmd='$MAGIC_CMD' | |
11899 | lt_cv_file_magic_test_file= | |
11900 | lt_cv_deplibs_check_method='unknown' | |
11901 | # Need to set the preceding variable on all platforms that support | |
11902 | # interlibrary dependencies. | |
11903 | # 'none' -- dependencies not supported. | |
11904 | # `unknown' -- same as none, but documents that we really don't know. | |
11905 | # 'pass_all' -- all dependencies passed with no checks. | |
11906 | # 'test_compile' -- check by making test program. | |
11907 | # 'file_magic [[regex]]' -- check by looking for files in library path | |
11908 | # which responds to the $file_magic_cmd with a given extended regex. | |
11909 | # If you have `file' or equivalent on your system and you're not sure | |
11910 | # whether `pass_all' will *always* work, you probably want this one. | |
11911 | ||
11912 | case $host_os in | |
11913 | aix[4-9]*) | |
11914 | lt_cv_deplibs_check_method=pass_all | |
11915 | ;; | |
11916 | ||
11917 | beos*) | |
11918 | lt_cv_deplibs_check_method=pass_all | |
11919 | ;; | |
11920 | ||
11921 | bsdi[45]*) | |
11922 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib)' | |
11923 | lt_cv_file_magic_cmd='/usr/bin/file -L' | |
11924 | lt_cv_file_magic_test_file=/shlib/libc.so | |
11925 | ;; | |
11926 | ||
11927 | cygwin*) | |
11928 | # func_win32_libid is a shell function defined in ltmain.sh | |
11929 | lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' | |
11930 | lt_cv_file_magic_cmd='func_win32_libid' | |
11931 | ;; | |
11932 | ||
11933 | mingw* | pw32*) | |
11934 | # Base MSYS/MinGW do not provide the 'file' command needed by | |
11935 | # func_win32_libid shell function, so use a weaker test based on 'objdump', | |
11936 | # unless we find 'file', for example because we are cross-compiling. | |
43e02a8a RW |
11937 | # func_win32_libid assumes BSD nm, so disallow it if using MS dumpbin. |
11938 | if ( test "$lt_cv_nm_interface" = "BSD nm" && file / ) >/dev/null 2>&1; then | |
da0f6381 PB |
11939 | lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL' |
11940 | lt_cv_file_magic_cmd='func_win32_libid' | |
11941 | else | |
11942 | lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?' | |
11943 | lt_cv_file_magic_cmd='$OBJDUMP -f' | |
11944 | fi | |
11945 | ;; | |
11946 | ||
43e02a8a | 11947 | cegcc*) |
5d47bb02 PG |
11948 | # use the weaker test based on 'objdump'. See mingw*. |
11949 | lt_cv_deplibs_check_method='file_magic file format pe-arm-.*little(.*architecture: arm)?' | |
11950 | lt_cv_file_magic_cmd='$OBJDUMP -f' | |
11951 | ;; | |
11952 | ||
da0f6381 PB |
11953 | darwin* | rhapsody*) |
11954 | lt_cv_deplibs_check_method=pass_all | |
11955 | ;; | |
11956 | ||
11957 | freebsd* | dragonfly*) | |
11958 | if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then | |
11959 | case $host_cpu in | |
11960 | i*86 ) | |
11961 | # Not sure whether the presence of OpenBSD here was a mistake. | |
11962 | # Let's accept both of them until this is cleared up. | |
11963 | lt_cv_deplibs_check_method='file_magic (FreeBSD|OpenBSD|DragonFly)/i[3-9]86 (compact )?demand paged shared library' | |
11964 | lt_cv_file_magic_cmd=/usr/bin/file | |
11965 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so.*` | |
11966 | ;; | |
11967 | esac | |
11968 | else | |
11969 | lt_cv_deplibs_check_method=pass_all | |
11970 | fi | |
11971 | ;; | |
11972 | ||
11973 | gnu*) | |
11974 | lt_cv_deplibs_check_method=pass_all | |
11975 | ;; | |
11976 | ||
43e02a8a RW |
11977 | haiku*) |
11978 | lt_cv_deplibs_check_method=pass_all | |
11979 | ;; | |
11980 | ||
da0f6381 PB |
11981 | hpux10.20* | hpux11*) |
11982 | lt_cv_file_magic_cmd=/usr/bin/file | |
11983 | case $host_cpu in | |
11984 | ia64*) | |
11985 | lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF-[0-9][0-9]) shared object file - IA64' | |
11986 | lt_cv_file_magic_test_file=/usr/lib/hpux32/libc.so | |
11987 | ;; | |
11988 | hppa*64*) | |
43e02a8a | 11989 | lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|ELF[ -][0-9][0-9])(-bit)?( [LM]SB)? shared object( file)?[, -]* PA-RISC [0-9]\.[0-9]' |
da0f6381 PB |
11990 | lt_cv_file_magic_test_file=/usr/lib/pa20_64/libc.sl |
11991 | ;; | |
11992 | *) | |
43e02a8a | 11993 | lt_cv_deplibs_check_method='file_magic (s[0-9][0-9][0-9]|PA-RISC[0-9]\.[0-9]) shared library' |
da0f6381 PB |
11994 | lt_cv_file_magic_test_file=/usr/lib/libc.sl |
11995 | ;; | |
11996 | esac | |
11997 | ;; | |
11998 | ||
11999 | interix[3-9]*) | |
12000 | # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here | |
12001 | lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$' | |
12002 | ;; | |
12003 | ||
12004 | irix5* | irix6* | nonstopux*) | |
12005 | case $LD in | |
12006 | *-32|*"-32 ") libmagic=32-bit;; | |
12007 | *-n32|*"-n32 ") libmagic=N32;; | |
12008 | *-64|*"-64 ") libmagic=64-bit;; | |
12009 | *) libmagic=never-match;; | |
12010 | esac | |
12011 | lt_cv_deplibs_check_method=pass_all | |
12012 | ;; | |
12013 | ||
12014 | # This must be Linux ELF. | |
7a9d3fe8 | 12015 | linux* | k*bsd*-gnu | kopensolaris*-gnu) |
da0f6381 PB |
12016 | lt_cv_deplibs_check_method=pass_all |
12017 | ;; | |
12018 | ||
12019 | netbsd*) | |
12020 | if echo __ELF__ | $CC -E - | $GREP __ELF__ > /dev/null; then | |
12021 | lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' | |
12022 | else | |
12023 | lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|_pic\.a)$' | |
12024 | fi | |
12025 | ;; | |
12026 | ||
12027 | newos6*) | |
12028 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (executable|dynamic lib)' | |
12029 | lt_cv_file_magic_cmd=/usr/bin/file | |
12030 | lt_cv_file_magic_test_file=/usr/lib/libnls.so | |
12031 | ;; | |
12032 | ||
12033 | *nto* | *qnx*) | |
12034 | lt_cv_deplibs_check_method=pass_all | |
12035 | ;; | |
12036 | ||
12037 | openbsd*) | |
12038 | if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then | |
12039 | lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|\.so|_pic\.a)$' | |
12040 | else | |
12041 | lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so\.[0-9]+\.[0-9]+|_pic\.a)$' | |
12042 | fi | |
12043 | ;; | |
12044 | ||
12045 | osf3* | osf4* | osf5*) | |
12046 | lt_cv_deplibs_check_method=pass_all | |
12047 | ;; | |
12048 | ||
12049 | rdos*) | |
12050 | lt_cv_deplibs_check_method=pass_all | |
12051 | ;; | |
12052 | ||
12053 | solaris*) | |
12054 | lt_cv_deplibs_check_method=pass_all | |
12055 | ;; | |
12056 | ||
12057 | sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) | |
12058 | lt_cv_deplibs_check_method=pass_all | |
12059 | ;; | |
12060 | ||
12061 | sysv4 | sysv4.3*) | |
12062 | case $host_vendor in | |
12063 | motorola) | |
12064 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]' | |
12065 | lt_cv_file_magic_test_file=`echo /usr/lib/libc.so*` | |
12066 | ;; | |
12067 | ncr) | |
12068 | lt_cv_deplibs_check_method=pass_all | |
12069 | ;; | |
12070 | sequent) | |
12071 | lt_cv_file_magic_cmd='/bin/file' | |
12072 | lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [LM]SB (shared object|dynamic lib )' | |
12073 | ;; | |
12074 | sni) | |
12075 | lt_cv_file_magic_cmd='/bin/file' | |
12076 | lt_cv_deplibs_check_method="file_magic ELF [0-9][0-9]*-bit [LM]SB dynamic lib" | |
12077 | lt_cv_file_magic_test_file=/lib/libc.so | |
12078 | ;; | |
12079 | siemens) | |
12080 | lt_cv_deplibs_check_method=pass_all | |
12081 | ;; | |
12082 | pc) | |
12083 | lt_cv_deplibs_check_method=pass_all | |
12084 | ;; | |
12085 | esac | |
12086 | ;; | |
12087 | ||
12088 | tpf*) | |
12089 | lt_cv_deplibs_check_method=pass_all | |
12090 | ;; | |
12091 | esac | |
12092 | ||
12093 | fi | |
5213506e RW |
12094 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_deplibs_check_method" >&5 |
12095 | $as_echo "$lt_cv_deplibs_check_method" >&6; } | |
da0f6381 PB |
12096 | file_magic_cmd=$lt_cv_file_magic_cmd |
12097 | deplibs_check_method=$lt_cv_deplibs_check_method | |
12098 | test -z "$deplibs_check_method" && deplibs_check_method=unknown | |
12099 | ||
12100 | ||
12101 | ||
12102 | ||
12103 | ||
12104 | ||
12105 | ||
12106 | ||
12107 | ||
12108 | ||
12109 | ||
12110 | ||
12111 | if test -n "$ac_tool_prefix"; then | |
12112 | # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args. | |
12113 | set dummy ${ac_tool_prefix}ar; ac_word=$2 | |
5213506e RW |
12114 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12115 | $as_echo_n "checking for $ac_word... " >&6; } | |
12116 | if test "${ac_cv_prog_AR+set}" = set; then : | |
12117 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12118 | else |
12119 | if test -n "$AR"; then | |
12120 | ac_cv_prog_AR="$AR" # Let the user override the test. | |
12121 | else | |
12122 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12123 | for as_dir in $PATH | |
12124 | do | |
12125 | IFS=$as_save_IFS | |
12126 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12127 | for ac_exec_ext in '' $ac_executable_extensions; do |
12128 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12129 | ac_cv_prog_AR="${ac_tool_prefix}ar" |
5213506e | 12130 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12131 | break 2 |
12132 | fi | |
12133 | done | |
5213506e RW |
12134 | done |
12135 | IFS=$as_save_IFS | |
da0f6381 PB |
12136 | |
12137 | fi | |
12138 | fi | |
12139 | AR=$ac_cv_prog_AR | |
12140 | if test -n "$AR"; then | |
5213506e RW |
12141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 |
12142 | $as_echo "$AR" >&6; } | |
da0f6381 | 12143 | else |
5213506e RW |
12144 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12145 | $as_echo "no" >&6; } | |
da0f6381 PB |
12146 | fi |
12147 | ||
5213506e | 12148 | |
da0f6381 PB |
12149 | fi |
12150 | if test -z "$ac_cv_prog_AR"; then | |
12151 | ac_ct_AR=$AR | |
12152 | # Extract the first word of "ar", so it can be a program name with args. | |
12153 | set dummy ar; ac_word=$2 | |
5213506e RW |
12154 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12155 | $as_echo_n "checking for $ac_word... " >&6; } | |
12156 | if test "${ac_cv_prog_ac_ct_AR+set}" = set; then : | |
12157 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12158 | else |
12159 | if test -n "$ac_ct_AR"; then | |
12160 | ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. | |
12161 | else | |
12162 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12163 | for as_dir in $PATH | |
12164 | do | |
12165 | IFS=$as_save_IFS | |
12166 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12167 | for ac_exec_ext in '' $ac_executable_extensions; do |
12168 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12169 | ac_cv_prog_ac_ct_AR="ar" |
5213506e | 12170 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12171 | break 2 |
12172 | fi | |
12173 | done | |
5213506e RW |
12174 | done |
12175 | IFS=$as_save_IFS | |
da0f6381 | 12176 | |
da0f6381 PB |
12177 | fi |
12178 | fi | |
12179 | ac_ct_AR=$ac_cv_prog_ac_ct_AR | |
12180 | if test -n "$ac_ct_AR"; then | |
5213506e RW |
12181 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 |
12182 | $as_echo "$ac_ct_AR" >&6; } | |
da0f6381 | 12183 | else |
5213506e RW |
12184 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12185 | $as_echo "no" >&6; } | |
da0f6381 PB |
12186 | fi |
12187 | ||
5213506e RW |
12188 | if test "x$ac_ct_AR" = x; then |
12189 | AR="false" | |
12190 | else | |
12191 | case $cross_compiling:$ac_tool_warned in | |
12192 | yes:) | |
12193 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
12194 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
12195 | ac_tool_warned=yes ;; | |
12196 | esac | |
12197 | AR=$ac_ct_AR | |
12198 | fi | |
da0f6381 PB |
12199 | else |
12200 | AR="$ac_cv_prog_AR" | |
12201 | fi | |
12202 | ||
12203 | test -z "$AR" && AR=ar | |
12204 | test -z "$AR_FLAGS" && AR_FLAGS=cru | |
12205 | ||
12206 | ||
12207 | ||
12208 | ||
12209 | ||
12210 | ||
12211 | ||
12212 | ||
12213 | ||
12214 | ||
12215 | ||
12216 | if test -n "$ac_tool_prefix"; then | |
12217 | # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args. | |
12218 | set dummy ${ac_tool_prefix}strip; ac_word=$2 | |
5213506e RW |
12219 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12220 | $as_echo_n "checking for $ac_word... " >&6; } | |
12221 | if test "${ac_cv_prog_STRIP+set}" = set; then : | |
12222 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12223 | else |
12224 | if test -n "$STRIP"; then | |
12225 | ac_cv_prog_STRIP="$STRIP" # Let the user override the test. | |
12226 | else | |
12227 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12228 | for as_dir in $PATH | |
12229 | do | |
12230 | IFS=$as_save_IFS | |
12231 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12232 | for ac_exec_ext in '' $ac_executable_extensions; do |
12233 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12234 | ac_cv_prog_STRIP="${ac_tool_prefix}strip" |
5213506e | 12235 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12236 | break 2 |
12237 | fi | |
12238 | done | |
5213506e RW |
12239 | done |
12240 | IFS=$as_save_IFS | |
da0f6381 PB |
12241 | |
12242 | fi | |
12243 | fi | |
12244 | STRIP=$ac_cv_prog_STRIP | |
12245 | if test -n "$STRIP"; then | |
5213506e RW |
12246 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 |
12247 | $as_echo "$STRIP" >&6; } | |
da0f6381 | 12248 | else |
5213506e RW |
12249 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12250 | $as_echo "no" >&6; } | |
da0f6381 PB |
12251 | fi |
12252 | ||
5213506e | 12253 | |
da0f6381 PB |
12254 | fi |
12255 | if test -z "$ac_cv_prog_STRIP"; then | |
12256 | ac_ct_STRIP=$STRIP | |
12257 | # Extract the first word of "strip", so it can be a program name with args. | |
12258 | set dummy strip; ac_word=$2 | |
5213506e RW |
12259 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12260 | $as_echo_n "checking for $ac_word... " >&6; } | |
12261 | if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then : | |
12262 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12263 | else |
12264 | if test -n "$ac_ct_STRIP"; then | |
12265 | ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. | |
12266 | else | |
12267 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12268 | for as_dir in $PATH | |
12269 | do | |
12270 | IFS=$as_save_IFS | |
12271 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12272 | for ac_exec_ext in '' $ac_executable_extensions; do |
12273 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12274 | ac_cv_prog_ac_ct_STRIP="strip" |
5213506e | 12275 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12276 | break 2 |
12277 | fi | |
12278 | done | |
5213506e RW |
12279 | done |
12280 | IFS=$as_save_IFS | |
da0f6381 | 12281 | |
da0f6381 PB |
12282 | fi |
12283 | fi | |
12284 | ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP | |
12285 | if test -n "$ac_ct_STRIP"; then | |
5213506e RW |
12286 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 |
12287 | $as_echo "$ac_ct_STRIP" >&6; } | |
da0f6381 | 12288 | else |
5213506e RW |
12289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12290 | $as_echo "no" >&6; } | |
da0f6381 PB |
12291 | fi |
12292 | ||
5213506e RW |
12293 | if test "x$ac_ct_STRIP" = x; then |
12294 | STRIP=":" | |
12295 | else | |
12296 | case $cross_compiling:$ac_tool_warned in | |
12297 | yes:) | |
12298 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
12299 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
12300 | ac_tool_warned=yes ;; | |
12301 | esac | |
12302 | STRIP=$ac_ct_STRIP | |
12303 | fi | |
da0f6381 PB |
12304 | else |
12305 | STRIP="$ac_cv_prog_STRIP" | |
12306 | fi | |
12307 | ||
12308 | test -z "$STRIP" && STRIP=: | |
12309 | ||
12310 | ||
12311 | ||
12312 | ||
12313 | ||
12314 | ||
12315 | if test -n "$ac_tool_prefix"; then | |
12316 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | |
12317 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | |
5213506e RW |
12318 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12319 | $as_echo_n "checking for $ac_word... " >&6; } | |
12320 | if test "${ac_cv_prog_RANLIB+set}" = set; then : | |
12321 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12322 | else |
12323 | if test -n "$RANLIB"; then | |
12324 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | |
12325 | else | |
12326 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12327 | for as_dir in $PATH | |
12328 | do | |
12329 | IFS=$as_save_IFS | |
12330 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12331 | for ac_exec_ext in '' $ac_executable_extensions; do |
12332 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12333 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" |
5213506e | 12334 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12335 | break 2 |
12336 | fi | |
12337 | done | |
5213506e RW |
12338 | done |
12339 | IFS=$as_save_IFS | |
da0f6381 PB |
12340 | |
12341 | fi | |
12342 | fi | |
12343 | RANLIB=$ac_cv_prog_RANLIB | |
12344 | if test -n "$RANLIB"; then | |
5213506e RW |
12345 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 |
12346 | $as_echo "$RANLIB" >&6; } | |
da0f6381 | 12347 | else |
5213506e RW |
12348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12349 | $as_echo "no" >&6; } | |
da0f6381 PB |
12350 | fi |
12351 | ||
5213506e | 12352 | |
da0f6381 PB |
12353 | fi |
12354 | if test -z "$ac_cv_prog_RANLIB"; then | |
12355 | ac_ct_RANLIB=$RANLIB | |
12356 | # Extract the first word of "ranlib", so it can be a program name with args. | |
12357 | set dummy ranlib; ac_word=$2 | |
5213506e RW |
12358 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12359 | $as_echo_n "checking for $ac_word... " >&6; } | |
12360 | if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then : | |
12361 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12362 | else |
12363 | if test -n "$ac_ct_RANLIB"; then | |
12364 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | |
12365 | else | |
12366 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12367 | for as_dir in $PATH | |
12368 | do | |
12369 | IFS=$as_save_IFS | |
12370 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12371 | for ac_exec_ext in '' $ac_executable_extensions; do |
12372 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 12373 | ac_cv_prog_ac_ct_RANLIB="ranlib" |
5213506e | 12374 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
12375 | break 2 |
12376 | fi | |
12377 | done | |
5213506e RW |
12378 | done |
12379 | IFS=$as_save_IFS | |
da0f6381 | 12380 | |
da0f6381 PB |
12381 | fi |
12382 | fi | |
12383 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | |
12384 | if test -n "$ac_ct_RANLIB"; then | |
5213506e RW |
12385 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 |
12386 | $as_echo "$ac_ct_RANLIB" >&6; } | |
da0f6381 | 12387 | else |
5213506e RW |
12388 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12389 | $as_echo "no" >&6; } | |
da0f6381 PB |
12390 | fi |
12391 | ||
5213506e RW |
12392 | if test "x$ac_ct_RANLIB" = x; then |
12393 | RANLIB=":" | |
12394 | else | |
12395 | case $cross_compiling:$ac_tool_warned in | |
12396 | yes:) | |
12397 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
12398 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
12399 | ac_tool_warned=yes ;; | |
12400 | esac | |
12401 | RANLIB=$ac_ct_RANLIB | |
12402 | fi | |
da0f6381 PB |
12403 | else |
12404 | RANLIB="$ac_cv_prog_RANLIB" | |
12405 | fi | |
12406 | ||
12407 | test -z "$RANLIB" && RANLIB=: | |
12408 | ||
12409 | ||
12410 | ||
12411 | ||
12412 | ||
12413 | ||
12414 | # Determine commands to create old-style static archives. | |
5d47bb02 | 12415 | old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs' |
da0f6381 PB |
12416 | old_postinstall_cmds='chmod 644 $oldlib' |
12417 | old_postuninstall_cmds= | |
12418 | ||
12419 | if test -n "$RANLIB"; then | |
12420 | case $host_os in | |
12421 | openbsd*) | |
12422 | old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib" | |
12423 | ;; | |
12424 | *) | |
12425 | old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib" | |
12426 | ;; | |
12427 | esac | |
12428 | old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib" | |
12429 | fi | |
12430 | ||
43e02a8a RW |
12431 | case $host_os in |
12432 | darwin*) | |
12433 | lock_old_archive_extraction=yes ;; | |
12434 | *) | |
12435 | lock_old_archive_extraction=no ;; | |
12436 | esac | |
12437 | ||
12438 | ||
12439 | ||
12440 | ||
12441 | ||
12442 | ||
da0f6381 PB |
12443 | |
12444 | ||
12445 | ||
12446 | ||
12447 | ||
12448 | ||
12449 | ||
12450 | ||
12451 | ||
12452 | ||
12453 | ||
12454 | ||
12455 | ||
12456 | ||
12457 | ||
12458 | ||
12459 | ||
12460 | ||
12461 | ||
12462 | ||
12463 | ||
12464 | ||
12465 | ||
12466 | ||
12467 | ||
12468 | ||
12469 | ||
12470 | ||
12471 | ||
12472 | ||
12473 | ||
12474 | ||
12475 | ||
12476 | # If no C compiler was specified, use CC. | |
12477 | LTCC=${LTCC-"$CC"} | |
12478 | ||
12479 | # If no C compiler flags were specified, use CFLAGS. | |
12480 | LTCFLAGS=${LTCFLAGS-"$CFLAGS"} | |
12481 | ||
12482 | # Allow CC to be a program name with arguments. | |
12483 | compiler=$CC | |
12484 | ||
12485 | ||
12486 | # Check for command to grab the raw symbol name followed by C symbol from nm. | |
5213506e RW |
12487 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking command to parse $NM output from $compiler object" >&5 |
12488 | $as_echo_n "checking command to parse $NM output from $compiler object... " >&6; } | |
12489 | if test "${lt_cv_sys_global_symbol_pipe+set}" = set; then : | |
12490 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12491 | else |
12492 | ||
12493 | # These are sane defaults that work on at least a few old systems. | |
12494 | # [They come from Ultrix. What could be older than Ultrix?!! ;)] | |
12495 | ||
12496 | # Character class describing NM global symbol codes. | |
12497 | symcode='[BCDEGRST]' | |
12498 | ||
12499 | # Regexp to match symbols that can be accessed directly from C. | |
12500 | sympat='\([_A-Za-z][_A-Za-z0-9]*\)' | |
12501 | ||
12502 | # Define system-specific variables. | |
12503 | case $host_os in | |
12504 | aix*) | |
12505 | symcode='[BCDT]' | |
12506 | ;; | |
5d47bb02 | 12507 | cygwin* | mingw* | pw32* | cegcc*) |
da0f6381 PB |
12508 | symcode='[ABCDGISTW]' |
12509 | ;; | |
12510 | hpux*) | |
12511 | if test "$host_cpu" = ia64; then | |
12512 | symcode='[ABCDEGRST]' | |
12513 | fi | |
12514 | ;; | |
12515 | irix* | nonstopux*) | |
12516 | symcode='[BCDEGRST]' | |
12517 | ;; | |
12518 | osf*) | |
12519 | symcode='[BCDEGQRST]' | |
12520 | ;; | |
12521 | solaris*) | |
12522 | symcode='[BDRT]' | |
12523 | ;; | |
12524 | sco3.2v5*) | |
12525 | symcode='[DT]' | |
12526 | ;; | |
12527 | sysv4.2uw2*) | |
12528 | symcode='[DT]' | |
12529 | ;; | |
12530 | sysv5* | sco5v6* | unixware* | OpenUNIX*) | |
12531 | symcode='[ABDT]' | |
12532 | ;; | |
12533 | sysv4) | |
12534 | symcode='[DFNSTU]' | |
12535 | ;; | |
12536 | esac | |
12537 | ||
12538 | # If we're using GNU nm, then use its standard symbol codes. | |
12539 | case `$NM -V 2>&1` in | |
12540 | *GNU* | *'with BFD'*) | |
12541 | symcode='[ABCDGIRSTW]' ;; | |
12542 | esac | |
12543 | ||
12544 | # Transform an extracted symbol line into a proper C declaration. | |
12545 | # Some systems (esp. on ia64) link data and code symbols differently, | |
12546 | # so use this general approach. | |
12547 | lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'" | |
12548 | ||
12549 | # Transform an extracted symbol line into symbol name and symbol address | |
12550 | lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"\2\", (void *) \&\2},/p'" | |
5d47bb02 | 12551 | lt_cv_sys_global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \([^ ]*\) $/ {\\\"\1\\\", (void *) 0},/p' -e 's/^$symcode* \([^ ]*\) \(lib[^ ]*\)$/ {\"\2\", (void *) \&\2},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/ {\"lib\2\", (void *) \&\2},/p'" |
da0f6381 PB |
12552 | |
12553 | # Handle CRLF in mingw tool chain | |
12554 | opt_cr= | |
12555 | case $build_os in | |
12556 | mingw*) | |
12557 | opt_cr=`$ECHO 'x\{0,1\}' | tr x '\015'` # option cr in regexp | |
12558 | ;; | |
12559 | esac | |
12560 | ||
12561 | # Try without a prefix underscore, then with it. | |
12562 | for ac_symprfx in "" "_"; do | |
12563 | ||
12564 | # Transform symcode, sympat, and symprfx into a raw symbol and a C symbol. | |
12565 | symxfrm="\\1 $ac_symprfx\\2 \\2" | |
12566 | ||
12567 | # Write the raw and C identifiers. | |
12568 | if test "$lt_cv_nm_interface" = "MS dumpbin"; then | |
12569 | # Fake it for dumpbin and say T for any non-static function | |
12570 | # and D for any global variable. | |
12571 | # Also find C++ and __fastcall symbols from MSVC++, | |
12572 | # which start with @ or ?. | |
12573 | lt_cv_sys_global_symbol_pipe="$AWK '"\ | |
12574 | " {last_section=section; section=\$ 3};"\ | |
12575 | " /Section length .*#relocs.*(pick any)/{hide[last_section]=1};"\ | |
12576 | " \$ 0!~/External *\|/{next};"\ | |
12577 | " / 0+ UNDEF /{next}; / UNDEF \([^|]\)*()/{next};"\ | |
12578 | " {if(hide[section]) next};"\ | |
12579 | " {f=0}; \$ 0~/\(\).*\|/{f=1}; {printf f ? \"T \" : \"D \"};"\ | |
12580 | " {split(\$ 0, a, /\||\r/); split(a[2], s)};"\ | |
12581 | " s[1]~/^[@?]/{print s[1], s[1]; next};"\ | |
12582 | " s[1]~prfx {split(s[1],t,\"@\"); print t[1], substr(t[1],length(prfx))}"\ | |
12583 | " ' prfx=^$ac_symprfx" | |
12584 | else | |
12585 | lt_cv_sys_global_symbol_pipe="sed -n -e 's/^.*[ ]\($symcode$symcode*\)[ ][ ]*$ac_symprfx$sympat$opt_cr$/$symxfrm/p'" | |
12586 | fi | |
12587 | ||
12588 | # Check to see that the pipe works correctly. | |
12589 | pipe_works=no | |
12590 | ||
12591 | rm -f conftest* | |
12592 | cat > conftest.$ac_ext <<_LT_EOF | |
12593 | #ifdef __cplusplus | |
12594 | extern "C" { | |
12595 | #endif | |
12596 | char nm_test_var; | |
12597 | void nm_test_func(void); | |
12598 | void nm_test_func(void){} | |
12599 | #ifdef __cplusplus | |
12600 | } | |
12601 | #endif | |
12602 | int main(){nm_test_var='a';nm_test_func();return(0);} | |
12603 | _LT_EOF | |
12604 | ||
5213506e | 12605 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
da0f6381 PB |
12606 | (eval $ac_compile) 2>&5 |
12607 | ac_status=$? | |
5213506e RW |
12608 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12609 | test $ac_status = 0; }; then | |
da0f6381 PB |
12610 | # Now try to grab the symbols. |
12611 | nlist=conftest.nm | |
43e02a8a RW |
12612 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist\""; } >&5 |
12613 | (eval $NM conftest.$ac_objext \| "$lt_cv_sys_global_symbol_pipe" \> $nlist) 2>&5 | |
da0f6381 | 12614 | ac_status=$? |
5213506e RW |
12615 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12616 | test $ac_status = 0; } && test -s "$nlist"; then | |
da0f6381 PB |
12617 | # Try sorting and uniquifying the output. |
12618 | if sort "$nlist" | uniq > "$nlist"T; then | |
12619 | mv -f "$nlist"T "$nlist" | |
12620 | else | |
12621 | rm -f "$nlist"T | |
12622 | fi | |
12623 | ||
12624 | # Make sure that we snagged all the symbols we need. | |
12625 | if $GREP ' nm_test_var$' "$nlist" >/dev/null; then | |
12626 | if $GREP ' nm_test_func$' "$nlist" >/dev/null; then | |
12627 | cat <<_LT_EOF > conftest.$ac_ext | |
12628 | #ifdef __cplusplus | |
12629 | extern "C" { | |
12630 | #endif | |
12631 | ||
12632 | _LT_EOF | |
12633 | # Now generate the symbol file. | |
12634 | eval "$lt_cv_sys_global_symbol_to_cdecl"' < "$nlist" | $GREP -v main >> conftest.$ac_ext' | |
12635 | ||
12636 | cat <<_LT_EOF >> conftest.$ac_ext | |
12637 | ||
12638 | /* The mapping between symbol names and symbols. */ | |
12639 | const struct { | |
12640 | const char *name; | |
12641 | void *address; | |
12642 | } | |
12643 | lt__PROGRAM__LTX_preloaded_symbols[] = | |
12644 | { | |
12645 | { "@PROGRAM@", (void *) 0 }, | |
12646 | _LT_EOF | |
12647 | $SED "s/^$symcode$symcode* \(.*\) \(.*\)$/ {\"\2\", (void *) \&\2},/" < "$nlist" | $GREP -v main >> conftest.$ac_ext | |
12648 | cat <<\_LT_EOF >> conftest.$ac_ext | |
12649 | {0, (void *) 0} | |
12650 | }; | |
12651 | ||
12652 | /* This works around a problem in FreeBSD linker */ | |
12653 | #ifdef FREEBSD_WORKAROUND | |
12654 | static const void *lt_preloaded_setup() { | |
12655 | return lt__PROGRAM__LTX_preloaded_symbols; | |
12656 | } | |
12657 | #endif | |
12658 | ||
12659 | #ifdef __cplusplus | |
12660 | } | |
12661 | #endif | |
12662 | _LT_EOF | |
12663 | # Now try linking the two files. | |
12664 | mv conftest.$ac_objext conftstm.$ac_objext | |
12665 | lt_save_LIBS="$LIBS" | |
12666 | lt_save_CFLAGS="$CFLAGS" | |
12667 | LIBS="conftstm.$ac_objext" | |
12668 | CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag" | |
5213506e | 12669 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 |
da0f6381 PB |
12670 | (eval $ac_link) 2>&5 |
12671 | ac_status=$? | |
5213506e RW |
12672 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12673 | test $ac_status = 0; } && test -s conftest${ac_exeext}; then | |
da0f6381 PB |
12674 | pipe_works=yes |
12675 | fi | |
12676 | LIBS="$lt_save_LIBS" | |
12677 | CFLAGS="$lt_save_CFLAGS" | |
12678 | else | |
12679 | echo "cannot find nm_test_func in $nlist" >&5 | |
12680 | fi | |
12681 | else | |
12682 | echo "cannot find nm_test_var in $nlist" >&5 | |
12683 | fi | |
12684 | else | |
12685 | echo "cannot run $lt_cv_sys_global_symbol_pipe" >&5 | |
12686 | fi | |
12687 | else | |
12688 | echo "$progname: failed program was:" >&5 | |
12689 | cat conftest.$ac_ext >&5 | |
12690 | fi | |
5d47bb02 | 12691 | rm -rf conftest* conftst* |
da0f6381 PB |
12692 | |
12693 | # Do not use the global_symbol_pipe unless it works. | |
12694 | if test "$pipe_works" = yes; then | |
12695 | break | |
12696 | else | |
12697 | lt_cv_sys_global_symbol_pipe= | |
12698 | fi | |
12699 | done | |
12700 | ||
12701 | fi | |
12702 | ||
12703 | if test -z "$lt_cv_sys_global_symbol_pipe"; then | |
12704 | lt_cv_sys_global_symbol_to_cdecl= | |
12705 | fi | |
12706 | if test -z "$lt_cv_sys_global_symbol_pipe$lt_cv_sys_global_symbol_to_cdecl"; then | |
5213506e RW |
12707 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: failed" >&5 |
12708 | $as_echo "failed" >&6; } | |
da0f6381 | 12709 | else |
5213506e RW |
12710 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 |
12711 | $as_echo "ok" >&6; } | |
da0f6381 PB |
12712 | fi |
12713 | ||
12714 | ||
12715 | ||
12716 | ||
12717 | ||
12718 | ||
12719 | ||
12720 | ||
12721 | ||
12722 | ||
12723 | ||
12724 | ||
12725 | ||
12726 | ||
12727 | ||
5d47bb02 PG |
12728 | |
12729 | ||
12730 | ||
12731 | ||
12732 | ||
da0f6381 PB |
12733 | |
12734 | ||
5213506e RW |
12735 | # Check whether --enable-libtool-lock was given. |
12736 | if test "${enable_libtool_lock+set}" = set; then : | |
12737 | enableval=$enable_libtool_lock; | |
12738 | fi | |
da0f6381 | 12739 | |
da0f6381 PB |
12740 | test "x$enable_libtool_lock" != xno && enable_libtool_lock=yes |
12741 | ||
12742 | # Some flags need to be propagated to the compiler or linker for good | |
12743 | # libtool support. | |
12744 | case $host in | |
12745 | ia64-*-hpux*) | |
12746 | # Find out which ABI we are using. | |
12747 | echo 'int i;' > conftest.$ac_ext | |
5213506e | 12748 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
da0f6381 PB |
12749 | (eval $ac_compile) 2>&5 |
12750 | ac_status=$? | |
5213506e RW |
12751 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12752 | test $ac_status = 0; }; then | |
da0f6381 PB |
12753 | case `/usr/bin/file conftest.$ac_objext` in |
12754 | *ELF-32*) | |
12755 | HPUX_IA64_MODE="32" | |
12756 | ;; | |
12757 | *ELF-64*) | |
12758 | HPUX_IA64_MODE="64" | |
12759 | ;; | |
12760 | esac | |
12761 | fi | |
12762 | rm -rf conftest* | |
12763 | ;; | |
12764 | *-*-irix6*) | |
12765 | # Find out which ABI we are using. | |
43e02a8a | 12766 | echo '#line '$LINENO' "configure"' > conftest.$ac_ext |
5213506e | 12767 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
da0f6381 PB |
12768 | (eval $ac_compile) 2>&5 |
12769 | ac_status=$? | |
5213506e RW |
12770 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12771 | test $ac_status = 0; }; then | |
da0f6381 PB |
12772 | if test "$lt_cv_prog_gnu_ld" = yes; then |
12773 | case `/usr/bin/file conftest.$ac_objext` in | |
12774 | *32-bit*) | |
12775 | LD="${LD-ld} -melf32bsmip" | |
12776 | ;; | |
12777 | *N32*) | |
12778 | LD="${LD-ld} -melf32bmipn32" | |
12779 | ;; | |
12780 | *64-bit*) | |
12781 | LD="${LD-ld} -melf64bmip" | |
12782 | ;; | |
12783 | esac | |
12784 | else | |
12785 | case `/usr/bin/file conftest.$ac_objext` in | |
12786 | *32-bit*) | |
12787 | LD="${LD-ld} -32" | |
12788 | ;; | |
12789 | *N32*) | |
12790 | LD="${LD-ld} -n32" | |
12791 | ;; | |
12792 | *64-bit*) | |
12793 | LD="${LD-ld} -64" | |
12794 | ;; | |
12795 | esac | |
12796 | fi | |
12797 | fi | |
12798 | rm -rf conftest* | |
12799 | ;; | |
12800 | ||
12801 | x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \ | |
12802 | s390*-*linux*|s390*-*tpf*|sparc*-*linux*) | |
12803 | # Find out which ABI we are using. | |
12804 | echo 'int i;' > conftest.$ac_ext | |
5213506e | 12805 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
da0f6381 PB |
12806 | (eval $ac_compile) 2>&5 |
12807 | ac_status=$? | |
5213506e RW |
12808 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12809 | test $ac_status = 0; }; then | |
da0f6381 PB |
12810 | case `/usr/bin/file conftest.o` in |
12811 | *32-bit*) | |
12812 | case $host in | |
12813 | x86_64-*kfreebsd*-gnu) | |
12814 | LD="${LD-ld} -m elf_i386_fbsd" | |
12815 | ;; | |
12816 | x86_64-*linux*) | |
12817 | LD="${LD-ld} -m elf_i386" | |
12818 | ;; | |
12819 | ppc64-*linux*|powerpc64-*linux*) | |
12820 | LD="${LD-ld} -m elf32ppclinux" | |
12821 | ;; | |
12822 | s390x-*linux*) | |
12823 | LD="${LD-ld} -m elf_s390" | |
12824 | ;; | |
12825 | sparc64-*linux*) | |
12826 | LD="${LD-ld} -m elf32_sparc" | |
12827 | ;; | |
12828 | esac | |
12829 | ;; | |
12830 | *64-bit*) | |
12831 | case $host in | |
12832 | x86_64-*kfreebsd*-gnu) | |
12833 | LD="${LD-ld} -m elf_x86_64_fbsd" | |
12834 | ;; | |
12835 | x86_64-*linux*) | |
12836 | LD="${LD-ld} -m elf_x86_64" | |
12837 | ;; | |
12838 | ppc*-*linux*|powerpc*-*linux*) | |
12839 | LD="${LD-ld} -m elf64ppc" | |
12840 | ;; | |
12841 | s390*-*linux*|s390*-*tpf*) | |
12842 | LD="${LD-ld} -m elf64_s390" | |
12843 | ;; | |
12844 | sparc*-*linux*) | |
12845 | LD="${LD-ld} -m elf64_sparc" | |
12846 | ;; | |
12847 | esac | |
12848 | ;; | |
12849 | esac | |
12850 | fi | |
12851 | rm -rf conftest* | |
12852 | ;; | |
12853 | ||
12854 | *-*-sco3.2v5*) | |
12855 | # On SCO OpenServer 5, we need -belf to get full-featured binaries. | |
12856 | SAVE_CFLAGS="$CFLAGS" | |
12857 | CFLAGS="$CFLAGS -belf" | |
5213506e RW |
12858 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler needs -belf" >&5 |
12859 | $as_echo_n "checking whether the C compiler needs -belf... " >&6; } | |
12860 | if test "${lt_cv_cc_needs_belf+set}" = set; then : | |
12861 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
12862 | else |
12863 | ac_ext=c | |
12864 | ac_cpp='$CPP $CPPFLAGS' | |
12865 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
12866 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
12867 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
12868 | ||
5213506e | 12869 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
da0f6381 PB |
12870 | /* end confdefs.h. */ |
12871 | ||
12872 | int | |
12873 | main () | |
12874 | { | |
12875 | ||
12876 | ; | |
12877 | return 0; | |
12878 | } | |
12879 | _ACEOF | |
5213506e | 12880 | if ac_fn_c_try_link "$LINENO"; then : |
da0f6381 PB |
12881 | lt_cv_cc_needs_belf=yes |
12882 | else | |
5213506e | 12883 | lt_cv_cc_needs_belf=no |
da0f6381 | 12884 | fi |
5213506e RW |
12885 | rm -f core conftest.err conftest.$ac_objext \ |
12886 | conftest$ac_exeext conftest.$ac_ext | |
da0f6381 PB |
12887 | ac_ext=c |
12888 | ac_cpp='$CPP $CPPFLAGS' | |
12889 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
12890 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
12891 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
12892 | ||
12893 | fi | |
5213506e RW |
12894 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_cc_needs_belf" >&5 |
12895 | $as_echo "$lt_cv_cc_needs_belf" >&6; } | |
da0f6381 PB |
12896 | if test x"$lt_cv_cc_needs_belf" != x"yes"; then |
12897 | # this is probably gcc 2.8.0, egcs 1.0 or newer; no need for -belf | |
12898 | CFLAGS="$SAVE_CFLAGS" | |
12899 | fi | |
12900 | ;; | |
12901 | sparc*-*solaris*) | |
12902 | # Find out which ABI we are using. | |
12903 | echo 'int i;' > conftest.$ac_ext | |
5213506e | 12904 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
da0f6381 PB |
12905 | (eval $ac_compile) 2>&5 |
12906 | ac_status=$? | |
5213506e RW |
12907 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
12908 | test $ac_status = 0; }; then | |
da0f6381 PB |
12909 | case `/usr/bin/file conftest.o` in |
12910 | *64-bit*) | |
12911 | case $lt_cv_prog_gnu_ld in | |
12912 | yes*) LD="${LD-ld} -m elf64_sparc" ;; | |
5d47bb02 PG |
12913 | *) |
12914 | if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then | |
12915 | LD="${LD-ld} -64" | |
12916 | fi | |
12917 | ;; | |
da0f6381 PB |
12918 | esac |
12919 | ;; | |
12920 | esac | |
12921 | fi | |
12922 | rm -rf conftest* | |
12923 | ;; | |
12924 | esac | |
12925 | ||
5d47bb02 PG |
12926 | need_locks="$enable_libtool_lock" |
12927 | ||
12928 | ||
12929 | case $host_os in | |
12930 | rhapsody* | darwin*) | |
12931 | if test -n "$ac_tool_prefix"; then | |
12932 | # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args. | |
12933 | set dummy ${ac_tool_prefix}dsymutil; ac_word=$2 | |
5213506e RW |
12934 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12935 | $as_echo_n "checking for $ac_word... " >&6; } | |
12936 | if test "${ac_cv_prog_DSYMUTIL+set}" = set; then : | |
12937 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
12938 | else |
12939 | if test -n "$DSYMUTIL"; then | |
12940 | ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test. | |
12941 | else | |
12942 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12943 | for as_dir in $PATH | |
12944 | do | |
12945 | IFS=$as_save_IFS | |
12946 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12947 | for ac_exec_ext in '' $ac_executable_extensions; do |
12948 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 12949 | ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil" |
5213506e | 12950 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
12951 | break 2 |
12952 | fi | |
12953 | done | |
5213506e RW |
12954 | done |
12955 | IFS=$as_save_IFS | |
5d47bb02 PG |
12956 | |
12957 | fi | |
12958 | fi | |
12959 | DSYMUTIL=$ac_cv_prog_DSYMUTIL | |
12960 | if test -n "$DSYMUTIL"; then | |
5213506e RW |
12961 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 |
12962 | $as_echo "$DSYMUTIL" >&6; } | |
5d47bb02 | 12963 | else |
5213506e RW |
12964 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
12965 | $as_echo "no" >&6; } | |
5d47bb02 PG |
12966 | fi |
12967 | ||
5213506e | 12968 | |
5d47bb02 PG |
12969 | fi |
12970 | if test -z "$ac_cv_prog_DSYMUTIL"; then | |
12971 | ac_ct_DSYMUTIL=$DSYMUTIL | |
12972 | # Extract the first word of "dsymutil", so it can be a program name with args. | |
12973 | set dummy dsymutil; ac_word=$2 | |
5213506e RW |
12974 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
12975 | $as_echo_n "checking for $ac_word... " >&6; } | |
12976 | if test "${ac_cv_prog_ac_ct_DSYMUTIL+set}" = set; then : | |
12977 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
12978 | else |
12979 | if test -n "$ac_ct_DSYMUTIL"; then | |
12980 | ac_cv_prog_ac_ct_DSYMUTIL="$ac_ct_DSYMUTIL" # Let the user override the test. | |
12981 | else | |
12982 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
12983 | for as_dir in $PATH | |
12984 | do | |
12985 | IFS=$as_save_IFS | |
12986 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
12987 | for ac_exec_ext in '' $ac_executable_extensions; do |
12988 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 12989 | ac_cv_prog_ac_ct_DSYMUTIL="dsymutil" |
5213506e | 12990 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
12991 | break 2 |
12992 | fi | |
12993 | done | |
5213506e RW |
12994 | done |
12995 | IFS=$as_save_IFS | |
5d47bb02 | 12996 | |
5d47bb02 PG |
12997 | fi |
12998 | fi | |
12999 | ac_ct_DSYMUTIL=$ac_cv_prog_ac_ct_DSYMUTIL | |
13000 | if test -n "$ac_ct_DSYMUTIL"; then | |
5213506e RW |
13001 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_DSYMUTIL" >&5 |
13002 | $as_echo "$ac_ct_DSYMUTIL" >&6; } | |
5d47bb02 | 13003 | else |
5213506e RW |
13004 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13005 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13006 | fi |
13007 | ||
5213506e RW |
13008 | if test "x$ac_ct_DSYMUTIL" = x; then |
13009 | DSYMUTIL=":" | |
13010 | else | |
13011 | case $cross_compiling:$ac_tool_warned in | |
13012 | yes:) | |
13013 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
13014 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
13015 | ac_tool_warned=yes ;; | |
13016 | esac | |
13017 | DSYMUTIL=$ac_ct_DSYMUTIL | |
13018 | fi | |
5d47bb02 PG |
13019 | else |
13020 | DSYMUTIL="$ac_cv_prog_DSYMUTIL" | |
13021 | fi | |
13022 | ||
13023 | if test -n "$ac_tool_prefix"; then | |
13024 | # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args. | |
13025 | set dummy ${ac_tool_prefix}nmedit; ac_word=$2 | |
5213506e RW |
13026 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13027 | $as_echo_n "checking for $ac_word... " >&6; } | |
13028 | if test "${ac_cv_prog_NMEDIT+set}" = set; then : | |
13029 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13030 | else |
13031 | if test -n "$NMEDIT"; then | |
13032 | ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test. | |
13033 | else | |
13034 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13035 | for as_dir in $PATH | |
13036 | do | |
13037 | IFS=$as_save_IFS | |
13038 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13039 | for ac_exec_ext in '' $ac_executable_extensions; do |
13040 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13041 | ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit" |
5213506e | 13042 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13043 | break 2 |
13044 | fi | |
13045 | done | |
5213506e RW |
13046 | done |
13047 | IFS=$as_save_IFS | |
5d47bb02 PG |
13048 | |
13049 | fi | |
13050 | fi | |
13051 | NMEDIT=$ac_cv_prog_NMEDIT | |
13052 | if test -n "$NMEDIT"; then | |
5213506e RW |
13053 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NMEDIT" >&5 |
13054 | $as_echo "$NMEDIT" >&6; } | |
5d47bb02 | 13055 | else |
5213506e RW |
13056 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13057 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13058 | fi |
13059 | ||
5213506e | 13060 | |
5d47bb02 PG |
13061 | fi |
13062 | if test -z "$ac_cv_prog_NMEDIT"; then | |
13063 | ac_ct_NMEDIT=$NMEDIT | |
13064 | # Extract the first word of "nmedit", so it can be a program name with args. | |
13065 | set dummy nmedit; ac_word=$2 | |
5213506e RW |
13066 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13067 | $as_echo_n "checking for $ac_word... " >&6; } | |
13068 | if test "${ac_cv_prog_ac_ct_NMEDIT+set}" = set; then : | |
13069 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13070 | else |
13071 | if test -n "$ac_ct_NMEDIT"; then | |
13072 | ac_cv_prog_ac_ct_NMEDIT="$ac_ct_NMEDIT" # Let the user override the test. | |
13073 | else | |
13074 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13075 | for as_dir in $PATH | |
13076 | do | |
13077 | IFS=$as_save_IFS | |
13078 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13079 | for ac_exec_ext in '' $ac_executable_extensions; do |
13080 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13081 | ac_cv_prog_ac_ct_NMEDIT="nmedit" |
5213506e | 13082 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13083 | break 2 |
13084 | fi | |
13085 | done | |
5213506e RW |
13086 | done |
13087 | IFS=$as_save_IFS | |
5d47bb02 | 13088 | |
5d47bb02 PG |
13089 | fi |
13090 | fi | |
13091 | ac_ct_NMEDIT=$ac_cv_prog_ac_ct_NMEDIT | |
13092 | if test -n "$ac_ct_NMEDIT"; then | |
5213506e RW |
13093 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NMEDIT" >&5 |
13094 | $as_echo "$ac_ct_NMEDIT" >&6; } | |
5d47bb02 | 13095 | else |
5213506e RW |
13096 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13097 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13098 | fi |
13099 | ||
5213506e RW |
13100 | if test "x$ac_ct_NMEDIT" = x; then |
13101 | NMEDIT=":" | |
13102 | else | |
13103 | case $cross_compiling:$ac_tool_warned in | |
13104 | yes:) | |
13105 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
13106 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
13107 | ac_tool_warned=yes ;; | |
13108 | esac | |
13109 | NMEDIT=$ac_ct_NMEDIT | |
13110 | fi | |
5d47bb02 PG |
13111 | else |
13112 | NMEDIT="$ac_cv_prog_NMEDIT" | |
13113 | fi | |
13114 | ||
13115 | if test -n "$ac_tool_prefix"; then | |
13116 | # Extract the first word of "${ac_tool_prefix}lipo", so it can be a program name with args. | |
13117 | set dummy ${ac_tool_prefix}lipo; ac_word=$2 | |
5213506e RW |
13118 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13119 | $as_echo_n "checking for $ac_word... " >&6; } | |
13120 | if test "${ac_cv_prog_LIPO+set}" = set; then : | |
13121 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13122 | else |
13123 | if test -n "$LIPO"; then | |
13124 | ac_cv_prog_LIPO="$LIPO" # Let the user override the test. | |
13125 | else | |
13126 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13127 | for as_dir in $PATH | |
13128 | do | |
13129 | IFS=$as_save_IFS | |
13130 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13131 | for ac_exec_ext in '' $ac_executable_extensions; do |
13132 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13133 | ac_cv_prog_LIPO="${ac_tool_prefix}lipo" |
5213506e | 13134 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13135 | break 2 |
13136 | fi | |
13137 | done | |
5213506e RW |
13138 | done |
13139 | IFS=$as_save_IFS | |
5d47bb02 PG |
13140 | |
13141 | fi | |
13142 | fi | |
13143 | LIPO=$ac_cv_prog_LIPO | |
13144 | if test -n "$LIPO"; then | |
5213506e RW |
13145 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 |
13146 | $as_echo "$LIPO" >&6; } | |
5d47bb02 | 13147 | else |
5213506e RW |
13148 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13149 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13150 | fi |
13151 | ||
5213506e | 13152 | |
5d47bb02 PG |
13153 | fi |
13154 | if test -z "$ac_cv_prog_LIPO"; then | |
13155 | ac_ct_LIPO=$LIPO | |
13156 | # Extract the first word of "lipo", so it can be a program name with args. | |
13157 | set dummy lipo; ac_word=$2 | |
5213506e RW |
13158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13159 | $as_echo_n "checking for $ac_word... " >&6; } | |
13160 | if test "${ac_cv_prog_ac_ct_LIPO+set}" = set; then : | |
13161 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13162 | else |
13163 | if test -n "$ac_ct_LIPO"; then | |
13164 | ac_cv_prog_ac_ct_LIPO="$ac_ct_LIPO" # Let the user override the test. | |
13165 | else | |
13166 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13167 | for as_dir in $PATH | |
13168 | do | |
13169 | IFS=$as_save_IFS | |
13170 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13171 | for ac_exec_ext in '' $ac_executable_extensions; do |
13172 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13173 | ac_cv_prog_ac_ct_LIPO="lipo" |
5213506e | 13174 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13175 | break 2 |
13176 | fi | |
13177 | done | |
5213506e RW |
13178 | done |
13179 | IFS=$as_save_IFS | |
5d47bb02 | 13180 | |
5d47bb02 PG |
13181 | fi |
13182 | fi | |
13183 | ac_ct_LIPO=$ac_cv_prog_ac_ct_LIPO | |
13184 | if test -n "$ac_ct_LIPO"; then | |
5213506e RW |
13185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_LIPO" >&5 |
13186 | $as_echo "$ac_ct_LIPO" >&6; } | |
5d47bb02 | 13187 | else |
5213506e RW |
13188 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13189 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13190 | fi |
13191 | ||
5213506e RW |
13192 | if test "x$ac_ct_LIPO" = x; then |
13193 | LIPO=":" | |
13194 | else | |
13195 | case $cross_compiling:$ac_tool_warned in | |
13196 | yes:) | |
13197 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
13198 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
13199 | ac_tool_warned=yes ;; | |
13200 | esac | |
13201 | LIPO=$ac_ct_LIPO | |
13202 | fi | |
5d47bb02 PG |
13203 | else |
13204 | LIPO="$ac_cv_prog_LIPO" | |
13205 | fi | |
13206 | ||
13207 | if test -n "$ac_tool_prefix"; then | |
13208 | # Extract the first word of "${ac_tool_prefix}otool", so it can be a program name with args. | |
13209 | set dummy ${ac_tool_prefix}otool; ac_word=$2 | |
5213506e RW |
13210 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13211 | $as_echo_n "checking for $ac_word... " >&6; } | |
13212 | if test "${ac_cv_prog_OTOOL+set}" = set; then : | |
13213 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13214 | else |
13215 | if test -n "$OTOOL"; then | |
13216 | ac_cv_prog_OTOOL="$OTOOL" # Let the user override the test. | |
13217 | else | |
13218 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13219 | for as_dir in $PATH | |
13220 | do | |
13221 | IFS=$as_save_IFS | |
13222 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13223 | for ac_exec_ext in '' $ac_executable_extensions; do |
13224 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13225 | ac_cv_prog_OTOOL="${ac_tool_prefix}otool" |
5213506e | 13226 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13227 | break 2 |
13228 | fi | |
13229 | done | |
5213506e RW |
13230 | done |
13231 | IFS=$as_save_IFS | |
5d47bb02 PG |
13232 | |
13233 | fi | |
13234 | fi | |
13235 | OTOOL=$ac_cv_prog_OTOOL | |
13236 | if test -n "$OTOOL"; then | |
5213506e RW |
13237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 |
13238 | $as_echo "$OTOOL" >&6; } | |
5d47bb02 | 13239 | else |
5213506e RW |
13240 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13241 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13242 | fi |
13243 | ||
5213506e | 13244 | |
5d47bb02 PG |
13245 | fi |
13246 | if test -z "$ac_cv_prog_OTOOL"; then | |
13247 | ac_ct_OTOOL=$OTOOL | |
13248 | # Extract the first word of "otool", so it can be a program name with args. | |
13249 | set dummy otool; ac_word=$2 | |
5213506e RW |
13250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13251 | $as_echo_n "checking for $ac_word... " >&6; } | |
13252 | if test "${ac_cv_prog_ac_ct_OTOOL+set}" = set; then : | |
13253 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13254 | else |
13255 | if test -n "$ac_ct_OTOOL"; then | |
13256 | ac_cv_prog_ac_ct_OTOOL="$ac_ct_OTOOL" # Let the user override the test. | |
13257 | else | |
13258 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13259 | for as_dir in $PATH | |
13260 | do | |
13261 | IFS=$as_save_IFS | |
13262 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13263 | for ac_exec_ext in '' $ac_executable_extensions; do |
13264 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13265 | ac_cv_prog_ac_ct_OTOOL="otool" |
5213506e | 13266 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13267 | break 2 |
13268 | fi | |
13269 | done | |
5213506e RW |
13270 | done |
13271 | IFS=$as_save_IFS | |
5d47bb02 | 13272 | |
5d47bb02 PG |
13273 | fi |
13274 | fi | |
13275 | ac_ct_OTOOL=$ac_cv_prog_ac_ct_OTOOL | |
13276 | if test -n "$ac_ct_OTOOL"; then | |
5213506e RW |
13277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL" >&5 |
13278 | $as_echo "$ac_ct_OTOOL" >&6; } | |
5d47bb02 | 13279 | else |
5213506e RW |
13280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13281 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13282 | fi |
13283 | ||
5213506e RW |
13284 | if test "x$ac_ct_OTOOL" = x; then |
13285 | OTOOL=":" | |
13286 | else | |
13287 | case $cross_compiling:$ac_tool_warned in | |
13288 | yes:) | |
13289 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
13290 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
13291 | ac_tool_warned=yes ;; | |
13292 | esac | |
13293 | OTOOL=$ac_ct_OTOOL | |
13294 | fi | |
5d47bb02 PG |
13295 | else |
13296 | OTOOL="$ac_cv_prog_OTOOL" | |
13297 | fi | |
13298 | ||
13299 | if test -n "$ac_tool_prefix"; then | |
13300 | # Extract the first word of "${ac_tool_prefix}otool64", so it can be a program name with args. | |
13301 | set dummy ${ac_tool_prefix}otool64; ac_word=$2 | |
5213506e RW |
13302 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13303 | $as_echo_n "checking for $ac_word... " >&6; } | |
13304 | if test "${ac_cv_prog_OTOOL64+set}" = set; then : | |
13305 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13306 | else |
13307 | if test -n "$OTOOL64"; then | |
13308 | ac_cv_prog_OTOOL64="$OTOOL64" # Let the user override the test. | |
13309 | else | |
13310 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13311 | for as_dir in $PATH | |
13312 | do | |
13313 | IFS=$as_save_IFS | |
13314 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13315 | for ac_exec_ext in '' $ac_executable_extensions; do |
13316 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13317 | ac_cv_prog_OTOOL64="${ac_tool_prefix}otool64" |
5213506e | 13318 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13319 | break 2 |
13320 | fi | |
13321 | done | |
5213506e RW |
13322 | done |
13323 | IFS=$as_save_IFS | |
5d47bb02 PG |
13324 | |
13325 | fi | |
13326 | fi | |
13327 | OTOOL64=$ac_cv_prog_OTOOL64 | |
13328 | if test -n "$OTOOL64"; then | |
5213506e RW |
13329 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL64" >&5 |
13330 | $as_echo "$OTOOL64" >&6; } | |
5d47bb02 | 13331 | else |
5213506e RW |
13332 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13333 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13334 | fi |
13335 | ||
5213506e | 13336 | |
5d47bb02 PG |
13337 | fi |
13338 | if test -z "$ac_cv_prog_OTOOL64"; then | |
13339 | ac_ct_OTOOL64=$OTOOL64 | |
13340 | # Extract the first word of "otool64", so it can be a program name with args. | |
13341 | set dummy otool64; ac_word=$2 | |
5213506e RW |
13342 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
13343 | $as_echo_n "checking for $ac_word... " >&6; } | |
13344 | if test "${ac_cv_prog_ac_ct_OTOOL64+set}" = set; then : | |
13345 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13346 | else |
13347 | if test -n "$ac_ct_OTOOL64"; then | |
13348 | ac_cv_prog_ac_ct_OTOOL64="$ac_ct_OTOOL64" # Let the user override the test. | |
13349 | else | |
13350 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
13351 | for as_dir in $PATH | |
13352 | do | |
13353 | IFS=$as_save_IFS | |
13354 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
13355 | for ac_exec_ext in '' $ac_executable_extensions; do |
13356 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
5d47bb02 | 13357 | ac_cv_prog_ac_ct_OTOOL64="otool64" |
5213506e | 13358 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
5d47bb02 PG |
13359 | break 2 |
13360 | fi | |
13361 | done | |
5213506e RW |
13362 | done |
13363 | IFS=$as_save_IFS | |
5d47bb02 | 13364 | |
5d47bb02 PG |
13365 | fi |
13366 | fi | |
13367 | ac_ct_OTOOL64=$ac_cv_prog_ac_ct_OTOOL64 | |
13368 | if test -n "$ac_ct_OTOOL64"; then | |
5213506e RW |
13369 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OTOOL64" >&5 |
13370 | $as_echo "$ac_ct_OTOOL64" >&6; } | |
5d47bb02 | 13371 | else |
5213506e RW |
13372 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13373 | $as_echo "no" >&6; } | |
5d47bb02 PG |
13374 | fi |
13375 | ||
5213506e RW |
13376 | if test "x$ac_ct_OTOOL64" = x; then |
13377 | OTOOL64=":" | |
13378 | else | |
13379 | case $cross_compiling:$ac_tool_warned in | |
13380 | yes:) | |
13381 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | |
13382 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | |
13383 | ac_tool_warned=yes ;; | |
13384 | esac | |
13385 | OTOOL64=$ac_ct_OTOOL64 | |
13386 | fi | |
5d47bb02 PG |
13387 | else |
13388 | OTOOL64="$ac_cv_prog_OTOOL64" | |
13389 | fi | |
13390 | ||
13391 | ||
13392 | ||
13393 | ||
13394 | ||
13395 | ||
13396 | ||
13397 | ||
13398 | ||
13399 | ||
13400 | ||
13401 | ||
13402 | ||
13403 | ||
13404 | ||
13405 | ||
13406 | ||
13407 | ||
13408 | ||
13409 | ||
13410 | ||
13411 | ||
13412 | ||
13413 | ||
13414 | ||
13415 | ||
13416 | ||
5213506e RW |
13417 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -single_module linker flag" >&5 |
13418 | $as_echo_n "checking for -single_module linker flag... " >&6; } | |
13419 | if test "${lt_cv_apple_cc_single_mod+set}" = set; then : | |
13420 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13421 | else |
13422 | lt_cv_apple_cc_single_mod=no | |
13423 | if test -z "${LT_MULTI_MODULE}"; then | |
13424 | # By default we will add the -single_module flag. You can override | |
13425 | # by either setting the environment variable LT_MULTI_MODULE | |
13426 | # non-empty at configure time, or by adding -multi_module to the | |
13427 | # link flags. | |
13428 | rm -rf libconftest.dylib* | |
13429 | echo "int foo(void){return 1;}" > conftest.c | |
13430 | echo "$LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ | |
13431 | -dynamiclib -Wl,-single_module conftest.c" >&5 | |
13432 | $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \ | |
13433 | -dynamiclib -Wl,-single_module conftest.c 2>conftest.err | |
13434 | _lt_result=$? | |
13435 | if test -f libconftest.dylib && test ! -s conftest.err && test $_lt_result = 0; then | |
13436 | lt_cv_apple_cc_single_mod=yes | |
13437 | else | |
13438 | cat conftest.err >&5 | |
13439 | fi | |
13440 | rm -rf libconftest.dylib* | |
13441 | rm -f conftest.* | |
13442 | fi | |
13443 | fi | |
5213506e RW |
13444 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_apple_cc_single_mod" >&5 |
13445 | $as_echo "$lt_cv_apple_cc_single_mod" >&6; } | |
13446 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -exported_symbols_list linker flag" >&5 | |
13447 | $as_echo_n "checking for -exported_symbols_list linker flag... " >&6; } | |
13448 | if test "${lt_cv_ld_exported_symbols_list+set}" = set; then : | |
13449 | $as_echo_n "(cached) " >&6 | |
5d47bb02 PG |
13450 | else |
13451 | lt_cv_ld_exported_symbols_list=no | |
13452 | save_LDFLAGS=$LDFLAGS | |
13453 | echo "_main" > conftest.sym | |
13454 | LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym" | |
5213506e | 13455 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
5d47bb02 PG |
13456 | /* end confdefs.h. */ |
13457 | ||
13458 | int | |
13459 | main () | |
13460 | { | |
13461 | ||
13462 | ; | |
13463 | return 0; | |
13464 | } | |
13465 | _ACEOF | |
5213506e | 13466 | if ac_fn_c_try_link "$LINENO"; then : |
5d47bb02 PG |
13467 | lt_cv_ld_exported_symbols_list=yes |
13468 | else | |
5213506e | 13469 | lt_cv_ld_exported_symbols_list=no |
5d47bb02 | 13470 | fi |
5213506e RW |
13471 | rm -f core conftest.err conftest.$ac_objext \ |
13472 | conftest$ac_exeext conftest.$ac_ext | |
5d47bb02 PG |
13473 | LDFLAGS="$save_LDFLAGS" |
13474 | ||
13475 | fi | |
5213506e RW |
13476 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_exported_symbols_list" >&5 |
13477 | $as_echo "$lt_cv_ld_exported_symbols_list" >&6; } | |
43e02a8a RW |
13478 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -force_load linker flag" >&5 |
13479 | $as_echo_n "checking for -force_load linker flag... " >&6; } | |
13480 | if test "${lt_cv_ld_force_load+set}" = set; then : | |
13481 | $as_echo_n "(cached) " >&6 | |
13482 | else | |
13483 | lt_cv_ld_force_load=no | |
13484 | cat > conftest.c << _LT_EOF | |
13485 | int forced_loaded() { return 2;} | |
13486 | _LT_EOF | |
13487 | echo "$LTCC $LTCFLAGS -c -o conftest.o conftest.c" >&5 | |
13488 | $LTCC $LTCFLAGS -c -o conftest.o conftest.c 2>&5 | |
13489 | echo "$AR cru libconftest.a conftest.o" >&5 | |
13490 | $AR cru libconftest.a conftest.o 2>&5 | |
13491 | cat > conftest.c << _LT_EOF | |
13492 | int main() { return 0;} | |
13493 | _LT_EOF | |
13494 | echo "$LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a" >&5 | |
13495 | $LTCC $LTCFLAGS $LDFLAGS -o conftest conftest.c -Wl,-force_load,./libconftest.a 2>conftest.err | |
13496 | _lt_result=$? | |
13497 | if test -f conftest && test ! -s conftest.err && test $_lt_result = 0 && $GREP forced_load conftest 2>&1 >/dev/null; then | |
13498 | lt_cv_ld_force_load=yes | |
13499 | else | |
13500 | cat conftest.err >&5 | |
13501 | fi | |
13502 | rm -f conftest.err libconftest.a conftest conftest.c | |
13503 | rm -rf conftest.dSYM | |
13504 | ||
13505 | fi | |
13506 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_ld_force_load" >&5 | |
13507 | $as_echo "$lt_cv_ld_force_load" >&6; } | |
5d47bb02 PG |
13508 | case $host_os in |
13509 | rhapsody* | darwin1.[012]) | |
13510 | _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;; | |
13511 | darwin1.*) | |
13512 | _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; | |
13513 | darwin*) # darwin 5.x on | |
13514 | # if running on 10.5 or later, the deployment target defaults | |
13515 | # to the OS version, if on x86, and 10.4, the deployment | |
13516 | # target defaults to 10.4. Don't you love it? | |
13517 | case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in | |
13518 | 10.0,*86*-darwin8*|10.0,*-darwin[91]*) | |
13519 | _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; | |
13520 | 10.[012]*) | |
13521 | _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;; | |
13522 | 10.*) | |
13523 | _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;; | |
13524 | esac | |
13525 | ;; | |
13526 | esac | |
13527 | if test "$lt_cv_apple_cc_single_mod" = "yes"; then | |
13528 | _lt_dar_single_mod='$single_module' | |
13529 | fi | |
13530 | if test "$lt_cv_ld_exported_symbols_list" = "yes"; then | |
13531 | _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym' | |
13532 | else | |
13533 | _lt_dar_export_syms='~$NMEDIT -s $output_objdir/${libname}-symbols.expsym ${lib}' | |
13534 | fi | |
43e02a8a | 13535 | if test "$DSYMUTIL" != ":" && test "$lt_cv_ld_force_load" = "no"; then |
5d47bb02 PG |
13536 | _lt_dsymutil='~$DSYMUTIL $lib || :' |
13537 | else | |
13538 | _lt_dsymutil= | |
13539 | fi | |
13540 | ;; | |
13541 | esac | |
da0f6381 | 13542 | |
da0f6381 | 13543 | for ac_header in dlfcn.h |
5213506e RW |
13544 | do : |
13545 | ac_fn_c_check_header_preproc "$LINENO" "dlfcn.h" "ac_cv_header_dlfcn_h" | |
13546 | if test "x$ac_cv_header_dlfcn_h" = x""yes; then : | |
da0f6381 | 13547 | cat >>confdefs.h <<_ACEOF |
5213506e | 13548 | #define HAVE_DLFCN_H 1 |
da0f6381 PB |
13549 | _ACEOF |
13550 | ||
13551 | fi | |
13552 | done | |
13553 | ||
13554 | ||
13555 | ||
5d47bb02 PG |
13556 | |
13557 | ||
5213506e | 13558 | |
43e02a8a | 13559 | # Set options |
5d47bb02 | 13560 | |
43e02a8a RW |
13561 | |
13562 | ||
13563 | enable_dlopen=no | |
13564 | ||
13565 | ||
13566 | enable_win32_dll=no | |
13567 | ||
13568 | ||
13569 | # Check whether --enable-shared was given. | |
13570 | if test "${enable_shared+set}" = set; then : | |
13571 | enableval=$enable_shared; p=${PACKAGE-default} | |
13572 | case $enableval in | |
13573 | yes) enable_shared=yes ;; | |
13574 | no) enable_shared=no ;; | |
13575 | *) | |
13576 | enable_shared=no | |
13577 | # Look at the argument we got. We use all the common list separators. | |
13578 | lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," | |
13579 | for pkg in $enableval; do | |
13580 | IFS="$lt_save_ifs" | |
13581 | if test "X$pkg" = "X$p"; then | |
13582 | enable_shared=yes | |
13583 | fi | |
13584 | done | |
13585 | IFS="$lt_save_ifs" | |
13586 | ;; | |
13587 | esac | |
5d47bb02 | 13588 | else |
43e02a8a | 13589 | enable_shared=yes |
5213506e RW |
13590 | fi |
13591 | ||
da0f6381 PB |
13592 | |
13593 | ||
13594 | ||
13595 | ||
13596 | ||
da0f6381 | 13597 | |
da0f6381 | 13598 | |
da0f6381 | 13599 | |
5213506e RW |
13600 | # Check whether --enable-static was given. |
13601 | if test "${enable_static+set}" = set; then : | |
13602 | enableval=$enable_static; p=${PACKAGE-default} | |
00020c16 ILT |
13603 | case $enableval in |
13604 | yes) enable_static=yes ;; | |
13605 | no) enable_static=no ;; | |
13606 | *) | |
13607 | enable_static=no | |
13608 | # Look at the argument we got. We use all the common list separators. | |
13609 | lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," | |
13610 | for pkg in $enableval; do | |
13611 | IFS="$lt_save_ifs" | |
13612 | if test "X$pkg" = "X$p"; then | |
13613 | enable_static=yes | |
13614 | fi | |
13615 | done | |
13616 | IFS="$lt_save_ifs" | |
13617 | ;; | |
13618 | esac | |
da0f6381 | 13619 | else |
00020c16 | 13620 | enable_static=yes |
5213506e | 13621 | fi |
da0f6381 PB |
13622 | |
13623 | ||
da0f6381 | 13624 | |
da0f6381 | 13625 | |
da0f6381 | 13626 | |
da0f6381 PB |
13627 | |
13628 | ||
da0f6381 | 13629 | |
da0f6381 | 13630 | |
5213506e RW |
13631 | |
13632 | # Check whether --with-pic was given. | |
13633 | if test "${with_pic+set}" = set; then : | |
13634 | withval=$with_pic; pic_mode="$withval" | |
00020c16 ILT |
13635 | else |
13636 | pic_mode=default | |
5213506e RW |
13637 | fi |
13638 | ||
da0f6381 | 13639 | |
00020c16 | 13640 | test -z "$pic_mode" && pic_mode=default |
da0f6381 PB |
13641 | |
13642 | ||
13643 | ||
13644 | ||
13645 | ||
13646 | ||
13647 | ||
5213506e RW |
13648 | # Check whether --enable-fast-install was given. |
13649 | if test "${enable_fast_install+set}" = set; then : | |
13650 | enableval=$enable_fast_install; p=${PACKAGE-default} | |
00020c16 ILT |
13651 | case $enableval in |
13652 | yes) enable_fast_install=yes ;; | |
13653 | no) enable_fast_install=no ;; | |
13654 | *) | |
13655 | enable_fast_install=no | |
13656 | # Look at the argument we got. We use all the common list separators. | |
13657 | lt_save_ifs="$IFS"; IFS="${IFS}$PATH_SEPARATOR," | |
13658 | for pkg in $enableval; do | |
13659 | IFS="$lt_save_ifs" | |
13660 | if test "X$pkg" = "X$p"; then | |
13661 | enable_fast_install=yes | |
13662 | fi | |
13663 | done | |
13664 | IFS="$lt_save_ifs" | |
13665 | ;; | |
13666 | esac | |
13667 | else | |
13668 | enable_fast_install=yes | |
5213506e RW |
13669 | fi |
13670 | ||
da0f6381 | 13671 | |
da0f6381 | 13672 | |
da0f6381 | 13673 | |
da0f6381 | 13674 | |
da0f6381 | 13675 | |
da0f6381 PB |
13676 | |
13677 | ||
da0f6381 | 13678 | |
da0f6381 | 13679 | |
da0f6381 | 13680 | |
00020c16 ILT |
13681 | # This can be used to rebuild libtool when needed |
13682 | LIBTOOL_DEPS="$ltmain" | |
da0f6381 | 13683 | |
00020c16 ILT |
13684 | # Always use our own libtool. |
13685 | LIBTOOL='$(SHELL) $(top_builddir)/libtool' | |
da0f6381 | 13686 | |
da0f6381 | 13687 | |
da0f6381 PB |
13688 | |
13689 | ||
13690 | ||
13691 | ||
13692 | ||
13693 | ||
da0f6381 | 13694 | |
da0f6381 | 13695 | |
da0f6381 | 13696 | |
da0f6381 | 13697 | |
da0f6381 | 13698 | |
da0f6381 | 13699 | |
da0f6381 | 13700 | |
da0f6381 | 13701 | |
da0f6381 | 13702 | |
da0f6381 | 13703 | |
da0f6381 | 13704 | |
da0f6381 | 13705 | |
da0f6381 | 13706 | |
da0f6381 | 13707 | |
da0f6381 | 13708 | |
43e02a8a | 13709 | |
da0f6381 | 13710 | |
da0f6381 | 13711 | |
00020c16 | 13712 | test -z "$LN_S" && LN_S="ln -s" |
da0f6381 | 13713 | |
da0f6381 | 13714 | |
da0f6381 | 13715 | |
da0f6381 | 13716 | |
da0f6381 | 13717 | |
da0f6381 | 13718 | |
da0f6381 | 13719 | |
da0f6381 | 13720 | |
da0f6381 | 13721 | |
da0f6381 | 13722 | |
da0f6381 | 13723 | |
da0f6381 | 13724 | |
da0f6381 | 13725 | |
da0f6381 | 13726 | |
00020c16 ILT |
13727 | if test -n "${ZSH_VERSION+set}" ; then |
13728 | setopt NO_GLOB_SUBST | |
13729 | fi | |
da0f6381 | 13730 | |
5213506e RW |
13731 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for objdir" >&5 |
13732 | $as_echo_n "checking for objdir... " >&6; } | |
13733 | if test "${lt_cv_objdir+set}" = set; then : | |
13734 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
13735 | else |
13736 | rm -f .libs 2>/dev/null | |
13737 | mkdir .libs 2>/dev/null | |
13738 | if test -d .libs; then | |
13739 | lt_cv_objdir=.libs | |
13740 | else | |
13741 | # MS-DOS does not allow filenames that begin with a dot. | |
13742 | lt_cv_objdir=_libs | |
13743 | fi | |
13744 | rmdir .libs 2>/dev/null | |
13745 | fi | |
5213506e RW |
13746 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_objdir" >&5 |
13747 | $as_echo "$lt_cv_objdir" >&6; } | |
00020c16 | 13748 | objdir=$lt_cv_objdir |
da0f6381 PB |
13749 | |
13750 | ||
13751 | ||
13752 | ||
da0f6381 | 13753 | |
00020c16 ILT |
13754 | cat >>confdefs.h <<_ACEOF |
13755 | #define LT_OBJDIR "$lt_cv_objdir/" | |
13756 | _ACEOF | |
da0f6381 | 13757 | |
da0f6381 | 13758 | |
da0f6381 PB |
13759 | |
13760 | ||
00020c16 ILT |
13761 | case $host_os in |
13762 | aix3*) | |
13763 | # AIX sometimes has problems with the GCC collect2 program. For some | |
13764 | # reason, if we set the COLLECT_NAMES environment variable, the problems | |
13765 | # vanish in a puff of smoke. | |
13766 | if test "X${COLLECT_NAMES+set}" != Xset; then | |
13767 | COLLECT_NAMES= | |
13768 | export COLLECT_NAMES | |
13769 | fi | |
13770 | ;; | |
13771 | esac | |
da0f6381 | 13772 | |
00020c16 ILT |
13773 | # Global variables: |
13774 | ofile=libtool | |
13775 | can_build_shared=yes | |
da0f6381 | 13776 | |
00020c16 ILT |
13777 | # All known linkers require a `.a' archive for static linking (except MSVC, |
13778 | # which needs '.lib'). | |
13779 | libext=a | |
da0f6381 | 13780 | |
00020c16 | 13781 | with_gnu_ld="$lt_cv_prog_gnu_ld" |
da0f6381 | 13782 | |
00020c16 ILT |
13783 | old_CC="$CC" |
13784 | old_CFLAGS="$CFLAGS" | |
da0f6381 | 13785 | |
00020c16 ILT |
13786 | # Set sane defaults for various variables |
13787 | test -z "$CC" && CC=cc | |
13788 | test -z "$LTCC" && LTCC=$CC | |
13789 | test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS | |
13790 | test -z "$LD" && LD=ld | |
13791 | test -z "$ac_objext" && ac_objext=o | |
da0f6381 | 13792 | |
00020c16 ILT |
13793 | for cc_temp in $compiler""; do |
13794 | case $cc_temp in | |
13795 | compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; | |
13796 | distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; | |
13797 | \-*) ;; | |
13798 | *) break;; | |
13799 | esac | |
13800 | done | |
43e02a8a | 13801 | cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` |
da0f6381 PB |
13802 | |
13803 | ||
00020c16 ILT |
13804 | # Only perform the check for file, if the check method requires it |
13805 | test -z "$MAGIC_CMD" && MAGIC_CMD=file | |
13806 | case $deplibs_check_method in | |
13807 | file_magic*) | |
13808 | if test "$file_magic_cmd" = '$MAGIC_CMD'; then | |
5213506e RW |
13809 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ${ac_tool_prefix}file" >&5 |
13810 | $as_echo_n "checking for ${ac_tool_prefix}file... " >&6; } | |
13811 | if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : | |
13812 | $as_echo_n "(cached) " >&6 | |
da0f6381 | 13813 | else |
00020c16 ILT |
13814 | case $MAGIC_CMD in |
13815 | [\\/*] | ?:[\\/]*) | |
13816 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. | |
13817 | ;; | |
13818 | *) | |
13819 | lt_save_MAGIC_CMD="$MAGIC_CMD" | |
13820 | lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR | |
13821 | ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" | |
13822 | for ac_dir in $ac_dummy; do | |
13823 | IFS="$lt_save_ifs" | |
13824 | test -z "$ac_dir" && ac_dir=. | |
13825 | if test -f $ac_dir/${ac_tool_prefix}file; then | |
13826 | lt_cv_path_MAGIC_CMD="$ac_dir/${ac_tool_prefix}file" | |
13827 | if test -n "$file_magic_test_file"; then | |
13828 | case $deplibs_check_method in | |
13829 | "file_magic "*) | |
13830 | file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` | |
13831 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" | |
13832 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | | |
13833 | $EGREP "$file_magic_regex" > /dev/null; then | |
13834 | : | |
13835 | else | |
13836 | cat <<_LT_EOF 1>&2 | |
da0f6381 | 13837 | |
00020c16 ILT |
13838 | *** Warning: the command libtool uses to detect shared libraries, |
13839 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
13840 | *** The result is that libtool may fail to recognize shared libraries | |
13841 | *** as such. This will affect the creation of libtool libraries that | |
13842 | *** depend on shared libraries, but programs linked with such libtool | |
13843 | *** libraries will work regardless of this problem. Nevertheless, you | |
13844 | *** may want to report the problem to your system manager and/or to | |
13845 | *** bug-libtool@gnu.org | |
da0f6381 | 13846 | |
00020c16 ILT |
13847 | _LT_EOF |
13848 | fi ;; | |
13849 | esac | |
13850 | fi | |
13851 | break | |
13852 | fi | |
13853 | done | |
13854 | IFS="$lt_save_ifs" | |
13855 | MAGIC_CMD="$lt_save_MAGIC_CMD" | |
13856 | ;; | |
13857 | esac | |
13858 | fi | |
da0f6381 | 13859 | |
00020c16 ILT |
13860 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
13861 | if test -n "$MAGIC_CMD"; then | |
5213506e RW |
13862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 |
13863 | $as_echo "$MAGIC_CMD" >&6; } | |
00020c16 | 13864 | else |
5213506e RW |
13865 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13866 | $as_echo "no" >&6; } | |
00020c16 | 13867 | fi |
da0f6381 PB |
13868 | |
13869 | ||
13870 | ||
da0f6381 | 13871 | |
da0f6381 | 13872 | |
00020c16 ILT |
13873 | if test -z "$lt_cv_path_MAGIC_CMD"; then |
13874 | if test -n "$ac_tool_prefix"; then | |
5213506e RW |
13875 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for file" >&5 |
13876 | $as_echo_n "checking for file... " >&6; } | |
13877 | if test "${lt_cv_path_MAGIC_CMD+set}" = set; then : | |
13878 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
13879 | else |
13880 | case $MAGIC_CMD in | |
13881 | [\\/*] | ?:[\\/]*) | |
13882 | lt_cv_path_MAGIC_CMD="$MAGIC_CMD" # Let the user override the test with a path. | |
13883 | ;; | |
13884 | *) | |
13885 | lt_save_MAGIC_CMD="$MAGIC_CMD" | |
13886 | lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR | |
13887 | ac_dummy="/usr/bin$PATH_SEPARATOR$PATH" | |
13888 | for ac_dir in $ac_dummy; do | |
13889 | IFS="$lt_save_ifs" | |
13890 | test -z "$ac_dir" && ac_dir=. | |
13891 | if test -f $ac_dir/file; then | |
13892 | lt_cv_path_MAGIC_CMD="$ac_dir/file" | |
13893 | if test -n "$file_magic_test_file"; then | |
13894 | case $deplibs_check_method in | |
13895 | "file_magic "*) | |
13896 | file_magic_regex=`expr "$deplibs_check_method" : "file_magic \(.*\)"` | |
13897 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" | |
13898 | if eval $file_magic_cmd \$file_magic_test_file 2> /dev/null | | |
13899 | $EGREP "$file_magic_regex" > /dev/null; then | |
13900 | : | |
13901 | else | |
13902 | cat <<_LT_EOF 1>&2 | |
da0f6381 | 13903 | |
00020c16 ILT |
13904 | *** Warning: the command libtool uses to detect shared libraries, |
13905 | *** $file_magic_cmd, produces output that libtool cannot recognize. | |
13906 | *** The result is that libtool may fail to recognize shared libraries | |
13907 | *** as such. This will affect the creation of libtool libraries that | |
13908 | *** depend on shared libraries, but programs linked with such libtool | |
13909 | *** libraries will work regardless of this problem. Nevertheless, you | |
13910 | *** may want to report the problem to your system manager and/or to | |
13911 | *** bug-libtool@gnu.org | |
da0f6381 | 13912 | |
00020c16 ILT |
13913 | _LT_EOF |
13914 | fi ;; | |
13915 | esac | |
13916 | fi | |
13917 | break | |
da0f6381 | 13918 | fi |
00020c16 ILT |
13919 | done |
13920 | IFS="$lt_save_ifs" | |
13921 | MAGIC_CMD="$lt_save_MAGIC_CMD" | |
13922 | ;; | |
13923 | esac | |
13924 | fi | |
da0f6381 | 13925 | |
00020c16 ILT |
13926 | MAGIC_CMD="$lt_cv_path_MAGIC_CMD" |
13927 | if test -n "$MAGIC_CMD"; then | |
5213506e RW |
13928 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAGIC_CMD" >&5 |
13929 | $as_echo "$MAGIC_CMD" >&6; } | |
00020c16 | 13930 | else |
5213506e RW |
13931 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
13932 | $as_echo "no" >&6; } | |
00020c16 | 13933 | fi |
da0f6381 | 13934 | |
da0f6381 | 13935 | |
00020c16 ILT |
13936 | else |
13937 | MAGIC_CMD=: | |
13938 | fi | |
13939 | fi | |
da0f6381 | 13940 | |
00020c16 ILT |
13941 | fi |
13942 | ;; | |
13943 | esac | |
da0f6381 | 13944 | |
00020c16 | 13945 | # Use C for the default configuration in the libtool script |
da0f6381 | 13946 | |
00020c16 ILT |
13947 | lt_save_CC="$CC" |
13948 | ac_ext=c | |
13949 | ac_cpp='$CPP $CPPFLAGS' | |
13950 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
13951 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
13952 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
da0f6381 | 13953 | |
da0f6381 | 13954 | |
00020c16 ILT |
13955 | # Source file extension for C test sources. |
13956 | ac_ext=c | |
da0f6381 | 13957 | |
00020c16 ILT |
13958 | # Object file extension for compiled C test sources. |
13959 | objext=o | |
13960 | objext=$objext | |
da0f6381 | 13961 | |
00020c16 ILT |
13962 | # Code to be used in simple compile tests |
13963 | lt_simple_compile_test_code="int some_variable = 0;" | |
5d47bb02 | 13964 | |
00020c16 ILT |
13965 | # Code to be used in simple link tests |
13966 | lt_simple_link_test_code='int main(){return(0);}' | |
da0f6381 | 13967 | |
da0f6381 | 13968 | |
da0f6381 | 13969 | |
da0f6381 | 13970 | |
00020c16 ILT |
13971 | |
13972 | ||
13973 | ||
13974 | # If no C compiler was specified, use CC. | |
13975 | LTCC=${LTCC-"$CC"} | |
13976 | ||
13977 | # If no C compiler flags were specified, use CFLAGS. | |
13978 | LTCFLAGS=${LTCFLAGS-"$CFLAGS"} | |
13979 | ||
13980 | # Allow CC to be a program name with arguments. | |
13981 | compiler=$CC | |
13982 | ||
13983 | # Save the default compiler, since it gets overwritten when the other | |
13984 | # tags are being tested, and _LT_TAGVAR(compiler, []) is a NOP. | |
13985 | compiler_DEFAULT=$CC | |
13986 | ||
13987 | # save warnings/boilerplate of simple test code | |
13988 | ac_outfile=conftest.$ac_objext | |
13989 | echo "$lt_simple_compile_test_code" >conftest.$ac_ext | |
13990 | eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err | |
13991 | _lt_compiler_boilerplate=`cat conftest.err` | |
13992 | $RM conftest* | |
13993 | ||
13994 | ac_outfile=conftest.$ac_objext | |
13995 | echo "$lt_simple_link_test_code" >conftest.$ac_ext | |
13996 | eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err | |
13997 | _lt_linker_boilerplate=`cat conftest.err` | |
13998 | $RM -r conftest* | |
13999 | ||
14000 | ||
14001 | ## CAVEAT EMPTOR: | |
14002 | ## There is no encapsulation within the following macros, do not change | |
14003 | ## the running order or otherwise move them around unless you know exactly | |
14004 | ## what you are doing... | |
14005 | if test -n "$compiler"; then | |
14006 | ||
14007 | lt_prog_compiler_no_builtin_flag= | |
14008 | ||
14009 | if test "$GCC" = yes; then | |
43e02a8a RW |
14010 | case $cc_basename in |
14011 | nvcc*) | |
14012 | lt_prog_compiler_no_builtin_flag=' -Xcompiler -fno-builtin' ;; | |
14013 | *) | |
14014 | lt_prog_compiler_no_builtin_flag=' -fno-builtin' ;; | |
14015 | esac | |
00020c16 | 14016 | |
5213506e RW |
14017 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -fno-rtti -fno-exceptions" >&5 |
14018 | $as_echo_n "checking if $compiler supports -fno-rtti -fno-exceptions... " >&6; } | |
14019 | if test "${lt_cv_prog_compiler_rtti_exceptions+set}" = set; then : | |
14020 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
14021 | else |
14022 | lt_cv_prog_compiler_rtti_exceptions=no | |
14023 | ac_outfile=conftest.$ac_objext | |
14024 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
14025 | lt_compiler_flag="-fno-rtti -fno-exceptions" | |
14026 | # Insert the option either (1) after the last *FLAGS variable, or | |
14027 | # (2) before a word containing "conftest.", or (3) at the end. | |
14028 | # Note that $ac_compile itself does not contain backslashes and begins | |
14029 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
14030 | # The option is referenced via a variable to avoid confusing sed. | |
14031 | lt_compile=`echo "$ac_compile" | $SED \ | |
14032 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
14033 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
14034 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 14035 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
14036 | (eval "$lt_compile" 2>conftest.err) |
14037 | ac_status=$? | |
14038 | cat conftest.err >&5 | |
43e02a8a | 14039 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
14040 | if (exit $ac_status) && test -s "$ac_outfile"; then |
14041 | # The compiler can only warn and ignore the option if not recognized | |
14042 | # So say no if there are warnings other than the usual output. | |
43e02a8a | 14043 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp |
00020c16 ILT |
14044 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
14045 | if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then | |
14046 | lt_cv_prog_compiler_rtti_exceptions=yes | |
14047 | fi | |
14048 | fi | |
14049 | $RM conftest* | |
14050 | ||
14051 | fi | |
5213506e RW |
14052 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_rtti_exceptions" >&5 |
14053 | $as_echo "$lt_cv_prog_compiler_rtti_exceptions" >&6; } | |
00020c16 ILT |
14054 | |
14055 | if test x"$lt_cv_prog_compiler_rtti_exceptions" = xyes; then | |
14056 | lt_prog_compiler_no_builtin_flag="$lt_prog_compiler_no_builtin_flag -fno-rtti -fno-exceptions" | |
14057 | else | |
14058 | : | |
14059 | fi | |
14060 | ||
14061 | fi | |
14062 | ||
14063 | ||
14064 | ||
14065 | ||
14066 | ||
14067 | ||
14068 | lt_prog_compiler_wl= | |
14069 | lt_prog_compiler_pic= | |
14070 | lt_prog_compiler_static= | |
14071 | ||
5213506e RW |
14072 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 |
14073 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
00020c16 ILT |
14074 | |
14075 | if test "$GCC" = yes; then | |
14076 | lt_prog_compiler_wl='-Wl,' | |
14077 | lt_prog_compiler_static='-static' | |
14078 | ||
14079 | case $host_os in | |
14080 | aix*) | |
14081 | # All AIX code is PIC. | |
14082 | if test "$host_cpu" = ia64; then | |
14083 | # AIX 5 now supports IA64 processor | |
14084 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 PB |
14085 | fi |
14086 | ;; | |
14087 | ||
00020c16 ILT |
14088 | amigaos*) |
14089 | case $host_cpu in | |
14090 | powerpc) | |
14091 | # see comment about AmigaOS4 .so support | |
14092 | lt_prog_compiler_pic='-fPIC' | |
14093 | ;; | |
14094 | m68k) | |
14095 | # FIXME: we need at least 68020 code to build shared libraries, but | |
14096 | # adding the `-m68020' flag to GCC prevents building anything better, | |
14097 | # like `-m68040'. | |
14098 | lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4' | |
14099 | ;; | |
14100 | esac | |
14101 | ;; | |
da0f6381 | 14102 | |
00020c16 ILT |
14103 | beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) |
14104 | # PIC is the default for these OSes. | |
14105 | ;; | |
da0f6381 | 14106 | |
00020c16 ILT |
14107 | mingw* | cygwin* | pw32* | os2* | cegcc*) |
14108 | # This hack is so that the source file can tell whether it is being | |
14109 | # built for inclusion in a dll (and should export symbols for example). | |
14110 | # Although the cygwin gcc ignores -fPIC, still need this for old-style | |
14111 | # (--disable-auto-import) libraries | |
14112 | lt_prog_compiler_pic='-DDLL_EXPORT' | |
14113 | ;; | |
14114 | ||
14115 | darwin* | rhapsody*) | |
14116 | # PIC is the default on this platform | |
14117 | # Common symbols not allowed in MH_DYLIB files | |
14118 | lt_prog_compiler_pic='-fno-common' | |
14119 | ;; | |
14120 | ||
43e02a8a RW |
14121 | haiku*) |
14122 | # PIC is the default for Haiku. | |
14123 | # The "-static" flag exists, but is broken. | |
14124 | lt_prog_compiler_static= | |
14125 | ;; | |
14126 | ||
00020c16 ILT |
14127 | hpux*) |
14128 | # PIC is the default for 64-bit PA HP-UX, but not for 32-bit | |
14129 | # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag | |
14130 | # sets the default TLS model and affects inlining. | |
14131 | case $host_cpu in | |
14132 | hppa*64*) | |
14133 | # +Z the default | |
da0f6381 | 14134 | ;; |
00020c16 ILT |
14135 | *) |
14136 | lt_prog_compiler_pic='-fPIC' | |
da0f6381 PB |
14137 | ;; |
14138 | esac | |
14139 | ;; | |
14140 | ||
00020c16 ILT |
14141 | interix[3-9]*) |
14142 | # Interix 3.x gcc -fpic/-fPIC options generate broken code. | |
14143 | # Instead, we relocate shared libraries at runtime. | |
da0f6381 PB |
14144 | ;; |
14145 | ||
00020c16 ILT |
14146 | msdosdjgpp*) |
14147 | # Just because we use GCC doesn't mean we suddenly get shared libraries | |
14148 | # on systems that don't support them. | |
14149 | lt_prog_compiler_can_build_shared=no | |
14150 | enable_shared=no | |
da0f6381 | 14151 | ;; |
da0f6381 | 14152 | |
00020c16 ILT |
14153 | *nto* | *qnx*) |
14154 | # QNX uses GNU C++, but need to define -shared option too, otherwise | |
14155 | # it will coredump. | |
14156 | lt_prog_compiler_pic='-fPIC -shared' | |
14157 | ;; | |
14158 | ||
14159 | sysv4*MP*) | |
14160 | if test -d /usr/nec; then | |
14161 | lt_prog_compiler_pic=-Kconform_pic | |
da0f6381 PB |
14162 | fi |
14163 | ;; | |
14164 | ||
43e02a8a RW |
14165 | *) |
14166 | lt_prog_compiler_pic='-fPIC' | |
14167 | ;; | |
14168 | esac | |
14169 | ||
14170 | case $cc_basename in | |
14171 | nvcc*) # Cuda Compiler Driver 2.2 | |
14172 | lt_prog_compiler_wl='-Xlinker ' | |
14173 | lt_prog_compiler_pic='-Xcompiler -fPIC' | |
00020c16 ILT |
14174 | ;; |
14175 | esac | |
14176 | else | |
14177 | # PORTME Check for flag to pass linker flags through the system compiler. | |
14178 | case $host_os in | |
14179 | aix*) | |
14180 | lt_prog_compiler_wl='-Wl,' | |
da0f6381 | 14181 | if test "$host_cpu" = ia64; then |
00020c16 ILT |
14182 | # AIX 5 now supports IA64 processor |
14183 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 | 14184 | else |
00020c16 | 14185 | lt_prog_compiler_static='-bnso -bI:/lib/syscalls.exp' |
da0f6381 | 14186 | fi |
00020c16 | 14187 | ;; |
da0f6381 | 14188 | |
00020c16 ILT |
14189 | mingw* | cygwin* | pw32* | os2* | cegcc*) |
14190 | # This hack is so that the source file can tell whether it is being | |
14191 | # built for inclusion in a dll (and should export symbols for example). | |
14192 | lt_prog_compiler_pic='-DDLL_EXPORT' | |
14193 | ;; | |
da0f6381 | 14194 | |
00020c16 ILT |
14195 | hpux9* | hpux10* | hpux11*) |
14196 | lt_prog_compiler_wl='-Wl,' | |
14197 | # PIC is the default for IA64 HP-UX and 64-bit HP-UX, but | |
14198 | # not for PA HP-UX. | |
14199 | case $host_cpu in | |
14200 | hppa*64*|ia64*) | |
14201 | # +Z the default | |
14202 | ;; | |
14203 | *) | |
14204 | lt_prog_compiler_pic='+Z' | |
14205 | ;; | |
14206 | esac | |
14207 | # Is there a better lt_prog_compiler_static that works with the bundled CC? | |
14208 | lt_prog_compiler_static='${wl}-a ${wl}archive' | |
14209 | ;; | |
da0f6381 | 14210 | |
00020c16 ILT |
14211 | irix5* | irix6* | nonstopux*) |
14212 | lt_prog_compiler_wl='-Wl,' | |
14213 | # PIC (with -KPIC) is the default. | |
14214 | lt_prog_compiler_static='-non_shared' | |
14215 | ;; | |
14216 | ||
14217 | linux* | k*bsd*-gnu | kopensolaris*-gnu) | |
14218 | case $cc_basename in | |
14219 | # old Intel for x86_64 which still supported -KPIC. | |
14220 | ecc*) | |
14221 | lt_prog_compiler_wl='-Wl,' | |
14222 | lt_prog_compiler_pic='-KPIC' | |
14223 | lt_prog_compiler_static='-static' | |
14224 | ;; | |
14225 | # icc used to be incompatible with GCC. | |
14226 | # ICC 10 doesn't accept -KPIC any more. | |
14227 | icc* | ifort*) | |
14228 | lt_prog_compiler_wl='-Wl,' | |
14229 | lt_prog_compiler_pic='-fPIC' | |
14230 | lt_prog_compiler_static='-static' | |
14231 | ;; | |
14232 | # Lahey Fortran 8.1. | |
14233 | lf95*) | |
14234 | lt_prog_compiler_wl='-Wl,' | |
14235 | lt_prog_compiler_pic='--shared' | |
14236 | lt_prog_compiler_static='--static' | |
14237 | ;; | |
43e02a8a | 14238 | pgcc* | pgf77* | pgf90* | pgf95* | pgfortran*) |
00020c16 ILT |
14239 | # Portland Group compilers (*not* the Pentium gcc compiler, |
14240 | # which looks to be a dead project) | |
14241 | lt_prog_compiler_wl='-Wl,' | |
14242 | lt_prog_compiler_pic='-fpic' | |
14243 | lt_prog_compiler_static='-Bstatic' | |
14244 | ;; | |
14245 | ccc*) | |
14246 | lt_prog_compiler_wl='-Wl,' | |
14247 | # All Alpha code is PIC. | |
14248 | lt_prog_compiler_static='-non_shared' | |
14249 | ;; | |
43e02a8a RW |
14250 | xl* | bgxl* | bgf* | mpixl*) |
14251 | # IBM XL C 8.0/Fortran 10.1, 11.1 on PPC and BlueGene | |
00020c16 ILT |
14252 | lt_prog_compiler_wl='-Wl,' |
14253 | lt_prog_compiler_pic='-qpic' | |
14254 | lt_prog_compiler_static='-qstaticlink' | |
14255 | ;; | |
14256 | *) | |
14257 | case `$CC -V 2>&1 | sed 5q` in | |
43e02a8a RW |
14258 | *Sun\ F* | *Sun*Fortran*) |
14259 | # Sun Fortran 8.3 passes all unrecognized flags to the linker | |
00020c16 ILT |
14260 | lt_prog_compiler_pic='-KPIC' |
14261 | lt_prog_compiler_static='-Bstatic' | |
43e02a8a | 14262 | lt_prog_compiler_wl='' |
00020c16 | 14263 | ;; |
43e02a8a RW |
14264 | *Sun\ C*) |
14265 | # Sun C 5.9 | |
00020c16 ILT |
14266 | lt_prog_compiler_pic='-KPIC' |
14267 | lt_prog_compiler_static='-Bstatic' | |
43e02a8a | 14268 | lt_prog_compiler_wl='-Wl,' |
da0f6381 PB |
14269 | ;; |
14270 | esac | |
00020c16 ILT |
14271 | ;; |
14272 | esac | |
14273 | ;; | |
da0f6381 | 14274 | |
00020c16 ILT |
14275 | newsos6) |
14276 | lt_prog_compiler_pic='-KPIC' | |
14277 | lt_prog_compiler_static='-Bstatic' | |
14278 | ;; | |
da0f6381 | 14279 | |
00020c16 ILT |
14280 | *nto* | *qnx*) |
14281 | # QNX uses GNU C++, but need to define -shared option too, otherwise | |
14282 | # it will coredump. | |
14283 | lt_prog_compiler_pic='-fPIC -shared' | |
14284 | ;; | |
da0f6381 | 14285 | |
00020c16 ILT |
14286 | osf3* | osf4* | osf5*) |
14287 | lt_prog_compiler_wl='-Wl,' | |
14288 | # All OSF/1 code is PIC. | |
14289 | lt_prog_compiler_static='-non_shared' | |
14290 | ;; | |
da0f6381 | 14291 | |
00020c16 ILT |
14292 | rdos*) |
14293 | lt_prog_compiler_static='-non_shared' | |
da0f6381 PB |
14294 | ;; |
14295 | ||
00020c16 ILT |
14296 | solaris*) |
14297 | lt_prog_compiler_pic='-KPIC' | |
14298 | lt_prog_compiler_static='-Bstatic' | |
14299 | case $cc_basename in | |
14300 | f77* | f90* | f95*) | |
14301 | lt_prog_compiler_wl='-Qoption ld ';; | |
14302 | *) | |
14303 | lt_prog_compiler_wl='-Wl,';; | |
5d47bb02 | 14304 | esac |
da0f6381 PB |
14305 | ;; |
14306 | ||
00020c16 ILT |
14307 | sunos4*) |
14308 | lt_prog_compiler_wl='-Qoption ld ' | |
14309 | lt_prog_compiler_pic='-PIC' | |
14310 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 PB |
14311 | ;; |
14312 | ||
00020c16 ILT |
14313 | sysv4 | sysv4.2uw2* | sysv4.3*) |
14314 | lt_prog_compiler_wl='-Wl,' | |
14315 | lt_prog_compiler_pic='-KPIC' | |
14316 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 PB |
14317 | ;; |
14318 | ||
00020c16 ILT |
14319 | sysv4*MP*) |
14320 | if test -d /usr/nec ;then | |
14321 | lt_prog_compiler_pic='-Kconform_pic' | |
14322 | lt_prog_compiler_static='-Bstatic' | |
14323 | fi | |
da0f6381 PB |
14324 | ;; |
14325 | ||
00020c16 ILT |
14326 | sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) |
14327 | lt_prog_compiler_wl='-Wl,' | |
14328 | lt_prog_compiler_pic='-KPIC' | |
14329 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 PB |
14330 | ;; |
14331 | ||
00020c16 ILT |
14332 | unicos*) |
14333 | lt_prog_compiler_wl='-Wl,' | |
14334 | lt_prog_compiler_can_build_shared=no | |
da0f6381 PB |
14335 | ;; |
14336 | ||
00020c16 ILT |
14337 | uts4*) |
14338 | lt_prog_compiler_pic='-pic' | |
14339 | lt_prog_compiler_static='-Bstatic' | |
da0f6381 PB |
14340 | ;; |
14341 | ||
00020c16 ILT |
14342 | *) |
14343 | lt_prog_compiler_can_build_shared=no | |
da0f6381 | 14344 | ;; |
00020c16 ILT |
14345 | esac |
14346 | fi | |
da0f6381 | 14347 | |
00020c16 ILT |
14348 | case $host_os in |
14349 | # For platforms which do not support PIC, -DPIC is meaningless: | |
14350 | *djgpp*) | |
14351 | lt_prog_compiler_pic= | |
14352 | ;; | |
14353 | *) | |
14354 | lt_prog_compiler_pic="$lt_prog_compiler_pic -DPIC" | |
14355 | ;; | |
14356 | esac | |
5213506e RW |
14357 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic" >&5 |
14358 | $as_echo "$lt_prog_compiler_pic" >&6; } | |
da0f6381 | 14359 | |
da0f6381 | 14360 | |
da0f6381 | 14361 | |
da0f6381 | 14362 | |
da0f6381 | 14363 | |
da0f6381 | 14364 | |
00020c16 ILT |
14365 | # |
14366 | # Check to make sure the PIC flag actually works. | |
14367 | # | |
14368 | if test -n "$lt_prog_compiler_pic"; then | |
5213506e RW |
14369 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5 |
14370 | $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic works... " >&6; } | |
14371 | if test "${lt_cv_prog_compiler_pic_works+set}" = set; then : | |
14372 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
14373 | else |
14374 | lt_cv_prog_compiler_pic_works=no | |
14375 | ac_outfile=conftest.$ac_objext | |
14376 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
14377 | lt_compiler_flag="$lt_prog_compiler_pic -DPIC" | |
14378 | # Insert the option either (1) after the last *FLAGS variable, or | |
14379 | # (2) before a word containing "conftest.", or (3) at the end. | |
14380 | # Note that $ac_compile itself does not contain backslashes and begins | |
14381 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
14382 | # The option is referenced via a variable to avoid confusing sed. | |
14383 | lt_compile=`echo "$ac_compile" | $SED \ | |
14384 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
14385 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
14386 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 14387 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
14388 | (eval "$lt_compile" 2>conftest.err) |
14389 | ac_status=$? | |
14390 | cat conftest.err >&5 | |
43e02a8a | 14391 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
14392 | if (exit $ac_status) && test -s "$ac_outfile"; then |
14393 | # The compiler can only warn and ignore the option if not recognized | |
14394 | # So say no if there are warnings other than the usual output. | |
43e02a8a | 14395 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp |
00020c16 ILT |
14396 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
14397 | if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then | |
14398 | lt_cv_prog_compiler_pic_works=yes | |
14399 | fi | |
14400 | fi | |
14401 | $RM conftest* | |
da0f6381 | 14402 | |
00020c16 | 14403 | fi |
5213506e RW |
14404 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works" >&5 |
14405 | $as_echo "$lt_cv_prog_compiler_pic_works" >&6; } | |
da0f6381 | 14406 | |
00020c16 ILT |
14407 | if test x"$lt_cv_prog_compiler_pic_works" = xyes; then |
14408 | case $lt_prog_compiler_pic in | |
14409 | "" | " "*) ;; | |
14410 | *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;; | |
14411 | esac | |
da0f6381 | 14412 | else |
00020c16 ILT |
14413 | lt_prog_compiler_pic= |
14414 | lt_prog_compiler_can_build_shared=no | |
da0f6381 | 14415 | fi |
da0f6381 | 14416 | |
00020c16 | 14417 | fi |
da0f6381 | 14418 | |
da0f6381 | 14419 | |
da0f6381 | 14420 | |
da0f6381 | 14421 | |
da0f6381 | 14422 | |
da0f6381 | 14423 | |
00020c16 ILT |
14424 | # |
14425 | # Check to make sure the static flag actually works. | |
14426 | # | |
14427 | wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\" | |
5213506e RW |
14428 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 |
14429 | $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } | |
14430 | if test "${lt_cv_prog_compiler_static_works+set}" = set; then : | |
14431 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
14432 | else |
14433 | lt_cv_prog_compiler_static_works=no | |
14434 | save_LDFLAGS="$LDFLAGS" | |
14435 | LDFLAGS="$LDFLAGS $lt_tmp_static_flag" | |
14436 | echo "$lt_simple_link_test_code" > conftest.$ac_ext | |
14437 | if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then | |
14438 | # The linker can only warn and ignore the option if not recognized | |
14439 | # So say no if there are warnings | |
14440 | if test -s conftest.err; then | |
14441 | # Append any errors to the config.log. | |
14442 | cat conftest.err 1>&5 | |
43e02a8a | 14443 | $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp |
00020c16 ILT |
14444 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
14445 | if diff conftest.exp conftest.er2 >/dev/null; then | |
14446 | lt_cv_prog_compiler_static_works=yes | |
14447 | fi | |
14448 | else | |
14449 | lt_cv_prog_compiler_static_works=yes | |
14450 | fi | |
14451 | fi | |
14452 | $RM -r conftest* | |
14453 | LDFLAGS="$save_LDFLAGS" | |
da0f6381 | 14454 | |
00020c16 | 14455 | fi |
5213506e RW |
14456 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works" >&5 |
14457 | $as_echo "$lt_cv_prog_compiler_static_works" >&6; } | |
da0f6381 | 14458 | |
00020c16 ILT |
14459 | if test x"$lt_cv_prog_compiler_static_works" = xyes; then |
14460 | : | |
14461 | else | |
14462 | lt_prog_compiler_static= | |
14463 | fi | |
da0f6381 | 14464 | |
da0f6381 | 14465 | |
da0f6381 | 14466 | |
da0f6381 | 14467 | |
da0f6381 | 14468 | |
da0f6381 | 14469 | |
da0f6381 | 14470 | |
5213506e RW |
14471 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 |
14472 | $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } | |
14473 | if test "${lt_cv_prog_compiler_c_o+set}" = set; then : | |
14474 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
14475 | else |
14476 | lt_cv_prog_compiler_c_o=no | |
14477 | $RM -r conftest 2>/dev/null | |
14478 | mkdir conftest | |
14479 | cd conftest | |
14480 | mkdir out | |
14481 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
da0f6381 | 14482 | |
00020c16 ILT |
14483 | lt_compiler_flag="-o out/conftest2.$ac_objext" |
14484 | # Insert the option either (1) after the last *FLAGS variable, or | |
14485 | # (2) before a word containing "conftest.", or (3) at the end. | |
14486 | # Note that $ac_compile itself does not contain backslashes and begins | |
14487 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
14488 | lt_compile=`echo "$ac_compile" | $SED \ | |
14489 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
14490 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
14491 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 14492 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
14493 | (eval "$lt_compile" 2>out/conftest.err) |
14494 | ac_status=$? | |
14495 | cat out/conftest.err >&5 | |
43e02a8a | 14496 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
14497 | if (exit $ac_status) && test -s out/conftest2.$ac_objext |
14498 | then | |
14499 | # The compiler can only warn and ignore the option if not recognized | |
14500 | # So say no if there are warnings | |
43e02a8a | 14501 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp |
00020c16 ILT |
14502 | $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 |
14503 | if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then | |
14504 | lt_cv_prog_compiler_c_o=yes | |
14505 | fi | |
14506 | fi | |
14507 | chmod u+w . 2>&5 | |
14508 | $RM conftest* | |
14509 | # SGI C++ compiler will create directory out/ii_files/ for | |
14510 | # template instantiation | |
14511 | test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files | |
14512 | $RM out/* && rmdir out | |
14513 | cd .. | |
14514 | $RM -r conftest | |
14515 | $RM conftest* | |
da0f6381 | 14516 | |
00020c16 | 14517 | fi |
5213506e RW |
14518 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 |
14519 | $as_echo "$lt_cv_prog_compiler_c_o" >&6; } | |
da0f6381 PB |
14520 | |
14521 | ||
14522 | ||
14523 | ||
14524 | ||
14525 | ||
5213506e RW |
14526 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 |
14527 | $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } | |
14528 | if test "${lt_cv_prog_compiler_c_o+set}" = set; then : | |
14529 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
14530 | else |
14531 | lt_cv_prog_compiler_c_o=no | |
14532 | $RM -r conftest 2>/dev/null | |
14533 | mkdir conftest | |
14534 | cd conftest | |
14535 | mkdir out | |
14536 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
da0f6381 | 14537 | |
00020c16 ILT |
14538 | lt_compiler_flag="-o out/conftest2.$ac_objext" |
14539 | # Insert the option either (1) after the last *FLAGS variable, or | |
14540 | # (2) before a word containing "conftest.", or (3) at the end. | |
14541 | # Note that $ac_compile itself does not contain backslashes and begins | |
14542 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
14543 | lt_compile=`echo "$ac_compile" | $SED \ | |
14544 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
14545 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
14546 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 14547 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
14548 | (eval "$lt_compile" 2>out/conftest.err) |
14549 | ac_status=$? | |
14550 | cat out/conftest.err >&5 | |
43e02a8a | 14551 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
14552 | if (exit $ac_status) && test -s out/conftest2.$ac_objext |
14553 | then | |
14554 | # The compiler can only warn and ignore the option if not recognized | |
14555 | # So say no if there are warnings | |
43e02a8a | 14556 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp |
00020c16 ILT |
14557 | $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 |
14558 | if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then | |
14559 | lt_cv_prog_compiler_c_o=yes | |
14560 | fi | |
14561 | fi | |
14562 | chmod u+w . 2>&5 | |
14563 | $RM conftest* | |
14564 | # SGI C++ compiler will create directory out/ii_files/ for | |
14565 | # template instantiation | |
14566 | test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files | |
14567 | $RM out/* && rmdir out | |
14568 | cd .. | |
14569 | $RM -r conftest | |
14570 | $RM conftest* | |
da0f6381 | 14571 | |
00020c16 | 14572 | fi |
5213506e RW |
14573 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o" >&5 |
14574 | $as_echo "$lt_cv_prog_compiler_c_o" >&6; } | |
da0f6381 PB |
14575 | |
14576 | ||
14577 | ||
14578 | ||
00020c16 ILT |
14579 | hard_links="nottested" |
14580 | if test "$lt_cv_prog_compiler_c_o" = no && test "$need_locks" != no; then | |
14581 | # do not overwrite the value of need_locks provided by the user | |
5213506e RW |
14582 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 |
14583 | $as_echo_n "checking if we can lock with hard links... " >&6; } | |
00020c16 | 14584 | hard_links=yes |
baafc534 | 14585 | $RM conftest* |
00020c16 ILT |
14586 | ln conftest.a conftest.b 2>/dev/null && hard_links=no |
14587 | touch conftest.a | |
14588 | ln conftest.a conftest.b 2>&5 || hard_links=no | |
14589 | ln conftest.a conftest.b 2>/dev/null && hard_links=no | |
5213506e RW |
14590 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 |
14591 | $as_echo "$hard_links" >&6; } | |
00020c16 | 14592 | if test "$hard_links" = no; then |
5213506e RW |
14593 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 |
14594 | $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} | |
00020c16 | 14595 | need_locks=warn |
da0f6381 | 14596 | fi |
00020c16 ILT |
14597 | else |
14598 | need_locks=no | |
14599 | fi | |
da0f6381 PB |
14600 | |
14601 | ||
14602 | ||
14603 | ||
14604 | ||
14605 | ||
5213506e RW |
14606 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 |
14607 | $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } | |
da0f6381 | 14608 | |
00020c16 ILT |
14609 | runpath_var= |
14610 | allow_undefined_flag= | |
14611 | always_export_symbols=no | |
14612 | archive_cmds= | |
14613 | archive_expsym_cmds= | |
14614 | compiler_needs_object=no | |
14615 | enable_shared_with_static_runtimes=no | |
14616 | export_dynamic_flag_spec= | |
14617 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' | |
14618 | hardcode_automatic=no | |
14619 | hardcode_direct=no | |
14620 | hardcode_direct_absolute=no | |
14621 | hardcode_libdir_flag_spec= | |
14622 | hardcode_libdir_flag_spec_ld= | |
14623 | hardcode_libdir_separator= | |
14624 | hardcode_minus_L=no | |
14625 | hardcode_shlibpath_var=unsupported | |
14626 | inherit_rpath=no | |
14627 | link_all_deplibs=unknown | |
14628 | module_cmds= | |
14629 | module_expsym_cmds= | |
14630 | old_archive_from_new_cmds= | |
14631 | old_archive_from_expsyms_cmds= | |
14632 | thread_safe_flag_spec= | |
14633 | whole_archive_flag_spec= | |
14634 | # include_expsyms should be a list of space-separated symbols to be *always* | |
14635 | # included in the symbol list | |
14636 | include_expsyms= | |
14637 | # exclude_expsyms can be an extended regexp of symbols to exclude | |
14638 | # it will be wrapped by ` (' and `)$', so one must not match beginning or | |
14639 | # end of line. Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc', | |
14640 | # as well as any symbol that contains `d'. | |
14641 | exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' | |
14642 | # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out | |
14643 | # platforms (ab)use it in PIC code, but their linkers get confused if | |
14644 | # the symbol is explicitly referenced. Since portable code cannot | |
14645 | # rely on this symbol name, it's probably fine to never include it in | |
14646 | # preloaded symbol tables. | |
14647 | # Exclude shared library initialization/finalization symbols. | |
14648 | extract_expsyms_cmds= | |
da0f6381 | 14649 | |
00020c16 ILT |
14650 | case $host_os in |
14651 | cygwin* | mingw* | pw32* | cegcc*) | |
14652 | # FIXME: the MSVC++ port hasn't been tested in a loooong time | |
14653 | # When not using gcc, we currently assume that we are using | |
14654 | # Microsoft Visual C++. | |
14655 | if test "$GCC" != yes; then | |
14656 | with_gnu_ld=no | |
14657 | fi | |
14658 | ;; | |
14659 | interix*) | |
14660 | # we just hope/assume this is gcc and not c89 (= MSVC++) | |
14661 | with_gnu_ld=yes | |
14662 | ;; | |
14663 | openbsd*) | |
14664 | with_gnu_ld=no | |
14665 | ;; | |
14666 | esac | |
da0f6381 | 14667 | |
00020c16 | 14668 | ld_shlibs=yes |
43e02a8a RW |
14669 | |
14670 | # On some targets, GNU ld is compatible enough with the native linker | |
14671 | # that we're better off using the native interface for both. | |
14672 | lt_use_gnu_ld_interface=no | |
00020c16 | 14673 | if test "$with_gnu_ld" = yes; then |
43e02a8a RW |
14674 | case $host_os in |
14675 | aix*) | |
14676 | # The AIX port of GNU ld has always aspired to compatibility | |
14677 | # with the native linker. However, as the warning in the GNU ld | |
14678 | # block says, versions before 2.19.5* couldn't really create working | |
14679 | # shared libraries, regardless of the interface used. | |
14680 | case `$LD -v 2>&1` in | |
14681 | *\ \(GNU\ Binutils\)\ 2.19.5*) ;; | |
14682 | *\ \(GNU\ Binutils\)\ 2.[2-9]*) ;; | |
14683 | *\ \(GNU\ Binutils\)\ [3-9]*) ;; | |
14684 | *) | |
14685 | lt_use_gnu_ld_interface=yes | |
14686 | ;; | |
14687 | esac | |
14688 | ;; | |
14689 | *) | |
14690 | lt_use_gnu_ld_interface=yes | |
14691 | ;; | |
14692 | esac | |
14693 | fi | |
14694 | ||
14695 | if test "$lt_use_gnu_ld_interface" = yes; then | |
00020c16 ILT |
14696 | # If archive_cmds runs LD, not CC, wlarc should be empty |
14697 | wlarc='${wl}' | |
da0f6381 | 14698 | |
00020c16 ILT |
14699 | # Set some defaults for GNU ld with shared library support. These |
14700 | # are reset later if shared libraries are not supported. Putting them | |
14701 | # here allows them to be overridden if necessary. | |
14702 | runpath_var=LD_RUN_PATH | |
14703 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' | |
14704 | export_dynamic_flag_spec='${wl}--export-dynamic' | |
14705 | # ancient GNU ld didn't support --whole-archive et. al. | |
14706 | if $LD --help 2>&1 | $GREP 'no-whole-archive' > /dev/null; then | |
14707 | whole_archive_flag_spec="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' | |
14708 | else | |
14709 | whole_archive_flag_spec= | |
14710 | fi | |
14711 | supports_anon_versioning=no | |
14712 | case `$LD -v 2>&1` in | |
43e02a8a | 14713 | *GNU\ gold*) supports_anon_versioning=yes ;; |
00020c16 ILT |
14714 | *\ [01].* | *\ 2.[0-9].* | *\ 2.10.*) ;; # catch versions < 2.11 |
14715 | *\ 2.11.93.0.2\ *) supports_anon_versioning=yes ;; # RH7.3 ... | |
14716 | *\ 2.11.92.0.12\ *) supports_anon_versioning=yes ;; # Mandrake 8.2 ... | |
14717 | *\ 2.11.*) ;; # other 2.11 versions | |
14718 | *) supports_anon_versioning=yes ;; | |
14719 | esac | |
da0f6381 | 14720 | |
00020c16 ILT |
14721 | # See if GNU ld supports shared libraries. |
14722 | case $host_os in | |
14723 | aix[3-9]*) | |
14724 | # On AIX/PPC, the GNU linker is very broken | |
14725 | if test "$host_cpu" != ia64; then | |
14726 | ld_shlibs=no | |
14727 | cat <<_LT_EOF 1>&2 | |
da0f6381 | 14728 | |
43e02a8a | 14729 | *** Warning: the GNU linker, at least up to release 2.19, is reported |
00020c16 ILT |
14730 | *** to be unable to reliably create shared libraries on AIX. |
14731 | *** Therefore, libtool is disabling shared libraries support. If you | |
43e02a8a RW |
14732 | *** really care for shared libraries, you may want to install binutils |
14733 | *** 2.20 or above, or modify your PATH so that a non-GNU linker is found. | |
14734 | *** You will then need to restart the configuration process. | |
da0f6381 | 14735 | |
00020c16 ILT |
14736 | _LT_EOF |
14737 | fi | |
14738 | ;; | |
da0f6381 | 14739 | |
00020c16 ILT |
14740 | amigaos*) |
14741 | case $host_cpu in | |
14742 | powerpc) | |
14743 | # see comment about AmigaOS4 .so support | |
14744 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14745 | archive_expsym_cmds='' | |
14746 | ;; | |
14747 | m68k) | |
14748 | archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' | |
14749 | hardcode_libdir_flag_spec='-L$libdir' | |
14750 | hardcode_minus_L=yes | |
14751 | ;; | |
14752 | esac | |
14753 | ;; | |
da0f6381 | 14754 | |
00020c16 ILT |
14755 | beos*) |
14756 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then | |
14757 | allow_undefined_flag=unsupported | |
14758 | # Joseph Beckenbach <jrb3@best.com> says some releases of gcc | |
14759 | # support --undefined. This deserves some investigation. FIXME | |
14760 | archive_cmds='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14761 | else | |
14762 | ld_shlibs=no | |
14763 | fi | |
14764 | ;; | |
da0f6381 | 14765 | |
00020c16 ILT |
14766 | cygwin* | mingw* | pw32* | cegcc*) |
14767 | # _LT_TAGVAR(hardcode_libdir_flag_spec, ) is actually meaningless, | |
14768 | # as there is no search path for DLLs. | |
14769 | hardcode_libdir_flag_spec='-L$libdir' | |
43e02a8a | 14770 | export_dynamic_flag_spec='${wl}--export-all-symbols' |
00020c16 ILT |
14771 | allow_undefined_flag=unsupported |
14772 | always_export_symbols=no | |
14773 | enable_shared_with_static_runtimes=yes | |
14774 | export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols' | |
da0f6381 | 14775 | |
00020c16 ILT |
14776 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then |
14777 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
14778 | # If the export-symbols file already is a .def file (1st line | |
14779 | # is EXPORTS), use it as is; otherwise, prepend... | |
14780 | archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
14781 | cp $export_symbols $output_objdir/$soname.def; | |
14782 | else | |
14783 | echo EXPORTS > $output_objdir/$soname.def; | |
14784 | cat $export_symbols >> $output_objdir/$soname.def; | |
14785 | fi~ | |
14786 | $CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
14787 | else | |
14788 | ld_shlibs=no | |
14789 | fi | |
14790 | ;; | |
da0f6381 | 14791 | |
43e02a8a RW |
14792 | haiku*) |
14793 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14794 | link_all_deplibs=yes | |
14795 | ;; | |
14796 | ||
00020c16 ILT |
14797 | interix[3-9]*) |
14798 | hardcode_direct=no | |
14799 | hardcode_shlibpath_var=no | |
14800 | hardcode_libdir_flag_spec='${wl}-rpath,$libdir' | |
14801 | export_dynamic_flag_spec='${wl}-E' | |
14802 | # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. | |
14803 | # Instead, shared libraries are loaded at an image base (0x10000000 by | |
14804 | # default) and relocated if they conflict, which is a slow very memory | |
14805 | # consuming and fragmenting process. To avoid this, we pick a random, | |
14806 | # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link | |
14807 | # time. Moving up from 0x10000000 also allows more sbrk(2) space. | |
14808 | archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' | |
14809 | archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' | |
14810 | ;; | |
da0f6381 | 14811 | |
00020c16 ILT |
14812 | gnu* | linux* | tpf* | k*bsd*-gnu | kopensolaris*-gnu) |
14813 | tmp_diet=no | |
14814 | if test "$host_os" = linux-dietlibc; then | |
14815 | case $cc_basename in | |
14816 | diet\ *) tmp_diet=yes;; # linux-dietlibc with static linking (!diet-dyn) | |
14817 | esac | |
14818 | fi | |
14819 | if $LD --help 2>&1 | $EGREP ': supported targets:.* elf' > /dev/null \ | |
14820 | && test "$tmp_diet" = no | |
14821 | then | |
14822 | tmp_addflag= | |
14823 | tmp_sharedflag='-shared' | |
14824 | case $cc_basename,$host_cpu in | |
14825 | pgcc*) # Portland Group C compiler | |
43e02a8a | 14826 | whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' |
00020c16 ILT |
14827 | tmp_addflag=' $pic_flag' |
14828 | ;; | |
43e02a8a RW |
14829 | pgf77* | pgf90* | pgf95* | pgfortran*) |
14830 | # Portland Group f77 and f90 compilers | |
14831 | whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' | |
00020c16 ILT |
14832 | tmp_addflag=' $pic_flag -Mnomain' ;; |
14833 | ecc*,ia64* | icc*,ia64*) # Intel C compiler on ia64 | |
14834 | tmp_addflag=' -i_dynamic' ;; | |
14835 | efc*,ia64* | ifort*,ia64*) # Intel Fortran compiler on ia64 | |
14836 | tmp_addflag=' -i_dynamic -nofor_main' ;; | |
14837 | ifc* | ifort*) # Intel Fortran compiler | |
14838 | tmp_addflag=' -nofor_main' ;; | |
14839 | lf95*) # Lahey Fortran 8.1 | |
14840 | whole_archive_flag_spec= | |
14841 | tmp_sharedflag='--shared' ;; | |
43e02a8a | 14842 | xl[cC]* | bgxl[cC]* | mpixl[cC]*) # IBM XL C 8.0 on PPC (deal with xlf below) |
00020c16 ILT |
14843 | tmp_sharedflag='-qmkshrobj' |
14844 | tmp_addflag= ;; | |
43e02a8a RW |
14845 | nvcc*) # Cuda Compiler Driver 2.2 |
14846 | whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' | |
14847 | compiler_needs_object=yes | |
14848 | ;; | |
00020c16 ILT |
14849 | esac |
14850 | case `$CC -V 2>&1 | sed 5q` in | |
14851 | *Sun\ C*) # Sun C 5.9 | |
43e02a8a | 14852 | whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' |
00020c16 ILT |
14853 | compiler_needs_object=yes |
14854 | tmp_sharedflag='-G' ;; | |
14855 | *Sun\ F*) # Sun Fortran 8.3 | |
14856 | tmp_sharedflag='-G' ;; | |
14857 | esac | |
14858 | archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
da0f6381 | 14859 | |
00020c16 ILT |
14860 | if test "x$supports_anon_versioning" = xyes; then |
14861 | archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ | |
14862 | cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ | |
14863 | echo "local: *; };" >> $output_objdir/$libname.ver~ | |
14864 | $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' | |
14865 | fi | |
da0f6381 | 14866 | |
00020c16 | 14867 | case $cc_basename in |
43e02a8a | 14868 | xlf* | bgf* | bgxlf* | mpixlf*) |
00020c16 ILT |
14869 | # IBM XL Fortran 10.1 on PPC cannot create shared libs itself |
14870 | whole_archive_flag_spec='--whole-archive$convenience --no-whole-archive' | |
14871 | hardcode_libdir_flag_spec= | |
14872 | hardcode_libdir_flag_spec_ld='-rpath $libdir' | |
14873 | archive_cmds='$LD -shared $libobjs $deplibs $compiler_flags -soname $soname -o $lib' | |
14874 | if test "x$supports_anon_versioning" = xyes; then | |
14875 | archive_expsym_cmds='echo "{ global:" > $output_objdir/$libname.ver~ | |
14876 | cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ | |
14877 | echo "local: *; };" >> $output_objdir/$libname.ver~ | |
14878 | $LD -shared $libobjs $deplibs $compiler_flags -soname $soname -version-script $output_objdir/$libname.ver -o $lib' | |
14879 | fi | |
14880 | ;; | |
14881 | esac | |
14882 | else | |
14883 | ld_shlibs=no | |
14884 | fi | |
14885 | ;; | |
da0f6381 | 14886 | |
00020c16 ILT |
14887 | netbsd*) |
14888 | if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then | |
14889 | archive_cmds='$LD -Bshareable $libobjs $deplibs $linker_flags -o $lib' | |
14890 | wlarc= | |
14891 | else | |
14892 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14893 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
14894 | fi | |
14895 | ;; | |
da0f6381 | 14896 | |
00020c16 ILT |
14897 | solaris*) |
14898 | if $LD -v 2>&1 | $GREP 'BFD 2\.8' > /dev/null; then | |
14899 | ld_shlibs=no | |
14900 | cat <<_LT_EOF 1>&2 | |
da0f6381 | 14901 | |
00020c16 ILT |
14902 | *** Warning: The releases 2.8.* of the GNU linker cannot reliably |
14903 | *** create shared libraries on Solaris systems. Therefore, libtool | |
14904 | *** is disabling shared libraries support. We urge you to upgrade GNU | |
14905 | *** binutils to release 2.9.1 or newer. Another option is to modify | |
14906 | *** your PATH or compiler configuration so that the native linker is | |
14907 | *** used, and then restart. | |
da0f6381 | 14908 | |
00020c16 ILT |
14909 | _LT_EOF |
14910 | elif $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then | |
14911 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14912 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
14913 | else | |
14914 | ld_shlibs=no | |
14915 | fi | |
14916 | ;; | |
da0f6381 | 14917 | |
00020c16 ILT |
14918 | sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*) |
14919 | case `$LD -v 2>&1` in | |
14920 | *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*) | |
14921 | ld_shlibs=no | |
14922 | cat <<_LT_EOF 1>&2 | |
da0f6381 | 14923 | |
00020c16 ILT |
14924 | *** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not |
14925 | *** reliably create shared libraries on SCO systems. Therefore, libtool | |
14926 | *** is disabling shared libraries support. We urge you to upgrade GNU | |
14927 | *** binutils to release 2.16.91.0.3 or newer. Another option is to modify | |
14928 | *** your PATH or compiler configuration so that the native linker is | |
14929 | *** used, and then restart. | |
da0f6381 | 14930 | |
00020c16 ILT |
14931 | _LT_EOF |
14932 | ;; | |
14933 | *) | |
14934 | # For security reasons, it is highly recommended that you always | |
14935 | # use absolute paths for naming shared libraries, and exclude the | |
14936 | # DT_RUNPATH tag from executables and libraries. But doing so | |
14937 | # requires that you compile everything twice, which is a pain. | |
14938 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then | |
14939 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' | |
14940 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14941 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
14942 | else | |
14943 | ld_shlibs=no | |
14944 | fi | |
14945 | ;; | |
14946 | esac | |
14947 | ;; | |
da0f6381 | 14948 | |
00020c16 ILT |
14949 | sunos4*) |
14950 | archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags' | |
14951 | wlarc= | |
14952 | hardcode_direct=yes | |
14953 | hardcode_shlibpath_var=no | |
14954 | ;; | |
da0f6381 | 14955 | |
00020c16 ILT |
14956 | *) |
14957 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then | |
14958 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
14959 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
14960 | else | |
14961 | ld_shlibs=no | |
14962 | fi | |
14963 | ;; | |
14964 | esac | |
da0f6381 | 14965 | |
00020c16 ILT |
14966 | if test "$ld_shlibs" = no; then |
14967 | runpath_var= | |
14968 | hardcode_libdir_flag_spec= | |
14969 | export_dynamic_flag_spec= | |
14970 | whole_archive_flag_spec= | |
14971 | fi | |
14972 | else | |
14973 | # PORTME fill in a description of your system's linker (not GNU ld) | |
14974 | case $host_os in | |
14975 | aix3*) | |
14976 | allow_undefined_flag=unsupported | |
14977 | always_export_symbols=yes | |
14978 | archive_expsym_cmds='$LD -o $output_objdir/$soname $libobjs $deplibs $linker_flags -bE:$export_symbols -T512 -H512 -bM:SRE~$AR $AR_FLAGS $lib $output_objdir/$soname' | |
14979 | # Note: this linker hardcodes the directories in LIBPATH if there | |
14980 | # are no directories specified by -L. | |
14981 | hardcode_minus_L=yes | |
14982 | if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then | |
14983 | # Neither direct hardcoding nor static linking is supported with a | |
14984 | # broken collect2. | |
14985 | hardcode_direct=unsupported | |
14986 | fi | |
14987 | ;; | |
da0f6381 | 14988 | |
00020c16 ILT |
14989 | aix[4-9]*) |
14990 | if test "$host_cpu" = ia64; then | |
14991 | # On IA64, the linker does run time linking by default, so we don't | |
14992 | # have to do anything special. | |
14993 | aix_use_runtimelinking=no | |
14994 | exp_sym_flag='-Bexport' | |
14995 | no_entry_flag="" | |
14996 | else | |
14997 | # If we're using GNU nm, then we don't want the "-C" option. | |
14998 | # -C means demangle to AIX nm, but means don't demangle with GNU nm | |
43e02a8a RW |
14999 | # Also, AIX nm treats weak defined symbols like other global |
15000 | # defined symbols, whereas GNU nm marks them as "W". | |
00020c16 | 15001 | if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then |
43e02a8a | 15002 | export_symbols_cmds='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' |
00020c16 ILT |
15003 | else |
15004 | export_symbols_cmds='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' | |
15005 | fi | |
15006 | aix_use_runtimelinking=no | |
da0f6381 | 15007 | |
00020c16 ILT |
15008 | # Test if we are trying to use run time linking or normal |
15009 | # AIX style linking. If -brtl is somewhere in LDFLAGS, we | |
15010 | # need to do runtime linking. | |
15011 | case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) | |
15012 | for ld_flag in $LDFLAGS; do | |
15013 | if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then | |
15014 | aix_use_runtimelinking=yes | |
15015 | break | |
15016 | fi | |
15017 | done | |
15018 | ;; | |
15019 | esac | |
da0f6381 | 15020 | |
00020c16 ILT |
15021 | exp_sym_flag='-bexport' |
15022 | no_entry_flag='-bnoentry' | |
15023 | fi | |
da0f6381 | 15024 | |
00020c16 ILT |
15025 | # When large executables or shared objects are built, AIX ld can |
15026 | # have problems creating the table of contents. If linking a library | |
15027 | # or program results in "error TOC overflow" add -mminimal-toc to | |
15028 | # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not | |
15029 | # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. | |
da0f6381 | 15030 | |
00020c16 ILT |
15031 | archive_cmds='' |
15032 | hardcode_direct=yes | |
15033 | hardcode_direct_absolute=yes | |
15034 | hardcode_libdir_separator=':' | |
15035 | link_all_deplibs=yes | |
15036 | file_list_spec='${wl}-f,' | |
da0f6381 | 15037 | |
00020c16 ILT |
15038 | if test "$GCC" = yes; then |
15039 | case $host_os in aix4.[012]|aix4.[012].*) | |
15040 | # We only want to do this on AIX 4.2 and lower, the check | |
15041 | # below for broken collect2 doesn't work under 4.3+ | |
15042 | collect2name=`${CC} -print-prog-name=collect2` | |
15043 | if test -f "$collect2name" && | |
15044 | strings "$collect2name" | $GREP resolve_lib_name >/dev/null | |
15045 | then | |
15046 | # We have reworked collect2 | |
15047 | : | |
15048 | else | |
15049 | # We have old collect2 | |
15050 | hardcode_direct=unsupported | |
15051 | # It fails to find uninstalled libraries when the uninstalled | |
15052 | # path is not listed in the libpath. Setting hardcode_minus_L | |
15053 | # to unsupported forces relinking | |
15054 | hardcode_minus_L=yes | |
15055 | hardcode_libdir_flag_spec='-L$libdir' | |
15056 | hardcode_libdir_separator= | |
15057 | fi | |
15058 | ;; | |
15059 | esac | |
15060 | shared_flag='-shared' | |
15061 | if test "$aix_use_runtimelinking" = yes; then | |
15062 | shared_flag="$shared_flag "'${wl}-G' | |
15063 | fi | |
15064 | else | |
15065 | # not using gcc | |
15066 | if test "$host_cpu" = ia64; then | |
15067 | # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release | |
15068 | # chokes on -Wl,-G. The following line is correct: | |
15069 | shared_flag='-G' | |
15070 | else | |
15071 | if test "$aix_use_runtimelinking" = yes; then | |
15072 | shared_flag='${wl}-G' | |
15073 | else | |
15074 | shared_flag='${wl}-bM:SRE' | |
15075 | fi | |
15076 | fi | |
15077 | fi | |
da0f6381 | 15078 | |
00020c16 ILT |
15079 | export_dynamic_flag_spec='${wl}-bexpall' |
15080 | # It seems that -bexpall does not export symbols beginning with | |
15081 | # underscore (_), so it is better to generate a list of symbols to export. | |
15082 | always_export_symbols=yes | |
15083 | if test "$aix_use_runtimelinking" = yes; then | |
15084 | # Warning - without using the other runtime loading flags (-brtl), | |
15085 | # -berok will link without error, but may produce a broken library. | |
15086 | allow_undefined_flag='-berok' | |
15087 | # Determine the default libpath from the value encoded in an | |
15088 | # empty executable. | |
5213506e | 15089 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 | 15090 | /* end confdefs.h. */ |
da0f6381 | 15091 | |
00020c16 ILT |
15092 | int |
15093 | main () | |
15094 | { | |
da0f6381 | 15095 | |
00020c16 ILT |
15096 | ; |
15097 | return 0; | |
15098 | } | |
15099 | _ACEOF | |
5213506e | 15100 | if ac_fn_c_try_link "$LINENO"; then : |
da0f6381 | 15101 | |
00020c16 ILT |
15102 | lt_aix_libpath_sed=' |
15103 | /Import File Strings/,/^$/ { | |
15104 | /^0/ { | |
15105 | s/^0 *\(.*\)$/\1/ | |
15106 | p | |
15107 | } | |
15108 | }' | |
15109 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
15110 | # Check for a 64-bit object if we didn't find anything. | |
15111 | if test -z "$aix_libpath"; then | |
15112 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
15113 | fi | |
00020c16 | 15114 | fi |
5213506e RW |
15115 | rm -f core conftest.err conftest.$ac_objext \ |
15116 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 | 15117 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi |
da0f6381 | 15118 | |
00020c16 | 15119 | hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" |
43e02a8a | 15120 | archive_expsym_cmds='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" |
00020c16 ILT |
15121 | else |
15122 | if test "$host_cpu" = ia64; then | |
15123 | hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib' | |
15124 | allow_undefined_flag="-z nodefs" | |
15125 | archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" | |
15126 | else | |
15127 | # Determine the default libpath from the value encoded in an | |
15128 | # empty executable. | |
5213506e | 15129 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 | 15130 | /* end confdefs.h. */ |
da0f6381 | 15131 | |
00020c16 ILT |
15132 | int |
15133 | main () | |
15134 | { | |
da0f6381 | 15135 | |
00020c16 ILT |
15136 | ; |
15137 | return 0; | |
15138 | } | |
15139 | _ACEOF | |
5213506e | 15140 | if ac_fn_c_try_link "$LINENO"; then : |
da0f6381 | 15141 | |
00020c16 ILT |
15142 | lt_aix_libpath_sed=' |
15143 | /Import File Strings/,/^$/ { | |
15144 | /^0/ { | |
15145 | s/^0 *\(.*\)$/\1/ | |
15146 | p | |
15147 | } | |
15148 | }' | |
15149 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
15150 | # Check for a 64-bit object if we didn't find anything. | |
15151 | if test -z "$aix_libpath"; then | |
15152 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
15153 | fi | |
00020c16 | 15154 | fi |
5213506e RW |
15155 | rm -f core conftest.err conftest.$ac_objext \ |
15156 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 | 15157 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi |
da0f6381 | 15158 | |
00020c16 ILT |
15159 | hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath" |
15160 | # Warning - without using the other run time loading flags, | |
15161 | # -berok will link without error, but may produce a broken library. | |
15162 | no_undefined_flag=' ${wl}-bernotok' | |
15163 | allow_undefined_flag=' ${wl}-berok' | |
43e02a8a RW |
15164 | if test "$with_gnu_ld" = yes; then |
15165 | # We only use this code for GNU lds that support --whole-archive. | |
15166 | whole_archive_flag_spec='${wl}--whole-archive$convenience ${wl}--no-whole-archive' | |
15167 | else | |
15168 | # Exported symbols can be pulled into shared objects from archives | |
15169 | whole_archive_flag_spec='$convenience' | |
15170 | fi | |
00020c16 ILT |
15171 | archive_cmds_need_lc=yes |
15172 | # This is similar to how AIX traditionally builds its shared libraries. | |
15173 | archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' | |
15174 | fi | |
15175 | fi | |
15176 | ;; | |
da0f6381 | 15177 | |
00020c16 ILT |
15178 | amigaos*) |
15179 | case $host_cpu in | |
15180 | powerpc) | |
15181 | # see comment about AmigaOS4 .so support | |
15182 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
15183 | archive_expsym_cmds='' | |
15184 | ;; | |
15185 | m68k) | |
15186 | archive_cmds='$RM $output_objdir/a2ixlibrary.data~$ECHO "#define NAME $libname" > $output_objdir/a2ixlibrary.data~$ECHO "#define LIBRARY_ID 1" >> $output_objdir/a2ixlibrary.data~$ECHO "#define VERSION $major" >> $output_objdir/a2ixlibrary.data~$ECHO "#define REVISION $revision" >> $output_objdir/a2ixlibrary.data~$AR $AR_FLAGS $lib $libobjs~$RANLIB $lib~(cd $output_objdir && a2ixlibrary -32)' | |
15187 | hardcode_libdir_flag_spec='-L$libdir' | |
15188 | hardcode_minus_L=yes | |
15189 | ;; | |
15190 | esac | |
15191 | ;; | |
da0f6381 | 15192 | |
00020c16 ILT |
15193 | bsdi[45]*) |
15194 | export_dynamic_flag_spec=-rdynamic | |
15195 | ;; | |
da0f6381 | 15196 | |
00020c16 ILT |
15197 | cygwin* | mingw* | pw32* | cegcc*) |
15198 | # When not using gcc, we currently assume that we are using | |
15199 | # Microsoft Visual C++. | |
15200 | # hardcode_libdir_flag_spec is actually meaningless, as there is | |
15201 | # no search path for DLLs. | |
15202 | hardcode_libdir_flag_spec=' ' | |
15203 | allow_undefined_flag=unsupported | |
15204 | # Tell ltmain to make .lib files, not .a files. | |
15205 | libext=lib | |
15206 | # Tell ltmain to make .dll files, not .so files. | |
15207 | shrext_cmds=".dll" | |
15208 | # FIXME: Setting linknames here is a bad hack. | |
43e02a8a | 15209 | archive_cmds='$CC -o $lib $libobjs $compiler_flags `func_echo_all "$deplibs" | $SED '\''s/ -lc$//'\''` -link -dll~linknames=' |
00020c16 ILT |
15210 | # The linker will automatically build a .lib file if we build a DLL. |
15211 | old_archive_from_new_cmds='true' | |
15212 | # FIXME: Should let the user specify the lib program. | |
15213 | old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs' | |
15214 | fix_srcfile_path='`cygpath -w "$srcfile"`' | |
15215 | enable_shared_with_static_runtimes=yes | |
15216 | ;; | |
da0f6381 | 15217 | |
00020c16 | 15218 | darwin* | rhapsody*) |
da0f6381 PB |
15219 | |
15220 | ||
00020c16 ILT |
15221 | archive_cmds_need_lc=no |
15222 | hardcode_direct=no | |
15223 | hardcode_automatic=yes | |
15224 | hardcode_shlibpath_var=unsupported | |
43e02a8a RW |
15225 | if test "$lt_cv_ld_force_load" = "yes"; then |
15226 | whole_archive_flag_spec='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' | |
15227 | else | |
15228 | whole_archive_flag_spec='' | |
15229 | fi | |
00020c16 ILT |
15230 | link_all_deplibs=yes |
15231 | allow_undefined_flag="$_lt_dar_allow_undefined" | |
15232 | case $cc_basename in | |
15233 | ifort*) _lt_dar_can_shared=yes ;; | |
15234 | *) _lt_dar_can_shared=$GCC ;; | |
15235 | esac | |
15236 | if test "$_lt_dar_can_shared" = "yes"; then | |
43e02a8a | 15237 | output_verbose_link_cmd=func_echo_all |
00020c16 ILT |
15238 | archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" |
15239 | module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" | |
15240 | archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" | |
15241 | module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" | |
da0f6381 | 15242 | |
00020c16 ILT |
15243 | else |
15244 | ld_shlibs=no | |
15245 | fi | |
da0f6381 | 15246 | |
00020c16 | 15247 | ;; |
da0f6381 | 15248 | |
00020c16 ILT |
15249 | dgux*) |
15250 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15251 | hardcode_libdir_flag_spec='-L$libdir' | |
15252 | hardcode_shlibpath_var=no | |
15253 | ;; | |
da0f6381 | 15254 | |
00020c16 ILT |
15255 | freebsd1*) |
15256 | ld_shlibs=no | |
15257 | ;; | |
da0f6381 | 15258 | |
00020c16 ILT |
15259 | # FreeBSD 2.2.[012] allows us to include c++rt0.o to get C++ constructor |
15260 | # support. Future versions do this automatically, but an explicit c++rt0.o | |
15261 | # does not break anything, and helps significantly (at the cost of a little | |
15262 | # extra space). | |
15263 | freebsd2.2*) | |
15264 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags /usr/lib/c++rt0.o' | |
15265 | hardcode_libdir_flag_spec='-R$libdir' | |
15266 | hardcode_direct=yes | |
15267 | hardcode_shlibpath_var=no | |
15268 | ;; | |
da0f6381 | 15269 | |
00020c16 ILT |
15270 | # Unfortunately, older versions of FreeBSD 2 do not have this feature. |
15271 | freebsd2*) | |
15272 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' | |
15273 | hardcode_direct=yes | |
15274 | hardcode_minus_L=yes | |
15275 | hardcode_shlibpath_var=no | |
15276 | ;; | |
da0f6381 | 15277 | |
00020c16 ILT |
15278 | # FreeBSD 3 and greater uses gcc -shared to do shared libraries. |
15279 | freebsd* | dragonfly*) | |
15280 | archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags' | |
15281 | hardcode_libdir_flag_spec='-R$libdir' | |
15282 | hardcode_direct=yes | |
15283 | hardcode_shlibpath_var=no | |
15284 | ;; | |
da0f6381 | 15285 | |
00020c16 ILT |
15286 | hpux9*) |
15287 | if test "$GCC" = yes; then | |
15288 | archive_cmds='$RM $output_objdir/$soname~$CC -shared -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $libobjs $deplibs $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
15289 | else | |
15290 | archive_cmds='$RM $output_objdir/$soname~$LD -b +b $install_libdir -o $output_objdir/$soname $libobjs $deplibs $linker_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
15291 | fi | |
15292 | hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' | |
15293 | hardcode_libdir_separator=: | |
15294 | hardcode_direct=yes | |
da0f6381 | 15295 | |
00020c16 ILT |
15296 | # hardcode_minus_L: Not really in the search PATH, |
15297 | # but as the default location of the library. | |
15298 | hardcode_minus_L=yes | |
15299 | export_dynamic_flag_spec='${wl}-E' | |
15300 | ;; | |
da0f6381 | 15301 | |
00020c16 | 15302 | hpux10*) |
43e02a8a | 15303 | if test "$GCC" = yes && test "$with_gnu_ld" = no; then |
00020c16 ILT |
15304 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' |
15305 | else | |
15306 | archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' | |
15307 | fi | |
15308 | if test "$with_gnu_ld" = no; then | |
15309 | hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' | |
15310 | hardcode_libdir_flag_spec_ld='+b $libdir' | |
15311 | hardcode_libdir_separator=: | |
15312 | hardcode_direct=yes | |
15313 | hardcode_direct_absolute=yes | |
15314 | export_dynamic_flag_spec='${wl}-E' | |
15315 | # hardcode_minus_L: Not really in the search PATH, | |
15316 | # but as the default location of the library. | |
15317 | hardcode_minus_L=yes | |
15318 | fi | |
15319 | ;; | |
da0f6381 | 15320 | |
00020c16 | 15321 | hpux11*) |
43e02a8a | 15322 | if test "$GCC" = yes && test "$with_gnu_ld" = no; then |
00020c16 ILT |
15323 | case $host_cpu in |
15324 | hppa*64*) | |
15325 | archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15326 | ;; | |
15327 | ia64*) | |
15328 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
15329 | ;; | |
15330 | *) | |
15331 | archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
15332 | ;; | |
15333 | esac | |
15334 | else | |
15335 | case $host_cpu in | |
15336 | hppa*64*) | |
15337 | archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15338 | ;; | |
15339 | ia64*) | |
15340 | archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags' | |
15341 | ;; | |
15342 | *) | |
43e02a8a RW |
15343 | |
15344 | # Older versions of the 11.00 compiler do not understand -b yet | |
15345 | # (HP92453-01 A.11.01.20 doesn't, HP92453-01 B.11.X.35175-35176.GP does) | |
15346 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC understands -b" >&5 | |
15347 | $as_echo_n "checking if $CC understands -b... " >&6; } | |
15348 | if test "${lt_cv_prog_compiler__b+set}" = set; then : | |
15349 | $as_echo_n "(cached) " >&6 | |
15350 | else | |
15351 | lt_cv_prog_compiler__b=no | |
15352 | save_LDFLAGS="$LDFLAGS" | |
15353 | LDFLAGS="$LDFLAGS -b" | |
15354 | echo "$lt_simple_link_test_code" > conftest.$ac_ext | |
15355 | if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then | |
15356 | # The linker can only warn and ignore the option if not recognized | |
15357 | # So say no if there are warnings | |
15358 | if test -s conftest.err; then | |
15359 | # Append any errors to the config.log. | |
15360 | cat conftest.err 1>&5 | |
15361 | $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp | |
15362 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 | |
15363 | if diff conftest.exp conftest.er2 >/dev/null; then | |
15364 | lt_cv_prog_compiler__b=yes | |
15365 | fi | |
15366 | else | |
15367 | lt_cv_prog_compiler__b=yes | |
15368 | fi | |
15369 | fi | |
15370 | $RM -r conftest* | |
15371 | LDFLAGS="$save_LDFLAGS" | |
15372 | ||
15373 | fi | |
15374 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler__b" >&5 | |
15375 | $as_echo "$lt_cv_prog_compiler__b" >&6; } | |
15376 | ||
15377 | if test x"$lt_cv_prog_compiler__b" = xyes; then | |
15378 | archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags' | |
15379 | else | |
15380 | archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags' | |
15381 | fi | |
15382 | ||
00020c16 ILT |
15383 | ;; |
15384 | esac | |
15385 | fi | |
15386 | if test "$with_gnu_ld" = no; then | |
15387 | hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir' | |
15388 | hardcode_libdir_separator=: | |
da0f6381 | 15389 | |
00020c16 ILT |
15390 | case $host_cpu in |
15391 | hppa*64*|ia64*) | |
15392 | hardcode_direct=no | |
15393 | hardcode_shlibpath_var=no | |
15394 | ;; | |
15395 | *) | |
15396 | hardcode_direct=yes | |
15397 | hardcode_direct_absolute=yes | |
15398 | export_dynamic_flag_spec='${wl}-E' | |
da0f6381 | 15399 | |
00020c16 ILT |
15400 | # hardcode_minus_L: Not really in the search PATH, |
15401 | # but as the default location of the library. | |
15402 | hardcode_minus_L=yes | |
15403 | ;; | |
15404 | esac | |
15405 | fi | |
15406 | ;; | |
da0f6381 | 15407 | |
00020c16 ILT |
15408 | irix5* | irix6* | nonstopux*) |
15409 | if test "$GCC" = yes; then | |
43e02a8a | 15410 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
15411 | # Try to use the -exported_symbol ld option, if it does not |
15412 | # work, assume that -exports_file does not work either and | |
15413 | # implicitly export all symbols. | |
15414 | save_LDFLAGS="$LDFLAGS" | |
15415 | LDFLAGS="$LDFLAGS -shared ${wl}-exported_symbol ${wl}foo ${wl}-update_registry ${wl}/dev/null" | |
5213506e RW |
15416 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
15417 | /* end confdefs.h. */ | |
00020c16 ILT |
15418 | int foo(void) {} |
15419 | _ACEOF | |
5213506e | 15420 | if ac_fn_c_try_link "$LINENO"; then : |
43e02a8a | 15421 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations ${wl}-exports_file ${wl}$export_symbols -o $lib' |
da0f6381 | 15422 | |
00020c16 | 15423 | fi |
5213506e RW |
15424 | rm -f core conftest.err conftest.$ac_objext \ |
15425 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 ILT |
15426 | LDFLAGS="$save_LDFLAGS" |
15427 | else | |
43e02a8a RW |
15428 | archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
15429 | archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -exports_file $export_symbols -o $lib' | |
00020c16 ILT |
15430 | fi |
15431 | archive_cmds_need_lc='no' | |
15432 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' | |
15433 | hardcode_libdir_separator=: | |
15434 | inherit_rpath=yes | |
15435 | link_all_deplibs=yes | |
15436 | ;; | |
da0f6381 | 15437 | |
00020c16 ILT |
15438 | netbsd*) |
15439 | if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then | |
15440 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' # a.out | |
15441 | else | |
15442 | archive_cmds='$LD -shared -o $lib $libobjs $deplibs $linker_flags' # ELF | |
15443 | fi | |
15444 | hardcode_libdir_flag_spec='-R$libdir' | |
15445 | hardcode_direct=yes | |
15446 | hardcode_shlibpath_var=no | |
15447 | ;; | |
da0f6381 | 15448 | |
00020c16 ILT |
15449 | newsos6) |
15450 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15451 | hardcode_direct=yes | |
15452 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' | |
15453 | hardcode_libdir_separator=: | |
15454 | hardcode_shlibpath_var=no | |
15455 | ;; | |
da0f6381 | 15456 | |
00020c16 ILT |
15457 | *nto* | *qnx*) |
15458 | ;; | |
da0f6381 | 15459 | |
00020c16 ILT |
15460 | openbsd*) |
15461 | if test -f /usr/libexec/ld.so; then | |
15462 | hardcode_direct=yes | |
15463 | hardcode_shlibpath_var=no | |
15464 | hardcode_direct_absolute=yes | |
15465 | if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then | |
15466 | archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' | |
15467 | archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols' | |
15468 | hardcode_libdir_flag_spec='${wl}-rpath,$libdir' | |
15469 | export_dynamic_flag_spec='${wl}-E' | |
15470 | else | |
15471 | case $host_os in | |
15472 | openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*) | |
15473 | archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags' | |
15474 | hardcode_libdir_flag_spec='-R$libdir' | |
15475 | ;; | |
15476 | *) | |
15477 | archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags' | |
15478 | hardcode_libdir_flag_spec='${wl}-rpath,$libdir' | |
15479 | ;; | |
15480 | esac | |
15481 | fi | |
15482 | else | |
15483 | ld_shlibs=no | |
15484 | fi | |
15485 | ;; | |
da0f6381 | 15486 | |
00020c16 ILT |
15487 | os2*) |
15488 | hardcode_libdir_flag_spec='-L$libdir' | |
15489 | hardcode_minus_L=yes | |
15490 | allow_undefined_flag=unsupported | |
43e02a8a | 15491 | archive_cmds='$ECHO "LIBRARY $libname INITINSTANCE" > $output_objdir/$libname.def~$ECHO "DESCRIPTION \"$libname\"" >> $output_objdir/$libname.def~echo DATA >> $output_objdir/$libname.def~echo " SINGLE NONSHARED" >> $output_objdir/$libname.def~echo EXPORTS >> $output_objdir/$libname.def~emxexp $libobjs >> $output_objdir/$libname.def~$CC -Zdll -Zcrtdll -o $lib $libobjs $deplibs $compiler_flags $output_objdir/$libname.def' |
00020c16 ILT |
15492 | old_archive_from_new_cmds='emximp -o $output_objdir/$libname.a $output_objdir/$libname.def' |
15493 | ;; | |
da0f6381 | 15494 | |
00020c16 ILT |
15495 | osf3*) |
15496 | if test "$GCC" = yes; then | |
15497 | allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' | |
43e02a8a | 15498 | archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
15499 | else |
15500 | allow_undefined_flag=' -expect_unresolved \*' | |
43e02a8a | 15501 | archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
15502 | fi |
15503 | archive_cmds_need_lc='no' | |
15504 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' | |
15505 | hardcode_libdir_separator=: | |
15506 | ;; | |
da0f6381 | 15507 | |
00020c16 ILT |
15508 | osf4* | osf5*) # as osf3* with the addition of -msym flag |
15509 | if test "$GCC" = yes; then | |
15510 | allow_undefined_flag=' ${wl}-expect_unresolved ${wl}\*' | |
43e02a8a | 15511 | archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
15512 | hardcode_libdir_flag_spec='${wl}-rpath ${wl}$libdir' |
15513 | else | |
15514 | allow_undefined_flag=' -expect_unresolved \*' | |
43e02a8a | 15515 | archive_cmds='$CC -shared${allow_undefined_flag} $libobjs $deplibs $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
00020c16 | 15516 | archive_expsym_cmds='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done; printf "%s\\n" "-hidden">> $lib.exp~ |
43e02a8a | 15517 | $CC -shared${allow_undefined_flag} ${wl}-input ${wl}$lib.exp $compiler_flags $libobjs $deplibs -soname $soname `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~$RM $lib.exp' |
da0f6381 | 15518 | |
00020c16 ILT |
15519 | # Both c and cxx compiler support -rpath directly |
15520 | hardcode_libdir_flag_spec='-rpath $libdir' | |
15521 | fi | |
15522 | archive_cmds_need_lc='no' | |
15523 | hardcode_libdir_separator=: | |
15524 | ;; | |
da0f6381 | 15525 | |
00020c16 ILT |
15526 | solaris*) |
15527 | no_undefined_flag=' -z defs' | |
15528 | if test "$GCC" = yes; then | |
15529 | wlarc='${wl}' | |
15530 | archive_cmds='$CC -shared ${wl}-z ${wl}text ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15531 | archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
15532 | $CC -shared ${wl}-z ${wl}text ${wl}-M ${wl}$lib.exp ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
15533 | else | |
15534 | case `$CC -V 2>&1` in | |
15535 | *"Compilers 5.0"*) | |
15536 | wlarc='' | |
15537 | archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15538 | archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
15539 | $LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$RM $lib.exp' | |
15540 | ;; | |
15541 | *) | |
15542 | wlarc='${wl}' | |
15543 | archive_cmds='$CC -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $compiler_flags' | |
15544 | archive_expsym_cmds='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
15545 | $CC -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $compiler_flags~$RM $lib.exp' | |
15546 | ;; | |
15547 | esac | |
15548 | fi | |
15549 | hardcode_libdir_flag_spec='-R$libdir' | |
15550 | hardcode_shlibpath_var=no | |
15551 | case $host_os in | |
15552 | solaris2.[0-5] | solaris2.[0-5].*) ;; | |
15553 | *) | |
15554 | # The compiler driver will combine and reorder linker options, | |
15555 | # but understands `-z linker_flag'. GCC discards it without `$wl', | |
15556 | # but is careful enough not to reorder. | |
15557 | # Supported since Solaris 2.6 (maybe 2.5.1?) | |
15558 | if test "$GCC" = yes; then | |
15559 | whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' | |
15560 | else | |
15561 | whole_archive_flag_spec='-z allextract$convenience -z defaultextract' | |
15562 | fi | |
15563 | ;; | |
15564 | esac | |
15565 | link_all_deplibs=yes | |
15566 | ;; | |
da0f6381 | 15567 | |
00020c16 ILT |
15568 | sunos4*) |
15569 | if test "x$host_vendor" = xsequent; then | |
15570 | # Use $CC to link under sequent, because it throws in some extra .o | |
15571 | # files that make .init and .fini sections work. | |
15572 | archive_cmds='$CC -G ${wl}-h $soname -o $lib $libobjs $deplibs $compiler_flags' | |
15573 | else | |
15574 | archive_cmds='$LD -assert pure-text -Bstatic -o $lib $libobjs $deplibs $linker_flags' | |
15575 | fi | |
15576 | hardcode_libdir_flag_spec='-L$libdir' | |
15577 | hardcode_direct=yes | |
15578 | hardcode_minus_L=yes | |
15579 | hardcode_shlibpath_var=no | |
15580 | ;; | |
da0f6381 | 15581 | |
00020c16 ILT |
15582 | sysv4) |
15583 | case $host_vendor in | |
15584 | sni) | |
15585 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15586 | hardcode_direct=yes # is this really true??? | |
15587 | ;; | |
15588 | siemens) | |
15589 | ## LD is ld it makes a PLAMLIB | |
15590 | ## CC just makes a GrossModule. | |
15591 | archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags' | |
15592 | reload_cmds='$CC -r -o $output$reload_objs' | |
15593 | hardcode_direct=no | |
15594 | ;; | |
15595 | motorola) | |
15596 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15597 | hardcode_direct=no #Motorola manual says yes, but my tests say they lie | |
15598 | ;; | |
15599 | esac | |
15600 | runpath_var='LD_RUN_PATH' | |
15601 | hardcode_shlibpath_var=no | |
15602 | ;; | |
da0f6381 | 15603 | |
00020c16 ILT |
15604 | sysv4.3*) |
15605 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15606 | hardcode_shlibpath_var=no | |
15607 | export_dynamic_flag_spec='-Bexport' | |
15608 | ;; | |
da0f6381 | 15609 | |
00020c16 ILT |
15610 | sysv4*MP*) |
15611 | if test -d /usr/nec; then | |
15612 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15613 | hardcode_shlibpath_var=no | |
15614 | runpath_var=LD_RUN_PATH | |
15615 | hardcode_runpath_var=yes | |
15616 | ld_shlibs=yes | |
15617 | fi | |
15618 | ;; | |
da0f6381 | 15619 | |
00020c16 ILT |
15620 | sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) |
15621 | no_undefined_flag='${wl}-z,text' | |
15622 | archive_cmds_need_lc=no | |
15623 | hardcode_shlibpath_var=no | |
15624 | runpath_var='LD_RUN_PATH' | |
da0f6381 | 15625 | |
00020c16 ILT |
15626 | if test "$GCC" = yes; then |
15627 | archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15628 | archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15629 | else | |
15630 | archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15631 | archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15632 | fi | |
15633 | ;; | |
da0f6381 | 15634 | |
00020c16 ILT |
15635 | sysv5* | sco3.2v5* | sco5v6*) |
15636 | # Note: We can NOT use -z defs as we might desire, because we do not | |
15637 | # link with -lc, and that would cause any symbols used from libc to | |
15638 | # always be unresolved, which means just about no library would | |
15639 | # ever link correctly. If we're not using GNU ld we use -z text | |
15640 | # though, which does catch some bad symbols but isn't as heavy-handed | |
15641 | # as -z defs. | |
15642 | no_undefined_flag='${wl}-z,text' | |
15643 | allow_undefined_flag='${wl}-z,nodefs' | |
15644 | archive_cmds_need_lc=no | |
15645 | hardcode_shlibpath_var=no | |
15646 | hardcode_libdir_flag_spec='${wl}-R,$libdir' | |
15647 | hardcode_libdir_separator=':' | |
15648 | link_all_deplibs=yes | |
15649 | export_dynamic_flag_spec='${wl}-Bexport' | |
15650 | runpath_var='LD_RUN_PATH' | |
da0f6381 | 15651 | |
00020c16 ILT |
15652 | if test "$GCC" = yes; then |
15653 | archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15654 | archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15655 | else | |
15656 | archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15657 | archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
15658 | fi | |
15659 | ;; | |
da0f6381 | 15660 | |
00020c16 ILT |
15661 | uts4*) |
15662 | archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags' | |
15663 | hardcode_libdir_flag_spec='-L$libdir' | |
15664 | hardcode_shlibpath_var=no | |
15665 | ;; | |
da0f6381 | 15666 | |
00020c16 ILT |
15667 | *) |
15668 | ld_shlibs=no | |
15669 | ;; | |
15670 | esac | |
da0f6381 | 15671 | |
00020c16 ILT |
15672 | if test x$host_vendor = xsni; then |
15673 | case $host in | |
15674 | sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*) | |
15675 | export_dynamic_flag_spec='${wl}-Blargedynsym' | |
15676 | ;; | |
15677 | esac | |
15678 | fi | |
15679 | fi | |
da0f6381 | 15680 | |
5213506e RW |
15681 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs" >&5 |
15682 | $as_echo "$ld_shlibs" >&6; } | |
00020c16 | 15683 | test "$ld_shlibs" = no && can_build_shared=no |
da0f6381 | 15684 | |
00020c16 | 15685 | with_gnu_ld=$with_gnu_ld |
da0f6381 PB |
15686 | |
15687 | ||
15688 | ||
15689 | ||
15690 | ||
15691 | ||
15692 | ||
15693 | ||
15694 | ||
15695 | ||
15696 | ||
15697 | ||
15698 | ||
15699 | ||
15700 | ||
00020c16 ILT |
15701 | # |
15702 | # Do we need to explicitly link libc? | |
15703 | # | |
15704 | case "x$archive_cmds_need_lc" in | |
15705 | x|xyes) | |
15706 | # Assume -lc should be added | |
15707 | archive_cmds_need_lc=yes | |
da0f6381 | 15708 | |
00020c16 ILT |
15709 | if test "$enable_shared" = yes && test "$GCC" = yes; then |
15710 | case $archive_cmds in | |
15711 | *'~'*) | |
15712 | # FIXME: we may have to deal with multi-command sequences. | |
15713 | ;; | |
15714 | '$CC '*) | |
15715 | # Test whether the compiler implicitly links with -lc since on some | |
15716 | # systems, -lgcc has to come before -lc. If gcc already passes -lc | |
15717 | # to ld, don't add -lc before -lgcc. | |
5213506e RW |
15718 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 |
15719 | $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } | |
15720 | if test "${lt_cv_archive_cmds_need_lc+set}" = set; then : | |
15721 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
15722 | else |
15723 | $RM conftest* | |
15724 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
da0f6381 | 15725 | |
5213506e | 15726 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
00020c16 ILT |
15727 | (eval $ac_compile) 2>&5 |
15728 | ac_status=$? | |
5213506e RW |
15729 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
15730 | test $ac_status = 0; } 2>conftest.err; then | |
00020c16 ILT |
15731 | soname=conftest |
15732 | lib=conftest | |
15733 | libobjs=conftest.$ac_objext | |
15734 | deplibs= | |
15735 | wl=$lt_prog_compiler_wl | |
15736 | pic_flag=$lt_prog_compiler_pic | |
15737 | compiler_flags=-v | |
15738 | linker_flags=-v | |
15739 | verstring= | |
15740 | output_objdir=. | |
15741 | libname=conftest | |
15742 | lt_save_allow_undefined_flag=$allow_undefined_flag | |
15743 | allow_undefined_flag= | |
5213506e | 15744 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 |
00020c16 ILT |
15745 | (eval $archive_cmds 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 |
15746 | ac_status=$? | |
5213506e RW |
15747 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
15748 | test $ac_status = 0; } | |
00020c16 ILT |
15749 | then |
15750 | lt_cv_archive_cmds_need_lc=no | |
15751 | else | |
15752 | lt_cv_archive_cmds_need_lc=yes | |
15753 | fi | |
15754 | allow_undefined_flag=$lt_save_allow_undefined_flag | |
15755 | else | |
15756 | cat conftest.err 1>&5 | |
15757 | fi | |
15758 | $RM conftest* | |
da0f6381 | 15759 | |
00020c16 | 15760 | fi |
5213506e RW |
15761 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc" >&5 |
15762 | $as_echo "$lt_cv_archive_cmds_need_lc" >&6; } | |
00020c16 ILT |
15763 | archive_cmds_need_lc=$lt_cv_archive_cmds_need_lc |
15764 | ;; | |
15765 | esac | |
15766 | fi | |
15767 | ;; | |
15768 | esac | |
da0f6381 PB |
15769 | |
15770 | ||
15771 | ||
15772 | ||
5d47bb02 | 15773 | |
da0f6381 | 15774 | |
da0f6381 | 15775 | |
da0f6381 | 15776 | |
da0f6381 | 15777 | |
00020c16 ILT |
15778 | |
15779 | ||
15780 | ||
15781 | ||
15782 | ||
15783 | ||
15784 | ||
15785 | ||
15786 | ||
15787 | ||
15788 | ||
15789 | ||
15790 | ||
15791 | ||
15792 | ||
15793 | ||
15794 | ||
15795 | ||
15796 | ||
15797 | ||
15798 | ||
15799 | ||
15800 | ||
15801 | ||
15802 | ||
15803 | ||
15804 | ||
15805 | ||
15806 | ||
15807 | ||
15808 | ||
15809 | ||
15810 | ||
15811 | ||
15812 | ||
15813 | ||
15814 | ||
15815 | ||
15816 | ||
15817 | ||
15818 | ||
15819 | ||
15820 | ||
15821 | ||
15822 | ||
15823 | ||
15824 | ||
15825 | ||
15826 | ||
15827 | ||
15828 | ||
15829 | ||
15830 | ||
15831 | ||
15832 | ||
15833 | ||
15834 | ||
15835 | ||
15836 | ||
15837 | ||
15838 | ||
15839 | ||
15840 | ||
15841 | ||
15842 | ||
15843 | ||
15844 | ||
15845 | ||
15846 | ||
15847 | ||
15848 | ||
15849 | ||
15850 | ||
15851 | ||
15852 | ||
15853 | ||
15854 | ||
15855 | ||
15856 | ||
15857 | ||
15858 | ||
15859 | ||
15860 | ||
15861 | ||
15862 | ||
15863 | ||
15864 | ||
15865 | ||
15866 | ||
15867 | ||
15868 | ||
15869 | ||
15870 | ||
15871 | ||
15872 | ||
15873 | ||
15874 | ||
15875 | ||
15876 | ||
15877 | ||
15878 | ||
15879 | ||
15880 | ||
15881 | ||
15882 | ||
15883 | ||
15884 | ||
15885 | ||
15886 | ||
15887 | ||
15888 | ||
15889 | ||
15890 | ||
15891 | ||
15892 | ||
15893 | ||
15894 | ||
15895 | ||
15896 | ||
15897 | ||
15898 | ||
15899 | ||
15900 | ||
15901 | ||
15902 | ||
15903 | ||
15904 | ||
15905 | ||
15906 | ||
15907 | ||
15908 | ||
15909 | ||
15910 | ||
15911 | ||
15912 | ||
15913 | ||
15914 | ||
15915 | ||
15916 | ||
15917 | ||
15918 | ||
15919 | ||
15920 | ||
15921 | ||
15922 | ||
15923 | ||
15924 | ||
15925 | ||
5213506e RW |
15926 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 |
15927 | $as_echo_n "checking dynamic linker characteristics... " >&6; } | |
00020c16 ILT |
15928 | |
15929 | if test "$GCC" = yes; then | |
15930 | case $host_os in | |
15931 | darwin*) lt_awk_arg="/^libraries:/,/LR/" ;; | |
15932 | *) lt_awk_arg="/^libraries:/" ;; | |
15933 | esac | |
43e02a8a RW |
15934 | case $host_os in |
15935 | mingw* | cegcc*) lt_sed_strip_eq="s,=\([A-Za-z]:\),\1,g" ;; | |
15936 | *) lt_sed_strip_eq="s,=/,/,g" ;; | |
15937 | esac | |
15938 | lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e $lt_sed_strip_eq` | |
15939 | case $lt_search_path_spec in | |
15940 | *\;*) | |
00020c16 ILT |
15941 | # if the path contains ";" then we assume it to be the separator |
15942 | # otherwise default to the standard path separator (i.e. ":") - it is | |
15943 | # assumed that no part of a normal pathname contains ";" but that should | |
15944 | # okay in the real world where ";" in dirpaths is itself problematic. | |
43e02a8a RW |
15945 | lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED 's/;/ /g'` |
15946 | ;; | |
15947 | *) | |
15948 | lt_search_path_spec=`$ECHO "$lt_search_path_spec" | $SED "s/$PATH_SEPARATOR/ /g"` | |
15949 | ;; | |
15950 | esac | |
00020c16 ILT |
15951 | # Ok, now we have the path, separated by spaces, we can step through it |
15952 | # and add multilib dir if necessary. | |
15953 | lt_tmp_lt_search_path_spec= | |
15954 | lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null` | |
15955 | for lt_sys_path in $lt_search_path_spec; do | |
15956 | if test -d "$lt_sys_path/$lt_multi_os_dir"; then | |
15957 | lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir" | |
15958 | else | |
15959 | test -d "$lt_sys_path" && \ | |
15960 | lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path" | |
15961 | fi | |
15962 | done | |
43e02a8a | 15963 | lt_search_path_spec=`$ECHO "$lt_tmp_lt_search_path_spec" | awk ' |
00020c16 ILT |
15964 | BEGIN {RS=" "; FS="/|\n";} { |
15965 | lt_foo=""; | |
15966 | lt_count=0; | |
15967 | for (lt_i = NF; lt_i > 0; lt_i--) { | |
15968 | if ($lt_i != "" && $lt_i != ".") { | |
15969 | if ($lt_i == "..") { | |
15970 | lt_count++; | |
15971 | } else { | |
15972 | if (lt_count == 0) { | |
15973 | lt_foo="/" $lt_i lt_foo; | |
15974 | } else { | |
15975 | lt_count--; | |
15976 | } | |
15977 | } | |
15978 | } | |
15979 | } | |
15980 | if (lt_foo != "") { lt_freq[lt_foo]++; } | |
15981 | if (lt_freq[lt_foo] == 1) { print lt_foo; } | |
15982 | }'` | |
43e02a8a RW |
15983 | # AWK program above erroneously prepends '/' to C:/dos/paths |
15984 | # for these hosts. | |
15985 | case $host_os in | |
15986 | mingw* | cegcc*) lt_search_path_spec=`$ECHO "$lt_search_path_spec" |\ | |
15987 | $SED 's,/\([A-Za-z]:\),\1,g'` ;; | |
15988 | esac | |
15989 | sys_lib_search_path_spec=`$ECHO "$lt_search_path_spec" | $lt_NL2SP` | |
00020c16 ILT |
15990 | else |
15991 | sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib" | |
15992 | fi | |
15993 | library_names_spec= | |
15994 | libname_spec='lib$name' | |
15995 | soname_spec= | |
15996 | shrext_cmds=".so" | |
15997 | postinstall_cmds= | |
15998 | postuninstall_cmds= | |
15999 | finish_cmds= | |
16000 | finish_eval= | |
16001 | shlibpath_var= | |
16002 | shlibpath_overrides_runpath=unknown | |
16003 | version_type=none | |
16004 | dynamic_linker="$host_os ld.so" | |
16005 | sys_lib_dlsearch_path_spec="/lib /usr/lib" | |
16006 | need_lib_prefix=unknown | |
16007 | hardcode_into_libs=no | |
16008 | ||
16009 | # when you set need_version to no, make sure it does not cause -set_version | |
16010 | # flags to be left without arguments | |
16011 | need_version=unknown | |
16012 | ||
16013 | case $host_os in | |
16014 | aix3*) | |
16015 | version_type=linux | |
16016 | library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' | |
16017 | shlibpath_var=LIBPATH | |
16018 | ||
16019 | # AIX 3 has no versioning support, so we append a major version to the name. | |
16020 | soname_spec='${libname}${release}${shared_ext}$major' | |
16021 | ;; | |
16022 | ||
16023 | aix[4-9]*) | |
16024 | version_type=linux | |
16025 | need_lib_prefix=no | |
16026 | need_version=no | |
16027 | hardcode_into_libs=yes | |
16028 | if test "$host_cpu" = ia64; then | |
16029 | # AIX 5 supports IA64 | |
16030 | library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' | |
16031 | shlibpath_var=LD_LIBRARY_PATH | |
16032 | else | |
16033 | # With GCC up to 2.95.x, collect2 would create an import file | |
16034 | # for dependence libraries. The import file would start with | |
16035 | # the line `#! .'. This would cause the generated library to | |
16036 | # depend on `.', always an invalid library. This was fixed in | |
16037 | # development snapshots of GCC prior to 3.0. | |
16038 | case $host_os in | |
16039 | aix4 | aix4.[01] | aix4.[01].*) | |
16040 | if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' | |
16041 | echo ' yes ' | |
da0f6381 PB |
16042 | echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then |
16043 | : | |
16044 | else | |
16045 | can_build_shared=no | |
16046 | fi | |
16047 | ;; | |
16048 | esac | |
16049 | # AIX (on Power*) has no versioning support, so currently we can not hardcode correct | |
16050 | # soname into executable. Probably we can add versioning support to | |
16051 | # collect2, so additional links can be useful in future. | |
16052 | if test "$aix_use_runtimelinking" = yes; then | |
16053 | # If using run time linking (on AIX 4.2 or later) use lib<name>.so | |
16054 | # instead of lib<name>.a to let people know that these are not | |
16055 | # typical AIX shared libraries. | |
16056 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16057 | else | |
16058 | # We preserve .a as extension for shared libraries through AIX4.2 | |
16059 | # and later when we are not doing run time linking. | |
16060 | library_names_spec='${libname}${release}.a $libname.a' | |
16061 | soname_spec='${libname}${release}${shared_ext}$major' | |
16062 | fi | |
16063 | shlibpath_var=LIBPATH | |
16064 | fi | |
16065 | ;; | |
16066 | ||
16067 | amigaos*) | |
5d47bb02 PG |
16068 | case $host_cpu in |
16069 | powerpc) | |
16070 | # Since July 2007 AmigaOS4 officially supports .so libraries. | |
16071 | # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. | |
16072 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16073 | ;; | |
16074 | m68k) | |
da0f6381 PB |
16075 | library_names_spec='$libname.ixlibrary $libname.a' |
16076 | # Create ${libname}_ixlibrary.a entries in /sys/libs. | |
43e02a8a | 16077 | finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' |
5d47bb02 PG |
16078 | ;; |
16079 | esac | |
da0f6381 PB |
16080 | ;; |
16081 | ||
16082 | beos*) | |
16083 | library_names_spec='${libname}${shared_ext}' | |
16084 | dynamic_linker="$host_os ld.so" | |
16085 | shlibpath_var=LIBRARY_PATH | |
16086 | ;; | |
16087 | ||
16088 | bsdi[45]*) | |
16089 | version_type=linux | |
16090 | need_version=no | |
16091 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16092 | soname_spec='${libname}${release}${shared_ext}$major' | |
16093 | finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' | |
16094 | shlibpath_var=LD_LIBRARY_PATH | |
16095 | sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" | |
16096 | sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" | |
16097 | # the default ld.so.conf also contains /usr/contrib/lib and | |
16098 | # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow | |
16099 | # libtool to hard-code these into programs | |
16100 | ;; | |
16101 | ||
5d47bb02 | 16102 | cygwin* | mingw* | pw32* | cegcc*) |
da0f6381 PB |
16103 | version_type=windows |
16104 | shrext_cmds=".dll" | |
16105 | need_version=no | |
16106 | need_lib_prefix=no | |
16107 | ||
5d47bb02 PG |
16108 | case $GCC,$host_os in |
16109 | yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) | |
da0f6381 PB |
16110 | library_names_spec='$libname.dll.a' |
16111 | # DLL is installed to $(libdir)/../bin by postinstall_cmds | |
16112 | postinstall_cmds='base_file=`basename \${file}`~ | |
16113 | dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ | |
16114 | dldir=$destdir/`dirname \$dlpath`~ | |
16115 | test -d \$dldir || mkdir -p \$dldir~ | |
16116 | $install_prog $dir/$dlname \$dldir/$dlname~ | |
16117 | chmod a+x \$dldir/$dlname~ | |
16118 | if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then | |
16119 | eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; | |
16120 | fi' | |
16121 | postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ | |
16122 | dlpath=$dir/\$dldll~ | |
16123 | $RM \$dlpath' | |
16124 | shlibpath_overrides_runpath=yes | |
16125 | ||
16126 | case $host_os in | |
16127 | cygwin*) | |
16128 | # Cygwin DLLs use 'cyg' prefix rather than 'lib' | |
16129 | soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
43e02a8a RW |
16130 | |
16131 | sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/lib/w32api" | |
da0f6381 | 16132 | ;; |
5d47bb02 | 16133 | mingw* | cegcc*) |
da0f6381 PB |
16134 | # MinGW DLLs use traditional 'lib' prefix |
16135 | soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
da0f6381 PB |
16136 | ;; |
16137 | pw32*) | |
16138 | # pw32 DLLs use 'pw' prefix rather than 'lib' | |
16139 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
16140 | ;; | |
16141 | esac | |
16142 | ;; | |
16143 | ||
16144 | *) | |
16145 | library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' | |
16146 | ;; | |
16147 | esac | |
16148 | dynamic_linker='Win32 ld.exe' | |
16149 | # FIXME: first we should search . and the directory the executable is in | |
16150 | shlibpath_var=PATH | |
16151 | ;; | |
16152 | ||
16153 | darwin* | rhapsody*) | |
16154 | dynamic_linker="$host_os dyld" | |
16155 | version_type=darwin | |
16156 | need_lib_prefix=no | |
16157 | need_version=no | |
16158 | library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' | |
16159 | soname_spec='${libname}${release}${major}$shared_ext' | |
16160 | shlibpath_overrides_runpath=yes | |
16161 | shlibpath_var=DYLD_LIBRARY_PATH | |
16162 | shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' | |
16163 | ||
16164 | sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" | |
16165 | sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' | |
16166 | ;; | |
16167 | ||
16168 | dgux*) | |
16169 | version_type=linux | |
16170 | need_lib_prefix=no | |
16171 | need_version=no | |
16172 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' | |
16173 | soname_spec='${libname}${release}${shared_ext}$major' | |
16174 | shlibpath_var=LD_LIBRARY_PATH | |
16175 | ;; | |
16176 | ||
16177 | freebsd1*) | |
16178 | dynamic_linker=no | |
16179 | ;; | |
16180 | ||
16181 | freebsd* | dragonfly*) | |
16182 | # DragonFly does not have aout. When/if they implement a new | |
16183 | # versioning mechanism, adjust this. | |
16184 | if test -x /usr/bin/objformat; then | |
16185 | objformat=`/usr/bin/objformat` | |
16186 | else | |
16187 | case $host_os in | |
16188 | freebsd[123]*) objformat=aout ;; | |
16189 | *) objformat=elf ;; | |
16190 | esac | |
16191 | fi | |
16192 | version_type=freebsd-$objformat | |
16193 | case $version_type in | |
16194 | freebsd-elf*) | |
16195 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' | |
16196 | need_version=no | |
16197 | need_lib_prefix=no | |
16198 | ;; | |
16199 | freebsd-*) | |
16200 | library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' | |
16201 | need_version=yes | |
16202 | ;; | |
16203 | esac | |
16204 | shlibpath_var=LD_LIBRARY_PATH | |
16205 | case $host_os in | |
16206 | freebsd2*) | |
16207 | shlibpath_overrides_runpath=yes | |
16208 | ;; | |
16209 | freebsd3.[01]* | freebsdelf3.[01]*) | |
16210 | shlibpath_overrides_runpath=yes | |
16211 | hardcode_into_libs=yes | |
16212 | ;; | |
16213 | freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ | |
16214 | freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) | |
16215 | shlibpath_overrides_runpath=no | |
16216 | hardcode_into_libs=yes | |
16217 | ;; | |
16218 | *) # from 4.6 on, and DragonFly | |
16219 | shlibpath_overrides_runpath=yes | |
16220 | hardcode_into_libs=yes | |
16221 | ;; | |
16222 | esac | |
16223 | ;; | |
16224 | ||
16225 | gnu*) | |
16226 | version_type=linux | |
16227 | need_lib_prefix=no | |
16228 | need_version=no | |
16229 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' | |
16230 | soname_spec='${libname}${release}${shared_ext}$major' | |
16231 | shlibpath_var=LD_LIBRARY_PATH | |
16232 | hardcode_into_libs=yes | |
16233 | ;; | |
16234 | ||
43e02a8a RW |
16235 | haiku*) |
16236 | version_type=linux | |
16237 | need_lib_prefix=no | |
16238 | need_version=no | |
16239 | dynamic_linker="$host_os runtime_loader" | |
16240 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' | |
16241 | soname_spec='${libname}${release}${shared_ext}$major' | |
16242 | shlibpath_var=LIBRARY_PATH | |
16243 | shlibpath_overrides_runpath=yes | |
16244 | sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib' | |
16245 | hardcode_into_libs=yes | |
16246 | ;; | |
16247 | ||
da0f6381 PB |
16248 | hpux9* | hpux10* | hpux11*) |
16249 | # Give a soname corresponding to the major version so that dld.sl refuses to | |
16250 | # link against other versions. | |
16251 | version_type=sunos | |
16252 | need_lib_prefix=no | |
16253 | need_version=no | |
16254 | case $host_cpu in | |
16255 | ia64*) | |
16256 | shrext_cmds='.so' | |
16257 | hardcode_into_libs=yes | |
16258 | dynamic_linker="$host_os dld.so" | |
16259 | shlibpath_var=LD_LIBRARY_PATH | |
16260 | shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. | |
16261 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16262 | soname_spec='${libname}${release}${shared_ext}$major' | |
16263 | if test "X$HPUX_IA64_MODE" = X32; then | |
16264 | sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" | |
16265 | else | |
16266 | sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" | |
16267 | fi | |
16268 | sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec | |
16269 | ;; | |
16270 | hppa*64*) | |
16271 | shrext_cmds='.sl' | |
16272 | hardcode_into_libs=yes | |
16273 | dynamic_linker="$host_os dld.sl" | |
16274 | shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH | |
16275 | shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. | |
16276 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16277 | soname_spec='${libname}${release}${shared_ext}$major' | |
16278 | sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" | |
16279 | sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec | |
16280 | ;; | |
16281 | *) | |
16282 | shrext_cmds='.sl' | |
16283 | dynamic_linker="$host_os dld.sl" | |
16284 | shlibpath_var=SHLIB_PATH | |
16285 | shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH | |
16286 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16287 | soname_spec='${libname}${release}${shared_ext}$major' | |
16288 | ;; | |
16289 | esac | |
43e02a8a | 16290 | # HP-UX runs *really* slowly unless shared libraries are mode 555, ... |
da0f6381 | 16291 | postinstall_cmds='chmod 555 $lib' |
43e02a8a RW |
16292 | # or fails outright, so override atomically: |
16293 | install_override_mode=555 | |
da0f6381 PB |
16294 | ;; |
16295 | ||
16296 | interix[3-9]*) | |
16297 | version_type=linux | |
16298 | need_lib_prefix=no | |
16299 | need_version=no | |
16300 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' | |
16301 | soname_spec='${libname}${release}${shared_ext}$major' | |
16302 | dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' | |
16303 | shlibpath_var=LD_LIBRARY_PATH | |
16304 | shlibpath_overrides_runpath=no | |
16305 | hardcode_into_libs=yes | |
16306 | ;; | |
16307 | ||
16308 | irix5* | irix6* | nonstopux*) | |
16309 | case $host_os in | |
16310 | nonstopux*) version_type=nonstopux ;; | |
16311 | *) | |
16312 | if test "$lt_cv_prog_gnu_ld" = yes; then | |
16313 | version_type=linux | |
16314 | else | |
16315 | version_type=irix | |
16316 | fi ;; | |
16317 | esac | |
16318 | need_lib_prefix=no | |
16319 | need_version=no | |
16320 | soname_spec='${libname}${release}${shared_ext}$major' | |
16321 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' | |
16322 | case $host_os in | |
16323 | irix5* | nonstopux*) | |
16324 | libsuff= shlibsuff= | |
16325 | ;; | |
16326 | *) | |
16327 | case $LD in # libtool.m4 will add one of these switches to LD | |
16328 | *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") | |
16329 | libsuff= shlibsuff= libmagic=32-bit;; | |
16330 | *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") | |
16331 | libsuff=32 shlibsuff=N32 libmagic=N32;; | |
16332 | *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") | |
16333 | libsuff=64 shlibsuff=64 libmagic=64-bit;; | |
16334 | *) libsuff= shlibsuff= libmagic=never-match;; | |
16335 | esac | |
16336 | ;; | |
16337 | esac | |
16338 | shlibpath_var=LD_LIBRARY${shlibsuff}_PATH | |
16339 | shlibpath_overrides_runpath=no | |
16340 | sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" | |
16341 | sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" | |
16342 | hardcode_into_libs=yes | |
16343 | ;; | |
16344 | ||
16345 | # No shared lib support for Linux oldld, aout, or coff. | |
16346 | linux*oldld* | linux*aout* | linux*coff*) | |
16347 | dynamic_linker=no | |
16348 | ;; | |
16349 | ||
16350 | # This must be Linux ELF. | |
7a9d3fe8 | 16351 | linux* | k*bsd*-gnu | kopensolaris*-gnu) |
da0f6381 PB |
16352 | version_type=linux |
16353 | need_lib_prefix=no | |
16354 | need_version=no | |
16355 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16356 | soname_spec='${libname}${release}${shared_ext}$major' | |
16357 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' | |
16358 | shlibpath_var=LD_LIBRARY_PATH | |
16359 | shlibpath_overrides_runpath=no | |
baafc534 | 16360 | |
da0f6381 | 16361 | # Some binutils ld are patched to set DT_RUNPATH |
5213506e RW |
16362 | if test "${lt_cv_shlibpath_overrides_runpath+set}" = set; then : |
16363 | $as_echo_n "(cached) " >&6 | |
baafc534 RW |
16364 | else |
16365 | lt_cv_shlibpath_overrides_runpath=no | |
16366 | save_LDFLAGS=$LDFLAGS | |
16367 | save_libdir=$libdir | |
16368 | eval "libdir=/foo; wl=\"$lt_prog_compiler_wl\"; \ | |
16369 | LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec\"" | |
5213506e | 16370 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
da0f6381 PB |
16371 | /* end confdefs.h. */ |
16372 | ||
16373 | int | |
16374 | main () | |
16375 | { | |
16376 | ||
16377 | ; | |
16378 | return 0; | |
16379 | } | |
16380 | _ACEOF | |
5213506e RW |
16381 | if ac_fn_c_try_link "$LINENO"; then : |
16382 | if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : | |
baafc534 | 16383 | lt_cv_shlibpath_overrides_runpath=yes |
da0f6381 | 16384 | fi |
da0f6381 | 16385 | fi |
5213506e RW |
16386 | rm -f core conftest.err conftest.$ac_objext \ |
16387 | conftest$ac_exeext conftest.$ac_ext | |
baafc534 RW |
16388 | LDFLAGS=$save_LDFLAGS |
16389 | libdir=$save_libdir | |
16390 | ||
16391 | fi | |
16392 | ||
16393 | shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath | |
da0f6381 PB |
16394 | |
16395 | # This implies no fast_install, which is unacceptable. | |
16396 | # Some rework will be needed to allow for fast_install | |
16397 | # before this can be enabled. | |
16398 | hardcode_into_libs=yes | |
16399 | ||
16400 | # Append ld.so.conf contents to the search path | |
16401 | if test -f /etc/ld.so.conf; then | |
43e02a8a | 16402 | lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` |
da0f6381 PB |
16403 | sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" |
16404 | fi | |
16405 | ||
16406 | # We used to test for /lib/ld.so.1 and disable shared libraries on | |
16407 | # powerpc, because MkLinux only supported shared libraries with the | |
16408 | # GNU dynamic linker. Since this was broken with cross compilers, | |
16409 | # most powerpc-linux boxes support dynamic linking these days and | |
16410 | # people can always --disable-shared, the test was removed, and we | |
16411 | # assume the GNU/Linux dynamic linker is in use. | |
16412 | dynamic_linker='GNU/Linux ld.so' | |
16413 | ;; | |
16414 | ||
16415 | netbsd*) | |
16416 | version_type=sunos | |
16417 | need_lib_prefix=no | |
16418 | need_version=no | |
16419 | if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then | |
16420 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' | |
16421 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' | |
16422 | dynamic_linker='NetBSD (a.out) ld.so' | |
16423 | else | |
16424 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' | |
16425 | soname_spec='${libname}${release}${shared_ext}$major' | |
16426 | dynamic_linker='NetBSD ld.elf_so' | |
16427 | fi | |
16428 | shlibpath_var=LD_LIBRARY_PATH | |
16429 | shlibpath_overrides_runpath=yes | |
16430 | hardcode_into_libs=yes | |
16431 | ;; | |
16432 | ||
16433 | newsos6) | |
16434 | version_type=linux | |
16435 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16436 | shlibpath_var=LD_LIBRARY_PATH | |
16437 | shlibpath_overrides_runpath=yes | |
16438 | ;; | |
16439 | ||
16440 | *nto* | *qnx*) | |
16441 | version_type=qnx | |
16442 | need_lib_prefix=no | |
16443 | need_version=no | |
16444 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16445 | soname_spec='${libname}${release}${shared_ext}$major' | |
16446 | shlibpath_var=LD_LIBRARY_PATH | |
16447 | shlibpath_overrides_runpath=no | |
16448 | hardcode_into_libs=yes | |
16449 | dynamic_linker='ldqnx.so' | |
16450 | ;; | |
16451 | ||
16452 | openbsd*) | |
16453 | version_type=sunos | |
16454 | sys_lib_dlsearch_path_spec="/usr/lib" | |
16455 | need_lib_prefix=no | |
16456 | # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. | |
16457 | case $host_os in | |
16458 | openbsd3.3 | openbsd3.3.*) need_version=yes ;; | |
16459 | *) need_version=no ;; | |
16460 | esac | |
16461 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' | |
16462 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' | |
16463 | shlibpath_var=LD_LIBRARY_PATH | |
16464 | if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then | |
16465 | case $host_os in | |
16466 | openbsd2.[89] | openbsd2.[89].*) | |
16467 | shlibpath_overrides_runpath=no | |
16468 | ;; | |
16469 | *) | |
16470 | shlibpath_overrides_runpath=yes | |
16471 | ;; | |
16472 | esac | |
16473 | else | |
16474 | shlibpath_overrides_runpath=yes | |
16475 | fi | |
16476 | ;; | |
16477 | ||
16478 | os2*) | |
16479 | libname_spec='$name' | |
16480 | shrext_cmds=".dll" | |
16481 | need_lib_prefix=no | |
16482 | library_names_spec='$libname${shared_ext} $libname.a' | |
16483 | dynamic_linker='OS/2 ld.exe' | |
16484 | shlibpath_var=LIBPATH | |
16485 | ;; | |
16486 | ||
16487 | osf3* | osf4* | osf5*) | |
16488 | version_type=osf | |
16489 | need_lib_prefix=no | |
16490 | need_version=no | |
16491 | soname_spec='${libname}${release}${shared_ext}$major' | |
16492 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16493 | shlibpath_var=LD_LIBRARY_PATH | |
16494 | sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" | |
16495 | sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" | |
16496 | ;; | |
16497 | ||
16498 | rdos*) | |
16499 | dynamic_linker=no | |
16500 | ;; | |
16501 | ||
16502 | solaris*) | |
16503 | version_type=linux | |
16504 | need_lib_prefix=no | |
16505 | need_version=no | |
16506 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16507 | soname_spec='${libname}${release}${shared_ext}$major' | |
16508 | shlibpath_var=LD_LIBRARY_PATH | |
16509 | shlibpath_overrides_runpath=yes | |
16510 | hardcode_into_libs=yes | |
16511 | # ldd complains unless libraries are executable | |
16512 | postinstall_cmds='chmod +x $lib' | |
16513 | ;; | |
16514 | ||
16515 | sunos4*) | |
16516 | version_type=sunos | |
16517 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' | |
16518 | finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' | |
16519 | shlibpath_var=LD_LIBRARY_PATH | |
16520 | shlibpath_overrides_runpath=yes | |
16521 | if test "$with_gnu_ld" = yes; then | |
16522 | need_lib_prefix=no | |
16523 | fi | |
16524 | need_version=yes | |
16525 | ;; | |
16526 | ||
16527 | sysv4 | sysv4.3*) | |
16528 | version_type=linux | |
16529 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16530 | soname_spec='${libname}${release}${shared_ext}$major' | |
16531 | shlibpath_var=LD_LIBRARY_PATH | |
16532 | case $host_vendor in | |
16533 | sni) | |
16534 | shlibpath_overrides_runpath=no | |
16535 | need_lib_prefix=no | |
16536 | runpath_var=LD_RUN_PATH | |
16537 | ;; | |
16538 | siemens) | |
16539 | need_lib_prefix=no | |
16540 | ;; | |
16541 | motorola) | |
16542 | need_lib_prefix=no | |
16543 | need_version=no | |
16544 | shlibpath_overrides_runpath=no | |
16545 | sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' | |
16546 | ;; | |
16547 | esac | |
16548 | ;; | |
16549 | ||
16550 | sysv4*MP*) | |
16551 | if test -d /usr/nec ;then | |
16552 | version_type=linux | |
16553 | library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' | |
16554 | soname_spec='$libname${shared_ext}.$major' | |
16555 | shlibpath_var=LD_LIBRARY_PATH | |
16556 | fi | |
16557 | ;; | |
16558 | ||
16559 | sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) | |
16560 | version_type=freebsd-elf | |
16561 | need_lib_prefix=no | |
16562 | need_version=no | |
16563 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' | |
16564 | soname_spec='${libname}${release}${shared_ext}$major' | |
16565 | shlibpath_var=LD_LIBRARY_PATH | |
16566 | shlibpath_overrides_runpath=yes | |
16567 | hardcode_into_libs=yes | |
16568 | if test "$with_gnu_ld" = yes; then | |
16569 | sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' | |
16570 | else | |
16571 | sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' | |
16572 | case $host_os in | |
16573 | sco3.2v5*) | |
16574 | sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" | |
16575 | ;; | |
16576 | esac | |
16577 | fi | |
16578 | sys_lib_dlsearch_path_spec='/usr/lib' | |
16579 | ;; | |
16580 | ||
16581 | tpf*) | |
16582 | # TPF is a cross-target only. Preferred cross-host = GNU/Linux. | |
16583 | version_type=linux | |
16584 | need_lib_prefix=no | |
16585 | need_version=no | |
5d47bb02 | 16586 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' |
da0f6381 PB |
16587 | shlibpath_var=LD_LIBRARY_PATH |
16588 | shlibpath_overrides_runpath=no | |
16589 | hardcode_into_libs=yes | |
16590 | ;; | |
16591 | ||
16592 | uts4*) | |
16593 | version_type=linux | |
16594 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
16595 | soname_spec='${libname}${release}${shared_ext}$major' | |
16596 | shlibpath_var=LD_LIBRARY_PATH | |
16597 | ;; | |
16598 | ||
16599 | *) | |
16600 | dynamic_linker=no | |
16601 | ;; | |
16602 | esac | |
5213506e RW |
16603 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 |
16604 | $as_echo "$dynamic_linker" >&6; } | |
da0f6381 PB |
16605 | test "$dynamic_linker" = no && can_build_shared=no |
16606 | ||
16607 | variables_saved_for_relink="PATH $shlibpath_var $runpath_var" | |
16608 | if test "$GCC" = yes; then | |
16609 | variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" | |
16610 | fi | |
16611 | ||
5d47bb02 PG |
16612 | if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then |
16613 | sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" | |
16614 | fi | |
16615 | if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then | |
16616 | sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" | |
16617 | fi | |
16618 | ||
da0f6381 PB |
16619 | |
16620 | ||
16621 | ||
16622 | ||
16623 | ||
16624 | ||
16625 | ||
16626 | ||
16627 | ||
16628 | ||
16629 | ||
16630 | ||
16631 | ||
16632 | ||
16633 | ||
16634 | ||
16635 | ||
16636 | ||
16637 | ||
16638 | ||
16639 | ||
16640 | ||
16641 | ||
16642 | ||
16643 | ||
16644 | ||
16645 | ||
16646 | ||
16647 | ||
16648 | ||
16649 | ||
16650 | ||
16651 | ||
16652 | ||
16653 | ||
16654 | ||
16655 | ||
16656 | ||
16657 | ||
16658 | ||
16659 | ||
16660 | ||
16661 | ||
16662 | ||
16663 | ||
16664 | ||
16665 | ||
16666 | ||
16667 | ||
16668 | ||
16669 | ||
16670 | ||
16671 | ||
16672 | ||
16673 | ||
16674 | ||
16675 | ||
16676 | ||
16677 | ||
16678 | ||
16679 | ||
16680 | ||
16681 | ||
16682 | ||
16683 | ||
16684 | ||
16685 | ||
16686 | ||
16687 | ||
16688 | ||
16689 | ||
16690 | ||
16691 | ||
16692 | ||
16693 | ||
16694 | ||
16695 | ||
16696 | ||
16697 | ||
16698 | ||
43e02a8a RW |
16699 | |
16700 | ||
16701 | ||
16702 | ||
16703 | ||
da0f6381 PB |
16704 | |
16705 | ||
16706 | ||
16707 | ||
16708 | ||
16709 | ||
5213506e RW |
16710 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 |
16711 | $as_echo_n "checking how to hardcode library paths into programs... " >&6; } | |
da0f6381 PB |
16712 | hardcode_action= |
16713 | if test -n "$hardcode_libdir_flag_spec" || | |
16714 | test -n "$runpath_var" || | |
16715 | test "X$hardcode_automatic" = "Xyes" ; then | |
16716 | ||
16717 | # We can hardcode non-existent directories. | |
16718 | if test "$hardcode_direct" != no && | |
16719 | # If the only mechanism to avoid hardcoding is shlibpath_var, we | |
16720 | # have to relink, otherwise we might link with an installed library | |
16721 | # when we should be linking with a yet-to-be-installed one | |
16722 | ## test "$_LT_TAGVAR(hardcode_shlibpath_var, )" != no && | |
16723 | test "$hardcode_minus_L" != no; then | |
16724 | # Linking always hardcodes the temporary library directory. | |
16725 | hardcode_action=relink | |
16726 | else | |
16727 | # We can link without hardcoding, and we can hardcode nonexisting dirs. | |
16728 | hardcode_action=immediate | |
16729 | fi | |
16730 | else | |
16731 | # We cannot hardcode anything, or else we can only hardcode existing | |
16732 | # directories. | |
16733 | hardcode_action=unsupported | |
16734 | fi | |
5213506e RW |
16735 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action" >&5 |
16736 | $as_echo "$hardcode_action" >&6; } | |
da0f6381 PB |
16737 | |
16738 | if test "$hardcode_action" = relink || | |
16739 | test "$inherit_rpath" = yes; then | |
16740 | # Fast installation is not supported | |
16741 | enable_fast_install=no | |
16742 | elif test "$shlibpath_overrides_runpath" = yes || | |
16743 | test "$enable_shared" = no; then | |
16744 | # Fast installation is not necessary | |
16745 | enable_fast_install=needless | |
16746 | fi | |
16747 | ||
16748 | ||
16749 | ||
16750 | ||
16751 | ||
16752 | ||
16753 | if test "x$enable_dlopen" != xyes; then | |
16754 | enable_dlopen=unknown | |
16755 | enable_dlopen_self=unknown | |
16756 | enable_dlopen_self_static=unknown | |
16757 | else | |
16758 | lt_cv_dlopen=no | |
16759 | lt_cv_dlopen_libs= | |
16760 | ||
16761 | case $host_os in | |
16762 | beos*) | |
16763 | lt_cv_dlopen="load_add_on" | |
16764 | lt_cv_dlopen_libs= | |
16765 | lt_cv_dlopen_self=yes | |
16766 | ;; | |
16767 | ||
5d47bb02 | 16768 | mingw* | pw32* | cegcc*) |
da0f6381 | 16769 | lt_cv_dlopen="LoadLibrary" |
5213506e RW |
16770 | lt_cv_dlopen_libs= |
16771 | ;; | |
da0f6381 | 16772 | |
5213506e RW |
16773 | cygwin*) |
16774 | lt_cv_dlopen="dlopen" | |
16775 | lt_cv_dlopen_libs= | |
16776 | ;; | |
16777 | ||
16778 | darwin*) | |
16779 | # if libdl is installed we need to link against it | |
16780 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 | |
16781 | $as_echo_n "checking for dlopen in -ldl... " >&6; } | |
16782 | if test "${ac_cv_lib_dl_dlopen+set}" = set; then : | |
16783 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
16784 | else |
16785 | ac_check_lib_save_LIBS=$LIBS | |
5213506e RW |
16786 | LIBS="-ldl $LIBS" |
16787 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
da0f6381 PB |
16788 | /* end confdefs.h. */ |
16789 | ||
5213506e RW |
16790 | /* Override any GCC internal prototype to avoid an error. |
16791 | Use char because int might match the return type of a GCC | |
16792 | builtin and then its argument prototype would still apply. */ | |
da0f6381 PB |
16793 | #ifdef __cplusplus |
16794 | extern "C" | |
16795 | #endif | |
5213506e | 16796 | char dlopen (); |
da0f6381 PB |
16797 | int |
16798 | main () | |
16799 | { | |
5213506e | 16800 | return dlopen (); |
da0f6381 PB |
16801 | ; |
16802 | return 0; | |
16803 | } | |
16804 | _ACEOF | |
5213506e RW |
16805 | if ac_fn_c_try_link "$LINENO"; then : |
16806 | ac_cv_lib_dl_dlopen=yes | |
da0f6381 | 16807 | else |
5213506e | 16808 | ac_cv_lib_dl_dlopen=no |
da0f6381 | 16809 | fi |
5213506e RW |
16810 | rm -f core conftest.err conftest.$ac_objext \ |
16811 | conftest$ac_exeext conftest.$ac_ext | |
da0f6381 PB |
16812 | LIBS=$ac_check_lib_save_LIBS |
16813 | fi | |
5213506e RW |
16814 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
16815 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } | |
16816 | if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : | |
16817 | lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" | |
da0f6381 | 16818 | else |
da0f6381 | 16819 | |
5213506e RW |
16820 | lt_cv_dlopen="dyld" |
16821 | lt_cv_dlopen_libs= | |
16822 | lt_cv_dlopen_self=yes | |
da0f6381 | 16823 | |
5213506e | 16824 | fi |
da0f6381 | 16825 | |
5213506e | 16826 | ;; |
da0f6381 | 16827 | |
5213506e RW |
16828 | *) |
16829 | ac_fn_c_check_func "$LINENO" "shl_load" "ac_cv_func_shl_load" | |
16830 | if test "x$ac_cv_func_shl_load" = x""yes; then : | |
16831 | lt_cv_dlopen="shl_load" | |
16832 | else | |
16833 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shl_load in -ldld" >&5 | |
16834 | $as_echo_n "checking for shl_load in -ldld... " >&6; } | |
16835 | if test "${ac_cv_lib_dld_shl_load+set}" = set; then : | |
16836 | $as_echo_n "(cached) " >&6 | |
16837 | else | |
16838 | ac_check_lib_save_LIBS=$LIBS | |
16839 | LIBS="-ldld $LIBS" | |
16840 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
16841 | /* end confdefs.h. */ | |
16842 | ||
16843 | /* Override any GCC internal prototype to avoid an error. | |
16844 | Use char because int might match the return type of a GCC | |
da0f6381 | 16845 | builtin and then its argument prototype would still apply. */ |
da0f6381 | 16846 | #ifdef __cplusplus |
5213506e | 16847 | extern "C" |
da0f6381 | 16848 | #endif |
5213506e | 16849 | char shl_load (); |
da0f6381 PB |
16850 | int |
16851 | main () | |
16852 | { | |
5213506e | 16853 | return shl_load (); |
da0f6381 PB |
16854 | ; |
16855 | return 0; | |
16856 | } | |
16857 | _ACEOF | |
5213506e RW |
16858 | if ac_fn_c_try_link "$LINENO"; then : |
16859 | ac_cv_lib_dld_shl_load=yes | |
da0f6381 | 16860 | else |
5213506e | 16861 | ac_cv_lib_dld_shl_load=no |
da0f6381 | 16862 | fi |
5213506e RW |
16863 | rm -f core conftest.err conftest.$ac_objext \ |
16864 | conftest$ac_exeext conftest.$ac_ext | |
16865 | LIBS=$ac_check_lib_save_LIBS | |
da0f6381 | 16866 | fi |
5213506e RW |
16867 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_shl_load" >&5 |
16868 | $as_echo "$ac_cv_lib_dld_shl_load" >&6; } | |
16869 | if test "x$ac_cv_lib_dld_shl_load" = x""yes; then : | |
16870 | lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld" | |
16871 | else | |
16872 | ac_fn_c_check_func "$LINENO" "dlopen" "ac_cv_func_dlopen" | |
16873 | if test "x$ac_cv_func_dlopen" = x""yes; then : | |
da0f6381 PB |
16874 | lt_cv_dlopen="dlopen" |
16875 | else | |
5213506e RW |
16876 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 |
16877 | $as_echo_n "checking for dlopen in -ldl... " >&6; } | |
16878 | if test "${ac_cv_lib_dl_dlopen+set}" = set; then : | |
16879 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
16880 | else |
16881 | ac_check_lib_save_LIBS=$LIBS | |
16882 | LIBS="-ldl $LIBS" | |
5213506e | 16883 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
da0f6381 PB |
16884 | /* end confdefs.h. */ |
16885 | ||
5213506e RW |
16886 | /* Override any GCC internal prototype to avoid an error. |
16887 | Use char because int might match the return type of a GCC | |
16888 | builtin and then its argument prototype would still apply. */ | |
da0f6381 PB |
16889 | #ifdef __cplusplus |
16890 | extern "C" | |
16891 | #endif | |
da0f6381 PB |
16892 | char dlopen (); |
16893 | int | |
16894 | main () | |
16895 | { | |
5213506e | 16896 | return dlopen (); |
da0f6381 PB |
16897 | ; |
16898 | return 0; | |
16899 | } | |
16900 | _ACEOF | |
5213506e | 16901 | if ac_fn_c_try_link "$LINENO"; then : |
da0f6381 PB |
16902 | ac_cv_lib_dl_dlopen=yes |
16903 | else | |
5213506e | 16904 | ac_cv_lib_dl_dlopen=no |
da0f6381 | 16905 | fi |
5213506e RW |
16906 | rm -f core conftest.err conftest.$ac_objext \ |
16907 | conftest$ac_exeext conftest.$ac_ext | |
da0f6381 PB |
16908 | LIBS=$ac_check_lib_save_LIBS |
16909 | fi | |
5213506e RW |
16910 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 |
16911 | $as_echo "$ac_cv_lib_dl_dlopen" >&6; } | |
16912 | if test "x$ac_cv_lib_dl_dlopen" = x""yes; then : | |
da0f6381 PB |
16913 | lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl" |
16914 | else | |
5213506e RW |
16915 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -lsvld" >&5 |
16916 | $as_echo_n "checking for dlopen in -lsvld... " >&6; } | |
16917 | if test "${ac_cv_lib_svld_dlopen+set}" = set; then : | |
16918 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
16919 | else |
16920 | ac_check_lib_save_LIBS=$LIBS | |
16921 | LIBS="-lsvld $LIBS" | |
5213506e | 16922 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
da0f6381 PB |
16923 | /* end confdefs.h. */ |
16924 | ||
5213506e RW |
16925 | /* Override any GCC internal prototype to avoid an error. |
16926 | Use char because int might match the return type of a GCC | |
16927 | builtin and then its argument prototype would still apply. */ | |
da0f6381 PB |
16928 | #ifdef __cplusplus |
16929 | extern "C" | |
16930 | #endif | |
da0f6381 PB |
16931 | char dlopen (); |
16932 | int | |
16933 | main () | |
16934 | { | |
5213506e | 16935 | return dlopen (); |
da0f6381 PB |
16936 | ; |
16937 | return 0; | |
16938 | } | |
16939 | _ACEOF | |
5213506e | 16940 | if ac_fn_c_try_link "$LINENO"; then : |
da0f6381 PB |
16941 | ac_cv_lib_svld_dlopen=yes |
16942 | else | |
5213506e | 16943 | ac_cv_lib_svld_dlopen=no |
da0f6381 | 16944 | fi |
5213506e RW |
16945 | rm -f core conftest.err conftest.$ac_objext \ |
16946 | conftest$ac_exeext conftest.$ac_ext | |
da0f6381 PB |
16947 | LIBS=$ac_check_lib_save_LIBS |
16948 | fi | |
5213506e RW |
16949 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_svld_dlopen" >&5 |
16950 | $as_echo "$ac_cv_lib_svld_dlopen" >&6; } | |
16951 | if test "x$ac_cv_lib_svld_dlopen" = x""yes; then : | |
da0f6381 PB |
16952 | lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld" |
16953 | else | |
5213506e RW |
16954 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dld_link in -ldld" >&5 |
16955 | $as_echo_n "checking for dld_link in -ldld... " >&6; } | |
16956 | if test "${ac_cv_lib_dld_dld_link+set}" = set; then : | |
16957 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
16958 | else |
16959 | ac_check_lib_save_LIBS=$LIBS | |
16960 | LIBS="-ldld $LIBS" | |
5213506e | 16961 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
da0f6381 PB |
16962 | /* end confdefs.h. */ |
16963 | ||
5213506e RW |
16964 | /* Override any GCC internal prototype to avoid an error. |
16965 | Use char because int might match the return type of a GCC | |
16966 | builtin and then its argument prototype would still apply. */ | |
da0f6381 PB |
16967 | #ifdef __cplusplus |
16968 | extern "C" | |
16969 | #endif | |
da0f6381 PB |
16970 | char dld_link (); |
16971 | int | |
16972 | main () | |
16973 | { | |
5213506e | 16974 | return dld_link (); |
00020c16 ILT |
16975 | ; |
16976 | return 0; | |
16977 | } | |
16978 | _ACEOF | |
5213506e | 16979 | if ac_fn_c_try_link "$LINENO"; then : |
00020c16 ILT |
16980 | ac_cv_lib_dld_dld_link=yes |
16981 | else | |
5213506e | 16982 | ac_cv_lib_dld_dld_link=no |
00020c16 | 16983 | fi |
5213506e RW |
16984 | rm -f core conftest.err conftest.$ac_objext \ |
16985 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 ILT |
16986 | LIBS=$ac_check_lib_save_LIBS |
16987 | fi | |
5213506e RW |
16988 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dld_dld_link" >&5 |
16989 | $as_echo "$ac_cv_lib_dld_dld_link" >&6; } | |
16990 | if test "x$ac_cv_lib_dld_dld_link" = x""yes; then : | |
00020c16 ILT |
16991 | lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld" |
16992 | fi | |
16993 | ||
16994 | ||
16995 | fi | |
16996 | ||
16997 | ||
16998 | fi | |
16999 | ||
17000 | ||
17001 | fi | |
17002 | ||
17003 | ||
17004 | fi | |
17005 | ||
17006 | ||
17007 | fi | |
17008 | ||
17009 | ;; | |
17010 | esac | |
17011 | ||
17012 | if test "x$lt_cv_dlopen" != xno; then | |
17013 | enable_dlopen=yes | |
17014 | else | |
17015 | enable_dlopen=no | |
17016 | fi | |
17017 | ||
17018 | case $lt_cv_dlopen in | |
17019 | dlopen) | |
17020 | save_CPPFLAGS="$CPPFLAGS" | |
17021 | test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H" | |
17022 | ||
17023 | save_LDFLAGS="$LDFLAGS" | |
17024 | wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\" | |
17025 | ||
17026 | save_LIBS="$LIBS" | |
17027 | LIBS="$lt_cv_dlopen_libs $LIBS" | |
17028 | ||
5213506e RW |
17029 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a program can dlopen itself" >&5 |
17030 | $as_echo_n "checking whether a program can dlopen itself... " >&6; } | |
17031 | if test "${lt_cv_dlopen_self+set}" = set; then : | |
17032 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
17033 | else |
17034 | if test "$cross_compiling" = yes; then : | |
17035 | lt_cv_dlopen_self=cross | |
17036 | else | |
17037 | lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 | |
17038 | lt_status=$lt_dlunknown | |
17039 | cat > conftest.$ac_ext <<_LT_EOF | |
e11ddaf5 | 17040 | #line 17040 "configure" |
00020c16 ILT |
17041 | #include "confdefs.h" |
17042 | ||
17043 | #if HAVE_DLFCN_H | |
17044 | #include <dlfcn.h> | |
17045 | #endif | |
17046 | ||
17047 | #include <stdio.h> | |
17048 | ||
17049 | #ifdef RTLD_GLOBAL | |
17050 | # define LT_DLGLOBAL RTLD_GLOBAL | |
17051 | #else | |
17052 | # ifdef DL_GLOBAL | |
17053 | # define LT_DLGLOBAL DL_GLOBAL | |
17054 | # else | |
17055 | # define LT_DLGLOBAL 0 | |
17056 | # endif | |
17057 | #endif | |
17058 | ||
17059 | /* We may have to define LT_DLLAZY_OR_NOW in the command line if we | |
17060 | find out it does not work in some platform. */ | |
17061 | #ifndef LT_DLLAZY_OR_NOW | |
17062 | # ifdef RTLD_LAZY | |
17063 | # define LT_DLLAZY_OR_NOW RTLD_LAZY | |
17064 | # else | |
17065 | # ifdef DL_LAZY | |
17066 | # define LT_DLLAZY_OR_NOW DL_LAZY | |
17067 | # else | |
17068 | # ifdef RTLD_NOW | |
17069 | # define LT_DLLAZY_OR_NOW RTLD_NOW | |
17070 | # else | |
17071 | # ifdef DL_NOW | |
17072 | # define LT_DLLAZY_OR_NOW DL_NOW | |
17073 | # else | |
17074 | # define LT_DLLAZY_OR_NOW 0 | |
17075 | # endif | |
17076 | # endif | |
17077 | # endif | |
17078 | # endif | |
17079 | #endif | |
17080 | ||
43e02a8a RW |
17081 | /* When -fvisbility=hidden is used, assume the code has been annotated |
17082 | correspondingly for the symbols needed. */ | |
17083 | #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) | |
17084 | void fnord () __attribute__((visibility("default"))); | |
17085 | #endif | |
17086 | ||
17087 | void fnord () { int i=42; } | |
00020c16 ILT |
17088 | int main () |
17089 | { | |
17090 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); | |
17091 | int status = $lt_dlunknown; | |
17092 | ||
17093 | if (self) | |
17094 | { | |
17095 | if (dlsym (self,"fnord")) status = $lt_dlno_uscore; | |
43e02a8a RW |
17096 | else |
17097 | { | |
17098 | if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; | |
17099 | else puts (dlerror ()); | |
17100 | } | |
00020c16 ILT |
17101 | /* dlclose (self); */ |
17102 | } | |
17103 | else | |
17104 | puts (dlerror ()); | |
17105 | ||
17106 | return status; | |
17107 | } | |
17108 | _LT_EOF | |
5213506e | 17109 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 |
00020c16 ILT |
17110 | (eval $ac_link) 2>&5 |
17111 | ac_status=$? | |
5213506e RW |
17112 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
17113 | test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then | |
00020c16 ILT |
17114 | (./conftest; exit; ) >&5 2>/dev/null |
17115 | lt_status=$? | |
17116 | case x$lt_status in | |
17117 | x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;; | |
17118 | x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;; | |
17119 | x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;; | |
17120 | esac | |
17121 | else : | |
17122 | # compilation failed | |
17123 | lt_cv_dlopen_self=no | |
17124 | fi | |
17125 | fi | |
17126 | rm -fr conftest* | |
17127 | ||
17128 | ||
17129 | fi | |
5213506e RW |
17130 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self" >&5 |
17131 | $as_echo "$lt_cv_dlopen_self" >&6; } | |
00020c16 ILT |
17132 | |
17133 | if test "x$lt_cv_dlopen_self" = xyes; then | |
17134 | wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\" | |
5213506e RW |
17135 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether a statically linked program can dlopen itself" >&5 |
17136 | $as_echo_n "checking whether a statically linked program can dlopen itself... " >&6; } | |
17137 | if test "${lt_cv_dlopen_self_static+set}" = set; then : | |
17138 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
17139 | else |
17140 | if test "$cross_compiling" = yes; then : | |
17141 | lt_cv_dlopen_self_static=cross | |
17142 | else | |
17143 | lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 | |
17144 | lt_status=$lt_dlunknown | |
17145 | cat > conftest.$ac_ext <<_LT_EOF | |
e11ddaf5 | 17146 | #line 17146 "configure" |
00020c16 ILT |
17147 | #include "confdefs.h" |
17148 | ||
17149 | #if HAVE_DLFCN_H | |
17150 | #include <dlfcn.h> | |
17151 | #endif | |
17152 | ||
17153 | #include <stdio.h> | |
17154 | ||
17155 | #ifdef RTLD_GLOBAL | |
17156 | # define LT_DLGLOBAL RTLD_GLOBAL | |
17157 | #else | |
17158 | # ifdef DL_GLOBAL | |
17159 | # define LT_DLGLOBAL DL_GLOBAL | |
17160 | # else | |
17161 | # define LT_DLGLOBAL 0 | |
17162 | # endif | |
17163 | #endif | |
17164 | ||
17165 | /* We may have to define LT_DLLAZY_OR_NOW in the command line if we | |
17166 | find out it does not work in some platform. */ | |
17167 | #ifndef LT_DLLAZY_OR_NOW | |
17168 | # ifdef RTLD_LAZY | |
17169 | # define LT_DLLAZY_OR_NOW RTLD_LAZY | |
17170 | # else | |
17171 | # ifdef DL_LAZY | |
17172 | # define LT_DLLAZY_OR_NOW DL_LAZY | |
17173 | # else | |
17174 | # ifdef RTLD_NOW | |
17175 | # define LT_DLLAZY_OR_NOW RTLD_NOW | |
17176 | # else | |
17177 | # ifdef DL_NOW | |
17178 | # define LT_DLLAZY_OR_NOW DL_NOW | |
17179 | # else | |
17180 | # define LT_DLLAZY_OR_NOW 0 | |
17181 | # endif | |
17182 | # endif | |
17183 | # endif | |
17184 | # endif | |
17185 | #endif | |
17186 | ||
43e02a8a RW |
17187 | /* When -fvisbility=hidden is used, assume the code has been annotated |
17188 | correspondingly for the symbols needed. */ | |
17189 | #if defined(__GNUC__) && (((__GNUC__ == 3) && (__GNUC_MINOR__ >= 3)) || (__GNUC__ > 3)) | |
17190 | void fnord () __attribute__((visibility("default"))); | |
17191 | #endif | |
17192 | ||
17193 | void fnord () { int i=42; } | |
00020c16 ILT |
17194 | int main () |
17195 | { | |
17196 | void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW); | |
17197 | int status = $lt_dlunknown; | |
17198 | ||
17199 | if (self) | |
17200 | { | |
17201 | if (dlsym (self,"fnord")) status = $lt_dlno_uscore; | |
43e02a8a RW |
17202 | else |
17203 | { | |
17204 | if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore; | |
17205 | else puts (dlerror ()); | |
17206 | } | |
00020c16 ILT |
17207 | /* dlclose (self); */ |
17208 | } | |
17209 | else | |
17210 | puts (dlerror ()); | |
17211 | ||
17212 | return status; | |
17213 | } | |
17214 | _LT_EOF | |
5213506e | 17215 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_link\""; } >&5 |
00020c16 ILT |
17216 | (eval $ac_link) 2>&5 |
17217 | ac_status=$? | |
5213506e RW |
17218 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
17219 | test $ac_status = 0; } && test -s conftest${ac_exeext} 2>/dev/null; then | |
00020c16 ILT |
17220 | (./conftest; exit; ) >&5 2>/dev/null |
17221 | lt_status=$? | |
17222 | case x$lt_status in | |
17223 | x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;; | |
17224 | x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;; | |
17225 | x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;; | |
17226 | esac | |
17227 | else : | |
17228 | # compilation failed | |
17229 | lt_cv_dlopen_self_static=no | |
17230 | fi | |
17231 | fi | |
17232 | rm -fr conftest* | |
17233 | ||
17234 | ||
17235 | fi | |
5213506e RW |
17236 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_dlopen_self_static" >&5 |
17237 | $as_echo "$lt_cv_dlopen_self_static" >&6; } | |
00020c16 ILT |
17238 | fi |
17239 | ||
17240 | CPPFLAGS="$save_CPPFLAGS" | |
17241 | LDFLAGS="$save_LDFLAGS" | |
17242 | LIBS="$save_LIBS" | |
17243 | ;; | |
17244 | esac | |
17245 | ||
17246 | case $lt_cv_dlopen_self in | |
17247 | yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;; | |
17248 | *) enable_dlopen_self=unknown ;; | |
17249 | esac | |
17250 | ||
17251 | case $lt_cv_dlopen_self_static in | |
17252 | yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;; | |
17253 | *) enable_dlopen_self_static=unknown ;; | |
17254 | esac | |
17255 | fi | |
17256 | ||
17257 | ||
17258 | ||
17259 | ||
17260 | ||
17261 | ||
17262 | ||
17263 | ||
17264 | ||
17265 | ||
17266 | ||
17267 | ||
17268 | ||
17269 | ||
17270 | ||
17271 | ||
17272 | ||
17273 | striplib= | |
17274 | old_striplib= | |
5213506e RW |
17275 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether stripping libraries is possible" >&5 |
17276 | $as_echo_n "checking whether stripping libraries is possible... " >&6; } | |
00020c16 ILT |
17277 | if test -n "$STRIP" && $STRIP -V 2>&1 | $GREP "GNU strip" >/dev/null; then |
17278 | test -z "$old_striplib" && old_striplib="$STRIP --strip-debug" | |
17279 | test -z "$striplib" && striplib="$STRIP --strip-unneeded" | |
5213506e RW |
17280 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
17281 | $as_echo "yes" >&6; } | |
00020c16 ILT |
17282 | else |
17283 | # FIXME - insert some real tests, host_os isn't really good enough | |
17284 | case $host_os in | |
17285 | darwin*) | |
17286 | if test -n "$STRIP" ; then | |
17287 | striplib="$STRIP -x" | |
17288 | old_striplib="$STRIP -S" | |
5213506e RW |
17289 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 |
17290 | $as_echo "yes" >&6; } | |
00020c16 | 17291 | else |
5213506e RW |
17292 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
17293 | $as_echo "no" >&6; } | |
00020c16 ILT |
17294 | fi |
17295 | ;; | |
17296 | *) | |
5213506e RW |
17297 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
17298 | $as_echo "no" >&6; } | |
00020c16 ILT |
17299 | ;; |
17300 | esac | |
17301 | fi | |
17302 | ||
17303 | ||
17304 | ||
17305 | ||
17306 | ||
17307 | ||
17308 | ||
17309 | ||
17310 | ||
17311 | ||
17312 | ||
17313 | ||
17314 | # Report which library types will actually be built | |
5213506e RW |
17315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libtool supports shared libraries" >&5 |
17316 | $as_echo_n "checking if libtool supports shared libraries... " >&6; } | |
17317 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $can_build_shared" >&5 | |
17318 | $as_echo "$can_build_shared" >&6; } | |
00020c16 | 17319 | |
5213506e RW |
17320 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build shared libraries" >&5 |
17321 | $as_echo_n "checking whether to build shared libraries... " >&6; } | |
00020c16 ILT |
17322 | test "$can_build_shared" = "no" && enable_shared=no |
17323 | ||
17324 | # On AIX, shared libraries and static libraries use the same namespace, and | |
17325 | # are all built from PIC. | |
17326 | case $host_os in | |
17327 | aix3*) | |
17328 | test "$enable_shared" = yes && enable_static=no | |
17329 | if test -n "$RANLIB"; then | |
17330 | archive_cmds="$archive_cmds~\$RANLIB \$lib" | |
17331 | postinstall_cmds='$RANLIB $lib' | |
17332 | fi | |
17333 | ;; | |
17334 | ||
17335 | aix[4-9]*) | |
17336 | if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then | |
17337 | test "$enable_shared" = yes && enable_static=no | |
17338 | fi | |
17339 | ;; | |
17340 | esac | |
5213506e RW |
17341 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_shared" >&5 |
17342 | $as_echo "$enable_shared" >&6; } | |
00020c16 | 17343 | |
5213506e RW |
17344 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to build static libraries" >&5 |
17345 | $as_echo_n "checking whether to build static libraries... " >&6; } | |
00020c16 ILT |
17346 | # Make sure either enable_shared or enable_static is yes. |
17347 | test "$enable_shared" = yes || enable_static=yes | |
5213506e RW |
17348 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_static" >&5 |
17349 | $as_echo "$enable_static" >&6; } | |
00020c16 ILT |
17350 | |
17351 | ||
17352 | ||
17353 | ||
17354 | fi | |
17355 | ac_ext=c | |
17356 | ac_cpp='$CPP $CPPFLAGS' | |
17357 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
17358 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
17359 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
17360 | ||
17361 | CC="$lt_save_CC" | |
17362 | ||
43e02a8a RW |
17363 | if test -n "$CXX" && ( test "X$CXX" != "Xno" && |
17364 | ( (test "X$CXX" = "Xg++" && `g++ -v >/dev/null 2>&1` ) || | |
17365 | (test "X$CXX" != "Xg++"))) ; then | |
17366 | ac_ext=cpp | |
17367 | ac_cpp='$CXXCPP $CPPFLAGS' | |
17368 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
17369 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
17370 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu | |
17371 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 | |
17372 | $as_echo_n "checking how to run the C++ preprocessor... " >&6; } | |
17373 | if test -z "$CXXCPP"; then | |
17374 | if test "${ac_cv_prog_CXXCPP+set}" = set; then : | |
17375 | $as_echo_n "(cached) " >&6 | |
17376 | else | |
17377 | # Double quotes because CXXCPP needs to be expanded | |
17378 | for CXXCPP in "$CXX -E" "/lib/cpp" | |
17379 | do | |
17380 | ac_preproc_ok=false | |
17381 | for ac_cxx_preproc_warn_flag in '' yes | |
17382 | do | |
17383 | # Use a header file that comes with gcc, so configuring glibc | |
17384 | # with a fresh cross-compiler works. | |
17385 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
17386 | # <limits.h> exists even on freestanding compilers. | |
17387 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
17388 | # not just through cpp. "Syntax error" is here to catch this case. | |
17389 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17390 | /* end confdefs.h. */ | |
17391 | #ifdef __STDC__ | |
17392 | # include <limits.h> | |
17393 | #else | |
17394 | # include <assert.h> | |
17395 | #endif | |
17396 | Syntax error | |
17397 | _ACEOF | |
17398 | if ac_fn_cxx_try_cpp "$LINENO"; then : | |
17399 | ||
17400 | else | |
17401 | # Broken: fails on valid input. | |
17402 | continue | |
17403 | fi | |
17404 | rm -f conftest.err conftest.$ac_ext | |
17405 | ||
17406 | # OK, works on sane cases. Now check whether nonexistent headers | |
17407 | # can be detected and how. | |
17408 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17409 | /* end confdefs.h. */ | |
17410 | #include <ac_nonexistent.h> | |
17411 | _ACEOF | |
17412 | if ac_fn_cxx_try_cpp "$LINENO"; then : | |
17413 | # Broken: success on invalid input. | |
17414 | continue | |
17415 | else | |
17416 | # Passes both tests. | |
17417 | ac_preproc_ok=: | |
17418 | break | |
17419 | fi | |
17420 | rm -f conftest.err conftest.$ac_ext | |
17421 | ||
17422 | done | |
17423 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
17424 | rm -f conftest.err conftest.$ac_ext | |
17425 | if $ac_preproc_ok; then : | |
17426 | break | |
17427 | fi | |
17428 | ||
17429 | done | |
17430 | ac_cv_prog_CXXCPP=$CXXCPP | |
17431 | ||
17432 | fi | |
17433 | CXXCPP=$ac_cv_prog_CXXCPP | |
17434 | else | |
17435 | ac_cv_prog_CXXCPP=$CXXCPP | |
17436 | fi | |
17437 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 | |
17438 | $as_echo "$CXXCPP" >&6; } | |
17439 | ac_preproc_ok=false | |
17440 | for ac_cxx_preproc_warn_flag in '' yes | |
17441 | do | |
17442 | # Use a header file that comes with gcc, so configuring glibc | |
17443 | # with a fresh cross-compiler works. | |
17444 | # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since | |
17445 | # <limits.h> exists even on freestanding compilers. | |
17446 | # On the NeXT, cc -E runs the code through the compiler's parser, | |
17447 | # not just through cpp. "Syntax error" is here to catch this case. | |
17448 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17449 | /* end confdefs.h. */ | |
17450 | #ifdef __STDC__ | |
17451 | # include <limits.h> | |
17452 | #else | |
17453 | # include <assert.h> | |
17454 | #endif | |
17455 | Syntax error | |
17456 | _ACEOF | |
17457 | if ac_fn_cxx_try_cpp "$LINENO"; then : | |
17458 | ||
17459 | else | |
17460 | # Broken: fails on valid input. | |
17461 | continue | |
17462 | fi | |
17463 | rm -f conftest.err conftest.$ac_ext | |
17464 | ||
17465 | # OK, works on sane cases. Now check whether nonexistent headers | |
17466 | # can be detected and how. | |
17467 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
17468 | /* end confdefs.h. */ | |
17469 | #include <ac_nonexistent.h> | |
17470 | _ACEOF | |
17471 | if ac_fn_cxx_try_cpp "$LINENO"; then : | |
17472 | # Broken: success on invalid input. | |
17473 | continue | |
17474 | else | |
17475 | # Passes both tests. | |
17476 | ac_preproc_ok=: | |
17477 | break | |
17478 | fi | |
17479 | rm -f conftest.err conftest.$ac_ext | |
17480 | ||
17481 | done | |
17482 | # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. | |
17483 | rm -f conftest.err conftest.$ac_ext | |
17484 | if $ac_preproc_ok; then : | |
17485 | ||
17486 | else | |
17487 | { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 | |
17488 | $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} | |
17489 | as_fn_error "C++ preprocessor \"$CXXCPP\" fails sanity check | |
17490 | See \`config.log' for more details." "$LINENO" 5; } | |
17491 | fi | |
17492 | ||
17493 | ac_ext=c | |
17494 | ac_cpp='$CPP $CPPFLAGS' | |
17495 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
17496 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
17497 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
17498 | ||
17499 | else | |
17500 | _lt_caught_CXX_error=yes | |
17501 | fi | |
00020c16 | 17502 | |
5213506e | 17503 | ac_ext=cpp |
00020c16 ILT |
17504 | ac_cpp='$CXXCPP $CPPFLAGS' |
17505 | ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
17506 | ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
17507 | ac_compiler_gnu=$ac_cv_cxx_compiler_gnu | |
17508 | ||
17509 | archive_cmds_need_lc_CXX=no | |
17510 | allow_undefined_flag_CXX= | |
17511 | always_export_symbols_CXX=no | |
17512 | archive_expsym_cmds_CXX= | |
17513 | compiler_needs_object_CXX=no | |
17514 | export_dynamic_flag_spec_CXX= | |
17515 | hardcode_direct_CXX=no | |
17516 | hardcode_direct_absolute_CXX=no | |
17517 | hardcode_libdir_flag_spec_CXX= | |
17518 | hardcode_libdir_flag_spec_ld_CXX= | |
17519 | hardcode_libdir_separator_CXX= | |
17520 | hardcode_minus_L_CXX=no | |
17521 | hardcode_shlibpath_var_CXX=unsupported | |
17522 | hardcode_automatic_CXX=no | |
17523 | inherit_rpath_CXX=no | |
17524 | module_cmds_CXX= | |
17525 | module_expsym_cmds_CXX= | |
17526 | link_all_deplibs_CXX=unknown | |
17527 | old_archive_cmds_CXX=$old_archive_cmds | |
43e02a8a RW |
17528 | reload_flag_CXX=$reload_flag |
17529 | reload_cmds_CXX=$reload_cmds | |
00020c16 ILT |
17530 | no_undefined_flag_CXX= |
17531 | whole_archive_flag_spec_CXX= | |
17532 | enable_shared_with_static_runtimes_CXX=no | |
17533 | ||
17534 | # Source file extension for C++ test sources. | |
17535 | ac_ext=cpp | |
17536 | ||
17537 | # Object file extension for compiled C++ test sources. | |
17538 | objext=o | |
17539 | objext_CXX=$objext | |
17540 | ||
17541 | # No sense in running all these tests if we already determined that | |
17542 | # the CXX compiler isn't working. Some variables (like enable_shared) | |
17543 | # are currently assumed to apply to all compilers on this platform, | |
17544 | # and will be corrupted by setting them based on a non-working compiler. | |
17545 | if test "$_lt_caught_CXX_error" != yes; then | |
17546 | # Code to be used in simple compile tests | |
17547 | lt_simple_compile_test_code="int some_variable = 0;" | |
17548 | ||
17549 | # Code to be used in simple link tests | |
17550 | lt_simple_link_test_code='int main(int, char *[]) { return(0); }' | |
17551 | ||
17552 | # ltmain only uses $CC for tagged configurations so make sure $CC is set. | |
17553 | ||
17554 | ||
17555 | ||
17556 | ||
17557 | ||
17558 | ||
17559 | # If no C compiler was specified, use CC. | |
17560 | LTCC=${LTCC-"$CC"} | |
17561 | ||
17562 | # If no C compiler flags were specified, use CFLAGS. | |
17563 | LTCFLAGS=${LTCFLAGS-"$CFLAGS"} | |
17564 | ||
17565 | # Allow CC to be a program name with arguments. | |
17566 | compiler=$CC | |
17567 | ||
17568 | ||
17569 | # save warnings/boilerplate of simple test code | |
17570 | ac_outfile=conftest.$ac_objext | |
17571 | echo "$lt_simple_compile_test_code" >conftest.$ac_ext | |
17572 | eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err | |
17573 | _lt_compiler_boilerplate=`cat conftest.err` | |
17574 | $RM conftest* | |
17575 | ||
17576 | ac_outfile=conftest.$ac_objext | |
17577 | echo "$lt_simple_link_test_code" >conftest.$ac_ext | |
17578 | eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err | |
17579 | _lt_linker_boilerplate=`cat conftest.err` | |
17580 | $RM -r conftest* | |
17581 | ||
17582 | ||
17583 | # Allow CC to be a program name with arguments. | |
17584 | lt_save_CC=$CC | |
17585 | lt_save_LD=$LD | |
17586 | lt_save_GCC=$GCC | |
17587 | GCC=$GXX | |
17588 | lt_save_with_gnu_ld=$with_gnu_ld | |
17589 | lt_save_path_LD=$lt_cv_path_LD | |
17590 | if test -n "${lt_cv_prog_gnu_ldcxx+set}"; then | |
17591 | lt_cv_prog_gnu_ld=$lt_cv_prog_gnu_ldcxx | |
17592 | else | |
17593 | $as_unset lt_cv_prog_gnu_ld | |
17594 | fi | |
17595 | if test -n "${lt_cv_path_LDCXX+set}"; then | |
17596 | lt_cv_path_LD=$lt_cv_path_LDCXX | |
17597 | else | |
17598 | $as_unset lt_cv_path_LD | |
17599 | fi | |
17600 | test -z "${LDCXX+set}" || LD=$LDCXX | |
17601 | CC=${CXX-"c++"} | |
17602 | compiler=$CC | |
17603 | compiler_CXX=$CC | |
17604 | for cc_temp in $compiler""; do | |
17605 | case $cc_temp in | |
17606 | compile | *[\\/]compile | ccache | *[\\/]ccache ) ;; | |
17607 | distcc | *[\\/]distcc | purify | *[\\/]purify ) ;; | |
17608 | \-*) ;; | |
17609 | *) break;; | |
17610 | esac | |
17611 | done | |
43e02a8a | 17612 | cc_basename=`$ECHO "$cc_temp" | $SED "s%.*/%%; s%^$host_alias-%%"` |
00020c16 ILT |
17613 | |
17614 | ||
17615 | if test -n "$compiler"; then | |
17616 | # We don't want -fno-exception when compiling C++ code, so set the | |
17617 | # no_builtin_flag separately | |
17618 | if test "$GXX" = yes; then | |
17619 | lt_prog_compiler_no_builtin_flag_CXX=' -fno-builtin' | |
17620 | else | |
17621 | lt_prog_compiler_no_builtin_flag_CXX= | |
17622 | fi | |
17623 | ||
17624 | if test "$GXX" = yes; then | |
17625 | # Set up default GNU C++ configuration | |
17626 | ||
17627 | ||
17628 | ||
5213506e RW |
17629 | # Check whether --with-gnu-ld was given. |
17630 | if test "${with_gnu_ld+set}" = set; then : | |
17631 | withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes | |
00020c16 ILT |
17632 | else |
17633 | with_gnu_ld=no | |
5213506e RW |
17634 | fi |
17635 | ||
00020c16 ILT |
17636 | ac_prog=ld |
17637 | if test "$GCC" = yes; then | |
17638 | # Check if gcc -print-prog-name=ld gives a path. | |
5213506e RW |
17639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ld used by $CC" >&5 |
17640 | $as_echo_n "checking for ld used by $CC... " >&6; } | |
00020c16 ILT |
17641 | case $host in |
17642 | *-*-mingw*) | |
17643 | # gcc leaves a trailing carriage return which upsets mingw | |
17644 | ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;; | |
17645 | *) | |
17646 | ac_prog=`($CC -print-prog-name=ld) 2>&5` ;; | |
17647 | esac | |
17648 | case $ac_prog in | |
17649 | # Accept absolute paths. | |
17650 | [\\/]* | ?:[\\/]*) | |
17651 | re_direlt='/[^/][^/]*/\.\./' | |
17652 | # Canonicalize the pathname of ld | |
17653 | ac_prog=`$ECHO "$ac_prog"| $SED 's%\\\\%/%g'` | |
17654 | while $ECHO "$ac_prog" | $GREP "$re_direlt" > /dev/null 2>&1; do | |
17655 | ac_prog=`$ECHO $ac_prog| $SED "s%$re_direlt%/%"` | |
17656 | done | |
17657 | test -z "$LD" && LD="$ac_prog" | |
17658 | ;; | |
17659 | "") | |
17660 | # If it fails, then pretend we aren't using GCC. | |
17661 | ac_prog=ld | |
17662 | ;; | |
17663 | *) | |
17664 | # If it is relative, then search for the first ld in PATH. | |
17665 | with_gnu_ld=unknown | |
17666 | ;; | |
17667 | esac | |
17668 | elif test "$with_gnu_ld" = yes; then | |
5213506e RW |
17669 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNU ld" >&5 |
17670 | $as_echo_n "checking for GNU ld... " >&6; } | |
00020c16 | 17671 | else |
5213506e RW |
17672 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for non-GNU ld" >&5 |
17673 | $as_echo_n "checking for non-GNU ld... " >&6; } | |
00020c16 | 17674 | fi |
5213506e RW |
17675 | if test "${lt_cv_path_LD+set}" = set; then : |
17676 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
17677 | else |
17678 | if test -z "$LD"; then | |
17679 | lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR | |
17680 | for ac_dir in $PATH; do | |
17681 | IFS="$lt_save_ifs" | |
17682 | test -z "$ac_dir" && ac_dir=. | |
17683 | if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then | |
17684 | lt_cv_path_LD="$ac_dir/$ac_prog" | |
17685 | # Check to see if the program is GNU ld. I'd rather use --version, | |
17686 | # but apparently some variants of GNU ld only accept -v. | |
17687 | # Break only if it was the GNU/non-GNU ld that we prefer. | |
17688 | case `"$lt_cv_path_LD" -v 2>&1 </dev/null` in | |
17689 | *GNU* | *'with BFD'*) | |
17690 | test "$with_gnu_ld" != no && break | |
17691 | ;; | |
17692 | *) | |
17693 | test "$with_gnu_ld" != yes && break | |
17694 | ;; | |
17695 | esac | |
17696 | fi | |
17697 | done | |
17698 | IFS="$lt_save_ifs" | |
17699 | else | |
17700 | lt_cv_path_LD="$LD" # Let the user override the test with a path. | |
17701 | fi | |
17702 | fi | |
17703 | ||
17704 | LD="$lt_cv_path_LD" | |
17705 | if test -n "$LD"; then | |
5213506e RW |
17706 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 |
17707 | $as_echo "$LD" >&6; } | |
00020c16 | 17708 | else |
5213506e RW |
17709 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
17710 | $as_echo "no" >&6; } | |
00020c16 | 17711 | fi |
5213506e RW |
17712 | test -z "$LD" && as_fn_error "no acceptable ld found in \$PATH" "$LINENO" 5 |
17713 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the linker ($LD) is GNU ld" >&5 | |
17714 | $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; } | |
17715 | if test "${lt_cv_prog_gnu_ld+set}" = set; then : | |
17716 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
17717 | else |
17718 | # I'd rather use --version here, but apparently some GNU lds only accept -v. | |
17719 | case `$LD -v 2>&1 </dev/null` in | |
17720 | *GNU* | *'with BFD'*) | |
17721 | lt_cv_prog_gnu_ld=yes | |
17722 | ;; | |
17723 | *) | |
17724 | lt_cv_prog_gnu_ld=no | |
17725 | ;; | |
17726 | esac | |
17727 | fi | |
5213506e RW |
17728 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_gnu_ld" >&5 |
17729 | $as_echo "$lt_cv_prog_gnu_ld" >&6; } | |
00020c16 ILT |
17730 | with_gnu_ld=$lt_cv_prog_gnu_ld |
17731 | ||
17732 | ||
17733 | ||
17734 | ||
17735 | ||
17736 | ||
17737 | ||
17738 | # Check if GNU C++ uses GNU ld as the underlying linker, since the | |
17739 | # archiving commands below assume that GNU ld is being used. | |
17740 | if test "$with_gnu_ld" = yes; then | |
17741 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
17742 | archive_expsym_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
17743 | ||
17744 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' | |
17745 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' | |
17746 | ||
17747 | # If archive_cmds runs LD, not CC, wlarc should be empty | |
17748 | # XXX I think wlarc can be eliminated in ltcf-cxx, but I need to | |
17749 | # investigate it a little bit more. (MM) | |
17750 | wlarc='${wl}' | |
17751 | ||
17752 | # ancient GNU ld didn't support --whole-archive et. al. | |
17753 | if eval "`$CC -print-prog-name=ld` --help 2>&1" | | |
17754 | $GREP 'no-whole-archive' > /dev/null; then | |
17755 | whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' | |
17756 | else | |
17757 | whole_archive_flag_spec_CXX= | |
17758 | fi | |
17759 | else | |
17760 | with_gnu_ld=no | |
17761 | wlarc= | |
17762 | ||
17763 | # A generic and very simple default shared library creation | |
17764 | # command for GNU C++ for the case where it uses the native | |
17765 | # linker, instead of GNU ld. If possible, this setting should | |
17766 | # overridden to take advantage of the native linker features on | |
17767 | # the platform it is being used on. | |
17768 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' | |
17769 | fi | |
17770 | ||
17771 | # Commands to make compiler produce verbose output that lists | |
17772 | # what "hidden" libraries, object files and flags are used when | |
17773 | # linking a shared library. | |
43e02a8a | 17774 | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' |
00020c16 ILT |
17775 | |
17776 | else | |
17777 | GXX=no | |
17778 | with_gnu_ld=no | |
17779 | wlarc= | |
17780 | fi | |
17781 | ||
17782 | # PORTME: fill in a description of your system's C++ link characteristics | |
5213506e RW |
17783 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 |
17784 | $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } | |
00020c16 ILT |
17785 | ld_shlibs_CXX=yes |
17786 | case $host_os in | |
17787 | aix3*) | |
17788 | # FIXME: insert proper C++ library support | |
17789 | ld_shlibs_CXX=no | |
17790 | ;; | |
17791 | aix[4-9]*) | |
17792 | if test "$host_cpu" = ia64; then | |
17793 | # On IA64, the linker does run time linking by default, so we don't | |
17794 | # have to do anything special. | |
17795 | aix_use_runtimelinking=no | |
17796 | exp_sym_flag='-Bexport' | |
17797 | no_entry_flag="" | |
17798 | else | |
17799 | aix_use_runtimelinking=no | |
17800 | ||
17801 | # Test if we are trying to use run time linking or normal | |
17802 | # AIX style linking. If -brtl is somewhere in LDFLAGS, we | |
17803 | # need to do runtime linking. | |
17804 | case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*) | |
17805 | for ld_flag in $LDFLAGS; do | |
17806 | case $ld_flag in | |
17807 | *-brtl*) | |
17808 | aix_use_runtimelinking=yes | |
17809 | break | |
17810 | ;; | |
17811 | esac | |
17812 | done | |
17813 | ;; | |
17814 | esac | |
17815 | ||
17816 | exp_sym_flag='-bexport' | |
17817 | no_entry_flag='-bnoentry' | |
17818 | fi | |
17819 | ||
17820 | # When large executables or shared objects are built, AIX ld can | |
17821 | # have problems creating the table of contents. If linking a library | |
17822 | # or program results in "error TOC overflow" add -mminimal-toc to | |
17823 | # CXXFLAGS/CFLAGS for g++/gcc. In the cases where that is not | |
17824 | # enough to fix the problem, add -Wl,-bbigtoc to LDFLAGS. | |
17825 | ||
17826 | archive_cmds_CXX='' | |
17827 | hardcode_direct_CXX=yes | |
17828 | hardcode_direct_absolute_CXX=yes | |
17829 | hardcode_libdir_separator_CXX=':' | |
17830 | link_all_deplibs_CXX=yes | |
17831 | file_list_spec_CXX='${wl}-f,' | |
17832 | ||
17833 | if test "$GXX" = yes; then | |
17834 | case $host_os in aix4.[012]|aix4.[012].*) | |
17835 | # We only want to do this on AIX 4.2 and lower, the check | |
17836 | # below for broken collect2 doesn't work under 4.3+ | |
17837 | collect2name=`${CC} -print-prog-name=collect2` | |
17838 | if test -f "$collect2name" && | |
17839 | strings "$collect2name" | $GREP resolve_lib_name >/dev/null | |
17840 | then | |
17841 | # We have reworked collect2 | |
17842 | : | |
17843 | else | |
17844 | # We have old collect2 | |
17845 | hardcode_direct_CXX=unsupported | |
17846 | # It fails to find uninstalled libraries when the uninstalled | |
17847 | # path is not listed in the libpath. Setting hardcode_minus_L | |
17848 | # to unsupported forces relinking | |
17849 | hardcode_minus_L_CXX=yes | |
17850 | hardcode_libdir_flag_spec_CXX='-L$libdir' | |
17851 | hardcode_libdir_separator_CXX= | |
17852 | fi | |
17853 | esac | |
17854 | shared_flag='-shared' | |
17855 | if test "$aix_use_runtimelinking" = yes; then | |
17856 | shared_flag="$shared_flag "'${wl}-G' | |
17857 | fi | |
17858 | else | |
17859 | # not using gcc | |
17860 | if test "$host_cpu" = ia64; then | |
17861 | # VisualAge C++, Version 5.5 for AIX 5L for IA-64, Beta 3 Release | |
17862 | # chokes on -Wl,-G. The following line is correct: | |
17863 | shared_flag='-G' | |
17864 | else | |
17865 | if test "$aix_use_runtimelinking" = yes; then | |
17866 | shared_flag='${wl}-G' | |
17867 | else | |
17868 | shared_flag='${wl}-bM:SRE' | |
17869 | fi | |
17870 | fi | |
17871 | fi | |
17872 | ||
17873 | export_dynamic_flag_spec_CXX='${wl}-bexpall' | |
17874 | # It seems that -bexpall does not export symbols beginning with | |
17875 | # underscore (_), so it is better to generate a list of symbols to | |
17876 | # export. | |
17877 | always_export_symbols_CXX=yes | |
17878 | if test "$aix_use_runtimelinking" = yes; then | |
17879 | # Warning - without using the other runtime loading flags (-brtl), | |
17880 | # -berok will link without error, but may produce a broken library. | |
17881 | allow_undefined_flag_CXX='-berok' | |
17882 | # Determine the default libpath from the value encoded in an empty | |
17883 | # executable. | |
5213506e | 17884 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
17885 | /* end confdefs.h. */ |
17886 | ||
17887 | int | |
17888 | main () | |
17889 | { | |
17890 | ||
17891 | ; | |
17892 | return 0; | |
17893 | } | |
17894 | _ACEOF | |
5213506e | 17895 | if ac_fn_cxx_try_link "$LINENO"; then : |
00020c16 ILT |
17896 | |
17897 | lt_aix_libpath_sed=' | |
17898 | /Import File Strings/,/^$/ { | |
17899 | /^0/ { | |
17900 | s/^0 *\(.*\)$/\1/ | |
17901 | p | |
17902 | } | |
17903 | }' | |
17904 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
17905 | # Check for a 64-bit object if we didn't find anything. | |
17906 | if test -z "$aix_libpath"; then | |
17907 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
17908 | fi | |
00020c16 | 17909 | fi |
5213506e RW |
17910 | rm -f core conftest.err conftest.$ac_objext \ |
17911 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 ILT |
17912 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi |
17913 | ||
17914 | hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" | |
17915 | ||
43e02a8a | 17916 | archive_expsym_cmds_CXX='$CC -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then func_echo_all "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag" |
00020c16 ILT |
17917 | else |
17918 | if test "$host_cpu" = ia64; then | |
17919 | hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib' | |
17920 | allow_undefined_flag_CXX="-z nodefs" | |
17921 | archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols" | |
17922 | else | |
17923 | # Determine the default libpath from the value encoded in an | |
17924 | # empty executable. | |
5213506e | 17925 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
17926 | /* end confdefs.h. */ |
17927 | ||
17928 | int | |
17929 | main () | |
17930 | { | |
17931 | ||
17932 | ; | |
17933 | return 0; | |
17934 | } | |
17935 | _ACEOF | |
5213506e | 17936 | if ac_fn_cxx_try_link "$LINENO"; then : |
00020c16 ILT |
17937 | |
17938 | lt_aix_libpath_sed=' | |
17939 | /Import File Strings/,/^$/ { | |
17940 | /^0/ { | |
17941 | s/^0 *\(.*\)$/\1/ | |
17942 | p | |
17943 | } | |
17944 | }' | |
17945 | aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
17946 | # Check for a 64-bit object if we didn't find anything. | |
17947 | if test -z "$aix_libpath"; then | |
17948 | aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"` | |
17949 | fi | |
00020c16 | 17950 | fi |
5213506e RW |
17951 | rm -f core conftest.err conftest.$ac_objext \ |
17952 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 ILT |
17953 | if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi |
17954 | ||
17955 | hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath" | |
17956 | # Warning - without using the other run time loading flags, | |
17957 | # -berok will link without error, but may produce a broken library. | |
17958 | no_undefined_flag_CXX=' ${wl}-bernotok' | |
17959 | allow_undefined_flag_CXX=' ${wl}-berok' | |
43e02a8a RW |
17960 | if test "$with_gnu_ld" = yes; then |
17961 | # We only use this code for GNU lds that support --whole-archive. | |
17962 | whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' | |
17963 | else | |
17964 | # Exported symbols can be pulled into shared objects from archives | |
17965 | whole_archive_flag_spec_CXX='$convenience' | |
17966 | fi | |
00020c16 ILT |
17967 | archive_cmds_need_lc_CXX=yes |
17968 | # This is similar to how AIX traditionally builds its shared | |
17969 | # libraries. | |
17970 | archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname' | |
17971 | fi | |
17972 | fi | |
17973 | ;; | |
17974 | ||
17975 | beos*) | |
17976 | if $LD --help 2>&1 | $GREP ': supported targets:.* elf' > /dev/null; then | |
17977 | allow_undefined_flag_CXX=unsupported | |
17978 | # Joseph Beckenbach <jrb3@best.com> says some releases of gcc | |
17979 | # support --undefined. This deserves some investigation. FIXME | |
17980 | archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
17981 | else | |
17982 | ld_shlibs_CXX=no | |
17983 | fi | |
17984 | ;; | |
17985 | ||
17986 | chorus*) | |
17987 | case $cc_basename in | |
17988 | *) | |
17989 | # FIXME: insert proper C++ library support | |
17990 | ld_shlibs_CXX=no | |
17991 | ;; | |
17992 | esac | |
17993 | ;; | |
17994 | ||
17995 | cygwin* | mingw* | pw32* | cegcc*) | |
17996 | # _LT_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless, | |
17997 | # as there is no search path for DLLs. | |
17998 | hardcode_libdir_flag_spec_CXX='-L$libdir' | |
43e02a8a | 17999 | export_dynamic_flag_spec_CXX='${wl}--export-all-symbols' |
00020c16 ILT |
18000 | allow_undefined_flag_CXX=unsupported |
18001 | always_export_symbols_CXX=no | |
18002 | enable_shared_with_static_runtimes_CXX=yes | |
18003 | ||
18004 | if $LD --help 2>&1 | $GREP 'auto-import' > /dev/null; then | |
18005 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
18006 | # If the export-symbols file already is a .def file (1st line | |
18007 | # is EXPORTS), use it as is; otherwise, prepend... | |
18008 | archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then | |
18009 | cp $export_symbols $output_objdir/$soname.def; | |
18010 | else | |
18011 | echo EXPORTS > $output_objdir/$soname.def; | |
18012 | cat $export_symbols >> $output_objdir/$soname.def; | |
18013 | fi~ | |
18014 | $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib' | |
18015 | else | |
18016 | ld_shlibs_CXX=no | |
18017 | fi | |
18018 | ;; | |
18019 | darwin* | rhapsody*) | |
18020 | ||
18021 | ||
18022 | archive_cmds_need_lc_CXX=no | |
18023 | hardcode_direct_CXX=no | |
18024 | hardcode_automatic_CXX=yes | |
18025 | hardcode_shlibpath_var_CXX=unsupported | |
43e02a8a RW |
18026 | if test "$lt_cv_ld_force_load" = "yes"; then |
18027 | whole_archive_flag_spec_CXX='`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience ${wl}-force_load,$conv\"; done; func_echo_all \"$new_convenience\"`' | |
18028 | else | |
18029 | whole_archive_flag_spec_CXX='' | |
18030 | fi | |
00020c16 ILT |
18031 | link_all_deplibs_CXX=yes |
18032 | allow_undefined_flag_CXX="$_lt_dar_allow_undefined" | |
18033 | case $cc_basename in | |
18034 | ifort*) _lt_dar_can_shared=yes ;; | |
18035 | *) _lt_dar_can_shared=$GCC ;; | |
18036 | esac | |
18037 | if test "$_lt_dar_can_shared" = "yes"; then | |
43e02a8a | 18038 | output_verbose_link_cmd=func_echo_all |
00020c16 ILT |
18039 | archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}" |
18040 | module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}" | |
18041 | archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}" | |
18042 | module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}" | |
18043 | if test "$lt_cv_apple_cc_single_mod" != "yes"; then | |
18044 | archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}" | |
18045 | archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}" | |
18046 | fi | |
18047 | ||
18048 | else | |
18049 | ld_shlibs_CXX=no | |
18050 | fi | |
18051 | ||
18052 | ;; | |
18053 | ||
18054 | dgux*) | |
18055 | case $cc_basename in | |
18056 | ec++*) | |
18057 | # FIXME: insert proper C++ library support | |
18058 | ld_shlibs_CXX=no | |
18059 | ;; | |
18060 | ghcx*) | |
18061 | # Green Hills C++ Compiler | |
18062 | # FIXME: insert proper C++ library support | |
18063 | ld_shlibs_CXX=no | |
18064 | ;; | |
18065 | *) | |
18066 | # FIXME: insert proper C++ library support | |
18067 | ld_shlibs_CXX=no | |
18068 | ;; | |
18069 | esac | |
18070 | ;; | |
18071 | ||
18072 | freebsd[12]*) | |
18073 | # C++ shared libraries reported to be fairly broken before | |
18074 | # switch to ELF | |
18075 | ld_shlibs_CXX=no | |
18076 | ;; | |
18077 | ||
18078 | freebsd-elf*) | |
18079 | archive_cmds_need_lc_CXX=no | |
18080 | ;; | |
18081 | ||
18082 | freebsd* | dragonfly*) | |
18083 | # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF | |
18084 | # conventions | |
18085 | ld_shlibs_CXX=yes | |
18086 | ;; | |
18087 | ||
18088 | gnu*) | |
18089 | ;; | |
18090 | ||
43e02a8a RW |
18091 | haiku*) |
18092 | archive_cmds_CXX='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
18093 | link_all_deplibs_CXX=yes | |
18094 | ;; | |
18095 | ||
00020c16 ILT |
18096 | hpux9*) |
18097 | hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' | |
18098 | hardcode_libdir_separator_CXX=: | |
18099 | export_dynamic_flag_spec_CXX='${wl}-E' | |
18100 | hardcode_direct_CXX=yes | |
18101 | hardcode_minus_L_CXX=yes # Not in the search PATH, | |
18102 | # but as the default | |
18103 | # location of the library. | |
18104 | ||
18105 | case $cc_basename in | |
18106 | CC*) | |
18107 | # FIXME: insert proper C++ library support | |
18108 | ld_shlibs_CXX=no | |
18109 | ;; | |
18110 | aCC*) | |
18111 | archive_cmds_CXX='$RM $output_objdir/$soname~$CC -b ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
18112 | # Commands to make compiler produce verbose output that lists | |
18113 | # what "hidden" libraries, object files and flags are used when | |
18114 | # linking a shared library. | |
18115 | # | |
18116 | # There doesn't appear to be a way to prevent this compiler from | |
18117 | # explicitly linking system object files so we need to strip them | |
18118 | # from the output so that they don't get included in the library | |
18119 | # dependencies. | |
43e02a8a | 18120 | output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $EGREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' |
00020c16 ILT |
18121 | ;; |
18122 | *) | |
18123 | if test "$GXX" = yes; then | |
18124 | archive_cmds_CXX='$RM $output_objdir/$soname~$CC -shared -nostdlib -fPIC ${wl}+b ${wl}$install_libdir -o $output_objdir/$soname $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~test $output_objdir/$soname = $lib || mv $output_objdir/$soname $lib' | |
18125 | else | |
18126 | # FIXME: insert proper C++ library support | |
18127 | ld_shlibs_CXX=no | |
18128 | fi | |
18129 | ;; | |
18130 | esac | |
18131 | ;; | |
18132 | ||
18133 | hpux10*|hpux11*) | |
18134 | if test $with_gnu_ld = no; then | |
18135 | hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir' | |
18136 | hardcode_libdir_separator_CXX=: | |
18137 | ||
18138 | case $host_cpu in | |
18139 | hppa*64*|ia64*) | |
18140 | ;; | |
18141 | *) | |
18142 | export_dynamic_flag_spec_CXX='${wl}-E' | |
18143 | ;; | |
18144 | esac | |
18145 | fi | |
18146 | case $host_cpu in | |
18147 | hppa*64*|ia64*) | |
18148 | hardcode_direct_CXX=no | |
18149 | hardcode_shlibpath_var_CXX=no | |
18150 | ;; | |
18151 | *) | |
18152 | hardcode_direct_CXX=yes | |
18153 | hardcode_direct_absolute_CXX=yes | |
18154 | hardcode_minus_L_CXX=yes # Not in the search PATH, | |
18155 | # but as the default | |
18156 | # location of the library. | |
18157 | ;; | |
18158 | esac | |
18159 | ||
18160 | case $cc_basename in | |
18161 | CC*) | |
18162 | # FIXME: insert proper C++ library support | |
18163 | ld_shlibs_CXX=no | |
18164 | ;; | |
18165 | aCC*) | |
18166 | case $host_cpu in | |
18167 | hppa*64*) | |
18168 | archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18169 | ;; | |
18170 | ia64*) | |
18171 | archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18172 | ;; | |
18173 | *) | |
18174 | archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18175 | ;; | |
18176 | esac | |
18177 | # Commands to make compiler produce verbose output that lists | |
18178 | # what "hidden" libraries, object files and flags are used when | |
18179 | # linking a shared library. | |
18180 | # | |
18181 | # There doesn't appear to be a way to prevent this compiler from | |
18182 | # explicitly linking system object files so we need to strip them | |
18183 | # from the output so that they don't get included in the library | |
18184 | # dependencies. | |
43e02a8a | 18185 | output_verbose_link_cmd='templist=`($CC -b $CFLAGS -v conftest.$objext 2>&1) | $GREP "\-L"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' |
00020c16 ILT |
18186 | ;; |
18187 | *) | |
18188 | if test "$GXX" = yes; then | |
18189 | if test $with_gnu_ld = no; then | |
18190 | case $host_cpu in | |
18191 | hppa*64*) | |
18192 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18193 | ;; | |
18194 | ia64*) | |
18195 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18196 | ;; | |
18197 | *) | |
18198 | archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18199 | ;; | |
18200 | esac | |
18201 | fi | |
18202 | else | |
18203 | # FIXME: insert proper C++ library support | |
18204 | ld_shlibs_CXX=no | |
18205 | fi | |
18206 | ;; | |
18207 | esac | |
18208 | ;; | |
18209 | ||
18210 | interix[3-9]*) | |
18211 | hardcode_direct_CXX=no | |
18212 | hardcode_shlibpath_var_CXX=no | |
18213 | hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' | |
18214 | export_dynamic_flag_spec_CXX='${wl}-E' | |
18215 | # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc. | |
18216 | # Instead, shared libraries are loaded at an image base (0x10000000 by | |
18217 | # default) and relocated if they conflict, which is a slow very memory | |
18218 | # consuming and fragmenting process. To avoid this, we pick a random, | |
18219 | # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link | |
18220 | # time. Moving up from 0x10000000 also allows more sbrk(2) space. | |
18221 | archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' | |
18222 | archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib' | |
18223 | ;; | |
18224 | irix5* | irix6*) | |
18225 | case $cc_basename in | |
18226 | CC*) | |
18227 | # SGI C++ | |
43e02a8a | 18228 | archive_cmds_CXX='$CC -shared -all -multigot $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
18229 | |
18230 | # Archives containing C++ object files must be created using | |
18231 | # "CC -ar", where "CC" is the IRIX C++ compiler. This is | |
18232 | # necessary to make sure instantiated templates are included | |
18233 | # in the archive. | |
18234 | old_archive_cmds_CXX='$CC -ar -WR,-u -o $oldlib $oldobjs' | |
18235 | ;; | |
18236 | *) | |
18237 | if test "$GXX" = yes; then | |
18238 | if test "$with_gnu_ld" = no; then | |
43e02a8a | 18239 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 | 18240 | else |
43e02a8a | 18241 | archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` -o $lib' |
00020c16 ILT |
18242 | fi |
18243 | fi | |
18244 | link_all_deplibs_CXX=yes | |
18245 | ;; | |
18246 | esac | |
18247 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' | |
18248 | hardcode_libdir_separator_CXX=: | |
18249 | inherit_rpath_CXX=yes | |
18250 | ;; | |
18251 | ||
18252 | linux* | k*bsd*-gnu | kopensolaris*-gnu) | |
18253 | case $cc_basename in | |
18254 | KCC*) | |
18255 | # Kuck and Associates, Inc. (KAI) C++ Compiler | |
18256 | ||
18257 | # KCC will only create a shared library if the output file | |
18258 | # ends with ".so" (or ".sl" for HP-UX), so rename the library | |
18259 | # to its proper name (with version) after linking. | |
18260 | archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' | |
18261 | archive_expsym_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo $lib | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib ${wl}-retain-symbols-file,$export_symbols; mv \$templib $lib' | |
18262 | # Commands to make compiler produce verbose output that lists | |
18263 | # what "hidden" libraries, object files and flags are used when | |
18264 | # linking a shared library. | |
18265 | # | |
18266 | # There doesn't appear to be a way to prevent this compiler from | |
18267 | # explicitly linking system object files so we need to strip them | |
18268 | # from the output so that they don't get included in the library | |
18269 | # dependencies. | |
43e02a8a | 18270 | output_verbose_link_cmd='templist=`$CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | $GREP "ld"`; rm -f libconftest$shared_ext; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' |
00020c16 ILT |
18271 | |
18272 | hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' | |
18273 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' | |
18274 | ||
18275 | # Archives containing C++ object files must be created using | |
18276 | # "CC -Bstatic", where "CC" is the KAI C++ compiler. | |
18277 | old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' | |
18278 | ;; | |
18279 | icpc* | ecpc* ) | |
18280 | # Intel C++ | |
18281 | with_gnu_ld=yes | |
18282 | # version 8.0 and above of icpc choke on multiply defined symbols | |
18283 | # if we add $predep_objects and $postdep_objects, however 7.1 and | |
18284 | # earlier do not add the objects themselves. | |
18285 | case `$CC -V 2>&1` in | |
18286 | *"Version 7."*) | |
18287 | archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
18288 | archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
18289 | ;; | |
18290 | *) # Version 8.0 or newer | |
18291 | tmp_idyn= | |
18292 | case $host_cpu in | |
18293 | ia64*) tmp_idyn=' -i_dynamic';; | |
18294 | esac | |
18295 | archive_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
18296 | archive_expsym_cmds_CXX='$CC -shared'"$tmp_idyn"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-retain-symbols-file $wl$export_symbols -o $lib' | |
18297 | ;; | |
18298 | esac | |
18299 | archive_cmds_need_lc_CXX=no | |
18300 | hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' | |
18301 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' | |
18302 | whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive' | |
18303 | ;; | |
18304 | pgCC* | pgcpp*) | |
18305 | # Portland Group C++ compiler | |
18306 | case `$CC -V` in | |
43e02a8a | 18307 | *pgCC\ [1-5].* | *pgcpp\ [1-5].*) |
00020c16 ILT |
18308 | prelink_cmds_CXX='tpldir=Template.dir~ |
18309 | rm -rf $tpldir~ | |
18310 | $CC --prelink_objects --instantiation_dir $tpldir $objs $libobjs $compile_deplibs~ | |
18311 | compile_command="$compile_command `find $tpldir -name \*.o | $NL2SP`"' | |
18312 | old_archive_cmds_CXX='tpldir=Template.dir~ | |
18313 | rm -rf $tpldir~ | |
18314 | $CC --prelink_objects --instantiation_dir $tpldir $oldobjs$old_deplibs~ | |
18315 | $AR $AR_FLAGS $oldlib$oldobjs$old_deplibs `find $tpldir -name \*.o | $NL2SP`~ | |
18316 | $RANLIB $oldlib' | |
18317 | archive_cmds_CXX='tpldir=Template.dir~ | |
18318 | rm -rf $tpldir~ | |
18319 | $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ | |
18320 | $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' | |
18321 | archive_expsym_cmds_CXX='tpldir=Template.dir~ | |
18322 | rm -rf $tpldir~ | |
18323 | $CC --prelink_objects --instantiation_dir $tpldir $predep_objects $libobjs $deplibs $convenience $postdep_objects~ | |
18324 | $CC -shared $pic_flag $predep_objects $libobjs $deplibs `find $tpldir -name \*.o | $NL2SP` $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' | |
18325 | ;; | |
43e02a8a | 18326 | *) # Version 6 and above use weak symbols |
00020c16 ILT |
18327 | archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib' |
18328 | archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib' | |
18329 | ;; | |
18330 | esac | |
18331 | ||
18332 | hardcode_libdir_flag_spec_CXX='${wl}--rpath ${wl}$libdir' | |
18333 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' | |
43e02a8a | 18334 | whole_archive_flag_spec_CXX='${wl}--whole-archive`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' |
00020c16 ILT |
18335 | ;; |
18336 | cxx*) | |
18337 | # Compaq C++ | |
18338 | archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
18339 | archive_expsym_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $wl$soname -o $lib ${wl}-retain-symbols-file $wl$export_symbols' | |
18340 | ||
18341 | runpath_var=LD_RUN_PATH | |
18342 | hardcode_libdir_flag_spec_CXX='-rpath $libdir' | |
18343 | hardcode_libdir_separator_CXX=: | |
18344 | ||
18345 | # Commands to make compiler produce verbose output that lists | |
18346 | # what "hidden" libraries, object files and flags are used when | |
18347 | # linking a shared library. | |
18348 | # | |
18349 | # There doesn't appear to be a way to prevent this compiler from | |
18350 | # explicitly linking system object files so we need to strip them | |
18351 | # from the output so that they don't get included in the library | |
18352 | # dependencies. | |
43e02a8a | 18353 | output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "X$list" | $Xsed' |
00020c16 | 18354 | ;; |
43e02a8a | 18355 | xl* | mpixl* | bgxl*) |
00020c16 ILT |
18356 | # IBM XL 8.0 on PPC, with GNU ld |
18357 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' | |
18358 | export_dynamic_flag_spec_CXX='${wl}--export-dynamic' | |
18359 | archive_cmds_CXX='$CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib' | |
18360 | if test "x$supports_anon_versioning" = xyes; then | |
18361 | archive_expsym_cmds_CXX='echo "{ global:" > $output_objdir/$libname.ver~ | |
18362 | cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~ | |
18363 | echo "local: *; };" >> $output_objdir/$libname.ver~ | |
18364 | $CC -qmkshrobj $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib' | |
18365 | fi | |
18366 | ;; | |
18367 | *) | |
18368 | case `$CC -V 2>&1 | sed 5q` in | |
18369 | *Sun\ C*) | |
18370 | # Sun C++ 5.9 | |
18371 | no_undefined_flag_CXX=' -zdefs' | |
18372 | archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18373 | archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols' | |
18374 | hardcode_libdir_flag_spec_CXX='-R$libdir' | |
43e02a8a | 18375 | whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; func_echo_all \"$new_convenience\"` ${wl}--no-whole-archive' |
00020c16 ILT |
18376 | compiler_needs_object_CXX=yes |
18377 | ||
18378 | # Not sure whether something based on | |
18379 | # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1 | |
18380 | # would be better. | |
43e02a8a | 18381 | output_verbose_link_cmd='func_echo_all' |
00020c16 ILT |
18382 | |
18383 | # Archives containing C++ object files must be created using | |
18384 | # "CC -xar", where "CC" is the Sun C++ compiler. This is | |
18385 | # necessary to make sure instantiated templates are included | |
18386 | # in the archive. | |
18387 | old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' | |
18388 | ;; | |
18389 | esac | |
18390 | ;; | |
18391 | esac | |
18392 | ;; | |
18393 | ||
18394 | lynxos*) | |
18395 | # FIXME: insert proper C++ library support | |
18396 | ld_shlibs_CXX=no | |
18397 | ;; | |
18398 | ||
18399 | m88k*) | |
18400 | # FIXME: insert proper C++ library support | |
18401 | ld_shlibs_CXX=no | |
18402 | ;; | |
18403 | ||
18404 | mvs*) | |
18405 | case $cc_basename in | |
18406 | cxx*) | |
18407 | # FIXME: insert proper C++ library support | |
18408 | ld_shlibs_CXX=no | |
18409 | ;; | |
18410 | *) | |
18411 | # FIXME: insert proper C++ library support | |
18412 | ld_shlibs_CXX=no | |
18413 | ;; | |
18414 | esac | |
18415 | ;; | |
18416 | ||
18417 | netbsd*) | |
18418 | if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then | |
18419 | archive_cmds_CXX='$LD -Bshareable -o $lib $predep_objects $libobjs $deplibs $postdep_objects $linker_flags' | |
18420 | wlarc= | |
18421 | hardcode_libdir_flag_spec_CXX='-R$libdir' | |
18422 | hardcode_direct_CXX=yes | |
18423 | hardcode_shlibpath_var_CXX=no | |
18424 | fi | |
18425 | # Workaround some broken pre-1.5 toolchains | |
18426 | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP conftest.$objext | $SED -e "s:-lgcc -lc -lgcc::"' | |
18427 | ;; | |
18428 | ||
18429 | *nto* | *qnx*) | |
18430 | ld_shlibs_CXX=yes | |
18431 | ;; | |
18432 | ||
18433 | openbsd2*) | |
18434 | # C++ shared libraries are fairly broken | |
18435 | ld_shlibs_CXX=no | |
18436 | ;; | |
18437 | ||
18438 | openbsd*) | |
18439 | if test -f /usr/libexec/ld.so; then | |
18440 | hardcode_direct_CXX=yes | |
18441 | hardcode_shlibpath_var_CXX=no | |
18442 | hardcode_direct_absolute_CXX=yes | |
18443 | archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib' | |
18444 | hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' | |
18445 | if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then | |
18446 | archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib' | |
18447 | export_dynamic_flag_spec_CXX='${wl}-E' | |
18448 | whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive' | |
18449 | fi | |
43e02a8a | 18450 | output_verbose_link_cmd=func_echo_all |
00020c16 ILT |
18451 | else |
18452 | ld_shlibs_CXX=no | |
18453 | fi | |
18454 | ;; | |
18455 | ||
18456 | osf3* | osf4* | osf5*) | |
18457 | case $cc_basename in | |
18458 | KCC*) | |
18459 | # Kuck and Associates, Inc. (KAI) C++ Compiler | |
18460 | ||
18461 | # KCC will only create a shared library if the output file | |
18462 | # ends with ".so" (or ".sl" for HP-UX), so rename the library | |
18463 | # to its proper name (with version) after linking. | |
18464 | archive_cmds_CXX='tempext=`echo $shared_ext | $SED -e '\''s/\([^()0-9A-Za-z{}]\)/\\\\\1/g'\''`; templib=`echo "$lib" | $SED -e "s/\${tempext}\..*/.so/"`; $CC $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags --soname $soname -o \$templib; mv \$templib $lib' | |
18465 | ||
18466 | hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir' | |
18467 | hardcode_libdir_separator_CXX=: | |
18468 | ||
18469 | # Archives containing C++ object files must be created using | |
18470 | # the KAI C++ compiler. | |
18471 | case $host in | |
18472 | osf3*) old_archive_cmds_CXX='$CC -Bstatic -o $oldlib $oldobjs' ;; | |
18473 | *) old_archive_cmds_CXX='$CC -o $oldlib $oldobjs' ;; | |
18474 | esac | |
18475 | ;; | |
18476 | RCC*) | |
18477 | # Rational C++ 2.4.1 | |
18478 | # FIXME: insert proper C++ library support | |
18479 | ld_shlibs_CXX=no | |
18480 | ;; | |
18481 | cxx*) | |
18482 | case $host in | |
18483 | osf3*) | |
18484 | allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' | |
43e02a8a | 18485 | archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname $soname `test -n "$verstring" && func_echo_all "${wl}-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
18486 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' |
18487 | ;; | |
18488 | *) | |
18489 | allow_undefined_flag_CXX=' -expect_unresolved \*' | |
43e02a8a | 18490 | archive_cmds_CXX='$CC -shared${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname `test -n "$verstring" && func_echo_all "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
18491 | archive_expsym_cmds_CXX='for i in `cat $export_symbols`; do printf "%s %s\\n" -exported_symbol "\$i" >> $lib.exp; done~ |
18492 | echo "-hidden">> $lib.exp~ | |
43e02a8a | 18493 | $CC -shared$allow_undefined_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -msym -soname $soname ${wl}-input ${wl}$lib.exp `test -n "$verstring" && $ECHO "-set_version $verstring"` -update_registry ${output_objdir}/so_locations -o $lib~ |
00020c16 ILT |
18494 | $RM $lib.exp' |
18495 | hardcode_libdir_flag_spec_CXX='-rpath $libdir' | |
18496 | ;; | |
18497 | esac | |
18498 | ||
18499 | hardcode_libdir_separator_CXX=: | |
18500 | ||
18501 | # Commands to make compiler produce verbose output that lists | |
18502 | # what "hidden" libraries, object files and flags are used when | |
18503 | # linking a shared library. | |
18504 | # | |
18505 | # There doesn't appear to be a way to prevent this compiler from | |
18506 | # explicitly linking system object files so we need to strip them | |
18507 | # from the output so that they don't get included in the library | |
18508 | # dependencies. | |
43e02a8a | 18509 | output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP "ld" | $GREP -v "ld:"`; templist=`func_echo_all "$templist" | $SED "s/\(^.*ld.*\)\( .*ld.*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; func_echo_all "$list"' |
00020c16 ILT |
18510 | ;; |
18511 | *) | |
18512 | if test "$GXX" = yes && test "$with_gnu_ld" = no; then | |
18513 | allow_undefined_flag_CXX=' ${wl}-expect_unresolved ${wl}\*' | |
18514 | case $host in | |
18515 | osf3*) | |
43e02a8a | 18516 | archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
18517 | ;; |
18518 | *) | |
43e02a8a | 18519 | archive_cmds_CXX='$CC -shared -nostdlib ${allow_undefined_flag} $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-msym ${wl}-soname ${wl}$soname `test -n "$verstring" && func_echo_all "${wl}-set_version ${wl}$verstring"` ${wl}-update_registry ${wl}${output_objdir}/so_locations -o $lib' |
00020c16 ILT |
18520 | ;; |
18521 | esac | |
18522 | ||
18523 | hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir' | |
18524 | hardcode_libdir_separator_CXX=: | |
18525 | ||
18526 | # Commands to make compiler produce verbose output that lists | |
18527 | # what "hidden" libraries, object files and flags are used when | |
18528 | # linking a shared library. | |
43e02a8a | 18529 | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' |
00020c16 ILT |
18530 | |
18531 | else | |
18532 | # FIXME: insert proper C++ library support | |
18533 | ld_shlibs_CXX=no | |
18534 | fi | |
18535 | ;; | |
18536 | esac | |
18537 | ;; | |
18538 | ||
18539 | psos*) | |
18540 | # FIXME: insert proper C++ library support | |
18541 | ld_shlibs_CXX=no | |
18542 | ;; | |
18543 | ||
18544 | sunos4*) | |
18545 | case $cc_basename in | |
18546 | CC*) | |
18547 | # Sun C++ 4.x | |
18548 | # FIXME: insert proper C++ library support | |
18549 | ld_shlibs_CXX=no | |
18550 | ;; | |
18551 | lcc*) | |
18552 | # Lucid | |
18553 | # FIXME: insert proper C++ library support | |
18554 | ld_shlibs_CXX=no | |
18555 | ;; | |
18556 | *) | |
18557 | # FIXME: insert proper C++ library support | |
18558 | ld_shlibs_CXX=no | |
18559 | ;; | |
18560 | esac | |
18561 | ;; | |
18562 | ||
18563 | solaris*) | |
18564 | case $cc_basename in | |
18565 | CC*) | |
18566 | # Sun C++ 4.2, 5.x and Centerline C++ | |
18567 | archive_cmds_need_lc_CXX=yes | |
18568 | no_undefined_flag_CXX=' -zdefs' | |
18569 | archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags' | |
18570 | archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
18571 | $CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
18572 | ||
18573 | hardcode_libdir_flag_spec_CXX='-R$libdir' | |
18574 | hardcode_shlibpath_var_CXX=no | |
18575 | case $host_os in | |
18576 | solaris2.[0-5] | solaris2.[0-5].*) ;; | |
18577 | *) | |
18578 | # The compiler driver will combine and reorder linker options, | |
18579 | # but understands `-z linker_flag'. | |
18580 | # Supported since Solaris 2.6 (maybe 2.5.1?) | |
18581 | whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract' | |
18582 | ;; | |
18583 | esac | |
18584 | link_all_deplibs_CXX=yes | |
18585 | ||
43e02a8a | 18586 | output_verbose_link_cmd='func_echo_all' |
00020c16 ILT |
18587 | |
18588 | # Archives containing C++ object files must be created using | |
18589 | # "CC -xar", where "CC" is the Sun C++ compiler. This is | |
18590 | # necessary to make sure instantiated templates are included | |
18591 | # in the archive. | |
18592 | old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs' | |
18593 | ;; | |
18594 | gcx*) | |
18595 | # Green Hills C++ Compiler | |
18596 | archive_cmds_CXX='$CC -shared $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
18597 | ||
18598 | # The C++ compiler must be used to create the archive. | |
18599 | old_archive_cmds_CXX='$CC $LDFLAGS -archive -o $oldlib $oldobjs' | |
18600 | ;; | |
18601 | *) | |
18602 | # GNU C++ compiler with Solaris linker | |
18603 | if test "$GXX" = yes && test "$with_gnu_ld" = no; then | |
18604 | no_undefined_flag_CXX=' ${wl}-z ${wl}defs' | |
18605 | if $CC --version | $GREP -v '^2\.7' > /dev/null; then | |
18606 | archive_cmds_CXX='$CC -shared -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
18607 | archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
18608 | $CC -shared -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
18609 | ||
18610 | # Commands to make compiler produce verbose output that lists | |
18611 | # what "hidden" libraries, object files and flags are used when | |
18612 | # linking a shared library. | |
43e02a8a | 18613 | output_verbose_link_cmd='$CC -shared $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' |
00020c16 ILT |
18614 | else |
18615 | # g++ 2.7 appears to require `-G' NOT `-shared' on this | |
18616 | # platform. | |
18617 | archive_cmds_CXX='$CC -G -nostdlib $LDFLAGS $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-h $wl$soname -o $lib' | |
18618 | archive_expsym_cmds_CXX='echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~echo "local: *; };" >> $lib.exp~ | |
18619 | $CC -G -nostdlib ${wl}-M $wl$lib.exp -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$RM $lib.exp' | |
18620 | ||
18621 | # Commands to make compiler produce verbose output that lists | |
18622 | # what "hidden" libraries, object files and flags are used when | |
18623 | # linking a shared library. | |
43e02a8a | 18624 | output_verbose_link_cmd='$CC -G $CFLAGS -v conftest.$objext 2>&1 | $GREP -v "^Configured with:" | $GREP "\-L"' |
00020c16 ILT |
18625 | fi |
18626 | ||
18627 | hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir' | |
18628 | case $host_os in | |
18629 | solaris2.[0-5] | solaris2.[0-5].*) ;; | |
18630 | *) | |
18631 | whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract' | |
18632 | ;; | |
18633 | esac | |
18634 | fi | |
18635 | ;; | |
18636 | esac | |
18637 | ;; | |
18638 | ||
18639 | sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*) | |
18640 | no_undefined_flag_CXX='${wl}-z,text' | |
18641 | archive_cmds_need_lc_CXX=no | |
18642 | hardcode_shlibpath_var_CXX=no | |
18643 | runpath_var='LD_RUN_PATH' | |
18644 | ||
18645 | case $cc_basename in | |
18646 | CC*) | |
18647 | archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18648 | archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18649 | ;; | |
18650 | *) | |
18651 | archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18652 | archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18653 | ;; | |
18654 | esac | |
18655 | ;; | |
18656 | ||
18657 | sysv5* | sco3.2v5* | sco5v6*) | |
18658 | # Note: We can NOT use -z defs as we might desire, because we do not | |
18659 | # link with -lc, and that would cause any symbols used from libc to | |
18660 | # always be unresolved, which means just about no library would | |
18661 | # ever link correctly. If we're not using GNU ld we use -z text | |
18662 | # though, which does catch some bad symbols but isn't as heavy-handed | |
18663 | # as -z defs. | |
18664 | no_undefined_flag_CXX='${wl}-z,text' | |
18665 | allow_undefined_flag_CXX='${wl}-z,nodefs' | |
18666 | archive_cmds_need_lc_CXX=no | |
18667 | hardcode_shlibpath_var_CXX=no | |
18668 | hardcode_libdir_flag_spec_CXX='${wl}-R,$libdir' | |
18669 | hardcode_libdir_separator_CXX=':' | |
18670 | link_all_deplibs_CXX=yes | |
18671 | export_dynamic_flag_spec_CXX='${wl}-Bexport' | |
18672 | runpath_var='LD_RUN_PATH' | |
18673 | ||
18674 | case $cc_basename in | |
18675 | CC*) | |
18676 | archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18677 | archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
43e02a8a RW |
18678 | old_archive_cmds_CXX='$CC -Tprelink_objects $oldobjs~ |
18679 | '"$old_archive_cmds_CXX" | |
18680 | reload_cmds_CXX='$CC -Tprelink_objects $reload_objs~ | |
18681 | '"$reload_cmds_CXX" | |
00020c16 ILT |
18682 | ;; |
18683 | *) | |
18684 | archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18685 | archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags' | |
18686 | ;; | |
18687 | esac | |
18688 | ;; | |
18689 | ||
18690 | tandem*) | |
18691 | case $cc_basename in | |
18692 | NCC*) | |
18693 | # NonStop-UX NCC 3.20 | |
18694 | # FIXME: insert proper C++ library support | |
18695 | ld_shlibs_CXX=no | |
18696 | ;; | |
18697 | *) | |
18698 | # FIXME: insert proper C++ library support | |
18699 | ld_shlibs_CXX=no | |
18700 | ;; | |
18701 | esac | |
18702 | ;; | |
18703 | ||
18704 | vxworks*) | |
18705 | # FIXME: insert proper C++ library support | |
18706 | ld_shlibs_CXX=no | |
18707 | ;; | |
18708 | ||
18709 | *) | |
18710 | # FIXME: insert proper C++ library support | |
18711 | ld_shlibs_CXX=no | |
18712 | ;; | |
18713 | esac | |
18714 | ||
5213506e RW |
18715 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 |
18716 | $as_echo "$ld_shlibs_CXX" >&6; } | |
00020c16 ILT |
18717 | test "$ld_shlibs_CXX" = no && can_build_shared=no |
18718 | ||
18719 | GCC_CXX="$GXX" | |
18720 | LD_CXX="$LD" | |
18721 | ||
18722 | ## CAVEAT EMPTOR: | |
18723 | ## There is no encapsulation within the following macros, do not change | |
18724 | ## the running order or otherwise move them around unless you know exactly | |
18725 | ## what you are doing... | |
18726 | # Dependencies to place before and after the object being linked: | |
18727 | predep_objects_CXX= | |
18728 | postdep_objects_CXX= | |
18729 | predeps_CXX= | |
18730 | postdeps_CXX= | |
18731 | compiler_lib_search_path_CXX= | |
18732 | ||
18733 | cat > conftest.$ac_ext <<_LT_EOF | |
18734 | class Foo | |
18735 | { | |
18736 | public: | |
18737 | Foo (void) { a = 0; } | |
18738 | private: | |
18739 | int a; | |
18740 | }; | |
18741 | _LT_EOF | |
18742 | ||
5213506e | 18743 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
00020c16 ILT |
18744 | (eval $ac_compile) 2>&5 |
18745 | ac_status=$? | |
5213506e RW |
18746 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
18747 | test $ac_status = 0; }; then | |
00020c16 ILT |
18748 | # Parse the compiler output and extract the necessary |
18749 | # objects, libraries and library flags. | |
18750 | ||
18751 | # Sentinel used to keep track of whether or not we are before | |
18752 | # the conftest object file. | |
18753 | pre_test_object_deps_done=no | |
18754 | ||
18755 | for p in `eval "$output_verbose_link_cmd"`; do | |
18756 | case $p in | |
18757 | ||
18758 | -L* | -R* | -l*) | |
18759 | # Some compilers place space between "-{L,R}" and the path. | |
18760 | # Remove the space. | |
18761 | if test $p = "-L" || | |
18762 | test $p = "-R"; then | |
18763 | prev=$p | |
18764 | continue | |
18765 | else | |
18766 | prev= | |
18767 | fi | |
18768 | ||
18769 | if test "$pre_test_object_deps_done" = no; then | |
18770 | case $p in | |
18771 | -L* | -R*) | |
18772 | # Internal compiler library paths should come after those | |
18773 | # provided the user. The postdeps already come after the | |
18774 | # user supplied libs so there is no need to process them. | |
18775 | if test -z "$compiler_lib_search_path_CXX"; then | |
18776 | compiler_lib_search_path_CXX="${prev}${p}" | |
18777 | else | |
18778 | compiler_lib_search_path_CXX="${compiler_lib_search_path_CXX} ${prev}${p}" | |
18779 | fi | |
18780 | ;; | |
18781 | # The "-l" case would never come before the object being | |
18782 | # linked, so don't bother handling this case. | |
18783 | esac | |
18784 | else | |
18785 | if test -z "$postdeps_CXX"; then | |
18786 | postdeps_CXX="${prev}${p}" | |
18787 | else | |
18788 | postdeps_CXX="${postdeps_CXX} ${prev}${p}" | |
18789 | fi | |
18790 | fi | |
18791 | ;; | |
18792 | ||
18793 | *.$objext) | |
18794 | # This assumes that the test object file only shows up | |
18795 | # once in the compiler output. | |
18796 | if test "$p" = "conftest.$objext"; then | |
18797 | pre_test_object_deps_done=yes | |
18798 | continue | |
18799 | fi | |
18800 | ||
18801 | if test "$pre_test_object_deps_done" = no; then | |
18802 | if test -z "$predep_objects_CXX"; then | |
18803 | predep_objects_CXX="$p" | |
18804 | else | |
18805 | predep_objects_CXX="$predep_objects_CXX $p" | |
18806 | fi | |
18807 | else | |
18808 | if test -z "$postdep_objects_CXX"; then | |
18809 | postdep_objects_CXX="$p" | |
18810 | else | |
18811 | postdep_objects_CXX="$postdep_objects_CXX $p" | |
18812 | fi | |
18813 | fi | |
18814 | ;; | |
18815 | ||
18816 | *) ;; # Ignore the rest. | |
18817 | ||
18818 | esac | |
18819 | done | |
18820 | ||
18821 | # Clean up. | |
18822 | rm -f a.out a.exe | |
18823 | else | |
18824 | echo "libtool.m4: error: problem compiling CXX test program" | |
18825 | fi | |
18826 | ||
18827 | $RM -f confest.$objext | |
18828 | ||
18829 | # PORTME: override above test on systems where it is broken | |
18830 | case $host_os in | |
18831 | interix[3-9]*) | |
18832 | # Interix 3.5 installs completely hosed .la files for C++, so rather than | |
18833 | # hack all around it, let's just trust "g++" to DTRT. | |
18834 | predep_objects_CXX= | |
18835 | postdep_objects_CXX= | |
18836 | postdeps_CXX= | |
18837 | ;; | |
18838 | ||
18839 | linux*) | |
18840 | case `$CC -V 2>&1 | sed 5q` in | |
18841 | *Sun\ C*) | |
18842 | # Sun C++ 5.9 | |
18843 | ||
18844 | # The more standards-conforming stlport4 library is | |
18845 | # incompatible with the Cstd library. Avoid specifying | |
18846 | # it if it's in CXXFLAGS. Ignore libCrun as | |
18847 | # -library=stlport4 depends on it. | |
18848 | case " $CXX $CXXFLAGS " in | |
18849 | *" -library=stlport4 "*) | |
18850 | solaris_use_stlport4=yes | |
18851 | ;; | |
18852 | esac | |
18853 | ||
18854 | if test "$solaris_use_stlport4" != yes; then | |
18855 | postdeps_CXX='-library=Cstd -library=Crun' | |
18856 | fi | |
18857 | ;; | |
18858 | esac | |
18859 | ;; | |
18860 | ||
18861 | solaris*) | |
18862 | case $cc_basename in | |
18863 | CC*) | |
18864 | # The more standards-conforming stlport4 library is | |
18865 | # incompatible with the Cstd library. Avoid specifying | |
18866 | # it if it's in CXXFLAGS. Ignore libCrun as | |
18867 | # -library=stlport4 depends on it. | |
18868 | case " $CXX $CXXFLAGS " in | |
18869 | *" -library=stlport4 "*) | |
18870 | solaris_use_stlport4=yes | |
18871 | ;; | |
18872 | esac | |
18873 | ||
18874 | # Adding this requires a known-good setup of shared libraries for | |
18875 | # Sun compiler versions before 5.6, else PIC objects from an old | |
18876 | # archive will be linked into the output, leading to subtle bugs. | |
18877 | if test "$solaris_use_stlport4" != yes; then | |
18878 | postdeps_CXX='-library=Cstd -library=Crun' | |
18879 | fi | |
18880 | ;; | |
18881 | esac | |
18882 | ;; | |
18883 | esac | |
18884 | ||
18885 | ||
18886 | case " $postdeps_CXX " in | |
18887 | *" -lc "*) archive_cmds_need_lc_CXX=no ;; | |
18888 | esac | |
18889 | compiler_lib_search_dirs_CXX= | |
18890 | if test -n "${compiler_lib_search_path_CXX}"; then | |
18891 | compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'` | |
18892 | fi | |
18893 | ||
18894 | ||
18895 | ||
18896 | ||
18897 | ||
18898 | ||
18899 | ||
18900 | ||
18901 | ||
18902 | ||
18903 | ||
18904 | ||
18905 | ||
18906 | ||
18907 | ||
18908 | ||
18909 | ||
18910 | ||
18911 | ||
18912 | ||
18913 | ||
18914 | ||
18915 | ||
18916 | ||
18917 | ||
18918 | ||
18919 | ||
18920 | ||
18921 | ||
18922 | ||
18923 | ||
18924 | lt_prog_compiler_wl_CXX= | |
18925 | lt_prog_compiler_pic_CXX= | |
18926 | lt_prog_compiler_static_CXX= | |
18927 | ||
5213506e RW |
18928 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $compiler option to produce PIC" >&5 |
18929 | $as_echo_n "checking for $compiler option to produce PIC... " >&6; } | |
00020c16 ILT |
18930 | |
18931 | # C++ specific cases for pic, static, wl, etc. | |
18932 | if test "$GXX" = yes; then | |
18933 | lt_prog_compiler_wl_CXX='-Wl,' | |
18934 | lt_prog_compiler_static_CXX='-static' | |
18935 | ||
18936 | case $host_os in | |
18937 | aix*) | |
18938 | # All AIX code is PIC. | |
18939 | if test "$host_cpu" = ia64; then | |
18940 | # AIX 5 now supports IA64 processor | |
18941 | lt_prog_compiler_static_CXX='-Bstatic' | |
18942 | fi | |
18943 | ;; | |
18944 | ||
18945 | amigaos*) | |
18946 | case $host_cpu in | |
18947 | powerpc) | |
18948 | # see comment about AmigaOS4 .so support | |
18949 | lt_prog_compiler_pic_CXX='-fPIC' | |
18950 | ;; | |
18951 | m68k) | |
18952 | # FIXME: we need at least 68020 code to build shared libraries, but | |
18953 | # adding the `-m68020' flag to GCC prevents building anything better, | |
18954 | # like `-m68040'. | |
18955 | lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4' | |
18956 | ;; | |
18957 | esac | |
18958 | ;; | |
18959 | ||
18960 | beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*) | |
18961 | # PIC is the default for these OSes. | |
18962 | ;; | |
18963 | mingw* | cygwin* | os2* | pw32* | cegcc*) | |
18964 | # This hack is so that the source file can tell whether it is being | |
18965 | # built for inclusion in a dll (and should export symbols for example). | |
18966 | # Although the cygwin gcc ignores -fPIC, still need this for old-style | |
18967 | # (--disable-auto-import) libraries | |
18968 | lt_prog_compiler_pic_CXX='-DDLL_EXPORT' | |
18969 | ;; | |
18970 | darwin* | rhapsody*) | |
18971 | # PIC is the default on this platform | |
18972 | # Common symbols not allowed in MH_DYLIB files | |
18973 | lt_prog_compiler_pic_CXX='-fno-common' | |
18974 | ;; | |
18975 | *djgpp*) | |
18976 | # DJGPP does not support shared libraries at all | |
18977 | lt_prog_compiler_pic_CXX= | |
18978 | ;; | |
43e02a8a RW |
18979 | haiku*) |
18980 | # PIC is the default for Haiku. | |
18981 | # The "-static" flag exists, but is broken. | |
18982 | lt_prog_compiler_static_CXX= | |
18983 | ;; | |
00020c16 ILT |
18984 | interix[3-9]*) |
18985 | # Interix 3.x gcc -fpic/-fPIC options generate broken code. | |
18986 | # Instead, we relocate shared libraries at runtime. | |
18987 | ;; | |
18988 | sysv4*MP*) | |
18989 | if test -d /usr/nec; then | |
18990 | lt_prog_compiler_pic_CXX=-Kconform_pic | |
18991 | fi | |
18992 | ;; | |
18993 | hpux*) | |
18994 | # PIC is the default for 64-bit PA HP-UX, but not for 32-bit | |
18995 | # PA HP-UX. On IA64 HP-UX, PIC is the default but the pic flag | |
18996 | # sets the default TLS model and affects inlining. | |
18997 | case $host_cpu in | |
18998 | hppa*64*) | |
18999 | ;; | |
19000 | *) | |
19001 | lt_prog_compiler_pic_CXX='-fPIC' | |
19002 | ;; | |
19003 | esac | |
19004 | ;; | |
19005 | *qnx* | *nto*) | |
19006 | # QNX uses GNU C++, but need to define -shared option too, otherwise | |
19007 | # it will coredump. | |
19008 | lt_prog_compiler_pic_CXX='-fPIC -shared' | |
19009 | ;; | |
19010 | *) | |
19011 | lt_prog_compiler_pic_CXX='-fPIC' | |
19012 | ;; | |
19013 | esac | |
19014 | else | |
19015 | case $host_os in | |
19016 | aix[4-9]*) | |
19017 | # All AIX code is PIC. | |
19018 | if test "$host_cpu" = ia64; then | |
19019 | # AIX 5 now supports IA64 processor | |
19020 | lt_prog_compiler_static_CXX='-Bstatic' | |
19021 | else | |
19022 | lt_prog_compiler_static_CXX='-bnso -bI:/lib/syscalls.exp' | |
19023 | fi | |
19024 | ;; | |
19025 | chorus*) | |
19026 | case $cc_basename in | |
19027 | cxch68*) | |
19028 | # Green Hills C++ Compiler | |
19029 | # _LT_TAGVAR(lt_prog_compiler_static, CXX)="--no_auto_instantiation -u __main -u __premain -u _abort -r $COOL_DIR/lib/libOrb.a $MVME_DIR/lib/CC/libC.a $MVME_DIR/lib/classix/libcx.s.a" | |
19030 | ;; | |
19031 | esac | |
19032 | ;; | |
19033 | dgux*) | |
19034 | case $cc_basename in | |
19035 | ec++*) | |
19036 | lt_prog_compiler_pic_CXX='-KPIC' | |
19037 | ;; | |
19038 | ghcx*) | |
19039 | # Green Hills C++ Compiler | |
19040 | lt_prog_compiler_pic_CXX='-pic' | |
19041 | ;; | |
19042 | *) | |
19043 | ;; | |
19044 | esac | |
19045 | ;; | |
19046 | freebsd* | dragonfly*) | |
19047 | # FreeBSD uses GNU C++ | |
19048 | ;; | |
19049 | hpux9* | hpux10* | hpux11*) | |
19050 | case $cc_basename in | |
19051 | CC*) | |
19052 | lt_prog_compiler_wl_CXX='-Wl,' | |
19053 | lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' | |
19054 | if test "$host_cpu" != ia64; then | |
19055 | lt_prog_compiler_pic_CXX='+Z' | |
19056 | fi | |
19057 | ;; | |
19058 | aCC*) | |
19059 | lt_prog_compiler_wl_CXX='-Wl,' | |
19060 | lt_prog_compiler_static_CXX='${wl}-a ${wl}archive' | |
19061 | case $host_cpu in | |
19062 | hppa*64*|ia64*) | |
19063 | # +Z the default | |
19064 | ;; | |
19065 | *) | |
19066 | lt_prog_compiler_pic_CXX='+Z' | |
19067 | ;; | |
19068 | esac | |
19069 | ;; | |
19070 | *) | |
19071 | ;; | |
19072 | esac | |
19073 | ;; | |
19074 | interix*) | |
19075 | # This is c89, which is MS Visual C++ (no shared libs) | |
19076 | # Anyone wants to do a port? | |
19077 | ;; | |
19078 | irix5* | irix6* | nonstopux*) | |
19079 | case $cc_basename in | |
19080 | CC*) | |
19081 | lt_prog_compiler_wl_CXX='-Wl,' | |
19082 | lt_prog_compiler_static_CXX='-non_shared' | |
19083 | # CC pic flag -KPIC is the default. | |
19084 | ;; | |
19085 | *) | |
19086 | ;; | |
19087 | esac | |
19088 | ;; | |
19089 | linux* | k*bsd*-gnu | kopensolaris*-gnu) | |
19090 | case $cc_basename in | |
19091 | KCC*) | |
19092 | # KAI C++ Compiler | |
19093 | lt_prog_compiler_wl_CXX='--backend -Wl,' | |
19094 | lt_prog_compiler_pic_CXX='-fPIC' | |
19095 | ;; | |
19096 | ecpc* ) | |
19097 | # old Intel C++ for x86_64 which still supported -KPIC. | |
19098 | lt_prog_compiler_wl_CXX='-Wl,' | |
19099 | lt_prog_compiler_pic_CXX='-KPIC' | |
19100 | lt_prog_compiler_static_CXX='-static' | |
19101 | ;; | |
19102 | icpc* ) | |
19103 | # Intel C++, used to be incompatible with GCC. | |
19104 | # ICC 10 doesn't accept -KPIC any more. | |
19105 | lt_prog_compiler_wl_CXX='-Wl,' | |
19106 | lt_prog_compiler_pic_CXX='-fPIC' | |
19107 | lt_prog_compiler_static_CXX='-static' | |
19108 | ;; | |
19109 | pgCC* | pgcpp*) | |
19110 | # Portland Group C++ compiler | |
19111 | lt_prog_compiler_wl_CXX='-Wl,' | |
19112 | lt_prog_compiler_pic_CXX='-fpic' | |
19113 | lt_prog_compiler_static_CXX='-Bstatic' | |
19114 | ;; | |
19115 | cxx*) | |
19116 | # Compaq C++ | |
19117 | # Make sure the PIC flag is empty. It appears that all Alpha | |
19118 | # Linux and Compaq Tru64 Unix objects are PIC. | |
19119 | lt_prog_compiler_pic_CXX= | |
19120 | lt_prog_compiler_static_CXX='-non_shared' | |
19121 | ;; | |
43e02a8a RW |
19122 | xlc* | xlC* | bgxl[cC]* | mpixl[cC]*) |
19123 | # IBM XL 8.0, 9.0 on PPC and BlueGene | |
00020c16 ILT |
19124 | lt_prog_compiler_wl_CXX='-Wl,' |
19125 | lt_prog_compiler_pic_CXX='-qpic' | |
19126 | lt_prog_compiler_static_CXX='-qstaticlink' | |
19127 | ;; | |
19128 | *) | |
19129 | case `$CC -V 2>&1 | sed 5q` in | |
19130 | *Sun\ C*) | |
19131 | # Sun C++ 5.9 | |
19132 | lt_prog_compiler_pic_CXX='-KPIC' | |
19133 | lt_prog_compiler_static_CXX='-Bstatic' | |
19134 | lt_prog_compiler_wl_CXX='-Qoption ld ' | |
19135 | ;; | |
19136 | esac | |
19137 | ;; | |
19138 | esac | |
19139 | ;; | |
19140 | lynxos*) | |
19141 | ;; | |
19142 | m88k*) | |
19143 | ;; | |
19144 | mvs*) | |
19145 | case $cc_basename in | |
19146 | cxx*) | |
19147 | lt_prog_compiler_pic_CXX='-W c,exportall' | |
19148 | ;; | |
19149 | *) | |
19150 | ;; | |
19151 | esac | |
19152 | ;; | |
19153 | netbsd*) | |
19154 | ;; | |
19155 | *qnx* | *nto*) | |
19156 | # QNX uses GNU C++, but need to define -shared option too, otherwise | |
19157 | # it will coredump. | |
19158 | lt_prog_compiler_pic_CXX='-fPIC -shared' | |
19159 | ;; | |
19160 | osf3* | osf4* | osf5*) | |
19161 | case $cc_basename in | |
19162 | KCC*) | |
19163 | lt_prog_compiler_wl_CXX='--backend -Wl,' | |
19164 | ;; | |
19165 | RCC*) | |
19166 | # Rational C++ 2.4.1 | |
19167 | lt_prog_compiler_pic_CXX='-pic' | |
19168 | ;; | |
19169 | cxx*) | |
19170 | # Digital/Compaq C++ | |
19171 | lt_prog_compiler_wl_CXX='-Wl,' | |
19172 | # Make sure the PIC flag is empty. It appears that all Alpha | |
19173 | # Linux and Compaq Tru64 Unix objects are PIC. | |
19174 | lt_prog_compiler_pic_CXX= | |
19175 | lt_prog_compiler_static_CXX='-non_shared' | |
19176 | ;; | |
19177 | *) | |
19178 | ;; | |
19179 | esac | |
19180 | ;; | |
19181 | psos*) | |
19182 | ;; | |
19183 | solaris*) | |
19184 | case $cc_basename in | |
19185 | CC*) | |
19186 | # Sun C++ 4.2, 5.x and Centerline C++ | |
19187 | lt_prog_compiler_pic_CXX='-KPIC' | |
19188 | lt_prog_compiler_static_CXX='-Bstatic' | |
19189 | lt_prog_compiler_wl_CXX='-Qoption ld ' | |
19190 | ;; | |
19191 | gcx*) | |
19192 | # Green Hills C++ Compiler | |
19193 | lt_prog_compiler_pic_CXX='-PIC' | |
19194 | ;; | |
19195 | *) | |
19196 | ;; | |
19197 | esac | |
19198 | ;; | |
19199 | sunos4*) | |
19200 | case $cc_basename in | |
19201 | CC*) | |
19202 | # Sun C++ 4.x | |
19203 | lt_prog_compiler_pic_CXX='-pic' | |
19204 | lt_prog_compiler_static_CXX='-Bstatic' | |
19205 | ;; | |
19206 | lcc*) | |
19207 | # Lucid | |
19208 | lt_prog_compiler_pic_CXX='-pic' | |
19209 | ;; | |
19210 | *) | |
19211 | ;; | |
19212 | esac | |
19213 | ;; | |
19214 | sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*) | |
19215 | case $cc_basename in | |
19216 | CC*) | |
19217 | lt_prog_compiler_wl_CXX='-Wl,' | |
19218 | lt_prog_compiler_pic_CXX='-KPIC' | |
19219 | lt_prog_compiler_static_CXX='-Bstatic' | |
19220 | ;; | |
19221 | esac | |
19222 | ;; | |
19223 | tandem*) | |
19224 | case $cc_basename in | |
19225 | NCC*) | |
19226 | # NonStop-UX NCC 3.20 | |
19227 | lt_prog_compiler_pic_CXX='-KPIC' | |
19228 | ;; | |
19229 | *) | |
19230 | ;; | |
19231 | esac | |
19232 | ;; | |
19233 | vxworks*) | |
19234 | ;; | |
19235 | *) | |
19236 | lt_prog_compiler_can_build_shared_CXX=no | |
19237 | ;; | |
19238 | esac | |
19239 | fi | |
19240 | ||
19241 | case $host_os in | |
19242 | # For platforms which do not support PIC, -DPIC is meaningless: | |
19243 | *djgpp*) | |
19244 | lt_prog_compiler_pic_CXX= | |
19245 | ;; | |
19246 | *) | |
19247 | lt_prog_compiler_pic_CXX="$lt_prog_compiler_pic_CXX -DPIC" | |
19248 | ;; | |
19249 | esac | |
5213506e RW |
19250 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_prog_compiler_pic_CXX" >&5 |
19251 | $as_echo "$lt_prog_compiler_pic_CXX" >&6; } | |
00020c16 ILT |
19252 | |
19253 | ||
19254 | ||
19255 | # | |
19256 | # Check to make sure the PIC flag actually works. | |
19257 | # | |
19258 | if test -n "$lt_prog_compiler_pic_CXX"; then | |
5213506e RW |
19259 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5 |
19260 | $as_echo_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works... " >&6; } | |
19261 | if test "${lt_cv_prog_compiler_pic_works_CXX+set}" = set; then : | |
19262 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
19263 | else |
19264 | lt_cv_prog_compiler_pic_works_CXX=no | |
19265 | ac_outfile=conftest.$ac_objext | |
19266 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
19267 | lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC" | |
19268 | # Insert the option either (1) after the last *FLAGS variable, or | |
19269 | # (2) before a word containing "conftest.", or (3) at the end. | |
19270 | # Note that $ac_compile itself does not contain backslashes and begins | |
19271 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
19272 | # The option is referenced via a variable to avoid confusing sed. | |
19273 | lt_compile=`echo "$ac_compile" | $SED \ | |
19274 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
19275 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
19276 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 19277 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
19278 | (eval "$lt_compile" 2>conftest.err) |
19279 | ac_status=$? | |
19280 | cat conftest.err >&5 | |
43e02a8a | 19281 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
19282 | if (exit $ac_status) && test -s "$ac_outfile"; then |
19283 | # The compiler can only warn and ignore the option if not recognized | |
19284 | # So say no if there are warnings other than the usual output. | |
43e02a8a | 19285 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' >conftest.exp |
00020c16 ILT |
19286 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
19287 | if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then | |
19288 | lt_cv_prog_compiler_pic_works_CXX=yes | |
19289 | fi | |
19290 | fi | |
19291 | $RM conftest* | |
19292 | ||
19293 | fi | |
5213506e RW |
19294 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_pic_works_CXX" >&5 |
19295 | $as_echo "$lt_cv_prog_compiler_pic_works_CXX" >&6; } | |
00020c16 ILT |
19296 | |
19297 | if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then | |
19298 | case $lt_prog_compiler_pic_CXX in | |
19299 | "" | " "*) ;; | |
19300 | *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;; | |
19301 | esac | |
19302 | else | |
19303 | lt_prog_compiler_pic_CXX= | |
19304 | lt_prog_compiler_can_build_shared_CXX=no | |
19305 | fi | |
19306 | ||
19307 | fi | |
19308 | ||
19309 | ||
19310 | ||
19311 | # | |
19312 | # Check to make sure the static flag actually works. | |
19313 | # | |
19314 | wl=$lt_prog_compiler_wl_CXX eval lt_tmp_static_flag=\"$lt_prog_compiler_static_CXX\" | |
5213506e RW |
19315 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler static flag $lt_tmp_static_flag works" >&5 |
19316 | $as_echo_n "checking if $compiler static flag $lt_tmp_static_flag works... " >&6; } | |
19317 | if test "${lt_cv_prog_compiler_static_works_CXX+set}" = set; then : | |
19318 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
19319 | else |
19320 | lt_cv_prog_compiler_static_works_CXX=no | |
19321 | save_LDFLAGS="$LDFLAGS" | |
19322 | LDFLAGS="$LDFLAGS $lt_tmp_static_flag" | |
19323 | echo "$lt_simple_link_test_code" > conftest.$ac_ext | |
19324 | if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then | |
19325 | # The linker can only warn and ignore the option if not recognized | |
19326 | # So say no if there are warnings | |
19327 | if test -s conftest.err; then | |
19328 | # Append any errors to the config.log. | |
19329 | cat conftest.err 1>&5 | |
43e02a8a | 19330 | $ECHO "$_lt_linker_boilerplate" | $SED '/^$/d' > conftest.exp |
00020c16 ILT |
19331 | $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2 |
19332 | if diff conftest.exp conftest.er2 >/dev/null; then | |
19333 | lt_cv_prog_compiler_static_works_CXX=yes | |
19334 | fi | |
19335 | else | |
19336 | lt_cv_prog_compiler_static_works_CXX=yes | |
19337 | fi | |
19338 | fi | |
19339 | $RM -r conftest* | |
19340 | LDFLAGS="$save_LDFLAGS" | |
19341 | ||
19342 | fi | |
5213506e RW |
19343 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_static_works_CXX" >&5 |
19344 | $as_echo "$lt_cv_prog_compiler_static_works_CXX" >&6; } | |
00020c16 ILT |
19345 | |
19346 | if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then | |
19347 | : | |
19348 | else | |
19349 | lt_prog_compiler_static_CXX= | |
19350 | fi | |
19351 | ||
19352 | ||
19353 | ||
19354 | ||
5213506e RW |
19355 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 |
19356 | $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } | |
19357 | if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then : | |
19358 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
19359 | else |
19360 | lt_cv_prog_compiler_c_o_CXX=no | |
19361 | $RM -r conftest 2>/dev/null | |
19362 | mkdir conftest | |
19363 | cd conftest | |
19364 | mkdir out | |
19365 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
19366 | ||
19367 | lt_compiler_flag="-o out/conftest2.$ac_objext" | |
19368 | # Insert the option either (1) after the last *FLAGS variable, or | |
19369 | # (2) before a word containing "conftest.", or (3) at the end. | |
19370 | # Note that $ac_compile itself does not contain backslashes and begins | |
19371 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
19372 | lt_compile=`echo "$ac_compile" | $SED \ | |
19373 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
19374 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
19375 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 19376 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
19377 | (eval "$lt_compile" 2>out/conftest.err) |
19378 | ac_status=$? | |
19379 | cat out/conftest.err >&5 | |
43e02a8a | 19380 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
19381 | if (exit $ac_status) && test -s out/conftest2.$ac_objext |
19382 | then | |
19383 | # The compiler can only warn and ignore the option if not recognized | |
19384 | # So say no if there are warnings | |
43e02a8a | 19385 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp |
00020c16 ILT |
19386 | $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 |
19387 | if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then | |
19388 | lt_cv_prog_compiler_c_o_CXX=yes | |
19389 | fi | |
19390 | fi | |
19391 | chmod u+w . 2>&5 | |
19392 | $RM conftest* | |
19393 | # SGI C++ compiler will create directory out/ii_files/ for | |
19394 | # template instantiation | |
19395 | test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files | |
19396 | $RM out/* && rmdir out | |
19397 | cd .. | |
19398 | $RM -r conftest | |
19399 | $RM conftest* | |
19400 | ||
19401 | fi | |
5213506e RW |
19402 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 |
19403 | $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } | |
00020c16 ILT |
19404 | |
19405 | ||
19406 | ||
5213506e RW |
19407 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $compiler supports -c -o file.$ac_objext" >&5 |
19408 | $as_echo_n "checking if $compiler supports -c -o file.$ac_objext... " >&6; } | |
19409 | if test "${lt_cv_prog_compiler_c_o_CXX+set}" = set; then : | |
19410 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
19411 | else |
19412 | lt_cv_prog_compiler_c_o_CXX=no | |
19413 | $RM -r conftest 2>/dev/null | |
19414 | mkdir conftest | |
19415 | cd conftest | |
19416 | mkdir out | |
19417 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
19418 | ||
19419 | lt_compiler_flag="-o out/conftest2.$ac_objext" | |
19420 | # Insert the option either (1) after the last *FLAGS variable, or | |
19421 | # (2) before a word containing "conftest.", or (3) at the end. | |
19422 | # Note that $ac_compile itself does not contain backslashes and begins | |
19423 | # with a dollar sign (not a hyphen), so the echo should work correctly. | |
19424 | lt_compile=`echo "$ac_compile" | $SED \ | |
19425 | -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \ | |
19426 | -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ | |
19427 | -e 's:$: $lt_compiler_flag:'` | |
43e02a8a | 19428 | (eval echo "\"\$as_me:$LINENO: $lt_compile\"" >&5) |
00020c16 ILT |
19429 | (eval "$lt_compile" 2>out/conftest.err) |
19430 | ac_status=$? | |
19431 | cat out/conftest.err >&5 | |
43e02a8a | 19432 | echo "$as_me:$LINENO: \$? = $ac_status" >&5 |
00020c16 ILT |
19433 | if (exit $ac_status) && test -s out/conftest2.$ac_objext |
19434 | then | |
19435 | # The compiler can only warn and ignore the option if not recognized | |
19436 | # So say no if there are warnings | |
43e02a8a | 19437 | $ECHO "$_lt_compiler_boilerplate" | $SED '/^$/d' > out/conftest.exp |
00020c16 ILT |
19438 | $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2 |
19439 | if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then | |
19440 | lt_cv_prog_compiler_c_o_CXX=yes | |
19441 | fi | |
19442 | fi | |
19443 | chmod u+w . 2>&5 | |
19444 | $RM conftest* | |
19445 | # SGI C++ compiler will create directory out/ii_files/ for | |
19446 | # template instantiation | |
19447 | test -d out/ii_files && $RM out/ii_files/* && rmdir out/ii_files | |
19448 | $RM out/* && rmdir out | |
19449 | cd .. | |
19450 | $RM -r conftest | |
19451 | $RM conftest* | |
19452 | ||
19453 | fi | |
5213506e RW |
19454 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_prog_compiler_c_o_CXX" >&5 |
19455 | $as_echo "$lt_cv_prog_compiler_c_o_CXX" >&6; } | |
00020c16 ILT |
19456 | |
19457 | ||
19458 | ||
19459 | ||
19460 | hard_links="nottested" | |
19461 | if test "$lt_cv_prog_compiler_c_o_CXX" = no && test "$need_locks" != no; then | |
19462 | # do not overwrite the value of need_locks provided by the user | |
5213506e RW |
19463 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can lock with hard links" >&5 |
19464 | $as_echo_n "checking if we can lock with hard links... " >&6; } | |
00020c16 ILT |
19465 | hard_links=yes |
19466 | $RM conftest* | |
19467 | ln conftest.a conftest.b 2>/dev/null && hard_links=no | |
19468 | touch conftest.a | |
19469 | ln conftest.a conftest.b 2>&5 || hard_links=no | |
19470 | ln conftest.a conftest.b 2>/dev/null && hard_links=no | |
5213506e RW |
19471 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hard_links" >&5 |
19472 | $as_echo "$hard_links" >&6; } | |
00020c16 | 19473 | if test "$hard_links" = no; then |
5213506e RW |
19474 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&5 |
19475 | $as_echo "$as_me: WARNING: \`$CC' does not support \`-c -o', so \`make -j' may be unsafe" >&2;} | |
00020c16 ILT |
19476 | need_locks=warn |
19477 | fi | |
19478 | else | |
19479 | need_locks=no | |
19480 | fi | |
19481 | ||
19482 | ||
19483 | ||
5213506e RW |
19484 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the $compiler linker ($LD) supports shared libraries" >&5 |
19485 | $as_echo_n "checking whether the $compiler linker ($LD) supports shared libraries... " >&6; } | |
00020c16 ILT |
19486 | |
19487 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' | |
19488 | case $host_os in | |
19489 | aix[4-9]*) | |
19490 | # If we're using GNU nm, then we don't want the "-C" option. | |
19491 | # -C means demangle to AIX nm, but means don't demangle with GNU nm | |
43e02a8a RW |
19492 | # Also, AIX nm treats weak defined symbols like other global defined |
19493 | # symbols, whereas GNU nm marks them as "W". | |
00020c16 | 19494 | if $NM -V 2>&1 | $GREP 'GNU' > /dev/null; then |
43e02a8a | 19495 | export_symbols_cmds_CXX='$NM -Bpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B") || (\$ 2 == "W")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' |
00020c16 ILT |
19496 | else |
19497 | export_symbols_cmds_CXX='$NM -BCpg $libobjs $convenience | awk '\''{ if (((\$ 2 == "T") || (\$ 2 == "D") || (\$ 2 == "B")) && (substr(\$ 3,1,1) != ".")) { print \$ 3 } }'\'' | sort -u > $export_symbols' | |
19498 | fi | |
19499 | ;; | |
19500 | pw32*) | |
19501 | export_symbols_cmds_CXX="$ltdll_cmds" | |
19502 | ;; | |
19503 | cygwin* | mingw* | cegcc*) | |
19504 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.* //'\'' | sort | uniq > $export_symbols' | |
19505 | ;; | |
19506 | *) | |
19507 | export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols' | |
19508 | ;; | |
19509 | esac | |
19510 | exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*' | |
19511 | ||
5213506e RW |
19512 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ld_shlibs_CXX" >&5 |
19513 | $as_echo "$ld_shlibs_CXX" >&6; } | |
00020c16 ILT |
19514 | test "$ld_shlibs_CXX" = no && can_build_shared=no |
19515 | ||
19516 | with_gnu_ld_CXX=$with_gnu_ld | |
19517 | ||
19518 | ||
19519 | ||
19520 | ||
19521 | ||
19522 | ||
19523 | # | |
19524 | # Do we need to explicitly link libc? | |
19525 | # | |
19526 | case "x$archive_cmds_need_lc_CXX" in | |
19527 | x|xyes) | |
19528 | # Assume -lc should be added | |
19529 | archive_cmds_need_lc_CXX=yes | |
19530 | ||
19531 | if test "$enable_shared" = yes && test "$GCC" = yes; then | |
19532 | case $archive_cmds_CXX in | |
19533 | *'~'*) | |
19534 | # FIXME: we may have to deal with multi-command sequences. | |
19535 | ;; | |
19536 | '$CC '*) | |
19537 | # Test whether the compiler implicitly links with -lc since on some | |
19538 | # systems, -lgcc has to come before -lc. If gcc already passes -lc | |
19539 | # to ld, don't add -lc before -lgcc. | |
5213506e RW |
19540 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -lc should be explicitly linked in" >&5 |
19541 | $as_echo_n "checking whether -lc should be explicitly linked in... " >&6; } | |
19542 | if test "${lt_cv_archive_cmds_need_lc_CXX+set}" = set; then : | |
19543 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
19544 | else |
19545 | $RM conftest* | |
19546 | echo "$lt_simple_compile_test_code" > conftest.$ac_ext | |
19547 | ||
5213506e | 19548 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_compile\""; } >&5 |
00020c16 ILT |
19549 | (eval $ac_compile) 2>&5 |
19550 | ac_status=$? | |
5213506e RW |
19551 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
19552 | test $ac_status = 0; } 2>conftest.err; then | |
00020c16 ILT |
19553 | soname=conftest |
19554 | lib=conftest | |
19555 | libobjs=conftest.$ac_objext | |
19556 | deplibs= | |
19557 | wl=$lt_prog_compiler_wl_CXX | |
19558 | pic_flag=$lt_prog_compiler_pic_CXX | |
19559 | compiler_flags=-v | |
19560 | linker_flags=-v | |
19561 | verstring= | |
19562 | output_objdir=. | |
19563 | libname=conftest | |
19564 | lt_save_allow_undefined_flag=$allow_undefined_flag_CXX | |
19565 | allow_undefined_flag_CXX= | |
5213506e | 19566 | if { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1\""; } >&5 |
00020c16 ILT |
19567 | (eval $archive_cmds_CXX 2\>\&1 \| $GREP \" -lc \" \>/dev/null 2\>\&1) 2>&5 |
19568 | ac_status=$? | |
5213506e RW |
19569 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
19570 | test $ac_status = 0; } | |
00020c16 ILT |
19571 | then |
19572 | lt_cv_archive_cmds_need_lc_CXX=no | |
19573 | else | |
19574 | lt_cv_archive_cmds_need_lc_CXX=yes | |
19575 | fi | |
19576 | allow_undefined_flag_CXX=$lt_save_allow_undefined_flag | |
19577 | else | |
19578 | cat conftest.err 1>&5 | |
19579 | fi | |
19580 | $RM conftest* | |
19581 | ||
19582 | fi | |
5213506e RW |
19583 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $lt_cv_archive_cmds_need_lc_CXX" >&5 |
19584 | $as_echo "$lt_cv_archive_cmds_need_lc_CXX" >&6; } | |
00020c16 ILT |
19585 | archive_cmds_need_lc_CXX=$lt_cv_archive_cmds_need_lc_CXX |
19586 | ;; | |
19587 | esac | |
19588 | fi | |
19589 | ;; | |
19590 | esac | |
19591 | ||
19592 | ||
19593 | ||
19594 | ||
19595 | ||
19596 | ||
19597 | ||
19598 | ||
19599 | ||
19600 | ||
19601 | ||
19602 | ||
19603 | ||
19604 | ||
19605 | ||
19606 | ||
19607 | ||
19608 | ||
19609 | ||
19610 | ||
19611 | ||
19612 | ||
19613 | ||
19614 | ||
19615 | ||
19616 | ||
19617 | ||
19618 | ||
19619 | ||
19620 | ||
19621 | ||
19622 | ||
19623 | ||
19624 | ||
19625 | ||
19626 | ||
19627 | ||
19628 | ||
19629 | ||
19630 | ||
19631 | ||
19632 | ||
19633 | ||
19634 | ||
19635 | ||
19636 | ||
19637 | ||
19638 | ||
19639 | ||
19640 | ||
19641 | ||
19642 | ||
19643 | ||
19644 | ||
19645 | ||
19646 | ||
19647 | ||
19648 | ||
19649 | ||
19650 | ||
19651 | ||
19652 | ||
19653 | ||
19654 | ||
5213506e RW |
19655 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking dynamic linker characteristics" >&5 |
19656 | $as_echo_n "checking dynamic linker characteristics... " >&6; } | |
00020c16 ILT |
19657 | |
19658 | library_names_spec= | |
19659 | libname_spec='lib$name' | |
19660 | soname_spec= | |
19661 | shrext_cmds=".so" | |
19662 | postinstall_cmds= | |
19663 | postuninstall_cmds= | |
19664 | finish_cmds= | |
19665 | finish_eval= | |
19666 | shlibpath_var= | |
19667 | shlibpath_overrides_runpath=unknown | |
19668 | version_type=none | |
19669 | dynamic_linker="$host_os ld.so" | |
19670 | sys_lib_dlsearch_path_spec="/lib /usr/lib" | |
19671 | need_lib_prefix=unknown | |
19672 | hardcode_into_libs=no | |
19673 | ||
19674 | # when you set need_version to no, make sure it does not cause -set_version | |
19675 | # flags to be left without arguments | |
19676 | need_version=unknown | |
19677 | ||
19678 | case $host_os in | |
19679 | aix3*) | |
19680 | version_type=linux | |
19681 | library_names_spec='${libname}${release}${shared_ext}$versuffix $libname.a' | |
19682 | shlibpath_var=LIBPATH | |
19683 | ||
19684 | # AIX 3 has no versioning support, so we append a major version to the name. | |
19685 | soname_spec='${libname}${release}${shared_ext}$major' | |
19686 | ;; | |
19687 | ||
19688 | aix[4-9]*) | |
19689 | version_type=linux | |
19690 | need_lib_prefix=no | |
19691 | need_version=no | |
19692 | hardcode_into_libs=yes | |
19693 | if test "$host_cpu" = ia64; then | |
19694 | # AIX 5 supports IA64 | |
19695 | library_names_spec='${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext}$versuffix $libname${shared_ext}' | |
19696 | shlibpath_var=LD_LIBRARY_PATH | |
19697 | else | |
19698 | # With GCC up to 2.95.x, collect2 would create an import file | |
19699 | # for dependence libraries. The import file would start with | |
19700 | # the line `#! .'. This would cause the generated library to | |
19701 | # depend on `.', always an invalid library. This was fixed in | |
19702 | # development snapshots of GCC prior to 3.0. | |
19703 | case $host_os in | |
19704 | aix4 | aix4.[01] | aix4.[01].*) | |
19705 | if { echo '#if __GNUC__ > 2 || (__GNUC__ == 2 && __GNUC_MINOR__ >= 97)' | |
19706 | echo ' yes ' | |
19707 | echo '#endif'; } | ${CC} -E - | $GREP yes > /dev/null; then | |
19708 | : | |
19709 | else | |
19710 | can_build_shared=no | |
19711 | fi | |
19712 | ;; | |
19713 | esac | |
19714 | # AIX (on Power*) has no versioning support, so currently we can not hardcode correct | |
19715 | # soname into executable. Probably we can add versioning support to | |
19716 | # collect2, so additional links can be useful in future. | |
19717 | if test "$aix_use_runtimelinking" = yes; then | |
19718 | # If using run time linking (on AIX 4.2 or later) use lib<name>.so | |
19719 | # instead of lib<name>.a to let people know that these are not | |
19720 | # typical AIX shared libraries. | |
19721 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19722 | else | |
19723 | # We preserve .a as extension for shared libraries through AIX4.2 | |
19724 | # and later when we are not doing run time linking. | |
19725 | library_names_spec='${libname}${release}.a $libname.a' | |
19726 | soname_spec='${libname}${release}${shared_ext}$major' | |
19727 | fi | |
19728 | shlibpath_var=LIBPATH | |
19729 | fi | |
19730 | ;; | |
19731 | ||
19732 | amigaos*) | |
19733 | case $host_cpu in | |
19734 | powerpc) | |
19735 | # Since July 2007 AmigaOS4 officially supports .so libraries. | |
19736 | # When compiling the executable, add -use-dynld -Lsobjs: to the compileline. | |
19737 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19738 | ;; | |
19739 | m68k) | |
19740 | library_names_spec='$libname.ixlibrary $libname.a' | |
19741 | # Create ${libname}_ixlibrary.a entries in /sys/libs. | |
43e02a8a | 19742 | finish_eval='for lib in `ls $libdir/*.ixlibrary 2>/dev/null`; do libname=`func_echo_all "$lib" | $SED '\''s%^.*/\([^/]*\)\.ixlibrary$%\1%'\''`; test $RM /sys/libs/${libname}_ixlibrary.a; $show "cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a"; cd /sys/libs && $LN_S $lib ${libname}_ixlibrary.a || exit 1; done' |
00020c16 ILT |
19743 | ;; |
19744 | esac | |
19745 | ;; | |
19746 | ||
19747 | beos*) | |
19748 | library_names_spec='${libname}${shared_ext}' | |
19749 | dynamic_linker="$host_os ld.so" | |
19750 | shlibpath_var=LIBRARY_PATH | |
19751 | ;; | |
19752 | ||
19753 | bsdi[45]*) | |
19754 | version_type=linux | |
19755 | need_version=no | |
19756 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19757 | soname_spec='${libname}${release}${shared_ext}$major' | |
19758 | finish_cmds='PATH="\$PATH:/sbin" ldconfig $libdir' | |
19759 | shlibpath_var=LD_LIBRARY_PATH | |
19760 | sys_lib_search_path_spec="/shlib /usr/lib /usr/X11/lib /usr/contrib/lib /lib /usr/local/lib" | |
19761 | sys_lib_dlsearch_path_spec="/shlib /usr/lib /usr/local/lib" | |
19762 | # the default ld.so.conf also contains /usr/contrib/lib and | |
19763 | # /usr/X11R6/lib (/usr/X11 is a link to /usr/X11R6), but let us allow | |
19764 | # libtool to hard-code these into programs | |
19765 | ;; | |
19766 | ||
19767 | cygwin* | mingw* | pw32* | cegcc*) | |
19768 | version_type=windows | |
19769 | shrext_cmds=".dll" | |
19770 | need_version=no | |
19771 | need_lib_prefix=no | |
19772 | ||
19773 | case $GCC,$host_os in | |
19774 | yes,cygwin* | yes,mingw* | yes,pw32* | yes,cegcc*) | |
19775 | library_names_spec='$libname.dll.a' | |
19776 | # DLL is installed to $(libdir)/../bin by postinstall_cmds | |
19777 | postinstall_cmds='base_file=`basename \${file}`~ | |
19778 | dlpath=`$SHELL 2>&1 -c '\''. $dir/'\''\${base_file}'\''i; echo \$dlname'\''`~ | |
19779 | dldir=$destdir/`dirname \$dlpath`~ | |
19780 | test -d \$dldir || mkdir -p \$dldir~ | |
19781 | $install_prog $dir/$dlname \$dldir/$dlname~ | |
19782 | chmod a+x \$dldir/$dlname~ | |
19783 | if test -n '\''$stripme'\'' && test -n '\''$striplib'\''; then | |
19784 | eval '\''$striplib \$dldir/$dlname'\'' || exit \$?; | |
19785 | fi' | |
19786 | postuninstall_cmds='dldll=`$SHELL 2>&1 -c '\''. $file; echo \$dlname'\''`~ | |
19787 | dlpath=$dir/\$dldll~ | |
19788 | $RM \$dlpath' | |
19789 | shlibpath_overrides_runpath=yes | |
19790 | ||
19791 | case $host_os in | |
19792 | cygwin*) | |
19793 | # Cygwin DLLs use 'cyg' prefix rather than 'lib' | |
19794 | soname_spec='`echo ${libname} | sed -e 's/^lib/cyg/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
43e02a8a | 19795 | |
00020c16 ILT |
19796 | ;; |
19797 | mingw* | cegcc*) | |
19798 | # MinGW DLLs use traditional 'lib' prefix | |
19799 | soname_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
00020c16 ILT |
19800 | ;; |
19801 | pw32*) | |
19802 | # pw32 DLLs use 'pw' prefix rather than 'lib' | |
19803 | library_names_spec='`echo ${libname} | sed -e 's/^lib/pw/'``echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext}' | |
19804 | ;; | |
19805 | esac | |
19806 | ;; | |
19807 | ||
19808 | *) | |
19809 | library_names_spec='${libname}`echo ${release} | $SED -e 's/[.]/-/g'`${versuffix}${shared_ext} $libname.lib' | |
19810 | ;; | |
19811 | esac | |
19812 | dynamic_linker='Win32 ld.exe' | |
19813 | # FIXME: first we should search . and the directory the executable is in | |
19814 | shlibpath_var=PATH | |
19815 | ;; | |
19816 | ||
19817 | darwin* | rhapsody*) | |
19818 | dynamic_linker="$host_os dyld" | |
19819 | version_type=darwin | |
19820 | need_lib_prefix=no | |
19821 | need_version=no | |
19822 | library_names_spec='${libname}${release}${major}$shared_ext ${libname}$shared_ext' | |
19823 | soname_spec='${libname}${release}${major}$shared_ext' | |
19824 | shlibpath_overrides_runpath=yes | |
19825 | shlibpath_var=DYLD_LIBRARY_PATH | |
19826 | shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`' | |
19827 | ||
19828 | sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib' | |
19829 | ;; | |
19830 | ||
19831 | dgux*) | |
19832 | version_type=linux | |
19833 | need_lib_prefix=no | |
19834 | need_version=no | |
19835 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname$shared_ext' | |
19836 | soname_spec='${libname}${release}${shared_ext}$major' | |
19837 | shlibpath_var=LD_LIBRARY_PATH | |
19838 | ;; | |
19839 | ||
19840 | freebsd1*) | |
19841 | dynamic_linker=no | |
19842 | ;; | |
19843 | ||
19844 | freebsd* | dragonfly*) | |
19845 | # DragonFly does not have aout. When/if they implement a new | |
19846 | # versioning mechanism, adjust this. | |
19847 | if test -x /usr/bin/objformat; then | |
19848 | objformat=`/usr/bin/objformat` | |
19849 | else | |
19850 | case $host_os in | |
19851 | freebsd[123]*) objformat=aout ;; | |
19852 | *) objformat=elf ;; | |
19853 | esac | |
19854 | fi | |
19855 | version_type=freebsd-$objformat | |
19856 | case $version_type in | |
19857 | freebsd-elf*) | |
19858 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' | |
19859 | need_version=no | |
19860 | need_lib_prefix=no | |
19861 | ;; | |
19862 | freebsd-*) | |
19863 | library_names_spec='${libname}${release}${shared_ext}$versuffix $libname${shared_ext}$versuffix' | |
19864 | need_version=yes | |
19865 | ;; | |
19866 | esac | |
19867 | shlibpath_var=LD_LIBRARY_PATH | |
19868 | case $host_os in | |
19869 | freebsd2*) | |
19870 | shlibpath_overrides_runpath=yes | |
19871 | ;; | |
19872 | freebsd3.[01]* | freebsdelf3.[01]*) | |
19873 | shlibpath_overrides_runpath=yes | |
19874 | hardcode_into_libs=yes | |
19875 | ;; | |
19876 | freebsd3.[2-9]* | freebsdelf3.[2-9]* | \ | |
19877 | freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1) | |
19878 | shlibpath_overrides_runpath=no | |
19879 | hardcode_into_libs=yes | |
19880 | ;; | |
19881 | *) # from 4.6 on, and DragonFly | |
19882 | shlibpath_overrides_runpath=yes | |
19883 | hardcode_into_libs=yes | |
19884 | ;; | |
19885 | esac | |
19886 | ;; | |
19887 | ||
19888 | gnu*) | |
19889 | version_type=linux | |
19890 | need_lib_prefix=no | |
19891 | need_version=no | |
19892 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' | |
19893 | soname_spec='${libname}${release}${shared_ext}$major' | |
19894 | shlibpath_var=LD_LIBRARY_PATH | |
19895 | hardcode_into_libs=yes | |
19896 | ;; | |
19897 | ||
43e02a8a RW |
19898 | haiku*) |
19899 | version_type=linux | |
19900 | need_lib_prefix=no | |
19901 | need_version=no | |
19902 | dynamic_linker="$host_os runtime_loader" | |
19903 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}${major} ${libname}${shared_ext}' | |
19904 | soname_spec='${libname}${release}${shared_ext}$major' | |
19905 | shlibpath_var=LIBRARY_PATH | |
19906 | shlibpath_overrides_runpath=yes | |
19907 | sys_lib_dlsearch_path_spec='/boot/home/config/lib /boot/common/lib /boot/beos/system/lib' | |
19908 | hardcode_into_libs=yes | |
19909 | ;; | |
19910 | ||
00020c16 ILT |
19911 | hpux9* | hpux10* | hpux11*) |
19912 | # Give a soname corresponding to the major version so that dld.sl refuses to | |
19913 | # link against other versions. | |
19914 | version_type=sunos | |
19915 | need_lib_prefix=no | |
19916 | need_version=no | |
19917 | case $host_cpu in | |
19918 | ia64*) | |
19919 | shrext_cmds='.so' | |
19920 | hardcode_into_libs=yes | |
19921 | dynamic_linker="$host_os dld.so" | |
19922 | shlibpath_var=LD_LIBRARY_PATH | |
19923 | shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. | |
19924 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19925 | soname_spec='${libname}${release}${shared_ext}$major' | |
19926 | if test "X$HPUX_IA64_MODE" = X32; then | |
19927 | sys_lib_search_path_spec="/usr/lib/hpux32 /usr/local/lib/hpux32 /usr/local/lib" | |
19928 | else | |
19929 | sys_lib_search_path_spec="/usr/lib/hpux64 /usr/local/lib/hpux64" | |
19930 | fi | |
19931 | sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec | |
19932 | ;; | |
19933 | hppa*64*) | |
19934 | shrext_cmds='.sl' | |
19935 | hardcode_into_libs=yes | |
19936 | dynamic_linker="$host_os dld.sl" | |
19937 | shlibpath_var=LD_LIBRARY_PATH # How should we handle SHLIB_PATH | |
19938 | shlibpath_overrides_runpath=yes # Unless +noenvvar is specified. | |
19939 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19940 | soname_spec='${libname}${release}${shared_ext}$major' | |
19941 | sys_lib_search_path_spec="/usr/lib/pa20_64 /usr/ccs/lib/pa20_64" | |
19942 | sys_lib_dlsearch_path_spec=$sys_lib_search_path_spec | |
19943 | ;; | |
19944 | *) | |
19945 | shrext_cmds='.sl' | |
19946 | dynamic_linker="$host_os dld.sl" | |
19947 | shlibpath_var=SHLIB_PATH | |
19948 | shlibpath_overrides_runpath=no # +s is required to enable SHLIB_PATH | |
19949 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
19950 | soname_spec='${libname}${release}${shared_ext}$major' | |
19951 | ;; | |
19952 | esac | |
43e02a8a | 19953 | # HP-UX runs *really* slowly unless shared libraries are mode 555, ... |
00020c16 | 19954 | postinstall_cmds='chmod 555 $lib' |
43e02a8a RW |
19955 | # or fails outright, so override atomically: |
19956 | install_override_mode=555 | |
00020c16 ILT |
19957 | ;; |
19958 | ||
19959 | interix[3-9]*) | |
19960 | version_type=linux | |
19961 | need_lib_prefix=no | |
19962 | need_version=no | |
19963 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' | |
19964 | soname_spec='${libname}${release}${shared_ext}$major' | |
19965 | dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)' | |
19966 | shlibpath_var=LD_LIBRARY_PATH | |
19967 | shlibpath_overrides_runpath=no | |
19968 | hardcode_into_libs=yes | |
19969 | ;; | |
19970 | ||
19971 | irix5* | irix6* | nonstopux*) | |
19972 | case $host_os in | |
19973 | nonstopux*) version_type=nonstopux ;; | |
19974 | *) | |
19975 | if test "$lt_cv_prog_gnu_ld" = yes; then | |
19976 | version_type=linux | |
19977 | else | |
19978 | version_type=irix | |
19979 | fi ;; | |
19980 | esac | |
19981 | need_lib_prefix=no | |
19982 | need_version=no | |
19983 | soname_spec='${libname}${release}${shared_ext}$major' | |
19984 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${release}${shared_ext} $libname${shared_ext}' | |
19985 | case $host_os in | |
19986 | irix5* | nonstopux*) | |
19987 | libsuff= shlibsuff= | |
19988 | ;; | |
19989 | *) | |
19990 | case $LD in # libtool.m4 will add one of these switches to LD | |
19991 | *-32|*"-32 "|*-melf32bsmip|*"-melf32bsmip ") | |
19992 | libsuff= shlibsuff= libmagic=32-bit;; | |
19993 | *-n32|*"-n32 "|*-melf32bmipn32|*"-melf32bmipn32 ") | |
19994 | libsuff=32 shlibsuff=N32 libmagic=N32;; | |
19995 | *-64|*"-64 "|*-melf64bmip|*"-melf64bmip ") | |
19996 | libsuff=64 shlibsuff=64 libmagic=64-bit;; | |
19997 | *) libsuff= shlibsuff= libmagic=never-match;; | |
19998 | esac | |
19999 | ;; | |
20000 | esac | |
20001 | shlibpath_var=LD_LIBRARY${shlibsuff}_PATH | |
20002 | shlibpath_overrides_runpath=no | |
20003 | sys_lib_search_path_spec="/usr/lib${libsuff} /lib${libsuff} /usr/local/lib${libsuff}" | |
20004 | sys_lib_dlsearch_path_spec="/usr/lib${libsuff} /lib${libsuff}" | |
20005 | hardcode_into_libs=yes | |
20006 | ;; | |
20007 | ||
20008 | # No shared lib support for Linux oldld, aout, or coff. | |
20009 | linux*oldld* | linux*aout* | linux*coff*) | |
20010 | dynamic_linker=no | |
20011 | ;; | |
20012 | ||
20013 | # This must be Linux ELF. | |
20014 | linux* | k*bsd*-gnu | kopensolaris*-gnu) | |
20015 | version_type=linux | |
20016 | need_lib_prefix=no | |
20017 | need_version=no | |
20018 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20019 | soname_spec='${libname}${release}${shared_ext}$major' | |
20020 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -n $libdir' | |
20021 | shlibpath_var=LD_LIBRARY_PATH | |
20022 | shlibpath_overrides_runpath=no | |
20023 | ||
20024 | # Some binutils ld are patched to set DT_RUNPATH | |
5213506e RW |
20025 | if test "${lt_cv_shlibpath_overrides_runpath+set}" = set; then : |
20026 | $as_echo_n "(cached) " >&6 | |
00020c16 ILT |
20027 | else |
20028 | lt_cv_shlibpath_overrides_runpath=no | |
20029 | save_LDFLAGS=$LDFLAGS | |
20030 | save_libdir=$libdir | |
20031 | eval "libdir=/foo; wl=\"$lt_prog_compiler_wl_CXX\"; \ | |
20032 | LDFLAGS=\"\$LDFLAGS $hardcode_libdir_flag_spec_CXX\"" | |
5213506e | 20033 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext |
00020c16 ILT |
20034 | /* end confdefs.h. */ |
20035 | ||
20036 | int | |
20037 | main () | |
20038 | { | |
20039 | ||
da0f6381 PB |
20040 | ; |
20041 | return 0; | |
20042 | } | |
20043 | _ACEOF | |
5213506e RW |
20044 | if ac_fn_cxx_try_link "$LINENO"; then : |
20045 | if ($OBJDUMP -p conftest$ac_exeext) 2>/dev/null | grep "RUNPATH.*$libdir" >/dev/null; then : | |
00020c16 ILT |
20046 | lt_cv_shlibpath_overrides_runpath=yes |
20047 | fi | |
da0f6381 | 20048 | fi |
5213506e RW |
20049 | rm -f core conftest.err conftest.$ac_objext \ |
20050 | conftest$ac_exeext conftest.$ac_ext | |
00020c16 ILT |
20051 | LDFLAGS=$save_LDFLAGS |
20052 | libdir=$save_libdir | |
da0f6381 PB |
20053 | |
20054 | fi | |
20055 | ||
00020c16 | 20056 | shlibpath_overrides_runpath=$lt_cv_shlibpath_overrides_runpath |
da0f6381 | 20057 | |
00020c16 ILT |
20058 | # This implies no fast_install, which is unacceptable. |
20059 | # Some rework will be needed to allow for fast_install | |
20060 | # before this can be enabled. | |
20061 | hardcode_into_libs=yes | |
da0f6381 | 20062 | |
00020c16 ILT |
20063 | # Append ld.so.conf contents to the search path |
20064 | if test -f /etc/ld.so.conf; then | |
43e02a8a | 20065 | lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ ]*hwcap[ ]/d;s/[:, ]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;s/"//g;/^$/d' | tr '\n' ' '` |
00020c16 ILT |
20066 | sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra" |
20067 | fi | |
da0f6381 | 20068 | |
00020c16 ILT |
20069 | # We used to test for /lib/ld.so.1 and disable shared libraries on |
20070 | # powerpc, because MkLinux only supported shared libraries with the | |
20071 | # GNU dynamic linker. Since this was broken with cross compilers, | |
20072 | # most powerpc-linux boxes support dynamic linking these days and | |
20073 | # people can always --disable-shared, the test was removed, and we | |
20074 | # assume the GNU/Linux dynamic linker is in use. | |
20075 | dynamic_linker='GNU/Linux ld.so' | |
20076 | ;; | |
da0f6381 | 20077 | |
00020c16 ILT |
20078 | netbsd*) |
20079 | version_type=sunos | |
20080 | need_lib_prefix=no | |
20081 | need_version=no | |
20082 | if echo __ELF__ | $CC -E - | $GREP __ELF__ >/dev/null; then | |
20083 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' | |
20084 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' | |
20085 | dynamic_linker='NetBSD (a.out) ld.so' | |
20086 | else | |
20087 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}' | |
20088 | soname_spec='${libname}${release}${shared_ext}$major' | |
20089 | dynamic_linker='NetBSD ld.elf_so' | |
20090 | fi | |
20091 | shlibpath_var=LD_LIBRARY_PATH | |
20092 | shlibpath_overrides_runpath=yes | |
20093 | hardcode_into_libs=yes | |
20094 | ;; | |
da0f6381 | 20095 | |
00020c16 ILT |
20096 | newsos6) |
20097 | version_type=linux | |
20098 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20099 | shlibpath_var=LD_LIBRARY_PATH | |
20100 | shlibpath_overrides_runpath=yes | |
20101 | ;; | |
da0f6381 | 20102 | |
00020c16 ILT |
20103 | *nto* | *qnx*) |
20104 | version_type=qnx | |
20105 | need_lib_prefix=no | |
20106 | need_version=no | |
20107 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20108 | soname_spec='${libname}${release}${shared_ext}$major' | |
20109 | shlibpath_var=LD_LIBRARY_PATH | |
20110 | shlibpath_overrides_runpath=no | |
20111 | hardcode_into_libs=yes | |
20112 | dynamic_linker='ldqnx.so' | |
20113 | ;; | |
da0f6381 | 20114 | |
00020c16 ILT |
20115 | openbsd*) |
20116 | version_type=sunos | |
20117 | sys_lib_dlsearch_path_spec="/usr/lib" | |
20118 | need_lib_prefix=no | |
20119 | # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs. | |
20120 | case $host_os in | |
20121 | openbsd3.3 | openbsd3.3.*) need_version=yes ;; | |
20122 | *) need_version=no ;; | |
da0f6381 | 20123 | esac |
00020c16 ILT |
20124 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' |
20125 | finish_cmds='PATH="\$PATH:/sbin" ldconfig -m $libdir' | |
20126 | shlibpath_var=LD_LIBRARY_PATH | |
20127 | if test -z "`echo __ELF__ | $CC -E - | $GREP __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then | |
20128 | case $host_os in | |
20129 | openbsd2.[89] | openbsd2.[89].*) | |
20130 | shlibpath_overrides_runpath=no | |
20131 | ;; | |
20132 | *) | |
20133 | shlibpath_overrides_runpath=yes | |
20134 | ;; | |
20135 | esac | |
da0f6381 | 20136 | else |
00020c16 | 20137 | shlibpath_overrides_runpath=yes |
da0f6381 | 20138 | fi |
00020c16 | 20139 | ;; |
da0f6381 | 20140 | |
00020c16 ILT |
20141 | os2*) |
20142 | libname_spec='$name' | |
20143 | shrext_cmds=".dll" | |
20144 | need_lib_prefix=no | |
20145 | library_names_spec='$libname${shared_ext} $libname.a' | |
20146 | dynamic_linker='OS/2 ld.exe' | |
20147 | shlibpath_var=LIBPATH | |
20148 | ;; | |
da0f6381 | 20149 | |
00020c16 ILT |
20150 | osf3* | osf4* | osf5*) |
20151 | version_type=osf | |
20152 | need_lib_prefix=no | |
20153 | need_version=no | |
20154 | soname_spec='${libname}${release}${shared_ext}$major' | |
20155 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20156 | shlibpath_var=LD_LIBRARY_PATH | |
20157 | sys_lib_search_path_spec="/usr/shlib /usr/ccs/lib /usr/lib/cmplrs/cc /usr/lib /usr/local/lib /var/shlib" | |
20158 | sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec" | |
20159 | ;; | |
da0f6381 | 20160 | |
00020c16 ILT |
20161 | rdos*) |
20162 | dynamic_linker=no | |
20163 | ;; | |
da0f6381 | 20164 | |
00020c16 ILT |
20165 | solaris*) |
20166 | version_type=linux | |
20167 | need_lib_prefix=no | |
20168 | need_version=no | |
20169 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20170 | soname_spec='${libname}${release}${shared_ext}$major' | |
20171 | shlibpath_var=LD_LIBRARY_PATH | |
20172 | shlibpath_overrides_runpath=yes | |
20173 | hardcode_into_libs=yes | |
20174 | # ldd complains unless libraries are executable | |
20175 | postinstall_cmds='chmod +x $lib' | |
20176 | ;; | |
da0f6381 | 20177 | |
00020c16 ILT |
20178 | sunos4*) |
20179 | version_type=sunos | |
20180 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${shared_ext}$versuffix' | |
20181 | finish_cmds='PATH="\$PATH:/usr/etc" ldconfig $libdir' | |
20182 | shlibpath_var=LD_LIBRARY_PATH | |
20183 | shlibpath_overrides_runpath=yes | |
20184 | if test "$with_gnu_ld" = yes; then | |
20185 | need_lib_prefix=no | |
20186 | fi | |
20187 | need_version=yes | |
20188 | ;; | |
da0f6381 | 20189 | |
00020c16 ILT |
20190 | sysv4 | sysv4.3*) |
20191 | version_type=linux | |
20192 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20193 | soname_spec='${libname}${release}${shared_ext}$major' | |
20194 | shlibpath_var=LD_LIBRARY_PATH | |
20195 | case $host_vendor in | |
20196 | sni) | |
20197 | shlibpath_overrides_runpath=no | |
20198 | need_lib_prefix=no | |
20199 | runpath_var=LD_RUN_PATH | |
20200 | ;; | |
20201 | siemens) | |
20202 | need_lib_prefix=no | |
20203 | ;; | |
20204 | motorola) | |
20205 | need_lib_prefix=no | |
20206 | need_version=no | |
20207 | shlibpath_overrides_runpath=no | |
20208 | sys_lib_search_path_spec='/lib /usr/lib /usr/ccs/lib' | |
20209 | ;; | |
20210 | esac | |
20211 | ;; | |
da0f6381 | 20212 | |
00020c16 ILT |
20213 | sysv4*MP*) |
20214 | if test -d /usr/nec ;then | |
20215 | version_type=linux | |
20216 | library_names_spec='$libname${shared_ext}.$versuffix $libname${shared_ext}.$major $libname${shared_ext}' | |
20217 | soname_spec='$libname${shared_ext}.$major' | |
20218 | shlibpath_var=LD_LIBRARY_PATH | |
20219 | fi | |
20220 | ;; | |
da0f6381 | 20221 | |
00020c16 ILT |
20222 | sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*) |
20223 | version_type=freebsd-elf | |
20224 | need_lib_prefix=no | |
20225 | need_version=no | |
20226 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}' | |
20227 | soname_spec='${libname}${release}${shared_ext}$major' | |
20228 | shlibpath_var=LD_LIBRARY_PATH | |
20229 | shlibpath_overrides_runpath=yes | |
20230 | hardcode_into_libs=yes | |
20231 | if test "$with_gnu_ld" = yes; then | |
20232 | sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib' | |
da0f6381 | 20233 | else |
00020c16 ILT |
20234 | sys_lib_search_path_spec='/usr/ccs/lib /usr/lib' |
20235 | case $host_os in | |
20236 | sco3.2v5*) | |
20237 | sys_lib_search_path_spec="$sys_lib_search_path_spec /lib" | |
20238 | ;; | |
da0f6381 | 20239 | esac |
da0f6381 | 20240 | fi |
00020c16 ILT |
20241 | sys_lib_dlsearch_path_spec='/usr/lib' |
20242 | ;; | |
da0f6381 | 20243 | |
00020c16 ILT |
20244 | tpf*) |
20245 | # TPF is a cross-target only. Preferred cross-host = GNU/Linux. | |
20246 | version_type=linux | |
20247 | need_lib_prefix=no | |
20248 | need_version=no | |
20249 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20250 | shlibpath_var=LD_LIBRARY_PATH | |
20251 | shlibpath_overrides_runpath=no | |
20252 | hardcode_into_libs=yes | |
20253 | ;; | |
da0f6381 | 20254 | |
00020c16 ILT |
20255 | uts4*) |
20256 | version_type=linux | |
20257 | library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}' | |
20258 | soname_spec='${libname}${release}${shared_ext}$major' | |
20259 | shlibpath_var=LD_LIBRARY_PATH | |
20260 | ;; | |
da0f6381 | 20261 | |
00020c16 ILT |
20262 | *) |
20263 | dynamic_linker=no | |
20264 | ;; | |
20265 | esac | |
5213506e RW |
20266 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $dynamic_linker" >&5 |
20267 | $as_echo "$dynamic_linker" >&6; } | |
00020c16 | 20268 | test "$dynamic_linker" = no && can_build_shared=no |
da0f6381 | 20269 | |
00020c16 ILT |
20270 | variables_saved_for_relink="PATH $shlibpath_var $runpath_var" |
20271 | if test "$GCC" = yes; then | |
20272 | variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH" | |
20273 | fi | |
da0f6381 | 20274 | |
00020c16 ILT |
20275 | if test "${lt_cv_sys_lib_search_path_spec+set}" = set; then |
20276 | sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec" | |
20277 | fi | |
20278 | if test "${lt_cv_sys_lib_dlsearch_path_spec+set}" = set; then | |
20279 | sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec" | |
20280 | fi | |
da0f6381 | 20281 | |
da0f6381 | 20282 | |
da0f6381 | 20283 | |
da0f6381 | 20284 | |
da0f6381 | 20285 | |
da0f6381 PB |
20286 | |
20287 | ||
da0f6381 | 20288 | |
da0f6381 | 20289 | |
da0f6381 | 20290 | |
da0f6381 PB |
20291 | |
20292 | ||
20293 | ||
20294 | ||
20295 | ||
20296 | ||
20297 | ||
20298 | ||
20299 | ||
20300 | ||
20301 | ||
20302 | ||
20303 | ||
20304 | ||
20305 | ||
20306 | ||
20307 | ||
da0f6381 PB |
20308 | |
20309 | ||
20310 | ||
20311 | ||
20312 | ||
20313 | ||
43e02a8a RW |
20314 | |
20315 | ||
da0f6381 PB |
20316 | |
20317 | ||
20318 | ||
5213506e RW |
20319 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to hardcode library paths into programs" >&5 |
20320 | $as_echo_n "checking how to hardcode library paths into programs... " >&6; } | |
00020c16 ILT |
20321 | hardcode_action_CXX= |
20322 | if test -n "$hardcode_libdir_flag_spec_CXX" || | |
20323 | test -n "$runpath_var_CXX" || | |
20324 | test "X$hardcode_automatic_CXX" = "Xyes" ; then | |
da0f6381 | 20325 | |
00020c16 ILT |
20326 | # We can hardcode non-existent directories. |
20327 | if test "$hardcode_direct_CXX" != no && | |
20328 | # If the only mechanism to avoid hardcoding is shlibpath_var, we | |
20329 | # have to relink, otherwise we might link with an installed library | |
20330 | # when we should be linking with a yet-to-be-installed one | |
20331 | ## test "$_LT_TAGVAR(hardcode_shlibpath_var, CXX)" != no && | |
20332 | test "$hardcode_minus_L_CXX" != no; then | |
20333 | # Linking always hardcodes the temporary library directory. | |
20334 | hardcode_action_CXX=relink | |
20335 | else | |
20336 | # We can link without hardcoding, and we can hardcode nonexisting dirs. | |
20337 | hardcode_action_CXX=immediate | |
20338 | fi | |
20339 | else | |
20340 | # We cannot hardcode anything, or else we can only hardcode existing | |
20341 | # directories. | |
20342 | hardcode_action_CXX=unsupported | |
20343 | fi | |
5213506e RW |
20344 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $hardcode_action_CXX" >&5 |
20345 | $as_echo "$hardcode_action_CXX" >&6; } | |
da0f6381 | 20346 | |
00020c16 ILT |
20347 | if test "$hardcode_action_CXX" = relink || |
20348 | test "$inherit_rpath_CXX" = yes; then | |
20349 | # Fast installation is not supported | |
20350 | enable_fast_install=no | |
20351 | elif test "$shlibpath_overrides_runpath" = yes || | |
20352 | test "$enable_shared" = no; then | |
20353 | # Fast installation is not necessary | |
20354 | enable_fast_install=needless | |
20355 | fi | |
da0f6381 | 20356 | |
da0f6381 | 20357 | |
da0f6381 | 20358 | |
da0f6381 | 20359 | |
da0f6381 | 20360 | |
da0f6381 PB |
20361 | |
20362 | ||
00020c16 | 20363 | fi # test -n "$compiler" |
da0f6381 | 20364 | |
00020c16 ILT |
20365 | CC=$lt_save_CC |
20366 | LDCXX=$LD | |
20367 | LD=$lt_save_LD | |
20368 | GCC=$lt_save_GCC | |
20369 | with_gnu_ld=$lt_save_with_gnu_ld | |
20370 | lt_cv_path_LDCXX=$lt_cv_path_LD | |
20371 | lt_cv_path_LD=$lt_save_path_LD | |
20372 | lt_cv_prog_gnu_ldcxx=$lt_cv_prog_gnu_ld | |
20373 | lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld | |
20374 | fi # test "$_lt_caught_CXX_error" != yes | |
da0f6381 | 20375 | |
da0f6381 PB |
20376 | ac_ext=c |
20377 | ac_cpp='$CPP $CPPFLAGS' | |
20378 | ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |
20379 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | |
20380 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | |
20381 | ||
da0f6381 PB |
20382 | |
20383 | ||
20384 | ||
20385 | ||
20386 | ||
20387 | ||
20388 | ||
20389 | ||
20390 | ||
20391 | ||
20392 | ||
20393 | ||
20394 | ||
20395 | ||
20396 | ||
20397 | # Only expand once: | |
20398 | ||
20399 | ||
20400 | ||
20401 | ||
20402 | ||
20403 | # Identify the assembler which will work hand-in-glove with the newly | |
20404 | # built GCC, so that we can examine its features. This is the assembler | |
20405 | # which will be driven by the driver program. | |
20406 | # | |
20407 | # If build != host, and we aren't building gas in-tree, we identify a | |
20408 | # build->target assembler and hope that it will have the same features | |
20409 | # as the host->target assembler we'll be using. | |
20410 | gcc_cv_gas_major_version= | |
20411 | gcc_cv_gas_minor_version= | |
20412 | gcc_cv_as_gas_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/gas | |
20413 | ||
5213506e RW |
20414 | if test "${gcc_cv_as+set}" = set; then : |
20415 | ||
da0f6381 PB |
20416 | else |
20417 | ||
20418 | if test -x "$DEFAULT_ASSEMBLER"; then | |
20419 | gcc_cv_as="$DEFAULT_ASSEMBLER" | |
20420 | elif test -f $gcc_cv_as_gas_srcdir/configure.in \ | |
20421 | && test -f ../gas/Makefile \ | |
20422 | && test x$build = x$host; then | |
20423 | gcc_cv_as=../gas/as-new$build_exeext | |
20424 | elif test -x as$build_exeext; then | |
20425 | # Build using assembler in the current directory. | |
20426 | gcc_cv_as=./as$build_exeext | |
20427 | elif test -x $AS_FOR_TARGET; then | |
20428 | gcc_cv_as="$AS_FOR_TARGET" | |
20429 | else | |
20430 | # Extract the first word of "$AS_FOR_TARGET", so it can be a program name with args. | |
20431 | set dummy $AS_FOR_TARGET; ac_word=$2 | |
5213506e RW |
20432 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
20433 | $as_echo_n "checking for $ac_word... " >&6; } | |
20434 | if test "${ac_cv_path_gcc_cv_as+set}" = set; then : | |
20435 | $as_echo_n "(cached) " >&6 | |
da0f6381 PB |
20436 | else |
20437 | case $gcc_cv_as in | |
20438 | [\\/]* | ?:[\\/]*) | |
20439 | ac_cv_path_gcc_cv_as="$gcc_cv_as" # Let the user override the test with a path. | |
20440 | ;; | |
20441 | *) | |
20442 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
20443 | for as_dir in $PATH | |
20444 | do | |
20445 | IFS=$as_save_IFS | |
20446 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
20447 | for ac_exec_ext in '' $ac_executable_extensions; do |
20448 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
da0f6381 | 20449 | ac_cv_path_gcc_cv_as="$as_dir/$ac_word$ac_exec_ext" |
5213506e | 20450 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
da0f6381 PB |
20451 | break 2 |
20452 | fi | |
20453 | done | |
5213506e RW |
20454 | done |
20455 | IFS=$as_save_IFS | |
da0f6381 PB |
20456 | |
20457 | ;; | |
20458 | esac | |
20459 | fi | |
20460 | gcc_cv_as=$ac_cv_path_gcc_cv_as | |
da0f6381 | 20461 | if test -n "$gcc_cv_as"; then |
5213506e RW |
20462 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as" >&5 |
20463 | $as_echo "$gcc_cv_as" >&6; } | |
da0f6381 | 20464 | else |
5213506e RW |
20465 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
20466 | $as_echo "no" >&6; } | |
da0f6381 PB |
20467 | fi |
20468 | ||
5213506e | 20469 | |
da0f6381 PB |
20470 | fi |
20471 | fi | |
20472 | ||
da0f6381 PB |
20473 | ORIGINAL_AS_FOR_TARGET=$gcc_cv_as |
20474 | ||
20475 | case "$ORIGINAL_AS_FOR_TARGET" in | |
20476 | ./as | ./as$build_exeext) ;; | |
5213506e | 20477 | *) ac_config_files="$ac_config_files as:exec-tool.in" |
da0f6381 PB |
20478 | ;; |
20479 | esac | |
20480 | ||
5213506e RW |
20481 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what assembler to use" >&5 |
20482 | $as_echo_n "checking what assembler to use... " >&6; } | |
da0f6381 PB |
20483 | if test "$gcc_cv_as" = ../gas/as-new$build_exeext; then |
20484 | # Single tree build which includes gas. We want to prefer it | |
20485 | # over whatever linker top-level may have detected, since | |
20486 | # we'll use what we're building after installation anyway. | |
5213506e RW |
20487 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: newly built gas" >&5 |
20488 | $as_echo "newly built gas" >&6; } | |
da0f6381 PB |
20489 | in_tree_gas=yes |
20490 | gcc_cv_as_bfd_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/bfd | |
20491 | for f in $gcc_cv_as_bfd_srcdir/configure \ | |
20492 | $gcc_cv_as_gas_srcdir/configure \ | |
20493 | $gcc_cv_as_gas_srcdir/configure.in \ | |
20494 | $gcc_cv_as_gas_srcdir/Makefile.in ; do | |
20495 | gcc_cv_gas_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f` | |
20496 | if test x$gcc_cv_gas_version != x; then | |
20497 | break | |
20498 | fi | |
20499 | done | |
20500 | gcc_cv_gas_major_version=`expr "$gcc_cv_gas_version" : "VERSION=\([0-9]*\)"` | |
20501 | gcc_cv_gas_minor_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.\([0-9]*\)"` | |
20502 | gcc_cv_gas_patch_version=`expr "$gcc_cv_gas_version" : "VERSION=[0-9]*\.[0-9]*\.\([0-9]*\)"` | |
20503 | case $gcc_cv_gas_patch_version in | |
20504 | "") gcc_cv_gas_patch_version="0" ;; | |
20505 | esac | |
20506 | gcc_cv_gas_vers=`expr \( \( $gcc_cv_gas_major_version \* 1000 \) \ | |
20507 | + $gcc_cv_gas_minor_version \) \* 1000 \ | |
20508 | + $gcc_cv_gas_patch_version` | |
20509 | ||
20510 | in_tree_gas_is_elf=no | |
20511 | if grep 'obj_format = elf' ../gas/Makefile > /dev/null \ | |
20512 | || (grep 'obj_format = multi' ../gas/Makefile \ | |
20513 | && grep 'extra_objects =.* obj-elf' ../gas/Makefile) > /dev/null | |
20514 | then | |
20515 | in_tree_gas_is_elf=yes | |
20516 | fi | |
20517 | else | |
5213506e RW |
20518 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as" >&5 |
20519 | $as_echo "$gcc_cv_as" >&6; } | |
da0f6381 PB |
20520 | in_tree_gas=no |
20521 | fi | |
20522 | ||
20523 | # Identify the linker which will work hand-in-glove with the newly | |
20524 | # built GCC, so that we can examine its features. This is the linker | |
20525 | # which will be driven by the driver program. | |
20526 | # | |
20527 | # If build != host, and we aren't building gas in-tree, we identify a | |
20528 | # build->target linker and hope that it will have the same features | |
20529 | # as the host->target linker we'll be using. | |
20530 | gcc_cv_gld_major_version= | |
20531 | gcc_cv_gld_minor_version= | |
20532 | gcc_cv_ld_gld_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/ld | |
20533 | gcc_cv_ld_bfd_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/bfd | |
20534 | ||
5213506e RW |
20535 | if test "${gcc_cv_ld+set}" = set; then : |
20536 | ||
da0f6381 PB |
20537 | else |
20538 | ||
20539 | if test -x "$DEFAULT_LINKER"; then | |
20540 | gcc_cv_ld="$DEFAULT_LINKER" | |
20541 | elif test -f $gcc_cv_ld_gld_srcdir/configure.in \ | |
20542 | && test -f ../ld/Makefile \ | |
20543 | && test x$build = x$host; then | |
20544 | gcc_cv_ld=../ld/ld-new$build_exeext | |
e8b05380 PB |
20545 | elif test -x collect-ld$build_exeext; then |
20546 | # Build using linker in the current directory. | |
20547 | gcc_cv_ld=./collect-ld$build_exeext | |
20548 | elif test -x $LD_FOR_TARGET; then | |
20549 | gcc_cv_ld="$LD_FOR_TARGET" | |
20550 | else | |
20551 | # Extract the first word of "$LD_FOR_TARGET", so it can be a program name with args. | |
20552 | set dummy $LD_FOR_TARGET; ac_word=$2 | |
5213506e RW |
20553 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
20554 | $as_echo_n "checking for $ac_word... " >&6; } | |
20555 | if test "${ac_cv_path_gcc_cv_ld+set}" = set; then : | |
20556 | $as_echo_n "(cached) " >&6 | |
d739199a | 20557 | else |
e8b05380 | 20558 | case $gcc_cv_ld in |
d739199a | 20559 | [\\/]* | ?:[\\/]*) |
e8b05380 | 20560 | ac_cv_path_gcc_cv_ld="$gcc_cv_ld" # Let the user override the test with a path. |
d739199a DJ |
20561 | ;; |
20562 | *) | |
20563 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
20564 | for as_dir in $PATH | |
20565 | do | |
20566 | IFS=$as_save_IFS | |
20567 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
20568 | for ac_exec_ext in '' $ac_executable_extensions; do |
20569 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
e8b05380 | 20570 | ac_cv_path_gcc_cv_ld="$as_dir/$ac_word$ac_exec_ext" |
5213506e | 20571 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
d739199a DJ |
20572 | break 2 |
20573 | fi | |
20574 | done | |
5213506e RW |
20575 | done |
20576 | IFS=$as_save_IFS | |
d739199a DJ |
20577 | |
20578 | ;; | |
20579 | esac | |
20580 | fi | |
e8b05380 | 20581 | gcc_cv_ld=$ac_cv_path_gcc_cv_ld |
e8b05380 | 20582 | if test -n "$gcc_cv_ld"; then |
5213506e RW |
20583 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld" >&5 |
20584 | $as_echo "$gcc_cv_ld" >&6; } | |
d739199a | 20585 | else |
5213506e RW |
20586 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
20587 | $as_echo "no" >&6; } | |
d739199a DJ |
20588 | fi |
20589 | ||
5213506e | 20590 | |
d739199a | 20591 | fi |
e8b05380 PB |
20592 | fi |
20593 | ||
5938f74d L |
20594 | ORIGINAL_PLUGIN_LD_FOR_TARGET=$gcc_cv_ld |
20595 | PLUGIN_LD=`basename $gcc_cv_ld` | |
20596 | ||
20597 | # Check whether --with-plugin-ld was given. | |
20598 | if test "${with_plugin_ld+set}" = set; then : | |
20599 | withval=$with_plugin_ld; if test x"$withval" != x; then | |
20600 | ORIGINAL_PLUGIN_LD_FOR_TARGET="$withval" | |
20601 | PLUGIN_LD="$withval" | |
20602 | fi | |
20603 | fi | |
20604 | ||
20605 | ||
20606 | ||
20607 | cat >>confdefs.h <<_ACEOF | |
20608 | #define PLUGIN_LD "$PLUGIN_LD" | |
20609 | _ACEOF | |
20610 | ||
20611 | ||
e8b05380 PB |
20612 | ORIGINAL_LD_FOR_TARGET=$gcc_cv_ld |
20613 | ||
be0fe523 PB |
20614 | case "$ORIGINAL_LD_FOR_TARGET" in |
20615 | ./collect-ld | ./collect-ld$build_exeext) ;; | |
5213506e | 20616 | *) ac_config_files="$ac_config_files collect-ld:exec-tool.in" |
be0fe523 PB |
20617 | ;; |
20618 | esac | |
e8b05380 | 20619 | |
5213506e RW |
20620 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what linker to use" >&5 |
20621 | $as_echo_n "checking what linker to use... " >&6; } | |
e8b05380 PB |
20622 | if test "$gcc_cv_ld" = ../ld/ld-new$build_exeext; then |
20623 | # Single tree build which includes ld. We want to prefer it | |
20624 | # over whatever linker top-level may have detected, since | |
20625 | # we'll use what we're building after installation anyway. | |
5213506e RW |
20626 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: newly built ld" >&5 |
20627 | $as_echo "newly built ld" >&6; } | |
e8b05380 PB |
20628 | in_tree_ld=yes |
20629 | in_tree_ld_is_elf=no | |
20630 | if (grep 'EMUL = .*elf' ../ld/Makefile \ | |
20631 | || grep 'EMUL = .*linux' ../ld/Makefile \ | |
20632 | || grep 'EMUL = .*lynx' ../ld/Makefile) > /dev/null; then | |
20633 | in_tree_ld_is_elf=yes | |
20634 | fi | |
20635 | for f in $gcc_cv_ld_bfd_srcdir/configure $gcc_cv_ld_gld_srcdir/configure $gcc_cv_ld_gld_srcdir/configure.in $gcc_cv_ld_gld_srcdir/Makefile.in | |
20636 | do | |
20637 | gcc_cv_gld_version=`sed -n -e 's/^[ ]*\(VERSION=[0-9]*\.[0-9]*.*\)/\1/p' < $f` | |
20638 | if test x$gcc_cv_gld_version != x; then | |
20639 | break | |
20640 | fi | |
20641 | done | |
20642 | gcc_cv_gld_major_version=`expr "$gcc_cv_gld_version" : "VERSION=\([0-9]*\)"` | |
20643 | gcc_cv_gld_minor_version=`expr "$gcc_cv_gld_version" : "VERSION=[0-9]*\.\([0-9]*\)"` | |
20644 | else | |
5213506e RW |
20645 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld" >&5 |
20646 | $as_echo "$gcc_cv_ld" >&6; } | |
e8b05380 PB |
20647 | in_tree_ld=no |
20648 | fi | |
20649 | ||
20650 | # Figure out what nm we will be using. | |
20651 | gcc_cv_binutils_srcdir=`echo $srcdir | sed -e 's,/gcc$,,'`/binutils | |
5213506e RW |
20652 | if test "${gcc_cv_nm+set}" = set; then : |
20653 | ||
e8b05380 PB |
20654 | else |
20655 | ||
20656 | if test -f $gcc_cv_binutils_srcdir/configure.in \ | |
c15b113b DD |
20657 | && test -f ../binutils/Makefile \ |
20658 | && test x$build = x$host; then | |
e8b05380 PB |
20659 | gcc_cv_nm=../binutils/nm-new$build_exeext |
20660 | elif test -x nm$build_exeext; then | |
20661 | gcc_cv_nm=./nm$build_exeext | |
20662 | elif test -x $NM_FOR_TARGET; then | |
20663 | gcc_cv_nm="$NM_FOR_TARGET" | |
20664 | else | |
20665 | # Extract the first word of "$NM_FOR_TARGET", so it can be a program name with args. | |
20666 | set dummy $NM_FOR_TARGET; ac_word=$2 | |
5213506e RW |
20667 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
20668 | $as_echo_n "checking for $ac_word... " >&6; } | |
20669 | if test "${ac_cv_path_gcc_cv_nm+set}" = set; then : | |
20670 | $as_echo_n "(cached) " >&6 | |
d739199a | 20671 | else |
e8b05380 | 20672 | case $gcc_cv_nm in |
d739199a | 20673 | [\\/]* | ?:[\\/]*) |
e8b05380 | 20674 | ac_cv_path_gcc_cv_nm="$gcc_cv_nm" # Let the user override the test with a path. |
d739199a DJ |
20675 | ;; |
20676 | *) | |
20677 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
20678 | for as_dir in $PATH | |
20679 | do | |
20680 | IFS=$as_save_IFS | |
20681 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
20682 | for ac_exec_ext in '' $ac_executable_extensions; do |
20683 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
e8b05380 | 20684 | ac_cv_path_gcc_cv_nm="$as_dir/$ac_word$ac_exec_ext" |
5213506e | 20685 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
d739199a DJ |
20686 | break 2 |
20687 | fi | |
20688 | done | |
5213506e RW |
20689 | done |
20690 | IFS=$as_save_IFS | |
d739199a DJ |
20691 | |
20692 | ;; | |
20693 | esac | |
20694 | fi | |
e8b05380 | 20695 | gcc_cv_nm=$ac_cv_path_gcc_cv_nm |
e8b05380 | 20696 | if test -n "$gcc_cv_nm"; then |
5213506e RW |
20697 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_nm" >&5 |
20698 | $as_echo "$gcc_cv_nm" >&6; } | |
d739199a | 20699 | else |
5213506e RW |
20700 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
20701 | $as_echo "no" >&6; } | |
d739199a DJ |
20702 | fi |
20703 | ||
5213506e | 20704 | |
d739199a | 20705 | fi |
e8b05380 | 20706 | fi |
d739199a | 20707 | |
5213506e RW |
20708 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what nm to use" >&5 |
20709 | $as_echo_n "checking what nm to use... " >&6; } | |
e8b05380 PB |
20710 | if test "$gcc_cv_nm" = ../binutils/nm-new$build_exeext; then |
20711 | # Single tree build which includes binutils. | |
5213506e RW |
20712 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: newly built nm" >&5 |
20713 | $as_echo "newly built nm" >&6; } | |
e8b05380 PB |
20714 | in_tree_nm=yes |
20715 | else | |
5213506e RW |
20716 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_nm" >&5 |
20717 | $as_echo "$gcc_cv_nm" >&6; } | |
e8b05380 PB |
20718 | in_tree_nm=no |
20719 | fi | |
20720 | ||
20721 | ORIGINAL_NM_FOR_TARGET=$gcc_cv_nm | |
20722 | ||
be0fe523 PB |
20723 | case "$ORIGINAL_NM_FOR_TARGET" in |
20724 | ./nm | ./nm$build_exeext) ;; | |
5213506e | 20725 | *) ac_config_files="$ac_config_files nm:exec-tool.in" |
be0fe523 PB |
20726 | ;; |
20727 | esac | |
20728 | ||
e8b05380 PB |
20729 | |
20730 | # Figure out what objdump we will be using. | |
5213506e RW |
20731 | if test "${gcc_cv_objdump+set}" = set; then : |
20732 | ||
e8b05380 PB |
20733 | else |
20734 | ||
20735 | if test -f $gcc_cv_binutils_srcdir/configure.in \ | |
c15b113b DD |
20736 | && test -f ../binutils/Makefile \ |
20737 | && test x$build = x$host; then | |
e8b05380 PB |
20738 | # Single tree build which includes binutils. |
20739 | gcc_cv_objdump=../binutils/objdump$build_exeext | |
20740 | elif test -x objdump$build_exeext; then | |
20741 | gcc_cv_objdump=./objdump$build_exeext | |
20742 | elif test -x $OBJDUMP_FOR_TARGET; then | |
20743 | gcc_cv_objdump="$OBJDUMP_FOR_TARGET" | |
20744 | else | |
20745 | # Extract the first word of "$OBJDUMP_FOR_TARGET", so it can be a program name with args. | |
20746 | set dummy $OBJDUMP_FOR_TARGET; ac_word=$2 | |
5213506e RW |
20747 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
20748 | $as_echo_n "checking for $ac_word... " >&6; } | |
20749 | if test "${ac_cv_path_gcc_cv_objdump+set}" = set; then : | |
20750 | $as_echo_n "(cached) " >&6 | |
9f18db39 | 20751 | else |
e8b05380 | 20752 | case $gcc_cv_objdump in |
9f18db39 | 20753 | [\\/]* | ?:[\\/]*) |
e8b05380 | 20754 | ac_cv_path_gcc_cv_objdump="$gcc_cv_objdump" # Let the user override the test with a path. |
9f18db39 PB |
20755 | ;; |
20756 | *) | |
20757 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
e8b05380 | 20758 | for as_dir in $PATH |
9f18db39 PB |
20759 | do |
20760 | IFS=$as_save_IFS | |
20761 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
20762 | for ac_exec_ext in '' $ac_executable_extensions; do |
20763 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
e8b05380 | 20764 | ac_cv_path_gcc_cv_objdump="$as_dir/$ac_word$ac_exec_ext" |
5213506e | 20765 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
9f18db39 PB |
20766 | break 2 |
20767 | fi | |
20768 | done | |
5213506e RW |
20769 | done |
20770 | IFS=$as_save_IFS | |
779243f7 | 20771 | |
9f18db39 PB |
20772 | ;; |
20773 | esac | |
20774 | fi | |
e8b05380 | 20775 | gcc_cv_objdump=$ac_cv_path_gcc_cv_objdump |
e8b05380 | 20776 | if test -n "$gcc_cv_objdump"; then |
5213506e RW |
20777 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_objdump" >&5 |
20778 | $as_echo "$gcc_cv_objdump" >&6; } | |
9f18db39 | 20779 | else |
5213506e RW |
20780 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
20781 | $as_echo "no" >&6; } | |
9f18db39 PB |
20782 | fi |
20783 | ||
5213506e | 20784 | |
e8b05380 PB |
20785 | fi |
20786 | fi | |
9f18db39 | 20787 | |
5213506e RW |
20788 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what objdump to use" >&5 |
20789 | $as_echo_n "checking what objdump to use... " >&6; } | |
e8b05380 PB |
20790 | if test "$gcc_cv_objdump" = ../binutils/objdump$build_exeext; then |
20791 | # Single tree build which includes binutils. | |
5213506e RW |
20792 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: newly built objdump" >&5 |
20793 | $as_echo "newly built objdump" >&6; } | |
e8b05380 | 20794 | elif test x$gcc_cv_objdump = x; then |
5213506e RW |
20795 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 |
20796 | $as_echo "not found" >&6; } | |
e8b05380 | 20797 | else |
5213506e RW |
20798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_objdump" >&5 |
20799 | $as_echo "$gcc_cv_objdump" >&6; } | |
a2eafc76 | 20800 | fi |
3cae5780 | 20801 | |
6e97481b | 20802 | # Figure out what readelf we will be using. |
5213506e RW |
20803 | if test "${gcc_cv_readelf+set}" = set; then : |
20804 | ||
6e97481b JJ |
20805 | else |
20806 | ||
20807 | if test -f $gcc_cv_binutils_srcdir/configure.in \ | |
20808 | && test -f ../binutils/Makefile \ | |
20809 | && test x$build = x$host; then | |
20810 | # Single tree build which includes binutils. | |
20811 | gcc_cv_readelf=../binutils/readelf$build_exeext | |
20812 | elif test -x readelf$build_exeext; then | |
20813 | gcc_cv_readelf=./readelf$build_exeext | |
20814 | else | |
20815 | # Extract the first word of "readelf", so it can be a program name with args. | |
20816 | set dummy readelf; ac_word=$2 | |
5213506e RW |
20817 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 |
20818 | $as_echo_n "checking for $ac_word... " >&6; } | |
20819 | if test "${ac_cv_path_gcc_cv_readelf+set}" = set; then : | |
20820 | $as_echo_n "(cached) " >&6 | |
6e97481b JJ |
20821 | else |
20822 | case $gcc_cv_readelf in | |
20823 | [\\/]* | ?:[\\/]*) | |
20824 | ac_cv_path_gcc_cv_readelf="$gcc_cv_readelf" # Let the user override the test with a path. | |
20825 | ;; | |
20826 | *) | |
20827 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
20828 | for as_dir in $PATH | |
20829 | do | |
20830 | IFS=$as_save_IFS | |
20831 | test -z "$as_dir" && as_dir=. | |
5213506e RW |
20832 | for ac_exec_ext in '' $ac_executable_extensions; do |
20833 | if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then | |
6e97481b | 20834 | ac_cv_path_gcc_cv_readelf="$as_dir/$ac_word$ac_exec_ext" |
5213506e | 20835 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 |
6e97481b JJ |
20836 | break 2 |
20837 | fi | |
20838 | done | |
5213506e RW |
20839 | done |
20840 | IFS=$as_save_IFS | |
6e97481b JJ |
20841 | |
20842 | ;; | |
20843 | esac | |
20844 | fi | |
20845 | gcc_cv_readelf=$ac_cv_path_gcc_cv_readelf | |
6e97481b | 20846 | if test -n "$gcc_cv_readelf"; then |
5213506e RW |
20847 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_readelf" >&5 |
20848 | $as_echo "$gcc_cv_readelf" >&6; } | |
6e97481b | 20849 | else |
5213506e RW |
20850 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
20851 | $as_echo "no" >&6; } | |
6e97481b JJ |
20852 | fi |
20853 | ||
5213506e | 20854 | |
6e97481b JJ |
20855 | fi |
20856 | fi | |
20857 | ||
5213506e RW |
20858 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking what readelf to use" >&5 |
20859 | $as_echo_n "checking what readelf to use... " >&6; } | |
6e97481b JJ |
20860 | if test "$gcc_cv_readelf" = ../binutils/readelf$build_exeext; then |
20861 | # Single tree build which includes binutils. | |
5213506e RW |
20862 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: newly built readelf" >&5 |
20863 | $as_echo "newly built readelf" >&6; } | |
6e97481b | 20864 | elif test x$gcc_cv_readelf = x; then |
5213506e RW |
20865 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 |
20866 | $as_echo "not found" >&6; } | |
6e97481b | 20867 | else |
5213506e RW |
20868 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_readelf" >&5 |
20869 | $as_echo "$gcc_cv_readelf" >&6; } | |
6e97481b JJ |
20870 | fi |
20871 | ||
981d4858 | 20872 | # Figure out what assembler alignment features are present. |
5213506e RW |
20873 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .balign and .p2align" >&5 |
20874 | $as_echo_n "checking assembler for .balign and .p2align... " >&6; } | |
20875 | if test "${gcc_cv_as_balign_and_p2align+set}" = set; then : | |
20876 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
20877 | else |
20878 | gcc_cv_as_balign_and_p2align=no | |
20879 | if test $in_tree_gas = yes; then | |
20880 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 6 \) \* 1000 + 0` | |
20881 | then gcc_cv_as_balign_and_p2align=yes | |
20882 | fi | |
20883 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 20884 | echo '.balign 4 |
8ada417f | 20885 | .p2align 2' > conftest.s |
ba479fd2 | 20886 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 20887 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
20888 | (eval $ac_try) 2>&5 |
20889 | ac_status=$? | |
5213506e RW |
20890 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
20891 | test $ac_status = 0; }; } | |
8ada417f ZW |
20892 | then |
20893 | gcc_cv_as_balign_and_p2align=yes | |
20894 | else | |
20895 | echo "configure: failed program was" >&5 | |
20896 | cat conftest.s >&5 | |
20897 | fi | |
20898 | rm -f conftest.o conftest.s | |
20899 | fi | |
20900 | fi | |
5213506e RW |
20901 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_balign_and_p2align" >&5 |
20902 | $as_echo "$gcc_cv_as_balign_and_p2align" >&6; } | |
63cf211a | 20903 | if test $gcc_cv_as_balign_and_p2align = yes; then |
ba479fd2 | 20904 | |
5213506e | 20905 | $as_echo "#define HAVE_GAS_BALIGN_AND_P2ALIGN 1" >>confdefs.h |
981d4858 | 20906 | |
ad9c4d9f NN |
20907 | fi |
20908 | ||
5213506e RW |
20909 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .p2align with maximum skip" >&5 |
20910 | $as_echo_n "checking assembler for .p2align with maximum skip... " >&6; } | |
20911 | if test "${gcc_cv_as_max_skip_p2align+set}" = set; then : | |
20912 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
20913 | else |
20914 | gcc_cv_as_max_skip_p2align=no | |
20915 | if test $in_tree_gas = yes; then | |
20916 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 8 \) \* 1000 + 0` | |
20917 | then gcc_cv_as_max_skip_p2align=yes | |
20918 | fi | |
20919 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 20920 | echo '.p2align 4,,7' > conftest.s |
ba479fd2 | 20921 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 20922 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
20923 | (eval $ac_try) 2>&5 |
20924 | ac_status=$? | |
5213506e RW |
20925 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
20926 | test $ac_status = 0; }; } | |
8ada417f ZW |
20927 | then |
20928 | gcc_cv_as_max_skip_p2align=yes | |
20929 | else | |
20930 | echo "configure: failed program was" >&5 | |
20931 | cat conftest.s >&5 | |
20932 | fi | |
20933 | rm -f conftest.o conftest.s | |
20934 | fi | |
ad9c4d9f | 20935 | fi |
5213506e RW |
20936 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_max_skip_p2align" >&5 |
20937 | $as_echo "$gcc_cv_as_max_skip_p2align" >&6; } | |
63cf211a | 20938 | if test $gcc_cv_as_max_skip_p2align = yes; then |
ba479fd2 | 20939 | |
5213506e | 20940 | $as_echo "#define HAVE_GAS_MAX_SKIP_P2ALIGN 1" >>confdefs.h |
9e423e6d | 20941 | |
9e423e6d | 20942 | fi |
ad9c4d9f | 20943 | |
5213506e RW |
20944 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .literal16" >&5 |
20945 | $as_echo_n "checking assembler for .literal16... " >&6; } | |
20946 | if test "${gcc_cv_as_literal16+set}" = set; then : | |
20947 | $as_echo_n "(cached) " >&6 | |
5708d18d MS |
20948 | else |
20949 | gcc_cv_as_literal16=no | |
20950 | if test $in_tree_gas = yes; then | |
20951 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 8 \) \* 1000 + 0` | |
20952 | then gcc_cv_as_literal16=yes | |
20953 | fi | |
20954 | elif test x$gcc_cv_as != x; then | |
20955 | echo '.literal16' > conftest.s | |
20956 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 20957 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
5708d18d MS |
20958 | (eval $ac_try) 2>&5 |
20959 | ac_status=$? | |
5213506e RW |
20960 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
20961 | test $ac_status = 0; }; } | |
5708d18d MS |
20962 | then |
20963 | gcc_cv_as_literal16=yes | |
20964 | else | |
20965 | echo "configure: failed program was" >&5 | |
20966 | cat conftest.s >&5 | |
20967 | fi | |
20968 | rm -f conftest.o conftest.s | |
20969 | fi | |
20970 | fi | |
5213506e RW |
20971 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_literal16" >&5 |
20972 | $as_echo "$gcc_cv_as_literal16" >&6; } | |
5708d18d MS |
20973 | if test $gcc_cv_as_literal16 = yes; then |
20974 | ||
5213506e | 20975 | $as_echo "#define HAVE_GAS_LITERAL16 1" >>confdefs.h |
5708d18d MS |
20976 | |
20977 | fi | |
20978 | ||
5213506e RW |
20979 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for working .subsection -1" >&5 |
20980 | $as_echo_n "checking assembler for working .subsection -1... " >&6; } | |
20981 | if test "${gcc_cv_as_subsection_m1+set}" = set; then : | |
20982 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
20983 | else |
20984 | gcc_cv_as_subsection_m1=no | |
20985 | if test $in_tree_gas = yes; then | |
20986 | if test $in_tree_gas_is_elf = yes \ | |
20987 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 9 \) \* 1000 + 0` | |
20988 | then gcc_cv_as_subsection_m1=yes | |
ad9c4d9f | 20989 | fi |
8ada417f | 20990 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 20991 | echo 'conftest_label1: .word 0 |
d1accaa3 JJ |
20992 | .subsection -1 |
20993 | conftest_label2: .word 0 | |
8ada417f | 20994 | .previous' > conftest.s |
ba479fd2 | 20995 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 20996 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
20997 | (eval $ac_try) 2>&5 |
20998 | ac_status=$? | |
5213506e RW |
20999 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21000 | test $ac_status = 0; }; } | |
8ada417f ZW |
21001 | then |
21002 | if test x$gcc_cv_nm != x; then | |
21003 | $gcc_cv_nm conftest.o | grep conftest_label1 > conftest.nm1 | |
21004 | $gcc_cv_nm conftest.o | grep conftest_label2 | sed -e 's/label2/label1/' > conftest.nm2 | |
21005 | if cmp conftest.nm1 conftest.nm2 > /dev/null 2>&1 | |
21006 | then : | |
21007 | else gcc_cv_as_subsection_m1=yes | |
21008 | fi | |
21009 | rm -f conftest.nm1 conftest.nm2 | |
21010 | fi | |
21011 | else | |
21012 | echo "configure: failed program was" >&5 | |
21013 | cat conftest.s >&5 | |
21014 | fi | |
21015 | rm -f conftest.o conftest.s | |
21016 | fi | |
981d4858 | 21017 | fi |
5213506e RW |
21018 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_subsection_m1" >&5 |
21019 | $as_echo "$gcc_cv_as_subsection_m1" >&6; } | |
63cf211a | 21020 | if test $gcc_cv_as_subsection_m1 = yes; then |
ba479fd2 | 21021 | |
5213506e | 21022 | $as_echo "#define HAVE_GAS_SUBSECTION_ORDERING 1" >>confdefs.h |
981d4858 | 21023 | |
d1accaa3 | 21024 | fi |
ad9c4d9f | 21025 | |
5213506e RW |
21026 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .weak" >&5 |
21027 | $as_echo_n "checking assembler for .weak... " >&6; } | |
21028 | if test "${gcc_cv_as_weak+set}" = set; then : | |
21029 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21030 | else |
21031 | gcc_cv_as_weak=no | |
21032 | if test $in_tree_gas = yes; then | |
21033 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 2 \) \* 1000 + 0` | |
21034 | then gcc_cv_as_weak=yes | |
ad9c4d9f | 21035 | fi |
8ada417f | 21036 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 21037 | echo ' .weak foobar' > conftest.s |
ba479fd2 | 21038 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 21039 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21040 | (eval $ac_try) 2>&5 |
21041 | ac_status=$? | |
5213506e RW |
21042 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21043 | test $ac_status = 0; }; } | |
8ada417f ZW |
21044 | then |
21045 | gcc_cv_as_weak=yes | |
21046 | else | |
21047 | echo "configure: failed program was" >&5 | |
21048 | cat conftest.s >&5 | |
21049 | fi | |
21050 | rm -f conftest.o conftest.s | |
21051 | fi | |
981d4858 | 21052 | fi |
5213506e RW |
21053 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_weak" >&5 |
21054 | $as_echo "$gcc_cv_as_weak" >&6; } | |
63cf211a | 21055 | if test $gcc_cv_as_weak = yes; then |
ba479fd2 | 21056 | |
5213506e | 21057 | $as_echo "#define HAVE_GAS_WEAK 1" >>confdefs.h |
981d4858 | 21058 | |
12822146 | 21059 | fi |
ad9c4d9f | 21060 | |
5213506e RW |
21061 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .weakref" >&5 |
21062 | $as_echo_n "checking assembler for .weakref... " >&6; } | |
21063 | if test "${gcc_cv_as_weakref+set}" = set; then : | |
21064 | $as_echo_n "(cached) " >&6 | |
a0203ca7 AO |
21065 | else |
21066 | gcc_cv_as_weakref=no | |
21067 | if test $in_tree_gas = yes; then | |
21068 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0` | |
21069 | then gcc_cv_as_weakref=yes | |
21070 | fi | |
21071 | elif test x$gcc_cv_as != x; then | |
21072 | echo ' .weakref foobar, barfnot' > conftest.s | |
21073 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21074 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
a0203ca7 AO |
21075 | (eval $ac_try) 2>&5 |
21076 | ac_status=$? | |
5213506e RW |
21077 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21078 | test $ac_status = 0; }; } | |
a0203ca7 AO |
21079 | then |
21080 | gcc_cv_as_weakref=yes | |
21081 | else | |
21082 | echo "configure: failed program was" >&5 | |
21083 | cat conftest.s >&5 | |
21084 | fi | |
21085 | rm -f conftest.o conftest.s | |
21086 | fi | |
21087 | fi | |
5213506e RW |
21088 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_weakref" >&5 |
21089 | $as_echo "$gcc_cv_as_weakref" >&6; } | |
a0203ca7 AO |
21090 | if test $gcc_cv_as_weakref = yes; then |
21091 | ||
5213506e | 21092 | $as_echo "#define HAVE_GAS_WEAKREF 1" >>confdefs.h |
a0203ca7 AO |
21093 | |
21094 | fi | |
21095 | ||
5213506e RW |
21096 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .nsubspa comdat" >&5 |
21097 | $as_echo_n "checking assembler for .nsubspa comdat... " >&6; } | |
21098 | if test "${gcc_cv_as_nsubspa_comdat+set}" = set; then : | |
21099 | $as_echo_n "(cached) " >&6 | |
e41f3691 JDA |
21100 | else |
21101 | gcc_cv_as_nsubspa_comdat=no | |
21102 | if test $in_tree_gas = yes; then | |
21103 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91` | |
21104 | then gcc_cv_as_nsubspa_comdat=yes | |
21105 | fi | |
21106 | elif test x$gcc_cv_as != x; then | |
21107 | echo ' .SPACE $TEXT$ | |
21108 | .NSUBSPA $CODE$,COMDAT' > conftest.s | |
21109 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21110 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
e41f3691 JDA |
21111 | (eval $ac_try) 2>&5 |
21112 | ac_status=$? | |
5213506e RW |
21113 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21114 | test $ac_status = 0; }; } | |
e41f3691 JDA |
21115 | then |
21116 | gcc_cv_as_nsubspa_comdat=yes | |
21117 | else | |
21118 | echo "configure: failed program was" >&5 | |
21119 | cat conftest.s >&5 | |
21120 | fi | |
21121 | rm -f conftest.o conftest.s | |
21122 | fi | |
21123 | fi | |
5213506e RW |
21124 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_nsubspa_comdat" >&5 |
21125 | $as_echo "$gcc_cv_as_nsubspa_comdat" >&6; } | |
e41f3691 JDA |
21126 | if test $gcc_cv_as_nsubspa_comdat = yes; then |
21127 | ||
5213506e | 21128 | $as_echo "#define HAVE_GAS_NSUBSPA_COMDAT 1" >>confdefs.h |
e41f3691 JDA |
21129 | |
21130 | fi | |
21131 | ||
8ada417f ZW |
21132 | # .hidden needs to be supported in both the assembler and the linker, |
21133 | # because GNU LD versions before 2.12.1 have buggy support for STV_HIDDEN. | |
21134 | # This is irritatingly difficult to feature test for; we have to check the | |
21135 | # date string after the version number. If we've got an in-tree | |
21136 | # ld, we don't know its patchlevel version, so we set the baseline at 2.13 | |
21137 | # to be safe. | |
21138 | # The gcc_GAS_CHECK_FEATURE call just sets a cache variable. | |
5213506e RW |
21139 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .hidden" >&5 |
21140 | $as_echo_n "checking assembler for .hidden... " >&6; } | |
21141 | if test "${gcc_cv_as_hidden+set}" = set; then : | |
21142 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21143 | else |
21144 | gcc_cv_as_hidden=no | |
21145 | if test $in_tree_gas = yes; then | |
21146 | if test $in_tree_gas_is_elf = yes \ | |
21147 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 13 \) \* 1000 + 0` | |
21148 | then gcc_cv_as_hidden=yes | |
21149 | fi | |
21150 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 21151 | echo ' .hidden foobar |
8ada417f | 21152 | foobar:' > conftest.s |
ba479fd2 | 21153 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 21154 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21155 | (eval $ac_try) 2>&5 |
21156 | ac_status=$? | |
5213506e RW |
21157 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21158 | test $ac_status = 0; }; } | |
8ada417f ZW |
21159 | then |
21160 | gcc_cv_as_hidden=yes | |
21161 | else | |
21162 | echo "configure: failed program was" >&5 | |
21163 | cat conftest.s >&5 | |
21164 | fi | |
21165 | rm -f conftest.o conftest.s | |
21166 | fi | |
21167 | fi | |
5213506e RW |
21168 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_hidden" >&5 |
21169 | $as_echo "$gcc_cv_as_hidden" >&6; } | |
63cf211a | 21170 | |
ad9c4d9f | 21171 | |
10ca6198 JJ |
21172 | if test $in_tree_ld != yes ; then |
21173 | ld_ver=`$gcc_cv_ld --version 2>/dev/null | sed 1q` | |
21174 | if echo "$ld_ver" | grep GNU > /dev/null; then | |
21175 | ld_vers=`echo $ld_ver | sed -n \ | |
21176 | -e 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*.*\)$,\1,p'` | |
21177 | ld_date=`echo $ld_ver | sed -n 's,^.*\([2-9][0-9][0-9][0-9]\)[-]*\([01][0-9]\)[-]*\([0-3][0-9]\).*$,\1\2\3,p'` | |
21178 | ld_vers_major=`expr "$ld_vers" : '\([0-9]*\)'` | |
21179 | ld_vers_minor=`expr "$ld_vers" : '[0-9]*\.\([0-9]*\)'` | |
21180 | ld_vers_patch=`expr "$ld_vers" : '[0-9]*\.[0-9]*\.\([0-9]*\)'` | |
21181 | fi | |
21182 | fi | |
21183 | ||
5213506e RW |
21184 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker for .hidden support" >&5 |
21185 | $as_echo_n "checking linker for .hidden support... " >&6; } | |
21186 | if test "${gcc_cv_ld_hidden+set}" = set; then : | |
21187 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21188 | else |
21189 | if test $in_tree_ld = yes ; then | |
21190 | gcc_cv_ld_hidden=no | |
21191 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 13 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
21192 | && test $in_tree_ld_is_elf = yes; then | |
21193 | gcc_cv_ld_hidden=yes | |
21194 | fi | |
21195 | else | |
21196 | gcc_cv_ld_hidden=yes | |
8ada417f | 21197 | if echo "$ld_ver" | grep GNU > /dev/null; then |
8ada417f ZW |
21198 | if test 0"$ld_date" -lt 20020404; then |
21199 | if test -n "$ld_date"; then | |
21200 | # If there was date string, but was earlier than 2002-04-04, fail | |
21201 | gcc_cv_ld_hidden=no | |
21202 | elif test -z "$ld_vers"; then | |
21203 | # If there was no date string nor ld version number, something is wrong | |
21204 | gcc_cv_ld_hidden=no | |
21205 | else | |
8ada417f ZW |
21206 | test -z "$ld_vers_patch" && ld_vers_patch=0 |
21207 | if test "$ld_vers_major" -lt 2; then | |
21208 | gcc_cv_ld_hidden=no | |
21209 | elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 12; then | |
21210 | gcc_cv_ld_hidden="no" | |
21211 | elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -eq 12 -a "$ld_vers_patch" -eq 0; then | |
21212 | gcc_cv_ld_hidden=no | |
c72931a6 | 21213 | fi |
8ada417f | 21214 | fi |
789b7de5 | 21215 | fi |
8ada417f | 21216 | else |
28690784 | 21217 | case "${target}" in |
b0fd7d27 | 21218 | hppa64*-*-hpux* | ia64*-*-hpux*) |
28690784 JDA |
21219 | gcc_cv_ld_hidden=yes |
21220 | ;; | |
5e87dc23 RO |
21221 | *-*-solaris2.9* | *-*-solaris2.1[0-9]*) |
21222 | gcc_cv_ld_hidden=yes | |
21223 | ;; | |
28690784 JDA |
21224 | *) |
21225 | gcc_cv_ld_hidden=no | |
21226 | ;; | |
21227 | esac | |
8ada417f ZW |
21228 | fi |
21229 | fi | |
6d07784a | 21230 | fi |
5213506e RW |
21231 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_hidden" >&5 |
21232 | $as_echo "$gcc_cv_ld_hidden" >&6; } | |
8ada417f | 21233 | libgcc_visibility=no |
ad9c4d9f | 21234 | |
232b67d9 | 21235 | |
8e3940b2 | 21236 | if test $gcc_cv_as_hidden = yes && test $gcc_cv_ld_hidden = yes; then |
8ada417f | 21237 | libgcc_visibility=yes |
ba479fd2 | 21238 | |
5213506e | 21239 | $as_echo "#define HAVE_GAS_HIDDEN 1" >>confdefs.h |
ad9c4d9f NN |
21240 | |
21241 | fi | |
21242 | ||
5213506e RW |
21243 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker read-only and read-write section mixing" >&5 |
21244 | $as_echo_n "checking linker read-only and read-write section mixing... " >&6; } | |
e73da78e RO |
21245 | gcc_cv_ld_ro_rw_mix=unknown |
21246 | if test $in_tree_ld = yes ; then | |
21247 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 10 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
21248 | && test $in_tree_ld_is_elf = yes; then | |
21249 | gcc_cv_ld_ro_rw_mix=read-write | |
21250 | fi | |
21251 | elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x -a x$gcc_cv_objdump != x ; then | |
21252 | echo '.section myfoosect, "a"' > conftest1.s | |
21253 | echo '.section myfoosect, "aw"' > conftest2.s | |
21254 | echo '.byte 1' >> conftest2.s | |
21255 | echo '.section myfoosect, "a"' > conftest3.s | |
21256 | echo '.byte 0' >> conftest3.s | |
21257 | if $gcc_cv_as -o conftest1.o conftest1.s > /dev/null 2>&1 \ | |
21258 | && $gcc_cv_as -o conftest2.o conftest2.s > /dev/null 2>&1 \ | |
21259 | && $gcc_cv_as -o conftest3.o conftest3.s > /dev/null 2>&1 \ | |
21260 | && $gcc_cv_ld -shared -o conftest1.so conftest1.o \ | |
21261 | conftest2.o conftest3.o > /dev/null 2>&1; then | |
21262 | gcc_cv_ld_ro_rw_mix=`$gcc_cv_objdump -h conftest1.so \ | |
21263 | | sed -e '/myfoosect/!d' -e N` | |
21264 | if echo "$gcc_cv_ld_ro_rw_mix" | grep CONTENTS > /dev/null; then | |
21265 | if echo "$gcc_cv_ld_ro_rw_mix" | grep READONLY > /dev/null; then | |
21266 | gcc_cv_ld_ro_rw_mix=read-only | |
21267 | else | |
21268 | gcc_cv_ld_ro_rw_mix=read-write | |
21269 | fi | |
21270 | fi | |
21271 | fi | |
21272 | rm -f conftest.* conftest[123].* | |
21273 | fi | |
21274 | if test x$gcc_cv_ld_ro_rw_mix = xread-write; then | |
21275 | ||
5213506e | 21276 | $as_echo "#define HAVE_LD_RO_RW_SECTION_MIXING 1" >>confdefs.h |
e73da78e RO |
21277 | |
21278 | fi | |
5213506e RW |
21279 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_ro_rw_mix" >&5 |
21280 | $as_echo "$gcc_cv_ld_ro_rw_mix" >&6; } | |
e73da78e | 21281 | |
8ada417f | 21282 | # Check if we have .[us]leb128, and support symbol arithmetic with it. |
5213506e RW |
21283 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .sleb128 and .uleb128" >&5 |
21284 | $as_echo_n "checking assembler for .sleb128 and .uleb128... " >&6; } | |
21285 | if test "${gcc_cv_as_leb128+set}" = set; then : | |
21286 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21287 | else |
21288 | gcc_cv_as_leb128=no | |
21289 | if test $in_tree_gas = yes; then | |
21290 | if test $in_tree_gas_is_elf = yes \ | |
21291 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0` | |
21292 | then gcc_cv_as_leb128=yes | |
21293 | fi | |
21294 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 21295 | echo ' .data |
b7460f24 RH |
21296 | .uleb128 L2 - L1 |
21297 | L1: | |
21298 | .uleb128 1280 | |
21299 | .sleb128 -1010 | |
8ada417f | 21300 | L2:' > conftest.s |
ba479fd2 | 21301 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 21302 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21303 | (eval $ac_try) 2>&5 |
21304 | ac_status=$? | |
5213506e RW |
21305 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21306 | test $ac_status = 0; }; } | |
8ada417f ZW |
21307 | then |
21308 | # GAS versions before 2.11 do not support uleb128, | |
21309 | # despite appearing to. | |
21310 | # ??? There exists an elf-specific test that will crash | |
21311 | # the assembler. Perhaps it's better to figure out whether | |
21312 | # arbitrary sections are supported and try the test. | |
bace148a | 21313 | as_ver=`$gcc_cv_as --version 2>/dev/null | sed 1q` |
8ada417f | 21314 | if echo "$as_ver" | grep GNU > /dev/null; then |
ddcd0f6f | 21315 | as_vers=`echo $as_ver | sed -n \ |
115e6e55 | 21316 | -e 's,^.*[ ]\([0-9][0-9]*\.[0-9][0-9]*.*\)$,\1,p'` |
ddcd0f6f BS |
21317 | as_major=`expr "$as_vers" : '\([0-9]*\)'` |
21318 | as_minor=`expr "$as_vers" : '[0-9]*\.\([0-9]*\)'` | |
8ada417f ZW |
21319 | if test $as_major -eq 2 && test $as_minor -lt 11 |
21320 | then : | |
21321 | else gcc_cv_as_leb128=yes | |
21322 | fi | |
21323 | fi | |
21324 | else | |
21325 | echo "configure: failed program was" >&5 | |
21326 | cat conftest.s >&5 | |
21327 | fi | |
21328 | rm -f conftest.o conftest.s | |
21329 | fi | |
b7460f24 | 21330 | fi |
5213506e RW |
21331 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_leb128" >&5 |
21332 | $as_echo "$gcc_cv_as_leb128" >&6; } | |
63cf211a | 21333 | if test $gcc_cv_as_leb128 = yes; then |
ba479fd2 | 21334 | |
5213506e | 21335 | $as_echo "#define HAVE_AS_LEB128 1" >>confdefs.h |
b7460f24 RH |
21336 | |
21337 | fi | |
ad9c4d9f | 21338 | |
d4ea4622 | 21339 | # Check if we have assembler support for unwind directives. |
5213506e RW |
21340 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for cfi directives" >&5 |
21341 | $as_echo_n "checking assembler for cfi directives... " >&6; } | |
21342 | if test "${gcc_cv_as_cfi_directive+set}" = set; then : | |
21343 | $as_echo_n "(cached) " >&6 | |
d4ea4622 RH |
21344 | else |
21345 | gcc_cv_as_cfi_directive=no | |
6e60703f | 21346 | if test x$gcc_cv_as != x; then |
d4ea4622 RH |
21347 | echo ' .text |
21348 | .cfi_startproc | |
21349 | .cfi_offset 0, 0 | |
21350 | .cfi_same_value 1 | |
21351 | .cfi_def_cfa 1, 2 | |
21352 | .cfi_escape 1, 2, 3, 4, 5 | |
21353 | .cfi_endproc' > conftest.s | |
21354 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21355 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
d4ea4622 RH |
21356 | (eval $ac_try) 2>&5 |
21357 | ac_status=$? | |
5213506e RW |
21358 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21359 | test $ac_status = 0; }; } | |
d4ea4622 | 21360 | then |
e73da78e RO |
21361 | case "$target" in |
21362 | *-*-solaris*) | |
21363 | # If the linker used on Solaris (like Sun ld) isn't capable of merging | |
21364 | # read-only and read-write sections, we need to make sure that the | |
21365 | # assembler used emits read-write .eh_frame sections. | |
21366 | if test "x$gcc_cv_ld_ro_rw_mix" != xread-write; then | |
21367 | if test "x$gcc_cv_objdump" != x; then | |
21368 | if $gcc_cv_objdump -h conftest.o 2>/dev/null | \ | |
21369 | sed -e /.eh_frame/!d -e N | grep READONLY > /dev/null; then | |
21370 | gcc_cv_as_cfi_directive=no | |
21371 | else | |
21372 | gcc_cv_as_cfi_directive=yes | |
21373 | fi | |
21374 | else | |
21375 | # no objdump, err on the side of caution | |
21376 | gcc_cv_as_cfi_directive=no | |
21377 | fi | |
21378 | else | |
21379 | gcc_cv_as_cfi_directive=yes | |
21380 | fi | |
21381 | ;; | |
21382 | *-*-*) | |
21383 | gcc_cv_as_cfi_directive=yes | |
21384 | ;; | |
21385 | esac | |
d4ea4622 RH |
21386 | else |
21387 | echo "configure: failed program was" >&5 | |
21388 | cat conftest.s >&5 | |
21389 | fi | |
21390 | rm -f conftest.o conftest.s | |
21391 | fi | |
21392 | fi | |
5213506e RW |
21393 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_cfi_directive" >&5 |
21394 | $as_echo "$gcc_cv_as_cfi_directive" >&6; } | |
d4ea4622 | 21395 | |
6e97481b | 21396 | if test $gcc_cv_as_cfi_directive = yes && test x$gcc_cv_readelf != x; then |
5213506e RW |
21397 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for working cfi advance" >&5 |
21398 | $as_echo_n "checking assembler for working cfi advance... " >&6; } | |
21399 | if test "${gcc_cv_as_cfi_advance_working+set}" = set; then : | |
21400 | $as_echo_n "(cached) " >&6 | |
6e97481b JJ |
21401 | else |
21402 | gcc_cv_as_cfi_advance_working=no | |
21403 | if test x$gcc_cv_as != x; then | |
21404 | echo ' .text | |
21405 | .cfi_startproc | |
21406 | .cfi_adjust_cfa_offset 64 | |
21407 | .skip 512, 0 | |
21408 | .cfi_adjust_cfa_offset 128 | |
21409 | .cfi_endproc' > conftest.s | |
21410 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21411 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
6e97481b JJ |
21412 | (eval $ac_try) 2>&5 |
21413 | ac_status=$? | |
5213506e RW |
21414 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21415 | test $ac_status = 0; }; } | |
6e97481b JJ |
21416 | then |
21417 | ||
21418 | if $gcc_cv_readelf -wf conftest.o 2>/dev/null \ | |
21419 | | grep 'DW_CFA_advance_loc[12]:[ ][ ]*512[ ]' >/dev/null; then | |
21420 | gcc_cv_as_cfi_advance_working=yes | |
21421 | fi | |
21422 | ||
21423 | else | |
21424 | echo "configure: failed program was" >&5 | |
21425 | cat conftest.s >&5 | |
21426 | fi | |
21427 | rm -f conftest.o conftest.s | |
21428 | fi | |
21429 | fi | |
5213506e RW |
21430 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_cfi_advance_working" >&5 |
21431 | $as_echo "$gcc_cv_as_cfi_advance_working" >&6; } | |
6e97481b JJ |
21432 | |
21433 | else | |
66f91112 EB |
21434 | # no readelf, err on the side of caution |
21435 | gcc_cv_as_cfi_advance_working=no | |
6e97481b | 21436 | fi |
d4ea4622 RH |
21437 | |
21438 | cat >>confdefs.h <<_ACEOF | |
6e97481b JJ |
21439 | #define HAVE_GAS_CFI_DIRECTIVE `if test $gcc_cv_as_cfi_directive = yes \ |
21440 | && test $gcc_cv_as_cfi_advance_working = yes; then echo 1; else echo 0; fi` | |
d4ea4622 RH |
21441 | _ACEOF |
21442 | ||
21443 | ||
5213506e RW |
21444 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for cfi personality directive" >&5 |
21445 | $as_echo_n "checking assembler for cfi personality directive... " >&6; } | |
21446 | if test "${gcc_cv_as_cfi_personality_directive+set}" = set; then : | |
21447 | $as_echo_n "(cached) " >&6 | |
058514b3 RH |
21448 | else |
21449 | gcc_cv_as_cfi_personality_directive=no | |
6e60703f | 21450 | if test x$gcc_cv_as != x; then |
058514b3 | 21451 | echo ' .text |
042628f9 | 21452 | .cfi_startproc |
058514b3 RH |
21453 | .cfi_personality 0, symbol |
21454 | .cfi_endproc' > conftest.s | |
21455 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21456 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
058514b3 RH |
21457 | (eval $ac_try) 2>&5 |
21458 | ac_status=$? | |
5213506e RW |
21459 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21460 | test $ac_status = 0; }; } | |
058514b3 RH |
21461 | then |
21462 | gcc_cv_as_cfi_personality_directive=yes | |
21463 | else | |
21464 | echo "configure: failed program was" >&5 | |
21465 | cat conftest.s >&5 | |
21466 | fi | |
21467 | rm -f conftest.o conftest.s | |
21468 | fi | |
21469 | fi | |
5213506e RW |
21470 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_cfi_personality_directive" >&5 |
21471 | $as_echo "$gcc_cv_as_cfi_personality_directive" >&6; } | |
058514b3 RH |
21472 | |
21473 | ||
21474 | cat >>confdefs.h <<_ACEOF | |
21475 | #define HAVE_GAS_CFI_PERSONALITY_DIRECTIVE `if test $gcc_cv_as_cfi_personality_directive = yes; | |
21476 | then echo 1; else echo 0; fi` | |
21477 | _ACEOF | |
21478 | ||
21479 | ||
7d45fb94 JJ |
21480 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for cfi sections directive" >&5 |
21481 | $as_echo_n "checking assembler for cfi sections directive... " >&6; } | |
21482 | if test "${gcc_cv_as_cfi_sections_directive+set}" = set; then : | |
21483 | $as_echo_n "(cached) " >&6 | |
21484 | else | |
21485 | gcc_cv_as_cfi_sections_directive=no | |
21486 | if test x$gcc_cv_as != x; then | |
21487 | echo ' .text | |
21488 | .cfi_sections .debug_frame, .eh_frame | |
21489 | .cfi_startproc | |
21490 | .cfi_endproc' > conftest.s | |
21491 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
21492 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 | |
21493 | (eval $ac_try) 2>&5 | |
21494 | ac_status=$? | |
21495 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
21496 | test $ac_status = 0; }; } | |
21497 | then | |
21498 | gcc_cv_as_cfi_sections_directive=yes | |
21499 | else | |
21500 | echo "configure: failed program was" >&5 | |
21501 | cat conftest.s >&5 | |
21502 | fi | |
21503 | rm -f conftest.o conftest.s | |
21504 | fi | |
21505 | fi | |
21506 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_cfi_sections_directive" >&5 | |
21507 | $as_echo "$gcc_cv_as_cfi_sections_directive" >&6; } | |
21508 | ||
21509 | ||
21510 | cat >>confdefs.h <<_ACEOF | |
21511 | #define HAVE_GAS_CFI_SECTIONS_DIRECTIVE `if test $gcc_cv_as_cfi_sections_directive = yes; | |
21512 | then echo 1; else echo 0; fi` | |
21513 | _ACEOF | |
21514 | ||
21515 | ||
8ada417f ZW |
21516 | # GAS versions up to and including 2.11.0 may mis-optimize |
21517 | # .eh_frame data. | |
5213506e RW |
21518 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for eh_frame optimization" >&5 |
21519 | $as_echo_n "checking assembler for eh_frame optimization... " >&6; } | |
21520 | if test "${gcc_cv_as_eh_frame+set}" = set; then : | |
21521 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21522 | else |
21523 | gcc_cv_as_eh_frame=no | |
21524 | if test $in_tree_gas = yes; then | |
21525 | if test $in_tree_gas_is_elf = yes \ | |
21526 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0` | |
21527 | then gcc_cv_as_eh_frame=yes | |
ad9c4d9f | 21528 | fi |
8ada417f | 21529 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 21530 | echo ' .text |
c64688ae RH |
21531 | .LFB1: |
21532 | .4byte 0 | |
21533 | .L1: | |
21534 | .4byte 0 | |
21535 | .LFE1: | |
21536 | .section .eh_frame,"aw",@progbits | |
21537 | __FRAME_BEGIN__: | |
21538 | .4byte .LECIE1-.LSCIE1 | |
21539 | .LSCIE1: | |
21540 | .4byte 0x0 | |
21541 | .byte 0x1 | |
21542 | .ascii "z\0" | |
21543 | .byte 0x1 | |
21544 | .byte 0x78 | |
21545 | .byte 0x1a | |
21546 | .byte 0x0 | |
21547 | .byte 0x4 | |
21548 | .4byte 1 | |
21549 | .p2align 1 | |
21550 | .LECIE1: | |
21551 | .LSFDE1: | |
21552 | .4byte .LEFDE1-.LASFDE1 | |
21553 | .LASFDE1: | |
21554 | .4byte .LASFDE1-__FRAME_BEGIN__ | |
21555 | .4byte .LFB1 | |
21556 | .4byte .LFE1-.LFB1 | |
21557 | .byte 0x4 | |
21558 | .4byte .LFE1-.LFB1 | |
21559 | .byte 0x4 | |
21560 | .4byte .L1-.LFB1 | |
8ada417f | 21561 | .LEFDE1:' > conftest.s |
ba479fd2 | 21562 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 21563 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21564 | (eval $ac_try) 2>&5 |
21565 | ac_status=$? | |
5213506e RW |
21566 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21567 | test $ac_status = 0; }; } | |
8ada417f ZW |
21568 | then |
21569 | cat > conftest.lit <<EOF | |
c64688ae RH |
21570 | 0000 10000000 00000000 017a0001 781a0004 .........z..x... |
21571 | 0010 01000000 12000000 18000000 00000000 ................ | |
093e61a6 | 21572 | 0020 08000000 04080000 0044 .........D |
01efb963 | 21573 | EOF |
ba479fd2 | 21574 | cat > conftest.big <<EOF |
01efb963 AS |
21575 | 0000 00000010 00000000 017a0001 781a0004 .........z..x... |
21576 | 0010 00000001 00000012 00000018 00000000 ................ | |
093e61a6 | 21577 | 0020 00000008 04000000 0844 .........D |
c64688ae | 21578 | EOF |
8ada417f ZW |
21579 | # If the assembler didn't choke, and we can objdump, |
21580 | # and we got the correct data, then succeed. | |
dbc02e7f AS |
21581 | # The text in the here-document typically retains its unix-style line |
21582 | # endings, while the output of objdump will use host line endings. | |
21583 | # Therefore, use diff -b for the comparisons. | |
8ada417f ZW |
21584 | if test x$gcc_cv_objdump != x \ |
21585 | && $gcc_cv_objdump -s -j .eh_frame conftest.o 2>/dev/null \ | |
21586 | | tail -3 > conftest.got \ | |
dbc02e7f AS |
21587 | && { diff -b conftest.lit conftest.got > /dev/null 2>&1 \ |
21588 | || diff -b conftest.big conftest.got > /dev/null 2>&1; } | |
8ada417f ZW |
21589 | then |
21590 | gcc_cv_as_eh_frame=yes | |
ba479fd2 | 21591 | elif { ac_try='$gcc_cv_as -o conftest.o --traditional-format /dev/null' |
5213506e | 21592 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21593 | (eval $ac_try) 2>&5 |
21594 | ac_status=$? | |
5213506e RW |
21595 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21596 | test $ac_status = 0; }; }; then | |
8ada417f ZW |
21597 | gcc_cv_as_eh_frame=buggy |
21598 | else | |
21599 | # Uh oh, what do we do now? | |
21600 | gcc_cv_as_eh_frame=no | |
21601 | fi | |
21602 | else | |
21603 | echo "configure: failed program was" >&5 | |
21604 | cat conftest.s >&5 | |
21605 | fi | |
21606 | rm -f conftest.o conftest.s | |
21607 | fi | |
c64688ae | 21608 | fi |
5213506e RW |
21609 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_eh_frame" >&5 |
21610 | $as_echo "$gcc_cv_as_eh_frame" >&6; } | |
ad9c4d9f | 21611 | |
6e3f3080 | 21612 | |
63cf211a | 21613 | if test $gcc_cv_as_eh_frame = buggy; then |
ba479fd2 | 21614 | |
5213506e | 21615 | $as_echo "#define USE_AS_TRADITIONAL_FORMAT 1" >>confdefs.h |
ad9c4d9f NN |
21616 | |
21617 | fi | |
21618 | ||
5213506e RW |
21619 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for section merging support" >&5 |
21620 | $as_echo_n "checking assembler for section merging support... " >&6; } | |
21621 | if test "${gcc_cv_as_shf_merge+set}" = set; then : | |
21622 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
21623 | else |
21624 | gcc_cv_as_shf_merge=no | |
21625 | if test $in_tree_gas = yes; then | |
21626 | if test $in_tree_gas_is_elf = yes \ | |
21627 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0` | |
21628 | then gcc_cv_as_shf_merge=yes | |
21629 | fi | |
21630 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 21631 | echo '.section .rodata.str, "aMS", @progbits, 1' > conftest.s |
ba479fd2 | 21632 | if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5' |
5213506e | 21633 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
21634 | (eval $ac_try) 2>&5 |
21635 | ac_status=$? | |
5213506e RW |
21636 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21637 | test $ac_status = 0; }; } | |
8ada417f ZW |
21638 | then |
21639 | gcc_cv_as_shf_merge=yes | |
21640 | else | |
21641 | echo "configure: failed program was" >&5 | |
21642 | cat conftest.s >&5 | |
21643 | fi | |
21644 | rm -f conftest.o conftest.s | |
21645 | fi | |
201556f0 | 21646 | fi |
5213506e RW |
21647 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_shf_merge" >&5 |
21648 | $as_echo "$gcc_cv_as_shf_merge" >&6; } | |
8ada417f | 21649 | |
c18a5b6c | 21650 | if test $gcc_cv_as_shf_merge = no; then |
5213506e RW |
21651 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for section merging support" >&5 |
21652 | $as_echo_n "checking assembler for section merging support... " >&6; } | |
21653 | if test "${gcc_cv_as_shf_merge+set}" = set; then : | |
21654 | $as_echo_n "(cached) " >&6 | |
c18a5b6c MM |
21655 | else |
21656 | gcc_cv_as_shf_merge=no | |
21657 | if test $in_tree_gas = yes; then | |
21658 | if test $in_tree_gas_is_elf = yes \ | |
21659 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0` | |
21660 | then gcc_cv_as_shf_merge=yes | |
21661 | fi | |
21662 | elif test x$gcc_cv_as != x; then | |
21663 | echo '.section .rodata.str, "aMS", %progbits, 1' > conftest.s | |
21664 | if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5' | |
5213506e | 21665 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
c18a5b6c MM |
21666 | (eval $ac_try) 2>&5 |
21667 | ac_status=$? | |
5213506e RW |
21668 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21669 | test $ac_status = 0; }; } | |
c18a5b6c MM |
21670 | then |
21671 | gcc_cv_as_shf_merge=yes | |
21672 | else | |
21673 | echo "configure: failed program was" >&5 | |
21674 | cat conftest.s >&5 | |
21675 | fi | |
21676 | rm -f conftest.o conftest.s | |
21677 | fi | |
21678 | fi | |
5213506e RW |
21679 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_shf_merge" >&5 |
21680 | $as_echo "$gcc_cv_as_shf_merge" >&6; } | |
c18a5b6c MM |
21681 | |
21682 | fi | |
8ad9fb33 | 21683 | |
ba479fd2 | 21684 | cat >>confdefs.h <<_ACEOF |
8ad9fb33 | 21685 | #define HAVE_GAS_SHF_MERGE `if test $gcc_cv_as_shf_merge = yes; then echo 1; else echo 0; fi` |
ba479fd2 | 21686 | _ACEOF |
201556f0 | 21687 | |
201556f0 | 21688 | |
5213506e RW |
21689 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for COMDAT group support" >&5 |
21690 | $as_echo_n "checking assembler for COMDAT group support... " >&6; } | |
21691 | if test "${gcc_cv_as_comdat_group+set}" = set; then : | |
21692 | $as_echo_n "(cached) " >&6 | |
c18a5b6c MM |
21693 | else |
21694 | gcc_cv_as_comdat_group=no | |
21695 | if test $in_tree_gas = yes; then | |
21696 | if test $in_tree_gas_is_elf = yes \ | |
11176d2a | 21697 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0` |
c18a5b6c MM |
21698 | then gcc_cv_as_comdat_group=yes |
21699 | fi | |
21700 | elif test x$gcc_cv_as != x; then | |
21701 | echo '.section .text,"axG",@progbits,.foo,comdat' > conftest.s | |
21702 | if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5' | |
5213506e | 21703 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
c18a5b6c MM |
21704 | (eval $ac_try) 2>&5 |
21705 | ac_status=$? | |
5213506e RW |
21706 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21707 | test $ac_status = 0; }; } | |
c18a5b6c MM |
21708 | then |
21709 | gcc_cv_as_comdat_group=yes | |
21710 | else | |
21711 | echo "configure: failed program was" >&5 | |
21712 | cat conftest.s >&5 | |
21713 | fi | |
21714 | rm -f conftest.o conftest.s | |
21715 | fi | |
21716 | fi | |
5213506e RW |
21717 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_comdat_group" >&5 |
21718 | $as_echo "$gcc_cv_as_comdat_group" >&6; } | |
c18a5b6c MM |
21719 | |
21720 | if test $gcc_cv_as_comdat_group = yes; then | |
21721 | gcc_cv_as_comdat_group_percent=no | |
21722 | else | |
5213506e RW |
21723 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for COMDAT group support" >&5 |
21724 | $as_echo_n "checking assembler for COMDAT group support... " >&6; } | |
21725 | if test "${gcc_cv_as_comdat_group_percent+set}" = set; then : | |
21726 | $as_echo_n "(cached) " >&6 | |
c18a5b6c MM |
21727 | else |
21728 | gcc_cv_as_comdat_group_percent=no | |
21729 | if test $in_tree_gas = yes; then | |
21730 | if test $in_tree_gas_is_elf = yes \ | |
11176d2a | 21731 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0` |
c18a5b6c MM |
21732 | then gcc_cv_as_comdat_group_percent=yes |
21733 | fi | |
21734 | elif test x$gcc_cv_as != x; then | |
21735 | echo '.section .text,"axG",%progbits,.foo,comdat' > conftest.s | |
21736 | if { ac_try='$gcc_cv_as --fatal-warnings -o conftest.o conftest.s >&5' | |
5213506e | 21737 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
c18a5b6c MM |
21738 | (eval $ac_try) 2>&5 |
21739 | ac_status=$? | |
5213506e RW |
21740 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21741 | test $ac_status = 0; }; } | |
c18a5b6c MM |
21742 | then |
21743 | gcc_cv_as_comdat_group_percent=yes | |
21744 | else | |
21745 | echo "configure: failed program was" >&5 | |
21746 | cat conftest.s >&5 | |
21747 | fi | |
21748 | rm -f conftest.o conftest.s | |
21749 | fi | |
21750 | fi | |
5213506e RW |
21751 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_comdat_group_percent" >&5 |
21752 | $as_echo "$gcc_cv_as_comdat_group_percent" >&6; } | |
c18a5b6c MM |
21753 | |
21754 | fi | |
39ba7b7d JB |
21755 | if test $in_tree_ld = yes ; then |
21756 | comdat_group=no | |
21757 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
21758 | && test $in_tree_ld_is_elf = yes; then | |
21759 | comdat_group=yes | |
21760 | fi | |
21761 | elif test x"$ld_vers" != x; then | |
11176d2a JB |
21762 | comdat_group=yes |
21763 | if test 0"$ld_date" -lt 20050308; then | |
21764 | if test -n "$ld_date"; then | |
21765 | # If there was date string, but was earlier than 2005-03-08, fail | |
21766 | comdat_group=no | |
21767 | elif test "$ld_vers_major" -lt 2; then | |
21768 | comdat_group=no | |
21769 | elif test "$ld_vers_major" -eq 2 -a "$ld_vers_minor" -lt 16; then | |
21770 | comdat_group=no | |
21771 | fi | |
21772 | fi | |
1cf0118d RO |
21773 | else |
21774 | # assume linkers other than GNU ld don't support COMDAT group | |
21775 | comdat_group=no | |
21776 | fi | |
21777 | if test $comdat_group = no; then | |
21778 | gcc_cv_as_comdat_group=no | |
21779 | gcc_cv_as_comdat_group_percent=no | |
11176d2a | 21780 | fi |
c18a5b6c MM |
21781 | |
21782 | cat >>confdefs.h <<_ACEOF | |
11176d2a | 21783 | #define HAVE_COMDAT_GROUP `if test $gcc_cv_as_comdat_group = yes || test $gcc_cv_as_comdat_group_percent = yes; then echo 1; else echo 0; fi` |
c18a5b6c MM |
21784 | _ACEOF |
21785 | ||
21786 | ||
5213506e RW |
21787 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for line table discriminator support" >&5 |
21788 | $as_echo_n "checking assembler for line table discriminator support... " >&6; } | |
21789 | if test "${gcc_cv_as_discriminator+set}" = set; then : | |
21790 | $as_echo_n "(cached) " >&6 | |
6c52e687 CC |
21791 | else |
21792 | gcc_cv_as_discriminator=no | |
21793 | if test $in_tree_gas = yes; then | |
21794 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 51` | |
21795 | then gcc_cv_as_discriminator=yes | |
21796 | fi | |
21797 | elif test x$gcc_cv_as != x; then | |
21798 | echo ' .text | |
21799 | .file 1 "conf.c" | |
21800 | .loc 1 1 0 discriminator 1' > conftest.s | |
21801 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 21802 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
6c52e687 CC |
21803 | (eval $ac_try) 2>&5 |
21804 | ac_status=$? | |
5213506e RW |
21805 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
21806 | test $ac_status = 0; }; } | |
6c52e687 CC |
21807 | then |
21808 | gcc_cv_as_discriminator=yes | |
21809 | else | |
21810 | echo "configure: failed program was" >&5 | |
21811 | cat conftest.s >&5 | |
21812 | fi | |
21813 | rm -f conftest.o conftest.s | |
21814 | fi | |
21815 | fi | |
5213506e RW |
21816 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_discriminator" >&5 |
21817 | $as_echo "$gcc_cv_as_discriminator" >&6; } | |
6c52e687 CC |
21818 | if test $gcc_cv_as_discriminator = yes; then |
21819 | ||
5213506e | 21820 | $as_echo "#define HAVE_GAS_DISCRIMINATOR 1" >>confdefs.h |
6c52e687 CC |
21821 | |
21822 | fi | |
21823 | ||
6a7a462c | 21824 | # Thread-local storage - the check is heavily parameterized. |
f996902d RH |
21825 | conftest_s= |
21826 | tls_first_major= | |
21827 | tls_first_minor= | |
9739c90c | 21828 | tls_as_opt= |
f996902d | 21829 | case "$target" in |
6f9b006d RH |
21830 | alpha*-*-*) |
21831 | conftest_s=' | |
21832 | .section ".tdata","awT",@progbits | |
21833 | foo: .long 25 | |
21834 | .text | |
21835 | ldq $27,__tls_get_addr($29) !literal!1 | |
21836 | lda $16,foo($29) !tlsgd!1 | |
21837 | jsr $26,($27),__tls_get_addr !lituse_tlsgd!1 | |
21838 | ldq $27,__tls_get_addr($29) !literal!2 | |
21839 | lda $16,foo($29) !tlsldm!2 | |
21840 | jsr $26,($27),__tls_get_addr !lituse_tlsldm!2 | |
21841 | ldq $1,foo($29) !gotdtprel | |
21842 | ldah $2,foo($29) !dtprelhi | |
21843 | lda $3,foo($2) !dtprello | |
21844 | lda $4,foo($29) !dtprel | |
21845 | ldq $1,foo($29) !gottprel | |
21846 | ldah $2,foo($29) !tprelhi | |
21847 | lda $3,foo($2) !tprello | |
21848 | lda $4,foo($29) !tprel' | |
21849 | tls_first_major=2 | |
21850 | tls_first_minor=13 | |
2f3321ca | 21851 | tls_as_opt=--fatal-warnings |
6f9b006d | 21852 | ;; |
ad9646c7 HPN |
21853 | cris-*-*|crisv32-*-*) |
21854 | conftest_s=' | |
21855 | .section ".tdata","awT",@progbits | |
21856 | x: .long 25 | |
21857 | .text | |
21858 | move.d x:IE,$r10 | |
21859 | nop' | |
21860 | tls_first_major=2 | |
21861 | tls_first_minor=20 | |
21862 | tls_as_opt=--fatal-warnings | |
21863 | ;; | |
e4dd71de AH |
21864 | frv*-*-*) |
21865 | conftest_s=' | |
21866 | .section ".tdata","awT",@progbits | |
21867 | x: .long 25 | |
21868 | .text | |
21869 | call #gettlsoff(x)' | |
21870 | tls_first_major=2 | |
21871 | tls_first_minor=14 | |
21872 | ;; | |
51076f96 RC |
21873 | hppa*-*-linux*) |
21874 | conftest_s=' | |
21875 | t1: .reg %r20 | |
21876 | t2: .reg %r21 | |
21877 | gp: .reg %r19 | |
21878 | .section ".tdata","awT",@progbits | |
21879 | foo: .long 25 | |
21880 | .text | |
21881 | .align 4 | |
21882 | addil LT%foo-$tls_gdidx$,gp | |
21883 | ldo RT%foo-$tls_gdidx$(%r1),%arg0 | |
21884 | b __tls_get_addr | |
21885 | nop | |
21886 | addil LT%foo-$tls_ldidx$,gp | |
21887 | b __tls_get_addr | |
21888 | ldo RT%foo-$tls_ldidx$(%r1),%arg0 | |
21889 | addil LR%foo-$tls_dtpoff$,%ret0 | |
21890 | ldo RR%foo-$tls_dtpoff$(%r1),%t1 | |
21891 | mfctl %cr27,%t1 | |
21892 | addil LT%foo-$tls_ieoff$,gp | |
21893 | ldw RT%foo-$tls_ieoff$(%r1),%t2 | |
21894 | add %t1,%t2,%t3 | |
21895 | mfctl %cr27,%t1 | |
21896 | addil LR%foo-$tls_leoff$,%t1 | |
21897 | ldo RR%foo-$tls_leoff$(%r1),%t2' | |
21898 | tls_first_major=2 | |
21899 | tls_first_minor=15 | |
21900 | tls_as_opt=--fatal-warnings | |
21901 | ;; | |
d3585b76 DJ |
21902 | arm*-*-*) |
21903 | conftest_s=' | |
21904 | .section ".tdata","awT",%progbits | |
21905 | foo: .long 25 | |
21906 | .text | |
21907 | .word foo(gottpoff) | |
21908 | .word foo(tpoff) | |
21909 | .word foo(tlsgd) | |
21910 | .word foo(tlsldm) | |
21911 | .word foo(tlsldo)' | |
21912 | tls_first_major=2 | |
21913 | tls_first_minor=17 | |
21914 | ;; | |
f996902d RH |
21915 | i[34567]86-*-*) |
21916 | conftest_s=' | |
21917 | .section ".tdata","awT",@progbits | |
21918 | foo: .long 25 | |
21919 | .text | |
21920 | movl %gs:0, %eax | |
21921 | leal foo@TLSGD(,%ebx,1), %eax | |
21922 | leal foo@TLSLDM(%ebx), %eax | |
21923 | leal foo@DTPOFF(%eax), %edx | |
21924 | movl foo@GOTTPOFF(%ebx), %eax | |
21925 | subl foo@GOTTPOFF(%ebx), %eax | |
75d38379 JJ |
21926 | addl foo@GOTNTPOFF(%ebx), %eax |
21927 | movl foo@INDNTPOFF, %eax | |
f996902d RH |
21928 | movl $foo@TPOFF, %eax |
21929 | subl $foo@TPOFF, %eax | |
21930 | leal foo@NTPOFF(%ecx), %eax' | |
21931 | tls_first_major=2 | |
75d38379 | 21932 | tls_first_minor=14 |
2f3321ca | 21933 | tls_as_opt=--fatal-warnings |
75d38379 JJ |
21934 | ;; |
21935 | x86_64-*-*) | |
21936 | conftest_s=' | |
21937 | .section ".tdata","awT",@progbits | |
21938 | foo: .long 25 | |
21939 | .text | |
21940 | movq %fs:0, %rax | |
21941 | leaq foo@TLSGD(%rip), %rdi | |
21942 | leaq foo@TLSLD(%rip), %rdi | |
21943 | leaq foo@DTPOFF(%rax), %rdx | |
21944 | movq foo@GOTTPOFF(%rip), %rax | |
21945 | movq $foo@TPOFF, %rax' | |
21946 | tls_first_major=2 | |
21947 | tls_first_minor=14 | |
2f3321ca | 21948 | tls_as_opt=--fatal-warnings |
f996902d | 21949 | ;; |
7b6e506e RH |
21950 | ia64-*-*) |
21951 | conftest_s=' | |
21952 | .section ".tdata","awT",@progbits | |
21953 | foo: data8 25 | |
21954 | .text | |
21955 | addl r16 = @ltoff(@dtpmod(foo#)), gp | |
21956 | addl r17 = @ltoff(@dtprel(foo#)), gp | |
21957 | addl r18 = @ltoff(@tprel(foo#)), gp | |
21958 | addl r19 = @dtprel(foo#), gp | |
21959 | adds r21 = @dtprel(foo#), r13 | |
21960 | movl r23 = @dtprel(foo#) | |
21961 | addl r20 = @tprel(foo#), gp | |
21962 | adds r22 = @tprel(foo#), r13 | |
21963 | movl r24 = @tprel(foo#)' | |
21964 | tls_first_major=2 | |
21965 | tls_first_minor=13 | |
2f3321ca | 21966 | tls_as_opt=--fatal-warnings |
7b6e506e | 21967 | ;; |
69229b81 DJ |
21968 | mips*-*-*) |
21969 | conftest_s=' | |
21970 | .section .tdata,"awT",@progbits | |
21971 | x: | |
21972 | .word 2 | |
21973 | .text | |
21974 | addiu $4, $28, %tlsgd(x) | |
21975 | addiu $4, $28, %tlsldm(x) | |
21976 | lui $4, %dtprel_hi(x) | |
21977 | addiu $4, $4, %dtprel_lo(x) | |
21978 | lw $4, %gottprel(x)($28) | |
21979 | lui $4, %tprel_hi(x) | |
21980 | addiu $4, $4, %tprel_lo(x)' | |
21981 | tls_first_major=2 | |
21982 | tls_first_minor=16 | |
21983 | tls_as_opt='-32 --fatal-warnings' | |
21984 | ;; | |
75df395f MK |
21985 | m68k-*-*) |
21986 | conftest_s=' | |
21987 | .section .tdata,"awT",@progbits | |
21988 | x: | |
21989 | .word 2 | |
21990 | .text | |
21991 | foo: | |
21992 | move.l x@TLSGD(%a5),%a0 | |
21993 | move.l x@TLSLDM(%a5),%a0 | |
21994 | move.l x@TLSLDO(%a5),%a0 | |
21995 | move.l x@TLSIE(%a5),%a0 | |
21996 | move.l x@TLSLE(%a5),%a0' | |
21997 | tls_first_major=2 | |
21998 | tls_first_minor=19 | |
21999 | tls_as_opt='--fatal-warnings' | |
22000 | ;; | |
c4501e62 JJ |
22001 | powerpc-*-*) |
22002 | conftest_s=' | |
22003 | .section ".tdata","awT",@progbits | |
22004 | .align 2 | |
22005 | ld0: .space 4 | |
22006 | ld1: .space 4 | |
22007 | x1: .space 4 | |
22008 | x2: .space 4 | |
22009 | x3: .space 4 | |
22010 | .text | |
22011 | addi 3,31,ld0@got@tlsgd | |
22012 | bl __tls_get_addr | |
22013 | addi 3,31,x1@got@tlsld | |
22014 | bl __tls_get_addr | |
22015 | addi 9,3,x1@dtprel | |
22016 | addis 9,3,x2@dtprel@ha | |
22017 | addi 9,9,x2@dtprel@l | |
22018 | lwz 9,x3@got@tprel(31) | |
22019 | add 9,9,x@tls | |
22020 | addi 9,2,x1@tprel | |
22021 | addis 9,2,x2@tprel@ha | |
22022 | addi 9,9,x2@tprel@l' | |
22023 | tls_first_major=2 | |
22024 | tls_first_minor=14 | |
2f3321ca | 22025 | tls_as_opt="-a32 --fatal-warnings" |
c4501e62 JJ |
22026 | ;; |
22027 | powerpc64-*-*) | |
22028 | conftest_s=' | |
22029 | .section ".tdata","awT",@progbits | |
22030 | .align 3 | |
22031 | ld0: .space 8 | |
22032 | ld1: .space 8 | |
22033 | x1: .space 8 | |
22034 | x2: .space 8 | |
22035 | x3: .space 8 | |
22036 | .text | |
22037 | addi 3,2,ld0@got@tlsgd | |
22038 | bl .__tls_get_addr | |
22039 | nop | |
22040 | addi 3,2,ld1@toc | |
22041 | bl .__tls_get_addr | |
22042 | nop | |
22043 | addi 3,2,x1@got@tlsld | |
22044 | bl .__tls_get_addr | |
22045 | nop | |
22046 | addi 9,3,x1@dtprel | |
22047 | bl .__tls_get_addr | |
22048 | nop | |
22049 | addis 9,3,x2@dtprel@ha | |
22050 | addi 9,9,x2@dtprel@l | |
22051 | bl .__tls_get_addr | |
22052 | nop | |
22053 | ld 9,x3@got@dtprel(2) | |
22054 | add 9,9,3 | |
22055 | bl .__tls_get_addr | |
22056 | nop' | |
22057 | tls_first_major=2 | |
22058 | tls_first_minor=14 | |
2f3321ca | 22059 | tls_as_opt="-a64 --fatal-warnings" |
c4501e62 | 22060 | ;; |
fd3cd001 UW |
22061 | s390-*-*) |
22062 | conftest_s=' | |
22063 | .section ".tdata","awT",@progbits | |
22064 | foo: .long 25 | |
22065 | .text | |
22066 | .long foo@TLSGD | |
22067 | .long foo@TLSLDM | |
22068 | .long foo@DTPOFF | |
22069 | .long foo@NTPOFF | |
22070 | .long foo@GOTNTPOFF | |
22071 | .long foo@INDNTPOFF | |
22072 | l %r1,foo@GOTNTPOFF(%r12) | |
22073 | l %r1,0(%r1):tls_load:foo | |
22074 | bas %r14,0(%r1,%r13):tls_gdcall:foo | |
22075 | bas %r14,0(%r1,%r13):tls_ldcall:foo' | |
22076 | tls_first_major=2 | |
22077 | tls_first_minor=14 | |
2f3321ca | 22078 | tls_as_opt="-m31 --fatal-warnings" |
fd3cd001 UW |
22079 | ;; |
22080 | s390x-*-*) | |
22081 | conftest_s=' | |
22082 | .section ".tdata","awT",@progbits | |
22083 | foo: .long 25 | |
22084 | .text | |
22085 | .quad foo@TLSGD | |
22086 | .quad foo@TLSLDM | |
22087 | .quad foo@DTPOFF | |
22088 | .quad foo@NTPOFF | |
22089 | .quad foo@GOTNTPOFF | |
22090 | lg %r1,foo@GOTNTPOFF(%r12) | |
22091 | larl %r1,foo@INDNTPOFF | |
22092 | brasl %r14,__tls_get_offset@PLT:tls_gdcall:foo | |
22093 | brasl %r14,__tls_get_offset@PLT:tls_ldcall:foo' | |
22094 | tls_first_major=2 | |
22095 | tls_first_minor=14 | |
2f3321ca | 22096 | tls_as_opt="-m64 -Aesame --fatal-warnings" |
fd3cd001 | 22097 | ;; |
9ff13962 KK |
22098 | sh-*-* | sh[34]-*-*) |
22099 | conftest_s=' | |
22100 | .section ".tdata","awT",@progbits | |
22101 | foo: .long 25 | |
22102 | .text | |
22103 | .long foo@TLSGD | |
22104 | .long foo@TLSLDM | |
22105 | .long foo@DTPOFF | |
22106 | .long foo@GOTTPOFF | |
22107 | .long foo@TPOFF' | |
22108 | tls_first_major=2 | |
22109 | tls_first_minor=13 | |
2f3321ca | 22110 | tls_as_opt=--fatal-warnings |
9ff13962 | 22111 | ;; |
5751a10b | 22112 | sparc*-*-*) |
2f3321ca | 22113 | case "$target" in |
7935dc1b EB |
22114 | sparc*-sun-solaris2.[56789]*) |
22115 | # TLS was introduced in the Solaris 9 4/04 release but | |
22116 | # we do not enable it by default on Solaris 9 either. | |
22117 | if test "x$enable_tls" = xyes ; then | |
22118 | on_solaris=yes | |
22119 | else | |
22120 | enable_tls=no; | |
22121 | fi | |
22122 | ;; | |
2f3321ca EB |
22123 | sparc*-sun-solaris2.*) |
22124 | on_solaris=yes | |
22125 | ;; | |
22126 | *) | |
22127 | on_solaris=no | |
22128 | ;; | |
22129 | esac | |
22130 | if test x$on_solaris = xyes && test x$gas_flag = xno; then | |
22131 | conftest_s=' | |
22132 | .section ".tdata",#alloc,#write,#tls | |
22133 | foo: .long 25 | |
22134 | .text | |
22135 | sethi %tgd_hi22(foo), %o0 | |
22136 | add %o0, %tgd_lo10(foo), %o1 | |
22137 | add %l7, %o1, %o0, %tgd_add(foo) | |
22138 | call __tls_get_addr, %tgd_call(foo) | |
22139 | sethi %tldm_hi22(foo), %l1 | |
22140 | add %l1, %tldm_lo10(foo), %l2 | |
22141 | add %l7, %l2, %o0, %tldm_add(foo) | |
22142 | call __tls_get_addr, %tldm_call(foo) | |
22143 | sethi %tldo_hix22(foo), %l3 | |
22144 | xor %l3, %tldo_lox10(foo), %l4 | |
22145 | add %o0, %l4, %l5, %tldo_add(foo) | |
22146 | sethi %tie_hi22(foo), %o3 | |
22147 | add %o3, %tie_lo10(foo), %o3 | |
22148 | ld [%l7 + %o3], %o2, %tie_ld(foo) | |
22149 | add %g7, %o2, %o4, %tie_add(foo) | |
22150 | sethi %tle_hix22(foo), %l1 | |
22151 | xor %l1, %tle_lox10(foo), %o5 | |
22152 | ld [%g7 + %o5], %o1' | |
22153 | tls_first_major=0 | |
22154 | tls_first_minor=0 | |
22155 | else | |
22156 | conftest_s=' | |
5751a10b JJ |
22157 | .section ".tdata","awT",@progbits |
22158 | foo: .long 25 | |
22159 | .text | |
22160 | sethi %tgd_hi22(foo), %o0 | |
22161 | add %o0, %tgd_lo10(foo), %o1 | |
22162 | add %l7, %o1, %o0, %tgd_add(foo) | |
22163 | call __tls_get_addr, %tgd_call(foo) | |
22164 | sethi %tldm_hi22(foo), %l1 | |
22165 | add %l1, %tldm_lo10(foo), %l2 | |
22166 | add %l7, %l2, %o0, %tldm_add(foo) | |
22167 | call __tls_get_addr, %tldm_call(foo) | |
22168 | sethi %tldo_hix22(foo), %l3 | |
22169 | xor %l3, %tldo_lox10(foo), %l4 | |
22170 | add %o0, %l4, %l5, %tldo_add(foo) | |
22171 | sethi %tie_hi22(foo), %o3 | |
22172 | add %o3, %tie_lo10(foo), %o3 | |
22173 | ld [%l7 + %o3], %o2, %tie_ld(foo) | |
22174 | add %g7, %o2, %o4, %tie_add(foo) | |
22175 | sethi %tle_hix22(foo), %l1 | |
22176 | xor %l1, %tle_lox10(foo), %o5 | |
22177 | ld [%g7 + %o5], %o1' | |
22178 | tls_first_major=2 | |
22179 | tls_first_minor=14 | |
2f3321ca EB |
22180 | tls_as_opt="-32 --fatal-warnings" |
22181 | fi | |
5751a10b | 22182 | ;; |
6a7a462c BW |
22183 | xtensa*-*-*) |
22184 | conftest_s=' | |
22185 | .section ".tdata","awT",@progbits | |
22186 | foo: .long 25 | |
22187 | .text | |
22188 | movi a8, foo@TLSFUNC | |
22189 | movi a10, foo@TLSARG | |
22190 | callx8.tls a8, foo@TLSCALL' | |
22191 | tls_first_major=2 | |
22192 | tls_first_minor=19 | |
22193 | ;; | |
f996902d | 22194 | esac |
8dea1cca DD |
22195 | set_have_as_tls=no |
22196 | if test "x$enable_tls" = xno ; then | |
22197 | : # TLS explicitly disabled. | |
22198 | elif test "x$enable_tls" = xyes ; then | |
22199 | set_have_as_tls=yes # TLS explicitly enabled. | |
22200 | elif test -z "$tls_first_major"; then | |
8ada417f ZW |
22201 | : # If we don't have a check, assume no support. |
22202 | else | |
5213506e RW |
22203 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for thread-local storage support" >&5 |
22204 | $as_echo_n "checking assembler for thread-local storage support... " >&6; } | |
22205 | if test "${gcc_cv_as_tls+set}" = set; then : | |
22206 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
22207 | else |
22208 | gcc_cv_as_tls=no | |
22209 | if test $in_tree_gas = yes; then | |
22210 | if test $gcc_cv_gas_vers -ge `expr \( \( $tls_first_major \* 1000 \) + $tls_first_minor \) \* 1000 + 0` | |
22211 | then gcc_cv_as_tls=yes | |
ad9c4d9f | 22212 | fi |
8ada417f | 22213 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 22214 | echo "$conftest_s" > conftest.s |
2f3321ca | 22215 | if { ac_try='$gcc_cv_as $tls_as_opt -o conftest.o conftest.s >&5' |
5213506e | 22216 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22217 | (eval $ac_try) 2>&5 |
22218 | ac_status=$? | |
5213506e RW |
22219 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22220 | test $ac_status = 0; }; } | |
8ada417f ZW |
22221 | then |
22222 | gcc_cv_as_tls=yes | |
22223 | else | |
22224 | echo "configure: failed program was" >&5 | |
22225 | cat conftest.s >&5 | |
22226 | fi | |
22227 | rm -f conftest.o conftest.s | |
f996902d | 22228 | fi |
f996902d | 22229 | fi |
5213506e RW |
22230 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_tls" >&5 |
22231 | $as_echo "$gcc_cv_as_tls" >&6; } | |
63cf211a | 22232 | if test $gcc_cv_as_tls = yes; then |
8dea1cca DD |
22233 | set_have_as_tls=yes |
22234 | fi | |
22235 | fi | |
22236 | if test $set_have_as_tls = yes ; then | |
ba479fd2 | 22237 | |
5213506e | 22238 | $as_echo "#define HAVE_AS_TLS 1" >>confdefs.h |
f996902d | 22239 | |
8ada417f ZW |
22240 | fi |
22241 | ||
22242 | # Target-specific assembler checks. | |
f996902d | 22243 | |
5213506e RW |
22244 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker -Bstatic/-Bdynamic option" >&5 |
22245 | $as_echo_n "checking linker -Bstatic/-Bdynamic option... " >&6; } | |
7e9d8517 L |
22246 | gcc_cv_ld_static_dynamic=no |
22247 | if test $in_tree_ld = yes ; then | |
83f0ccb8 | 22248 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 10 -o "$gcc_cv_gld_major_version" -gt 2; then |
7e9d8517 L |
22249 | gcc_cv_ld_static_dynamic=yes |
22250 | fi | |
22251 | elif test x$gcc_cv_ld != x; then | |
22252 | # Check if linker supports -Bstatic/-Bdynamic option | |
22253 | if $gcc_cv_ld --help 2>/dev/null | grep -- -Bstatic > /dev/null \ | |
22254 | && $gcc_cv_ld --help 2>/dev/null | grep -- -Bdynamic > /dev/null; then | |
22255 | gcc_cv_ld_static_dynamic=yes | |
22256 | fi | |
22257 | fi | |
22258 | if test x"$gcc_cv_ld_static_dynamic" = xyes; then | |
22259 | ||
5213506e | 22260 | $as_echo "#define HAVE_LD_STATIC_DYNAMIC 1" >>confdefs.h |
7e9d8517 L |
22261 | |
22262 | fi | |
5213506e RW |
22263 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_static_dynamic" >&5 |
22264 | $as_echo "$gcc_cv_ld_static_dynamic" >&6; } | |
7e9d8517 | 22265 | |
d594623a | 22266 | if test x"$demangler_in_ld" = xyes; then |
5213506e RW |
22267 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --demangle support" >&5 |
22268 | $as_echo_n "checking linker --demangle support... " >&6; } | |
d594623a L |
22269 | gcc_cv_ld_demangle=no |
22270 | if test $in_tree_ld = yes; then | |
22271 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 14 -o "$gcc_cv_gld_major_version" -gt 2; then \ | |
22272 | gcc_cv_ld_demangle=yes | |
22273 | fi | |
22274 | elif test x$gcc_cv_ld != x -a x"$gnu_ld" = xyes; then | |
22275 | # Check if the GNU linker supports --demangle option | |
22276 | if $gcc_cv_ld --help 2>/dev/null | grep no-demangle > /dev/null; then | |
22277 | gcc_cv_ld_demangle=yes | |
22278 | fi | |
22279 | fi | |
22280 | if test x"$gcc_cv_ld_demangle" = xyes; then | |
22281 | ||
5213506e | 22282 | $as_echo "#define HAVE_LD_DEMANGLE 1" >>confdefs.h |
d594623a L |
22283 | |
22284 | fi | |
5213506e RW |
22285 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_demangle" >&5 |
22286 | $as_echo "$gcc_cv_ld_demangle" >&6; } | |
d594623a L |
22287 | fi |
22288 | ||
3a37b08e RH |
22289 | case "$target" in |
22290 | # All TARGET_ABI_OSF targets. | |
22291 | alpha*-*-osf* | alpha*-*-linux* | alpha*-*-*bsd*) | |
5213506e RW |
22292 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for explicit relocation support" >&5 |
22293 | $as_echo_n "checking assembler for explicit relocation support... " >&6; } | |
22294 | if test "${gcc_cv_as_alpha_explicit_relocs+set}" = set; then : | |
22295 | $as_echo_n "(cached) " >&6 | |
3a37b08e | 22296 | else |
8ada417f ZW |
22297 | gcc_cv_as_alpha_explicit_relocs=no |
22298 | if test $in_tree_gas = yes; then | |
22299 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 12 \) \* 1000 + 0` | |
22300 | then gcc_cv_as_alpha_explicit_relocs=yes | |
ad9c4d9f | 22301 | fi |
8ada417f | 22302 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 22303 | echo ' .set nomacro |
3a37b08e RH |
22304 | .text |
22305 | extbl $3, $2, $3 !lituse_bytoff!1 | |
22306 | ldq $2, a($29) !literal!1 | |
22307 | ldq $4, b($29) !literal!2 | |
22308 | ldq_u $3, 0($2) !lituse_base!1 | |
22309 | ldq $27, f($29) !literal!5 | |
22310 | jsr $26, ($27), f !lituse_jsr!5 | |
22311 | ldah $29, 0($26) !gpdisp!3 | |
22312 | lda $0, c($29) !gprel | |
22313 | ldah $1, d($29) !gprelhigh | |
22314 | lda $1, d($1) !gprellow | |
8ada417f | 22315 | lda $29, 0($29) !gpdisp!3' > conftest.s |
ba479fd2 | 22316 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 22317 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22318 | (eval $ac_try) 2>&5 |
22319 | ac_status=$? | |
5213506e RW |
22320 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22321 | test $ac_status = 0; }; } | |
8ada417f ZW |
22322 | then |
22323 | gcc_cv_as_alpha_explicit_relocs=yes | |
22324 | else | |
22325 | echo "configure: failed program was" >&5 | |
22326 | cat conftest.s >&5 | |
22327 | fi | |
22328 | rm -f conftest.o conftest.s | |
22329 | fi | |
cafe096b | 22330 | fi |
5213506e RW |
22331 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_alpha_explicit_relocs" >&5 |
22332 | $as_echo "$gcc_cv_as_alpha_explicit_relocs" >&6; } | |
63cf211a | 22333 | if test $gcc_cv_as_alpha_explicit_relocs = yes; then |
ba479fd2 | 22334 | |
5213506e | 22335 | $as_echo "#define HAVE_AS_EXPLICIT_RELOCS 1" >>confdefs.h |
3a37b08e | 22336 | |
d006f5eb | 22337 | fi |
5213506e RW |
22338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for jsrdirect relocation support" >&5 |
22339 | $as_echo_n "checking assembler for jsrdirect relocation support... " >&6; } | |
22340 | if test "${gcc_cv_as_alpha_jsrdirect_relocs+set}" = set; then : | |
22341 | $as_echo_n "(cached) " >&6 | |
d006f5eb RH |
22342 | else |
22343 | gcc_cv_as_alpha_jsrdirect_relocs=no | |
22344 | if test $in_tree_gas = yes; then | |
22345 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 90` | |
22346 | then gcc_cv_as_alpha_jsrdirect_relocs=yes | |
22347 | fi | |
22348 | elif test x$gcc_cv_as != x; then | |
22349 | echo ' .set nomacro | |
22350 | .text | |
22351 | ldq $27, a($29) !literal!1 | |
22352 | jsr $26, ($27), a !lituse_jsrdirect!1' > conftest.s | |
22353 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22354 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
d006f5eb RH |
22355 | (eval $ac_try) 2>&5 |
22356 | ac_status=$? | |
5213506e RW |
22357 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22358 | test $ac_status = 0; }; } | |
d006f5eb RH |
22359 | then |
22360 | gcc_cv_as_alpha_jsrdirect_relocs=yes | |
22361 | else | |
22362 | echo "configure: failed program was" >&5 | |
22363 | cat conftest.s >&5 | |
22364 | fi | |
22365 | rm -f conftest.o conftest.s | |
22366 | fi | |
22367 | fi | |
5213506e RW |
22368 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_alpha_jsrdirect_relocs" >&5 |
22369 | $as_echo "$gcc_cv_as_alpha_jsrdirect_relocs" >&6; } | |
d006f5eb RH |
22370 | if test $gcc_cv_as_alpha_jsrdirect_relocs = yes; then |
22371 | ||
5213506e | 22372 | $as_echo "#define HAVE_AS_JSRDIRECT_RELOCS 1" >>confdefs.h |
d006f5eb | 22373 | |
86da66b5 HPN |
22374 | fi |
22375 | ;; | |
22376 | ||
22377 | cris-*-*) | |
5213506e RW |
22378 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for -no-mul-bug-abort option" >&5 |
22379 | $as_echo_n "checking assembler for -no-mul-bug-abort option... " >&6; } | |
22380 | if test "${gcc_cv_as_cris_no_mul_bug+set}" = set; then : | |
22381 | $as_echo_n "(cached) " >&6 | |
86da66b5 HPN |
22382 | else |
22383 | gcc_cv_as_cris_no_mul_bug=no | |
22384 | if test $in_tree_gas = yes; then | |
22385 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91` | |
22386 | then gcc_cv_as_cris_no_mul_bug=yes | |
22387 | fi | |
22388 | elif test x$gcc_cv_as != x; then | |
22389 | echo '.text' > conftest.s | |
22390 | if { ac_try='$gcc_cv_as -no-mul-bug-abort -o conftest.o conftest.s >&5' | |
5213506e | 22391 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
86da66b5 HPN |
22392 | (eval $ac_try) 2>&5 |
22393 | ac_status=$? | |
5213506e RW |
22394 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22395 | test $ac_status = 0; }; } | |
86da66b5 HPN |
22396 | then |
22397 | gcc_cv_as_cris_no_mul_bug=yes | |
22398 | else | |
22399 | echo "configure: failed program was" >&5 | |
22400 | cat conftest.s >&5 | |
22401 | fi | |
22402 | rm -f conftest.o conftest.s | |
22403 | fi | |
22404 | fi | |
5213506e RW |
22405 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_cris_no_mul_bug" >&5 |
22406 | $as_echo "$gcc_cv_as_cris_no_mul_bug" >&6; } | |
86da66b5 HPN |
22407 | if test $gcc_cv_as_cris_no_mul_bug = yes; then |
22408 | ||
5213506e | 22409 | $as_echo "#define HAVE_AS_NO_MUL_BUG_ABORT_OPTION 1" >>confdefs.h |
86da66b5 | 22410 | |
8ada417f | 22411 | fi |
3a37b08e | 22412 | ;; |
8ada417f | 22413 | |
1cb36a98 | 22414 | sparc*-*-*) |
5213506e RW |
22415 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .register" >&5 |
22416 | $as_echo_n "checking assembler for .register... " >&6; } | |
22417 | if test "${gcc_cv_as_sparc_register_op+set}" = set; then : | |
22418 | $as_echo_n "(cached) " >&6 | |
5b68c389 | 22419 | else |
8ada417f ZW |
22420 | gcc_cv_as_sparc_register_op=no |
22421 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22422 | echo '.register %g2, #scratch' > conftest.s |
ba479fd2 | 22423 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 22424 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22425 | (eval $ac_try) 2>&5 |
22426 | ac_status=$? | |
5213506e RW |
22427 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22428 | test $ac_status = 0; }; } | |
8ada417f ZW |
22429 | then |
22430 | gcc_cv_as_sparc_register_op=yes | |
22431 | else | |
22432 | echo "configure: failed program was" >&5 | |
22433 | cat conftest.s >&5 | |
22434 | fi | |
22435 | rm -f conftest.o conftest.s | |
22436 | fi | |
cafe096b | 22437 | fi |
5213506e RW |
22438 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_register_op" >&5 |
22439 | $as_echo "$gcc_cv_as_sparc_register_op" >&6; } | |
63cf211a | 22440 | if test $gcc_cv_as_sparc_register_op = yes; then |
ba479fd2 | 22441 | |
5213506e | 22442 | $as_echo "#define HAVE_AS_REGISTER_PSEUDO_OP 1" >>confdefs.h |
1cb36a98 | 22443 | |
8ada417f | 22444 | fi |
1cb36a98 | 22445 | |
5213506e RW |
22446 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for -relax option" >&5 |
22447 | $as_echo_n "checking assembler for -relax option... " >&6; } | |
22448 | if test "${gcc_cv_as_sparc_relax+set}" = set; then : | |
22449 | $as_echo_n "(cached) " >&6 | |
e95b1e6a | 22450 | else |
8ada417f ZW |
22451 | gcc_cv_as_sparc_relax=no |
22452 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22453 | echo '.text' > conftest.s |
ba479fd2 | 22454 | if { ac_try='$gcc_cv_as -relax -o conftest.o conftest.s >&5' |
5213506e | 22455 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22456 | (eval $ac_try) 2>&5 |
22457 | ac_status=$? | |
5213506e RW |
22458 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22459 | test $ac_status = 0; }; } | |
8ada417f ZW |
22460 | then |
22461 | gcc_cv_as_sparc_relax=yes | |
22462 | else | |
22463 | echo "configure: failed program was" >&5 | |
22464 | cat conftest.s >&5 | |
22465 | fi | |
22466 | rm -f conftest.o conftest.s | |
22467 | fi | |
cafe096b | 22468 | fi |
5213506e RW |
22469 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_relax" >&5 |
22470 | $as_echo "$gcc_cv_as_sparc_relax" >&6; } | |
63cf211a | 22471 | if test $gcc_cv_as_sparc_relax = yes; then |
ba479fd2 | 22472 | |
5213506e | 22473 | $as_echo "#define HAVE_AS_RELAX_OPTION 1" >>confdefs.h |
e95b1e6a | 22474 | |
8ada417f | 22475 | fi |
e95b1e6a | 22476 | |
5213506e RW |
22477 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for unaligned pcrel relocs" >&5 |
22478 | $as_echo_n "checking assembler for unaligned pcrel relocs... " >&6; } | |
22479 | if test "${gcc_cv_as_sparc_ua_pcrel+set}" = set; then : | |
22480 | $as_echo_n "(cached) " >&6 | |
17e9e88c | 22481 | else |
8ada417f ZW |
22482 | gcc_cv_as_sparc_ua_pcrel=no |
22483 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22484 | echo '.text |
8ada417f ZW |
22485 | foo: |
22486 | nop | |
22487 | .data | |
22488 | .align 4 | |
22489 | .byte 0 | |
22490 | .uaword %r_disp32(foo)' > conftest.s | |
ba479fd2 | 22491 | if { ac_try='$gcc_cv_as -K PIC -o conftest.o conftest.s >&5' |
5213506e | 22492 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22493 | (eval $ac_try) 2>&5 |
22494 | ac_status=$? | |
5213506e RW |
22495 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22496 | test $ac_status = 0; }; } | |
8ada417f ZW |
22497 | then |
22498 | if test x$gcc_cv_ld != x \ | |
22499 | && $gcc_cv_ld -o conftest conftest.o -G > /dev/null 2>&1; then | |
22500 | gcc_cv_as_sparc_ua_pcrel=yes | |
22501 | fi | |
22502 | rm -f conftest | |
22503 | else | |
22504 | echo "configure: failed program was" >&5 | |
22505 | cat conftest.s >&5 | |
22506 | fi | |
22507 | rm -f conftest.o conftest.s | |
22508 | fi | |
cafe096b | 22509 | fi |
5213506e RW |
22510 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_ua_pcrel" >&5 |
22511 | $as_echo "$gcc_cv_as_sparc_ua_pcrel" >&6; } | |
63cf211a | 22512 | if test $gcc_cv_as_sparc_ua_pcrel = yes; then |
ba479fd2 | 22513 | |
5213506e | 22514 | $as_echo "#define HAVE_AS_SPARC_UA_PCREL 1" >>confdefs.h |
17e9e88c | 22515 | |
17e9e88c | 22516 | |
5213506e RW |
22517 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for unaligned pcrel relocs against hidden symbols" >&5 |
22518 | $as_echo_n "checking assembler for unaligned pcrel relocs against hidden symbols... " >&6; } | |
22519 | if test "${gcc_cv_as_sparc_ua_pcrel_hidden+set}" = set; then : | |
22520 | $as_echo_n "(cached) " >&6 | |
cf7b8b0d | 22521 | else |
8ada417f ZW |
22522 | gcc_cv_as_sparc_ua_pcrel_hidden=no |
22523 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22524 | echo '.data |
8ada417f ZW |
22525 | .align 4 |
22526 | .byte 0x31 | |
22527 | .uaword %r_disp32(foo) | |
22528 | .byte 0x32, 0x33, 0x34 | |
22529 | .global foo | |
22530 | .hidden foo | |
22531 | foo: | |
22532 | .skip 4' > conftest.s | |
ba479fd2 | 22533 | if { ac_try='$gcc_cv_as -K PIC -o conftest.o conftest.s >&5' |
5213506e | 22534 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22535 | (eval $ac_try) 2>&5 |
22536 | ac_status=$? | |
5213506e RW |
22537 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22538 | test $ac_status = 0; }; } | |
8ada417f ZW |
22539 | then |
22540 | if test x$gcc_cv_ld != x && test x$gcc_cv_objdump != x \ | |
22541 | && $gcc_cv_ld -o conftest conftest.o -G > /dev/null 2>&1 \ | |
22542 | && $gcc_cv_objdump -s -j .data conftest 2> /dev/null \ | |
22543 | | grep ' 31000000 07323334' > /dev/null 2>&1; then | |
22544 | if $gcc_cv_objdump -R conftest 2> /dev/null \ | |
22545 | | grep 'DISP32' > /dev/null 2>&1; then | |
22546 | : | |
22547 | else | |
22548 | gcc_cv_as_sparc_ua_pcrel_hidden=yes | |
cf7b8b0d | 22549 | fi |
8ada417f ZW |
22550 | fi |
22551 | rm -f conftest | |
22552 | else | |
22553 | echo "configure: failed program was" >&5 | |
22554 | cat conftest.s >&5 | |
22555 | fi | |
22556 | rm -f conftest.o conftest.s | |
22557 | fi | |
cafe096b | 22558 | fi |
5213506e RW |
22559 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_ua_pcrel_hidden" >&5 |
22560 | $as_echo "$gcc_cv_as_sparc_ua_pcrel_hidden" >&6; } | |
63cf211a | 22561 | if test $gcc_cv_as_sparc_ua_pcrel_hidden = yes; then |
ba479fd2 | 22562 | |
5213506e | 22563 | $as_echo "#define HAVE_AS_SPARC_UA_PCREL_HIDDEN 1" >>confdefs.h |
cf7b8b0d | 22564 | |
8ada417f | 22565 | fi |
ba479fd2 | 22566 | |
8ada417f | 22567 | fi # unaligned pcrel relocs |
cf7b8b0d | 22568 | |
5213506e RW |
22569 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for offsetable %lo()" >&5 |
22570 | $as_echo_n "checking assembler for offsetable %lo()... " >&6; } | |
22571 | if test "${gcc_cv_as_sparc_offsetable_lo10+set}" = set; then : | |
22572 | $as_echo_n "(cached) " >&6 | |
5b68c389 | 22573 | else |
8ada417f ZW |
22574 | gcc_cv_as_sparc_offsetable_lo10=no |
22575 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22576 | echo '.text |
8ada417f ZW |
22577 | or %g1, %lo(ab) + 12, %g1 |
22578 | or %g1, %lo(ab + 12), %g1' > conftest.s | |
ba479fd2 | 22579 | if { ac_try='$gcc_cv_as -xarch=v9 -o conftest.o conftest.s >&5' |
5213506e | 22580 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22581 | (eval $ac_try) 2>&5 |
22582 | ac_status=$? | |
5213506e RW |
22583 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22584 | test $ac_status = 0; }; } | |
8ada417f ZW |
22585 | then |
22586 | if test x$gcc_cv_objdump != x \ | |
ecb0ccbc | 22587 | && $gcc_cv_objdump -s -j .text conftest.o 2> /dev/null \ |
8ada417f | 22588 | | grep ' 82106000 82106000' > /dev/null 2>&1; then |
1b5c0152 | 22589 | gcc_cv_as_sparc_offsetable_lo10=yes |
8ada417f ZW |
22590 | fi |
22591 | else | |
22592 | echo "configure: failed program was" >&5 | |
22593 | cat conftest.s >&5 | |
22594 | fi | |
22595 | rm -f conftest.o conftest.s | |
22596 | fi | |
cafe096b | 22597 | fi |
5213506e RW |
22598 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_sparc_offsetable_lo10" >&5 |
22599 | $as_echo "$gcc_cv_as_sparc_offsetable_lo10" >&6; } | |
63cf211a | 22600 | if test $gcc_cv_as_sparc_offsetable_lo10 = yes; then |
ba479fd2 | 22601 | |
5213506e | 22602 | $as_echo "#define HAVE_AS_OFFSETABLE_LO10 1" >>confdefs.h |
1cb36a98 | 22603 | |
8ada417f | 22604 | fi |
1cb36a98 RH |
22605 | ;; |
22606 | ||
c307e6dd | 22607 | i[34567]86-*-* | x86_64-*-*) |
f7e413e2 DK |
22608 | case $target_os in |
22609 | cygwin*) | |
22610 | # Full C++ conformance when using a shared libstdc++-v3 requires some | |
22611 | # support from the Cygwin DLL, which in more recent versions exports | |
22612 | # wrappers to aid in interposing and redirecting operators new, delete, | |
22613 | # etc., as per n2800 #17.6.4.6 [replacement.functions]. Check if we | |
22614 | # are configuring for a version of Cygwin that exports the wrappers. | |
22615 | if test x$host = x$target; then | |
22616 | ac_fn_c_check_func "$LINENO" "__wrap__Znaj" "ac_cv_func___wrap__Znaj" | |
22617 | if test "x$ac_cv_func___wrap__Znaj" = x""yes; then : | |
22618 | gcc_ac_cygwin_dll_wrappers=yes | |
22619 | else | |
22620 | gcc_ac_cygwin_dll_wrappers=no | |
22621 | fi | |
22622 | ||
22623 | else | |
22624 | # Can't check presence of libc functions during cross-compile, so | |
22625 | # we just have to assume we're building for an up-to-date target. | |
22626 | gcc_ac_cygwin_dll_wrappers=yes | |
22627 | fi | |
22628 | ||
22629 | cat >>confdefs.h <<_ACEOF | |
22630 | #define USE_CYGWIN_LIBSTDCXX_WRAPPERS `if test $gcc_ac_cygwin_dll_wrappers = yes; then echo 1; else echo 0; fi` | |
22631 | _ACEOF | |
22632 | ||
22633 | esac | |
d38bc601 BF |
22634 | case $target_os in |
22635 | cygwin* | pe | mingw32*) | |
233215fe DK |
22636 | # Recent binutils allows the three-operand form of ".comm" on PE. This |
22637 | # definition is used unconditionally to initialise the default state of | |
22638 | # the target option variable that governs usage of the feature. | |
5213506e RW |
22639 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .comm with alignment" >&5 |
22640 | $as_echo_n "checking assembler for .comm with alignment... " >&6; } | |
22641 | if test "${gcc_cv_as_comm_has_align+set}" = set; then : | |
22642 | $as_echo_n "(cached) " >&6 | |
233215fe DK |
22643 | else |
22644 | gcc_cv_as_comm_has_align=no | |
22645 | if test $in_tree_gas = yes; then | |
22646 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 52` | |
22647 | then gcc_cv_as_comm_has_align=yes | |
22648 | fi | |
22649 | elif test x$gcc_cv_as != x; then | |
22650 | echo '.comm foo,1,32' > conftest.s | |
22651 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22652 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
233215fe DK |
22653 | (eval $ac_try) 2>&5 |
22654 | ac_status=$? | |
5213506e RW |
22655 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22656 | test $ac_status = 0; }; } | |
233215fe DK |
22657 | then |
22658 | gcc_cv_as_comm_has_align=yes | |
22659 | else | |
22660 | echo "configure: failed program was" >&5 | |
22661 | cat conftest.s >&5 | |
22662 | fi | |
22663 | rm -f conftest.o conftest.s | |
22664 | fi | |
22665 | fi | |
5213506e RW |
22666 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_comm_has_align" >&5 |
22667 | $as_echo "$gcc_cv_as_comm_has_align" >&6; } | |
233215fe DK |
22668 | |
22669 | ||
22670 | cat >>confdefs.h <<_ACEOF | |
22671 | #define HAVE_GAS_ALIGNED_COMM `if test $gcc_cv_as_comm_has_align = yes; then echo 1; else echo 0; fi` | |
22672 | _ACEOF | |
22673 | ||
d38bc601 | 22674 | # Used for DWARF 2 in PE |
5213506e RW |
22675 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .secrel32 relocs" >&5 |
22676 | $as_echo_n "checking assembler for .secrel32 relocs... " >&6; } | |
22677 | if test "${gcc_cv_as_ix86_pe_secrel32+set}" = set; then : | |
22678 | $as_echo_n "(cached) " >&6 | |
d38bc601 BF |
22679 | else |
22680 | gcc_cv_as_ix86_pe_secrel32=no | |
22681 | if test $in_tree_gas = yes; then | |
22682 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 15 \) \* 1000 + 91` | |
22683 | then gcc_cv_as_ix86_pe_secrel32=yes | |
22684 | fi | |
22685 | elif test x$gcc_cv_as != x; then | |
22686 | echo '.text | |
22687 | foo: nop | |
22688 | .data | |
22689 | .secrel32 foo' > conftest.s | |
22690 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22691 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
d38bc601 BF |
22692 | (eval $ac_try) 2>&5 |
22693 | ac_status=$? | |
5213506e RW |
22694 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22695 | test $ac_status = 0; }; } | |
d38bc601 BF |
22696 | then |
22697 | if test x$gcc_cv_ld != x \ | |
22698 | && $gcc_cv_ld -o conftest conftest.o > /dev/null 2>&1; then | |
22699 | gcc_cv_as_ix86_pe_secrel32=yes | |
22700 | fi | |
22701 | rm -f conftest | |
22702 | else | |
22703 | echo "configure: failed program was" >&5 | |
22704 | cat conftest.s >&5 | |
22705 | fi | |
22706 | rm -f conftest.o conftest.s | |
22707 | fi | |
22708 | fi | |
5213506e RW |
22709 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_pe_secrel32" >&5 |
22710 | $as_echo "$gcc_cv_as_ix86_pe_secrel32" >&6; } | |
d38bc601 BF |
22711 | if test $gcc_cv_as_ix86_pe_secrel32 = yes; then |
22712 | ||
5213506e | 22713 | $as_echo "#define HAVE_GAS_PE_SECREL32_RELOC 1" >>confdefs.h |
d38bc601 BF |
22714 | |
22715 | fi | |
22716 | ;; | |
22717 | esac | |
22718 | ||
5213506e RW |
22719 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for filds and fists mnemonics" >&5 |
22720 | $as_echo_n "checking assembler for filds and fists mnemonics... " >&6; } | |
22721 | if test "${gcc_cv_as_ix86_filds+set}" = set; then : | |
22722 | $as_echo_n "(cached) " >&6 | |
8ada417f | 22723 | else |
a3a5e3d1 UB |
22724 | gcc_cv_as_ix86_filds=no |
22725 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22726 | echo 'filds mem; fists mem' > conftest.s |
ba479fd2 | 22727 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 22728 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22729 | (eval $ac_try) 2>&5 |
22730 | ac_status=$? | |
5213506e RW |
22731 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22732 | test $ac_status = 0; }; } | |
8ada417f | 22733 | then |
a3a5e3d1 UB |
22734 | gcc_cv_as_ix86_filds=yes |
22735 | else | |
22736 | echo "configure: failed program was" >&5 | |
22737 | cat conftest.s >&5 | |
22738 | fi | |
22739 | rm -f conftest.o conftest.s | |
22740 | fi | |
22741 | fi | |
5213506e RW |
22742 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_filds" >&5 |
22743 | $as_echo "$gcc_cv_as_ix86_filds" >&6; } | |
a3a5e3d1 UB |
22744 | if test $gcc_cv_as_ix86_filds = yes; then |
22745 | ||
5213506e | 22746 | $as_echo "#define HAVE_AS_IX86_FILDS 1" >>confdefs.h |
a3a5e3d1 UB |
22747 | |
22748 | fi | |
22749 | ||
5213506e RW |
22750 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for fildq and fistpq mnemonics" >&5 |
22751 | $as_echo_n "checking assembler for fildq and fistpq mnemonics... " >&6; } | |
22752 | if test "${gcc_cv_as_ix86_fildq+set}" = set; then : | |
22753 | $as_echo_n "(cached) " >&6 | |
a3a5e3d1 UB |
22754 | else |
22755 | gcc_cv_as_ix86_fildq=no | |
22756 | if test x$gcc_cv_as != x; then | |
22757 | echo 'fildq mem; fistpq mem' > conftest.s | |
22758 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22759 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
a3a5e3d1 UB |
22760 | (eval $ac_try) 2>&5 |
22761 | ac_status=$? | |
5213506e RW |
22762 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22763 | test $ac_status = 0; }; } | |
a3a5e3d1 UB |
22764 | then |
22765 | gcc_cv_as_ix86_fildq=yes | |
8ada417f ZW |
22766 | else |
22767 | echo "configure: failed program was" >&5 | |
22768 | cat conftest.s >&5 | |
981d4858 | 22769 | fi |
8ada417f ZW |
22770 | rm -f conftest.o conftest.s |
22771 | fi | |
22772 | fi | |
5213506e RW |
22773 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_fildq" >&5 |
22774 | $as_echo "$gcc_cv_as_ix86_fildq" >&6; } | |
a3a5e3d1 | 22775 | if test $gcc_cv_as_ix86_fildq = yes; then |
ba479fd2 | 22776 | |
5213506e | 22777 | $as_echo "#define HAVE_AS_IX86_FILDQ 1" >>confdefs.h |
ad9c4d9f | 22778 | |
f6f5dff2 RO |
22779 | fi |
22780 | ||
5213506e RW |
22781 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for cmov syntax" >&5 |
22782 | $as_echo_n "checking assembler for cmov syntax... " >&6; } | |
22783 | if test "${gcc_cv_as_ix86_cmov_sun_syntax+set}" = set; then : | |
22784 | $as_echo_n "(cached) " >&6 | |
f6f5dff2 RO |
22785 | else |
22786 | gcc_cv_as_ix86_cmov_sun_syntax=no | |
22787 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 22788 | echo 'cmovl.l %edx, %eax' > conftest.s |
ba479fd2 | 22789 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 22790 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22791 | (eval $ac_try) 2>&5 |
22792 | ac_status=$? | |
5213506e RW |
22793 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22794 | test $ac_status = 0; }; } | |
f6f5dff2 RO |
22795 | then |
22796 | gcc_cv_as_ix86_cmov_sun_syntax=yes | |
22797 | else | |
22798 | echo "configure: failed program was" >&5 | |
22799 | cat conftest.s >&5 | |
22800 | fi | |
22801 | rm -f conftest.o conftest.s | |
22802 | fi | |
22803 | fi | |
5213506e RW |
22804 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_cmov_sun_syntax" >&5 |
22805 | $as_echo "$gcc_cv_as_ix86_cmov_sun_syntax" >&6; } | |
63cf211a | 22806 | if test $gcc_cv_as_ix86_cmov_sun_syntax = yes; then |
ba479fd2 | 22807 | |
5213506e | 22808 | $as_echo "#define HAVE_AS_IX86_CMOV_SUN_SYNTAX 1" >>confdefs.h |
f6f5dff2 | 22809 | |
b6c03bcd RS |
22810 | fi |
22811 | ||
5213506e RW |
22812 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for ffreep mnemonic" >&5 |
22813 | $as_echo_n "checking assembler for ffreep mnemonic... " >&6; } | |
22814 | if test "${gcc_cv_as_ix86_ffreep+set}" = set; then : | |
22815 | $as_echo_n "(cached) " >&6 | |
b6c03bcd RS |
22816 | else |
22817 | gcc_cv_as_ix86_ffreep=no | |
22818 | if test x$gcc_cv_as != x; then | |
22819 | echo 'ffreep %st(1)' > conftest.s | |
22820 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22821 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
b6c03bcd RS |
22822 | (eval $ac_try) 2>&5 |
22823 | ac_status=$? | |
5213506e RW |
22824 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22825 | test $ac_status = 0; }; } | |
b6c03bcd RS |
22826 | then |
22827 | gcc_cv_as_ix86_ffreep=yes | |
22828 | else | |
22829 | echo "configure: failed program was" >&5 | |
22830 | cat conftest.s >&5 | |
22831 | fi | |
22832 | rm -f conftest.o conftest.s | |
22833 | fi | |
22834 | fi | |
5213506e RW |
22835 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_ffreep" >&5 |
22836 | $as_echo "$gcc_cv_as_ix86_ffreep" >&6; } | |
b6c03bcd RS |
22837 | if test $gcc_cv_as_ix86_ffreep = yes; then |
22838 | ||
5213506e | 22839 | $as_echo "#define HAVE_AS_IX86_FFREEP 1" >>confdefs.h |
b6c03bcd | 22840 | |
38ca3765 UB |
22841 | fi |
22842 | ||
5213506e RW |
22843 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for sahf mnemonic" >&5 |
22844 | $as_echo_n "checking assembler for sahf mnemonic... " >&6; } | |
22845 | if test "${gcc_cv_as_ix86_sahf+set}" = set; then : | |
22846 | $as_echo_n "(cached) " >&6 | |
38ca3765 UB |
22847 | else |
22848 | gcc_cv_as_ix86_sahf=no | |
22849 | if test x$gcc_cv_as != x; then | |
22850 | echo 'sahf' > conftest.s | |
22851 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22852 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
38ca3765 UB |
22853 | (eval $ac_try) 2>&5 |
22854 | ac_status=$? | |
5213506e RW |
22855 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22856 | test $ac_status = 0; }; } | |
38ca3765 UB |
22857 | then |
22858 | gcc_cv_as_ix86_sahf=yes | |
22859 | else | |
22860 | echo "configure: failed program was" >&5 | |
22861 | cat conftest.s >&5 | |
22862 | fi | |
22863 | rm -f conftest.o conftest.s | |
22864 | fi | |
22865 | fi | |
5213506e RW |
22866 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_sahf" >&5 |
22867 | $as_echo "$gcc_cv_as_ix86_sahf" >&6; } | |
38ca3765 UB |
22868 | if test $gcc_cv_as_ix86_sahf = yes; then |
22869 | ||
5213506e | 22870 | $as_echo "#define HAVE_AS_IX86_SAHF 1" >>confdefs.h |
38ca3765 | 22871 | |
bad72d7a RH |
22872 | fi |
22873 | ||
22874 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for swap suffix" >&5 | |
22875 | $as_echo_n "checking assembler for swap suffix... " >&6; } | |
22876 | if test "${gcc_cv_as_ix86_swap+set}" = set; then : | |
22877 | $as_echo_n "(cached) " >&6 | |
22878 | else | |
22879 | gcc_cv_as_ix86_swap=no | |
22880 | if test x$gcc_cv_as != x; then | |
22881 | echo 'movl.s %esp, %ebp' > conftest.s | |
22882 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
22883 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 | |
22884 | (eval $ac_try) 2>&5 | |
22885 | ac_status=$? | |
22886 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
22887 | test $ac_status = 0; }; } | |
22888 | then | |
22889 | gcc_cv_as_ix86_swap=yes | |
22890 | else | |
22891 | echo "configure: failed program was" >&5 | |
22892 | cat conftest.s >&5 | |
22893 | fi | |
22894 | rm -f conftest.o conftest.s | |
22895 | fi | |
22896 | fi | |
22897 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_swap" >&5 | |
22898 | $as_echo "$gcc_cv_as_ix86_swap" >&6; } | |
22899 | if test $gcc_cv_as_ix86_swap = yes; then | |
22900 | ||
22901 | $as_echo "#define HAVE_AS_IX86_SWAP 1" >>confdefs.h | |
22902 | ||
68b92f78 RS |
22903 | fi |
22904 | ||
5213506e RW |
22905 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for different section symbol subtraction" >&5 |
22906 | $as_echo_n "checking assembler for different section symbol subtraction... " >&6; } | |
22907 | if test "${gcc_cv_as_ix86_diff_sect_delta+set}" = set; then : | |
22908 | $as_echo_n "(cached) " >&6 | |
68b92f78 RS |
22909 | else |
22910 | gcc_cv_as_ix86_diff_sect_delta=no | |
22911 | if test x$gcc_cv_as != x; then | |
22912 | echo '.section .rodata | |
22913 | .L1: | |
22914 | .long .L2-.L1 | |
22915 | .long .L3-.L1 | |
22916 | .text | |
22917 | .L3: nop | |
22918 | .L2: nop' > conftest.s | |
22919 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 22920 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
68b92f78 RS |
22921 | (eval $ac_try) 2>&5 |
22922 | ac_status=$? | |
5213506e RW |
22923 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22924 | test $ac_status = 0; }; } | |
68b92f78 RS |
22925 | then |
22926 | gcc_cv_as_ix86_diff_sect_delta=yes | |
22927 | else | |
22928 | echo "configure: failed program was" >&5 | |
22929 | cat conftest.s >&5 | |
22930 | fi | |
22931 | rm -f conftest.o conftest.s | |
22932 | fi | |
22933 | fi | |
5213506e RW |
22934 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_diff_sect_delta" >&5 |
22935 | $as_echo "$gcc_cv_as_ix86_diff_sect_delta" >&6; } | |
68b92f78 RS |
22936 | if test $gcc_cv_as_ix86_diff_sect_delta = yes; then |
22937 | ||
5213506e | 22938 | $as_echo "#define HAVE_AS_IX86_DIFF_SECT_DELTA 1" >>confdefs.h |
68b92f78 | 22939 | |
ad9c4d9f NN |
22940 | fi |
22941 | ||
6f3ca281 ZW |
22942 | # This one is used unconditionally by i386.[ch]; it is to be defined |
22943 | # to 1 if the feature is present, 0 otherwise. | |
5213506e RW |
22944 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for GOTOFF in data" >&5 |
22945 | $as_echo_n "checking assembler for GOTOFF in data... " >&6; } | |
22946 | if test "${gcc_cv_as_ix86_gotoff_in_data+set}" = set; then : | |
22947 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
22948 | else |
22949 | gcc_cv_as_ix86_gotoff_in_data=no | |
22950 | if test $in_tree_gas = yes; then | |
22951 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0` | |
22952 | then gcc_cv_as_ix86_gotoff_in_data=yes | |
22953 | fi | |
22954 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 22955 | echo ' .text |
f88c65f7 RH |
22956 | .L0: |
22957 | nop | |
22958 | .data | |
8ada417f | 22959 | .long .L0@GOTOFF' > conftest.s |
ba479fd2 | 22960 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 22961 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
22962 | (eval $ac_try) 2>&5 |
22963 | ac_status=$? | |
5213506e RW |
22964 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
22965 | test $ac_status = 0; }; } | |
8ada417f ZW |
22966 | then |
22967 | gcc_cv_as_ix86_gotoff_in_data=yes | |
22968 | else | |
22969 | echo "configure: failed program was" >&5 | |
22970 | cat conftest.s >&5 | |
f88c65f7 | 22971 | fi |
8ada417f ZW |
22972 | rm -f conftest.o conftest.s |
22973 | fi | |
22974 | fi | |
5213506e RW |
22975 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ix86_gotoff_in_data" >&5 |
22976 | $as_echo "$gcc_cv_as_ix86_gotoff_in_data" >&6; } | |
8ada417f | 22977 | |
6f3ca281 | 22978 | |
ba479fd2 | 22979 | cat >>confdefs.h <<_ACEOF |
6f3ca281 | 22980 | #define HAVE_AS_GOTOFF_IN_DATA `if test $gcc_cv_as_ix86_gotoff_in_data = yes; then echo 1; else echo 0; fi` |
ba479fd2 | 22981 | _ACEOF |
f88c65f7 | 22982 | |
1cb36a98 | 22983 | ;; |
ef1ecf87 RH |
22984 | |
22985 | ia64*-*-*) | |
5213506e RW |
22986 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for ltoffx and ldxmov relocs" >&5 |
22987 | $as_echo_n "checking assembler for ltoffx and ldxmov relocs... " >&6; } | |
22988 | if test "${gcc_cv_as_ia64_ltoffx_ldxmov_relocs+set}" = set; then : | |
22989 | $as_echo_n "(cached) " >&6 | |
ef1ecf87 | 22990 | else |
8ada417f ZW |
22991 | gcc_cv_as_ia64_ltoffx_ldxmov_relocs=no |
22992 | if test $in_tree_gas = yes; then | |
22993 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0` | |
22994 | then gcc_cv_as_ia64_ltoffx_ldxmov_relocs=yes | |
ad9c4d9f | 22995 | fi |
8ada417f | 22996 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 22997 | echo ' .text |
ef1ecf87 RH |
22998 | addl r15 = @ltoffx(x#), gp |
22999 | ;; | |
cfa9ee99 | 23000 | ld8.mov r16 = [r15], x#' > conftest.s |
ba479fd2 | 23001 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 23002 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23003 | (eval $ac_try) 2>&5 |
23004 | ac_status=$? | |
5213506e RW |
23005 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23006 | test $ac_status = 0; }; } | |
8ada417f | 23007 | then |
cfa9ee99 | 23008 | gcc_cv_as_ia64_ltoffx_ldxmov_relocs=yes |
8ada417f ZW |
23009 | else |
23010 | echo "configure: failed program was" >&5 | |
23011 | cat conftest.s >&5 | |
2c4a9cff | 23012 | fi |
8ada417f ZW |
23013 | rm -f conftest.o conftest.s |
23014 | fi | |
23015 | fi | |
5213506e RW |
23016 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ia64_ltoffx_ldxmov_relocs" >&5 |
23017 | $as_echo "$gcc_cv_as_ia64_ltoffx_ldxmov_relocs" >&6; } | |
63cf211a | 23018 | if test $gcc_cv_as_ia64_ltoffx_ldxmov_relocs = yes; then |
ba479fd2 | 23019 | |
5213506e | 23020 | $as_echo "#define HAVE_AS_LTOFFX_LDXMOV_RELOCS 1" >>confdefs.h |
8ada417f | 23021 | |
cfa9ee99 | 23022 | fi |
8ada417f | 23023 | |
2c4a9cff | 23024 | ;; |
8ada417f | 23025 | |
2c4a9cff | 23026 | powerpc*-*-*) |
8ada417f | 23027 | case $target in |
432218ba DE |
23028 | *-*-aix*) conftest_s=' .machine "pwr5" |
23029 | .csect .text[PR] | |
6b37db3c | 23030 | mfcr 3,128';; |
8af4d362 | 23031 | *-*-darwin*) |
5213506e RW |
23032 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .machine directive support" >&5 |
23033 | $as_echo_n "checking assembler for .machine directive support... " >&6; } | |
23034 | if test "${gcc_cv_as_machine_directive+set}" = set; then : | |
23035 | $as_echo_n "(cached) " >&6 | |
8af4d362 PB |
23036 | else |
23037 | gcc_cv_as_machine_directive=no | |
23038 | if test x$gcc_cv_as != x; then | |
23039 | echo ' .machine ppc7400' > conftest.s | |
23040 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23041 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
8af4d362 PB |
23042 | (eval $ac_try) 2>&5 |
23043 | ac_status=$? | |
5213506e RW |
23044 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23045 | test $ac_status = 0; }; } | |
8af4d362 PB |
23046 | then |
23047 | gcc_cv_as_machine_directive=yes | |
23048 | else | |
23049 | echo "configure: failed program was" >&5 | |
23050 | cat conftest.s >&5 | |
23051 | fi | |
23052 | rm -f conftest.o conftest.s | |
23053 | fi | |
23054 | fi | |
5213506e RW |
23055 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_machine_directive" >&5 |
23056 | $as_echo "$gcc_cv_as_machine_directive" >&6; } | |
8af4d362 PB |
23057 | |
23058 | if test x$gcc_cv_as_machine_directive != xyes; then | |
23059 | echo "*** This target requires an assembler supporting \".machine\"" >&2 | |
23060 | echo you can get it from: ftp://gcc.gnu.org/pub/gcc/infrastructure/cctools-528.5.dmg >&2 | |
23061 | test x$build = x$target && exit 1 | |
23062 | fi | |
23063 | conftest_s=' .text | |
6b37db3c | 23064 | mfcr r3,128';; |
4c67db14 | 23065 | *) conftest_s=' .machine power4 |
d2ab3e37 | 23066 | .text |
6b37db3c | 23067 | mfcr 3,128';; |
8ada417f | 23068 | esac |
8ada417f | 23069 | |
5213506e RW |
23070 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for mfcr field support" >&5 |
23071 | $as_echo_n "checking assembler for mfcr field support... " >&6; } | |
23072 | if test "${gcc_cv_as_powerpc_mfcrf+set}" = set; then : | |
23073 | $as_echo_n "(cached) " >&6 | |
2c4a9cff | 23074 | else |
8ada417f ZW |
23075 | gcc_cv_as_powerpc_mfcrf=no |
23076 | if test $in_tree_gas = yes; then | |
23077 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0` | |
23078 | then gcc_cv_as_powerpc_mfcrf=yes | |
2c4a9cff | 23079 | fi |
8ada417f | 23080 | elif test x$gcc_cv_as != x; then |
6e3f3080 | 23081 | echo "$conftest_s" > conftest.s |
ba479fd2 | 23082 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 23083 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23084 | (eval $ac_try) 2>&5 |
23085 | ac_status=$? | |
5213506e RW |
23086 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23087 | test $ac_status = 0; }; } | |
8ada417f ZW |
23088 | then |
23089 | gcc_cv_as_powerpc_mfcrf=yes | |
23090 | else | |
23091 | echo "configure: failed program was" >&5 | |
23092 | cat conftest.s >&5 | |
23093 | fi | |
23094 | rm -f conftest.o conftest.s | |
23095 | fi | |
2c4a9cff | 23096 | fi |
5213506e RW |
23097 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_mfcrf" >&5 |
23098 | $as_echo "$gcc_cv_as_powerpc_mfcrf" >&6; } | |
63cf211a | 23099 | if test $gcc_cv_as_powerpc_mfcrf = yes; then |
ba479fd2 | 23100 | |
5213506e | 23101 | $as_echo "#define HAVE_AS_MFCRF 1" >>confdefs.h |
ef1ecf87 | 23102 | |
8ada417f | 23103 | fi |
432218ba DE |
23104 | |
23105 | case $target in | |
23106 | *-*-aix*) conftest_s=' .machine "pwr5" | |
23107 | .csect .text[PR] | |
23108 | popcntb 3,3';; | |
23109 | *) conftest_s=' .machine power5 | |
23110 | .text | |
23111 | popcntb 3,3';; | |
23112 | esac | |
23113 | ||
5213506e RW |
23114 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for popcntb support" >&5 |
23115 | $as_echo_n "checking assembler for popcntb support... " >&6; } | |
23116 | if test "${gcc_cv_as_powerpc_popcntb+set}" = set; then : | |
23117 | $as_echo_n "(cached) " >&6 | |
432218ba DE |
23118 | else |
23119 | gcc_cv_as_powerpc_popcntb=no | |
23120 | if test $in_tree_gas = yes; then | |
23121 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0` | |
23122 | then gcc_cv_as_powerpc_popcntb=yes | |
23123 | fi | |
23124 | elif test x$gcc_cv_as != x; then | |
23125 | echo "$conftest_s" > conftest.s | |
23126 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23127 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
432218ba DE |
23128 | (eval $ac_try) 2>&5 |
23129 | ac_status=$? | |
5213506e RW |
23130 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23131 | test $ac_status = 0; }; } | |
432218ba DE |
23132 | then |
23133 | gcc_cv_as_powerpc_popcntb=yes | |
23134 | else | |
23135 | echo "configure: failed program was" >&5 | |
23136 | cat conftest.s >&5 | |
23137 | fi | |
23138 | rm -f conftest.o conftest.s | |
23139 | fi | |
23140 | fi | |
5213506e RW |
23141 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_popcntb" >&5 |
23142 | $as_echo "$gcc_cv_as_powerpc_popcntb" >&6; } | |
432218ba DE |
23143 | if test $gcc_cv_as_powerpc_popcntb = yes; then |
23144 | ||
5213506e | 23145 | $as_echo "#define HAVE_AS_POPCNTB 1" >>confdefs.h |
432218ba | 23146 | |
9719f3b7 DE |
23147 | fi |
23148 | ||
23149 | case $target in | |
23150 | *-*-aix*) conftest_s=' .machine "pwr5x" | |
23151 | .csect .text[PR] | |
23152 | frin 1,1';; | |
1e04bfdc | 23153 | *) conftest_s=' .machine power5 |
9719f3b7 DE |
23154 | .text |
23155 | frin 1,1';; | |
23156 | esac | |
23157 | ||
5213506e RW |
23158 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for fp round support" >&5 |
23159 | $as_echo_n "checking assembler for fp round support... " >&6; } | |
23160 | if test "${gcc_cv_as_powerpc_fprnd+set}" = set; then : | |
23161 | $as_echo_n "(cached) " >&6 | |
9719f3b7 DE |
23162 | else |
23163 | gcc_cv_as_powerpc_fprnd=no | |
23164 | if test $in_tree_gas = yes; then | |
23165 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0` | |
23166 | then gcc_cv_as_powerpc_fprnd=yes | |
23167 | fi | |
23168 | elif test x$gcc_cv_as != x; then | |
23169 | echo "$conftest_s" > conftest.s | |
23170 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23171 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
9719f3b7 DE |
23172 | (eval $ac_try) 2>&5 |
23173 | ac_status=$? | |
5213506e RW |
23174 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23175 | test $ac_status = 0; }; } | |
9719f3b7 DE |
23176 | then |
23177 | gcc_cv_as_powerpc_fprnd=yes | |
23178 | else | |
23179 | echo "configure: failed program was" >&5 | |
23180 | cat conftest.s >&5 | |
23181 | fi | |
23182 | rm -f conftest.o conftest.s | |
23183 | fi | |
23184 | fi | |
5213506e RW |
23185 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_fprnd" >&5 |
23186 | $as_echo "$gcc_cv_as_powerpc_fprnd" >&6; } | |
9719f3b7 DE |
23187 | if test $gcc_cv_as_powerpc_fprnd = yes; then |
23188 | ||
5213506e | 23189 | $as_echo "#define HAVE_AS_FPRND 1" >>confdefs.h |
9719f3b7 | 23190 | |
44cd321e PS |
23191 | fi |
23192 | ||
23193 | case $target in | |
23194 | *-*-aix*) conftest_s=' .machine "pwr6" | |
23195 | .csect .text[PR] | |
23196 | mffgpr 1,3';; | |
23197 | *) conftest_s=' .machine power6 | |
23198 | .text | |
23199 | mffgpr 1,3';; | |
23200 | esac | |
23201 | ||
5213506e RW |
23202 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for move fp gpr support" >&5 |
23203 | $as_echo_n "checking assembler for move fp gpr support... " >&6; } | |
23204 | if test "${gcc_cv_as_powerpc_mfpgpr+set}" = set; then : | |
23205 | $as_echo_n "(cached) " >&6 | |
44cd321e PS |
23206 | else |
23207 | gcc_cv_as_powerpc_mfpgpr=no | |
23208 | if test $in_tree_gas = yes; then | |
cacf1ca8 | 23209 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` |
44cd321e PS |
23210 | then gcc_cv_as_powerpc_mfpgpr=yes |
23211 | fi | |
23212 | elif test x$gcc_cv_as != x; then | |
23213 | echo "$conftest_s" > conftest.s | |
23214 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23215 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
44cd321e PS |
23216 | (eval $ac_try) 2>&5 |
23217 | ac_status=$? | |
5213506e RW |
23218 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23219 | test $ac_status = 0; }; } | |
44cd321e PS |
23220 | then |
23221 | gcc_cv_as_powerpc_mfpgpr=yes | |
23222 | else | |
23223 | echo "configure: failed program was" >&5 | |
23224 | cat conftest.s >&5 | |
23225 | fi | |
23226 | rm -f conftest.o conftest.s | |
23227 | fi | |
23228 | fi | |
5213506e RW |
23229 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_mfpgpr" >&5 |
23230 | $as_echo "$gcc_cv_as_powerpc_mfpgpr" >&6; } | |
44cd321e PS |
23231 | if test $gcc_cv_as_powerpc_mfpgpr = yes; then |
23232 | ||
5213506e | 23233 | $as_echo "#define HAVE_AS_MFPGPR 1" >>confdefs.h |
44cd321e | 23234 | |
432218ba DE |
23235 | fi |
23236 | ||
7f970b70 AM |
23237 | case $target in |
23238 | *-*-aix*) conftest_s=' .csect .text[PR] | |
23239 | LCF..0: | |
23240 | addis 11,30,_GLOBAL_OFFSET_TABLE_-LCF..0@ha';; | |
23241 | *-*-darwin*) | |
23242 | conftest_s=' .text | |
23243 | LCF0: | |
23244 | addis r11,r30,_GLOBAL_OFFSET_TABLE_-LCF0@ha';; | |
23245 | *) conftest_s=' .text | |
23246 | .LCF0: | |
23247 | addis 11,30,_GLOBAL_OFFSET_TABLE_-.LCF0@ha';; | |
23248 | esac | |
23249 | ||
5213506e RW |
23250 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for rel16 relocs" >&5 |
23251 | $as_echo_n "checking assembler for rel16 relocs... " >&6; } | |
23252 | if test "${gcc_cv_as_powerpc_rel16+set}" = set; then : | |
23253 | $as_echo_n "(cached) " >&6 | |
695d8830 AS |
23254 | else |
23255 | gcc_cv_as_powerpc_rel16=no | |
23256 | if test $in_tree_gas = yes; then | |
23257 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 17 \) \* 1000 + 0` | |
23258 | then gcc_cv_as_powerpc_rel16=yes | |
23259 | fi | |
23260 | elif test x$gcc_cv_as != x; then | |
23261 | echo "$conftest_s" > conftest.s | |
23262 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23263 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
695d8830 AS |
23264 | (eval $ac_try) 2>&5 |
23265 | ac_status=$? | |
5213506e RW |
23266 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23267 | test $ac_status = 0; }; } | |
695d8830 AS |
23268 | then |
23269 | gcc_cv_as_powerpc_rel16=yes | |
23270 | else | |
23271 | echo "configure: failed program was" >&5 | |
23272 | cat conftest.s >&5 | |
23273 | fi | |
23274 | rm -f conftest.o conftest.s | |
23275 | fi | |
23276 | fi | |
5213506e RW |
23277 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_rel16" >&5 |
23278 | $as_echo "$gcc_cv_as_powerpc_rel16" >&6; } | |
695d8830 AS |
23279 | if test $gcc_cv_as_powerpc_rel16 = yes; then |
23280 | ||
5213506e | 23281 | $as_echo "#define HAVE_AS_REL16 1" >>confdefs.h |
695d8830 AS |
23282 | |
23283 | fi | |
23284 | ||
b639c3c2 JJ |
23285 | case $target in |
23286 | *-*-aix*) conftest_s=' .machine "pwr6" | |
23287 | .csect .text[PR] | |
23288 | cmpb 3,4,5';; | |
23289 | *) conftest_s=' .machine power6 | |
23290 | .text | |
23291 | cmpb 3,4,5';; | |
23292 | esac | |
23293 | ||
5213506e RW |
23294 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for compare bytes support" >&5 |
23295 | $as_echo_n "checking assembler for compare bytes support... " >&6; } | |
23296 | if test "${gcc_cv_as_powerpc_cmpb+set}" = set; then : | |
23297 | $as_echo_n "(cached) " >&6 | |
b639c3c2 JJ |
23298 | else |
23299 | gcc_cv_as_powerpc_cmpb=no | |
23300 | if test $in_tree_gas = yes; then | |
cacf1ca8 | 23301 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` |
b639c3c2 JJ |
23302 | then gcc_cv_as_powerpc_cmpb=yes |
23303 | fi | |
23304 | elif test x$gcc_cv_as != x; then | |
23305 | echo "$conftest_s" > conftest.s | |
23306 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23307 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
b639c3c2 JJ |
23308 | (eval $ac_try) 2>&5 |
23309 | ac_status=$? | |
5213506e RW |
23310 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23311 | test $ac_status = 0; }; } | |
b639c3c2 JJ |
23312 | then |
23313 | gcc_cv_as_powerpc_cmpb=yes | |
23314 | else | |
23315 | echo "configure: failed program was" >&5 | |
23316 | cat conftest.s >&5 | |
23317 | fi | |
23318 | rm -f conftest.o conftest.s | |
23319 | fi | |
23320 | fi | |
5213506e RW |
23321 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_cmpb" >&5 |
23322 | $as_echo "$gcc_cv_as_powerpc_cmpb" >&6; } | |
b639c3c2 JJ |
23323 | if test $gcc_cv_as_powerpc_cmpb = yes; then |
23324 | ||
5213506e | 23325 | $as_echo "#define HAVE_AS_CMPB 1" >>confdefs.h |
b639c3c2 JJ |
23326 | |
23327 | fi | |
23328 | ||
23329 | case $target in | |
23330 | *-*-aix*) conftest_s=' .machine "pwr6" | |
23331 | .csect .text[PR] | |
0d74c0ee | 23332 | dadd 1,2,3';; |
b639c3c2 JJ |
23333 | *) conftest_s=' .machine power6 |
23334 | .text | |
0d74c0ee | 23335 | dadd 1,2,3';; |
b639c3c2 JJ |
23336 | esac |
23337 | ||
5213506e RW |
23338 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for decimal float support" >&5 |
23339 | $as_echo_n "checking assembler for decimal float support... " >&6; } | |
23340 | if test "${gcc_cv_as_powerpc_dfp+set}" = set; then : | |
23341 | $as_echo_n "(cached) " >&6 | |
b639c3c2 JJ |
23342 | else |
23343 | gcc_cv_as_powerpc_dfp=no | |
23344 | if test $in_tree_gas = yes; then | |
cacf1ca8 | 23345 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` |
b639c3c2 JJ |
23346 | then gcc_cv_as_powerpc_dfp=yes |
23347 | fi | |
23348 | elif test x$gcc_cv_as != x; then | |
23349 | echo "$conftest_s" > conftest.s | |
23350 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23351 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
b639c3c2 JJ |
23352 | (eval $ac_try) 2>&5 |
23353 | ac_status=$? | |
5213506e RW |
23354 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23355 | test $ac_status = 0; }; } | |
b639c3c2 JJ |
23356 | then |
23357 | gcc_cv_as_powerpc_dfp=yes | |
23358 | else | |
23359 | echo "configure: failed program was" >&5 | |
23360 | cat conftest.s >&5 | |
23361 | fi | |
23362 | rm -f conftest.o conftest.s | |
23363 | fi | |
23364 | fi | |
5213506e RW |
23365 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_dfp" >&5 |
23366 | $as_echo "$gcc_cv_as_powerpc_dfp" >&6; } | |
b639c3c2 JJ |
23367 | if test $gcc_cv_as_powerpc_dfp = yes; then |
23368 | ||
5213506e | 23369 | $as_echo "#define HAVE_AS_DFP 1" >>confdefs.h |
b639c3c2 | 23370 | |
d40c9e33 PB |
23371 | fi |
23372 | ||
23373 | case $target in | |
23374 | *-*-aix*) conftest_s=' .machine "pwr7" | |
23375 | .csect .text[PR] | |
23376 | lxvd2x 1,2,3';; | |
23377 | *) conftest_s=' .machine power7 | |
23378 | .text | |
23379 | lxvd2x 1,2,3';; | |
23380 | esac | |
23381 | ||
5213506e RW |
23382 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for vector-scalar support" >&5 |
23383 | $as_echo_n "checking assembler for vector-scalar support... " >&6; } | |
23384 | if test "${gcc_cv_as_powerpc_vsx+set}" = set; then : | |
23385 | $as_echo_n "(cached) " >&6 | |
d40c9e33 PB |
23386 | else |
23387 | gcc_cv_as_powerpc_vsx=no | |
23388 | if test $in_tree_gas = yes; then | |
cacf1ca8 | 23389 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` |
d40c9e33 PB |
23390 | then gcc_cv_as_powerpc_vsx=yes |
23391 | fi | |
23392 | elif test x$gcc_cv_as != x; then | |
23393 | echo "$conftest_s" > conftest.s | |
23394 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23395 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
d40c9e33 PB |
23396 | (eval $ac_try) 2>&5 |
23397 | ac_status=$? | |
5213506e RW |
23398 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23399 | test $ac_status = 0; }; } | |
d40c9e33 PB |
23400 | then |
23401 | gcc_cv_as_powerpc_vsx=yes | |
23402 | else | |
23403 | echo "configure: failed program was" >&5 | |
23404 | cat conftest.s >&5 | |
23405 | fi | |
23406 | rm -f conftest.o conftest.s | |
23407 | fi | |
23408 | fi | |
5213506e RW |
23409 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_vsx" >&5 |
23410 | $as_echo "$gcc_cv_as_powerpc_vsx" >&6; } | |
d40c9e33 PB |
23411 | if test $gcc_cv_as_powerpc_vsx = yes; then |
23412 | ||
5213506e | 23413 | $as_echo "#define HAVE_AS_VSX 1" >>confdefs.h |
d40c9e33 | 23414 | |
cacf1ca8 MM |
23415 | fi |
23416 | ||
23417 | case $target in | |
23418 | *-*-aix*) conftest_s=' .machine "pwr7" | |
23419 | .csect .text[PR] | |
23420 | popcntd 3,3';; | |
23421 | *) conftest_s=' .machine power7 | |
23422 | .text | |
23423 | popcntd 3,3';; | |
23424 | esac | |
23425 | ||
5213506e RW |
23426 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for popcntd support" >&5 |
23427 | $as_echo_n "checking assembler for popcntd support... " >&6; } | |
23428 | if test "${gcc_cv_as_powerpc_popcntd+set}" = set; then : | |
23429 | $as_echo_n "(cached) " >&6 | |
cacf1ca8 MM |
23430 | else |
23431 | gcc_cv_as_powerpc_popcntd=no | |
23432 | if test $in_tree_gas = yes; then | |
23433 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` | |
23434 | then gcc_cv_as_powerpc_popcntd=yes | |
23435 | fi | |
23436 | elif test x$gcc_cv_as != x; then | |
23437 | echo "$conftest_s" > conftest.s | |
23438 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23439 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
cacf1ca8 MM |
23440 | (eval $ac_try) 2>&5 |
23441 | ac_status=$? | |
5213506e RW |
23442 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23443 | test $ac_status = 0; }; } | |
cacf1ca8 MM |
23444 | then |
23445 | gcc_cv_as_powerpc_popcntd=yes | |
23446 | else | |
23447 | echo "configure: failed program was" >&5 | |
23448 | cat conftest.s >&5 | |
23449 | fi | |
23450 | rm -f conftest.o conftest.s | |
23451 | fi | |
23452 | fi | |
5213506e RW |
23453 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_popcntd" >&5 |
23454 | $as_echo "$gcc_cv_as_powerpc_popcntd" >&6; } | |
cacf1ca8 MM |
23455 | if test $gcc_cv_as_powerpc_popcntd = yes; then |
23456 | ||
5213506e | 23457 | $as_echo "#define HAVE_AS_POPCNTD 1" >>confdefs.h |
cacf1ca8 MM |
23458 | |
23459 | fi | |
23460 | ||
23461 | case $target in | |
23462 | *-*-aix*) conftest_s=' .csect .text[PR] | |
23463 | lwsync';; | |
23464 | *) conftest_s=' .text | |
23465 | lwsync';; | |
23466 | esac | |
23467 | ||
5213506e RW |
23468 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for lwsync support" >&5 |
23469 | $as_echo_n "checking assembler for lwsync support... " >&6; } | |
23470 | if test "${gcc_cv_as_powerpc_lwsync+set}" = set; then : | |
23471 | $as_echo_n "(cached) " >&6 | |
cacf1ca8 MM |
23472 | else |
23473 | gcc_cv_as_powerpc_lwsync=no | |
23474 | if test $in_tree_gas = yes; then | |
23475 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 2` | |
23476 | then gcc_cv_as_powerpc_lwsync=yes | |
23477 | fi | |
23478 | elif test x$gcc_cv_as != x; then | |
23479 | echo "$conftest_s" > conftest.s | |
23480 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
5213506e | 23481 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
cacf1ca8 MM |
23482 | (eval $ac_try) 2>&5 |
23483 | ac_status=$? | |
5213506e RW |
23484 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23485 | test $ac_status = 0; }; } | |
cacf1ca8 MM |
23486 | then |
23487 | gcc_cv_as_powerpc_lwsync=yes | |
23488 | else | |
23489 | echo "configure: failed program was" >&5 | |
23490 | cat conftest.s >&5 | |
23491 | fi | |
23492 | rm -f conftest.o conftest.s | |
23493 | fi | |
23494 | fi | |
5213506e RW |
23495 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_lwsync" >&5 |
23496 | $as_echo "$gcc_cv_as_powerpc_lwsync" >&6; } | |
cacf1ca8 MM |
23497 | if test $gcc_cv_as_powerpc_lwsync = yes; then |
23498 | ||
5213506e | 23499 | $as_echo "#define HAVE_AS_LWSYNC 1" >>confdefs.h |
cacf1ca8 | 23500 | |
47f67e51 PB |
23501 | fi |
23502 | ||
23503 | case $target in | |
23504 | *-*-aix*) conftest_s=' .machine "476" | |
23505 | .csect .text[PR] | |
23506 | dci 0';; | |
23507 | *) conftest_s=' .machine "476" | |
23508 | .text | |
23509 | dci 0';; | |
23510 | esac | |
23511 | ||
23512 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for data cache invalidate support" >&5 | |
23513 | $as_echo_n "checking assembler for data cache invalidate support... " >&6; } | |
23514 | if test "${gcc_cv_as_powerpc_dci+set}" = set; then : | |
23515 | $as_echo_n "(cached) " >&6 | |
23516 | else | |
23517 | gcc_cv_as_powerpc_dci=no | |
23518 | if test $in_tree_gas = yes; then | |
23519 | if test $gcc_cv_gas_vers -ge `expr \( \( 9 \* 1000 \) + 99 \) \* 1000 + 0` | |
23520 | then gcc_cv_as_powerpc_dci=yes | |
23521 | fi | |
23522 | elif test x$gcc_cv_as != x; then | |
23523 | echo "$conftest_s" > conftest.s | |
23524 | if { ac_try='$gcc_cv_as -a32 -o conftest.o conftest.s >&5' | |
23525 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 | |
23526 | (eval $ac_try) 2>&5 | |
23527 | ac_status=$? | |
23528 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 | |
23529 | test $ac_status = 0; }; } | |
23530 | then | |
23531 | gcc_cv_as_powerpc_dci=yes | |
23532 | else | |
23533 | echo "configure: failed program was" >&5 | |
23534 | cat conftest.s >&5 | |
23535 | fi | |
23536 | rm -f conftest.o conftest.s | |
23537 | fi | |
23538 | fi | |
23539 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_dci" >&5 | |
23540 | $as_echo "$gcc_cv_as_powerpc_dci" >&6; } | |
23541 | if test $gcc_cv_as_powerpc_dci = yes; then | |
23542 | ||
23543 | $as_echo "#define HAVE_AS_DCI 1" >>confdefs.h | |
23544 | ||
e51917ae JM |
23545 | fi |
23546 | ||
5213506e RW |
23547 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .gnu_attribute support" >&5 |
23548 | $as_echo_n "checking assembler for .gnu_attribute support... " >&6; } | |
23549 | if test "${gcc_cv_as_powerpc_gnu_attribute+set}" = set; then : | |
23550 | $as_echo_n "(cached) " >&6 | |
e51917ae JM |
23551 | else |
23552 | gcc_cv_as_powerpc_gnu_attribute=no | |
23553 | if test $in_tree_gas = yes; then | |
23554 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0` | |
23555 | then gcc_cv_as_powerpc_gnu_attribute=yes | |
23556 | fi | |
23557 | elif test x$gcc_cv_as != x; then | |
23558 | echo '.gnu_attribute 4,1' > conftest.s | |
23559 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23560 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
e51917ae JM |
23561 | (eval $ac_try) 2>&5 |
23562 | ac_status=$? | |
5213506e RW |
23563 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23564 | test $ac_status = 0; }; } | |
e51917ae JM |
23565 | then |
23566 | gcc_cv_as_powerpc_gnu_attribute=yes | |
23567 | else | |
23568 | echo "configure: failed program was" >&5 | |
23569 | cat conftest.s >&5 | |
23570 | fi | |
23571 | rm -f conftest.o conftest.s | |
23572 | fi | |
23573 | fi | |
5213506e RW |
23574 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_gnu_attribute" >&5 |
23575 | $as_echo "$gcc_cv_as_powerpc_gnu_attribute" >&6; } | |
e51917ae JM |
23576 | if test $gcc_cv_as_powerpc_gnu_attribute = yes; then |
23577 | ||
5213506e | 23578 | $as_echo "#define HAVE_AS_GNU_ATTRIBUTE 1" >>confdefs.h |
e51917ae | 23579 | |
9752c4ad AM |
23580 | fi |
23581 | ||
5213506e RW |
23582 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for tls marker support" >&5 |
23583 | $as_echo_n "checking assembler for tls marker support... " >&6; } | |
23584 | if test "${gcc_cv_as_powerpc_tls_markers+set}" = set; then : | |
23585 | $as_echo_n "(cached) " >&6 | |
9752c4ad AM |
23586 | else |
23587 | gcc_cv_as_powerpc_tls_markers=no | |
23588 | if test $in_tree_gas = yes; then | |
207bf79d | 23589 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 20 \) \* 1000 + 0` |
9752c4ad AM |
23590 | then gcc_cv_as_powerpc_tls_markers=yes |
23591 | fi | |
23592 | elif test x$gcc_cv_as != x; then | |
23593 | echo ' bl __tls_get_addr(x@tlsgd)' > conftest.s | |
23594 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23595 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
9752c4ad AM |
23596 | (eval $ac_try) 2>&5 |
23597 | ac_status=$? | |
5213506e RW |
23598 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23599 | test $ac_status = 0; }; } | |
9752c4ad AM |
23600 | then |
23601 | gcc_cv_as_powerpc_tls_markers=yes | |
23602 | else | |
23603 | echo "configure: failed program was" >&5 | |
23604 | cat conftest.s >&5 | |
23605 | fi | |
23606 | rm -f conftest.o conftest.s | |
23607 | fi | |
23608 | fi | |
5213506e RW |
23609 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_powerpc_tls_markers" >&5 |
23610 | $as_echo "$gcc_cv_as_powerpc_tls_markers" >&6; } | |
9752c4ad AM |
23611 | if test $gcc_cv_as_powerpc_tls_markers = yes; then |
23612 | ||
5213506e | 23613 | $as_echo "#define HAVE_AS_TLS_MARKERS 1" >>confdefs.h |
9752c4ad | 23614 | |
7f970b70 | 23615 | fi |
8ada417f ZW |
23616 | ;; |
23617 | ||
23618 | mips*-*-*) | |
5213506e RW |
23619 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for explicit relocation support" >&5 |
23620 | $as_echo_n "checking assembler for explicit relocation support... " >&6; } | |
23621 | if test "${gcc_cv_as_mips_explicit_relocs+set}" = set; then : | |
23622 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
23623 | else |
23624 | gcc_cv_as_mips_explicit_relocs=no | |
23625 | if test $in_tree_gas = yes; then | |
23626 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 14 \) \* 1000 + 0` | |
23627 | then gcc_cv_as_mips_explicit_relocs=yes | |
23628 | fi | |
23629 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 23630 | echo ' lw $4,%gp_rel(foo)($4)' > conftest.s |
ba479fd2 | 23631 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 23632 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23633 | (eval $ac_try) 2>&5 |
23634 | ac_status=$? | |
5213506e RW |
23635 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23636 | test $ac_status = 0; }; } | |
8ada417f ZW |
23637 | then |
23638 | gcc_cv_as_mips_explicit_relocs=yes | |
23639 | else | |
23640 | echo "configure: failed program was" >&5 | |
23641 | cat conftest.s >&5 | |
ef1ecf87 | 23642 | fi |
8ada417f ZW |
23643 | rm -f conftest.o conftest.s |
23644 | fi | |
23645 | fi | |
5213506e RW |
23646 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_mips_explicit_relocs" >&5 |
23647 | $as_echo "$gcc_cv_as_mips_explicit_relocs" >&6; } | |
8ada417f ZW |
23648 | if test $gcc_cv_as_mips_explicit_relocs = yes; then |
23649 | if test x$target_cpu_default = x | |
23650 | then target_cpu_default=MASK_EXPLICIT_RELOCS | |
23651 | else target_cpu_default="($target_cpu_default)|MASK_EXPLICIT_RELOCS" | |
23652 | fi | |
4551169f | 23653 | fi |
5213506e RW |
23654 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for -mno-shared support" >&5 |
23655 | $as_echo_n "checking assembler for -mno-shared support... " >&6; } | |
23656 | if test "${gcc_cv_as_mips_no_shared+set}" = set; then : | |
23657 | $as_echo_n "(cached) " >&6 | |
4551169f RS |
23658 | else |
23659 | gcc_cv_as_mips_no_shared=no | |
23660 | if test $in_tree_gas = yes; then | |
23661 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 0` | |
23662 | then gcc_cv_as_mips_no_shared=yes | |
23663 | fi | |
23664 | elif test x$gcc_cv_as != x; then | |
23665 | echo 'nop' > conftest.s | |
23666 | if { ac_try='$gcc_cv_as -mno-shared -o conftest.o conftest.s >&5' | |
5213506e | 23667 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
4551169f RS |
23668 | (eval $ac_try) 2>&5 |
23669 | ac_status=$? | |
5213506e RW |
23670 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23671 | test $ac_status = 0; }; } | |
4551169f RS |
23672 | then |
23673 | gcc_cv_as_mips_no_shared=yes | |
23674 | else | |
23675 | echo "configure: failed program was" >&5 | |
23676 | cat conftest.s >&5 | |
23677 | fi | |
23678 | rm -f conftest.o conftest.s | |
23679 | fi | |
23680 | fi | |
5213506e RW |
23681 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_mips_no_shared" >&5 |
23682 | $as_echo "$gcc_cv_as_mips_no_shared" >&6; } | |
4551169f RS |
23683 | if test $gcc_cv_as_mips_no_shared = yes; then |
23684 | ||
5213506e | 23685 | $as_echo "#define HAVE_AS_NO_SHARED 1" >>confdefs.h |
4551169f | 23686 | |
dcb957d9 JM |
23687 | fi |
23688 | ||
5213506e RW |
23689 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .gnu_attribute support" >&5 |
23690 | $as_echo_n "checking assembler for .gnu_attribute support... " >&6; } | |
23691 | if test "${gcc_cv_as_mips_gnu_attribute+set}" = set; then : | |
23692 | $as_echo_n "(cached) " >&6 | |
dcb957d9 JM |
23693 | else |
23694 | gcc_cv_as_mips_gnu_attribute=no | |
23695 | if test $in_tree_gas = yes; then | |
23696 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0` | |
23697 | then gcc_cv_as_mips_gnu_attribute=yes | |
23698 | fi | |
23699 | elif test x$gcc_cv_as != x; then | |
23700 | echo '.gnu_attribute 4,1' > conftest.s | |
23701 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23702 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
dcb957d9 JM |
23703 | (eval $ac_try) 2>&5 |
23704 | ac_status=$? | |
5213506e RW |
23705 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23706 | test $ac_status = 0; }; } | |
dcb957d9 JM |
23707 | then |
23708 | gcc_cv_as_mips_gnu_attribute=yes | |
23709 | else | |
23710 | echo "configure: failed program was" >&5 | |
23711 | cat conftest.s >&5 | |
23712 | fi | |
23713 | rm -f conftest.o conftest.s | |
23714 | fi | |
23715 | fi | |
5213506e RW |
23716 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_mips_gnu_attribute" >&5 |
23717 | $as_echo "$gcc_cv_as_mips_gnu_attribute" >&6; } | |
dcb957d9 JM |
23718 | if test $gcc_cv_as_mips_gnu_attribute = yes; then |
23719 | ||
5213506e | 23720 | $as_echo "#define HAVE_AS_GNU_ATTRIBUTE 1" >>confdefs.h |
dcb957d9 | 23721 | |
a44380d2 JM |
23722 | fi |
23723 | ||
5213506e RW |
23724 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .dtprelword support" >&5 |
23725 | $as_echo_n "checking assembler for .dtprelword support... " >&6; } | |
23726 | if test "${gcc_cv_as_mips_dtprelword+set}" = set; then : | |
23727 | $as_echo_n "(cached) " >&6 | |
a44380d2 JM |
23728 | else |
23729 | gcc_cv_as_mips_dtprelword=no | |
23730 | if test $in_tree_gas = yes; then | |
23731 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0` | |
23732 | then gcc_cv_as_mips_dtprelword=yes | |
23733 | fi | |
23734 | elif test x$gcc_cv_as != x; then | |
23735 | echo '.section .tdata,"awT",@progbits | |
23736 | x: | |
23737 | .word 2 | |
23738 | .text | |
23739 | .dtprelword x+0x8000' > conftest.s | |
23740 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 23741 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
a44380d2 JM |
23742 | (eval $ac_try) 2>&5 |
23743 | ac_status=$? | |
5213506e RW |
23744 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23745 | test $ac_status = 0; }; } | |
a44380d2 JM |
23746 | then |
23747 | gcc_cv_as_mips_dtprelword=yes | |
23748 | else | |
23749 | echo "configure: failed program was" >&5 | |
23750 | cat conftest.s >&5 | |
23751 | fi | |
23752 | rm -f conftest.o conftest.s | |
23753 | fi | |
23754 | fi | |
5213506e RW |
23755 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_mips_dtprelword" >&5 |
23756 | $as_echo "$gcc_cv_as_mips_dtprelword" >&6; } | |
a44380d2 JM |
23757 | if test $gcc_cv_as_mips_dtprelword = yes; then |
23758 | ||
5213506e | 23759 | $as_echo "#define HAVE_AS_DTPRELWORD 1" >>confdefs.h |
a44380d2 | 23760 | |
8ada417f | 23761 | fi |
b53da244 AN |
23762 | |
23763 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler and linker for explicit JALR relocation" >&5 | |
23764 | $as_echo_n "checking assembler and linker for explicit JALR relocation... " >&6; } | |
23765 | gcc_cv_as_ld_jalr_reloc=no | |
23766 | if test $gcc_cv_as_mips_explicit_relocs = yes; then | |
23767 | if test $in_tree_ld = yes ; then | |
23768 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 20 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
23769 | && test $in_tree_ld_is_elf = yes; then | |
23770 | gcc_cv_as_ld_jalr_reloc=yes | |
23771 | fi | |
23772 | elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x -a x$gcc_cv_objdump != x; then | |
23773 | echo ' .ent x' > conftest.s | |
23774 | echo 'x: ld $2,%got_disp(y)($3)' >> conftest.s | |
23775 | echo ' ld $25,%call16(y)($28)' >> conftest.s | |
23776 | echo ' .reloc 1f,R_MIPS_JALR,y' >> conftest.s | |
23777 | echo '1: jalr $25' >> conftest.s | |
23778 | echo ' .reloc 1f,R_MIPS_JALR,x' >> conftest.s | |
23779 | echo '1: jalr $25' >> conftest.s | |
23780 | echo ' .end x' >> conftest.s | |
23781 | if $gcc_cv_as -o conftest.o conftest.s >/dev/null 2>&5 \ | |
23782 | && $gcc_cv_ld -shared -o conftest.so conftest.o >/dev/null 2>&5; then | |
23783 | if $gcc_cv_objdump -d conftest.so | grep -q jalr \ | |
23784 | && $gcc_cv_objdump -d conftest.so | grep -q "bal.*<x>"; then | |
23785 | gcc_cv_as_ld_jalr_reloc=yes | |
23786 | fi | |
23787 | fi | |
23788 | rm -f conftest.* | |
23789 | fi | |
23790 | fi | |
23791 | if test $gcc_cv_as_ld_jalr_reloc = yes; then | |
23792 | if test x$target_cpu_default = x; then | |
23793 | target_cpu_default=MASK_RELAX_PIC_CALLS | |
23794 | else | |
23795 | target_cpu_default="($target_cpu_default)|MASK_RELAX_PIC_CALLS" | |
23796 | fi | |
23797 | fi | |
23798 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_ld_jalr_reloc" >&5 | |
23799 | $as_echo "$gcc_cv_as_ld_jalr_reloc" >&6; } | |
49576e25 RS |
23800 | |
23801 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker for .eh_frame personality relaxation" >&5 | |
23802 | $as_echo_n "checking linker for .eh_frame personality relaxation... " >&6; } | |
23803 | if test "${gcc_cv_ld_mips_personality_relaxation+set}" = set; then : | |
23804 | $as_echo_n "(cached) " >&6 | |
23805 | else | |
23806 | gcc_cv_ld_mips_personality_relaxation=no | |
23807 | if test $in_tree_ld = yes ; then | |
23808 | if test "$gcc_cv_gld_major_version" -eq 2 \ | |
23809 | -a "$gcc_cv_gld_minor_version" -ge 21 \ | |
23810 | -o "$gcc_cv_gld_major_version" -gt 2; then | |
23811 | gcc_cv_ld_mips_personality_relaxation=yes | |
23812 | fi | |
23813 | elif test x$gcc_cv_as != x \ | |
23814 | -a x$gcc_cv_ld != x \ | |
23815 | -a x$gcc_cv_readelf != x ; then | |
23816 | cat > conftest.s <<EOF | |
23817 | .cfi_startproc | |
23818 | .cfi_personality 0x80,indirect_ptr | |
23819 | .ent test | |
23820 | test: | |
23821 | nop | |
23822 | .end test | |
23823 | .cfi_endproc | |
23824 | ||
23825 | .section .data,"aw",@progbits | |
23826 | indirect_ptr: | |
23827 | .dc.a personality | |
23828 | EOF | |
23829 | if $gcc_cv_as -KPIC -o conftest.o conftest.s > /dev/null 2>&1 \ | |
23830 | && $gcc_cv_ld -o conftest conftest.o -shared > /dev/null 2>&1; then | |
23831 | if $gcc_cv_readelf -d conftest 2>&1 \ | |
23832 | | grep TEXTREL > /dev/null 2>&1; then | |
23833 | : | |
23834 | elif $gcc_cv_readelf --relocs conftest 2>&1 \ | |
23835 | | grep 'R_MIPS_REL32 *$' > /dev/null 2>&1; then | |
23836 | : | |
23837 | else | |
23838 | gcc_cv_ld_mips_personality_relaxation=yes | |
23839 | fi | |
23840 | fi | |
23841 | fi | |
23842 | rm -f conftest.s conftest.o conftest | |
23843 | fi | |
23844 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_mips_personality_relaxation" >&5 | |
23845 | $as_echo "$gcc_cv_ld_mips_personality_relaxation" >&6; } | |
23846 | if test x$gcc_cv_ld_mips_personality_relaxation = xyes; then | |
23847 | ||
23848 | $as_echo "#define HAVE_LD_PERSONALITY_RELAXATION 1" >>confdefs.h | |
23849 | ||
23850 | fi | |
dbad5e72 SE |
23851 | ;; |
23852 | esac | |
8ada417f | 23853 | |
dbad5e72 SE |
23854 | # Mips and HP-UX need the GNU assembler. |
23855 | # Linux on IA64 might be able to use the Intel assembler. | |
23856 | ||
23857 | case "$target" in | |
23858 | mips*-*-* | *-*-hpux* ) | |
82563d35 RS |
23859 | if test x$gas_flag = xyes \ |
23860 | || test x"$host" != x"$build" \ | |
23861 | || test ! -x "$gcc_cv_as" \ | |
23862 | || "$gcc_cv_as" -v < /dev/null 2>&1 | grep GNU > /dev/null; then | |
23863 | : | |
23864 | else | |
23865 | echo "*** This configuration requires the GNU assembler" >&2 | |
23866 | exit 1 | |
23867 | fi | |
ef1ecf87 | 23868 | ;; |
1cb36a98 | 23869 | esac |
dbad5e72 | 23870 | |
9d147085 RH |
23871 | # ??? Not all targets support dwarf2 debug_line, even within a version |
23872 | # of gas. Moreover, we need to emit a valid instruction to trigger any | |
23873 | # info to the output file. So, as supported targets are added to gas 2.11, | |
23874 | # add some instruction here to (also) show we expect this might work. | |
23875 | # ??? Once 2.11 is released, probably need to add first known working | |
23876 | # version to the per-target configury. | |
23877 | case "$target" in | |
80486e06 | 23878 | i?86*-*-* | mips*-*-* | alpha*-*-* | powerpc*-*-* | sparc*-*-* | m68*-*-* \ |
cd985f66 | 23879 | | x86_64*-*-* | hppa*-*-* | arm*-*-* \ |
ad9646c7 | 23880 | | xstormy16*-*-* | cris-*-* | crisv32-*-* | xtensa*-*-* | bfin-*-* | score*-*-* \ |
15a43677 | 23881 | | spu-*-* | fido*-*-* | m32c-*-*) |
9d147085 RH |
23882 | insn="nop" |
23883 | ;; | |
57116d8d | 23884 | ia64*-*-* | s390*-*-*) |
9d147085 RH |
23885 | insn="nop 0" |
23886 | ;; | |
2853bc5a HPN |
23887 | mmix-*-*) |
23888 | insn="swym 0" | |
23889 | ;; | |
8ada417f ZW |
23890 | esac |
23891 | if test x"$insn" != x; then | |
23892 | conftest_s="\ | |
23893 | .file 1 \"conftest.s\" | |
23894 | .loc 1 3 0 | |
23895 | $insn" | |
5213506e RW |
23896 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for dwarf2 debug_line support" >&5 |
23897 | $as_echo_n "checking assembler for dwarf2 debug_line support... " >&6; } | |
23898 | if test "${gcc_cv_as_dwarf2_debug_line+set}" = set; then : | |
23899 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
23900 | else |
23901 | gcc_cv_as_dwarf2_debug_line=no | |
23902 | if test $in_tree_gas = yes; then | |
23903 | if test $in_tree_gas_is_elf = yes \ | |
23904 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0` | |
23905 | then gcc_cv_as_dwarf2_debug_line=yes | |
23906 | fi | |
23907 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 23908 | echo "$conftest_s" > conftest.s |
ba479fd2 | 23909 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 23910 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23911 | (eval $ac_try) 2>&5 |
23912 | ac_status=$? | |
5213506e RW |
23913 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23914 | test $ac_status = 0; }; } | |
8ada417f | 23915 | then |
080a5bb0 EB |
23916 | if test x$gcc_cv_objdump != x \ |
23917 | && $gcc_cv_objdump -h conftest.o 2> /dev/null \ | |
23918 | | grep debug_line > /dev/null 2>&1; then | |
8ada417f ZW |
23919 | gcc_cv_as_dwarf2_debug_line=yes |
23920 | fi | |
23921 | else | |
23922 | echo "configure: failed program was" >&5 | |
23923 | cat conftest.s >&5 | |
23924 | fi | |
23925 | rm -f conftest.o conftest.s | |
23926 | fi | |
23927 | fi | |
5213506e RW |
23928 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_dwarf2_debug_line" >&5 |
23929 | $as_echo "$gcc_cv_as_dwarf2_debug_line" >&6; } | |
ad9c4d9f | 23930 | |
ad9c4d9f | 23931 | |
8ada417f ZW |
23932 | # The .debug_line file table must be in the exact order that |
23933 | # we specified the files, since these indices are also used | |
23934 | # by DW_AT_decl_file. Approximate this test by testing if | |
23935 | # the assembler bitches if the same index is assigned twice. | |
5213506e RW |
23936 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for buggy dwarf2 .file directive" >&5 |
23937 | $as_echo_n "checking assembler for buggy dwarf2 .file directive... " >&6; } | |
23938 | if test "${gcc_cv_as_dwarf2_file_buggy+set}" = set; then : | |
23939 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
23940 | else |
23941 | gcc_cv_as_dwarf2_file_buggy=no | |
23942 | if test x$gcc_cv_as != x; then | |
6e3f3080 | 23943 | echo ' .file 1 "foo.s" |
8ada417f | 23944 | .file 1 "bar.s"' > conftest.s |
ba479fd2 | 23945 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' |
5213506e | 23946 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23947 | (eval $ac_try) 2>&5 |
23948 | ac_status=$? | |
5213506e RW |
23949 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23950 | test $ac_status = 0; }; } | |
8ada417f ZW |
23951 | then |
23952 | gcc_cv_as_dwarf2_file_buggy=yes | |
23953 | else | |
23954 | echo "configure: failed program was" >&5 | |
23955 | cat conftest.s >&5 | |
23956 | fi | |
23957 | rm -f conftest.o conftest.s | |
23958 | fi | |
ad9c4d9f | 23959 | fi |
5213506e RW |
23960 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_dwarf2_file_buggy" >&5 |
23961 | $as_echo "$gcc_cv_as_dwarf2_file_buggy" >&6; } | |
8ada417f ZW |
23962 | |
23963 | ||
23964 | if test $gcc_cv_as_dwarf2_debug_line = yes \ | |
23965 | && test $gcc_cv_as_dwarf2_file_buggy = no; then | |
ba479fd2 | 23966 | |
5213506e | 23967 | $as_echo "#define HAVE_AS_DWARF2_DEBUG_LINE 1" >>confdefs.h |
9d147085 | 23968 | |
8ada417f | 23969 | fi |
ad9c4d9f | 23970 | |
5213506e RW |
23971 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for --gdwarf2 option" >&5 |
23972 | $as_echo_n "checking assembler for --gdwarf2 option... " >&6; } | |
23973 | if test "${gcc_cv_as_gdwarf2_flag+set}" = set; then : | |
23974 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
23975 | else |
23976 | gcc_cv_as_gdwarf2_flag=no | |
23977 | if test $in_tree_gas = yes; then | |
23978 | if test $in_tree_gas_is_elf = yes \ | |
23979 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0` | |
23980 | then gcc_cv_as_gdwarf2_flag=yes | |
23981 | fi | |
23982 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 23983 | echo "$insn" > conftest.s |
ba479fd2 | 23984 | if { ac_try='$gcc_cv_as --gdwarf2 -o conftest.o conftest.s >&5' |
5213506e | 23985 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
23986 | (eval $ac_try) 2>&5 |
23987 | ac_status=$? | |
5213506e RW |
23988 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
23989 | test $ac_status = 0; }; } | |
8ada417f ZW |
23990 | then |
23991 | gcc_cv_as_gdwarf2_flag=yes | |
23992 | else | |
23993 | echo "configure: failed program was" >&5 | |
23994 | cat conftest.s >&5 | |
23995 | fi | |
23996 | rm -f conftest.o conftest.s | |
23997 | fi | |
ad9c4d9f | 23998 | fi |
5213506e RW |
23999 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_gdwarf2_flag" >&5 |
24000 | $as_echo "$gcc_cv_as_gdwarf2_flag" >&6; } | |
63cf211a | 24001 | if test $gcc_cv_as_gdwarf2_flag = yes; then |
ba479fd2 | 24002 | |
5213506e | 24003 | $as_echo "#define HAVE_AS_GDWARF2_DEBUG_FLAG 1" >>confdefs.h |
5f0e9ea2 GK |
24004 | |
24005 | fi | |
ad9c4d9f | 24006 | |
5213506e RW |
24007 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for --gstabs option" >&5 |
24008 | $as_echo_n "checking assembler for --gstabs option... " >&6; } | |
24009 | if test "${gcc_cv_as_gstabs_flag+set}" = set; then : | |
24010 | $as_echo_n "(cached) " >&6 | |
8ada417f ZW |
24011 | else |
24012 | gcc_cv_as_gstabs_flag=no | |
24013 | if test $in_tree_gas = yes; then | |
24014 | if test $in_tree_gas_is_elf = yes \ | |
24015 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 11 \) \* 1000 + 0` | |
24016 | then gcc_cv_as_gstabs_flag=yes | |
24017 | fi | |
24018 | elif test x$gcc_cv_as != x; then | |
6e3f3080 | 24019 | echo "$insn" > conftest.s |
ba479fd2 | 24020 | if { ac_try='$gcc_cv_as --gstabs -o conftest.o conftest.s >&5' |
5213506e | 24021 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
24022 | (eval $ac_try) 2>&5 |
24023 | ac_status=$? | |
5213506e RW |
24024 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24025 | test $ac_status = 0; }; } | |
8ada417f ZW |
24026 | then |
24027 | # The native Solaris 9/Intel assembler doesn't understand --gstabs | |
24028 | # and warns about it, but still exits successfully. So check for | |
24029 | # this. | |
ba479fd2 | 24030 | if { ac_try='$gcc_cv_as --gstabs -o conftest.o conftest.s 2>&1 | grep -i warning > /dev/null' |
5213506e | 24031 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
ba479fd2 NN |
24032 | (eval $ac_try) 2>&5 |
24033 | ac_status=$? | |
5213506e RW |
24034 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24035 | test $ac_status = 0; }; } | |
8ada417f ZW |
24036 | then : |
24037 | else gcc_cv_as_gstabs_flag=yes | |
24038 | fi | |
24039 | else | |
24040 | echo "configure: failed program was" >&5 | |
24041 | cat conftest.s >&5 | |
24042 | fi | |
24043 | rm -f conftest.o conftest.s | |
24044 | fi | |
ad9c4d9f | 24045 | fi |
5213506e RW |
24046 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_gstabs_flag" >&5 |
24047 | $as_echo "$gcc_cv_as_gstabs_flag" >&6; } | |
63cf211a | 24048 | if test $gcc_cv_as_gstabs_flag = yes; then |
ba479fd2 | 24049 | |
5213506e | 24050 | $as_echo "#define HAVE_AS_GSTABS_DEBUG_FLAG 1" >>confdefs.h |
5f0e9ea2 | 24051 | |
c8aea42c PB |
24052 | fi |
24053 | ||
5213506e RW |
24054 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for --debug-prefix-map option" >&5 |
24055 | $as_echo_n "checking assembler for --debug-prefix-map option... " >&6; } | |
24056 | if test "${gcc_cv_as_debug_prefix_map_flag+set}" = set; then : | |
24057 | $as_echo_n "(cached) " >&6 | |
c8aea42c PB |
24058 | else |
24059 | gcc_cv_as_debug_prefix_map_flag=no | |
24060 | if test $in_tree_gas = yes; then | |
303a4698 | 24061 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 18 \) \* 1000 + 0` |
c8aea42c PB |
24062 | then gcc_cv_as_debug_prefix_map_flag=yes |
24063 | fi | |
24064 | elif test x$gcc_cv_as != x; then | |
24065 | echo "$insn" > conftest.s | |
24066 | if { ac_try='$gcc_cv_as --debug-prefix-map /a=/b -o conftest.o conftest.s >&5' | |
5213506e | 24067 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
c8aea42c PB |
24068 | (eval $ac_try) 2>&5 |
24069 | ac_status=$? | |
5213506e RW |
24070 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24071 | test $ac_status = 0; }; } | |
c8aea42c PB |
24072 | then |
24073 | gcc_cv_as_debug_prefix_map_flag=yes | |
24074 | else | |
24075 | echo "configure: failed program was" >&5 | |
24076 | cat conftest.s >&5 | |
24077 | fi | |
24078 | rm -f conftest.o conftest.s | |
24079 | fi | |
24080 | fi | |
5213506e RW |
24081 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_debug_prefix_map_flag" >&5 |
24082 | $as_echo "$gcc_cv_as_debug_prefix_map_flag" >&6; } | |
c8aea42c PB |
24083 | if test $gcc_cv_as_debug_prefix_map_flag = yes; then |
24084 | ||
5213506e | 24085 | $as_echo "#define HAVE_AS_DEBUG_PREFIX_MAP 1" >>confdefs.h |
c8aea42c | 24086 | |
5f0e9ea2 | 24087 | fi |
8ada417f | 24088 | fi |
5f0e9ea2 | 24089 | |
5213506e RW |
24090 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for .lcomm with alignment" >&5 |
24091 | $as_echo_n "checking assembler for .lcomm with alignment... " >&6; } | |
24092 | if test "${gcc_cv_as_lcomm_with_alignment+set}" = set; then : | |
24093 | $as_echo_n "(cached) " >&6 | |
28e6bb13 NC |
24094 | else |
24095 | gcc_cv_as_lcomm_with_alignment=no | |
24096 | if test x$gcc_cv_as != x; then | |
24097 | echo '.lcomm bar,4,16' > conftest.s | |
24098 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 24099 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
28e6bb13 NC |
24100 | (eval $ac_try) 2>&5 |
24101 | ac_status=$? | |
5213506e RW |
24102 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24103 | test $ac_status = 0; }; } | |
28e6bb13 NC |
24104 | then |
24105 | gcc_cv_as_lcomm_with_alignment=yes | |
24106 | else | |
24107 | echo "configure: failed program was" >&5 | |
24108 | cat conftest.s >&5 | |
24109 | fi | |
24110 | rm -f conftest.o conftest.s | |
24111 | fi | |
24112 | fi | |
5213506e RW |
24113 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_lcomm_with_alignment" >&5 |
24114 | $as_echo "$gcc_cv_as_lcomm_with_alignment" >&6; } | |
28e6bb13 NC |
24115 | if test $gcc_cv_as_lcomm_with_alignment = yes; then |
24116 | ||
5213506e | 24117 | $as_echo "#define HAVE_GAS_LCOMM_WITH_ALIGNMENT 1" >>confdefs.h |
28e6bb13 NC |
24118 | |
24119 | fi | |
24120 | ||
5213506e RW |
24121 | # Check whether --enable-gnu-unique-object was given. |
24122 | if test "${enable_gnu_unique_object+set}" = set; then : | |
24123 | enableval=$enable_gnu_unique_object; case $enable_gnu_unique_object in | |
e31bcd1b | 24124 | yes | no) ;; |
5213506e RW |
24125 | *) as_fn_error "'$enable_gnu_unique_object' is an invalid value for --enable-gnu-unique-object. |
24126 | Valid choices are 'yes' and 'no'." "$LINENO" 5 ;; | |
e31bcd1b JM |
24127 | esac |
24128 | else | |
5213506e RW |
24129 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for gnu_unique_object" >&5 |
24130 | $as_echo_n "checking assembler for gnu_unique_object... " >&6; } | |
24131 | if test "${gcc_cv_as_gnu_unique_object+set}" = set; then : | |
24132 | $as_echo_n "(cached) " >&6 | |
e31bcd1b JM |
24133 | else |
24134 | gcc_cv_as_gnu_unique_object=no | |
24135 | if test $in_tree_gas = yes; then | |
24136 | if test $in_tree_gas_is_elf = yes \ | |
24137 | && test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 19 \) \* 1000 + 52` | |
24138 | then gcc_cv_as_gnu_unique_object=yes | |
24139 | fi | |
24140 | elif test x$gcc_cv_as != x; then | |
24141 | echo '.type foo, @gnu_unique_object' > conftest.s | |
24142 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5' | |
5213506e | 24143 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
e31bcd1b JM |
24144 | (eval $ac_try) 2>&5 |
24145 | ac_status=$? | |
5213506e RW |
24146 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24147 | test $ac_status = 0; }; } | |
e31bcd1b | 24148 | then |
e00ded68 | 24149 | gcc_cv_as_gnu_unique_object=yes |
e31bcd1b JM |
24150 | else |
24151 | echo "configure: failed program was" >&5 | |
24152 | cat conftest.s >&5 | |
24153 | fi | |
24154 | rm -f conftest.o conftest.s | |
24155 | fi | |
24156 | fi | |
5213506e RW |
24157 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_gnu_unique_object" >&5 |
24158 | $as_echo "$gcc_cv_as_gnu_unique_object" >&6; } | |
e31bcd1b | 24159 | if test $gcc_cv_as_gnu_unique_object = yes; then |
e00ded68 JM |
24160 | # Also check for ld.so support, i.e. glibc 2.11 or higher. |
24161 | if test x$host = x$build -a x$host = x$target && | |
24162 | glibcver=`ldd --version 2>/dev/null`; then | |
24163 | glibcmajor=`expr "$glibcver" : "ldd (GNU libc) \([0-9]*\)"` | |
24164 | glibcminor=`expr "$glibcver" : "ldd (GNU libc) [0-9]*\.\([0-9]*\)"` | |
24165 | glibcnum=`expr $glibcmajor \* 1000 + $glibcminor` | |
24166 | if test "$glibcnum" -ge 2011 ; then | |
24167 | enable_gnu_unique_object=yes | |
24168 | fi | |
24169 | fi | |
e31bcd1b | 24170 | fi |
5213506e RW |
24171 | fi |
24172 | ||
e31bcd1b JM |
24173 | if test x$enable_gnu_unique_object = xyes; then |
24174 | ||
5213506e | 24175 | $as_echo "#define HAVE_GAS_GNU_UNIQUE_OBJECT 1" >>confdefs.h |
e31bcd1b JM |
24176 | |
24177 | fi | |
24178 | ||
5213506e RW |
24179 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking assembler for tolerance to line number 0" >&5 |
24180 | $as_echo_n "checking assembler for tolerance to line number 0... " >&6; } | |
24181 | if test "${gcc_cv_as_line_zero+set}" = set; then : | |
24182 | $as_echo_n "(cached) " >&6 | |
03943c05 AO |
24183 | else |
24184 | gcc_cv_as_line_zero=no | |
24185 | if test $in_tree_gas = yes; then | |
cf0eb7a1 AO |
24186 | if test $gcc_cv_gas_vers -ge `expr \( \( 2 \* 1000 \) + 16 \) \* 1000 + 91` |
24187 | then gcc_cv_as_line_zero=yes | |
03943c05 AO |
24188 | fi |
24189 | elif test "x$gcc_cv_as" != x; then | |
24190 | { echo '# 1 "test.s" 1'; echo '# 0 "" 2'; } > conftest.s | |
24191 | if { ac_try='$gcc_cv_as -o conftest.o conftest.s >&5 2>conftest.out' | |
5213506e | 24192 | { { eval echo "\"\$as_me\":${as_lineno-$LINENO}: \"$ac_try\""; } >&5 |
03943c05 AO |
24193 | (eval $ac_try) 2>&5 |
24194 | ac_status=$? | |
5213506e RW |
24195 | $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 |
24196 | test $ac_status = 0; }; } && | |
03943c05 AO |
24197 | test "x`cat conftest.out`" = x |
24198 | then | |
24199 | gcc_cv_as_line_zero=yes | |
24200 | else | |
24201 | echo "configure: failed program was" >&5 | |
24202 | cat conftest.s >&5 | |
24203 | echo "configure: error output was" >&5 | |
24204 | cat conftest.out >&5 | |
24205 | fi | |
24206 | rm -f conftest.o conftest.s conftest.out | |
24207 | fi | |
24208 | fi | |
5213506e RW |
24209 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_as_line_zero" >&5 |
24210 | $as_echo "$gcc_cv_as_line_zero" >&6; } | |
03943c05 AO |
24211 | if test "x$gcc_cv_as_line_zero" = xyes; then |
24212 | ||
5213506e | 24213 | $as_echo "#define HAVE_AS_LINE_ZERO 1" >>confdefs.h |
03943c05 AO |
24214 | |
24215 | fi | |
24216 | ||
5213506e RW |
24217 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker PT_GNU_EH_FRAME support" >&5 |
24218 | $as_echo_n "checking linker PT_GNU_EH_FRAME support... " >&6; } | |
275b60d6 | 24219 | gcc_cv_ld_eh_frame_hdr=no |
34a86c2b | 24220 | if test $in_tree_ld = yes ; then |
5408ac6c HPN |
24221 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 12 -o "$gcc_cv_gld_major_version" -gt 2 \ |
24222 | && test $in_tree_ld_is_elf = yes; then | |
275b60d6 JJ |
24223 | gcc_cv_ld_eh_frame_hdr=yes |
24224 | fi | |
24225 | elif test x$gcc_cv_ld != x; then | |
24226 | # Check if linker supports --eh-frame-hdr option | |
24227 | if $gcc_cv_ld --help 2>/dev/null | grep eh-frame-hdr > /dev/null; then | |
24228 | gcc_cv_ld_eh_frame_hdr=yes | |
24229 | fi | |
24230 | fi | |
232b67d9 | 24231 | |
275b60d6 | 24232 | if test x"$gcc_cv_ld_eh_frame_hdr" = xyes; then |
ba479fd2 | 24233 | |
5213506e | 24234 | $as_echo "#define HAVE_LD_EH_FRAME_HDR 1" >>confdefs.h |
275b60d6 JJ |
24235 | |
24236 | fi | |
5213506e RW |
24237 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_eh_frame_hdr" >&5 |
24238 | $as_echo "$gcc_cv_ld_eh_frame_hdr" >&6; } | |
275b60d6 | 24239 | |
5213506e RW |
24240 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker position independent executable support" >&5 |
24241 | $as_echo_n "checking linker position independent executable support... " >&6; } | |
24a4dd31 JJ |
24242 | gcc_cv_ld_pie=no |
24243 | if test $in_tree_ld = yes ; then | |
5408ac6c HPN |
24244 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 15 -o "$gcc_cv_gld_major_version" -gt 2 \ |
24245 | && test $in_tree_ld_is_elf = yes; then | |
24a4dd31 JJ |
24246 | gcc_cv_ld_pie=yes |
24247 | fi | |
24248 | elif test x$gcc_cv_ld != x; then | |
24249 | # Check if linker supports -pie option | |
24250 | if $gcc_cv_ld --help 2>/dev/null | grep -- -pie > /dev/null; then | |
24251 | gcc_cv_ld_pie=yes | |
24252 | fi | |
24253 | fi | |
24254 | if test x"$gcc_cv_ld_pie" = xyes; then | |
ba479fd2 | 24255 | |
5213506e | 24256 | $as_echo "#define HAVE_LD_PIE 1" >>confdefs.h |
24a4dd31 JJ |
24257 | |
24258 | fi | |
5213506e RW |
24259 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_pie" >&5 |
24260 | $as_echo "$gcc_cv_ld_pie" >&6; } | |
24a4dd31 | 24261 | |
5213506e RW |
24262 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker EH-compatible garbage collection of sections" >&5 |
24263 | $as_echo_n "checking linker EH-compatible garbage collection of sections... " >&6; } | |
22ba88ef | 24264 | gcc_cv_ld_eh_gc_sections=no |
b639c3c2 JJ |
24265 | if test $in_tree_ld = yes ; then |
24266 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 17 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
24267 | && test $in_tree_ld_is_elf = yes; then | |
24268 | gcc_cv_ld_eh_gc_sections=yes | |
24269 | fi | |
24270 | elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x -a x$gcc_cv_objdump != x ; then | |
24271 | cat > conftest.s <<EOF | |
24272 | .section .text | |
24273 | .globl _start | |
24274 | .type _start, @function | |
24275 | _start: | |
24276 | .long foo | |
24277 | .size _start, .-_start | |
24278 | .section .text.foo,"ax",@progbits | |
24279 | .type foo, @function | |
24280 | foo: | |
24281 | .long 0 | |
24282 | .size foo, .-foo | |
24283 | .section .gcc_except_table.foo,"a",@progbits | |
24284 | .L0: | |
24285 | .long 0 | |
24286 | .section .eh_frame,"a",@progbits | |
24287 | .long .L0 | |
24288 | EOF | |
24289 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
24290 | if $gcc_cv_ld -o conftest conftest.o --entry=_start --gc-sections 2>&1 \ | |
24291 | | grep "gc-sections option ignored" > /dev/null; then | |
24292 | gcc_cv_ld_eh_gc_sections=no | |
24293 | elif $gcc_cv_objdump -h conftest | grep gcc_except_table > /dev/null; then | |
24294 | gcc_cv_ld_eh_gc_sections=yes | |
24295 | # If no COMDAT groups, the compiler will emit .gnu.linkonce.t. sections. | |
24296 | if test x$gcc_cv_as_comdat_group != xyes; then | |
24297 | gcc_cv_ld_eh_gc_sections=no | |
24298 | cat > conftest.s <<EOF | |
24299 | .section .text | |
24300 | .globl _start | |
24301 | .type _start, @function | |
24302 | _start: | |
24303 | .long foo | |
24304 | .size _start, .-_start | |
24305 | .section .gnu.linkonce.t.foo,"ax",@progbits | |
24306 | .type foo, @function | |
24307 | foo: | |
24308 | .long 0 | |
24309 | .size foo, .-foo | |
24310 | .section .gcc_except_table.foo,"a",@progbits | |
24311 | .L0: | |
24312 | .long 0 | |
24313 | .section .eh_frame,"a",@progbits | |
24314 | .long .L0 | |
24315 | EOF | |
24316 | if $gcc_cv_as -o conftest.o conftest.s > /dev/null 2>&1; then | |
24317 | if $gcc_cv_ld -o conftest conftest.o --entry=_start --gc-sections 2>&1 \ | |
24318 | | grep "gc-sections option ignored" > /dev/null; then | |
24319 | gcc_cv_ld_eh_gc_sections=no | |
24320 | elif $gcc_cv_objdump -h conftest | grep gcc_except_table > /dev/null; then | |
24321 | gcc_cv_ld_eh_gc_sections=yes | |
24322 | fi | |
24323 | fi | |
24324 | fi | |
24325 | fi | |
24326 | fi | |
24327 | rm -f conftest.s conftest.o conftest | |
24328 | fi | |
e9d207d9 EB |
24329 | case "$target" in |
24330 | hppa*-*-linux*) | |
24331 | # ??? This apparently exposes a binutils bug with PC-relative relocations. | |
24332 | gcc_cv_ld_eh_gc_sections=no | |
24333 | ;; | |
24334 | esac | |
22ba88ef EB |
24335 | if test x$gcc_cv_ld_eh_gc_sections = xyes; then |
24336 | ||
5213506e | 24337 | $as_echo "#define HAVE_LD_EH_GC_SECTIONS 1" >>confdefs.h |
22ba88ef EB |
24338 | |
24339 | fi | |
5213506e RW |
24340 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_eh_gc_sections" >&5 |
24341 | $as_echo "$gcc_cv_ld_eh_gc_sections" >&6; } | |
22ba88ef | 24342 | |
8bb915b6 NN |
24343 | # -------- |
24344 | # UNSORTED | |
24345 | # -------- | |
24346 | ||
5213506e RW |
24347 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --as-needed support" >&5 |
24348 | $as_echo_n "checking linker --as-needed support... " >&6; } | |
24349 | if test "${gcc_cv_ld_as_needed+set}" = set; then : | |
24350 | $as_echo_n "(cached) " >&6 | |
82e923f6 RS |
24351 | else |
24352 | gcc_cv_ld_as_needed=no | |
765f1bf9 AM |
24353 | if test $in_tree_ld = yes ; then |
24354 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 \ | |
24355 | && test $in_tree_ld_is_elf = yes; then | |
24356 | gcc_cv_ld_as_needed=yes | |
24357 | fi | |
24358 | elif test x$gcc_cv_ld != x; then | |
24359 | # Check if linker supports --as-needed and --no-as-needed options | |
24360 | if $gcc_cv_ld --help 2>/dev/null | grep as-needed > /dev/null; then | |
24361 | gcc_cv_ld_as_needed=yes | |
24362 | fi | |
24363 | fi | |
82e923f6 RS |
24364 | |
24365 | fi | |
5213506e RW |
24366 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_as_needed" >&5 |
24367 | $as_echo "$gcc_cv_ld_as_needed" >&6; } | |
765f1bf9 AM |
24368 | if test x"$gcc_cv_ld_as_needed" = xyes; then |
24369 | ||
5213506e | 24370 | $as_echo "#define HAVE_LD_AS_NEEDED 1" >>confdefs.h |
765f1bf9 AM |
24371 | |
24372 | fi | |
765f1bf9 | 24373 | |
d82bf747 AM |
24374 | case "$target:$tm_file" in |
24375 | powerpc64*-*-linux* | powerpc*-*-linux*rs6000/biarch64.h*) | |
5213506e RW |
24376 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker support for omitting dot symbols" >&5 |
24377 | $as_echo_n "checking linker support for omitting dot symbols... " >&6; } | |
24378 | if test "${gcc_cv_ld_no_dot_syms+set}" = set; then : | |
24379 | $as_echo_n "(cached) " >&6 | |
85b776df AM |
24380 | else |
24381 | gcc_cv_ld_no_dot_syms=no | |
24382 | if test $in_tree_ld = yes ; then | |
24383 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2; then | |
24384 | gcc_cv_ld_no_dot_syms=yes | |
24385 | fi | |
24386 | elif test x$gcc_cv_as != x -a x$gcc_cv_ld != x ; then | |
24387 | cat > conftest1.s <<EOF | |
24388 | .text | |
24389 | bl .foo | |
24390 | EOF | |
24391 | cat > conftest2.s <<EOF | |
24392 | .section ".opd","aw" | |
24393 | .align 3 | |
24394 | .globl foo | |
24395 | .type foo,@function | |
24396 | foo: | |
24397 | .quad .LEfoo,.TOC.@tocbase,0 | |
24398 | .text | |
24399 | .LEfoo: | |
24400 | blr | |
24401 | .size foo,.-.LEfoo | |
24402 | EOF | |
24403 | if $gcc_cv_as -a64 -o conftest1.o conftest1.s > /dev/null 2>&1 \ | |
24404 | && $gcc_cv_as -a64 -o conftest2.o conftest2.s > /dev/null 2>&1 \ | |
24405 | && $gcc_cv_ld -melf64ppc -o conftest conftest1.o conftest2.o > /dev/null 2>&1; then | |
24406 | gcc_cv_ld_no_dot_syms=yes | |
24407 | fi | |
24408 | rm -f conftest conftest1.o conftest2.o conftest1.s conftest2.s | |
24409 | fi | |
24410 | ||
24411 | fi | |
5213506e RW |
24412 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_no_dot_syms" >&5 |
24413 | $as_echo "$gcc_cv_ld_no_dot_syms" >&6; } | |
85b776df AM |
24414 | if test x"$gcc_cv_ld_no_dot_syms" = xyes; then |
24415 | ||
5213506e | 24416 | $as_echo "#define HAVE_LD_NO_DOT_SYMS 1" >>confdefs.h |
85b776df AM |
24417 | |
24418 | fi | |
24419 | ;; | |
24420 | esac | |
24421 | ||
5213506e RW |
24422 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --build-id support" >&5 |
24423 | $as_echo_n "checking linker --build-id support... " >&6; } | |
24424 | if test "${gcc_cv_ld_buildid+set}" = set; then : | |
24425 | $as_echo_n "(cached) " >&6 | |
cd533689 PP |
24426 | else |
24427 | gcc_cv_ld_buildid=no | |
24428 | if test $in_tree_ld = yes ; then | |
24429 | if test "$gcc_cv_gld_major_version" -eq 2 -a \ | |
24430 | "$gcc_cv_gld_minor_version" -ge 18 -o \ | |
24431 | "$gcc_cv_gld_major_version" -gt 2 \ | |
24432 | && test $in_tree_ld_is_elf = yes; then | |
24433 | gcc_cv_ld_buildid=yes | |
24434 | fi | |
24435 | elif test x$gcc_cv_ld != x; then | |
24436 | if $gcc_cv_ld --help 2>/dev/null | grep build-id > /dev/null; then | |
24437 | gcc_cv_ld_buildid=yes | |
24438 | fi | |
24439 | fi | |
24440 | fi | |
5213506e RW |
24441 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_buildid" >&5 |
24442 | $as_echo "$gcc_cv_ld_buildid" >&6; } | |
cd533689 PP |
24443 | if test x"$gcc_cv_ld_buildid" = xyes; then |
24444 | ||
5213506e | 24445 | $as_echo "#define HAVE_LD_BUILDID 1" >>confdefs.h |
cd533689 PP |
24446 | |
24447 | fi | |
24448 | ||
5213506e RW |
24449 | # Check whether --enable-linker-build-id was given. |
24450 | if test "${enable_linker_build_id+set}" = set; then : | |
24451 | enableval=$enable_linker_build_id; | |
cd533689 PP |
24452 | else |
24453 | enable_linker_build_id=no | |
5213506e RW |
24454 | fi |
24455 | ||
cd533689 PP |
24456 | |
24457 | if test x"$enable_linker_build_id" = xyes; then | |
24458 | if test x"$gcc_cv_ld_buildid" = xyes; then | |
24459 | ||
5213506e | 24460 | $as_echo "#define ENABLE_LD_BUILDID 1" >>confdefs.h |
cd533689 PP |
24461 | |
24462 | else | |
5213506e RW |
24463 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --build-id is not supported by your linker; --enable-linker-build-id ignored" >&5 |
24464 | $as_echo "$as_me: WARNING: --build-id is not supported by your linker; --enable-linker-build-id ignored" >&2;} | |
cd533689 PP |
24465 | fi |
24466 | fi | |
24467 | ||
5213506e RW |
24468 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking linker --sysroot support" >&5 |
24469 | $as_echo_n "checking linker --sysroot support... " >&6; } | |
24470 | if test "${gcc_cv_ld_sysroot+set}" = set; then : | |
24471 | $as_echo_n "(cached) " >&6 | |
380e5ca4 MM |
24472 | else |
24473 | gcc_cv_ld_sysroot=no | |
24474 | if test $in_tree_ld = yes ; then | |
24475 | if test "$gcc_cv_gld_major_version" -eq 2 -a "$gcc_cv_gld_minor_version" -ge 16 -o "$gcc_cv_gld_major_version" -gt 2 ; then | |
7032df40 | 24476 | gcc_cv_ld_sysroot=yes |
380e5ca4 MM |
24477 | fi |
24478 | elif test x$gcc_cv_ld != x; then | |
24479 | if $gcc_cv_ld --help 2>/dev/null | grep sysroot > /dev/null; then | |
24480 | gcc_cv_ld_sysroot=yes | |
24481 | fi | |
24482 | fi | |
24483 | fi | |
5213506e RW |
24484 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_ld_sysroot" >&5 |
24485 | $as_echo "$gcc_cv_ld_sysroot" >&6; } | |
380e5ca4 MM |
24486 | if test x"$gcc_cv_ld_sysroot" = xyes; then |
24487 | ||
5213506e | 24488 | $as_echo "#define HAVE_LD_SYSROOT 1" >>confdefs.h |
380e5ca4 MM |
24489 | |
24490 | fi | |
24491 | ||
9fb28a67 | 24492 | if test x$with_sysroot = x && test x$host = x$target \ |
c794c06f CD |
24493 | && test "$prefix" != "/usr" && test "x$prefix" != "x$local_prefix" \ |
24494 | && test "$prefix" != "NONE"; then | |
ba479fd2 NN |
24495 | |
24496 | cat >>confdefs.h <<_ACEOF | |
793e9558 | 24497 | #define PREFIX_INCLUDE_DIR "$prefix/include" |
ba479fd2 | 24498 | _ACEOF |
793e9558 PB |
24499 | |
24500 | fi | |
24501 | ||
77008252 | 24502 | # Test for stack protector support in target C library. |
5213506e RW |
24503 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking __stack_chk_fail in target C library" >&5 |
24504 | $as_echo_n "checking __stack_chk_fail in target C library... " >&6; } | |
24505 | if test "${gcc_cv_libc_provides_ssp+set}" = set; then : | |
24506 | $as_echo_n "(cached) " >&6 | |
77008252 JJ |
24507 | else |
24508 | gcc_cv_libc_provides_ssp=no | |
a6ccdbab | 24509 | case "$target" in |
22f96a0f | 24510 | *-*-linux* | *-*-kfreebsd*-gnu | *-*-knetbsd*-gnu) |
77008252 JJ |
24511 | if test x$host != x$target || test "x$TARGET_SYSTEM_ROOT" != x; then |
24512 | if test "x$with_sysroot" = x; then | |
24513 | glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-include" | |
c9ecbf86 JM |
24514 | elif test "x$with_build_sysroot" != "x"; then |
24515 | glibc_header_dir="${with_build_sysroot}/usr/include" | |
77008252 JJ |
24516 | elif test "x$with_sysroot" = xyes; then |
24517 | glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-root/usr/include" | |
24518 | else | |
24519 | glibc_header_dir="${with_sysroot}/usr/include" | |
24520 | fi | |
24521 | else | |
24522 | glibc_header_dir=/usr/include | |
24523 | fi | |
24524 | # glibc 2.4 and later provides __stack_chk_fail and | |
24525 | # either __stack_chk_guard, or TLS access to stack guard canary. | |
24526 | if test -f $glibc_header_dir/features.h \ | |
24527 | && $EGREP '^[ ]*#[ ]*define[ ]+__GNU_LIBRARY__[ ]+([1-9][0-9]|[6-9])' \ | |
24528 | $glibc_header_dir/features.h > /dev/null; then | |
24529 | if $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC__[ ]+([1-9][0-9]|[3-9])' \ | |
24530 | $glibc_header_dir/features.h > /dev/null; then | |
24531 | gcc_cv_libc_provides_ssp=yes | |
24532 | elif $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC__[ ]+2' \ | |
24533 | $glibc_header_dir/features.h > /dev/null \ | |
24534 | && $EGREP '^[ ]*#[ ]*define[ ]+__GLIBC_MINOR__[ ]+([1-9][0-9]|[4-9])' \ | |
24535 | $glibc_header_dir/features.h > /dev/null; then | |
24536 | gcc_cv_libc_provides_ssp=yes | |
fed6d628 BF |
24537 | elif $EGREP '^[ ]*#[ ]*define[ ]+__UCLIBC__[ ]+1' \ |
24538 | $glibc_header_dir/features.h > /dev/null && \ | |
24539 | test -f $glibc_header_dir/bits/uClibc_config.h && \ | |
24540 | $EGREP '^[ ]*#[ ]*define[ ]+__UCLIBC_HAS_SSP__[ ]+1' \ | |
24541 | $glibc_header_dir/bits/uClibc_config.h > /dev/null; then | |
24542 | gcc_cv_libc_provides_ssp=yes | |
77008252 | 24543 | fi |
fed6d628 | 24544 | fi |
a6ccdbab | 24545 | ;; |
4cc115a2 TS |
24546 | *-*-gnu*) |
24547 | # Avoid complicated tests (see | |
24548 | # <http://gcc.gnu.org/ml/gcc/2008-10/msg00130.html>) and for now | |
24549 | # simply assert that glibc does provide this, which is true for all | |
24550 | # realistically usable GNU/Hurd configurations. | |
24551 | gcc_cv_libc_provides_ssp=yes;; | |
61e1d511 | 24552 | *-*-darwin* | *-*-freebsd*) |
5213506e RW |
24553 | ac_fn_c_check_func "$LINENO" "__stack_chk_fail" "ac_cv_func___stack_chk_fail" |
24554 | if test "x$ac_cv_func___stack_chk_fail" = x""yes; then : | |
a6ccdbab EC |
24555 | gcc_cv_libc_provides_ssp=yes |
24556 | else | |
24557 | echo "no __stack_chk_fail on this target" | |
77008252 | 24558 | fi |
a6ccdbab EC |
24559 | |
24560 | ;; | |
77008252 | 24561 | *) gcc_cv_libc_provides_ssp=no ;; |
a6ccdbab EC |
24562 | esac |
24563 | fi | |
5213506e RW |
24564 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $gcc_cv_libc_provides_ssp" >&5 |
24565 | $as_echo "$gcc_cv_libc_provides_ssp" >&6; } | |
a6ccdbab | 24566 | |
77008252 JJ |
24567 | if test x$gcc_cv_libc_provides_ssp = xyes; then |
24568 | ||
5213506e | 24569 | $as_echo "#define TARGET_LIBC_PROVIDES_SSP 1" >>confdefs.h |
77008252 JJ |
24570 | |
24571 | fi | |
24572 | ||
ed965309 JJ |
24573 | # Check if TFmode long double should be used by default or not. |
24574 | # Some glibc targets used DFmode long double, but with glibc 2.4 | |
24575 | # and later they can use TFmode. | |
24576 | case "$target" in | |
f7cc5390 JM |
24577 | powerpc*-*-linux* | \ |
24578 | powerpc*-*-gnu* | \ | |
ed965309 JJ |
24579 | sparc*-*-linux* | \ |
24580 | s390*-*-linux* | \ | |
24581 | alpha*-*-linux*) | |
24582 | ||
5213506e RW |
24583 | # Check whether --with-long-double-128 was given. |
24584 | if test "${with_long_double_128+set}" = set; then : | |
24585 | withval=$with_long_double_128; gcc_cv_target_ldbl128="$with_long_double_128" | |
ed965309 JJ |
24586 | else |
24587 | gcc_cv_target_ldbl128=no | |
24588 | if test x$host != x$target || test "x$TARGET_SYSTEM_ROOT" != x; then | |
24589 | if test "x$with_sysroot" = x; then | |
24590 | glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-include" | |
c9ecbf86 JM |
24591 | elif test "x$with_build_sysroot" != "x"; then |
24592 | glibc_header_dir="${with_build_sysroot}/usr/include" | |
ed965309 JJ |
24593 | elif test "x$with_sysroot" = xyes; then |
24594 | glibc_header_dir="${exec_prefix}/${target_noncanonical}/sys-root/usr/include" | |
24595 | else | |
24596 | glibc_header_dir="${with_sysroot}/usr/include" | |
24597 | fi | |
24598 | else | |
24599 | glibc_header_dir=/usr/include | |
24600 | fi | |
65280f6c | 24601 | grep '^[ ]*#[ ]*define[ ][ ]*__LONG_DOUBLE_MATH_OPTIONAL' \ |
ed965309 JJ |
24602 | $glibc_header_dir/bits/wordsize.h > /dev/null 2>&1 \ |
24603 | && gcc_cv_target_ldbl128=yes | |
65280f6c | 24604 | |
5213506e RW |
24605 | fi |
24606 | ||
ed965309 JJ |
24607 | ;; |
24608 | esac | |
24609 | if test x$gcc_cv_target_ldbl128 = xyes; then | |
24610 | ||
5213506e | 24611 | $as_echo "#define TARGET_DEFAULT_LONG_DOUBLE_128 1" >>confdefs.h |
ed965309 JJ |
24612 | |
24613 | fi | |
24614 | ||
81bf3d9e | 24615 | # Find out what GC implementation we want, or may, use. |
ba479fd2 | 24616 | |
5213506e RW |
24617 | # Check whether --with-gc was given. |
24618 | if test "${with_gc+set}" = set; then : | |
24619 | withval=$with_gc; case "$withval" in | |
08cee789 | 24620 | page) |
81bf3d9e | 24621 | GGC=ggc-$withval |
08cee789 DJ |
24622 | ;; |
24623 | zone) | |
24624 | GGC=ggc-$withval | |
24625 | ||
5213506e | 24626 | $as_echo "#define GGC_ZONE 1" >>confdefs.h |
08cee789 | 24627 | |
81bf3d9e RH |
24628 | ;; |
24629 | *) | |
5213506e | 24630 | as_fn_error "$withval is an invalid option to --with-gc" "$LINENO" 5 |
81bf3d9e RH |
24631 | ;; |
24632 | esac | |
24633 | else | |
005537df | 24634 | GGC=ggc-page |
5213506e RW |
24635 | fi |
24636 | ||
81bf3d9e RH |
24637 | |
24638 | echo "Using $GGC for garbage collection." | |
24639 | ||
00020c16 ILT |
24640 | # Libraries to use on the host. This will normally be set by the top |
24641 | # level Makefile. Here we simply capture the value for our Makefile. | |
24642 | if test -z "${HOST_LIBS+set}"; then | |
24643 | HOST_LIBS= | |
24644 | fi | |
24645 | ||
24646 | ||
3c809ba4 | 24647 | # Use the system's zlib library. |
b8dad04b ZW |
24648 | zlibdir=-L../zlib |
24649 | zlibinc="-I\$(srcdir)/../zlib" | |
ba479fd2 | 24650 | |
5213506e RW |
24651 | # Check whether --with-system-zlib was given. |
24652 | if test "${with_system_zlib+set}" = set; then : | |
24653 | withval=$with_system_zlib; zlibdir= | |
3c809ba4 AG |
24654 | zlibinc= |
24655 | ||
5213506e RW |
24656 | fi |
24657 | ||
b8ec3cc8 | 24658 | |
703d89ab | 24659 | |
ab22c1fa | 24660 | |
1a4b763e | 24661 | |
5213506e RW |
24662 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to enable maintainer-specific portions of Makefiles" >&5 |
24663 | $as_echo_n "checking whether to enable maintainer-specific portions of Makefiles... " >&6; } | |
24664 | # Check whether --enable-maintainer-mode was given. | |
24665 | if test "${enable_maintainer_mode+set}" = set; then : | |
24666 | enableval=$enable_maintainer_mode; maintainer_mode=$enableval | |
dc6746e7 PT |
24667 | else |
24668 | maintainer_mode=no | |
5213506e | 24669 | fi |
a6ccdbab | 24670 | |
5213506e RW |
24671 | |
24672 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $maintainer_mode" >&5 | |
24673 | $as_echo "$maintainer_mode" >&6; } | |
dc6746e7 PT |
24674 | |
24675 | if test "$maintainer_mode" = "yes"; then | |
24676 | MAINT='' | |
24677 | else | |
24678 | MAINT='#' | |
24679 | fi | |
24680 | ||
8bb915b6 NN |
24681 | # -------------- |
24682 | # Language hooks | |
24683 | # -------------- | |
24684 | ||
861bb6c1 JL |
24685 | # Make empty files to contain the specs and options for each language. |
24686 | # Then add #include lines to for a compiler that has specs and/or options. | |
24687 | ||
cc11cc9b | 24688 | subdirs= |
d7b42618 | 24689 | lang_opt_files= |
861bb6c1 | 24690 | lang_specs_files= |
3103b7db | 24691 | lang_tree_files= |
861bb6c1 JL |
24692 | # These (without "all_") are set in each config-lang.in. |
24693 | # `language' must be a single word so is spelled singularly. | |
24694 | all_languages= | |
861bb6c1 | 24695 | all_compilers= |
47ad7893 | 24696 | all_outputs='Makefile gccbug' |
861bb6c1 | 24697 | # List of language makefile fragments. |
2ed26f6b ZW |
24698 | all_lang_makefrags= |
24699 | # List of language subdirectory makefiles. Deprecated. | |
861bb6c1 | 24700 | all_lang_makefiles= |
703d89ab | 24701 | # Additional files for gengtype |
ef69da62 | 24702 | all_gtfiles="$target_gtfiles" |
861bb6c1 | 24703 | |
cc11cc9b PB |
24704 | # These are the languages that are set in --enable-languages, |
24705 | # and are available in the GCC tree. | |
24706 | all_selected_languages= | |
24707 | ||
861bb6c1 JL |
24708 | # Add the language fragments. |
24709 | # Languages are added via two mechanisms. Some information must be | |
24710 | # recorded in makefile variables, these are defined in config-lang.in. | |
24711 | # We accumulate them and plug them into the main Makefile. | |
24712 | # The other mechanism is a set of hooks for each of the main targets | |
24713 | # like `clean', `install', etc. | |
24714 | ||
861bb6c1 | 24715 | language_hooks="Make-hooks" |
861bb6c1 | 24716 | |
cc11cc9b | 24717 | for lang in ${srcdir}/*/config-lang.in |
861bb6c1 | 24718 | do |
1546bb64 PB |
24719 | test "$lang" = "${srcdir}/*/config-lang.in" && continue |
24720 | ||
cc11cc9b PB |
24721 | lang_alias=`sed -n -e 's,^language=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^language=\([^ ]*\).*$,\1,p' $lang` |
24722 | if test "x$lang_alias" = x | |
24723 | then | |
24724 | echo "$lang doesn't set \$language." 1>&2 | |
24725 | exit 1 | |
24726 | fi | |
24727 | subdir="`echo $lang | sed -e 's,^.*/\([^/]*\)/config-lang.in$,\1,'`" | |
24728 | subdirs="$subdirs $subdir" | |
349c3166 OH |
24729 | |
24730 | # $gcc_subdir is where the gcc integration files are to be found | |
24731 | # for a language, both for internal compiler purposes (compiler | |
24732 | # sources implementing front-end to GCC tree converters), and for | |
24733 | # build infrastructure purposes (Make-lang.in, etc.) | |
24734 | # | |
24735 | # This will be <subdir> (relative to $srcdir) if a line like | |
24736 | # gcc_subdir="<subdir>" or gcc_subdir=<subdir> | |
24737 | # is found in <langdir>/config-lang.in, and will remain <langdir> | |
24738 | # otherwise. | |
24739 | # | |
24740 | # Except for the language alias (fetched above), the regular | |
24741 | # "config-lang.in" contents are always retrieved from $gcc_subdir, | |
24742 | # so a <langdir>/config-lang.in setting gcc_subdir typically sets | |
24743 | # only this and the language alias. | |
24744 | ||
24745 | gcc_subdir=`sed -n -e 's,^gcc_subdir=['"'"'"'"]\(.*\)["'"'"'"'].*$,\1,p' -e 's,^gcc_subdir=\([^ ]*\).*$,\1,p' $lang` | |
24746 | if [ "$gcc_subdir" = "" ]; then | |
24747 | gcc_subdir="$subdir" | |
24748 | fi | |
24749 | ||
cc11cc9b PB |
24750 | case ",$enable_languages," in |
24751 | *,$lang_alias,*) | |
24752 | all_selected_languages="$all_selected_languages $lang_alias" | |
349c3166 OH |
24753 | if test -f $srcdir/$gcc_subdir/lang-specs.h; then |
24754 | lang_specs_files="$lang_specs_files $srcdir/$gcc_subdir/lang-specs.h" | |
cc11cc9b PB |
24755 | fi |
24756 | ;; | |
24757 | esac | |
24758 | ||
cc11cc9b PB |
24759 | language= |
24760 | boot_language= | |
24761 | compilers= | |
cc11cc9b PB |
24762 | outputs= |
24763 | gtfiles= | |
1546bb64 | 24764 | subdir_requires= |
349c3166 | 24765 | . ${srcdir}/$gcc_subdir/config-lang.in |
cc11cc9b PB |
24766 | if test "x$language" = x |
24767 | then | |
349c3166 | 24768 | echo "${srcdir}/$gcc_subdir/config-lang.in doesn't set \$language." 1>&2 |
cc11cc9b PB |
24769 | exit 1 |
24770 | fi | |
1546bb64 PB |
24771 | |
24772 | ok=: | |
24773 | case ",$enable_languages," in | |
24774 | *,$lang_alias,*) ;; | |
24775 | *) | |
24776 | for i in $subdir_requires; do | |
b6348cb3 | 24777 | test -f "${srcdir}/$i/config-lang.in" && continue |
1546bb64 PB |
24778 | ok=false |
24779 | break | |
24780 | done | |
24781 | ;; | |
24782 | esac | |
24783 | $ok || continue | |
24784 | ||
349c3166 OH |
24785 | all_lang_makefrags="$all_lang_makefrags \$(srcdir)/$gcc_subdir/Make-lang.in" |
24786 | if test -f $srcdir/$gcc_subdir/lang.opt; then | |
24787 | lang_opt_files="$lang_opt_files $srcdir/$gcc_subdir/lang.opt" | |
1546bb64 | 24788 | fi |
349c3166 OH |
24789 | if test -f $srcdir/$gcc_subdir/$subdir-tree.def; then |
24790 | lang_tree_files="$lang_tree_files $srcdir/$gcc_subdir/$subdir-tree.def" | |
1546bb64 | 24791 | fi |
349c3166 OH |
24792 | if test -f ${srcdir}/$gcc_subdir/Makefile.in |
24793 | then all_lang_makefiles="$gcc_subdir/Makefile" | |
cc11cc9b PB |
24794 | fi |
24795 | all_languages="$all_languages $language" | |
cc11cc9b | 24796 | all_compilers="$all_compilers $compilers" |
cc11cc9b | 24797 | all_outputs="$all_outputs $outputs" |
703d89ab | 24798 | all_gtfiles="$all_gtfiles [$subdir] $gtfiles" |
d7f09764 DN |
24799 | case ",$enable_languages," in |
24800 | *,lto,*) | |
24801 | ||
24802 | $as_echo "#define ENABLE_LTO 1" >>confdefs.h | |
24803 | ||
24804 | enable_lto=yes | |
24805 | ||
24806 | ;; | |
24807 | *) ;; | |
24808 | esac | |
861bb6c1 JL |
24809 | done |
24810 | ||
8ac9d31f TJ |
24811 | # Pick up gtfiles for c |
24812 | gtfiles= | |
8ac9d31f | 24813 | . ${srcdir}/c-config-lang.in |
703d89ab | 24814 | all_gtfiles="$all_gtfiles [c] $gtfiles" |
8ac9d31f | 24815 | |
cbc59f01 | 24816 | check_languages= |
cc11cc9b | 24817 | for language in $all_selected_languages |
cbc59f01 | 24818 | do |
cc11cc9b | 24819 | check_languages="$check_languages check-$language" |
cbc59f01 DD |
24820 | done |
24821 | ||
62b81e45 | 24822 | # We link each language in with a set of hooks, reached indirectly via |
cc11cc9b | 24823 | # lang.${target}. Only do so for selected languages. |
861bb6c1 JL |
24824 | |
24825 | rm -f Make-hooks | |
24826 | touch Make-hooks | |
bd97af06 | 24827 | target_list="all.cross start.encap rest.encap tags \ |
bcc3d150 BM |
24828 | install-common install-man install-info install-pdf dvi pdf \ |
24829 | html uninstall info man srcextra srcman srcinfo \ | |
2a4c0366 | 24830 | mostlyclean clean distclean maintainer-clean install-plugin" |
cc11cc9b | 24831 | |
861bb6c1 JL |
24832 | for t in $target_list |
24833 | do | |
24834 | x= | |
cc11cc9b | 24835 | for lang in $all_selected_languages |
861bb6c1 | 24836 | do |
cc11cc9b | 24837 | x="$x $lang.$t" |
861bb6c1 JL |
24838 | done |
24839 | echo "lang.$t: $x" >> Make-hooks | |
24840 | done | |
24841 | ||
8bb915b6 NN |
24842 | # -------- |
24843 | # UNSORTED | |
24844 | # -------- | |
24845 | ||
cc06d68c | 24846 | # Create .gdbinit. |
861bb6c1 | 24847 | |
cc06d68c GP |
24848 | echo "dir ." > .gdbinit |
24849 | echo "dir ${srcdir}" >> .gdbinit | |
24850 | if test x$gdb_needs_out_file_path = xyes | |
24851 | then | |
24852 | echo "dir ${srcdir}/config/"`dirname ${out_file}` >> .gdbinit | |
24853 | fi | |
24854 | if test "x$subdirs" != x; then | |
24855 | for s in $subdirs | |
24856 | do | |
24857 | echo "dir ${srcdir}/$s" >> .gdbinit | |
24858 | done | |
861bb6c1 | 24859 | fi |
cc06d68c | 24860 | echo "source ${srcdir}/gdbinit.in" >> .gdbinit |
861bb6c1 | 24861 | |
15c723f3 | 24862 | gcc_tooldir='$(libsubdir)/$(libsubdir_to_prefix)$(target_noncanonical)' |
d062c304 JL |
24863 | |
24864 | ||
2ce3c6c6 | 24865 | |
2bbea3a6 RH |
24866 | # Find a directory in which to install a shared libgcc. |
24867 | ||
5213506e RW |
24868 | # Check whether --enable-version-specific-runtime-libs was given. |
24869 | if test "${enable_version_specific_runtime_libs+set}" = set; then : | |
24870 | enableval=$enable_version_specific_runtime_libs; | |
24871 | fi | |
ba479fd2 | 24872 | |
2bbea3a6 RH |
24873 | |
24874 | ||
5213506e RW |
24875 | # Check whether --with-slibdir was given. |
24876 | if test "${with_slibdir+set}" = set; then : | |
24877 | withval=$with_slibdir; slibdir="$with_slibdir" | |
5b15f277 RH |
24878 | else |
24879 | if test "${enable_version_specific_runtime_libs+set}" = set; then | |
2bbea3a6 | 24880 | slibdir='$(libsubdir)' |
5b15f277 | 24881 | elif test "$host" != "$target"; then |
2bbea3a6 RH |
24882 | slibdir='$(build_tooldir)/lib' |
24883 | else | |
5b15f277 | 24884 | slibdir='$(libdir)' |
2bbea3a6 | 24885 | fi |
5213506e RW |
24886 | fi |
24887 | ||
2bbea3a6 RH |
24888 | |
24889 | ||
703d89ab | 24890 | # Substitute configuration variables |
861bb6c1 JL |
24891 | |
24892 | ||
24893 | ||
24894 | ||
24895 | ||
24896 | ||
24897 | ||
24898 | ||
24899 | ||
24900 | ||
24901 | ||
24902 | ||
24903 | ||
24904 | ||
24905 | ||
24906 | ||
24907 | ||
24908 | ||
24909 | ||
24910 | ||
24911 | ||
24912 | ||
24913 | ||
24914 | ||
24915 | ||
24916 | ||
24917 | ||
24918 | ||
24919 | ||
24920 | ||
24921 | ||
24922 | ||
24923 | ||
24924 | ||
24925 | ||
24926 | ||
24927 | ||
24928 | ||
24929 | ||
24930 | ||
24931 | ||
24932 | ||
24933 | ||
24934 | ||
9b16d2c4 | 24935 | |
e9a25f70 | 24936 | |
6e26218f | 24937 | |
c8724862 | 24938 | |
11642c3a ZW |
24939 | |
24940 | ||
24941 | ||
3d9d2476 | 24942 | |
e2500fed | 24943 | |
a0e527e3 | 24944 | |
aca600aa AS |
24945 | |
24946 | ||
24947 | ||
c776a6d0 | 24948 | |
207bf79d | 24949 | |
51b9ff45 | 24950 | |
861bb6c1 | 24951 | |
6e3f3080 NN |
24952 | # Echo link setup. |
24953 | if test x${build} = x${host} ; then | |
24954 | if test x${host} = x${target} ; then | |
24955 | echo "Links are now set up to build a native compiler for ${target}." 1>&2 | |
24956 | else | |
24957 | echo "Links are now set up to build a cross-compiler" 1>&2 | |
24958 | echo " from ${host} to ${target}." 1>&2 | |
24959 | fi | |
24960 | else | |
24961 | if test x${host} = x${target} ; then | |
24962 | echo "Links are now set up to build (on ${build}) a native compiler" 1>&2 | |
24963 | echo " for ${target}." 1>&2 | |
24964 | else | |
24965 | echo "Links are now set up to build (on ${build}) a cross-compiler" 1>&2 | |
24966 | echo " from ${host} to ${target}." 1>&2 | |
24967 | fi | |
24968 | fi | |
24969 | ||
6de9cd9a DN |
24970 | |
24971 | ||
24972 | ||
f8bf9252 SP |
24973 | |
24974 | ||
24975 | ||
24976 | ||
24977 | ||
24978 | if test "x${CLOOGLIBS}" != "x" ; then | |
24979 | ||
5213506e | 24980 | $as_echo "#define HAVE_cloog 1" >>confdefs.h |
f8bf9252 | 24981 | |
f8bf9252 SP |
24982 | fi |
24983 | ||
d7f09764 DN |
24984 | |
24985 | ||
24986 | if test "x${LIBELFLIBS}" != "x" ; then | |
24987 | ||
24988 | $as_echo "#define HAVE_libelf 1" >>confdefs.h | |
24989 | ||
24990 | fi | |
24991 | ||
68a607d8 | 24992 | # Check for plugin support |
5213506e RW |
24993 | # Check whether --enable-plugin was given. |
24994 | if test "${enable_plugin+set}" = set; then : | |
24995 | enableval=$enable_plugin; enable_plugin=$enableval | |
68a607d8 DN |
24996 | else |
24997 | enable_plugin=yes; default_plugin=yes | |
5213506e RW |
24998 | fi |
24999 | ||
68a607d8 DN |
25000 | |
25001 | pluginlibs= | |
25002 | if test x"$enable_plugin" = x"yes"; then | |
25003 | # Check that the host supports -rdynamic and -ldl | |
25004 | have_rdynamic=no | |
25005 | have_dl=no | |
25006 | saved_LDFLAGS="$LDFLAGS" | |
25007 | saved_LIBS="$LIBS" | |
25008 | LIBS= | |
25009 | ||
25010 | # Check -rdynamic | |
25011 | LDFLAGS="$LDFLAGS -rdynamic" | |
5213506e RW |
25012 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -rdynamic" >&5 |
25013 | $as_echo_n "checking for -rdynamic... " >&6; } | |
25014 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
68a607d8 DN |
25015 | /* end confdefs.h. */ |
25016 | ||
25017 | int | |
25018 | main () | |
25019 | { | |
25020 | return 0; | |
25021 | ; | |
25022 | return 0; | |
25023 | } | |
25024 | _ACEOF | |
5213506e RW |
25025 | if ac_fn_c_try_link "$LINENO"; then : |
25026 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
25027 | $as_echo "yes" >&6; }; have_rdynamic=yes | |
68a607d8 | 25028 | else |
5213506e RW |
25029 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
25030 | $as_echo "no" >&6; } | |
68a607d8 | 25031 | fi |
5213506e RW |
25032 | rm -f core conftest.err conftest.$ac_objext \ |
25033 | conftest$ac_exeext conftest.$ac_ext | |
68a607d8 DN |
25034 | if test x"$have_rdynamic" = x"yes" ; then |
25035 | pluginlibs="-rdynamic" | |
25036 | fi | |
25037 | ||
25038 | # Check -ldl | |
0c2edd9f ILT |
25039 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5 |
25040 | $as_echo_n "checking for library containing dlopen... " >&6; } | |
25041 | if test "${ac_cv_search_dlopen+set}" = set; then : | |
25042 | $as_echo_n "(cached) " >&6 | |
25043 | else | |
25044 | ac_func_search_save_LIBS=$LIBS | |
25045 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
68a607d8 | 25046 | /* end confdefs.h. */ |
0c2edd9f ILT |
25047 | |
25048 | /* Override any GCC internal prototype to avoid an error. | |
25049 | Use char because int might match the return type of a GCC | |
25050 | builtin and then its argument prototype would still apply. */ | |
25051 | #ifdef __cplusplus | |
25052 | extern "C" | |
25053 | #endif | |
25054 | char dlopen (); | |
68a607d8 DN |
25055 | int |
25056 | main () | |
25057 | { | |
0c2edd9f | 25058 | return dlopen (); |
68a607d8 DN |
25059 | ; |
25060 | return 0; | |
25061 | } | |
25062 | _ACEOF | |
0c2edd9f ILT |
25063 | for ac_lib in '' dl; do |
25064 | if test -z "$ac_lib"; then | |
25065 | ac_res="none required" | |
25066 | else | |
25067 | ac_res=-l$ac_lib | |
25068 | LIBS="-l$ac_lib $ac_func_search_save_LIBS" | |
25069 | fi | |
25070 | if ac_fn_c_try_link "$LINENO"; then : | |
25071 | ac_cv_search_dlopen=$ac_res | |
68a607d8 | 25072 | fi |
5213506e | 25073 | rm -f core conftest.err conftest.$ac_objext \ |
0c2edd9f ILT |
25074 | conftest$ac_exeext |
25075 | if test "${ac_cv_search_dlopen+set}" = set; then : | |
25076 | break | |
25077 | fi | |
25078 | done | |
25079 | if test "${ac_cv_search_dlopen+set}" = set; then : | |
25080 | ||
25081 | else | |
25082 | ac_cv_search_dlopen=no | |
25083 | fi | |
25084 | rm conftest.$ac_ext | |
25085 | LIBS=$ac_func_search_save_LIBS | |
25086 | fi | |
25087 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5 | |
25088 | $as_echo "$ac_cv_search_dlopen" >&6; } | |
25089 | ac_res=$ac_cv_search_dlopen | |
25090 | if test "$ac_res" != no; then : | |
25091 | test "$ac_res" = "none required" || LIBS="$ac_res $LIBS" | |
25092 | ||
25093 | fi | |
25094 | ||
25095 | if test x"$ac_cv_search_dlopen" = x"-ldl"; then | |
68a607d8 DN |
25096 | pluginlibs="$pluginlibs -ldl" |
25097 | fi | |
25098 | ||
25099 | # Check that we can build shared objects with -fPIC -shared | |
25100 | LDFLAGS="$LDFLAGS -fPIC -shared" | |
5213506e RW |
25101 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for -fPIC -shared" >&5 |
25102 | $as_echo_n "checking for -fPIC -shared... " >&6; } | |
25103 | cat confdefs.h - <<_ACEOF >conftest.$ac_ext | |
68a607d8 DN |
25104 | /* end confdefs.h. */ |
25105 | extern int X; | |
25106 | int | |
25107 | main () | |
25108 | { | |
25109 | return X == 0; | |
25110 | ; | |
25111 | return 0; | |
25112 | } | |
25113 | _ACEOF | |
5213506e RW |
25114 | if ac_fn_c_try_link "$LINENO"; then : |
25115 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 | |
25116 | $as_echo "yes" >&6; }; have_pic_shared=yes | |
68a607d8 | 25117 | else |
5213506e RW |
25118 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 |
25119 | $as_echo "no" >&6; }; have_pic_shared=no | |
68a607d8 | 25120 | fi |
5213506e RW |
25121 | rm -f core conftest.err conftest.$ac_objext \ |
25122 | conftest$ac_exeext conftest.$ac_ext | |
0c2edd9f | 25123 | if test x"$have_pic_shared" != x"yes" -o x"$ac_cv_search_dlopen" = x"no"; then |
68a607d8 DN |
25124 | pluginlibs= |
25125 | enable_plugin=no | |
25126 | fi | |
25127 | ||
25128 | # If plugin support had been requested but not available, fail. | |
25129 | if test x"$enable_plugin" = x"no" ; then | |
25130 | if test x"$default_plugin" != x"yes"; then | |
5213506e | 25131 | as_fn_error " |
68a607d8 | 25132 | Building GCC with plugin support requires a host that supports |
5213506e | 25133 | -fPIC, -shared, -ldl and -rdynamic." "$LINENO" 5 |
68a607d8 DN |
25134 | fi |
25135 | fi | |
25136 | ||
25137 | LDFLAGS="$saved_LDFLAGS" | |
25138 | LIBS="$saved_LIBS" | |
25139 | fi | |
25140 | ||
25141 | ||
25142 | ||
25143 | if test x"$enable_plugin" = x"yes"; then | |
25144 | ||
5213506e | 25145 | $as_echo "#define ENABLE_PLUGIN 1" >>confdefs.h |
68a607d8 DN |
25146 | |
25147 | fi | |
25148 | ||
6e3f3080 NN |
25149 | # Configure the subdirectories |
25150 | # AC_CONFIG_SUBDIRS($subdirs) | |
25151 | ||
25152 | # Create the Makefile | |
25153 | # and configure language subdirectories | |
5213506e | 25154 | ac_config_files="$ac_config_files $all_outputs" |
914c5af7 NN |
25155 | |
25156 | ||
5213506e | 25157 | ac_config_commands="$ac_config_commands default" |
914c5af7 | 25158 | |
ba479fd2 | 25159 | cat >confcache <<\_ACEOF |
6e3f3080 NN |
25160 | # This file is a shell script that caches the results of configure |
25161 | # tests run on this system so they can be shared between configure | |
ba479fd2 NN |
25162 | # scripts and configure runs, see configure's option --config-cache. |
25163 | # It is not useful on other systems. If it contains results you don't | |
25164 | # want to keep, you may remove or edit it. | |
6e3f3080 | 25165 | # |
ba479fd2 NN |
25166 | # config.status only pays attention to the cache file if you give it |
25167 | # the --recheck option to rerun configure. | |
6e3f3080 | 25168 | # |
ba479fd2 NN |
25169 | # `ac_cv_env_foo' variables (set or unset) will be overridden when |
25170 | # loading this file, other *unset* `ac_cv_foo' will be assigned the | |
25171 | # following values. | |
25172 | ||
25173 | _ACEOF | |
25174 | ||
6e3f3080 NN |
25175 | # The following way of writing the cache mishandles newlines in values, |
25176 | # but we know of no workaround that is simple, portable, and efficient. | |
5213506e | 25177 | # So, we kill variables containing newlines. |
6e3f3080 NN |
25178 | # Ultrix sh set writes to stderr and can't be redirected directly, |
25179 | # and sets the high bit in the cache file unless we assign to the vars. | |
5213506e RW |
25180 | ( |
25181 | for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do | |
25182 | eval ac_val=\$$ac_var | |
25183 | case $ac_val in #( | |
25184 | *${as_nl}*) | |
25185 | case $ac_var in #( | |
25186 | *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 | |
25187 | $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; | |
25188 | esac | |
25189 | case $ac_var in #( | |
25190 | _ | IFS | as_nl) ;; #( | |
25191 | BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( | |
25192 | *) { eval $ac_var=; unset $ac_var;} ;; | |
25193 | esac ;; | |
25194 | esac | |
25195 | done | |
25196 | ||
ba479fd2 | 25197 | (set) 2>&1 | |
5213506e RW |
25198 | case $as_nl`(ac_space=' '; set) 2>&1` in #( |
25199 | *${as_nl}ac_space=\ *) | |
25200 | # `set' does not quote correctly, so add quotes: double-quote | |
25201 | # substitution turns \\\\ into \\, and sed turns \\ into \. | |
ba479fd2 | 25202 | sed -n \ |
86da66b5 HPN |
25203 | "s/'/'\\\\''/g; |
25204 | s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" | |
5213506e | 25205 | ;; #( |
ba479fd2 NN |
25206 | *) |
25207 | # `set' quotes correctly as required by POSIX, so do not add quotes. | |
5213506e | 25208 | sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" |
ba479fd2 | 25209 | ;; |
5213506e RW |
25210 | esac | |
25211 | sort | |
25212 | ) | | |
ba479fd2 | 25213 | sed ' |
5213506e | 25214 | /^ac_cv_env_/b end |
ba479fd2 | 25215 | t clear |
5213506e | 25216 | :clear |
ba479fd2 NN |
25217 | s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ |
25218 | t end | |
5213506e RW |
25219 | s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ |
25220 | :end' >>confcache | |
25221 | if diff "$cache_file" confcache >/dev/null 2>&1; then :; else | |
25222 | if test -w "$cache_file"; then | |
25223 | test "x$cache_file" != "x/dev/null" && | |
25224 | { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 | |
25225 | $as_echo "$as_me: updating cache $cache_file" >&6;} | |
ba479fd2 | 25226 | cat confcache >$cache_file |
6e3f3080 | 25227 | else |
5213506e RW |
25228 | { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 |
25229 | $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} | |
6e3f3080 NN |
25230 | fi |
25231 | fi | |
25232 | rm -f confcache | |
25233 | ||
25234 | test "x$prefix" = xNONE && prefix=$ac_default_prefix | |
25235 | # Let make expand exec_prefix. | |
25236 | test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' | |
25237 | ||
63cf211a | 25238 | DEFS=-DHAVE_CONFIG_H |
6e3f3080 | 25239 | |
ba479fd2 NN |
25240 | ac_libobjs= |
25241 | ac_ltlibobjs= | |
25242 | for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue | |
25243 | # 1. Remove the extension, and $U if already installed. | |
5213506e RW |
25244 | ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' |
25245 | ac_i=`$as_echo "$ac_i" | sed "$ac_script"` | |
25246 | # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR | |
25247 | # will be set to the directory where LIBOBJS objects are built. | |
25248 | as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" | |
25249 | as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' | |
ba479fd2 NN |
25250 | done |
25251 | LIBOBJS=$ac_libobjs | |
63cf211a | 25252 | |
ba479fd2 NN |
25253 | LTLIBOBJS=$ac_ltlibobjs |
25254 | ||
25255 | ||
25256 | ||
5213506e | 25257 | |
ba479fd2 | 25258 | : ${CONFIG_STATUS=./config.status} |
5213506e | 25259 | ac_write_fail=0 |
ba479fd2 NN |
25260 | ac_clean_files_save=$ac_clean_files |
25261 | ac_clean_files="$ac_clean_files $CONFIG_STATUS" | |
5213506e RW |
25262 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 |
25263 | $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} | |
25264 | as_write_fail=0 | |
25265 | cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 | |
ba479fd2 NN |
25266 | #! $SHELL |
25267 | # Generated by $as_me. | |
6e3f3080 NN |
25268 | # Run this file to recreate the current configuration. |
25269 | # Compiler output produced by configure, useful for debugging | |
ba479fd2 | 25270 | # configure, is in config.log if it exists. |
6e3f3080 | 25271 | |
ba479fd2 NN |
25272 | debug=false |
25273 | ac_cs_recheck=false | |
25274 | ac_cs_silent=false | |
ba479fd2 | 25275 | |
5213506e RW |
25276 | SHELL=\${CONFIG_SHELL-$SHELL} |
25277 | export SHELL | |
25278 | _ASEOF | |
25279 | cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 | |
25280 | ## -------------------- ## | |
25281 | ## M4sh Initialization. ## | |
25282 | ## -------------------- ## | |
ba479fd2 | 25283 | |
5213506e RW |
25284 | # Be more Bourne compatible |
25285 | DUALCASE=1; export DUALCASE # for MKS sh | |
25286 | if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : | |
ba479fd2 NN |
25287 | emulate sh |
25288 | NULLCMD=: | |
5213506e | 25289 | # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which |
ba479fd2 NN |
25290 | # is contrary to our usage. Disable this feature. |
25291 | alias -g '${1+"$@"}'='"$@"' | |
5213506e RW |
25292 | setopt NO_GLOB_SUBST |
25293 | else | |
25294 | case `(set -o) 2>/dev/null` in #( | |
25295 | *posix*) : | |
25296 | set -o posix ;; #( | |
25297 | *) : | |
25298 | ;; | |
25299 | esac | |
2f41c1d6 | 25300 | fi |
ab22c1fa | 25301 | |
5213506e RW |
25302 | |
25303 | as_nl=' | |
25304 | ' | |
25305 | export as_nl | |
25306 | # Printing a long string crashes Solaris 7 /usr/bin/printf. | |
25307 | as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' | |
25308 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo | |
25309 | as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo | |
25310 | # Prefer a ksh shell builtin over an external printf program on Solaris, | |
25311 | # but without wasting forks for bash or zsh. | |
25312 | if test -z "$BASH_VERSION$ZSH_VERSION" \ | |
25313 | && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then | |
25314 | as_echo='print -r --' | |
25315 | as_echo_n='print -rn --' | |
25316 | elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then | |
25317 | as_echo='printf %s\n' | |
25318 | as_echo_n='printf %s' | |
25319 | else | |
25320 | if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then | |
25321 | as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' | |
25322 | as_echo_n='/usr/ucb/echo -n' | |
25323 | else | |
25324 | as_echo_body='eval expr "X$1" : "X\\(.*\\)"' | |
25325 | as_echo_n_body='eval | |
25326 | arg=$1; | |
25327 | case $arg in #( | |
25328 | *"$as_nl"*) | |
25329 | expr "X$arg" : "X\\(.*\\)$as_nl"; | |
25330 | arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; | |
25331 | esac; | |
25332 | expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" | |
25333 | ' | |
25334 | export as_echo_n_body | |
25335 | as_echo_n='sh -c $as_echo_n_body as_echo' | |
25336 | fi | |
25337 | export as_echo_body | |
25338 | as_echo='sh -c $as_echo_body as_echo' | |
25339 | fi | |
25340 | ||
25341 | # The user is always right. | |
25342 | if test "${PATH_SEPARATOR+set}" != set; then | |
25343 | PATH_SEPARATOR=: | |
25344 | (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { | |
25345 | (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || | |
25346 | PATH_SEPARATOR=';' | |
25347 | } | |
1a4b763e BS |
25348 | fi |
25349 | ||
ab22c1fa | 25350 | |
5213506e RW |
25351 | # IFS |
25352 | # We need space, tab and new line, in precisely that order. Quoting is | |
25353 | # there to prevent editors from complaining about space-tab. | |
25354 | # (If _AS_PATH_WALK were called with IFS unset, it would disable word | |
25355 | # splitting by setting IFS to empty value.) | |
25356 | IFS=" "" $as_nl" | |
25357 | ||
25358 | # Find who we are. Look in the path if we contain no directory separator. | |
25359 | case $0 in #(( | |
25360 | *[\\/]* ) as_myself=$0 ;; | |
25361 | *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | |
25362 | for as_dir in $PATH | |
25363 | do | |
25364 | IFS=$as_save_IFS | |
25365 | test -z "$as_dir" && as_dir=. | |
25366 | test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break | |
25367 | done | |
25368 | IFS=$as_save_IFS | |
25369 | ||
25370 | ;; | |
25371 | esac | |
25372 | # We did not find ourselves, most probably we were run as `sh COMMAND' | |
25373 | # in which case we are not to be found in the path. | |
25374 | if test "x$as_myself" = x; then | |
25375 | as_myself=$0 | |
25376 | fi | |
25377 | if test ! -f "$as_myself"; then | |
25378 | $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 | |
25379 | exit 1 | |
25380 | fi | |
25381 | ||
25382 | # Unset variables that we do not need and which cause bugs (e.g. in | |
25383 | # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" | |
25384 | # suppresses any "Segmentation fault" message there. '((' could | |
25385 | # trigger a bug in pdksh 5.2.14. | |
25386 | for as_var in BASH_ENV ENV MAIL MAILPATH | |
25387 | do eval test x\${$as_var+set} = xset \ | |
25388 | && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : | |
25389 | done | |
1a4b763e BS |
25390 | PS1='$ ' |
25391 | PS2='> ' | |
25392 | PS4='+ ' | |
25393 | ||
25394 | # NLS nuisances. | |
5213506e RW |
25395 | LC_ALL=C |
25396 | export LC_ALL | |
25397 | LANGUAGE=C | |
25398 | export LANGUAGE | |
25399 | ||
25400 | # CDPATH. | |
25401 | (unset CDPATH) >/dev/null 2>&1 && unset CDPATH | |
25402 | ||
25403 | ||
25404 | # as_fn_error ERROR [LINENO LOG_FD] | |
25405 | # --------------------------------- | |
25406 | # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are | |
25407 | # provided, also output the error to LOG_FD, referencing LINENO. Then exit the | |
25408 | # script with status $?, using 1 if that was 0. | |
25409 | as_fn_error () | |
25410 | { | |
25411 | as_status=$?; test $as_status -eq 0 && as_status=1 | |
25412 | if test "$3"; then | |
25413 | as_lineno=${as_lineno-"$2"} as_lineno_stack=as_lineno_stack=$as_lineno_stack | |
25414 | $as_echo "$as_me:${as_lineno-$LINENO}: error: $1" >&$3 | |
1a4b763e | 25415 | fi |
5213506e RW |
25416 | $as_echo "$as_me: error: $1" >&2 |
25417 | as_fn_exit $as_status | |
25418 | } # as_fn_error | |
25419 | ||
25420 | ||
25421 | # as_fn_set_status STATUS | |
25422 | # ----------------------- | |
25423 | # Set $? to STATUS, without forking. | |
25424 | as_fn_set_status () | |
25425 | { | |
25426 | return $1 | |
25427 | } # as_fn_set_status | |
25428 | ||
25429 | # as_fn_exit STATUS | |
25430 | # ----------------- | |
25431 | # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. | |
25432 | as_fn_exit () | |
25433 | { | |
25434 | set +e | |
25435 | as_fn_set_status $1 | |
25436 | exit $1 | |
25437 | } # as_fn_exit | |
25438 | ||
25439 | # as_fn_unset VAR | |
25440 | # --------------- | |
25441 | # Portably unset VAR. | |
25442 | as_fn_unset () | |
25443 | { | |
25444 | { eval $1=; unset $1;} | |
25445 | } | |
25446 | as_unset=as_fn_unset | |
25447 | # as_fn_append VAR VALUE | |
25448 | # ---------------------- | |
25449 | # Append the text in VALUE to the end of the definition contained in VAR. Take | |
25450 | # advantage of any shell optimizations that allow amortized linear growth over | |
25451 | # repeated appends, instead of the typical quadratic growth present in naive | |
25452 | # implementations. | |
25453 | if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : | |
25454 | eval 'as_fn_append () | |
25455 | { | |
25456 | eval $1+=\$2 | |
25457 | }' | |
25458 | else | |
25459 | as_fn_append () | |
25460 | { | |
25461 | eval $1=\$$1\$2 | |
25462 | } | |
25463 | fi # as_fn_append | |
25464 | ||
25465 | # as_fn_arith ARG... | |
25466 | # ------------------ | |
25467 | # Perform arithmetic evaluation on the ARGs, and store the result in the | |
25468 | # global $as_val. Take advantage of shells that can avoid forks. The arguments | |
25469 | # must be portable across $(()) and expr. | |
25470 | if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : | |
25471 | eval 'as_fn_arith () | |
25472 | { | |
25473 | as_val=$(( $* )) | |
25474 | }' | |
25475 | else | |
25476 | as_fn_arith () | |
25477 | { | |
25478 | as_val=`expr "$@" || test $? -eq 1` | |
25479 | } | |
25480 | fi # as_fn_arith | |
1a4b763e | 25481 | |
5213506e RW |
25482 | |
25483 | if expr a : '\(a\)' >/dev/null 2>&1 && | |
25484 | test "X`expr 00001 : '.*\(...\)'`" = X001; then | |
1a4b763e BS |
25485 | as_expr=expr |
25486 | else | |
25487 | as_expr=false | |
25488 | fi | |
25489 | ||
5213506e | 25490 | if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then |
1a4b763e BS |
25491 | as_basename=basename |
25492 | else | |
25493 | as_basename=false | |
25494 | fi | |
25495 | ||
5213506e RW |
25496 | if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then |
25497 | as_dirname=dirname | |
25498 | else | |
25499 | as_dirname=false | |
25500 | fi | |
1a4b763e | 25501 | |
5213506e | 25502 | as_me=`$as_basename -- "$0" || |
1a4b763e BS |
25503 | $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ |
25504 | X"$0" : 'X\(//\)$' \| \ | |
5213506e RW |
25505 | X"$0" : 'X\(/\)' \| . 2>/dev/null || |
25506 | $as_echo X/"$0" | | |
25507 | sed '/^.*\/\([^/][^/]*\)\/*$/{ | |
25508 | s//\1/ | |
25509 | q | |
25510 | } | |
25511 | /^X\/\(\/\/\)$/{ | |
25512 | s//\1/ | |
25513 | q | |
25514 | } | |
25515 | /^X\/\(\/\).*/{ | |
25516 | s//\1/ | |
25517 | q | |
25518 | } | |
25519 | s/.*/./; q'` | |
b61ff9c8 | 25520 | |
b61ff9c8 BS |
25521 | # Avoid depending upon Character Ranges. |
25522 | as_cr_letters='abcdefghijklmnopqrstuvwxyz' | |
25523 | as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' | |
25524 | as_cr_Letters=$as_cr_letters$as_cr_LETTERS | |
25525 | as_cr_digits='0123456789' | |
25526 | as_cr_alnum=$as_cr_Letters$as_cr_digits | |
25527 | ||
5213506e RW |
25528 | ECHO_C= ECHO_N= ECHO_T= |
25529 | case `echo -n x` in #((((( | |
25530 | -n*) | |
25531 | case `echo 'xy\c'` in | |
25532 | *c*) ECHO_T=' ';; # ECHO_T is single tab character. | |
25533 | xy) ECHO_C='\c';; | |
25534 | *) echo `echo ksh88 bug on AIX 6.1` > /dev/null | |
25535 | ECHO_T=' ';; | |
25536 | esac;; | |
25537 | *) | |
25538 | ECHO_N='-n';; | |
ba479fd2 NN |
25539 | esac |
25540 | ||
ba479fd2 | 25541 | rm -f conf$$ conf$$.exe conf$$.file |
5213506e RW |
25542 | if test -d conf$$.dir; then |
25543 | rm -f conf$$.dir/conf$$.file | |
25544 | else | |
25545 | rm -f conf$$.dir | |
25546 | mkdir conf$$.dir 2>/dev/null | |
25547 | fi | |
25548 | if (echo >conf$$.file) 2>/dev/null; then | |
25549 | if ln -s conf$$.file conf$$ 2>/dev/null; then | |
b61ff9c8 | 25550 | as_ln_s='ln -s' |
5213506e RW |
25551 | # ... but there are two gotchas: |
25552 | # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. | |
25553 | # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. | |
25554 | # In both cases, we have to default to `cp -p'. | |
25555 | ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || | |
25556 | as_ln_s='cp -p' | |
25557 | elif ln conf$$.file conf$$ 2>/dev/null; then | |
25558 | as_ln_s=ln | |
25559 | else | |
25560 | as_ln_s='cp -p' | |
b61ff9c8 | 25561 | fi |
ba479fd2 NN |
25562 | else |
25563 | as_ln_s='cp -p' | |
25564 | fi | |
5213506e RW |
25565 | rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file |
25566 | rmdir conf$$.dir 2>/dev/null | |
25567 | ||
25568 | ||
25569 | # as_fn_mkdir_p | |
25570 | # ------------- | |
25571 | # Create "$as_dir" as a directory, including parents if necessary. | |
25572 | as_fn_mkdir_p () | |
25573 | { | |
25574 | ||
25575 | case $as_dir in #( | |
25576 | -*) as_dir=./$as_dir;; | |
25577 | esac | |
25578 | test -d "$as_dir" || eval $as_mkdir_p || { | |
25579 | as_dirs= | |
25580 | while :; do | |
25581 | case $as_dir in #( | |
25582 | *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( | |
25583 | *) as_qdir=$as_dir;; | |
25584 | esac | |
25585 | as_dirs="'$as_qdir' $as_dirs" | |
25586 | as_dir=`$as_dirname -- "$as_dir" || | |
25587 | $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ | |
25588 | X"$as_dir" : 'X\(//\)[^/]' \| \ | |
25589 | X"$as_dir" : 'X\(//\)$' \| \ | |
25590 | X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || | |
25591 | $as_echo X"$as_dir" | | |
25592 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
25593 | s//\1/ | |
25594 | q | |
25595 | } | |
25596 | /^X\(\/\/\)[^/].*/{ | |
25597 | s//\1/ | |
25598 | q | |
25599 | } | |
25600 | /^X\(\/\/\)$/{ | |
25601 | s//\1/ | |
25602 | q | |
25603 | } | |
25604 | /^X\(\/\).*/{ | |
25605 | s//\1/ | |
25606 | q | |
25607 | } | |
25608 | s/.*/./; q'` | |
25609 | test -d "$as_dir" && break | |
25610 | done | |
25611 | test -z "$as_dirs" || eval "mkdir $as_dirs" | |
25612 | } || test -d "$as_dir" || as_fn_error "cannot create directory $as_dir" | |
25613 | ||
ba479fd2 | 25614 | |
5213506e | 25615 | } # as_fn_mkdir_p |
ba479fd2 | 25616 | if mkdir -p . 2>/dev/null; then |
5213506e | 25617 | as_mkdir_p='mkdir -p "$as_dir"' |
ba479fd2 | 25618 | else |
86da66b5 | 25619 | test -d ./-p && rmdir ./-p |
ba479fd2 NN |
25620 | as_mkdir_p=false |
25621 | fi | |
25622 | ||
5213506e RW |
25623 | if test -x / >/dev/null 2>&1; then |
25624 | as_test_x='test -x' | |
25625 | else | |
25626 | if ls -dL / >/dev/null 2>&1; then | |
25627 | as_ls_L_option=L | |
25628 | else | |
25629 | as_ls_L_option= | |
25630 | fi | |
25631 | as_test_x=' | |
25632 | eval sh -c '\'' | |
25633 | if test -d "$1"; then | |
25634 | test -d "$1/."; | |
25635 | else | |
25636 | case $1 in #( | |
25637 | -*)set "./$1";; | |
25638 | esac; | |
25639 | case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #(( | |
25640 | ???[sx]*):;;*)false;;esac;fi | |
25641 | '\'' sh | |
25642 | ' | |
25643 | fi | |
25644 | as_executable_p=$as_test_x | |
ba479fd2 NN |
25645 | |
25646 | # Sed expression to map a string onto a valid CPP name. | |
86da66b5 | 25647 | as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" |
ba479fd2 NN |
25648 | |
25649 | # Sed expression to map a string onto a valid variable name. | |
86da66b5 | 25650 | as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" |
ba479fd2 NN |
25651 | |
25652 | ||
ba479fd2 | 25653 | exec 6>&1 |
5213506e RW |
25654 | ## ----------------------------------- ## |
25655 | ## Main body of $CONFIG_STATUS script. ## | |
25656 | ## ----------------------------------- ## | |
25657 | _ASEOF | |
25658 | test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 | |
ba479fd2 | 25659 | |
5213506e RW |
25660 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
25661 | # Save the log message, to keep $0 and so on meaningful, and to | |
ba479fd2 | 25662 | # report actual input values of CONFIG_FILES etc. instead of their |
5213506e RW |
25663 | # values after options handling. |
25664 | ac_log=" | |
ba479fd2 | 25665 | This file was extended by $as_me, which was |
5213506e | 25666 | generated by GNU Autoconf 2.64. Invocation command line was |
ba479fd2 NN |
25667 | |
25668 | CONFIG_FILES = $CONFIG_FILES | |
25669 | CONFIG_HEADERS = $CONFIG_HEADERS | |
25670 | CONFIG_LINKS = $CONFIG_LINKS | |
25671 | CONFIG_COMMANDS = $CONFIG_COMMANDS | |
25672 | $ $0 $@ | |
25673 | ||
5213506e RW |
25674 | on `(hostname || uname -n) 2>/dev/null | sed 1q` |
25675 | " | |
25676 | ||
ba479fd2 NN |
25677 | _ACEOF |
25678 | ||
5213506e RW |
25679 | case $ac_config_files in *" |
25680 | "*) set x $ac_config_files; shift; ac_config_files=$*;; | |
25681 | esac | |
2f41c1d6 | 25682 | |
5213506e RW |
25683 | case $ac_config_headers in *" |
25684 | "*) set x $ac_config_headers; shift; ac_config_headers=$*;; | |
25685 | esac | |
b61ff9c8 | 25686 | |
b61ff9c8 | 25687 | |
5213506e RW |
25688 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
25689 | # Files that config.status was made for. | |
25690 | config_files="$ac_config_files" | |
25691 | config_headers="$ac_config_headers" | |
25692 | config_commands="$ac_config_commands" | |
ba479fd2 | 25693 | |
5213506e | 25694 | _ACEOF |
b61ff9c8 | 25695 | |
5213506e | 25696 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
ba479fd2 | 25697 | ac_cs_usage="\ |
5213506e RW |
25698 | \`$as_me' instantiates files and other configuration actions |
25699 | from templates according to the current configuration. Unless the files | |
25700 | and actions are specified as TAGs, all are instantiated by default. | |
ba479fd2 | 25701 | |
5213506e | 25702 | Usage: $0 [OPTION]... [TAG]... |
ba479fd2 NN |
25703 | |
25704 | -h, --help print this help, then exit | |
5213506e RW |
25705 | -V, --version print version number and configuration settings, then exit |
25706 | -q, --quiet, --silent | |
25707 | do not print progress messages | |
ba479fd2 NN |
25708 | -d, --debug don't remove temporary files |
25709 | --recheck update $as_me by reconfiguring in the same conditions | |
5213506e RW |
25710 | --file=FILE[:TEMPLATE] |
25711 | instantiate the configuration file FILE | |
25712 | --header=FILE[:TEMPLATE] | |
25713 | instantiate the configuration header FILE | |
ba479fd2 NN |
25714 | |
25715 | Configuration files: | |
25716 | $config_files | |
25717 | ||
25718 | Configuration headers: | |
25719 | $config_headers | |
25720 | ||
25721 | Configuration commands: | |
25722 | $config_commands | |
25723 | ||
5213506e | 25724 | Report bugs to the package provider." |
b61ff9c8 | 25725 | |
5213506e RW |
25726 | _ACEOF |
25727 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
ba479fd2 NN |
25728 | ac_cs_version="\\ |
25729 | config.status | |
5213506e RW |
25730 | configured by $0, generated by GNU Autoconf 2.64, |
25731 | with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\" | |
ba479fd2 | 25732 | |
5213506e | 25733 | Copyright (C) 2009 Free Software Foundation, Inc. |
ba479fd2 NN |
25734 | This config.status script is free software; the Free Software Foundation |
25735 | gives unlimited permission to copy, distribute and modify it." | |
5213506e RW |
25736 | |
25737 | ac_pwd='$ac_pwd' | |
25738 | srcdir='$srcdir' | |
25739 | AWK='$AWK' | |
25740 | test -n "\$AWK" || AWK=awk | |
ba479fd2 NN |
25741 | _ACEOF |
25742 | ||
5213506e RW |
25743 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
25744 | # The default lists apply if the user does not specify any file. | |
ba479fd2 NN |
25745 | ac_need_defaults=: |
25746 | while test $# != 0 | |
25747 | do | |
25748 | case $1 in | |
25749 | --*=*) | |
5213506e RW |
25750 | ac_option=`expr "X$1" : 'X\([^=]*\)='` |
25751 | ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` | |
ba479fd2 NN |
25752 | ac_shift=: |
25753 | ;; | |
5213506e | 25754 | *) |
ba479fd2 NN |
25755 | ac_option=$1 |
25756 | ac_optarg=$2 | |
25757 | ac_shift=shift | |
25758 | ;; | |
ba479fd2 NN |
25759 | esac |
25760 | ||
25761 | case $ac_option in | |
25762 | # Handling of the options. | |
ba479fd2 NN |
25763 | -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) |
25764 | ac_cs_recheck=: ;; | |
5213506e RW |
25765 | --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) |
25766 | $as_echo "$ac_cs_version"; exit ;; | |
25767 | --debug | --debu | --deb | --de | --d | -d ) | |
ba479fd2 NN |
25768 | debug=: ;; |
25769 | --file | --fil | --fi | --f ) | |
25770 | $ac_shift | |
5213506e RW |
25771 | case $ac_optarg in |
25772 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
25773 | esac | |
25774 | as_fn_append CONFIG_FILES " '$ac_optarg'" | |
ba479fd2 NN |
25775 | ac_need_defaults=false;; |
25776 | --header | --heade | --head | --hea ) | |
25777 | $ac_shift | |
5213506e RW |
25778 | case $ac_optarg in |
25779 | *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; | |
25780 | esac | |
25781 | as_fn_append CONFIG_HEADERS " '$ac_optarg'" | |
ba479fd2 | 25782 | ac_need_defaults=false;; |
5213506e RW |
25783 | --he | --h) |
25784 | # Conflict between --help and --header | |
25785 | as_fn_error "ambiguous option: \`$1' | |
25786 | Try \`$0 --help' for more information.";; | |
25787 | --help | --hel | -h ) | |
25788 | $as_echo "$ac_cs_usage"; exit ;; | |
ba479fd2 NN |
25789 | -q | -quiet | --quiet | --quie | --qui | --qu | --q \ |
25790 | | -silent | --silent | --silen | --sile | --sil | --si | --s) | |
25791 | ac_cs_silent=: ;; | |
25792 | ||
25793 | # This is an error. | |
5213506e RW |
25794 | -*) as_fn_error "unrecognized option: \`$1' |
25795 | Try \`$0 --help' for more information." ;; | |
ba479fd2 | 25796 | |
5213506e RW |
25797 | *) as_fn_append ac_config_targets " $1" |
25798 | ac_need_defaults=false ;; | |
ba479fd2 NN |
25799 | |
25800 | esac | |
25801 | shift | |
6e3f3080 | 25802 | done |
ba479fd2 NN |
25803 | |
25804 | ac_configure_extra_args= | |
25805 | ||
25806 | if $ac_cs_silent; then | |
25807 | exec 6>/dev/null | |
25808 | ac_configure_extra_args="$ac_configure_extra_args --silent" | |
861bb6c1 JL |
25809 | fi |
25810 | ||
ba479fd2 | 25811 | _ACEOF |
5213506e | 25812 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 |
ba479fd2 | 25813 | if \$ac_cs_recheck; then |
5213506e RW |
25814 | set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion |
25815 | shift | |
25816 | \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 | |
25817 | CONFIG_SHELL='$SHELL' | |
25818 | export CONFIG_SHELL | |
25819 | exec "\$@" | |
ba479fd2 | 25820 | fi |
861bb6c1 | 25821 | |
ba479fd2 | 25822 | _ACEOF |
5213506e RW |
25823 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
25824 | exec 5>>config.log | |
25825 | { | |
25826 | echo | |
25827 | sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX | |
25828 | ## Running $as_me. ## | |
25829 | _ASBOX | |
25830 | $as_echo "$ac_log" | |
25831 | } >&5 | |
ba479fd2 | 25832 | |
5213506e RW |
25833 | _ACEOF |
25834 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
ba479fd2 | 25835 | # |
5213506e | 25836 | # INIT-COMMANDS |
ba479fd2 | 25837 | # |
ba479fd2 | 25838 | subdirs='$subdirs' |
ba479fd2 NN |
25839 | |
25840 | _ACEOF | |
25841 | ||
5213506e | 25842 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
1a4b763e | 25843 | |
5213506e | 25844 | # Handling of arguments. |
ba479fd2 NN |
25845 | for ac_config_target in $ac_config_targets |
25846 | do | |
5213506e RW |
25847 | case $ac_config_target in |
25848 | "auto-host.h") CONFIG_HEADERS="$CONFIG_HEADERS auto-host.h:config.in" ;; | |
25849 | "as") CONFIG_FILES="$CONFIG_FILES as:exec-tool.in" ;; | |
25850 | "collect-ld") CONFIG_FILES="$CONFIG_FILES collect-ld:exec-tool.in" ;; | |
25851 | "nm") CONFIG_FILES="$CONFIG_FILES nm:exec-tool.in" ;; | |
25852 | "$all_outputs") CONFIG_FILES="$CONFIG_FILES $all_outputs" ;; | |
25853 | "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; | |
25854 | ||
25855 | *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; | |
861bb6c1 | 25856 | esac |
ba479fd2 NN |
25857 | done |
25858 | ||
5213506e | 25859 | |
ba479fd2 NN |
25860 | # If the user did not use the arguments to specify the items to instantiate, |
25861 | # then the envvar interface is used. Set only those that are not. | |
25862 | # We use the long form for the default assignment because of an extremely | |
25863 | # bizarre bug on SunOS 4.1.3. | |
25864 | if $ac_need_defaults; then | |
25865 | test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files | |
25866 | test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers | |
25867 | test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands | |
25868 | fi | |
25869 | ||
25870 | # Have a temporary directory for convenience. Make it in the build tree | |
5213506e | 25871 | # simply because there is no reason against having it here, and in addition, |
ba479fd2 | 25872 | # creating and moving files from /tmp can sometimes cause problems. |
5213506e RW |
25873 | # Hook for its removal unless debugging. |
25874 | # Note that there is a small window in which the directory will not be cleaned: | |
25875 | # after its creation but before its name has been assigned to `$tmp'. | |
ba479fd2 NN |
25876 | $debug || |
25877 | { | |
5213506e RW |
25878 | tmp= |
25879 | trap 'exit_status=$? | |
25880 | { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status | |
25881 | ' 0 | |
25882 | trap 'as_fn_exit 1' 1 2 13 15 | |
ba479fd2 | 25883 | } |
ba479fd2 | 25884 | # Create a (secure) tmp directory for tmp files. |
6e3f3080 | 25885 | |
ba479fd2 | 25886 | { |
5213506e | 25887 | tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && |
ba479fd2 NN |
25888 | test -n "$tmp" && test -d "$tmp" |
25889 | } || | |
25890 | { | |
5213506e RW |
25891 | tmp=./conf$$-$RANDOM |
25892 | (umask 077 && mkdir "$tmp") | |
25893 | } || as_fn_error "cannot create a temporary directory in ." "$LINENO" 5 | |
25894 | ||
25895 | # Set up the scripts for CONFIG_FILES section. | |
25896 | # No need to generate them if there are no CONFIG_FILES. | |
25897 | # This happens for instance with `./config.status config.h'. | |
25898 | if test -n "$CONFIG_FILES"; then | |
25899 | ||
25900 | if $AWK 'BEGIN { getline <"/dev/null" }' </dev/null 2>/dev/null; then | |
25901 | ac_cs_awk_getline=: | |
25902 | ac_cs_awk_pipe_init= | |
25903 | ac_cs_awk_read_file=' | |
25904 | while ((getline aline < (F[key])) > 0) | |
25905 | print(aline) | |
25906 | close(F[key])' | |
25907 | ac_cs_awk_pipe_fini= | |
25908 | else | |
25909 | ac_cs_awk_getline=false | |
25910 | ac_cs_awk_pipe_init="print \"cat <<'|#_!!_#|' &&\"" | |
25911 | ac_cs_awk_read_file=' | |
25912 | print "|#_!!_#|" | |
25913 | print "cat " F[key] " &&" | |
25914 | '$ac_cs_awk_pipe_init | |
25915 | # The final `:' finishes the AND list. | |
25916 | ac_cs_awk_pipe_fini='END { print "|#_!!_#|"; print ":" }' | |
25917 | fi | |
25918 | ac_cr=`echo X | tr X '\015'` | |
25919 | # On cygwin, bash can eat \r inside `` if the user requested igncr. | |
25920 | # But we know of no other shell where ac_cr would be empty at this | |
25921 | # point, so we can use a bashism as a fallback. | |
25922 | if test "x$ac_cr" = x; then | |
25923 | eval ac_cr=\$\'\\r\' | |
25924 | fi | |
25925 | ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` | |
25926 | if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then | |
25927 | ac_cs_awk_cr='\r' | |
25928 | else | |
25929 | ac_cs_awk_cr=$ac_cr | |
25930 | fi | |
25931 | ||
25932 | echo 'BEGIN {' >"$tmp/subs1.awk" && | |
25933 | _ACEOF | |
25934 | ||
25935 | # Create commands to substitute file output variables. | |
ba479fd2 | 25936 | { |
5213506e RW |
25937 | echo "cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1" && |
25938 | echo 'cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&' && | |
25939 | echo "$ac_subst_files" | sed 's/.*/F["&"]="$&"/' && | |
25940 | echo "_ACAWK" && | |
25941 | echo "_ACEOF" | |
25942 | } >conf$$files.sh && | |
25943 | . ./conf$$files.sh || | |
25944 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 | |
25945 | rm -f conf$$files.sh | |
ba479fd2 | 25946 | |
5213506e RW |
25947 | { |
25948 | echo "cat >conf$$subs.awk <<_ACEOF" && | |
25949 | echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && | |
25950 | echo "_ACEOF" | |
25951 | } >conf$$subs.sh || | |
25952 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 | |
25953 | ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'` | |
25954 | ac_delim='%!_!# ' | |
25955 | for ac_last_try in false false false false false :; do | |
25956 | . ./conf$$subs.sh || | |
25957 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 | |
25958 | ||
25959 | ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` | |
25960 | if test $ac_delim_n = $ac_delim_num; then | |
25961 | break | |
25962 | elif $ac_last_try; then | |
25963 | as_fn_error "could not make $CONFIG_STATUS" "$LINENO" 5 | |
25964 | else | |
25965 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
25966 | fi | |
25967 | done | |
25968 | rm -f conf$$subs.sh | |
25969 | ||
25970 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
25971 | cat >>"\$tmp/subs1.awk" <<\\_ACAWK && | |
25972 | _ACEOF | |
25973 | sed -n ' | |
25974 | h | |
25975 | s/^/S["/; s/!.*/"]=/ | |
25976 | p | |
25977 | g | |
25978 | s/^[^!]*!// | |
25979 | :repl | |
25980 | t repl | |
25981 | s/'"$ac_delim"'$// | |
25982 | t delim | |
25983 | :nl | |
25984 | h | |
25985 | s/\(.\{148\}\).*/\1/ | |
25986 | t more1 | |
25987 | s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ | |
25988 | p | |
25989 | n | |
25990 | b repl | |
25991 | :more1 | |
25992 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
25993 | p | |
25994 | g | |
25995 | s/.\{148\}// | |
25996 | t nl | |
25997 | :delim | |
25998 | h | |
25999 | s/\(.\{148\}\).*/\1/ | |
26000 | t more2 | |
26001 | s/["\\]/\\&/g; s/^/"/; s/$/"/ | |
26002 | p | |
26003 | b | |
26004 | :more2 | |
26005 | s/["\\]/\\&/g; s/^/"/; s/$/"\\/ | |
26006 | p | |
26007 | g | |
26008 | s/.\{148\}// | |
26009 | t delim | |
26010 | ' <conf$$subs.awk | sed ' | |
26011 | /^[^""]/{ | |
26012 | N | |
26013 | s/\n// | |
26014 | } | |
26015 | ' >>$CONFIG_STATUS || ac_write_fail=1 | |
26016 | rm -f conf$$subs.awk | |
26017 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
26018 | _ACAWK | |
26019 | cat >>"\$tmp/subs1.awk" <<_ACAWK && | |
26020 | for (key in S) S_is_set[key] = 1 | |
26021 | FS = "\a" | |
26022 | \$ac_cs_awk_pipe_init | |
26023 | } | |
26024 | { | |
26025 | line = $ 0 | |
26026 | nfields = split(line, field, "@") | |
26027 | substed = 0 | |
26028 | len = length(field[1]) | |
26029 | for (i = 2; i < nfields; i++) { | |
26030 | key = field[i] | |
26031 | keylen = length(key) | |
26032 | if (S_is_set[key]) { | |
26033 | value = S[key] | |
26034 | line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) | |
26035 | len += length(value) + length(field[++i]) | |
26036 | substed = 1 | |
26037 | } else | |
26038 | len += 1 + keylen | |
26039 | } | |
26040 | if (nfields == 3 && !substed) { | |
26041 | key = field[2] | |
26042 | if (F[key] != "" && line ~ /^[ ]*@.*@[ ]*$/) { | |
26043 | \$ac_cs_awk_read_file | |
26044 | next | |
26045 | } | |
26046 | } | |
26047 | print line | |
26048 | } | |
26049 | \$ac_cs_awk_pipe_fini | |
26050 | _ACAWK | |
26051 | _ACEOF | |
26052 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | |
26053 | if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then | |
26054 | sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" | |
26055 | else | |
26056 | cat | |
26057 | fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \ | |
26058 | || as_fn_error "could not setup config files machinery" "$LINENO" 5 | |
b61ff9c8 BS |
26059 | _ACEOF |
26060 | ||
5213506e RW |
26061 | # VPATH may cause trouble with some makes, so we remove $(srcdir), |
26062 | # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and | |
26063 | # trailing colons and then remove the whole line if VPATH becomes empty | |
26064 | # (actually we leave an empty line to preserve line numbers). | |
26065 | if test "x$srcdir" = x.; then | |
26066 | ac_vpsub='/^[ ]*VPATH[ ]*=/{ | |
26067 | s/:*\$(srcdir):*/:/ | |
26068 | s/:*\${srcdir}:*/:/ | |
26069 | s/:*@srcdir@:*/:/ | |
26070 | s/^\([^=]*=[ ]*\):*/\1/ | |
26071 | s/:*$// | |
26072 | s/^[^=]*=[ ]*$// | |
26073 | }' | |
26074 | fi | |
ba479fd2 | 26075 | |
5213506e RW |
26076 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
26077 | fi # test -n "$CONFIG_FILES" | |
b61ff9c8 | 26078 | |
5213506e RW |
26079 | # Set up the scripts for CONFIG_HEADERS section. |
26080 | # No need to generate them if there are no CONFIG_HEADERS. | |
26081 | # This happens for instance with `./config.status Makefile'. | |
26082 | if test -n "$CONFIG_HEADERS"; then | |
26083 | cat >"$tmp/defines.awk" <<\_ACAWK || | |
26084 | BEGIN { | |
b61ff9c8 BS |
26085 | _ACEOF |
26086 | ||
5213506e RW |
26087 | # Transform confdefs.h into an awk script `defines.awk', embedded as |
26088 | # here-document in config.status, that substitutes the proper values into | |
26089 | # config.h.in to produce config.h. | |
26090 | ||
26091 | # Create a delimiter string that does not exist in confdefs.h, to ease | |
26092 | # handling of long lines. | |
26093 | ac_delim='%!_!# ' | |
26094 | for ac_last_try in false false :; do | |
26095 | ac_t=`sed -n "/$ac_delim/p" confdefs.h` | |
26096 | if test -z "$ac_t"; then | |
26097 | break | |
26098 | elif $ac_last_try; then | |
26099 | as_fn_error "could not make $CONFIG_HEADERS" "$LINENO" 5 | |
26100 | else | |
26101 | ac_delim="$ac_delim!$ac_delim _$ac_delim!! " | |
1a4b763e | 26102 | fi |
5213506e | 26103 | done |
1a4b763e | 26104 | |
5213506e RW |
26105 | # For the awk script, D is an array of macro values keyed by name, |
26106 | # likewise P contains macro parameters if any. Preserve backslash | |
26107 | # newline sequences. | |
26108 | ||
26109 | ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]* | |
26110 | sed -n ' | |
26111 | s/.\{148\}/&'"$ac_delim"'/g | |
26112 | t rset | |
26113 | :rset | |
26114 | s/^[ ]*#[ ]*define[ ][ ]*/ / | |
26115 | t def | |
26116 | d | |
26117 | :def | |
26118 | s/\\$// | |
26119 | t bsnl | |
26120 | s/["\\]/\\&/g | |
26121 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
26122 | D["\1"]=" \3"/p | |
26123 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2"/p | |
26124 | d | |
26125 | :bsnl | |
26126 | s/["\\]/\\&/g | |
26127 | s/^ \('"$ac_word_re"'\)\(([^()]*)\)[ ]*\(.*\)/P["\1"]="\2"\ | |
26128 | D["\1"]=" \3\\\\\\n"\\/p | |
26129 | t cont | |
26130 | s/^ \('"$ac_word_re"'\)[ ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p | |
26131 | t cont | |
26132 | d | |
26133 | :cont | |
26134 | n | |
26135 | s/.\{148\}/&'"$ac_delim"'/g | |
26136 | t clear | |
26137 | :clear | |
26138 | s/\\$// | |
26139 | t bsnlc | |
26140 | s/["\\]/\\&/g; s/^/"/; s/$/"/p | |
26141 | d | |
26142 | :bsnlc | |
26143 | s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p | |
26144 | b cont | |
26145 | ' <confdefs.h | sed ' | |
26146 | s/'"$ac_delim"'/"\\\ | |
26147 | "/g' >>$CONFIG_STATUS || ac_write_fail=1 | |
26148 | ||
26149 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
26150 | for (key in D) D_is_set[key] = 1 | |
26151 | FS = "\a" | |
26152 | } | |
26153 | /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ { | |
26154 | line = \$ 0 | |
26155 | split(line, arg, " ") | |
26156 | if (arg[1] == "#") { | |
26157 | defundef = arg[2] | |
26158 | mac1 = arg[3] | |
26159 | } else { | |
26160 | defundef = substr(arg[1], 2) | |
26161 | mac1 = arg[2] | |
26162 | } | |
26163 | split(mac1, mac2, "(") #) | |
26164 | macro = mac2[1] | |
26165 | prefix = substr(line, 1, index(line, defundef) - 1) | |
26166 | if (D_is_set[macro]) { | |
26167 | # Preserve the white space surrounding the "#". | |
26168 | print prefix "define", macro P[macro] D[macro] | |
26169 | next | |
26170 | } else { | |
26171 | # Replace #undef with comments. This is necessary, for example, | |
26172 | # in the case of _POSIX_SOURCE, which is predefined and required | |
26173 | # on some systems where configure will not decide to define it. | |
26174 | if (defundef == "undef") { | |
26175 | print "/*", prefix defundef, macro, "*/" | |
26176 | next | |
26177 | } | |
26178 | } | |
26179 | } | |
26180 | { print } | |
26181 | _ACAWK | |
1a4b763e | 26182 | _ACEOF |
5213506e RW |
26183 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
26184 | as_fn_error "could not setup config headers machinery" "$LINENO" 5 | |
26185 | fi # test -n "$CONFIG_HEADERS" | |
26186 | ||
26187 | ||
26188 | eval set X " :F $CONFIG_FILES :H $CONFIG_HEADERS :C $CONFIG_COMMANDS" | |
26189 | shift | |
26190 | for ac_tag | |
26191 | do | |
26192 | case $ac_tag in | |
26193 | :[FHLC]) ac_mode=$ac_tag; continue;; | |
26194 | esac | |
26195 | case $ac_mode$ac_tag in | |
26196 | :[FHL]*:*);; | |
26197 | :L* | :C*:*) as_fn_error "invalid tag \`$ac_tag'" "$LINENO" 5;; | |
26198 | :[FH]-) ac_tag=-:-;; | |
26199 | :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; | |
26200 | esac | |
26201 | ac_save_IFS=$IFS | |
26202 | IFS=: | |
26203 | set x $ac_tag | |
26204 | IFS=$ac_save_IFS | |
26205 | shift | |
26206 | ac_file=$1 | |
26207 | shift | |
26208 | ||
26209 | case $ac_mode in | |
26210 | :L) ac_source=$1;; | |
26211 | :[FH]) | |
26212 | ac_file_inputs= | |
26213 | for ac_f | |
26214 | do | |
26215 | case $ac_f in | |
26216 | -) ac_f="$tmp/stdin";; | |
26217 | *) # Look for the file first in the build tree, then in the source tree | |
26218 | # (if the path is not absolute). The absolute path cannot be DOS-style, | |
26219 | # because $ac_f cannot contain `:'. | |
26220 | test -f "$ac_f" || | |
26221 | case $ac_f in | |
26222 | [\\/$]*) false;; | |
26223 | *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; | |
26224 | esac || | |
26225 | as_fn_error "cannot find input file: \`$ac_f'" "$LINENO" 5;; | |
26226 | esac | |
26227 | case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac | |
26228 | as_fn_append ac_file_inputs " '$ac_f'" | |
26229 | done | |
26230 | ||
26231 | # Let's still pretend it is `configure' which instantiates (i.e., don't | |
26232 | # use $as_me), people would be surprised to read: | |
26233 | # /* config.h. Generated by config.status. */ | |
26234 | configure_input='Generated from '` | |
26235 | $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' | |
26236 | `' by configure.' | |
26237 | if test x"$ac_file" != x-; then | |
26238 | configure_input="$ac_file. $configure_input" | |
26239 | { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 | |
26240 | $as_echo "$as_me: creating $ac_file" >&6;} | |
26241 | fi | |
26242 | # Neutralize special characters interpreted by sed in replacement strings. | |
26243 | case $configure_input in #( | |
26244 | *\&* | *\|* | *\\* ) | |
26245 | ac_sed_conf_input=`$as_echo "$configure_input" | | |
26246 | sed 's/[\\\\&|]/\\\\&/g'`;; #( | |
26247 | *) ac_sed_conf_input=$configure_input;; | |
26248 | esac | |
26249 | ||
26250 | case $ac_tag in | |
26251 | *:-:* | *:-) cat >"$tmp/stdin" \ | |
26252 | || as_fn_error "could not create $ac_file" "$LINENO" 5 ;; | |
26253 | esac | |
26254 | ;; | |
703d89ab ZW |
26255 | esac |
26256 | ||
5213506e | 26257 | ac_dir=`$as_dirname -- "$ac_file" || |
ba479fd2 | 26258 | $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ |
86da66b5 HPN |
26259 | X"$ac_file" : 'X\(//\)[^/]' \| \ |
26260 | X"$ac_file" : 'X\(//\)$' \| \ | |
5213506e RW |
26261 | X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || |
26262 | $as_echo X"$ac_file" | | |
26263 | sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ | |
26264 | s//\1/ | |
26265 | q | |
26266 | } | |
26267 | /^X\(\/\/\)[^/].*/{ | |
26268 | s//\1/ | |
26269 | q | |
26270 | } | |
26271 | /^X\(\/\/\)$/{ | |
26272 | s//\1/ | |
26273 | q | |
26274 | } | |
26275 | /^X\(\/\).*/{ | |
26276 | s//\1/ | |
26277 | q | |
26278 | } | |
26279 | s/.*/./; q'` | |
26280 | as_dir="$ac_dir"; as_fn_mkdir_p | |
ba479fd2 NN |
26281 | ac_builddir=. |
26282 | ||
5213506e RW |
26283 | case "$ac_dir" in |
26284 | .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
26285 | *) | |
26286 | ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` | |
26287 | # A ".." for each directory in $ac_dir_suffix. | |
26288 | ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` | |
26289 | case $ac_top_builddir_sub in | |
26290 | "") ac_top_builddir_sub=. ac_top_build_prefix= ;; | |
26291 | *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; | |
26292 | esac ;; | |
26293 | esac | |
26294 | ac_abs_top_builddir=$ac_pwd | |
26295 | ac_abs_builddir=$ac_pwd$ac_dir_suffix | |
26296 | # for backward compatibility: | |
26297 | ac_top_builddir=$ac_top_build_prefix | |
ba479fd2 NN |
26298 | |
26299 | case $srcdir in | |
5213506e | 26300 | .) # We are building in place. |
ba479fd2 | 26301 | ac_srcdir=. |
5213506e RW |
26302 | ac_top_srcdir=$ac_top_builddir_sub |
26303 | ac_abs_top_srcdir=$ac_pwd ;; | |
26304 | [\\/]* | ?:[\\/]* ) # Absolute name. | |
ba479fd2 | 26305 | ac_srcdir=$srcdir$ac_dir_suffix; |
5213506e RW |
26306 | ac_top_srcdir=$srcdir |
26307 | ac_abs_top_srcdir=$srcdir ;; | |
26308 | *) # Relative name. | |
26309 | ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix | |
26310 | ac_top_srcdir=$ac_top_build_prefix$srcdir | |
26311 | ac_abs_top_srcdir=$ac_pwd/$srcdir ;; | |
ba479fd2 | 26312 | esac |
5213506e | 26313 | ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix |
ba479fd2 | 26314 | |
703d89ab | 26315 | |
5213506e RW |
26316 | case $ac_mode in |
26317 | :F) | |
26318 | # | |
26319 | # CONFIG_FILE | |
26320 | # | |
ab22c1fa | 26321 | |
5213506e | 26322 | _ACEOF |
1a4b763e | 26323 | |
5213506e RW |
26324 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
26325 | # If the template does not know about datarootdir, expand it. | |
26326 | # FIXME: This hack should be removed a few years after 2.60. | |
26327 | ac_datarootdir_hack=; ac_datarootdir_seen= | |
26328 | ac_sed_dataroot=' | |
26329 | /datarootdir/ { | |
26330 | p | |
26331 | q | |
26332 | } | |
26333 | /@datadir@/p | |
26334 | /@docdir@/p | |
26335 | /@infodir@/p | |
26336 | /@localedir@/p | |
26337 | /@mandir@/p' | |
26338 | case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in | |
26339 | *datarootdir*) ac_datarootdir_seen=yes;; | |
26340 | *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) | |
26341 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 | |
26342 | $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} | |
26343 | _ACEOF | |
26344 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
26345 | ac_datarootdir_hack=' | |
26346 | s&@datadir@&$datadir&g | |
26347 | s&@docdir@&$docdir&g | |
26348 | s&@infodir@&$infodir&g | |
26349 | s&@localedir@&$localedir&g | |
26350 | s&@mandir@&$mandir&g | |
26351 | s&\\\${datarootdir}&$datarootdir&g' ;; | |
26352 | esac | |
a6ccdbab | 26353 | _ACEOF |
5213506e RW |
26354 | |
26355 | # Neutralize VPATH when `$srcdir' = `.'. | |
26356 | # Shell code in configure.ac might set extrasub. | |
26357 | # FIXME: do we really want to maintain this feature? | |
26358 | cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 | |
26359 | ac_sed_extra="$ac_vpsub | |
ba479fd2 NN |
26360 | $extrasub |
26361 | _ACEOF | |
5213506e | 26362 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
ba479fd2 NN |
26363 | :t |
26364 | /@[a-zA-Z_][a-zA-Z_0-9]*@/!b | |
5213506e RW |
26365 | s|@configure_input@|$ac_sed_conf_input|;t t |
26366 | s&@top_builddir@&$ac_top_builddir_sub&;t t | |
26367 | s&@top_build_prefix@&$ac_top_build_prefix&;t t | |
26368 | s&@srcdir@&$ac_srcdir&;t t | |
26369 | s&@abs_srcdir@&$ac_abs_srcdir&;t t | |
26370 | s&@top_srcdir@&$ac_top_srcdir&;t t | |
26371 | s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |
26372 | s&@builddir@&$ac_builddir&;t t | |
26373 | s&@abs_builddir@&$ac_abs_builddir&;t t | |
26374 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | |
26375 | $ac_datarootdir_hack | |
26376 | " | |
26377 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | | |
26378 | if $ac_cs_awk_getline; then | |
26379 | $AWK -f "$tmp/subs.awk" | |
26380 | else | |
26381 | $AWK -f "$tmp/subs.awk" | $SHELL | |
26382 | fi >$tmp/out \ | |
26383 | || as_fn_error "could not create $ac_file" "$LINENO" 5 | |
26384 | ||
26385 | test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && | |
26386 | { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } && | |
26387 | { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } && | |
26388 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
26389 | which seems to be undefined. Please make sure it is defined." >&5 | |
26390 | $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' | |
26391 | which seems to be undefined. Please make sure it is defined." >&2;} | |
26392 | ||
26393 | rm -f "$tmp/stdin" | |
b61ff9c8 | 26394 | case $ac_file in |
5213506e RW |
26395 | -) cat "$tmp/out" && rm -f "$tmp/out";; |
26396 | *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";; | |
26397 | esac \ | |
26398 | || as_fn_error "could not create $ac_file" "$LINENO" 5 | |
26399 | ;; | |
26400 | :H) | |
26401 | # | |
26402 | # CONFIG_HEADER | |
26403 | # | |
ba479fd2 | 26404 | if test x"$ac_file" != x-; then |
5213506e RW |
26405 | { |
26406 | $as_echo "/* $configure_input */" \ | |
26407 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" | |
26408 | } >"$tmp/config.h" \ | |
26409 | || as_fn_error "could not create $ac_file" "$LINENO" 5 | |
26410 | if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then | |
26411 | { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5 | |
26412 | $as_echo "$as_me: $ac_file is unchanged" >&6;} | |
ba479fd2 | 26413 | else |
5213506e RW |
26414 | rm -f "$ac_file" |
26415 | mv "$tmp/config.h" "$ac_file" \ | |
26416 | || as_fn_error "could not create $ac_file" "$LINENO" 5 | |
ba479fd2 NN |
26417 | fi |
26418 | else | |
5213506e RW |
26419 | $as_echo "/* $configure_input */" \ |
26420 | && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \ | |
26421 | || as_fn_error "could not create -" "$LINENO" 5 | |
ba479fd2 | 26422 | fi |
5213506e | 26423 | ;; |
b61ff9c8 | 26424 | |
5213506e RW |
26425 | :C) { $as_echo "$as_me:${as_lineno-$LINENO}: executing $ac_file commands" >&5 |
26426 | $as_echo "$as_me: executing $ac_file commands" >&6;} | |
26427 | ;; | |
26428 | esac | |
b61ff9c8 BS |
26429 | |
26430 | ||
5213506e RW |
26431 | case $ac_file$ac_mode in |
26432 | "as":F) chmod +x as ;; | |
26433 | "collect-ld":F) chmod +x collect-ld ;; | |
26434 | "nm":F) chmod +x nm ;; | |
26435 | "default":C) | |
f1faaabd NN |
26436 | case ${CONFIG_HEADERS} in |
26437 | *auto-host.h:config.in*) | |
26438 | echo > cstamp-h ;; | |
861bb6c1 | 26439 | esac |
2ed26f6b | 26440 | # Make sure all the subdirs exist. |
3b620440 | 26441 | for d in $subdirs doc build |
2ed26f6b | 26442 | do |
2ed26f6b | 26443 | test -d $d || mkdir $d |
2ed26f6b | 26444 | done |
ba479fd2 | 26445 | ;; |
5213506e | 26446 | |
ba479fd2 | 26447 | esac |
5213506e | 26448 | done # for ac_tag |
cafe096b | 26449 | |
ba479fd2 | 26450 | |
5213506e | 26451 | as_fn_exit 0 |
ba479fd2 | 26452 | _ACEOF |
ba479fd2 NN |
26453 | ac_clean_files=$ac_clean_files_save |
26454 | ||
5213506e RW |
26455 | test $ac_write_fail = 0 || |
26456 | as_fn_error "write failure creating $CONFIG_STATUS" "$LINENO" 5 | |
26457 | ||
ba479fd2 NN |
26458 | |
26459 | # configure is writing to config.log, and then calls config.status. | |
26460 | # config.status does its own redirection, appending to config.log. | |
26461 | # Unfortunately, on DOS this fails, as config.log is still kept open | |
26462 | # by configure, so config.status won't be able to write to it; its | |
26463 | # output is simply discarded. So we exec the FD to /dev/null, | |
26464 | # effectively closing config.log, so it can be properly (re)opened and | |
26465 | # appended to by config.status. When coming back to configure, we | |
26466 | # need to make the FD available again. | |
26467 | if test "$no_create" != yes; then | |
26468 | ac_cs_success=: | |
26469 | ac_config_status_args= | |
26470 | test "$silent" = yes && | |
26471 | ac_config_status_args="$ac_config_status_args --quiet" | |
26472 | exec 5>/dev/null | |
26473 | $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false | |
26474 | exec 5>>config.log | |
26475 | # Use ||, not &&, to avoid exiting from the if with $? = 1, which | |
26476 | # would make configure fail if this is the last instruction. | |
5213506e RW |
26477 | $ac_cs_success || as_fn_exit $? |
26478 | fi | |
26479 | if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then | |
26480 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 | |
26481 | $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} | |
ba479fd2 | 26482 | fi |
861bb6c1 | 26483 |